Bugzilla will be upgraded to version 5.0. The upgrade date is tentatively scheduled for 2 December 2018, pending final testing and feedback.
Bug 747317 - yppasswdd returns success when /etc/passwd.adjunct is not writable
yppasswdd returns success when /etc/passwd.adjunct is not writable
Status: CLOSED ERRATA
Product: Red Hat Enterprise Linux 5
Classification: Red Hat
Component: ypserv (Show other bugs)
5.8
Unspecified Unspecified
unspecified Severity unspecified
: rc
: ---
Assigned To: Honza Horak
Petr Sklenar
: Patch
Depends On:
Blocks: 747334 747335
  Show dependency treegraph
 
Reported: 2011-10-19 09:25 EDT by Honza Horak
Modified: 2012-02-21 00:53 EST (History)
3 users (show)

See Also:
Fixed In Version:
Doc Type: Bug Fix
Doc Text:
Story Points: ---
Clone Of:
: 747334 747335 (view as bug list)
Environment:
Last Closed: 2012-02-21 00:53:50 EST
Type: ---
Regression: ---
Mount Type: ---
Documentation: ---
CRM:
Verified Versions:
Category: ---
oVirt Team: ---
RHEL 7.3 requirements from Atomic Host:
Cloudforms Team: ---


Attachments (Terms of Use)
proposed patch that reports failure when rename() fails (1.28 KB, patch)
2011-10-19 10:14 EDT, Honza Horak
no flags Details | Diff


External Trackers
Tracker ID Priority Status Summary Last Updated
Red Hat Product Errata RHBA-2012:0205 normal SHIPPED_LIVE ypserv bug fix and enhancement update 2012-02-20 09:53:39 EST

  None (edit)
Description Honza Horak 2011-10-19 09:25:09 EDT
Description of problem:
If rpc.yppasswdd cannot write into /etc/passwd.adjunct (or /etc/shadow in standard configuration) because of wrong SELinux context, rpc.yppasswdd still reports success, which is wrong.

Version-Release number of selected component (if applicable):
ypserv-2.19-8.el5

How reproducible:
every-time

Steps to Reproduce:
1. change context of /etc/shadow or /etc/passwd.adjunct to wrong one
# chcon -t etc_t /etc/passwd.adjunct
2. try to change password of a user using yppasswd
3. /etc/passwd.adjunct is not updated and a message "Cannot create backup file /etc/passwd.adjunct.OLD: Permission denied" is logged into /var/log/messages
  
Actual results:
yppasswd returns success, so as rpc.yppasswdd in /var/log/messages

Expected results:
yppasswd returns failure, so as rpc.yppasswdd in /var/log/messages
Comment 1 Honza Horak 2011-10-19 10:14:06 EDT
Created attachment 529012 [details]
proposed patch that reports failure when rename() fails
Comment 2 Honza Horak 2011-10-25 04:00:00 EDT
Just a note that this bug is easy to test with only slightly modified /CoreOS/ypserv/Regression/rfe-yppasswdd-support-passwd-adjunct.
Comment 4 Honza Horak 2011-10-25 09:50:35 EDT
Committed to CVS, moving to modified. 
http://post-office.corp.redhat.com/archives/cvs-commits-list/2011-October/msg05734.html
Comment 7 errata-xmlrpc 2012-02-21 00:53:50 EST
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.

http://rhn.redhat.com/errata/RHBA-2012-0205.html

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