A multiple-language kiosk for Linux (Ubuntu Edgy)
Saturday, February 10th, 2007[This post is a work on progress and may be updated]
Linux is great for one thing: it supports multiple language on the desktop. If you plan to offer a kiosk mode supporting many languages, Linux becomes a good choice.
We settle on Ubuntu Edgy as a default distribution for this setup, but any distribution might do. The chosen environment is Gnome.
Worklog
- install Ubuntu.
we name the administration account ‘administrator’. Pick a secure password. - Add your supported languages (System/Administration/Language Support). I selected English, French and Norwegian. Chose Apply and select your default language
- add a guest account
login ‘guest’, password ‘guest’, real name ‘Mediatheque Guest User’ - if you use the GUI, you can limit the privileges. I selected ‘Access external storage…” “Use audio devices” and “Use CD-ROM devices”
- change some account options
- FIXME disable package notifications
- FIXME restrict menu rights?
- configure gdm
- add a theme with user list, language & logo
- using gdmsetup, select the theme and restrict the list of users to guest only (one can still log in as administrator, it just won’t show up in the list)
- trim gdm locales list: reduce
/etc/gdm/locale.conf - pam for guest users. Create a file called
/etc/X11/gdm/nopassusers.txtcontaining the name of the users that do not require to have a password typed, one user name per line. In our case the file will containguest. Then modify/etc/pam.d/gdmso that the lineauth sufficient pam_listfile.so item=user sense=allow file=/etc/X11/gdm/nopassusers.txt onerr=failfollowsauth required pam_env.so
tip: use
gdmthemetesterto test; which requires you to install xnest package on Edgy - autologout of the guest account:
- enable blank screen saver, 10 minutes
- custom autologout script added to session
You might want to use the following scripts (add them to /usr/local/bin):
forcelogout
#!/bin/bash # allow close session without user interaction gconftool-2 --set /apps/gnome-session/options/logout_prompt --type=bool false # kill session gnome-screensaver-command --deactivate gnome-session-save --kill --silent
screensaveractive
#!/bin/bash # return 0 if screensaver actif; 1 otherwise output=`( LANGUAGE=en && gnome-screensaver-command --query )` if [[ $output == "The screensaver is active" ]]; then exit 0 else exit 1 fi
autologout
#!/bin/bash # This script will perform an autologout of the current user # from a gnome-session when the screensaver is triggered while [ 1 ]; do sleep 2 screensaveractive && forcelogout && exit done
- session
add firefox, configure home page; change some preferences related to security. Also disable the ‘ask on exit’ element of the session preferences dialog. That will make guest user disconnect easily.
Also set browser.sessionstore.resume_from_crash to false in about:config as to avoid session restore dialog upon restart (best would be to cleanly shutdown FF in forcelogout, but I don’t know how) - potential security improvements?
- change menus?
- remove command line?
- disable services?
- kiosk advertising/documentation. Print out a help document and let it close to the machine
- help file
- offer to distribute Linux
- sell blank CDs/DVDs ?
- TODO
- improvements
- session reset
- localeList widget for gdm ? no flags in gdm to map to a locale (conscious political avoidance decision)…
- auto-logout for gdm?
- generic auto logout for X?
- remove confirm close session?
- Interesting links:
- http://www.justlinux.com/nhf/Filesystems/Mounting_smbfs_Shares_Permanently.html