02a54da28f376dd66d7939d8546a196a0045b486Timo Sirainen#define ACL_ID_NAME_AUTHENTICATED "authenticated"
02a54da28f376dd66d7939d8546a196a0045b486Timo Sirainen#define ACL_ID_NAME_GROUP_OVERRIDE_PREFIX "group-override="
3809b9691c46926aa54968ac8e418d04361e1efaTimo Sirainen int (*init)(struct acl_backend *backend, const char *data);
2f122b4db3f0d4eeb59ff9d306e54b2009d72cf9Timo Sirainen (*nonowner_lookups_iter_init)(struct acl_backend *backend);
37c72fa0cd3f1d74d79b64afb3fb6da5ffd4fe3aAki Tuomi bool (*nonowner_lookups_iter_next)(struct acl_mailbox_list_context *ctx,
2f122b4db3f0d4eeb59ff9d306e54b2009d72cf9Timo Sirainen const char **name_r);
579e70631b8474d20fd3829f477c62950e5f9635Timo Sirainen int (*nonowner_lookups_rebuild)(struct acl_backend *backend);
7fb70daba4e571eab5b64f496d20b9e37e31141bTimo Sirainen struct acl_object *(*object_init)(struct acl_backend *backend,
3809b9691c46926aa54968ac8e418d04361e1efaTimo Sirainen const char *name);
da9f6acdcb303d0fe5160b669668aedf39c8f45aTimo Sirainen struct acl_object *(*object_init_parent)(struct acl_backend *backend,
7fb70daba4e571eab5b64f496d20b9e37e31141bTimo Sirainen void (*object_deinit)(struct acl_object *aclobj);
7fb70daba4e571eab5b64f496d20b9e37e31141bTimo Sirainen int (*object_refresh_cache)(struct acl_object *aclobj);
7fb70daba4e571eab5b64f496d20b9e37e31141bTimo Sirainen int (*object_update)(struct acl_object *aclobj,
eb4d4f557fa75aa2a47639e9deb75a21f44eb42aTimo Sirainen int (*last_changed)(struct acl_object *aclobj, time_t *last_changed_r);
7fb70daba4e571eab5b64f496d20b9e37e31141bTimo Sirainen (*object_list_init)(struct acl_object *aclobj);
37c72fa0cd3f1d74d79b64afb3fb6da5ffd4fe3aAki Tuomi bool (*object_list_next)(struct acl_object_list_iter *iter,
37c72fa0cd3f1d74d79b64afb3fb6da5ffd4fe3aAki Tuomi int (*object_list_deinit)(struct acl_object_list_iter *iter);
7d8afd1e15bdf23b5fd13aa9ac9606aca2797125Timo Sirainenextern const char *const all_mailbox_rights[];
086c52e4bcdc950e47ee331e1e07c9c10982a670Timo Sirainenacl_default_object_list_init(struct acl_object *aclobj);
37c72fa0cd3f1d74d79b64afb3fb6da5ffd4fe3aAki Tuomibool acl_default_object_list_next(struct acl_object_list_iter *iter,
37c72fa0cd3f1d74d79b64afb3fb6da5ffd4fe3aAki Tuomiint acl_default_object_list_deinit(struct acl_object_list_iter *iter);
02a54da28f376dd66d7939d8546a196a0045b486Timo Sirainenconst char *const *
02a54da28f376dd66d7939d8546a196a0045b486Timo Sirainenacl_backend_mask_get_names(struct acl_backend *backend,
515d649c1802beb48433b90125518c00d0a1fbb4Timo Sirainenstruct acl_object *acl_backend_get_default_object(struct acl_backend *backend);
2f122b4db3f0d4eeb59ff9d306e54b2009d72cf9Timo Sirainenint acl_backend_get_default_rights(struct acl_backend *backend,
81e6e1ef0feef60644a4c4b745d82a4c98223affTimo Sirainenvoid acl_rights_write_id(string_t *dest, const struct acl_rights *right);
3cd0463d17cf9ecbc3d826d60b36800d09f0633cTimo Sirainenbool acl_rights_has_nonowner_lookup_changes(const struct acl_rights *rights);
7d8afd1e15bdf23b5fd13aa9ac9606aca2797125Timo Sirainenint acl_identifier_parse(const char *line, struct acl_rights *rights);
eb4d4f557fa75aa2a47639e9deb75a21f44eb42aTimo Sirainenint acl_rights_update_import(struct acl_rights_update *update,
eb4d4f557fa75aa2a47639e9deb75a21f44eb42aTimo Sirainen const char **error_r);
eb4d4f557fa75aa2a47639e9deb75a21f44eb42aTimo Sirainenconst char *acl_rights_export(const struct acl_rights *rights);
15f43b172d2c626aa03c921979c49821a55c7e5eTimo Sirainenint acl_rights_parse_line(const char *line, pool_t pool,
15f43b172d2c626aa03c921979c49821a55c7e5eTimo Sirainen struct acl_rights *rights_r, const char **error_r);
4c158400b046fefefce0194603951a6587f51867Timo Sirainenvoid acl_rights_dup(const struct acl_rights *src,
cc287b822b175619a853686b738ba673e370117bTimo Sirainenint acl_rights_cmp(const struct acl_rights *r1, const struct acl_rights *r2);
086c52e4bcdc950e47ee331e1e07c9c10982a670Timo Sirainenvoid acl_rights_sort(struct acl_object *aclobj);
cc287b822b175619a853686b738ba673e370117bTimo Sirainenconst char *const *
cc287b822b175619a853686b738ba673e370117bTimo Sirainenacl_right_names_parse(pool_t pool, const char *acl, const char **error_r);
cc287b822b175619a853686b738ba673e370117bTimo Sirainenvoid acl_right_names_write(string_t *dest, const char *const *rights);
cc287b822b175619a853686b738ba673e370117bTimo Sirainenvoid acl_right_names_merge(pool_t pool, const char *const **destp,
cc287b822b175619a853686b738ba673e370117bTimo Sirainen const char *const **rightsp,
cc287b822b175619a853686b738ba673e370117bTimo Sirainen const char *const *modify_rights,
086c52e4bcdc950e47ee331e1e07c9c10982a670Timo Sirainenvoid acl_object_rebuild_cache(struct acl_object *aclobj);
086c52e4bcdc950e47ee331e1e07c9c10982a670Timo Sirainenvoid acl_object_remove_all_access(struct acl_object *aclobj);