02-08-2012, 22:15
(This post was last modified: 02-08-2012, 23:53 by SuperNovaAO.)
Hey,
So I can fetch the post key, this code is very crude and done very fast
so don't even think about trolling me.
And some of it is copied from @iAegle
So I can fetch the post key, this code is very crude and done very fast
so don't even think about trolling me.
And some of it is copied from @iAegle
VB Code
- Private Function Login(ByVal User As String, ByVal Password As String) As Boolean
- Dim Data As New System.Collections.Specialized.NameValueCollection()
- Dim SData As New System.Collections.Specialized.NameValueCollection()
- Data.Add("username", User)
- Data.Add("password", Password)
- Data.Add("submit", "Login")
- Data.Add("action", "do_login")
- SData.Add("action", "add_shout")
- SData.Add("shout_data", "ASDASASD")
- Dim wb As New WebClient()
- Dim bytes As Byte() = wb.UploadValues("http://itsmods.com/forum/member.php", "POST", Data)
- My.Computer.FileSystem.WriteAllText("C:\rcrayon\bytes.txt", System.Text.Encoding.ASCII.GetString(bytes), False)
- ListBox1.Items.AddRange(System.IO.File.ReadAllLines("C:\rcrayon\bytes.txt"))
- Dim i As Integer
- For i = 0 To ListBox1.Items.Count - 1
- If InStr(ListBox1.Items(i), "var my_post_key") Then
- Dim PostKey As Array
- Dim PostKeyTrimmed As String
- Dim PostKeyClean As String
- PostKey = Split(ListBox1.Items(i), "=")
- PostKeyTrimmed = Replace(PostKey(1), Chr(34), "")
- PostKeyClean = Replace(PostKeyTrimmed, ";", "")
- MsgBox("Your postkey is: " + PostKeyClean)
- SData.Add("postcode", PostKeyClean)
- End If
- Next
- Dim wb2 As New WebClient()
- Dim sbytes As Byte() = wb2.UploadValues("http://www.itsmods.com/forum/xmlhttp.php", "POST", SData)
- MsgBox(System.Text.Encoding.ASCII.GetString(sbytes))
- Return True
- Return False
- End Function
crAyon makes no warranty with respect to documents or other information available from this place, assumes no legal liability or responsibility whatsoever for the accuracy, completeness, or usefulness of any such information, and does not represent that its use would not infringe privately owned rights. crAyon disclaims all warranties, express and implied, including the warranties of merchantability and fitness for a particular purpose.