2
Spring REST(web.xmlなし)でアプリケーションを構築しています。 RESTの呼び出しはうまくいきますが、私はweb.xmlを使って追加するのは簡単ですが、Spring 4をweb.xmlなしで使用しているので、私はweb.xml部分Java構成を使用します。Spring RESTアプリケーションにおけるセキュリティ制約のJava構成
マイweb.xmlの:
<security-role>
<role-name>all</role-name>
</security-role>
<security-constraint>
<web-resource-collection>
<web-resource-name>test</web-resource-name>
<url-pattern>/*</url-pattern>
</web-resource-collection>
<auth-constraint>
<role-name>all</role-name>
</auth-constraint>
</security-constraint>
私は、Java構成を通じて、こののweb.xmlを構成する上で助けを必要としています。おそらく、これはSpring Securityを通じて追加することができますが、その方法はわかりません。