好的,所以我正在尝试使用nasm -f elf final.asm以下方法在汇编中组装一些代码:
xor eax,eax
push eax
push dword(0x75792273)
push dword(0x70742027)
push dword(0x77777875)
push dword(0x20237678)
push dword(0x76727827)
push dword(0x27797175)
push dword(0x75711225)
push dword(0x72747676)
push dword(0x74231476)
push dword(0x70707470)
push dword(0x23247077)
push dword(0x78707822)
push dword(0x24711174)
push dword(0x22707373)
push dword(0x78717974)
push dword(0x75771777)
push dword(0x70777125)
push dword(0x73731472)
push dword(0x71277377)
push dword(0x79251822)
push dword(0x79707478)
push dword(0x78742779)
push dword(0x72727871)
push dword(0x71251475)
push dword(0x27247772)
push dword(0x79757479)
push dword(0x70227071)
push dword(0x77737420)
push dword(0x70251970)
push dword(0x74747127)
push dword(0x23277677)
push dword(0x79712024)
push esp
pop esi
mov edi,esi …Run Code Online (Sandbox Code Playgroud) 在Python Urllib中执行POST而不是GET时遇到问题.我跑3.5.我试图POST到形成字段.
我读到如果数据参数存在,urllib.request.Request将默认为POST.我在https://docs.python.org/3/howto/urllib2.html上看到了这个
我复制这些设置,当我启动wireshark时,我看到的是GET和Never a Post,即使看起来代码正在执行.
这是我的代码:
values = {"field1" : z[2:-1], "Submit":"Save"}
print(values)
data = urllib.parse.urlencode(values)
data = data.encode('utf-8')
print(data)
req = urllib.request.Request("http://www.randomsite.com/myprocessingscript.php", data)
with urllib.request.urlopen(req) as response:
the_page = response.read()
print(the_page)
Run Code Online (Sandbox Code Playgroud)
当我启动wireshark时,这是req行的结果:
GET /myprocessingscript.php HTTP/1.1 Accept-Encoding:identity主机:ec2-52-91-45-113.compute-1.amazonaws.com连接:close User-Agent:Python-urllib/3.5
HTTP/1.1 200 OK日期:2015年10月28日星期三02:47:22 GMT服务器:Apache/2.4.17(Unix)OpenSSL/1.0.1p PHP/5.5.30 mod_perl/2.0.8-dev Perl/v5.16.3 X-Powered-By:PHP/5.5.30内容长度:23连接:关闭内容类型:text/html
没有要处理的帖子数据
另外当我运行脚本时,这是我从print语句得到的:
{'Submit':'save','field1':'hostlab\chris'} b'Submit = Save&field1 = hostlab%5Cchris%5Cr%5Cn'b'no post post data to process'Trackback(最近一次呼叫最后):File "C:\ Users\chris\Desktop\test.py",第20行,time.sleep(random.randint(5,10))
他们正在访问两个Web文件.Index.html和myprocessingscript.php:
Index.html:
<h1>randomsite.com.</h1>
####<p>whoami</p>
<form action="myprocessingscript.php" method="POST">
<input name="field1" type="text" />
<input type="submit" name="submit" value="Save"> …Run Code Online (Sandbox Code Playgroud) 我如何跳转到 intel 汇编语法(x32 和 x64)中的已知内存地址。
我想我已经掌握了 64 位语法。例如,如果在 x64 中我想跳转到位于 的代码0x75767并且我位于0000,我会这样做:
0000: FF 25 01 00 00 00 jmp QWORD PTR [rip+0x75761]
Run Code Online (Sandbox Code Playgroud)
^ 正确吗?我想我可以使用 objdump 将这些字节分解为 x32 指令,objdump.exe -D -Mintel,i386 -b binary -m i386 test.bin结果是:
jmp DWORD PTR 0x75761
Run Code Online (Sandbox Code Playgroud)
然后只需使用clang++.exe -masm=intel -m32 -c test.o将此指令转换为 x32 字节即可,但它显示:
error: invalid operand for instruction
jmp DWORD PTR 0x75761
^
Run Code Online (Sandbox Code Playgroud)
我想避免写入任何寄存器。
我的 x64 jmp 指令正确吗?
我如何在 x32 中完成类似的事情?假设在 x32 中我需要跳转到0x400107并且我在0x400000
我正在调整 Windows 上的运行进程内存。如果我的问题有不准确的地方,请原谅我,我正在学习。
所以让我们说我绝对需要0xc0000140f0在 go的特定内存地址存储一个值。我该怎么做。例如:
package main
import (
"fmt"
"unsafe"
)
func main() {
targetAddress := 0xc0000140f0
loc := (uintptr)(unsafe.Pointer(targetAddress))
p := unsafe.Pointer(loc)
var val int = *((*int)(p))
fmt.Println("Location : ", loc, " Val :", val)
}
Run Code Online (Sandbox Code Playgroud)
这会导致以下错误:
./memory.go:10:33: cannot convert targetAddress (type int) to type unsafe.Pointer
Run Code Online (Sandbox Code Playgroud) 我有以下代码:
#include <stdio.h>
#include <string.h>
int main(void)
{
char buff[50];
int pass = 0;
printf("\n Enter the password : \n");
gets(buff);
char str[80];
strcat(str, "nw");
strcat(str, "ww");
strcat(str, "io");
strcat(str, "oi");
char str2[22];
strcat(str2, "jm");
strcat(str2, "qw");
strcat(str2, "ef");
strcat(str2, "io");
strcat(str2, "nw");
strcat(str2, "ce");
strcat(str2, "or");
strcat(str2, "ww");
strcat(str2, "qf");
strcat(str2, "ej");
strcat(str2, "oi");
if(strcmp(buff, str))
{
/* we sf as df er fd xc yyu er we nm hj ui ty as asd qwe er t yu as …Run Code Online (Sandbox Code Playgroud)