mirror of
https://gitlab.com/apparmor/apparmor
synced 2025-08-30 05:47:59 +00:00
Create wip conditional policy
parent
b52327a5e0
commit
82ff9e0b4a
31
wip-conditional-policy.md
Normal file
31
wip-conditional-policy.md
Normal file
@ -0,0 +1,31 @@
|
||||
Ideas around how to structure policy to make it easy to conditionally enable/disable via a GUI.
|
||||
|
||||
```
|
||||
profile example {
|
||||
|
||||
include <conditional_camera>
|
||||
include <conditional_microphone>
|
||||
|
||||
}
|
||||
```
|
||||
|
||||
conditional_camera
|
||||
```
|
||||
# ??? some syntax to declare a dependency on $allow_camera, making it a user defined var ...
|
||||
|
||||
if $allow_camera {
|
||||
include <camera>
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
camera
|
||||
```
|
||||
# set meta data for the rules
|
||||
tag=camera {
|
||||
# regular rules
|
||||
}
|
||||
```
|
||||
|
||||
|
||||
??? hrmmm how to handle hot plug udev devices better
|
Loading…
x
Reference in New Issue
Block a user