I keep all my sensitive documents encrypted in Truecrypt volumes (don’t you?). Â But I ran into a problem when I wanted to share a Truecrypt volume across my home network. Â I had to setup the share every time I mounted the volume.
Then it hit me; my flaw was that I was trying to set up a share within the Truecrypt volume. Â I needed to set up a share and then mount the TC volume inside that share. Â But you can’t mount a Truecrypt volume to a directory. Â Humm….
Enter Hardlink Shell Extension. Â HSE will let you create Volume Mount Points in Windows. Â That will let you “map complete local volumes onto arbitrary disk locations”. Â So you can create a VMP (as a folder) and point it at the drive letter of your TC volume. Â That way whenever you mount the TC volume to that drive letter, it will already be shared.
After installing the HSE, Mount your TC volume, right-click, and select “Pick Link Source”
Now go to the drive you are going to set up your shared folder and right click. Â Then select “Drop As…” and “Volume Mountpoint”.
Now just share the resulting folder.
When you mount the TC volume (or any TC volume for that matter) to the drive letter you selected as your “Link Source” it will be shared.
–Zen
I found a great article about a script to mount a TrueCrypt Volume on Windows here. Â It also detailed a script to unmount the volume.
I decided to improve on it a bit, and allow the same script to mount and unmount the volume (by testing to see if the volume is mounted). Â I did not include his password parameter because TrueCrypt will ask for the password anyway. And I really don’t want to code my password into any script.
So here is the script:
REM TrueCrypt mounting script (version 2)
REM Based on script Written by Mark Ursino (allthingsmarked.com)
REM Modified by Zen (Zenmojo.com)
REM Modifications are allowed, but please include these comments
@echo offset TrueSource=I:\TrueCrypt\truecrypt
set Source=I:\volume.cab
set Drive=O:IF EXIST “%Drive%” goto unmount
:mount
cls
“%TrueSource%” /v “%Source%” /l “%Drive%” /m /a /p /q
explorer.exe “%Drive%”
cls
goto end:unmount
cls
“%TrueSource%” /d”%Drive%” /q
cls
goto end:end
cls
Notes:
TrueSource is the location of your truecrypt.sys file (from the stand-alone version of TrueCrypt)
Source is the source of your TrueCrypt file
Drive is the drive letter you want to mount the file to
This is where I will catalog some of my favorite software
—————————————————————
7-Zip – Command-line and Windows shell utility for manipulating ZIP archives
Audacity – The Free, Cross-Platform Sound Editor
AudioGrabber – a great, and simple CD to MP3 Ripping software
CamStudio – Free Video Screen Capture Software
Clamwin – Free Software Open Source Virus and Spyware Scanner
Folder2ISO – creates an iso from any kind of folder (with the subfolders).
Hardlink – Split directories up to Span CD/DVD
Icons from File – Ever wanted to extract the icon from an exe file? No? Well, here is the program anyway.
ISORecorder – Free CD Image Burner and CD to CD Copier program for Windows
NTSFLink – a set of Windows Shell Extensions which hook into Explorer, providing extended functionality for creating and using hard links, as well as junction points on NTFS file systems.
Nvu – A complete Web Authoring System
Pandora’s Jar – to “time-shift” Pandora internet radio
ScreenRecoder from UltraVNC – A free Screen Recorder software package
SDP Multimedia – If you want to save a streaming Microsoft video (like an ASX playlist), then this is the tool you need
UltraVNC – VNC that will authenticate users via ldap or AD.
VDownloader – If you want to save that great Google Video or YouTube video, you need this tool
Xenu’s Link Sleuth – Find broken links on your site
zamzar.com – Web-based File Converter
I never could find a good script to check to see if a Macromedia Contribute key had been installed for a user on a machine, and if not then to run the key. So I made one. This one is for Contribute 2, but I think it will work with 3 (if you change the Site folder to 3). And it assumes that the user will only be running one Site. I make the Contribute Icon/Shortcut point to this script.
You will need to change “h:\key.stc” to the location of your key. You will need to save the following script as a .vbs
Set objFSO = CreateObject(“Scripting.FileSystemObject”)
Set objNetwork = WScript.CreateObject(“WScript.Network”)
strUserName = objNetwork.UserName
If objFSO.FileExists(“C:\Documents and Settings\” & strUserName & “\Local Settings\Application Data\Macromedia\Contribute 2\Sites\Site1\_mm\contribute.xml”) Then
Set wshShell = WScript.CreateObject (“WSCript.shell”)
wshshell.run “””C:\Program Files\Macromedia\Contribute 2\Contribute.exe”””, 6, True
set wshshell = nothing
Wscript.Quit
Else
Wscript.Echo “Your Contribute Key needs to be installed on this computer. Click OK to begin.”
Set wshShell = WScript.CreateObject (“WSCript.shell”)
wshshell.run “h:\key.stc”, 6, True
set wshshell = nothing
End If
References:
1) http://www.microsoft.com/technet/scriptcenter/resources/qanda/jun05/hey0620.mspx
2) http://weblogs.asp.net/steveschofield/archive/2004/03/14/89240.aspx
3) http://www.computerperformance.co.uk/Logon/Logon_HomeDirAdv.htm
Recent Comments