···11+{
22+ lib,
33+ buildGoModule,
44+ fetchFromGitHub,
55+}:
66+77+buildGoModule (finalAttrs: {
88+ pname = "oss-rebuild";
99+ version = "0-unstable-2025-07-22";
1010+1111+ src = fetchFromGitHub {
1212+ owner = "google";
1313+ repo = "oss-rebuild";
1414+ rev = "6f57c474a8faf3012204792af8ef5d8b6fae2fd1";
1515+ hash = "sha256-H8HkhQcRt6C+lxoMVLzRfhv60Mq8TAf83ctOBRbx4p0=";
1616+ };
1717+1818+ proxyVendor = true;
1919+ vendorHash = "sha256-H6ZMop3tXwpzvjoLWAaovP8UHSYLLFxvSz2jhz8tj/g=";
2020+2121+ subPackages = [
2222+ "cmd/oss-rebuild"
2323+ "cmd/proxy"
2424+ "cmd/stabilize"
2525+ "cmd/timewarp"
2626+ # There are other tools in available, but without documentation.
2727+ ];
2828+2929+ ldflags = [ "-s" ];
3030+3131+ env.CGO_ENABLED = 0;
3232+3333+ meta = {
3434+ description = "Securing open-source package ecosystems by originating, validating, and augmenting build attestations";
3535+ longDescription = ''
3636+ OSS Rebuild aims to apply reproducible build concepts at low-cost and high-scale for open-source package ecosystems.
3737+3838+ Rebuilds are derived by analyzing the published metadata and artifacts and are evaluated against the upstream package
3939+ versions. When successful, build attestations are published for the upstream artifacts, verifying the integrity of
4040+ the upstream artifact and eliminating many possible sources of compromise.
4141+4242+ [`oss-rebuild`](https://github.com/google/oss-rebuild?tab=readme-ov-file#usage) CLI tool provides access to OSS Rebuild
4343+ data.
4444+4545+ [`proxy`](https://github.com/google/oss-rebuild/blob/main/cmd/proxy/README.md) is a transparent HTTP(S) proxy that
4646+ intercepts and records network activity. It's primarily used within OSS Rebuild to monitor network interactions during
4747+ the build process, helping to passively enumerate remote dependencies and to identify suspect build behavior.
4848+4949+ [`stabilize`](https://github.com/google/oss-rebuild/blob/main/cmd/stabilize/README.md) is a command-line tool that
5050+ removes non-deterministic metadata from software packages to facilitate functional comparison of artifacts.
5151+5252+ [`timewarp`](https://github.com/google/oss-rebuild/blob/main/cmd/timewarp/README.md) is a registry-fronting HTTP
5353+ service that filters returned content by time. This tool allows you to transparently adjust the data returned to
5454+ package manager clients to reflect the state of a registry at a given point in time (especially useful for reproducing
5555+ prior builds).
5656+ '';
5757+ homepage = "https://github.com/google/oss-rebuild";
5858+ license = lib.licenses.asl20;
5959+ maintainers = with lib.maintainers; [ katexochen ];
6060+ mainProgram = "oss-rebuild";
6161+ };
6262+})