One Hat Cyber Team
Your IP :
216.73.216.178
Server IP :
178.162.244.166
Server :
Linux flexi.hostpinnacleservers.com 5.14.0-611.30.1.el9_7.x86_64 #1 SMP PREEMPT_DYNAMIC Wed Feb 11 06:42:00 EST 2026 x86_64
Server Software :
Apache
PHP Version :
8.1.34
Buat File
|
Buat Folder
Eksekusi
Dir :
~
/
usr
/
share
/
wireplumber
/
scripts
/
access
/
View File Name :
access-default.lua
-- WirePlumber -- -- Copyright © 2021 Collabora Ltd. -- @author George Kiagiadakis <george.kiagiadakis@collabora.com> -- -- SPDX-License-Identifier: MIT local config = ... or {} -- preprocess rules and create Interest objects for _, r in ipairs(config.rules or {}) do r.interests = {} for _, i in ipairs(r.matches) do local interest_desc = { type = "properties" } for _, c in ipairs(i) do c.type = "pw" table.insert(interest_desc, Constraint(c)) end local interest = Interest(interest_desc) table.insert(r.interests, interest) end r.matches = nil end function rulesGetDefaultPermissions(properties) for _, r in ipairs(config.rules or {}) do if r.default_permissions then for _, interest in ipairs(r.interests) do if interest:matches(properties) then return r.default_permissions end end end end end clients_om = ObjectManager { Interest { type = "client" } } clients_om:connect("object-added", function (om, client) local id = client["bound-id"] local properties = client["properties"] local perms = rulesGetDefaultPermissions(properties) if perms then Log.info(client, "Granting permissions to client " .. id .. ": " .. perms) client:update_permissions { ["any"] = perms } end end) clients_om:activate()