Commit Graph

237 Commits (a4bd7806b3ee51b64315287da60b235a83decbf0)

Author SHA1 Message Date
dr7ana a5b7a7e35b Deprecate pending_msg_que in favor of libquic internal stream buffers 5 months ago
dr7ana 5469c9beb0 HAPPY NEW YEAR 6 months ago
dr7ana 5be09563fa address parsing of deprecated opts 6 months ago
dr7ana 4437d0b373 re-abstraction for client connections
- pending_conns removed in favor of direct creation of link::Connection objects in link::Endpoint::{service,client}_conn containers
- conn lookup maps removed, they were pointless
6 months ago
dr7ana 9e31300d0f gossip storage, logs 6 months ago
dr7ana 87ae0686d0 rc parsing
- new btdc method used to ensure no junk at the end of our bt data
- DRYed out the RC code
- check inbound bootstraps against all registered routers, not just whitelist
- libquic vbump
6 months ago
dr7ana c71e767511 full mesh proto implementation 6 months ago
dr7ana ef1897c25a Added connection keepalive
- implemented ngtcp2 ping to keep connections alive
- fixed weird lambda captures
- fetch logic
- lets see what happens
6 months ago
dr7ana 575494c3da actually have rid in command registration 6 months ago
dr7ana 08c2c26c29 bootstrap tweaking 6 months ago
dr7ana 6cb2f57abd whatever 6 months ago
dr7ana f2feea74ee Crit logging
- TODO: discuss authentication for nodes connecting to bootstrap seed
- crit log num connected/RC's, conn open/closed, etc
6 months ago
dr7ana d00257b9f0 address parsing
- straightened out setting of public addr and public port in config vs listen ("bind") addr
- fixed small bug in router contact writing and saving
6 months ago
dr7ana cef2ff7782 Local router mode
- Up and running locally, no connections yet
- Next: flip testnet and do the gosh dang thing
6 months ago
dr7ana ed6bd28a35 testnet prep
- redoing link_manager functions again to implement previously ignored review comments on several PRs
- conceptually merging "whitelist_routers" and new "known_{rids,rcs}", s.t. we can completely eliminate white/red/gray/green/etc lists in favor of something that isn't dumb
6 months ago
dr7ana 62c37825b0 testnet prep
- disable reachability testing with config option; required to be done on testnet
- reachability testing pipeline through link_manager executes pings similar to storage server. connection established hook reports successful reachability, while connection closed callback (with non-default error code) reports unsuccessful testing
6 months ago
dr7ana 70e9c1ae25 trust model fetch fails
- bootstrap cooldown implemented with 1min timer in case all bootstraps fail
- set comparison implemented in non-initial and non-bootstrap rc fetching; set comparison in rid fetching is done every fetch
- nodedb get_random functions refactored into conditional/non-conditional methods. Conditional search implements reservoir sampling for one-pass accumulation of n random rcs
6 months ago
dr7ana 91121ea22b pull yourself up by your bootstraps sonny
- initial/subsequent fetching combined for RouterContacts and RouterIDs
- bootstraps fallback implemented and looped into fetch logic
6 months ago
dr7ana 3fc7980691 less synchronous for the subsequent fetches 6 months ago
dr7ana 5fa3c2be87 housekeeping and groundwork, initial commit 6 months ago
Thomas Winget 14b9aa20ee (client) periodically fetch RouterIDs from peers 6 months ago
Thomas Winget 6952e8f705 Add command to fetch RCs from remote node
This command will be called periodically by clients to maintain a list
of RCs of active relay nodes.  It will require another command (future
commit) to fetch the RouterIDs from many nodes and reconcile those so we
have some notion of good-ness of the RCs we're getting; if we get what
seems to be a bad set of RCs (this concept not yet implemented), we will
choose a different relay to fetch RCs from.  These are left as TODOs for
now.
6 months ago
Thomas Winget 5bf520d0f1 minor style/naming changes 6 months ago
Thomas Winget b044622a21 implement new rc gossip logic
Relays will now re-sign and gossip their RCs every 6 hours (minus a
couple random minutes) using the new gossip_rc message.

