* oak-2 * oak-8 * oak-13 * oak-15 * oak-18 * Minor clippy nit * 2023-01-13-OAK-6 * 2023-01-13-OAK-3 * 2023-01-13-OAK-13 Implemented via direct dependency on cw2 and calling the appropriate code on migration * Removed few instances of password being unecessarily copied * 2023-01-13-OAK-10 * 2023-01-13-OAK-12 * 2021-09-13-JP-S-NYM-02 * 2021-09-13-JP-S-NYM-03 * Removed further instances of needlessly copying the mnemonic * 2021-09-13-JP-O-PROT-03 * 2021-09-13-JP-S-NYM-01* *: we still have one vulnerability on 'time' pulled from chrono via sqlx. However, apparently its usage is fine... Having said that, I'd still recommend removing all dependencies on chrono, but this will require some database migrations... * 2023-01-13-OAK-11 (#3009) * wip * Introducing the concept of starting epoch transition in `nym-api` * split epoch operations into multiple files * epoch operation failure recovery * sending rewarding transactions in correct order * tests and fixes due to epoch state progression * lint * missed rebasing import changes * Setting cw2 contract version during first migration run * calling 'reconcile_epoch_events' at least once * Made message to BeginEpochTransition more consistent with other variants * Merge layer assignment updates --------- Co-authored-by: Jędrzej Stuczyński <jedrzej.stuczynski@gmail.com>
Network Explorer API
An API that provides data for the Network Explorer.
Features:
- geolocates mixnodes using https://dev.maxmind.com/geoip/geolite2-free-geolocation-data
- calculates how many nodes are in each country
- proxies mixnode API requests to add HTTPS
GeoIP db install/update
First we need to install the geoip database.
We use https://github.com/maxmind/geoipupdate to automatically download and update GeoLite2 binary database. For convenience we run it as a docker container.
At the root of the repo, inside the docker-compose.yml, there
is a docker service geoipupdate for it.
Supposed you provided an .env file with all the environment
variables listed in .env.sample-dev (found at the root),
simply run the service through docker:
docker compose up -d geoipupdate
Running this command will automatically install (and update) the
db file inside the directory path provided by GEOIP_DB_DIRECTORY
env variable.
Running
When starting the explorer-api, supply the environment variable
GEOIP_DB_PATH, pointing to the GeoLite2 binary database file.
It should be previously installed thanks to geoipupdate service.
For example:
GEOIP_DB_PATH=./geo_ip/GeoLite2-City.mmdb cargo run
Note: explorer-api binary reads the provided .env file.
Run as a service and reverse proxy with nginx to add https with Lets Encrypt.
Setup nginx to inject the request IP to the header X-Real-IP.
TODO / Known Issues
TODO
- record the number of mixnodes on a given date and write to a file for later retrieval
- dependency injection
- tests