在ec2实例上部署应用程序时,我正在努力解决以下错误
10:59:13,129 [localhost-startStop-1] [] [ERROR] [ContextLoader]。[initWebApplicationContext()]:312 ::上下文初始化失败 java.lang.VerifyError :(类:org / springframework / security / web / FilterChainProxy,方法:签名:(Lorg / springframework / security / web / SecurityFilterChain;)V)期望在堆栈上找到对象/数组
当我从安全上下文文件中删除http标签时,我们可以在ec2 isntance上部署应用程序。
如何在我们的本地实例(窗口)上部署相同的战争。
请在下面找到我们的安全上下文文件
<global-method-security secured-annotations="enabled" pre-post-annotations="enabled" authentication-manager-ref="mizuAuthenticationManager" ></global-method-security>
<beans:bean id="mizuPropertiesHolder" class="org.springframework.beans.factory.config.PropertyPlaceholderConfigurer">
<beans:property name="locations">
<beans:list>
<beans:value>classpath*:mizu-conf.properties</beans:value>
</beans:list>
</beans:property>
<beans:property name="ignoreUnresolvablePlaceholders" value="true"/>
</beans:bean>
<beans:bean id="preAuthFilter" class="com.converse.mizu.service.filter.UrlParametersAuthenticationFilter">
</beans:bean>
<beans:bean id="mizuAuthenticationEntryPoint" class="com.converse.mizu.service.security.MizuAuthenticationEntryPoint">
<beans:constructor-arg name="loginUrl" value="/" />
</beans:bean>
<beans:bean id="rememberMeFilter" class= "org.springframework.security.web.authentication.rememberme.RememberMeAuthenticationFilter">
<beans:constructor-arg name="authenticationManager" ref="mizuAuthenticationManager" />
<beans:constructor-arg name="rememberMeServices" ref="mizuRememberMeServices"/>
</beans:bean>
<beans:bean id="mizuUserDetailsService" class="com.converse.mizu.service.security.UserDetailsServiceImpl"></beans:bean>
<beans:bean id="mizuAuthenticationProvider" class="com.converse.mizu.service.security.MizuAuthenticationProvider"></beans:bean>
<beans:bean id="mizuRememberMeServices" class= "com.converse.mizu.service.security.CustomTokenBasedRememberMeService">
<beans:constructor-arg name="key" value="${remembeMeCoockie.key}"></beans:constructor-arg>
<beans:constructor-arg name="userDetailsService" ref="mizuUserDetailsService"></beans:constructor-arg>
<beans:property name="tokenValiditySeconds" value="2592000" />
<beans:property name="cookieName" value="${remembeMeCoockie.name}" />
<beans:property name="cookiePath" value="/" />
</beans:bean>
<beans:bean id="rememberMeAuthenticationProvider" class= "org.springframework.security.authentication.RememberMeAuthenticationProvider">
<beans:property name="key" value="${remembeMeCoockie.key}"/>
</beans:bean>
<beans:bean id="logoutSuccessHandler" class="com.converse.mizu.service.security.LogoutSuccessHandler" >
<beans:property name="logoutSuccessUrl" value="/"/>
</beans:bean>
<beans:bean id="concurrencyFilter" class="org.springframework.security.web.session.ConcurrentSessionFilter">
<beans:property name="sessionRegistry" ref="sessionRegistry" />
<beans:property name="expiredUrl" value="/" />
</beans:bean>
<beans:bean id="sas" class= "org.springframework.security.web.authentication.session.ConcurrentSessionControlStrategy">
<beans:constructor-arg name="sessionRegistry" ref="sessionRegistry" />
<beans:property name="maximumSessions" value="1" />
</beans:bean>
<beans:bean id="sessionRegistry" class="org.springframework.security.core.session.SessionRegistryImpl" />
<http pattern="/js/**" security="none" />
<http pattern="/css/**" security="none" />
<http pattern="/img/**" security="none" />
<http pattern="/font/**" security="none" />
<http pattern="/index.html*" security="none" />
<http pattern="/rest/url/**" security="none" />
<http pattern="/rest/user/resetpwd/**" security="none" />
<http pattern="/rest/uiads/analytics/uispec/**" security="none" />
<http entry-point-ref="http403EntryPoint" pattern="/autologin">
<custom-filter ref="preAuthFilter" position="PRE_AUTH_FILTER"/>
<session-management invalid-session-url="/" >
<concurrency-control session-registry-ref="sessionRegistry" max-sessions="1" />
</session-management>
</http>
<http use-expressions="true" entry-point-ref="mizuAuthenticationEntryPoint" >
<intercept-url pattern="/rest/signup/selfserve/register/account**" access="hasRole('CREATE_ACCOUNT')"/>
<intercept-url pattern="/html/account/register.html" access="hasRole('CREATE_ACCOUNT')"/>
<intercept-url pattern="/html/adStudio.htm**" access="isAuthenticated()"/>
<intercept-url pattern="/html/adcreator.htm**" access="isAuthenticated() and hasRole('AD_CREATOR_TOOL')"/>
<intercept-url pattern="/rest/signup/**" access="permitAll"/>
<intercept-url pattern="/rest/**" access="isAuthenticated()"/>
<custom-filter ref="mizuAuthenticationProcessingFilter" position="FORM_LOGIN_FILTER"/>
<custom-filter ref="rememberMeFilter" position="REMEMBER_ME_FILTER"/>
<custom-filter ref="concurrencyFilter" position="CONCURRENT_SESSION_FILTER"/>
<session-management session-authentication-strategy-ref="sas"/>
<logout invalidate-session="true" success-handler-ref="logoutSuccessHandler"/>
<access-denied-handler ref="accessDeniedHandler"/>
</http>
<beans:bean id="mizuAuthenticationProcessingFilter" class="org.springframework.security.web.authentication.UsernamePasswordAuthenticationFilter">
<beans:property name="sessionAuthenticationStrategy" ref="sas" />
<beans:property name="authenticationManager" ref="mizuAuthenticationManager"/>
<beans:property name="usernameParameter" value="username" />
<beans:property name="passwordParameter" value="password" />
<beans:property name="authenticationFailureHandler" ref="loginFailureHandler"/>
<beans:property name="authenticationSuccessHandler" ref="loginSuccessHandler"/>
<beans:property name="rememberMeServices" ref="mizuRememberMeServices" />
</beans:bean>
<!-- Register authentication manager for form login-->
<authentication-manager alias="mizuAuthenticationManager">
<authentication-provider ref="mizuAuthenticationProvider"/>
<authentication-provider ref="rememberMeAuthenticationProvider"/>
</authentication-manager>
<beans:bean id="http403EntryPoint" class="org.springframework.security.web.authentication.Http403ForbiddenEntryPoint"></beans:bean>