-
Notifications
You must be signed in to change notification settings - Fork 42
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Improvements needed to run /bin/id
from binutils
#93
Comments
Hi Alberto, Syscall 218 is We can probably implement some trivial handlers that make it seem like this syscall (and some related ones like |
After some tests, running
|
I can take care of this
I thought we supported those when
They are described in table 2-27 of Intel Advanced Vector Extensions Programming Reference. I think Maat/sleigh already support them, but we should also set the corresponding flags to 1 in the |
(FYI I also tried enabling the CPU features in
and I didn't investigate further.) |
Ugh - some instructions must still be unsupported by sleigh then. We should check whether updating to latest sleigh would add support for those (see #105), and if not we can write the sleigh spec for missing instructions. |
/bin/id
from binutils
FYI: I renamed the issue since we are actually discussing several issues in here |
With the latest additions from the related PR emulation of |
After some more tests, the last fixes required to properly emulate
Tested with the following snippet: m = MaatEngine(ARCH.X64, OS.LINUX)
m.env.fs.add_real_file("/lib/x86_64-linux-gnu/libnss_files.so.2", "/usr/lib/libnss_files.so.2")
m.env.fs.add_real_file("/etc/nsswitch.conf", "/etc/nsswitch.conf")
m.env.fs.add_real_file("/etc/group", "/etc/group")
m.env.fs.add_real_file("/etc/passwd", "/etc/passwd")
m.load("/bin/id", BIN.ELF64, libdirs=["/lib/x86_64-linux-gnu/"])
m.run() |
* Fix a typo related bug crashing when using virtual_fs (#90) * Map real files into the virtual filesystem (#116) * Add add_real_file() method to FileSystem * Add FileSystem::add_real_file() to python bindings * Add getpid, getuid and geteuid linux syscalls (#93) * Add getrandom linux syscall * Add stubs for gettid, set_tid_address, set_robust_list, rseq and prlimit64 linux syscalls (#93) * Add a note about the need for determinism Co-authored-by: Boyan MILANOV <[email protected]> * Initialise ruid and euid to zero by default * Add getgid, getegid and getgroups linux syscalls (#93) * Set CPU features bits to reach baseline ISA level (#93) * Update set_robust_list, rseq and prlimit64 linux syscalls stubs to return success * Add stubs for rt_sigaction and rt_sigprocmask linux syscalls (#93) * Add stubs for statfs and socket linux syscalls (#93) * Warn user about syscalls not fully emulated * Initialise UID, EUID, GID and EGID to 1000 * Add lseek linux syscall (#93) * Don't use the RLMI_INFINITY token directly * Don't use `INFINITY` token either `INFINITY` is also a C++ macro from `cmath`... Co-authored-by: Boyan-MILANOV <[email protected]>
Hi,
I would like to use
maat
with simple projects but I have troubles running, for instance,id
. My code is the following:and the output is the following
Would it be hard to add the support for the missing system call?
Thanks
The text was updated successfully, but these errors were encountered: