You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The man page specifies that the user-agent set from using -A can also be set by using -H. This leads to misconceptions, because -A will set proxy-header user-agents, and -H will not. I'm proposing a documentation change, based on the following outcomes.
The Test Setup
Simulate a proxy with socat so we can see the requests:
kali# socat - TCP-LISTEN:80,crlf,reuseaddr,fork
Make an https request using curl with a special user-agent:
@bagder thanks for the response. My confusion came from this line:
(HTTP) Specify the User-Agent string to send to the HTTP server. To encode blanks
in the string, surround the string with single quote marks. This can also be set
with the -H, --header option of course.
That made it sound like -A and -H do the same thing, which I realize now is obviously not the case.
EDIT: If this isn't really seen as an issue by the community, feel free to close it. Personally, it just didn't make sense to a few of us that -A and -H had different effects.
They once had the exact same behavior, until we realized that sending -H headers unconditionally to both the server and the proxy has security implications and you may very well decide to send headers to just one of the parties...