Open thobson88 opened 1 year ago
The original Verifier
API looks like this:
async fn verify(
&self,
did: &str,
root_timestamp: Timestamp,
) -> Result<DIDChain, VerifierError>;
This API will change, because the recognised root DIDs will be known in advance, as they are uniquely determined by the configuration parameters entered by the user. Therefore the root timestamps are also known in advance and should not be passed as an argument to the verify
method.
But we want to design the new API in such a way as to support:
verify
method - which performs the verification locally but without transparency for the user)
Currently dDID verification is done in the
verify()
method, which takes a DID (string) and a timestamp. To succeed, the timestamp must match that found in the header of the Bitcoin block containing the transaction that embedded the root ION DID.Now we want to replace the passing of an arbitrary timestamp with a configured root event date, plus a short confirmation code, which together uniquely determine the root DID (and hence its Unix timestamp).
A similar change has already been implemented on
trustchain-mobile
: https://github.com/alan-turing-institute/trustchain-mobile/issues/26.