mirror of
https://github.com/HEYAHONG/CoreBoard-001
synced 2025-05-08 18:39:51 +08:00
切换到系统级别的DBus,要求使用root用户启动ExtBoardD
This commit is contained in:
parent
fcfb330fde
commit
aa03cdb77f
15
FW/package/ExtBoard/files/etc/dbus-1/system.d/ExtBoardD.conf
Normal file
15
FW/package/ExtBoard/files/etc/dbus-1/system.d/ExtBoardD.conf
Normal file
@ -0,0 +1,15 @@
|
||||
<busconfig>
|
||||
|
||||
<!-- ../system.conf have denied everything, so we just punch some holes -->
|
||||
|
||||
<policy user="root">
|
||||
<allow own="ExtBoard.Deamon.Server"/>
|
||||
<allow send_destination="ExtBoard.Deamon.Server"/>
|
||||
<allow send_interface="ExtBoard.Deamon"/>
|
||||
</policy>
|
||||
|
||||
<policy context="default">
|
||||
<allow send_destination="ExtBoard.Deamon.Server"/>
|
||||
</policy>
|
||||
|
||||
</busconfig>
|
@ -28,7 +28,7 @@ void DbusInterface_Init()
|
||||
dispatcher=DBus::StandaloneDispatcher::create();
|
||||
if(dispatcher != nullptr)
|
||||
{
|
||||
con=dispatcher->create_connection(DBus::BusType::SESSION);
|
||||
con=dispatcher->create_connection(DBus::BusType::SYSTEM);
|
||||
}
|
||||
|
||||
if(con == nullptr)
|
||||
|
Loading…
x
Reference in New Issue
Block a user