Jump to content
Sign in to follow this  
jaenster

My Crypt tool

Recommended Posts

jaenster

;----------------------------------------------------
;| CrytTool by jaenster
;|Input Crypt   : $do , 0 = Decrypt , 1 = Crypt
;|              : $t , The Text to crypt
;|              : $pw , The password 
;------------------------------------------------------
func crypt($Do,$t,$pw)
    if $do = 0 then;Decrypt
        return _crypttool(_crypttool2($t,$pw))
    endif
    if $do = 1 then;Crypt
        return _crypttool2(_crypttool($t),$pw)
    endif
endfunc
;This are the subfuncions of CrytIT
func _crypttool($t)
    $Terug = ""
    $t = _ReturnOtherWish($t)
    for $i = 1 to stringlen($t)
        $Nummer = asc(stringmid($t,$i,1))
        if $Nummer < 128 then
            $Terug = $Terug &chr(128+$nummer)
        EndIf
        if $nummer >= 128 then
            $Terug = $Terug &chr($Nummer-128)
        endif
    next
    return $terug
endfunc
func _crypttool2($t,$pw)
    $Terug = ""
    $Max = stringlen($pw)
    $c = 1
    for $i = 1 to stringlen($t)
        $c = $c + 1
        if $c = $max then 
            $c = 1
        endif
        $Terug = $Terug & chr(BitXOR(asc(stringmid($t,$i,1)),asc(stringmid($pw,$c,1)))&"  ")    
    next
    return $Terug
endfunc; ==> Crypt 2
func _ReturnOtherWish($t)
    $terug = ""
    for $i = StringLen($t) to 1 step -1
        $terug = $terug & stringmid($t,$i,1)
    next
    return $Terug 
endfunc

Yeah , my crypt tool :o for an example i has copy crypt tool orginol to my progam and modifide it that it works with my crypter

Here you can find then ,

#include <guiconstants.au3>
;#include files for encryption and GUI constants
;~~
$WinMain = GuiCreate('Jaensters , Encryption tool , Use an other crypter', 400, 400)
; Creates window
;~~
$EditText = GuiCtrlCreateEdit('This is not an clone of Encryption tool in gui examples'&@CRLF&"My crypter pwns ya ^^",5,5,380,350)
; Creates main edit
;~~
$InputPass = GuiCtrlCreateInput('',5,360,100,20, 0x21)
; Creates the password box with blured/centered input
;~~
$EncryptButton = GuiCtrlCreateButton('Encrypt', 170, 360, 105, 35)
$DecryptButton = GuiCtrlCreateButton('Decrypt', 285, 360, 105, 35)
; Encryption/Decryption buttons
;~~
GUICtrlCreateLabel('Password', 5, 385)
GuiCtrlCreateLabel('No Lvl Needed',100,385)
; Simple text labels so you know what is what
;~~
GuiSetState()
; Shows window
;~~
while(1)
    $msg = GUIGetMsg()
    if $msg = $GUI_EVENT_CLOSE Then
        Exit
    endif
    if $msg = $EncryptButton Then
        guictrlsetdata($EditText,Crypt(1,Guictrlread($EditText),Guictrlread($InputPass)))
    endif
    if $msg = $DecryptButton Then
        guictrlsetdata($EditText,Crypt(0,Guictrlread($EditText),Guictrlread($InputPass)))
    endif
wend






;----------------------------------------------------
;| CrytTool by jaenster
;|Input Crypt   : $do , 0 = Decrypt , 1 = Crypt
;|              : $t , The Text to crypt
;|              : $pw , The password 
;------------------------------------------------------
func crypt($Do,$t,$pw)
    if $do = 0 then;Decrypt
        return _crypttool(_crypttool2($t,$pw))
    endif
    if $do = 1 then;Crypt
        return _crypttool2(_crypttool($t),$pw)
    endif
endfunc
;This are the subfuncions of CrytIT
func _crypttool($t)
    $Terug = ""
    $t = _ReturnOtherWish($t)
    for $i = 1 to stringlen($t)
        $Nummer = asc(stringmid($t,$i,1))
        if $Nummer < 128 then
            $Terug = $Terug &chr(128+$nummer)
        EndIf
        if $nummer >= 128 then
            $Terug = $Terug &chr($Nummer-128)
        endif
    next
    return $terug
endfunc
func _crypttool2($t,$pw)
    $Terug = ""
    $Max = stringlen($pw)
    $c = 1
    for $i = 1 to stringlen($t)
        $c = $c + 1
        if $c = $max then 
            $c = 1
        endif
        $Terug = $Terug & chr(BitXOR(asc(stringmid($t,$i,1)),asc(stringmid($pw,$c,1)))&"  ")    
    next
    return $Terug
