Invalid CSRF Token 'null' was found on the request parameter '_csrf' or header 'X-CSRF-TOKEN'

前端 未结 11 2488
你的背包
你的背包 2020-12-07 15:38

After configuring Spring Security 3.2, _csrf.token is not bound to a request or a session object.

This is the spring security config:

&l         


        
11条回答
  •  庸人自扰
    2020-12-07 16:00

    I used to have the same problem.

    Your config use security="none" so cannot generate _csrf:

    
    

    you can set access="IS_AUTHENTICATED_ANONYMOUSLY" for page /login.jsp replace above config:

    
        
        
        
        
        
    
    

提交回复
热议问题