-
Notifications
You must be signed in to change notification settings - Fork 415
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Use new Base64Url API #2817
Use new Base64Url API #2817
Conversation
@msbw2 Can you post a before / after of this benchmark as well here: JsonWebTokenHandler_ValidateTokenAsyncWithTVP ? Would be good to see the difference at that level. |
4abfe06
to
9b9b583
Compare
src/Microsoft.IdentityModel.Tokens/Microsoft.IdentityModel.Tokens.csproj
Outdated
Show resolved
Hide resolved
Benchmarks are here: #2828 (comment) |
9b9b583
to
615df8a
Compare
9e2ff23
to
b1d4eed
Compare
benchmark/Microsoft.IdentityModel.Benchmarks/identitymodel.benchmarks.yml
Outdated
Show resolved
Hide resolved
168bfe8
to
08c0f25
Compare
73666d5
to
55946bb
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
test/Microsoft.IdentityModel.Tokens.Tests/Base64UrlEncodingTests.cs
Outdated
Show resolved
Hide resolved
55946bb
to
4ddc291
Compare
6ad7e88
to
6a7db22
Compare
src/Microsoft.IdentityModel.Tokens/Microsoft.IdentityModel.Tokens.csproj
Outdated
Show resolved
Hide resolved
Should the test coverage be 100%? Curious what's not covered. |
6a7db22
to
00f7d29
Compare
00f7d29
to
ad14384
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Copilot reviewed 5 out of 10 changed files in this pull request and generated 1 comment.
Files not reviewed (5)
- build/dependencies.props: Language not supported
- src/Microsoft.IdentityModel.Tokens/InternalAPI.Unshipped.txt: Language not supported
- src/Microsoft.IdentityModel.Tokens/Microsoft.IdentityModel.Tokens.csproj: Language not supported
- src/Microsoft.IdentityModel.Tokens/LogMessages.cs: Evaluated as low risk
- src/Microsoft.IdentityModel.Tokens/Base64UrlEncoding.cs: Evaluated as low risk
Comments suppressed due to low confidence (3)
test/Microsoft.IdentityModel.Tokens.Tests/Base64UrlEncodingTests.cs:37
- [nitpick] The variable name 'randomPadding' is misleading as it is a constant string. Consider renaming it to 'paddingString'.
const string randomPadding = "RANDOMPADDING";
benchmark/Microsoft.IdentityModel.Benchmarks/Base64UrlEncoderTests.cs:20
- [nitpick] The variable name
base64NoSpecialCharsEncodedString
is quite long and could be confusing. Consider renaming it to something shorter and more descriptive.
private static readonly string base64NoSpecialCharsEncodedString = base64UrlEncodedString.Replace('-', 'A').Replace('_', 'B') + "ab";
benchmark/Microsoft.IdentityModel.Benchmarks/Base64UrlEncoderTests.cs:22
- [nitpick] The variable name
base64NoSpecialCharsExceptPaddingEncodedString
is quite long and could be confusing. Consider renaming it to something shorter and more descriptive.
private static readonly string base64NoSpecialCharsExceptPaddingEncodedString = base64UrlEncodedString.Replace('-', 'A').Replace('_', 'B') + "==";
SummarySummary
CoverageMicrosoft.IdentityModel.JsonWebTokens - 80.3%
|
Use the new
Base64Url
API.