Bug 1145249

Summary: Please backport the upstream shadow.aug
Product: Red Hat Enterprise Linux 7 Reporter: Pino Toscano <ptoscano>
Component: augeasAssignee: Dominic Cleal <dcleal>
Status: CLOSED ERRATA QA Contact: Virtualization Bugs <virt-bugs>
Severity: low Docs Contact:
Priority: medium    
Version: 7.0CC: leiwang, lkong
Target Milestone: rc   
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard:
Fixed In Version: augeas-1.1.0-16.el7 Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 1160261 (view as bug list) Environment:
Last Closed: 2015-03-05 09:26:06 UTC Type: Bug
Regression: --- Mount Type: ---
Documentation: --- CRM:
Verified Versions: Category: ---
oVirt Team: --- RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: --- Target Upstream Version:
Embargoed:
Bug Depends On:    
Bug Blocks: 1144927, 1160261    

Description Pino Toscano 2014-09-22 15:50:38 UTC
Description of problem:
Since few weeks (development release 1.27.38), libguestfs uses a copy of the upstream shadow.aug lens to properly edit /etc/shadow, like editing password fields or removing users.
We did that (carrying a copy) because this lens is pretty new ([1][2]), and it is not part of any upstream release.

Thus, it would be nice if the Augeas in RHEL 7.1 could provide a backport of it, which would ease our implementation a bit (especially because libguestds 1.27.x/1.28.x is in RHEL 7.1).

[1] https://github.com/hercules-team/augeas/commit/03f24b24ed13fb1d01717a9247bf8a2cea5f0b71
[2] https://github.com/hercules-team/augeas/commit/b6090f1782e6093666f60d60ad7d79fd488cc8d0

Version-Release number of selected component (if applicable):
1.1.0-15.el7

Comment 3 Lingfei Kong 2014-11-10 08:42:12 UTC
Verify with augeas-1.1.0-16.el7

Steps to verify:

1. #find /usr/share/augeas/lenses -name shadow.aug 
/usr/share/augeas/lenses/dist/shadow.aug

2. #augtool print /augeas/files/etc/shadow
/augeas/files/etc/shadow
/augeas/files/etc/shadow/path = "/files/etc/shadow"
/augeas/files/etc/shadow/mtime = "1414466594"
/augeas/files/etc/shadow/lens = "@Shadow"
/augeas/files/etc/shadow/lens/info = "/usr/share/augeas/lenses/dist/shadow.aug:66.17-.40:"

3. #augtool print /files/etc/shadow
/files/etc/shadow
/files/etc/shadow/root
/files/etc/shadow/root/password = "$1$pDj5hfT7$SKwmFsQdYEnyCJ5qKphwE1"
/files/etc/shadow/root/lastchange_date = "16338"
/files/etc/shadow/root/minage_days = "0"
/files/etc/shadow/root/maxage_days = "99999"
/files/etc/shadow/root/warn_days = "7"
/files/etc/shadow/root/inactive_days = ""
/files/etc/shadow/root/expire_date = ""
/files/etc/shadow/root/flag = ""
/files/etc/shadow/bin
[...]

Comment 5 errata-xmlrpc 2015-03-05 09:26:06 UTC
Since the problem described in this bug report should be
resolved in a recent advisory, it has been closed with a
resolution of ERRATA.

For information on the advisory, and where to find the updated
files, follow the link below.

If the solution does not work for you, open a new bug report.

https://rhn.redhat.com/errata/RHBA-2015-0399.html