-
Notifications
You must be signed in to change notification settings - Fork 40
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Tracker Checker: Support different types of tracker addresses #675
Labels
- Admin -
Enjoyable to Install and Setup our Software
- Developer -
Torrust Improvement Experience
Code Cleanup / Refactoring
Tidying and Making Neat
Enhancement / Feature Request
Something New
Testing
Checking Torrust
Milestone
Comments
josecelano
added
Enhancement / Feature Request
Something New
Code Cleanup / Refactoring
Tidying and Making Neat
- Developer -
Torrust Improvement Experience
- Admin -
Enjoyable to Install and Setup our Software
Testing
Checking Torrust
labels
Feb 2, 2024
josecelano
added a commit
to josecelano/torrust-tracker
that referenced
this issue
Sep 12, 2024
…mats All the following URL for UDP trackers are allow now: ```console TORRUST_CHECKER_CONFIG='{ "udp_trackers": [ "127.0.0.1:6969", "127.0.0.1:6969/", "127.0.0.1:6969/announce", "localhost:6969", "localhost:6969/", "localhost:6969/announce", "udp://127.0.0.1:6969", "udp://127.0.0.1:6969/", "udp://127.0.0.1:6969/announce", "udp://localhost:6969", "udp://localhost:6969/", "udp://localhost:6969/announce" ], "http_trackers": [], "health_checks": [] }' cargo run --bin tracker_checker ``` NOTICE: the client will resolve the domain to a socket address if needed.
josecelano
added a commit
to josecelano/torrust-tracker
that referenced
this issue
Sep 12, 2024
…mats All the following URL for UDP trackers are allow now: ```console TORRUST_CHECKER_CONFIG='{ "udp_trackers": [ "127.0.0.1:6969", "127.0.0.1:6969/", "127.0.0.1:6969/announce", "localhost:6969", "localhost:6969/", "localhost:6969/announce", "udp://127.0.0.1:6969", "udp://127.0.0.1:6969/", "udp://127.0.0.1:6969/announce", "udp://localhost:6969", "udp://localhost:6969/", "udp://localhost:6969/announce" ], "http_trackers": [], "health_checks": [] }' cargo run --bin tracker_checker ``` NOTICE: the client will resolve the domain to a socket address if needed.
josecelano
added a commit
to josecelano/torrust-tracker
that referenced
this issue
Sep 12, 2024
…ice address formats Now it supports a path prefix. It will be remove by the client to build the "scrape" URLs. This type of URL is very common in tracker lists like in https://newtrackon.com/. ```console TORRUST_CHECKER_CONFIG='{ "udp_trackers": [], "http_trackers": [ "http://127.0.0.1:7070", "http://127.0.0.1:7070/", "http://127.0.0.1:7070/announce" ], "health_checks": [] }' cargo run --bin tracker_checker ```
josecelano
added a commit
to josecelano/torrust-tracker
that referenced
this issue
Sep 12, 2024
…ice address formats Now it supports a path prefix. It will be remove by the client to build the "scrape" URLs. This type of URL is very common in tracker lists like in https://newtrackon.com/. ```console TORRUST_CHECKER_CONFIG='{ "udp_trackers": [], "http_trackers": [ "http://127.0.0.1:7070", "http://127.0.0.1:7070/", "http://127.0.0.1:7070/announce" ], "health_checks": [] }' cargo run --bin tracker_checker ```
josecelano
added a commit
that referenced
this issue
Sep 12, 2024
faee02f feat: [#675] tracker checker (HTTP tracker) supports more service address formats (Jose Celano) 520026d feat: [#675] tracker checker supports more service address formats (Jose Celano) Pull request description: ### UDP Trackers All the following URLs for UDP trackers are now allowed: ```console TORRUST_CHECKER_CONFIG='{ "udp_trackers": [ "127.0.0.1:6969", "127.0.0.1:6969/", "127.0.0.1:6969/announce", "localhost:6969", "localhost:6969/", "localhost:6969/announce", "udp://127.0.0.1:6969", "udp://127.0.0.1:6969/", "udp://127.0.0.1:6969/announce", "udp://localhost:6969", "udp://localhost:6969/", "udp://localhost:6969/announce" ], "http_trackers": [], "health_checks": [] }' cargo run --bin tracker_checker ``` **NOTICE:** the client will resolve the domain to an IP address if it's needed. ### HTTP Trackers Now, it supports a path suffix (`/` or `/announce`). It will be removed by the client to build the "scrape" URLs. This type of URL is widespread in tracker lists like https://newtrackon.com/. ```console TORRUST_CHECKER_CONFIG='{ "udp_trackers": [], "http_trackers": [ "http://127.0.0.1:7070", "http://127.0.0.1:7070/", "http://127.0.0.1:7070/announce" ], "health_checks": [] }' cargo run --bin tracker_checker ``` ACKs for top commit: josecelano: ACK faee02f Tree-SHA512: 16f7ada07fc863b03fa40073c020b377188958e53f92a9ef49a81a1d565ab7e55ca6654fa71cf54dde770f85201e72ef08858e14491531ab39381c0c707f1b6f
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Labels
- Admin -
Enjoyable to Install and Setup our Software
- Developer -
Torrust Improvement Experience
Code Cleanup / Refactoring
Tidying and Making Neat
Enhancement / Feature Request
Something New
Testing
Checking Torrust
Parent issue: #669
Currently, you can run the Tracker Checker with this input:
And with some restrictions.
144.126.245.19:6969
without the scheme.http://domain:port
https://domain:port
/
or the/announce
at the end.We should be more flexible and allow these input formats:
UDP URL
Valid:
11.22.33.44
11.22.33.44:6969
11.22.33.44:6969/
udp://11.22.33.44:6969
udp://11.22.33.44:6969/
Also valid but the Tracker Checker makes
scrape
request too:11.22.33.44:6969/announce
udp://11.22.33.44:6969/announce
HTTP URL
Invalid:
tracker.torrust-demo
tracker.torrust-demo:6969
tracker.torrust-demo:6969/
tracker.torrust-demo:6969/announce
Valid:
http://tracker.torrust-demo:6969
http://tracker.torrust-demo:6969/
https://tracker.torrust-demo:6969
https://tracker.torrust-demo:6969/
Also valid but the Tracker Checker makes
scrape
request too:http://tracker.torrust-demo:6969/announce
https://tracker.torrust-demo:6969/announce
NOTES
We allow the suffix
announce
because it's very common to get tracker lists with that suffix.See #650
We should normalize the URL and internally store the canonical one (full URL without path):
http://[domain|ip][:port]
https://[domain|ip][:port]
udp://[domain|ip][:port]
Notice that it might be necessary to resolve the domain to an IP with DNS for the UDP tracker in order to make the request because the
UdpClient
does not accept a URL:It only accepts a socket address. Example:
Finally, we should support URLs for UDP trackers because they could have dynamic IPs.
The text was updated successfully, but these errors were encountered: