Yhis is where I get stuck (I have posted the same question)
The admin account works providing you have NO security constraints in the
ejb-jar.xml file. Otherwise you have to update the orion-application.xml
file to show how the ejb-jar security-roles are mapped to the groups defined
in principals.xml.
e.g.
<security-role-mapping name="administrators">
<group name="admins" />
</security-role-mapping>
where administrators is the security-role in ejb-jar.xml and admins is the
group name in principals.xml (or whatever source you use e.g.
EJBUserManager). I believe the principals.xml used is the one created in the
application-deployments tree unless you modify your orion-application.xml to
point to the one in the config directory.
Dave Smith
Senior Team Leader
Aristocrat Technologies Australia Pty Ltd
mailto:[EMAIL PROTECTED]
-----Original Message-----
From: Enrique Wallace [mailto:[EMAIL PROTECTED]]
Sent: Wednesday, 19 July 2000 9:23
To: Orion-Interest
Subject: RE: initial context help
>I think I remember somebody said that you should use
>(Context.INITIAL_CONTEXT_FACTORY,"com.evermind.server.rmi.RMIInitialContext
Factory");
>
Thanks for the quick response! This worked! I get further along now before
getting another error. Now I'm doing this:
Hashtable h = new Hashtable();
h.put(Context.INITIAL_CONTEXT_FACTORY,"com.evermind.server.rmi.RMIInitialCon
textFactory");
h.put(Context.PROVIDER_URL,"ormi://localhost/app");
h.put(Context.SECURITY_PRINCIPAL,"admin");
h.put(Context.SECURITY_CREDENTIALS,"123")
Context jndiContext = new InitialContext(h);
Object obj = jndiContext.lookup("CabinBean");
CabinHome home = (CabinHome) javax.rmi.PortableRemoteObject.narrow(obj,
CabinHome.class)
Cabin cabin_1 = home.create(1);
but when it comes to the create(), I get this error message:
com.evermind.server.rmi.OrionRemoteException: admin is not allowed to call
the CabinBean.create(...) method, check your security settings.
at EntityHomeWrapper1.create(EntityHomeWrapper1.java:340)
at java.lang.reflect.Method.invoke(Native Method)
at com.evermind.server.rmi.ba.run(JAX)
at com.evermind.server.rmi.a8.gu(JAX)
at com.evermind.server.rmi.a8.run(JAX)
at com.evermind.util.e.run(JAX)
at connection to localhost/127.0.0.1 as admin
at com.evermind.server.rmi.a8.invokeMethod(JAX)
at com.evermind.server.rmi.a_.invoke(JAX)
at com.evermind.server.rmi.a0.invoke(JAX)
at __Proxy0.create(Unknown Source)
at com.titan.cabin.Client_1.main(Client_1.java:27)
Where/how do I set my security settings? I had to activate the admin user
in principals.xml myself.
Thanks for your help.
ekw
________________________________________________________________________
Get Your Private, Free E-mail from MSN Hotmail at http://www.hotmail.com