Yubico / java-webauthn-server

Server-side Web Authentication library for Java https://www.w3.org/TR/webauthn/#rp-operations
Other
439 stars 137 forks source link

Please make the Extensions.CredentialProperties.CredentialPropertiesOutput constructor public #330

Open rwinch opened 8 months ago

rwinch commented 8 months ago

Summary

I'd like to construct an instance of Extensions.CredentialProperties.CredentialPropertiesOutput but the constructor is not public. Can you please make the constructor public?

Details

The Extensions.CredentialProperties.CredentialPropertiesOutput is not public which means that users can only create an instance of this object through reflection (e.g. using Jackson's ObjectMapper). This means that the only way users can use CredentialPropertiesOutput is through reflection or by deserializing JSON. This limits how the data can be sent from the client to the server.

A specific problem I'm running into is that I would like to have an interface that prevents downstream libraries from depending directly on java-webauthn-server. By doing this we can provide additional implementations of the same interface with different libraries without breaking downstream users.

However, for this to work I need to be able to create a Extensions.CredentialProperties.CredentialPropertiesOutput directly from our Object rather than from JSON.

Please make the Extensions.CredentialProperties.CredentialPropertiesOutput constructor public to allow more flexible usage of this extension.

emlun commented 8 months ago

Hi! Seems fair - especially since ClientAssertionExtensionOutputs etc. have corresponding public builders, which seems a bit moot if you can't actually construct the constituent values. This will be included in the next release.

emlun commented 8 months ago

This is now released in experimental release 2.6.0-alpha4. Thanks!

alokkulkarni commented 7 months ago

Still facing issues in 2.6.0-alpha4 experiemental. i have just opened up another issue on this #333 ....