keystone
keystone copied to clipboard
Error in assembly of thumb2 instructions(adr/adr.w)
Hi all,
kstool:
kstool thumb "start:; adr r3, start; b #0x129f8;" 0x32f048 --> wrong
start:; adr r3, start; b #0x129f8; = [ af f2 04 03 e3 f4 d5 bc ]
kstool thumb "start:; adr.w r3, start; b #0x129f8;" 0x32f048 --> right
start:; adr.w r3, start; b #0x129f8; = [ af f2 04 03 e3 f4 d4 bc ]
cstool:
cstool thumb "af f2 04 03 e3 f4 d5 bc" 0x32f048
32f048 af f2 04 03 subw r3, pc, #4
32f04c e3 f4 d5 bc b.w #0x129fa ---> wrong
cstool thumb "af f2 04 03 e3 f4 d4 bc" 0x32f048
32f048 af f2 04 03 subw r3, pc, #4
32f04c e3 f4 d4 bc b.w #0x129f8 ----> right
http://aosp.opersys.com/xref/android-10.0.0_r3/xref/cts/hostsidetests/securitybulletin/securityPatch/CVE-2018-9424/poc.cpp