Parental Control

Posted: 09-23-2003, 02:27 AM
I am looking for a way to restict user (kids) access by time and
content to the net.

If not, is there a way to restrict the time at which a user can log on
to Mandrake?

Thanks.
Reply With Quote

Responses to "Parental Control"

Bit Twister
Guest
Posts: n/a
 
Re: Parental Control
Posted: 09-23-2003, 03:35 AM
On Tue, 23 Sep 2003 01:27:50 GMT, The Etobian wrote:
> I am looking for a way to restict user (kids) access by time and
> content to the net.
>
> If not, is there a way to restrict the time at which a user can log on
> to Mandrake?
squid proxy server may stop content. Never played with it.

You can write a cron job to blow the kid's login away or prevent
login.

Some light reading at http://www.tldp.org/LDP/abs/html/index.html
man ps
man kill

Particial example script run by cron on the half hour.
You place the script in /etc/profile.d with execute permission to
control login. This is untested.

IFS=' :'
set $(date)
_day=$1
_mo=$2
_hr=$3
_min=$4
_stay_on=0

case $_day in
Mon)
if [ $LOGNAME = "kid_1" ] ; then
_stay_on=0
_start=17
_stop=20
fi
if [ $LOGNAME = "kid_2" ] ; then
_stay_on=0
_start=17
_stop=21
fi
;;
Tue)
;;
Wed)
;;
Thu)
;;
Fri)
;;
Sat)
if [ $LOGNAME = "kid_2" ] ; then
_stay_on=0
_start=8
_stop=21
fi
;;
Sun)
;;
esac


if [ "$LOGNAME" = "kid_1" ] ; then
if [ $_hr -gt $_start && $_hr -lt $_stop ] ; then
_stay_on=1
fi
fi

if [ $_stay_on -eq 0 ] ; then

ps U $LOGNAME > /tmp/$LOGNAME

while read line
do
set -a $line
if [ $1 != "PID" ] ; then
kill $1
fi
done < /tmp/$LOGNAME
exit
fi
Reply With Quote
AlienMojo
Guest
Posts: n/a
 
Re: Parental Control
Posted: 09-23-2003, 07:20 AM
On Tue, 23 Sep 2003 01:27:50 +0000, The Etobian wrote:
> I am looking for a way to restict user (kids) access by time and content
> to the net.
>
> If not, is there a way to restrict the time at which a user can log on
> to Mandrake?
>
> Thanks.
I am doing this with netfilter/iptables, squid proxy, and DansGuardian
content filtering. Iptables performs transparent proxy redirection for
common http ports to Squid/DansGuardian. DansGuardian performs content
filtering on all connections. This way I don't have to worry if the kids
screw around with proxy settings in their browser, as well as it also
picks up non-browser connections over http ports.

I am not restricting access by time but it would be very easy to have two
sets of iptable rules. One that allows access and one that blocks it.
Then setup 2 cron jobs to put the correct rules in effect whenever you
want.

http://www.netfilter.org/
http://www.squid-cache.org/
http://dansguardian.org/


--
AlienMojo
Reply With Quote
 
LinkBack Thread Tools Display Modes
Reply


Thread Tools
Display Modes

Posting Rules
You may not post new threads
You may post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are Off
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On
Forum Jump


Similar Threads
Thread Thread Starter Forum Replies Last Post
parental control muddy Windows Vista Security 3 10-24-2007 10:27 PM
Parental Control gone mad! Amee Windows Vista Security 1 07-02-2007 02:57 AM
Bug in Parental Control ?? Andres Pae Windows Vista Administration 0 06-24-2007 08:31 PM
Parental Control PIN Chad Windows Vista Administration 0 05-03-2007 06:14 PM
Parental Control lindy Customize Windows XP 1 08-25-2004 03:36 PM