From b779dbac721a008647a7fd646a3e19cbbb6b0e73 Mon Sep 17 00:00:00 2001 From: 宋文武 Date: Tue, 13 Nov 2018 21:36:01 +0800 Subject: gnu: Add liblcf. * gnu/packages/easyrpg.scm: New file. * gnu/local.mk (GNU_SYSTEM_MODULES): Add it. --- gnu/local.mk | 1 + 1 file changed, 1 insertion(+) (limited to 'gnu/local.mk') diff --git a/gnu/local.mk b/gnu/local.mk index ae3aee7c21..42b13d1aec 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -146,6 +146,7 @@ GNU_SYSTEM_MODULES = \ %D%/packages/documentation.scm \ %D%/packages/dunst.scm \ %D%/packages/dvtm.scm \ + %D%/packages/easyrpg.scm \ %D%/packages/ebook.scm \ %D%/packages/ed.scm \ %D%/packages/education.scm \ -- cgit 1.4.1 From 5d3f673db4f866564b4226046a266de36dc21dbd Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Wed, 5 Dec 2018 18:35:36 -0500 Subject: gnu: polkit: Fix CVE-2018-19788. * gnu/packages/patches/polkit-CVE-2018-19788.patch: New file. * gnu/local.mk (dist_patch_DATA): Add it. * gnu/packages/polkit.scm (polkit)[source]: Use it. --- gnu/local.mk | 1 + gnu/packages/patches/polkit-CVE-2018-19788.patch | 197 +++++++++++++++++++++++ gnu/packages/polkit.scm | 1 + 3 files changed, 199 insertions(+) create mode 100644 gnu/packages/patches/polkit-CVE-2018-19788.patch (limited to 'gnu/local.mk') diff --git a/gnu/local.mk b/gnu/local.mk index 42b13d1aec..1f368aba71 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1063,6 +1063,7 @@ dist_patch_DATA = \ %D%/packages/patches/plink-endian-detection.patch \ %D%/packages/patches/plotutils-libpng-jmpbuf.patch \ %D%/packages/patches/podofo-cmake-3.12.patch \ + %D%/packages/patches/polkit-CVE-2018-19788.patch \ %D%/packages/patches/poppler-CVE-2018-19149.patch \ %D%/packages/patches/portaudio-audacity-compat.patch \ %D%/packages/patches/portmidi-modular-build.patch \ diff --git a/gnu/packages/patches/polkit-CVE-2018-19788.patch b/gnu/packages/patches/polkit-CVE-2018-19788.patch new file mode 100644 index 0000000000..58cde6c5dc --- /dev/null +++ b/gnu/packages/patches/polkit-CVE-2018-19788.patch @@ -0,0 +1,197 @@ +Fix CVE-2018-19788: + +https://cve.mitre.org/cgi-bin/cvename.cgi?name=CVE-2018-19788 +https://gitlab.freedesktop.org/polkit/polkit/issues/74 + +Patch copied from upstream source repository: + +https://gitlab.freedesktop.org/polkit/polkit/commit/2cb40c4d5feeaa09325522bd7d97910f1b59e379 + +From 2cb40c4d5feeaa09325522bd7d97910f1b59e379 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?Zbigniew=20J=C4=99drzejewski-Szmek?= +Date: Mon, 3 Dec 2018 10:28:58 +0100 +Subject: [PATCH] Allow negative uids/gids in PolkitUnixUser and Group objects + +(uid_t) -1 is still used as placeholder to mean "unset". This is OK, since +there should be no users with such number, see +https://systemd.io/UIDS-GIDS#special-linux-uids. + +(uid_t) -1 is used as the default value in class initialization. + +When a user or group above INT32_MAX is created, the numeric uid or +gid wraps around to negative when the value is assigned to gint, and +polkit gets confused. Let's accept such gids, except for -1. + +A nicer fix would be to change the underlying type to e.g. uint32 to +not have negative values. But this cannot be done without breaking the +API, so likely new functions will have to be added (a +polkit_unix_user_new variant that takes a unsigned, and the same for +_group_new, _set_uid, _get_uid, _set_gid, _get_gid, etc.). This will +require a bigger patch. + +Fixes https://gitlab.freedesktop.org/polkit/polkit/issues/74. +--- + src/polkit/polkitunixgroup.c | 15 +++++++++++---- + src/polkit/polkitunixprocess.c | 12 ++++++++---- + src/polkit/polkitunixuser.c | 13 ++++++++++--- + 3 files changed, 29 insertions(+), 11 deletions(-) + +diff --git a/src/polkit/polkitunixgroup.c b/src/polkit/polkitunixgroup.c +index c57a1aa..309f689 100644 +--- a/src/polkit/polkitunixgroup.c ++++ b/src/polkit/polkitunixgroup.c +@@ -71,6 +71,7 @@ G_DEFINE_TYPE_WITH_CODE (PolkitUnixGroup, polkit_unix_group, G_TYPE_OBJECT, + static void + polkit_unix_group_init (PolkitUnixGroup *unix_group) + { ++ unix_group->gid = -1; /* (git_t) -1 is not a valid GID under Linux */ + } + + static void +@@ -100,11 +101,14 @@ polkit_unix_group_set_property (GObject *object, + GParamSpec *pspec) + { + PolkitUnixGroup *unix_group = POLKIT_UNIX_GROUP (object); ++ gint val; + + switch (prop_id) + { + case PROP_GID: +- unix_group->gid = g_value_get_int (value); ++ val = g_value_get_int (value); ++ g_return_if_fail (val != -1); ++ unix_group->gid = val; + break; + + default: +@@ -131,9 +135,9 @@ polkit_unix_group_class_init (PolkitUnixGroupClass *klass) + g_param_spec_int ("gid", + "Group ID", + "The UNIX group ID", +- 0, ++ G_MININT, + G_MAXINT, +- 0, ++ -1, + G_PARAM_CONSTRUCT | + G_PARAM_READWRITE | + G_PARAM_STATIC_NAME | +@@ -166,9 +170,10 @@ polkit_unix_group_get_gid (PolkitUnixGroup *group) + */ + void + polkit_unix_group_set_gid (PolkitUnixGroup *group, +- gint gid) ++ gint gid) + { + g_return_if_fail (POLKIT_IS_UNIX_GROUP (group)); ++ g_return_if_fail (gid != -1); + group->gid = gid; + } + +@@ -183,6 +188,8 @@ polkit_unix_group_set_gid (PolkitUnixGroup *group, + PolkitIdentity * + polkit_unix_group_new (gint gid) + { ++ g_return_val_if_fail (gid != -1, NULL); ++ + return POLKIT_IDENTITY (g_object_new (POLKIT_TYPE_UNIX_GROUP, + "gid", gid, + NULL)); +diff --git a/src/polkit/polkitunixprocess.c b/src/polkit/polkitunixprocess.c +index 972b777..b02b258 100644 +--- a/src/polkit/polkitunixprocess.c ++++ b/src/polkit/polkitunixprocess.c +@@ -159,9 +159,14 @@ polkit_unix_process_set_property (GObject *object, + polkit_unix_process_set_pid (unix_process, g_value_get_int (value)); + break; + +- case PROP_UID: +- polkit_unix_process_set_uid (unix_process, g_value_get_int (value)); ++ case PROP_UID: { ++ gint val; ++ ++ val = g_value_get_int (value); ++ g_return_if_fail (val != -1); ++ polkit_unix_process_set_uid (unix_process, val); + break; ++ } + + case PROP_START_TIME: + polkit_unix_process_set_start_time (unix_process, g_value_get_uint64 (value)); +@@ -239,7 +244,7 @@ polkit_unix_process_class_init (PolkitUnixProcessClass *klass) + g_param_spec_int ("uid", + "User ID", + "The UNIX user ID", +- -1, ++ G_MININT, + G_MAXINT, + -1, + G_PARAM_CONSTRUCT | +@@ -303,7 +308,6 @@ polkit_unix_process_set_uid (PolkitUnixProcess *process, + gint uid) + { + g_return_if_fail (POLKIT_IS_UNIX_PROCESS (process)); +- g_return_if_fail (uid >= -1); + process->uid = uid; + } + +diff --git a/src/polkit/polkitunixuser.c b/src/polkit/polkitunixuser.c +index 8bfd3a1..234a697 100644 +--- a/src/polkit/polkitunixuser.c ++++ b/src/polkit/polkitunixuser.c +@@ -72,6 +72,7 @@ G_DEFINE_TYPE_WITH_CODE (PolkitUnixUser, polkit_unix_user, G_TYPE_OBJECT, + static void + polkit_unix_user_init (PolkitUnixUser *unix_user) + { ++ unix_user->uid = -1; /* (uid_t) -1 is not a valid UID under Linux */ + unix_user->name = NULL; + } + +@@ -112,11 +113,14 @@ polkit_unix_user_set_property (GObject *object, + GParamSpec *pspec) + { + PolkitUnixUser *unix_user = POLKIT_UNIX_USER (object); ++ gint val; + + switch (prop_id) + { + case PROP_UID: +- unix_user->uid = g_value_get_int (value); ++ val = g_value_get_int (value); ++ g_return_if_fail (val != -1); ++ unix_user->uid = val; + break; + + default: +@@ -144,9 +148,9 @@ polkit_unix_user_class_init (PolkitUnixUserClass *klass) + g_param_spec_int ("uid", + "User ID", + "The UNIX user ID", +- 0, ++ G_MININT, + G_MAXINT, +- 0, ++ -1, + G_PARAM_CONSTRUCT | + G_PARAM_READWRITE | + G_PARAM_STATIC_NAME | +@@ -182,6 +186,7 @@ polkit_unix_user_set_uid (PolkitUnixUser *user, + gint uid) + { + g_return_if_fail (POLKIT_IS_UNIX_USER (user)); ++ g_return_if_fail (uid != -1); + user->uid = uid; + } + +@@ -196,6 +201,8 @@ polkit_unix_user_set_uid (PolkitUnixUser *user, + PolkitIdentity * + polkit_unix_user_new (gint uid) + { ++ g_return_val_if_fail (uid != -1, NULL); ++ + return POLKIT_IDENTITY (g_object_new (POLKIT_TYPE_UNIX_USER, + "uid", uid, + NULL)); +-- +2.18.1 + diff --git a/gnu/packages/polkit.scm b/gnu/packages/polkit.scm index 7cc5205faa..830006d439 100644 --- a/gnu/packages/polkit.scm +++ b/gnu/packages/polkit.scm @@ -49,6 +49,7 @@ (uri (string-append "https://www.freedesktop.org/software/polkit/releases/" name "-" version ".tar.gz")) + (patches (search-patches "polkit-CVE-2018-19788.patch")) (sha256 (base32 "0c91y61y4gy6p91cwbzg32dhavw4b7fflg370rimqhdxpzdfr1rg")) -- cgit 1.4.1 From accb5c310001339bb4956632db89b1654c6431f1 Mon Sep 17 00:00:00 2001 From: Gábor Boskovits Date: Sun, 9 Dec 2018 12:41:15 +0100 Subject: gnu: openjdk: Make idlj respect SOURCE_DATE_EPOCH. * gnu/packages/patches/openjdk-10-idlj-reproducibility.patch: New file. * gnu/packages/java.scm (openjdk10)[source]: Use it. * gnu/locale.mk (dist_patch_DATA): Register it. --- gnu/local.mk | 1 + gnu/packages/java.scm | 2 ++ .../patches/openjdk-10-idlj-reproducibility.patch | 36 ++++++++++++++++++++++ 3 files changed, 39 insertions(+) create mode 100644 gnu/packages/patches/openjdk-10-idlj-reproducibility.patch (limited to 'gnu/local.mk') diff --git a/gnu/local.mk b/gnu/local.mk index 1f368aba71..50fc08445f 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -1019,6 +1019,7 @@ dist_patch_DATA = \ %D%/packages/patches/openbabel-fix-crash-on-nwchem-output.patch \ %D%/packages/patches/opencascade-oce-glibc-2.26.patch \ %D%/packages/patches/openfoam-4.1-cleanup.patch \ + %D%/packages/patches/openjdk-10-idlj-reproducibility.patch \ %D%/packages/patches/openldap-CVE-2017-9287.patch \ %D%/packages/patches/openocd-nrf52.patch \ %D%/packages/patches/opensmtpd-fix-crash.patch \ diff --git a/gnu/packages/java.scm b/gnu/packages/java.scm index a09bcfabe5..951c1f4fd3 100644 --- a/gnu/packages/java.scm +++ b/gnu/packages/java.scm @@ -1820,6 +1820,8 @@ new Date();")) (sha256 (base32 "0zywq2203b4hx4jms9vbwvjcj1d3k2v3qpx4s33729fkpmid97r4")) + (patches (search-patches + "openjdk-10-idlj-reproducibility.patch")) (modules '((guix build utils))) (snippet `(begin diff --git a/gnu/packages/patches/openjdk-10-idlj-reproducibility.patch b/gnu/packages/patches/openjdk-10-idlj-reproducibility.patch new file mode 100644 index 0000000000..b29a06f272 --- /dev/null +++ b/gnu/packages/patches/openjdk-10-idlj-reproducibility.patch @@ -0,0 +1,36 @@ +From a0a0c6a43b88d946f2b5484892cf0209bd7c0e68 Mon Sep 17 00:00:00 2001 +From: =?UTF-8?q?G=C3=A1bor=20Boskovits?= +Date: Sat, 8 Dec 2018 21:25:31 +0100 +Subject: [PATCH] Make idlj respect SOURCE_DATE_EPOCH. + +--- + .../sun/tools/corba/se/idl/toJavaPortable/Util.java | 13 ++++++++++++- + 1 file changed, 12 insertions(+), 1 deletion(-) + +diff --git a/src/java.corba/share/classes/com/sun/tools/corba/se/idl/toJavaPortable/Util.java b/src/java.corba/share/classes/com/sun/tools/corba/se/idl/toJavaPortable/Util.java +index 7397619f2..583d6b8e4 100644 +--- a/src/java.corba/share/classes/com/sun/tools/corba/se/idl/toJavaPortable/Util.java ++++ b/src/java.corba/share/classes/com/sun/tools/corba/se/idl/toJavaPortable/Util.java +@@ -1146,7 +1146,18 @@ public class Util extends com.sun.tools.corba.se.idl.Util + else + formatter.setTimeZone (java.util.TimeZone.getDefault ()); + +- stream.println ("* " + formatter.format (new Date ())); ++ try { ++ String epoch = System.getenv("SOURCE_DATE_EPOCH"); ++ if(epoch != null) { ++ long unixTime = Long.parseLong(epoch); ++ stream.println ("* " + formatter.format (new Date (unixTime*1000L))); ++ } else { ++ stream.println ("* " + formatter.format (new Date ())); ++ } ++ } catch (Exception e) { ++ //in case of error fall back to default ++ stream.println ("* " + formatter.format (new Date ())); ++ } + + // + /////////////// +-- +2.19.2 + -- cgit 1.4.1 From fec2c8532d238f75b2d33e2281509d101bd45171 Mon Sep 17 00:00:00 2001 From: Leo Famulari Date: Mon, 10 Dec 2018 10:07:44 -0500 Subject: gnu: Borg: Update to 1.1.8. * gnu/packages/backup.scm (borg): Update to 1.1.8. [source]: Remove obsolete patch. * gnu/packages/patches/borg-respect-storage-quota.patch: Delete file. * gnu/local.mk (dist_patch_DATA): Remove it. --- gnu/local.mk | 1 - gnu/packages/backup.scm | 5 ++-- .../patches/borg-respect-storage-quota.patch | 32 ---------------------- 3 files changed, 2 insertions(+), 36 deletions(-) delete mode 100644 gnu/packages/patches/borg-respect-storage-quota.patch (limited to 'gnu/local.mk') diff --git a/gnu/local.mk b/gnu/local.mk index 50fc08445f..4f2437befa 100644 --- a/gnu/local.mk +++ b/gnu/local.mk @@ -607,7 +607,6 @@ dist_patch_DATA = \ %D%/packages/patches/blast+-fix-makefile.patch \ %D%/packages/patches/blender-newer-ffmpeg.patch \ %D%/packages/patches/boost-fix-icu-build.patch \ - %D%/packages/patches/borg-respect-storage-quota.patch \ %D%/packages/patches/byobu-writable-status.patch \ %D%/packages/patches/cairo-CVE-2016-9082.patch \ %D%/packages/patches/cairo-setjmp-wrapper.patch \ diff --git a/gnu/packages/backup.scm b/gnu/packages/backup.scm index c927a14673..a9d8286702 100644 --- a/gnu/packages/backup.scm +++ b/gnu/packages/backup.scm @@ -491,15 +491,14 @@ detection, and lossless compression.") (define-public borg (package (name "borg") - (version "1.1.7") + (version "1.1.8") (source (origin (method url-fetch) (uri (pypi-uri "borgbackup" version)) - (patches (search-patches "borg-respect-storage-quota.patch")) (sha256 (base32 - "1p3zia62vyg9vadkdjzzkzbj4dmgijr7ix5lmhfbxpwy5q9imdgp")) + "0qqvcscn1l4y83x4sh3izdpmr8zq38j8chjkpfq4q4d01i470hqb")) (modules '((guix build utils))) (snippet '(begin diff --git a/gnu/packages/patches/borg-respect-storage-quota.patch b/gnu/packages/patches/borg-respect-storage-quota.patch deleted file mode 100644 index d23d1ffc01..0000000000 --- a/gnu/packages/patches/borg-respect-storage-quota.patch +++ /dev/null @@ -1,32 +0,0 @@ -Make sure the client respects the storage quota set by the server: - -https://github.com/borgbackup/borg/issues/4093 - -Patch copied from upstream source repository: - -https://github.com/borgbackup/borg/commit/975cc33206e0e3644626fb7204c34d2157715b61 - -From 975cc33206e0e3644626fb7204c34d2157715b61 Mon Sep 17 00:00:00 2001 -From: Manu -Date: Wed, 3 Oct 2018 23:47:36 +0800 -Subject: [PATCH] Add storage_quota for forced_result if set by serve command. - ---- - src/borg/archiver.py | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/src/borg/archiver.py b/src/borg/archiver.py -index 916725e7..279194c1 100644 ---- a/src/borg/archiver.py -+++ b/src/borg/archiver.py -@@ -4276,6 +4276,7 @@ def get_args(self, argv, cmd): - result.restrict_to_paths = forced_result.restrict_to_paths - result.restrict_to_repositories = forced_result.restrict_to_repositories - result.append_only = forced_result.append_only -+ result.storage_quota = forced_result.storage_quota - return result - - def parse_args(self, args=None): --- -2.19.1 - -- cgit 1.4.1