-
Notifications
You must be signed in to change notification settings - Fork 32
Update sal, sar and xadd instructions #95
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
Conversation
… to set fs and gs on runtime.
xadd [rsp+rdx-62177877h], rdx
Also update the parity_table so that it is generate at compile time
Maybe I need some update to the algorithm |
Hi, it's not passing this tests: test tests::tests::sc32win_donut It's mainly because a bug in the modifications of: ie, the address 0x4CC230 is changed to 0x8ceca5 ~/s/c/mwemu_pr95 ❯❯❯ cargo run --release -- -f test/elf64lin_static_helloworld.bin -6 -vv -c 28
...
27 0x402a70: mov [rsp+78h],r9
-------
28 0x402a75: mov [4CC230h],rdi
--- console ---
=>r rdi
rdi: 0x7fffffffe280 140737488347776 (linux_static_stack)
=>mn
address=>0x4CC230
map: elf64.bss 0x4c72a0-0x4ccc20 (22912)
=>
28 0x402a75: mov [4CC230h],rdi
thread 'main' panicked at libmwemu/src/maps/mod.rs:142:17:
Writing qword to unmapped region at 0x8ceca5 ~/s/mwemu ❯❯❯ cargo run --release -- -f test/elf64lin_static_helloworld.bin -6 -c 28 -vv
...
27 0x402a70: mov [rsp+78h],r9
-------
28 0x402a75: mov [4CC230h],rdi
--- console ---
=>r rdi
rdi: 0x7fffffffe280 140737488347776 (linux_static_stack)
=>mn
address=>0x4CC230
map: elf64.bss 0x4c72a0-0x4ccc20 (22912)
=>
28 0x402a75: mov [4CC230h],rdi
=>
|
ok thanks I will take a look but for now we can fall back to virtual memory if thing don't work out. |
Hello, this is what is happening with donut shellcode: 121 0x3ea4ac: mov [edx+eax],cl
Writing byte to unmapped region at 0x10022da8c
=>r edx
edx: 0x8f921a56 2408716886
=>r eax
eax: 0x7090c036 1888534582 'SHELL32.dll' (shell32.text)
>>> hex(0x8f921a56+0x7090c036)
'0x10022da8c' set_operand_value on 32bits don't have to write to this address (0x10022da8c) that is not 32bits, the add should give: 0x22da8c Enabling memory trace mode (--memory) on the main branch is calculating: 0x22da8c 121 0x3ea4ac: mov [edx+eax],cl regards. |
awesome!!!! |
This update make change include: