You are viewing a plain text version of this content. The canonical link for it is here.
Posted to java-dev@axis.apache.org by Pop Marius <po...@regens.hu> on 2002/07/11 14:07:17 UTC
C#client & username
hello everybody !
Could anyone of you help me ? I have the following problem:
on the server side I have :
public class ThrowHandler extends BasicHandler {
public void invoke(MessageContext msgContext) throws AxisFault {
try {
String user = msgContext.getUsername();
if ("".equals(user) || (user==null))
throw new AxisFault("aaaa","no user defined....",null,null);
} catch (Exception e) {
throw AxisFault.makeFault(e);
}
}
}
so I can catch the username which the java client side send it with the code below:
...........................................................
Service service = new Service();
Call call = (Call) service.createCall();
call.setTargetEndpointAddress( new java.net.URL(m_https) );
...........................................................
call.setUsername("XXX");
call.setPassword("YYY");
so the question is: how could I send the username and the password from C# client with the use of those classes
where I1ve defined a proxy class inherited from SoapHttpClientProtocol
I've tired with : this.Credentials = new System.Net.NetworkCredential("XXX","YYY",""); but it didn't work.
point me in the right direction please, for any ideea I will be glad !
thanks in advance
Pop Marius Lucian