Hi,
I would like to learn how to monitor messages between an applet and the server it is connected to.
Can someone direct me on where to learn how to do this or provide me with some pointers.
Thanks,
KDUB
Hi,
I would like to learn how to monitor messages between an applet and the server it is connected to.
Can someone direct me on where to learn how to do this or provide me with some pointers.
Thanks,
KDUB
I’m assuming you don’t have the source code for the applet, and hoping you’re not doing anything naughty…
The easiest thing is probably to set up a logging proxy server and route all traffic through it. Direct the proxy to lurk on port 8080 and proxy for :80, then hit http://localhost:8080/ in your browser.
An easily-modifiable proxy server was included in Java Examples in a Nutshell by David Flanagan; you should be able to find the sample code via Google.
IMHO:
Ethereal is … indispensable for network protocol work 
What I am trying to do is figure out how Play Buddy
http://www.playbuddy.com/pb/yahoodownloads.htm works. During a Yahoo applet game they can keep track of which cards have been played by all people playing the applet.
KDUB
Ah, so you’re trying to see what cards everyone else is holding then? ;D
Without looking at the applet, here’s my guess:
Applet connects to game server, tells the server every move you make. The server keeps track of what everyone is doing, and tells each client just what they need to know to render their display. It would be incredibly foolish for the server to propogate the entire game state to all clients, as people would then be able to cheat.
Does that mean that the play buddy application connects into the yahoo server? Or is there another way to do that?
I don’t want to see what people are holding but I want to be able to do something similar to the play buddy app.
KDub
Yes, it’ll likely either speak HTTP to a servlet running inside the web container, or connect to a dedicated “game server” running on the same box.
Because of the security model an unsigned applet runs in, these games must be developed as a client-server architecture - two users running an applet cannot communicate with each other, except via a central service.