@@ -47,31 +47,32 @@ This base64 string encodes a sequence of bytes whose structure is defined below.
| Ğ1 | 0x00000001 |
| Ğ1-Test | 0x10000001 |
## encrypted datas
## version data
### v1
v1 data (encrypted):
| seed(32 bytes) | public key(32bytes) |
|:--------------:|:-------------------:|
| seed bytes | public key bytes |
The public key serves as a checksum. To check that the `.dewif` file is not corrupted, simply generate an ed25519 keypair with the seed and check that the obtained public key matches.
Symmetric encryption algorithm : aes256
aes256 key: scrypt of user passphrase with the following parameters:
Seed generated from scrypt with the following parameters:
aes256 key: scrypt of user passphrase with the following parameters:
password: passphrase
salt: sha256("dewif" ++ passphrase)
N : 4096
r: 16
p: 1
Encrypted datas :
| seed(32 bytes) | public key(32bytes) |
|:--------------:|:-------------------:|
| seed bytes | public key bytes |
The public key serves as a checksum. To check that the `.dewif` file is not corrupted, simply generate an ed25519 keypair with the seed and check that the obtained public key matches.
Example #1:
Example 1:
aes256 key generated from scrypt with the following parameters:
Seed generated from scrypt with the following parameters:
| seed bytes | public key bytes | seed bytes | public key bytes |
The public key serves as a checksum. To check that the `.dewif` file is not corrupted, simply generate an ed25519 keypair with the seed and check that the obtained public key matches.
Symmetric encryption algorithm : aes256
aes256 key: scrypt of user passphrase with the following parameters:
Seed generated from scrypt with the following parameters:
aes256 key: scrypt of user passphrase with the following parameters:
password: passphrase
salt: sha256("dewif" ++ passphrase)
N : 4096
r: 16
p: 1
Encrypted datas :
### v3
| seed1(32 bytes) | public key1(32bytes) | seed2(32 bytes) | public key2(32bytes) |
| seed bytes | public key bytes | seed bytes | public key bytes |
v3 data :
| `log N` | Encrypted data |
|:-------:|:--------------:|
| 1 byte | 64 bytes |
Encrypted data :
| seed(32 bytes) | public key(32bytes) |
|:--------------:|:-------------------:|
| seed bytes | public key bytes |
The public key serves as a checksum. To check that the `.dewif` file is not corrupted, simply generate an ed25519 keypair with the seed and check that the obtained public key matches.
Symmetric encryption algorithm : aes256
aes256 key: scrypt of user passphrase with the following parameters:
password: passphrase
salt: sha256("dewif" ++ passphrase)
N : `2^(log N)`
r: 16
p: 1
Example #2:
aes256 key generated from scrypt with the following parameters: