Trying to understand some code - intercepting packets

Forum closed. All further discussion to be discussed at https://github.com/OpenKore/

Moderator: Moderators

Message
Author
Fedarkyn
Noob
Noob
Posts: 4
Joined: 10 Jul 2008, 09:15
Noob?: Yes

Trying to understand some code - intercepting packets

#1 Post by Fedarkyn »

Hi,

I am not very good at perl and I´m trying to learn some triks that I expect I can use to bot some other games.

from what I saw at Xkoreproxy.pm the Xkore mode in fact estabilish a proxy where you can filter all the packets coming and going. A classic "man in the middle" attack.

What I dodn´t catch is how it is done since when you start kore the client is already on, and the connection between the client and the server is already done....

another doubt is that opening a socket on the local machine can intercept incoming connection from the server, but how did u intercept the outgoing connections?

Thanks for any help
Regards
Fedarkyn

sli
Perl Monk
Perl Monk
Posts: 810
Joined: 04 Apr 2008, 17:26
Noob?: No

Re: Trying to understand some code - intercepting packets

#2 Post by sli »

If you want to packet sniff, just use Wireshark or WPE. Hooking into the client isn't required to bot in ANY game.
cs : ee : realist

Fedarkyn
Noob
Noob
Posts: 4
Joined: 10 Jul 2008, 09:15
Noob?: Yes

Re: Trying to understand some code - intercepting packets

#3 Post by Fedarkyn »

sniffing is the initial part of the project. It is necessary to understand and map the protocol used between the client and the server.

This "proxy" used by openkore and that I would like to do in my bot also, would enable to bot while using the client and seeing what am I doing.

listening in a port can intercept the incoming connections, but I haven´t figured out how openkore intercept the outgoing connections (from RO´s client to the server).

kali
OpenKore Monk
OpenKore Monk
Posts: 457
Joined: 04 Apr 2008, 10:10

Re: Trying to understand some code - intercepting packets

#4 Post by kali »

Simple. The RO client isn't connected to the server - it's connected to openkore.

Whatever RO client sends is sent to openkore, which is relayed by openkore to the server. It is, as you've said, a classic man in the middle - no direct contact between the two ends.
Got your topic trashed by a mod?

Trashing topics is one click, and moving a topic to its proper forum is a lot harder. You expend the least effort in deciding where to post, mods expend the least effort by trashing.

Have a nice day.

Fedarkyn
Noob
Noob
Posts: 4
Joined: 10 Jul 2008, 09:15
Noob?: Yes

Re: Trying to understand some code - intercepting packets

#5 Post by Fedarkyn »

But how it is done since the RO client is unmodified? How can I trick a program to think that he is connecting a remote location but instead he is connecting a local invisible proxy?

sli
Perl Monk
Perl Monk
Posts: 810
Joined: 04 Apr 2008, 17:26
Noob?: No

Re: Trying to understand some code - intercepting packets

#6 Post by sli »

Just change the address it connects to?
cs : ee : realist

Fedarkyn
Noob
Noob
Posts: 4
Joined: 10 Jul 2008, 09:15
Noob?: Yes

Re: Trying to understand some code - intercepting packets

#7 Post by Fedarkyn »

where is it done in the code?

sli
Perl Monk
Perl Monk
Posts: 810
Joined: 04 Apr 2008, 17:26
Noob?: No

Re: Trying to understand some code - intercepting packets

#8 Post by sli »

Nowhere. You just change the (s)clientinfo.xml.
cs : ee : realist

Locked