Is there direct php extension to ubus

Hello I'm rewriting php website that sits on OpenWRT.

Is there native extension to php that would enable efficient communiaction with ubus/uci.

My current approach is sanitization and system command, which is not ideal.

Thanks you in advance.

You can post to ubus web api

Hey, thanks for answering.
Can you clarify? Is it like post-ing to localhost ubus web api?
Are talking about rpcd ? or something else

Where can I find it?

1 Like
1 Like

Hey thanks for answering and sorry for the delay. For now I will mark your answer as solution but it is not ideal for me, as it requires to run 2 servers at the same time (uhttpd and light) and I didn't see ubus there (I think it can be added thou).

There is luci for nginx, probably you can transfer some ideas to lighthttpd.

That would be ideal, but I already have lighttpd-php server and website (both are extensive, hard to transfer over) ,so I cannot resigne from this duo.

Maybe it is time to create php extension for ubus

Nothing can stop you.