aboutsummaryrefslogtreecommitdiff
path: root/src/include/gnunet_crypto_lib.h
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2013-08-11 15:36:42 +0000
committerChristian Grothoff <christian@grothoff.org>2013-08-11 15:36:42 +0000
commitb64ef35e9e4d3f43b8840bacac60ac2a91ae03f1 (patch)
treed97273f6ef88c54622e15ea1d675b7d9f2ee93a5 /src/include/gnunet_crypto_lib.h
parenta78e015dd4764c54c013729cf58c55dbaa8af626 (diff)
downloadgnunet-b64ef35e9e4d3f43b8840bacac60ac2a91ae03f1.tar.gz
gnunet-b64ef35e9e4d3f43b8840bacac60ac2a91ae03f1.zip
-add extra context argument for key deriviation, so that fs and gads do not collide
Diffstat (limited to 'src/include/gnunet_crypto_lib.h')
-rw-r--r--src/include/gnunet_crypto_lib.h12
1 files changed, 9 insertions, 3 deletions
diff --git a/src/include/gnunet_crypto_lib.h b/src/include/gnunet_crypto_lib.h
index 1704fce07..96bbdc214 100644
--- a/src/include/gnunet_crypto_lib.h
+++ b/src/include/gnunet_crypto_lib.h
@@ -1,10 +1,10 @@
1/* 1/*
2 This file is part of GNUnet. 2 This file is part of GNUnet.
3 (C) 2001, 2002, 2003, 2004, 2005, 2006, 2007, 2012 Christian Grothoff (and other contributing authors) 3 (C) 2001-2013 Christian Grothoff (and other contributing authors)
4 4
5 GNUnet is free software; you can redistribute it and/or modify 5 GNUnet is free software; you can redistribute it and/or modify
6 it under the terms of the GNU General Public License as published 6 it under the terms of the GNU General Public License as published
7 by the Free Software Foundation; either version 2, or (at your 7 by the Free Software Foundation; either version 3, or (at your
8 option) any later version. 8 option) any later version.
9 9
10 GNUnet is distributed in the hope that it will be useful, but 10 GNUnet is distributed in the hope that it will be useful, but
@@ -979,11 +979,14 @@ GNUNET_CRYPTO_ecc_verify (uint32_t purpose,
979 * 979 *
980 * @param priv original private key 980 * @param priv original private key
981 * @param label label to use for key deriviation 981 * @param label label to use for key deriviation
982 * @param context additional context to use for HKDF of 'h';
983 * typically the name of the subsystem/application
982 * @return derived private key 984 * @return derived private key
983 */ 985 */
984struct GNUNET_CRYPTO_EccPrivateKey * 986struct GNUNET_CRYPTO_EccPrivateKey *
985GNUNET_CRYPTO_ecc_key_derive (const struct GNUNET_CRYPTO_EccPrivateKey *priv, 987GNUNET_CRYPTO_ecc_key_derive (const struct GNUNET_CRYPTO_EccPrivateKey *priv,
986 const char *label); 988 const char *label,
989 const char *context);
987 990
988 991
989/** 992/**
@@ -992,11 +995,14 @@ GNUNET_CRYPTO_ecc_key_derive (const struct GNUNET_CRYPTO_EccPrivateKey *priv,
992 * 995 *
993 * @param pub original public key 996 * @param pub original public key
994 * @param label label to use for key deriviation 997 * @param label label to use for key deriviation
998 * @param context additional context to use for HKDF of 'h'.
999 * typically the name of the subsystem/application
995 * @param result where to write the derived public key 1000 * @param result where to write the derived public key
996 */ 1001 */
997void 1002void
998GNUNET_CRYPTO_ecc_public_key_derive (const struct GNUNET_CRYPTO_EccPublicKey *pub, 1003GNUNET_CRYPTO_ecc_public_key_derive (const struct GNUNET_CRYPTO_EccPublicKey *pub,
999 const char *label, 1004 const char *label,
1005 const char *context,
1000 struct GNUNET_CRYPTO_EccPublicKey *result); 1006 struct GNUNET_CRYPTO_EccPublicKey *result);
1001 1007
1002 1008