An NTP implementation in Rust, supported by Internet Security Research Group's Prossimo project.

Last update: Jun 12, 2022

checkscodecov

NTPD-rs

NTPD-rs is an implementation of NTP completely written in Rust, with a focus on exposing a minimal attack surface. The project is currently in an early stage, and is not yet suitable for daily use. However, you can try it out if you are comfortable with running pre-release software.

Quick start

Currently, NTPD-rs only supports Linux-based operating systems. Our current testing only targets Linux kernels after version 5.0.0, older kernels may work but this is not guaranteed.

NTPD-rs is written in rust, and requires cargo 1.60.0 at a minimum to be built. We strongly recommend using rustup to install a rust toolchain, because the version provided by system package managers tends to be out of date.

To build NTPD-rs run

cargo build --release

This produces a binary ntp-daemon in the target/release folder, which is the main NTP daemon.

Before running the NTPD-rs daemon, make sure that no other NTP daemons are running. E.g. when chrony is running

systemctl stop chronyd

The NTPD-rs daemon requires elevated permissions to change the system clock. It can be tested against a server in the NTP pool

sudo ./target/release/ntp-daemon -p pool.ntp.org

After a few minutes you should start to see messages indicating the offset of your machine from the server. A complete description of how the daemon can be configured can be found in the configuration documentation

Naming

We are currently looking for a better name for this project. Suggestions for this are welcome.

Package substructure

Currently, the code is split up into five separate crates:

  • ntp-proto contains the packet parsing and the algorithms needed for clock selection, filtering and steering.
  • ntp-daemon contains the main NTP daemon, and deals with orchestrating the networking and configuration.
  • test-binaries contains a number of simple NTP servers that can be used for testing (see below).
  • ntp-os-clock contains the unsafe code needed to interface with system clocks.
  • ntp-udp contains the unsafe code needed to deal with timestamping on the network layer.

All unsafe code is contained within the ntp-os-clock and ntp-udp packages, which are kept as small as possible. All interfaces exposed by these crates should be safe. For a more detailed description of how NTPD-rs is structured, see the development documentation.

Test Binaries

This crate contains extremely limited NTP servers for testing purposes

  • demobilize-server always sends the DENY kiss code, the client must demobilize this association
  • rate-limit-server forces an increase of the poll interval to 32 seconds

Minimum supported rust version

We try to keep NTPD-rs working on at least the latest stable, beta and nightly rust compiler. Beyond this, we keep track of the current minimum rust version needed to compile our code for purposes of documentation. However, right now we do not have a policy guaranteeing a minimum amount of time we will support a stable rust release beyond the 6 weeks during which it is the latest stable version.

Please note that the rust foundation only supports the latest stable rust release. As this is the only release that will receive any security updates, we STRONGLY recommend using the latest stable rust version for compiling NTPD-rs for daily use.

GitHub

