Add Support for Custom HTTP Headers in agent-python via Argument - #55
Open
BrunoTeixeira1996 wants to merge 7 commits into
Open
Add Support for Custom HTTP Headers in agent-python via Argument#55BrunoTeixeira1996 wants to merge 7 commits into
BrunoTeixeira1996 wants to merge 7 commits into
Conversation
Member
|
Thanks for creating this PR, I'll create a review now with some smaller adjustments needed. |
s3inlc
self-requested a review
September 1, 2026 10:18
s3inlc
requested changes
Sep 1, 2026
s3inlc
left a comment
Member
There was a problem hiding this comment.
Can you update the README.md with the output of the --help command to also include the --http-headers flag. Also maybe state in the help text of the flag, how this needs to look like in format.
Member
There was a problem hiding this comment.
There seems to be an issue with these changes. The count does not count since the last tag but probably from the beginning. When I build on this branch, I get s3-python-0.7.3.781 as version (whereas the count should be something around 5-10 since 0.7.3).
… root git describe would fail whenever tags aren't available locally (e.g. a fork with no tags), and the old fallback counted commits since the very first commit instead of since the last release tag, producing bogus version suffixes like 0.7.3.781. Now it fetches tags best-effort and falls back to count=0 (no suffix) if no tag can be found. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com> Claude-Session: https://claude.ai/code/session_0191rVrRZAhzPAwfx1E5sFq7
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Hi guys,
I was using Hashtopolis inside a Docker container inside a VPS, however I wanted to integrated vast.ai to act as my agents and so for that I had to expose the VPS to the internet. That's not good in my opinion as we could get a lot of traffic from people trying to bruteforce the login form.
Knowing this I implemented a Cloud Flare Tunnel exposing port 8080 localy and assigned to a domain of my own - adding to this I also created an access rule that only people with a certain CF header can access that login form, thus making this login form protected.
Everything worked just fine however the agent-python was not prepared to deal with this kind of authentication since the requests being made dont use any kind of authentication mechanism and there's no argumment available to do this right now.
This pull request adds a new flag called
http-headersthat is optional but if used these headers will be used on the Session.py and jsonRequest.py thus making it possible to authenticate in the CF Tunnel and make requests to the Hashtopolis Server.I tested all of this using vast.ai agents and everything worked just fine!
Please tell me if you guys need anything to be changed as I am willing to help
Thanks!