Removes the old RCGossiper concept
6 months ago
Thomas Winget 27aea62994 Remove find/lookup router
We're removing the notion of find/lookup a singular RC, so this gets rid
of all functions which did that and replaces their usages with something
sensible.
6 months ago
Thomas Winget ad9d0b19c1 remove rc_lookup_handler, relocating useful parts
RC "lookup" is being replaced with "gimme all recently updated RCs".  As
such, doing a lookup on a specific RC is going away, as is network
exploration, so a lot of what RCLookupHandler was doing will no longer
be relevant.  Functionality from it which was kept has moved to NodeDB,
as it makes sense for that functionality to live where the RCs live.
6 months ago
dr7ana af0ac28119 Review fixes + misc fixes 7 months ago
dr7ana fa4471f566 {Remote,Local}RC's
- RemoteRC supplants most of the functionality throughout the code of RouterContact
- Next step will be to sort out CI issues, then see if we can get rid of either LocalRC (and therefore RouterContact entirely)
7 months ago
dr7ana 07271f9ae7 RC refactor layout
- Local and Remote RC's now implemented with discrete functionalities and uses
7 months ago
dr7ana 46ad8d4058 Clang format include sorting + CMake
- includes are now sorted in consistent, logical order; first step in an attempt to fix the tomfoolery (no relation to Tom) brought in by include-what-you-use
- shuffled around some cmake linking to simplify dependency graph
- superfluous files removed
8 months ago
dr7ana e710cfea47 Review commit 8 months ago
dr7ana 0e451db77f Compilation fixes
- almost all errors have been commented out for refactor or already refactored
- committing this prior to sorting out the cmake structure
- upcoming include-what-you-use application
8 months ago
Jason Rhinelander 82c945ca24
Remove RC key rotation
We don't have/want this anymore (and on top of that, we *never* used
it in the first place and it probably didn't even work).
8 months ago
Jason Rhinelander 018d7b4a00
Remove optional relay whitelist disabling
Whitelisting is now always-on for relays.  Disabling the option is never
used and is unsupported/unmaintained (it was, in theory, to allow
lokinet as a separate usage in a non-service-node relay mode, i.e. on a
completely separate network).

Confusingly, the option was enabled by the `[lokid]:enabled` config
parameter.
8 months ago
dr7ana a6f901a3a9 RIP everything 8 months ago
dr7ana 5ccec24470 callsafe
- Added call_get to ev.hpp to queue event loop operations w/ a return value
- de-mutexed NodeDB and made all operations via event loop. Some calls to NodeDB methods (like ::put_if_newer) were wrapped in call->get's, but some weren't. All function bodies were using mutex locks
8 months ago
dr7ana 4ed6a01e02 following up before Tom meeting 8 months ago
dr7ana 1a9f977208 Message method implementation continued
- tons of surrounding stupid refactoring required
8 months ago
dr7ana d9ead7d0f6 crypto and message encoding
- libsodium calls streamlined and moved away from stupid typedefs
- buffer handling taken away from buffer_t and towards ustrings and strings
- lots of stuff deleted
- team is working well
- re-implementing message handling in proper link_manager methods
8 months ago
dr7ana ae319091d6 libquic bump 9 months ago
dr7ana d0c3837384 libquic bparser merged
- bumped version to latest main branch commit
- wired up callbacks to set RPC request stream on creation
- methods for I/O of control and data messages through link_manager
9 months ago
dr7ana a3e6cec7e7 Address type migration + libquic bump
- llarp/router/router.hpp, route_poker, and platform code moved to libquic Address types
- implementing required methods in link_manager for connection establishment
- coming along nicely
9 months ago
dr7ana bfa9629779 More carving + libquic bump
- bumped libquic to begin implementing dependent features on connection open/close signals
- more gutting of interface classes
9 months ago
dr7ana aaf688cf81 Deleted a lot
- RIP llarp/iwp/* and most of llarp/link
9 months ago
dr7ana fd527d612f Carving through llarp/link 9 months ago
dr7ana 7f8207d5d3 Nuked superfluous interface classes
RIP:
- i_link_manager
- i_outbound_message_handler
- i_gossiper
- i_outbound_session_maker
- i_rc_lookup_handler
9 months ago
dr7ana 511c20cdb6 Message handling methods
- `::handle_message` is transposed; Rather than the message calling the method and taking a reference to the router, the router should have a handle_message method and take a reference to the message
- `::EndcodeBuffer` takes a string reference, to which the result of `::bt_encode()` is assigned
9 months ago
dr7ana a921575c55 mein gott 9 months ago
Thomas Winget 99be31b72f compiles, but does not link 9 months ago
Thomas Winget ab86318404 Partial implementation of libquic as wire protocol
TODO:

- set up all the callbacks for libquic

- define control message requests, responses, commands

- plug new control messages into lokinet (path creation, network state, etc)

- plug connection state changes (established, failed, closed, etc.) into lokinet

- lots of cleanup and miscellanea
10 months ago