-
Notifications
You must be signed in to change notification settings - Fork 6k
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
Make PublicKeyCredentialRequestOptions Serializable #16438
base: main
Are you sure you want to change the base?
Conversation
87e31a2
to
6f3e2ac
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.
Thanks for the Pull Request. Historically the serialVersionUID no longer used for new classes implementing Serializable. Going forward we should generate a serialVersionUID.
Hi @rwinch, thanks for feedback. If we use the generated |
Please take a look at 6f379aa which was progress towards gh-16276 for an example for how to implement it. It uses generated NOTE: This PR has some overlap with gh-16285 (which I provided the same advice for) |
24a3e46
to
d646106
Compare
Closes spring-projectsgh-16432 Signed-off-by: Max Batischev <[email protected]>
d646106
to
c845b68
Compare
Thanks for help @rwinch. Could you review changes please? |
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.
Thanks for the PR! I've provided feedback inline
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.
It looks like this failed to write
CredProtectAuthenticationExtensionsClientInput.CredProtect credProtect = new CredProtectAuthenticationExtensionsClientInput.CredProtect( | ||
CredProtectAuthenticationExtensionsClientInput.CredProtect.ProtectionPolicy.USER_VERIFICATION_OPTIONAL, | ||
true); | ||
Bytes id = new Bytes(("test").getBytes()); |
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.
I like that you used a constant value here vs generating a new value. Please use a more realistic value. To make this easy I recently added TestBytes.get() gh-16461
generatorByClassName.put(Bytes.class, (b) -> id); | ||
generatorByClassName.put(PublicKeyCredentialDescriptor.class, (d) -> descriptor); | ||
// @formatter:off | ||
generatorByClassName.put(PublicKeyCredentialRequestOptions.class, (o) -> PublicKeyCredentialRequestOptions.builder() |
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.
Please use (or at least start with) TestPublicKeyCredentialRequestOptions
Closes gh-16432