Reply
Thread Tools
Posts: 255 | Thanked: 107 times | Joined on Nov 2010
#1
I was looking for a way to "lock" applications with a password but I could only find one that hides the apps so I just hacked up a small script.
My original intention was to prevent people from taking my phone and playing Angry Birds >:[

Code:
#!/bin/sh
PASS="password"
read -p "Password please: " pw

if [ $PASS = $pw ]; then
   echo "Program will be run."
   # program to run here
else
   read -p "Password incorrect."
fi
Save this to a file, for example ~/bin/launch_program

of course it doesn't prevent anyone from just directly launching the command nor does it prevent someone from checking the password but chances are no one you knwo will figure out what to do.
You'll have to change the launch command in /usr/share/applications/hildon/<program>.desktop from Exec=whatever to
Code:
Exec=/usr/bin/osso-xterm /home/user/bin/launch_program
and also remove the X-Maemo-Service line, if any.

If there's something to do this already, then I'm an ignorant monkey and deserve a slap.
 

The Following 2 Users Say Thank You to Char For This Useful Post:
daperl's Avatar
Posts: 2,427 | Thanked: 2,986 times | Joined on Dec 2007
#2
We really need fast user switching. Then you can just unset some execute bits. Also, a guest is going to want to browse, but who wants to share their saved cookies with anyone?
__________________
N9: Go white or go home
 
Posts: 255 | Thanked: 107 times | Joined on Nov 2010
#3
User switching on a phone would be godly.
 
Reply


 
Forum Jump


All times are GMT. The time now is 17:22.