filesystem permissions

Hi!
I have to implement filesystem permissions for my web service file manager.
Clients get file from my server through webservice and I'm looking for nice access rights mechanism. For example how to store those data (about permissions) or how to identify user to make it quite efficient ?