Coder Social home page Coder Social logo

[Feature request] Proxy about website-stalker HOT 13 CLOSED

rEnr3n avatar rEnr3n commented on September 24, 2024
[Feature request] Proxy

from website-stalker.

Comments (13)

b-reich avatar b-reich commented on September 24, 2024 1

It states they are enabled by default and might already work out of the box with the website-stalker.

They were referring to system-wide proxy which I can't use.

i think you could use export https_proxy= for a specific proxy in your shell session

from website-stalker.

rEnr3n avatar rEnr3n commented on September 24, 2024 1

Does not work:
$ http_proxy=socks5://127.0.0.1:1080 ~/Downloads/website-stalker run --all ❌

I have sockd listen on port 1080 and tinyproxy on port 1081.

Confirmed my proxies are working:

$ curl -x socks5://127.0.0.1:1080 icanhazip.com
CORRECT_IP

$ curl -x http://127.0.0.1:1081 icanhazip.com
CORRECT_IP

from website-stalker.

EdJoPaTo avatar EdJoPaTo commented on September 24, 2024

I'm not sure how proxy handling is done. My current understanding is the proxy gets used system-wide and processes simply use the system network which includes the proxy? In that case it would already work but it seems there is something I don't know yet?

from website-stalker.

rEnr3n avatar rEnr3n commented on September 24, 2024

I don't want to use the proxy system-wide. That would interfere with my workflow. I only want to use it for specific commands.

from website-stalker.

EdJoPaTo avatar EdJoPaTo commented on September 24, 2024

I'm not used to using proxies and only know them in theory. I'm not sure how this might be added best.

From looking on reqwest, the HTTP library being used, there is a section on proxies. It states they are enabled by default and might already work out of the box with the website-stalker.
Can you give it a try? If that already works I guess its a nice thing to be added to the readme.

from website-stalker.

b-reich avatar b-reich commented on September 24, 2024

@rEnr3n you could use a PAC as a hacky workaround until this feature is implemented

from website-stalker.

rEnr3n avatar rEnr3n commented on September 24, 2024

It states they are enabled by default and might already work out of the box with the website-stalker.

They were referring to system-wide proxy which I can't use.

from website-stalker.

rEnr3n avatar rEnr3n commented on September 24, 2024

Right 😝. I tested it quickly but it won't work. Running curl icanhazip.com on the same shell gives me the ip address of the proxy though.

from website-stalker.

rEnr3n avatar rEnr3n commented on September 24, 2024

This is what I did:

$ export http_proxy="socks5://127.0.0.1:1080"
$ curl icanhazip.com
<PROXY IP ADDRESS>
$ website-stalker run --all --commit
<TIMEOUT ERROR>
$ export https_proxy="socks5://127.0.0.1:1080"
$ curl icanhazip.com
<REAL IP ADDRESS>
$ website-stalker run --all --commit
<TIMEOUT ERROR>

These are two separate shells btw.

from website-stalker.

EdJoPaTo avatar EdJoPaTo commented on September 24, 2024

Looks like export https_proxy= is behind a feature flag of reqwest. I added that in 3ba2ddb.
If you want to test it out get the latest build from the build artifacts. I'm interested if that already works.

from website-stalker.

rEnr3n avatar rEnr3n commented on September 24, 2024

I have socks proxy on port 1080 and http proxy on 1081.

Works:
$ https_proxy=socks5://127.0.0.1:1080 ~/Downloads/website-stalker run --all βœ”οΈ

Does not work:
$ http_proxy=http://127.0.0.1:1081 ~/Downloads/website-stalker run --all ❌

from website-stalker.

EdJoPaTo avatar EdJoPaTo commented on September 24, 2024

Your second example used http instead of socks5. Does it work with socks5 and the port? Or is the port fixed with socks5?

But it seems like it’s working with the feature flag.

from website-stalker.

EdJoPaTo avatar EdJoPaTo commented on September 24, 2024

As this seems to be working in general (environment variable is picked up and used) I will close this for now. If someone has ideas how to improve things here feel free to comment.

Improvements to the proxy support might also be suggested for reqwest which will end up in this tool.

from website-stalker.

Related Issues (20)

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    πŸ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. πŸ“ŠπŸ“ˆπŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❀️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.