]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Reported by Olaf Kirch:
authorhno <>
Thu, 11 Apr 2002 04:09:40 +0000 (04:09 +0000)
committerhno <>
Thu, 11 Apr 2002 04:09:40 +0000 (04:09 +0000)
Possible buffer overflow in make_auth_header

src/cachemgr.cc

index a340bf1f2a684858bed5c9244151c45e035036b7..1f4b131cac9f0a31a0146c773d11cb0e3ccf61e0 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: cachemgr.cc,v 1.90 2001/10/17 20:25:01 hno Exp $
+ * $Id: cachemgr.cc,v 1.91 2002/04/10 22:09:40 hno Exp $
  *
  * DEBUG: section 0     CGI Cache Manager
  * AUTHOR: Duane Wessels
@@ -736,6 +736,7 @@ make_auth_header(const cachemgr_request * req)
 
     str64 = base64_encode(buf);
     l += snprintf(buf, sizeof(buf), "Authorization: Basic %s\r\n", str64);
+    assert(l < sizeof(buf));
     l += snprintf(&buf[l], sizeof(buf) - l,
        "Proxy-Authorization: Basic %s\r\n", str64);
     return buf;