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

Windows server2019 problem #319

Closed
iLonaKarpova opened this issue Dec 26, 2022 · 4 comments
Closed

Windows server2019 problem #319

iLonaKarpova opened this issue Dec 26, 2022 · 4 comments

Comments

@iLonaKarpova
Copy link

I've wrote some simple project using SimpleWebAuthn that does registration and auth. It works great on localhost (running Windows 11), but fails when deployed at server env (running Windows Server 2019) with an error:
react_devtools_backend.js:4012 Error: Invalid key for curve: "Public key is not a point"
at t.exports (async-vendor.js:91:329050)
at t.exports (async-vendor.js:91:327623)
at e.convertPublicKeyToPEM (async-vendor.js:91:326888)
at e.verifySignature (async-vendor.js:73:28917)
at e.verifyAuthenticationResponse (async-v
Could you please share any ideas what could be the reason?

@MasterKale
Copy link
Owner

Can you share more about how you're calling @simplewebauthn/server's methods? Code samples, ideally.

async-vendor.js

Are you bundling @simplewebauthn/server into a front end project? It's not often you see vendoring like this in Node projects. If you are then that's part of the problem, Node is the only supported runtime for @simplewebauthn/server right now.

@iLonaKarpova
Copy link
Author

iLonaKarpova commented Dec 28, 2022 via email

@MasterKale
Copy link
Owner

If you're the adventurous type, the master branch currently has #299 in it which did a huge refactor to try and make it possible for server to run on more platforms. This includes using WebCrypto and Uint8Array everywhere, which means it's feasible to include server in a front end project as there's no longer going to be anything tightly coupling server to Node.

The catch is that you'd have to figure out how to get your project to work with CommonJS modules. I wouldn't spend a whole lot of time on that if you did decide to experiment with what will be released as SimpleWebAuthn v7.0.0 early next year, though, as in my experiments getting server running in a vite project I had to abandon CommonJS completely to get server running in the browser.

After v7.0.0 debuts I plan on taking another look at how I might make it possible for server to run in more browser-like environments, including browsers for those interested in building fully-contained demo sites. If you're interested I can tag you in a follow-up issue or discussion in the future when I have something for you to properly test with.

@iLonaKarpova
Copy link
Author

iLonaKarpova commented Dec 31, 2022 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants