BeAnonym für FireFox

  • Hi ich habe mich in letzter Zeit viel mit der FF.au3 beschäftigt und habe nun ein Script entwickelt was Proxys auf ihr Funktion testen und dann die Proxy Einstellungen in Firefox ändert. Wenn es beendet wird löscht es Cache und Verlauf.

    *Infos*

    Beschreibung:

    Mit BlackEyes BeAnonym surfen sie in Mozilla Firefox automatisch über Proxy Server. Damit sie völlig unproblematisch und ungestört surfen können werden die Proxy Server vorher auf ihre Funktionalität geprüft. Sollte der Proxy Server nicht mehr funktionieren wird er spätestens nach 20 Sekunden durch einen anderen ersetzt. Bevor sie das Programm beenden oder ihren PC herunterfahren löscht BlackEyes BeAnonym automatisch ihren Verlauf und ihren Cache.

    Voraussetzungen:

    BlackEyes BeAnonym leitet nur Ihren Datenverkehr von Mozilla Firefox über einen Proxy Server um. In anderen Programmen wird Ihr Datenverkehr nicht über einen Proxy Server umgeleitet. Benötigt sind Mozilla Firefox und das kostenlose Add-On MozRepl, welches falls es nicht vorhanden ist automatisch installiert wird.

    Hinweise:

    BlackEyes BeAnonym funktioniert nur wenn das Add-On MozRepl installiert und zu ihrer Mozilla Firefox Version kompatibel ist. Die Anonymität hängt von dem jeweiligen Proxy Server ab. Eigen Proxy Server können hinzugefügt werden in dem Sie den Ordner öffnen in dem Sie BlackEyes BeAnonym installiert haben und die Proxy.txt öffnen. Dort können sie nun den Proxy einfügen im Format

    [autoit]

    $IP & ":" & $Port

    [/autoit]

    . IP müssen sie dann durch die jeweilige IP des Proxy Servers ergänzen und Port durch den Port der benutzt werden soll. BlackEyes BeAnonym arbeitet immer im Hintergrund so das sie ungestört surfen können. Falls das BlackEyes BeAnonym läuft sehen sie unten rechts in der Taskleiste das BlackEyes BeAnonym Icon. Falls sie BlackEyes BeAnonym schon installiert haben und es erneut installieren wollen, müssen sie zuerst den Prozess BlackEyesBeAnonym.exe beenden, weil die Installation sonst fehlschlägt.

    Unterstützte Betriebssysteme: Windows XP, Windows Server 2003/2008, Windows Vista , Windows 7

    64 Bit kompatibel.

    Dateigröße: 800 KB

    Download und weitere Infos

    Source
    [autoit]

    #Region ;**** Directives created by AutoIt3Wrapper_GUI ****
    #AutoIt3Wrapper_icon=..\..\Desktop\BlackEyes\proxy.ico
    #AutoIt3Wrapper_outfile=..\..\Desktop\BlackEyes\BeAnonym\BlackEyesBeAnonym.exe
    #AutoIt3Wrapper_UseUpx=n
    #AutoIt3Wrapper_UseX64=n
    #EndRegion ;**** Directives created by AutoIt3Wrapper_GUI ****
    #cs
    Author: Molaynox
    Homepage: http://www.black-eyes-soft.tk
    E-Mail: [email='black.eyes.soft@gmx.de'][/email]
    Date: 26.12.2010 21:38
    #ce

    [/autoit] [autoit][/autoit] [autoit]

    #include <FF.au3>
    #include <FFEx.au3>
    #include <File.au3>
    ;~ #include <Array.au3>

    [/autoit] [autoit][/autoit] [autoit]

    Opt("TrayAutoPause", 0)
    Opt("TrayMenuMode", 3)
    Opt("TrayOnEventMode", 1)

    [/autoit] [autoit][/autoit] [autoit]

    TrayCreateItem("Exit")
    TrayItemSetOnEvent(-1, "_Exit")
    TrayCreateItem("About")
    TrayItemSetOnEvent(-1, "_About")

    [/autoit] [autoit][/autoit] [autoit]

    If RegRead("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\Current Version\Run", "SetProxy") <> @ScriptFullPath Then
    RegWrite("HKEY_LOCAL_MACHINE\SOFTWARE\Microsoft\Windows\Current Version\Run", "SetProxy", @ScriptFullPath)
    EndIf

    [/autoit] [autoit][/autoit] [autoit]

    Global $aProxy, $iExit = 0

    [/autoit] [autoit][/autoit] [autoit]

    OnAutoItExitRegister("_Exit")
    _FF_MozRepl_Detect()

    [/autoit] [autoit][/autoit] [autoit]

    If Not FileExists(@ScriptDir & "\Proxy.txt") Then
    MsgBox(48, "ERROR", "Cannot find Proxy.txt in Script Directory!" & @CRLF & _
    "Please move the Proxy.txt in this Directory: " & @ScriptDir)
    Exit
    EndIf

    [/autoit] [autoit][/autoit] [autoit]

    TCPStartup()
    $hFile = FileOpen(@ScriptDir & "\Proxy.txt")
    For $i = 1 To _FileCountLines(@ScriptDir & "\Proxy.txt")
    $sString = FileReadLine($hFile, $i)
    Global $aProxy = StringSplit($sString, ":", 2)
    $aProxy[0] = String(StringStripCR(StringStripWS($aProxy[0], 8)))
    $aProxy[1] = Int(StringStripCR(StringStripWS($aProxy[1], 8)))
    ConsoleWrite(@CRLF & "Test This Proxy:" & @CRLF & "IP: " & $aProxy[0] & @CRLF & "Port: " & $aProxy[1] & @CRLF)
    $MainSocket = TCPConnect($aProxy[0], $aProxy[1])
    If $MainSocket = -1 Then
    _FileWriteToLine(@ScriptDir & "\Proxy.txt", $i, "", 1)
    ConsoleWrite("DELETE " & $aProxy[0] & ":" & $aProxy[1] & @CRLF & "This Proxy doesn't work!" & @CRLF)
    Else
    ConsoleWrite("SUCCESFUL " & $aProxy[0] & ":" & $aProxy[1] & @CRLF & "This Proxy work!" & @CRLF)
    ExitLoop
    EndIf
    Next

    [/autoit] [autoit][/autoit] [autoit]

    Dim $aProxyLast[2]
    $aProxyLast[0] = "127.0.0.5"
    $aProxyLast[1] = 80
    $iCleaned = 0

    [/autoit] [autoit][/autoit] [autoit]

    AdlibRegister("_CheckProxy", 20000)

    [/autoit] [autoit][/autoit] [autoit]

    While Sleep(5000)
    If ProcessExists("firefox.exe") And _FFIsConnected() And $aProxy[0] <> $aProxyLast[0] Then
    If Not IsInt($aProxy[1]) Then
    MsgBox(48, "ERROR", "Integer Error")
    Exit
    EndIf
    _FFPrefSet("network.proxy.type", 1)
    _FFPrefSet("network.proxy.http", $aProxy[0])
    _FFPrefSet("network.proxy.http_port", $aProxy[1])
    _FFPrefSet("network.proxy.socks", $aProxy[0])
    _FFPrefSet("network.proxy.socks_port", $aProxy[1])
    _FFPrefSet("network.proxy.socks_version", 4)
    If _FFPrefGet("network.proxy.type") <> 1 And _FFPrefGet("network.proxy.http") <> $aProxy[0] And _
    _FFPrefGet("network.proxy.socks") <> $aProxy[0] And _FFPrefGet("network.proxy.http_port") <> $aProxy[1] And _
    _FFPrefGet("network.proxy.socks_port") <> $aProxy[1] Then
    MsgBox(48, "ERROR", "ERROR in _FFPrefSet()")
    Exit
    EndIf
    MsgBox(64, "", "Neuer Proxy:" & @CRLF & "IP: " & $aProxy[0] & @CRLF & "Port: " & $aProxy[1], 10000)
    ConsoleWrite(@CRLF & "Neuer Proxy:" & @CRLF & "IP: " & $aProxy[0] & @CRLF & "Port: " & $aProxy[1] & @CRLF)
    $aProxyLast[0] = $aProxy[0]
    $aProxyLast[1] = $aProxy[1]
    ElseIf ProcessExists("firefox.exe") And Not _FFIsConnected() Then
    If Not _FFConnect() Then
    MsgBox(16, "FATAL ERROR", "_FFConnect() Error! Please Start MozRepl Addon for FireFox before you start this Tool")
    EndIf
    EndIf
    WEnd

    [/autoit] [autoit][/autoit] [autoit]

    Func _Exit()
    If Not $iExit Then
    $iExit = 1
    _FFStart("about:blank", "default", 1, True)
    If ProcessExists("firefox.exe") And _FFIsConnected() Then
    _FFPrefReset("network.proxy.type")
    _FFPrefReset("network.proxy.http")
    _FFPrefReset("network.proxy.http_port")
    _FFPrefReset("network.proxy.socks")
    _FFPrefReset("network.proxy.socks_port")
    _FFPrefReset("network.proxy.socks_version")
    _FF_EmptyHistory()
    _FF_EmptyCache()
    MsgBox(64, "Info", "Verlauf und Cache wurden gelöscht.")
    EndIf
    _FFQuit()
    Exit
    EndIf
    EndFunc ;==>_Exit

    [/autoit] [autoit][/autoit] [autoit]

    Func _CheckProxy()
    For $i = 1 To _FileCountLines(@ScriptDir & "\Proxy.txt")
    $sString = FileReadLine($hFile, $i)
    Global $aProxy = StringSplit($sString, ":", 2)
    $aProxy[0] = String(StringStripCR(StringStripWS($aProxy[0], 8)))
    $aProxy[1] = Int(StringStripCR(StringStripWS($aProxy[1], 8)))
    $MainSocket = TCPConnect($aProxy[0], $aProxy[1])
    If $MainSocket = -1 Then
    _FileWriteToLine(@ScriptDir & "\Proxy.txt", $i, "", 1)
    Else
    ExitLoop
    EndIf
    Next
    EndFunc ;==>_CheckProxy

    [/autoit] [autoit][/autoit] [autoit]

    Func _About()
    MsgBox(64, "About", "Programmiert von: Black-Eyes-Soft" & @CRLF & "Support E-Mail: black.eyes.soft@gmx.de" & @CRLF & "Homepage: http://www.black-eyes-soft.tk")
    EndFunc

    [/autoit]

    Hätte gerne ein bisschen Feedback oder Tipps was man noch verbessern könnte.

    Einmal editiert, zuletzt von Molaynox (10. März 2011 um 16:50)