Commit graph

122 commits

Author SHA1 Message Date
W.C.A. Wijngaards
812d8f71e8 dnstap io, ssl write. 2020-02-05 15:04:04 +01:00
W.C.A. Wijngaards
5b117c851a dnstap io, ssl handshake. 2020-02-05 13:59:56 +01:00
W.C.A. Wijngaards
e5d43a6f4e dnstap io, close fd routine. 2020-02-05 13:03:58 +01:00
W.C.A. Wijngaards
9f7a16c7ab dnstap io, ssl and ssl ctx creation. 2020-02-04 17:23:19 +01:00
W.C.A. Wijngaards
1420d59949 dnstap io, connect and write over TCP. 2020-01-31 17:07:40 +01:00
W.C.A. Wijngaards
27a5239ccf dnstap unbound-dnstap-sock, comments and log output on tls error close. 2020-01-31 14:13:41 +01:00
W.C.A. Wijngaards
dc31cf3652 dnstap unbound-dnstap-sock, read from TLS. 2020-01-31 14:03:28 +01:00
W.C.A. Wijngaards
03db238a51 dnstap unbound-dnstap-sock, verbose accepted stream IP addresses 2020-01-31 13:05:06 +01:00
W.C.A. Wijngaards
8d2ff8a6bf dnstap unbound-dnstap-sock, add -t option. 2020-01-31 11:18:14 +01:00
W.C.A. Wijngaards
b912169f15 dnstap unbound-dnstap-sock, fixup check for ssl context create error. 2020-01-31 11:11:43 +01:00
W.C.A. Wijngaards
473783e432 dnstap unbound-dnstap-sock, tls options and context created. 2020-01-31 11:10:04 +01:00
W.C.A. Wijngaards
59136055b9 dnstap unbound-dnstap-sock, fixup constant defines. 2020-01-31 10:05:00 +01:00
W.C.A. Wijngaards
70b2c24a4e dnstap unbound-dnstap-sock, fixup signal handler exit. 2020-01-31 10:02:51 +01:00
W.C.A. Wijngaards
11e80ce3ab dnstap unbound-dnstap-sock, can listen to multiple sockets, can listen
to TCP sockets, cleans up on exit after signal.
2020-01-31 09:53:49 +01:00
W.C.A. Wijngaards
a8264065f6 - put fstrm protocol contents in separate files, dnstap_fstrm.c
and dnstap_fstrm.h
2020-01-30 17:11:07 +01:00
W.C.A. Wijngaards
fa49fc77e3 fix dnstap io for lock checks, log identity (numworkers+1), and add locks
around protected area modification in the message queue.
2020-01-30 13:39:31 +01:00
W.C.A. Wijngaards
ba49524708 dnstap socket tool better help text. 2020-01-30 13:10:29 +01:00
W.C.A. Wijngaards
0248872938 dnstap io, move setup with nothreads into its own routine. 2020-01-29 16:31:33 +01:00
W.C.A. Wijngaards
565b3ef8cb dnstap io, fix compile warning when compiled with threading enabled. 2020-01-29 16:22:32 +01:00
W.C.A. Wijngaards
1e4165d25b dnstap io, without threads, logs from the main event loop. 2020-01-28 15:51:39 +01:00
W.C.A. Wijngaards
989922631a dnstap io, fix exit when compiled without threads. 2020-01-28 15:09:21 +01:00
W.C.A. Wijngaards
e13675d6cb dnstap io, windows portability improvements. 2020-01-28 14:24:14 +01:00
W.C.A. Wijngaards
bb81684206 dnstap io, fix memory leak if dnstap queue full. 2020-01-28 12:48:36 +01:00
W.C.A. Wijngaards
b3bf416888 dnstap io, fix for msg queue cleanup and make test. 2020-01-28 12:46:08 +01:00
W.C.A. Wijngaards
cf5aa85f29 dnstap io, nicer layout for wouldblock calls. 2020-01-23 16:51:57 +01:00
W.C.A. Wijngaards
8f2f004778 dnstap io, fix event reference in winevent wouldblock call. 2020-01-23 16:49:44 +01:00
W.C.A. Wijngaards
874c349b44 dnstap io, remove --with-libfstrm, it is not required to build dnstap
support. protobuf-c is still used for handling the dnstap encoding.
2020-01-23 15:56:12 +01:00
W.C.A. Wijngaards
4c64c4b78e dnstap io, remove libfstrm calls from dnstap.c. 2020-01-23 15:49:36 +01:00
W.C.A. Wijngaards
1042134eec dnstap io, failure to add event closes and attempts to reopen the output. 2020-01-23 15:39:27 +01:00
W.C.A. Wijngaards
b33df3cc63 in stop flush use timer_del to remove timer. 2020-01-23 15:17:43 +01:00
W.C.A. Wijngaards
299086d447 dnstap io, reconnect attempts with exponential backoff to once per second. 2020-01-23 15:11:08 +01:00
W.C.A. Wijngaards
86e1948afe dnstap io, fixup error exit of event add routines. 2020-01-23 13:38:10 +01:00
W.C.A. Wijngaards
8c47d16e29 dnstap io, sleeps thread when there is no traffic. 2020-01-23 13:27:21 +01:00
W.C.A. Wijngaards
c0f410f721 dnstap io, make sure to free current message when stream closes. 2020-01-23 11:51:10 +01:00
W.C.A. Wijngaards
29fdcf0c71 loop in output callback for performance. 2020-01-23 11:44:32 +01:00
W.C.A. Wijngaards
e7d5a89ae2 check close neater also with a write at the same time. 2020-01-23 11:16:41 +01:00
W.C.A. Wijngaards
24536473d8 dnstap io: check for close of channel by the other side. 2020-01-23 11:07:30 +01:00
W.C.A. Wijngaards
14d7658897 dtio_find_msg loop roundrobin instead of first queue only, with
state in the dtio struct for loop iterator.
2020-01-23 10:34:38 +01:00
W.C.A. Wijngaards
e9772b609e dnstap io fixup socket creation, stop flush dtio pointer, connect reports. 2020-01-23 09:55:15 +01:00
W.C.A. Wijngaards
569cccea24 dnstap io output performs nonblocking connect. 2020-01-22 17:41:34 +01:00
W.C.A. Wijngaards
814a886354 output event del before free. 2020-01-22 15:26:04 +01:00
W.C.A. Wijngaards
a21ac9838d write data and stop flush for dnstap io. 2020-01-22 15:20:48 +01:00
W.C.A. Wijngaards
3cc1f4a74e remove fatal_exit from runtime reopen routines. 2020-01-22 12:05:52 +01:00
W.C.A. Wijngaards
6fb602d57b improve fstrm routine documentation. 2020-01-22 11:57:15 +01:00
W.C.A. Wijngaards
9f2ac374f4 fstrm routines for start and stop, fstrm_create_control_frame_start and
fstrm_create_control_frame_stop, suitable for reuse, together with fstrm
protocol defines.
2020-01-22 11:44:11 +01:00
W.C.A. Wijngaards
3e7758ee58 Remove editor file that was added by mistake. 2020-01-21 17:15:37 +01:00
W.C.A. Wijngaards
351e0e6986 iothread find msg. 2020-01-21 17:14:47 +01:00
W.C.A. Wijngaards
efc79beb2d iothread work. 2020-01-21 17:01:25 +01:00
W.C.A. Wijngaards
57ad169605 the framestream queue. 2020-01-21 14:50:37 +01:00
W.C.A. Wijngaards
bb55cc1685 dnstap unit test. 2020-01-21 14:02:45 +01:00
W.C.A. Wijngaards
ade0ba63ff dnstap test program prints messages and timestamps in long format. 2020-01-21 10:14:30 +01:00
W.C.A. Wijngaards
7bddf97450 dnstap test program prints identity and version. 2020-01-21 09:56:28 +01:00
W.C.A. Wijngaards
ac362625c3 dnstap test progam can log on one line type,ip,qname,qtype,qclass 2020-01-20 17:23:01 +01:00
W.C.A. Wijngaards
90a9de9d52 unbound-dnstap-socket debug test program. 2020-01-20 15:45:31 +01:00
W.C.A. Wijngaards
9285e10fef iolist item added. 2020-01-20 12:12:27 +01:00
W.C.A. Wijngaards
c6534ac6b3 Writeup of FrameStreams protocol. 2020-01-20 11:44:45 +01:00
W.C.A. Wijngaards
b7e08045b1 git branch to track feature for framestreams. The aim is to make
reconnecting work, TLS support and not depend on the libfstrm library,
but keep compatibility with the Frame Streams protocol spec for
existing DNSTAP tools.
2020-01-20 11:04:06 +01:00
Wouter Wijngaards
6bd4060ae0 portability.
git-svn-id: file:///svn/unbound/trunk@4944 be551aaa-1e26-0410-a405-d3ace91eadb9
2018-10-22 10:19:30 +00:00
Wouter Wijngaards
84a8415357 - check that the dnstap socket file can be opened and exists, print
error if not.


git-svn-id: file:///svn/unbound/trunk@4943 be551aaa-1e26-0410-a405-d3ace91eadb9
2018-10-22 10:17:38 +00:00
Wouter Wijngaards
bf6f33ceaf - Fix #3451: dnstap not building when you have a separate build dir.
And removed protoc warning, set dnstap.proto syntax to proto2.


git-svn-id: file:///svn/unbound/trunk@4508 be551aaa-1e26-0410-a405-d3ace91eadb9
2018-02-05 12:14:51 +00:00
Wouter Wijngaards
86dcdaae33 - Fix dnstap for warning of set but not used.
git-svn-id: file:///svn/unbound/trunk@4007 be551aaa-1e26-0410-a405-d3ace91eadb9
2017-02-10 08:26:59 +00:00
Wouter Wijngaards
2958b53293 - Fix dnstap-log-resolver-response-messages, from Nikolay Edigaryev.
git-svn-id: file:///svn/unbound/trunk@3684 be551aaa-1e26-0410-a405-d3ace91eadb9
2016-03-21 09:04:21 +00:00
Wouter Wijngaards
8c2a28adbc - Fix #741: log message for dnstap socket connection is more clear.
git-svn-id: file:///svn/unbound/trunk@3612 be551aaa-1e26-0410-a405-d3ace91eadb9
2016-01-27 17:12:26 +00:00
Wouter Wijngaards
152458c40b - spelling fixes from Igor Sobrado Delgado.
git-svn-id: file:///svn/unbound/trunk@3544 be551aaa-1e26-0410-a405-d3ace91eadb9
2015-11-18 14:11:46 +00:00
Wouter Wijngaards
b2bdce46be - rename ldns subdirectory to sldns to avoid name collision.
git-svn-id: file:///svn/unbound/trunk@3380 be551aaa-1e26-0410-a405-d3ace91eadb9
2015-03-26 10:21:38 +00:00
Wouter Wijngaards
e3843bd0b6 remove unused variable
git-svn-id: file:///svn/unbound/trunk@3255 be551aaa-1e26-0410-a405-d3ace91eadb9
2014-11-07 09:09:37 +00:00
Wouter Wijngaards
818650efae - dnstap fixes by Robert Edmonds:
dnstap/dnstap.m4: cosmetic fixes
	dnstap/: Remove compiled protoc-c output files
	dnstap/dnstap.m4: Error out if required libraries are not found
	dnstap: Fix ProtobufCBufferSimple usage that is incorrect as of
		protobuf-c 1.0.0
	dnstap/: Adapt to API changes in latest libfstrm (>= 0.2.0)


git-svn-id: file:///svn/unbound/trunk@3254 be551aaa-1e26-0410-a405-d3ace91eadb9
2014-11-07 09:09:04 +00:00
Wouter Wijngaards
a2bcf1d2ec spelling fix.
git-svn-id: file:///svn/unbound/trunk@3219 be551aaa-1e26-0410-a405-d3ace91eadb9
2014-08-25 13:53:30 +00:00
Wouter Wijngaards
3390cc15c7 If we find protobuf in /usr/local then also set -L to there.
git-svn-id: file:///svn/unbound/trunk@3218 be551aaa-1e26-0410-a405-d3ace91eadb9
2014-08-25 13:17:53 +00:00
Wouter Wijngaards
595d40aad5 - Removed necessity for pkg-config from the dnstap.m4, new are
the --with-libfstrm and --with-protobuf-c configure options.


git-svn-id: file:///svn/unbound/trunk@3216 be551aaa-1e26-0410-a405-d3ace91eadb9
2014-08-25 13:04:32 +00:00
Wouter Wijngaards
aa9a1721cc Fixup for dnstap.
git-svn-id: file:///svn/unbound/trunk@3209 be551aaa-1e26-0410-a405-d3ace91eadb9
2014-08-18 14:42:26 +00:00
Wouter Wijngaards
8ccba42b1f - dnstap support, with a patch from Farsight Security, written by
Robert Edmonds. The --enable-dnstap needs libfstrm and protobuf-c.
  It is BSD licensed (see dnstap/dnstap.c).
  Building with --enable-dnstap needs pkg-config with this patch.
- Noted dnstap in doc/README and doc/CREDITS.


git-svn-id: file:///svn/unbound/trunk@3206 be551aaa-1e26-0410-a405-d3ace91eadb9
2014-08-05 07:57:52 +00:00