Bug 2312228

Summary: Review Request: rust-rcgen - Rust X.509 certificate generator
Product: [Fedora] Fedora Reporter: Fabio Valentini <decathorpe>
Component: Package ReviewAssignee: Ben Beasley <code>
Status: CLOSED NEXTRELEASE QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: rawhideCC: code, package-review, pbrobinson
Target Milestone: ---Flags: code: fedora-review+
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: rust-rcgen-0.13.1-1.fc42 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2024-09-19 22:35:24 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 2272352    

Description Fabio Valentini 2024-09-13 15:47:38 UTC
Spec URL: https://decathorpe.fedorapeople.org/rust-rcgen.spec
SRPM URL: https://decathorpe.fedorapeople.org/rust-rcgen-0.13.1-1.fc40.src.rpm

Description:
Rust X.509 certificate generator.

Fedora Account System Username: decathorpe

Comment 1 Fabio Valentini 2024-09-13 15:48:32 UTC
*** Bug 2272355 has been marked as a duplicate of this bug. ***

Comment 2 Fabio Valentini 2024-09-13 15:53:41 UTC
koji scratch build for rawhide:
https://koji.fedoraproject.org/koji/taskinfo?taskID=123350961

Comment 3 Ben Beasley 2024-09-18 19:12:54 UTC
The package is APPROVED, but please add a patch upstream status comment for 0001-fix-compilation-failure-of-OpenSSL-tests-on-32-bit-a.patch.

Package Review
==============

Legend:
[x] = Pass, [!] = Fail, [-] = Not applicable, [?] = Not evaluated

The package is generated with rust2rpm, simplifying the review. There are some manual changes:

  +# Manually created patch for downstream crate metadata changes
  +# * drop unused support for the aws-lc-rs crypto backend
  +# * drop unused x509-parser support
  +# * drop botan dev-dependency (Rust bindings for botan are not packaged)
  +Patch:          rcgen-fix-metadata.diff
  +Patch:          0001-fix-compilation-failure-of-OpenSSL-tests-on-32-bit-a.patch

   %cargo_prep
  +# drop example that depends on x509-parser support
  +rm examples/sign-leaf-with-ca.rs

All of this is reasonable. The other differences in the spec file are all
consequences of dropping features in rcgen-fix-metadata.diff.


Issues:
=======
- Package does not contain duplicates in %files.
  Note: warning: File listed twice:
  /usr/share/cargo/registry/rcgen-0.13.1/CHANGELOG.md
  See: https://docs.fedoraproject.org/en-US/packaging-
  guidelines/#_duplicate_files

  This is not a real issue; it is a consequence of resonable choices in
  rust2rpm.

