diff --git a/Makefile b/Makefile index 450b8a0b4..d5ec11ea6 100644 --- a/Makefile +++ b/Makefile @@ -111,7 +111,7 @@ contrib/syntax/lists/profile_commands_arg0.list: src/firejail/profile.c Makefile # TODO: private-lib is special-cased in the code and doesn't match the regex contrib/syntax/lists/profile_commands_arg1.list: src/firejail/profile.c Makefile @printf 'Generating %s from %s\n' $@ $< - @{ sed -En 's/.*strn?cmp\(ptr, "([^"]+) ".*/\1/p' $<; \ + @{ sed -En 's/.*strn?cmp\(ptr, "([^"]+) .*/\1/p' $<; \ echo private-lib; } | LC_ALL=C sort -u >$@ contrib/syntax/lists/profile_conditionals.list: src/firejail/profile.c Makefile diff --git a/contrib/syntax/lists/profile_commands_arg1.list b/contrib/syntax/lists/profile_commands_arg1.list index 28913542f..5862f16ac 100644 --- a/contrib/syntax/lists/profile_commands_arg1.list +++ b/contrib/syntax/lists/profile_commands_arg1.list @@ -5,11 +5,13 @@ blacklist-nolog caps.drop caps.keep cpu +dbus-system dbus-system.broadcast dbus-system.call dbus-system.own dbus-system.see dbus-system.talk +dbus-user dbus-user.broadcast dbus-user.call dbus-user.own @@ -74,4 +76,5 @@ tmpfs veth-name whitelist whitelist-ro +x11 xephyr-screen diff --git a/src/firejail/profile.c b/src/firejail/profile.c index bdaaed433..8cc5c1166 100644 --- a/src/firejail/profile.c +++ b/src/firejail/profile.c @@ -484,7 +484,7 @@ int profile_check_line(char *ptr, int lineno, const char *fname) { #endif return 0; } - else if (strncmp("dbus-user ", ptr, 10) == 0) { + else if (strncmp(ptr, "dbus-user ", 10) == 0) { #ifdef HAVE_DBUSPROXY ptr += 10; if (strcmp("filter", ptr) == 0) { @@ -551,7 +551,7 @@ int profile_check_line(char *ptr, int lineno, const char *fname) { #endif return 1; } - else if (strncmp("dbus-system ", ptr, 12) == 0) { + else if (strncmp(ptr, "dbus-system ", 12) == 0) { #ifdef HAVE_DBUSPROXY ptr += 12; if (strcmp("filter", ptr) == 0) {