unbound icon indicating copy to clipboard operation
unbound copied to clipboard

[FR] Introduce libunbound-control library for external consumers

Open rcmcdonald91 opened this issue 1 year ago • 2 comments

Current behavior Currently all the business logic for unbound-control is self-contained within unbound-control.c.

Describe the desired feature Break out this core functionality into a shared library (say libunbound-control) and reimplement unbound-control in terms of this library.

Potential use-case The ability for external consumers to link against libunbound-control and communicate with Unbound in a variety of ways.


We should also start a conversation about the design of this library. My initial thought is to start moving functionality from unbound-control into libunbound. I don't think we strictly need another library when we already have libunbound and the requisite build infrastructure.

rcmcdonald91 avatar Apr 26 '24 18:04 rcmcdonald91

I have a functional PoC

One thing that I would like is to be able to recycle the connection, SSL context between requests. Any advice here would be most welcomed. It doesn't look like daemon/remote.c is able to handle this.

rcmcdonald91 avatar Apr 29 '24 18:04 rcmcdonald91

https://github.com/NLnetLabs/unbound/pull/1058

rcmcdonald91 avatar Apr 29 '24 21:04 rcmcdonald91