Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Import fix for CVE-2018-1113 #2

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

LucienLassalle
Copy link

Imported patch from redhat setup-2.8.71-10

From NIST:

/sbin/nologin and /usr/sbin/nologin to /etc/shells. This violates security assumptions made by pam_shells and some daemons which allow access based on a user's shell being listed in /etc/shells. Under some circumstances, users which had their shell changed to /sbin/nologin could still access the system.

@LucienLassalle
Copy link
Author

Scratch Build : https://koji.xcp-ng.org/taskinfo?taskID=71209

@stormi
Copy link
Member

stormi commented Nov 20, 2024

It would be good to put the explanation you wrote in the PR description directly in the commit message. Is the patch identical to that of the Red Hat package (no patch description in their headers?)

@stormi
Copy link
Member

stormi commented Nov 20, 2024

Are we sure that this change is enough to remove nologin from XCP-ng? Will there be other components which assume this user exists and will try to use it?

@LucienLassalle
Copy link
Author

Are we sure that this change is enough to remove nologin from XCP-ng? Will there be other components which assume this user exists and will try to use it?

The patch comes directly from the following version of redhat setup-2.8.71-10, there was no header.

Components use the "shells" file to validate that a user can use a shell. But each component is unique, if another one did not handle it that way, then we may have other CVEs to fix in the future.

In any case this fix does not solve a critical vulnerabilities. It can prevent a potential root access coming from a backdoor/reverse shell for example.

@LucienLassalle LucienLassalle force-pushed the 8.3-import-CVE-2018-1113 branch from dd4ee2a to c4c4075 Compare November 20, 2024 21:35
@stormi
Copy link
Member

stormi commented Nov 21, 2024

But each component is unique, if another one did not handle it that way, then we may have other CVEs to fix in the future.

My question was rather about the risk for a functional regression if a component expects the nologin shell to be a valid shell and it isn't listed as available anymore. Or worse, components which would fall back to an even more insecure behaviour when nologin is absent.

I think we should evaluate all this before we do such a change in a production release.

Imported patch from redhat setup-2.8.71-10
From NIST:
 /sbin/nologin and /usr/sbin/nologin to /etc/shells.
 This violates security assumptions made by pam_shells and some daemons which allow access based on a user's shell being listed in /etc/shells.
 Under some circumstances, users which had their shell changed to /sbin/nologin could still access the system.

Signed-off-by: Lucas RAVAGNIER <[email protected]>
@LucienLassalle LucienLassalle force-pushed the 8.3-import-CVE-2018-1113 branch from c4c4075 to 94e25f4 Compare December 4, 2024 14:45
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants