*/
void
GNUNET_CRYPTO_aes_derive_iv (struct GNUNET_CRYPTO_AesInitializationVector *iv,
- const struct GNUNET_CRYPTO_AesSessionKey *skey, void *salt,
- size_t salt_len, ...);
+ const struct GNUNET_CRYPTO_AesSessionKey *skey,
+ const void *salt, size_t salt_len,
+ ...);
/**
*/
void
GNUNET_CRYPTO_aes_derive_iv_v (struct GNUNET_CRYPTO_AesInitializationVector *iv,
- const struct GNUNET_CRYPTO_AesSessionKey *skey, void *salt,
- size_t salt_len, va_list argp);
+ const struct GNUNET_CRYPTO_AesSessionKey *skey,
+ const void *salt, size_t salt_len,
+ va_list argp);
/**
/**
* Compute the hash of an entire file.
*
- * @param sched scheduler to use
* @param priority scheduling priority to use
* @param filename name of file to hash
* @param blocksize number of bytes to process in one task
* @return NULL on (immediate) errror
*/
struct GNUNET_CRYPTO_FileHashContext *
-GNUNET_CRYPTO_hash_file (struct GNUNET_SCHEDULER_Handle *sched,
- enum GNUNET_SCHEDULER_Priority priority,
+GNUNET_CRYPTO_hash_file (enum GNUNET_SCHEDULER_Priority priority,
const char *filename,
size_t blocksize,
GNUNET_CRYPTO_HashCompletedCallback callback,
GNUNET_CRYPTO_hmac_derive_key_v(struct GNUNET_CRYPTO_AuthKey *key,
const struct GNUNET_CRYPTO_AesSessionKey *rkey,
const void *salt,
- const size_t salt_len,
+ size_t salt_len,
va_list argp);
GNUNET_CRYPTO_hmac_derive_key(struct GNUNET_CRYPTO_AuthKey *key,
const struct GNUNET_CRYPTO_AesSessionKey *rkey,
const void *salt,
- const size_t salt_len,
+ size_t salt_len,
...);
/**
* @param xts_len length of xts
* @param skm source key material
* @param skm_len length of skm
- * @param ctx context info
- * @param ctx_len length of ctx
* @return GNUNET_YES on success
*/
int
*/
struct GNUNET_CRYPTO_RsaPrivateKey *GNUNET_CRYPTO_rsa_key_create (void);
+/**
+ * Decode the private key from the data-format back
+ * to the "normal", internal format.
+ *
+ * @param buf the buffer where the private key data is stored
+ * @param len the length of the data in 'buffer'
+ */
+struct GNUNET_CRYPTO_RsaPrivateKey *
+GNUNET_CRYPTO_rsa_decode_key (const char *buf, uint16_t len);
/**
* Create a new private key by reading it from a file. If the