Hide setup key from non-admin users (#539)

This commit is contained in:
Misha Bragin
2022-11-03 17:02:31 +01:00
committed by GitHub
parent 2e0bf61e9a
commit 6aa7a2c5e1
5 changed files with 48 additions and 12 deletions

View File

@ -214,8 +214,9 @@ func isBuiltinModule(name string) (bool, error) {
}
// /proc/modules
// name | memory size | reference count | references | state: <Live|Loading|Unloading>
// macvlan 28672 1 macvtap, Live 0x0000000000000000
//
// name | memory size | reference count | references | state: <Live|Loading|Unloading>
// macvlan 28672 1 macvtap, Live 0x0000000000000000
func moduleStatus(name string) (status, error) {
state := unknown
f, err := os.Open("/proc/modules")