alan-turing-institute / trustchain

Trustworthy decentralised PKI
https://alan-turing-institute.github.io/trustchain/
Apache License 2.0
11 stars 5 forks source link

Implement Credentials for Data MVP #181

Closed thobson88 closed 2 months ago

thobson88 commented 5 months ago

Notes on hackmd: https://hackmd.io/h7FX48jpSOCuKoPmMs61bQ?view

Main steps:

thobson88 commented 5 months ago

Signing & verifying a credential (already implemented):

trustchain-cli vc sign -f <CREDENTIAL_FILE> --did <DID>
trustchain-cli vc verify -f <CREDENTIAL_FILE>

Signing a dataset (proposed):

trustchain-cli data sign -f <DATASET_FILE> --did <DID>
trustchain-cli data verify -f <DATASET_FILE> -c <CREDENTIAL_FILE>

(other options same as for vc case)

thobson88 commented 4 months ago

I've removed the xattr stuff because it's platform-dependent and is a file system feature, so the attributes are not (in general) retained when the file is transferred.

thobson88 commented 4 months ago

To try out the updated CLI, checkout the branch:

git checkout 181-credentials4data

Then either install the CLI:

cargo install --path trustchain-cli

and then run the trustchain-cli command as usual.

Or, descend to the trustchain-cli directory:

cd trustchain-cli

and run the binary:

cargo run --bin trustchain-cli