Bug 1716955 (CVE-2018-20839) - CVE-2018-20839 systemd: mishandling of the current keyboard mode check leading to passwords being disclosed in cleartext to attacker
Summary: CVE-2018-20839 systemd: mishandling of the current keyboard mode check leadin...
Keywords:
Status: CLOSED NOTABUG
Alias: CVE-2018-20839
Product: Security Response
Classification: Other
Component: vulnerability
Version: unspecified
Hardware: All
OS: Linux
medium
medium
Target Milestone: ---
Assignee: Red Hat Product Security
QA Contact:
URL:
Whiteboard:
Depends On: 1716956
Blocks: 1716957
TreeView+ depends on / blocked
 
Reported: 2019-06-04 13:03 UTC by Marian Rehak
Modified: 2024-10-24 04:43 UTC (History)
9 users (show)

Fixed In Version:
Clone Of:
Environment:
Last Closed: 2020-04-15 15:09:51 UTC
Embargoed:


Attachments (Terms of Use)

Description Marian Rehak 2019-06-04 13:03:17 UTC
systemd 242 changes the VT1 mode upon a logout, which allows attackers to read cleartext passwords in certain circumstances, such as watching a shutdown, or using Ctrl-Alt-F1 and Ctrl-Alt-F2. This occurs because the KDGKBMODE (aka current keyboard mode) check is mishandled.

Ubuntu bug report:

https://bugs.launchpad.net/ubuntu/+source/systemd/+bug/1803993

Upstream commit:

https://github.com/systemd/systemd/pull/12378

Comment 1 Marian Rehak 2019-06-04 13:03:30 UTC
Created systemd tracking bugs for this issue:

Affects: fedora-all [bug 1716956]

Comment 4 Riccardo Schirone 2019-06-06 15:34:59 UTC
The fix implemented in [1] seems to cause a regression, which was reported upstream at [2]. It is still not clear what the right fix for this CVE will be, as there is a PR[3] under review to revert the fix [1]

[1] https://github.com/systemd/systemd/pull/12378
[2] https://github.com/systemd/systemd/issues/12616
[3] https://github.com/systemd/systemd/pull/12739

Comment 5 Riccardo Schirone 2019-06-07 13:03:48 UTC
To see the leaked passwords in VT1, the attacker needs to either be root or be physically in front of the computer (AV:P). Also, it's required for the victim users to be physically in front of the computer as well and login after the vulnerability is triggered (UI:R).

Comment 6 Riccardo Schirone 2019-06-07 17:27:17 UTC
Given what said in comment 5, I'm lowering the Impact to Moderate.

Comment 10 Riccardo Schirone 2019-11-08 10:07:48 UTC
The fix that supposedly should had fixed this CVE was actually reverted upstream in https://github.com/systemd/systemd/commit/ad3f86e6a4e5f2d5d64c81f9a30f250b624284fa .

Comment 13 Riccardo Schirone 2020-04-15 15:09:51 UTC
Closing the flaw bug as NOTABUG because the supposed fix was actually reverted and it's not clear whether the issue was really in systemd or not.
See also:
https://github.com/systemd/systemd/pull/13109
https://gitlab.freedesktop.org/xorg/xserver/issues/857


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