summaryrefslogtreecommitdiff
path: root/src/libsimaka/simaka_crypto.h
diff options
context:
space:
mode:
authorYves-Alexis Perez <corsac@debian.org>2013-01-02 14:18:20 +0100
committerYves-Alexis Perez <corsac@debian.org>2013-01-02 14:18:20 +0100
commit2ea5b8ab2fa64487af984af2162039596a06015a (patch)
tree58f9a4372d6007b33b1fca63ab18b53aa34b090d /src/libsimaka/simaka_crypto.h
parent4e331141b8693e5214b82fdd6c3c6f4fa65eafca (diff)
parentc1343b3278cdf99533b7902744d15969f9d6fdc1 (diff)
downloadvyos-strongswan-2ea5b8ab2fa64487af984af2162039596a06015a.tar.gz
vyos-strongswan-2ea5b8ab2fa64487af984af2162039596a06015a.zip
Merge tag 'upstream/5.0.1'
Upstream version 5.0.1
Diffstat (limited to 'src/libsimaka/simaka_crypto.h')
-rw-r--r--src/libsimaka/simaka_crypto.h18
1 files changed, 11 insertions, 7 deletions
diff --git a/src/libsimaka/simaka_crypto.h b/src/libsimaka/simaka_crypto.h
index d1830e658..c07755865 100644
--- a/src/libsimaka/simaka_crypto.h
+++ b/src/libsimaka/simaka_crypto.h
@@ -62,10 +62,11 @@ struct simaka_crypto_t {
* @param id peer identity
* @param data method specific data
* @param mk chunk receiving allocated master key MK
- * @return allocated MSK value
+ * @param msk chunk receiving allocated MSK
+ * @return TRUE if keys allocated and derived successfully
*/
- chunk_t (*derive_keys_full)(simaka_crypto_t *this, identification_t *id,
- chunk_t data, chunk_t *mk);
+ bool (*derive_keys_full)(simaka_crypto_t *this, identification_t *id,
+ chunk_t data, chunk_t *mk, chunk_t *msk);
/**
* Derive k_encr/k_auth keys from MK using fast reauthentication.
@@ -74,8 +75,9 @@ struct simaka_crypto_t {
* internal crypter/signer instances.
*
* @param mk master key
+ * @return TRUE if keys derived successfully
*/
- void (*derive_keys_reauth)(simaka_crypto_t *this, chunk_t mk);
+ bool (*derive_keys_reauth)(simaka_crypto_t *this, chunk_t mk);
/**
* Derive MSK using fast reauthentication.
@@ -84,10 +86,12 @@ struct simaka_crypto_t {
* @param counter fast reauthentication counter value, network order
* @param nonce_s server generated NONCE_S value
* @param mk master key of last full authentication
+ * @param msk chunk receiving allocated MSK
+ * @return TRUE if MSK allocated and derived successfully
*/
- chunk_t (*derive_keys_reauth_msk)(simaka_crypto_t *this,
- identification_t *id, chunk_t counter,
- chunk_t nonce_s, chunk_t mk);
+ bool (*derive_keys_reauth_msk)(simaka_crypto_t *this,
+ identification_t *id, chunk_t counter,
+ chunk_t nonce_s, chunk_t mk, chunk_t *msk);
/**
* Clear keys (partially) derived.