[bug-notifications] [pkgutil 0004693]: multiple occurences of use_gpg lead to multiple checks

Mantis Bug Tracker noreply at opencsw.org
Fri Feb 25 13:58:34 CET 2011


A NOTE has been added to this issue. 
====================================================================== 
https://www.opencsw.org/mantis/view.php?id=4693 
====================================================================== 
Reported By:                flod
Assigned To:                bonivart
====================================================================== 
Project:                    pkgutil
Issue ID:                   4693
Category:                   regular use
Reproducibility:            always
Severity:                   trivial
Priority:                   normal
Status:                     feedback
====================================================================== 
Date Submitted:             2011-02-20 04:16 CET
Last Modified:              2011-02-25 13:58 CET
====================================================================== 
Summary:                    multiple occurences of use_gpg lead to multiple
checks
Description: 
With the update to CSWpkgutil 2.3,REV=2011.02.12 the behavior somehow
changed.
I always saw two gpg blocks on one machine:
pkgutil -c
Checking integrity of
/var/opt/csw/pkgutil/catalog.csw.informatik.uni-erlangen.de_csw_current_i386_5.10
with gpg.
gpg: Unterschrift vom 17. Februar 2011 18:27:53 MET mittels DSA-Schlüssel
ID E12E9D2F
gpg: Korrekte Unterschrift von "CSW Distribution Manager
<dm at opencsw.org>"
Checking integrity of
/var/opt/csw/pkgutil/catalog.csw.informatik.uni-erlangen.de_csw_current_i386_5.10
with gpg.
gpg: Unterschrift vom 17. Februar 2011 18:27:53 MET mittels DSA-Schlüssel
ID E12E9D2F
gpg: Korrekte Unterschrift von "CSW Distribution Manager
<dm at opencsw.org>"

It looks like there are two places for config files:
/etc/opt/csw/pkgutil.conf
/opt/csw/etc/pkgutil.conf

at the host both contained the configuration:
use_gpg=true
use_md5=true

I removed /etc/opt/csw/pkgutil.conf and the output is back to one block.

Nevertheless that was a somehow unexpected behaviour.
====================================================================== 

---------------------------------------------------------------------- 
 (0008828) flod (reporter) - 2011-02-25 13:58
 https://www.opencsw.org/mantis/view.php?id=4693#c8828 
---------------------------------------------------------------------- 
I can confirm that you are right. After removing duplicate entries I only
get one gpg block.

It is exactly as you described it, for every mirror= line one gets 3
additional lines with use_gpg=true.

I never tried to add experimental repositories, but these work there too
(but there seems to be no key that one can install).

Now back to the reason out of which i stumbled upon that.
I use something like:
...
pkgutil -c 2> "$ERRFILE" > "$OUTFILE"
...
cat "$OUTFILE" | tail +3 | grep -v SAME > "$RESFILE"

to get automated daily update reports.

The fixed number in the tail command is the problem.
One solution would be that I just use a more intelligent shell script with
sed.

But the question is still, what stable interface can one expect from
pkgutil for shell scripts.

It would help if one could rely on something like always one header line
and then the content on stdout. And all gpg/check output goes to stderr.

The state now is:
stdin - n lines info output (1 per mirror=), 1 header line, content
follows
stderr - gpg output, errors

And it hit me that n was not stable (whatever caused the duplicate
entries).



More information about the bug-notifications mailing list