Commit Graph

8952 Commits

Author SHA1 Message Date
draoi
36204d3685 channel: deserialize vector, not individual bytes on read_command() 2024-07-23 18:05:21 +02:00
draoi
c699d326a9 doc: update hosts.rs HostColor documentation 2024-07-23 14:56:35 +02:00
draoi
38aa8be3b3 refine_session: clear the darklist once a day
This helps reduce the tradeoff space between a) ensuring all transports
are propagated, even those we do not support b) ensuring hosts shared
around the network are valid.

We assume that a one day period is sufficient for valid hosts to
propagate and enter into non-dark hostlists of a peer that does support
this transport.
2024-07-23 14:54:17 +02:00
draoi
3b0e012126 src: Use peers() instead of channels() method where applicable
The following messages are now only broadcast to peers (inbound/ manual/
outbound session) and not seed or refinery connections:

* EventGraph DAG sync
* OutboundSession `GetAddrs`

The following changes have been made to the p2p API:

* p2p.broadcast() now only sends to peers, not seeds or refine connections.
* p2p.is_connected() only reports peer connections, not all (seed, refinery) connections.
2024-07-23 11:54:05 +02:00
draoi
5e5bca6340 rpc: add SESSION_REFINE to channel matching in p2p_method() 2024-07-23 11:54:05 +02:00
darkfi
df0c938ee4 wallet: fix panic caused by freeing textures/buffers before we updated the draw call. 2024-07-23 11:26:08 +02:00
skoupidi
fa6a4be257 net/hosts: use reference in block_all_ports() 2024-07-22 19:34:51 +03:00
skoupidi
151aa186c4 net/channel: introduced Message pre-serialization for minor optimization of p2p.broadcast() 2024-07-22 19:29:09 +03:00
draoi
d63f675fba net: match on host() instead of host_str() in block_all_ports
This fixes a bug where IPv6 addresses could be truncated in different
ways during the comparison due to the `host_str()` conversion and potentially be treated as different addresses.
2024-07-22 18:21:02 +02:00
draoi
5be7a372e8 hosts: use host() not host_str() method in filter_addresses()
Also add an additional check and print a warning if an external address
enters the hostlist.
2024-07-22 18:21:02 +02:00
draoi
a316bcc84e hosts: make peers() reject both seed and refine session channels 2024-07-22 18:21:02 +02:00
darkfi
17d837ee6c wallet: chatview rendering text 2024-07-22 12:48:36 +02:00
draoi
3b8a685d9c hosts: add peers() method to return channels minus seed connections 2024-07-22 12:04:39 +02:00
draoi
c9a66fdd63 dnet: update urwid version and switch to urwid scroll 2024-07-22 10:39:24 +02:00
draoi
91c890a1fa dnet: enable lilith on/off switching 2024-07-22 09:24:33 +02:00
draoi
25b614fadd dnet: reimplement node dis(connect) handling 2024-07-21 16:39:38 +02:00
draoi
aeb7f8b90a dnet: simplify view.py and improve inbound (dis)connection handling
Stiill TODO:

