Skip to content
Draft
Show file tree
Hide file tree
Changes from 29 commits
Commits
Show all changes
31 commits
Select commit Hold shift + click to select a range
c48ee29
Complete Key Vault migration with ObjectId validation
RyAuld Oct 18, 2025
12e0e44
Complete Key Vault migration and update OnBehalfOf tests
RyAuld Oct 20, 2025
855e19b
Enhance lab infrastructure with debug logging and ADFS 2022 support
RyAuld Oct 24, 2025
ea1a6f7
Update UsernamePasswordIntegrationTests.NetFwk.cs with additional imp…
RyAuld Oct 24, 2025
5417662
Align UsernamePasswordIntegrationTests.NetFwk.cs with main branch - c…
RyAuld Oct 28, 2025
78659e9
Restore complete LabMigration version of UsernamePasswordIntegrationT…
RyAuld Oct 28, 2025
37e1665
Update LabUserHelper calls to use LabMigration enhanced methods while…
RyAuld Oct 28, 2025
86e591d
Fix GetHybridSpaAccontAsync to use Key Vault approach instead of old …
RyAuld Oct 28, 2025
67e51ac
Complete migration to new lab infrastructure
RyAuld Oct 28, 2025
30ee25b
Fix failing tests in labmigration branch
RyAuld Oct 28, 2025
4714ab9
Fix CacheCompat test compilation errors
RyAuld Oct 28, 2025
613d4dc
Trigger pipeline rebuild with latest changes
RyAuld Oct 28, 2025
352b44d
Migrate integration tests from MSIDLAB4 to id4slab1 tenant
RyAuld Oct 29, 2025
cfbd534
Complete MSAL.NET OBO integration test migration to ID4SLAB1 tenant
RyAuld Oct 30, 2025
61cc635
Migrate ADFS tests from fs.msidlab8.com to fs.id4slab1.com
RyAuld Oct 30, 2025
dc39585
Merge branch 'main' into labmigration
RyAuld Oct 30, 2025
ac6cd53
Add missing CreateAadTestTokenResponseWithMsalUserDefault method
RyAuld Oct 30, 2025
00cf259
Merge branch 'labmigration' of https://github.com/AzureAD/microsoft-a…
RyAuld Oct 30, 2025
10309b3
Fix tenant routing issue by using multi-tenant app for integration tests
RyAuld Oct 30, 2025
10f838b
Fix HybridSPA test to use multi-tenant app and clean up whitespace
RyAuld Oct 30, 2025
348813d
Clean up trailing whitespace in commented code
RyAuld Oct 31, 2025
b1eda23
Merge remote-tracking branch 'origin/main' into labmigration
RyAuld Oct 31, 2025
211f861
Fix device code flow tests to use tenant-specific authority
RyAuld Oct 31, 2025
8b63d36
Add GetDefaultUserWithMultiTenantAppAsync method and update device co…
RyAuld Oct 31, 2025
066af43
Fix AADSTS700016 errors by migrating to multi-tenant app configuration
RyAuld Oct 31, 2025
22ebda2
Fix additional tests using default user instead of multi-tenant app
RyAuld Oct 31, 2025
85ad81a
Fix more tests using /common endpoint with single-tenant app
RyAuld Oct 31, 2025
7a92a52
Final migration updates - OBO tests and interactive flow fixes
RyAuld Oct 31, 2025
ae9ba1a
Fix interactive tests to use correct app configuration
RyAuld Oct 31, 2025
b1fbc93
Remove Selenium.WebDriver.ChromeDriver package reference to match mai…
RyAuld Nov 4, 2025
bd86c1a
Merge branch 'main' into labmigration
RyAuld Nov 5, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
529,229 changes: 529,229 additions & 0 deletions 60.txt

Large diffs are not rendered by default.

11 changes: 5 additions & 6 deletions tests/CacheCompat/CommonCache.Test.Unit/CacheExecutionTests.cs
Original file line number Diff line number Diff line change
Expand Up @@ -19,13 +19,12 @@ public class CacheExecutionTests

