Change:
, CVSSv3=7.5 (nixos-21.05) CVSSv3=7.5 (nixos-21.05) CVSSv3=7.5 (nixos-21.05) NLnet Labs Routinator prior to 0.10.2 happily processes a chain of RRDP repositories of infinite length causing it to never finish a validation run. In RPKI, a CA can choose the RRDP repository it wishes to publish its data in. By continuously generating a new child CA that only consists of another CA using a different RRDP repository, a malicious CA can create a chain of CAs of de-facto infinite length. Routinator prior to version 0.10.2 did not contain a limit on the length of such a chain and will therefore continue to process this chain forever. As a result, the validation run will never finish, leading to Routinator continuing to serve the old data set or, if in the initial validation run directly after starting, never serve any data at all. In NLnet Labs Routinator prior to 0.10.2, a validation run can be delayed significantly by an RRDP repository by not answering but slowly drip-feeding bytes to keep the connection alive. This can be used to effectively stall validation. While Routinator has a configurable time-out value for RRDP connections, this time-out was only applied to individual read or write operations rather than the complete request. Thus, if an RRDP repository sends a little bit of data before that time-out expired, it can continuously extend the time it takes for the request to finish. Since validation will only continue once the update of an RRDP repository has concluded, this delay will cause validation to stall, leading to Routinator continuing to serve the old data set or, if in the initial validation run directly after starting, never serve any data at all. NLnet Labs Routinator versions 0.9.0 up to and including 0.10.1, support the gzip transfer encoding when querying RRDP repositories. This encoding can be used by an RRDP repository to cause an out-of-memory crash in these versions of Routinator. RRDP uses XML which allows arbitrary amounts of white space in the encoded data. The gzip scheme compresses such white space extremely well, leading to very small compressed files that become huge when being decompressed for further processing, big enough that Routinator runs out of memory when parsing input data waiting for the next XML element. Scanned versions: nixos-21.05: . Cc

Discussion:
{ lib <del> , stdenv , fetchFromGitHub </del> , rustPlatform <ins> , fetchFromGitHub , stdenv </ins> , Security }: rustPlatform.buildRustPackage rec { pname = "routinator"; <del> version = "0.10.1"; </del> <ins> version = "0.10.2"; </ins> src = fetchFromGitHub { owner = "NLnetLabs"; repo = pname; rev = "v${version}"; <del> sha256 = "sha256-ThgTGtTZ0LGm9nHJoy0KhnBFWNvKRjk7hoNTVVTeL/Y="; </del> <ins> sha256 = "0a2iwpmljkha6qlbw0373wph7pxz05qym5712vzbszw0z42f82l2"; </ins> }; cargoPatches = [ ./Cargo.toml.patch ]; <del> cargoSha256 = "sha256-mcx+qUtTUxeYP0PeJp1eOQwsdS6PPUx/m7TfAyqFiIM="; </del> <ins> cargoSha256 = "0l3fhwgrdvjrlmiqdy90sfd8kb2s7y0lbfswlrr560ly0bi1lfbx"; </ins> buildInputs = lib.optionals stdenv.isDarwin [ Security ]; <ins> buildNoDefaultFeatures = true; buildFeatures = [ "socks" ]; </ins> meta = with lib; { description = "An RPKI Validator written in Rust"; homepage = "https://github.com/NLnetLabs/routinator"; <ins> changelog = "https://github.com/NLnetLabs/routinator/blob/v${version}/Changelog.md"; </ins> license = licenses.bsd3; maintainers = with maintainers; [ _0x4A6F ]; <del> platforms = platforms.all; </del> }; }