Bug 137497 - Root home dir hardcoded in gpgUtils.py, should be ~root, not /root
Summary: Root home dir hardcoded in gpgUtils.py, should be ~root, not /root
Status: CLOSED DUPLICATE of bug 135246
Alias: None
Product: Red Hat Enterprise Linux 2.1
Classification: Red Hat
Component: up2date   
(Show other bugs)
Version: 2.1
Hardware: i686 Linux
medium
medium
Target Milestone: ---
Assignee: Adrian Likins
QA Contact: Fanny Augustin
URL:
Whiteboard:
Keywords:
Depends On:
Blocks:
TreeView+ depends on / blocked
 
Reported: 2004-10-28 20:56 UTC by Trever Furnish
Modified: 2007-11-30 22:06 UTC (History)
0 users

Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
Environment:
Last Closed: 2006-02-21 19:06:41 UTC
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)

Description Trever Furnish 2004-10-28 20:56:03 UTC
From Bugzilla Helper:
User-Agent: Mozilla/5.0 (Windows; U; Windows NT 5.0; en-US; rv:1.7)
Gecko/20040616

Description of problem:
If you change the home directory of the root account, up2date is no
longer able to verify gpg signatures because it has a hardcoded value
starting with /root instead of ~root in
/usr/share/rhn/up2date_client/gpgUtils.py.  The line causing the
problem is:

gpg_home_dir = "/root/.gnupg"

That ought to be instead:

gpg_home_dir = "~root/.gnupg"

OR something that is derived by checking the home directory of the
root user.  I'm not a python programmer - I trust you'll know the
right thing.



Version-Release number of selected component (if applicable):
2.9.3

How reproducible:
Always

Steps to Reproduce:
1. cd / && usermod -d /sysadm -m root
2. log out and log back in (to get the updated environment)
3. up2date --nox --update
    

Actual Results:  Errors are printed from gpg at the beginning of the
process:
gpg: fatal: /root/.gnupg: can't create directory: No such file or
directory
secmem usage: 1408/1408 bytes in 2/2 blocks of pool 1408/16384
gpg: fatal: /root/.gnupg: can't create directory: No such file or
directory
secmem usage: 1408/1408 bytes in 2/2 blocks of pool 1408/16384
gpg: fatal: /root/.gnupg: can't create directory: No such file or
directory
secmem usage: 1408/1408 bytes in 2/2 blocks of pool 1408/16384
gpg: fatal: /root/.gnupg: can't create directory: No such file or
directory
secmem usage: 1408/1408 bytes in 2/2 blocks of pool 1408/16384

Later in the process all package updates fail because of GPG problems.


Expected Results:  Packages should have been downloaded and
successfully verified by gpg, then installed.

Additional info:

Changing the /root to ~root Works For Me.  Would really prefer not to
have to do that though, since that's going to cause package
verification headaches in the future.

Setting GNUPGHOME does not help - it's overridden by a command-line
flag when up2date runs gpg.

Comment 1 Trever Furnish 2004-10-28 20:57:45 UTC
A workaround is to symlink the original ~root path to the new ~root
path, though that's annoying.

Comment 2 Aleksey Nogin 2004-11-29 16:08:46 UTC

*** This bug has been marked as a duplicate of 135246 ***

Comment 3 Red Hat Bugzilla 2006-02-21 19:06:41 UTC
Changed to 'CLOSED' state since 'RESOLVED' has been deprecated.


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