update_chap_credentials
¶
update_chap_credentials(
target_arn: TargetARN,
secret_to_authenticate_initiator: ChapSecret,
initiator_name: IqnName,
*,
config_overrides: Optional[StorageGatewayClientConfig] = 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.
>>> 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/storage_gateway.py
5655 5656 5657 5658 5659 5660 5661 5662 5663 5664 5665 5666 5667 5668 5669 5670 5671 5672 5673 5674 5675 5676 5677 5678 5679 5680 5681 5682 5683 5684 5685 5686 5687 5688 5689 5690 5691 5692 5693 5694 5695 5696 5697 5698 5699 5700 5701 5702 5703 5704 5705 5706 5707 5708 5709 5710 5711 5712 5713 5714 5715 5716 5717 5718 5719 5720 5721 5722 5723 5724 5725 5726 5727 | |