pkgsrc-Changes-HG archive

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]

[pkgsrc/trunk]: pkgsrc/security/polkit polkit: update to 0.114.



details:   https://anonhg.NetBSD.org/pkgsrc/rev/17aaf1b36f97
branches:  trunk
changeset: 306891:17aaf1b36f97
user:      wiz <wiz%pkgsrc.org@localhost>
date:      Sun Apr 29 05:14:36 2018 +0000
description:
polkit: update to 0.114.

--------------
polkit 0.114
--------------

WARNING WARNING WARNING: This is a prerelease on the road to polkit
1.0. Public API might change and certain parts of the code still needs
some security review. Use at your own risk.

This is polkit 0.114.

Highlights:
 Port to mozjs 52, the latest version of the firefox JavaScript engine.

 Add gettext support for policy files

 Fixes for various memory leaks

Build requirements

 glib, gobject, gio    >= 2.32
 mozjs-52
 gobject-introspection >= 0.6.2 (optional)
 pam (optional)
 ConsoleKit OR systemd

Changes since polkit 0.113:

Anders Jonsson (2):
      pkcheck: fix man typos
      Add Swedish translation

Antoine Jacoutot (1):
      Add support for OpenBSD

Christian Kirbach (1):
      Add German translation

Colin Walters (3):
      build: Pull in GCC warning infra from ostree
      build: Use AC_USE_SYSTEM_EXTENSIONS
      tests: Correct boundary test for overflow

Dariusz Gadomski (2):
      Fix multi-line pam text info.
      Refactor send_to_helper usage

Gabor Kelemen (1):
      Add initial Hungarian translation, and add hu to LINGUAS

Jeremy Linton (5):
      change mozjs interface module to c++
      Switch to hard requiring mozjs24
      Fix warnings caused by building with C++
      Replace autocompartment
      test: Add a test case to handle actions without explicit rules

Ji?? Klime? (1):
      trivial: fix deprecated indication for polkit_agent_register_listener()

Matthias Clasen (1):
      Add gettext support for .policy files

Miloslav Trma? (21):
      Post-release version bump to 0.114
      Consistently use HAVE_NETGROUP_H instead of HAVE_OPENBSD
      Fix a memory leak of PolkitAgentListener's Server object
      Remove polkitbackendconfigsource.[ch]
      Add Slovak translation by Dusan Kazik <prescott66%gmail.com@localhost>
      Add Indonesian translation by Andika Triwidada
      Add Chinese (Taiwan) translation
      Fix a typo in polkit(8)
      Simplify GVariant reference counting
      Fix a memory leak on an error path of lookup_asv (twice)
      Fix a memory leak in server_handle_register_authentication_agent_with_options
      Fix a memory leak in server_handle_unregister_authentication_agent
      Fix a memory leak in server_handle_authentication_agent_response{,2}
      Fix memory leaks in server_handle_*_temporary_authorizations
      Fix error handling in polkit_authority_enumerate_temporary_authorizations_finish
      Fix a memory leak per agent authentication
      Fix a memory leak on agent authentication cancellation
      Audit and fix GVariant reference counting
      Fix help for (pkttyagent -s)
      Fix a race condition when terminating runaway_killer_thread
      Move to current GLib

Mingye Wang (Arthur2e5) (1):
      Add zh_CN translation

Muhammet Kara (1):
      Added Turkish translation

OBATA Akio (1):
      Add support for NetBSD

Peter Hutterer (1):
      gettext: switch to default-translate "no"

Philip Withnall (3):
      polkit: Add g_autoptr() support for GObject-derived polkit types
      data: Set GIO_USE_VFS=local in the environment
      polkitbackend: Fix typos in a couple of initialisation error messages

Piotr Dr?g (1):
      Add Polish translation

Rafael Fontenelle (1):
      Add Brazilian Portuguese translation

