diff options
author | Christian Grothoff <christian@grothoff.org> | 2013-03-04 14:09:27 +0000 |
---|---|---|
committer | Christian Grothoff <christian@grothoff.org> | 2013-03-04 14:09:27 +0000 |
commit | dcb57a9e51e8fe7412948ec0c47d383ed390ed61 (patch) | |
tree | 4b137f53d1959e099db77da43091973471df0dbc /src/include/gnunet_crypto_lib.h | |
parent | 4022058a6325b650542ad8e5a52e167c5336eaaa (diff) | |
download | gnunet-dcb57a9e51e8fe7412948ec0c47d383ed390ed61.tar.gz gnunet-dcb57a9e51e8fe7412948ec0c47d383ed390ed61.zip |
add argument to GNUNET_CRYPTO_ecc_decode_key to allow testing to disable key validation
Diffstat (limited to 'src/include/gnunet_crypto_lib.h')
-rw-r--r-- | src/include/gnunet_crypto_lib.h | 6 |
1 files changed, 5 insertions, 1 deletions
diff --git a/src/include/gnunet_crypto_lib.h b/src/include/gnunet_crypto_lib.h index 1bfa988c2..5b6d238c5 100644 --- a/src/include/gnunet_crypto_lib.h +++ b/src/include/gnunet_crypto_lib.h | |||
@@ -1244,11 +1244,15 @@ GNUNET_CRYPTO_ecc_encode_key (const struct GNUNET_CRYPTO_EccPrivateKey *key); | |||
1244 | * | 1244 | * |
1245 | * @param buf the buffer where the private key data is stored | 1245 | * @param buf the buffer where the private key data is stored |
1246 | * @param len the length of the data in 'buffer' | 1246 | * @param len the length of the data in 'buffer' |
1247 | * @param validate GNUNET_YES to validate that the key is well-formed, | ||
1248 | * GNUNET_NO if the key comes from a totally trusted source | ||
1249 | * and validation is considered too expensive | ||
1247 | * @return NULL on error | 1250 | * @return NULL on error |
1248 | */ | 1251 | */ |
1249 | struct GNUNET_CRYPTO_EccPrivateKey * | 1252 | struct GNUNET_CRYPTO_EccPrivateKey * |
1250 | GNUNET_CRYPTO_ecc_decode_key (const char *buf, | 1253 | GNUNET_CRYPTO_ecc_decode_key (const char *buf, |
1251 | size_t len); | 1254 | size_t len, |
1255 | int validate); | ||
1252 | 1256 | ||
1253 | 1257 | ||
1254 | /** | 1258 | /** |