Commit Graph

7 Commits

Author SHA1 Message Date
Neil Booth 8376005fd0 Remove exception for onion peers
Like clearnet peers, they are only returned in server.peers.subscribe
if there was a successful connection.
2017-09-08 17:31:46 +09:00
Neil Booth b196a1bdb9 Fix doc typos 2017-09-08 10:21:46 +09:00
Neil Booth ba4bd79da4 Update PROTOCOL.rst and PEER_DISCOVERY.rst 2017-03-25 13:28:20 +09:00
Neil Booth 1bb8a9d5a4 Implement peer discovery protocol
Closes #104

DEFAULT_PORTS now a coin property
A Peer object maintains peer information
Revamp LocalRPC "peers" call to show a lot more information
Have lib/jsonrpc.py take care of handling request timeouts
Save and restore peers to a file
Loosen JSON RPC rules so we work with electrum-server and beancurd which don't follow the spec.
Handle incoming server.add_peer requests
Send server.add_peer registrations if peer doesn't have us or correct ports
Verify peers at regular intervals, forget stale peers, verify new peers or those with updated ports
If connecting via one port fails, try the other
Add socks.py for SOCKS4 and SOCKS5 proxying, so Tor servers can now be reached by TCP and SSL
Put full licence boilerplate in lib/ files
Disable IRC advertising on testnet
Serve a Tor banner file if it seems like a connection came from your tor proxy (see ENVIONMENT.rst)
Retry tor proxy hourly, and peers that are about to turn stale
Report more onion peers to a connection that seems to be combing from your tor proxy
Only report good peers to server.peers.subscribe; always report self if valid
Handle peers on the wrong network robustly
Default to 127.0.0.1 rather than localhost for Python <= 3.5.2 compatibility
Put peer name in logs of connections to it
Update docs
2017-02-18 12:43:45 +09:00
Neil Booth 0b0a3a8f5b Accept IPv6 addresses in DAEMON_URL
Fixes #126
2017-02-16 08:00:08 +09:00
Neil Booth 3c1ca39a34 Prepare 0.10.14 2017-01-29 08:29:41 +09:00
Neil Booth 8ba176f41c Add peer discovery document 2017-01-29 08:24:18 +09:00