commit cfengine for openSUSE:Factory
![](https://seccdn.libravatar.org/avatar/e2145bc5cf53dda95c308a3c75e8fef3.jpg?s=120&d=mm&r=g)
Hello community,
here is the log from the commit of package cfengine for openSUSE:Factory checked in at 2016-08-12 15:44:33
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Comparing /work/SRC/openSUSE:Factory/cfengine (Old)
and /work/SRC/openSUSE:Factory/.cfengine.new (New)
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "cfengine"
Changes:
--------
--- /work/SRC/openSUSE:Factory/cfengine/cfengine.changes 2016-06-23 13:37:34.000000000 +0200
+++ /work/SRC/openSUSE:Factory/.cfengine.new/cfengine.changes 2016-08-12 15:44:34.000000000 +0200
@@ -1,0 +2,22 @@
+Fri Aug 5 10:30:01 UTC 2016 - kkaempf@suse.com
+
+- Update to 3.9.1
+ - Change: Log level for keeping verbatim JSON to DEBUG (CFE-2141)
+ - Change (masterfiles): Definition of from_cfexecd for
+ cf-execd initiated runs (CFE-2386)
+ - Change: Switch processes restart_class logging to verbose
+ - Change: Enable agent component management policy on systemd hosts
+ (CFE-2429)
+ - Change: Remove executable bit from systemd units (CFE-2436)
+ - Change: Require network before cfengine services (CFE-2435)
+ - Fix 'contain' attribute 'no_output' having no effect when
+ the 'commands' promise is using 'module => "true"'. (CFE-2412)
+ - Fix: Services starting or stopping unnecessarily (CFE-2421)
+ - Fix occasional segfault when running getindices() on a
+ variable that has indices of multiple depths (e.g. both "a[x]" and
+ "a[x][y]"). (CFE-2397)
+ - Fix bug in files promise when multiple owners are promised
+ but first one doesn't exist, and improve logging . (CFE-2432)
+ - fix: memory leaks
+
+-------------------------------------------------------------------
Old:
----
cfengine-3.9.0.tar.gz
New:
----
cfengine-3.9.1.tar.gz
++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Other differences:
------------------
++++++ cfengine.spec ++++++
--- /var/tmp/diff_new_pack.GJlhUH/_old 2016-08-12 15:44:36.000000000 +0200
+++ /var/tmp/diff_new_pack.GJlhUH/_new 2016-08-12 15:44:36.000000000 +0200
@@ -16,7 +16,7 @@
#
-%define srcversion 3.9.0
+%define srcversion 3.9.1
%define srcname %{name}-%{srcversion}
%define libname libpromises
%define libsoname %{libname}3
++++++ cfengine-3.9.0.tar.gz -> cfengine-3.9.1.tar.gz ++++++
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cfengine-3.9.0/ChangeLog new/cfengine-3.9.1/ChangeLog
--- old/cfengine-3.9.0/ChangeLog 2016-06-06 12:01:06.000000000 +0200
+++ new/cfengine-3.9.1/ChangeLog 2016-07-28 23:25:32.000000000 +0200
@@ -1,3 +1,22 @@
+3.9.1:
+ - Change: Log level for keeping verbatim JSON to DEBUG (CFE-2141)
+ - Change (masterfiles): Definition of from_cfexecd for
+ cf-execd initiated runs (CFE-2386)
+ - Change: Switch processes restart_class logging to verbose
+ - Change: Enable agent component management policy on systemd hosts
+ (CFE-2429)
+ - Change: Remove executable bit from systemd units (CFE-2436)
+ - Change: Require network before cfengine services (CFE-2435)
+ - Fix 'contain' attribute 'no_output' having no effect when
+ the 'commands' promise is using 'module => "true"'. (CFE-2412)
+ - Fix: Services starting or stopping unnecessarily (CFE-2421)
+ - Fix occasional segfault when running getindices() on a
+ variable that has indices of multiple depths (e.g. both "a[x]" and
+ "a[x][y]"). (CFE-2397)
+ - Fix bug in files promise when multiple owners are promised
+ but first one doesn't exist, and improve logging . (CFE-2432)
+ - fix: memory leaks
+
3.9.0:
New features/additions:
- Classes promise: allow classes without an expression to default to defined.
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cfengine-3.9.0/cf-agent/cf-agent.c new/cfengine-3.9.1/cf-agent/cf-agent.c
--- old/cfengine-3.9.0/cf-agent/cf-agent.c 2016-06-06 12:01:06.000000000 +0200
+++ new/cfengine-3.9.1/cf-agent/cf-agent.c 2016-07-28 23:25:32.000000000 +0200
@@ -1105,14 +1105,20 @@
Banner("Begin policy/promise evaluation");
- if (config->bundlesequence)
+ if (config->bundlesequence != NULL)
{
Log(LOG_LEVEL_INFO, "Using command line specified bundlesequence");
- bundlesequence = config->bundlesequence;
+ bundlesequence = RlistCopy(config->bundlesequence);
}
- else if (!(bundlesequence = (Rlist *)EvalContextVariableControlCommonGet(ctx, COMMON_CONTROL_BUNDLESEQUENCE)))
+ else
{
- RlistAppendScalar(&bundlesequence, "main");
+ bundlesequence = RlistCopy((Rlist *) EvalContextVariableControlCommonGet(
+ ctx, COMMON_CONTROL_BUNDLESEQUENCE));
+
+ if (bundlesequence == NULL)
+ {
+ RlistAppendScalar(&bundlesequence, "main");
+ }
}
bool ok = true;
@@ -1225,6 +1231,8 @@
}
}
}
+
+ RlistDestroy(bundlesequence);
}
static void AllClassesReport(const EvalContext *ctx)
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cfengine-3.9.0/cf-agent/verify_exec.c new/cfengine-3.9.1/cf-agent/verify_exec.c
--- old/cfengine-3.9.0/cf-agent/verify_exec.c 2016-06-06 12:01:06.000000000 +0200
+++ new/cfengine-3.9.1/cf-agent/verify_exec.c 2016-07-28 23:25:32.000000000 +0200
@@ -384,7 +384,8 @@
{
ModuleProtocol(ctx, cmdline, line, !a.contain.nooutput, module_context, module_tags, &persistence);
}
- else if ((!a.contain.nooutput) && (!EmptyString(line)))
+
+ if (!a.contain.nooutput && !EmptyString(line))
{
lineOutLen = strlen(comm) + strlen(line) + 12;
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cfengine-3.9.0/cf-agent/verify_files_utils.c new/cfengine-3.9.1/cf-agent/verify_files_utils.c
--- old/cfengine-3.9.0/cf-agent/verify_files_utils.c 2016-06-06 12:01:06.000000000 +0200
+++ new/cfengine-3.9.1/cf-agent/verify_files_utils.c 2016-07-28 23:25:32.000000000 +0200
@@ -3580,93 +3580,97 @@
struct group *gp;
UidList *ulp;
GidList *glp;
- short uidmatch = false, gidmatch = false;
- uid_t uid = CF_SAME_OWNER;
- gid_t gid = CF_SAME_GROUP;
+ /* The groups to change ownership to, using lchown(uid,gid). */
+ uid_t uid = CF_UNKNOWN_OWNER; /* just init values */
+ gid_t gid = CF_UNKNOWN_GROUP;
+
+ /* SKIP if file is already owned by anyone of the promised owners. */
for (ulp = attr.perms.owners; ulp != NULL; ulp = ulp->next)
{
if (ulp->uid == CF_SAME_OWNER || sb->st_uid == ulp->uid) /* "same" matches anything */
{
- uid = ulp->uid;
- uidmatch = true;
+ uid = CF_SAME_OWNER; /* chown(-1) doesn't change ownership */
break;
}
}
- if (attr.perms.groups->next == NULL && attr.perms.groups->gid == CF_UNKNOWN_GROUP) // Only one non.existent item
+ if (uid != CF_SAME_OWNER)
{
- cfPS(ctx, LOG_LEVEL_ERR, PROMISE_RESULT_FAIL, pp, attr, "Unable to make file belong to an unknown group");
- *result = PromiseResultUpdate(*result, PROMISE_RESULT_FAIL);
- }
-
- if (attr.perms.owners->next == NULL && attr.perms.owners->uid == CF_UNKNOWN_OWNER) // Only one non.existent item
- {
- cfPS(ctx, LOG_LEVEL_ERR, PROMISE_RESULT_FAIL, pp, attr, "Unable to make file belong to an unknown user");
- *result = PromiseResultUpdate(*result, PROMISE_RESULT_FAIL);
+ /* Change ownership to the first known user in the promised list. */
+ for (ulp = attr.perms.owners; ulp != NULL; ulp = ulp->next)
+ {
+ if (ulp->uid != CF_UNKNOWN_OWNER)
+ {
+ uid = ulp->uid;
+ break;
+ }
+ }
+ if (ulp == NULL)
+ {
+ cfPS(ctx, LOG_LEVEL_ERR, PROMISE_RESULT_FAIL, pp, attr,
+ "None of the promised owners for '%s' exist -- see INFO logs for more",
+ file);
+ *result = PromiseResultUpdate(*result, PROMISE_RESULT_FAIL);
+ uid = CF_SAME_OWNER; /* chown(-1) doesn't change ownership */
+ }
}
+ assert(uid != CF_UNKNOWN_OWNER);
+ /* SKIP if file is already group owned by anyone of the promised groups. */
for (glp = attr.perms.groups; glp != NULL; glp = glp->next)
{
- if (glp->gid == CF_SAME_GROUP || sb->st_gid == glp->gid) /* "same" matches anything */
+ if (glp->gid == CF_SAME_GROUP || sb->st_gid == glp->gid)
{
- gid = glp->gid;
- gidmatch = true;
+ gid = CF_SAME_GROUP; /* chown(-1) doesn't change ownership */
break;
}
}
- if (uidmatch && gidmatch)
+ /* Change group ownership to the first known group in the promised list. */
+ if (gid != CF_SAME_GROUP)
{
- return false;
- }
- else
- {
- if (!uidmatch)
+ for (glp = attr.perms.groups; glp != NULL; glp = glp->next)
{
- for (ulp = attr.perms.owners; ulp != NULL; ulp = ulp->next)
+ if (glp->gid != CF_UNKNOWN_GROUP)
{
- if (attr.perms.owners->uid != CF_UNKNOWN_OWNER)
- {
- uid = attr.perms.owners->uid; /* default is first (not unknown) item in list */
- break;
- }
+ gid = glp->gid;
+ break;
}
}
-
- if (!gidmatch)
+ if (glp == NULL)
{
- for (glp = attr.perms.groups; glp != NULL; glp = glp->next)
- {
- if (attr.perms.groups->gid != CF_UNKNOWN_GROUP)
- {
- gid = attr.perms.groups->gid; /* default is first (not unknown) item in list */
- break;
- }
- }
+ cfPS(ctx, LOG_LEVEL_ERR, PROMISE_RESULT_FAIL, pp, attr,
+ "None of the promised groups for '%s' exist -- see INFO logs for more",
+ file);
+ *result = PromiseResultUpdate(*result, PROMISE_RESULT_FAIL);
+ gid = CF_SAME_GROUP; /* chown(-1) doesn't change ownership */
}
+ }
+ assert(gid != CF_UNKNOWN_GROUP);
+ if (uid == CF_SAME_OWNER &&
+ gid == CF_SAME_GROUP)
+ {
+ /* User and group as promised, skip completely. */
+ return false;
+ }
+ else
+ {
switch (attr.transaction.action)
{
case cfa_fix:
- if (uid == CF_SAME_OWNER && gid == CF_SAME_GROUP)
+ if (uid != CF_SAME_OWNER)
{
- Log(LOG_LEVEL_VERBOSE, "Touching '%s'", file);
+ Log(LOG_LEVEL_DEBUG, "Change owner to uid '%ju' if possible",
+ (uintmax_t) uid);
}
- else
- {
- if (uid != CF_SAME_OWNER)
- {
- Log(LOG_LEVEL_DEBUG, "Change owner to uid '%ju' if possible",
- (uintmax_t) uid);
- }
- if (gid != CF_SAME_GROUP)
- {
- Log(LOG_LEVEL_DEBUG, "Change group to gid '%ju' if possible",
- (uintmax_t) gid);
- }
+ if (gid != CF_SAME_GROUP)
+ {
+ Log(LOG_LEVEL_DEBUG, "Change group to gid '%ju' if possible",
+ (uintmax_t) gid);
}
if (!DONTDO && S_ISLNK(sb->st_mode))
@@ -3685,7 +3689,7 @@
}
else if (!DONTDO)
{
- if (!uidmatch)
+ if (uid != CF_SAME_OWNER)
{
cfPS(ctx, LOG_LEVEL_INFO, PROMISE_RESULT_CHANGE, pp, attr,
"Owner of '%s' was %ju, setting to %ju",
@@ -3693,10 +3697,11 @@
*result = PromiseResultUpdate(*result, PROMISE_RESULT_CHANGE);
}
- if (!gidmatch)
+ if (gid != CF_SAME_GROUP)
{
- cfPS(ctx, LOG_LEVEL_INFO, PROMISE_RESULT_CHANGE, pp, attr, "Group of '%s' was %ju, setting to %ju", file, (uintmax_t)sb->st_gid,
- (uintmax_t)gid);
+ cfPS(ctx, LOG_LEVEL_INFO, PROMISE_RESULT_CHANGE, pp, attr,
+ "Group of '%s' was %ju, setting to %ju",
+ file, (uintmax_t)sb->st_gid, (uintmax_t)gid);
*result = PromiseResultUpdate(*result, PROMISE_RESULT_CHANGE);
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cfengine-3.9.0/cf-agent/verify_processes.c new/cfengine-3.9.1/cf-agent/verify_processes.c
--- old/cfengine-3.9.0/cf-agent/verify_processes.c 2016-06-06 12:01:06.000000000 +0200
+++ new/cfengine-3.9.1/cf-agent/verify_processes.c 2016-07-28 23:25:32.000000000 +0200
@@ -246,8 +246,8 @@
else
{
PromiseResult status = killed ? PROMISE_RESULT_CHANGE : PROMISE_RESULT_NOOP;
- cfPS(ctx, LOG_LEVEL_INFO, status, pp, a,
- "Setting restart class '%s' for promise '%s'", a.restart_class, pp->promiser);
+ cfPS(ctx, LOG_LEVEL_VERBOSE, status, pp, a,
+ "C: + Global class: %s ", a.restart_class);
result = PromiseResultUpdate(result, status);
EvalContextClassPutSoft(ctx, a.restart_class, CONTEXT_SCOPE_NAMESPACE, "source=promise");
}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cfengine-3.9.0/configure new/cfengine-3.9.1/configure
--- old/cfengine-3.9.0/configure 2016-06-06 12:01:47.000000000 +0200
+++ new/cfengine-3.9.1/configure 2016-07-28 23:26:45.000000000 +0200
@@ -3197,7 +3197,7 @@
# Define the identity of the package.
PACKAGE=cfengine
- VERSION=3.9.0
+ VERSION=3.9.1
cat >>confdefs.h <<_ACEOF
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cfengine-3.9.0/configure.ac new/cfengine-3.9.1/configure.ac
--- old/cfengine-3.9.0/configure.ac 2016-06-06 12:01:06.000000000 +0200
+++ new/cfengine-3.9.1/configure.ac 2016-07-28 23:25:32.000000000 +0200
@@ -29,7 +29,7 @@
dnl #
dnl ##########################################################################
-AC_PREREQ(2.59)
+AC_PREREQ(2.63)
AC_INIT
AC_CONFIG_SRCDIR([libpromises/generic_agent.c])
@@ -41,18 +41,18 @@
dnl
AC_CHECK_PROG(MAKEINFO, makeinfo, makeinfo)
-m4_define([revision], m4_esyscmd_s([git rev-list -1 --abbrev-commit HEAD]))
+m4_define([revision], m4_normalize(m4_esyscmd([git rev-list -1 --abbrev-commit HEAD])))
-m4_define([cfversion_from_env], m4_esyscmd_s([echo $EXPLICIT_VERSION]))
-m4_ifblank(cfversion_from_env, [
- m4_define([cfversion_from_detect], m4_esyscmd_s([misc/determine-version.py]))
+m4_define([cfversion_from_env], m4_normalize(m4_esyscmd([echo $EXPLICIT_VERSION])))
+m4_ifval(cfversion_from_env, [
+ m4_define([cfversion], cfversion_from_env)
+], [
+ m4_define([cfversion_from_detect], m4_normalize(m4_esyscmd([misc/determine-version.py])))
m4_if(m4_sysval, 0, [], [
m4_fatal([Could not determine CFEngine version. Please set EXPLICIT_VERSION in the environment or make sure all git tags are up to date.])
])
m4_define([cfversion], cfversion_from_detect[]a1.revision)
m4_undefine([cfversion_from_detect])
-], [
- m4_define([cfversion], cfversion_from_env)
])
_AM_SET_OPTION([tar-ustar])
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cfengine-3.9.0/examples/randomint.cf new/cfengine-3.9.1/examples/randomint.cf
--- old/cfengine-3.9.0/examples/randomint.cf 2016-06-06 12:01:06.000000000 +0200
+++ new/cfengine-3.9.1/examples/randomint.cf 2016-07-28 23:25:32.000000000 +0200
@@ -21,12 +21,7 @@
# included file COSL.txt.
#+begin_src cfengine3
-body common control
-{
- bundlesequence => { "randomint_example" };
-}
-
-bundle agent randomint_example
+bundle agent main
{
vars:
"low" string => "4";
@@ -39,9 +34,20 @@
reports:
isabove::
"The generated random number was above 3";
+
+ show_random::
+ "Randomly generated '$(random)'";
}
#+end_src
###############################################################################
+#+begin_src show_random_example_output
+#@ ```
+#@ R: The generated random number was above 3
+#@ R: Randomly generated '9'
+#@ R: Randomly generated '52'
+#@ R: Randomly generated '26'
+#@ ```
+#+end_src
#+begin_src example_output
#@ ```
#@ R: The generated random number was above 3
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cfengine-3.9.0/examples/regline.cf new/cfengine-3.9.1/examples/regline.cf
--- old/cfengine-3.9.0/examples/regline.cf 2016-06-06 12:01:06.000000000 +0200
+++ new/cfengine-3.9.1/examples/regline.cf 2016-07-28 23:25:32.000000000 +0200
@@ -24,39 +24,43 @@
# Function regline(regex,file)
######################################################################
-body common control
-
-{
- version => "1.2.3";
- bundlesequence => { "example" };
-}
-
-########################################################
-
-bundle agent example
-
+#+begin_src cfengine3
+bundle agent main
+# @brief An example showing how to use regline to see if a pattern exists within
+# a file.
{
- files:
+ vars:
- "/tmp/testfile"
+ linux::
- edit_line => test;
+ "file" string => "/proc/sys/net/ipv4/ip_forward";
+ "reg_enabled" string => "^1$";
+ "reg_disabled" string => "^0$";
-}
+ classes:
-########################################################
+ linux::
-bundle edit_line test
-{
- classes:
+ "ipv4_forwarding_enabled" -> { "SecOps" }
+ expression => regline( $(reg_enabled) , $(file) ),
+ comment => "We want to know if ip forwarding is enabled because it is a
+ potential security issue.";
- "ok" expression => regline(".*mark.*","$(edit.filename)");
+ "ipv4_forwarding_disabled" -> { "SecOps" }
+ expression => regline( $(reg_disabled) , $(file) );
reports:
- ok::
-
- "File matched $(edit.filename)";
+ ipv4_forwarding_enabled::
+ "I found that IPv4 forwarding is enabled!";
+ ipv4_forwarding_disabled::
+ "I found that IPv4 forwarding is disabled.";
}
+#+end_src
+#+begin_src example_output
+#@ ```
+#@ R: I found that IPv4 forwarding is disabled.
+#@ ```
+#+end_src
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cfengine-3.9.0/examples/services.cf new/cfengine-3.9.1/examples/services.cf
--- old/cfengine-3.9.0/examples/services.cf 1970-01-01 01:00:00.000000000 +0100
+++ new/cfengine-3.9.1/examples/services.cf 2016-07-28 23:25:32.000000000 +0200
@@ -0,0 +1,56 @@
+body file control
+{
+ inputs => { "$(sys.libdir)/services.cf", "$(sys.libdir)/commands.cf" };
+}
+
+bundle agent main
+# @brief Example showing services promises to manage standard operating system
+# services
+{
+ vars:
+
+ linux::
+ "enable[ssh]"
+ string => ifelse( "debian|ubuntu", "ssh", "sshd"),
+ comment => "The name of the ssh service varies on different platforms.
+ Here we set the name of the service based on existing
+ classes and defaulting to `sshd`";
+
+ "disable[apache]"
+ string => ifelse( "debian|ubuntu", "apache2", "httpd" ),
+ comment => "The name of the apache web service varies on different
+ platforms. Here we set the name of the service based on
+ existing classes and defaulting to `httpd`";
+
+ "enable[cron]"
+ string => ifelse( "debian|ubuntu", "cron", "crond" ),
+ comment => "The name of the cron service varies on different
+ platforms. Here we set the name of the service based on
+ existing classes and defaulting to `crond`";
+
+ "disable[cups]"
+ string => "cups",
+ comment => "Printing services are not needed on most hosts.";
+
+ "enabled" slist => getvalues( enable );
+ "disabled" slist => getvalues( disable );
+
+ services:
+
+ linux::
+
+ "$(enabled)" -> { "SysOps" }
+ service_policy => "start",
+ comment => "These services should be running because x, y or z.";
+
+ "$(disabled)" -> { "SysOps" }
+ service_policy => "stop",
+ comment => "These services should not be running because x, y or z.";
+
+ systemd::
+
+ "sysstat"
+ service_policy => "stop",
+ comment => "Standard service handling for sysstat only works with
+ systemd. Other inits need cron entries managed.";
+}
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cfengine-3.9.0/libcfnet/conn_cache.c new/cfengine-3.9.1/libcfnet/conn_cache.c
--- old/cfengine-3.9.0/libcfnet/conn_cache.c 2016-06-06 12:01:06.000000000 +0200
+++ new/cfengine-3.9.1/libcfnet/conn_cache.c 2016-07-28 23:25:32.000000000 +0200
@@ -82,7 +82,7 @@
DisconnectServer(svp->conn);
}
- SeqClear(conn_cache);
+ SeqDestroy(conn_cache);
conn_cache = NULL;
ThreadUnlock(&cft_conncache);
diff -urN '--exclude=CVS' '--exclude=.cvsignore' '--exclude=.svn' '--exclude=.svnignore' old/cfengine-3.9.0/libenv/unix_iface.c new/cfengine-3.9.1/libenv/unix_iface.c
--- old/cfengine-3.9.0/libenv/unix_iface.c 2016-06-06 12:01:06.000000000 +0200
+++ new/cfengine-3.9.1/libenv/unix_iface.c 2016-07-28 23:25:33.000000000 +0200
@@ -1186,7 +1186,7 @@
EvalContextVariablePutSpecial(ctx, SPECIAL_SCOPE_SYS, "inet", inet, CF_DATA_TYPE_CONTAINER,
"inventory,networking,/proc,source=agent,attribute_name=none,procfs");
-
+ JsonDestroy(inet);
JsonElement *inet6 = JsonObjectCreate(3);
@@ -1247,12 +1247,14 @@
EvalContextVariablePutSpecial(ctx, SPECIAL_SCOPE_SYS, "inet6", inet6, CF_DATA_TYPE_CONTAINER,
"inventory,networking,/proc,source=agent,attribute_name=none,procfs");
+ JsonDestroy(inet6);
// Inter-| Receive | Transmit
// face |bytes packets errs drop fifo frame compressed multicast|bytes packets errs drop fifo colls carrier compressed
// eth0: 74850544807 75236137 0 0 0 0 0 1108775 63111535625 74696758 0 0 0 0 0 0
BufferPrintf(pbuf, "%s/proc/net/dev", procdir);
+ JsonElement *interfaces_data =
GetProcFileInfo(ctx, BufferData(pbuf), "interfaces_data", "device", NULL,
"^\\s*(?<device>[^:]+)\\s*:\\s*"
// All of the below are just decimal digits separated by spaces
@@ -1272,7 +1274,7 @@
"(?
participants (1)
-
root@hilbert.suse.de