Ray Strode (34):
      configure: bump mozjs requirement to 52
      jsauthority: fix how classes are defined
      jsauthority: use JS_FN instead of JS_FS
      jsauthority: get rid of JSRuntime
      jsauthority: change how setVersion is called
      jsauthority: call JS_Init
      jsauthority: call JS_InitSelfHostedCode
      jsauthority: change how JIT is disabled
      jsauthority: JS::SetWarningReporter instead of JS_SetErrorReporter
      jsauthority: add UTF8 suffix to renamed functions
      jsauthority: pass "%s" format string to report functions
      jsauthority: s/JSBool/bool/
      jsauthority: s/jsval/JS::Value/
      jsauthority: s/JSVAL_NULL/JS::NullValue()/
      jsauthority: s/JSVAL_VOID/JS::UndefinedValue()/
      jsauthority: s/OBJECT_TO_JSVAL/JS::ObjectValue/
      jsauthority: s/STRING_TO_JSVAL/JS::StringValue/
      jsauthority: s/BOOLEAN_TO_JSVAL/JS::BooleanValue/
      jsauthority: JSVAL_TO_OBJECT (o) to o.toObjectOrNull()
      jsauthority: JSVAL_TO_STRING (s) to s.toString()
      jsauthority: JSVAL_IS_STRING (s) to s.isString()
      jsauthority: JSVAL_IS_NULL (o) to o.isNull()
      jsauthority: Fix up JS_CallFunctionName invocations
      jsauthority: use InterruptCallback api instead of OperationCallback
      jsauthority: redo how global objects are set up
      jsauthority: root some locals to the context
      jsauthority: adapt arguments for new JS::Compile API
      jsauthority: adapt arguments for new JS_ExecuteScript API
      jsauthority: use JS::Evaluate instead of JS_EvaluateScript
      jsauthority: fix up set_property methods
      jsauthority: stop using JS_GetStringCharsZ
      jsauthority: switch from JS_ConvertArguments to JS::CallArgsFromVp
      jsauthority: re-enable JIT
      Port JavaScript authority to mozjs52

Rui Matos (1):
      polkitpermission: Fix a memory leak on authority changes

Sebastien Bacher (1):
      Support polkit session agent running outside user session

Stef Walter (2):
      polkitagent: Fix access after dereference on hashtable
      polkitagent: No double warnings in polkit_agent_listener_register()

Sven Eden (1):
      configure: enable elogind support in PolicyKit

Yuri Chornoivan (1):
      Add Ukrainian translation

enkore (1):
      Fix abnomal formatting of authentication header lines

muzena (1):
      Add hr.po

Thanks to our contributors.

Colin Walters and Miloslav Trma?,
April 2, 2017

diffstat:

 security/polkit/Makefile                                                            |   12 +-
 security/polkit/PLIST                                                               |   18 +-
 security/polkit/distinfo                                                            |   18 +-
 security/polkit/options.mk                                                          |    3 +-
 security/polkit/patches/patch-src_polkit_polkitunixprocess.c                        |  215 ----------
 security/polkit/patches/patch-src_polkitbackend_polkitbackendinteractiveauthority.c |   15 +-
 security/polkit/patches/patch-src_polkitbackend_polkitbackendjsauthority.c          |  107 ----
 security/polkit/patches/patch-src_polkitbackend_polkitd.c                           |   12 +-
 security/polkit/patches/patch-src_programs_pkttyagent.c                             |    8 +-
 9 files changed, 50 insertions(+), 358 deletions(-)

diffs (truncated from 564 to 300 lines):

diff -r ce0c90d1aaf3 -r 17aaf1b36f97 security/polkit/Makefile
--- a/security/polkit/Makefile  Sun Apr 29 05:11:44 2018 +0000
+++ b/security/polkit/Makefile  Sun Apr 29 05:14:36 2018 +0000
@@ -1,8 +1,6 @@
-# $NetBSD: Makefile,v 1.8 2017/10/15 23:19:12 prlw1 Exp $
-#
+# $NetBSD: Makefile,v 1.9 2018/04/29 05:14:36 wiz Exp $
 
