summaryrefslogtreecommitdiff
path: root/src/bus-proxyd/test-bus-policy.c
AgeCommit message (Collapse)Author
2014-12-23core: rearrange code so that libsystemd/sd-bus/ does not include header ↵Lennart Poettering
files from core Stuff in src/shared or src/libsystemd should *never* include code from src/core or any of the tools, so don't do that here either. It's not OK!
2014-11-27bus-proxy: beef up policy enforcementLennart Poettering
- actually return permission errors to clients - use the right ucreds field - fix error paths when we cannot keep track of locally acquired names due to OOM - avoid unnecessary global variables - log when the policy denies access - enforce correct policy rule order - always request all the metadata its we need to make decisions
2014-11-26bus-policy: actually test messages against the newly added test.confLennart Poettering
2014-11-26bus-policy: also add in other bus policy tests from dbus1Lennart Poettering
dbus1 only checks if these files parse correctly so let's do the same for now.
2014-11-26bus-policy: steal a test case for prefix ownership from dbus1, and make sure ↵Lennart Poettering
it passes with the bus proxy enforcement
2014-10-09bus-policy: move name list iteration to policy usersDaniel Mack
We need to figure out which of the possible names satisfied the policy, so we cannot do the iteration in check_policy_item() but have to leave it to the users. Test cases amended accordingly.
2014-10-01Remove repeated includesThomas Hindoe Paaboel Andersen
In pty.c there was both an include of our pty.h and the system installed pty.h. The latter contains only two functions openpty and forkpty. We use neither so I assume it was a typo and removed it. We still compile and pass all tests.
2014-09-28test-bus-policy: silence coverityThomas Hindoe Paaboel Andersen
Check if strjoin worked and also use _cleanup_free_ since we are here. Found with Coverity. Fixes CID#1241962
2014-09-26test-bus-policy: load policy files from TEST_DIRDaniel Mack
'make distcheck' calls test-bus-policy outside of the source tree, so it must consider the TEST_DIR variable to access its files.
2014-09-24bus-policy: split API for bus-proxydDaniel Mack
Instead of operating on an sd_bus_message object, expose an API that has 4 functions: policy_check_own() policy_check_hello() policy_check_recv() policy_check_send() This also allows dropping extra code to parse message contents - the bus proxy already has dedicated code paths for that, and we can hook into those later. Tests amended accordingly.
2014-09-20bus-policy: add test utilityDaniel Mack
Add some test files and routines for dbus policy checking.