Class EmuLinuxX86SyscallUseropLibrary<T>
java.lang.Object
ghidra.pcode.exec.DefaultPcodeUseropLibrary<T>
ghidra.pcode.exec.AnnotatedPcodeUseropLibrary<T>
ghidra.pcode.emu.sys.AnnotatedEmuSyscallUseropLibrary<T>
ghidra.pcode.emu.unix.AbstractEmuUnixSyscallUseropLibrary<T>
ghidra.pcode.emu.linux.AbstractEmuLinuxSyscallUseropLibrary<T>
ghidra.pcode.emu.linux.EmuLinuxX86SyscallUseropLibrary<T>
- Type Parameters:
T- the type of values processed by the library
- All Implemented Interfaces:
EmuSyscallLibrary<T>, PcodeUseropLibrary<T>
A system call library simulating Linux for x86 (32-bit)
-
Nested Class Summary
Nested classes/interfaces inherited from class AbstractEmuUnixSyscallUseropLibrary
AbstractEmuUnixSyscallUseropLibrary.Errno, AbstractEmuUnixSyscallUseropLibrary.UnixStructuredPartNested classes/interfaces inherited from class AnnotatedEmuSyscallUseropLibrary
AnnotatedEmuSyscallUseropLibrary.EmuSyscall, AnnotatedEmuSyscallUseropLibrary.StructuredPartNested classes/interfaces inherited from class AnnotatedPcodeUseropLibrary
AnnotatedPcodeUseropLibrary.AnnotatedPcodeUseropDefinition<T>, AnnotatedPcodeUseropLibrary.FixedArgsAnnotatedPcodeUseropDefinition<T>, AnnotatedPcodeUseropLibrary.OpExecutor, AnnotatedPcodeUseropLibrary.OpInput, AnnotatedPcodeUseropLibrary.OpLibrary, AnnotatedPcodeUseropLibrary.OpOp, AnnotatedPcodeUseropLibrary.OpOutput, AnnotatedPcodeUseropLibrary.OpState, AnnotatedPcodeUseropLibrary.PcodeUserop, AnnotatedPcodeUseropLibrary.VariadicAnnotatedPcodeUseropDefinition<T>Nested classes/interfaces inherited from interface EmuSyscallLibrary
EmuSyscallLibrary.EmuSyscallDefinition<T>Nested classes/interfaces inherited from interface PcodeUseropLibrary
PcodeUseropLibrary.EmptyPcodeUseropLibrary, PcodeUseropLibrary.PcodeUseropDefinition<T>, PcodeUseropLibrary.PcodeUseropSymbolMap -
Field Summary
FieldsChangeModifier and TypeFieldDescriptionprotected FileDataTypeManagerREMOVEDregEIP() RemovedREMOVEDregEAX() RemovedFields inherited from class AbstractEmuLinuxSyscallUseropLibrary
ERRNOS, O_APPEND, O_CREAT, O_MASK_RDWR, O_RDONLY, O_RDWR, O_TRUNC, O_WRONLYFields inherited from class AbstractEmuUnixSyscallUseropLibrary
closedFds, descriptors, fs, intSize, userFields inherited from class AnnotatedEmuSyscallUseropLibrary
additionalArchives, CACHE_BY_CLASS, cSpec, dtMachineWord, machine, program, SYSCALL_SPACE_NAME, syscallMapFields inherited from class DefaultPcodeUseropLibrary
opsFields inherited from interface EmuSyscallLibrary
FALLBACK_EMU_SYSCALL, SYSCALL_CONVENTION_NAMEFields inherited from interface PcodeUseropLibrary
NIL, SYMBOL_CACHE -
Constructor Summary
ConstructorsChangeConstructorDescriptionEmuLinuxX86SyscallUseropLibrary(PcodeMachine<T> machine, EmuUnixFileSystem<T> fs, Program program) Construct the system call library for Linux-x86EmuLinuxX86SyscallUseropLibrary(PcodeMachine<T> machine, EmuUnixFileSystem<T> fs, Program program, EmuUnixUser user) Construct the system call library for Linux-x86 -
Method Summary
ChangeModifier and TypeMethodDescriptionprotected voidprotected Collection<DataTypeManager> voidswi(PcodeExecutor<T> executor, PcodeUseropLibrary<T> library, Varnode out, int intNo) Implement this to detect and interpret theINT 0x80instruction as the syscall conventionMethods inherited from class AbstractEmuLinuxSyscallUseropLibrary
convertFlags, getErrnoMethods inherited from class AbstractEmuUnixSyscallUseropLibrary
abstract_unix_read, claimFd, createHandle, findFd, lowestFd, newStructuredPart, putDescriptor, releaseFd, unix_close, unix_exit, unix_group_exit, unix_open, unix_read, unix_writeMethods inherited from class AnnotatedEmuSyscallUseropLibrary
getSyscalls, mapAndBindSyscalls, mapAndBindSyscalls, newBoundSyscallMethods inherited from class AnnotatedPcodeUseropLibrary
getMethodLookup, getOperandTypeMethods inherited from class DefaultPcodeUseropLibrary
getUserops, putOpMethods inherited from class Object
clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, waitMethods inherited from interface EmuSyscallLibrary
emu_rt_syscall, emu_syscallMethods inherited from interface PcodeUseropLibrary
compose, compose, getSymbols, getUserops
-
Field Details
-
clib32
-
-
Constructor Details
-
EmuLinuxX86SyscallUseropLibrary
public EmuLinuxX86SyscallUseropLibrary(PcodeMachine<T> machine, EmuUnixFileSystem<T> fs, Program program) Construct the system call library for Linux-x86- Parameters:
machine- the machine emulating the hardwarefs- the file system to export to the user-space programprogram- a program containing syscall definitions and conventions, likely the target program
-
EmuLinuxX86SyscallUseropLibrary
public EmuLinuxX86SyscallUseropLibrary(PcodeMachine<T> machine, EmuUnixFileSystem<T> fs, Program program, EmuUnixUser user) Construct the system call library for Linux-x86- Parameters:
machine- the machine emulating the hardwarefs- the file system to export to the user-space programprogram- a program containing syscall definitions and conventions, likely the target programuser- the "current user" to simulate
-
-
Method Details
-
getAdditionalArchives
- Overrides:
getAdditionalArchivesin classAnnotatedEmuSyscallUseropLibrary<T>
-
disposeAdditionalArchives
protected void disposeAdditionalArchives()- Overrides:
disposeAdditionalArchivesin classAnnotatedEmuSyscallUseropLibrary<T>
-
swi
Implement this to detect and interpret theINT 0x80instruction as the syscall convention- Parameters:
executor- to receive the executorlibrary- to receive the userop library, presumably replete with syscallsout- the output varnodeintNo- the interrupt number
-