LibWeb: Implement ED25519 verify for SubtleCrypto

This commit is contained in:
stelar7 2024-03-31 23:05:05 +02:00 committed by Andrew Kaster
commit 35676491ec
Notes: sideshowbarker 2024-07-17 05:06:13 +09:00
5 changed files with 44 additions and 18 deletions

View file

@ -267,6 +267,8 @@ private:
class ED25519 : public AlgorithmMethods {
public:
virtual WebIDL::ExceptionOr<JS::NonnullGCPtr<JS::ArrayBuffer>> sign(AlgorithmParams const&, JS::NonnullGCPtr<CryptoKey>, ByteBuffer const&) override;
virtual WebIDL::ExceptionOr<JS::Value> verify(AlgorithmParams const&, JS::NonnullGCPtr<CryptoKey>, ByteBuffer const&, ByteBuffer const&) override;
virtual WebIDL::ExceptionOr<Variant<JS::NonnullGCPtr<CryptoKey>, JS::NonnullGCPtr<CryptoKeyPair>>> generate_key(AlgorithmParams const&, bool, Vector<Bindings::KeyUsage> const&) override;
static NonnullOwnPtr<AlgorithmMethods> create(JS::Realm& realm) { return adopt_own(*new ED25519(realm)); }