Add http security filter in java config

前端 未结 2 1179
挽巷
挽巷 2020-12-13 00:51

I\'m trying to add web security in spring but I don\'t want the filter to apply to certain things. How is that done in java?

And maybe there\'s a better way to do th

2条回答
  •  情话喂你
    2020-12-13 01:32

    1 In xml configuration of spring-security I use

     
    
    
     
        
    

    to retrieve it from security check.

    2 After that add mvc:resource tag in your spring configuration

    
    

    Important: this config will only work if url is handled by dispatcher servlet. This means that in web.xml you must have

       
            dispatcher
            /
         
    

提交回复
热议问题