* re-implement offline nodes comes online, online node goes offline
* update to latest urwid version.
2024-07-21 16:39:38 +02:00
darkfi
d59ea7175f doc: darkirc section run podman in rootless mode as your local user 2024-07-21 11:13:25 +02:00
darkfi
6de436658b darkirc: switch recommendation from docker to podman for android builds 2024-07-21 11:01:18 +02:00
darkfi
4bcb5f9336 book: make it clearer that darkirc is compiled on desktop 2024-07-21 09:22:44 +02:00
skoupidi
cc9d4a87c4 darkirc/darkirc_config: seed fallback torrc onion added 2024-07-20 21:35:00 +03:00
skoupidi
0eb5203671 script/ping: increased timeout 2024-07-20 15:26:38 +03:00
darkfi
f6786f5b0c script: add tor-test util 2024-07-20 12:02:41 +02:00
darkfi
42458d3780 script/ping: allow specifying endpoint using argv 2024-07-20 11:31:03 +02:00
darkfi
53c15245f3 book: s/external_addr/external_addrs/ typo 2024-07-20 11:25:02 +02:00
skoupidi
bca6239af0 chore: updated Cargo.lock 2024-07-19 17:18:35 +03:00
skoupidi
fbcebe5e43 chore: updated some .gitignore files 2024-07-19 16:53:13 +03:00
skoupidi
248ec4e8e6 script/ping: .gitignore added 2024-07-19 16:49:40 +03:00
darkfi
ceced050af Cargo.toml: remove ping from root workspace 2024-07-19 15:17:24 +02:00
darkfi
3b421bb8e3 ping: cleanup and move to script/ 2024-07-19 15:12:39 +02:00
darkfi
69fb1568ed ping: added util to ping seed servers for debugging availability 2024-07-19 15:01:10 +02:00
darkfi
e1d21ebb5d wallet: editbox, draw() means draw, not reload cached draw 2024-07-19 10:13:02 +02:00
darkfi
46de755258 wallet: impl push/pop for viewport changes. end of scope for a drawcall, resets viewport back again nicely 2024-07-19 09:35:58 +02:00
draoi
3b5535a90d inbound_session: explicitly handle failures in setup_channel() 2024-07-18 13:49:04 +02:00
draoi
1b24bfa340 channel: actually stop the channel on main_receive_loop() error
Previously we would return Error::ChannelStopped which triggers
handle_error but doesn't actually explicitly stop the channel. This was
leading inbound session to hang forever on `stop_sub.receive().await`.

Also add some useful debug info to inbound_session.rs.
2024-07-18 13:13:00 +02:00
draoi
1d8ab03f80 refine_session: actually delete greylist entries that fail the handshake 2024-07-18 13:13:00 +02:00
draoi
3359893c30 doc: fix copy paste misprint on seedsync_session 2024-07-18 13:13:00 +02:00
darkfi
58b67fe388 wallet: vastly improve the text atlassing util 2024-07-18 12:58:36 +02:00
darkfi
7588ac5709 book: update instructions for mining with darkfid 2024-07-18 10:23:16 +02:00
dasman
90c7bcb2c4 tau: fix default hostlist path 2024-07-17 18:47:01 +03:00
draoi
4e952746ad chore: make clippy 2024-07-17 16:01:11 +02:00
draoi
4070f482e4 settings: implement Default for BanPolicy 2024-07-17 15:52:39 +02:00
draoi
68b63a76e9 dnet+lilith: rename anchorlist to goldlist 2024-07-17 15:52:39 +02:00
draoi
5cbba48ec4 dnet: fix copy paste error 2024-07-17 15:52:39 +02:00
darkfi
e0a49ba316 zk: sumcheck.sage 2024-07-17 15:16:08 +02:00
draoi
9dd240f13e net+lilith: introduce BanPolicy
We create a new net Setting called BanPolicy that can be Strict or
Relaxed. If it's set to Strict, we ban peers that send messages without
us having a corresponding Dispatcher. If it's set to Relaxed we simply
close the connection.

Lilith is set to Relaxed by default while other peers are set to Strict.
This helps us avoid Lilith blacklisting peers that send messages for
protocols it is not subscribed to.
2024-07-17 14:36:28 +02:00
darkfi
6962bbfd38 tau: assign field already contains @, so it will appear when adding task as @@foo 2024-07-17 14:08:06 +02:00
darkfi
97385aedc3 book: correct LOG_TARGETS format for running node 2024-07-17 13:51:24 +02:00
darkfi
180ec6491d Revert "book: correct output in running node"
This reverts commit 5b70077449.
2024-07-17 12:58:41 +02:00
darkfi
5b70077449 book: correct output in running node 2024-07-17 12:49:09 +02:00