Home / vulnerabilities ipfilter-overflow.txt
Posted on 24 May 2009
Source : packetstormsecurity.org Link
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
[ IPFilter (ippool) 4.1.31 lib/load_http.c buffer overflow ]
Author: Maksymilian Arciemowicz
http://SecurityReason.com/
Date:
- - Dis.: 05.03.2009
- - Pub.: 22.05.2009
CVE: CVE-2009-1476
Risk: Low
Original URL:
http://securityreason.com/achievement_securityalert/62
- --- 0.Description ---
IPFilter is a software package that can be used to provide network
address translation (NAT) or firewall services. To use, it can either be
used as a loadable kernel module or incorporated into your UNIX kernel;
use as a loadable kernel module where possible is highly recommended.
Scripts are provided to install and patch system files, as required.
ippool - user interface to the IPFilter pools
Ippool is used to manage information stored in the IP pools subsystem of
IPFilter. Configuration file information may be parsed and loaded into
the kernel, currently configured pools removed or changed as well as
inspected.
- --- 1. IPFilter (ippool) 4.1.31 lib/load_http.c buffer overflow ---
The main problem exist in lib/load_http.c .
Let's see lib/load_http.c ( char buffer[1024] )
- ---
...
alist_t *
load_http(char *url)
{
int fd, len, left, port, endhdr, removed;
char *s, *t, *u, buffer[1024], *myurl;
alist_t *a, *rtop, *rbot;
struct sockaddr_in sin;
struct hostent *host;
/*
* More than this would just be absurd.
*/
if (strlen(url) > 512) {
fprintf(stderr, "load_http has a URL > 512 bytes?!
");
return NULL;
}
fd = -1;
rtop = NULL;
rbot = NULL;
sprintf(buffer, "GET %s HTTP/1.0
", url);
myurl = strdup(url);
if (myurl == NULL)
goto done;
s = myurl + 7; /* http:// */
t = strchr(s, '/');
if (t == NULL) {
fprintf(stderr, "load_http has a malformed URL '%s'
", url);
free(myurl);
return NULL;
}
*t++ = '