Hallo ihr Super-Forenmitglieder
Habe folgendes Problem, Ich habe ein Skript gemacht was den Quelltext eines anderen Skriptes sozusagen "Versteckt"
Ich kann den Fehler einfach nicht finden (Bin total Genervt wegen der Fehler-Suche
)
Vllt. findet ihr ja den Fehler:
Spoiler anzeigen
;~ UnReadable v0.20
;~ Alle Benötigten Include's
#include <ButtonConstants.au3>
#include <EditConstants.au3>
#include <GUIConstantsEx.au3>
#include <ProgressConstants.au3>
#include <StaticConstants.au3>
#include <WindowsConstants.au3>
#include <String.au3>
#include <File.au3>
;~ Die Gui
$hGui = GUICreate("UnReadable", 265, 98, 879, 232)
GUICtrlCreateLabel("Skript :", 8, 8, 45, 17)
GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif")
$hCodeInput = GUICtrlCreateInput("", 56, 8, 161, 21, BitOR($ES_AUTOHSCROLL, $ES_READONLY))
$hSelectFileBtn = GUICtrlCreateButton("...", 224, 8, 35, 25, $WS_GROUP)
GUICtrlSetFont(-1, 8, 800, 0, "MS Sans Serif")
$Progress1 = GUICtrlCreateProgress(8, 40, 250, 17)
$hStartBtn = GUICtrlCreateButton("Absichern!", 8, 64, 163, 25, $WS_GROUP)
GUISetState(@SW_SHOW)
;~ Gui-Status abfragen
While 1
$nMsg = GUIGetMsg()
Switch $nMsg
Case $GUI_EVENT_CLOSE
Exit
Case $hSelectFileBtn
$sFilename = FileOpenDialog("AutoIt-Datei auswählen", "", "AutoIt Skript (*.au3)")
If @error Or FileExists($sFilename) = 0 Then ContinueLoop
GUICtrlSetData($hCodeInput, $sFilename)
Case $hStartBtn
If GUICtrlRead($hCodeInput) = "" Then ContinueLoop
_Start(GUICtrlRead($hCodeInput))
MsgBox(64, "Info", "Erledigt!")
Exit
EndSwitch
WEnd
;~ Quellcode "Verstecken"
Func _Start($sFilePath = '')
Local $sName = _GetName($sFilePath)
Local $sPath = _GetPath($sFilePath)
Local $sContent = FileRead($sFilePath)
If StringInStr($sContent, "#include <String.au3>") Then $sContent = StringReplace($sContent, "#include <String.au3>", "")
Local $sCrypted = _StringEncrypt(1, $sContent, "SECURE", 2)
Local $sHex = _StringToHex("SECURE")
FileWrite($sPath & $sName & "_Secured.au3", "#include <String.au3>" & @CRLF)
FileWrite($sPath & $sName & "_Secured.au3", "Execute(_StringEncrypt(0, '" & $sCrypted & "', _HexToString(' " & $sHex & ' '), 2)) ")
EndFunc ;==>_Start
;~ Gibt den Pfad einer Datei zurück
Func _GetPath($sPath = '')
Local $sTmp1, $sTmp2, $sTmp3, $sTmp4
Local $sReturn = _PathSplit($sPath, $sTmp1, $sTmp2, $sTmp3, $sTmp4)
Return $sReturn[1] & $sReturn[2]
EndFunc ;==>_GetPath
;~ Gibt den Namen einer Datei zurück
Func _GetName($sPath = '')
Local $aSplit = StringSplit($sPath, "\")
Return StringTrimRight($aSplit[$aSplit[0]], 4)
EndFunc ;==>_GetName
Und noch mal als Download:
´Vielen Danke schonmal im Vorrauß!