1. HTTP遠程訪問鑒權

RemoteMethodServer rms = RemoteMethodServer.getDefault();

GatewayAuthenticator auth = new GatewayAuthenticator();

auth.setRemoteUser("wcadmin");

rms.setAuthenticator(auth);

2. RMI遠程訪問鑒權

RemoteMethodServer rms = RemoteMethodServer.getDefault();

rms.setUserName("wcadmin"); rms.setPassword("wcadmin");

3. WebService客戶端測試訪問

IEServiceProxy s = new IEServiceProxy();

SoapBindingStub stub = (SoapBindingStub)s.getIEService();

stub.setUsername("wcadmin");

stub.setPassword("wcadmin");

Logo

权威|前沿|技术|干货|国内首个API全生命周期开发者社区

更多推荐