Authentication and authorization

Hello,

I'm doing some experiments with your code base. The pull request contains a basis for authentication and authorization. I'm not sure it's the right way to implement this feature, but I hope it may help.

I also had some questions regarding the part of your code which is used to stream content to amazon s3. Do you already used such streaming techniques in production?

Best regards.