ObjectWeb Consortium
Search ObjectWeb Mail Archive: 

Advanced Search - Powered by Google


Mail Archive Home | shark List | May 2005 Index

<--  Date Index  --> <--  Thread Index  -->

Re: [shark] initial login only works in runSA


Hello Ben

you wrote:
> Hi,
> after I run recreateDB.bat, I cannot login into shark like this:
>             sconn.connect("admin", "enhydra", "", "");
> I get the following:
> org.enhydra.shark.api.client.wfservice.ConnectFailed: Connection
> failed, invalid username or password
>
> However, if I first log into the admin via runSA.bat using
> admin/enhydra, then I can login using the above method.
>
> Any ideas how to avoid the necessary admin logon?

Either
* turn off AuthenticationManager (comment the line in Shark.conf)
or
* create the user and group in Shark's UserGroup before logging in
  (this is what POJO SharkAdmin does)

Here is excerpt from ManualTest.java
 Shark ss=Shark.getInstance();
 // ...
 UserGroupAdministration uga = ss
    .getAdminInterface()
    .getUserGroupAdministration();
 try {
 // ...
    if (!uga.doesGroupExist("test")) {
       uga.createGroup("test","test group");
    }
    if (!uga.doesUserExist(username)) {
       uga.createUser("test", username, pwd,"Jane", "Doe","");
    }
 } catch (Throwable t) {t.printStackTrace();}

hope this helps
-- 
Vladimir Puskas
Together Serbia





<--  Date Index  --> <--  Thread Index  -->

Reply via email to:

Powered by MHonArc.

Copyright © 1999-2005, ObjectWeb Consortium | contact | webmaster.