Bug 178609 - pkg_info(1): pkg_info -g fails to notice when files have been changed
Summary: pkg_info(1): pkg_info -g fails to notice when files have been changed
Status: Closed Overcome By Events
Alias: None
Product: Base System
Classification: Unclassified
Component: bin (show other bugs)
Version: 9.1-RELEASE
Hardware: Any Any
: Normal Affects Only Me
Assignee: freebsd-bugs mailing list
URL:
Keywords:
Depends on:
Blocks:
 
Reported: 2013-05-14 03:30 UTC by Ronald F. Guilmette
Modified: 2016-12-10 15:50 UTC (History)
1 user (show)

See Also:


Attachments

Note You need to log in before you can comment on or make changes to this bug.
Description Ronald F. Guilmette 2013-05-14 03:21:53 UTC
>Number:         178609
>Category:       bin
>Synopsis:       pkg_info -g fails to notice when files have been changed
>Confidential:   no
>Severity:       serious
>Priority:       medium
>Responsible:    freebsd-bugs
>State:          open
>Quarter:        
>Keywords:       
>Date-Required:
>Class:          sw-bug
>Submitter-Id:   current-users
>Arrival-Date:   Tue May 14 02:30:00 UTC 2013
>Closed-Date:
>Last-Modified:
>Originator:     Ronald F. Guilmette
>Release:        FreeBSD 9.1-RELEASE amd64
>Organization:
entr0py
>Environment:

FreeBSD 9.1-RELEASE amd64

>Description:

Running the "pkg_info -g" command can sometimes improperly result in
pkg_info reporting MD5 checksum mismatches for files that have simply
been modified, either by the user or by some other port or package
installation process, since the time when the file(s) in question
were first installed.  This is entirely inappropriate as it can cause
the system administrator to worry and fret that some file or files
that were installed as parts of ports or packages have gotten corrupted
somehow, when in fact the files in question, which may be locally con-
figurable config files have merely been locally configured.

More information on this problem can be found here:

http://lists.freebsd.org/pipermail/freebsd-ports/2013-May/083485.html

>How-To-Repeat:

portinstall p5-XML-SAX
portinstall p5-XML-LibXML
pkg_info -g 'p5-XML-SAX*'

(The second portinstall invocation above will result in the file named
/usr/local/lib/perl5/site_perl/5.14.2/XML/SAX/ParserDetails.ini which was
already installed as part of the p5-XML-SAX install to be diddled.  There
after, pkg_info -g 'p5-XML-SAX*' will claim that the file is failing its
MD5 checksum check.  This is arguably true, but is also entirely superfluous,
pointless, and unnerving for the typical sysadmin.)

>Fix:

Left as an exercise for the reader.
 
But seriously folks, a proper fix should be fairly trivial.  I will cook
up patches, if requested.

>Release-Note:
>Audit-Trail:
>Unformatted:
_______________________________________________
freebsd-bugs@freebsd.org mailing list
http://lists.freebsd.org/mailman/listinfo/freebsd-bugs
To unsubscribe, send any mail to "freebsd-bugs-unsubscribe@freebsd.org"
Comment 1 Ronald F. Guilmette 2013-05-14 03:30:00 UTC
Running the "pkg_info -g" command can sometimes improperly result in
pkg_info reporting MD5 checksum mismatches for files that have simply
been modified, either by the user or by some other port or package
installation process, since the time when the file(s) in question
were first installed.  This is entirely inappropriate as it can cause
the system administrator to worry and fret that some file or files
that were installed as parts of ports or packages have gotten corrupted
somehow, when in fact the files in question, which may be locally con-
figurable config files have merely been locally configured.

More information on this problem can be found here:

http://lists.freebsd.org/pipermail/freebsd-ports/2013-May/083485.html

Fix: 

Left as an exercise for the reader.
 
But seriously folks, a proper fix should be fairly trivial.  I will cook
up patches, if requested.
How-To-Repeat: 
portinstall p5-XML-SAX
portinstall p5-XML-LibXML
pkg_info -g 'p5-XML-SAX*'

(The second portinstall invocation above will result in the file named
/usr/local/lib/perl5/site_perl/5.14.2/XML/SAX/ParserDetails.ini which was
already installed as part of the p5-XML-SAX install to be diddled.  There
after, pkg_info -g 'p5-XML-SAX*' will claim that the file is failing its
MD5 checksum check.  This is arguably true, but is also entirely superfluous,
pointless, and unnerving for the typical sysadmin.)