update_chap_credentials
async
¶
update_chap_credentials(
target_arn: TargetARN,
secret_to_authenticate_initiator: ChapSecret,
initiator_name: IqnName,
*,
config_overrides: Optional[AsyncStorageGatewayClientConfig] = None,
secret_to_authenticate_target: Optional[ChapSecret] = None,
) -> UpdateChapCredentialsOutput
Updates the Challenge-Handshake Authentication Protocol (CHAP) credentials for a specified iSCSI target. By default, a gateway does not have CHAP enabled; however, for added security, you might use it. This operation is supported in the volume and tape gateway types.
When you update CHAP credentials, all existing connections on the target are closed and initiators must reconnect with the new credentials.
Parameters:
-
target_arn(TargetARN) –The Amazon Resource Name (ARN) of the iSCSI volume target. Use the DescribeStorediSCSIVolumes operation to return the TargetARN for specified VolumeARN.
-
secret_to_authenticate_initiator(ChapSecret) –The secret key that the initiator (for example, the Windows client) must provide to participate in mutual CHAP with the target.
The secret key must be between 12 and 16 bytes when encoded in UTF-8.
-
initiator_name(IqnName) –The iSCSI initiator that connects to the target.
-
secret_to_authenticate_target(Optional[ChapSecret], default:None) –The secret key that the target must provide to participate in mutual CHAP with the initiator (e.g. Windows client).
Byte constraints: Minimum bytes of 12. Maximum bytes of 16.
The secret key must be between 12 and 16 bytes when encoded in UTF-8.
Raises:
-
InternalServerError–An internal server error has occurred during the request. For more information, see the error and message fields.
-
InvalidGatewayRequestException–An exception occurred because an invalid gateway request was issued to the service. For more information, see the error and message fields.
-
UnknownServiceError–The service returned an error code this client does not model.
Examples:
To update CHAP credentials for an iSCSI target Updates the Challenge-Handshake Authentication Protocol (CHAP) credentials for a specified iSCSI target.
>>> await client.update_chap_credentials(target_arn='arn:aws:storagegateway:us-east-1:111122223333:gateway/sgw-12A3456B/target/iqn.1997-05.com.amazon:myvolume', secret_to_authenticate_initiator='111111111111', initiator_name='iqn.1991-05.com.microsoft:computername.domain.example.com', secret_to_authenticate_target='222222222222')
Source code in docs_src/capo_storage_gateway/_services/async_storage_gateway.py
5739 5740 5741 5742 5743 5744 5745 5746 5747 5748 5749 5750 5751 5752 5753 5754 5755 5756 5757 5758 5759 5760 5761 5762 5763 5764 5765 5766 5767 5768 5769 5770 5771 5772 5773 5774 5775 5776 5777 5778 5779 5780 5781 5782 5783 5784 5785 5786 5787 5788 5789 5790 5791 5792 5793 5794 5795 5796 5797 5798 5799 5800 5801 5802 5803 5804 5805 5806 5807 5808 5809 5810 5811 5812 | |