in reply to X11::GUITest questions

Please learn first about the differences between the network communication and the user interface your program is using.

In principle, it is possible to inject automated commands into every stream, where it is easier in many cases to inject commands into your user interface (through X11::GUITest or Win32::GUITest).

Completely decoding a foreign network protocol is not easy, and you will be even more dependant on changes within the client protocol. Net::PCapUtils is my tool of choice for network sniffing of local programs, and I believe that it is also possible to alter packets and inject new packets into the stream.

None of the two ways are easy, and if you don't even know the difference, you have much to learn on your way. I suggest that you start by automating the UI via one of the GUITest modules, as the interface is more accessible and visible to you.

perl -MHTTP::Daemon -MHTTP::Response -MLWP::Simple -e ' ; # The $d = new HTTP::Daemon and fork and getprint $d->url and exit;#spider ($c = $d->accept())->get_request(); $c->send_response( new #in the HTTP::Response(200,$_,$_,qq(Just another Perl hacker\n))); ' # web

Replies are listed 'Best First'.
Re: Re: simple sniffer/injector
by jettero (Monsignor) on Jan 26, 2004 at 15:10 UTC
    Your answer is precisely the reason I asked in the first place. You've totally convinced me I'm barking up the wrong tree and I'm now going to look at these X11::GUITest tools.

    It even sounds easier.

    Thanks very much.

    EDIT: Actually, I have made significant progress using this approach. So, thanks again.

    EDIT2: OK, I have gotten guitest to do some really neat things. I'm not clear on how to find things in the window. That is, I can poke the windows with a stick, but how do you see them?

      open your eyes? (you need to elaborate)
        I mean, how do I break down the window and find the edges of the widgets, and also, how do you fetch the text from a text widget?