-const char cgisimple_rcs[] = "$Id: cgisimple.c,v 1.77 2008/05/02 09:47:48 fabiankeil Exp $";
+const char cgisimple_rcs[] = "$Id: cgisimple.c,v 1.78 2008/05/03 16:50:11 fabiankeil Exp $";
/*********************************************************************
*
* File : $Source: /cvsroot/ijbswa/current/cgisimple.c,v $
*
* Revisions :
* $Log: cgisimple.c,v $
+ * Revision 1.78 2008/05/03 16:50:11 fabiankeil
+ * Leverage content_filters_enabled() in cgi_show_url_info().
+ *
* Revision 1.77 2008/05/02 09:47:48 fabiankeil
* In cgi_show_url_info, pass an initialized http structure
* to parse_http_url() as that will be required soonish and
}
memset(url_to_query, '\0', sizeof(url_to_query));
- err = parse_http_url(url_param, url_to_query, csp);
+ err = parse_http_url(url_param, url_to_query);
assert(url_to_query->ssl == !strncmp(url_param, "https://", 8));
free(url_param);
-const char urlmatch_rcs[] = "$Id: urlmatch.c,v 1.41 2008/05/02 09:51:34 fabiankeil Exp $";
+const char urlmatch_rcs[] = "$Id: urlmatch.c,v 1.42 2008/05/04 13:24:16 fabiankeil Exp $";
/*********************************************************************
*
* File : $Source: /cvsroot/ijbswa/current/urlmatch.c,v $
*
* Revisions :
* $Log: urlmatch.c,v $
+ * Revision 1.42 2008/05/04 13:24:16 fabiankeil
+ * If the method isn't CONNECT, reject URLs without protocol.
+ *
* Revision 1.41 2008/05/02 09:51:34 fabiankeil
* In parse_http_url(), don't muck around with values
* that are none of its business: require an initialized
* 1 : url = URL (or is it URI?) to break down
* 2 : http = pointer to the http structure to hold elements.
* Must be initialized with valid values (like NULLs).
- * 3 : csp = Current client state (buffers, headers, etc...)
*
* Returns : JB_ERR_OK on success
* JB_ERR_MEMORY on out of memory
* or >100 domains deep.
*
*********************************************************************/
-jb_err parse_http_url(const char * url,
- struct http_request *http,
- const struct client_state *csp)
+jb_err parse_http_url(const char * url, struct http_request *http)
{
int host_available = 1; /* A proxy can dream. */
http->ssl = !strcmpic(v[0], "CONNECT");
- err = parse_http_url(v[1], http, csp);
+ err = parse_http_url(v[1], http);
if (err)
{
freez(buf);
#ifndef URLMATCH_H_INCLUDED
#define URLMATCH_H_INCLUDED
-#define URLMATCH_H_VERSION "$Id: urlmatch.h,v 1.9 2008/04/08 16:07:39 fabiankeil Exp $"
+#define URLMATCH_H_VERSION "$Id: urlmatch.h,v 1.10 2008/04/14 18:11:21 fabiankeil Exp $"
/*********************************************************************
*
* File : $Source: /cvsroot/ijbswa/current/urlmatch.h,v $
*
* Revisions :
* $Log: urlmatch.h,v $
+ * Revision 1.10 2008/04/14 18:11:21 fabiankeil
+ * The compiler might not notice it, but the buffer passed to
+ * create_url_spec() is modified later on and thus shouldn't
+ * be declared immutable.
+ *
* Revision 1.9 2008/04/08 16:07:39 fabiankeil
* Make it harder to mistake url_match()'s
* second parameter for an url_spec.
extern jb_err parse_http_request(const char *req,
struct http_request *http,
const struct client_state *csp);
-extern jb_err parse_http_url(const char * url,
- struct http_request *http,
- const struct client_state *csp);
+extern jb_err parse_http_url(const char *url, struct http_request *http);
extern int url_match(const struct url_spec *pattern,
const struct http_request *http);