Fix ans_key exchange in recent changes
send_ans_key() was using the wrong in vs. outkeylength to terminate the key being sent, so it was always empty.
This commit is contained in:
parent
7034338bc3
commit
ca5b67111e
1 changed files with 1 additions and 1 deletions
|
@ -172,7 +172,7 @@ bool send_ans_key(node_t *to)
|
|||
// Convert to hexadecimal and send
|
||||
key = alloca(2 * to->inkeylength + 1);
|
||||
bin2hex(to->inkey, key, to->inkeylength);
|
||||
key[to->outkeylength * 2] = '\0';
|
||||
key[to->inkeylength * 2] = '\0';
|
||||
|
||||
return send_request(to->nexthop->connection, "%d %s %s %s %d %d %d %d", ANS_KEY,
|
||||
myself->name, to->name, key,
|
||||
|
|
Loading…
Reference in a new issue