commit bc7cfc708c104371aebc10fddb8cb3cfe642f4c0054701b1374f301d3c81486c Author: William Brown Date: Fri Nov 4 05:11:20 2022 +0000 Accepting request 1032994 from home:firstyear:branches:devel:languages:rust New package cargo-auditable OBS-URL: https://build.opensuse.org/request/show/1032994 OBS-URL: https://build.opensuse.org/package/show/devel:languages:rust/cargo-auditable?expand=0&rev=1 diff --git a/.gitattributes b/.gitattributes new file mode 100644 index 0000000..9b03811 --- /dev/null +++ b/.gitattributes @@ -0,0 +1,23 @@ +## Default LFS +*.7z filter=lfs diff=lfs merge=lfs -text +*.bsp filter=lfs diff=lfs merge=lfs -text +*.bz2 filter=lfs diff=lfs merge=lfs -text +*.gem filter=lfs diff=lfs merge=lfs -text +*.gz filter=lfs diff=lfs merge=lfs -text +*.jar filter=lfs diff=lfs merge=lfs -text +*.lz filter=lfs diff=lfs merge=lfs -text +*.lzma filter=lfs diff=lfs merge=lfs -text +*.obscpio filter=lfs diff=lfs merge=lfs -text +*.oxt filter=lfs diff=lfs merge=lfs -text +*.pdf filter=lfs diff=lfs merge=lfs -text +*.png filter=lfs diff=lfs merge=lfs -text +*.rpm filter=lfs diff=lfs merge=lfs -text +*.tbz filter=lfs diff=lfs merge=lfs -text +*.tbz2 filter=lfs diff=lfs merge=lfs -text +*.tgz filter=lfs diff=lfs merge=lfs -text +*.ttf filter=lfs diff=lfs merge=lfs -text +*.txz filter=lfs diff=lfs merge=lfs -text +*.whl filter=lfs diff=lfs merge=lfs -text +*.xz filter=lfs diff=lfs merge=lfs -text +*.zip filter=lfs diff=lfs merge=lfs -text +*.zst filter=lfs diff=lfs merge=lfs -text diff --git a/.gitignore b/.gitignore new file mode 100644 index 0000000..57affb6 --- /dev/null +++ b/.gitignore @@ -0,0 +1 @@ +.osc diff --git a/_service b/_service new file mode 100644 index 0000000..5df9260 --- /dev/null +++ b/_service @@ -0,0 +1,27 @@ + + + https://github.com/rust-secure-code/cargo-auditable.git + @PARENT_TAG@~@TAG_OFFSET@ + git + v0.5.2 + * + v(\d+\.\d+\.\d+) + \1 + enable + william.brown@suse.com + + + + *.tar + zst + + + + cargo-auditable + zst + true + + + cargo-auditable + + diff --git a/_servicedata b/_servicedata new file mode 100644 index 0000000..b5601a0 --- /dev/null +++ b/_servicedata @@ -0,0 +1,4 @@ + + + https://github.com/rust-secure-code/cargo-auditable.git + 4e4860cda0de05d35b5abc4782c0f0b8c9404475 \ No newline at end of file diff --git a/cargo-auditable-0.5.2~0.tar.zst b/cargo-auditable-0.5.2~0.tar.zst new file mode 100644 index 0000000..ebd9618 --- /dev/null +++ b/cargo-auditable-0.5.2~0.tar.zst @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:6b3025304a4a0484ce59a559ab6c561a4a8b9a620565360e4318a967d4bbe3ec +size 38647 diff --git a/cargo-auditable.changes b/cargo-auditable.changes new file mode 100644 index 0000000..56c00d0 --- /dev/null +++ b/cargo-auditable.changes @@ -0,0 +1,4 @@ +------------------------------------------------------------------- +Thu Nov 3 04:31:16 UTC 2022 - William Brown + +- Initial commit diff --git a/cargo-auditable.spec b/cargo-auditable.spec new file mode 100644 index 0000000..9a012d5 --- /dev/null +++ b/cargo-auditable.spec @@ -0,0 +1,67 @@ +# +# spec file for package cargo-auditable +# +# Copyright (c) 2022 SUSE LINUX GmbH, Nuernberg, Germany. +# +# All modifications and additions to the file contributed by third parties +# remain the property of their copyright owners, unless otherwise agreed +# upon. The license for this file, and modifications and additions to the +# file, is the same license as for the pristine package itself (unless the +# license for the pristine package is not an Open Source License, in which +# case the license is the MIT License). An "Open Source License" is a +# license that conforms to the Open Source Definition (Version 1.9) +# published by the Open Source Initiative. + +# Please submit bugfixes or comments via http://bugs.opensuse.org/ +# + +%define __rustflags -Clink-arg=-Wl,-z,relro,-z,now -C debuginfo=2 -C incremental=false +%define __cargo CARGO_FEATURE_VENDORED=1 RUSTFLAGS="%{__rustflags}" %{_bindir}/cargo +%define __cargo_common_opts %{?_smp_mflags} + +Name: cargo-auditable +Version: 0.5.2~0 +Release: 0 +Summary: A tool to embed auditing information in ELF sections of rust binaries +# If you know the license, put it's SPDX string here. +# Alternately, you can use cargo lock2rpmprovides to help generate this. +License: ( (MIT OR Apache-2.0) AND Unicode-DFS-2016 ) AND ( 0BSD OR MIT OR Apache-2.0 ) AND ( Apache-2.0 OR BSL-1.0 ) AND ( Apache-2.0 OR MIT ) AND ( Apache-2.0 WITH LLVM-exception OR Apache-2.0 OR MIT ) AND ( MIT OR Apache-2.0 OR Zlib ) AND ( MIT OR Zlib OR Apache-2.0 ) AND ( Unlicense OR MIT ) AND ( Zlib OR Apache-2.0 OR MIT ) AND MIT +# Select a group from this link: +# https://en.opensuse.org/openSUSE:Package_group_guidelines +Group: Development/Languages/Rust +Url: https://github.com/rust-secure-code/cargo-auditable +Source0: %{name}-%{version}.tar.zst +Source1: vendor.tar.zst +Source2: cargo_config +# We can't dep on cargo-packaging because we would create a dependency loop. +# BuildRequires: cargo-packaging +BuildRequires: cargo +BuildRequires: zstd +Requires: cargo + +%description +Know the exact crate versions used to build your Rust executable. Audit binaries for known bugs or +security vulnerabilities in production, at scale, with zero bookkeeping. This works by embedding +data about the dependency tree in JSON format into a dedicated linker section of the compiled +executable. + +%prep +%autosetup -a1 +mkdir .cargo +cp %{SOURCE2} .cargo/config + +%build +unset LIBSSH2_SYS_USE_PKG_CONFIG +%{__cargo} build \ + %{__cargo_common_opts} \ + --offline --release + +%install +install -D -d -m 0755 %{buildroot}%{_bindir} +install -m 0755 %{_builddir}/%{name}-%{version}/target/release/cargo-auditable %{buildroot}%{_bindir}/cargo-auditable + +%files +%{_bindir}/cargo-auditable + +%changelog + diff --git a/cargo_config b/cargo_config new file mode 100644 index 0000000..6fb4ff4 --- /dev/null +++ b/cargo_config @@ -0,0 +1,5 @@ +[source.crates-io] +replace-with = "vendored-sources" + +[source.vendored-sources] +directory = "vendor" \ No newline at end of file diff --git a/vendor.tar.zst b/vendor.tar.zst new file mode 100644 index 0000000..907ff97 --- /dev/null +++ b/vendor.tar.zst @@ -0,0 +1,3 @@ +version https://git-lfs.github.com/spec/v1 +oid sha256:d80f4bffdaffd3222d4fc54ce0aa4e41dd172958d933818a3d5132cc4779947f +size 2391562