From 1c0e6f26e2f5fe2561ca09a1edf12bb3458392eb Mon Sep 17 00:00:00 2001 From: "Jasper St. Pierre" Date: Wed, 20 Nov 2013 13:12:38 -0500 Subject: [PATCH] mutter-launch: Don't test the argument name to validate launching things Somebody could do: $ mv my-evil-program mutter-wayland $ PATH=.:$PATH mutter-launch mutter-wayland It's not secure, and it's hard to test with, so just drop it for now We'll be relying on logind to hand us permissions in the future. --- src/wayland/weston-launch.c | 3 --- 1 file changed, 3 deletions(-) diff --git a/src/wayland/weston-launch.c b/src/wayland/weston-launch.c index d81164835..773eea4bd 100644 --- a/src/wayland/weston-launch.c +++ b/src/wayland/weston-launch.c @@ -738,9 +738,6 @@ main(int argc, char *argv[]) if (optind >= argc) error(1, 0, "Expected program argument"); - if (strcmp (argv[optind], "mutter-wayland") && - strcmp (argv[optind], "gnome-shell-wayland")) - error(1, 0, "mutter-launch can only be used to launch mutter or gnome-shell"); wl.pw = getpwuid(getuid()); if (wl.pw == NULL)