SRL Archive - General

Is it possible to ...


cycrosism

2010-05-01 07:33:35

Send packets to a server using SCAR on an already open connection?

The problem I have here is that when I create a new connection and send a packet to a server it gets ignored as it is sending it using the new connection and not the existing one.

I made a small function here:


Function SendPacket: Boolean;
Var
Packet:Integer;
Begin
Packet := OpenConnection('', , 5000); //I edited out the I.P and Port
If Packet = -1 Then Exit;
Writeln('Packet ID: '+IntToStr(Packet));
Wait(500);
If IsConnectionOpen(Packet) Then
Begin
Writeln('Connection Open! Attempting to send packet ...');
If SendConnectionData(Packet, '00 00 00 00 00 ') Then //Edited packet
Begin
Result := True;
Wait(1000);
Writeln('Packet Sent!');
End Else Writeln('Sending failed');
End;
End;

Now what happens is when I run this function it does create a new connection and I do get the "Packet Sent!" in the debug … but nothing happens.

I was just wondering if there is a way to see if there is a socket already open on a specific I.P and PORT and if I am able to send packets using that, because as I stated before it does not work correctly if I create a new packet.

Frement

2010-05-01 07:36:47

You need to create a plugin that uses hooks.

cycrosism

2010-05-01 07:40:02

And how would I do that?

Frement

2010-05-01 07:40:59

From: cycrosism
And how would I do that?


Its a very complex process. There are plenty of tutorials online.

And you can search the forum for plugin tutorials.

mastaraymond

2010-05-01 08:00:04

I haven't found any good packet editor out there… Only packed sniffing, but that aint much help.. So I guess; Good luck on making such a thing :p.

cycrosism

2010-05-01 12:00:54

From: mastaraymond
I haven't found any good packet editor out there… Only packed sniffing, but that aint much help.. So I guess; Good luck on making such a thing :p.


I use one called wpepro. Its free and it has lots of great features like filtering packets and sending packets on an already open connection.

mastaraymond

2010-05-01 15:56:24

From: cycrosism
I use one called wpepro. Its free and it has lots of great features like filtering packets and sending packets on an already open connection.

IIRC it didn't have real good packet-editing features..