]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
Configurable proxy-auth realm string (Bob Franklin)
authorwessels <>
Tue, 4 Aug 1998 01:30:26 +0000 (01:30 +0000)
committerwessels <>
Tue, 4 Aug 1998 01:30:26 +0000 (01:30 +0000)
src/cf.data.pre
src/client_side.cc
src/structs.h

index f3ad1d0ec8be4fc40ca3c6adcada2186d35c639c..1689f62de3b1613dfcd5490c47195e85079f62a6 100644 (file)
@@ -1,6 +1,6 @@
 
 #
-# $Id: cf.data.pre,v 1.93 1998/07/31 00:15:36 wessels Exp $
+# $Id: cf.data.pre,v 1.94 1998/08/03 19:30:26 wessels Exp $
 #
 #
 # SQUID Internet Object Cache  http://squid.nlanr.net/Squid/
@@ -1392,6 +1392,19 @@ DOC_START
        the Squid FAQ (http://squid.nlanr.net/Squid/FAQ/FAQ-10.html).
 DOC_END
 
+NAME: proxy_auth_realm
+TYPE: eol
+DEFAULT: Squid proxy-caching web server
+LOC: Config.proxyAuthRealm
+DOC_START
+       Specifies the realm name which is to be reported to the client for
+       proxy authentication (part of the text the user will see when
+       prompted their username and password).
+
+proxy_auth_realm Squid proxy-caching web server
+DOC_END
+
+
 COMMENT_START
  ADMINISTRATIVE PARAMETERS
  -----------------------------------------------------------------------------
index de70cb2482bc3a965935201ddf8568e4a189809d..72894998b5c2b4a4b2a91385ef570911735141a0 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: client_side.cc,v 1.372 1998/07/31 14:48:13 wessels Exp $
+ * $Id: client_side.cc,v 1.373 1998/08/03 19:30:28 wessels Exp $
  *
  * DEBUG: section 33    Client-side Routines
  * AUTHOR: Duane Wessels
@@ -40,8 +40,7 @@
 #endif
 
 static const char *const crlf = "\r\n";
-static const char *const proxy_auth_challenge =
-"Basic realm=\"Squid proxy-caching web server\"";
+static const char *const proxy_auth_challenge_fmt = "Basic realm=\"%s\"";
 
 #define REQUEST_BUF_SIZE 4096
 #define FAILURE_MODE_TIME 300
@@ -139,7 +138,7 @@ clientConstructProxyAuthReply(clientHttpRequest * http)
     rep = errorBuildReply(err);
     errorStateFree(err);
     /* add Authenticate header */
-    httpHeaderPutStr(&rep->header, HDR_PROXY_AUTHENTICATE, proxy_auth_challenge);
+    httpHeaderPutStrf(&rep->header, HDR_PROXY_AUTHENTICATE, proxy_auth_challenge_fmt, Config.proxyAuthRealm);
     return rep;
 }
 
index 36bf9a24873dbb088e02f88605802e358665e41f..298e609048d71986de9ba7cefbc1a1126278fe87 100644 (file)
@@ -1,6 +1,6 @@
 
 /*
- * $Id: structs.h,v 1.193 1998/07/31 00:15:54 wessels Exp $
+ * $Id: structs.h,v 1.194 1998/08/03 19:30:27 wessels Exp $
  *
  *
  * SQUID Internet Object Cache  http://squid.nlanr.net/Squid/
@@ -370,6 +370,7 @@ struct _SquidConfig {
        acl_access *noCache;
     } accessList;
     acl_deny_info_list *denyInfoList;
+    char *proxyAuthRealm;
     struct {
        size_t list_width;
        int list_wrap;