TCognitoIdentityProviderSecretHashEncoder
Class in AWS.CognitoIdentityProvider
Encoder utility for generating "secret hash" values used in authentication requests made to Cognito User Pools.
Ancestors
TObject
Constructors
Create
constructor Create(const AClientId, AClientSecret: string);
Constructor for TCognitoIdentityProviderSecretHashEncoder.
Parameters
| Name | Description |
|---|---|
AClientId | Specify the app client ID. |
AClientSecret | Specify the secret for the client ID. |
Methods
Encode
class function Encode(const AClientId, AClientSecret, AUsername: string): string; overload; static;
Encode a secret hash for a given username for the configured client.
Parameters
| Name | Description |
|---|---|
AClientId | Specify the app client ID. |
AClientSecret | Specify the secret for the client ID. |
AUsername | Specify the username. |
Returns
Returns an Base64 encoded string value of the calculated hash.
function Encode(const AUsername: string): string; overload;
Encode a secret hash for a given username for the configured client.
Parameters
| Name | Description |
|---|---|
AUsername | Specify the username. |
Returns
Returns an Base64 encoded string value of the calculated hash.