Sandbox APP can't use pppd

#1

We encountered a project that needed to use the following code for PPPD dialing。

code:
system("/usr/sbin/pppd /dev/ttyHS0 19200 192.168.244.4:192.168.244.3 noauth local noipdefault");

But it doesn’t seem to work properly in a sandbox.

Here is the error log:

Apr 28 08:46:16 | mqtt_v21_converter[9066]/MQTT_V21_ConverterComponent T=3 | VM_PPP.c VM_PPP_Task() 119 | read port buff:CLIENTSERVER
Apr 28 08:46:17 | mqtt_v21_converter[9066]/MQTT_V21_ConverterComponent T=4 | VM_PPP.c SendClient() 37 | SendClient End
Apr 28 08:46:18 | mqtt_v21_converter[9066]/MQTT_V21_ConverterComponent T=4 | VM_PPP.c PPPConnect() 42 | PPPConnect
Apr 28 16:46:18 | mqtt_v21_converter[9066] | | Segmentation fault (core dumped)
Apr 28 16:46:18 | mqtt_v21_converter[9066] | | 19200
Apr 28 16:46:18 | mqtt_v21_converter[9066] | | /usr/sbin/pppd: using the noauth option requires root privilege
Apr 28 16:46:23 | mqtt_v21_converter[9066] | | VmiDriver_CallbackECMFunc
Apr 28 16:46:23 | mqtt_v21_converter[9066] | | TRIG_LINKUP

It seems that PPPD dialing requires ROOT privileges. How can I use PPPD to dial in the APP configured as sandboxed: true?

Besides, will sandbox affect other modules ?
For example socket or http etc.

#2

The simplest approach is change your application to “unsandboxed”, otherwise you need create a new unsandboxed app and put pppd into that app.