bagder: curl-www/CVE-2009-0037 curl-7.18.2-CVE-2009-0037.patch, 1.1, 1.2

[email protected] Tue, 03 Mar 2009 10:06:01 +0000
Newsgroups gmane.comp.web.curl.www.cvs
Message-ID <[email protected]>
Update of /cvsroot/curl/curl-www/CVE-2009-0037
In directory labb:/tmp/cvs-serv7581

Modified Files:
	curl-7.18.2-CVE-2009-0037.patch 
Log Message:
updated since it wasn't done correctly - the include/curl part was missing


Index: curl-7.18.2-CVE-2009-0037.patch
===================================================================
RCS file: /cvsroot/curl/curl-www/CVE-2009-0037/curl-7.18.2-CVE-2009-0037.patch,v
retrieving revision 1.1
retrieving revision 1.2
diff -u -d -r1.1 -r1.2
--- curl-7.18.2-CVE-2009-0037.patch	2 Mar 2009 23:06:26 -0000	1.1
+++ curl-7.18.2-CVE-2009-0037.patch	3 Mar 2009 10:05:59 -0000	1.2
@@ -40,6 +40,50 @@
  .IP CURLOPT_UNRESTRICTED_AUTH
  A non-zero parameter tells the library it can continue to send authentication
  (user+password) when following locations, even when hostname changed. This
+diff -X curl/diff-exclude -ru curl-7.18.2/include/curl/curl.h curl-7.18.2-protpatched/include/curl/curl.h
+--- curl-7.18.2/include/curl/curl.h	2008-06-04 17:36:10.000000000 +0200
++++ curl-7.18.2-protpatched/include/curl/curl.h	2009-02-24 10:26:17.000000000 +0100
+@@ -592,6 +592,21 @@
+   CURLFTPMETHOD_LAST       /* not an option, never use */
+ } curl_ftpmethod;
+ 
++/* CURLPROTO_ defines are for the CURLOPT_*PROTOCOLS options */
++#define CURLPROTO_HTTP   (1<<0)
++#define CURLPROTO_HTTPS  (1<<1)
++#define CURLPROTO_FTP    (1<<2)
++#define CURLPROTO_FTPS   (1<<3)
++#define CURLPROTO_SCP    (1<<4)
++#define CURLPROTO_SFTP   (1<<5)
++#define CURLPROTO_TELNET (1<<6)
++#define CURLPROTO_LDAP   (1<<7)
++#define CURLPROTO_LDAPS  (1<<8)
++#define CURLPROTO_DICT   (1<<9)
++#define CURLPROTO_FILE   (1<<10)
++#define CURLPROTO_TFTP   (1<<11)
++#define CURLPROTO_ALL    (~0) /* enable everything */
++
+ /* long may be 32 or 64 bits, but we should never depend on anything else
+    but 32 */
+ #define CURLOPTTYPE_LONG          0
+@@ -1200,6 +1215,18 @@
+   CINIT(SEEKFUNCTION, FUNCTIONPOINT, 167),
+   CINIT(SEEKDATA, OBJECTPOINT, 168),
+ 
++  /* set the bitmask for the protocols that are allowed to be used for the
++     transfer, which thus helps the app which takes URLs from users or other
++     external inputs and want to restrict what protocol(s) to deal
++     with. Defaults to CURLPROTO_ALL. */
++  CINIT(PROTOCOLS, LONG, 181),
++
++  /* set the bitmask for the protocols that libcurl is allowed to follow to,
++     as a subset of the CURLOPT_PROTOCOLS ones. That means the protocol needs
++     to be set in both bitmasks to be allowed to get redirected to. Defaults
++     to all protocols except FILE and SCP. */
++  CINIT(REDIR_PROTOCOLS, LONG, 182),
++
+   CURLOPT_LASTENTRY /* the last unused */
+ } CURLoption;
+ 
 diff -X curl/diff-exclude -ru curl-7.18.2/lib/url.c curl-7.18.2-protpatched/lib/url.c
 --- curl-7.18.2/lib/url.c	2008-04-30 23:20:09.000000000 +0200
 +++ curl-7.18.2-protpatched/lib/url.c	2009-02-24 10:30:02.000000000 +0100
@@ -161,3 +205,4 @@
  };
  
  struct Names {
+Only in curl-7.18.2-protpatched/src: curl