Darnit... I read that post and made a mental note to myself to change
it!!!  (But of course, I got distracted by something stupid and didn't
do it right away).

Anyhow.... after that change:

2010-05-11 18:26:56,985 ERROR
[org.springframework.web.context.ContextLoader] - <Context
initialization failed>
org.springframework.beans.factory.BeanCreationException: Error creating
bean with name 'centralAuthenticationService' defined in ServletContext
resource [/WEB-INF/spring-configuration/applicationContext.xml]: Cannot
resolve reference to bean 'authenticationManager' while setting bean
property 'authenticationManager'; nested exception is
org.springframework.beans.factory.BeanCreationException: Error creating
bean with name 'authenticationManager' defined in ServletContext
resource [/WEB-INF/deployerConfigContext.xml]: Cannot create inner bean
'org.jasig.cas.authentication.principal.UrlCredentialToPrincipalResolver
#c02d83' of type
[org.jasig.cas.authentication.principal.UrlCredentialToPrincipalResolver
] while setting bean property 'credentialsToPrincipalResolvers' with key
[1]; nested exception is
org.springframework.beans.factory.CannotLoadBeanClassException: Cannot
find class
[org.jasig.cas.authentication.principal.UrlCredentialToPrincipalResolver
] for bean with name 'org.jasig.cas.authentication.pri
ncipal.UrlCredentialToPrincipalResolver#c02d83' defined in
ServletContext resource [/WEB-INF/deployerConfigContext.xml]; nested
exception is java.lang.ClassNotFoundException:
org.jasig.cas.authentication.principal.UrlCredentialToPrincipalResolver
  at
org.springframework.beans.factory.support.BeanDefinitionValueResolver.re
solveReference(BeanDefinitionValueResolver.java:328)
  at
org.springframework.beans.factory.support.BeanDefinitionValueResolver.re
solveValueIfNecessary(BeanDefinitionValueResolver.java:106) 
  at
org.springframework.beans.factory.support.AbstractAutowireCapableBeanFac
tory.applyPropertyValues(AbstractAutowireCapableBeanFactory.ja
va:1308)
.........

V/R,

Rob McKennon
Unix Admin (fish out of water)

<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans";
       xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance";
       xmlns:p="http://www.springframework.org/schema/p";
       xmlns:sec="http://www.springframework.org/schema/security";
xmlns:tx="http://www.springframework.org/schema/tx";
       xsi:schemaLocation="http://www.springframework.org/schema/beans
http://www.springframework.org/schema/beans/spring-beans-3.0.xsd
       http://www.springframework.org/schema/security
http://www.springframework.org/schema/security/spring-security-3.0.xsd
http://www.springframework.org/schema/tx
http://www.springframework.org/schema/tx/spring-tx-2.5.xsd";>
    <bean id="authenticationManager"
 
class="org.jasig.cas.authentication.AuthenticationManagerImpl">
        <property name="credentialsToPrincipalResolvers">
            <list>
                <bean
 
class="org.jasig.cas.authentication.principal.UsernamePasswordCredential
sToPrincipalResolver"/>
                <bean
 
class="org.jasig.cas.authentication.principal.UrlCredentialToPrincipalRe
solver"/>
            </list>
        </property>

        <property name="authenticationHandlers">
            <list>
                <bean
class="org.jasig.cas.authentication.handler.support.HttpBasedServiceCred
entialsAuthenticationHandler"
                      p:httpClient-ref="httpClient"/>

                <bean
class="org.jasig.cas.adaptors.ldap.BindLdapAuthenticationHandler">
                        <property name="filter" value="uid=%u" />
                        <property name="searchBase"
value="ou=Users,dc=usf,dc=edu" />
                        <property name="contextSource"
ref="contextSource" />
                </bean>
            </list>
        </property>
    </bean>

    <bean id="contextSource"
class="org.springframework.ldap.core.support.LdapContextSource">
        <property name="pooled" value="false"/>
        <property name="urls">
                <list>
                        <value>ldap://ldapdemo.idea.com/</value>
                        <value>ldaps://ldapdemo.idea.com/</value>
                </list>
        </property>
        <property name="userDn" value="cn=admin,dc=usf,dc=edu"/>
        <property name="password" value="admin"/>
        <property name="baseEnvironmentProperties">
                <map>
                        <entry>
                                <key>
        
<value>java.naming.security.authentication</value>
                                </key>
                                        <value>simple</value>
                        </entry>
                </map>
        </property>
    </bean>


    <sec:user-service id="userDetailsService">
        <sec:user name="battags" password="notused"
authorities="ROLE_ADMIN"/>
    </sec:user-service>

    <bean id="attributeRepository"
 
class="org.jasig.services.persondir.support.StubPersonAttributeDao">
        <property name="backingMap">
            <map>
                <entry key="uid" value="uid"/>
                <entry key="eduPersonAffiliation"
value="eduPersonAffiliation"/>
                <entry key="groupMembership" value="groupMembership"/>
            </map>
        </property>
    </bean>
<!--
    <bean id="serviceRegistryDao"
class="org.jasig.cas.services.JpaServiceRegistryDaoImpl"
          p:entityManagerFactory-ref="entityManagerFactory"/>
+-->
    <bean id="serviceRegistryDao"
class="org.jasig.cas.services.InMemoryServiceRegistryDaoImpl" />

    <tx:annotation-driven transaction-manager="transactionManager"/>
<bean
                id="dataSource"
                class="org.apache.commons.dbcp.BasicDataSource"
                p:driverClassName="com.mysql.jdbc.Driver"
        
p:url="jdbc:mysql://localhost:3306/test?autoReconnect=true"
                p:password=""
                p:username="sa" />
</beans>






-----Original Message-----
From: Marvin Addison [mailto:[email protected]] 
Sent: Tuesday, May 11, 2010 6:03 PM
To: [email protected]
Subject: Re: [cas-user] LDAP setup errors

> org.springframework.beans.factory.BeanCreationException: Error
creating bean with name 'centralAuthenticationService' defined in
ServletContext resource
[/WEB-INF/spring-configuration/applicationContext.xml]: Cannot resolve
reference to bean 'authenticationManager' while setting bean property
'authenticationManager'; nested exception is
org.springframework.beans.factory.CannotLoadBeanClassException: Cannot
find class
[org.jasig.cas.authentication.DefaultAuthenticationManagerImpl] for bean
with name 'authenticationManager'

Man, this issue bites two people in one day.  Ouch!

You'll want to change the class name of your authenticationManager
bean to org.jasig.cas.authentication.AuthenticationManagerImpl.  The
one you used is from trunk which doesn't exist in any released version
to date.

M

-- 
You are currently subscribed to [email protected] as:
[email protected]
To unsubscribe, change settings or access archives, see
http://www.ja-sig.org/wiki/display/JSG/cas-user


-- 
You are currently subscribed to [email protected] as: 
[email protected]
To unsubscribe, change settings or access archives, see 
http://www.ja-sig.org/wiki/display/JSG/cas-user

Reply via email to