NHAS / reverse_ssh

SSH based reverse shell

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

HTTP_PROXY parsing should be more robust

lachlan2k opened this issue · comments

The HTTP_PROXY env variable can take many forms, such as http://my-egress-lad:1234. But, net.Dial is confused as it expects host:port, and this will cause an error.

When trying http_proxy, I suggest that RSSH should:

  • Strip out http://
  • If no port is specified, try both 80, and 8080

This is now on unstable

I like the changes -- perhaps they should also be applied to the --proxy command line flag? It would be great for that to be more versatile (and consistency).

I have to admit it took me a hot second to realise what was was breaking when I was trying to --proxy http://foo previously.

I'll test later to make sure it works for me.

Done