Public Declare Function X Lib "BnetAuth.dll" _
(ByVal outbuf As String, ByVal password As String) As Long
Public Sub CreateAccount(Username As String, password As String)
Dim Result As Boolean
Dim Hash As String
Hash = String(5 * 4, vbNullChar)
Result = X(Hash, password)
If Result = True Then
packetbuf.InsertNonNTString Hash
packetbuf.InsertNTString Username
packetbuf.SendPacket frmMain.sckBnet, &H3D
addText "Created " & Username & "/" & password & " successfully!", AtomicGreen
Else
addText "Error: Failed to create the account " & Username, AtomicRed
frmMain.sckBnet.Close
End If
End Sub
I hope this will help anyone who is trying to get the "Create Account" to work.
Quote from: ChR0NiC on November 24, 2003, 09:11 PM
Public Declare Function X Lib "BnetAuth.dll" _
(ByVal outbuf As String, ByVal password As String) As Long
Public Sub CreateAccount(Username As String, password As String)
Dim Result As Boolean
Dim Hash As String
Hash = String(5 * 4, vbNullChar)
Result = X(Hash, password)
If Result = True Then
packetbuf.InsertNonNTString Hash
packetbuf.InsertNTString Username
packetbuf.SendPacket frmMain.sckBnet, &H3D
addText "Created " & Username & "/" & password & " successfully!", AtomicGreen
Else
addText "Error: Failed to create the account " & Username, AtomicRed
frmMain.sckBnet.Close
End If
End Sub
I hope this will help anyone who is trying to get the "Create Account" to work.
I already posted code for account creation like a few days ago.
Quote from: Turbo on November 24, 2003, 09:13 PM
I already posted code for account creation like a few days ago.
I just wanted to feel special ;D
Don't take that away from me >:(
ANd 90% of it is done by a dll neither of you made, so hush.
and how much of the code is original?
probably from ethbot.
not too much original code floating out there these days.
wrong, Stu did, and he gave the source to zorm (BTW i still have the original BnetAuth.dll source if anybody wants it) Stu decided to go ahead and release it, then Raihan and other people got there hands on it, and now u see those lame functions named A and C and whatever else is in them.
/me feels like a history teacher :-D
Quote from: MesiaH on November 26, 2003, 01:15 PM
wrong, Stu did, and he gave the source to zorm (BTW i still have the original BnetAuth.dll source if anybody wants it) Stu decided to go ahead and release it, then Raihan and other people got there hands on it, and now u see those lame functions named A and C and whatever else is in them.
/me feels like a history teacher :-D
I would like to see how BnetAuth.dll works, I haven't been able to figure out how to do the stuff it does yet :-\
It's simply a DLL written in C++ containing implementations of various functions used during the logon process. It contains Yobguls' CheckRevision function, for example, although it exports it as 'Z' for some idiotic reason. Everything in it is available to the public, I think.
There have almost certainly been additions to this library since the revision of the source that I have, but I doubt there have been any significant alterations to it aside from that.
For those of you who have PM'ed me and are interested in the somewhat original source to BnetAuth.dll, please visit this thread:
http://forum.valhallalegends.com/phpbbs/index.php?board=30;action=display;threadid=3986
IIRC, bnetauth was compiled by stu from code from the old botdev forum.