УЮ
Size: a a a
УЮ
SY
SY
ДК
ДК
algorithm = {
name: 'RSA-PSS',
modulusLength: 512,
publicExponent: new Uint8Array([ 1, 0, 1 ]),
hash: 'SHA-256',
saltLength: 8,
}
crypto.subtle.generateKey(
algorithm,
true,
[ 'sign', 'verify' ],
)
.then( ({ privateKey })=> crypto.subtle.sign(
algorithm,
privateKey,
new Uint8Array([]),
) )
.then( console.log, console.error )ДК
ДК
algorithm = {
name: "ECDSA",
hash: {name: "SHA-256"},
namedCurve: 'P-256',
}
crypto.subtle.generateKey(
algorithm,
true,
[ 'sign', 'verify' ],
)
.then( ({ privateKey })=> crypto.subtle.sign(
algorithm,
privateKey,
new Uint8Array([ 1, 0, 1 ]),
) )
.then( console.log, console.error )ДК
УЮ
ДК
ВМ

SY
ДК