Bug 1767606
Summary: | Cockpit cannot log in with google-authenticator when enabled. | ||
---|---|---|---|
Product: | [Fedora] Fedora | Reporter: | Gwyn Ciesla <gwync> |
Component: | selinux-policy | Assignee: | Patrik Koncity <pkoncity> |
Status: | CLOSED EOL | QA Contact: | Fedora Extras Quality Assurance <extras-qa> |
Severity: | medium | Docs Contact: | |
Priority: | high | ||
Version: | 31 | CC: | aimery, bartmichu, dperpeet, dwalsh, dylan.graham, ichavero, lvrabec, mgrepl, plautrba, stefw, zpytela |
Target Milestone: | --- | ||
Target Release: | --- | ||
Hardware: | Unspecified | ||
OS: | Unspecified | ||
Whiteboard: | |||
Fixed In Version: | Doc Type: | If docs needed, set a value | |
Doc Text: | Story Points: | --- | |
Clone Of: | Environment: | ||
Last Closed: | 2020-11-24 20:14:38 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
Gwyn Ciesla
2019-10-31 19:11:36 UTC
Hi Cockpit maintainers, Could you please put SELinux to permissive and test this feature and collect all SELinux denials? Then we could fix it in SELinux policy, but I would like to get approval what should be added to cockpit policy first. Thanks, Lukas. @Gwyn, are you in a position to do that? If not, can you please describe how you set up your system, so that we can replicate? I. e. this certainly requires changes to the PAM config and such. Thanks! I can, just let me know specifically the commands you want me to use. The only change other than package installation is this in /etc/pam.d/cockpit: auth required pam_google_authenticator.so Martin, If you can reproduce it and give me list of SELinux denials, I can add these rules as SELinux boolean to the distribution policy. Thanks, Lukas. @Lukas: Sorry for the delay! Here we are. I set up google-authenticator with Cockpit on current Fedora 31 (selinux-policy-3.14.4-39.fc31.noarch). After "setenforce 0", 2FA works (yay!), and I get these four violations: AVC avc: denied { create } for pid=8358 comm="cockpit-session" name=".google_authenticator~CeLwZc" scontext=system_u:system_r:cockpit_session_t:s0 tcontext=system_u:object_r:user_home_dir_t:s0 tclass=file permissive=1 AVC avc: denied { read write open } for pid=8358 comm="cockpit-session" path="/home/admin/.google_authenticator~CeLwZc" dev="dm-0" ino=395796 scontext=system_u:system_r:cockpit_session_t:s0 tcontext=system_u:object_r:user_home_dir_t:s0 tclass=file permissive=1 AVC avc: denied { setattr } for pid=8358 comm="cockpit-session" name=".google_authenticator~CeLwZc" dev="dm-0" ino=395796 scontext=system_u:system_r:cockpit_session_t:s0 tcontext=system_u:object_r:user_home_dir_t:s0 tclass=file permissive=1 AVC avc: denied { rename } for pid=8358 comm="cockpit-session" name=".google_authenticator~CeLwZc" dev="dm-0" ino=395796 scontext=system_u:system_r:cockpit_session_t:s0 tcontext=system_u:object_r:user_home_dir_t:s0 tclass=file permissive=1 Allowing these sounds perfectly sensible to me -- This is just doing "by the book" updating of a file, and by design 2FA needs to update the file to update its time stamps and such. As these changes need to be done in selinux-policy, I'm reassigning if you don't mind? Hi Martin, Ok this should be fixed on our side. Martin, would it be possible to provide some VM for testing purposes? @Patrik, We need SELinux boolean for cockpit to allow access user homedirs ( allow google-authenticator for cockpit), which will be turned off by default. THanks, Lukas. *** Bug 1771041 has been marked as a duplicate of this bug. *** @Patrik, We need to make it more generic and allow it also for sshd domain via boolean. Do we have any updates on when this bug is likely to be closed? Hi Aimery de Malet Roquefort, Patrik is working on the fix: https://github.com/fedora-selinux/selinux-policy/pull/293 Thanks, Lukas. Any further updates on when this will be pulled into the main active branch of Fedora? Seems we have been waiting for this relatively simple fix forever. Hi Aimery, fix is still in progress. Thanks, Patrik. Hello. Any progress on that fix? Or at least a workaround? Thanks, Michał Hi Michal, we almost finished this fix, but this fix not depend only on selinux component. So it also depend on agreement with maintainers of google authenticator. This message is a reminder that Fedora 31 is nearing its end of life. Fedora will stop maintaining and issuing updates for Fedora 31 on 2020-11-24. It is Fedora's policy to close all bug reports from releases that are no longer maintained. At that time this bug will be closed as EOL if it remains open with a Fedora 'version' of '31'. Package Maintainer: If you wish for this bug to remain open because you plan to fix it in a currently maintained version, simply change the 'version' to a later Fedora version. Thank you for reporting this issue and we are sorry that we were not able to fix it before Fedora 31 is end of life. If you would still like to see this bug fixed and are able to reproduce it against a later version of Fedora, you are encouraged change the 'version' to a later Fedora version prior this bug is closed as described in the policy above. Although we aim to fix as many bugs as possible during every release's lifetime, sometimes those efforts are overtaken by events. Often a more recent Fedora release includes newer upstream software that fixes bugs or makes them obsolete. Fedora 31 changed to end-of-life (EOL) status on 2020-11-24. Fedora 31 is no longer maintained, which means that it will not receive any further security or bug fix updates. As a result we are closing this bug. If you can reproduce this bug against a currently maintained version of Fedora please feel free to reopen this bug against that version. If you are unable to reopen this bug, please file a new report against the current release. If you experience problems, please add a comment to this bug. Thank you for reporting this bug and we are sorry it could not be fixed. |