Date: Wed, 8 Mar 2006 03:13:01 +0900 (JST) From: Hiroki Sato <hrs@FreeBSD.org> To: FreeBSD-gnats-submit@FreeBSD.org Cc: cperciva@FreeBSD.org Subject: bin/94180: portsnap does not handle HTTP_PROXY_AUTH correctly Message-ID: <200603071813.k27ID1OQ045253@alph.allbsd.org> Resent-Message-ID: <200603071820.k27IK44u049280@freefall.freebsd.org>
next in thread | raw e-mail | index | archive | help
>Number: 94180
>Category: bin
>Synopsis: portsnap does not handle HTTP_PROXY_AUTH correctly
>Confidential: no
>Severity: non-critical
>Priority: high
>Responsible: freebsd-bugs
>State: open
>Quarter:
>Keywords:
>Date-Required:
>Class: sw-bug
>Submitter-Id: current-users
>Arrival-Date: Tue Mar 07 18:20:04 GMT 2006
>Closed-Date:
>Last-Modified:
>Originator: Hiroki Sato
>Release: FreeBSD 6.0-RELEASE i386
>Organization:
Tokyo University of Science
>Environment:
FreeBSD spike2.allbsd.org 6.0-RELEASE FreeBSD 6.0-RELEASE #0: Mon Jan 23 02:16:00 JST 2006 hrs@spike2.allbsd.org:/usr/obj/usr/src/sys/SPIKE2 i386
>Description:
portsnap uses strsep() to get username and password from
HTTP_PROXY_AUTH, but it wrongly assumes ":" character in
the end of the string. This problem is reported by ume@.
>How-To-Repeat:
N/A
>Fix:
Index: phttpget.c
===================================================================
RCS file: /home/ncvs/src/usr.sbin/portsnap/phttpget/phttpget.c,v
retrieving revision 1.8
diff -d -u -I\$OpenBSD:.*\$ -I\$FreeBSD:.*\$ -I\$Id:.*\$ -I\$hrs:.*\$ -r1.8 phttpget.c
--- phttpget.c 27 Jan 2006 14:42:15 -0000 1.8
+++ phttpget.c 7 Mar 2006 17:47:36 -0000
@@ -152,7 +152,7 @@
/* Obtain username and password */
proxy_auth_user = strsep(&env_HTTP_PROXY_AUTH, ":");
- proxy_auth_pass = strsep(&env_HTTP_PROXY_AUTH, ":");
+ proxy_auth_pass = env_HTTP_PROXY_AUTH;
}
if ((proxy_auth_user != NULL) && (proxy_auth_pass != NULL)) {
>Release-Note:
>Audit-Trail:
>Unformatted:
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?200603071813.k27ID1OQ045253>
