Skip to content

Commit c26381f

Browse files
Thadeu Lima de Souza Cascardokuba-moo
authored andcommitted
nfc: virtual_ncidev: change default device permissions
Device permissions is S_IALLUGO, with many unnecessary bits. Remove them and also remove read and write permissions from group and others. Before the change: crwsrwsrwt 1 0 0 10, 125 Nov 25 13:59 /dev/virtual_nci After the change: crw------- 1 0 0 10, 125 Nov 25 14:05 /dev/virtual_nci Signed-off-by: Thadeu Lima de Souza Cascardo <cascardo@canonical.com> Reviewed-by: Krzysztof Kozlowski <krzysztof.kozlowski@canonical.com> Reviewed-by: Bongsu Jeon <bongsu.jeon@samsung.com> Link: https://lore.kernel.org/r/20211125141457.716921-1-cascardo@canonical.com Signed-off-by: Jakub Kicinski <kuba@kernel.org>
1 parent de6d259 commit c26381f

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

drivers/nfc/virtual_ncidev.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -202,7 +202,7 @@ static int __init virtual_ncidev_init(void)
202202
miscdev.minor = MISC_DYNAMIC_MINOR;
203203
miscdev.name = "virtual_nci";
204204
miscdev.fops = &virtual_ncidev_fops;
205-
miscdev.mode = S_IALLUGO;
205+
miscdev.mode = 0600;
206206

207207
return misc_register(&miscdev);
208208
}

0 commit comments

Comments
 (0)