From c437da17409f22e26aa7f37180d993e3ecb9d369 Mon Sep 17 00:00:00 2001 From: Tyler Roach Date: Mon, 30 Jan 2023 11:49:14 -0500 Subject: [PATCH] Fix Authorization header for fetching hosted ui token when appSecret is used --- .../java/com/amplifyframework/auth/cognito/HostedUIClient.kt | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/aws-auth-cognito/src/main/java/com/amplifyframework/auth/cognito/HostedUIClient.kt b/aws-auth-cognito/src/main/java/com/amplifyframework/auth/cognito/HostedUIClient.kt index 8d7c3ca8a5..bbb5059580 100644 --- a/aws-auth-cognito/src/main/java/com/amplifyframework/auth/cognito/HostedUIClient.kt +++ b/aws-auth-cognito/src/main/java/com/amplifyframework/auth/cognito/HostedUIClient.kt @@ -181,7 +181,7 @@ internal class HostedUIClient private constructor( if (configuration.appSecret != null) { put( "Authorization", - PkceHelper.encodeBase64("${configuration.appClient}:${configuration.appSecret}") + "Basic ${PkceHelper.encodeBase64("${configuration.appClient}:${configuration.appSecret}")}" ) } }