Skip to content

Commit 1d524bd

Browse files
committed
msauth: set MSAL embedded webview window title
Set the MSAL embedded webview window to "Git Credential Manager" to give some context to the user where this dialog came from.
1 parent 301f888 commit 1d524bd

File tree

1 file changed

+8
-0
lines changed

1 file changed

+8
-0
lines changed

src/shared/Microsoft.Git.CredentialManager/Authentication/MicrosoftAuthentication.cs

Lines changed: 8 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -183,6 +183,7 @@ public async Task<IMicrosoftAuthenticationResult> GetTokenAsync(
183183
result = await app.AcquireTokenInteractive(scopes)
184184
.WithPrompt(Prompt.SelectAccount)
185185
.WithUseEmbeddedWebView(true)
186+
.WithEmbeddedWebViewOptions(GetEmbeddedWebViewOptions())
186187
.ExecuteAsync();
187188
break;
188189

@@ -407,6 +408,13 @@ private StorageCreationProperties CreateTokenCacheProps(bool useLinuxFallback)
407408
return builder.Build();
408409
}
409410

411+
private static EmbeddedWebViewOptions GetEmbeddedWebViewOptions()
412+
{
413+
return new EmbeddedWebViewOptions
414+
{
415+
Title = "Git Credential Manager"
416+
};
417+
}
410418

411419
private static SystemWebViewOptions GetSystemWebViewOptions()
412420
{

0 commit comments

Comments
 (0)