Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Bugfix: pem.extensions.isCA -> pem.isCA, remove 'new' before 'Buffer.from' #37

Open
wants to merge 1 commit into
base: master
Choose a base branch
from
Open
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions src/Webauthn.js
Original file line number Diff line number Diff line change
Expand Up @@ -404,7 +404,7 @@ class Webauthn {
// A UTF8String of the vendor’s choosing
pem.subject.commonName &&
// The Basic Constraints extension MUST have the CA component set to false
!pem.extensions.isCA &&
!pem.isCA &&
// If attestnCert contains an extension with OID 1.3.6.1.4.1.45724.1.1.4 (id-fido-gen-ce-aaguid)
// verify that the value of this extension matches the aaguid in authenticatorData.
// The extension MUST NOT be marked as critical.
Expand Down Expand Up @@ -577,7 +577,7 @@ class Webauthn {
let type
if (pkBuffer.length == 65 && pkBuffer[0] == 0x04) {
pkBuffer = Buffer.concat([
new Buffer.from("3059301306072a8648ce3d020106082a8648ce3d030107034200", "hex"),
Buffer.from("3059301306072a8648ce3d020106082a8648ce3d030107034200", "hex"),
pkBuffer
])

Expand Down