Giter Club home page Giter Club logo

Comments (2)

MasterKale avatar MasterKale commented on May 25, 2024

Hello @netmiller, this is a fun question for someone like me!

In absolute terms there shouldn't be anything about those existing credID's or publicKey (very specifically using wallix names here) that would prevent you from using them for WebAuthn response verification with other libraries like SimpleWebAuthn.

Talking specifically about SimpleWebAuthn, it looks like you're using base64 to store credential ID and public key bytes; so long as you convert them to Uint8Arrays when passing them into verifyAuthenticationResponse() as the value of options.authenticator.credentialID and options.authenticator.credentialPublicKey respectively then there shouldn't be a problem to use those existing credentials with SimpleWebAuthn.

FYI you can import isoBase64URL from @simplewebauthn/server/helpers and use its support for base64 if needed:

import { isoBase64URL } from '@simplewebauthn/server/helpers';

const verification = await verifyAuthenticationResponse({
  // ...
  authenticator: {
    credentialID: isoBase64URL.toBuffer(wallix.credID, 'base64'),
    credentialPublicKey: isoBase64URL.toBuffer(wallix.publicKey, 'base64'),
    counter: wallix.counter
  },
});

There's nothing isoBase64URL does that other base64 libraries don't already do. Put another way, use of isoBase64URL is not a requirement for working with SimpleWebAuthn, it's only offered as a resource for projects that might not already have pulled in such a base64url/base64 helper library.

from simplewebauthn.

MasterKale avatar MasterKale commented on May 25, 2024

I'm going to convert this into a discussion now as this isn't reporting an issue with SimpleWebAuthn.

from simplewebauthn.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.