165 lines
5.7 KiB
Text
165 lines
5.7 KiB
Text
NAME=iphone-arm-esil tests
|
|
FILE=bins/mach0/FileDP
|
|
CMDS=<<EOF
|
|
s main
|
|
aei
|
|
aeim
|
|
e asm.emu=true
|
|
e asm.bytes=true
|
|
e asm.emustr=false
|
|
pd 4~!--
|
|
EOF
|
|
EXPECT=<<EOF
|
|
0x000028ec b0402de9 push {r4, r5, r7, lr} ; sp=0x177ff0
|
|
0x000028f0 08708de2 add r7, sp, 8 ; r7=0x177ff8
|
|
0x000028f4 05dd4de2 sub sp, sp, 0x140 ; sp=0x177eb0
|
|
0x000028f8 07d0cde3 bic sp, sp, 7 ; sp=0x177eb0
|
|
EOF
|
|
RUN
|
|
|
|
NAME=iphone-arm-esil pdsf scr.html=true
|
|
FILE=bins/mach0/FileDP
|
|
CMDS=<<EOF
|
|
e scr.html=true
|
|
e asm.flags=false
|
|
s main
|
|
e emu.str=true
|
|
af
|
|
pdsf
|
|
EOF
|
|
EXPECT=<<EOF
|
|
0x00002900 argc<br />0x00002904 argv<br />0x00002918 "alloc"<br />0x00002920 str.alloc<br />0x00002928 bl sym.imp.objc_msgSend<br />0x00002934 "init"<br />0x0000293c str.init<br />0x00002940 bl sym.imp.objc_msgSend<br />0x0000294c "X\x10\x9d\xe5"<br />0x0000295c bl sym.imp.objc_msgSend<br />0x00002970 bl sym.imp.objc_msgSend<br />0x00002998 "Usage: FileDP [-f/-d] [Full path to file/directory] "<br />0x0000299c bl sym.imp.puts<br />0x000029c8 bl sym.imp.strcmp<br />0x000029ec str.stringWithCString:encoding:<br />0x00002a1c bl sym.imp.objc_msgSend<br />0x00002a30 str.fileExistsAtPath:<br />0x00002a38 bl sym.imp.objc_msgSend<br />0x00002a58 str.attributesOfItemAtPath:error:<br />0x00002a64 bl sym.imp.objc_msgSend<br />0x00002a74 str.objectForKey:<br />0x00002a90 bl sym.imp.objc_msgSend<br />0x00002aa4 bl sym.imp.NSLog<br />0x00002ab0 str.File_Not_Found<br />0x00002ab4 bl sym.imp.puts<br />0x00002ad0 str.stringWithCString:encoding:<br />0x00002b00 bl sym.imp.objc_msgSend<br />0x00002b10 str.hasSuffix:<br />0x00002b1c bl sym.imp.objc_msgSend<br />0x00002b38 str.stringByAppendingFormat:<br />0x00002b48 bl sym.imp.objc_msgSend<br />0x00002b5c str.fileExistsAtPath:<br />0x00002b64 bl sym.imp.objc_msgSend<br />0x00002b90 str.enumeratorAtPath:<br />0x00002ba4 bl sym.imp.objc_msgSend<br />0x00002bdc str.countByEnumeratingWithState:objects:count:<br />0x00002c00 bl sym.imp.objc_msgSend<br />0x00002c54 bl sym.imp.objc_enumerationMutation<br />0x00002c98 str.stringByAppendingFormat:<br />0x00002ca0 bl sym.imp.objc_msgSend<br />0x00002cb4 str.attributesOfItemAtPath:error:<br />0x00002cc0 bl sym.imp.objc_msgSend<br />0x00002cd0 str.objectForKey:<br />0x00002cec bl sym.imp.objc_msgSend<br />0x00002cfc str.cstr.file_name_is:_____protection_class:<br />0x00002d04 bl sym.imp.NSLog<br />0x00002d28 str.countByEnumeratingWithState:objects:count:<br />0x00002d50 bl sym.imp.objc_msgSend<br />0x00002d84 str.Directory_Not_found<br />0x00002d88 bl sym.imp.puts<br />0x00002da0 "drain"<br />0x00002dac bl sym.imp.objc_msgSend<br />0x00002dcc bx lr
|
|
EOF
|
|
RUN
|
|
|
|
NAME=iphone-arm-esil pdsf
|
|
FILE=bins/mach0/FileDP
|
|
CMDS=<<EOF
|
|
e asm.flags=false
|
|
s main
|
|
e emu.str=true
|
|
af
|
|
pdsf
|
|
EOF
|
|
EXPECT=<<EOF
|
|
0x00002900 argc
|
|
0x00002904 argv
|
|
0x00002918 "alloc"
|
|
0x00002920 str.alloc
|
|
0x00002928 bl sym.imp.objc_msgSend
|
|
0x00002934 "init"
|
|
0x0000293c str.init
|
|
0x00002940 bl sym.imp.objc_msgSend
|
|
0x0000294c "X\x10\x9d\xe5"
|
|
0x0000295c bl sym.imp.objc_msgSend
|
|
0x00002970 bl sym.imp.objc_msgSend
|
|
0x00002998 "Usage: FileDP [-f/-d] [Full path to file/directory] "
|
|
0x0000299c bl sym.imp.puts
|
|
0x000029c8 bl sym.imp.strcmp
|
|
0x000029ec str.stringWithCString:encoding:
|
|
0x00002a1c bl sym.imp.objc_msgSend
|
|
0x00002a30 str.fileExistsAtPath:
|
|
0x00002a38 bl sym.imp.objc_msgSend
|
|
0x00002a58 str.attributesOfItemAtPath:error:
|
|
0x00002a64 bl sym.imp.objc_msgSend
|
|
0x00002a74 str.objectForKey:
|
|
0x00002a90 bl sym.imp.objc_msgSend
|
|
0x00002aa4 bl sym.imp.NSLog
|
|
0x00002ab0 str.File_Not_Found
|
|
0x00002ab4 bl sym.imp.puts
|
|
0x00002ad0 str.stringWithCString:encoding:
|
|
0x00002b00 bl sym.imp.objc_msgSend
|
|
0x00002b10 str.hasSuffix:
|
|
0x00002b1c bl sym.imp.objc_msgSend
|
|
0x00002b38 str.stringByAppendingFormat:
|
|
0x00002b48 bl sym.imp.objc_msgSend
|
|
0x00002b5c str.fileExistsAtPath:
|
|
0x00002b64 bl sym.imp.objc_msgSend
|
|
0x00002b90 str.enumeratorAtPath:
|
|
0x00002ba4 bl sym.imp.objc_msgSend
|
|
0x00002bdc str.countByEnumeratingWithState:objects:count:
|
|
0x00002c00 bl sym.imp.objc_msgSend
|
|
0x00002c54 bl sym.imp.objc_enumerationMutation
|
|
0x00002c98 str.stringByAppendingFormat:
|
|
0x00002ca0 bl sym.imp.objc_msgSend
|
|
0x00002cb4 str.attributesOfItemAtPath:error:
|
|
0x00002cc0 bl sym.imp.objc_msgSend
|
|
0x00002cd0 str.objectForKey:
|
|
0x00002cec bl sym.imp.objc_msgSend
|
|
0x00002cfc str.cstr.file_name_is:_____protection_class:
|
|
0x00002d04 bl sym.imp.NSLog
|
|
0x00002d28 str.countByEnumeratingWithState:objects:count:
|
|
0x00002d50 bl sym.imp.objc_msgSend
|
|
0x00002d84 str.Directory_Not_found
|
|
0x00002d88 bl sym.imp.puts
|
|
0x00002da0 "drain"
|
|
0x00002dac bl sym.imp.objc_msgSend
|
|
0x00002dcc bx lr
|
|
EOF
|
|
RUN
|
|
|
|
NAME=thumb emulation arm issue
|
|
FILE=bins/mach0/FileDP
|
|
CMDS=<<EOF
|
|
aes
|
|
e asm.bits
|
|
EOF
|
|
EXPECT=<<EOF
|
|
32
|
|
EOF
|
|
RUN
|
|
|
|
NAME=string refs: thumb
|
|
FILE=bins/mach0/test-thumb
|
|
CMDS=<<EOF
|
|
af
|
|
e asm.emu=true
|
|
e emu.str=true
|
|
pdf~?str.string
|
|
EOF
|
|
EXPECT=<<EOF
|
|
6
|
|
EOF
|
|
RUN
|
|
|
|
NAME=string refs: arm32
|
|
FILE=bins/mach0/test-arm32
|
|
CMDS=<<EOF
|
|
af
|
|
e asm.emu=true
|
|
e asm.emustr=true
|
|
pdf~?str.string
|
|
EOF
|
|
EXPECT=<<EOF
|
|
6
|
|
EOF
|
|
RUN
|
|
|
|
NAME=string refs: arm64
|
|
FILE=bins/mach0/test-arm64
|
|
CMDS=<<EOF
|
|
af
|
|
e asm.emu=true
|
|
e asm.emustr=true
|
|
pdf~?str.string
|
|
EOF
|
|
EXPECT=<<EOF
|
|
6
|
|
EOF
|
|
RUN
|
|
|
|
NAME=arm32: thumb
|
|
FILE=bins/mach0/arm32-ofp.lzh
|
|
CMDS=pd 2~?push
|
|
EXPECT=<<EOF
|
|
1
|
|
EOF
|
|
RUN
|
|
|
|
NAME=thumb: arm32
|
|
FILE=bins/mach0/arm16-ofp.lzh
|
|
CMDS=pd 2~?push
|
|
EXPECT=<<EOF
|
|
1
|
|
EOF
|
|
RUN
|