Using the Kix Script Tokenize option to Obsfucate Passwords

Written by James McDonald

March 5, 2009

If you want to check if your PPTP VPN Server is alive and responding via a script you can run the standard windows rasdial command from a windows batch file:

rasdial entryname username password

However to do this you the have to include a username and password in the batch file which may be a tad insecure.

A better approach although not entirely secure is to use Kix to script the rasdial connection and then tokenize it:

For example say you create the following and call it checkVPN.kix:

$VPNCON="theHostnameOrIPaddressOfYourVPNServer"

; set user and pass in your kix file
$USER=xxxxxxxxx
$PW=xxxxxxxxxxx
					
? "Connecting to $VPNCON"
shell "rasdial $VPNCON $USER $PW"

Then you get a command prompt up and use kix32.exe to tokenize it thusly:

kix32.exe /t checkVPN.kix

The above command will output a file named checkVPN.KX with content not readable to humans:

Sample of tokenized content

Sample of tokenized content

You then can launch that tokenized script using a windows batch file with the following syntax:

@ECHO OFF
set PATH=%0\..\;%PATH%
REM echo %PATH%
%0\..\Kix32.exe %0\..\checkVPN.KX

KiXtart 2010 4.60

0 Comments

Submit a Comment

Your email address will not be published. Required fields are marked *

You May Also Like…

Toggen builds a new website

So I have built and hosted a new website for Roger Clark Pest Management they are a family owned and operated Pest...

WizTree

Just downloaded WizTree (not a sponsor) from https://wiztreefree.com/ It seems to do what it says on the tin which is...

Scam call from “Telstra”

Just had a call from a man with a sub-continental accent from caller ID 0734946596 Told me there was problem with my...