2020-07-25 2020-07-25 今天试图请求一个raw格式的数据,发现postman给的格式并不正确: 1 2 3 4 5 6 7 8 9 POST /upload/1.php HTTP/1.1 Host: 52.82.121.166:28437 Content-Type: multipart/form-data; boundary=----WebKitFormBoundary7MA4YWxkTrZu0gW ----WebKitFormBoundary7MA4YWxkTrZu0gW Content-Disposition: form-data; name="a" system("ls"); ----WebKitFormBoundary7MA4YWxkTrZu0gW 正确格式应该如下: 1 2 3 4 5 6 7 8 9 POST /upload/1.php HTTP/1.1 Host: 52.82.121.166:28437 Content-Type: multipart/form-data; boundary=----WebKitFormBoundary7MA4YWxkTrZu0gW ------WebKitFormBoundary7MA4YWxkTrZu0gW #这里多两个- Content-Disposition: form-data; name="a" system("ls"); ------WebKitFormBoundary7MA4YWxkTrZu0gW--#这里头部尾部均加两个- 事实上,这种请求并不方便,使用另一种格式更简单: 也就是x-www-form-urlencoded的形式将form编码中url中。 1 2 3 4 5 POST /upload/1.php HTTP/1.1 Host: 52.82.121.166:28437 Content-Type: application/x-www-form-urlencoded a=system("ls"); 前一篇 ctf自动拼图 后一篇 如何实时修改网页的javascript代码
说些什么吧!