From 579ae43e2cf46c7951bcc1a23ecea15bdc9e2691 Mon Sep 17 00:00:00 2001 From: Jose V Beneyto Date: Tue, 16 Nov 2010 09:50:20 +0100 Subject: [PATCH] cyrus-sasl: initial import (verified compilation) --- cyrus-sasl/.footprint | 106 +++++++++++++++++++++++ cyrus-sasl/.md5sum | 3 + cyrus-sasl/Pkgfile | 64 ++++++++++++++ cyrus-sasl/cyrus-sasl-2.1.23-gcc44.patch | 20 +++++ cyrus-sasl/saslauthd | 33 +++++++ 5 files changed, 226 insertions(+) create mode 100644 cyrus-sasl/.footprint create mode 100644 cyrus-sasl/.md5sum create mode 100644 cyrus-sasl/Pkgfile create mode 100644 cyrus-sasl/cyrus-sasl-2.1.23-gcc44.patch create mode 100644 cyrus-sasl/saslauthd diff --git a/cyrus-sasl/.footprint b/cyrus-sasl/.footprint new file mode 100644 index 0000000..f294f7c --- /dev/null +++ b/cyrus-sasl/.footprint @@ -0,0 +1,106 @@ +drwxr-xr-x root/root etc/ +drwxr-xr-x root/root etc/rc.d/ +-rwxr-xr-x root/root etc/rc.d/saslauthd +drwxr-xr-x root/root usr/ +drwxr-xr-x root/root usr/include/ +drwxr-xr-x root/root usr/include/sasl/ +-rw-r--r-- root/root usr/include/sasl/hmac-md5.h +-rw-r--r-- root/root usr/include/sasl/md5.h +-rw-r--r-- root/root usr/include/sasl/md5global.h +-rw-r--r-- root/root usr/include/sasl/prop.h +-rw-r--r-- root/root usr/include/sasl/sasl.h +-rw-r--r-- root/root usr/include/sasl/saslplug.h +-rw-r--r-- root/root usr/include/sasl/saslutil.h +drwxr-xr-x root/root usr/lib/ +-rwxr-xr-x root/root usr/lib/libsasl2.la +lrwxrwxrwx root/root usr/lib/libsasl2.so -> libsasl2.so.2.0.23 +lrwxrwxrwx root/root usr/lib/libsasl2.so.2 -> libsasl2.so.2.0.23 +-rwxr-xr-x root/root usr/lib/libsasl2.so.2.0.23 +drwxr-xr-x root/root usr/lib/sasl2/ +-rwxr-xr-x root/root usr/lib/sasl2/libanonymous.la +lrwxrwxrwx root/root usr/lib/sasl2/libanonymous.so -> libanonymous.so.2.0.23 +lrwxrwxrwx root/root usr/lib/sasl2/libanonymous.so.2 -> libanonymous.so.2.0.23 +-rwxr-xr-x root/root usr/lib/sasl2/libanonymous.so.2.0.23 +-rwxr-xr-x root/root usr/lib/sasl2/libcrammd5.la +lrwxrwxrwx root/root usr/lib/sasl2/libcrammd5.so -> libcrammd5.so.2.0.23 +lrwxrwxrwx root/root usr/lib/sasl2/libcrammd5.so.2 -> libcrammd5.so.2.0.23 +-rwxr-xr-x root/root usr/lib/sasl2/libcrammd5.so.2.0.23 +-rwxr-xr-x root/root usr/lib/sasl2/libdigestmd5.la +lrwxrwxrwx root/root usr/lib/sasl2/libdigestmd5.so -> libdigestmd5.so.2.0.23 +lrwxrwxrwx root/root usr/lib/sasl2/libdigestmd5.so.2 -> libdigestmd5.so.2.0.23 +-rwxr-xr-x root/root usr/lib/sasl2/libdigestmd5.so.2.0.23 +-rwxr-xr-x root/root usr/lib/sasl2/liblogin.la +lrwxrwxrwx root/root usr/lib/sasl2/liblogin.so -> liblogin.so.2.0.23 +lrwxrwxrwx root/root usr/lib/sasl2/liblogin.so.2 -> liblogin.so.2.0.23 +-rwxr-xr-x root/root usr/lib/sasl2/liblogin.so.2.0.23 +-rwxr-xr-x root/root usr/lib/sasl2/libotp.la +lrwxrwxrwx root/root usr/lib/sasl2/libotp.so -> libotp.so.2.0.23 +lrwxrwxrwx root/root usr/lib/sasl2/libotp.so.2 -> libotp.so.2.0.23 +-rwxr-xr-x root/root usr/lib/sasl2/libotp.so.2.0.23 +-rwxr-xr-x root/root usr/lib/sasl2/libplain.la +lrwxrwxrwx root/root usr/lib/sasl2/libplain.so -> libplain.so.2.0.23 +lrwxrwxrwx root/root usr/lib/sasl2/libplain.so.2 -> libplain.so.2.0.23 +-rwxr-xr-x root/root usr/lib/sasl2/libplain.so.2.0.23 +-rwxr-xr-x root/root usr/lib/sasl2/libsasldb.la +lrwxrwxrwx root/root usr/lib/sasl2/libsasldb.so -> libsasldb.so.2.0.23 +lrwxrwxrwx root/root usr/lib/sasl2/libsasldb.so.2 -> libsasldb.so.2.0.23 +-rwxr-xr-x root/root usr/lib/sasl2/libsasldb.so.2.0.23 +drwxr-xr-x root/root usr/man/ +drwxr-xr-x root/root usr/man/man3/ +-rw-r--r-- root/root usr/man/man3/sasl.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_authorize_t.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_auxprop.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_auxprop_getctx.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_auxprop_request.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_callbacks.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_canon_user_t.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_chalprompt_t.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_checkapop.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_checkpass.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_client_init.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_client_new.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_client_start.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_client_step.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_decode.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_dispose.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_done.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_encode.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_encodev.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_errdetail.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_errors.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_errstring.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_getconfpath_t.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_getopt_t.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_getpath_t.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_getprop.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_getrealm_t.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_getsecret_t.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_getsimple_t.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_global_listmech.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_idle.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_listmech.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_log_t.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_server_init.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_server_new.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_server_start.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_server_step.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_server_userdb_checkpass_t.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_server_userdb_setpass_t.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_setpass.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_setprop.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_user_exists.3.gz +-rw-r--r-- root/root usr/man/man3/sasl_verifyfile_t.3.gz +drwxr-xr-x root/root usr/man/man8/ +-rw-r--r-- root/root usr/man/man8/pluginviewer.8.gz +-rw-r--r-- root/root usr/man/man8/saslauthd.8.gz +-rw-r--r-- root/root usr/man/man8/sasldblistusers2.8.gz +-rw-r--r-- root/root usr/man/man8/saslpasswd2.8.gz +drwxr-xr-x root/root usr/sbin/ +-rwxr-xr-x root/root usr/sbin/pluginviewer +-rwxr-xr-x root/root usr/sbin/saslauthd +-rwxr-xr-x root/root usr/sbin/sasldblistusers2 +-rwxr-xr-x root/root usr/sbin/saslpasswd2 +-rwxr-xr-x root/root usr/sbin/testsaslauthd +drwxr-xr-x root/root var/ +drwxr-xr-x root/root var/sasl/ +drwxr-xr-x root/root var/sasl/saslauthd/ diff --git a/cyrus-sasl/.md5sum b/cyrus-sasl/.md5sum new file mode 100644 index 0000000..f7c33cd --- /dev/null +++ b/cyrus-sasl/.md5sum @@ -0,0 +1,3 @@ +7ffb3d7e147470f26041c005847512cf cyrus-sasl-2.1.23-gcc44.patch +2eb0e48106f0e9cd8001e654f267ecbc cyrus-sasl-2.1.23.tar.gz +ec81c1d452216c3da110d7b9a6f8fa8f saslauthd diff --git a/cyrus-sasl/Pkgfile b/cyrus-sasl/Pkgfile new file mode 100644 index 0000000..a8f7b14 --- /dev/null +++ b/cyrus-sasl/Pkgfile @@ -0,0 +1,64 @@ +# Description: Simple Authentication and Security Layer +# URL: http://asg.web.cmu.edu/sasl/sasl-library.html +# Packager: Daniel Mueller, daniel at danm dot de +# Maintainer: Simon Glossner, viper at hometux dot de +# Arch Maintainer: CRUX-ARM System Team, devel at crux-arm dot nu +# Packager: Daniel Mueller, daniel at danm dot de +# Depends on: db openssl + +name=cyrus-sasl +version=2.1.23 +release=2 +source=(ftp://ftp.andrew.cmu.edu/pub/cyrus-mail/$name-$version.tar.gz \ + saslauthd $name-$version-gcc44.patch) + +build(){ + cd $name-$version + + patch -p0 -i $SRC/$name-$version-gcc44.patch + + export SAVED_CC="$CC" SAVED_CXX="$CXX" + export SAVED_CFLAGS="$CFLAGS" SAVED_CXXFLAGS="$CXXFLAGS" + unset CC CXX CFLAGS CXXFLAGS + + # build native tools + ./configure --prefix=/usr + make -j 1 + mv include/makemd5{,-host} + make distclean + + # and now crossbuild + export CC="$SAVED_CC" CXX="$SAVED_CXX" + export CFLAGS="$SAVED_CFLAGS" CXXFLAGS="$SAVED_CXXFLAGS" + + ./configure --build=$CHOST \ + --host=$CTARGET \ + --prefix=/usr \ + --sysconfdir=/etc/sasl \ + --with-plugindir=/usr/lib/sasl2 \ + --with-saslauthd=/var/sasl/saslauthd \ + --with-dbpath=/etc/sasl/sasldb2 \ + --with-dblib=berkeley \ + --with-bdb-incdir=$CLFS/usr/include \ + --with-bdb-libdir=$CLFS/usr/lib \ + --with-openssl=$CLFS/usr \ + --enable-login \ + --enable-cram \ + --enable-digest \ + --enable-shared + + # fix to use native tools + sed -i include/Makefile \ + -e 's|./makemd5 md5global.h|./makemd5-host md5global.h|' + + make -j 1 + make DESTDIR=$PKG install + + mkdir -p \ + $PKG/usr/lib/sasl2 \ + $PKG/var/sasl/saslauthd \ + $PKG/etc/rc.d + + install -m 644 saslauthd/saslauthd.mdoc $PKG/usr/man/man8/saslauthd.8 + install -m 755 $SRC/saslauthd $PKG/etc/rc.d +} diff --git a/cyrus-sasl/cyrus-sasl-2.1.23-gcc44.patch b/cyrus-sasl/cyrus-sasl-2.1.23-gcc44.patch new file mode 100644 index 0000000..79ee408 --- /dev/null +++ b/cyrus-sasl/cyrus-sasl-2.1.23-gcc44.patch @@ -0,0 +1,20 @@ +--- plugins/digestmd5.c~ 2008-11-08 18:28:21.000000000 +0000 ++++ plugins/digestmd5.c 2008-11-08 18:28:50.000000000 +0000 +@@ -2715,7 +2715,7 @@ + "DIGEST-MD5", /* mech_name */ + #ifdef WITH_RC4 + 128, /* max_ssf */ +-#elif WITH_DES ++#elif defined(WITH_DES) + 112, + #else + 1, +@@ -4034,7 +4034,7 @@ + "DIGEST-MD5", + #ifdef WITH_RC4 /* mech_name */ + 128, /* max ssf */ +-#elif WITH_DES ++#elif defined(WITH_DES) + 112, + #else + 1, diff --git a/cyrus-sasl/saslauthd b/cyrus-sasl/saslauthd new file mode 100644 index 0000000..22b0d0f --- /dev/null +++ b/cyrus-sasl/saslauthd @@ -0,0 +1,33 @@ +#!/bin/bash +# +# /etc/rc.d/saslauthd: start/stop sasl authentication daemon +# + +SASLAUTHD_PID=/var/sasl/saslauth/saslauthd.pid + +AUTHMECH=shadow + +case $1 in + start) + /usr/sbin/saslauthd -a $AUTHMECH + ;; + stop) + if [ -f $SASLAUTHD_PID ]; then + kill `head -1 $SASLAUTHD_PID` + rm $SASLAUTHD_PID + else + killall -q /usr/sbin/saslauthd + fi + ;; + restart) + $0 stop + sleep 2 + $0 start + ;; + *) + echo "usage: $0 [start|stop|restart]" + ;; +esac + +# End of file + -- 2.26.2