[Security & JAAS/JBoss] - Re: JAAS/LDAP Roles configuration pulls superset instead of
by sarahm
I have tried to use LdapExtLoginModule to see if it pulls my roles correctly, but I cannot even get it to authenticate properly. I am running JBoss [Zion] 4.0.3SP1 (build: CVSTag=JBoss_4_0_3_SP1 date=200510231054).
I have verfified the search bases and filters via ldapsearch on the command line, and did use the corrent password to authenticate.
Config:
<application-policy name="testLDAP">
| <authentication>
| <login-module code="org.jboss.security.auth.spi.LdapExtLoginModule"
| flag="required">
| <module-option name="java.naming.factory.initial">
| com.sun.jndi.ldap.LdapCtxFactory
| </module-option>
| <module-option name="java.naming.provider.url">
| ldap://ldap.mydomain.com/
| </module-option>
| <module-option name="java.naming.security.authentication">
| simple
| </module-option>
| <module-option name="baseCtxDN">ou=People,dc=mydomain,dc=com</module-option>
| <module-option name="baseFilter">(uid={0})</module-option>
| <module-option name="rolesCtxDN">ou=Groups,dc=mydomain,dc=com</module-option>
| <module-option name="roleFilter">(memberUid={0})</module-option>
| <module-option name="roleAttributeIsDN">false</module-option>
| <module-option name="roleAttributeID">cn</module-option>
| </login-module>
| </authentication>
| </application-policy>
Error:
| 13:31:45,766 DEBUG [testLDAP] CallbackHandler: org.jboss.security.auth.callback.SecurityAssociationHandler@228ba7
| 13:31:45,766 DEBUG [JaasSecurityManagerService] Created securityMgr=org.jboss.security.plugins.JaasSecurityManager@1fea0cf
| 13:31:45,769 DEBUG [testLDAP] CachePolicy set to: org.jboss.util.TimedCachePolicy@1ef9e0a
| 13:31:45,769 DEBUG [JaasSecurityManagerService] setCachePolicy, c=org.jboss.util.TimedCachePolicy@1ef9e0a
| 13:31:45,770 DEBUG [JaasSecurityManagerService] Added testLDAP, org.jboss.security.plugins.SecurityDomainContext@70a698 to map
| 13:31:45,798 DEBUG [LdapExtLoginModule] Failed to validate password
| java.lang.NullPointerException
| at java.util.Hashtable.put(Hashtable.java:396)
| at java.util.Properties.setProperty(Properties.java:128)
| at org.jboss.security.auth.spi.LdapExtLoginModule.constructInitialLdapContext(LdapExtLoginModule.java:470)
| at org.jboss.security.auth.spi.LdapExtLoginModule.createLdapInitContext(LdapExtLoginModule.java:317)
| at org.jboss.security.auth.spi.LdapExtLoginModule.validatePassword(LdapExtLoginModule.java:215)
| at org.jboss.security.auth.spi.UsernamePasswordLoginModule.login(UsernamePasswordLoginModule.java:186)
| at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
| at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccessorImpl.java:39)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:585)
| at javax.security.auth.login.LoginContext.invoke(LoginContext.java:769)
| at javax.security.auth.login.LoginContext.access$000(LoginContext.java:186)
| at javax.security.auth.login.LoginContext$4.run(LoginContext.java:683)
| at java.security.AccessController.doPrivileged(Native Method)
| at javax.security.auth.login.LoginContext.invokePriv(LoginContext.java:680)
| at javax.security.auth.login.LoginContext.login(LoginContext.java:579)
| at org.jboss.security.plugins.JaasSecurityManager.defaultLogin(JaasSecurityManager.java:572)
| at org.jboss.security.plugins.JaasSecurityManager.authenticate(JaasSecurityManager.java:506)
| at org.jboss.security.plugins.JaasSecurityManager.isValid(JaasSecurityManager.java:315)
| at org.jboss.web.tomcat.security.JBossSecurityMgrRealm.authenticate(JBossSecurityMgrRealm.java:230)
| at org.apache.catalina.authenticator.FormAuthenticator.authenticate(FormAuthenticator.java:256)
| at org.apache.catalina.authenticator.AuthenticatorBase.invoke(AuthenticatorBase.java:391)
| at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:59)
| at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
| at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
| at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
| at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
| at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:856)
| at org.apache.coyote.http11.Http11Protocol$Http11ConnectionHandler.processConnection(Http11Protocol.java:744)
| at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
| at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
| at java.lang.Thread.run(Thread.java:595)
| 13:31:45,800 DEBUG [LdapExtLoginModule] Bad password for username=sarahm
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3977948#3977948
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3977948
19 years, 7 months
[Installation, Configuration & Deployment] - Re: Could not open Jboss Welcome page!!!
by brooksj
"PeterJ" wrote : Do you have iptables (or some other firewall) running on the linux system? If so, is port 8080 open? Does the Linus system have a monitor, and if so, can you access JBoss from there using http://localhost:8080?
hi,guy,
thank you for replying,I'm not sure whether some firewall running on my linux.But I use nmap ,netstat,find the port 8080 is open.So what's wrong with my linux.Btw,my linux is running on the command line,so I don't know how to access "http://localhost:8080" on the command line.
nmap -A -sT localhost
Starting Nmap 4.11 ( http://www.insecure.org/nmap/ ) at 2006-06-19 01:51 EDT
Interesting ports on yyy (127.0.0.1):
Not shown: 1671 closed ports
PORT STATE SERVICE VERSION
22/tcp open ssh OpenSSH 4.3 (protocol 2.0)
25/tcp open smtp Sendmail 8.13.5/8.13.5
111/tcp open rpcbind 2 (rpc #100000)
631/tcp open ipp CUPS 1.1
4444/tcp open krb524?
8009/tcp open ajp13?
8080/tcp open http Apache Tomcat/Coyote JSP engine 1.1
50000/tcp open hpiod HP Linux Imaging and Printing System
50002/tcp open iiimsf?
Device type: general purpose
Running: Linux 2.4.X|2.5.X|2.6.X
OS details: Linux 2.4.0 - 2.5.20, Linux 2.5.25 - 2.6.8 or Gentoo 1.2 Linux 2.4.19 rc1-rc7, Linux 2.6.3 - 2.6.10
Service Info: Host: localhost.localdomain; OS: Unix
netstat -anp | grep 8080
tcp 0 0 :::8080 :::* LISTEN 32529/java
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3977947#3977947
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3977947
19 years, 7 months
[JBoss Seam] - SFSB - NotSerializableException
by bsmithjj
Hello,
I am using the 2006.1011 nightly build of Seam. I am getting the following exception in the server:
SEVERE: Error Rendering View[/user_access_request.xhtml]
| javax.faces.FacesException: java.io.NotSerializableException: com.evergreen.accesscontrol.AccessRequestManager$$EnhancerByCGLIB$$1703dda3
| at org.apache.myfaces.shared_impl.util.StateUtils.getAsByteArray(StateUtils.java:190)
| at org.apache.myfaces.shared_impl.util.StateUtils.construct(StateUtils.java:150)
| at org.apache.myfaces.renderkit.html.HtmlResponseStateManager.writeState(HtmlResponseStateManager.java:102)
| at org.apache.myfaces.application.jsp.JspStateManagerImpl.writeState(JspStateManagerImpl.java:430)
| at org.jboss.seam.jsf.SeamStateManager.writeState(SeamStateManager.java:53)
| at com.sun.facelets.FaceletViewHandler.renderView(FaceletViewHandler.java:606)
| at org.apache.myfaces.lifecycle.LifecycleImpl.render(LifecycleImpl.java:384)
| at javax.faces.webapp.FacesServlet.service(FacesServlet.java:138)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:252)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| at org.apache.myfaces.webapp.filter.ExtensionsFilter.doFilter(ExtensionsFilter.java:97)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| at org.apache.myfaces.webapp.filter.ExtensionsFilter.doFilter(ExtensionsFilter.java:144)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| at com.evergreen.filter.RequestDumper.doFilter(RequestDumper.java:72)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| at org.jboss.seam.servlet.SeamExceptionFilter.doFilter(SeamExceptionFilter.java:45)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| at org.jboss.seam.servlet.SeamRedirectFilter.doFilter(SeamRedirectFilter.java:33)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| at org.jboss.web.tomcat.filters.ReplyHeaderFilter.doFilter(ReplyHeaderFilter.java:96)
| at org.apache.catalina.core.ApplicationFilterChain.internalDoFilter(ApplicationFilterChain.java:202)
| at org.apache.catalina.core.ApplicationFilterChain.doFilter(ApplicationFilterChain.java:173)
| at org.apache.catalina.core.StandardWrapperValve.invoke(StandardWrapperValve.java:213)
| at org.apache.catalina.core.StandardContextValve.invoke(StandardContextValve.java:178)
| at org.jboss.web.tomcat.security.SecurityAssociationValve.invoke(SecurityAssociationValve.java:175)
| at com.evergreen.fastpass.catalina.CASSSOAuthenticatorValve.invoke(CASSSOAuthenticatorValve.java:371)
| at org.jboss.web.tomcat.security.JaccContextValve.invoke(JaccContextValve.java:74)
| at org.apache.catalina.core.StandardHostValve.invoke(StandardHostValve.java:126)
| at org.apache.catalina.valves.ErrorReportValve.invoke(ErrorReportValve.java:105)
| at org.apache.catalina.core.StandardEngineValve.invoke(StandardEngineValve.java:107)
| at org.apache.catalina.connector.CoyoteAdapter.service(CoyoteAdapter.java:148)
| at org.apache.coyote.http11.Http11Processor.process(Http11Processor.java:869)
| at org.apache.coyote.http11.Http11BaseProtocol$Http11ConnectionHandler.processConnection(Http11BaseProtocol.java:664)
| at org.apache.tomcat.util.net.PoolTcpEndpoint.processSocket(PoolTcpEndpoint.java:527)
| at org.apache.tomcat.util.net.MasterSlaveWorkerThread.run(MasterSlaveWorkerThread.java:112)
| at java.lang.Thread.run(Thread.java:595)
| Caused by: java.io.NotSerializableException: com.evergreen.accesscontrol.AccessRequestManager$$EnhancerByCGLIB$$1703dda3
| at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1081)
| at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:302)
| at java.util.HashMap.writeObject(HashMap.java:1039)
| at sun.reflect.GeneratedMethodAccessor112.invoke(Unknown Source)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:585)
| at java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:917)
| at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1339)
| at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1290)
| at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1079)
| at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:302)
| at java.util.HashMap.writeObject(HashMap.java:1039)
| at sun.reflect.GeneratedMethodAccessor112.invoke(Unknown Source)
| at sun.reflect.DelegatingMethodAccessorImpl.invoke(DelegatingMethodAccessorImpl.java:25)
| at java.lang.reflect.Method.invoke(Method.java:585)
| at java.io.ObjectStreamClass.invokeWriteObject(ObjectStreamClass.java:917)
| at java.io.ObjectOutputStream.writeSerialData(ObjectOutputStream.java:1339)
| at java.io.ObjectOutputStream.writeOrdinaryObject(ObjectOutputStream.java:1290)
| at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1079)
| at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1251)
| at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1075)
| at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1251)
| at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1075)
| at java.io.ObjectOutputStream.writeArray(ObjectOutputStream.java:1251)
| at java.io.ObjectOutputStream.writeObject0(ObjectOutputStream.java:1075)
| at java.io.ObjectOutputStream.writeObject(ObjectOutputStream.java:302)
| at org.apache.myfaces.shared_impl.util.StateUtils.getAsByteArray(StateUtils.java:180)
| ... 41 more
|
Here is my SFSB code (not a lot there yet):
@Stateful
| @Name("accessRequestManager")
| @Conversational(ifNotBegunOutcome = "home")
| public class AccessRequestManagerBean implements AccessRequestManager {
|
| @Logger
| private Log log;
|
| @In(create=true) @Out
| private AccessRequest accessRequest;
|
| @PersistenceContext(unitName = "accessControlDatabase")
| private EntityManager em;
|
| // This is another stateful EJB
| @In
| private ApplicationManager applicationManager;
|
| @Begin(join=true)
| public String create() {
|
| log.info("create() : accessRequest -> " + this.accessRequest);
| log.info("create() : applicationManager -> "+this.applicationManager);
| log.info("create() : selectedApplications -> "+this.applicationManager.getSelectedApplications());
| return "success";
| }
|
| /**
| * End conversation and return user to home page (often index.seam).
| *
| * @return "home"
| */
| @End
| public String cancel() {
| return "home";
| }
|
| /**
| * If the destroy method is not declared in the interface, Seam will throw an exception
| * when the bean is destroyed.
| */
| @Destroy @Remove
| public void destroy() {
| // NO OP
| }
| }
|
I am using the CVS build because in the released version of Seam 1.0.1, @RequestParameter does not correctly handle req. param values from non-JSF widgets (e.g. a SelectManyList manually rendered). The version in CVS does correctly handle multiple parameter values for a single req. param.
Does this seem familiar to anyone?
Thanks.
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3977946#3977946
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3977946
19 years, 7 months
[JBoss jBPM] - Swimlane assigment
by nort
Hello,
I want to run my first jbpm application and have some troubles with assigment of swimlanes. My configuration is that:
<process-definition
| xmlns="urn:jbpm.org:jpdl-3.1" name="Urlaubsantrag">
| <swimlane name="Antragssteller">
| <assignment expression="group(applicant)"></assignment>
| </swimlane>
| <swimlane name="Vorgesetzer">
| <assignment expression="group(supervisor)"></assignment>
| </swimlane>
| <start-state name="Urlaubsantrag erstellen">
| <task name="Sende Urlaubsantrag" swimlane="Antragssteller">
| <controller>...
| </controller>
| </task>
| <transition name="Urlaubsantrag versenden" to="Urlaubsantrag entscheiden"></transition>
| </start-state>
| <end-state name="Ende"></end-state>
| <task-node name="Urlaubsantrag entscheiden">
| <task name="Urlaubsantrag lesen" swimlane="Vorgesetzer">
| <controller>...
| </controller>
| </task>
| <transition name="Urlaubsantrag bearbeitet" to="Ende"></transition>
| </task-node>
| </process-definition>
I run the first task:
| Token token = processInstance.getRootToken();
| Node node = (Node)token.getNode();
| System.out.println("Current node: "+node.getName());
|
| Task task = processInstance.getProcessDefinition().
| getTaskMgmtDefinition().getStartTask();
|
| TaskInstance taskInstance = new TaskInstance(task.getName(), "Antragssteller");
| token.signal("Urlaubsantrag versenden");
|
and get the exception:
Caused by: org.jbpm.identity.assignment.ExpressionAssignmentException: couldn't resolve assignment expression 'group(supervisor)'
| at org.jbpm.identity.assignment.ExpressionAssignmentHandler.assign(ExpressionAssignmentHandler.java:97)
| at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignmentDelegation(TaskMgmtInstance.java:217)
| at org.jbpm.taskmgmt.exe.TaskMgmtInstance.performAssignment(TaskMgmtInstance.java:193)
| ... 11 more
| Caused by: java.lang.RuntimeException: no active JbpmContext for resolving assignment expression'group(supervisor)'
| at org.jbpm.identity.assignment.ExpressionAssignmentHandler.getExpressionSession(ExpressionAssignmentHandler.java:109)
| at org.jbpm.identity.assignment.ExpressionAssignmentHandler.assign(ExpressionAssignmentHandler.java:69)
| ... 13 more
| Exception in thread "main"
What is wrong? What I have to do?
Thank you,
nort
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3977942#3977942
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3977942
19 years, 7 months
[JBoss Seam] - Seam in Eclipse: Library problems
by cupdike
I was following along with the Seam in Eclipse flash demo, and after pulling the project down from cvs, there were 5 library jars that were reporting problems (2 drools jars, 2 myfaces jars and a jbpm jar). It looked like they had been updated with later versions but the eclipse project classpath had not been updated. So I updated the 5 entries in the build path libraries. Now I get two errors.
| The project was not built since its build path is incomplete. Cannot find the class file for org.jgroups.MembershipListener. Fix the build path then try building this project
|
| The type org.jgroups.MembershipListener cannot be resolved. It is indirectly referenced from required .class files UICache.java jboss-seam/src/ui/org/jboss/seam/ui line 86
|
Is there any way to get rid of these errors?
Note: The ant compile still runs without any errors.
TIA, Clark
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3977941#3977941
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3977941
19 years, 7 months
[EJB 3.0] - embedded-war problem + source code
by emil_prager
Hello everybody!
I'll put here a question about Embedded EJB3, as it was the requirement posted at http://www.jboss.org/index.html?module=bb&op=viewtopic&t=91662
| 1. About the embedded EJB3 tutorials (http://docs.jboss.org/ejb3/embedded/embedded.html), which are classified there in 2 categories:
|
| | + a simpler one, and the
| | + "Advanced Deployment Tutorials"
| |
| Did they all work fine at you?
|
| For me, almost all the simpler ones worked fine, with the exception of the "embedded-war" to deploy to Tomcat (while the "security" one was skipped from tests for the moment).
| (Maybe the "embedded-war" one should be considered to be in the 2nd category of tutorials.)
| After I modified a little the JSP for getting more infos about what's happening there, I found that a
| NamingException: org.jboss.tutorial.embeddedwar.CustomerDAOLocal not bound
| is thrown.
| (If it's useful, I can insert later some code snippets from the modified EmbeddedEJB3.jsp, but it's only usual old-style debugging stuff for finding more infos.)
|
|
| 2. About the source code and the libraries (jboss-ejb3-all.jar, hibernate-all.jar, thirdparty-all.jar)
|
| | i. If all the tutorials succeeded at you, what version of embedded EJB3 did you used ? (e.g. "Alpha8 patch 2", or "Alpha 9", the latest by now).
| | ii. From where should I try to get the source code for the version of embedded EJB3 I use at some moment (I mean the source for the libraries in the org.jboss.ejb3.embedded package, within the jboss-ejb3-all.jar, part of some version of the embedded EJB3 product)? (this question was posted today in another thread, see http://www.jboss.org/index.html?module=bb&op=viewtopic&t=92609.)
| | For ex., I found some source code at http://anonsvn.labs.jboss.com/labs/jbossbuild/trunk/projects/jboss/ejb3/s...
| | (Revision 6759, from now on referred as "anon.labs").
| | But it seems to be quite different from the decompiled version from jboss-ejb3-all.jar
| | (for ex., the "Alpha8 patch 2" or "Alpha 9" EJB3StandaloneDeployer.java start() method contains a call to the private void loadMbeanServer(), which doesn't appear in the version from the "anon.labs".
| |
| | This is the point where the embedded-war example fails at me: (Main.main(), at the call of deployer.start().
| |
|
| (If it's useful, I can insert later some code snippets to provide more details about where exactly that Exception is thrown; by default, this throw is not visible in the jsp page, it just don't show the expected result.)
|
| If necessary, I can give in a later reply more informations.
| (For the moment, let's mention that I used Windows XP SP2, with JDKs/JREs of generation 5.0 from Sun, Bea and IBM, the one in use during the tests being JRockit from Bea; the IDE used was Eclipse 3.2/Lomboz).
|
| (The main reason I am interested in embedded EJB3 is for testing the availability of JBossESB with other App Servers which currently don't have support for EJB3, e.g. WebSphere 6.1, see http://www.jboss.org/index.html?module=bb&op=viewtopic&t=92220 for a related thread).
|
|
|
|
| Thank you very much in advance.
|
| Best regards,
| ___ Emil Prager __________________________________________________
View the original post : http://www.jboss.com/index.html?module=bb&op=viewtopic&p=3977938#3977938
Reply to the post : http://www.jboss.com/index.html?module=bb&op=posting&mode=reply&p=3977938
19 years, 7 months