Hi,

I recommend you to read the following article "SessionMan gives a solution
to the problem of saving state while using web-services":
http://www.webtair.com/articles/sessionman_en.html

Also you can checkout example that illustrates answer on your question:
http://sessionman.googlecode.com/svn/trunk/sessionman-example

With best regards,
Vaclav

On 1/2/07, celia05es <[EMAIL PROTECTED]> wrote:


Hi,
I have defined 2 roles (admin and oper). When the user enters the
application, he enters a username and a password (therefore a role has
been
applied to him).
Now, depending on this role, some operations can be denied or simply
different.
So my question is: How can I call AXIS using the username and the
password?
I would like to be able (on the server side) to check which user/password
has been used to connect to AXIS ... depending on that, I will do one
thing
or another.

Thank for helping.


Up till now, I used the following :

public static void init()  throws IOException
{
    url = new URL(InicializaCliente.BONOServidorURL);
    call = new Call();

   SOAPMappingRegistry smr = new SOAPMappingRegistry();
   StringDeserializer sd = new StringDeserializer();
   smr.mapTypes(Constants.NS_URI_SOAP_ENC,
      new QName("http://schemas.xmlsoap.org.sopa/encoding/","string";),
       String.class,null,sd);
    BeanSerializer beanSer = new BeanSerializer();
    smr.mapTypes(Constants.NS_URI_SOAP_ENC,
        new QName(InicializaCliente.BONOUrn, "ObjResultadoBasico"),
        ObjResultadoBasico.class, beanSer, beanSer);

    call.setSOAPMappingRegistry(smr);
    call.setEncodingStyleURI(Constants.NS_URI_SOAP_ENC);
    call.setTargetObjectURI(InicializaCliente.BONOUrn);
    salidaObjBasico= new ObjResultadoBasico();
  }



As you can see, no username and no password.
--
View this message in context:
http://www.nabble.com/How-can-I-call-AXIS-specifying-username-and-password--tf2908656.html#a8126131
Sent from the Axis - User mailing list archive at Nabble.com.


---------------------------------------------------------------------
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]




--
Vaclav
_________________________
Sun Certified Programmer for Java 2 Platform
gTalk, msn: [EMAIL PROTECTED]
cv: http://www.vaclav.kiev.ua/cv
http://www.vaclav.kiev.ua
http://www.wtg.kiev.ua
icq: 196335325

Reply via email to