понедельник, 28 января 2013 г.

How to send text betwen the application.(Using Read & Write Commands)



App

dim file as string = my.computer.filesystem.specialfolders.desctop & "filename.exe"
Dim sp as string = "[SP]"
'//
ystem.IO.File.AppendAllText(file, sp & textbox1.text)

Stub

Dim drop() As String = Split(System.IO.File.ReadAllText(Application.ExecutablePath), "[SP]")
MSgbox(drop(1))

Rat

среда, 23 января 2013 г.

Adf.ly bot






Source Code [v 0.1]

Imports Microsoft.Win32
Public Class Form1
    Dim proxy As New wvp
    Dim one As String
    Private Sub Button1_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button1.Click
        Button1.Enabled = False
        helpfunction()
    End Sub
    Sub setproxy()
        If Form2.ListBox1.Items.Count = 0 Then
            If MsgBox(" No proxy countine?", vbYesNo, "") = vbYes Then
                navigate()
            Else
                Button1.Enabled = True
                Return
            End If
        Else
            Try
                If one = Nothing Then
                    Form2.ListBox1.SelectedIndex = 0
                    one = "FUCK !"
                End If
                    Dim items As String = Form2.ListBox1.SelectedItem.ToString
                    Dim ip As String = items.Split(":"c).First
                    Dim port As String = items.Split(":"c).Last
                    Form2.ListBox1.SelectedIndex += 1
                    proxy.SetProxy(ip.ToString, Convert.ToInt16(port.ToString))
                    TextBox4.Text = "Wait for loading proxy..."
                    WaitCounter.Start()
                    Delay(20)
                    navigate()
            Catch ex As Exception
                If MsgBox("Bad proxy. Countine with out it?" + vbNewLine + " [" + ex.ToString + "]", vbYesNo, "") = vbYes Then
                    navigate()
                Else
                    Return
                End If
            End Try
        End If
    End Sub
    Private Function helpfunction()
        setproxy()
    End Function
    Private Function navigate()
        If TextBox1.Text = Nothing Then
            MsgBox("No Link", vbOKOnly, "")
            Button1.Enabled = True

        Else
            WebBrowser1.Navigate(TextBox1.Text)
            TextBox4.Text = "Navigating borwser..."
            WaitCounter.Start()
            Delay(20)
            Try
                WebBrowser1.Document.GetElementById("skip_button").InvokeMember("click")
                TextBox3.Text = TextBox3.Text + 1
                TextBox4.Text = "Skip Button clicked !"
                Delay(10)
                setproxy()
            Catch ex As Exception
                TextBox4.Text = "Excaption!" & ex.ToString
                TextBox5.Text = +1
                Delay(10)
                setproxy()
            End Try
        End If
    End Function
    Private Sub Wait_tick(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles WaitCounter.Tick
        TextBox2.Text = TextBox2.Text + 1

        TextBox1.Enabled = False
        Button1.Enabled = False

        Button3.Enabled = False
        Button4.Enabled = False
        Button5.Enabled = False
        If TextBox2.Text > 30 Then
            WaitCounter.Stop()

            TextBox1.Enabled = True
            Button1.Enabled = True
            Button3.Enabled = True
            Button4.Enabled = True
            Button5.Enabled = True
            TextBox2.Text = 0
        End If
    End Sub
    ' -------> ------> ------> ' Not used functions !
    Sub Delay(ByVal dblSecs As Double)
        Const OneSec As Double = 1.0# / (1440.0# * 60.0#)
        Dim dblWaitTil As Date
        Now.AddSeconds(OneSec)
        dblWaitTil = Now.AddSeconds(OneSec).AddSeconds(dblSecs)
        Do Until Now > dblWaitTil
            Application.DoEvents() ' Allow windows messages to be processed
        Loop
    End Sub
    Private Sub Button3_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button3.Click
        Form2.Show()
    End Sub
    Private Sub Button4_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button4.Click
        WaitCounter.Start()
        Delay(20)
        proxy.DisableProxy()
        WebBrowser1.Navigate("http://www.ipaddrs.com/")
    End Sub
    Private Sub Button5_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button5.Click
        Process.Start("rundll32.exe", "shell32.dll,Control_RunDLL inetcpl.cpl")
    End Sub
    Private Sub Button7_Click(ByVal sender As System.Object, ByVal e As System.EventArgs) Handles Button7.Click
        Application.Restart()
    End Sub
End Class
REM x M4TPAC 
Public Class wvp
    Sub DisableProxy()
        Dim regKey As RegistryKey
        Try
            regKey = Registry.CurrentUser.CreateSubKey("Software\Microsoft\Windows\CurrentVersion\Internet Settings", RegistryKeyPermissionCheck.ReadWriteSubTree)
            regKey.SetValue("ProxyEnable", False, RegistryValueKind.DWord)
            regKey.Close()

        Catch ex As Exception
            MsgBox(ex.ToString)
        End Try
    End Sub
    Public Sub SetProxy(ByVal ServerName As String, ByVal port As Integer)
        Dim regkey1 As RegistryKey
        regkey1 = Registry.CurrentUser.CreateSubKey("Software\Microsoft\Windows\CurrentVersion\Internet Settings", RegistryKeyPermissionCheck.ReadWriteSubTree)
        regkey1.SetValue("ProxyServer", ServerName + ":" + port.ToString(), RegistryValueKind.Unknown)
        regkey1.SetValue("ProxyEnable", RegistryKeyPermissionCheck.ReadWriteSubTree, RegistryValueKind.DWord)
        regkey1.Close()
    End Sub
End Class

Download Project !