-DISTNAME=      polkit-0.113
-PKGREVISION=   3
+DISTNAME=      polkit-0.114
 CATEGORIES=    security
 MASTER_SITES=  http://www.freedesktop.org/software/polkit/releases/
 
@@ -15,6 +13,7 @@
 BUILD_DEPENDS+=                docbook-xsl-[0-9]*:../../textproc/docbook-xsl
 
 GNU_CONFIGURE=         yes
+USE_LANGUAGES=         c c++11
 USE_LIBTOOL=           yes
 USE_PKGLOCALEDIR=      yes
 USE_TOOLS+=            pkg-config intltool gmake msgfmt perl
@@ -25,6 +24,7 @@
 CONFIGURE_ARGS+=       --sysconfdir=${PKG_SYSCONFDIR}
 CONFIGURE_ARGS+=       --with-polkitd-user=${POLKITD_USER}
 CONFIGURE_ARGS+=       --disable-libsystemd-login
+CONFIGURE_ARGS+=       --disable-libelogind
 
 .include "../../mk/bsd.prefs.mk"
 
@@ -37,6 +37,8 @@
 PKG_GROUPS_VARS+=              POLKITD_GROUP
 PKG_USERS_VARS+=               POLKITD_USER
 
+BUILD_DEFS+=           VARBASE
+
 REPLACE_PERL+=         src/polkitbackend/toarray.pl
 
 INSTALL_MAKE_FLAGS+=   sysconfdir=${PREFIX}/share/examples/polkit
@@ -62,7 +64,7 @@
 SUBST_FILES.paths+=    src/examples/org.freedesktop.policykit.examples.pkexec.policy.in
 SUBST_SED.paths+=      -e 's,/usr/bin/,${PREFIX}/bin/,g'
 
-.include "../../lang/spidermonkey17/buildlink3.mk"
+.include "../../lang/spidermonkey52/buildlink3.mk"
 .include "../../devel/gettext-lib/buildlink3.mk"
 .include "../../devel/glib2/buildlink3.mk"
 .include "../../textproc/expat/buildlink3.mk"
diff -r ce0c90d1aaf3 -r 17aaf1b36f97 security/polkit/PLIST
--- a/security/polkit/PLIST     Sun Apr 29 05:11:44 2018 +0000
+++ b/security/polkit/PLIST     Sun Apr 29 05:14:36 2018 +0000
@@ -1,4 +1,4 @@
-@comment $NetBSD: PLIST,v 1.1 2016/05/20 18:39:33 youri Exp $
+@comment $NetBSD: PLIST,v 1.2 2018/04/29 05:14:36 wiz Exp $
 bin/pk-example-frobnicate
 bin/pkaction
 bin/pkcheck
@@ -47,12 +47,26 @@
 man/man8/polkit.8
 man/man8/polkitd.8
 share/dbus-1/system-services/org.freedesktop.PolicyKit1.service
+share/examples/polkit/dbus-1/system.d/org.freedesktop.PolicyKit1.conf
 ${PLIST.pam}share/examples/pam.d/polkit-1
-share/examples/polkit/dbus-1/system.d/org.freedesktop.PolicyKit1.conf
 share/examples/polkit/polkit-1/rules.d/50-default.rules
+share/gettext/its/polkit.its
+share/gettext/its/polkit.loc
 ${PLIST.introspection}share/gir-1.0/Polkit-1.0.gir
 ${PLIST.introspection}share/gir-1.0/PolkitAgent-1.0.gir
 share/locale/cs/LC_MESSAGES/polkit-1.mo
 share/locale/da/LC_MESSAGES/polkit-1.mo
