Bug 960771 - Review Request: polkit-pkla-compat - polkit rules for compatibility with pklocalauthority
Summary: Review Request: polkit-pkla-compat - polkit rules for compatibility with pklo...
Keywords:
Status: CLOSED NEXTRELEASE
Alias: None
Product: Fedora
Classification: Fedora
Component: Package Review
Version: rawhide
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Alex G.
QA Contact: Fedora Extras Quality Assurance
URL:
Whiteboard:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2013-05-07 23:10 UTC by Miloslav Trmač
Modified: 2013-05-10 16:42 UTC (History)
4 users (show)

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Clone Of:
Environment:
Last Closed: 2013-05-10 16:15:55 UTC
Type: ---
Embargoed:
mitr: fedora-review?
gwync: fedora-cvs+


Attachments (Terms of Use)

Description Miloslav Trmač 2013-05-07 23:10:44 UTC
Spec URL: http://people.redhat.com/mitr/packaging/polkit-pkla-compat.spec
SRPM URL: http://people.redhat.com/mitr/packaging/polkit-pkla-compat-0.1-1.fc18.src.rpm

Description:
A polkit JavaScript rule and associated helpers that mostly provide
compatibility with the .pkla file format supported in polkit <= 0.105 for users
of later polkit releases.

Fedora Account System Username: mitr

Comment 1 Christopher Meng 2013-05-09 14:49:07 UTC
Maybe you can replace your source0 with 

https://fedorahosted.org/releases/p/o/%{name}/%{name}-%{version}.tar.xz

