how to lock your Ubuntu desktop without hiding it
I recently had the need to lock my Linux desktop without hiding the screen's contents. I thought some sort of transparent screensaver might do the trick, but I was unable to find one. There are many screensavers that manipulate desktop pixels, thus allowing it to sort-of be visible. However, these screensavers operate on static screen shots of the screen as it appeared at the time the screensaver activated, and do not update as the desktop content changes.
A handy work-around I discovered is called xtrlock. This program locks the screen without hiding it, so that you can safely monitor screen updates (such as scrolling log files) without exposing an unsecured console environment.
When you run this program, the cursor turns into a blue lock icon and all interaction with the screen is prevented until you enter your password.
If you are using Ubuntu, you can install this program by entering the following command:
sudo aptitude install xtrlock
Of course, you'll need sudo permissions.
After you have installed this program, I recommend creating a launcher for it on your task bar. I don't think the package creates it own launchers anywhere.
One thing to note, that confused me the first time I ran this program. When you are ready to unlock the screen, you will not be visibly prompted for a password. You are simply expected to type your password, at any time, to unlock.