Bug 2129336

Summary: Dates in chage command are incorrectly formatted
Product: [Fedora] Fedora Reporter: Simon Kobyda <skobyda>
Component: shadow-utilsAssignee: Iker Pedrosa <ipedrosa>
Status: CLOSED ERRATA QA Contact: Fedora Extras Quality Assurance <extras-qa>
Severity: unspecified Docs Contact:
Priority: unspecified    
Version: 37CC: ipedrosa, pvrabec, tm
Target Milestone: ---Keywords: Triaged
Target Release: ---   
Hardware: Unspecified   
OS: Unspecified   
Whiteboard: CockpitTest
Fixed In Version: shadow-utils-4.12.3-3.fc37 Doc Type: If docs needed, set a value
Doc Text:
Story Points: ---
Clone Of: Environment:
Last Closed: 2022-11-10 22:14:08 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:

Description Simon Kobyda 2022-09-23 11:50:39 UTC
Description of problem:

When running 'chage -l [userName]', fields "Last password change" and "Account expires" do not show a valid date

Version-Release number of selected component (if applicable):
shadow-utils 4.9

How reproducible:
always

Steps to Reproduce:

1. Create a user with expiration date:
# useradd scruffy -s /bin/bash -c Scruffy")
# echo scruffy:foobar | chpasswd
2. Set expiry date:
sudo usermod -e 2022-09-30 scruffy
3. chage -l scruffy


Actual results:

Last password change                                    : %b %d, %Y
Password expires                                        : never
Password inactive                                       : never
Account expires                                         : %b %d, %Y


Expected results:

Last password change                                    : Sep 23, 2022
Password expires                                        : never
Password inactive                                       : never
Account expires                                         : Sep 30, 2022


Additional info:

Comment 1 Simon Kobyda 2022-09-23 12:22:06 UTC
Additional info:
I just found github issue which describes what change caused the bug: https://github.com/shadow-maint/shadow/issues/564

Comment 2 Fedora Update System 2022-10-10 09:20:14 UTC
FEDORA-2022-d9b0e47341 has been submitted as an update to Fedora 37. https://bodhi.fedoraproject.org/updates/FEDORA-2022-d9b0e47341

Comment 3 Fedora Update System 2022-10-11 08:21:53 UTC
FEDORA-2022-d9b0e47341 has been pushed to the Fedora 37 testing repository.
Soon you'll be able to install the update with the following command:
`sudo dnf upgrade --enablerepo=updates-testing --refresh --advisory=FEDORA-2022-d9b0e47341`
You can provide feedback for this update here: https://bodhi.fedoraproject.org/updates/FEDORA-2022-d9b0e47341

See also https://fedoraproject.org/wiki/QA:Updates_Testing for more information on how to test updates.

Comment 4 Fedora Update System 2022-11-10 22:14:08 UTC
FEDORA-2022-d9b0e47341 has been pushed to the Fedora 37 stable repository.
If problem still persists, please make note of it in this bug report.