Posted by gmendoza on December 9, 2009 under Tech Tips |
If you’re running the Gnome desktop environment and would like to have GnuPG context menu options in Nautilus to encrypt, decrypt, and digitally sign files, simply install the Seahorse plugins package available in your favorite Linux distribution repositories. If using Debian or Ubuntu, it’s as easy as an apt-get install.
sudo apt-get install seahorse-plugins
After installing the package, go to System -> Preferences -> Encryption and Keyrings, select a default key to use and decide whether you want to include your own key by default when encrypting files. This is sometimes a good idea if you ever want to open a file you encrypted to someone else. Below are some screenshots of the Seahorse preferences.


Here are some screen shots of the context menu options that appear when you right click on files in Nautilus.

When you choose to encrypt a file, you can select as many public keys as you’d like. Here’s an example of the dialogue.

Using PGP has never been easier. There are still some improvements to the UI I would like to see completed, but overall the most important features are there.
Posted by gmendoza on December 1, 2009 under Tech Tips |
When adding third party software repositories to your APT sources list, you can easily download a referenced PGP key to your APT keyring using the advanced options of the apt-key utility.
For example, if you are adding a third party repository that references the PGP key ID of 6E80C6B7, the following will work as long as the key has been uploaded to a keyserver.
sudo apt-key adv --keyserver keyserver.ubuntu.com --recv-keys 6E80C6B7
gpg: requesting key 6E80C6B7 from hkp server keyserver.ubuntu.com
gpg: key 6E80C6B7: public key "Launchpad PPA for Banshee Team" imported
gpg: no ultimately trusted keys found
gpg: Total number processed: 1
gpg: imported: 1 (RSA: 1)
Typically, instructions on adding repositories give readers a two or three step process that involves apt-key reading a key from a text file or piped from a wget command. The above just cuts all that nonsense out.
The apt-key man page is a bit bare, but there are a few other options you might find interesting that are only mentioned in the commands help output.
apt-key
Usage: apt-key [command] [arguments]
Manage apt's list of trusted keys
apt-key add - add the key contained in ('-' for stdin)
apt-key del - remove the key
apt-key export - output the key
apt-key exportall - output all trusted keys
apt-key update - update keys using the keyring package
apt-key net-update - update keys using the network
apt-key list - list keys
apt-key finger - list fingerprints
apt-key adv - pass advanced options to gpg (download key)
Posted by gmendoza on November 11, 2009 under Tech Tips |
If you have a video vile that you wish to convert and burn to DVD, you can do so from a Linux command line very easily. We will use FFmpeg for the video conversion, DVDAuthor to create the DVD file system structure, and Growisofs to burn the DVD.
Using FFmpeg, simply specify your input file, the target format, resolution and an output file name. While the following is an over simplified example, it will more than likely work very nicely in most scenarios. The source video file is movie.avi, the target will be formatted for NTSC, and a standard DVD resolution of 720×480 will be used to create a new video file called movie.mpg. There are many additional options that FFMpeg can use to increase quality, so be sure to check out the documentation.
ffmpeg -i movie.avi -target ntsc-video -s 720x480 movie.mpg
Next, you will need to take your new movie.mpg file, and create a DVD file structure that you will burn to disc. Just create a folder that will serve as the parent directory of your DVD. I Like to name it after the title of the movie. Then you will use dvdauthor to create a title set and table of contents and no DVD menus. The movie will just play. :-)
mkdir MOVIE_TITLE
dvdauthor -o MOVIE_TITLE/ -t movie.mpg
dvdauthor -o MOVIE_TITLE/ -T
The dvdauthor -t option creates a title track in the VIDEO_TS directory. If you list the contents after running the first command, you’ll see the corresponding VTS_01_0.BUP, VTS_01_0.IFO, and VTS_01_X.VOB files. The -T option creates a table of contents for all title sets in the file system, which are listed as VIDEO_TS.BUP and VIDEO_TS.IFO.
You are now ready to burn the DVD. In the following command, we will use the -Z option to burn an initial session to the disc, the -dvd-video option to generate a DVD-Video compliant UDF file system, and the -V option to give the disc a Volume ID. This Volume ID is read by your computer to and displays as a nice human readable title typically underneath the icon representing the disc. The -dvd-video and -V options are actually part of the mkisofs (genisoimage) command sets, so they do not show up in the growisofs man pages.
growisofs -Z /dev/dvdrw -dvd-video -V MOVIE_TITLE MOVIE_TITLE/
Notice, you do not need to generate an ISO file to burn the DVD. This would only waste space if your intention is not to distribute or store the video as a disc image. To create the image however, that’s as easy as the following.
genisoimage -o MOVIE_TITLE.iso -dvd-video MOVIE_TITLE/