Comment 2 Miloslav Trmač 2013-05-09 14:55:54 UTC
(In reply to comment #1)
> Maybe you can replace your source0 with 
> 
> https://fedorahosted.org/releases/p/o/%{name}/%{name}-%{version}.tar.xz

Thanks for the comment.  I was considering it; in general, the package name is implied all over the spec file anyway and not expected to change.   In particular the  /p/o/ part of the path also hardcodes a part of the package name, so using %{name} would misleadingly imply flexibility in an aspect that is actually hardcoded and not flexible.

Comment 3 Christopher Meng 2013-05-09 15:11:59 UTC
(In reply to comment #2)
> (In reply to comment #1)
> > Maybe you can replace your source0 with 
> > 
> > https://fedorahosted.org/releases/p/o/%{name}/%{name}-%{version}.tar.xz
> 
> Thanks for the comment.  I was considering it; in general, the package name
> is implied all over the spec file anyway and not expected to change.   In
> particular the  /p/o/ part of the path also hardcodes a part of the package
> name, so using %{name} would misleadingly imply flexibility in an aspect
> that is actually hardcoded and not flexible.

In fact this is not important, so it doesn't matter~

ANd, you can simplify your files section:

%{_mandir}/man8/pkla-admin-identities.8*
%{_mandir}/man8/pkla-check-authorization.8*
%{_mandir}/man8/pklocalauthority.8*

with

%{_mandir}/man8/*.8*

This is optional, too.

Comment 4 Alex G. 2013-05-09 17:41:15 UTC
(In reply to comment #3)
> ANd, you can simplify your files section:
> 
> %{_mandir}/man8/pkla-admin-identities.8*
> %{_mandir}/man8/pkla-check-authorization.8*
> %{_mandir}/man8/pklocalauthority.8*
> 
> with
> 
> %{_mandir}/man8/*.8*
> 
> This is optional, too.

This has the advantage of looking cleaner. The disadvantage is that during a %{version} update, it's harder to catch a manpage going missing, or a new one with a conflicting name being added. Either forms are acceptable.

Comment 5 Alex G. 2013-05-09 18:58:50 UTC
Package Review
==============

Status: NEEDSWORK

Key:
[x] = Pass
[!] = Fail
[-] = Not applicable
[?] = Not evaluated
[ ] = Manual review needed


[x]: License field in the package spec file matches the actual license.
     Note: Checking patched sources after %prep for licenses. Licenses found:
     "Apache (v2.0)", "GPL (v2 or later)", "LGPL (v2 or later) (with incorrect
     FSF address)". 3 files have unknown license. Detailed output of
     licensecheck in /home/mrnuke/960771-polkit-pkla-compat/licensecheck.txt

> License:	LGPLv2+

The file identified as GPLv2 is ltmain.sh. That's part of the autotools build
system, so it's not a distributed with the binary rpm. The Apache licensed files
are also just part of the testsuite, and not included in the binary rpm. Please
consider putting a comment above the License tag explaining this.

===== ISSUES =====

> polkit-pkla-compat.x86_64: W: spelling-error Summary(en_US) pklocalauthority -> authoritarianism
False positive. Spelling OK.

> polkit-pkla-compat.x86_64: W: summary-not-capitalized C polkit rules for compatibility with pklocalauthority
"Rules for polkit compatibility with pklocalauthority"
"Legacy polkit rules for compatibility with pklocalauthority"
would silence this one.

> polkit-pkla-compat.x86_64: W: non-standard-gid /var/lib/polkit-1 polkitd
> polkit-pkla-compat.x86_64: W: non-standard-gid /etc/polkit-1/localauthority polkitd
> %dir %attr(0750,root,polkitd) %dir %{_sysconfdir}/polkit-1/localauthority
> %dir %attr(0750,root,polkitd) %{_localstatedir}/lib/polkit-1
Did you mean polkituser?

> polkit-pkla-compat.x86_64: E: non-standard-dir-perm /var/lib/polkit-1 0750L
> polkit-pkla-compat.x86_64: E: non-standard-dir-perm /etc/polkit-1/localauthority 0750L
As rpmlint explains, "A standard directory should have permission set to 0755."

> polkit-pkla-compat.x86_64: E: incorrect-fsf-address /usr/share/doc/polkit-pkla-compat-0.1/COPYING
This file contains an older address for FSF. Please contact upstream to fix
this, but do NOT patch the license file yourself.


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

C/C++:
[x]: Package does not contain kernel modules.
[x]: Package contains no static executables.
[x]: Package does not contain any libtool archives (.la)
[x]: Rpath absent or only used for internal libs.

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]: %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.
[-]: Development files must be in a -devel package
[x]: Package requires other packages for directories it uses.
[x]: Package uses nothing in %doc for runtime.
[x]: Package is not known to require ExcludeArch.
[ ]: Package complies to the Packaging Guidelines
[x]: License field in the package spec file matches the actual license.
     Note: Checking patched sources after %prep for licenses. Licenses found:
     "Apache (v2.0)", "GPL (v2 or later)", "LGPL (v2 or later) (with incorrect
     FSF address)". 3 files have unknown license. Detailed output of
     licensecheck in /home/mrnuke/960771-polkit-pkla-compat/licensecheck.txt
[x]: Package consistently uses macro is (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]: Package must own all directories that it creates.
[x]: Package does not own files or directories owned by other packages.
[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]: Useful -debuginfo package or justification otherwise.
[x]: Large documentation must go in a -doc subpackage.
     Note: Documentation size is 40960 bytes in 4 files.
[x]: All build dependencies are listed in BuildRequires, except for any that
     are listed in the exceptions section of Packaging Guidelines.
[x]: Package does not run rm -rf %{buildroot} (or $RPM_BUILD_ROOT) at the
     beginning of %install.
[x]: %config files are marked noreplace or the reason is justified.
[x]: Each %files section contains %defattr if rpm < 4.4
[x]: Macros in Summary, %description expandable at SRPM build time.
[x]: Package does not contain duplicates in %files.
[x]: Permissions on files are set properly.
[x]: Fully versioned dependency in subpackages, if present.
[x]: Spec file lacks Packager, Vendor, PreReq tags.
[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 %doc.
[x]: Package use %makeinstall only when make install' ' DESTDIR=... doesn't
     work.
[x]: Package is named using only allowed ASCII characters.
[x]: No %config files under /usr.
[x]: Package do not use a name that already exist
[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]: Packages must not store files under /srv, /opt or /usr/local
[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).

===== 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).
[?]: Package functions as described.
[x]: Latest version is packaged.
[x]: Package does not include license text files separate from upstream.
[-]: Description and summary sections in the package spec file contains
     translations for supported Non-English languages, if available.
[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]: Sources can be downloaded from URI in Source: tag
[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]: Dist tag is present.
[x]: No file requires outside of /etc, /bin, /sbin, /usr/bin, /usr/sbin.
[x]: Uses parallel make.
[x]: SourceX tarball generation or download is documented.
[x]: SourceX is a working URL.
[x]: Spec use %global instead of %define.

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

Generic:
[x]: Large data in /usr/share should live in a noarch subpackage if package is
     arched.
[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: polkit-pkla-compat-0.1-1.fc20.x86_64.rpm
polkit-pkla-compat.x86_64: W: spelling-error Summary(en_US) pklocalauthority -> authoritarianism
polkit-pkla-compat.x86_64: W: summary-not-capitalized C polkit rules for compatibility with pklocalauthority
polkit-pkla-compat.x86_64: W: non-standard-gid /var/lib/polkit-1 polkitd
polkit-pkla-compat.x86_64: E: non-standard-dir-perm /var/lib/polkit-1 0750L
polkit-pkla-compat.x86_64: E: incorrect-fsf-address /usr/share/doc/polkit-pkla-compat-0.1/COPYING
polkit-pkla-compat.x86_64: W: non-standard-gid /etc/polkit-1/localauthority polkitd
polkit-pkla-compat.x86_64: E: non-standard-dir-perm /etc/polkit-1/localauthority 0750L
1 packages and 0 specfiles checked; 3 errors, 4 warnings.




Rpmlint (installed packages)
----------------------------
# rpmlint polkit-pkla-compat
polkit-pkla-compat.x86_64: W: spelling-error Summary(en_US) pklocalauthority -> authoritarianism
polkit-pkla-compat.x86_64: W: summary-not-capitalized C polkit rules for compatibility with pklocalauthority
polkit-pkla-compat.x86_64: W: non-standard-gid /var/lib/polkit-1 polkitd
polkit-pkla-compat.x86_64: E: non-standard-dir-perm /var/lib/polkit-1 0750L
polkit-pkla-compat.x86_64: E: incorrect-fsf-address /usr/share/doc/polkit-pkla-compat-0.1/COPYING
polkit-pkla-compat.x86_64: W: non-standard-gid /etc/polkit-1/localauthority polkitd
polkit-pkla-compat.x86_64: E: non-standard-dir-perm /etc/polkit-1/localauthority 0750L
1 packages and 0 specfiles checked; 3 errors, 4 warnings.
# echo 'rpmlint-done:'



Requires
--------
polkit-pkla-compat (rpmlib, GLIBC filtered):
    config(polkit-pkla-compat)
    libc.so.6()(64bit)
    libgio-2.0.so.0()(64bit)
    libglib-2.0.so.0()(64bit)
    libgobject-2.0.so.0()(64bit)
    libpolkit-gobject-1.so.0()(64bit)
    libpthread.so.0()(64bit)
    polkit
    rtld(GNU_HASH)



Provides
--------
polkit-pkla-compat:
    config(polkit-pkla-compat)
    polkit-pkla-compat
    polkit-pkla-compat(x86-64)



MD5-sum check
-------------
https://fedorahosted.org/releases/p/o/polkit-pkla-compat/polkit-pkla-compat-0.1.tar.xz :
  CHECKSUM(SHA256) this package     : cbf804dfc235b40f2f7ea694c37d577f1cb5d3042d53063de1753016a46c39af
  CHECKSUM(SHA256) upstream package : cbf804dfc235b40f2f7ea694c37d577f1cb5d3042d53063de1753016a46c39af


Generated by fedora-review 0.4.0 (660ce56) last change: 2013-01-29
Buildroot used: fedora-rawhide-x86_64
Command line :/bin/fedora-review -b 960771

Comment 6 Miloslav Trmač 2013-05-09 19:25:51 UTC
Thanks for the review.

(In reply to comment #5)
> Status: NEEDSWORK

> [x]: License field in the package spec file matches the actual license.
>      Note: Checking patched sources after %prep for licenses. Licenses found:
>      "Apache (v2.0)", "GPL (v2 or later)", "LGPL (v2 or later) (with
> incorrect
>      FSF address)". 3 files have unknown license. Detailed output of
>      licensecheck in /home/mrnuke/960771-polkit-pkla-compat/licensecheck.txt
> 
> > License:	LGPLv2+
> 
> The file identified as GPLv2 is ltmain.sh. That's part of the autotools build
> system, so it's not a distributed with the binary rpm. The Apache licensed files
> are also just part of the testsuite, and not included in the binary rpm. Please
> consider putting a comment above the License tag explaining this.

Added.


> > polkit-pkla-compat.x86_64: W: summary-not-capitalized C polkit rules for compatibility with pklocalauthority
> "Rules for polkit compatibility with pklocalauthority"
> "Legacy polkit rules for compatibility with pklocalauthority"
> would silence this one.

Fair enough, modified to
> Rules for polkit to add compatibility with pklocalauthority

> > polkit-pkla-compat.x86_64: W: non-standard-gid /var/lib/polkit-1 polkitd
> > polkit-pkla-compat.x86_64: W: non-standard-gid /etc/polkit-1/localauthority polkitd
> > %dir %attr(0750,root,polkitd) %dir %{_sysconfdir}/polkit-1/localauthority
> > %dir %attr(0750,root,polkitd) %{_localstatedir}/lib/polkit-1
> Did you mean polkituser?

No, the group name is literally "polkitd".


> > polkit-pkla-compat.x86_64: E: non-standard-dir-perm /var/lib/polkit-1 0750L
> > polkit-pkla-compat.x86_64: E: non-standard-dir-perm /etc/polkit-1/localauthority 0750L
> As rpmlint explains, "A standard directory should have permission set to
> 0755."
These permissions are intentional; the authorization policy is intended to not be accessible to any user but root, and only readable by the polkitd daemon.  Upstream README and notes at bottom of configure.ac recommend the same thing.


> > polkit-pkla-compat.x86_64: E: incorrect-fsf-address /usr/share/doc/polkit-pkla-compat-0.1/COPYING
> This file contains an older address for FSF. Please contact upstream to fix
> this, but do NOT patch the license file yourself.
Updated upstream.


Updated package:
http://people.redhat.com/mitr/packaging/polkit-pkla-compat-0.1-2.fc18.src.rpm
http://people.redhat.com/mitr/packaging/polkit-pkla-compat.spec (overwritten)

Comment 7 Alex G. 2013-05-09 20:24:26 UTC
Great! I see no further blockers.

The package is APPROVED.

Comment 8 Miloslav Trmač 2013-05-10 15:29:12 UTC
New Package SCM Request
=======================
Package Name: polkit-pkla-compat
Short Description: Rules for polkit to add compatibility with pklocalauthority
Owners: mitr
Branches: f19
InitialCC:

Comment 9 Gwyn Ciesla 2013-05-10 15:31:17 UTC
Git done (by process-git-requests).

Comment 10 Miloslav Trmač 2013-05-10 16:15:55 UTC
Thanks!

rawhide build done.

Comment 11 Alex G. 2013-05-10 16:42:58 UTC
> Miloslav Trmač <email_removed> changed:
>            What    |Removed                     |Added
> ----------------------------------------------------------------------------
>             Status|NEW                         |CLOSED
>         Resolution|---                         |NEXTRELEASE
>        Last Closed|                            |2013-05-10 12:15:55

You don't need to close review bugs manually. Bodhi will do it automatically once the package hits stable. :)


Note You need to log in before you can comment on or make changes to this bug.