Not exactly sure if this is what you're looking for, but I thought I'd post it. So basically this is an RC4 encryption that I used from
http://www.autohotke...ml&highlight=rc4.
How it works:
1. run the script (it can be left running at all times)
2. when you want to encrypt something simply copy the text to the clipboard and then fire the hotkey (ctrl + alt + z)
3. you will be prompted to enter a password which is used for the encryption
4. once you enter a password your text will then be encrypted and then placed back to the clipboard.
5. send your encrypted text to someone that has the same script
6. they place the encrypted text to the clipboard and fire the hotkey (ctrl + alt + z)
7. they have to enter the same password you used to encrypt the text
8. the text will then be decrypted and the original text that you wrote will be placed to the clipboard
AHK
SingleInstance Force
#Persistent
#NoEnv
SetBatchLines, -1
^!x::
Password:
InputBox, PW, Password, Enter a password., , 200, 125
If ErrorLevel <> 0
ExitApp
If PW =
Goto, Password
Data = %Clipboard%
Gosub, RC4
Clipboard = %Result%
Return
RC4:
ATrim = %A_AutoTrim%
AutoTrim, Off
BLines = %A_BatchLines%
SetBatchlines, -1
StringLen, PWLen, PW
IfNotEqual, PW, %OldPW%
{
Loop, 256
{
a := A_Index - 1
Transform, ModVal, Mod, %a%, %PWLen%
ModVal ++
StringMid, C, PW, %ModVal%, 1
Transform, AscVar, Asc, %C%
Key%a% = %AscVar%
sBox%a% = %a%
}
b = 0
Loop, 256
{
a := A_Index - 1
TempVar := b + sBox%a% + Key%a%
Transform, b, Mod, %TempVar%, 256
T := sBox%a%
sBox%a% := sBox%b%
sBox%b% = %T%
}
OldPW = %PW%
}
StringLen, DataLen, Data
Result =
i = 0
j = 0
Loop, %DataLen%
{
TmpVar := i + 1
Transform, i, Mod, %TmpVar%, 256
TmpVar := sBox%i% + j
Transform, j, Mod, %TmpVar%, 256
TmpVar := sBox%i% + sBox%j%
Transform, TmpVar2, Mod, %TmpVar%, 256
k := sBox%TmpVar2%
StringMid, TmpVar, Data, %A_Index%, 1
Transform, AscVar, Asc, %TmpVar%
Transform, C, BitXOR, %AscVar%, %k%
IfEqual, C, 0
C = %k%
Transform, ChrVar, Chr, %C%
Result = %Result%%ChrVar%
}
AutoTrim, %ATrim%
SetBatchlines, %BLines%
Return
GuiClose:
ExitApp