Skip to content

Conversation

Borghii
Copy link
Contributor

@Borghii Borghii commented Feb 17, 2025

Issue gh-16385

@spring-projects-issues spring-projects-issues added the status: waiting-for-triage An issue we've not yet triaged label Feb 17, 2025
@ziqin
Copy link

ziqin commented Feb 18, 2025

👍 I have tried this PR. It works with my own JDBC-based PublicKeyCredentialUserEntityRepository and UserCredentialRepository implementation. No anonymousUser entry is created.

@Kehrlann
Copy link
Contributor

Kehrlann commented Mar 24, 2025

@Borghii Thanks for the pull request!

Please also consider adding a test for when authentication == null. This is the case is users explicitly disable anonymous auth, with http.anonymous(AnonymousConfigurer::disable).

Also consider using AuthenticationTrustResolverImpl#isAnonymous for checking anonymity.

Copy link

@ziqin ziqin left a comment

Choose a reason for hiding this comment

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

We don't need to create a trustResolver instance every time findCredentialRecords is called.

Borghii added 2 commits March 24, 2025 13:18
Signed-off-by: Tomas Borghi <[email protected]>
@rwinch rwinch self-assigned this Mar 25, 2025
@rwinch rwinch added in: web An issue in web modules (web, webmvc) and removed status: waiting-for-triage An issue we've not yet triaged labels Mar 25, 2025
@rwinch rwinch added this to the 6.4.5 milestone Mar 25, 2025
@rwinch rwinch added the type: bug A general bug label Mar 25, 2025
@rwinch rwinch changed the title Fix bug PublicKeyCredentialUserEntityRepository saves anonymousUser Fix WebAuthn saves Anonymous PublicKeyCredentialUserEntity Mar 25, 2025
@rwinch rwinch merged commit 0a08413 into spring-projects:6.4.x Mar 25, 2025
3 checks passed
@Borghii Borghii deleted the gh-16385 branch March 26, 2025 10:53
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

in: web An issue in web modules (web, webmvc) type: bug A general bug

Projects

None yet

Development

Successfully merging this pull request may close these issues.

5 participants