-
Notifications
You must be signed in to change notification settings - Fork 70
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
UsePAM should probably default to yes on Red Hat Linux 7 #96
Comments
I've seen this (the inability to ssh in with use_pam = false) with Debian-based distributions, too. |
Thanks @elyscape and @michaelklishin We've scheduled RHEL7 support for the next weeks. @michaelklishin Especially with Ubuntu cloud machines, you normally run into locked accounts: https://github.com/hardening-io/chef-ssh-hardening#faq--pitfalls In such cases, use_pam works around this. |
@artem-sidorenko FYI |
@chris-rock I'm pretty sure my account was not locked. So was a decision made on making this default to |
let me double-check, do you have any documentation that indicates usepam is required on rhel7 |
@chris-rock: As mentioned in the issue, the # WARNING: 'UsePAM no' is not supported in Red Hat Enterprise Linux and may cause several
# problems. |
thanks @elyscape Then we should make it default on RHEL7 |
I guess its not only RHEL7 related, I remember some discussion with RH about 3-4 years ago about this flag (and about SUID bits). |
Probably its a good idea to change the default options to a supported config to avoid any issues in general. In deployments like we have, the users will have to take care about this option and change the defaults. But in my eyes it makes sense to keep the support for |
We could switch to UsePam yes on all RHEL systems to meet the default supported way. |
As per this post. The workaround mentioned by RedHat is: We could create that policy and add it to selinux, when use_pam is off and selinux is on. |
Maybe it is a good a approach to implement the idea @rndmh3ro mentioned to keep usePam=no as default for this cookbook version. |
@chris-rock I think its a good approach
FYI: CC @larsjuetten as far as I remember you did the quick evaluation of chef-(os/ssh)-hardening on RHEL/Centos 7, can you remember if you got this issue or have any details which might be useful here? |
So, we had exactly this issue as well:) |
Thanks for the great discussion. Lets make usePam=yes the default version for all implementations. We should bump a major though and add a proper no implementation for RedHat as suggested by @rndmh3ro |
👍 :) |
as PAM should be enabled per default on the most distros: - dev-sec/chef-ssh-hardening#96 - dev-sec/ansible-ssh-hardening#23 - dev-sec/puppet-ssh-hardening#53
as PAM should be enabled per default on the most distros: - dev-sec/chef-ssh-hardening#96 - dev-sec/ansible-ssh-hardening#23 - dev-sec/puppet-ssh-hardening#53
as PAM should be enabled per default on the most distros: - dev-sec/chef-ssh-hardening#96 - dev-sec/ansible-ssh-hardening#23 - dev-sec/puppet-ssh-hardening#53
From the
sshd_config
file on a CentOS 7 box:As such, it's probably a good idea to default
default['ssh']['use_pam']
totrue
on RedHat 7.This warning isn't in the CentOS 6
sshd_config
file, but there is an article in the Red Hat 6 knowledgebase about not being able to SSH into a system if UsePAM is off and SELinux is on. I don't have an account and can't see the solution, though, so there might be a way to deal with that.See also dev-sec/puppet-ssh-hardening#53 and dev-sec/ansible-ssh-hardening#23.
The text was updated successfully, but these errors were encountered: