tcpdump mailing list archives

Re: RFC: a loadable plugin framework for external capture backends


From: Guy Harris <gharris () sonic net>
Date: Mon, 12 Oct 2026 03:39:48 -0700

On Oct 12, 2026, at 2:19 AM, Robin Jarry via tcpdump-workers <tcpdump-workers () lists tcpdump org> wrote:

However, I don't know if sharing an anonymous ring-buffer [1] in memory is possible with all backends that libpcap 
supports (is there file descriptor sharing over SCM_RIGHTS [2] on windows?).

No, but there are other mechanisms by which one process can pass a HANDLE (the Windows equivalent of a UNIX file 
descriptor) to another process.

CreateFileMapping() creates a "file mapping object" and, if passed INVALID_HANDLE_VALUE as the "HANDLE for the file to 
map", the object refers to anonymous (swap-space backed rather than file-backed) memory. and DuplicateHandle() can, as 
far as I know, pass the HANDLE for the file mapping object to another process to map the shared memory into its address 
space, just as the process creating the object can use it to map the shared memory into its address space.

There could be different options to allow sharing over POSIX shared memory segments [3].

On UN*Xes with support for either System V or POSIX shared memory segments, those are, I suspect, backed by swap space.

I can't speak for Haiku, the GNU Hurd with GNU Mach, or QNX.
_______________________________________________
tcpdump-workers mailing list -- tcpdump-workers () lists tcpdump org
To unsubscribe send an email to tcpdump-workers-leave () lists tcpdump org
%(web_page_url)slistinfo%(cgiext)s/%(_internal_name)s

Current thread: