Class LinuxSyscallResolver
java.lang.Object
com.pnfsoftware.jeb.core.units.code.asm.LinuxSyscallResolver
Generic Linux syscall number-to-name and number-to-routine provider.
-
Method Summary
Modifier and TypeMethodDescriptionstatic LinuxSyscallResolvergetInstance(ProcessorType procType) Retrieve the syscall resolver for a processor type.getName(int syscallNumber) Retrieve a syscall name.getPrototype(int syscallNumber, ITypeManager typeman) Retrieve a syscall prototype from available type libraries.getRoutine(int syscallNumber, ITypeManager typeman) Retrieve a syscall routine from available type libraries.longRetrieve the register ID where the syscall number is storedbooleanisSyscall(IInstruction insn) Indicate is anIInstructionis a syscall.
-
Method Details
-
getInstance
Retrieve the syscall resolver for a processor type.- Parameters:
procType- processor type- Returns:
- resolver instance, or null if the processor type is unsupported
-
isSyscall
Indicate is anIInstructionis a syscall. Only implemented for x86 and ARM families.- Parameters:
insn- instruction to test- Returns:
- true if the instruction is a known syscall, false is the instruction is not a syscall or not managed.
-
getSyscallRegisterId
Retrieve the register ID where the syscall number is stored- Parameters:
insn- syscall instruction- Returns:
- register identifier, or -1 if unsupported
-
getName
Retrieve a syscall name.- Parameters:
syscallNumber- syscall number- Returns:
- syscall name, or null if unknown
-
getPrototype
Retrieve a syscall prototype from available type libraries.- Parameters:
syscallNumber- syscall numbertypeman- type manager- Returns:
- prototype, or null if unavailable
-
getRoutine
Retrieve a syscall routine from available type libraries.- Parameters:
syscallNumber- syscall numbertypeman- type manager- Returns:
- routine, or null if unavailable
-