Note: This bug is displayed in read-only format because
the product is no longer active in Red Hat Bugzilla.
RHEL Engineering is moving the tracking of its product development work on RHEL 6 through RHEL 9 to Red Hat Jira (issues.redhat.com). If you're a Red Hat customer, please continue to file support cases via the Red Hat customer portal. If you're not, please head to the "RHEL project" in Red Hat Jira and file new tickets here. Individual Bugzilla bugs in the statuses "NEW", "ASSIGNED", and "POST" are being migrated throughout September 2023. Bugs of Red Hat partners with an assigned Engineering Partner Manager (EPM) are migrated in late September as per pre-agreed dates. Bugs against components "kernel", "kernel-rt", and "kpatch" are only migrated if still in "NEW" or "ASSIGNED". If you cannot log in to RH Jira, please consult article #7032570. That failing, please send an e-mail to the RH Jira admins at rh-issues@redhat.com to troubleshoot your issue as a user management inquiry. The email creates a ServiceNow ticket with Red Hat. Individual Bugzilla bugs that are migrated will be moved to status "CLOSED", resolution "MIGRATED", and set with "MigratedToJIRA" in "Keywords". The link to the successor Jira issue will be found under "Links", have a little "two-footprint" icon next to it, and direct you to the "RHEL project" in Red Hat Jira (issue links are of type "https://issues.redhat.com/browse/RHEL-XXXX", where "X" is a digit). This same link will be available in a blue banner at the top of the page informing you that that bug has been migrated.
This bug is created as a clone of upstream ticket:
https://fedorahosted.org/389/ticket/47353
We have seen some instances of PassSync failing to open it's changelog (passhook.dat) even though it exists. In the PassSync log, you will see looping messages like this:
04/21/13 18:02:49: No entries yet
04/22/13 05:55:49: No entries yet
04/22/13 06:11:24: No entries yet
04/22/13 06:47:02: No entries yet
04/22/13 07:51:44: No entries yet
If you look in the PassSync code, this message only occurs when we attempt to run SyncPasswords(), which is only executed on start-up, or when we receive a notification from passhook.dll. The fact that this message loops without PassSync restarting means that passhook.dll is writing changes to the changelog and properly notifying PassSync that we need to process the changes. If you trace the code further, you will see that "No entries yet" only occurs when loadSet() returns 1. The loadSet() function only returns 1 when the open() fails with ENOENT.
When this problem happens, we know that the changelog file exists since passhook.dll is writing changes there and notifying us. This leads me to believe that PassSync is using an incorrect filename when it tries to open the changelog. The filename is built up dynamically when PassSync is started. It is made of of the "%SystemRoot%" environment variable plus a hard coded path:
ExpandEnvironmentStrings("%SystemRoot%", sysPath, SYNCSERV_BUF_SIZE);
_snprintf(dataFilename, SYNCSERV_BUF_SIZE, "%s\\system32\\passhook.dat", sysPath);
I believe that "%SystemRoot%" is not being properly expanded when this problem occurs, but I'm not sure what triggers this to happen. Regardless, I think we need to handle things better when this expansion fails. If we can't expand this variable, we should probably fail to start the PassSync service. It would also be helpful to log the filename we are using when we encounter a problem like the ENOENT error.