Will 'nullok' option allow users to login without entering a password?

Solution Verified - Updated -

Issue

I have a nullok entry in /etc/pam.d/system-auth file:

$ more /etc/pam.d/system-auth |grep nullok
auth        sufficient    pam_unix.so nullok try_first_pass
password    sufficient    pam_unix.so md5 remember=6 shadow nullok try_first_pass use_authtok

If an enabled account on the system is not password protected, then the users can login with no password. How do I fix this issue?

Environment

  • Red Hat Enterprise Linux 4
  • Red Hat Enterprise Linux 5
  • Red Hat Enterprise Linux 6
  • Red Hat Enterprise Linux 7
  • Red Hat Enterprise Linux 8
    • pam

Subscriber exclusive content

A Red Hat subscription provides unlimited access to our knowledgebase, tools, and much more.

Current Customers and Partners

Log in for full access

Log In

New to Red Hat?

Learn more about Red Hat subscriptions

Using a Red Hat product through a public cloud?

How to access this content