summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorRobin H. Johnson <robbat2@gentoo.org>2005-07-03 15:01:32 +0000
committerRobin H. Johnson <robbat2@gentoo.org>2005-07-03 15:01:32 +0000
commit5dde767c5634324fc9e61f079d038cdd827c0d0f (patch)
tree55320d29cc032266b8aaa8ba99db4da3fb388fb3 /sys-libs/nss-db/files
parentRemoving outdated ebuild (diff)
downloadhistorical-5dde767c5634324fc9e61f079d038cdd827c0d0f.tar.gz
historical-5dde767c5634324fc9e61f079d038cdd827c0d0f.tar.bz2
historical-5dde767c5634324fc9e61f079d038cdd827c0d0f.zip
Add small patch to only use db->update when root privileges are present.
Package-Manager: portage-2.0.51.22-r1
Diffstat (limited to 'sys-libs/nss-db/files')
-rw-r--r--sys-libs/nss-db/files/digest-nss-db-2.2.3_pre1-r14
-rw-r--r--sys-libs/nss-db/files/nss-db-2.2.3_pre1-root-upgrade-only.patch27
2 files changed, 31 insertions, 0 deletions
diff --git a/sys-libs/nss-db/files/digest-nss-db-2.2.3_pre1-r1 b/sys-libs/nss-db/files/digest-nss-db-2.2.3_pre1-r1
new file mode 100644
index 000000000000..df79771ab5d6
--- /dev/null
+++ b/sys-libs/nss-db/files/digest-nss-db-2.2.3_pre1-r1
@@ -0,0 +1,4 @@
+MD5 b4440ba2865d28e9068e465426c19ede nss_db-2.2.3pre1.tar.gz 235360
+MD5 ec455e427bf7bf4daba3427fd4066db3 nss_db-2.2.3pre1-external.patch.bz2 1870
+MD5 d02a1a231c70e28320ed21e883be4d6a nss_db-2.2.3pre1-dbupgrade.patch.bz2 263
+MD5 e26590083b9f32d2c134d204ba0ad72e nss_db-2.2.3pre1-dbopen.patch.bz2 258
diff --git a/sys-libs/nss-db/files/nss-db-2.2.3_pre1-root-upgrade-only.patch b/sys-libs/nss-db/files/nss-db-2.2.3_pre1-root-upgrade-only.patch
new file mode 100644
index 000000000000..e2db2342e2a4
--- /dev/null
+++ b/sys-libs/nss-db/files/nss-db-2.2.3_pre1-root-upgrade-only.patch
@@ -0,0 +1,27 @@
+diff -NuarwbB nss_db-2.2.3pre1.orig/src/db-compat.c nss_db-2.2.3pre1/src/db-compat.c
+--- nss_db-2.2.3pre1.orig/src/db-compat.c 2005-06-07 00:08:39.000000000 -0700
++++ nss_db-2.2.3pre1/src/db-compat.c 2005-06-07 00:53:00.000000000 -0700
+@@ -20,6 +20,9 @@
+ #include <assert.h>
+ #include <db.h>
+ #include <fcntl.h>
++#include <unistd.h>
++#include <sys/types.h>
++
+
+ #if DB_VERSION_MAJOR > 2
+
+@@ -39,8 +42,13 @@
+ if (err)
+ return err;
+
++ uid_t uid = geteuid();
++
++ if(uid == 0) {
+ /* Make sure we upgrade, in case this is an older database */
++ /* However we need root access to do so */
+ db->upgrade(db, file, 0);
++ }
+
+ err = db->open (db, NULL, file, NULL, type, flags, mode);
+ if (err)