<?xml version="1.0"?>
<feed xmlns="http://www.w3.org/2005/Atom" xml:lang="en">
	<id>https://www.3dbrew.org/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=EmuAGR</id>
	<title>3dbrew - User contributions [en]</title>
	<link rel="self" type="application/atom+xml" href="https://www.3dbrew.org/w/api.php?action=feedcontributions&amp;feedformat=atom&amp;user=EmuAGR"/>
	<link rel="alternate" type="text/html" href="https://www.3dbrew.org/wiki/Special:Contributions/EmuAGR"/>
	<updated>2026-04-14T19:37:14Z</updated>
	<subtitle>User contributions</subtitle>
	<generator>MediaWiki 1.43.1</generator>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=MAC_Address&amp;diff=17431</id>
		<title>MAC Address</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=MAC_Address&amp;diff=17431"/>
		<updated>2016-05-22T17:59:31Z</updated>

		<summary type="html">&lt;p&gt;EmuAGR: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
== List of known Nintendo MAC prefixes ==&lt;br /&gt;
[http://www.coffer.com/mac_find/?string=Nintendo Vendor/Ethernet/Bluetooth MAC Address Lookup and Search]&lt;br /&gt;
&lt;br /&gt;
== List of known 3DS MAC prefixes ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! MAC prefix&lt;br /&gt;
! Found in model / version (region)&lt;br /&gt;
! Source&lt;br /&gt;
|-&lt;br /&gt;
| 2C:10:C1&lt;br /&gt;
| O3DS / Red (U)&lt;br /&gt;
| [https://gbatemp.net/threads/device-mac-address-survey.365525/#post-4987679 GBAtemp]&lt;br /&gt;
|-&lt;br /&gt;
| 40:D2:8A&lt;br /&gt;
| N3DS XL / Black (U)&lt;br /&gt;
| [[User:Rubik|Rubik]]&lt;br /&gt;
|-&lt;br /&gt;
| 58:BD:A3&lt;br /&gt;
| O3DS / Blue (U) &lt;br /&gt;
| [https://gbatemp.net/threads/device-mac-address-survey.365525/#post-4987679 GBAtemp]&lt;br /&gt;
|-&lt;br /&gt;
| 58:BD:A3&lt;br /&gt;
| O3DS / Zelda: OOT3D (E)&lt;br /&gt;
| [[User:EmuAGR|EmuAGR]]&lt;br /&gt;
|-&lt;br /&gt;
| 9C:E6:35&lt;br /&gt;
| O3DS XL (J)&lt;br /&gt;
| [https://gbatemp.net/threads/device-mac-address-survey.365525/#post-4987679 GBAtemp]&lt;br /&gt;
|-&lt;br /&gt;
| A4:C0:E1&lt;br /&gt;
| O3DS / Blue (E)&lt;br /&gt;
| [[User:EmuAGR|EmuAGR]]&lt;br /&gt;
|-&lt;br /&gt;
| B8:AE:6E&lt;br /&gt;
| O3DS XL / Zelda: Link Between Worlds (U)&lt;br /&gt;
| [https://gbatemp.net/threads/device-mac-address-survey.365525/#post-4987679 GBAtemp]&lt;br /&gt;
|-&lt;br /&gt;
| CC:FB:65&lt;br /&gt;
| N3DS / White (E)&lt;br /&gt;
| [[User:EmuAGR|EmuAGR]]&lt;br /&gt;
|-&lt;br /&gt;
| CC:FB:65&lt;br /&gt;
| N3DS XL / Zelda: Majora&#039;s Mask (E)&lt;br /&gt;
| [[User:EmuAGR|EmuAGR]]&lt;br /&gt;
|-&lt;br /&gt;
| E0:0C:7F&lt;br /&gt;
| O3DS / Zelda: OOT3D (E)&lt;br /&gt;
| [[User:EmuAGR|EmuAGR]]&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>EmuAGR</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=MAC_Address&amp;diff=17429</id>
		<title>MAC Address</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=MAC_Address&amp;diff=17429"/>
		<updated>2016-05-22T13:02:42Z</updated>

		<summary type="html">&lt;p&gt;EmuAGR: /* List of known 3DS MAC prefixes */&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
== List of known Nintendo MAC prefixes ==&lt;br /&gt;
[http://www.coffer.com/mac_find/?string=Nintendo Vendor/Ethernet/Bluetooth MAC Address Lookup and Search]&lt;br /&gt;
&lt;br /&gt;
== List of known 3DS MAC prefixes ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! MAC prefix&lt;br /&gt;
! Found in model / version (region)&lt;br /&gt;
! Source&lt;br /&gt;
|-&lt;br /&gt;
| 2C:10:C1&lt;br /&gt;
| O3DS / Red (U)&lt;br /&gt;
| [https://gbatemp.net/threads/device-mac-address-survey.365525/#post-4987679 GBAtemp]&lt;br /&gt;
|-&lt;br /&gt;
| 58:BD:A3&lt;br /&gt;
| O3DS / Blue (U) &lt;br /&gt;
| [https://gbatemp.net/threads/device-mac-address-survey.365525/#post-4987679 GBAtemp]&lt;br /&gt;
|-&lt;br /&gt;
| 58:BD:A3&lt;br /&gt;
| O3DS / Zelda: OOT3D (E)&lt;br /&gt;
| Own&lt;br /&gt;
|-&lt;br /&gt;
| 9C:E6:35&lt;br /&gt;
| O3DS XL (J)&lt;br /&gt;
| [https://gbatemp.net/threads/device-mac-address-survey.365525/#post-4987679 GBAtemp]&lt;br /&gt;
|-&lt;br /&gt;
| A4:C0:E1&lt;br /&gt;
| O3DS / Blue (E)&lt;br /&gt;
| Own&lt;br /&gt;
|-&lt;br /&gt;
| B8:AE:6E&lt;br /&gt;
| O3DS XL / Zelda: Link Between Worlds (U)&lt;br /&gt;
| [https://gbatemp.net/threads/device-mac-address-survey.365525/#post-4987679 GBAtemp]&lt;br /&gt;
|-&lt;br /&gt;
| CC:FB:65&lt;br /&gt;
| N3DS / White (E)&lt;br /&gt;
| Own&lt;br /&gt;
|-&lt;br /&gt;
| CC:FB:65&lt;br /&gt;
| N3DS XL / Zelda: Majora&#039;s Mask (E)&lt;br /&gt;
| Own&lt;br /&gt;
|-&lt;br /&gt;
| E0:0C:7F&lt;br /&gt;
| O3DS / Zelda: OOT3D (E)&lt;br /&gt;
| Own&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>EmuAGR</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=MAC_Address&amp;diff=17428</id>
		<title>MAC Address</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=MAC_Address&amp;diff=17428"/>
		<updated>2016-05-22T12:58:22Z</updated>

		<summary type="html">&lt;p&gt;EmuAGR: Known 3DS MAC prefixes&lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;&lt;br /&gt;
== List of known Nintendo MAC prefixes ==&lt;br /&gt;
[http://www.coffer.com/mac_find/?string=Nintendo Vendor/Ethernet/Bluetooth MAC Address Lookup and Search]&lt;br /&gt;
&lt;br /&gt;
== List of known 3DS MAC prefixes ==&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
! MAC prefix&lt;br /&gt;
! Found in model / version (region)&lt;br /&gt;
! Source&lt;br /&gt;
|-&lt;br /&gt;
| 2C:10:C1&lt;br /&gt;
| O3DS / Red (U)&lt;br /&gt;
| [https://gbatemp.net/threads/device-mac-address-survey.365525/#post-4987679 GBATemp]&lt;br /&gt;
|-&lt;br /&gt;
| 58:BD:A3&lt;br /&gt;
| O3DS / Blue (U) &lt;br /&gt;
| [https://gbatemp.net/threads/device-mac-address-survey.365525/#post-4987679 GBATemp]&lt;br /&gt;
|-&lt;br /&gt;
| 58:BD:A3&lt;br /&gt;
| O3DS / Zelda: OOT3D (E)&lt;br /&gt;
| Own&lt;br /&gt;
|-&lt;br /&gt;
| 9C:E6:35&lt;br /&gt;
| O3DS XL (J)&lt;br /&gt;
| [https://gbatemp.net/threads/device-mac-address-survey.365525/#post-4987679 GBATemp]&lt;br /&gt;
|-&lt;br /&gt;
| A4:C0:E1&lt;br /&gt;
| O3DS / Blue (E)&lt;br /&gt;
| Own&lt;br /&gt;
|-&lt;br /&gt;
| B8:AE:6E&lt;br /&gt;
| O3DS XL / Zelda: Link Between Worlds (U)&lt;br /&gt;
| [https://gbatemp.net/threads/device-mac-address-survey.365525/#post-4987679 GBATemp]&lt;br /&gt;
|-&lt;br /&gt;
| CC:FB:65&lt;br /&gt;
| N3DS / White (E)&lt;br /&gt;
| Own&lt;br /&gt;
|-&lt;br /&gt;
| CC:FB:65&lt;br /&gt;
| N3DS XL / Zelda: Majora&#039;s Mask (E)&lt;br /&gt;
| Own&lt;br /&gt;
|-&lt;br /&gt;
| E0:0C:7F&lt;br /&gt;
| O3DS / Zelda: OOT3D (E)&lt;br /&gt;
| Own&lt;br /&gt;
|}&lt;/div&gt;</summary>
		<author><name>EmuAGR</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=3DS_Userland_Flaws&amp;diff=15939</id>
		<title>3DS Userland Flaws</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=3DS_Userland_Flaws&amp;diff=15939"/>
		<updated>2016-02-26T11:46:35Z</updated>

		<summary type="html">&lt;p&gt;EmuAGR: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page lists vulnerabilities / exploits for 3DS applications and applets. Exploiting these initially results in ROP, from that ROP one can then for example try exploiting [[3DS_System_Flaws|system]] flaw(s).&lt;br /&gt;
&lt;br /&gt;
=Non-system applications=&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Application name&lt;br /&gt;
!  Summary&lt;br /&gt;
!  Description&lt;br /&gt;
!  Fixed in app/system version&lt;br /&gt;
!  Last app/system version this flaw was checked for&lt;br /&gt;
!  Timeframe info related to this was added to wiki&lt;br /&gt;
!  Timeframe this vuln was discovered&lt;br /&gt;
!  Vuln discovered by&lt;br /&gt;
|-&lt;br /&gt;
| Cubic Ninja&lt;br /&gt;
| Map-data stack smash&lt;br /&gt;
| See [[Ninjhax|here]] regarding Ninjhax.&lt;br /&gt;
| None&lt;br /&gt;
| App: Initial version. System: [[10.4.0-29]].&lt;br /&gt;
| Ninjhax release&lt;br /&gt;
| July 2014&lt;br /&gt;
| [[User:smea|smea]]&lt;br /&gt;
|-&lt;br /&gt;
| The Legend of Zelda: Ocarina of Time 3D&lt;br /&gt;
| UTF-16 name string buffer overflow via unchecked u8 length field&lt;br /&gt;
| The u8 at offset 0x2C in the savefile is the character-length of the UTF-16 string at offset 0x1C. When copying this string, it&#039;s essentially a memory-copy with lenval*2, not a string-copy. This can be used to trigger buffer overflows at various locations depending on the string length.&lt;br /&gt;
* When value is &amp;gt;=0x6E it crashes when saving the saveslot, this causes a stack-smash however it normally crashes before it returns from the function which had the stack-frame overwritten.&lt;br /&gt;
* With value &amp;gt;=0x9A, it crashes via stack-smash in-game once any dialogs are opened(touching buttons on the touch-screen can trigger it too).&lt;br /&gt;
* Length value&amp;gt;=0xCD causes a crash while loading the saveslot, via a heap buffer overflow. This buf-overflow overwrites a heap memchunk following the allocated buffer. When the first 16-bits overwriting that heap memchunk is not the memchunk magic-number(0x7373), the mem-alloc code will just return a NULL ptr which later results in a crash. When the magic-number is valid, the mem-alloc code will continue to attempt to parse the memchunk, which may crash depending on the data which overwrote the memchunk. This heap code is separate from the CTRSDK heap code. Exploiting this doesn&#039;t seem to be possible: since the heap code actually verifies that the magic-number for the next/prev memchunk ptrs are correct(unlike CTRSDK), it&#039;s not possible to change those ptrs to useful arbitrary addresses outside of savedata(like with triggering a write to a c++ object ptr which later is used with a vtable func-call, this is what one would do with CTRSDK heap here).&lt;br /&gt;
&lt;br /&gt;
On March 11, 2015, an exploit using this vuln was released, that one was intended for warez/etc. The following exploit wasn&#039;t released before then mainly because doing so would (presumably) result in the vuln being fixed. The following old exploit was released on March 14, 2015: [https://github.com/yellows8/oot3dhax].&lt;br /&gt;
| None&lt;br /&gt;
| App: Initial version. System: [[10.6.0-31]].&lt;br /&gt;
| March 11, 2015&lt;br /&gt;
| Around October 22, 2012&lt;br /&gt;
| [[User:Yellows8|Yellows8]]&lt;br /&gt;
|-&lt;br /&gt;
| Super Smash Bros 3DS&lt;br /&gt;
| Buffer overflow in local-multiplayer beacon handling.&lt;br /&gt;
| See [[smashbroshax|here]].&lt;br /&gt;
| None&lt;br /&gt;
| See [[smashbroshax|here]]. System: [[10.3.0-28]].&lt;br /&gt;
| Time of exploit release.&lt;br /&gt;
| See [[smashbroshax|here]].&lt;br /&gt;
| [[User:Yellows8|Yellows8]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Useless crashes / applications which were fuzzed==&lt;br /&gt;
* Pushmo (3DSWare), QR codes: level name is properly limited to 16 characters, game doesn&#039;t crash with a longer name. The only possible crashes are triggered by out-of-bounds array index values, these crashes are not exploitable due to the index value being 8bit.&lt;br /&gt;
&lt;br /&gt;
* Pyramids (3DSWare), QR codes: no strings. Only crashes are from out-of-bounds values (like background ID) and are not exploitable.&lt;br /&gt;
&lt;br /&gt;
* [https://github.com/yellows8/mm3d_re The Legend of Zelda: Majora&#039;s Mask 3D]&lt;br /&gt;
&lt;br /&gt;
* &amp;quot;The Legend of Zelda: A Link Between Worlds&amp;quot; and &amp;quot;The Legend of Zelda: Tri Force Heroes&amp;quot;: these games don&#039;t crash at all when the entire save-file(minus constant header data) is overwritten with /dev/random output / 0xFF-bytes. All of the CRC32s were updated for this of course.&lt;br /&gt;
&lt;br /&gt;
* Disney Infinity crashes when all savedata overwritten with /dev/urandom. No checksums. 0xFF bytes don&#039;t cause a crash.&lt;br /&gt;
&lt;br /&gt;
=System applications=&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Summary&lt;br /&gt;
!  Description&lt;br /&gt;
!  Fixed in version&lt;br /&gt;
!  Last version this flaw was checked for&lt;br /&gt;
!  Timeframe this was discovered&lt;br /&gt;
!  Discovered by&lt;br /&gt;
|-&lt;br /&gt;
| 3DS [[System Settings]] DS profile string stack-smash&lt;br /&gt;
| Too long or corrupted strings (01Ah  2   Nickname length in characters     050h  2   Message length in characters) in the NVRAM DS user settings (System Settings-&amp;gt;Other Settings-&amp;gt;Profile-&amp;gt;Nintendo DS Profile) cause it to crash in 3DS-mode due to a stack-smash. The DSi is not vulnerable to this, DSi launcher(menu) and DSi System Settings will reset the NVRAM user-settings if the length field values are too long(same result as when the CRCs are invalid). TWL_FIRM also resets the NVRAM user-settings when the string-length(s) are too long.&lt;br /&gt;
| [[7.0.0-13]]&lt;br /&gt;
| [[7.0.0-13]]&lt;br /&gt;
| 2012&lt;br /&gt;
| [[User:Ichfly|Ichfly]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=System applets=&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Summary&lt;br /&gt;
!  Description&lt;br /&gt;
!  Fixed in version&lt;br /&gt;
!  Last version this flaw was checked for&lt;br /&gt;
!  Timeframe info related to this was added to wiki&lt;br /&gt;
!  Timeframe this was discovered&lt;br /&gt;
!  Discovered by&lt;br /&gt;
|-&lt;br /&gt;
| [[Home Menu]] [[System_SaveData|NAND-savedata]] Launcher.dat icons&lt;br /&gt;
| The homemenu code processing the titleid list @ launcherdat+8 copies those titleIDs to another buffer, where the offset relative to that buffer is calculated using the corresponding s8/s16 entries. Those two values are not range checked at all. Hence, one can use this to write u64(s) with arbitrary values to before/after this allocated output buffer. See [[Home_Menu|here]] regarding Launcher.dat structure.&lt;br /&gt;
&lt;br /&gt;
This can be exploited(with Launcher.dat loading at startup at least) by using a s16 for the icon entry with value 0xFFEC(-20)(and perhaps more icons with similar s16 values to write multiple u64s). The result is that the u64 value is written to outbuf-0xA0, which overwrites object+0(vtable) and object+4(doesn&#039;t matter here) for an object that gets used a bit after the vulnerable function triggers. The low 32bits of the u64 can then be set to the address of controlled memory(either outbuf in regular heap or the entire launcherdat buffer in linearmem), for use as a fake vtable in order to get control of PC. From there one can begin ROP via vtable funcptrs to do a stack-pivot(r4=objectaddr at the time the above object gets used).&lt;br /&gt;
&lt;br /&gt;
Originally this vuln could only be triggered via Launcher.dat at Home Menu startup, right after Launcher.dat gets loaded + memory gets allocated, once the file-format version code is finished running. Starting with v9.6 this can be triggered when loading layouts from SD extdata as well. The vuln itself triggers before the layout data is written to Launcher.dat, but it doesn&#039;t seem to be possible to overwrite anything which actually gets used before the function which writes Launcher.dat into the layout gets called.&lt;br /&gt;
&lt;br /&gt;
Home Menu has some sort of fail-safe system(or at least on v9.7) when Home Menu crashes due to Launcher.dat(this also applies for other things with Home Menu): after crashing once, Home Menu resets Launcher.dat to a state where it no longer crashes anymore. However, note that any exploits using this which hang/etc without crashing will still brick the system. &#039;&#039;&#039;Hence, attempting anything with this on physnand without hw-nand-access isn&#039;t really recommended.&#039;&#039;&#039;&lt;br /&gt;
| None&lt;br /&gt;
| [[10.3.0-28|10.3.0-X]]&lt;br /&gt;
| &lt;br /&gt;
| May 14, 2015&lt;br /&gt;
| [[User:Yellows8|Yellows8]]&lt;br /&gt;
|-&lt;br /&gt;
| [[Home Menu]] theme-data decompression buffer overflow ([[menuhax|themehax]])&lt;br /&gt;
| The only func-call size parameter used by the theme decompression function is one for the compressed size, none for the decompressed size. The decompressed-size value from the LZ header is used by this function to check when to stop decompressing, but this function itself has nothing to verify the decompressed_size with. The code calling this function does not check or even use the decompressed size from the header either.&lt;br /&gt;
&lt;br /&gt;
This function is separate from the rest of the Home Menu code: the function used for decompressing themes is *only* used for decompressing themes, nothing else. There&#039;s a separate decompression function in Home Menu used for decompressing everything else.&lt;br /&gt;
&lt;br /&gt;
That other decompression function in Home Menu handles decompression size properly(decompressed size check for max buffer size is done by code calling the other function, not in the function itself). Unlike the other function, the theme function supports multiple LZ algorithms, but the one which actually gets used in official themes is the same one supported by the other function anyway.&lt;br /&gt;
&lt;br /&gt;
See also [[menuhax|here]].&lt;br /&gt;
&lt;br /&gt;
With [[10.2.0-28|10.2.0-X]] Home Menu, the only code change was that the following was added right after theme-load and before actual decompression: &amp;quot;if(&amp;lt;get_lzheader_decompressed_size&amp;gt;(compressed_buf) &amp;gt; 0x150000)&amp;lt;exit&amp;gt;;&amp;quot;. This fixed the vuln.&lt;br /&gt;
| [[10.2.0-28|10.2.0-X]]&lt;br /&gt;
| [[10.2.0-28|10.2.0-X]]&lt;br /&gt;
| &lt;br /&gt;
| December 22, 2014&lt;br /&gt;
| [[User:Yellows8|Yellows8]], [[User:Myria|Myria]] independently (~spring 2015)&lt;br /&gt;
|-&lt;br /&gt;
| [[Home Menu]] shuffle body-data buffer overflow ([[menuhax|shufflehax]])&lt;br /&gt;
| See [[menuhax|here]].&lt;br /&gt;
| [[10.6.0-31|10.6.0-X]]&lt;br /&gt;
| [[10.6.0-31|10.6.0-X]]&lt;br /&gt;
| &lt;br /&gt;
| January 3, 2015&lt;br /&gt;
| [[User:Yellows8|Yellows8]]&lt;br /&gt;
|-&lt;br /&gt;
| Webkit/web-browser bugs&lt;br /&gt;
| spider has had at least three different code-execution exploits. Majority of them are use-after-free issues. See also [[browserhax|here]].&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| 2013?&lt;br /&gt;
| A lot of people.&lt;br /&gt;
|-&lt;br /&gt;
| Old3DS/New3DS [[Internet_Browser|Browser-version-check]] bypass&lt;br /&gt;
| When the browser-version-check code runs where the savedata for it was never initialized(such as when the user used the &amp;quot;Initialize savedata&amp;quot; option), it will use base_timestamp=0 instead of the timestamp loaded from savedata. This is then used with &amp;quot;if(cur_timestamp - base_timestamp &amp;gt;= &amp;lt;24h timestamp&amp;gt;){Run browser-version-check HTTPS request code}&amp;quot;.&lt;br /&gt;
Hence, if the savedata was just initialized, and if the system datetime is set to before January 2, 2000, the browser-version-check will be skipped. This includes January 1, 2000, 00:00, because that&#039;s the epoch(timestamp value 0x0) used with this timestamp.&lt;br /&gt;
&lt;br /&gt;
See [http://yls8.mtheall.com/3dsbrowserhax.php here] for bypass usage instructions.&lt;br /&gt;
| None&lt;br /&gt;
| [[10.6.0-31|10.6.0-X]]&lt;br /&gt;
| February 25, 2016&lt;br /&gt;
| November 2, 2015 (Exactly one week after the browser version pages were initially updated server-side)&lt;br /&gt;
| [[User:Yellows8|Yellows8]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Useless crashes==&lt;br /&gt;
Old3DS system web-browser:&lt;br /&gt;
* 2^32 characters long string(&#039;&#039;finally&#039;&#039; fixed with v10.6): this is similar to the vulnerability fixed [http://git.chromium.org/gitweb/?p=external/Webkit.git;a=commitdiff;h=ec471f16fbd1f879cb631f9b022fd16acd75f4d4 here], concat-large-strings-crash2.html triggers a crash which is about the same as the one triggered by a 2^32 string. Most of the time this vulnerability will cause a memory page permissions fault, since the WebKit code attempts to copy the string text data to the output buffer located in read-only [[CRO0|CRO]] heap memory. The only difference between a crash triggered by a 2^32 string and the concat-large-strings-crash2.html crash is at the former copies the string data using the original string length(like 1 text character for &amp;quot;x&amp;quot;, 4 for &amp;quot;xxxx&amp;quot;) while the latter attempts to copy &amp;gt;12MB. In some &#039;&#039;very&#039;&#039; rare cases a thread separate from the string data-copy thread will crash, this might be exploitable. However, this is mostly useless since it rarely crashes this way.&lt;br /&gt;
&lt;br /&gt;
* Trying to directly load a page via the browser &amp;quot;URL&amp;quot; option with [https://github.com/yellows8/3ds_browserhax_common webkitdebug] setup, causes a crash to trigger in oss.cro due to an use-after-free being caught with webkitdebug. This is presumably some sort of realloc() issue in the libcurl version used by the &amp;lt;={v10.2-v10.3} browser. This happens with *every* *single* *page* one tries to load via the &amp;quot;URL&amp;quot; option, but not when loading links on the current page, hence this is probably useless. A different use-after-free with realloc triggers with loading any page at all regardless of method too(libcurl probably).&lt;br /&gt;
&lt;br /&gt;
* This WebKit build has &#039;&#039;a lot&#039;&#039; of crash-trigger bugs that only happen with [https://github.com/yellows8/3ds_browserhax_common webkitdebug] completely setup(addr accesses near 0x0), with &#039;&#039;just&#039;&#039; trying to load any page at all.&lt;/div&gt;</summary>
		<author><name>EmuAGR</name></author>
	</entry>
	<entry>
		<id>https://www.3dbrew.org/w/index.php?title=3DS_Userland_Flaws&amp;diff=15938</id>
		<title>3DS Userland Flaws</title>
		<link rel="alternate" type="text/html" href="https://www.3dbrew.org/w/index.php?title=3DS_Userland_Flaws&amp;diff=15938"/>
		<updated>2016-02-26T11:45:56Z</updated>

		<summary type="html">&lt;p&gt;EmuAGR: &lt;/p&gt;
&lt;hr /&gt;
&lt;div&gt;This page lists vulnerabilities / exploits for 3DS applications and applets. Exploiting these initially results in ROP, from that ROP one can then for example try exploiting [[3DS_System_Flaws|system]] flaw(s).&lt;br /&gt;
&lt;br /&gt;
=Non-system applications=&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Application name&lt;br /&gt;
!  Summary&lt;br /&gt;
!  Description&lt;br /&gt;
!  Fixed in app/system version&lt;br /&gt;
!  Last app/system version this flaw was checked for&lt;br /&gt;
!  Timeframe info related to this was added to wiki&lt;br /&gt;
!  Timeframe this vuln was discovered&lt;br /&gt;
!  Vuln discovered by&lt;br /&gt;
|-&lt;br /&gt;
| Cubic Ninja&lt;br /&gt;
| Map-data stack smash&lt;br /&gt;
| See [[Ninjhax|here]] regarding Ninjhax.&lt;br /&gt;
| None&lt;br /&gt;
| App: Initial version. System: [[10.4.0-29]].&lt;br /&gt;
| Ninjhax release&lt;br /&gt;
| July 2014&lt;br /&gt;
| [[User:smea|smea]]&lt;br /&gt;
|-&lt;br /&gt;
| The Legend of Zelda: Ocarina of Time 3D&lt;br /&gt;
| UTF-16 name string buffer overflow via unchecked u8 length field&lt;br /&gt;
| The u8 at offset 0x2C in the savefile is the character-length of the UTF-16 string at offset 0x1C. When copying this string, it&#039;s essentially a memory-copy with lenval*2, not a string-copy. This can be used to trigger buffer overflows at various locations depending on the string length.&lt;br /&gt;
* When value is &amp;gt;=0x6E it crashes when saving the saveslot, this causes a stack-smash however it normally crashes before it returns from the function which had the stack-frame overwritten.&lt;br /&gt;
* With value &amp;gt;=0x9A, it crashes via stack-smash in-game once any dialogs are opened(touching buttons on the touch-screen can trigger it too).&lt;br /&gt;
* Length value&amp;gt;=0xCD causes a crash while loading the saveslot, via a heap buffer overflow. This buf-overflow overwrites a heap memchunk following the allocated buffer. When the first 16-bits overwriting that heap memchunk is not the memchunk magic-number(0x7373), the mem-alloc code will just return a NULL ptr which later results in a crash. When the magic-number is valid, the mem-alloc code will continue to attempt to parse the memchunk, which may crash depending on the data which overwrote the memchunk. This heap code is separate from the CTRSDK heap code. Exploiting this doesn&#039;t seem to be possible: since the heap code actually verifies that the magic-number for the next/prev memchunk ptrs are correct(unlike CTRSDK), it&#039;s not possible to change those ptrs to useful arbitrary addresses outside of savedata(like with triggering a write to a c++ object ptr which later is used with a vtable func-call, this is what one would do with CTRSDK heap here).&lt;br /&gt;
&lt;br /&gt;
On March 11, 2015, an exploit using this vuln was released, that one was intended for warez/etc. The following exploit wasn&#039;t released before then mainly because doing so would (presumably) result in the vuln being fixed. The following old exploit was released on March 14, 2015: [https://github.com/yellows8/oot3dhax].&lt;br /&gt;
| None&lt;br /&gt;
| App: Initial version. System: [[10.6.0-29]].&lt;br /&gt;
| March 11, 2015&lt;br /&gt;
| Around October 22, 2012&lt;br /&gt;
| [[User:Yellows8|Yellows8]]&lt;br /&gt;
|-&lt;br /&gt;
| Super Smash Bros 3DS&lt;br /&gt;
| Buffer overflow in local-multiplayer beacon handling.&lt;br /&gt;
| See [[smashbroshax|here]].&lt;br /&gt;
| None&lt;br /&gt;
| See [[smashbroshax|here]]. System: [[10.3.0-28]].&lt;br /&gt;
| Time of exploit release.&lt;br /&gt;
| See [[smashbroshax|here]].&lt;br /&gt;
| [[User:Yellows8|Yellows8]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Useless crashes / applications which were fuzzed==&lt;br /&gt;
* Pushmo (3DSWare), QR codes: level name is properly limited to 16 characters, game doesn&#039;t crash with a longer name. The only possible crashes are triggered by out-of-bounds array index values, these crashes are not exploitable due to the index value being 8bit.&lt;br /&gt;
&lt;br /&gt;
* Pyramids (3DSWare), QR codes: no strings. Only crashes are from out-of-bounds values (like background ID) and are not exploitable.&lt;br /&gt;
&lt;br /&gt;
* [https://github.com/yellows8/mm3d_re The Legend of Zelda: Majora&#039;s Mask 3D]&lt;br /&gt;
&lt;br /&gt;
* &amp;quot;The Legend of Zelda: A Link Between Worlds&amp;quot; and &amp;quot;The Legend of Zelda: Tri Force Heroes&amp;quot;: these games don&#039;t crash at all when the entire save-file(minus constant header data) is overwritten with /dev/random output / 0xFF-bytes. All of the CRC32s were updated for this of course.&lt;br /&gt;
&lt;br /&gt;
* Disney Infinity crashes when all savedata overwritten with /dev/urandom. No checksums. 0xFF bytes don&#039;t cause a crash.&lt;br /&gt;
&lt;br /&gt;
=System applications=&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Summary&lt;br /&gt;
!  Description&lt;br /&gt;
!  Fixed in version&lt;br /&gt;
!  Last version this flaw was checked for&lt;br /&gt;
!  Timeframe this was discovered&lt;br /&gt;
!  Discovered by&lt;br /&gt;
|-&lt;br /&gt;
| 3DS [[System Settings]] DS profile string stack-smash&lt;br /&gt;
| Too long or corrupted strings (01Ah  2   Nickname length in characters     050h  2   Message length in characters) in the NVRAM DS user settings (System Settings-&amp;gt;Other Settings-&amp;gt;Profile-&amp;gt;Nintendo DS Profile) cause it to crash in 3DS-mode due to a stack-smash. The DSi is not vulnerable to this, DSi launcher(menu) and DSi System Settings will reset the NVRAM user-settings if the length field values are too long(same result as when the CRCs are invalid). TWL_FIRM also resets the NVRAM user-settings when the string-length(s) are too long.&lt;br /&gt;
| [[7.0.0-13]]&lt;br /&gt;
| [[7.0.0-13]]&lt;br /&gt;
| 2012&lt;br /&gt;
| [[User:Ichfly|Ichfly]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
=System applets=&lt;br /&gt;
{| class=&amp;quot;wikitable&amp;quot; border=&amp;quot;1&amp;quot;&lt;br /&gt;
|-&lt;br /&gt;
!  Summary&lt;br /&gt;
!  Description&lt;br /&gt;
!  Fixed in version&lt;br /&gt;
!  Last version this flaw was checked for&lt;br /&gt;
!  Timeframe info related to this was added to wiki&lt;br /&gt;
!  Timeframe this was discovered&lt;br /&gt;
!  Discovered by&lt;br /&gt;
|-&lt;br /&gt;
| [[Home Menu]] [[System_SaveData|NAND-savedata]] Launcher.dat icons&lt;br /&gt;
| The homemenu code processing the titleid list @ launcherdat+8 copies those titleIDs to another buffer, where the offset relative to that buffer is calculated using the corresponding s8/s16 entries. Those two values are not range checked at all. Hence, one can use this to write u64(s) with arbitrary values to before/after this allocated output buffer. See [[Home_Menu|here]] regarding Launcher.dat structure.&lt;br /&gt;
&lt;br /&gt;
This can be exploited(with Launcher.dat loading at startup at least) by using a s16 for the icon entry with value 0xFFEC(-20)(and perhaps more icons with similar s16 values to write multiple u64s). The result is that the u64 value is written to outbuf-0xA0, which overwrites object+0(vtable) and object+4(doesn&#039;t matter here) for an object that gets used a bit after the vulnerable function triggers. The low 32bits of the u64 can then be set to the address of controlled memory(either outbuf in regular heap or the entire launcherdat buffer in linearmem), for use as a fake vtable in order to get control of PC. From there one can begin ROP via vtable funcptrs to do a stack-pivot(r4=objectaddr at the time the above object gets used).&lt;br /&gt;
&lt;br /&gt;
Originally this vuln could only be triggered via Launcher.dat at Home Menu startup, right after Launcher.dat gets loaded + memory gets allocated, once the file-format version code is finished running. Starting with v9.6 this can be triggered when loading layouts from SD extdata as well. The vuln itself triggers before the layout data is written to Launcher.dat, but it doesn&#039;t seem to be possible to overwrite anything which actually gets used before the function which writes Launcher.dat into the layout gets called.&lt;br /&gt;
&lt;br /&gt;
Home Menu has some sort of fail-safe system(or at least on v9.7) when Home Menu crashes due to Launcher.dat(this also applies for other things with Home Menu): after crashing once, Home Menu resets Launcher.dat to a state where it no longer crashes anymore. However, note that any exploits using this which hang/etc without crashing will still brick the system. &#039;&#039;&#039;Hence, attempting anything with this on physnand without hw-nand-access isn&#039;t really recommended.&#039;&#039;&#039;&lt;br /&gt;
| None&lt;br /&gt;
| [[10.3.0-28|10.3.0-X]]&lt;br /&gt;
| &lt;br /&gt;
| May 14, 2015&lt;br /&gt;
| [[User:Yellows8|Yellows8]]&lt;br /&gt;
|-&lt;br /&gt;
| [[Home Menu]] theme-data decompression buffer overflow ([[menuhax|themehax]])&lt;br /&gt;
| The only func-call size parameter used by the theme decompression function is one for the compressed size, none for the decompressed size. The decompressed-size value from the LZ header is used by this function to check when to stop decompressing, but this function itself has nothing to verify the decompressed_size with. The code calling this function does not check or even use the decompressed size from the header either.&lt;br /&gt;
&lt;br /&gt;
This function is separate from the rest of the Home Menu code: the function used for decompressing themes is *only* used for decompressing themes, nothing else. There&#039;s a separate decompression function in Home Menu used for decompressing everything else.&lt;br /&gt;
&lt;br /&gt;
That other decompression function in Home Menu handles decompression size properly(decompressed size check for max buffer size is done by code calling the other function, not in the function itself). Unlike the other function, the theme function supports multiple LZ algorithms, but the one which actually gets used in official themes is the same one supported by the other function anyway.&lt;br /&gt;
&lt;br /&gt;
See also [[menuhax|here]].&lt;br /&gt;
&lt;br /&gt;
With [[10.2.0-28|10.2.0-X]] Home Menu, the only code change was that the following was added right after theme-load and before actual decompression: &amp;quot;if(&amp;lt;get_lzheader_decompressed_size&amp;gt;(compressed_buf) &amp;gt; 0x150000)&amp;lt;exit&amp;gt;;&amp;quot;. This fixed the vuln.&lt;br /&gt;
| [[10.2.0-28|10.2.0-X]]&lt;br /&gt;
| [[10.2.0-28|10.2.0-X]]&lt;br /&gt;
| &lt;br /&gt;
| December 22, 2014&lt;br /&gt;
| [[User:Yellows8|Yellows8]], [[User:Myria|Myria]] independently (~spring 2015)&lt;br /&gt;
|-&lt;br /&gt;
| [[Home Menu]] shuffle body-data buffer overflow ([[menuhax|shufflehax]])&lt;br /&gt;
| See [[menuhax|here]].&lt;br /&gt;
| [[10.6.0-31|10.6.0-X]]&lt;br /&gt;
| [[10.6.0-31|10.6.0-X]]&lt;br /&gt;
| &lt;br /&gt;
| January 3, 2015&lt;br /&gt;
| [[User:Yellows8|Yellows8]]&lt;br /&gt;
|-&lt;br /&gt;
| Webkit/web-browser bugs&lt;br /&gt;
| spider has had at least three different code-execution exploits. Majority of them are use-after-free issues. See also [[browserhax|here]].&lt;br /&gt;
|&lt;br /&gt;
|&lt;br /&gt;
| 2013?&lt;br /&gt;
| A lot of people.&lt;br /&gt;
|-&lt;br /&gt;
| Old3DS/New3DS [[Internet_Browser|Browser-version-check]] bypass&lt;br /&gt;
| When the browser-version-check code runs where the savedata for it was never initialized(such as when the user used the &amp;quot;Initialize savedata&amp;quot; option), it will use base_timestamp=0 instead of the timestamp loaded from savedata. This is then used with &amp;quot;if(cur_timestamp - base_timestamp &amp;gt;= &amp;lt;24h timestamp&amp;gt;){Run browser-version-check HTTPS request code}&amp;quot;.&lt;br /&gt;
Hence, if the savedata was just initialized, and if the system datetime is set to before January 2, 2000, the browser-version-check will be skipped. This includes January 1, 2000, 00:00, because that&#039;s the epoch(timestamp value 0x0) used with this timestamp.&lt;br /&gt;
&lt;br /&gt;
See [http://yls8.mtheall.com/3dsbrowserhax.php here] for bypass usage instructions.&lt;br /&gt;
| None&lt;br /&gt;
| [[10.6.0-31|10.6.0-X]]&lt;br /&gt;
| February 25, 2016&lt;br /&gt;
| November 2, 2015 (Exactly one week after the browser version pages were initially updated server-side)&lt;br /&gt;
| [[User:Yellows8|Yellows8]]&lt;br /&gt;
|}&lt;br /&gt;
&lt;br /&gt;
==Useless crashes==&lt;br /&gt;
Old3DS system web-browser:&lt;br /&gt;
* 2^32 characters long string(&#039;&#039;finally&#039;&#039; fixed with v10.6): this is similar to the vulnerability fixed [http://git.chromium.org/gitweb/?p=external/Webkit.git;a=commitdiff;h=ec471f16fbd1f879cb631f9b022fd16acd75f4d4 here], concat-large-strings-crash2.html triggers a crash which is about the same as the one triggered by a 2^32 string. Most of the time this vulnerability will cause a memory page permissions fault, since the WebKit code attempts to copy the string text data to the output buffer located in read-only [[CRO0|CRO]] heap memory. The only difference between a crash triggered by a 2^32 string and the concat-large-strings-crash2.html crash is at the former copies the string data using the original string length(like 1 text character for &amp;quot;x&amp;quot;, 4 for &amp;quot;xxxx&amp;quot;) while the latter attempts to copy &amp;gt;12MB. In some &#039;&#039;very&#039;&#039; rare cases a thread separate from the string data-copy thread will crash, this might be exploitable. However, this is mostly useless since it rarely crashes this way.&lt;br /&gt;
&lt;br /&gt;
* Trying to directly load a page via the browser &amp;quot;URL&amp;quot; option with [https://github.com/yellows8/3ds_browserhax_common webkitdebug] setup, causes a crash to trigger in oss.cro due to an use-after-free being caught with webkitdebug. This is presumably some sort of realloc() issue in the libcurl version used by the &amp;lt;={v10.2-v10.3} browser. This happens with *every* *single* *page* one tries to load via the &amp;quot;URL&amp;quot; option, but not when loading links on the current page, hence this is probably useless. A different use-after-free with realloc triggers with loading any page at all regardless of method too(libcurl probably).&lt;br /&gt;
&lt;br /&gt;
* This WebKit build has &#039;&#039;a lot&#039;&#039; of crash-trigger bugs that only happen with [https://github.com/yellows8/3ds_browserhax_common webkitdebug] completely setup(addr accesses near 0x0), with &#039;&#039;just&#039;&#039; trying to load any page at all.&lt;/div&gt;</summary>
		<author><name>EmuAGR</name></author>
	</entry>
</feed>