Control amount of time a user may be logged in. (Parental Control)
I'm wondering if there is a way to control the amount of time a user can be logged into their account.
I want to specify certain hours in the day that my kids can use the computer. For example, 4pm to 6pm. Thoughts on how to do this? Also, would it be possible instead of specifying the hours inwhich they can use the computer to specify the amount of time they are allowed to use the computer? Anyway to specify the length of time a user can use a specific application? - darrensnospam |
For the 4pm-6pm limitation you could use a cron script to deactivate their account at 6pm, and if they are logged in kill all processes in their name (maybe with a warning first?). Then another script at 4pm could reactive it. Not sure how comfortable you are with linux, if you need some help just post back and I'll do my best. Not sure about the time limitations though...
|
Re: Control amount of time a user may be logged in. (Parental Control)
Quote:
|
Thanks for the leads, archtoad6 & infinity42.
I'll table development at this point if/when I do create something, I'll be certain to share it. If I find something ready made, I'll post back and let you know what I found. I've reviewed dansguardian and I'll be testing that out. I believe that it allows for controling net access during certain periods of time. - darrensnospam |
I Look fwd. to seeing your results.
|
Hi,
I am interested in the same thing. Time limitations, regulating the amount of time, and web access during homework time. I have also reviewed dansguardian and will be trying that soon. I would be interested in seeing your results as well. thanks john |
I guess no one ever found a way to make a time limitation on one's unix box... I myself have a linux box in our place, which is available for everyone in the house (we're like 12), and everyone got their own username, but what I am missing is the time control. Let's say each person gets max an hour every day. Isn't there a program on the web that can handle things like that?
|
There's a program called PAM which comes with Mandriva. I don't know a lot about it but I'm pretty sure that's exactly what it's used for.
|
More info, please.
|
|
I think PAM is pretty complicated, there must be an easier way. But there's a PAM module called pam_time.so which does exactly what you're looking for.
|
Another link.
http://www.kernel.org/pub/linux/libs...-html/pam.html |
Dont seem to do the job
Extracts from "pam_time" "Note, currently there is no daemon enforcing the end of a session. This needs to be remedied." |
You might be able to write a script that works with the output of last. You'd have to loop through and add up a user's entries for a date, then take the last entry and calculate the difference between it and the current time (periodically, through cron every 5 minutes?).
I haven't tried it yet though... |
All times are GMT -5. The time now is 03:39 AM. |