changed key format, now includes the ed25519 pubkey for signing.

This commit is contained in:
git@daemon.de
2013-11-08 12:50:04 +01:00
parent e6733e5e56
commit 60ee58b106
25 changed files with 281 additions and 136 deletions

View File

@@ -45,7 +45,7 @@ typedef unsigned int qbyte; // Quad byte = 32 bits
#define PCP_ME "Pretty Curved Privacy"
#define PCP_KEY_VERSION 0x00000001U
#define PCP_KEY_VERSION 0x00000002U
#define PCP_KEY_PRIMITIVE "CURVE25519-ED25519-SALSA20-POLY1305"
#define PCP_KEY_TYPE_MAINSECRET 0x01
@@ -60,7 +60,7 @@ typedef unsigned int qbyte; // Quad byte = 32 bits
// vault id
#define PCP_VAULT_ID 0xC4
#define PCP_VAULT_VERSION 0x01
#define PCP_VAULT_VERSION 0x02
// sigs
#define PCP_SIG_VERSION 0x01

View File

@@ -79,6 +79,7 @@ extern "C" {
struct _pcp_key_t {
byte public[32];
byte secret[32];
byte edpub[32];
byte nonce[24];
byte encrypted[48];
char owner[255];
@@ -93,6 +94,7 @@ struct _pcp_key_t {
struct _pcp_pubkey_t {
byte public[32];
byte edpub[32];
char owner[255];
char mail[255];
char id[17];

View File

@@ -25,7 +25,7 @@
#define PCP_VERSION_MAJOR 0
#define PCP_VERSION_MINOR 1
#define PCP_VERSION_PATCH 2
#define PCP_VERSION_PATCH 3
#define PCP_MAKE_VERSION(major, minor, patch) \
((major) * 10000 + (minor) * 100 + (patch))