summaryrefslogtreecommitdiffstats
path: root/src/protocol_ec25519_fhmqvc_xsalsa20_poly1305.c
diff options
context:
space:
mode:
authorMatthias Schiffer <mschiffer@universe-factory.net>2012-03-31 18:04:02 +0200
committerMatthias Schiffer <mschiffer@universe-factory.net>2012-03-31 18:04:02 +0200
commit0c82651c30bf543903ca05df4e5b179201353ee1 (patch)
tree8c7d7eb1e2f41b500433b14213dc1532d4a79b0f /src/protocol_ec25519_fhmqvc_xsalsa20_poly1305.c
parent342d63a45a8918e45ddcf6a0b82b2f593f4bde12 (diff)
downloadfastd-0c82651c30bf543903ca05df4e5b179201353ee1.tar
fastd-0c82651c30bf543903ca05df4e5b179201353ee1.zip
Change how handshakes are triggered
Diffstat (limited to 'src/protocol_ec25519_fhmqvc_xsalsa20_poly1305.c')
-rw-r--r--src/protocol_ec25519_fhmqvc_xsalsa20_poly1305.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/src/protocol_ec25519_fhmqvc_xsalsa20_poly1305.c b/src/protocol_ec25519_fhmqvc_xsalsa20_poly1305.c
index df551fb..11edfa2 100644
--- a/src/protocol_ec25519_fhmqvc_xsalsa20_poly1305.c
+++ b/src/protocol_ec25519_fhmqvc_xsalsa20_poly1305.c
@@ -352,7 +352,7 @@ static void establish(fastd_context *ctx, fastd_peer *peer, const fastd_peer_con
crypto_hash_sha256(peer->protocol_state->session.key, hashinput, 5*PUBLICKEYBYTES);
peer->protocol_state->session.valid_till = ctx->now;
- peer->protocol_state->session.valid_till.tv_sec += ctx->conf->rekey;
+ peer->protocol_state->session.valid_till.tv_sec += ctx->conf->key_valid;
peer->protocol_state->session.send_nonce[0] = initiator ? 3 : 2;
peer->protocol_state->session.receive_nonce[0] = initiator ? 0 : 1;