This week's book giveaway is in the Clojure forum.
We're giving away four copies of Clojure in Action and have Amit Rathore and Francis Avila on-line!
See this thread for details.
Win a copy of Clojure in Action this week in the Clojure forum!
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic

internal or external request.

 
hasan khan
Ranch Hand
Posts: 222
Eclipse IDE Firefox Browser Java
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
my website can be access at http://www.mydomain.com/mycontext/ by external users and
we the internal user can also access the web site by using some internal ip : http://10.20.30.40/mycontext/

how do i distinguish wheater the request has come from internal or external.
[ June 14, 2006: Message edited by: hasaN khaN ]
 
Darren Edwards
Ranch Hand
Posts: 69
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Use the Host header from HTTP (assuming you are using HTTP1.1, but most people are!)

 
hasan khan
Ranch Hand
Posts: 222
Eclipse IDE Firefox Browser Java
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
i know about host header, but i want to distinguish between domain name or IP is coming in the host header.
 
Ben Souther
Sheriff
Posts: 13411
Firefox Browser Redhat VI Editor
  • 0
  • Mark post as helpful
  • send pies
  • Quote
  • Report post to moderator
Read the header.
If it contains your domain name, you know the requests was from your domain name.
If it contains the IP number, then you know it came from the IP number.
 
I agree. Here's the link: http://aspose.com/file-tools
  • Post Reply
  • Bookmark Topic Watch Topic
  • New Topic