diff --git a/Readme.md b/Readme.md
index 04ed8a3..67576a2 100644
--- a/Readme.md
+++ b/Readme.md
@@ -2,19 +2,19 @@
go-did-it
-
-
+
+
-
-
+
+
-
+
-
+
-
+
@@ -36,7 +36,7 @@ Built with ❤️ by [Consensys](https://consensys.io/).
## Installation
```bash
-go get github.com/ucan-wg/go-did-it
+go get github.com/MetaMask/go-did-it
```
## Usage
@@ -52,10 +52,10 @@ import (
"encoding/base64"
"fmt"
- "github.com/ucan-wg/go-did-it"
+ "github.com/MetaMask/go-did-it"
// 0) Import the methods you want to support
- _ "github.com/ucan-wg/go-did-it/verifiers/did-key"
+ _ "github.com/MetaMask/go-did-it/verifiers/did-key"
)
func main() {
@@ -90,11 +90,11 @@ import (
"encoding/base64"
"fmt"
- "github.com/ucan-wg/go-did-it"
- "github.com/ucan-wg/go-did-it/crypto/x25519"
+ "github.com/MetaMask/go-did-it"
+ "github.com/MetaMask/go-did-it/crypto/x25519"
// 0) Import the methods you want to support
- _ "github.com/ucan-wg/go-did-it/verifiers/did-key"
+ _ "github.com/MetaMask/go-did-it/verifiers/did-key"
)
func main() {
@@ -141,14 +141,15 @@ func main() {
### Supported Cryptographic Algorithms
#### Signing Keys
-| Algorithm | Signature Format | Public Key Formats | Private Key Formats |
-|-----------------|-------------------|-------------------------------------|---------------------------|
-| Ed25519 | Raw bytes, ASN.1 | Raw bytes, X.509 DER/PEM, Multibase | Raw bytes, PKCS#8 DER/PEM |
-| ECDSA P-256 | Raw bytes, ASN.1 | Raw bytes, X.509 DER/PEM, Multibase | Raw bytes, PKCS#8 DER/PEM |
-| ECDSA P-384 | Raw bytes, ASN.1 | Raw bytes, X.509 DER/PEM, Multibase | Raw bytes, PKCS#8 DER/PEM |
-| ECDSA P-521 | Raw bytes, ASN.1 | Raw bytes, X.509 DER/PEM, Multibase | Raw bytes, PKCS#8 DER/PEM |
-| ECDSA secp256k1 | Raw bytes, ASN.1 | Raw bytes, X.509 DER/PEM, Multibase | Raw bytes, PKCS#8 DER/PEM |
-| RSA | PKCS#1 v1.5 ASN.1 | X.509 DER/PEM, Multibase | PKCS#8 DER/PEM |
+| Algorithm | Signature Format | Public Key Formats | Private Key Formats | Key Agreement |
+|-----------------|-------------------|-------------------------------------|---------------------------|----------------|
+| Ed25519 | Raw bytes, ASN.1 | Raw bytes, X.509 DER/PEM, Multibase | Raw bytes, PKCS#8 DER/PEM | ✅ (via X25519) |
+| ECDSA P-256 | Raw bytes, ASN.1 | Raw bytes, X.509 DER/PEM, Multibase | Raw bytes, PKCS#8 DER/PEM | ✅ |
+| ECDSA P-384 | Raw bytes, ASN.1 | Raw bytes, X.509 DER/PEM, Multibase | Raw bytes, PKCS#8 DER/PEM | ✅ |
+| ECDSA P-521 | Raw bytes, ASN.1 | Raw bytes, X.509 DER/PEM, Multibase | Raw bytes, PKCS#8 DER/PEM | ✅ |
+| ECDSA secp256k1 | Raw bytes, ASN.1 | Raw bytes, X.509 DER/PEM, Multibase | Raw bytes, PKCS#8 DER/PEM | ✅ |
+| RSA | PKCS#1 v1.5 ASN.1 | X.509 DER/PEM, Multibase | PKCS#8 DER/PEM | ❌ |
+| X25519 | ❌ | Raw bytes, X.509 DER/PEM, Multibase | Raw bytes, PKCS#8 DER/PEM | ✅ |
#### Key Agreement (Encryption)
diff --git a/controller/did-key/key.go b/controller/did-key/key.go
index d76faf3..6785ad9 100644
--- a/controller/did-key/key.go
+++ b/controller/did-key/key.go
@@ -1,9 +1,9 @@
package didkeyctl
import (
- "github.com/ucan-wg/go-did-it"
- "github.com/ucan-wg/go-did-it/crypto"
- didkey "github.com/ucan-wg/go-did-it/verifiers/did-key"
+ "github.com/MetaMask/go-did-it"
+ "github.com/MetaMask/go-did-it/crypto"
+ didkey "github.com/MetaMask/go-did-it/verifiers/did-key"
)
func FromPublicKey(pub crypto.PublicKey) did.DID {
diff --git a/crypto/_allkeys/allkeys.go b/crypto/_allkeys/allkeys.go
index 7bf3267..d7c45bc 100644
--- a/crypto/_allkeys/allkeys.go
+++ b/crypto/_allkeys/allkeys.go
@@ -3,15 +3,15 @@ package allkeys
import (
"fmt"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/ed25519"
- helpers "github.com/ucan-wg/go-did-it/crypto/internal"
- "github.com/ucan-wg/go-did-it/crypto/p256"
- "github.com/ucan-wg/go-did-it/crypto/p384"
- "github.com/ucan-wg/go-did-it/crypto/p521"
- "github.com/ucan-wg/go-did-it/crypto/rsa"
- "github.com/ucan-wg/go-did-it/crypto/secp256k1"
- "github.com/ucan-wg/go-did-it/crypto/x25519"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/ed25519"
+ helpers "github.com/MetaMask/go-did-it/crypto/internal"
+ "github.com/MetaMask/go-did-it/crypto/p256"
+ "github.com/MetaMask/go-did-it/crypto/p384"
+ "github.com/MetaMask/go-did-it/crypto/p521"
+ "github.com/MetaMask/go-did-it/crypto/rsa"
+ "github.com/MetaMask/go-did-it/crypto/secp256k1"
+ "github.com/MetaMask/go-did-it/crypto/x25519"
)
var decoders = map[uint64]func(b []byte) (crypto.PublicKey, error){
diff --git a/crypto/_testsuite/testsuite.go b/crypto/_testsuite/testsuite.go
index df78bab..9f6e350 100644
--- a/crypto/_testsuite/testsuite.go
+++ b/crypto/_testsuite/testsuite.go
@@ -10,7 +10,7 @@ import (
"github.com/multiformats/go-varint"
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto"
)
type TestHarness[PubT crypto.PublicKey, PrivT crypto.PrivateKey] struct {
diff --git a/crypto/ed25519/key_test.go b/crypto/ed25519/key_test.go
index 51c3d6b..40032f8 100644
--- a/crypto/ed25519/key_test.go
+++ b/crypto/ed25519/key_test.go
@@ -3,8 +3,8 @@ package ed25519
import (
"testing"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/_testsuite"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/_testsuite"
)
var harness = testsuite.TestHarness[PublicKey, PrivateKey]{
diff --git a/crypto/ed25519/private.go b/crypto/ed25519/private.go
index d0e23aa..efc1aba 100644
--- a/crypto/ed25519/private.go
+++ b/crypto/ed25519/private.go
@@ -8,7 +8,7 @@ import (
"golang.org/x/crypto/cryptobyte"
- "github.com/ucan-wg/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto"
)
var _ crypto.PrivateKeySigningBytes = &PrivateKey{}
diff --git a/crypto/ed25519/public.go b/crypto/ed25519/public.go
index 6a43ee1..949066d 100644
--- a/crypto/ed25519/public.go
+++ b/crypto/ed25519/public.go
@@ -9,8 +9,8 @@ import (
"golang.org/x/crypto/cryptobyte"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/internal"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/internal"
)
var _ crypto.PublicKeySigningBytes = PublicKey{}
diff --git a/crypto/jwk/private.go b/crypto/jwk/private.go
index cb76a66..4ced0d3 100644
--- a/crypto/jwk/private.go
+++ b/crypto/jwk/private.go
@@ -5,14 +5,14 @@ import (
"encoding/json"
"fmt"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/ed25519"
- "github.com/ucan-wg/go-did-it/crypto/p256"
- "github.com/ucan-wg/go-did-it/crypto/p384"
- "github.com/ucan-wg/go-did-it/crypto/p521"
- "github.com/ucan-wg/go-did-it/crypto/rsa"
- "github.com/ucan-wg/go-did-it/crypto/secp256k1"
- "github.com/ucan-wg/go-did-it/crypto/x25519"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/ed25519"
+ "github.com/MetaMask/go-did-it/crypto/p256"
+ "github.com/MetaMask/go-did-it/crypto/p384"
+ "github.com/MetaMask/go-did-it/crypto/p521"
+ "github.com/MetaMask/go-did-it/crypto/rsa"
+ "github.com/MetaMask/go-did-it/crypto/secp256k1"
+ "github.com/MetaMask/go-did-it/crypto/x25519"
)
type PrivateJwk struct {
diff --git a/crypto/jwk/public.go b/crypto/jwk/public.go
index 41a92c5..ac5dd41 100644
--- a/crypto/jwk/public.go
+++ b/crypto/jwk/public.go
@@ -5,14 +5,14 @@ import (
"encoding/json"
"fmt"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/ed25519"
- "github.com/ucan-wg/go-did-it/crypto/p256"
- "github.com/ucan-wg/go-did-it/crypto/p384"
- "github.com/ucan-wg/go-did-it/crypto/p521"
- "github.com/ucan-wg/go-did-it/crypto/rsa"
- "github.com/ucan-wg/go-did-it/crypto/secp256k1"
- "github.com/ucan-wg/go-did-it/crypto/x25519"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/ed25519"
+ "github.com/MetaMask/go-did-it/crypto/p256"
+ "github.com/MetaMask/go-did-it/crypto/p384"
+ "github.com/MetaMask/go-did-it/crypto/p521"
+ "github.com/MetaMask/go-did-it/crypto/rsa"
+ "github.com/MetaMask/go-did-it/crypto/secp256k1"
+ "github.com/MetaMask/go-did-it/crypto/x25519"
)
// Specification:
diff --git a/crypto/p256/key_test.go b/crypto/p256/key_test.go
index 6ee10de..b252e93 100644
--- a/crypto/p256/key_test.go
+++ b/crypto/p256/key_test.go
@@ -6,8 +6,8 @@ import (
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/_testsuite"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/_testsuite"
)
var harness = testsuite.TestHarness[*PublicKey, *PrivateKey]{
diff --git a/crypto/p256/private.go b/crypto/p256/private.go
index dc36d07..245b69b 100644
--- a/crypto/p256/private.go
+++ b/crypto/p256/private.go
@@ -9,7 +9,7 @@ import (
"fmt"
"math/big"
- "github.com/ucan-wg/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto"
)
var _ crypto.PrivateKeySigningBytes = &PrivateKey{}
diff --git a/crypto/p256/public.go b/crypto/p256/public.go
index 7625427..902dd93 100644
--- a/crypto/p256/public.go
+++ b/crypto/p256/public.go
@@ -8,8 +8,8 @@ import (
"fmt"
"math/big"
- "github.com/ucan-wg/go-did-it/crypto"
- helpers "github.com/ucan-wg/go-did-it/crypto/internal"
+ "github.com/MetaMask/go-did-it/crypto"
+ helpers "github.com/MetaMask/go-did-it/crypto/internal"
)
var _ crypto.PublicKeySigningBytes = &PublicKey{}
diff --git a/crypto/p384/key_test.go b/crypto/p384/key_test.go
index 5c131d5..b5c0972 100644
--- a/crypto/p384/key_test.go
+++ b/crypto/p384/key_test.go
@@ -3,8 +3,8 @@ package p384
import (
"testing"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/_testsuite"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/_testsuite"
)
var harness = testsuite.TestHarness[*PublicKey, *PrivateKey]{
diff --git a/crypto/p384/private.go b/crypto/p384/private.go
index dd30a1c..73346cb 100644
--- a/crypto/p384/private.go
+++ b/crypto/p384/private.go
@@ -9,7 +9,7 @@ import (
"fmt"
"math/big"
- "github.com/ucan-wg/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto"
)
var _ crypto.PrivateKeySigningBytes = &PrivateKey{}
diff --git a/crypto/p384/public.go b/crypto/p384/public.go
index 2b3a03f..c318659 100644
--- a/crypto/p384/public.go
+++ b/crypto/p384/public.go
@@ -8,8 +8,8 @@ import (
"fmt"
"math/big"
- "github.com/ucan-wg/go-did-it/crypto"
- helpers "github.com/ucan-wg/go-did-it/crypto/internal"
+ "github.com/MetaMask/go-did-it/crypto"
+ helpers "github.com/MetaMask/go-did-it/crypto/internal"
)
var _ crypto.PublicKeySigningBytes = &PublicKey{}
diff --git a/crypto/p521/key_test.go b/crypto/p521/key_test.go
index 15e6f26..404ff57 100644
--- a/crypto/p521/key_test.go
+++ b/crypto/p521/key_test.go
@@ -3,8 +3,8 @@ package p521
import (
"testing"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/_testsuite"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/_testsuite"
)
var harness = testsuite.TestHarness[*PublicKey, *PrivateKey]{
diff --git a/crypto/p521/private.go b/crypto/p521/private.go
index f4ceb1d..bcc1e29 100644
--- a/crypto/p521/private.go
+++ b/crypto/p521/private.go
@@ -9,7 +9,7 @@ import (
"fmt"
"math/big"
- "github.com/ucan-wg/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto"
)
var _ crypto.PrivateKeySigningBytes = &PrivateKey{}
diff --git a/crypto/p521/public.go b/crypto/p521/public.go
index 0f6d933..3ebb6a9 100644
--- a/crypto/p521/public.go
+++ b/crypto/p521/public.go
@@ -8,8 +8,8 @@ import (
"fmt"
"math/big"
- "github.com/ucan-wg/go-did-it/crypto"
- helpers "github.com/ucan-wg/go-did-it/crypto/internal"
+ "github.com/MetaMask/go-did-it/crypto"
+ helpers "github.com/MetaMask/go-did-it/crypto/internal"
)
var _ crypto.PublicKeySigningBytes = &PublicKey{}
diff --git a/crypto/rsa/key.go b/crypto/rsa/key.go
index 6c66fd6..ba673d8 100644
--- a/crypto/rsa/key.go
+++ b/crypto/rsa/key.go
@@ -5,7 +5,7 @@ import (
"crypto/rsa"
"fmt"
- "github.com/ucan-wg/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto"
)
const (
diff --git a/crypto/rsa/key_test.go b/crypto/rsa/key_test.go
index fe249d6..13118c6 100644
--- a/crypto/rsa/key_test.go
+++ b/crypto/rsa/key_test.go
@@ -6,8 +6,8 @@ import (
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/_testsuite"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/_testsuite"
)
var harness2048 = testsuite.TestHarness[*PublicKey, *PrivateKey]{
diff --git a/crypto/rsa/private.go b/crypto/rsa/private.go
index 0560fe8..a0440e9 100644
--- a/crypto/rsa/private.go
+++ b/crypto/rsa/private.go
@@ -9,7 +9,7 @@ import (
"fmt"
"math/big"
- "github.com/ucan-wg/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto"
)
var _ crypto.PrivateKeySigningASN1 = &PrivateKey{}
diff --git a/crypto/rsa/public.go b/crypto/rsa/public.go
index b122226..3d7832d 100644
--- a/crypto/rsa/public.go
+++ b/crypto/rsa/public.go
@@ -8,8 +8,8 @@ import (
"fmt"
"math/big"
- "github.com/ucan-wg/go-did-it/crypto"
- helpers "github.com/ucan-wg/go-did-it/crypto/internal"
+ "github.com/MetaMask/go-did-it/crypto"
+ helpers "github.com/MetaMask/go-did-it/crypto/internal"
)
var _ crypto.PublicKeySigningASN1 = &PublicKey{}
diff --git a/crypto/secp256k1/key_test.go b/crypto/secp256k1/key_test.go
index 72edad8..5f0e70e 100644
--- a/crypto/secp256k1/key_test.go
+++ b/crypto/secp256k1/key_test.go
@@ -6,8 +6,8 @@ import (
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/_testsuite"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/_testsuite"
)
var harness = testsuite.TestHarness[*PublicKey, *PrivateKey]{
diff --git a/crypto/secp256k1/private.go b/crypto/secp256k1/private.go
index a9f292a..0c172d0 100644
--- a/crypto/secp256k1/private.go
+++ b/crypto/secp256k1/private.go
@@ -9,7 +9,7 @@ import (
"github.com/decred/dcrd/dcrec/secp256k1/v4"
"github.com/decred/dcrd/dcrec/secp256k1/v4/ecdsa"
- "github.com/ucan-wg/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto"
)
var _ crypto.PrivateKeySigningBytes = &PrivateKey{}
diff --git a/crypto/secp256k1/public.go b/crypto/secp256k1/public.go
index 97477a0..f96c2b0 100644
--- a/crypto/secp256k1/public.go
+++ b/crypto/secp256k1/public.go
@@ -9,8 +9,8 @@ import (
"github.com/decred/dcrd/dcrec/secp256k1/v4"
"github.com/decred/dcrd/dcrec/secp256k1/v4/ecdsa"
- "github.com/ucan-wg/go-did-it/crypto"
- helpers "github.com/ucan-wg/go-did-it/crypto/internal"
+ "github.com/MetaMask/go-did-it/crypto"
+ helpers "github.com/MetaMask/go-did-it/crypto/internal"
)
var _ crypto.PublicKeySigningBytes = &PublicKey{}
diff --git a/crypto/x25519/key_test.go b/crypto/x25519/key_test.go
index a0de228..abde75e 100644
--- a/crypto/x25519/key_test.go
+++ b/crypto/x25519/key_test.go
@@ -5,8 +5,8 @@ import (
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it/crypto/_testsuite"
- "github.com/ucan-wg/go-did-it/crypto/ed25519"
+ "github.com/MetaMask/go-did-it/crypto/_testsuite"
+ "github.com/MetaMask/go-did-it/crypto/ed25519"
)
var harness = testsuite.TestHarness[*PublicKey, *PrivateKey]{
diff --git a/crypto/x25519/private.go b/crypto/x25519/private.go
index f7a49ca..1775917 100644
--- a/crypto/x25519/private.go
+++ b/crypto/x25519/private.go
@@ -7,8 +7,8 @@ import (
"encoding/pem"
"fmt"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/ed25519"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/ed25519"
)
var _ crypto.PrivateKeyKeyExchange = (*PrivateKey)(nil)
diff --git a/crypto/x25519/public.go b/crypto/x25519/public.go
index 8b89e3c..238ea81 100644
--- a/crypto/x25519/public.go
+++ b/crypto/x25519/public.go
@@ -7,9 +7,9 @@ import (
"fmt"
"math/big"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/ed25519"
- helpers "github.com/ucan-wg/go-did-it/crypto/internal"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/ed25519"
+ helpers "github.com/MetaMask/go-did-it/crypto/internal"
)
var _ crypto.PublicKey = (*PublicKey)(nil)
diff --git a/did_test.go b/did_test.go
index 2fc22ff..cc23365 100644
--- a/did_test.go
+++ b/did_test.go
@@ -7,9 +7,9 @@ import (
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it"
- "github.com/ucan-wg/go-did-it/crypto/x25519"
- _ "github.com/ucan-wg/go-did-it/verifiers/did-key"
+ "github.com/MetaMask/go-did-it"
+ "github.com/MetaMask/go-did-it/crypto/x25519"
+ _ "github.com/MetaMask/go-did-it/verifiers/did-key"
)
func Example_signature() {
diff --git a/document/document.go b/document/document.go
index 6e8f401..6332dcc 100644
--- a/document/document.go
+++ b/document/document.go
@@ -7,8 +7,8 @@ import (
"io"
"net/url"
- "github.com/ucan-wg/go-did-it"
- verifications "github.com/ucan-wg/go-did-it/verifiers/_methods"
+ "github.com/MetaMask/go-did-it"
+ verifications "github.com/MetaMask/go-did-it/verifiers/_methods"
)
var _ did.Document = &Document{}
diff --git a/document/document_test.go b/document/document_test.go
index 8f8a40a..288d1f8 100644
--- a/document/document_test.go
+++ b/document/document_test.go
@@ -6,10 +6,10 @@ import (
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/ed25519"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/jsonwebkey"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/x25519"
- _ "github.com/ucan-wg/go-did-it/verifiers/did-key"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/ed25519"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/jsonwebkey"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/x25519"
+ _ "github.com/MetaMask/go-did-it/verifiers/did-key"
)
func TestRoundTrip(t *testing.T) {
diff --git a/go.mod b/go.mod
index dadedf9..7568f65 100644
--- a/go.mod
+++ b/go.mod
@@ -1,4 +1,4 @@
-module github.com/ucan-wg/go-did-it
+module github.com/MetaMask/go-did-it
go 1.23.0
diff --git a/interfaces.go b/interfaces.go
index e04f955..58ddbb0 100644
--- a/interfaces.go
+++ b/interfaces.go
@@ -4,7 +4,7 @@ import (
"encoding/json"
"net/url"
- "github.com/ucan-wg/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto"
)
// DID is a decoded (i.e. from a string) Decentralized Identifier.
diff --git a/utilities.go b/utilities.go
index 1883e93..152a99e 100644
--- a/utilities.go
+++ b/utilities.go
@@ -3,7 +3,7 @@ package did
import (
"fmt"
- "github.com/ucan-wg/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto"
)
// TryAllVerify tries to verify the signature with all the methods in the slice.
diff --git a/verifiers/_methods/ed25519/VerificationKey2018.go b/verifiers/_methods/ed25519/VerificationKey2018.go
index edb87d9..3bbfc64 100644
--- a/verifiers/_methods/ed25519/VerificationKey2018.go
+++ b/verifiers/_methods/ed25519/VerificationKey2018.go
@@ -7,8 +7,8 @@ import (
"github.com/mr-tron/base58"
- "github.com/ucan-wg/go-did-it"
- "github.com/ucan-wg/go-did-it/crypto/ed25519"
+ "github.com/MetaMask/go-did-it"
+ "github.com/MetaMask/go-did-it/crypto/ed25519"
)
// Specification: https://w3c-ccg.github.io/lds-ed25519-2018/
diff --git a/verifiers/_methods/ed25519/VerificationKey2018_test.go b/verifiers/_methods/ed25519/VerificationKey2018_test.go
index fa8ff74..40a4878 100644
--- a/verifiers/_methods/ed25519/VerificationKey2018_test.go
+++ b/verifiers/_methods/ed25519/VerificationKey2018_test.go
@@ -6,7 +6,7 @@ import (
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/ed25519"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/ed25519"
)
func TestJsonRoundTrip2018(t *testing.T) {
diff --git a/verifiers/_methods/ed25519/VerificationKey2020.go b/verifiers/_methods/ed25519/VerificationKey2020.go
index 50eb2fc..4cdc174 100644
--- a/verifiers/_methods/ed25519/VerificationKey2020.go
+++ b/verifiers/_methods/ed25519/VerificationKey2020.go
@@ -5,8 +5,8 @@ import (
"errors"
"fmt"
- "github.com/ucan-wg/go-did-it"
- "github.com/ucan-wg/go-did-it/crypto/ed25519"
+ "github.com/MetaMask/go-did-it"
+ "github.com/MetaMask/go-did-it/crypto/ed25519"
)
// Specification: https://w3c.github.io/cg-reports/credentials/CG-FINAL-di-eddsa-2020-20220724/
diff --git a/verifiers/_methods/ed25519/VerificationKey2020_test.go b/verifiers/_methods/ed25519/VerificationKey2020_test.go
index ba22bba..acd6c59 100644
--- a/verifiers/_methods/ed25519/VerificationKey2020_test.go
+++ b/verifiers/_methods/ed25519/VerificationKey2020_test.go
@@ -7,10 +7,10 @@ import (
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it"
- "github.com/ucan-wg/go-did-it/crypto/ed25519"
- ed25519vm "github.com/ucan-wg/go-did-it/verifiers/_methods/ed25519"
- _ "github.com/ucan-wg/go-did-it/verifiers/did-key"
+ "github.com/MetaMask/go-did-it"
+ "github.com/MetaMask/go-did-it/crypto/ed25519"
+ ed25519vm "github.com/MetaMask/go-did-it/verifiers/_methods/ed25519"
+ _ "github.com/MetaMask/go-did-it/verifiers/did-key"
)
func TestJsonRoundTrip2020(t *testing.T) {
diff --git a/verifiers/_methods/json.go b/verifiers/_methods/json.go
index dc74238..d65b288 100644
--- a/verifiers/_methods/json.go
+++ b/verifiers/_methods/json.go
@@ -4,13 +4,13 @@ import (
"encoding/json"
"fmt"
- "github.com/ucan-wg/go-did-it"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/ed25519"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/jsonwebkey"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/multikey"
- p256vm "github.com/ucan-wg/go-did-it/verifiers/_methods/p256"
- secp256k1vm "github.com/ucan-wg/go-did-it/verifiers/_methods/secp256k1"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/x25519"
+ "github.com/MetaMask/go-did-it"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/ed25519"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/jsonwebkey"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/multikey"
+ p256vm "github.com/MetaMask/go-did-it/verifiers/_methods/p256"
+ secp256k1vm "github.com/MetaMask/go-did-it/verifiers/_methods/secp256k1"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/x25519"
)
func UnmarshalJSON(data []byte) (did.VerificationMethod, error) {
diff --git a/verifiers/_methods/jsonwebkey/JsonWebKey2020.go b/verifiers/_methods/jsonwebkey/JsonWebKey2020.go
index 3c6454d..6a93392 100644
--- a/verifiers/_methods/jsonwebkey/JsonWebKey2020.go
+++ b/verifiers/_methods/jsonwebkey/JsonWebKey2020.go
@@ -4,9 +4,9 @@ import (
"encoding/json"
"errors"
- "github.com/ucan-wg/go-did-it"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/jwk"
+ "github.com/MetaMask/go-did-it"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/jwk"
)
// Specification:
diff --git a/verifiers/_methods/multikey/multikey.go b/verifiers/_methods/multikey/multikey.go
index 62e584b..dbcd761 100644
--- a/verifiers/_methods/multikey/multikey.go
+++ b/verifiers/_methods/multikey/multikey.go
@@ -5,9 +5,9 @@ import (
"errors"
"fmt"
- "github.com/ucan-wg/go-did-it"
- "github.com/ucan-wg/go-did-it/crypto"
- allkeys "github.com/ucan-wg/go-did-it/crypto/_allkeys"
+ "github.com/MetaMask/go-did-it"
+ "github.com/MetaMask/go-did-it/crypto"
+ allkeys "github.com/MetaMask/go-did-it/crypto/_allkeys"
)
// Specification: https://www.w3.org/TR/cid-1.0/#Multikey
diff --git a/verifiers/_methods/multikey/multikey_test.go b/verifiers/_methods/multikey/multikey_test.go
index 77a881d..c5825c8 100644
--- a/verifiers/_methods/multikey/multikey_test.go
+++ b/verifiers/_methods/multikey/multikey_test.go
@@ -6,9 +6,9 @@ import (
"github.com/stretchr/testify/require"
- _ "github.com/ucan-wg/go-did-it/verifiers/did-key"
+ _ "github.com/MetaMask/go-did-it/verifiers/did-key"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/multikey"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/multikey"
)
func TestJsonRoundTrip(t *testing.T) {
diff --git a/verifiers/_methods/p256/key2021.go b/verifiers/_methods/p256/key2021.go
index f8453c4..072cdb3 100644
--- a/verifiers/_methods/p256/key2021.go
+++ b/verifiers/_methods/p256/key2021.go
@@ -7,9 +7,9 @@ import (
"github.com/mr-tron/base58"
- "github.com/ucan-wg/go-did-it"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/p256"
+ "github.com/MetaMask/go-did-it"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/p256"
)
// Specification: missing
diff --git a/verifiers/_methods/p256/key2021_test.go b/verifiers/_methods/p256/key2021_test.go
index f208605..59687f1 100644
--- a/verifiers/_methods/p256/key2021_test.go
+++ b/verifiers/_methods/p256/key2021_test.go
@@ -6,7 +6,7 @@ import (
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/p256"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/p256"
)
func TestJsonRoundTrip(t *testing.T) {
diff --git a/verifiers/_methods/secp256k1/VerificationKey2019.go b/verifiers/_methods/secp256k1/VerificationKey2019.go
index beaae30..fd8b746 100644
--- a/verifiers/_methods/secp256k1/VerificationKey2019.go
+++ b/verifiers/_methods/secp256k1/VerificationKey2019.go
@@ -7,9 +7,9 @@ import (
"github.com/mr-tron/base58"
- "github.com/ucan-wg/go-did-it"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/secp256k1"
+ "github.com/MetaMask/go-did-it"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/secp256k1"
)
// Specification: https://w3c-ccg.github.io/lds-ecdsa-secp256k1-2019/
diff --git a/verifiers/_methods/secp256k1/VerificationKey2019_test.go b/verifiers/_methods/secp256k1/VerificationKey2019_test.go
index 68cb856..c5939da 100644
--- a/verifiers/_methods/secp256k1/VerificationKey2019_test.go
+++ b/verifiers/_methods/secp256k1/VerificationKey2019_test.go
@@ -6,7 +6,7 @@ import (
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/secp256k1"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/secp256k1"
)
func TestJsonRoundTrip(t *testing.T) {
diff --git a/verifiers/_methods/x25519/KeyAgreementKey2019.go b/verifiers/_methods/x25519/KeyAgreementKey2019.go
index 0ed89ca..cb806a6 100644
--- a/verifiers/_methods/x25519/KeyAgreementKey2019.go
+++ b/verifiers/_methods/x25519/KeyAgreementKey2019.go
@@ -7,9 +7,9 @@ import (
"github.com/mr-tron/base58"
- "github.com/ucan-wg/go-did-it"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/x25519"
+ "github.com/MetaMask/go-did-it"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/x25519"
)
// Specification: https://github.com/digitalbazaar/x25519-key-agreement-key-2019
diff --git a/verifiers/_methods/x25519/KeyAgreementKey2019_test.go b/verifiers/_methods/x25519/KeyAgreementKey2019_test.go
index 1289055..8c0ce36 100644
--- a/verifiers/_methods/x25519/KeyAgreementKey2019_test.go
+++ b/verifiers/_methods/x25519/KeyAgreementKey2019_test.go
@@ -6,7 +6,7 @@ import (
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/x25519"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/x25519"
)
func TestJsonRoundTrip2019(t *testing.T) {
diff --git a/verifiers/_methods/x25519/KeyAgreementKey2020.go b/verifiers/_methods/x25519/KeyAgreementKey2020.go
index faaf18a..6631de8 100644
--- a/verifiers/_methods/x25519/KeyAgreementKey2020.go
+++ b/verifiers/_methods/x25519/KeyAgreementKey2020.go
@@ -5,9 +5,9 @@ import (
"errors"
"fmt"
- "github.com/ucan-wg/go-did-it"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/x25519"
+ "github.com/MetaMask/go-did-it"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/x25519"
)
// Specification: https://w3c-ccg.github.io/did-method-key/#ed25519-x25519
diff --git a/verifiers/_methods/x25519/KeyAgreementKey2020_test.go b/verifiers/_methods/x25519/KeyAgreementKey2020_test.go
index 2d1ce04..4ad9dc2 100644
--- a/verifiers/_methods/x25519/KeyAgreementKey2020_test.go
+++ b/verifiers/_methods/x25519/KeyAgreementKey2020_test.go
@@ -6,7 +6,7 @@ import (
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/x25519"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/x25519"
)
func TestJsonRoundTrip2020(t *testing.T) {
diff --git a/verifiers/did-key/document.go b/verifiers/did-key/document.go
index 635411d..18df510 100644
--- a/verifiers/did-key/document.go
+++ b/verifiers/did-key/document.go
@@ -4,7 +4,7 @@ import (
"encoding/json"
"net/url"
- "github.com/ucan-wg/go-did-it"
+ "github.com/MetaMask/go-did-it"
)
var _ did.Document = &document{}
diff --git a/verifiers/did-key/document_test.go b/verifiers/did-key/document_test.go
index 4b21045..2ccab9c 100644
--- a/verifiers/did-key/document_test.go
+++ b/verifiers/did-key/document_test.go
@@ -6,8 +6,8 @@ import (
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it"
- "github.com/ucan-wg/go-did-it/verifiers/did-key/testvectors"
+ "github.com/MetaMask/go-did-it"
+ "github.com/MetaMask/go-did-it/verifiers/did-key/testvectors"
)
func TestDocument(t *testing.T) {
diff --git a/verifiers/did-key/key.go b/verifiers/did-key/key.go
index bd18673..842b1d8 100644
--- a/verifiers/did-key/key.go
+++ b/verifiers/did-key/key.go
@@ -4,22 +4,22 @@ import (
"fmt"
"strings"
- "github.com/ucan-wg/go-did-it"
- "github.com/ucan-wg/go-did-it/crypto"
- allkeys "github.com/ucan-wg/go-did-it/crypto/_allkeys"
- "github.com/ucan-wg/go-did-it/crypto/ed25519"
- "github.com/ucan-wg/go-did-it/crypto/p256"
- "github.com/ucan-wg/go-did-it/crypto/p384"
- "github.com/ucan-wg/go-did-it/crypto/p521"
- "github.com/ucan-wg/go-did-it/crypto/rsa"
- "github.com/ucan-wg/go-did-it/crypto/secp256k1"
- "github.com/ucan-wg/go-did-it/crypto/x25519"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/ed25519"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/jsonwebkey"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/multikey"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/p256"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/secp256k1"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/x25519"
+ "github.com/MetaMask/go-did-it"
+ "github.com/MetaMask/go-did-it/crypto"
+ allkeys "github.com/MetaMask/go-did-it/crypto/_allkeys"
+ "github.com/MetaMask/go-did-it/crypto/ed25519"
+ "github.com/MetaMask/go-did-it/crypto/p256"
+ "github.com/MetaMask/go-did-it/crypto/p384"
+ "github.com/MetaMask/go-did-it/crypto/p521"
+ "github.com/MetaMask/go-did-it/crypto/rsa"
+ "github.com/MetaMask/go-did-it/crypto/secp256k1"
+ "github.com/MetaMask/go-did-it/crypto/x25519"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/ed25519"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/jsonwebkey"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/multikey"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/p256"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/secp256k1"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/x25519"
)
// Specification: https://w3c-ccg.github.io/did-method-key/
diff --git a/verifiers/did-key/key_test.go b/verifiers/did-key/key_test.go
index c995cf5..5e966c6 100644
--- a/verifiers/did-key/key_test.go
+++ b/verifiers/did-key/key_test.go
@@ -7,9 +7,9 @@ import (
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it"
- "github.com/ucan-wg/go-did-it/crypto/ed25519"
- didkey "github.com/ucan-wg/go-did-it/verifiers/did-key"
+ "github.com/MetaMask/go-did-it"
+ "github.com/MetaMask/go-did-it/crypto/ed25519"
+ didkey "github.com/MetaMask/go-did-it/verifiers/did-key"
)
func ExampleGenerateKeyPair() {
diff --git a/verifiers/did-key/testvectors/vectors.go b/verifiers/did-key/testvectors/vectors.go
index 6f31987..2351f62 100644
--- a/verifiers/did-key/testvectors/vectors.go
+++ b/verifiers/did-key/testvectors/vectors.go
@@ -8,15 +8,15 @@ import (
"github.com/mr-tron/base58"
- "github.com/ucan-wg/go-did-it/crypto"
- "github.com/ucan-wg/go-did-it/crypto/ed25519"
- "github.com/ucan-wg/go-did-it/crypto/jwk"
- "github.com/ucan-wg/go-did-it/crypto/p256"
- "github.com/ucan-wg/go-did-it/crypto/secp256k1"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/ed25519"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/jsonwebkey"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/p256"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/secp256k1"
+ "github.com/MetaMask/go-did-it/crypto"
+ "github.com/MetaMask/go-did-it/crypto/ed25519"
+ "github.com/MetaMask/go-did-it/crypto/jwk"
+ "github.com/MetaMask/go-did-it/crypto/p256"
+ "github.com/MetaMask/go-did-it/crypto/secp256k1"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/ed25519"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/jsonwebkey"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/p256"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/secp256k1"
)
// Origin: https://github.com/w3c-ccg/did-key-spec/tree/main/test-vectors
diff --git a/verifiers/did-plc/document.go b/verifiers/did-plc/document.go
index 917eaea..2abfdda 100644
--- a/verifiers/did-plc/document.go
+++ b/verifiers/did-plc/document.go
@@ -4,7 +4,7 @@ import (
"encoding/json"
"net/url"
- "github.com/ucan-wg/go-did-it"
+ "github.com/MetaMask/go-did-it"
)
var _ did.Document = &document{}
diff --git a/verifiers/did-plc/document_test.go b/verifiers/did-plc/document_test.go
index 575f196..26d9058 100644
--- a/verifiers/did-plc/document_test.go
+++ b/verifiers/did-plc/document_test.go
@@ -9,7 +9,7 @@ import (
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it"
+ "github.com/MetaMask/go-did-it"
)
func TestDocument(t *testing.T) {
diff --git a/verifiers/did-plc/plc.go b/verifiers/did-plc/plc.go
index 6b0fae5..2b9a30e 100644
--- a/verifiers/did-plc/plc.go
+++ b/verifiers/did-plc/plc.go
@@ -8,19 +8,19 @@ import (
"net/url"
"strings"
- "github.com/ucan-wg/go-did-it"
- allkeys "github.com/ucan-wg/go-did-it/crypto/_allkeys"
- "github.com/ucan-wg/go-did-it/crypto/ed25519"
- "github.com/ucan-wg/go-did-it/crypto/p256"
- "github.com/ucan-wg/go-did-it/crypto/p384"
- "github.com/ucan-wg/go-did-it/crypto/p521"
- "github.com/ucan-wg/go-did-it/crypto/rsa"
- "github.com/ucan-wg/go-did-it/crypto/secp256k1"
- ed25519vm "github.com/ucan-wg/go-did-it/verifiers/_methods/ed25519"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/jsonwebkey"
- "github.com/ucan-wg/go-did-it/verifiers/_methods/multikey"
- p256vm "github.com/ucan-wg/go-did-it/verifiers/_methods/p256"
- secp256k1vm "github.com/ucan-wg/go-did-it/verifiers/_methods/secp256k1"
+ "github.com/MetaMask/go-did-it"
+ allkeys "github.com/MetaMask/go-did-it/crypto/_allkeys"
+ "github.com/MetaMask/go-did-it/crypto/ed25519"
+ "github.com/MetaMask/go-did-it/crypto/p256"
+ "github.com/MetaMask/go-did-it/crypto/p384"
+ "github.com/MetaMask/go-did-it/crypto/p521"
+ "github.com/MetaMask/go-did-it/crypto/rsa"
+ "github.com/MetaMask/go-did-it/crypto/secp256k1"
+ ed25519vm "github.com/MetaMask/go-did-it/verifiers/_methods/ed25519"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/jsonwebkey"
+ "github.com/MetaMask/go-did-it/verifiers/_methods/multikey"
+ p256vm "github.com/MetaMask/go-did-it/verifiers/_methods/p256"
+ secp256k1vm "github.com/MetaMask/go-did-it/verifiers/_methods/secp256k1"
)
// Specification: https://web.plc.directory/spec/v0.1/did-plc
diff --git a/verifiers/did-plc/plc_test.go b/verifiers/did-plc/plc_test.go
index 449178c..490beaa 100644
--- a/verifiers/did-plc/plc_test.go
+++ b/verifiers/did-plc/plc_test.go
@@ -5,7 +5,7 @@ import (
"github.com/stretchr/testify/require"
- "github.com/ucan-wg/go-did-it"
+ "github.com/MetaMask/go-did-it"
)
func TestParseDIDPlc(t *testing.T) {