Skip to content

Commit ad816f6

Browse files
[AutoPR- Security] Patch avahi for CVE-2026-24401 [MEDIUM] (microsoft#15580)
1 parent c326e08 commit ad816f6

File tree

2 files changed

+80
-1
lines changed

2 files changed

+80
-1
lines changed

SPECS/avahi/CVE-2026-24401.patch

Lines changed: 75 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,75 @@
1+
From 319fe039124f393a947686119ea3eafdc39d4008 Mon Sep 17 00:00:00 2001
2+
From: Hugo Muis <198191869+friendlyhugo@users.noreply.github.com>
3+
Date: Sun, 2 Mar 2025 18:06:24 +0100
4+
Subject: [PATCH] core: fix uncontrolled recursion bug using a simple loop
5+
detection algorithm
6+
7+
Closes https://github.com/avahi/avahi/issues/501
8+
9+
Signed-off-by: Azure Linux Security Servicing Account <azurelinux-security@microsoft.com>
10+
Upstream-reference: https://github.com/avahi/avahi/commit/78eab31128479f06e30beb8c1cbf99dd921e2524.patch
11+
---
12+
avahi-core/browse.c | 40 ++++++++++++++++++++++++++++++++++++++++
13+
1 file changed, 40 insertions(+)
14+
15+
diff --git a/avahi-core/browse.c b/avahi-core/browse.c
16+
index 57435fc..d7d541b 100644
17+
--- a/avahi-core/browse.c
18+
+++ b/avahi-core/browse.c
19+
@@ -400,6 +400,40 @@ static int lookup_go(AvahiSRBLookup *l) {
20+
return n;
21+
}
22+
23+
+static int lookup_exists_in_path(AvahiSRBLookup* lookup, AvahiSRBLookup* from, AvahiSRBLookup* to) {
24+
+ AvahiRList* rl;
25+
+ if (from == to)
26+
+ return 0;
27+
+ for (rl = from->cname_lookups; rl; rl = rl->rlist_next) {
28+
+ int r = lookup_exists_in_path(lookup, rl->data, to);
29+
+ if (r == 1) {
30+
+ /* loop detected, propagate result */
31+
+ return r;
32+
+ } else if (r == 0) {
33+
+ /* is loop detected? */
34+
+ return lookup == from;
35+
+ } else {
36+
+ /* `to` not found, continue */
37+
+ continue;
38+
+ }
39+
+ }
40+
+ /* no path found */
41+
+ return -1;
42+
+}
43+
+
44+
+static int cname_would_create_loop(AvahiSRBLookup* l, AvahiSRBLookup* n) {
45+
+ int ret;
46+
+ if (l == n)
47+
+ /* Loop to self */
48+
+ return 1;
49+
+
50+
+ ret = lookup_exists_in_path(n, l->record_browser->root_lookup, l);
51+
+
52+
+ /* Path to n always exists */
53+
+ assert(ret != -1);
54+
+ return ret;
55+
+}
56+
+
57+
static void lookup_handle_cname(AvahiSRBLookup *l, AvahiIfIndex interface, AvahiProtocol protocol, AvahiLookupFlags flags, AvahiRecord *r) {
58+
AvahiKey *k;
59+
AvahiSRBLookup *n;
60+
@@ -419,6 +453,12 @@ static void lookup_handle_cname(AvahiSRBLookup *l, AvahiIfIndex interface, Avahi
61+
return;
62+
}
63+
64+
+ if (cname_would_create_loop(l, n)) {
65+
+ /* CNAME loops are not allowed */
66+
+ lookup_unref(n);
67+
+ return;
68+
+ }
69+
+
70+
l->cname_lookups = avahi_rlist_prepend(l->cname_lookups, lookup_ref(n));
71+
72+
lookup_go(n);
73+
--
74+
2.45.4
75+

SPECS/avahi/avahi.spec

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -3,7 +3,7 @@
33
Summary: Local network service discovery
44
Name: avahi
55
Version: 0.8
6-
Release: 6%{?dist}
6+
Release: 7%{?dist}
77
License: LGPLv2+
88
Vendor: Microsoft Corporation
99
Distribution: Azure Linux
@@ -22,6 +22,7 @@ Patch9: CVE-2024-52616.patch
2222
Patch10: CVE-2025-68276.patch
2323
Patch11: CVE-2025-68468.patch
2424
Patch12: CVE-2025-68471.patch
25+
Patch13: CVE-2026-24401.patch
2526
BuildRequires: automake
2627
BuildRequires: dbus-devel >= 0.90
2728
BuildRequires: dbus-glib-devel >= 0.70
@@ -429,6 +430,9 @@ exit 0
429430
%endif
430431

431432
%changelog
433+
* Tue Jan 27 2026 Azure Linux Security Servicing Account <azurelinux-security@microsoft.com> - 0.8-7
434+
- Patch for CVE-2026-24401
435+
432436
* Wed Jan 14 2026 Azure Linux Security Servicing Account <azurelinux-security@microsoft.com> - 0.8-6
433437
- Patch for CVE-2025-68471, CVE-2025-68276, CVE-2025-68468
434438

0 commit comments

Comments
 (0)