From 8b36cc0f179ee35176016ab67ae53078df4110fa Mon Sep 17 00:00:00 2001 From: "kay.sievers@vrfy.org" Date: Sat, 18 Dec 2004 11:34:17 +0100 Subject: [PATCH] complete removal of explicit udev permissions config file --- test/devd_test | 1 - test/net_test | 1 - test/replace_test | 1 - test/udev-test.pl | 183 +++++--------------------------------------------- test/udev.permissions | 22 ------ 5 files changed, 17 insertions(+), 191 deletions(-) delete mode 100644 test/udev.permissions (limited to 'test') diff --git a/test/devd_test b/test/devd_test index 6e4c206352..269c2b11da 100644 --- a/test/devd_test +++ b/test/devd_test @@ -16,7 +16,6 @@ cat > $CONFIG << EOF udev_root="$PWD/udev/" udev_db="$PWD/udev/.udevdb" udev_rules="$PWD/$RULES" -udev_permissions="$PWD/udev.permissions" EOF mkdir udev diff --git a/test/net_test b/test/net_test index ec0dea4642..9686f99258 100644 --- a/test/net_test +++ b/test/net_test @@ -15,7 +15,6 @@ cat > $CONFIG << EOF udev_root="$PWD/udev/" udev_db="$PWD/udev/.udevdb" udev_rules="$PWD/$RULES" -udev_permissions="$PWD/udev.permissions" EOF mkdir udev diff --git a/test/replace_test b/test/replace_test index 9445b7262a..19260765ba 100644 --- a/test/replace_test +++ b/test/replace_test @@ -15,7 +15,6 @@ cat > $CONFIG << EOF udev_root="$PWD/udev/" udev_db="$PWD/udev/.udevdb" udev_rules="$PWD/$RULES" -udev_permissions="$PWD/udev.permissions" EOF mkdir udev diff --git a/test/udev-test.pl b/test/udev-test.pl index 3f9a848490..8ee8ba5414 100644 --- a/test/udev-test.pl +++ b/test/udev-test.pl @@ -31,7 +31,6 @@ my $sysfs = "sys/"; my $udev_bin = "../udev"; my $udev_root = "udev-root/"; # !!! directory will be removed !!! my $udev_db = ".udevdb"; -my $perm = "udev.permissions"; my $main_conf = "udev-test.conf"; my $conf_tmp = "udev-test.rules"; @@ -503,167 +502,17 @@ BUS="scsi", SYSFS{whitespace_test}="WHITE SPACE ", NAME="matched-with-space" EOF }, { - desc => "permissions test", - subsys => "block", - devpath => "/block/sda", - exp_name => "node", - exp_perms => "5000::0444", - conf => < "permissions ttyUSB0:root:uucp:0660", - subsys => "tty", - devpath => "/class/tty/ttyUSB0", - exp_name => "ttyUSB0", - exp_perms => "0:14:0660", - conf => < "permissions tty0::root:0444", - subsys => "tty", - devpath => "/class/tty/tty0", - exp_name => "tty0", - exp_perms => "0:0:0444", - conf => < "permissions tty1:root::0555", - subsys => "tty", - devpath => "/class/tty/tty1", - exp_name => "tty1", - exp_perms => "0:0:0555", - conf => < "permissions tty2:::0777", - subsys => "tty", - devpath => "/class/tty/tty2", - exp_name => "tty2", - exp_perms => "0:0:0777", - conf => < "permissions tty3::: (default mode applied)", - subsys => "tty", - devpath => "/class/tty/tty3", - exp_name => "tty3", - exp_perms => "0:0:600", - conf => < "permissions i2c-300:root:sys:0744", - subsys => "i2c-dev", - devpath => "/class/i2c-dev/i2c-300", - exp_name => "i2c-300", - exp_perms => "0:3:0744", - conf => < "permissions i2c-fake1:root:7:0007", - subsys => "i2c-dev", - devpath => "/class/i2c-dev/i2c-fake1", - exp_name => "i2c-fake1", - exp_perms => "0:7:0007", - conf => < "permissions ttyS[01]:0:5:0700", - subsys => "tty", - devpath => "/class/tty/ttyS1", - exp_name => "ttyS1", - exp_perms => "0:5:0700", - conf => < "permissions ttyS[4-9]:tty:5:0060", - subsys => "tty", - devpath => "/class/tty/ttyS7", - exp_name => "ttyS7", - exp_perms => "0:5:0060", - conf => < "permissions tty4:0:5:0707", - subsys => "ttyS4", - devpath => "/class/tty/tty4", - exp_name => "tty4", - exp_perms => "0:5:0707", - conf => < "permissions tty4?:0:5:0007", - subsys => "tty", - devpath => "/class/tty/tty44", - exp_name => "tty44", - exp_perms => "0:5:0007", - conf => < "permissions tty3[!3]:::0467", - subsys => "tty", - devpath => "/class/tty/tty35", - exp_name => "tty35", - exp_perms => "0:0:0467", - conf => < "permissions tty33:bad:name:0500", + desc => "permissions USER=bad GROUP=name", subsys => "tty", devpath => "/class/tty/tty33", exp_name => "tty33", - exp_perms => "0:0:0500", - conf => < "permissions rtc:0:users:0600", - subsys => "misc", - devpath => "/class/misc/rtc", - exp_name => "misc/rtc", - exp_perms => "0:100:0600", + exp_perms => "0:0:0600", conf => < "permissions misc:0:users:0600", - subsys => "misc", - devpath => "/class/misc/psaux", - exp_name => "misc/psaux", - exp_perms => "0:100:0600", - conf => < "permissions set OWNER=5000", + desc => "permissions OWNER=5000", subsys => "block", devpath => "/block/sda", exp_name => "node", @@ -673,7 +522,7 @@ BUS="scsi", KERNEL="sda", NAME="node", OWNER="5000" EOF }, { - desc => "permissions set GROUP=100", + desc => "permissions GROUP=100", subsys => "block", devpath => "/block/sda", exp_name => "node", @@ -683,7 +532,7 @@ BUS="scsi", KERNEL="sda", NAME="node", GROUP="100" EOF }, { - desc => "permissions set mode=0777", + desc => "permissions MODE=0777", subsys => "block", devpath => "/block/sda", exp_name => "node", @@ -693,7 +542,7 @@ BUS="scsi", KERNEL="sda", NAME="node", MODE="0777" EOF }, { - desc => "permissions set OWNER=5000 GROUP=100 MODE=0777", + desc => "permissions OWNER=5000 GROUP=100 MODE=0777", subsys => "block", devpath => "/block/sda", exp_name => "node", @@ -703,37 +552,37 @@ BUS="scsi", KERNEL="sda", NAME="node", OWNER="5000", GROUP="100", MODE="0777" EOF }, { - desc => "permissions override OWNER to 5000", + desc => "permissions OWNER to 5000", subsys => "tty", devpath => "/class/tty/ttyUSB0", exp_name => "ttyUSB0", - exp_perms => "5000:14:0660", + exp_perms => "5000::", conf => < "permissions override GROUP to 100", + desc => "permissions GROUP to 100", subsys => "tty", devpath => "/class/tty/ttyUSB0", exp_name => "ttyUSB0", - exp_perms => ":100:0660", + exp_perms => ":100:0600", conf => < "permissions override MODE to 0060", + desc => "permissions MODE to 0060", subsys => "tty", devpath => "/class/tty/ttyUSB0", exp_name => "ttyUSB0", - exp_perms => ":14:0060", + exp_perms => "::0060", conf => < "permissions override OWNER, GROUP, MODE", + desc => "permissions OWNER, GROUP, MODE", subsys => "tty", devpath => "/class/tty/ttyUSB0", exp_name => "ttyUSB0", @@ -1336,7 +1185,9 @@ open CONF, ">$main_conf" || die "unable to create config file: $main_conf"; print CONF "udev_root=\"$udev_root\"\n"; print CONF "udev_db=\"$udev_db\"\n"; print CONF "udev_rules=\"$conf_tmp\"\n"; -print CONF "udev_permissions=\"$perm\"\n"; +print CONF "default_mode=\"0600\"\n"; +print CONF "default_owner=\"root\"\n"; +print CONF "default_group=\"root\"\n"; close CONF; my $test_num = 1; diff --git a/test/udev.permissions b/test/udev.permissions deleted file mode 100644 index b7baeea7b4..0000000000 --- a/test/udev.permissions +++ /dev/null @@ -1,22 +0,0 @@ -#name:user:group:mode -ttyUSB0:root:uucp:0660 -ttyUSB1:root:uucp:0666 -visor:500:500:0666 -dsp1:::0666 -boot_disk?:::0666 - -#used for permissions tests in udev-test.pl -tty0::root:0444 -tty1:root::0555 -tty2:::0777 -tty3::: -rtc:0:6:0770 -misc/*:0:users:0600 -i2c-fake1:root:7:0007 -i2c*:root:sys:0744 -ttyS[01]:0:5:0700 -ttyS[5-9]:root:5:0060 -tty4::tty:0707 -tty4?::tty:0007 -tty3[!3]:::0467 -tty33:bad:name:0500 -- cgit v1.2.3-54-g00ecf