Skip to content

Fix ARM/Thumb SYS gadget discovery#220

Merged
SweetVishnya merged 1 commit intoJonathanSalwan:masterfrom
jman3323:master
Dec 16, 2025
Merged

Fix ARM/Thumb SYS gadget discovery#220
SweetVishnya merged 1 commit intoJonathanSalwan:masterfrom
jman3323:master

Conversation

@jman3323
Copy link
Contributor

The arm32/thumb regexes for svc instructions were invalid, this fixes them and includes conditional suffixes for arm32 (e.g. svceq and friends). Added big endian versions too while I was there.

For the tests, this finds:

  • 761 for elf-ARMv7-ls
  • 92 for elf-ARMv7-ls --thumb
  • 17 for pe-Windows-ARMv7-Thumb2LE-HelloWorld

Just a note, there's so many for arm32 since only ~1 nibble of the 4-byte instruction matters, so you get all of e.g. svc #0x112233 and svc #anything and so on. The immediate does not matter on default Linux kernels, so these are duplicates, sort of. But at least it's usable.

@SweetVishnya
Copy link
Collaborator

Thank you!

@SweetVishnya SweetVishnya merged commit 4e5d4da into JonathanSalwan:master Dec 16, 2025
1 check passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants