chore(deps): update dependency webauthn to v2 #330
Closed
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
This PR contains the following updates:
==1.11.1
->==2.2.0
Release Notes
duo-labs/py_webauthn (webauthn)
v2.2.0
Compare Source
Changes:
webauthn.helpers.exceptions
now subclass the newwebauthn.helpers.exceptions.WebAuthnException
base exception (#219, h/t @bschoenmaeckers)"smart-card"
transport (#221)v2.1.0
Compare Source
from webauthn.helpers import parse_registration_options_json
json_reg_options: dict = get_stored_registration_options(session_id)
parsed_reg_options: PublicKeyCredentialCreationOptions = parse_registration_options_json(
json_reg_options,
)
After:
Option 2: Generate unique WebAuthn-specific identifiers for existing and new users
WebAuthn strongly encourages Relying Parties to use 64 randomized bytes for every user ID you pass into
navigator.credentials.create()
. This would be a second identifier used exclusively for WebAuthn that you associate along with your typical internal user ID.py_webauthn includes a
generate_user_handle()
helper that can simplify the task of creating this special user identifier for your existing users in one go:v2.0.0
Compare Source
Changes:
Breaking Changes:
calls any Pydantic-specific methods on classes provided by py_webauthn then you will need to
refactor those calls accordingly. Typical use of py_webauthn should not need any major refactor
related to this change, but please see Breaking Changes below (#195)
webauthn.helpers.generate_challenge()
now always generates 64 random bytes and no longer accepts any arguments. Refactor your existing calls to remove any arguments (#198)webauthn.helpers.exceptions.InvalidClientDataJSONStructure
has been replaced bywebauthn.helpers.exceptions.InvalidJSONStructure
(#195)webauthn.helpers.json_loads_base64url_to_bytes()
has been removed (#195)user_id
argument passed intogenerate_registration_options()
is nowOptional[bytes]
instead of a required
str
value. A random sequence of 64 bytes will be generated foruser_id
if it is
None
(#197)Option 1: Use the
base64url_to_bytes()
helperIf you already store your WebAuthn user ID bytes as base64url-encoded strings then you can simply decode these strings to bytes using an included helper:
Before:
After:
Option 2: Generate unique WebAuthn-specific identifiers for existing and new users
WebAuthn strongly encourages Relying Parties to use 64 randomized bytes for every user ID you pass into
navigator.credentials.create()
. This would be a second identifier used exclusively for WebAuthn that you associate along with your typical internal user ID.py_webauthn includes a
generate_user_handle()
helper that can simplify the task of creating this special user identifier for your existing users in one go:Configuration
📅 Schedule: Branch creation - At any time (no schedule defined), Automerge - At any time (no schedule defined).
🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.
♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.
🔕 Ignore: Close this PR and you won't be reminded about this update again.
This PR was generated by Mend Renovate. View the repository job log.