rwinch / spring-security-webauthn

41 stars 13 forks source link

Clicking Sign in with a passkey fails #28

Closed rwinch closed 1 month ago

rwinch commented 3 months ago

Using the conditional ui it is possible to sign in. However, clicking Sign in with a passkey fails

Kehrlann commented 3 months ago

Tried on macOS, M1, Sonoma 14.5 with:

Kehrlann commented 3 months ago

This seems to be due to a missing Permission-Policy, see MDN ... Unsure why, though.

It seems adding either Permissions-Policy: identity-credentials-get=* (ref) or Permissions-Policy: publickey-credentials-get=* (ref) fixes the issue.

Hacked with:

.headers(h -> h.addHeaderWriter((request, response) -> {
    response.setHeader("Permissions-Policy", "identity-credentials-get=*");
}))
rwinch commented 1 month ago

This has been fixed