Thursday, August 29, 2013

Packet editor progress #8

Work on BPE has been going slow lately, as usual.
Adding UDP support creates a whole lot of problems.
The only "good" way of doing it is binding to the UDP port on each IP that's been hooked, which is messy and generally a pain to implement.
It seems like that's the only option, though since the AIR DatagramSocket doesn't allow you to get the destination IP address of an incoming packet if you bind (their address for binding to all incoming addresses)
The good news is that gives me a reason to redesign BPE a little bit. For a while now, I've been thinking it would be good to manage hooked ports on a per-server basis, instead of having to hook ports on all servers. The bad news is making that work will require some pretty huge modifications, which will take some time.
I'm thinking for now I might just make it you can only hook one UDP server, since I can't think of a clean solution for multiple UDP hooks right now. Plus, the only use I've found for hooking UDP is DNS requests which would only require one server hook anyway.
So, it's highly likely 1.3 will only have partial UDP support.

I'm also modifying the socket open hook so that plugins can redirect connections. This is useful for games that use more than one server. You could for example use it to write a plugin that allows you to choose from one of many private servers.
I'll probably release an example plugin using it which works as a quickstart server/game chooser for Stick Arena and/or BBH.

I haven't started work on the server/port adding plugin hooks, but they should be simple enough to add. I still plan on putting them in the next release, since those hooks and UDP support would be a powerful combination allowing me to automatically hook servers, as I have mentioned before.

While I'm at it I might as well mention I'm currently working on a new tutorial on SWF bytecode modification. Just the basics.
It's going to be really detailed, since I haven't seen any really in-depth tutorials out there on the subject.
Be warned, though. I'm not even half way done and it's already stupidly long.

No comments: