X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=blobdiff_plain;ds=sidebyside;f=src%2Fbus-proxyd%2Fbus-policy.h;h=5b4d9d0c1065bf9d6c8a673df329a7faa0dcf081;hb=078ef7b85ad77ba999588f72b31a50ced5907692;hp=bad4256a33a4cace2cb055212efd86b614409f7e;hpb=2e2b36084a98f9071fd178c6540ce57b2f577f8d;p=elogind.git diff --git a/src/bus-proxyd/bus-policy.h b/src/bus-proxyd/bus-policy.h index bad4256a3..5b4d9d0c1 100644 --- a/src/bus-proxyd/bus-policy.h +++ b/src/bus-proxyd/bus-policy.h @@ -42,6 +42,7 @@ typedef enum PolicyItemClass { POLICY_ITEM_OWN_PREFIX, POLICY_ITEM_USER, POLICY_ITEM_GROUP, + POLICY_ITEM_IGNORE, _POLICY_ITEM_CLASS_MAX, _POLICY_ITEM_CLASS_INVALID = -1, } PolicyItemClass; @@ -75,6 +76,23 @@ typedef struct Policy { int policy_load(Policy *p, char **files); void policy_free(Policy *p); +bool policy_check_own(Policy *p, const struct ucred *ucred, const char *name); +bool policy_check_hello(Policy *p, const struct ucred *ucred); +bool policy_check_recv(Policy *p, + const struct ucred *ucred, + Hashmap *names, + int message_type, + const char *path, + const char *interface, + const char *member); +bool policy_check_send(Policy *p, + const struct ucred *ucred, + char **names, + int message_type, + const char *path, + const char *interface, + const char *member); + void policy_dump(Policy *p); const char* policy_item_type_to_string(PolicyItemType t) _const_;