
Truecrypt mount and unmount scripts
Source (link to git-repo or to original if based on someone elses unmodified work): Add the source-code for this project on opencode.net
TrueCrypt mount scripts v 1.2
by Taboom
INTRODUCTION
This zip file contains two .sh files for mounting and unmounting TrueCrypt partitions with some dialogues. When mounting passwords are stored in KDE Wallet so you have to open it. If you mount a partition for the first time, the password for the drive will be asked and then stored in KDE Wallet. After that all you need when mounting is an open KDE Wallet, which you will be asked to open if necessary. To change the password later you have to do it manually in KDE Wallet. The key for the KDE Wallet stored passwords is the device (ex. /dev/hda1). By default the KDE Wallet is closed after using it. Not having KDE Wallet installed should not be a problem - you should be asked for a password normally anyways.
Unmounting supports both normal and forced unmounting. All is done with nice dialogues in each stage. These are very simple scripts, but I decided to share them with the world, as I couldn't find them myself.
USAGE
Create two desktop icons which link to the scripts and give as parameters the source and the destination for the TrueCrypt partition. Now clicking the icons allow you to mount and unmount your partitions via dialogues. Very simple, but useful. Remember to make all the scripts executable.
FUTURE
I know there's are usability issues with opening KDE Wallet as there is nothing saying why you open KDE Wallet but I don't have time or need to fix this currently. TrueCrypt 4.3 does not allow setting mount-options as user so this can also be a problem.
CREDITS
I believe the idea for these scripts came from http://gentoo-wiki.com/TIP_EncFS and especially Kevin Wennemuth who wrote the scrips, so thank's to him. Script parts for accessing the KDE Wallet is originally from Jochen Hoenicke at http://hoenicke.ath.cx/kwallet/. They have been edited for better functionality in this script.
13 years ago
1.0 Initial release
1.1 Added KDE Wallet support
1.2 Opening KDE Wallet fixed, script did not always open kdewallet and never closed it. Kwallet script (needed parts) integrated into mount script. Some minor cosmetic changes.
13 years ago
1.0 Initial release
1.1 Added KDE Wallet support
1.2 Opening KDE Wallet fixed, script did not always open kdewallet and never closed it. Kwallet script (needed parts) integrated into mount script. Some minor cosmetic changes.
taboom
13 years ago
Report
Miron73
13 years ago
Your script stores password as-is (per source) - in that situation user has to remove this password when he wants to switch partition type. Furthermore in situation when he is enforced to reveal his data there is no possibility to enter normal partition password. It will be entered "magically"
Maybe there should be a switch to ignore kdewallet?
Report
gassauer
13 years ago
if [ -z "$SOURCE" ]; then
SOURCE_TYPE=$(kdialog --radiolist "TrueCrypt: Mount" 0 "File" on 1 "Directory" off)
if [ "$SOURCE_TYPE" = "0" ]
then
SOURCE=$(kfiledialog --caption "TrueCrypt: Mount SOURCE File?" --file)
else
SOURCE=$(kfiledialog --caption "TrueCrypt: Mount SOURCE Directory?" --directory)
fi
SOURCE_FETCHED=$?
fi
if [ -z "$DESTINATION" ]; then
DESTINATION=$(kfiledialog --directory --caption "TrueCrypt: Mount DESTINATION?")
DESTINATION_FETCHED=$?
fi
Report
shevegen
13 years ago
I think we all should find a consensus.
There may be people that come for shell scripts, but there are also people that look only for real KDE applications.
The admin of the site should find a way to manage that. Personally I would think of having a small logo:
- shell script logo
- kde app logo
etc..
A small icon.
So that visitors can immediately verify whats this application for.
Report
bitcrazy
13 years ago
Greetings
m0nk
Report