Author | Message | Time |
---|---|---|
UserLoser. | ...with what I think is that GNU GPL thingy [url]http://www.userloser.net/files/source/clsDynamicBuffer.cls[/url] How to use -> self explanatory but I feel the need to explain anyways. Declare an instance (which will be used throughout this example): [code] Dim DynBuf As New clsDynamicBuffer [/code] Set the buffer: [code] Call DynBuf.ResetBuffer(NewBufferData) [/code] Build a buffer: [code] DynBuf.NextByte = &HFF DynBuf.NextByte = &HE DynBuf.NextWord = &H8 DynBuf.NextString = "hmm" [/code] Add data (no null terminator follows): [code] Call DynBuf.AddBytes(OutData) [/code] Pick apart the buffer: [code] SomeVar = DynBuf.NextByte() SomeOtherVar = DynBuf.NextString() SomeVariable = DynBuf.NextDword() [/code] Grab some data by length: [code] Signature = DynBuf.GetBytes(128) [/code] Get the whole buffer: [code] BufferData = DynBuf.Buffer() [/code] Clear the buffer: [code] Call DynBuf.ResetBuffer(vbNullString) [/code] Destroy the buffer: [code] Set DynBuf = Nothing [/code] Enjoy. | March 28, 2005, 6:40 AM |
Newby | Noodlez told me he did something like this when he coded a VB bot. He could extract DWORDs and such out of a buffer by doing recvBuff.GetNextDWord() It sounded neat. Anyways, good to see you release something that will benefit others. :) | March 28, 2005, 8:35 AM |
kamakazie | In the get property NextString() why increase the buffer position (m_Pos) when you don't actually find a vbNullChar? | March 28, 2005, 8:42 AM |
Adron | Haha, neat, you're turning people's bots into GPL software! | March 28, 2005, 2:18 PM |
UserLoser. | [quote author=dxoigmn link=topic=11078.msg105922#msg105922 date=1111999335] In the get property NextString() why increase the buffer position (m_Pos) when you don't actually find a vbNullChar? [/quote] Hmm, oops. Thanks. I kept finding small things that I overlooked which I didn't find when I was testing it right before I posted this thread. | March 28, 2005, 5:38 PM |
kamakazie | [quote author=UserLoser link=topic=11078.msg105979#msg105979 date=1112031519] [quote author=dxoigmn link=topic=11078.msg105922#msg105922 date=1111999335] In the get property NextString() why increase the buffer position (m_Pos) when you don't actually find a vbNullChar? [/quote] Hmm, oops. Thanks. I kept finding small things that I overlooked which I didn't find when I was testing it right before I posted this thread. [/quote] Hehe, the beauty of open-source :P | March 28, 2005, 6:41 PM |
Newby | [quote author=Adron link=topic=11078.msg105948#msg105948 date=1112019519] Haha, neat, you're turning people's bots into GPL software! [/quote] I don't think he realized (or maybe he just overlooked) that now tons of bots that utilize this are going to have to be open-source. :P | March 29, 2005, 4:44 PM |
UserLoser. | [quote author=Newby link=topic=11078.msg106111#msg106111 date=1112114652] [quote author=Adron link=topic=11078.msg105948#msg105948 date=1112019519] Haha, neat, you're turning people's bots into GPL software! [/quote] I don't think he realized (or maybe he just overlooked) that now tons of bots that utilize this are going to have to be open-source. :P [/quote] So what happens if I find someone who is using this without creditting/making their product open soruce or whatever? Can I sue them and become really rich? | March 29, 2005, 7:02 PM |
Newby | [quote author=UserLoser link=topic=11078.msg106131#msg106131 date=1112122969] So what happens if I find someone who is using this without creditting/making their product open soruce or whatever?[/quote] Violations of the GPL, LGPL, and GFDL Taken from the page: Licenses | March 29, 2005, 7:45 PM |