Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DNSTap #114

Open
loe opened this issue Dec 13, 2022 · 10 comments
Open

DNSTap #114

loe opened this issue Dec 13, 2022 · 10 comments
Labels
enhancement New feature or request

Comments

@loe
Copy link

loe commented Dec 13, 2022

Thoughts on an alternate build with it enabled? Drags in some dependencies, so not advocating for it as the default.

@klutchell
Copy link
Owner

What additional dependencies would it require?

@loe
Copy link
Author

loe commented Dec 14, 2022

It depends on protobuf and fstrm.

https://dnstap.info/Source/

@klutchell
Copy link
Owner

I will have to look into this since we are using the official buildroot recipe for unbound. I would probably rather upstream this as a buildroot option rather than maintain another patch.

@loe
Copy link
Author

loe commented Dec 20, 2022

I'm not familiar with how options work for buildroot, but the components are all included in the source distribution for unbound. Its an option in the configure script, --enable-dnstap more details in the documentation "DNSTAP Logging Options" section.

@klutchell
Copy link
Owner

klutchell commented Dec 21, 2022

We can look into adding a new config option in here and see if the buildroot maintainers accept it.
https://github.com/buildroot/buildroot/blob/master/package/unbound/unbound.mk

eg.

ifeq ($(BR2_PACKAGE_UNBOUND_DNSTAP),y)
UNBOUND_CONF_OPTS += --enable-dnstap
UNBOUND_DEPENDENCIES += fstrm
UNBOUND_DEPENDENCIES += protobuf-c
else
UNBOUND_CONF_OPTS += --disable-dnstap
endif

There would also need to be some additional dependencies added in here
https://github.com/buildroot/buildroot/blob/master/package/unbound/Config.in
eg.

if BR2_PACKAGE_UNBOUND
config BR2_PACKAGE_UNBOUND_DNSTAP
	bool "enable dnstap"
	select BR2_PACKAGE_FSTRM
	select BR2_PACKAGE_PROTOBUF_C
	help
	  dnstap is a flexible, structured binary log format for
	  DNS software.

	  https://dnstap.info/

	  It uses Protocol Buffers to encode events that occur
	  inside DNS software in an implementation-neutral format.

	  dnstap logging starts an extra thread that writes the log
	  information to the destination.
endif

@klutchell
Copy link
Owner

There does not appear to be an fstrm package in buildroot, so we would need to make a whole new package for that as well.

@klutchell klutchell added the enhancement New feature or request label Dec 26, 2022
@klutchell
Copy link
Owner

I have a PR that removes the dependency on buildroot: #143

If that PR becomes viable, and I merge it, then the changes above could be added directly to the Dockerfile.

@klutchell
Copy link
Owner

The current main branch now builds from sources without buildroot, so feel free to open a PR with the additional DNSTap dependencies and we will see how much size it adds to the image.

@klutchell
Copy link
Owner

@loe is this still something you are interested in?

@loe
Copy link
Author

loe commented Aug 24, 2023

@loe is this still something you are interested in?

I'll look into it - still interested, would love to know where my traffic is going!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
enhancement New feature or request
Projects
None yet
Development

No branches or pull requests

2 participants