Ver Mensaje Individual
  #2 (permalink)  
Antiguo 14/11/2013, 15:07
oskrok
 
Fecha de Ingreso: febrero-2006
Mensajes: 43
Antigüedad: 18 años, 9 meses
Puntos: 1
Respuesta: Aplicación que no despliega con Spring Security

bets-dispatcher-servlet.xml
Código PHP:
<?xml version="1.0" encoding="UTF-8"?>
<beans xmlns="http://www.springframework.org/schema/beans"
    xmlns:mvc="http://www.springframework.org/schema/mvc"
    xmlns:context="http://www.springframework.org/schema/context"
    xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    xsi:schemaLocation="
        http://www.springframework.org/schema/mvc 
          http://www.springframework.org/schema/mvc/spring-mvc-3.1.xsd
        http://www.springframework.org/schema/beans     
        http://www.springframework.org/schema/beans/spring-beans-3.1.xsd
        http://www.springframework.org/schema/context 
        http://www.springframework.org/schema/context/spring-context-3.1.xsd">
        
    <context:component-scan base-package="com.omb.bets.web.pages" />

    <!-- support JSR303 annotation if JSR 303 validation present on classpath -->
    <mvc:annotation-driven />
    
    <bean class="org.springframework.web.servlet.view.InternalResourceViewResolver">
        <property name="prefix">
            <value>/WEB-INF/pages/</value>
        </property>
        
        <property name="suffix">
            <value>.jsp</value>
        </property>
    </bean>
    
    <bean id="properties" class="org.springframework.beans.factory.config.PropertiesFactoryBean">
        <property name="locations">
            <list><value>/WEB-INF/config.properties</value></list>
        </property>
    </bean>
    
    <bean id="messagestatusdao" class="com.omb.bets.model.message.MessageStatusDao" />
    <bean id="messagedao" class="com.omb.bets.model.message.MessageDao" />
    
    <bean id="userstatusdao" class="com.omb.bets.model.user.UserStatusDao" />
    <bean id="usertypedao" class="com.omb.bets.model.user.UserTypeDao" />    
    <bean id="userdao" class="com.omb.bets.model.user.UserDao" />    
    
    <bean id="country" class="com.omb.bets.model.country.Country" />
    <bean id="countrydao" class="com.omb.bets.model.country.CountryDao" />        
    
    <bean id="province" class="com.omb.bets.model.province.Province" />
    <bean id="provincedao" class="com.omb.bets.model.province.ProvinceDao" />

    <!-- Handles HTTP GET requests for /resources/** by efficiently serving up static resources in the ${webappRoot}/resources/ directory -->
    <mvc:resources mapping="/assets/**" location="/assets/" />
</beans>
spring-security.xml
Código PHP:
<beans:beans xmlns="http://www.springframework.org/schema/security"
    
xmlns:beans="http://www.springframework.org/schema/beans" 
    
xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
    
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.3.xsd"
>
 
    <
http auto-config="true">
        <
intercept-url pattern="/welcome*" access="ROLE_USER" />
        <
form-login login-page="/login" default-target-url="/welcome"
            
authentication-failure-url="/loginfailed" />
        <
logout logout-success-url="/logout" />
    </
http>
 
    <
authentication-manager>
        <
authentication-provider>
            <
user-service>
                <
user name="mkyong" password="123456" authorities="ROLE_USER" />
            </
user-service>
        </
authentication-provider>
    </
authentication-manager>
 
</
beans:beans