Re: libkvm usage on FreeBSD

Bart Van Assche via Net-snmp-coders <[email protected]> Fri, 12 Apr 2024 07:13:41 -0700
Newsgroups gmane.network.net-snmp.devel
Message-ID <[email protected]>
On 4/12/24 06:44, Mark Johnston wrote:
> I would like to introduce the patch below, which gets compiled when
> --without-kmem-usage is specified.  In this case, snmpd will still use
> libkvm, but won't open /dev/(k)mem.  In my testing so far, this works
> perfectly.  Does anyone have any thoughts on this patch/approach?  Would
> the net-snmp project be willing to accept the patch?  Thank you in
> advance for any feedback or guidance.

What privileges are required to call kvm_open() on FreeBSD? Are
the same privileges required as for opening /dev/kmem or not? If not,
has it been considered to make init_kmem() call kvm_open() on FreeBSD
independent of whether or not --without-kmem-usage has been specified?

Thanks,

Bart.