Compare commits

...
Sign in to create a new pull request.

69 commits

Author SHA1 Message Date
Fedora Release Engineering
68dfe36cf9 Rebuilt for https://fedoraproject.org/wiki/Fedora_44_Mass_Rebuild 2026-01-16 04:11:15 +00:00
Petr Menšík
b19244db41 Fix fortify_source detected issue in test
Prevent crash stopped by fortification source hardening. Make it
compiled with new defaults.

https://github.com/avahi/avahi/pull/707
2025-08-05 16:13:02 +02:00
Petr Menšík
9391e1eeb3 Require systemd-devel 2025-08-05 16:12:47 +02:00
Petr Menšík
4738e71dd5 Fix randomization of DNS source port in wide area (CVE-2024-52615)
https://github.com/avahi/avahi/pull/662
2025-08-05 16:11:17 +02:00
Fedora Release Engineering
c167401b13 Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild 2025-07-23 17:29:07 +00:00
Zbigniew Jędrzejewski-Szmek
9f7c403b66 Also create sysusers.d config file for the avahi-autoipd user
Two files are needed because the second second user is for a subpackage.
I missed the second user in the first sweep.
2025-04-14 16:44:43 +02:00
Zbigniew Jędrzejewski-Szmek
0068914251 Add sysusers.d config file to allow rpm to create users/groups automatically 2025-01-29 14:32:34 +01:00
Michal Sekletar
dd144f1100 Fix previous changelog entry
%changelog entries must start with *
2025-01-16 18:58:41 +01:00
Michal Sekletar
2858c1b8d7 Rebase to v0.9-rc2
Resolves: #1392924, #2262378, #1356304, #1540180, #2338453
2025-01-16 18:36:16 +01:00
Fedora Release Engineering
94ef8a637d Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild 2025-01-16 12:03:16 +00:00
Michal Sekletar
23aab0f744 Fix file attributes of /run/avahi-daemon
Resolves: rhbz#1608918
2024-08-21 17:02:54 +02:00
Michal Sekletar
7ba6797b77 tests: couple of fixlets for got-audit test case 2024-08-06 16:32:01 +02:00
Gordon Messmer
439702e4fa Examine the server process GOT for signs of tampering. 2024-08-01 15:41:57 -07:00
Fedora Release Engineering
9cbffbccff Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild 2024-07-17 17:53:49 +00:00
Michal Sekletar
e53a1dcbb8 Add build dependency on gettext-devel 2024-04-04 19:25:41 +02:00
Fedora Release Engineering
acf24e6f23 Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild 2024-01-22 23:55:22 +00:00
Fedora Release Engineering
8be6b6a654 Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild 2024-01-19 13:59:12 +00:00
Lukáš Zaoral
a328cd9a38
migrate to SPDX license format 2023-07-31 11:57:18 +02:00
Fedora Release Engineering
224aade90b Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2023-07-19 14:12:24 +00:00
Tomas Popela
13b4bfb1e7 Drop BR on dbus-glib as the project is not using it at all 2023-05-10 14:53:13 +02:00
Petr Menšík
e8ad0f7bbb Enable few unit tests during build
Upstream contains some unit tests, but they have to be explicitly
enabled during configure. Enable them and run them during check phase.
2023-04-01 19:04:16 +02:00
Petr Menšík
df02cf92b5 Correct bootstrap option
Some tools moved from python dependency to tools, but they broken option
to make the build without UI tools.
2023-04-01 19:03:05 +02:00
Petr Menšík
e9b6c7fb60 Provide versioned howl compatibility package
Fixes rpmlint warning.
2023-04-01 19:00:51 +02:00
Petr Menšík
0596791a38 Prevent crashes on some invalid DBus calls 2023-04-01 19:00:50 +02:00
Yaakov Selkowitz
edb7728055 Disable GTK2 in ELN/RHEL10 builds
gtk2 is unwanted in ELN and RHEL 10.
2023-03-19 01:17:49 -04:00
Yaakov Selkowitz
17e7177680 Fix flatpak build 2023-01-23 15:41:28 +00:00
Fedora Release Engineering
fc2e2af422 Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2023-01-18 22:31:08 +00:00
Petr Menšík
bfe1212eb6 Add upstream PR links to patches
Removes some warnings in spec as well.
2022-11-11 01:26:43 +01:00
Christian Krause
f29dc51363 Fix installed files in avahi-ui-tools
- Install glade file for avahi-discover-standalone unconditionally
  (fixes #2036073 and #2126721)
- Install desktop files for bssh and bsvn unconditionally
2022-11-01 21:30:01 +01:00
Kalev Lember
3d83a9f66e Avoid systemd_requires as per updated packaging guidelines
There is no need to have them as systemd correctly handles reloading
depending on the transaction ordering (even if systemd is installed
_after_ the package that installs the unit file).
2022-08-05 12:01:19 +02:00
Fedora Release Engineering
4d3ba397b1 Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2022-07-20 21:37:04 +00:00
Fedora Release Engineering
3245ce6e58 - Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2022-01-19 21:59:40 +00:00
Marie Loise Nolden
3e16de6326 Update avahi.spec 2021-12-22 06:25:56 +00:00
Rex Dieter
2ad878bdde revert "Re-enable LTO" on f34 (still needed) 2021-08-03 11:01:20 -05:00
Rex Dieter
bee2e8d2f1 pull in upstream fix for CVE-2021-36217 (#1989381,#1989382) 2021-08-03 10:24:11 -05:00
Fedora Release Engineering
7a071ce071 - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2021-07-21 18:15:54 +00:00
Fedora Release Engineering
c4e0beb057 - Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2021-07-21 13:19:46 +00:00
Jeff Law
64bffa7f65 - Re-enable LTO 2021-05-10 08:44:09 -06:00
Rex Dieter
ab36315347 changelog typo 2021-04-29 16:28:26 -05:00
Rex Dieter
f4b4f57d27 avahi libraries missing -fstack-protector-stong (#1817737) 2021-04-29 16:27:59 -05:00
Zbigniew Jędrzejewski-Szmek
b14dda007b Rebuilt for updated systemd-rpm-macros
See https://pagure.io/fesco/issue/2583.
2021-03-02 16:14:10 +01:00
Rex Dieter
c71132b246 disable lto, workaround FTBFS (#1907727) 2021-02-16 11:43:42 -06:00
Rex Dieter
865aa4c0e4 cleanup/fix conditionals (#1751484)
flip defaults (to off) for deprecated items: Qt3, Qt4, Python(2)
2021-02-16 10:06:28 -06:00
Fedora Release Engineering
74c72f25ef - Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2021-01-26 00:48:31 +00:00
Tom Stellard
29b5438f14 Add BuildRequires: make
https://fedoraproject.org/wiki/Changes/Remove_make_from_BuildRoot
2020-12-17 02:37:33 +00:00
Rex Dieter
dd53bfdcda fix undefined symbols in libavahi-qt3 (#1897925) 2020-11-17 16:54:27 -06:00
Rex Dieter
4ae18a0168 Release++, +changelog 2020-10-15 11:53:28 -05:00
Rex Dieter
d8904eb58e resurrect ui-tools, not just for python (#1885513) 2020-10-15 11:32:12 -05:00
Michal Sekletar
2c08e02ed6 Disable bootstrap 2020-09-21 16:06:43 +02:00
Michal Sekletar
1fc220f76d Enable bootstrap 2020-09-21 13:59:15 +02:00
Michal Sekletar
178fd0a306 Make possible to bootstrap build w/o GTK and Qt5 2020-09-21 13:57:58 +02:00
Fedora Release Engineering
2500cac704 - Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2020-07-27 12:46:16 +00:00
Stephen Gallagher
d48b042164
Minor conditional tweaks for ELN
Signed-off-by: Stephen Gallagher <sgallagh@redhat.com>
2020-05-05 14:34:42 -04:00
Rex Dieter
29acccc4aa pull in some upstream fixes 2020-03-22 19:48:28 -05:00
Lubomir Rintel
eb82c89c94 Update to release 0.8
- Dropped the patch for the functionality equivalent to what has been done
  upstream in avahi.git commit 2fd76baeb829 ("Listen on loopback interfaces").
- Added Qt5
- Adjusted for upstream flipping QT3 and QT4 to default off
- Packaged the libevent library
2020-03-22 19:24:08 +01:00
Petr Viktorin
cbce6b24de Don't BuildRequire pygtk2 if building without Python 2020-02-20 13:05:31 +01:00
Fedora Release Engineering
09c496e9c0 - Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2020-01-28 12:32:09 +00:00
Rex Dieter
9ec1238048 Release++ 2019-09-19 17:07:54 -05:00
Rex Dieter
8d87c1f62b drop python bindings/support (includes -ui-tools that use the bindings) on f31+ (#1751484) 2019-09-19 17:07:00 -05:00
Miro Hrončok
a311802c04 Rebuilt for Python 3.8 2019-08-19 10:10:21 +02:00
Fedora Release Engineering
7c9c0f2d38 - Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2019-07-24 18:52:14 +00:00
Michal Sekletar
ae12454f63 Add support for advertising services on the local machine only
This patch is not merged upstream yet. However, Ubuntu is already
shipping it. Let's merge it to Fedora too so ippusbxd (which depends on
this functionality) can get packaged to Fedora.

https://github.com/lathiat/avahi/issues/125
https://github.com/lathiat/avahi/pull/161
2019-02-22 11:05:46 +01:00
Kalev Lember
21c3d90854 Update requires for pygobject3 -> python2-gobject rename 2019-02-04 09:28:22 +01:00
Fedora Release Engineering
7a6630006b - Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2019-01-31 14:14:38 +00:00
Adam Williamson
63dfef7216 Update python3 sed hack to avoid '/usr/bin/python32' dep
In F28 and earlier /usr/bin/python exists during the build, and
the build process decides PYTHON is /usr/bin/python, so this
sed command works. In F29+ /usr/bin/python does not exist during
the build, so the build process decides /usr/bin/python2 is
PYTHON, and when we do 's!/usr/bin/python!/usr/bin/python3!', we
wind up with /usr/bin/python32...which is not what we wanted.
So, let's fix that.
2018-07-30 15:39:38 -07:00
Jan Grulich
fed0baaeba Requires: tigervnc
Tigervnc removed old obsoleted provides
2018-07-24 09:21:08 +02:00
Fedora Release Engineering
a52f80289e - Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
Signed-off-by: Fedora Release Engineering <releng@fedoraproject.org>
2018-07-12 20:49:50 +00:00
Miro Hrončok
034b3d4556 Rebuilt for Python 3.7 2018-06-19 10:40:04 +02:00
Serhii Turivnyi
1f0b377b18 Add CI tests using the standard test interface 2018-04-11 12:51:53 +03:00
18 changed files with 1000 additions and 111 deletions

1
.fmf/version Normal file
View file

@ -0,0 +1 @@
1

2
.gitignore vendored
View file

@ -5,3 +5,5 @@
/avahi-0.6.31.tar.gz
/avahi-0.6.32.tar.gz
/avahi-0.7.tar.gz
/avahi-0.8.tar.gz
/v0.9-rc2.tar.gz

View file

@ -0,0 +1,31 @@
diff --git a/avahi-qt/Makefile.am b/avahi-qt/Makefile.am
index b404810..6911db8 100644
--- a/avahi-qt/Makefile.am
+++ b/avahi-qt/Makefile.am
@@ -40,7 +40,7 @@ qt-watch.moc3: qt-watch.cpp
libavahi_qt3_la_CPPFLAGS = $(AM_CFLAGS) $(QT3_CFLAGS) -DQT3 $(VISIBILITY_HIDDEN_CFLAGS)
libavahi_qt3_la_LIBADD = $(AM_LDADD) ../avahi-common/libavahi-common.la $(QT3_LIBS)
-libavahi_qt3_la_LDFLAGS = $(AM_LDFLAGS) -export-dynamic -version-info $(LIBAVAHI_QT3_VERSION_INFO)
+libavahi_qt3_la_LDFLAGS = $(AM_LDFLAGS) -Wl,--no-undefined -no-undefined -export-dynamic -version-info $(LIBAVAHI_QT3_VERSION_INFO)
endif
if HAVE_QT4
@@ -62,7 +62,7 @@ qt-watch.moc4: qt-watch.cpp
libavahi_qt4_la_CPPFLAGS = $(AM_CFLAGS) $(QT4_CFLAGS) -DQT4 $(VISIBILITY_HIDDEN_CFLAGS)
libavahi_qt4_la_LIBADD = $(AM_LDADD) ../avahi-common/libavahi-common.la $(QT4_LIBS)
-libavahi_qt4_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(LIBAVAHI_QT4_VERSION_INFO)
+libavahi_qt4_la_LDFLAGS = $(AM_LDFLAGS) -Wl,--no-undefined -no-undefined -version-info $(LIBAVAHI_QT4_VERSION_INFO)
endif
if HAVE_QT5
@@ -84,7 +84,7 @@ qt-watch.moc5: qt-watch.cpp
libavahi_qt5_la_CPPFLAGS = $(AM_CFLAGS) --std=gnu++11 $(QT5_CFLAGS) -DQT5 $(VISIBILITY_HIDDEN_CFLAGS)
libavahi_qt5_la_LIBADD = $(AM_LDADD) ../avahi-common/libavahi-common.la $(QT5_LIBS)
-libavahi_qt5_la_LDFLAGS = $(AM_LDFLAGS) -version-info $(LIBAVAHI_QT5_VERSION_INFO)
+libavahi_qt5_la_LDFLAGS = $(AM_LDFLAGS) -Wl,--no-undefined -no-undefined -version-info $(LIBAVAHI_QT5_VERSION_INFO)
endif
CLEANFILES = $(BUILT_SOURCES)

View file

@ -0,0 +1,224 @@
From 4e2e1ea0908d7e6ad7f38ae04fdcdf2411f8b942 Mon Sep 17 00:00:00 2001
From: Michal Sekletar <msekleta@redhat.com>
Date: Wed, 27 Nov 2024 18:07:32 +0100
Subject: [PATCH] core/wide-area: fix for CVE-2024-52615
---
avahi-core/wide-area.c | 128 ++++++++++++++++++++++-------------------
1 file changed, 69 insertions(+), 59 deletions(-)
diff --git a/avahi-core/wide-area.c b/avahi-core/wide-area.c
index 00a15056e..06df7afc6 100644
--- a/avahi-core/wide-area.c
+++ b/avahi-core/wide-area.c
@@ -81,6 +81,10 @@ struct AvahiWideAreaLookup {
AvahiAddress dns_server_used;
+ int fd;
+ AvahiWatch *watch;
+ AvahiProtocol proto;
+
AVAHI_LLIST_FIELDS(AvahiWideAreaLookup, lookups);
AVAHI_LLIST_FIELDS(AvahiWideAreaLookup, by_key);
};
@@ -88,9 +92,6 @@ struct AvahiWideAreaLookup {
struct AvahiWideAreaLookupEngine {
AvahiServer *server;
- int fd_ipv4, fd_ipv6;
- AvahiWatch *watch_ipv4, *watch_ipv6;
-
/* Cache */
AVAHI_LLIST_HEAD(AvahiWideAreaCacheEntry, cache);
AvahiHashmap *cache_by_key;
@@ -125,35 +126,67 @@ static AvahiWideAreaLookup* find_lookup(AvahiWideAreaLookupEngine *e, uint16_t i
return l;
}
+static void socket_event(AVAHI_GCC_UNUSED AvahiWatch *w, int fd, AVAHI_GCC_UNUSED AvahiWatchEvent events, void *userdata);
+
static int send_to_dns_server(AvahiWideAreaLookup *l, AvahiDnsPacket *p) {
+ AvahiWideAreaLookupEngine *e;
AvahiAddress *a;
+ AvahiServer *s;
+ AvahiWatch *w;
+ int r;
assert(l);
assert(p);
- if (l->engine->n_dns_servers <= 0)
+ e = l->engine;
+ assert(e);
+
+ s = e->server;
+ assert(s);
+
+ if (e->n_dns_servers <= 0)
return -1;
- assert(l->engine->current_dns_server < l->engine->n_dns_servers);
+ assert(e->current_dns_server < e->n_dns_servers);
- a = &l->engine->dns_servers[l->engine->current_dns_server];
+ a = &e->dns_servers[e->current_dns_server];
l->dns_server_used = *a;
- if (a->proto == AVAHI_PROTO_INET) {
+ if (l->fd >= 0) {
+ /* We are reusing lookup object and sending packet to another server so let's cleanup before we establish connection to new server. */
+ s->poll_api->watch_free(l->watch);
+ l->watch = NULL;
- if (l->engine->fd_ipv4 < 0)
- return -1;
+ close(l->fd);
+ l->fd = -EBADF;
+ }
- return avahi_send_dns_packet_ipv4(l->engine->fd_ipv4, AVAHI_IF_UNSPEC, p, NULL, &a->data.ipv4, AVAHI_DNS_PORT);
+ assert(a->proto == AVAHI_PROTO_INET || a->proto == AVAHI_PROTO_INET6);
- } else {
- assert(a->proto == AVAHI_PROTO_INET6);
+ if (a->proto == AVAHI_PROTO_INET)
+ r = s->config.use_ipv4 ? avahi_open_unicast_socket_ipv4() : -1;
+ else
+ r = s->config.use_ipv6 ? avahi_open_unicast_socket_ipv6() : -1;
- if (l->engine->fd_ipv6 < 0)
- return -1;
+ if (r < 0) {
+ avahi_log_error(__FILE__ ": Failed to create socket for wide area lookup");
+ return -1;
+ }
- return avahi_send_dns_packet_ipv6(l->engine->fd_ipv6, AVAHI_IF_UNSPEC, p, NULL, &a->data.ipv6, AVAHI_DNS_PORT);
+ w = s->poll_api->watch_new(s->poll_api, r, AVAHI_WATCH_IN, socket_event, l);
+ if (!w) {
+ close(r);
+ avahi_log_error(__FILE__ ": Failed to create socket watch for wide area lookup");
+ return -1;
}
+
+ l->fd = r;
+ l->watch = w;
+ l->proto = a->proto;
+
+ return a->proto == AVAHI_PROTO_INET ?
+ avahi_send_dns_packet_ipv4(l->fd, AVAHI_IF_UNSPEC, p, NULL, &a->data.ipv4, AVAHI_DNS_PORT):
+ avahi_send_dns_packet_ipv6(l->fd, AVAHI_IF_UNSPEC, p, NULL, &a->data.ipv6, AVAHI_DNS_PORT);
}
static void next_dns_server(AvahiWideAreaLookupEngine *e) {
@@ -246,6 +279,9 @@ AvahiWideAreaLookup *avahi_wide_area_lookup_new(
l->dead = 0;
l->key = avahi_key_ref(key);
l->cname_key = avahi_key_new_cname(l->key);
+ l->fd = -EBADF;
+ l->watch = NULL;
+ l->proto = AVAHI_PROTO_UNSPEC;
l->callback = callback;
l->userdata = userdata;
@@ -314,6 +350,12 @@ static void lookup_destroy(AvahiWideAreaLookup *l) {
if (l->cname_key)
avahi_key_unref(l->cname_key);
+ if (l->watch)
+ l->engine->server->poll_api->watch_free(l->watch);
+
+ if (l->fd >= 0)
+ close(l->fd);
+
avahi_free(l);
}
@@ -572,14 +614,20 @@ static void handle_packet(AvahiWideAreaLookupEngine *e, AvahiDnsPacket *p) {
}
static void socket_event(AVAHI_GCC_UNUSED AvahiWatch *w, int fd, AVAHI_GCC_UNUSED AvahiWatchEvent events, void *userdata) {
- AvahiWideAreaLookupEngine *e = userdata;
+ AvahiWideAreaLookup *l = userdata;
+ AvahiWideAreaLookupEngine *e = l->engine;
AvahiDnsPacket *p = NULL;
- if (fd == e->fd_ipv4)
- p = avahi_recv_dns_packet_ipv4(e->fd_ipv4, NULL, NULL, NULL, NULL, NULL);
+ assert(l);
+ assert(e);
+ assert(l->fd == fd);
+
+ if (l->proto == AVAHI_PROTO_INET)
+ p = avahi_recv_dns_packet_ipv4(l->fd, NULL, NULL, NULL, NULL, NULL);
else {
- assert(fd == e->fd_ipv6);
- p = avahi_recv_dns_packet_ipv6(e->fd_ipv6, NULL, NULL, NULL, NULL, NULL);
+ assert(l->proto == AVAHI_PROTO_INET6);
+
+ p = avahi_recv_dns_packet_ipv6(l->fd, NULL, NULL, NULL, NULL, NULL);
}
if (p) {
@@ -598,32 +646,6 @@ AvahiWideAreaLookupEngine *avahi_wide_area_engine_new(AvahiServer *s) {
e->server = s;
e->cleanup_dead = 0;
- /* Create sockets */
- e->fd_ipv4 = s->config.use_ipv4 ? avahi_open_unicast_socket_ipv4() : -1;
- e->fd_ipv6 = s->config.use_ipv6 ? avahi_open_unicast_socket_ipv6() : -1;
-
- if (e->fd_ipv4 < 0 && e->fd_ipv6 < 0) {
- avahi_log_error(__FILE__": Failed to create wide area sockets: %s", strerror(errno));
-
- if (e->fd_ipv6 >= 0)
- close(e->fd_ipv6);
-
- if (e->fd_ipv4 >= 0)
- close(e->fd_ipv4);
-
- avahi_free(e);
- return NULL;
- }
-
- /* Create watches */
-
- e->watch_ipv4 = e->watch_ipv6 = NULL;
-
- if (e->fd_ipv4 >= 0)
- e->watch_ipv4 = s->poll_api->watch_new(e->server->poll_api, e->fd_ipv4, AVAHI_WATCH_IN, socket_event, e);
- if (e->fd_ipv6 >= 0)
- e->watch_ipv6 = s->poll_api->watch_new(e->server->poll_api, e->fd_ipv6, AVAHI_WATCH_IN, socket_event, e);
-
e->n_dns_servers = e->current_dns_server = 0;
/* Initialize cache */
@@ -651,18 +673,6 @@ void avahi_wide_area_engine_free(AvahiWideAreaLookupEngine *e) {
avahi_hashmap_free(e->lookups_by_id);
avahi_hashmap_free(e->lookups_by_key);
- if (e->watch_ipv4)
- e->server->poll_api->watch_free(e->watch_ipv4);
-
- if (e->watch_ipv6)
- e->server->poll_api->watch_free(e->watch_ipv6);
-
- if (e->fd_ipv6 >= 0)
- close(e->fd_ipv6);
-
- if (e->fd_ipv4 >= 0)
- close(e->fd_ipv4);
-
avahi_free(e);
}
@@ -680,7 +690,7 @@ void avahi_wide_area_set_servers(AvahiWideAreaLookupEngine *e, const AvahiAddres
if (a) {
for (e->n_dns_servers = 0; n > 0 && e->n_dns_servers < AVAHI_WIDE_AREA_SERVERS_MAX; a++, n--)
- if ((a->proto == AVAHI_PROTO_INET && e->fd_ipv4 >= 0) || (a->proto == AVAHI_PROTO_INET6 && e->fd_ipv6 >= 0))
+ if (a->proto == AVAHI_PROTO_INET || a->proto == AVAHI_PROTO_INET6)
e->dns_servers[e->n_dns_servers++] = *a;
} else {
assert(n == 0);

View file

@ -0,0 +1,30 @@
From 358e5a3b0122b418614e2ac0fc71f6aad1de06f8 Mon Sep 17 00:00:00 2001
From: Michal Sekletar <msekleta@redhat.com>
Date: Mon, 23 Jun 2025 16:27:40 +0200
Subject: [PATCH] Make data member as big as IPv6 address
Unfortunately, recent FORTIFY_SOURCE hardening for inet_pton() can't
deal with our type independent "data[1]" union member trick.
Fixes #699
---
avahi-common/address.h | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/avahi-common/address.h b/avahi-common/address.h
index a14104fad..013fa975e 100644
--- a/avahi-common/address.h
+++ b/avahi-common/address.h
@@ -71,9 +71,9 @@ typedef struct AvahiAddress {
AvahiProtocol proto; /**< Address family */
union {
- AvahiIPv6Address ipv6; /**< Address when IPv6 */
- AvahiIPv4Address ipv4; /**< Address when IPv4 */
- uint8_t data[1]; /**< Type-independent data field */
+ AvahiIPv6Address ipv6; /**< Address when IPv6 */
+ AvahiIPv4Address ipv4; /**< Address when IPv4 */
+ uint8_t data[sizeof(AvahiIPv6Address)]; /**< Type-independent data field */
} data;
} AvahiAddress;

View file

@ -1,21 +1,53 @@
%bcond_with bootstrap
%bcond_without check
%if %{without bootstrap}
%{?!WITH_MONO: %global WITH_MONO 1}
%else
%{?!WITH_MONO: %global WITH_MONO 0}
%endif
%{?!WITH_COMPAT_DNSSD: %global WITH_COMPAT_DNSSD 1}
%{?!WITH_COMPAT_HOWL: %global WITH_COMPAT_HOWL 1}
%{?!WITH_QT3: %global WITH_QT3 1}
%{?!WITH_QT4: %global WITH_QT4 1}
%{?!WITH_QT3: %global WITH_QT3 0}
%{?!WITH_QT4: %global WITH_QT4 0}
%if %{without bootstrap}
%{?!WITH_GTK2: %global WITH_GTK2 1}
%{?!WITH_GTK3: %global WITH_GTK3 1}
%{?!WITH_QT5: %global WITH_QT5 1}
%else
%{?!WITH_GTK2: %global WITH_GTK2 0}
%{?!WITH_GTK3: %global WITH_GTK3 0}
%{?!WITH_QT5: %global WITH_QT5 0}
%endif
# https://bugzilla.redhat.com/show_bug.cgi?id=1751484
%{?!WITH_PYTHON: %global WITH_PYTHON 0}
%ifnarch %{mono_arches}
%define WITH_MONO 0
%endif
%if 0%{?fedora}
%global WITH_QT3 1
%global WITH_QT4 1
%endif
%if 0%{?rhel}
%define WITH_MONO 0
%if 0%{?rhel} >= 6
%define WITH_QT4 0
%endif
%if 0%{?rhel} > 7
%define WITH_QT3 0
%endif
%if 0%{?rhel} > 9
%global WITH_GTK2 0
%endif
%global WITH_MONO 0
%global WITH_QT5 0
%if 0%{?rhel} < 8
%global WITH_PYTHON 1
%endif
%endif
%if 0%{?fedora} == 34 || 0%{?rhel} >= 9
# https://bugzilla.redhat.com/show_bug.cgi?id=1907727
%global _lto_cflags %{nil}
%endif
# http://bugzilla.redhat.com/1008395 - no hardened build
@ -24,24 +56,49 @@
# trim changelog included in binary rpms
%global _changelog_trimtime %(date +%s -d "1 year ago")
%define rc rc2
Name: avahi
Version: 0.7
Release: 12%{?dist}
Version: 0.9%{?rc:~%{rc}}
Release: 7%{?dist}
Summary: Local network service discovery
License: LGPLv2+
License: LGPL-2.1-or-later AND LGPL-2.0-or-later AND BSD-2-Clause-Views AND MIT
URL: http://avahi.org
Requires: dbus
Requires: expat
Requires: libdaemon >= 0.11
# For /usr/bin/dbus-send
Requires(post): dbus
Requires(pre): shadow-utils
Requires(pre): coreutils
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
BuildRequires: automake
BuildRequires: libtool
BuildRequires: dbus-devel >= 0.90
BuildRequires: dbus-glib-devel >= 0.70
BuildRequires: desktop-file-utils
%if %{WITH_GTK2}
BuildRequires: gtk2-devel
%endif
%if %{WITH_GTK3}
BuildRequires: gtk3-devel >= 2.99.0
%endif
#BuildRequires: gobject-introspection-devel
%if %{WITH_QT3}
BuildRequires: qt3-devel
%endif
%if %{WITH_QT4}
BuildRequires: qt4-devel
%endif
%if %{WITH_QT5}
BuildRequires: qt5-qtbase-devel
%endif
BuildRequires: libdaemon-devel >= 0.11
BuildRequires: glib2-devel
BuildRequires: libcap-devel
BuildRequires: expat-devel
%if %{WITH_PYTHON}
%if %{without bootstrap}
BuildRequires: pygtk2
%endif
%if 0%{?fedora} > 27
%global python2_dbus python2-dbus
%global python2_libxml2 python2-libxml2
@ -51,25 +108,16 @@ BuildRequires: dbus-glib-devel >= 0.70
%endif
BuildRequires: %{python2_dbus}
BuildRequires: %{python2_libxml2}
BuildRequires: desktop-file-utils
BuildRequires: gtk2-devel
BuildRequires: gtk3-devel >= 2.99.0
#BuildRequires: gobject-introspection-devel
%if %{WITH_QT3}
BuildRequires: qt3-devel
%endif
%if %{WITH_QT4}
BuildRequires: qt4-devel
%endif
BuildRequires: libdaemon-devel >= 0.11
BuildRequires: glib2-devel
BuildRequires: libcap-devel
BuildRequires: expat-devel
# really only need interpreter + rpm-macros -- rex
BuildRequires: python2-devel
BuildRequires: python3-devel
%else
Obsoletes: python2-avahi < %{version}-%{release}
Obsoletes: python3-avahi < %{version}-%{release}
%endif
BuildRequires: gdbm-devel
BuildRequires: pkgconfig(pygobject-3.0)
BuildRequires: pygtk2
BuildRequires: pkgconfig(libevent) >= 2.0.21
BuildRequires: intltool
BuildRequires: perl-XML-Parser
BuildRequires: xmltoman
@ -78,20 +126,26 @@ BuildRequires: mono-devel
BuildRequires: monodoc-devel
%endif
BuildRequires: systemd
%{?systemd_requires}
BuildRequires: systemd-devel
BuildRequires: gcc
BuildRequires: gcc-c++
BuildRequires: gettext-devel
%if 0%{?beta:1}
Source0: https://github.com/lathiat/avahi/archive/%{version}-%{beta}.tar.gz#/%{name}-%{version}-%{beta}.tar.gz
%if 0%{?rc:1}
Source0: https://github.com/avahi/avahi/archive/refs/tags/v%{version_no_tilde}.tar.gz
%else
Source0: https://github.com/lathiat/avahi/releases/download/v%{version}/avahi-%{version}.tar.gz
#Source0: http://avahi.org/download/avahi-%{version}.tar.gz
Source0: https://github.com/avahi/avahi/releases/download/v%{version_no_tilde}/%{name}-%{version_no_tilde}.tar.gz
%endif
## upstream patches
# https://github.com/avahi/avahi/pull/662
Patch1: avahi-0.9-CVE-2024-52615.patch
# https://github.com/avahi/avahi/pull/707
Patch2: avahi-0.9-address-data-size.patch
## downstream patches
Patch100: avahi-0.6.30-mono-libdir.patch
Patch100: avahi-0.6.30-mono-libdir.patch
Patch102: avahi-0.8-no_undefined.patch
%description
Avahi is a system which facilitates service discovery on
@ -116,15 +170,16 @@ Requires: %{name} = %{version}-%{release}
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
Requires: %{name}-glib%{?_isa} = %{version}-%{release}
Requires: %{name}-ui-gtk3%{?_isa} = %{version}-%{release}
Requires: python2-avahi = %{version}-%{release}
Requires: vnc
Requires: tigervnc
Requires: openssh-clients
%if %{WITH_PYTHON}
Requires: gdbm
Requires: pygtk2
Requires: pygtk2-libglade
Requires: gdbm
Requires: python2-avahi = %{version}-%{release}
Requires: %{python2_dbus}
# aka python2-gobject-base
Requires: pygobject3-base
Requires: python2-gobject-base
%endif
%description ui-tools
Graphical user interface tools that use Avahi to browse for mDNS services.
@ -158,12 +213,12 @@ This library contains a GObject wrapper for the Avahi API
Summary: Libraries and header files for Avahi GObject development
Requires: %{name}-devel%{?_isa} = %{version}-%{release}
Requires: %{name}-gobject%{?_isa} = %{version}-%{release}
#Requires: %{name}-glib-devel = %{version}-%{release}
%description gobject-devel
The avahi-gobject-devel package contains the header files and libraries
necessary for developing programs using avahi-gobject.
%if %{WITH_GTK2}
%package ui
Summary: Gtk user interface library for Avahi (Gtk+ 2 version)
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
@ -172,7 +227,9 @@ Requires: gtk2
%description ui
This library contains a Gtk 2.x widget for browsing services.
%endif
%if %{WITH_GTK3}
%package ui-gtk3
Summary: Gtk user interface library for Avahi (Gtk+ 3 version)
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
@ -181,17 +238,23 @@ Requires: gtk3
%description ui-gtk3
This library contains a Gtk 3.x widget for browsing services.
%endif
%if %{WITH_GTK2} || %{WITH_GTK3}
%package ui-devel
Summary: Libraries and header files for Avahi UI development
Requires: %{name}-devel%{?_isa} = %{version}-%{release}
%if %{WITH_GTK2}
Requires: %{name}-ui%{?_isa} = %{version}-%{release}
%endif
%if %{WITH_GTK3}
Requires: %{name}-ui-gtk3%{?_isa} = %{version}-%{release}
#Requires: %{name}-glib-devel = %{version}-%{release}
%endif
%description ui-devel
The avahi-ui-devel package contains the header files and libraries
necessary for developing programs using avahi-ui.
%endif
%if %{WITH_QT3}
%package qt3
@ -229,6 +292,24 @@ Th avahi-qt4-devel package contains the header files and libraries
necessary for developing programs using avahi with Qt4.
%endif
%if %{WITH_QT5}
%package qt5
Summary: Qt5 libraries for avahi
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
%description qt5
Libraries for easy use of avahi from Qt5 applications.
%package qt5-devel
Summary: Libraries and header files for avahi Qt5 development
Requires: %{name}-devel%{?_isa} = %{version}-%{release}
Requires: %{name}-qt5%{?_isa} = %{version}-%{release}
%description qt5-devel
Th avahi-qt5-devel package contains the header files and libraries
necessary for developing programs using avahi with Qt5.
%endif
%if %{WITH_MONO}
%package sharp
Summary: Mono language bindings for avahi mono development
@ -247,6 +328,7 @@ Requires: %{name}-sharp%{?_isa} = %{version}-%{release}
Requires: mono-core >= 1.1.13
Requires: gtk-sharp2
BuildRequires: gtk-sharp2-devel
BuildRequires: make
%description ui-sharp
The avahi-sharp package contains the files needed to run
@ -282,8 +364,8 @@ necessary for developing programs using avahi.
%package compat-howl
Summary: Libraries for howl compatibility
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
Obsoletes: howl-libs
Provides: howl-libs
Obsoletes: howl-libs < 0.6-16
Provides: howl-libs = %{version}-%{release}
%description compat-howl
Libraries that are compatible with those provided by the howl package.
@ -292,8 +374,8 @@ Libraries that are compatible with those provided by the howl package.
Summary: Header files for development with the howl compatibility libraries
Requires: %{name}-compat-howl%{?_isa} = %{version}-%{release}
Requires: %{name}-devel%{?_isa} = %{version}-%{release}
Obsoletes: howl-devel
Provides: howl-devel
Obsoletes: howl-devel < 0.6-16
Provides: howl-devel = %{version}-%{release}
%description compat-howl-devel
Header files for development with the howl compatibility libraries.
@ -319,7 +401,6 @@ libraries.
%package autoipd
Summary: Link-local IPv4 address automatic configuration daemon (IPv4LL)
Requires(pre): shadow-utils
Requires: %{name}-libs%{?_isa} = %{version}-%{release}
%description autoipd
@ -340,6 +421,7 @@ avahi-dnsconfd connects to a running avahi-daemon and runs the script
local LAN. This is useful for configuring unicast DNS servers in a DHCP-like
fashion with mDNS.
%if %{WITH_PYTHON}
%package -n python2-avahi
Summary: Python2 Avahi bindings
Obsoletes: python-avahi < 0.7
@ -357,18 +439,28 @@ Requires: %{name}-libs%{?_isa} = %{version}-%{release}
%description -n python3-avahi
%{summary}.
%endif
%prep
%autosetup -n %{name}-%{version}%{?beta:-%{beta}} -p1
%autosetup -n %{name}-%{version_no_tilde} -p1
rm -fv docs/INSTALL
# Create two sysusers.d config files
cat >avahi.sysusers.conf <<EOF
u avahi 70 'Avahi mDNS/DNS-SD Stack' %{_localstatedir}/run/avahi-daemon -
EOF
cat >avahi-autoipd.sysusers.conf <<EOF
u avahi-autoipd 170 'Avahi IPv4LL Stack' %{_localstatedir}/lib/avahi-autoipd -
EOF
%build
# patch100 requires autogen
# and kills rpaths a bonus
rm -fv missing
## why autogen?
## * kills rpaths
## * fixes -stack-protector flags (once gcc_stack_protect.m4 is removed)
rm -fv missing common/gcc_stack_protect.m4
NOCONFIGURE=1 ./autogen.sh
%configure \
@ -384,17 +476,36 @@ NOCONFIGURE=1 ./autogen.sh
--enable-shared=yes \
--enable-static=no \
--disable-silent-rules \
%if %{with check}
--enable-tests \
%endif
%if %{WITH_GTK2}
--enable-gtk \
%else
--disable-gtk \
%endif
%if %{WITH_GTK3}
--enable-gtk3 \
%else
--disable-gtk3 \
%endif
%if ! %{WITH_PYTHON}
--disable-python \
%endif
%if %{WITH_COMPAT_DNSSD}
--enable-compat-libdns_sd \
%endif
%if %{WITH_COMPAT_HOWL}
--enable-compat-howl \
%endif
%if ! %{WITH_QT3}
--disable-qt3 \
%if %{WITH_QT3}
--enable-qt3 \
%endif
%if ! %{WITH_QT4}
--disable-qt4 \
%if %{WITH_QT4}
--enable-qt4 \
%endif
%if ! %{WITH_QT5}
--disable-qt5 \
%endif
%if ! %{WITH_MONO}
--disable-mono \
@ -423,8 +534,8 @@ mkdir -p %{buildroot}%{_localstatedir}/lib/avahi-autoipd
rm -rfv %{buildroot}%{_datadir}/%{name}-%{version}
# Make /etc/avahi/etc/localtime owned by avahi:
mkdir -p %{buildroot}/etc/avahi/etc
touch %{buildroot}/etc/avahi/etc/localtime
mkdir -p %{buildroot}%{_sysconfdir}/avahi/etc
touch %{buildroot}%{_sysconfdir}/avahi/etc/localtime
# fix bug 197414 - add missing symlinks for avahi-compat-howl and avahi-compat-dns-sd
%if %{WITH_COMPAT_HOWL}
@ -435,14 +546,12 @@ ln -s avahi-compat-libdns_sd.pc %{buildroot}/%{_libdir}/pkgconfig/libdns_sd.pc
ln -s avahi-compat-libdns_sd/dns_sd.h %{buildroot}/%{_includedir}/
%endif
%if %{WITH_PYTHON}
# Add python3 support
mkdir -p %{buildroot}%{python3_sitelib}/avahi/
cp -r %{buildroot}%{python2_sitelib}/avahi/* %{buildroot}%{python3_sitelib}/avahi/
rm -fv %{buildroot}%{buildroot}%{python3_sitelib}/avahi/*.py{c,o}
sed -i 's!/usr/bin/python!/usr/bin/python3!' %{buildroot}%{python3_sitelib}/avahi/ServiceTypeDatabase.py
rm -fv %{buildroot}%{_sysconfdir}/rc.d/init.d/avahi-daemon
rm -fv %{buildroot}%{_sysconfdir}/rc.d/init.d/avahi-dnsconfd
sed -i 's!/usr/bin/python2!/usr/bin/python3!' %{buildroot}%{python3_sitelib}/avahi/ServiceTypeDatabase.py
# avoid empty GenericName keys from .desktop files
for i in %{buildroot}%{_datadir}/applications/*.desktop ; do
@ -450,32 +559,36 @@ if [ -n "$(grep '^GenericName=$' $i)" ]; then
desktop-file-edit --copy-name-to-generic-name $i
fi
done
%endif
rm -fv %{buildroot}%{_sysconfdir}/rc.d/init.d/avahi-daemon
rm -fv %{buildroot}%{_sysconfdir}/rc.d/init.d/avahi-dnsconfd
%find_lang %{name}
install -m0644 -D avahi.sysusers.conf %{buildroot}%{_sysusersdir}/avahi.conf
install -m0644 -D avahi-autoipd.sysusers.conf %{buildroot}%{_sysusersdir}/avahi-autoipd.conf
%check
for i in %{buildroot}%{_datadir}/applications/*.desktop ; do
desktop-file-validate $i
done
%if %{with check}
%make_build check
%endif
%if %{without bootstrap}
for i in %{buildroot}%{_datadir}/applications/b*.desktop ; do
desktop-file-validate $i
done
%endif
%if %{WITH_PYTHON}
desktop-file-validate %{buildroot}%{_datadir}/applications/avahi-discover.desktop
%endif
%pre
getent group avahi >/dev/null || groupadd -f -g 70 -r avahi
if ! getent passwd avahi > /dev/null ; then
if ! getent passwd 70 > /dev/null ; then
useradd -r -l -u 70 -g avahi -d %{_localstatedir}/run/avahi-daemon -s /sbin/nologin -c "Avahi mDNS/DNS-SD Stack" avahi
else
useradd -r -l -g avahi -d %{_localstatedir}/run/avahi-daemon -s /sbin/nologin -c "Avahi mDNS/DNS-SD Stack" avahi
fi
fi
exit 0
%post
%{?ldconfig}
/usr/bin/dbus-send --system --type=method_call --dest=org.freedesktop.DBus / org.freedesktop.DBus.ReloadConfig >/dev/null 2>&1 || :
if [ "$1" -eq 1 -a -s /etc/localtime ]; then
/usr/bin/cp -cfp /etc/localtime /etc/avahi/etc/localtime >/dev/null 2>&1 || :
/usr/bin/cp -cfp /etc/localtime %{_sysconfdir}/avahi/etc/localtime >/dev/null 2>&1 || :
fi
%systemd_post avahi-daemon.socket avahi-daemon.service
@ -486,17 +599,6 @@ fi
%{?ldconfig}
%systemd_postun_with_restart avahi-daemon.socket avahi-daemon.service
%pre autoipd
getent group avahi-autoipd >/dev/null || groupadd -f -g 170 -r avahi-autoipd
if ! getent passwd avahi-autoipd > /dev/null ; then
if ! getent passwd 170 > /dev/null; then
useradd -r -u 170 -l -g avahi-autoipd -d %{_localstatedir}/lib/avahi-autoipd -s /sbin/nologin -c "Avahi IPv4LL Stack" avahi-autoipd
else
useradd -r -l -g avahi-autoipd -d %{_localstatedir}/lib/avahi-autoipd -s /sbin/nologin -c "Avahi IPv4LL Stack" avahi-autoipd
fi
fi
exit 0
%post dnsconfd
%systemd_post avahi-dnsconfd.service
@ -527,14 +629,16 @@ exit 0
%ghost %{_sysconfdir}/avahi/etc/localtime
%config(noreplace) %{_sysconfdir}/avahi/hosts
%dir %{_sysconfdir}/avahi/services
%ghost %dir %{_localstatedir}/run/avahi-daemon
%ghost %attr(0755, avahi, avahi) %dir %{_localstatedir}/run/avahi-daemon
%config(noreplace) %{_sysconfdir}/avahi/avahi-daemon.conf
%config(noreplace) %{_sysconfdir}/dbus-1/system.d/avahi-dbus.conf
%config(noreplace) %{_datadir}/dbus-1/system.d/avahi-dbus.conf
%{_sbindir}/avahi-daemon
%dir %{_datadir}/avahi
%{_datadir}/avahi/*.dtd
%dir %{_libdir}/avahi
%if %{WITH_PYTHON}
%{_libdir}/avahi/service-types.db
%endif
%{_mandir}/man5/*
%{_mandir}/man8/avahi-daemon.*
%{_unitdir}/avahi-daemon.service
@ -542,12 +646,14 @@ exit 0
%{_datadir}/dbus-1/interfaces/*.xml
%{_datadir}/dbus-1/system-services/org.freedesktop.Avahi.service
%{_libdir}/libavahi-core.so.*
%{_sysusersdir}/avahi.conf
%files autoipd
%{_sbindir}/avahi-autoipd
%config(noreplace) %{_sysconfdir}/avahi/avahi-autoipd.action
%attr(1770,avahi-autoipd,avahi-autoipd) %dir %{_localstatedir}/lib/avahi-autoipd/
%{_mandir}/man8/avahi-autoipd.*
%{_sysusersdir}/avahi-autoipd.conf
%files dnsconfd
%config(noreplace) %{_sysconfdir}/avahi/avahi-dnsconfd.action
@ -556,43 +662,66 @@ exit 0
%{_unitdir}/avahi-dnsconfd.service
%files tools
%{_bindir}/*
%{_mandir}/man1/*
%exclude %{_bindir}/b*
%exclude %{_bindir}/avahi-discover*
%exclude %{_bindir}/avahi-bookmarks
%exclude %{_mandir}/man1/b*
%exclude %{_mandir}/man1/avahi-discover*
%exclude %{_mandir}/man1/avahi-bookmarks*
%{_bindir}/avahi-browse
%{_bindir}/avahi-browse-domains
%{_bindir}/avahi-publish
%{_bindir}/avahi-publish-address
%{_bindir}/avahi-publish-service
%{_bindir}/avahi-resolve
%{_bindir}/avahi-resolve-address
%{_bindir}/avahi-resolve-host-name
%{_bindir}/avahi-set-host-name
%{_mandir}/man1/avahi-browse.1*
%{_mandir}/man1/avahi-browse-domains.1*
%{_mandir}/man1/avahi-publish.1*
%{_mandir}/man1/avahi-publish-address.1*
%{_mandir}/man1/avahi-publish-service.1*
%{_mandir}/man1/avahi-resolve.1*
%{_mandir}/man1/avahi-resolve-address.1*
%{_mandir}/man1/avahi-resolve-host-name.1*
%{_mandir}/man1/avahi-set-host-name.1*
%if %{without bootstrap}
%files ui-tools
%{_bindir}/b*
%{_bindir}/avahi-discover
%{_bindir}/bshell
%{_bindir}/bssh
%{_bindir}/bvnc
%{_bindir}/avahi-discover-standalone
%{_mandir}/man1/bshell.1*
%{_mandir}/man1/bssh.1*
%{_mandir}/man1/bvnc.1*
%{_datadir}/applications/b*.desktop
%{_datadir}/avahi/interfaces/
%if %{WITH_PYTHON}
# avahi-bookmarks is not really a UI tool, but I won't create a seperate package for it...
%{_bindir}/avahi-bookmarks
%{_mandir}/man1/b*
%{_mandir}/man1/avahi-discover*
%{_mandir}/man1/avahi-bookmarks*
%{_datadir}/applications/b*.desktop
%{_datadir}/applications/avahi-discover.desktop
%{_datadir}/avahi/interfaces/
%{python2_sitelib}/avahi_discover/
%endif
%endif
%files devel
%{_libdir}/libavahi-common.so
%{_libdir}/libavahi-core.so
%{_libdir}/libavahi-client.so
%{_libdir}/libavahi-libevent.so
%{_includedir}/avahi-client
%{_includedir}/avahi-common
%{_includedir}/avahi-core
%{_includedir}/avahi-libevent
%{_libdir}/pkgconfig/avahi-core.pc
%{_libdir}/pkgconfig/avahi-client.pc
%{_libdir}/pkgconfig/avahi-libevent.pc
%files libs
%doc README
%license LICENSE
%{_libdir}/libavahi-common.so.*
%{_libdir}/libavahi-client.so.*
%{_libdir}/libavahi-libevent.so.*
%files glib
%{_libdir}/libavahi-glib.so.*
@ -604,28 +733,38 @@ exit 0
%files gobject
%{_libdir}/libavahi-gobject.so.*
#%{_libdir}/girepository-1.0/Avahi-0.6.typelib
#%{_libdir}/girepository-1.0/AvahiCore-0.6.typelib
#%%{_libdir}/girepository-1.0/Avahi-0.6.typelib
#%%{_libdir}/girepository-1.0/AvahiCore-0.6.typelib
%files gobject-devel
%{_libdir}/libavahi-gobject.so
%{_includedir}/avahi-gobject
%{_libdir}/pkgconfig/avahi-gobject.pc
#%{_datadir}/gir-1.0/Avahi-0.6.gir
#%{_datadir}/gir-1.0/AvahiCore-0.6.gir
#%%{_datadir}/gir-1.0/Avahi-0.6.gir
#%%{_datadir}/gir-1.0/AvahiCore-0.6.gir
%if %{WITH_GTK2}
%files ui
%{_libdir}/libavahi-ui.so.*
%endif
%if %{WITH_GTK3}
%files ui-gtk3
%{_libdir}/libavahi-ui-gtk3.so.*
%endif
%if %{WITH_GTK2} || %{WITH_GTK3}
%files ui-devel
%{_libdir}/libavahi-ui.so
%{_libdir}/libavahi-ui-gtk3.so
%{_includedir}/avahi-ui
%if %{WITH_GTK2}
%{_libdir}/libavahi-ui.so
%{_libdir}/pkgconfig/avahi-ui.pc
%endif
%if %{WITH_GTK3}
%{_libdir}/libavahi-ui-gtk3.so
%{_libdir}/pkgconfig/avahi-ui-gtk3.pc
%endif
%endif
%if %{WITH_QT3}
%ldconfig_scriptlets qt3
@ -651,6 +790,18 @@ exit 0
%{_libdir}/pkgconfig/avahi-qt4.pc
%endif
%if %{WITH_QT5}
%ldconfig_scriptlets qt5
%files qt5
%{_libdir}/libavahi-qt5.so.*
%files qt5-devel
%{_libdir}/libavahi-qt5.so
%{_includedir}/avahi-qt5/
%{_libdir}/pkgconfig/avahi-qt5.pc
%endif
%if %{WITH_MONO}
%files sharp
%{_prefix}/lib/mono/avahi-sharp
@ -688,16 +839,177 @@ exit 0
%{_libdir}/pkgconfig/libdns_sd.pc
%endif
%if %{WITH_PYTHON}
%files -n python2-avahi
# These are .py files only, so they don't go in lib64
%{python2_sitelib}/avahi/
%files -n python3-avahi
# These are .py files only, so they don't go in lib64
%{python3_sitelib}/avahi/
%endif
%changelog
* Fri Jan 16 2026 Fedora Release Engineering <releng@fedoraproject.org> - 0.9~rc2-7
- Rebuilt for https://fedoraproject.org/wiki/Fedora_44_Mass_Rebuild
* Tue Aug 05 2025 Petr Menšík <pemensik@redhat.com> - 0.9~rc2-6
- Fix port randomization for wide area queries (CVE-2024-52615)
- Add systemd-devel dependency
- Fix test crashing because FORTIFY_SOURCE protection
* Wed Jul 23 2025 Fedora Release Engineering <releng@fedoraproject.org> - 0.9~rc2-5
- Rebuilt for https://fedoraproject.org/wiki/Fedora_43_Mass_Rebuild
* Mon Apr 14 2025 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 0.9~rc2-4
- Also create sysusers.d config file for the avahi-autoipd user
* Thu Jan 23 2025 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 0.9~rc2-3
- Add sysusers.d config file to allow rpm to create users/groups automatically
* Thu Jan 16 2025 Michal Sekletar <msekleta@redhat.com> - 0.9~rc2-2
- Fix previous changelog entry
* Thu Jan 16 2025 Michal Sekletar <msekleta@redhat.com> - 0.9~rc2-1
- Rebase to 0.9-rc2
* Thu Jan 16 2025 Fedora Release Engineering <releng@fedoraproject.org> - 0.8-31
- Rebuilt for https://fedoraproject.org/wiki/Fedora_42_Mass_Rebuild
* Wed Aug 21 2024 Michal Sekletar <msekleta@redhat.com> - 0.8-30
- fix file attributes of /run/avahi-daemon (rhbz#1608918)
* Wed Jul 17 2024 Fedora Release Engineering <releng@fedoraproject.org> - 0.8-29
- Rebuilt for https://fedoraproject.org/wiki/Fedora_41_Mass_Rebuild
* Thu Apr 04 2024 Michal Sekletar <msekleta@redhat.com> - 0.8-28
- Add gettext-devel to build dependencies
* Mon Jan 22 2024 Fedora Release Engineering <releng@fedoraproject.org> - 0.8-27
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Fri Jan 19 2024 Fedora Release Engineering <releng@fedoraproject.org> - 0.8-26
- Rebuilt for https://fedoraproject.org/wiki/Fedora_40_Mass_Rebuild
* Wed Jul 26 2023 Lukáš Zaoral <lzaoral@redhat.com> - 0.8-25
- migrate to SPDX license format
* Wed Jul 19 2023 Fedora Release Engineering <releng@fedoraproject.org> - 0.8-24
- Rebuilt for https://fedoraproject.org/wiki/Fedora_39_Mass_Rebuild
* Wed May 10 2023 Tomas Popela <tpopela@redhat.com> - 0.8-23
- Drop BR on dbus-glib as the project is not using it at all
* Sun Mar 19 2023 Petr Menšík <pemensik@redhat.com> - 0.8-22
- Enable unit tests during check
- Prevent crashes on some invalid DBus calls
- Provide versioned howl compatibility package
- Correct bootstrap option
* Sun Mar 19 2023 Yaakov Selkowitz <yselkowi@redhat.com> - 0.8-21
- Disable GTK2 in ELN/RHEL10 builds
* Wed Jan 18 2023 Fedora Release Engineering <releng@fedoraproject.org> - 0.8-20
- Rebuilt for https://fedoraproject.org/wiki/Fedora_38_Mass_Rebuild
* Fri Nov 11 2022 Petr Menšík <pemensik@redhat.com> - 0.8-19
- Add upstream PR links to patches
* Tue Nov 01 2022 Christian Krause <chkr@fedoraproject.org> - 0.8-18
- Install glade file for avahi-discover-standalone unconditionally
(fixes #2036073 and #2126721)
- Install desktop files for bssh and bvnc unconditionally
* Fri Aug 05 2022 Kalev Lember <klember@redhat.com> - 0.8-17
- Avoid systemd_requires as per updated packaging guidelines
* Wed Jul 20 2022 Fedora Release Engineering <releng@fedoraproject.org> - 0.8-16
- Rebuilt for https://fedoraproject.org/wiki/Fedora_37_Mass_Rebuild
* Wed Jan 19 2022 Fedora Release Engineering <releng@fedoraproject.org> - 0.8-15
- Rebuilt for https://fedoraproject.org/wiki/Fedora_36_Mass_Rebuild
* Tue Aug 03 2021 Rex Dieter <rdieter@fedoraproject.org> - 0.8-14
- pull in upstream fix for CVE-2021-36217 (#1989381,#1989382)
- revert "Re-enable LTO" on f34 (still needed)
* Wed Jul 21 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.8-13
- Rebuilt for https://fedoraproject.org/wiki/Fedora_35_Mass_Rebuild
* Mon May 10 2021 Jeff Law <jlaw@tachyum.com> - 0.8-12
- Re-enable LTO
* Thu Apr 29 2021 Rex Dieter <rdieter@fedoraproject.org> - 0.8-11
- avahi libraries missing -fstack-protector-strong (#1817737)
* Tue Mar 02 2021 Zbigniew Jędrzejewski-Szmek <zbyszek@in.waw.pl> - 0.8-10
- Rebuilt for updated systemd-rpm-macros
See https://pagure.io/fesco/issue/2583.
* Tue Feb 16 2021 Rex Dieter <rdieter@fedoraproject.org> - 0.8-9
- cleanup/fix conditionals (#1751484)
- disable lto, workaround FTBFS (#1907727)
* Tue Jan 26 2021 Fedora Release Engineering <releng@fedoraproject.org> - 0.8-8
- Rebuilt for https://fedoraproject.org/wiki/Fedora_34_Mass_Rebuild
* Tue Nov 17 2020 Rex Dieter <rdieter@fedoraproject.org> - 0.8-7
- fix undefined symbols in libavahi-qt3 (#1897925)
* Thu Oct 15 2020 Rex Dieter <rdieter@fedoraproject.org> - 0.8-6
- resurrect ui-tools, not just for python (#1885513)
* Mon Sep 21 2020 Michal Sekletar <msekleta@redhat.com> - 0.8-5
- Disable bootstrap
* Mon Sep 07 2020 Ondřej Lysoněk <olysonek@redhat.com> - 0.8-4
- Rebuilt due to libevent rebase
* Mon Jul 27 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.8-3
- Rebuilt for https://fedoraproject.org/wiki/Fedora_33_Mass_Rebuild
* Sun Mar 22 2020 Rex Dieter <rdieter@fedoraproject.org> - 0.8-2
- pull in some upstream fixes
* Sun Mar 22 2020 Lubomir Rintel <lkundrak@v3.sk> - 0.8-1
- Update to version 0.8
* Thu Feb 20 2020 Petr Viktorin <pviktori@redhat.com> - 0.7-24
- Don't BuildRequire pygtk2 if building without Python
* Tue Jan 28 2020 Fedora Release Engineering <releng@fedoraproject.org> - 0.7-23
- Rebuilt for https://fedoraproject.org/wiki/Fedora_32_Mass_Rebuild
* Thu Sep 19 2019 Rex Dieter <rdieter@fedoraproject.org> - 0.7-22
- drop python bindings/support (includes -ui-tools that use the bindings) on f31+ (#1751484)
* Mon Aug 19 2019 Miro Hrončok <mhroncok@redhat.com> - 0.7-21
- Rebuilt for Python 3.8
* Wed Jul 24 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.7-20
- Rebuilt for https://fedoraproject.org/wiki/Fedora_31_Mass_Rebuild
* Fri Feb 22 2019 Michal Sekletár <msekleta@redhat.com> - 0.7-19
- add support for advertising services on the local machine only (i.e. on loopback)
* Mon Feb 04 2019 Kalev Lember <klember@redhat.com> - 0.7-18
- Update requires for pygobject3 -> python2-gobject rename
* Thu Jan 31 2019 Fedora Release Engineering <releng@fedoraproject.org> - 0.7-17
- Rebuilt for https://fedoraproject.org/wiki/Fedora_30_Mass_Rebuild
* Mon Jul 30 2018 Adam Williamson <awilliam@redhat.com> - 0.7-16
- Update python3 sed hack to avoid '/usr/bin/python32' dep
* Tue Jul 24 2018 Jan Grulich <jgrulich@redhat.com> - 0.7-15
- Requires: tigervnc
Tigervnc removed old obsoleted provides
* Thu Jul 12 2018 Fedora Release Engineering <releng@fedoraproject.org> - 0.7-14
- Rebuilt for https://fedoraproject.org/wiki/Fedora_29_Mass_Rebuild
* Tue Jun 19 2018 Miro Hrončok <mhroncok@redhat.com> - 0.7-13
- Rebuilt for Python 3.7
* Thu Apr 05 2018 Rex Dieter <rdieter@fedoraproject.org> - 0.7-12
- use %%make_build %%ldconfig_scriptlets %%license
- %%build: --enable-shared=yes --enable-static=no --disable-silent-rules

6
plans/main.fmf Normal file
View file

@ -0,0 +1,6 @@
summary: Run all tests
execute:
how: tmt
discover:
how: fmf

View file

@ -1 +1 @@
SHA512 (avahi-0.7.tar.gz) = bae5a1e9204aca90b90e7fd223d19e809e3514d03ba5fa2da1e55bf1d72d3d3b98567f357900c36393613dc17dc98e15ff3ebf0f226f2f6b9766e592452a6ce7
SHA512 (v0.9-rc2.tar.gz) = 29d6c9d075d0202b9da2cdf935fa04fad31ba95475ba5de086c9958d25caa405925bbd82ed439a024febf7880325e80c1a032a660284a7708c71dae9076f413b

View file

@ -0,0 +1,64 @@
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# Makefile of /CoreOS/avahi/Sanity/Basic-sanity-test
# Description: Tests basic functionality of avahi.
# Author: Martin Cermak <mcermak@redhat.com>
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# Copyright (c) 2010 Red Hat, Inc.
#
# This copyrighted material is made available to anyone wishing
# to use, modify, copy, or redistribute it subject to the terms
# and conditions of the GNU General Public License version 2.
#
# This program is distributed in the hope that it will be
# useful, but WITHOUT ANY WARRANTY; without even the implied
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
# PURPOSE. See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public
# License along with this program; if not, write to the Free
# Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
# Boston, MA 02110-1301, USA.
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
export TEST=/CoreOS/avahi/Sanity/Basic-sanity-test
export TESTVERSION=1.0
BUILT_FILES=
FILES=$(METADATA) runtest.sh Makefile PURPOSE named.conf zonefile
.PHONY: all install download clean
run: $(FILES) build
./runtest.sh
build: $(BUILT_FILES)
test -e runtest.sh || chmod a+x runtest.sh
clean:
rm -f *~ $(BUILT_FILES)
include /usr/share/rhts/lib/rhts-make.include
$(METADATA): Makefile
@echo "Owner: Martin Cermak <mcermak@redhat.com>" > $(METADATA)
@echo "Name: $(TEST)" >> $(METADATA)
@echo "TestVersion: $(TESTVERSION)" >> $(METADATA)
@echo "Path: $(TEST_DIR)" >> $(METADATA)
@echo "Description: Tests basic functionality of avahi." >> $(METADATA)
@echo "Type: Sanity" >> $(METADATA)
@echo "TestTime: 10m" >> $(METADATA)
@echo "RunFor: avahi" >> $(METADATA)
@echo "Requires: avahi avahi-tools bind bind-chroot bind-utils" >> $(METADATA)
@echo "Priority: Normal" >> $(METADATA)
@echo "License: GPLv2" >> $(METADATA)
@echo "Confidential: no" >> $(METADATA)
@echo "Destructive: no" >> $(METADATA)
@echo "Releases: -RedHatEnterpriseLinux3 -RedHatEnterpriseLinux4" >> $(METADATA)
rhts-lint $(METADATA)

View file

@ -0,0 +1,15 @@
PURPOSE of /CoreOS/avahi/Sanity/Basic-sanity-test
Description: Tests basic functionality of avahi.
Author: Martin Cermak <mcermak@redhat.com>
My objective was to write a very basic sanity test for avahi.
As I'm the avahi newbie, I browsed avahi.org, experimented
a little with RHEL avahi packages and pinged Lennart, which
did not respond.
My result is a simple test for the avahi domain name resolver.
It requires the avahi-daemon running. As the RHTS/Beaker is/will
shortly be a closed system without the possibility to reach the
outside network, this test contains its own nameserver.

View file

@ -0,0 +1,11 @@
options {
directory "/var/named";
allow-query { any; };
};
zone "<DOMAIN>" IN {
type master;
file "<DOMAIN>.zone";
allow-update { none; };
};

View file

@ -0,0 +1,96 @@
#!/bin/bash
# vim: dict=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# runtest.sh of /CoreOS/avahi/Sanity/Basic-sanity-test
# Description: Tests basic functionality of avahi.
# Author: Martin Cermak <mcermak@redhat.com>
# Author: Tomas Dolezal <todoleza@redhat.com> - rhel7 updates
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# Copyright (c) 2013 Red Hat, Inc.
#
# This copyrighted material is made available to anyone wishing
# to use, modify, copy, or redistribute it subject to the terms
# and conditions of the GNU General Public License version 2.
#
# This program is distributed in the hope that it will be
# useful, but WITHOUT ANY WARRANTY; without even the implied
# warranty of MERCHANTABILITY or FITNESS FOR A PARTICULAR
# PURPOSE. See the GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public
# License along with this program; if not, write to the Free
# Software Foundation, Inc., 51 Franklin Street, Fifth Floor,
# Boston, MA 02110-1301, USA.
#
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
# Include rhts environment
. /usr/bin/rhts-environment.sh
. /usr/lib/beakerlib/beakerlib.sh
TEMPSTR=$(date +%c%N | md5sum | awk '{print $1}' | cut -c -8)
ORIGPWD=$(pwd)
IP1='127.0.0.1'
IP2='::1'
rlJournalStart
rlPhaseStartSetup
rlAssertRpm 'avahi'
rlAssertRpm 'avahi-tools'
rlRun "TmpDir=\`mktemp -d\`" 0 "Creating tmp directory"
rlRun "pushd $TmpDir"
ROOTDIR="" #using non-chroot
rlFileBackup /etc/named.conf /etc/resolv.conf
rlFileBackup --clean /var/named/
cat $ORIGPWD/named.conf > /etc/named.conf
rlRun "TDOMAIN=$TEMPSTR.cz"
rlRun "TZONEFILE=$ROOTDIR/var/named/$TDOMAIN.zone"
# set up /etc/named.conf
rlRun "sed -i \"s/<DOMAIN>/$TDOMAIN/g\" /etc/named.conf"
# set up zonefile
rlRun "cp $ORIGPWD/zonefile $TZONEFILE"
rlRun "chmod a+r $TZONEFILE"
rlRun "sed -i \"s/<DOMAIN>/$TDOMAIN/g\" $TZONEFILE"
rlRun "sed -i \"s/<IP1>/$IP1/g\" $TZONEFILE"
rlRun "sed -i \"s/<IP2>/$IP2/g\" $TZONEFILE"
rlRun "sed -i \"s/<SERIAL>/$(date +%N)/g\" $TZONEFILE"
rlServiceStart named #using non-chroot
# set default resolver
rlRun "echo nameserver 127.0.0.1 > /etc/resolv.conf"
rlPhaseEnd
rlPhaseStartTest
# check bind
rlRun "dig @localhost server1.$TDOMAIN +short | grep $IP1"
rlRun "dig AAAA @localhost server2.$TDOMAIN +short | grep $IP2"
# turn on avahi or restart it with new resolv.conf
rlServiceStart "avahi-daemon"
# the test itself...
rlRun "avahi-resolve -4n server1.$TDOMAIN | grep '127.0.0.1'" 0 "Test the IPv4 avahi DN resolver."
rlRun "avahi-resolve -6n server2.$TDOMAIN | grep '::1'" 0 "Test the IPv6 avahi DN resolver."
rlPhaseEnd
rlPhaseStartCleanup
rlFileRestore
rlServiceStart avahi-daemon
rlServiceRestore named avahi-daemon
rlRun "popd"
rlRun "rm -r $TmpDir" 0 "Removing tmp directory"
rlPhaseEnd
rlJournalPrintText
rlJournalEnd

View file

@ -0,0 +1,23 @@
$ORIGIN <DOMAIN>.
$TTL 86400
@ IN SOA dns1.<DOMAIN>. hostmaster.<DOMAIN>. (
<SERIAL> ; serial
21600 ; refresh after 6 hours
3600 ; retry after 1 hour
604800 ; expire after 1 week
86400 ) ; minimum TTL of 1 day
IN NS dns1.<DOMAIN>.
IN NS dns2.<DOMAIN>.
IN MX 10 mail.<DOMAIN>.
IN MX 20 mail2.<DOMAIN>.
IN A <IP1>
server1 IN A <IP1>
server2 IN AAAA <IP2>
dns1 IN A <IP1>
dns2 IN A <IP1>

View file

@ -0,0 +1,2 @@
gef config gef.disable_color True
got-audit --all

7
tests/got-audit/main.fmf Normal file
View file

@ -0,0 +1,7 @@
summary: Audit the GOT for signs of tampering
description: |
Pointers in the server process GOT will be checked to ensure that
each function pointer's value is within a shared object file
that exports a symbol of that name, and that no shared object
files export conflicting symbols.
contact: Gordon Messmer <gordon.messmer@gmail.com>

45
tests/got-audit/runtest.sh Executable file
View file

@ -0,0 +1,45 @@
#!/bin/bash
# vim: dict+=/usr/share/beakerlib/dictionary.vim cpt=.,w,b,u,t,i,k
# ~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
#
# runtest.sh of /CoreOS/avahi/Sanity/got-audit
# Description: Check pointers in the server process GOT for signs of tampering
# Author: Gordon Messmer <gordon.messmer@gmail.com>
#
# Include Beaker environment
. /usr/share/beakerlib/beakerlib.sh || exit 1
TEST="/CoreOS/avahi/Sanity/got-audit"
rlJournalStart
rlPhaseStartSetup
rlServiceStart avahi-daemon.socket
rlServiceStart avahi-daemon
rlRun "TestDir=\$(pwd)"
rlRun "TmpDir=\$(mktemp -d)" 0 "Creating tmp directory"
rlRun "pushd $TmpDir"
rlRun "auditfile=\$(mktemp --tmpdir=${TmpDir})"
rlPhaseEnd
rlPhaseStartTest "Run GEF got-audit"
rlRun "SERVICE_PID=\$(systemctl show --property=MainPID --value avahi-daemon.service)"
rlRun "echo SERVICE_PID is '$SERVICE_PID'"
[ -n "$SERVICE_PID" ] || rlFail "No service pid was found"
rlRun "gdb-gef --pid '$SERVICE_PID' --command='$TestDir'/got-audit.gdb --batch > '$auditfile'"
# Basic test: ensure that at least one symbol is found in libc.so,
# to verify that the report looks plausible.
rlAssertGrep " : /.*/libc.so" "$auditfile"
# Ensure the got-audit did not report any errors
rlAssertNotGrep " :: ERROR" "$auditfile"
rlRun "cp '$auditfile' '$TMT_TEST_DATA'/got-audit.txt"
rlPhaseEnd
rlPhaseStartCleanup
rlServiceRestore avahi-daemon.socket
rlServiceRestore avahi-daemon
rlRun "popd"
rlRun "rm -r $TmpDir" 0 "Removing tmp directory"
rlPhaseEnd
rlJournalEnd
rlJournalPrintText

2
tests/main.fmf Normal file
View file

@ -0,0 +1,2 @@
test: ./runtest.sh
framework: beakerlib

18
tests/tests.yml Normal file
View file

@ -0,0 +1,18 @@
---
# Tests that run in classic context
- hosts: localhost
roles:
- role: standard-test-beakerlib
tags:
- classic
tests:
- Basic-sanity-test
- got-audit
required_packages:
- avahi
- avahi-tools
- bind
- bind-chroot
- bind-utils
- gdb-gef # needed to test got-audit