private static async Task<LabUserData> GetPublicAadUserDataAsync()
{
var api = new LabServiceApi();
LabResponse labResponse = (await api.GetLabResponseFromApiAsync(UserQuery.PublicAadUserQuery).ConfigureAwait(false));
var labUser = await LabUserHelper.GetDefaultUserAsync().ConfigureAwait(false);
return new LabUserData(
labResponse.User.Upn,
labResponse.User.GetOrFetchPassword(),
labResponse.User.AppId,
labResponse.User.TenantId);
labUser.User.Upn,
labUser.User.GetOrFetchPassword(),
labUser.App.AppId,
labUser.User.TenantId);
}

[AssemblyInitialize]
Expand Down
19 changes: 16 additions & 3 deletions tests/Microsoft.Identity.Test.Common/TestConstants.cs
Original file line number Diff line number Diff line change
Expand Up @@ -32,8 +32,9 @@ public static HashSet<string> s_scope
public const string MsiResource = "scope";
public static readonly string[] s_graphScopes = new[] { "user.read" };
public const uint JwtToAadLifetimeInSeconds = 60 * 10; // Ten minutes
public const string ClientCredentialAudience = "https://login.microsoftonline.com/f645ad92-e38d-4d1a-b510-d1b09a74a8ca/v2.0";
public const string PublicCloudConfidentialClientID = "88f91eac-c606-4c67-a0e2-a5e8a186854f";
// TODO: Tenant Migration - Migrated to new id4slab1 tenant, legacy values: f645ad92-e38d-4d1a-b510-d1b09a74a8ca, 88f91eac-c606-4c67-a0e2-a5e8a186854f
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

What is the action behind the "TODO"?

public const string ClientCredentialAudience = "https://login.microsoftonline.com/10c419d4-4a50-45b2-aa4e-919fb84df24f/v2.0";
public const string PublicCloudConfidentialClientID = "54a2d933-8bf8-483b-a8f8-0a31924f3c1f";
public const string AutomationTestCertName = "LabAuth.MSIDLab.com";
public static Dictionary<string, string> AdditionalAssertionClaims =>
new Dictionary<string, string>() { { "Key1", "Val1" }, { "Key2", "Val2" }, { "customClaims", "{\"xms_az_claim\": [\"GUID\", \"GUID2\", \"GUID3\"]}" } };
Expand Down Expand Up @@ -74,6 +75,9 @@ public static HashSet<string> s_scope

public const string ProductionPrefNetworkEnvironment = "login.microsoftonline.com";
public const string ProductionPrefCacheEnvironment = "login.windows.net";
// TODO: Tenant Migration - Regional endpoint may need update after migration
// Current: centralus (old tenant), New: eastus2 (id4slab1 tenant)
// Note: Regional endpoints may not work with new tenant due to AADSTS100007 restrictions
public const string ProductionPrefRegionalEnvironment = "centralus.login.microsoft.com";
public const string ProductionPrefInvalidRegionEnvironment = "invalidregion.login.microsoft.com";
public const string ProductionNotPrefEnvironmentAlias = "sts.windows.net";
Expand Down Expand Up @@ -204,7 +208,7 @@ public static HashSet<string> s_scope
public const string PKeyAuthResponse = "PKeyAuth Context=\"context\",Version=\"1.0\"";

public const string RegionName = "REGION_NAME";
public const string Region = "centralus";
public const string Region = "centralus"; // TODO: Tenant Migration - Update for new tenant (id4slab1) is in eastus2
public const string InvalidRegion = "invalidregion";
public const int TimeoutInMs = 2000;
public const string ImdsHost = "169.254.169.254";
Expand Down Expand Up @@ -250,6 +254,7 @@ public static IDictionary<string, string> ExtraQueryParameters
public const string MsalCCAKeyVaultUri = "https://id4skeyvault.vault.azure.net/secrets/AzureADIdentityDivisionTestAgentSecret/";

