Commit Graph

28 Commits

Author SHA1 Message Date
Dave d03af9de05 Merge branch 'develop' of https://github.com/lnceballosz/nym into lnceballosz-develop 2021-01-29 10:28:47 +00:00
Dimitris Apostolou 131574cd3c Fix typos (#492) 2021-01-04 09:31:50 +00:00
Lina Ceballos 67ac1d9f4b adding license and copyright headers 2020-12-10 10:13:17 +01:00
Dave 4b34ed1f16 Adding the ulimit stuff to suggested service file. 2020-11-19 18:05:39 +00:00
Jędrzej Stuczyński 2fa5c3c3b7 Release/v0.9.0 (#453)
* Feature/wasm update (#341)

* Split text and binary client apis

* Very initial attempt at new serialization

* Defined ser+de for Recipient and ReplySURB

* Response errors

* builds with changes

* Working WS API + moved to separate crate

* updated python examples

* Fixed parsing bug

* Updated go examples

* Updated rust examples

* formatting

* Removed unused imports

* dependency updates

* Further dependency changes

* nymsphinx exposingn framing only if not in wasm32

* Cargo lock changes before develop merge

* Pending work

* Actually sending and receiving websocket from rust!

* more WIP

* Initial wasm client + establishing shared key with gateway!

* Splitting and sending a message!

* WIP

* WIP

* Initial wasm-ification of the gateway client

* Passing reconstruction result to js callback!

* Initial WASM cleaning pass

* Dependency pruning

* Moved processing loop to received_processor + at least ack unwrappingn

* Post merge fix

* Kinda updated react example

* Old print statement removed

* Removed yarn.lock

* Fixed building issue for other clients

* Fixed travis test command

* Updated wasm publishing instructions

* Feature/instant sending (#359)

* Ability to set client in vpn mode

* Connection handler for mixnode

* Initial vpn mode for mixes

* Updated SphinxCodec to contain more metadata

* Renaming

* Removed handle from mixnet client and introduced forwarder

* Mixnode using new forwarder

* Mixnode common module containing shared packet processing

* ibid. incorporated inside mixnode

* New processing for gateway

* Type cleanup

* Wasm fix

* Fixed client config

* Fixed mixnode runtime issues

* Formatting

* Client re-using secret on 'normal' packets

* Using the same key for acks

* WIP

* vpn key manager cleanup

* wasm fix

* VPN_KEY_REUSE_LIMIT moved to config

* Moved AckDelayQueue to separate common crate

* Key cache invalidator

* Updated dashmap used in gateway

* Old typo

* Additional comment

* Cargo fmt

* Fixed tests

* Sphinx update

* cache ttl as config option

* Cargo fmt

* Feature/network monitor (#369)

* WIP commit

* Further into errors (WIP)

* WIP commit, more stuff compiling, but now we switch to sneaky Jedrzej trick

* Websocket connections starting to work

* WIP

* Constructing the socket stream in one go

* Nicer connections. Getting topology now works.

* Fixing startup message

* Injecting directory uri

* Injecting good mixndodes

* Deleting old healthcheck

* Starting to wrap gateway client

* Splitting out good topology contstruction

* Starting to breathe finally

* Fixed layer assignment error

* Starting gateway client in a better spot

* Cleanup

* Renamed construct() to new()

* Injected channels, removed websockets

* Added a MixnetListener to deal with returned packet traffic

* Simplification

* Renaming and commenting a few things

* Renamed temp variables

* Fixed variable names

* Made errors a bit more explicit on message reconstruction

* Added the mixmining route / object to the directory server client

* Recipient is always "me", a bit easier to understand what's going on

* Subbing in test nodes works

* Using QA directory

* Noting which directory server we're using at monitor start

* Adding Debug to MixStatus so we can print it more easily

* Prettification of startup messages

* Notifying directory of successful packet receipt

* All nodes now being tested

* Now able to do timer-based test runs and detect the last node tested

* Renamed mixnet_listener to notifier

* Moved message chunking into its own home

* Starting to pull out packet sends

* Basic functionality working!

* Enabled timer runs forever

* License notices

* Depdendency cleanup

* Import cleanup

* Moved to implicit tokio runtime

* Removed some unnecessary data clones

* Fixed monitor doing two runs at startup rather than one

* dalek version updates

* This should have been split but got carried away

* Initial ipv6 support

* Don't test outdated nodes

* Added network monitor to default workspace members

* Actually sending reports

* Batch-sending mix status

* Cargo fmt

* Minor cleanup

* Malformed Cargo.lock

* Post-merge fixes

* Defined constant in main.rs for enabling detailed reporting

* Updated package versions of the system

* Checking version compatibility on startup

Co-authored-by: Dave Hrycyszyn <futurechimp@users.noreply.github.com>

* Added sphinx socks to default workspace members (#358)

* Feature/version in config (#376)

* Added version field to config files

* Removed built dependency

* Missing non-removed call to built

* Corrected version on client-core (#377)

* Feature/remove validator (#380)

* Replacing Rust validator sketch with Cosmos-based code.

* Removing old build instructions

* go fmt on generated code

* Removing build files for github and pi

* Starting transplant surgery

* Directory now running in validator, sans metrics

* Updating go sum

* A partly-working directory startup integrated into the nymcli app.

* Removing the Swagger docs header from nymcli, it can live in server.go

* Working swagger docs.

* Updating test title on Swagger docs

* Directory server now integrated into validator (primitive but working)

* Noted location of mixmining reports database.

* Bumped golang version

* Removing validator cargo files.

* Moving directory API init method into the nymd module

* Ditching a test which is causing tooling problems - presence will go away soon anyway

* Removing the validator and merging develop

* Update README.md

* Update README.md

* Feature/upgrade command (#381)

* Exposed version parsing from version checker

* Ability to upgrade mixnode from 0.8.X to 0.9.0

* Ability to upgrade gateway from 0.8.X to 0.9.0

* Ability to upgrade native client from 0.8.X to 0.9.0

* Ability to upgrade socks5 client from 0.8.X to 0.9.0

* Typo

* Minor renaming

* Preventing upgrade if current is not a release version

* Additional upgrade restrictions

* Corrected version bound

* Feature/mix ed25519 identity (#388)

* Introduced identity keypair to mixnode

* Updated upgrade 0.9.0 mix upgrade instructions

* Printing failed upgrade notice when it failed

* Moved printing upgrade start notice to beginning of function

* Feature/double init prevention (#386)

* Updated NymConfig trait making id always obligatory. Also added extra default method implementations

* Preventing init on mixnodes that were initialised before

* Quotes before mix id

* Preventing init on gateways that were initialised before

* Preventing init on native clients that were initialised before

* Preventing init on socks5 clients that were initialised before

* Feature/duration cleanup (#391)

* Mixnode using Duration for time intervals + human readable config fields for them

* Removed old comment

* Native client using Duration for time intervals + human readable config fields for them

* Socks5 client using Duration for time intervals + human readable config fields for them

* Gateway using Duration for time intervals + human readable config fields for them

* Config compatibility with 0.8.0 debug values

* Fixed previous merge issue

* Moving subsidiary functions down below main so we can see where thing start

* Feature/fix dependabot alerts (#393)

* Fixing a dependabot alert

* Fixing npm audit failures in js example for webassembly client

* Fixed some more npm audit problems

* Explicitly handling base58 key recovery errors (#396)

* Fix compiler warnings for unneeded mut (#398)

* moved new_v4_with_node to test only section (#392)

* moved new_v4_with_node to test only section

* cargo fmt

* Feature/directory server transition (#401)

* Initial changes to validator client API

* Updated models

* GatewayRegistrationInfo constructor

* Change validator topology to convert into NymTopology without failure

* Mixnode registering and unregistering presence

* Directory -> Validator renamings + adjustments

* Updated upgrade command for mixnode

* Extracted metrics part of directory client into separate library

* Removed no longer needed traits

* Integrated new metrics client into mixnode

* Introduced the same set of changes to the gateway

* Getting active topology in client core via validator client

* Updated clients to get correct topology

* Introduced mix mining endpoints to validator client

* Network monitor using validator client

* Removed directory client

* Updated wasm client

* Temporarily disabled the test

* Checking ok status for validator client response

* Updated upgrade command for clients

* Allowing using old presence directory as new validator endpoint for mixnodes and gateways

* Fixed tests in non-default crates

* Feature/validator api update (#402)

* Updated validator API routes

* missing comment

* Feature/wasm client fix (#399)

* Disabling wasm optimization for the moment, it isn't working on my machine

* Updating the React example back to a working state, 0.8.1 npm package is published.

* Merging develop into bugfix

* Upgrading react-scripts to fix a major vulnerability

* Using metrics interval received from server (#403)

* Using metrics interval received from server

* Test fix

* Feature/error on noninit (#404)

* More graceful shutdown in case of uninitialised client/node

* Performing version check on binary `run`

* Feature/no run config flag (#405)

* Removed `--config` parameter in `run` commands

* Removed old tests that were doing disk IO

* Renamed directory arguments to validator (#408)

* Feature/max retry (#409)

* Maximum number of allowed reconnection attempts

* Requiring initial internode connection to be successful

* Decreased logging level for failing to establish initial connection

* Feature/controlled reinit (#410)

* Allowing init with existing id but keeps existing keys

* Removed unused imports

* Removed debug print statement (#411)

* Updated upgrade commands to set new default validator (#413)

* Feature/network monitor file topology (#412)

* Network monitor loading 'good' topology from files instead

* Update .gitignore

* Passing address of validator as an argument

* Made detailed report const flag into an argument

* Flag to start network requester in open proxy mode (#418)

* Renamed 'sphinx-socks' to 'network-requester' (#417)

* Added option to set incentives address during mix and gateway init (#419)

* Updated validator topology (#420)

* Bugfix/upgrade fix (#421)

* Added default for incentives address when deserializing

* Ability to optionally pass incentives address during upgrade

* Feature/socks improvements (#423)

* Changed AvailableReader from Future to Stream

* comment formatting

* WIP

* Maximum number of bytes read per poll

* More detailed socks5 printing

* Split up socks5 service provider runner

* Fixed closing proxy too soon on one side

* Additional log information

* Printing connection id in log target

* Adjusted some constants

* Target field in log

* Removed dead code

* Decreased logging level

* Explicitly seperated 'Send' and 'Connect' request + data buffering

* Temporarily commented out test that fails due to not understanding limitations of tokio test io builder

* Fixed socks5 tests

* Starting cover traffic stream under correct condition (#422)

* Fixed bunch of clippy warnings (#427)

* Updated default sending rates (#430)

* Feature/explorer (#431)

* Initial commit of the new dashboard code.

* Periodically grabbing topology json

* Pulling file saving out into its own module

* Ignoring downloaded topology file

* Moved everything public into a public folder

* Refreshing the mixmining report

* Mounting static files from /public

* Including mixminiming report grabber

* Leaving the route in place to pick up later. It's not used right now.

* Removing json download from git

* Ignoring topology download

* Moving recurrent jobs in to a jobs module

* Adding websocket dependencies

* Starting to get client/server websocket functionality running.

* Fixing unused imports

* Separating client and server functionality a bit more cleanly

* WIP to sketch out the ws client and server a bit more

* Initial metrics broadcaster

* Import fixup

* Spawning rocket in tokio task

* Removed outdated comment

* removed the js file

Co-authored-by: Dave <futurechimp@users.noreply.github.com>

* Bugfix/metrics fixes (#434)

* Updated dashboard html file

* Changed explorer to listen on the same port as old dashboard

* Using correct field names in js file

* Sending correct key in metrics

* Added nym prefix to binary names (#436)

* Passing validator base url as an argument (#439)

* Spawning rocket as a blocking task (#440)

* Update main.js (#441)

* Update main.js

* Changed websocket port to 1648

* Changing default validator location to make it clear we're testnet (#437)

* Changing default validator location to make it clear we're on a testnet here.

* Updated validator url

* Updated metrics url

Co-authored-by: jstuczyn <jedrzej.stuczynski@gmail.com>

* Adding keybase to allowed.list.sample (#442)

* Updated nym-run gateway id (#445)

* Adjusted 'fastmode' settings (#444)

* Added validators to dashboard + validator and block count (#443)

* Slightly friendlier upgrade argument description (#446)

* Slightly friendlier upgrade argument description

* Added right format examples

* Explorer public folder being relative to the binary (#447)

* Explorer public folder being relative to the binary

* Qualifying the public mounting path

Co-authored-by: Dave <futurechimp@users.noreply.github.com>

* Extra argument to specify metrics websocket + long attribute (#448)

* Extra argument to specify metrics websocket + long attribute

* Default testnet values

* Fixed the URL of the websocket (#449)

* Removed hardcoded 'good gateways' in favour of pseusorandom choice from the active set (#450)

* Adding graceful de-registration to service

* Removed incentives form url (#451)

* Updated version numbers

* Updated generate changelog script

* Updated changelog

* wasm examples fixes

Co-authored-by: Dave Hrycyszyn <futurechimp@users.noreply.github.com>
Co-authored-by: Ethan Frey <ethanfrey@users.noreply.github.com>
2020-11-13 12:44:58 +00:00
Dave Hrycyszyn 7b2036bd33 Feature/perf messing (#311)
* Merge branch 'develop' into feature/socks5-no-core

common/client-libs/directory-client/models/src/presence/topology.rs

* More diagnostics

* WIP commit, not properly multithreaded

* WIP, now sort of multithreaded but errors all over the place

* Replaced expect with a return

* Adding abort on panic

* Removing a few noisy prints

* Another ack-related expect replaced

* Moved profile.dev annotation to workspace cargo.toml

* Semi-stabilised socks

* Assigning connection shared key post registration (#309)

* Sending return address with connect request

* WIP commit

* Reading all available data on reader + removed duplicate code

Co-authored-by: jstuczyn <jedrzej.stuczynski@gmail.com>
2020-08-20 13:43:26 +01:00
Dave Hrycyszyn 1546088904 Feature/socks5 (#302)
* Adding the beginnings of a socks5 crate

* Removing unused import

* Adding built.rs

* Figured out test failure, stuck a note in detailing under what conditions it fails.

* Added lib

* wip on the way to compile

* First compile with much of the client in place

* Comment reflow to 80 lines

* Changed Socks5 client help message

* Latest changes to from develop applied to socks5 client

* Minor cleanup on unused code

* Adding snafu dependency

* Adding socks library

* Getting socks into the module structure

* Tokio conversion for socks code nearly completed.

* Starting traffic controllers again

* Bitcoin SP starting to breathe with Socks5 proxy. Responses not yet being sent.

* Adding in some hugely verbose print action so we can see things happening

* WIP refactor of socks code.

* Renamed structs to be more rubyish

* Refactored the run command a bit.

* handle_client doesn't need to be public

* Starting to split the handle method up into smaller, refactorable chunks

* Renamed a test

* Finished initial refactor

* Minor cleanup

* Made a few notes for my future self

* Being a bit more explicit in authtentication test

* Ensuring that user/password authentication attempts fail if that auth mode is off

* Documentation

* Refactord types into a types module

* Sending the request ID across and reading the response when it comes back.

* Added the request_id to the response header

* Adding exception handling to websocket send

* Semi-working...

* Removing non-functional examples.

* Minor output clarification

* Adding a Socks5 service provider

* Websocket connection is now being made.

* Added some simple and ungraceful websocket connection error handling

* Renamed socks5_proxy back to proxy

* ibid

* Nicer websocket start method

* Receiving messages via websocket

* Socks requests work in the simple case, SSL requests don't (yet).

* Minor cleanup, renaming variables and moving private functions around

* Comments on try_read_request

* Moved some code around

* Removed commented code and printlns

* Comments sp request

* Commented response data read

* Changing Request to Connection

* ibid

* Added a controller and split connection / request parsing

* Built out error handling on requests a bit

* Initial router action

* Request deserialization tests back in action

* Request constructors

* Constructor for controller

* Renamed message_router to controller

* Starting to build out the responses

* Returning proxied connection data

* Moving towards new Socks5 request crate

* Sending Socks5 multi-part requests through mixnet

* Removed the detritus of exploratory coding.

* Breaking the socks client read loop when empty bytes are read

* Documenting the message format for serialized socks requests

* Returning a response from the socks proxy

* Removing unused import

* Removing more detritus

* Restarting loop if no response is received

* The off-by-one change that fixed it all

* Removing unused response.rs module

* Removed unused import

* Comment cleanup

* More detritus

* Cleaning...

* Docs for socks5-requests

* Using the simple-socks5-requests crate Response in the socks5 client

* Removing unused error types

* Split request/response into their own files and wrote more tests

* Removing temporary README notes

* Renamed all instances of request_id to connection_id

* Docs on Connection struct

* Caving in to connecting inside the constructor for the moment

* Fixing up comments on socks5 service provider start

* Simplified errors in the Socks5 requests crate

* Flattened service provider module hierarchy a bit.

* Removed println

* Comment to explain return on timeout

* Logging controller connect errors

* Renamed websocket reads and writes to make them a bit more understandable

* Renamed TodoError to ConnectionError

* Logging errors instead of panicking on connection read/write failures

* Fixed error handling in controller

* Removing dead comments

* Cargo fmt applied

* Removing print statements

* Removed more comments, prints, etc

Co-authored-by: jstuczyn <jedrzej.stuczynski@gmail.com>
2020-08-12 16:23:23 +01:00
Stefan Steinert 169c995e95 Removed misplaced WorkingDirectory parameter (#264) 2020-06-15 15:53:00 +01:00
Stefan Steinert 9d88c8241e could not count to ten properly (#262) 2020-06-09 10:25:09 +01:00
Stefan Steinert c1e921db6a systemd service unit example (#257)
* systemd service unit example

* typo

* inconsistent use of sudo
2020-06-05 10:22:40 +01:00
Jędrzej Stuczyński 3773800133 Feature/start local network improvements (#228)
* Moved directory_server from Debug section of configs

* Using correct variable path

* Updated start_local_network script

* Actually killing gateways on startup

* Removed redundant stop_local_network.sh

* The Canadian appeasement accord
2020-05-13 12:01:51 +01:00
Dave Hrycyszyn 4b2a6f20f3 scripts: building for local in debug mode 2020-04-16 13:43:25 +01:00
Dave Hrycyszyn 2a6dd1d5a8 scripts: adding a stop script so I don't need to manually killall all the time 2020-04-15 20:53:29 +01:00
Dave Hrycyszyn f07966c3fc scripts: setting run_local_network.sh to be executable 2020-04-14 15:50:14 +01:00
Dave Hrycyszyn 3f06ccc36b Adding Apache 2 license headers to all files (#178) 2020-04-09 11:24:24 +01:00
Dave Hrycyszyn c4bc6d2799 Making changelog script executable 2020-04-07 17:20:09 +01:00
Jędrzej Stuczyński aee3286793 Feature/packet chunking (#158)
Basic support for message chunking and reconstruction. It's now possible to take arbitrarily-sized input and send it through the mixnet. The sending Nym client will automatically chunk the input into Sphinx packets, and the receiving Nym client will then reconstruct the message at the other end.
2020-03-31 16:00:41 +01:00
Dave Hrycyszyn ef062e15ac Documented changelog process a bit better 2020-03-23 11:33:35 +00:00
Jedrzej Stuczynski 4abb4d0b45 Updated run_local_network script to work with 0.5.0 2020-03-06 12:51:24 +00:00
Dave Hrycyszyn 1d58d1c2f1 Fixed changelog generator script 2020-01-28 15:38:01 +00:00
Dave Hrycyszyn 677791d64c ibid 2020-01-28 12:49:34 +00:00
Jedrzej Stuczynski 4cc7fc309b Fixed run local network script 2020-01-17 11:44:24 +00:00
Dave Hrycyszyn 67a900701e Updated script copyright date 2020-01-08 15:56:01 +00:00
Dave Hrycyszyn 8314d647d9 script: proper invocation for testnet runnign 2020-01-08 15:53:27 +00:00
Dave Hrycyszyn b88ca3ed91 script: killing old testnet processes in case they're already running 2020-01-08 15:53:11 +00:00
Dave Hrycyszyn 95f103b4fd scripts: local network now runs 2020-01-08 15:13:30 +00:00
Dave Hrycyszyn 5ad6db9232 removed commented logging code 2020-01-08 14:58:18 +00:00
Dave Hrycyszyn d42a75cea9 scripts: run_local_network.sh port of the old Go code
Currently non-functional
2020-01-07 19:10:46 +00:00