Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Add did:ethr and EIP-712-based linked data proof type #99

Merged
merged 4 commits into from
Feb 24, 2021
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -45,12 +45,14 @@ blake2b_simd = "0.5"
bs58 = { version = "0.4", features = ["check"] }
libsecp256k1 = { version = "0.3", optional = true }
thiserror = "1.0"
keccak-hash = { version = "0.7", optional = true }

[workspace]
members = [
"did-tezos",
"did-key",
"did-web",
"did-ethr",
"vc-test",
]

Expand Down
52 changes: 52 additions & 0 deletions contexts/eip712vm.jsonld
Original file line number Diff line number Diff line change
@@ -0,0 +1,52 @@
{
"Eip712Method2021": "https://w3id.org/security#Eip712Method2021",
"Eip712Signature2021": {
"@id": "https://w3id.org/security#Eip712Signature2021",
"@context": {
"@version": 1.1,
"@protected": true,
"id": "@id",
"type": "@type",
"challenge": "https://w3id.org/security#challenge",
"created": {
"@id": "http://purl.org/dc/terms/created",
"@type": "http://www.w3.org/2001/XMLSchema#dateTime"
},
"domain": "https://w3id.org/security#domain",
"expires": {
"@id": "https://w3id.org/security#expiration",
"@type": "http://www.w3.org/2001/XMLSchema#dateTime"
},
"nonce": "https://w3id.org/security#nonce",
"proofPurpose": {
"@id": "https://w3id.org/security#proofPurpose",
"@type": "@vocab",
"@context": {
"@version": 1.1,
"@protected": true,
"id": "@id",
"type": "@type",
"assertionMethod": {
"@id": "https://w3id.org/security#assertionMethod",
"@type": "@id",
"@container": "@set"
},
"authentication": {
"@id": "https://w3id.org/security#authenticationMethod",
"@type": "@id",
"@container": "@set"
}
}
},
"proofValue": "https://w3id.org/security#proofValue",
"verificationMethod": {
"@id": "https://w3id.org/security#verificationMethod",
"@type": "@id"
},
"publicKeyJwk": {
"@id": "https://w3id.org/security#publicKeyJwk",
"@type": "@json"
}
}
}
}
15 changes: 15 additions & 0 deletions did-ethr/Cargo.toml
Original file line number Diff line number Diff line change
@@ -0,0 +1,15 @@
[package]
name = "did-ethr"
version = "0.0.1"
authors = ["Spruce Systems, Inc."]
edition = "2018"

[dependencies]
ssi = { path = "../", default-features = false, features = ["secp256k1", "keccak-hash"] }
chrono = { version = "0.4", features = ["serde"] }
tokio = { version = "1.0", features = ["macros", "rt"] }
serde = { version = "1.0", features = ["derive"] }
serde_json = "1.0"
async-trait = "0.1"
libsecp256k1 = { version = "0.3" }
keccak-hash = "0.7"
Loading