public const string MsalCCAKeyVaultSecretName = "MSIDLAB4-IDLABS-APP-AzureADMyOrg-CC";
// TODO: Tenant Migration - New secret name for id4slab1 tenant: "MSAL-APP-AzureADMultipleOrgs"
public const string MsalOBOKeyVaultUri = "https://id4skeyvault.vault.azure.net/secrets/IdentityDivisionDotNetOBOServiceSecret/";
public const string MsalOBOKeyVaultSecretName = "IdentityDivisionDotNetOBOServiceSecret";
public const string MsalArlingtonOBOKeyVaultUri = "https://msidlabs.vault.azure.net:443/secrets/ARLMSIDLAB1-IDLASBS-App-CC-Secret";
Expand Down Expand Up @@ -583,6 +588,14 @@ public static MsalTokenResponse CreateAadTestTokenResponseWithFoci()
return msalTokenResponse;
}

public static MsalTokenResponse CreateAadTestTokenResponseWithMsalUserDefault()
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is for unit tests only I believe. Unit tests do not make HTTP calls to Entra and do not rely on an actual infra. I would recommend not modifying this.

{
// Token response with MSAL User Default user information for ID4SLAB1 tenant
const string jsonResponse = "{\"token_type\":\"Bearer\",\"scope\":\"Calendars.Read openid profile Tasks.Read User.Read email\",\"expires_in\":3600,\"ext_expires_in\":262800,\"access_token\":\"<removed_at>\",\"refresh_token\":\"<removed_rt>\",\"id_token\":\"eyJhbGciOiJIUzI1NiIsInR5cCI6IkpXVCJ9.eyJhdWQiOiJiNmM2OWEzNy1kZjk2LTRkYjAtOTA4OC0yYWI5NmUxZDgyMTUiLCJpc3MiOiJodHRwczovL2xvZ2luLm1pY3Jvc29mdG9ubGluZS5jb20vZjY0NWFkOTItZTM4ZC00ZDFhLWI1MTAtZDFiMDlhNzRhOGNhL3YyLjAiLCJpYXQiOjE1Mzg1Mzg0MjIsIm5iZiI6MTUzODUzODQyMiwiZXhwIjoxNTM4NTQyMzIyLCJuYW1lIjoiTVNBTCBVc2VyIERlZmF1bHQiLCJvaWQiOiI5ZjQ4ODBkOC04MGJhLTRjNDAtOTdiYy1mN2EyM2M3MDMwODQiLCJwcmVmZXJyZWRfdXNlcm5hbWUiOiJNU0FMLVVzZXItRGVmYXVsdEBpZDRzbGFiMS5vbm1pY3Jvc29mdC5jb20iLCJzdWIiOiJZNllrQmRITk5MSE5tVEtlbDlLaFJ6OHdyYXN4ZExSRmlQMTRCUlBXcm40IiwidGlkIjoiZjY0NWFkOTItZTM4ZC00ZDFhLWI1MTAtZDFiMDlhNzRhOGNhIiwidXRpIjoiNm5jaVgwMlNNa2k5azczLUYxc1pBQSIsInZlciI6IjIuMCJ9.\",\"client_info\":\"" + AadRawClientInfo + "\"}";
var msalTokenResponse = JsonHelper.DeserializeFromJson<MsalTokenResponse>(jsonResponse);
return msalTokenResponse;
}

