mirror of
https://github.com/bitwarden/browser
synced 2025-12-29 06:33:40 +00:00
* [PM-4881]: Added userName to fido2credential * added user.name as input params * Fixed some type errors
38 lines
974 B
TypeScript
38 lines
974 B
TypeScript
import { Fido2CredentialApi } from "../../api/fido2-credential.api";
|
|
|
|
export class Fido2CredentialData {
|
|
credentialId: string;
|
|
keyType: "public-key";
|
|
keyAlgorithm: "ECDSA";
|
|
keyCurve: "P-256";
|
|
keyValue: string;
|
|
rpId: string;
|
|
userHandle: string;
|
|
userName: string;
|
|
counter: string;
|
|
rpName: string;
|
|
userDisplayName: string;
|
|
discoverable: string;
|
|
creationDate: string;
|
|
|
|
constructor(data?: Fido2CredentialApi) {
|
|
if (data == null) {
|
|
return;
|
|
}
|
|
|
|
this.credentialId = data.credentialId;
|
|
this.keyType = data.keyType;
|
|
this.keyAlgorithm = data.keyAlgorithm;
|
|
this.keyCurve = data.keyCurve;
|
|
this.keyValue = data.keyValue;
|
|
this.rpId = data.rpId;
|
|
this.userHandle = data.userHandle;
|
|
this.userName = data.userName;
|
|
this.counter = data.counter;
|
|
this.rpName = data.rpName;
|
|
this.userDisplayName = data.userDisplayName;
|
|
this.discoverable = data.discoverable;
|
|
this.creationDate = data.creationDate;
|
|
}
|
|
}
|