[PATCH] settings: Overwrite values before freeing memory
by Andrew Zaborowski
Since there may be sensitive data in the setting values, wipe the
value memory before freeing.
---
ell/settings.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/ell/settings.c b/ell/settings.c
index a556144..8e67fa3 100644
--- a/ell/settings.c
+++ b/ell/settings.c
@@ -61,6 +61,7 @@ static void setting_destroy(void *data)
struct setting_data *pair = data;
l_free(pair->key);
+ memset(pair->value, 0, strlen(pair->value));
l_free(pair->value);
l_free(pair);
}
--
2.14.1
4 years, 3 months
Debug logging with ell
by Stotland, Inga
Hi all,
Quick question: can I use l_debug() when I am dynamically linking with
installed ell library (i.e., the one created with make install and
linked as -lell)?
Calling l_debug() generates no output, l_info() works just fine.
When I link with libell-private, l_debug works as expected. Something
to do with debug mem sections?
I would rather not write my own logging if l_debug() is
available.
Thanks,
Inga
4 years, 3 months
[PATCH] net: fix include error
by James Prestwood
sys/socket.h needed to be included before linux/if_arp.h
to fix a build error.
---
ell/net.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/ell/net.c b/ell/net.c
index 77eadff..b5b5f9d 100644
--- a/ell/net.c
+++ b/ell/net.c
@@ -24,6 +24,7 @@
#include <config.h>
#endif
+#include <sys/socket.h>
#include <linux/if_arp.h>
#include <unistd.h>
#include <errno.h>
--
2.7.4
4 years, 4 months
[PATCH] ell: fix build with musl libc
by maxin.john@gmail.com
From: "Maxin B. John" <maxin.john(a)intel.com>
musl libc doesn't implement TEMP_FAILURE_RETRY. Use the
TEMP_FAILURE_RETRY from glibc to fix build.
---
ell/dbus.h | 10 ++++++++++
1 file changed, 10 insertions(+)
diff --git a/ell/dbus.h b/ell/dbus.h
index a7c08d2..3ff5e0f 100644
--- a/ell/dbus.h
+++ b/ell/dbus.h
@@ -28,6 +28,16 @@
#include <stddef.h>
#include <stdarg.h>
+/* taken from glibc unistd.h for musl support */
+#ifndef TEMP_FAILURE_RETRY
+#define TEMP_FAILURE_RETRY(expression) \
+ (__extension__ \
+ ({ long int __result; \
+ do __result = (long int) (expression); \
+ while (__result == -1L && errno == EINTR); \
+ __result; }))
+#endif
+
#ifdef __cplusplus
extern "C" {
#endif
--
2.4.0
4 years, 4 months