rizin/test/db/rzil/pic
Rot127 b765151015
Port px/ and rename into pxF and alias x to RzShell (#4961)
* Port `px/` to RzShell.

* Escape string before emitting it for psb.

'psb' just emitted the whole string. It ignores the posibility that it might
contain escape sequences which mess up the output.

In the specific case of the fixed test this happened. The invalid string
contained some invalid escape sequences and cut of the output afterwards.

* Rename `px/` to `pxF`
2025-03-07 21:56:34 +08:00

50 lines
858 B
Text

NAME=Testing the decryption in emulateme
FILE=bins/pic/emulateme.pic18f2520.elf
TIMEOUT=30
CMDS=<<EOF
e asm.cpu=highend
e io.cache=1
s loc.__pcinit
aezi
aezsu 0x68e
ps @ seckrit
EOF
EXPECT=<<EOF
Hello from RzIL!
EOF
RUN
NAME=Testing the decryption in emulateme 16F13113
FILE=bins/pic/emulateme.16F13113.elf
TIMEOUT=30
CMDS=<<EOF
e analysis.cpu=midrange
e asm.cpu=midrange
e io.cache=1
om- 1 # cinit
om- 3 # maintext
om- 6 # stringtext1
om- 8 # idataBANK0
aaa
wx 00 @ 0xa
wx 51534d775814515f456c177f6e787f1c0000 @ seckrit # 0x20
wz "AnyColourYouLike" @ obj.main_key # key 0x7c
wx 7c @ obj.decrypt_key
wx 00 @ obj.decrypt_key+1
wx bd @ 0x801
# goto 0x80d
wx 0830 @ 0x82d
wx 8a00 @ 0x82f
wx 0d28 @ 0x831
wx 00 @ 0x9
wx 00 @ 0x3
s sym._decrypt
aezi
aezsu 0x0000082b
psb @ seckrit
EOF
EXPECT=<<EOF
0x00000020 Hello from RzIL!
0x0000007c AnyColourYouLike
EOF
RUN