we are implementing a new web service. The web service will be a store of sensitive data and there are multiple users types with different permissions. So some user types can’t access(and some can’t change, and so on) certain types of data. How would this work in REST? I’m very new to REST, so sorry if this sounds noobish.
Share
Your first step is to provide some transport encryption in the form of SSL. This should take care of ensureing there are no man in the middle attacks and that nobody is snooping the data. Second you’ll need to figure out some sort of authentication method. A popular method is to create a login service to which you send a user name and password and it returns some sort of a limited life key. You then send this key along with all subsiquent requests and the server validates it before returning any data. If you have different user levels then as well as checking the key also check if the given user should be able to access that information.