// Fake strings approximately representing tokens of real-world size
internal const string AppAccessToken = "a9sVdA2UrU0KbsG19MjSZp4hlrd4B3mhZc1gfWsu1v3Nxuf9y7MMqdmCqyt4OwJ7cZEFAhdy8wf9vRastaS0Dcc6MnAtaI73k9co06QtQgecLPVMR23ht6cWB25Ta7yqdcQ8X7ARdUD4MWY6o01TqADKE4Vo3DMpzZiwpiS6Z81I5bW9jbWiUTT7J44lRM1qR3ZJUdaa6OSOaLZT4temLYy3bXZh6Bvu7fxOF1pStzwESRDiFegYq6LFf1sHVY5scdvNOifQnWuRy4bWw0Fl17IO5lKzhuEUvaOcgyWea0Hg3Rh9U0or2WPogJna7HraHdp0BWtuj3KOdXqmjxDoFKkTfBXiubpnAqlWwfAKHvKYefNuSRT7ewHLFQNpVVbr93P1Na4aMHqL4DWIQ1BEYoRskQkxNDtzeipb5CP5FrfStz8lFB4nCaZsJPqIzi82BpZ4HwXls8VYrRLt2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SUpZNQwRh3wHidZAkp1xyjyVc2pIHPg6XhzJnlt77zHNiBkPxWbYt7hXBQf3QeYoMF4s0Qi1y5N72DdoSNJ3iaTwx3esAz6TeyxSh36PIz35mR5jGyGMssyaNg6lIewLPbjnizgC6xssi6mKOheDqWqBv89nIvSBOXEkKcUYsBlhBBK6BgxOIha1NAeP93RRKfyjrF7LtIoSOk3DJUx75rUJ9oyuuTt4FdSnp7ZdrIciO8vlNslPrfa7UjBdOtVHiaz9Ef91dctdADVFcwXXmcu2ypyKB1YvMbkPP7mc12TF1a8X6t0mU4s4J4IpA3SHmT5JvbQBEzOIs6ex38X3UtXSItxpaS2gKozAhAmvjt6NKMe3Jysm4bafH1kb8eB1vdwTQu3jIOGozqHC3rvqEVAt26NNKOuNYAoYYamQOSb2w8PUCuDDWs1ffLvvfyvRndZztV5C4HGGR1Tg82N291Sb7rSUYmA1rdGyJ4kPtSaiPOwMyPUs9FuZNef5Ib83D3gTcgS1gMxto5UkfSxtCDKLXtGKArOdACrRzHiiMSn3owQfyVtSXZPdeofoCzuPWcZzFLBUJR0iKWBpUkxd0N17vw45uMQpQUNGgGoyvyboKkAFlOGsEIAmrnooC3CJGVA4jHPYJnVG4xTJ37U6QL5sX95qWtjbvuD5KoT2GyWec0o62CNr09tCQsiALLC1QrfCiCGsullefbsgBB5tsOY1Kyiy4uf84qBMu20GbsJ01R8xxpJ5bh6HFRaStEK3WIy7TMJym42YMbxB3AGsGFGhNYljtuqgeUjXn1UuWskkB6QqdepFHCof6CHg0LlV0o4Iz9QKu5cfoi8jk5HKbvIGyDqCgZaC2LdugNgQ0X";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -29,6 +29,11 @@ namespace Microsoft.Identity.Test.Integration.HeadlessTests
[TestClass]
public class RegionalAuthIntegrationTests
{
// TODO: TENANT MIGRATION - These tests currently use original tenant configuration
// Regional endpoints (eastus2.login.microsoft.com) return AADSTS100007 with new tenant
// "Only managed identities and Microsoft internal service identities are supported"
Copy link
Member

@bgavrilMS bgavrilMS Nov 3, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ack. Let's have a list of these. We will talk to AAD to enable these features.

// Regional endpoints are restricted by Azure AD policy for regular app registrations

private KeyVaultSecretsProvider _keyVault;

private const string RegionalHost = "centralus.login.microsoft.com";
Expand Down Expand Up @@ -59,7 +64,7 @@ public async Task AcquireTokenToRegionalEndpointAsync(bool instanceDiscoveryEnab
{
// Arrange
var factory = new HttpSnifferClientFactory();
var settings = ConfidentialAppSettings.GetSettings(Cloud.Public);
var settings = ConfidentialAppSettings.GetSettings(Cloud.PublicLegacy); // Use legacy config for regional tests
settings.InstanceDiscoveryEndpoint = instanceDiscoveryEnabled;
_confidentialClientApplication = BuildCCA(settings, factory);

Expand All @@ -78,7 +83,7 @@ public async Task InvalidRegion_GoesToInvalidAuthority_Async()
{
// Arrange
var factory = new HttpSnifferClientFactory();
var settings = ConfidentialAppSettings.GetSettings(Cloud.Public);
var settings = ConfidentialAppSettings.GetSettings(Cloud.PublicLegacy); // Use legacy config for regional tests
_confidentialClientApplication = BuildCCA(settings, factory, true, "invalid");

Environment.SetEnvironmentVariable(TestConstants.RegionName, TestConstants.Region);
Expand Down Expand Up @@ -193,7 +198,7 @@ private static string GetSignedClientAssertionUsingMsalInternal(string clientId,
var manager = PlatformProxyFactory.CreatePlatformProxy(null).CryptographyManager;

var jwtToken = new JsonWebToken(manager, clientId, TestConstants.ClientCredentialAudience, claims);
var cert = ConfidentialAppSettings.GetSettings(Cloud.Public).GetCertificate();
var cert = ConfidentialAppSettings.GetSettings(Cloud.PublicLegacy).GetCertificate(); // Use legacy config for regional tests

return jwtToken.Sign(cert, true, true);
}
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@ public async Task AuthorityMigrationAsync()
[TestMethod]
public async Task FailedAuthorityValidationTestAsync()
{
LabResponse labResponse = await LabUserHelper.GetDefaultUserAsync().ConfigureAwait(false);
LabResponse labResponse = await LabUserHelper.GetDefaultUserWithMultiTenantAppAsync().ConfigureAwait(false);
LabUser user = labResponse.User;

IPublicClientApplication pca = PublicClientApplicationBuilder
Expand Down Expand Up @@ -97,7 +97,7 @@ public async Task FailedAuthorityValidationTestAsync()
[TestMethod]
public async Task AuthorityValidationTestWithFalseValidateAuthorityAsync()
{
LabResponse labResponse = await LabUserHelper.GetDefaultUserAsync().ConfigureAwait(false);
LabResponse labResponse = await LabUserHelper.GetDefaultUserWithMultiTenantAppAsync().ConfigureAwait(false);
LabUser user = labResponse.User;

IPublicClientApplication pca = PublicClientApplicationBuilder
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -22,22 +22,26 @@ public class LongRunningOnBehalfOfTests
{
private static readonly string[] s_scopes = { "User.Read" };
private static readonly string[] s_oboServiceScope = { "api://23c64cd8-21e4-41dd-9756-ab9e2c23f58c/access_as_user" };
const string PublicClientID = "be9b0186-7dfd-448a-a944-f771029105bf";
const string OboConfidentialClientID = "23c64cd8-21e4-41dd-9756-ab9e2c23f58c";

private string _confidentialClientSecret;
private string _multiTenantAppId; // Will be set in test initialize

private readonly KeyVaultSecretsProvider _keyVault = new KeyVaultSecretsProvider(KeyVaultInstance.MsalTeam);

#region Test Hooks
[TestInitialize]
public void TestInitialize()
public async Task TestInitializeAsync()
{
ApplicationBase.ResetStateForTest();
if (string.IsNullOrEmpty(_confidentialClientSecret))
{
_confidentialClientSecret = _keyVault.GetSecretByName(TestConstants.MsalOBOKeyVaultSecretName).Value;
}

// Get the multi-tenant app ID for use in tests
var labResponse = await LabUserHelper.GetDefaultUserWithMultiTenantAppAsync().ConfigureAwait(false);
_multiTenantAppId = labResponse.App.AppId;
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

It seems like each test anyway calls GetDefaultUserWithMultiTenantAppAsync ? So there's not need to call it in the TestInitialize

}

#endregion
Expand All @@ -52,9 +56,9 @@ public void TestInitialize()
[TestMethod]
public async Task LongRunningAndNormalObo_WithDifferentKeys_TestAsync()
{
var user1 = (await LabUserHelper.GetSpecificUserAsync("[email protected]").ConfigureAwait(false)).User;
var user1 = (await LabUserHelper.GetDefaultUserWithMultiTenantAppAsync().ConfigureAwait(false)).User;
var pca = PublicClientApplicationBuilder
.Create(PublicClientID)
.Create(_multiTenantAppId)
.WithAuthority(AadAuthorityAudience.AzureAdMultipleOrgs)
.Build();

Expand Down Expand Up @@ -104,9 +108,9 @@ public async Task LongRunningAndNormalObo_WithDifferentKeys_TestAsync()
[TestMethod]
public async Task LongRunningThenNormalObo_WithTheSameKey_TestAsync()
{
var user1 = (await LabUserHelper.GetSpecificUserAsync("[email protected]").ConfigureAwait(false)).User;
var user1 = (await LabUserHelper.GetDefaultUserWithMultiTenantAppAsync().ConfigureAwait(false)).User;
var pca = PublicClientApplicationBuilder
.Create(PublicClientID)
.Create(_multiTenantAppId)
.WithAuthority(AadAuthorityAudience.AzureAdMultipleOrgs)
.Build();

Expand Down Expand Up @@ -177,9 +181,9 @@ public async Task LongRunningThenNormalObo_WithTheSameKey_TestAsync()
public async Task InitiateLRWithCustomKey_ThenAcquireLRWithSameKey_Succeeds_TestAsync()
{
// Arrange
LabUser user1 = (await LabUserHelper.GetSpecificUserAsync("[email protected]").ConfigureAwait(false)).User;
LabUser user1 = (await LabUserHelper.GetDefaultUserWithMultiTenantAppAsync().ConfigureAwait(false)).User;
IPublicClientApplication pca = PublicClientApplicationBuilder
.Create(PublicClientID)
.Create(_multiTenantAppId)
.WithAuthority(AadAuthorityAudience.AzureAdMultipleOrgs)
.Build();

Expand Down Expand Up @@ -248,9 +252,9 @@ public async Task InitiateLRWithCustomKey_ThenAcquireLRWithSameKey_Succeeds_Test
[TestMethod]
public async Task NormalOboThenLongRunningAcquire_WithTheSameKey_TestAsync()
{
var user1 = (await LabUserHelper.GetSpecificUserAsync("[email protected]").ConfigureAwait(false)).User;
LabUser user1 = (await LabUserHelper.GetDefaultUserWithMultiTenantAppAsync().ConfigureAwait(false)).User;
var pca = PublicClientApplicationBuilder
.Create(PublicClientID)
.Create(_multiTenantAppId)
.WithAuthority(AadAuthorityAudience.AzureAdMultipleOrgs)
.Build();

Expand Down Expand Up @@ -319,9 +323,9 @@ public async Task NormalOboThenLongRunningAcquire_WithTheSameKey_TestAsync()
[TestMethod]
public async Task NormalOboThenLongRunningInitiate_WithTheSameKey_TestAsync()
{
var user1 = (await LabUserHelper.GetSpecificUserAsync("[email protected]").ConfigureAwait(false)).User;
var user1 = (await LabUserHelper.GetDefaultUserWithMultiTenantAppAsync().ConfigureAwait(false)).User;
var pca = PublicClientApplicationBuilder
.Create(PublicClientID)
.Create(_multiTenantAppId)
.WithAuthority(AadAuthorityAudience.AzureAdMultipleOrgs)
.Build();

Expand Down Expand Up @@ -375,10 +379,10 @@ public async Task NormalOboThenLongRunningInitiate_WithTheSameKey_TestAsync()
[TestMethod]
public async Task WithDifferentScopes_TestAsync()
{
string[] scopes2 = { "api://eec635da-5760-452d-940a-448220db047c/access_as_user" };
var user1 = (await LabUserHelper.GetSpecificUserAsync("[email protected]").ConfigureAwait(false)).User;
string[] scopes2 = { "api://23c64cd8-21e4-41dd-9756-ab9e2c23f58c/access_as_user" };
var user1 = (await LabUserHelper.GetDefaultUserWithMultiTenantAppAsync().ConfigureAwait(false)).User;
var pca = PublicClientApplicationBuilder
.Create(PublicClientID)
.Create(_multiTenantAppId)
.WithAuthority(AadAuthorityAudience.AzureAdMultipleOrgs)
.WithRedirectUri("https://login.microsoftonline.com/common/oauth2/nativeclient")
.Build();
Expand Down
Loading
Loading