Comments (8)
Nice catch, I can confirm it works with https_proxy
and http_proxy
.
It seems suckit makes https content retrieval and additional http requests for something else.
If I had to guess, there is some code that resolves URLs, which is responsible for the http requests. (I remember some unit test which try to resolve an invalid lwn.net URL and looks for a redirect.)
My public server IP got blocked from scraping a particular website, so I can tell it needs both kinds of proxies to circumvent the block.
For future readers:
For multithreading downloading via proxies to work, the constants MAX_EMPTY_RECEIVES
and SLEEP_MILLIS
may need to be adjusted upwards, otherwise all worker threads exit prematurely: They receive no work in the time interval because of the increased proxy latency.
from suckit.
Reqwest seems to support this. https://docs.rs/reqwest/latest/reqwest/struct.Proxy.html
We could read the environment variable before creating the Downloader
from suckit.
What I find strange, the environment variable is already read and processed somehow:
- the download takes significantly longer with a proxy
- bad proxy strings lead to failed downloads
- running
strings
on the binary shows that the stringshttp_proxy
andHTTP_PROXY
are contained
But, the downloaded page does not show the proxy ip for the ifconfig.me website.
from suckit.
My knowledge on proxy is quite limited but I agree with you, something is not right
from suckit.
From what I read here it should "just works"™
from suckit.
This works for me (with some warning and retry for the proxy connection):
https_proxy=147.135.134.57:9300 suckit https://ifconfig.me
https_proxy=147.135.134.57:9300 suckit http://ifconfig.me
The ip I get is not my real ip
Note that I'm using https_proxy and not http_proxy. If I used your http_proxy with a random https_proxy this is not working. I think that for some reason we are doing https request even when specifying http.
from suckit.
My public server IP got blocked from scraping a particular website
Typical SuckIT
Should we close this?
from suckit.
As far as I am concerned, yes.
Except you want to keep it to open for the multiple proxy feature. This was just an idea, nothing where I would contribute personally.
from suckit.
Related Issues (20)
- Fonts download support
- Quoting issue on charset detection HOT 3
- Unicode handling of --include and --exclude HOT 8
- Give tl a try HOT 1
- Solved: error: linkr 'cc' not found during install HOT 2
- Panic when folder path with dot serves a webpage HOT 3
- Incorrect local URLs on an index_no_slash.html HOT 2
- Failure in name resolution on books.toscrape.com HOT 1
- Fix release cross compilation CI HOT 1
- Only download certain filetypes HOT 1
- Crash with v0.2.0 HOT 3
- Build for riscv64
- Exclude already downloaded file HOT 1
- Make URL Processing optional HOT 3
- Add URLs to depth tree from CSS HOT 4
- Stuck thread on silent connection close HOT 12
- Create issue template
- Resume download for large websites HOT 2
- Moving currently downloaded files and folders HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
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.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from suckit.