This week's giveaway is in the Android forum.
We're giving away four copies of Android Security Essentials Live Lessons and have Godfrey Nolan on-line!
See this thread for details.
The moose likes Developer Certification (SCJD/OCMJD) and the fly likes server DNS Big Moose Saloon
  Search | Java FAQ | Recent Topics | Flagged Topics | Hot Topics | Zero Replies
Register / Login


Win a copy of Android Security Essentials Live Lessons this week in the Android forum!
JavaRanch » Java Forums » Certification » Developer Certification (SCJD/OCMJD)
Bookmark "server DNS" Watch "server DNS" New topic
Author

server DNS

John Chien
Ranch Hand

Joined: Feb 06, 2003
Posts: 105
Hi,
The server DNS can be in the form of:
a) IP address
b) www.cnn.com form
If we want to allow user to enter the b) form,
we must have a system file that does the name/ip
translation.
Please let me know where I can find this file in the UNIX (/etc/host ??) and Window (???) operating system.
Thanks,
John Chien


SCJP, SCJD, SCWCD, SCBCD<br />IBM Certified Specialist (158)<br />Oracle9i PL/SQL Developer Certified Associate
Mark Spritzler
ranger
Sheriff

Joined: Feb 05, 2001
Posts: 17249
    
    6

well in windows it is in the windows directory.
Just do a find on host*.* and you will find your file.
However, I really wouldn't worry about it. If the ip or address that the client puts in is incorrect, then an Exception will be raised, and you just catch it and display a nice message that says "Sorry, but you have entered an invalid server. Please try again"
Mark


Perfect World Programming, LLC - Two Laptop Bag - Tube Organizer
How to Ask Questions the Smart Way FAQ
John Chien
Ranch Hand

Joined: Feb 06, 2003
Posts: 105
Mark:
That is a good strategy.
Thanks,
John Chien
 
 
subject: server DNS
 
Similar Threads
How to map a default url to another?
how to find dns name or server name
James server issue...
slow initialcontext lookup in swing client app