+share/locale/de/LC_MESSAGES/polkit-1.mo
+share/locale/hr/LC_MESSAGES/polkit-1.mo
+share/locale/hu/LC_MESSAGES/polkit-1.mo
+share/locale/id/LC_MESSAGES/polkit-1.mo
+share/locale/pl/LC_MESSAGES/polkit-1.mo
+share/locale/pt_BR/LC_MESSAGES/polkit-1.mo
+share/locale/sk/LC_MESSAGES/polkit-1.mo
+share/locale/sv/LC_MESSAGES/polkit-1.mo
+share/locale/tr/LC_MESSAGES/polkit-1.mo
+share/locale/uk/LC_MESSAGES/polkit-1.mo
+share/locale/zh_CN/LC_MESSAGES/polkit-1.mo
+share/locale/zh_TW/LC_MESSAGES/polkit-1.mo
 share/polkit-1/actions/org.freedesktop.policykit.examples.pkexec.policy
 share/polkit-1/actions/org.freedesktop.policykit.policy
diff -r ce0c90d1aaf3 -r 17aaf1b36f97 security/polkit/distinfo
--- a/security/polkit/distinfo  Sun Apr 29 05:11:44 2018 +0000
+++ b/security/polkit/distinfo  Sun Apr 29 05:14:36 2018 +0000
@@ -1,15 +1,13 @@
-$NetBSD: distinfo,v 1.4 2016/12/03 01:58:49 marino Exp $
+$NetBSD: distinfo,v 1.5 2018/04/29 05:14:36 wiz Exp $
 
-SHA1 (polkit-0.113.tar.gz) = ef855c2d04184dceb38e0940dc7bec9cc3da415c
-RMD160 (polkit-0.113.tar.gz) = 661b0a678f7c770c213404db3af604935fdb25bc
-SHA512 (polkit-0.113.tar.gz) = ab177c89a20eeb2978ddbe28afb205d3619f9c5defe833eb68a85e71a0f2c905367f1295cbbfb85da5eafdd661bce474d5d84aca9195cd425a18c9b4170eb5f9
-Size (polkit-0.113.tar.gz) = 1448865 bytes
-SHA1 (patch-src_polkit_polkitunixprocess.c) = dbfdfd441b211c80183ea5c63a20252c58a594b2
-SHA1 (patch-src_polkitbackend_polkitbackendinteractiveauthority.c) = d8b7cbcd0db26969bc4b83c32a731ae920c2e87b
-SHA1 (patch-src_polkitbackend_polkitbackendjsauthority.c) = f0771b27e192ed199c65ed7514962ec5a8cb28a4
-SHA1 (patch-src_polkitbackend_polkitd.c) = a567b31131f63f92f8e2967c3aabfa7f3d41f627
+SHA1 (polkit-0.114.tar.gz) = f29deef0076e76588f209a028a3e33ef70c2d9cd
+RMD160 (polkit-0.114.tar.gz) = 000749a5f902b9be347f462d486bed20f8bbe8d5
+SHA512 (polkit-0.114.tar.gz) = 49cdf9dd3663714b1c6569ad8740cb413d9c5bd5c11e4bdbba3ce82b744f36638b652547edff9203caab9287834bc68a1d6a4895ec7a188fa1524dc1e9c9b4ea
+Size (polkit-0.114.tar.gz) = 1557340 bytes
+SHA1 (patch-src_polkitbackend_polkitbackendinteractiveauthority.c) = dd91b4e74e6c39f24e0f5a9b3150fdac12899cb5
+SHA1 (patch-src_polkitbackend_polkitd.c) = b8e11b40e2b171d4f030eb4c4cbc6fdc7a96b2c2
 SHA1 (patch-src_programs_pkexec.c) = bfc0414c7a943c8e8b8412566a2519198eab8abd
-SHA1 (patch-src_programs_pkttyagent.c) = 72a1c3750e6b496b981eb5479201946da80b6d15
+SHA1 (patch-src_programs_pkttyagent.c) = 4dbffd02c7e66910d4104a75d6f5f437bd51acc9
 SHA1 (patch-test_mocklib_src_netdb.c) = 0fe71068a6261d5e2c8874f2b4507e7e3c002526
 SHA1 (patch-test_mocklibc_src_grp.c) = 435ff94fd4c7f5511d74d03839fad453dd841633
 SHA1 (patch-test_mocklibc_src_pwd.c) = c65b02209db1bd1d531444026822fcca73d5027a
