From: [EMAIL PROTECTED]
Operating system: Solaris (SPARC) 2.6
PHP version: 4.0CVS-2001-08-21
PHP Bug Type: Feature/Change Request
Bug description: krb4 support in c-client
the line wrapping might be a little off..
this should allow php_imap.c to support a kerberized (krb4) c-client, with
the appropriate configure options.
it works with the CGI, but not the apache server module. i'm not sure why.
we're trying to figure that part out.
-----------------------------------------------------------
diff -p -N -U 4 -r ext/imap/config.m4 ext/imap-krb4/config.m4
--- ext/imap/config.m4 Tue Aug 21 12:41:18 2001
+++ ext/imap-krb4/config.m4 Tue Aug 21 13:50:28 2001
@@ -20,8 +20,37 @@ AC_DEFUN(IMAP_LIB_CHK,[
fi
done
])
+AC_DEFUN(PHP_IMAP_KRB4_CHK, [
+ AC_ARG_WITH(krb4,
+ [ --with-krb4[=DIR] IMAP: Include KerberosIV support. DIR is the
Kerber
+os install dir.],[
+ PHP_KRB4=$withval
+ ],[
+ PHP_KRB4=no
+ ])
+
+ if test "$PHP_KRB4" = "yes"; then
+ test -d /usr/kerberos && PHP_KERBEROS=/usr/kerberos
+ fi
+
+ if test "$PHP_KRB4" != "no"; then
+ AC_DEFINE(HAVE_IMAP_KRB4,1,[ ])
+ PHP_ADD_LIBPATH($PHP_KRB4/lib, IMAP_SHARED_LIBADD)
+ PHP_ADD_LIBRARY(des, 1, IMAP_SHARED_LIBADD)
+ PHP_ADD_LIBRARY(krb, 1, IMAP_SHARED_LIBADD)
+ else
+ AC_EGREP_HEADER(auth_krb, $IMAP_INC_DIR/linkage.h, [
+ AC_MSG_ERROR(This c-client library is build with Kerberos support.
+
+ Add --with-krb4<=DIR> to your configure line. Check config.log for
det
+ails.)
+ ])
+ fi
+
+])
+
AC_DEFUN(PHP_IMAP_KRB_CHK, [
AC_ARG_WITH(kerberos,
[ --with-kerberos[=DIR] IMAP: Include Kerberos support. DIR is the
Kerberos install dir.],[
PHP_KERBEROS=$withval
@@ -163,7 +192,8 @@ if test "$PHP_IMAP" != "no"; then
PHP_ADD_INCLUDE($IMAP_INC_DIR)
PHP_ADD_LIBPATH($IMAP_LIBDIR, IMAP_SHARED_LIBADD)
PHP_ADD_LIBRARY_DEFER($IMAP_LIB,, IMAP_SHARED_LIBADD)
+ PHP_IMAP_KRB4_CHK
PHP_IMAP_KRB_CHK
PHP_IMAP_SSL_CHK
fi
diff -p -N -U 4 -r ext/imap/php_imap.c ext/imap-krb4/php_imap.c
--- ext/imap/php_imap.c Tue Aug 21 13:35:28 2001
+++ ext/imap-krb4/php_imap.c Tue Aug 21 12:45:53 2001
@@ -413,8 +413,9 @@ PHP_MINIT_FUNCTION(imap)
/* mail_link(&mxdriver); */ /* According to c-client docs
(internal.
txt) this shouldn't be used. */
mail_link(&mmdfdriver); /* link in the mmdf driver */
mail_link(&newsdriver); /* link in the news driver */
mail_link(&philedriver); /* link in the phile driver */
+ auth_link(&auth_krb); /* link in the krb authenticator
*/
auth_link(&auth_md5); /* link in the cram-md5 authenticator
*/
auth_link(&auth_log); /* link in the log authenticator
*/
#ifdef HAVE_IMAP_SSL
ssl_onceonlyinit ();
--
Edit bug report at: http://bugs.php.net/?id=12883&edit=1
--
PHP Development Mailing List <http://www.php.net/>
To unsubscribe, e-mail: [EMAIL PROTECTED]
For additional commands, e-mail: [EMAIL PROTECTED]
To contact the list administrators, e-mail: [EMAIL PROTECTED]