admin管理员组文章数量:1122846
I'm using Fido2.AspNet version 4.0.0-beta.16 to implement passwordless logins. When trying to register a user, I'm getting an exception saying:
Authenticator response challenge does not match original challenge
I'm calling fido2.RequestNewCredential
, storing the result in a redis cache, then sending that back to the Angular application. The Angular app calls fido2Create
from @ownid/webauthn
. I then send the data
property of that back to the server.
When I run this code on the server to complete registration, the exception is thrown
var options = await cache.GetStringAsync(...);
var makeNewCredentialParams = new MakeNewCredentialParams {
AttestationResponse = request.AttestationResponse,
IsCredentialIdUniqueToUserCallback = ...,
OriginalOptions = CredentialCreateOptions.FromJson(options)
};
var credential = await fido2.MakeNewCredentialAsync(makeNewCredentialParams, cancellationToken);
This is all the Angular service is doing:
async register(email: string) {
const response = await lastValueFrom(this.#http.post('account/registerStart', email))
const fido = await fido2Create(response, email)
return await lastValueFrom(this.#http.post('account/registerEnd', { email, attestationResponse: fido.data })) as string
}
本文标签: cFido2 challenge not matching original challengeStack Overflow
版权声明:本文标题:c# - Fido2 challenge not matching original challenge - Stack Overflow 内容由网友自发贡献,该文观点仅代表作者本人, 转载请联系作者并注明出处:http://www.betaflare.com/web/1736283929a1927132.html, 本站仅提供信息存储空间服务,不拥有所有权,不承担相关法律责任。如发现本站有涉嫌抄袭侵权/违法违规的内容,一经查实,本站将立刻删除。
发表评论