• Passing CAS credentials using SDK 1.1.

  • We tried to make OpenKM as intuitive as possible, but an advice is always welcome.
We tried to make OpenKM as intuitive as possible, but an advice is always welcome.
Forum rules: Please, before asking something see the documentation wiki or use the search feature of the forum. And remember we don't have a crystal ball or mental readers, so if you post about an issue tell us which OpenKM are you using and also the browser and operating system version. For more info read How to Report Bugs Effectively.
 #43450  by PSHREYASHOLLA
 
Hi,

We are using openKM with CAS. And for development we are using openKM SDK 1.1.

How to pass TGT/Service ticket as part of the request.

We are using,

import com.openkm.sdk4j.OKMWebservices;
import com.openkm.sdk4j.OKMWebservicesFactory;

OKMWebservices ws= OKMWebservicesFactory.newInstance(host, user, password);

Here instead of user and password, how can we pass TGT/Service ticket? Please help.
 #43458  by jllort
 
First step should be OpenKM webservices be configured for accepting the ticket. You are welcome in helping us to modifying the source code for it https://github.com/openkm/document-management-system ( do in a simple method like /services/auth/getUsers to evaluate the change in the whole code ).
 #48687  by m.carlzy
 
Hello jllort,
I also have the same query. Could you please confirm, is the current method for newinstance in webservice will not be able to accept any service ticket from CAS and will require some sdk changes:

OKMWebservices ws= OKMWebservicesFactory.newInstance(host, user, password);


I tried some combinations of what to pass either use the cas host/service ticket for the password on the newInstance but I always end up with 401 http error code.
 #48700  by jllort
 
I think the source code should be modified to allow CAS authentication in webservices. Currently webservices only allow basic authentication and should be added some filter to allow CAS, might be modifying something in the appContext.xml and probably with some extra class in the OpenKM core.
Code: Select all
<!-- REST -->
  <security:http pattern="/services/rest/**" create-session="stateless">
    <security:intercept-url pattern="/**" access="IS_AUTHENTICATED_FULLY"/>
    <security:http-basic/>
  </security:http>

About Us

OpenKM is part of the management software. A management software is a program that facilitates the accomplishment of administrative tasks. OpenKM is a document management system that allows you to manage business content and workflow in a more efficient way. Document managers guarantee data protection by establishing information security for business content.