LPIC-1 Exam 102 v5 (Linux Administrator) — Question 5

Which of the following steps prevents a user from obtaining an interactive login session?

Answer options

Correct answer: B

Explanation

The correct answer is B because running the command chsh -s /bin/false changes the user's shell to /bin/false, effectively preventing interactive logins. Option A is incorrect since setting the UID to 0 grants administrative privileges, not restricts access. Options C and D do not prevent login sessions, and option E, while it may prevent login, is not the most direct method compared to option B.