2023-12-15 20:25:35 +01:00
|
|
|
enum KeyType { "public", "private", "secret" };
|
|
|
|
|
|
2025-11-27 02:44:01 +01:00
|
|
|
// https://wicg.github.io/webcrypto-modern-algos/#subtlecrypto-interface-keyusage
|
|
|
|
|
enum KeyUsage { "encrypt", "decrypt", "sign", "verify", "deriveKey", "deriveBits", "wrapKey", "unwrapKey", "encapsulateKey", "encapsulateBits", "decapsulateKey", "decapsulateBits" };
|
2023-12-15 20:25:35 +01:00
|
|
|
|
|
|
|
|
// https://w3c.github.io/webcrypto/#cryptokey-interface
|
|
|
|
|
[SecureContext,Exposed=(Window,Worker),Serializable]
|
|
|
|
|
interface CryptoKey {
|
2024-09-10 16:21:16 +09:00
|
|
|
readonly attribute KeyType type;
|
|
|
|
|
readonly attribute boolean extractable;
|
|
|
|
|
readonly attribute object algorithm;
|
|
|
|
|
readonly attribute object usages;
|
2023-12-15 20:25:35 +01:00
|
|
|
};
|