discord icon
سرور دیسکورد گاردایران

پست های پیشنهاد شده

••.•´¯`•.•• 🎀 به نام خدا 🎀 ••.•`¯´•.••

با سلام خدمت کاربران محترم انجمن گاردایران

در این تاپیک یک رمزنگاری و رمزگشایی متن رو با برنامه Autoit نوشتم میتونید استفاده کنید سورس کدها و فیلم آموزشی نحوه ی استفاده را قرار میدم

;Code By rvlocker
;;;;;;;;guardiran.org
#Region ;**** Directives created by AutoIt3Wrapper_GUI ****
#AutoIt3Wrapper_Icon=..\Downloads\defend-encryption-cyan-1_0.ico
#AutoIt3Wrapper_UseX64=n
#AutoIt3Wrapper_Res_Comment=Code by rvlocker --> This is a program for text encryption
#AutoIt3Wrapper_Res_Description=Text encryption
#AutoIt3Wrapper_Run_Au3Stripper=y
#EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
#include <Crypt.au3>
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <StaticConstants.au3>
#include <TabConstants.au3>
#include <WindowsConstants.au3>
#Region ### START Koda GUI section ### Form=
Global $Form1 = GUICreate("EnCrypt Text ! code by---> rvlocker", 570, 256, 302, 173)
GUISetBkColor(0x008000)
Global $Tab1 = GUICtrlCreateTab(8, 0, 553, 249)
Global $enCryptText = GUICtrlCreateTabItem("EnCrypt")
Global $Edit1 = GUICtrlCreateEdit("", 48, 32, 265, 73)
GUICtrlSetData(-1, "")
Global $Button1 = GUICtrlCreateButton("SetPassword", 328, 48, 121, 33)
GUICtrlSetFont(-1, 8, 400, 0, "Broadway")
GUICtrlSetColor(-1, 0x800000)
GUICtrlSetBkColor(-1, 0x00FFFF)
Global $Edit2 = GUICtrlCreateEdit("", 48, 136, 265, 73)
GUICtrlSetData(-1, "")
Global $Button2 = GUICtrlCreateButton("Encrypt", 328, 160, 121, 33)
GUICtrlSetFont(-1, 8, 400, 0, "Elephant")
GUICtrlSetColor(-1, 0x800080)
GUICtrlSetBkColor(-1, 0x99B4D1)
Global $deCryptText = GUICtrlCreateTabItem("DeCrypt")
Global $Edit3 = GUICtrlCreateEdit("", 48, 40, 265, 73)
GUICtrlSetData(-1, "")
Global $Button3 = GUICtrlCreateButton("YourPassword", 328, 56, 121, 33)
GUICtrlSetFont(-1, 8, 800, 0, "Sitka Text")
GUICtrlSetColor(-1, 0x0000FF)
GUICtrlSetBkColor(-1, 0x800080)
Global $Edit4 = GUICtrlCreateEdit("", 48, 136, 265, 73)
GUICtrlSetData(-1, "")
Global $Button4 = GUICtrlCreateButton("DeCrypt", 328, 152, 121, 33)
GUICtrlSetFont(-1, 8, 800, 0, "Ravie")
GUICtrlSetColor(-1, 0x008080)
Global $Help = GUICtrlCreateTabItem("Help")
Global $Label1 = GUICtrlCreateLabel("Hello, to use the program", 144, 32, 219, 22)
GUICtrlSetFont(-1, 11, 400, 2, "Showcard Gothic")
GUICtrlSetColor(-1, 0xFF0000)
GUICtrlSetBkColor(-1, 0xFFFFFF)
Global $Label2 = GUICtrlCreateLabel("first enter your password ", 128, 56, 248, 24)
GUICtrlSetFont(-1, 12, 400, 2, "Showcard Gothic")
GUICtrlSetBkColor(-1, 0xFFFFFF)
Global $Label3 = GUICtrlCreateLabel("guardiran.org", 136, 160, 253, 30)
GUICtrlSetFont(-1, 16, 400, 0, "Wide Latin")
GUICtrlSetColor(-1, 0x00FF00)
GUICtrlSetBkColor(-1, 0xFFFFFF)
Global $Label4 = GUICtrlCreateLabel("and then your text for encryption", 112, 96, 289, 22)
GUICtrlSetFont(-1, 11, 400, 0, "Showcard Gothic")
GUICtrlSetColor(-1, 0xFF00FF)
GUICtrlSetBkColor(-1, 0xFFFFFF)
GUICtrlCreateTabItem("")
GUISetState(@SW_SHOW)
#EndRegion ### END Koda GUI section ###

