dwn-sdk-js icon indicating copy to clipboard operation
dwn-sdk-js copied to clipboard

Replace verificationMethod checks with JSON Schema based validation (publicJwk)

Open bnonni opened this issue 3 years ago • 1 comments

Replace with JSON Schema based validation for publicJwk. More info about the publicJwk property can be found here: https://www.w3.org/TR/did-spec-registries/#publicJwk

https://github.com/TBD54566975/dwn-sdk-js/blob/fcea84929e12dd3e3ef0e8866b0e592a025786fa/src/jose/jws/general/verifier.ts#L74-L84

bnonni avatar Jul 22 '22 11:07 bnonni

@thehenrytsai interested in your thoughts on depth of validation in my first pass at this. Initially started with basic checks for required fields, but then decided might be valuable to validate there is no private properties and that the curve is valid for a keytype.

Thanks!

flothjl avatar Oct 28 '22 06:10 flothjl

@flothjl, thanks for tackling this, I've merged in your PR! 🎆 🍾 🎊

thehenrytsai avatar Nov 03 '22 02:11 thehenrytsai