Hi,
your stub example is too simple. I try to call the rpc
method:
USHORT Login (
[in] RPC_BINDING_HANDLE ConnectionHandle,
[in,string] UCHAR cpServerName[30],
[in,string] UCHAR cpUserName[30],
[in,string] BYTE cpPassword[20],
[out] PUSERCONTEXT_HANDLE *pUserContext);
My try:
public int Login(String server, String user, String
password) throws RemoteException {
InputParameters input = new InputParameters();
input.add(new VaryingString(server));
input.add(new VaryingString(user));
input.add(new VaryingString(password));
OutputParameters output = new OutputParameters
();
UnsignedLongHolder context = new
UnsignedLongHolder();
output.add(new rpc.ndr.FullPointer
(context));
UnsignedShortHolder result = new
UnsignedShortHolder();
output.setResult(result);
try {
// this would really be operation 0, but we don't
want to collide
// with a real endpoint mapper operation.
call(0, 0, input, output);
} catch (RpcException ex) {
throw new RemoteException("RPC error.", ex);
} catch (Exception ex) {
throw new RemoteException("Unknown error.",
ex);
}
return result.getUnsignedShort();
}
Logged In: YES
user_id=913267
I know this is very very old but you can compile that idl
with midlc. If you have further questions please follow up
on the jCIFS mailing list.