While 1
	$nMsg = GUIGetMsg()
	Switch $nMsg
		Case $GUI_EVENT_CLOSE
			Exit
		Case $Button1
			Global $PasswordFromUser1 = GUICtrlRead($Edit1)
		Case $Button2
			Global $TextFromUser1 = GUICtrlRead($Edit2)
			$encData = _Crypt_EncryptData($TextFromUser1,$PasswordFromUser1,$CALG_AES_256)
			MsgBox(64,"",$encData)
			$saveLocation = FileSaveDialog("Encrypt File ",@ScriptDir,"Text Files (*.txt)",16)
			FileWrite($saveLocation,$encData)
		Case $Button3
			Global $PasswordFromUser2 = GUICtrlRead($Edit3)
		Case $Button4
			$deCryptData = _Crypt_DecryptData($encData,$PasswordFromUser2,$CALG_AES_256)
			MsgBox(64,"",BinaryToString($encData))
			$saveLocation2 = FileSaveDialog("Decrypt File ",@ScriptDir,"Text Files (*.txt)",16)
			FileWrite($saveLocation2,$deCryptData)
	EndSwitch
WEnd



در تاپیک های بعدی برنامه های بیشتری قرار خواهم داد

دانلود فایل ---->> دانلود از github

برای آموزش های بیشتر به دیسکورد گاردایران مراجعه فرمایید با تشکر

به اشتراک گذاری این ارسال


لینک به ارسال
به اشتراک گذاری در سایت های دیگر

••.•´¯`•.•• 🎀 به نام خدا 🎀 ••.•`¯´•.••

با سلام خدمت کاربران محترم انجمن گاردایران

در این تاپیک یک برنامه ی دیگه برای رمزنگاری متن با زبان VB نوشتم امیدوارتون خوشتون بیاد

ca5b6e422c9ec4292c09fb2d39729e07199d21175aed9de17fad49b16d7a289d

Source


'Profile: https://guardiran.org/profile/30462-rvlocker/
' --------------------------------------------------------------------------------
' -                script written by Rvlocker Virus Creator                      -
' -                                Version 1.10                                  -
' -                                                                              -
' -                                                                              -
' -                            Created by Rvlocker                               -
' -                                                                              -
' -                        With thanks to Guardiran.org                          -
' -                                                                              -
' --------------------------------------------------------------------------------
Public Class frmMain

