JISession session = JISession.createSession(bonafides.getDomain(),
bonafides.getUser(), bonafides.getPassword());
session.useSessionSecurity(true);
// Execute command
JIComServer comStub = new JIComServer(JIProgId.valueOf("WScript.Shell"),
bonafides.getHost(), session);
IJIComObject unknown = comStub.createInstance();
IJIComObject comobject = unknown.queryInterface(IJIDispatch.IID);
IJIDispatch shell = (IJIDispatch) JIObjectFactory.narrowObject(comobject);
Object[] scriptArgs = new Object[]{
new JIString("%comspec% /c " + cmd)