0
0
mirror of https://github.com/darkk/redsocks.git synced 2025-08-29 13:15:30 +00:00

Log dropped clients when http-proxy reply is too long

This commit is contained in:
Leonid Evdokimov 2016-04-13 01:50:34 +03:00
parent 6804500a0a
commit ec06dc6ad6
2 changed files with 2 additions and 0 deletions

View File

@ -150,6 +150,7 @@ static void httpc_read_cb(struct bufferevent *buffev, void *_arg)
free(line);
}
else if (len >= HTTP_HEAD_WM_HIGH) {
redsocks_log_error(client, LOG_NOTICE, "HTTP Proxy reply is too long, %zu bytes", len);
redsocks_drop_client(client);
dropped = 1;
}

View File

@ -229,6 +229,7 @@ static void httpr_relay_read_cb(struct bufferevent *buffev, void *_arg)
free(line);
}
else if (len >= HTTP_HEAD_WM_HIGH) {
redsocks_log_error(client, LOG_NOTICE, "HTTP Proxy reply is too long, %zu bytes", len);
redsocks_drop_client(client);
dropped = 1;
}