Mailing List Archive: 49091 messages
  • Home
  • Script library
  • AltME Archive
  • Mailing list
  • Articles Index
  • Site search

[REBOL] Re: Rugby Question

From: maarten:vrijheid at: 3-Nov-2003 21:42

Hi Matt,
> Sorry, I had to put this problem aside for a minute. Ok Maarten, I > followed > your advise to keep a running list of the server ports when I connect
> them, that makes sense, but I'm still not following how the server can > keep > track of the clients. Basically I need to do this on the server: > > alive: does > [ > client-IP: {get client IP and port from Rugby?} > ] > > or something like that so that and then serve that function. This way
> client can call that function periodically to let the server know that
> is > still running. I need to have the IP for security reasons so I can
> sure that the client is coming from the same address every time. If
> need any more specifics, let me know. Some code would really help.
You cannot get the client IP directly in Rugby. The ports are stored in the i/o engine (port-q and object-q), but you cannot see that when a function is invoked (you don't see what client is calling). You restrict access to a set of functions using the /restirct refinement, but I doubt that is what you want. Perhaps a simple private/public key scheme works best here. With all the spoofing going on that is a better idea anyway. --Maarten