Bug 1668521 (CVE-2019-3842)
Summary: | CVE-2019-3842 systemd: Spoofing of XDG_SEAT allows for actions to be checked against "allow_active" instead of "allow_any" | ||
---|---|---|---|
Product: | [Other] Security Response | Reporter: | Sam Fowler <sfowler> |
Component: | vulnerability | Assignee: | Red Hat Product Security <security-response-team> |
Status: | CLOSED ERRATA | QA Contact: | |
Severity: | medium | Docs Contact: | |
Priority: | medium | ||
Version: | unspecified | CC: | apmukher, jkalliya, lnykryn, lpoetter, msekleta, psampaio, security-response-team, s, systemd-maint-list, systemd-maint, zbyszek, zjedrzej |
Target Milestone: | --- | Keywords: | Security |
Target Release: | --- | ||
Hardware: | All | ||
OS: | Linux | ||
Whiteboard: | |||
Fixed In Version: | systemd 242 | Doc Type: | If docs needed, set a value |
Doc Text: |
It was discovered that pam_systemd does not properly sanitize the environment before using the XDG_SEAT variable. It is possible for an attacker, in some particular configurations, to set a XDG_SEAT environment variable which allows for commands to be checked against polkit policies using the "allow_active" element rather than "allow_any".
|
Story Points: | --- |
Clone Of: | Environment: | ||
Last Closed: | 2021-05-18 20:33:43 UTC | Type: | --- |
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: | 1685443, 1687514, 1698045, 1936866, 1968647, 1968648, 1968649 | ||
Bug Blocks: | 1668522 |
Description
Sam Fowler
2019-01-23 01:23:07 UTC
pam_systemd uses getenv() to retrieve XDG_SEAT value, however when pam_systemd is used by a SUID binary this allows a unprivileged user, in some circumstances, to provide a fake XDG_SEAT value, with the consequences mentioned in comment 0. For the attack to be successful, a new session must be created and that is created by pam_systemd only if the calling process is not already part of a session. On Fedora/RHEL, in their default PAM configurations, it does not seem to be possible to let a session sneak in without systemd knowing about it, since pam_systemd is always called in every PAM config file. Created systemd tracking bugs for this issue: Affects: fedora-all [bug 1698045] Acknowledgments: Name: Jann Horn (Google Project Zero) Statement: For the attack to be successful, a new session must be created by pam_systemd. This is done only if the calling process is not already part of a session. Red Hat Enterprise Linux, in its default PAM configurations, does not let a session sneak in without systemd knowing about it, since pam_systemd is always called in every PAM config file. Unless a wrong PAM config file is in place, this vulnerability cannot be triggered on Red Hat Enterprise Linux 7 and 8. This issue has been addressed in the following products: Red Hat Enterprise Linux 8 Via RHSA-2021:1611 https://access.redhat.com/errata/RHSA-2021:1611 This bug is now closed. Further updates for individual products will be reflected on the CVE page(s): https://access.redhat.com/security/cve/cve-2019-3842 This issue has been addressed in the following products: Red Hat Enterprise Linux 8.2 Extended Update Support Via RHSA-2021:3900 https://access.redhat.com/errata/RHSA-2021:3900 |