LinuxQuestions.org

LinuxQuestions.org (/questions/)
-   Linux - Newbie (https://www.linuxquestions.org/questions/linux-newbie-8/)
-   -   denying login based on time (https://www.linuxquestions.org/questions/linux-newbie-8/denying-login-based-on-time-805302/)

shaps 05-01-2010 09:20 AM

denying login based on time
 
i want to deny certain users based on time to login to my machine i am using CentOs 5.0 any sugestions?

smoker 05-01-2010 09:40 AM

Use /etc/security/time.conf to make rules.

http://blogs.techrepublic.com.com/security/?p=319

For example :

Code:

login ; * ; !bobby ; MoTuWeThFr0800-2000
http ; * ; !bobby ; MoTuWeThFr0800-2000

means that all users except for bobby can login between 0800 and 2000.

The manpage is accurate -

http://manpages.ubuntu.com/manpages/...me.conf.5.html

EricTRA 05-01-2010 09:43 AM

Hello,

If I'm not mistaking, CentOS uses PAM and you should have a file called time.conf in /etc/security. Have a look at that file, it's pretty well documented if I remember well. Also you can have a look at this site which explains the basics of PAM.

Kind regards,

Eric


All times are GMT -5. The time now is 07:12 PM.