#Region " [ Encryption Functions: Code By Rvlocker ] "
    Public Function DES_Encrypt(ByVal input As String, ByVal pass As String) As String
        Dim DES As New System.Security.Cryptography.DESCryptoServiceProvider
        Dim Hash_DES As New System.Security.Cryptography.MD5CryptoServiceProvider
        Dim encrypted As String = ""
        Try
            Dim hash(7) As Byte
            Dim temp As Byte() = Hash_DES.ComputeHash(System.Text.ASCIIEncoding.ASCII.GetBytes(pass))
            Array.Copy(temp, 0, hash, 0, 8)
            DES.Key = hash
            DES.Mode = Security.Cryptography.CipherMode.ECB
            Dim DESEncrypter As System.Security.Cryptography.ICryptoTransform = DES.CreateEncryptor
            Dim Buffer As Byte() = System.Text.ASCIIEncoding.ASCII.GetBytes(input)
            encrypted = Convert.ToBase64String(DESEncrypter.TransformFinalBlock(Buffer, 0, Buffer.Length))
            Return encrypted
        Catch ex As Exception
        End Try
    End Function
    Public Function DES_Decrypt(ByVal input As String, ByVal pass As String) As String
        Dim DES As New System.Security.Cryptography.DESCryptoServiceProvider
        Dim Hash_DES As New System.Security.Cryptography.MD5CryptoServiceProvider
        Dim decrypted As String = ""
        Try
            Dim hash(7) As Byte
            Dim temp As Byte() = Hash_DES.ComputeHash(System.Text.ASCIIEncoding.ASCII.GetBytes(pass))
            Array.Copy(temp, 0, hash, 0, 8)
            DES.Key = hash
            DES.Mode = Security.Cryptography.CipherMode.ECB
            Dim DESDecrypter As System.Security.Cryptography.ICryptoTransform = DES.CreateDecryptor
            Dim Buffer As Byte() = Convert.FromBase64String(input)
            decrypted = System.Text.ASCIIEncoding.ASCII.GetString(DESDecrypter.TransformFinalBlock(Buffer, 0, Buffer.Length))
            Return decrypted
        Catch ex As Exception
        End Try
    End Function
    Public Function AES_Encrypt(ByVal input As String, ByVal pass As String) As String
        Dim AES As New System.Security.Cryptography.RijndaelManaged
        Dim Hash_AES As New System.Security.Cryptography.MD5CryptoServiceProvider
        Dim encrypted As String = ""
        Try
            Dim hash(31) As Byte
            Dim temp As Byte() = Hash_AES.ComputeHash(System.Text.ASCIIEncoding.ASCII.GetBytes(pass))
            Array.Copy(temp, 0, hash, 0, 16)
            Array.Copy(temp, 0, hash, 15, 16)
            AES.Key = hash
            AES.Mode = Security.Cryptography.CipherMode.ECB
            Dim DESEncrypter As System.Security.Cryptography.ICryptoTransform = AES.CreateEncryptor
            Dim Buffer As Byte() = System.Text.ASCIIEncoding.ASCII.GetBytes(input)
            encrypted = Convert.ToBase64String(DESEncrypter.TransformFinalBlock(Buffer, 0, Buffer.Length))
            Return encrypted
        Catch ex As Exception
        End Try
    End Function
    Public Function AES_Decrypt(ByVal input As String, ByVal pass As String) As String
        Dim AES As New System.Security.Cryptography.RijndaelManaged
        Dim Hash_AES As New System.Security.Cryptography.MD5CryptoServiceProvider
        Dim decrypted As String = ""
        Try
            Dim hash(31) As Byte
            Dim temp As Byte() = Hash_AES.ComputeHash(System.Text.ASCIIEncoding.ASCII.GetBytes(pass))
            Array.Copy(temp, 0, hash, 0, 16)
            Array.Copy(temp, 0, hash, 15, 16)
            AES.Key = hash
            AES.Mode = Security.Cryptography.CipherMode.ECB
            Dim DESDecrypter As System.Security.Cryptography.ICryptoTransform = AES.CreateDecryptor
            Dim Buffer As Byte() = Convert.FromBase64String(input)
            decrypted = System.Text.ASCIIEncoding.ASCII.GetString(DESDecrypter.TransformFinalBlock(Buffer, 0, Buffer.Length))
            Return decrypted
        Catch ex As Exception
        End Try
    End Function
    Public Function TripleDES_Encrypt(ByVal input As String, ByVal pass As String) As String
        Dim TripleDES As New System.Security.Cryptography.TripleDESCryptoServiceProvider
        Dim Hash_TripleDES As New System.Security.Cryptography.MD5CryptoServiceProvider
        Dim encrypted As String = ""
        Try
            Dim hash(23) As Byte
            Dim temp As Byte() = Hash_TripleDES.ComputeHash(System.Text.ASCIIEncoding.ASCII.GetBytes(pass))
            Array.Copy(temp, 0, hash, 0, 16)
            Array.Copy(temp, 0, hash, 15, 8)
            TripleDES.Key = hash
            TripleDES.Mode = Security.Cryptography.CipherMode.ECB
            Dim DESEncrypter As System.Security.Cryptography.ICryptoTransform = TripleDES.CreateEncryptor
            Dim Buffer As Byte() = System.Text.ASCIIEncoding.ASCII.GetBytes(input)
            encrypted = Convert.ToBase64String(DESEncrypter.TransformFinalBlock(Buffer, 0, Buffer.Length))
            Return encrypted
        Catch ex As Exception
        End Try
    End Function
    Public Function TripleDES_Decrypt(ByVal input As String, ByVal pass As String) As String
        Dim TripleDES As New System.Security.Cryptography.TripleDESCryptoServiceProvider
        Dim Hash_TripleDES As New System.Security.Cryptography.MD5CryptoServiceProvider
        Dim decrypted As String = ""
        Try
            Dim hash(23) As Byte
            Dim temp As Byte() = Hash_TripleDES.ComputeHash(System.Text.ASCIIEncoding.ASCII.GetBytes(pass))
            Array.Copy(temp, 0, hash, 0, 16)
            Array.Copy(temp, 0, hash, 15, 8)
            TripleDES.Key = hash
            TripleDES.Mode = Security.Cryptography.CipherMode.ECB
            Dim DESDecrypter As System.Security.Cryptography.ICryptoTransform = TripleDES.CreateDecryptor
            Dim Buffer As Byte() = Convert.FromBase64String(input)
            decrypted = System.Text.ASCIIEncoding.ASCII.GetString(DESDecrypter.TransformFinalBlock(Buffer, 0, Buffer.Length))
            Return decrypted
        Catch ex As Exception
        End Try
    End Function
    Public Function RC2_Encrypt(ByVal input As String, ByVal pass As String) As String
        Dim RC2 As New System.Security.Cryptography.RC2CryptoServiceProvider
        Dim Hash_RC2 As New System.Security.Cryptography.MD5CryptoServiceProvider
        Dim encrypted As String = ""
        Try
            Dim hash() As Byte = Hash_RC2.ComputeHash(System.Text.ASCIIEncoding.ASCII.GetBytes(pass))

            RC2.Key = hash
            RC2.Mode = Security.Cryptography.CipherMode.ECB
            Dim DESEncrypter As System.Security.Cryptography.ICryptoTransform = RC2.CreateEncryptor
            Dim Buffer As Byte() = System.Text.ASCIIEncoding.ASCII.GetBytes(input)
            encrypted = Convert.ToBase64String(DESEncrypter.TransformFinalBlock(Buffer, 0, Buffer.Length))
            Return encrypted
        Catch ex As Exception
        End Try
    End Function
    Public Function RC2_Decrypt(ByVal input As String, ByVal pass As String) As String
        Dim RC2 As New System.Security.Cryptography.RC2CryptoServiceProvider
        Dim Hash_RC2 As New System.Security.Cryptography.MD5CryptoServiceProvider
        Dim decrypted As String = ""
        Try
            Dim hash() As Byte = Hash_RC2.ComputeHash(System.Text.ASCIIEncoding.ASCII.GetBytes(pass))
            RC2.Key = hash
            RC2.Mode = Security.Cryptography.CipherMode.ECB
            Dim DESDecrypter As System.Security.Cryptography.ICryptoTransform = RC2.CreateDecryptor
            Dim Buffer As Byte() = Convert.FromBase64String(input)
            decrypted = System.Text.ASCIIEncoding.ASCII.GetString(DESDecrypter.TransformFinalBlock(Buffer, 0, Buffer.Length))
            Return decrypted
        Catch ex As Exception
        End Try
    End Function
    Public Function XOR_Encrypt(ByVal Input As String, ByVal pass As String) As String
        Dim out As New System.Text.StringBuilder
        Dim u As Integer
        For i As Integer = 0 To Input.Length - 1
            Dim tmp As String = Hex(Asc(Input(i)) Xor Asc(pass(u)))
            If tmp.Length = 1 Then tmp = "0" & tmp
            out.Append(tmp)
            If u = pass.Length - 1 Then u = 0 Else u = u + 1
        Next
        Return out.ToString
    End Function
    Public Function XOR_Decrypt(ByVal Input As String, ByVal pass As String) As String
        Dim out As New System.Text.StringBuilder
        Dim u As Integer
        For i As Integer = 0 To Input.Length - 1 Step +2
            Dim tmp As String = Chr(("&H" & Input.Substring(i, 2)) Xor Asc(pass(u)))
            out.Append(tmp)
            If u = pass.Length - 1 Then u = 0 Else u = u + 1
        Next
        Return out.ToString
    End Function
    Public Function CustomXOR_Encrypt(ByVal Input As String, ByVal pass As String) As String
        Dim out As New System.Text.StringBuilder
        Dim Hash As New System.Security.Cryptography.MD5CryptoServiceProvider
        Dim XorHash As Byte() = Hash.ComputeHash(System.Text.Encoding.ASCII.GetBytes(pass))
        Dim u As Integer
        For i As Integer = 0 To Input.Length - 1
            Dim tmp As String = Hex(Asc(Input(i)) Xor XorHash(u))
            If tmp.Length = 1 Then tmp = "0" & tmp
            out.Append(tmp)
            If u = pass.Length - 1 Then u = 0 Else u = u + 1
        Next
        Return out.ToString
    End Function
    Public Function CustomXOR_Decrypt(ByVal Input As String, ByVal pass As String) As String
        Dim out As New System.Text.StringBuilder
        Dim Hash As New System.Security.Cryptography.MD5CryptoServiceProvider
        Dim XorHash As Byte() = Hash.ComputeHash(System.Text.Encoding.ASCII.GetBytes(pass))
        Dim u As Integer
        For i As Integer = 0 To Input.Length - 1 Step +2
            Dim tmp As String = Chr(("&H" & Input.Substring(i, 2)) Xor XorHash(u))
            out.Append(tmp)
            If u = pass.Length - 1 Then u = 0 Else u = u + 1
        Next
        Return out.ToString
    End Function
    Public Function RSA_Encrypt(ByVal Input As String) As String
        Dim cp As New Security.Cryptography.CspParameters
        cp.Flags = Security.Cryptography.CspProviderFlags.UseMachineKeyStore
        cp.KeyContainerName = "Keys"
        Dim RSA As New Security.Cryptography.RSACryptoServiceProvider(cp)

        Dim buffer As Byte() = System.Text.Encoding.UTF8.GetBytes(Input)
        Dim encrypted As Byte() = RSA.Encrypt(buffer, True)
        Return Convert.ToBase64String(encrypted)
    End Function
    Public Function RSA_Decrypt(ByVal Input As String) As String
        Dim cp As New Security.Cryptography.CspParameters
        cp.Flags = Security.Cryptography.CspProviderFlags.UseMachineKeyStore
        cp.KeyContainerName = "Keys"
        Dim RSA As New Security.Cryptography.RSACryptoServiceProvider(cp)
        Dim buffer As Byte() = Convert.FromBase64String(Input)
        Dim decrypted As Byte() = RSA.Decrypt(buffer, True)
        Return System.Text.Encoding.UTF8.GetString(decrypted)
    End Function