- There is no patch upstream status for
  0001-fix-compilation-failure-of-OpenSSL-tests-on-32-bit-a.patch
  (https://docs.fedoraproject.org/en-US/packaging-guidelines/#_all_patches_should_have_an_upstream_bug_link_or_comment).
  Please add an appropriate comment to the spec file.


===== MUST items =====

Generic:
[x]: Package is licensed with an open-source compatible license and meets
     other legal requirements as defined in the legal section of Packaging
     Guidelines.
[x]: License field in the package spec file matches the actual license.
     Note: Checking patched sources after %prep for licenses. Licenses
     found: "Unknown or generated", "Apache License 2.0 and/or MIT
     License". 26 files have unknown license. Detailed output of
     licensecheck in /home/ben/fedora/review/2312228-rust-
     rcgen/licensecheck.txt
[x]: License file installed when any subpackage combination is installed.
[-]: If the package is under multiple licenses, the licensing breakdown
     must be documented in the spec.
[x]: %build honors applicable compiler flags or justifies otherwise.
[x]: Package contains no bundled libraries without FPC exception.
[x]: Changelog in prescribed format.
[x]: Sources contain only permissible code or content.
[-]: Package contains desktop file if it is a GUI application.
[x]: Development files must be in a -devel package
[x]: Package uses nothing in %doc for runtime.
[x]: Package consistently uses macros (instead of hard-coded directory
     names).
[x]: Package is named according to the Package Naming Guidelines.
[x]: Package does not generate any conflict.
[x]: Package obeys FHS, except libexecdir and /usr/target.
[-]: If the package is a rename of another package, proper Obsoletes and
     Provides are present.
[x]: Requires correct, justified where necessary.
[x]: Spec file is legible and written in American English.
[-]: Package contains systemd file(s) if in need.
[x]: Package is not known to require an ExcludeArch tag.
[x]: Package complies to the Packaging Guidelines
[x]: Package successfully compiles and builds into binary rpms on at least
     one supported primary architecture.
[x]: Package installs properly.
[x]: Rpmlint is run on all rpms the build produces.
     Note: There are rpmlint messages (see attachment).
[x]: If (and only if) the source package includes the text of the
     license(s) in its own file, then that file, containing the text of the
     license(s) for the package is included in %license.
[x]: The License field must be a valid SPDX expression.
[x]: Package requires other packages for directories it uses.
[x]: Package must own all directories that it creates.
[x]: Package does not own files or directories owned by other packages.
[x]: Package uses either %{buildroot} or $RPM_BUILD_ROOT
[x]: Package does not run rm -rf %{buildroot} (or $RPM_BUILD_ROOT) at the
     beginning of %install.
[x]: Macros in Summary, %description expandable at SRPM build time.
[x]: Dist tag is present.
[x]: Permissions on files are set properly.
[x]: Package must not depend on deprecated() packages.
[x]: Package use %makeinstall only when make install DESTDIR=... doesn't
     work.
[x]: Package is named using only allowed ASCII characters.
[x]: Package does not use a name that already exists.
[x]: Package is not relocatable.
[x]: Sources used to build the package match the upstream source, as
     provided in the spec URL.
[x]: Spec file name must match the spec package %{name}, in the format
     %{name}.spec.
[x]: File names are valid UTF-8.
[x]: Large documentation must go in a -doc subpackage. Large could be size
     (~1MB) or number of files.
     Note: Documentation size is 0 bytes in 0 files.
[x]: Packages must not store files under /srv, /opt or /usr/local

===== SHOULD items =====

Generic:
[-]: If the source package does not include license text(s) as a separate
     file from upstream, the packager SHOULD query upstream to include it.
[x]: Final provides and requires are sane (see attachments).
[-]: Fully versioned dependency in subpackages if applicable.
     Note: No Requires: %{name}%{?_isa} = %{version}-%{release} in rust-
     rcgen-devel , rust-rcgen+default-devel , rust-rcgen+crypto-devel ,
     rust-rcgen+pem-devel , rust-rcgen+ring-devel , rust-rcgen+zeroize-
     devel
[x]: Package functions as described.

     (Tests pass.)

[x]: Latest version is packaged.
[x]: Package does not include license text files separate from upstream.
[!]: Patches link to upstream bugs/comments/lists or are otherwise
     justified.
[-]: Sources are verified with gpgverify first in %prep if upstream
     publishes signatures.
     Note: gpgverify is not used.
[x]: Package should compile and build into binary rpms on all supported
     architectures.
[x]: %check is present and all tests pass.
[x]: Packages should try to preserve timestamps of original installed
     files.
[x]: Reviewer should test that the package builds in mock.
[x]: Buildroot is not present
[x]: Package has no %clean section with rm -rf %{buildroot} (or
     $RPM_BUILD_ROOT)
[x]: No file requires outside of /etc, /bin, /sbin, /usr/bin, /usr/sbin.
[x]: Packager, Vendor, PreReq, Copyright tags should not be in spec file
[x]: Sources can be downloaded from URI in Source: tag
[x]: SourceX is a working URL.
[x]: Spec use %global instead of %define unless justified.

===== EXTRA items =====

Generic:
[x]: Rpmlint is run on all installed packages.
     Note: There are rpmlint messages (see attachment).
[x]: Spec file according to URL is the same as in SRPM.


Rpmlint
-------
Checking: rust-rcgen-devel-0.13.1-1.fc42.noarch.rpm
          rust-rcgen+default-devel-0.13.1-1.fc42.noarch.rpm
          rust-rcgen+crypto-devel-0.13.1-1.fc42.noarch.rpm
          rust-rcgen+pem-devel-0.13.1-1.fc42.noarch.rpm
          rust-rcgen+ring-devel-0.13.1-1.fc42.noarch.rpm
          rust-rcgen+zeroize-devel-0.13.1-1.fc42.noarch.rpm
          rust-rcgen-0.13.1-1.fc42.src.rpm
=========================================================================================== rpmlint session starts ===========================================================================================
rpmlint: 2.5.0
configuration:
    /usr/lib/python3.12/site-packages/rpmlint/configdefaults.toml
    /etc/xdg/rpmlint/fedora-legacy-licenses.toml
    /etc/xdg/rpmlint/fedora-spdx-licenses.toml
    /etc/xdg/rpmlint/fedora.toml
    /etc/xdg/rpmlint/scoring.toml
    /etc/xdg/rpmlint/users-groups.toml
    /etc/xdg/rpmlint/warn-on-functions.toml
rpmlintrc: [PosixPath('/tmp/tmp8hdwm_kd')]
checks: 32, packages: 7

rust-rcgen+crypto-devel.noarch: W: no-documentation
rust-rcgen+default-devel.noarch: W: no-documentation
rust-rcgen+pem-devel.noarch: W: no-documentation
rust-rcgen+ring-devel.noarch: W: no-documentation
rust-rcgen+zeroize-devel.noarch: W: no-documentation
===================================================== 7 packages and 0 specfiles checked; 0 errors, 5 warnings, 32 filtered, 0 badness; has taken 0.4 s ======================================================




Rpmlint (installed packages)
----------------------------
============================ rpmlint session starts ============================
rpmlint: 2.5.0
configuration:
    /usr/lib/python3.13/site-packages/rpmlint/configdefaults.toml
    /etc/xdg/rpmlint/fedora-spdx-licenses.toml
    /etc/xdg/rpmlint/fedora.toml
    /etc/xdg/rpmlint/scoring.toml
    /etc/xdg/rpmlint/users-groups.toml
    /etc/xdg/rpmlint/warn-on-functions.toml
checks: 32, packages: 6

rust-rcgen+zeroize-devel.noarch: W: no-documentation
rust-rcgen+ring-devel.noarch: W: no-documentation
rust-rcgen+pem-devel.noarch: W: no-documentation
rust-rcgen+crypto-devel.noarch: W: no-documentation
rust-rcgen+default-devel.noarch: W: no-documentation
 6 packages and 0 specfiles checked; 0 errors, 5 warnings, 28 filtered, 0 badness; has taken 0.2 s 



Source checksums
----------------
https://crates.io/api/v1/crates/rcgen/0.13.1/download#/rcgen-0.13.1.crate :
  CHECKSUM(SHA256) this package     : 54077e1872c46788540de1ea3d7f4ccb1983d12f9aa909b234468676c1a36779
  CHECKSUM(SHA256) upstream package : 54077e1872c46788540de1ea3d7f4ccb1983d12f9aa909b234468676c1a36779


Requires
--------
rust-rcgen-devel (rpmlib, GLIBC filtered):
    (crate(rustls-pki-types/default) >= 1.4.1 with crate(rustls-pki-types/default) < 2.0.0~)
    (crate(time) >= 0.3.6 with crate(time) < 0.4.0~)
    (crate(yasna/default) >= 0.5.2 with crate(yasna/default) < 0.6.0~)
    (crate(yasna/std) >= 0.5.2 with crate(yasna/std) < 0.6.0~)
    (crate(yasna/time) >= 0.5.2 with crate(yasna/time) < 0.6.0~)
    cargo

rust-rcgen+default-devel (rpmlib, GLIBC filtered):
    cargo
    crate(rcgen)
    crate(rcgen/crypto)
    crate(rcgen/pem)
    crate(rcgen/ring)

rust-rcgen+crypto-devel (rpmlib, GLIBC filtered):
    cargo
    crate(rcgen)

rust-rcgen+pem-devel (rpmlib, GLIBC filtered):
    (crate(pem/default) >= 3.0.2 with crate(pem/default) < 4.0.0~)
    cargo
    crate(rcgen)

rust-rcgen+ring-devel (rpmlib, GLIBC filtered):
    (crate(ring/default) >= 0.17.0 with crate(ring/default) < 0.18.0~)
    cargo
    crate(rcgen)
    crate(rcgen/crypto)

rust-rcgen+zeroize-devel (rpmlib, GLIBC filtered):
    (crate(zeroize/default) >= 1.2.0 with crate(zeroize/default) < 2.0.0~)
    cargo
    crate(rcgen)



Provides
--------
rust-rcgen-devel:
    crate(rcgen)
    rust-rcgen-devel

rust-rcgen+default-devel:
    crate(rcgen/default)
    rust-rcgen+default-devel

rust-rcgen+crypto-devel:
    crate(rcgen/crypto)
    rust-rcgen+crypto-devel

rust-rcgen+pem-devel:
    crate(rcgen/pem)
    rust-rcgen+pem-devel

rust-rcgen+ring-devel:
    crate(rcgen/ring)
    rust-rcgen+ring-devel

rust-rcgen+zeroize-devel:
    crate(rcgen/zeroize)
    rust-rcgen+zeroize-devel



Generated by fedora-review 0.10.0 (e79b66b) last change: 2023-07-24
Command line :/usr/bin/fedora-review -b 2312228
Buildroot used: fedora-rawhide-x86_64
Active plugins: Shell-api, Generic
Disabled plugins: PHP, C/C++, Perl, Haskell, fonts, SugarActivity, R, Ocaml, Python, Java
Disabled flags: EXARCH, EPEL6, EPEL7, DISTTAG, BATCH

Comment 4 Fabio Valentini 2024-09-19 21:07:34 UTC
Thank you for the review!

I've submitted the fix for the compilation issue upstream:
https://github.com/rustls/rcgen/pull/290

Comment 5 Fedora Admin user for bugzilla script actions 2024-09-19 21:39:50 UTC
The Pagure repository was created at https://src.fedoraproject.org/rpms/rust-rcgen

Comment 6 Fabio Valentini 2024-09-19 22:35:24 UTC
Imported and built:
https://bodhi.fedoraproject.org/updates/FEDORA-2024-3a3de68056

Comment 7 Peter Robinson 2024-09-20 13:49:00 UTC
Thanks Fabio for getting this over the line, it's much appreciated.

Comment 8 Fabio Valentini 2024-09-23 11:10:55 UTC
No problem, hope it helps you with the pending parsec updates too.