https://github.com/memorysafety/ntpd-rs
Comments
  • 1. Client for observing state and dynamically changing configuration

    we have two unix sockets, by default

    /run/ntpd-rs/log-level
    /run/ntpd-rs/config
    

    the log level is unprotected, the config needs additional permissions.


    we can use https://docs.rs/tokio/latest/tokio/net/struct.UnixStream.html

    for sending data over the socket, use https://docs.rs/postcard/latest/postcard/ ? (or send json as bytes?)


    client --set-log-level=debug
    
    client --step-if-bigger=1000 --step-first-updates=10
    

    then we also need some observability features, some ideas

    client peers list # lists all remotes we are connected to
    client peers watch # show for each connected peer its `PeerStatus`
    
    Reviewed by folkertdev at 2022-05-31 09:21
  • 2. Bump clap from 3.1.18 to 3.2.1

    Bumps clap from 3.1.18 to 3.2.1.

    Release notes

    Sourced from clap's releases.

    v3.2.0

    [3.2.0] - 2022-06-13

    Features

    • Parsed, typed arguments via Arg::value_parser / ArgMatches::{get_one,get_many} (#2683, #3732)
      • Several built-in TypedValueParsers available with an API open for expansion
      • value_parser!(T) macro for selecting a parser for a given type (#3732) and open to expansion via the ValueParserFactory trait (#3755)
      • [&str] is implicitly a value parser for possible values
      • All ArgMatches getters do not assume required arguments (#2505)
      • Add ArgMatches::remove_* variants to transfer ownership
      • Add ArgMatches::try_* variants to avoid panics for developer errors (#3621)
      • Add a get_raw to access the underlying OsStrs
      • PathBuf value parsers imply ValueHint::AnyPath for completions (#3732)
    • Explicit control over parsing via Arg::action (#3774)
      • ArgAction::StoreValue: existing takes_value(true) behavior
      • ArgAction::IncOccurrences: existing takes_value(false) behavior
      • ArgAction::Help: existing --help behavior
      • ArgAction::Version: existing --version behavior
      • ArgAction::Set: Overwrite existing values (like Arg::multiple_occurrences mixed with Command::args_override_self) (#3777)
      • ArgAction::Append: like Arg::multiple_occurrences (#3777)
      • ArgAction::SetTrue: Treat --flag as --flag=true (#3775)
        • Implies Arg::default_value("false") (#3786)
        • Parses Arg::env via Arg::value_parser
      • ArgAction::SetFalse: Treat --flag as --flag=false (#3775)
        • Implies Arg::default_value("true") (#3786)
        • Parses Arg::env via Arg::value_parser
      • ArgAction::Count: Treat --flag --flag --flag as --flag=1 --flag=2 --flag=3 (#3775)
        • Implies Arg::default_value("0") (#3786)
        • Parses Arg::env via Arg::value_parser
    • (derive) Opt-in to new Arg::value_parser / Arg::action with either #[clap(value_parser)] (#3589, #3742) / #[clap(action)] attributes (#3794)
      • Default ValueParser is determined by value_parser! (#3199, #3496)
      • Default ArgAction is determine by a hard-coded lookup on the type (#3794)
    • Command::multicall is now stable for busybox-like programs and REPLs (#2861, #3684)
    • ArgMatches::{try_,}contains_id for checking if there are values for an argument that mirrors the new get_{one,many} API

    Fixes

    parser

    • Set ArgMatches::value_source and ArgMatches::occurrences_of for external subcommands (#3732)
    • Use value delimiter for Arg::default_missing_values (#3761, #3765)
    • SplitArg::default_value / Arg::env on value delimiters independent of whether -- was used (#3765)
    • Allow applying defaults to flags (#3294, 3775)
    • Defaults no longer satisfy required and its variants (#3793)

    Compatibility

    MSRV is now 1.56.0 (#3732)

    Behavior

    ... (truncated)

    Changelog

    Sourced from clap's changelog.

    [3.2.1] - 2022-06-13

    [3.2.0] - 2022-06-13

    Features

    • Parsed, typed arguments via Arg::value_parser / ArgMatches::{get_one,get_many} (#2683, #3732)
      • Several built-in TypedValueParsers available with an API open for expansion
      • value_parser!(T) macro for selecting a parser for a given type (#3732) and open to expansion via the ValueParserFactory trait (#3755)
      • [&str] is implicitly a value parser for possible values
      • All ArgMatches getters do not assume required arguments (#2505)
      • Add ArgMatches::remove_* variants to transfer ownership
      • Add ArgMatches::try_* variants to avoid panics for developer errors (#3621)
      • Add a get_raw to access the underlying OsStrs
      • PathBuf value parsers imply ValueHint::AnyPath for completions (#3732)
    • Explicit control over parsing via Arg::action (#3774)
      • ArgAction::StoreValue: existing takes_value(true) behavior
      • ArgAction::IncOccurrences: existing takes_value(false) behavior
      • ArgAction::Help: existing --help behavior
      • ArgAction::Version: existing --version behavior
      • ArgAction::Set: Overwrite existing values (like Arg::multiple_occurrences mixed with Command::args_override_self) (#3777)
      • ArgAction::Append: like Arg::multiple_occurrences (#3777)
      • ArgAction::SetTrue: Treat --flag as --flag=true (#3775)
        • Implies Arg::default_value("false") (#3786)
        • Parses Arg::env via Arg::value_parser
      • ArgAction::SetFalse: Treat --flag as --flag=false (#3775)
        • Implies Arg::default_value("true") (#3786)
        • Parses Arg::env via Arg::value_parser
      • ArgAction::Count: Treat --flag --flag --flag as --flag=1 --flag=2 --flag=3 (#3775)
        • Implies Arg::default_value("0") (#3786)
        • Parses Arg::env via Arg::value_parser
    • (derive) Opt-in to new Arg::value_parser / Arg::action with either #[clap(value_parser)] (#3589, #3742) / #[clap(action)] attributes (#3794)
      • Default ValueParser is determined by value_parser! (#3199, #3496)
      • Default ArgAction is determine by a hard-coded lookup on the type (#3794)
    • Command::multicall is now stable for busybox-like programs and REPLs (#2861, #3684)
    • ArgMatches::{try_,}contains_id for checking if there are values for an argument that mirrors the new get_{one,many} API

    Fixes

    parser

    • Set ArgMatches::value_source and ArgMatches::occurrences_of for external subcommands (#3732)
    • Use value delimiter for Arg::default_missing_values (#3761, #3765)
    • SplitArg::default_value / Arg::env on value delimiters independent of whether -- was used (#3765)
    • Allow applying defaults to flags (#3294, 3775)
    • Defaults no longer satisfy required and its variants (#3793)

    Compatibility

    MSRV is now 1.56.0 (#3732)

    ... (truncated)

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    Reviewed by dependabot[bot] at 2022-06-14 01:46
  • 3. Bump tokio from 1.18.2 to 1.19.2

    Bumps tokio from 1.18.2 to 1.19.2.

    Release notes

    Sourced from tokio's releases.

    Tokio v1.19.1

    1.19.1 (June 5, 2022)

    This release fixes a bug in Notified::enable. (#4747)

    #4747: tokio-rs/tokio#4747

    Tokio v1.19.0

    1.19.0 (June 3, 2022)

    Added

    • runtime: add is_finished method for JoinHandle and AbortHandle (#4709)
    • runtime: make global queue and event polling intervals configurable (#4671)
    • sync: add Notified::enable (#4705)
    • sync: add watch::Sender::send_if_modified (#4591)
    • sync: add resubscribe method to broadcast::Receiver (#4607)
    • net: add take_error to TcpSocket and TcpStream (#4739)

    Changed

    • io: refactor out usage of Weak in the io handle (#4656)

    Fixed

    • macros: avoid starvation in join! and try_join! (#4624)

    Documented

    • runtime: clarify semantics of tasks outliving block_on (#4729)
    • time: fix example for MissedTickBehavior::Burst (#4713)

    Unstable

    • metrics: correctly update atomics in IoDriverMetrics (#4725)
    • metrics: fix compilation with unstable, process, and rt, but without net (#4682)
    • task: add #[track_caller] to JoinSet/JoinMap (#4697)
    • task: add Builder::{spawn_on, spawn_local_on, spawn_blocking_on} (#4683)
    • task: add consume_budget for cooperative scheduling (#4498)
    • task: add join_set::Builder for configuring JoinSet tasks (#4687)
    • task: update return value of JoinSet::join_one (#4726)

    #4498: tokio-rs/tokio#4498 #4591: tokio-rs/tokio#4591 #4607: tokio-rs/tokio#4607 #4624: tokio-rs/tokio#4624 #4656: tokio-rs/tokio#4656 #4671: tokio-rs/tokio#4671 #4682: tokio-rs/tokio#4682 #4683: tokio-rs/tokio#4683 #4687: tokio-rs/tokio#4687 #4697: tokio-rs/tokio#4697 #4705: tokio-rs/tokio#4705 #4709: tokio-rs/tokio#4709 #4713: tokio-rs/tokio#4713 #4725: tokio-rs/tokio#4725 #4726: tokio-rs/tokio#4726 #4729: tokio-rs/tokio#4729

    ... (truncated)

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    Reviewed by dependabot[bot] at 2022-06-07 01:34
  • 4. Discussion: Failure mode upon detecting programming errors

    There are currently a few, and probably in the future will be a few more, places where we can and do do checks that essentially represent invariants that should always hold, regardless of any input provided from external sources. As such, failure of these checks directly indicate bugs in our code, and the question then becomes what should the behaviour of these checks be in release builds.

    Given the specific nature of NTP, especially for an NTP client, I personally am of the opinion that the safer option is to actively blow up upon detection of such errors. This is because, assuming we detected it early enough, the system time now is hopefully reasonably correct, and in that case without corrections shouldn't drift to the point in the short term, and at the same time blowing up makes the issue very visible to whomever is managing the server running the client. However, silently ignoring the error or trying to work around it could result in incorrect steering of the clock (since the software is now in a state that was never anticipated), and incorrect steering could potentially result in significant clock deviation from UTC fairly quickly, and furthermore is far less visible to whomever is managing the server running the client, increasing the potential for a faulty situation to last for a significant time interval.

    Is this the view we want to take as project, or are there arguments to the contrary that I am forgetting about here.

    Reviewed by davidv1992 at 2022-04-07 09:50
  • 5. Bump clap from 3.1.18 to 3.2.4

    Bumps clap from 3.1.18 to 3.2.4.

    Release notes

    Sourced from clap's releases.

    v3.2.4

    [3.2.4] - 2022-06-14

    Fixes

    • (derive) Provide more clearer deprecation messages for #[clap(parse)] attribute (#3832)

    v3.2.3

    [3.2.3] - 2022-06-14

    Fixes

    • Moved deprecations to be behind the deprecated Cargo.toml feature (#3830)
      • For now, it is disabled by default though we are considering enabling it by default as we release the next major version to help draw attention to the deprecation migration path

    v3.2.2

    [3.2.2] - 2022-06-14

    Fixes

    • (derive) Improve the highlighted code for deprecation warnings

    gated behind unstable-v4

    • (derive) Default to #[clap(value_parser, action)] instead of #[clap(parse)] (#3827)

    v3.2.0

    [3.2.0] - 2022-06-13

    Features

    • Parsed, typed arguments via Arg::value_parser / ArgMatches::{get_one,get_many} (#2683, #3732)
      • Several built-in TypedValueParsers available with an API open for expansion
      • value_parser!(T) macro for selecting a parser for a given type (#3732) and open to expansion via the ValueParserFactory trait (#3755)
      • [&str] is implicitly a value parser for possible values
      • All ArgMatches getters do not assume required arguments (#2505)
      • Add ArgMatches::remove_* variants to transfer ownership
      • Add ArgMatches::try_* variants to avoid panics for developer errors (#3621)
      • Add a get_raw to access the underlying OsStrs
      • PathBuf value parsers imply ValueHint::AnyPath for completions (#3732)
    • Explicit control over parsing via Arg::action (#3774)
      • ArgAction::StoreValue: existing takes_value(true) behavior
      • ArgAction::IncOccurrences: existing takes_value(false) behavior
      • ArgAction::Help: existing --help behavior
      • ArgAction::Version: existing --version behavior
      • ArgAction::Set: Overwrite existing values (like Arg::multiple_occurrences mixed with Command::args_override_self) (#3777)
      • ArgAction::Append: like Arg::multiple_occurrences (#3777)
      • ArgAction::SetTrue: Treat --flag as --flag=true (#3775)
        • Implies Arg::default_value("false") (#3786)

    ... (truncated)

    Changelog

    Sourced from clap's changelog.

    [3.2.4] - 2022-06-14

    Fixes

    • (derive) Provide more clearer deprecation messages for #[clap(parse)] attribute (#3832)

    [3.2.3] - 2022-06-14

    Fixes

    • Moved deprecations to be behind the deprecated Cargo.toml feature (#3830)
      • For now, it is disabled by default though we are considering enabling it by default as we release the next major version to help draw attention to the deprecation migration path

    [3.2.2] - 2022-06-14

    Fixes

    • (derive) Improve the highlighted code for deprecation warnings

    gated behind unstable-v4

    • (derive) Default to #[clap(value_parser, action)] instead of #[clap(parse)] (#3827)

    [3.2.1] - 2022-06-13

    [3.2.0] - 2022-06-13

    Compatibility

    MSRV is now 1.56.0 (#3732)

    Behavior

    • Defaults no longer satisfy required and its variants (#3793)
    • When misusing ArgMatches::value_of and friends, debug asserts were turned into panics

    Moving (old location deprecated)

    • clap::{PossibleValue, ValueHint} to clap::builder::{PossibleValue, ValueHint}
    • clap::{Indices, OsValues, ValueSource, Values} to clap::parser::{Indices, OsValues, ValueSource, Values}
    • clap::ArgEnum to clap::ValueEnum (#3799)

    Replaced

    • Arg::allow_invalid_utf8 with Arg::value_parser(value_parser!(PathBuf)) (#3753)
    • Arg::validator / Arg::validator_os with Arg::value_parser (#3753)
    • Arg::validator_regex with users providing their own builder::TypedValueParser (#3756)
    • Arg::forbid_empty_values with builder::NonEmptyStringValueParser / builder::PathBufValueParser (#3753)
    • Arg::possible_values with Arg::value_parser([...]), builder::PossibleValuesParser, or builder::EnumValueParser (#3753)
    • Arg::max_occurrences with arg.action(ArgAction::Count).value_parser(value_parser!(u8).range(..N)) for flags (#3797)
    • Arg::multiple_occurrences with ArgAction::Append or ArgAction::Count though positionals will need Arg::multiple_values (#3772, #3797)
    • Command::args_override_self with ArgAction::Set (#2627, #3797)

    ... (truncated)

    Commits
    • 20358ff chore: Release
    • 241a6fc docs: Update changelog
    • ffd24af Merge pull request #3832 from epage/derive
    • 5881bd0 fix(derive): Provide derive-friendly deprecation messages
    • 11fe3ce fix(derive): Allow opting in to the original deprecations
    • ae81b09 refactor(derive): Split up chained calls
    • ce5cc92 refactor(derive): Clarify the kinds of methods
    • 89beb28 fix(derive): Reduce amount of deprecation noise
    • 63a17a4 chore: Release
    • d290f11 docs: Update changelog
    • Additional commits viewable in compare view

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    Reviewed by dependabot[bot] at 2022-06-15 01:45
  • 6. Bump tokio from 1.18.2 to 1.19.1

    Bumps tokio from 1.18.2 to 1.19.1.

    Release notes

    Sourced from tokio's releases.

    Tokio v1.19.1

    1.19.1 (June 5, 2022)

    This release fixes a bug in Notified::enable. (#4747)

    #4747: tokio-rs/tokio#4747

    Tokio v1.19.0

    1.19.0 (June 3, 2022)

    Added

    • runtime: add is_finished method for JoinHandle and AbortHandle (#4709)
    • runtime: make global queue and event polling intervals configurable (#4671)
    • sync: add Notified::enable (#4705)
    • sync: add watch::Sender::send_if_modified (#4591)
    • sync: add resubscribe method to broadcast::Receiver (#4607)
    • net: add take_error to TcpSocket and TcpStream (#4739)

    Changed

    • io: refactor out usage of Weak in the io handle (#4656)

    Fixed

    • macros: avoid starvation in join! and try_join! (#4624)

    Documented

    • runtime: clarify semantics of tasks outliving block_on (#4729)
    • time: fix example for MissedTickBehavior::Burst (#4713)

    Unstable

    • metrics: correctly update atomics in IoDriverMetrics (#4725)
    • metrics: fix compilation with unstable, process, and rt, but without net (#4682)
    • task: add #[track_caller] to JoinSet/JoinMap (#4697)
    • task: add Builder::{spawn_on, spawn_local_on, spawn_blocking_on} (#4683)
    • task: add consume_budget for cooperative scheduling (#4498)
    • task: add join_set::Builder for configuring JoinSet tasks (#4687)
    • task: update return value of JoinSet::join_one (#4726)

    #4498: tokio-rs/tokio#4498 #4591: tokio-rs/tokio#4591 #4607: tokio-rs/tokio#4607 #4624: tokio-rs/tokio#4624 #4656: tokio-rs/tokio#4656 #4671: tokio-rs/tokio#4671 #4682: tokio-rs/tokio#4682 #4683: tokio-rs/tokio#4683 #4687: tokio-rs/tokio#4687 #4697: tokio-rs/tokio#4697 #4705: tokio-rs/tokio#4705 #4709: tokio-rs/tokio#4709 #4713: tokio-rs/tokio#4713 #4725: tokio-rs/tokio#4725 #4726: tokio-rs/tokio#4726 #4729: tokio-rs/tokio#4729

    ... (truncated)

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    Reviewed by dependabot[bot] at 2022-06-06 01:48
  • 7. stop sending messages to servers that send the DENY code

    we did previously remove a peer that receives DENY from the list of peers, but did not cancel the task that keeps sending messages to the server. Also the ordering of checks was such that the KISS code would never be processed if other fields of the packet are also invalid. But the spec notes that if a KISS code is sent, the rest of the packet may be invalid anyway. So we should check for kiss codes first when validating a packet.

    Reviewed by folkertdev at 2022-05-13 13:59
  • 8. Bump tokio from 1.18.1 to 1.18.2

    Bumps tokio from 1.18.1 to 1.18.2.

    Release notes

    Sourced from tokio's releases.

    Tokio v1.18.2

    1.18.2 (May 5, 2022)

    Add missing features for the winapi dependency. (#4663)

    #4663: tokio-rs/tokio#4663

    Commits

    Dependabot compatibility score

    Dependabot will resolve any conflicts with this PR as long as you don't alter it yourself. You can also trigger a rebase manually by commenting @dependabot rebase.


    Dependabot commands and options

    You can trigger Dependabot actions by commenting on this PR:

    • @dependabot rebase will rebase this PR
    • @dependabot recreate will recreate this PR, overwriting any edits that have been made to it
    • @dependabot merge will merge this PR after your CI passes on it
    • @dependabot squash and merge will squash and merge this PR after your CI passes on it
    • @dependabot cancel merge will cancel a previously requested merge and block automerging
    • @dependabot reopen will reopen this PR if it is closed
    • @dependabot close will close this PR and stop Dependabot recreating it. You can achieve the same result by closing it manually
    • @dependabot ignore this major version will close this PR and stop Dependabot creating any more for this major version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this minor version will close this PR and stop Dependabot creating any more for this minor version (unless you reopen the PR or upgrade to it yourself)
    • @dependabot ignore this dependency will close this PR and stop Dependabot creating any more for this dependency (unless you reopen the PR or upgrade to it yourself)
    Reviewed by dependabot[bot] at 2022-05-09 02:23
  • 9. Cleanup NTP-proto

    Current work has created a bit of a mess, we need to

    • choose better names
    • look at where code is still dead but needed in the future
    • re-evaluate the public/private-ness of fields/functions on types
    Reviewed by davidv1992 at 2022-04-28 14:13
  • 10. reorganize filter.rs into more files

    pub(crate) all the things.

    This seems to generally work well. The one thing I'm not entirely sure on is where PeerStatistics should live. I know that in rust you can have circular dependencies between modules, but intuitively I dislike that. Right now there is still a circular dependency between peer.rs and filter.rs

    Reviewed by folkertdev at 2022-04-21 10:54
  • 11. Run cargo deny in CI

    This helps check dependency licenses, security vulnerabilities and other stuff. Something like this:

    https://github.com/InstantDomain/instant-distance/blob/main/.github/workflows/rust.yml#L79

    Reviewed by djc at 2022-04-05 16:12
  • 12. Better error handling for well known failure scenarios that require operator intervention

    Some failure modes:

    • when the client can't start up because of permissions
    • when the client can't start because of configuration failure
    • When a sudden time jump is detected in the middle of normal operation

    I think we may want to try and emit specific exit codes for these well known failure modes, so that they can be distinguished from other errors and panics. We also want to specifically make sure that we emit an error level log message before exiting the program to make sure that such a message pops up in a system that monitors the log messages.

    Reviewed by rnijveld at 2022-05-27 18:46
  • 13. Add SRV record peer discovery mechanism

    One easy way to discover peer addresses would be by using SRV records in DNS. This would make the client a lot easier to use in many cloud-based environments.

    Reviewed by rnijveld at 2022-05-27 18:34
Related tags
A shell for research papers

Reason: A Shell for Research Papers Did I ever read this paper? Which OSDI 2021 papers did I read? Which ones have the word 'Distributed' in their tit

Jun 1, 2022
DeFiChain octopus is a codename research & development for DFIP 2111-B: VOC: Ethereum Virtual Machine (EVM) Support.

DeFiCh/octopus DeFiChain octopus is a codename research & development for DFIP 2111-B: VOC: Ethereum Virtual Machine (EVM) Support . Proposed as a DFI

Apr 18, 2022
⌚ A command-line tool (and library) for the rusty Swatch Internet Time.

⌚ A command-line tool (and library) for the rusty Swatch Internet Time. Comes with XBar/Swiftbar support.

Jun 13, 2022
Curated list of awesome projects and resources related to Rust and computer security

Awesome Rust Security Curated list of awesome projects and resources related to Rust and computer security Table of Contents Tools Web and Cloud Secur

Jun 10, 2022
Baby's first Rust CLI project. Basic implementation of grep. Written in about 100 SLOC.

minigrep Coding project from Chapter 12 of the The Rust Programming Language book. Usage Compile and run as so minigrep QUERY FILENAME QUERY being the

Oct 2, 2021
A CLI tool that allow you to create a temporary new rust project using cargo with already installed dependencies
A CLI tool that allow you to create a temporary new rust project using cargo with already installed dependencies

cargo-temp A CLI tool that allow you to create a new rust project in a temporary directory with already installed dependencies. Install Requires Rust

Jun 21, 2022
The dead easy way to use config files in your rust project

Configr The dead easy way to use config files in your project This will load a config.toml file if it exists, otherwise it will create the needed fold

May 27, 2021
This repository presents a numbers vizualizer in a polar base. This small project has been entirely made in Rust !

NumbersRepresentation This repository presents a numbers vizualizer in a polar base. This small project has been entirely made in Rust ! This is an id

Apr 12, 2022
🤖 just is a handy way to save and run project-specific commands.

just just is a handy way to save and run project-specific commands. (非官方中文文档,这里,快看过来!) Commands, called recipes, are stored in a file called justfile

Jun 24, 2022
A CLI for analyzing the programming languages and how much code written in a project.
A CLI for analyzing the programming languages and how much code written in a project.

projlyzer A CLI for analyzing the programming languages and how much code written in a project. New features are on the way... Example Screenshot Buil

Apr 10, 2022
A command-line utility that creates project structure.
 A command-line utility that creates project structure.

petridish A command-line utility that creates project structure. If you have heard of the cookiecutter project, petridish is a rust implementation of

May 10, 2022
A command-line tool to generate a list of required missing Android OS Project blobs.

aosp-missing-blobs aosp-missing-blobs is a nifty tool to identify required blobs (.so) that are missing from AOSP ROM builds, and to show which existi

Jun 18, 2022
Watches over your Cargo project's source.

$ cargo watch Cargo Watch watches over your project's source for changes, and runs Cargo commands when they occur. If you've used nodemon, guard, or e

Jun 18, 2022
A cargo subcommand that displays ghidra function output through the use of the rizin rz-ghidra project.

cargo-rz-ghidra A cargo subcommand that displays ghidra function output through the use of the rizin rz-ghidra project. Install cargo install --git ht

May 10, 2022
A simple, modern fuzzy finder tool to run examples in a Cargo project.

cargo-rx cargo-rx is a simple, modern Runner for Examples in a Cargo project. This crate provides a single executable: rx. Basically anywhere you woul

May 3, 2022
Various Code answers for karan's Project questions.

Projects Answers Projects Answers is a collection of various code answers from different contributors in relation to the Projects repository. We encou

Jun 4, 2022
Mac App/CLI that automatically adds project logos to your locally cloned GitHub repos
Mac App/CLI that automatically adds project logos to your locally cloned GitHub repos

Download the app Automatically adds project logos to your locally cloned GitHub repos. Youtube Video This repository contains the source code for the

Jun 23, 2022
A template for starting a dioxus project to be used with dioxus-cli

A template for starting a dioxus project to be used with dioxus-cli

Feb 25, 2022
Readline Implementation in Rust

RustyLine Readline implementation in Rust that is based on Antirez' Linenoise Supported Platforms Unix (tested on FreeBSD, Linux and macOS) Windows cm

Jun 16, 2022