Merge branch 'v2-dev' of https://github.com/certd/certd into v2-dev

This commit is contained in:
xiaojunnuo
2026-03-17 23:33:18 +08:00
8 changed files with 90 additions and 39 deletions
@@ -278,20 +278,22 @@ async function doRegisterPasskey(deviceName: string) {
// type: "public-key",
// }));
const credential = await (navigator.credentials as any).create({
publicKey: {
challenge: Uint8Array.from(atob(options.challenge.replace(/-/g, "+").replace(/_/g, "/")), c => c.charCodeAt(0)),
rp: options.rp,
pubKeyCredParams: options.pubKeyCredParams,
timeout: options.timeout || 60000,
attestation: options.attestation,
// excludeCredentials: excludeCredentials,
user: {
id: new TextEncoder().encode(options.userId + ""),
name: userInfo.value.username,
displayName: deviceName,
},
const publicKey = {
challenge: Uint8Array.from(atob(options.challenge.replace(/-/g, "+").replace(/_/g, "/")), c => c.charCodeAt(0)),
rp: options.rp,
pubKeyCredParams: options.pubKeyCredParams,
timeout: options.timeout || 60000,
attestation: options.attestation,
// excludeCredentials: excludeCredentials,
user: {
id: new TextEncoder().encode(options.userId + ""),
name: userInfo.value.username,
displayName: deviceName,
},
};
console.log("passkey register publicKey:", publicKey);
const credential = await (navigator.credentials as any).create({
publicKey,
});
if (!credential) {
@@ -100,7 +100,10 @@ function formatDate(dateStr: string): string {
.cert-detail {
table {
width: 100%;
table-layout: fixed;
table-layout: fixed !important;
}
.ant-descriptions-item-label {
width: 90px;
}
.fingerprint {
.label {