Joey Hess
23438fb80f
move to debug
2016-12-08 15:56:36 -04:00
Joey Hess
af41519126
convert P2P runners from Maybe to Either String
...
So we get some useful error messages when things fail.
This commit was sponsored by Peter Hogg on Patreon.
2016-12-08 15:47:49 -04:00
Joey Hess
f744bd5391
refactor
2016-12-06 15:43:03 -04:00
Joey Hess
b16a1cee4b
plumb peer uuid through to runLocal
...
This will allow updating transfer logs with the uuid.
2016-12-02 15:39:49 -04:00
Joey Hess
881274d021
make remote-daemon able to send and receive objects over tor
...
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.
2016-12-02 13:52:43 -04:00
Joey Hess
3dce6a080e
cleanups
2016-12-01 00:42:01 -04:00
Joey Hess
e714e0f67a
actually check p2p authtokens for tor connections
...
This commit was sponsored by Ethan Aubin.
2016-11-30 16:46:02 -04:00
Joey Hess
2ad3420c19
fix
2016-11-29 15:43:34 -04:00
Joey Hess
3ed8895a09
fix build
2016-11-24 16:36:16 -04:00
Joey Hess
e053f31816
avoid serving more than 10 tor connections at a time
...
Another 10 clients can be accepted and waiting their turn. After that,
start dropping connections.
This is to avoid DOS attacks..
2016-11-21 22:03:29 -04:00
Joey Hess
2da338bb8d
detect EOF on socket and cleanly shutdown the service process
2016-11-21 21:45:56 -04:00
Joey Hess
483dbcdbef
stop cleanly when there's a IO error accessing the Handle
...
All other exceptions are let through, but IO errors accessing the handle
are to be expected, so quietly ignore.
2016-11-21 21:32:51 -04:00
Joey Hess
070fb9e624
Added git-remote-tor-annex, which allows git pull and push to the tor hidden 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.
2016-11-21 17:27:38 -04:00
Joey Hess
9cf9ee73f5
improve p2p protocol implementation
...
Tested it in ghci a little now.
2016-11-20 16:42:18 -04:00
Joey Hess
74691ddf0e
remotedaemon: serve tor hidden service
2016-11-20 15:48:12 -04:00