There is nothing wrong in your configuration.
Write your configuration in first line of /etc/pam.d/sshd
like this
#%PAM-1.0
auth required pam_listfile.so item=user onerr=fail sense=allow file=/etc/logins_user.txt
auth required pam_sepermit.so
auth include password-auth
account required pam_nologin.so
account include password-auth
password include password-auth
# pam_selinux.so close should be the first session rule
session required pam_selinux.so close
session required pam_loginuid.so
# pam_selinux.so open should only be followed by sessions to be executed in the user context
session required pam_selinux.so open env_params
session optional pam_keyinit.so force revoke
session include password-auth
That is because PAM will check all these configuration line by line , if you put your configuration in last line then any other condition will pass before checking your condition , That's why all users all able to login . Check this and let me know.
Be careful while trying this
Before changing anything take a backup of file.
if you configure like this
auth required pam_listfile.so item=user onerr=fail sense=allow file=/etc/logins_user.txt
auth include password-auth
account required pam_nologin.so
.
.
session include password-auth
And condition fails still PAM will check remaing rules.
if you configure like this
auth requisite pam_listfile.so item=user onerr=fail sense=allow file=/etc/logins_user.txt
auth include password-auth
account required pam_nologin.so
.
.
session include password-auth
And above condition fails , PAM will not check remaing rules.
required
Failure also results in denial of authentication, although PAM will still call all the other modules listed for this service before denying authentication.
requisite
Failure to authenticate via this module results in immediate denial of authentication.
So in your case may be below condition giving permission
auth include password-auth
You are entering correct password while ssh.