Chromium proxy only https - node.js

I use mac os & chromium 80.0.3987.0 and I have problem with proxy.
When I start for example: ./Chromium --proxy-server=123.123.123.123:8888 and open https page I have proxied IP but when I open http I have my own ip! What's wrong?
How to get proxy on both http & https and return error in other cases to prevent connecting from own IP? I use it also with puppeteer.
http://whatismyip.host/ - no proxy
https://whatismyipaddress.com/ - with proxy

Related

Ngrok - HTTP 400 with virtualhost

I have created a url in ngrok integrated in my webhook of stripe.
But when I call that url, I receive a HTTP 400.
I have a domain name attached to my localhost url: abc.com:port and i have registered that address in my host-file. I executed ngrok like this: ngrok http port which gives me localhost:port.
What might be the issue for it?
See the documentation on how you can "ask ngrok to rewrite the Host header of all tunneled requests to match what your web server expects."
"For example, to route to your local site myapp.dev, you would run:
ngrok http -host-header=myapp.dev 80"

Cannot POST to express server from domain with SSL on it

I have an existing ssl certificate through LetsEncrypt for my domain. On the same server as my site I have an express app running at port :8080. Before adding the SSL to the domain I was able to make requests to http://domainname:8080.com. Now that the domain making the requests is https it obviously can't make those requests. If I instead make requests to https://domainname:8080.com, I get no response and instead get a timeout error.
I have attempted to curl -X -POST on the server manually and it returns (35) gnutls_handshake() failed: The TLS connection was non-properly terminated. If I however run the same command pointing to the non https domain it executes correctly. I also tried installing the https modules for express and pointing it to the same certs I'm using for the domain. For all my effort I cannot get this to work. What am I missing here? I want to make requests to a port on the same server that is serving my app.
Setup a reverse proxy in my nginx site config from the domain to the ip address the express server was running on. This solved all the issues I was having.

Why are HTTP curl/Postman requests to a HTTPS server working? (Node, AWS)

I've set up a HTTPS Node server on AWS EC2 which runs on port 4443 and set up Nginx to redirect requests(port 443).
https.createServer(options, app).listen(4443, function(){
console.log("https server started at port 4443");
});
The HTTPS server is working fine, I get a secure connection on browsers and
curl https://mydomain/apiroute works
Now, when I do
curl http://mydomain/apiroute the requests still work. The same goes for Postman.
I know that I can redirect all HTTP traffic to HTTPS using something like 301 redirects but my question is, why does the server respond to HTTP API calls inspite of there being no "HTTP" server?
Additionally, I use a letsencrypt generated certificate.

Possible to add proxy after TOR exit node?

Can I configure the Tor Browser Bundle so that it becomes an extra hop after the Tor exit node without using special OS such as Whonix?
The Tor Browser Bundle just comes pre-configured to use Tor as a socks proxy so as far as I know, you cannot add an extra HTTP proxy after Tor.
Another alternative to using a special OS would be to use proxychains to chain requests through Tor and then an HTTP proxy. You wouldn't necessarily want or need to use the Tor Browser Bundle for this.
I have Tor running locally on port 9050 so I added these lines to my proxychains.conf file under the [ProxyList] section:
[ProxyList]
# tor
socks5 127.0.0.1 9050
# then chain through http proxy
http 2.3.4.5 80
Then to launch your browser which will proxy through Tor and then the HTTP proxy, run proxychains /usr/bin/firefox
It will cause all connections from the browser to first go through Tor, then through the HTTP proxy.
You should see output similar to this on the command line to know its working:
|S-chain|-<>-127.0.0.1:9050-<>-2.3.4.5:80-<><>-74.125.239.39:443-<><>-OK
127.0.0.1:9050 shows it chained through Tor, then 2.3.4.5:80 is the HTTP proxy, and finally out to the destination 74.125.239.39:4443 (Google).
A note on security, I used firefox browser for the example. You could use Tor browser instead but you will want to make sure its proxy configuration is set not to use a proxy since you're already chaining through Tor via proxychains.
Tor Browser will be a little safer since it won't keep history/cache and its signature much less unique.
Hope that helps.

How do I use HTTPS port on clould9 ide?

I am just running some tests on c9.io - but I am stuck on how to get the HTTPS server to run.
I am using the port given in process.env.PORT which links up to the browser in c9, but there doesn't seem to an HTTPS port. In a local environment I use port 3001 for HTTPS.
The Cloud9 workspaces don't support custom SSL certificates yet so you won't be able to start an HTTPS server from there, but your http server running on 0.0.0.0:8080 will be accessible via both HTTP and HTTPS.

Resources