--- id: webauthn version: "3.0.0" license: BSD-3-Clause license_treatment: permissive maintenance: active --- # webauthn — Pythonic WebAuthn License: permissive · Maintenance: active · Downloads: 7.0M/mo ## What it is and what it does py_webauthn is a server-side implementation of the WebAuthn specification that handles the cryptographic validation of passwordless authentication credentials. It works with any FIDO2-compliant authenticator—security keys, Touch ID, Face ID, Windows Hello, Android biometrics—and exposes four core methods: generate_registration_options, verify_registration_response, generate_authentication_options, and verify_authentication_response. The library assumes JSON transport between server and browser, with base64url encoding for binary data to avoid extra dependencies. The package depends on pyasn1, pyasn1-modules, cbor2, cryptography, and pyOpenSSL to handle the underlying cryptographic operations and ASN.1 parsing required by the WebAuthn spec. It provides helper dataclasses for type-safe construction of inputs and outputs, and utility functions for JSON serialization and base64url conversion. Developers integrate it by generating challenge-based options on the server, sending them to the browser's WebAuthn API, then validating the returned credential against the server-stored challenge. Use it for: - Add passwordless login to a web application using hardware security keys or platform biometrics. - Implement multi-factor authentication where WebAuthn serves as a second factor alongside passwords. - Build a registration flow that enrolls users' authenticators and stores their public keys server-side. - Verify authentication responses from browser-based WebAuthn ceremonies without managing passwords. - Support cross-platform authentication across desktop, mobile, and web clients with a single server implementation. ## Worth the install? AI-flagged interpretation of the facts above — verify before relying. Implements server-side WebAuthn validation for passwordless authentication using FIDO2-compliant authenticators like security keys, biometrics, and platform authenticators. Yes. This is a production-stable, actively maintained library with no known vulnerabilities, low install friction, and a permissive license. Install it if you need to add WebAuthn support to a Python backend and are targeting Python 3.10+. The API is straightforward and the dependency footprint is small and well-established. ## Install pip install webauthn uv add webauthn poetry add webauthn ## Installing webauthn Before you install: Low install friction with a pure-Python wheel and five stable runtime dependencies. Active maintenance with a recent release and no known vulnerabilities. License in practice: BSD-3-Clause permissive license allows commercial and private use with minimal restrictions. Quickstart: pip install webauthn from webauthn import generate_registration_options, verify_registration_response options = generate_registration_options(rp_id="example.com", rp_name="Example") # Send options to client, receive response, then: verified = verify_registration_response(credential=response, expected_challenge=challenge) Requires Python 3.10 or later. Verify before relying: - Whether the library's type hints and dataclass helpers fully cover all WebAuthn spec edge cases in production deployments. - Performance characteristics when handling high-volume concurrent registration and authentication flows. ## Package facts - License: BSD-3-Clause (permissive) - Python support: supports_current - Install friction: low - Maintenance: active - Downloads: 7.0M/month (top 5,000 on PyPI) - Known vulnerabilities: none known ## Tags webauthn server implementation, fido2 authentication, passwordless login, security key verification, biometric authentication server, authentication, cryptography, fido2 [View on SkillFed](https://skillfed.io/packages/webauthn) · [View on PyPI](https://pypi.org/project/webauthn/)