Spring Roo + security + json, how to authenticate?
Hi,
Imagine that example pizzashop, included in Spring Roo installlation. It offer JSON remoting for all domain types. So you can externalize all operations using REST.
Until here, everything works ok, now add security to this project using:
security setup
Alright, now I can have authentication through html. However, if I intercept "/bases" for example and limit it to isAuthenticated(), through web, I can for sure authenticate, but how to do that through REST?
Before use Spring Security a simple command like this:
curl -i -X POST -H "Content-Type: application/json" -H "Accept: application/json" -d '{name: "Thin Crust"}' http://localhost:8080/pizzashop/bases
Expose some data, however after applying Security, it doesn't work anymore because it needs to be authenticate.