You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-user@axis.apache.org by va...@bull.net on 2003/12/08 09:58:16 UTC

Réf. : Re: handler : how to get information onthe sender ?

I have many web services and servlets talking to each other
For security reasons I want to identify the application who send the
message :
If it's a web service I would like to know its logical name (or uri...).
If it's a servlet I would need something like ServletContextName...
Security is a very important thing, and how can you secure a web service if
you don't kwow who is talking to you ? Handlers should be able to know that
!

Valerie





"Jörn G. Eichler" <Jo...@web.de>@web.de sur 06/12/2003 14:47:37

Veuillez répondre à axis-user@ws.apache.org

Envoyé par :      joern.eichler@web.de


Pour : <ax...@ws.apache.org>
cc :
Objet :     Re: handler : how to get information on the sender ?


>In a handler we can find who will receive the request with the method
>getTargetService()
>But how can we get information about who is the sender of this request ?
>
>Valerie

what do you mean with information about the sender? to get the username &
ip:

----> snip <----
public void onFault(MessageContext in_msgContext) {
  try {
    if (in_msgContext != null) {
      String strUsername = in_msgContext.getUsername();
      String strRemoteAddress = (String)
in_msgContext.getProperty(REMOTE_ADDR_KEY);
----> snap <----

cheers,

j.