Support for acl

Support for acl and some bugfixes