Valhalla Legends Archive

Programming => Battle.net Bot Development => Topic started by: Tazo on April 22, 2003, 01:07 PM

Title: A data dump
Post by: Tazo on April 22, 2003, 01:07 PM
This may sound kind of newbish, but how do you receive a data dump? Do you use a packetlogger and what the packetlogger receives is the dump?
Title: Re:A data dump
Post by: tA-Kane on April 22, 2003, 06:00 PM
Quote from: laurion on April 22, 2003, 01:07 PMHow do you receive a data dump?
A "data dump" is quite a generic term.
Quote from: laurion on April 22, 2003, 01:07 PMDo you use a packetlogger and what the packetlogger receives is the dump?
That is one form of a "data dump", yes, and that form is more commonly referred to as a packet log.
Title: Re:A data dump
Post by: Tazo on April 22, 2003, 07:53 PM
So I can't receive the data dump in VB? I have to use a packetlogger?
Title: Re:A data dump
Post by: Yoni on April 22, 2003, 09:03 PM
A data dump is when there is data of any sort, and it's being dumped in some way, usually to the screen/terminal or to a log file.
This term is extremely context-specific. Could you tell us what type of data you might be talking about?
Title: Re:A data dump
Post by: Camel on April 22, 2003, 09:22 PM
ugh, it's obvious what he wants, you pretentious jurx ::)

vb won't do what you want, you need a packet logger like ethereal
Title: Re:A data dump
Post by: Yoni on April 23, 2003, 04:59 AM
Are Camel and laurion communicating on a subliminal level? I still don't know what laurion wants to do.

If you want to display a dump of everything going on in a TCP session that you control, you can certainly and easily do that in VB. Just make your own centralized Send function which dumps everything it sends before sending and also dump everything you receive before processing.

If you want to display a dump of a TCP session you don't control, it might be possible, but you'll have to go great lengths to get there and VB is certainly not the right tool for it.

If you want something else, I don't know.
Title: Re:A data dump
Post by: Tazo on April 23, 2003, 10:10 AM
Quote from: Yoni on April 23, 2003, 04:59 AM
Are Camel and laurion communicating on a subliminal level? I still don't know what laurion wants to do.

If you want to display a dump of everything going on in a TCP session that you control, you can certainly and easily do that in VB. Just make your own centralized Send function which dumps everything it sends before sending and also dump everything you receive before processing.

If you want to display a dump of a TCP session you don't control, it might be possible, but you'll have to go great lengths to get there and VB is certainly not the right tool for it.

If you want something else, I don't know.
I want to do a TCP session that I control. How would I 'dump' the data? Please elaborate on the controlled session thing. Thanks.
Title: Re:A data dump
Post by: Yoni on April 23, 2003, 10:40 AM
Well, first of all, you'll want a function that dumps data in a readable format:

Function DumpHex(ByVal Data As String) As String
   ' Returns a readable string with the hex values of the ASCII characters in Data
   ' I'll let you fill this in...
End Sub


Then, whenever you send data, instead of using SomeWinsockControl.SendData directly, you can do something like:

Sub MySendData(ByVal Data As String)
   Debug.Print "Sent: "
   Debug.Print DumpHex(Data)
   SomeWinsockControl.SendData Data


And when you receive, you can do something like:

Private Sub SomeWinsockControl_DataArrival(bytesTotal As Integer)
   Dim Data As String
   SomeWinsockControl.GetData Data
   Debug.Print "Received: "
   Debug.Print DumpHex(Data)
   MyProcessingFunction Data
End Sub
Title: Re:A data dump
Post by: Tazo on April 23, 2003, 10:45 AM
Thanks so much!!!!
Title: Re:A data dump
Post by: Banana fanna fo fanna on April 23, 2003, 06:21 PM
I agree with Camel :)
I hate it when Spht and CupHead do shit like that too. It's annoying.
Title: Re:A data dump
Post by: Mesiah / haiseM on April 23, 2003, 06:36 PM
Quote from: Yoni on April 23, 2003, 10:40 AM
Well, first of all, you'll want a function that dumps data in a readable format:

Function DumpHex(ByVal Data As String) As String
   ' Returns a readable string with the hex values of the ASCII characters in Data
   ' I'll let you fill this in...
End Sub


ahhem? this must be untested code, hence the fact your trying to end a sub that doesnt exist, end function silly!
Title: Re:A data dump
Post by: Yoni on April 23, 2003, 07:36 PM
Err... Yeah. I wrote the code directly in the forum. DumpHex started out as a Sub, and morphed into a Function during the typing of the above post.

Just for the principle I'm not going to edit the post though. ;)

Edit: Hmm, just noticed MySendData has no End Sub either... Oh wlel.
Title: Re:A data dump
Post by: Mesiah / haiseM on April 24, 2003, 12:56 PM
as long as your not trying to use it, thats all that matters :P +1 to yoni for attempting to write vb code, and not caring about it.