Your message dated Sun, 08 Nov 2026 21:25:47 +0000
with message-id <[email protected]>
and subject line Bug#1138586: fixed in minidlna 1.3.3+dfsg-2
has caused the Debian Bug report #1138586,
regarding minidlna: segfault in select_del due to missing guard against
double-close of HTTP socket
to be marked as done.
This means that you claim that the problem has been dealt with.
If this is not the case it is now your responsibility to reopen the
Bug report if necessary, and/or fix the problem forthwith.
(NB: If you are a system administrator and have no idea what this
message is talking about, this may indicate a serious mail system
misconfiguration somewhere. Please contact [email protected]
immediately.)
--
1138586: https://bugs.debian.org/cgi-bin/bugreport.cgi?bug=1138586
Debian Bug Tracking System
Contact [email protected] with problems
--- Begin Message ---
Package: minidlna
Version: 1.3.3+dfsg-1.1+b1
Severity: important
From: [email protected] <mailto:[email protected]>
Dear Maintainer,
MiniDLNA crashes with a segmentation fault (SIGSEGV) during media file
playback. The crash is reproducible and occurs while serving media files to
DLNA clients. It manifests as a complete server crash, interrupting active
playback sessions.
-- Symptoms --
The minidlnad process crashes with signal 11 (SIGSEGV) while serving a media
file via HTTP. The crash appears during or after sending a response to a client
HEAD or GET request for a media item. The systemd journal shows a core dump:
Signal: 11 (SEGV)
Process: minidlnad
-- Stack trace (obtained by compiling with debug symbols using
DEB_BUILD_OPTIONS="nostrip noopt") --
#0 select_del (ev=0x..., flags=1) at ./select.c:135
ev0 = 0x184 <- corrupted pointer (not a valid address)
#1 CloseSocket_upnphttp (h=0x...) at ./upnphttp.c:126
#2 SendResp_dlnafile (h=0x..., object="7536.mkv") at ./upnphttp.c:2121
#3 ProcessHttpQuery_upnphttp (h=0x...) at ./upnphttp.c:1015
#4 Process_upnphttp (ev=0x...) at ./upnphttp.c:1145
#5 select_process (tv=0x...) at ./select.c:177
#6 main (argc=7, argv=0x...) at ./minidlna.c:1315
-- Root cause --
There are two related bugs:
Bug 1: CloseSocket_upnphttp() in upnphttp.c has no guard against being called
on an already-closed socket (h->ev.fd < 0). It can be called multiple times on
the same struct upnphttp from different code paths. Note that Delete_upnphttp()
-- which wraps CloseSocket_upnphttp() -- already correctly checks h->ev.fd >= 0
before calling it, but the guard is missing inside CloseSocket_upnphttp()
itself.
Bug 2: select_del() in select.c has no guard against being called on an
already-deleted event (ev->index < 0). When CloseSocket_upnphttp() is called on
an already-closed socket, ev->index is -1 (set during the first deletion). The
condition (-1 < --nevents) evaluates to true, causing:
- events[-1] = ev0 -- writes before the events array (memory corruption)
- ev0->index = -1 -- corrupts a valid active event's index
Over subsequent connections this leads to events[nevents] containing a garbage
value (observed: 0x184) which is then dereferenced, causing the SIGSEGV.
-- Fix --
upnphttp.c -- add guard at the start of CloseSocket_upnphttp():
void
CloseSocket_upnphttp(struct upnphttp * h)
{
if(h->ev.fd < 0) /* already closed, avoid double-delete */
return;
event_module.del(&h->ev, EV_FLAG_CLOSING);
if(close(h->ev.fd) < 0)
{
DPRINTF(E_ERROR, L_HTTP, "CloseSocket_upnphttp: close(%d): %s\n", h->ev.fd,
strerror(errno));
}
h->ev.fd = -1;
h->state = 100;
}
select.c -- add guard at the start of select_del(), before the existing
assert():
static int
select_del(struct event *ev, int flags)
{
if(ev->index < 0) /* already deleted, avoid double-delete */
return (0);
assert(ev->fd < FD_SETSIZE);
...
}
The guard in select_del must be placed BEFORE the assert(ev->fd < FD_SETSIZE)
to prevent the assert from firing on an invalid fd value.
-- Verification --
After applying both fixes and recompiling with debug symbols, the crash no
longer
occurs during playback. The fix has been tested on Debian Trixie 13.5 amd64 with
minidlna 1.3.3+dfsg-1.1, serving MKV files to a Samsung Series CDE DLNA client.
-- Note --
This bug is present in all current Debian builds of minidlna:
stable: 1.3.3+dfsg-1.1+b1
testing: 1.3.3+dfsg-1.1+b2
unstable: 1.3.3+dfsg-1.1+b2
These are binary-only rebuilds of the same unfixed source. The fix should also
be reported upstream to the ReadyMedia/MiniDLNA project at:
https://sourceforge.net/p/minidlna/bugs/
-- System information --
Debian GNU/Linux 13 (Trixie) 13.5, amd64
minidlna 1.3.3+dfsg-1.1+b1
Linux brix2
Regards,
Tamas Kohegyi
--- End Message ---
--- Begin Message ---
Source: minidlna
Source-Version: 1.3.3+dfsg-2
Done: Alexander GQ Gerasiov <[email protected]>
We believe that the bug you reported is fixed in the latest version of
minidlna, which is due to be installed in the Debian FTP archive.
A summary of the changes between this version and the previous one is
attached.
Thank you for reporting the bug, which will now be closed. If you
have further comments please address them to [email protected],
and the maintainer will reopen the bug report if appropriate.
Debian distribution maintenance software
pp.
Alexander GQ Gerasiov <[email protected]> (supplier of updated minidlna package)
(This message was generated automatically at their request; if you
believe that there is a problem with it please contact the archive
administrators by mailing [email protected])
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA512
Format: 1.8
Date: Sun, 08 Nov 2026 22:17:04 +0200
Source: minidlna
Architecture: source
Version: 1.3.3+dfsg-2
Distribution: unstable
Urgency: high
Maintainer: Alexander GQ Gerasiov <[email protected]>
Changed-By: Alexander GQ Gerasiov <[email protected]>
Closes: 989828 1081948 1138586 1144655 1153446
Changes:
minidlna (1.3.3+dfsg-2) unstable; urgency=high
.
[ Barak A. Pearlmutter ]
* Update standards version to 4.7.0, no changes needed.
* patch for deletion race condition (closes: #1081948) many thanks
to Simon Tatham <[email protected]>
.
[ Luca Boccassi ]
* Install and use sysusers.d/tmpfiles.d config files
.
[ Alexander Gerasiov ]
* d/patches: Fix DFF parser memory safety issues (CVE-2026-29508).
Thanks to Sumit Verma (Closes: #1153446)
* d/patches: Do not abort on UPnP unsubscribe during notify connect.
(Closes: #1144655)
* d/patches: Fix select_del() crash in forked HTTP children.
(Closes: #989828, #1138586)
* d/patches: Fix FTBFS on GNU/Hurd.
* debian/minidlna.init: Create cache directory if missing.
* debian/copyright: Do not list COPYING license file.
* debian/copyright: Move DFSG repack explanation to Comment field.
* d/patches: Fix DSF parser division by zero and huge allocation.
* debian/minidlna.service: Fix man page section, restart on failure.
* debian/control: Add pkgconf to Build-Depends.
* Bump Standards-Version to 4.7.2, no changes needed.
* debian/copyright: Update packaging copyright years.
* Remove debian/minidlna.postinst.
* debian/rules: Take OS version from dpkg-vendor.
* debian/minidlna.init: Use the pidfile for status.
* debian/minidlna.conf.5: Fix wording, typos and wrong defaults.
Checksums-Sha1:
34266c09ca5b3152d3e3fad16aa2ce883035ca8e 2354 minidlna_1.3.3+dfsg-2.dsc
e90538bd33b23792b5af1ae0c8e6626c6002194a 36564
minidlna_1.3.3+dfsg-2.debian.tar.xz
601da25e47e8524cd48f4971c8bc29da2752da56 691944
minidlna_1.3.3+dfsg-2.git.tar.xz
6f263859499e3cdaa0769f305a970aea407cdc3d 17761
minidlna_1.3.3+dfsg-2_source.buildinfo
Checksums-Sha256:
e06ab497c31d06f495b3e21ec3afdfb1374dbc76b903abcea2473bf60bae59b4 2354
minidlna_1.3.3+dfsg-2.dsc
48608ce97810e77bf2baeaebb696a412b5439493812f45c616f1eb486a44f398 36564
minidlna_1.3.3+dfsg-2.debian.tar.xz
30a3fa9d6ea32bf325122096c48c8f1534e16eef27b49fa1dc02bb2c8f75f8fe 691944
minidlna_1.3.3+dfsg-2.git.tar.xz
629de6c0594b6e90e89095cfa9859c04afb636eafa4c465154610c7c1bbbefab 17761
minidlna_1.3.3+dfsg-2_source.buildinfo
Files:
657b8ffed2d51590b46b737f87d041b6 2354 net optional minidlna_1.3.3+dfsg-2.dsc
ebeb40b9c77386ec449a5d691c30d0ea 36564 net optional
minidlna_1.3.3+dfsg-2.debian.tar.xz
eb68a1a026e82c8d73f2498600bda035 691944 net optional
minidlna_1.3.3+dfsg-2.git.tar.xz
3a1101b65d67e090c5b0b7a3bc7b9c3e 17761 net optional
minidlna_1.3.3+dfsg-2_source.buildinfo
Git-Tag-Info: tag=742839717c893f4e36f7c286cb25f89c006a41af
fp=04b59d90df7cc2abcd49baeaca87e9e82aac33f1
Git-Tag-Tagger: Alexander Gerasiov <[email protected]>
-----BEGIN PGP SIGNATURE-----
iQIzBAEBCgAdFiEEN02M5NuW6cvUwJcqYG0ITkaDwHkFAmrw3swACgkQYG0ITkaD
wHmbCxAAiALzsF8pj3zG0ZZF7Rxb6w7J8eVKdB3sYG4msEEFNSQIIkqEe3Q/DDil
k7pYGGW6n3stkPIiaKc+70Kv4MCxAiG1IUr+VgxniCsH5GSggAp26HUEbfQRCUm8
8r04BCm5a+Nn0XpoQPLI+Cb8cqGFfevhf76FbWkISLi1zLbYm0ugC6mACX8d7CsT
P/tna1fEAbr7hyw2AC4d9Ow4aa8n6HYVEr5xhriillaw3MGuvgXAjMqo6lZFxHY0
79EW9kRR8zNLyGMBrlWDgJCkwPtfJpPdxVaDHzp+t5qSoXzvxiitXuV3D1tSvGSa
dO494mnl8NwRngCPPgNJVE9TgeWe6sQUdiMK4O+yiypDEOjdA0ceGgOaTYHWBBDE
YE7BYsmuyRkOsp38jkRrYAjySTrgwpCifrd+2Hkw1uBgcwalR5Z0BjnTMTt5ndGk
eNeLpeYCKoe9NZHSXEK8D8O+w1XUSqLPXb0GVKwr6Cb5EteQTcSdRyWxQ1lYKJZS
KcOpJlafRFeUB9KC7OdXTaagMKDzKZ1pW4mOzoIdrXf+MPdQL7yqmptb09uO95gf
TKE99ZeVuqmnDZMSj9xb9OaBkHFQg3ukskh5eSEgGP7NoxfbOgtjgHHnMr13o0HF
CeLqQHKPHLOOPeFuqyKdLwT02ClXG8pm1dELSYWhShjN9igVErQ=
=w4MV
-----END PGP SIGNATURE-----
pgpjibYVwec5e.pgp
Description: PGP signature
--- End Message ---