aboutsummaryrefslogtreecommitdiffstats
path: root/main/phpldapadmin
diff options
context:
space:
mode:
authorLeonardo Arena <rnalrd@alpinelinux.org>2014-08-12 07:05:43 +0000
committerLeonardo Arena <rnalrd@alpinelinux.org>2014-08-12 07:06:01 +0000
commitbc12563552b622d46252ff825c96e271da232595 (patch)
tree676b7baa0beaab350dc0ee887b5c92132dc0c20d /main/phpldapadmin
parente94a3de546287fdf74c3ff748c09585c3270cdf9 (diff)
downloadaports-bc12563552b622d46252ff825c96e271da232595.tar.bz2
aports-bc12563552b622d46252ff825c96e271da232595.tar.xz
main/phpldapadmin: force crypt to use SSHA512 algorithm
Diffstat (limited to 'main/phpldapadmin')
-rw-r--r--main/phpldapadmin/APKBUILD28
-rw-r--r--main/phpldapadmin/phpldapadmin-1.2.3-force-ssha512.patch11
2 files changed, 35 insertions, 4 deletions
diff --git a/main/phpldapadmin/APKBUILD b/main/phpldapadmin/APKBUILD
index 99ac475fdd..448098f830 100644
--- a/main/phpldapadmin/APKBUILD
+++ b/main/phpldapadmin/APKBUILD
@@ -1,7 +1,7 @@
# Maintainer: Leonardo Arena <rnalrd@alpinelinux.org>
pkgname=phpldapadmin
pkgver=1.2.3
-pkgrel=0
+pkgrel=1
pkgdesc="Web front-end for managing OpenLDAP"
url="http://phpldapadmin.sourceforge.net"
arch="noarch"
@@ -12,14 +12,27 @@ makedepends="$depends_dev"
install=
subpackages=
source="http://downloads.sourceforge.net/project/$pkgname/$pkgname-php5/$pkgver/$pkgname-$pkgver.tgz
- $pkgname.additional-template"
+ $pkgname.additional-template
+ phpldapadmin-1.2.3-force-ssha512.patch
+ "
_builddir="$srcdir"/$pkgname-$pkgver
prepare() {
cd "$_builddir"
- # apply patches here
+ for i in $source; do
+ case $i in
+ *.patch)
+ msg "Applying $i..."
+ if ! patch -s -p1 -N -i "$srcdir"/$i; then
+ echo $i >>failed
+ _patch_failed=1
+ fi
+ ;;
+ esac
+ done
+
}
build() {
@@ -38,4 +51,11 @@ package() {
}
md5sums="59a49054039ceb852c2da377d8742360 phpldapadmin-1.2.3.tgz
-3ca4fbf9e16f192b441b51b2d25ecf14 phpldapadmin.additional-template"
+3ca4fbf9e16f192b441b51b2d25ecf14 phpldapadmin.additional-template
+34e36e414f59c6ed4946efa1f277f962 phpldapadmin-1.2.3-force-ssha512.patch"
+sha256sums="aecaf8c3ce77ba3899dd31ee5ee183555b2f9349eb8e196dcd33d8a3c485ed58 phpldapadmin-1.2.3.tgz
+85e931a84f3fd5e398da24403425b58711c48196ed9692f7a312883a0ed9fae0 phpldapadmin.additional-template
+0cd1d8195ecdc53cde9667bf256d2243d67675ac92547d163a707659df5a3d9a phpldapadmin-1.2.3-force-ssha512.patch"
+sha512sums="58a57ca577586685ebd0d7fde7e299b8945d1693018c7803e19239b79f4b9d72a4d207d53c9f284268e32398108038efafcdb434e634619bfe87db3524d267b6 phpldapadmin-1.2.3.tgz
+913cc89bfba3a24064865f091a3bcc6ec88db0824d750e8b3b1f6497b5ac1a1e158ced895f1f85f93607402e9353798b3dd4ccdbb1454713f96937c884456eb7 phpldapadmin.additional-template
+aecbf3699af4ae39426c6c81edd45a738cdd91f9cfc1e8062ade4b6fa11e7530a8d8b4c2730cd648749b87381dbcca1bbe8681b8e45ec7af50b6b74137f89331 phpldapadmin-1.2.3-force-ssha512.patch"
diff --git a/main/phpldapadmin/phpldapadmin-1.2.3-force-ssha512.patch b/main/phpldapadmin/phpldapadmin-1.2.3-force-ssha512.patch
new file mode 100644
index 0000000000..c69096e7fc
--- /dev/null
+++ b/main/phpldapadmin/phpldapadmin-1.2.3-force-ssha512.patch
@@ -0,0 +1,11 @@
+--- a/lib/functions.php
++++ b/lib/functions.php
+@@ -2147,7 +2147,7 @@
+ if ($_SESSION[APPCONFIG]->getValue('password', 'no_random_crypt_salt'))
+ $new_value = sprintf('{CRYPT}%s',crypt($password_clear,substr($password_clear,0,2)));
+ else
+- $new_value = sprintf('{CRYPT}%s',crypt($password_clear,random_salt(2)));
++ $new_value = sprintf('{CRYPT}%s',crypt($password_clear,'$6$'.random_salt(2)));
+
+ break;
+