Bug 712295

Summary: /usr/bin/certwatch unnecessary
Product: [Fedora] Fedora Reporter: JW <ohtmvyyn>
Component: crypto-utilsAssignee: Joe Orton <jorton>
Status: CLOSED WONTFIX QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 19CC: emaldona, jorton, philipp
Target Milestone: ---Keywords: Reopened
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2014-01-27 10:49:58 UTC Type: ---
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:

Description JW 2011-06-10 07:31:27 UTC
Description of problem:
/usr/bin/certwatch should not exists ... there are sufficient command-line tools to do the job

Version-Release number of selected component (if applicable):
crypto-utils-2.4.1-27

How reproducible:
Always

Steps to Reproduce:
1. file /usr/bin/certwatch
  
Actual results:
1. /usr/bin/certwatch: ELF 32-bit LSB executable

Expected results:
1. /usr/bin/certwatch: ERROR: No such file or directory

Additional info:
There was once an operating system named Unix where the concept was that tools were simple, reusable, and the output of one command could easily be fed into another to achieve the desired result.

The certwatch program seems to be mainly used by crond via a script in /etc/cron.daily/certwach.

It would be just as easy to insert commands in /etc/cron.daily/certwatch such as:

expiry=`openssl x509 -noout -enddate -in xxxx.crt | perl -MDate::Parse -ne 'print str2time(+(split(/=/,$_,2))[1]);'`

and perform some simple integer comparisons with:

now=`date +%s`

Why go to the trouble of creating a binary to perform this trivial task, especially as there is already a script around /usr/bin/certwatch?

Comment 1 Elio Maldonado Batiz 2011-07-06 16:17:20 UTC
How shall we deal with the case Apache uses mod_nss and the certs are in the nss database instead of flat files.

Comment 2 JW 2011-07-08 14:29:31 UTC
Step 1. Extract the certs from nss database
Step 2. Check the certs with openssl

Comment 3 Joe Orton 2012-04-23 19:36:31 UTC
Patches welcome.

Comment 4 Fedora End Of Life 2012-08-07 16:37:44 UTC
This message is a notice that Fedora 15 is now at end of life. Fedora
has stopped maintaining and issuing updates for Fedora 15. It is
Fedora's policy to close all bug reports from releases that are no
longer maintained. At this time, all open bugs with a Fedora 'version'
of '15' have been closed as WONTFIX.

(Please note: Our normal process is to give advanced warning of this
occurring, but we forgot to do that. A thousand apologies.)

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, feel free to reopen
this bug and simply change the 'version' to a later Fedora version.

Bug Reporter: Thank you for reporting this issue and we are sorry that
we were unable to fix it before Fedora 15 reached end of life. If you
would still like to see this bug fixed and are able to reproduce it
against a later version of Fedora, you are encouraged to click on
"Clone This Bug" (top right of this page) and open it against that
version of Fedora.

Although we aim to fix as many bugs as possible during every release's
lifetime, sometimes those efforts are overtaken by events. Often a
more recent Fedora release includes newer upstream software that fixes
bugs or makes them obsolete.

The process we are following is described here:
http://fedoraproject.org/wiki/BugZappers/HouseKeeping

Comment 5 JW 2012-08-08 00:05:22 UTC
still a problem

Comment 6 Fedora End Of Life 2013-07-04 05:56:28 UTC
This message is a reminder that Fedora 17 is nearing its end of life.
Approximately 4 (four) weeks from now Fedora will stop maintaining
and issuing updates for Fedora 17. It is Fedora's policy to close all
bug reports from releases that are no longer maintained. At that time
this bug will be closed as WONTFIX if it remains open with a Fedora 
'version' of '17'.

Package Maintainer: If you wish for this bug to remain open because you
plan to fix it in a currently maintained version, simply change the 'version' 
to a later Fedora version prior to Fedora 17's end of life.

Bug Reporter:  Thank you for reporting this issue and we are sorry that 
we may not be able to fix it before Fedora 17 is end of life. If you 
would still like  to see this bug fixed and are able to reproduce it 
against a later version  of Fedora, you are encouraged  change the 
'version' to a later Fedora version prior to Fedora 17's end of life.

Although we aim to fix as many bugs as possible during every release's 
lifetime, sometimes those efforts are overtaken by events. Often a 
more recent Fedora release includes newer upstream software that fixes 
bugs or makes them obsolete.

Comment 7 Philip Prindeville 2013-10-28 17:02:03 UTC
(In reply to JW from comment #0)

> Why go to the trouble of creating a binary to perform this trivial task,
> especially as there is already a script around /usr/bin/certwatch?

Because (a) there are a lot of system administrators who aren't as up on security as they should be, (b) because the cost of expired certificates is significant enough to justify extra tooling to make sure it doesn't happen, (c) because the security of the Internet in general is weak enough that we should go for all the low-hanging fruit that we can to make it more secure.

Comment 8 Joe Orton 2014-01-27 10:49:58 UTC
Again absent patches to implement this better -> WONTFIX.