summaryrefslogtreecommitdiffstats
path: root/examples
diff options
context:
space:
mode:
authorNikos Mavrogiannopoulos <nmav@gnutls.org>2010-08-25 17:45:44 +0200
committerNikos Mavrogiannopoulos <nmav@gnutls.org>2010-08-25 17:45:44 +0200
commit68c4e5ec42e1151591aee19ba36a4dbe22715a91 (patch)
tree075c2d8811ba79dd6b33924ef5649dff5dbedf07 /examples
parent61950862971ef6630930e9889921959405f3f76e (diff)
downloadcryptodev-linux-68c4e5ec42e1151591aee19ba36a4dbe22715a91.tar.gz
cryptodev-linux-68c4e5ec42e1151591aee19ba36a4dbe22715a91.tar.xz
cryptodev-linux-68c4e5ec42e1151591aee19ba36a4dbe22715a91.zip
The RFC5649 wrapping algorithm now includes a DER encoding of the data to distinguish between keys of different types. This prevents keys being unwrapped in a wrong type.
Diffstat (limited to 'examples')
-rw-r--r--examples/pk.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/examples/pk.c b/examples/pk.c
index 032ae98..ea5720c 100644
--- a/examples/pk.c
+++ b/examples/pk.c
@@ -646,7 +646,7 @@ test_ncr_wrap_key3(int cfd)
/* try unwrapping */
memset(&kwrap, 0, sizeof(kwrap));
kwrap.algorithm = NCR_WALG_AES_RFC5649;
- kwrap.wrapped_key_algorithm = NCR_ALG_RSA;
+ kwrap.wrapped_key_flags = 0;
kwrap.keytowrap = privkey;
kwrap.key = key;
kwrap.io = data;