summaryrefslogtreecommitdiff
path: root/usr.sbin/relayd/relay_http.c
diff options
context:
space:
mode:
Diffstat (limited to 'usr.sbin/relayd/relay_http.c')
-rw-r--r--usr.sbin/relayd/relay_http.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/usr.sbin/relayd/relay_http.c b/usr.sbin/relayd/relay_http.c
index 2bd6952bbeb..3b6f8e84e37 100644
--- a/usr.sbin/relayd/relay_http.c
+++ b/usr.sbin/relayd/relay_http.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: relay_http.c,v 1.67 2017/09/23 11:56:57 bluhm Exp $ */
+/* $OpenBSD: relay_http.c,v 1.68 2017/11/15 19:03:26 benno Exp $ */
/*
* Copyright (c) 2006 - 2016 Reyk Floeter <reyk@openbsd.org>
@@ -187,9 +187,10 @@ relay_read_http(struct bufferevent *bev, void *arg)
/* Limit the total header length minus \r\n */
cre->headerlen += linelen;
- if (cre->headerlen > RELAY_MAXHEADERLENGTH) {
+ if (cre->headerlen > proto->httpheaderlen) {
free(line);
- relay_abort_http(con, 413, "request too large", 0);
+ relay_abort_http(con, 413,
+ "request headers too large", 0);
return;
}