mirror of
https://github.com/Grasscutters/mitmproxy.git
synced 2024-11-30 03:14:22 +00:00
Switch to single quotes
This commit is contained in:
parent
dde0ff50a5
commit
b424c1d43f
@ -283,7 +283,7 @@ def copy_as_curl_command(flow):
|
|||||||
|
|
||||||
headerString = ""
|
headerString = ""
|
||||||
for k,v in flow.request.headers:
|
for k,v in flow.request.headers:
|
||||||
headerString += " -H \"" + k + ":" + v + "\" "
|
headerString += " -H '" + k + ":" + v + "' "
|
||||||
|
|
||||||
data = "curl"
|
data = "curl"
|
||||||
|
|
||||||
@ -291,7 +291,7 @@ def copy_as_curl_command(flow):
|
|||||||
data += " -X " + flow.request.method
|
data += " -X " + flow.request.method
|
||||||
|
|
||||||
full_url = flow.request.scheme + "://" + flow.request.host + flow.request.path
|
full_url = flow.request.scheme + "://" + flow.request.host + flow.request.path
|
||||||
data += headerString + " \"" + full_url + "\""
|
data += " " + headerString + "'" + full_url + "'"
|
||||||
|
|
||||||
if flow.request.content != None and flow.request.content != "":
|
if flow.request.content != None and flow.request.content != "":
|
||||||
data += " --data-binary " + "'" + flow.request.content + "'"
|
data += " --data-binary " + "'" + flow.request.content + "'"
|
||||||
|
Loading…
Reference in New Issue
Block a user