Skip to content

Commit 1992155

Browse files
authored
[dotnet] Remove IdentityModel nuget from bazel workspace (#12834)
* Remove IdentityModel from bazel workspace * Make Base64UrlEncoder as public * Make Base64UrlEncoder back to internal
1 parent 9a6947e commit 1992155

File tree

5 files changed

+10
-33
lines changed

5 files changed

+10
-33
lines changed

dotnet/src/webdriver/BUILD.bazel

Lines changed: 2 additions & 6 deletions
Original file line numberDiff line numberDiff line change
@@ -40,6 +40,7 @@ csharp_library(
4040
"IE/*.cs",
4141
"Interactions/*.cs",
4242
"Internal/*.cs",
43+
"Properties/*.cs",
4344
"Remote/**/*.cs",
4445
"Safari/*.cs",
4546
"Support/*.cs",
@@ -60,9 +61,6 @@ csharp_library(
6061
],
6162
visibility = ["//visibility:public"],
6263
deps = [
63-
"@identitymodel.abstractions//:Microsoft.IdentityModel.Abstractions",
64-
"@identitymodel.logging//:Microsoft.IdentityModel.Logging",
65-
"@identitymodel.tokens//:Microsoft.IdentityModel.Tokens",
6664
"@json.net//:Newtonsoft.Json",
6765
"@system.drawing.common//:System.Drawing.Common",
6866
],
@@ -80,6 +78,7 @@ csharp_library(
8078
"IE/*.cs",
8179
"Interactions/*.cs",
8280
"Internal/*.cs",
81+
"Properties/*.cs",
8382
"Remote/**/*.cs",
8483
"Safari/*.cs",
8584
"Support/*.cs",
@@ -101,9 +100,6 @@ csharp_library(
101100
],
102101
visibility = ["//visibility:public"],
103102
deps = [
104-
"@identitymodel.abstractions//:Microsoft.IdentityModel.Abstractions",
105-
"@identitymodel.logging//:Microsoft.IdentityModel.Logging",
106-
"@identitymodel.tokens//:Microsoft.IdentityModel.Tokens",
107103
"@json.net//:Newtonsoft.Json",
108104
"@system.drawing.common//:System.Drawing.Common",
109105
],
Lines changed: 3 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,3 @@
1+
using System.Runtime.CompilerServices;
2+
3+
[assembly:InternalsVisibleTo("WebDriver.Common.Tests")]

dotnet/test/common/VirtualAuthn/VirtualAuthenticatorTest.cs

Lines changed: 5 additions & 8 deletions
Original file line numberDiff line numberDiff line change
@@ -3,8 +3,8 @@
33
using System.Collections.ObjectModel;
44
using System.Linq;
55
using OpenQA.Selenium.Environment;
6+
using OpenQA.Selenium.Internal;
67
using NUnit.Framework;
7-
using Microsoft.IdentityModel.Tokens;
88

99
using static OpenQA.Selenium.VirtualAuth.VirtualAuthenticatorOptions;
1010

@@ -207,9 +207,8 @@ public void ShouldAddNonResidentCredentialWhenAuthenticatorUsesU2FProtocol()
207207
{
208208
CreateRKDisabledU2FAuthenticator();
209209

210-
/**
211-
* A pkcs#8 encoded unencrypted EC256 private key as a base64url string.
212-
*/
210+
211+
// A pkcs#8 encoded unencrypted EC256 private key as a base64url string.
213212
string base64EncodedEC256PK =
214213
"MIGHAgEAMBMGByqGSM49AgEGCCqGSM49AwEHBG0wawIBAQQg8_zMDQDYAxlU-Q"
215214
+ "hk1Dwkf0v18GZca1DMF3SaJ9HPdmShRANCAASNYX5lyVCOZLzFZzrIKmeZ2jwU"
@@ -272,9 +271,7 @@ public void AddResidentCredentialNotSupportedWhenAuthenticatorUsesU2FProtocol()
272271
// Add a resident credential using the testing API.
273272
CreateRKEnabledU2FAuthenticator();
274273

275-
/**
276-
* A pkcs#8 encoded unencrypted EC256 private key as a base64url string.
277-
*/
274+
// A pkcs#8 encoded unencrypted EC256 private key as a base64url string.
278275
string base64EncodedEC256PK =
279276
"MIGHAgEAMBMGByqGSM49AgEGCCqGSM49AwEHBG0wawIBAQQg8_zMDQDYAxlU-Q"
280277
+ "hk1Dwkf0v18GZca1DMF3SaJ9HPdmShRANCAASNYX5lyVCOZLzFZzrIKmeZ2jwU"
@@ -475,4 +472,4 @@ public void testSetUserVerified()
475472
Assert.True(error.StartsWith("NotAllowedError"));
476473
}
477474
}
478-
}
475+
}

dotnet/test/common/WebDriver.Common.Tests.csproj

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -30,7 +30,6 @@
3030
<PrivateAssets>all</PrivateAssets>
3131
<IncludeAssets>runtime; build; native; contentfiles; analyzers; buildtransitive</IncludeAssets>
3232
</PackageReference>
33-
<PackageReference Include="Microsoft.IdentityModel.Tokens" Version="6.19.0" />
3433
</ItemGroup>
3534

3635
<ItemGroup>

dotnet/workspace.bzl

Lines changed: 0 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -11,24 +11,6 @@ def selenium_register_dotnet():
1111

1212
native.register_toolchains("//third_party/dotnet/ilmerge:all")
1313

14-
import_nuget_package(
15-
name = "identitymodel.tokens",
16-
file = "third_party/dotnet/nuget/packages/microsoft.identitymodel.tokens.6.19.0.nupkg",
17-
sha256 = "9ef0cd1a0f36716e20a39a7d612292c1ea0b1a6f196395db0c7552518ac0f0bd",
18-
)
19-
20-
import_nuget_package(
21-
name = "identitymodel.logging",
22-
file = "third_party/dotnet/nuget/packages/microsoft.identitymodel.logging.6.19.0.nupkg",
23-
sha256 = "0f0c738bf4ce27c5b4f6a441ce067a888b3e3b2a6783517b5d8caa46eec4516a",
24-
)
25-
26-
import_nuget_package(
27-
name = "identitymodel.abstractions",
28-
file = "third_party/dotnet/nuget/packages/microsoft.identitymodel.abstractions.6.19.0.nupkg",
29-
sha256 = "eaa7f4995eb68edf7b6d1586a3a35027f6f9252ab82cb1478cec347a42895ee0",
30-
)
31-
3214
import_nuget_package(
3315
name = "json.net",
3416
file = "third_party/dotnet/nuget/packages/newtonsoft.json.13.0.1.nupkg",

0 commit comments

Comments
 (0)