2 # The following are some default rules for devfs(5) mounts.
3 # The format is very simple. Empty lines and lines beginning
4 # with a hash '#' are ignored. If the hash mark occurs anywhere
5 # other than the beginning of a line, it and any subsequent
6 # characters will be ignored. A line in between brackets '[]'
7 # denotes the beginning of a ruleset. In the brackets should
8 # be a name for the rule and its ruleset number. Any other lines
9 # will be considered to be the 'action' part of a rule
10 # passed to the devfs(8) command. These will be passed
11 # "as-is" to the devfs(8) command with the exception that
12 # any references to other rulesets will be expanded first. These
13 # references must include a dollar sign '$' in front of the
14 # name to be expanded properly.
19 # Very basic and secure ruleset: Hide everything.
20 # Used as a basis for other rules.
22 [devfsrules_hide_all=1]
25 # Basic devices typically necessary.
26 # Requires: devfsrules_hide_all
28 [devfsrules_unhide_basic=2]
32 add path crypto unhide
33 add path random unhide
34 add path urandom unhide
36 # Devices typically needed to support logged-in users.
37 # Requires: devfsrules_hide_all
39 [devfsrules_unhide_login=3]
40 add path 'ptyp*' unhide
41 add path 'ptyq*' unhide
42 add path 'ptyr*' unhide
43 add path 'ptys*' unhide
44 add path 'ptyP*' unhide
45 add path 'ptyQ*' unhide
46 add path 'ptyR*' unhide
47 add path 'ptyS*' unhide
48 add path 'ptyl*' unhide
49 add path 'ptym*' unhide
50 add path 'ptyn*' unhide
51 add path 'ptyo*' unhide
52 add path 'ptyL*' unhide
53 add path 'ptyM*' unhide
54 add path 'ptyN*' unhide
55 add path 'ptyO*' unhide
56 add path 'ttyp*' unhide
57 add path 'ttyq*' unhide
58 add path 'ttyr*' unhide
59 add path 'ttys*' unhide
60 add path 'ttyP*' unhide
61 add path 'ttyQ*' unhide
62 add path 'ttyR*' unhide
63 add path 'ttyS*' unhide
64 add path 'ttyl*' unhide
65 add path 'ttym*' unhide
66 add path 'ttyn*' unhide
67 add path 'ttyo*' unhide
68 add path 'ttyL*' unhide
69 add path 'ttyM*' unhide
70 add path 'ttyN*' unhide
71 add path 'ttyO*' unhide
74 add path 'pts/*' unhide
76 add path 'fd/*' unhide
78 add path stdout unhide
79 add path stderr unhide
81 # Devices usually found in a jail.
84 add include $devfsrules_hide_all
85 add include $devfsrules_unhide_basic
86 add include $devfsrules_unhide_login