誰かが私に助けてくれますか?あなたの助けに感謝。スプリングセキュリティ3.1
私は、create-session = "stateless"オプションでSpringセキュリティ3.1を使用しています。 "InsufficientAuthenticationException"をスローする:ExceptionTranslationFilterの "このリソースにアクセスするには完全な認証が必要です"。
私は何が間違っているのか、なぜこの例外が発生しているのか理解できません。この例外は資格情報が適切ではないと述べていますが、資格情報が要求を通過していることがわかります。まだ401が不正なものになっています
実際にユーザーが正しくログインできるかどうかは、&です。しかし、再び、アクセス拒否例外のためにログインページにリダイレクトしています。
ここで私は、コード
春のsecurity.xml
私の知る限りでは<http entry-point-ref="negotiateSecurityFilterEntryPoint"
create-session="stateless" >
<intercept-url pattern="/user/loginuser" access="ROLE_ANONYMOUS"/>
<intercept-url pattern="/**" access="ROLE_USER"/>
<custom-filter ref="securityContextPersistenceFilter" after="BASIC_AUTH_FILTER" />
<custom-filter ref="ldapAuthFilter" position="CAS_FILTER" />
<custom-filter ref="databaseAuthFilter" position="FORM_LOGIN_FILTER" />
</http>
<bean id="securityContextPersistenceFilter" class="org.springframework.security.web.context.SecurityContextPersistenceFilter">
<property name='securityContextRepository'>
<bean class='org.springframework.security.web.context.HttpSessionSecurityContextRepository'>
<property name='allowSessionCreation' value='false' />
</bean>
</property>
</bean>
現在の質問ではないため、質問のタイトルを実際の質問に編集してください。 – carlspring