1
0
mirror of https://github.com/yarrick/iodine.git synced 2024-11-25 06:26:05 +03:00

client: warn when handshake fails due to BADIP

other parts of the code show the meaningful error message too, but
not at the spot where it happened for me.
This commit is contained in:
rofl0r 2018-12-29 05:25:11 +00:00 committed by Erik Ekman
parent d37ebdaca7
commit 37960ab9dd

View File

@ -1439,6 +1439,9 @@ handshake_login(int dns_fd, int seed)
if (strncmp("LNAK", in, 4) == 0) {
fprintf(stderr, "Bad password\n");
return 1;
} else if (strncmp("BADIP", in, 5) == 0) {
warnx("BADIP: Server rejected sender IP address (maybe iodined -c will help)");
return 1;
} else if (sscanf(in, "%64[^-]-%64[^-]-%d-%d",
server, client, &mtu, &netmask) == 4) {