#End Region

    Private Sub frmMain_Load(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles MyBase.Load

    End Sub

    Private Sub btnEncrypt_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnEncrypt.Click
        If EncryptionMethod.Text = "AES Encryption" Then
            TextToEncrypt.Text = AES_Encrypt(TextToEncrypt.Text, EncryptionPassword.Text)
        ElseIf EncryptionMethod.Text = "RC2 Encryption" Then
            TextToEncrypt.Text = RC2_Encrypt(TextToEncrypt.Text, EncryptionPassword.Text)
        ElseIf EncryptionMethod.Text = "RSA Encryption" Then
            TextToEncrypt.Text = RSA_Encrypt(TextToEncrypt.Text)
        ElseIf EncryptionMethod.Text = "XOR Encryption" Then
            TextToEncrypt.Text = XOR_Encrypt(TextToEncrypt.Text, EncryptionPassword.Text)
        ElseIf EncryptionMethod.Text = "DES Encryption" Then
            TextToEncrypt.Text = DES_Encrypt(TextToEncrypt.Text, EncryptionPassword.Text)
        ElseIf EncryptionMethod.Text = "TripleDES Encryption" Then
            TextToEncrypt.Text = TripleDES_Encrypt(TextToEncrypt.Text, EncryptionPassword.Text)
        ElseIf EncryptionMethod.Text = "XOR Encryption [Custom]" Then
            TextToEncrypt.Text = CustomXOR_Encrypt(TextToEncrypt.Text, EncryptionPassword.Text)
        End If
    End Sub

    Private Sub btnDecrypt_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnDecrypt.Click
        If EncryptionMethod.Text = "AES Encryption" Then
            TextToDecrypt.Text = AES_Decrypt(TextToDecrypt.Text, EncryptionPassword.Text)
        ElseIf EncryptionMethod.Text = "RC2 Encryption" Then
            TextToDecrypt.Text = RC2_Decrypt(TextToDecrypt.Text, EncryptionPassword.Text)
        ElseIf EncryptionMethod.Text = "RSA Encryption" Then
            TextToDecrypt.Text = RSA_Decrypt(TextToDecrypt.Text)
        ElseIf EncryptionMethod.Text = "XOR Encryption" Then
            TextToDecrypt.Text = XOR_Decrypt(TextToDecrypt.Text, EncryptionPassword.Text)
        ElseIf EncryptionMethod.Text = "DES Encryption" Then
            TextToDecrypt.Text = DES_Decrypt(TextToDecrypt.Text, EncryptionPassword.Text)
        ElseIf EncryptionMethod.Text = "TripleDES Encryption" Then
            TextToDecrypt.Text = TripleDES_Decrypt(TextToDecrypt.Text, EncryptionPassword.Text)
        ElseIf EncryptionMethod.Text = "XOR Encryption [Custom]" Then
            TextToDecrypt.Text = CustomXOR_Decrypt(TextToDecrypt.Text, EncryptionPassword.Text)
        End If
    End Sub

    Private Sub btnCopy1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCopy1.Click
        My.Computer.Clipboard.Clear()
        My.Computer.Clipboard.SetText(TextToEncrypt.Text)
    End Sub

    Private Sub btnCopy2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnCopy2.Click
        My.Computer.Clipboard.Clear()
        My.Computer.Clipboard.SetText(TextToDecrypt.Text)
    End Sub

    Private Sub btnPaste1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnPaste1.Click
        TextToEncrypt.Text = My.Computer.Clipboard.GetText()
    End Sub

    Private Sub btnPaste2_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles btnPaste2.Click
        TextToDecrypt.Text = My.Computer.Clipboard.GetText()
    End Sub
End Class

پسورد ---->>>> guardiran.org

Text Encryption.rar

به اشتراک گذاری این ارسال


لینک به ارسال
به اشتراک گذاری در سایت های دیگر

برای ارسال دیدگاه یک حساب کاربری ایجاد کنید یا وارد حساب خود شوید

برای اینکه بتوانید دیدگاهی ارسال کنید نیاز دارید که کاربر سایت شوید

ایجاد یک حساب کاربری

برای حساب کاربری جدید در سایت ما ثبت نام کنید. عضویت خیلی ساده است !

ثبت نام یک حساب کاربری جدید

ورود به حساب کاربری

دارای حساب کاربری هستید؟ از اینجا وارد شوید

ورود به حساب کاربری