diff -r ce0c90d1aaf3 -r 17aaf1b36f97 security/polkit/options.mk
--- a/security/polkit/options.mk        Sun Apr 29 05:11:44 2018 +0000
+++ b/security/polkit/options.mk        Sun Apr 29 05:14:36 2018 +0000
@@ -1,4 +1,4 @@
-# $NetBSD: options.mk,v 1.2 2016/06/13 23:06:46 youri Exp $
+# $NetBSD: options.mk,v 1.3 2018/04/29 05:14:36 wiz Exp $
 
 PKG_OPTIONS_VAR=       PKG_OPTIONS.polkit
 PKG_SUPPORTED_OPTIONS= introspection pam
@@ -22,7 +22,6 @@
 CONFIGURE_ARGS+=       --with-authfw=pam
 CONFIGURE_ARGS+=       --with-pam-module-dir=${PREFIX}/lib/security
 PLIST.pam=     yes
-.include "../../mk/bsd.prefs.mk"
 .  if ${OPSYS} == "NetBSD"
 CONFIGURE_ARGS+=       --with-pam-include=system
 .  endif
diff -r ce0c90d1aaf3 -r 17aaf1b36f97 security/polkit/patches/patch-src_polkit_polkitunixprocess.c
--- a/security/polkit/patches/patch-src_polkit_polkitunixprocess.c      Sun Apr 29 05:11:44 2018 +0000
+++ /dev/null   Thu Jan 01 00:00:00 1970 +0000
@@ -1,215 +0,0 @@
-$NetBSD: patch-src_polkit_polkitunixprocess.c,v 1.2 2016/06/18 12:16:23 youri Exp $
-
-* NetBSD support
-* SunOS support
-
---- src/polkit/polkitunixprocess.c.orig        2014-01-14 22:42:25.000000000 +0000
-+++ src/polkit/polkitunixprocess.c
-@@ -29,10 +29,19 @@
- #include <sys/sysctl.h>
- #include <sys/user.h>
- #endif
-+#ifdef __NetBSD__
-+#include <sys/param.h>
-+#include <sys/sysctl.h>
-+#endif
- #include <stdlib.h>
- #include <string.h>
- #include <errno.h>
- #include <stdio.h>
-+#include <fcntl.h>
-+
-+#ifdef HAVE_SOLARIS
-+#include <procfs.h>
-+#endif
- 
- #include "polkitunixprocess.h"
- #include "polkitsubject.h"
-@@ -80,7 +89,7 @@ enum
- 
- static void subject_iface_init (PolkitSubjectIface *subject_iface);
- 
--static guint64 get_start_time_for_pid (gint    pid,
-+static guint64 get_start_time_for_pid (pid_t    pid,
-                                        GError **error);
- 
- static gint _polkit_unix_process_get_owner (PolkitUnixProcess  *process,
-@@ -89,6 +98,9 @@ static gint _polkit_unix_process_get_own
- #ifdef HAVE_FREEBSD
- static gboolean get_kinfo_proc (gint pid, struct kinfo_proc *p);
- #endif
-+#if defined(__NetBSD__)
-+static gboolean get_kinfo_proc (gint pid, struct kinfo_proc2 *p);
-+#endif
- 
- G_DEFINE_TYPE_WITH_CODE (PolkitUnixProcess, polkit_unix_process, G_TYPE_OBJECT,
-                          G_IMPLEMENT_INTERFACE (POLKIT_TYPE_SUBJECT, subject_iface_init)
-@@ -514,17 +526,17 @@ subject_iface_init (PolkitSubjectIface *
- 
- #ifdef HAVE_SOLARIS
- static int
--get_pid_psinfo (pid_t pid, struct psinfo *ps)
-+get_pid_psinfo (pid_t pid, psinfo_t *ps)
- {
-   char pname[32];
-   int  procfd;
- 
--  (void) snprintf(pname, sizeof(pname), "/proc/%d/psinfo", pid);
-+  (void) snprintf(pname, sizeof(pname), "/proc/%lu/psinfo", pid);
-   if ((procfd = open(pname, O_RDONLY)) == -1)
-     {
-       return -1;
-     }
--  if (read(procfd, ps, sizeof(struct psinfo)) < 0)
-+  if (read(procfd, ps, sizeof(psinfo_t)) < 0)
-     {
-       (void) close(procfd);
-       return -1;
-@@ -554,12 +566,38 @@ get_kinfo_proc (pid_t pid, struct kinfo_
- }
- #endif
- 
-+#ifdef __NetBSD__
-+static gboolean
-+get_kinfo_proc (pid_t pid, struct kinfo_proc2 *p)
-+{
-+  int name[6];
-+  u_int namelen;
-+  size_t sz;
-+
-+  sz = sizeof(*p);
-+  namelen = 0;
-+  name[namelen++] = CTL_KERN;
-+  name[namelen++] = KERN_PROC2;
-+  name[namelen++] = KERN_PROC_PID;
-+  name[namelen++] = pid;
-+  name[namelen++] = sz;
-+  name[namelen++] = 1;
-+
-+  if (sysctl (name, namelen, p, &sz, NULL, 0) == -1) {
-+    perror("sysctl kern.proc2.pid");
-+    return FALSE;
-+  }
-+
-+  return TRUE;
-+}
-+#endif
-+
- static guint64
- get_start_time_for_pid (pid_t    pid,
-                         GError **error)
- {
-   guint64 start_time;
--#ifndef HAVE_FREEBSD
-+#if !defined(HAVE_FREEBSD) || !defined(__NetBSD__)
-   gchar *filename;
-   gchar *contents;
-   size_t length;
-@@ -571,7 +609,7 @@ get_start_time_for_pid (pid_t    pid,
-   start_time = 0;
-   contents = NULL;
- 
--  filename = g_strdup_printf ("/proc/%d/stat", pid);
-+  filename = g_strdup_printf ("/proc/%lu/stat", pid);
- 
-   if (!g_file_get_contents (filename, &contents, &length, error))
-     goto out;
-@@ -631,8 +669,8 @@ get_start_time_for_pid (pid_t    pid,
-  out:
-   g_free (filename);
-   g_free (contents);
--#else
--  struct kinfo_proc p;
-+#elif defined(__NetBSD__)
-+  struct kinfo_proc2 p;
- 
-   start_time = 0;
- 
-@@ -647,9 +685,43 @@ get_start_time_for_pid (pid_t    pid,
-       goto out;
-     }
- 
-+  start_time = (guint64) p.p_ustart_sec;
-+
-+out:
-+
-+#elif HAVE_FREEBSD
-+  struct kinfo_proc p;
-+
-+  if (! get_kinfo_proc (pid, &p))
-+    {
-+      g_set_error (error,
-+                   POLKIT_ERROR,
-+                   POLKIT_ERROR_FAILED,
-+                   "Error obtaining start time for %d (%s)",
-+                   (gint) pid,
-+                   g_strerror (errno));
-+      goto out;
-+    }
-+
-   start_time = (guint64) p.ki_start.tv_sec;
- 
- out:
-+#elif HAVE_SOLARIS
-+  psinfo_t p;
-+  if (!get_pid_psinfo (pid, &p))
-+    {
-+      g_set_error (error,
-+                   POLKIT_ERROR,
-+                   POLKIT_ERROR_FAILED,
-+                   "Error obtaining start time for %d (%s)",
-+                   (gint) pid,
-+                   g_strerror (errno));
-+      goto out;
-+    }
-+  start_time = (guint64) p.pr_start.tv_sec;
-+out:
-+#else



Home | Main Index | Thread Index | Old Index