Commit 9666ef7
committed
fix(roles/openvpn_server): use etc_t for file labels on RHEL 10
The SELinux type `openvpn_etc_t` was removed from the RHEL 10 core
policy; only `openvpn_port_t` and the packet types remain. Setting
`setype: openvpn_etc_t` on `server.p12` / `crl.pem` therefore failed
with `invalid selinux context: [Errno 22] Invalid argument`.
Introduce an OS-specific internal variable
`__openvpn_server__selinux_etc_type` (default `openvpn_etc_t`,
overridden to `etc_t` on RHEL 10) and parameterize both `setype:`
assignments. On RHEL 10, `etc_t` is the appropriate default label
since openvpn runs unconfined (no `openvpn_t` domain) there.
Also mark `openvpn_server` as RHEL 10 compatible in COMPATIBILITY.md.1 parent ce22b63 commit 9666ef7
5 files changed
Lines changed: 14 additions & 3 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
25 | 25 | | |
26 | 26 | | |
27 | 27 | | |
| 28 | + | |
28 | 29 | | |
29 | 30 | | |
30 | 31 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
122 | 122 | | |
123 | 123 | | |
124 | 124 | | |
125 | | - | |
| 125 | + | |
126 | 126 | | |
127 | 127 | | |
128 | 128 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| 2 | + | |
| 3 | + | |
| 4 | + | |
| 5 | + | |
| 6 | + | |
| 7 | + | |
| 8 | + | |
1 | 9 | | |
2 | 10 | | |
3 | 11 | | |
| |||
60 | 68 | | |
61 | 69 | | |
62 | 70 | | |
63 | | - | |
| 71 | + | |
64 | 72 | | |
65 | 73 | | |
66 | 74 | | |
| |||
93 | 101 | | |
94 | 102 | | |
95 | 103 | | |
96 | | - | |
| 104 | + | |
97 | 105 | | |
98 | 106 | | |
99 | 107 | | |
| |||
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
| 1 | + | |
0 commit comments