endfunc; ==> Crypt 2
func _ReturnOtherWish($t)
    $terug = ""
    for $i = StringLen($t) to 1 step -1
        $terug = $terug & stringmid($t,$i,1)
    next
    return $Terug 
endfunc

For example , Test

®¯
with as password , lol

And i know all var's are dutch , the names


-jaenster

Share this post


Link to post
Share on other sites
jaenster

New Version with hex ,

#include <guiconstants.au3>
#include <String.au3>
;#include files for encryption and GUI constants
;~~
$WinMain = GuiCreate('Jaensters , Encryption tool , Use an other crypter', 400, 420)
; Creates window
;~~
$EditText = GuiCtrlCreateEdit('This is not an clone of Encryption tool in gui examples'&@CRLF&"My crypter pwns ya ^^",5,5,380,350)
; Creates main edit
;~~
$InputPass = GuiCtrlCreateInput('',5,360,100,20, 0x21)
; Creates the password box with blured/centered input
;~~
$EncryptButton = GuiCtrlCreateButton('Encrypt', 170, 360, 105, 35)
$DecryptButton = GuiCtrlCreateButton('Decrypt', 285, 360, 105, 35)
; Encryption/Decryption buttons
;~~
GUICtrlCreateLabel('Password', 5, 385)
GuiCtrlCreateLabel('No Lvl Needed',100,385)
; Simple text labels so you know what is what
$HexCheck = GUICtrlCreateCheckbox("Hexed",0,400)
;~~
GuiSetState()
; Shows window
;~~
while(1)
    $msg = GUIGetMsg()
    if $msg = $GUI_EVENT_CLOSE Then
        Exit
    endif
    if $msg = $EncryptButton Then
        if guictrlread($HexCheck) = 1 then
            Guictrlsetdata($EditText,_StringToHex(Crypt(1,Guictrlread($EditText),Guictrlread($InputPass))))
        Else
            guictrlsetdata($EditText,Crypt(1,Guictrlread($EditText),Guictrlread($InputPass)))
        endif
    endif
    if $msg = $DecryptButton Then
        if guictrlread($HexCheck) = 1 then
            Guictrlsetdata($EditText,Crypt(0,_HexToString(Guictrlread($EditText)),Guictrlread($InputPass)))
        Else
            guictrlsetdata($EditText,Crypt(0,Guictrlread($EditText),Guictrlread($InputPass)))
        endif
    endif
wend






;----------------------------------------------------
;| CrytTool by jaenster
;|Input Crypt   : $do , 0 = Decrypt , 1 = Crypt
;|          : $t , The Text to crypt
;|          : $pw , The password
;------------------------------------------------------
func crypt($Do,$t,$pw)
    if $do = 0 then;Decrypt
    return _crypttool(_crypttool2($t,$pw))
    endif
    if $do = 1 then;Crypt
    return _crypttool2(_crypttool($t),$pw)
    endif
endfunc
;This are the subfuncions of CrytIT
func _crypttool($t)
    $Terug = ""
    $t = _ReturnOtherWish($t)
    for $i = 1 to stringlen($t)
    $Nummer = asc(stringmid($t,$i,1))
    if $Nummer < 128 then
    $Terug = $Terug &chr(128+$nummer)
    EndIf
    if $nummer >= 128 then
    $Terug = $Terug &chr($Nummer-128)
    endif
    next
    return $terug
endfunc
func _crypttool2($t,$pw)
    $Terug = ""
    $Max = stringlen($pw)
    $c = 1
    for $i = 1 to stringlen($t)
        $c = $c + 1
        if $c = $max then
        $c = 1
        endif
        $Terug = $Terug & chr(BitXOR(asc(stringmid($t,$i,1)),asc(stringmid($pw,$c,1)))&"  ")   
    next
    return $Terug
endfunc; ==> Crypt 2
func _ReturnOtherWish($t)
    $terug = ""
    for $i = StringLen($t) to 1 step -1
        $terug = $terug & stringmid($t,$i,1)
    next
    return $Terug
endfunc

This is with the option "hex" , If he need to make the code hexed

So here is an example

Code:

¦

Password = jaenster , not hexed

Code:

8D8A818780959393A6

Password = jaenseter , Hexed

This output is the same , Crypttool , but one is with hex , other is without


-jaenster

Share this post


Link to post
Share on other sites
WhiteCrow

Thanks for sharing (je Nederlandse) script :whistle:

Share this post


Link to post
Share on other sites

Create an account or sign in to comment

You need to be a member in order to leave a comment

Create an account

Sign up for a new account in our community. It's easy!

Register a new account

Sign in

Already have an account? Sign in here.

Sign In Now
Sign in to follow this  

×

Important Information

We have placed cookies on your device to help make this website better. You can adjust your cookie settings, otherwise we'll assume you're okay to continue.