Open fqutishat opened 5 years ago
Validate input DID conforms to the did rule of the Generic DID Syntax.
////////////////////////////////////////////////// did = "did:" method-name ":" method-specific-id method-name = 1method-char method-char = %x61-7A / DIGIT method-specific-id = idchar ( ":" idchar ) idchar = ALPHA / DIGIT / "." / "-" / "" did-url = did ( ";" param ) path-abempty [ "?" query ] [ "#" fragment ] param = param-name [ "=" param-value ] param-name = 1param-char param-value = *param-char param-char = ALPHA / DIGIT / "." / "-" / "" / ":" / pct-encoded
////////////////////////////////////////////////////
There is implementation in java
https://github.com/decentralized-identity/did-common-java/tree/master/src/main/java/did/parser
This was done in #18
Validate input DID conforms to the did rule of the Generic DID Syntax.
////////////////////////////////////////////////// did = "did:" method-name ":" method-specific-id method-name = 1method-char method-char = %x61-7A / DIGIT method-specific-id = idchar ( ":" idchar ) idchar = ALPHA / DIGIT / "." / "-" / "" did-url = did ( ";" param ) path-abempty [ "?" query ] [ "#" fragment ] param = param-name [ "=" param-value ] param-name = 1param-char param-value = *param-char param-char = ALPHA / DIGIT / "." / "-" / "" / ":" / pct-encoded
////////////////////////////////////////////////////
There is implementation in java
https://github.com/decentralized-identity/did-common-java/tree/master/src/main/java/did/parser