aboutsummaryrefslogtreecommitdiff
path: root/RemoteDaemon/Transport/Tor.hs
Commit message (Collapse)AuthorAge
* add readonly mode to serve P2P protocolGravatar Joey Hess2018-03-07
| | | | | | This will be used by git-annex-shell when configured to be readonly. This commit was sponsored by Nick Daly on Patreon.
* refactorGravatar Joey Hess2018-03-06
|
* Added remote.<name>.annex-push and remote.<name>.annex-pullGravatar Joey Hess2017-04-05
| | | | | | | | | | | | | | | | | | | | | | | | | | | | | | | The former can be useful to make remotes that don't get fully synced with local changes, which comes up in a lot of situations. The latter was mostly added for symmetry, but could be useful (though less likely to be). Implementing `remote.<name>.annex-pull` was a bit tricky, as there's no one place where git-annex pulls/fetches from remotes. I audited all instances of "fetch" and "pull". A few cases were left not checking this config: * Git.Repair can try to pull missing refs from a remote, and if the local repo is corrupted, that seems a reasonable thing to do even though the config would normally prevent it. * Assistant.WebApp.Gpg and Remote.Gcrypt and Remote.Git do fetches as part of the setup process of a remote. The config would probably not be set then, and having the setup fail seems worse than honoring it if it is already set. I have not prevented all the code that does a "merge" from merging branches from remotes with remote.<name>.annex-pull=false. That could perhaps be done, but it would need a way to map from branch name to remote name, and the way refspecs work makes that hard to get really correct. So if the user fetches manually, the git-annex branch will get merged, for example. Anther way of looking at/justifying this is that the setting is called "annex-pull", not "annex-merge". This commit was supported by the NSF-funded DataLad project.
* refactorGravatar Joey Hess2016-12-30
|
* remotedaemon: notice on RELOAD when tor hidden service has been enabledGravatar Joey Hess2016-12-28
| | | | | | and start serving it. This makes the webapp wormhole tor pairing work 100%! This commit was sponsored by Andrea Rota.
* refactorGravatar Joey Hess2016-12-24
|
* Revert "close"Gravatar Joey Hess2016-12-24
| | | | | | This reverts commit 6c089cff615bc44ca94cc4ca77dc69f281dd2ab8. Commit contained incomplete work.
* closeGravatar Joey Hess2016-12-22
|
* include tor-annex in hidden service directory namesGravatar Joey Hess2016-12-21
| | | | | | To make it easier to manage/delete them etc. Backwards compatablity is preserved for existing tor configs.
* relocate tor socket out of /etcGravatar Joey Hess2016-12-20
| | | | | | | | | | | | | weasel explained that apparmor limits on what files tor can read do not apply to sockets (because they're not files). And apparently the problems I was seeing with hidden services not being accessible had to do with onion address propigation and not the location of the socket file. remotedaemon looks up the HiddenServicePort in torrc, so if it was previously configured with the socket in /etc, that will still work. This commit was sponsored by Denis Dzyubenko on Patreon.
* fix build with old stmGravatar Joey Hess2016-12-10
| | | | | | | Old stm lacks isFullTMQueue. To avoid needing to update stm on the Android autobuilder, I switched to a TBMQueue. It never needs to be closed, but the overhead is minimal.
* fix uuid comparisonGravatar Joey Hess2016-12-09
|
* make tor hidden service work when directory watching is not availableGravatar Joey Hess2016-12-09
| | | | Avoid crashing when built w/o inotify..
* bump maxConnections to 100Gravatar Joey Hess2016-12-09
| | | | | | | | | | | 10 seemed too low because more than 10 friends could be linked to a repo over tor, and if all were running the remotedaemon, which makes a persistent connection for change notification, then the 11th friend would not be able to access that repo. 100 might be too low, but it's a much larger group of people. And at that size group, it probably makes sense to structure the network so that 100 peers are not all trying to access one central node.
* remotedaemon: git change detection over tor hidden serviceGravatar Joey Hess2016-12-09
|
* only start ref change watcher thread once per P2P connectionGravatar Joey Hess2016-12-09
| | | | | | This is more efficient. Note that the peer will get CHANGED messages for all refs changed since the connection opened, even if those changes happened before it sent NOTIFYCHANGE.
* debug on error serving peerGravatar Joey Hess2016-12-09
|
* consistent capsGravatar Joey Hess2016-12-08
|
* move to debugGravatar Joey Hess2016-12-08
|
* convert P2P runners from Maybe to Either StringGravatar Joey Hess2016-12-08
| | | | | | So we get some useful error messages when things fail. This commit was sponsored by Peter Hogg on Patreon.
* refactorGravatar Joey Hess2016-12-06
|
* plumb peer uuid through to runLocalGravatar Joey Hess2016-12-02
| | | | This will allow updating transfer logs with the uuid.
* make remote-daemon able to send and receive objects over torGravatar Joey Hess2016-12-02
| | | | | | | | Each worker thread needs to run in the Annex monad, but the remote-daemon's liftAnnex can only run 1 action at a time. Used Annex.Concurrent to deal with that. P2P.Annex is incomplete as of yet.
* cleanupsGravatar Joey Hess2016-12-01
|
* actually check p2p authtokens for tor connectionsGravatar Joey Hess2016-11-30
| | | | This commit was sponsored by Ethan Aubin.
* fixGravatar Joey Hess2016-11-29
|
* fix buildGravatar Joey Hess2016-11-24
|
* avoid serving more than 10 tor connections at a timeGravatar Joey Hess2016-11-21
| | | | | | | Another 10 clients can be accepted and waiting their turn. After that, start dropping connections. This is to avoid DOS attacks..
* detect EOF on socket and cleanly shutdown the service processGravatar Joey Hess2016-11-21
|
* stop cleanly when there's a IO error accessing the HandleGravatar Joey Hess2016-11-21
| | | | | All other exceptions are let through, but IO errors accessing the handle are to be expected, so quietly ignore.
* Added git-remote-tor-annex, which allows git pull and push to the tor hidden ↵Gravatar Joey Hess2016-11-21
| | | | | | | | | | | service. Almost working, but there's a bug in the relaying. Also, made tor hidden service setup pick a random port, to make it harder to port scan. This commit was sponsored by Boyd Stephen Smith Jr. on Patreon.
* improve p2p protocol implementationGravatar Joey Hess2016-11-20
| | | | Tested it in ghci a little now.
* remotedaemon: serve tor hidden serviceGravatar Joey Hess2016-11-20