1
0
mirror of git://git.gnupg.org/gnupg.git synced 2024-06-06 23:17:47 +02:00

kbx: Add experimental support for EDDSA.

* kbx/keybox-openpgp.c (parse_key): Use algo constants and add
experimental support for EdDSA.
This commit is contained in:
Werner Koch 2014-05-07 12:39:43 +02:00
parent a63ed98758
commit bdb9c2b314

View File

@ -199,23 +199,24 @@ parse_key (const unsigned char *data, size_t datalen,
switch (algorithm) switch (algorithm)
{ {
case 1: case PUBKEY_ALGO_RSA:
case 2: case PUBKEY_ALGO_RSA_E:
case 3: /* RSA */ case PUBKEY_ALGO_RSA_S:
npkey = 2; npkey = 2;
break; break;
case 16: case PUBKEY_ALGO_ELGAMAL_E:
case 20: /* Elgamal */ case PUBKEY_ALGO_ELGAMAL:
npkey = 3; npkey = 3;
break; break;
case 17: /* DSA */ case PUBKEY_ALGO_DSA:
npkey = 4; npkey = 4;
break; break;
case 18: /* ECDH */ case PUBKEY_ALGO_ECDH:
npkey = 3; npkey = 3;
is_ecc = 1; is_ecc = 1;
break; break;
case 19: /* ECDSA */ case PUBKEY_ALGO_ECDSA:
case PUBKEY_ALGO_EDDSA:
npkey = 2; npkey = 2;
is_ecc = 1; is_ecc = 1;
break; break;