Commit e36827f6 authored by Matt Caswell's avatar Matt Caswell
Browse files

Remove remaining Kerberos references



Following on from the removal of libcrypto and libssl support for Kerberos
this commit removes all remaining references to Kerberos.

Reviewed-by: default avatarRich Salz <rsalz@openssl.org>
parent 60b3d36d
Loading
Loading
Loading
Loading
+7 −96
Original line number Diff line number Diff line
@@ -14,7 +14,7 @@ use File::Spec::Functions;

# see INSTALL for instructions.

my $usage="Usage: Configure [no-<cipher> ...] [enable-<cipher> ...] [experimental-<cipher> ...] [-Dxxx] [-lxxx] [-Lxxx] [-fxxx] [-Kxxx] [no-hw-xxx|no-hw] [[no-]threads] [[no-]shared] [[no-]zlib|zlib-dynamic] [no-asm] [no-dso] [no-krb5] [sctp] [386] [--prefix=DIR] [--openssldir=OPENSSLDIR] [--with-xxx[=vvv]] [--test-sanity] [--config=FILE] os/compiler[:flags]\n";
my $usage="Usage: Configure [no-<cipher> ...] [enable-<cipher> ...] [experimental-<cipher> ...] [-Dxxx] [-lxxx] [-Lxxx] [-fxxx] [-Kxxx] [no-hw-xxx|no-hw] [[no-]threads] [[no-]shared] [[no-]zlib|zlib-dynamic] [no-asm] [no-dso] [sctp] [386] [--prefix=DIR] [--openssldir=OPENSSLDIR] [--with-xxx[=vvv]] [--test-sanity] [--config=FILE] os/compiler[:flags]\n";

# Options:
#
@@ -30,18 +30,6 @@ my $usage="Usage: Configure [no-<cipher> ...] [enable-<cipher> ...] [experimenta
#               default).  This needn't be set in advance, you can
#               just as well use "make INSTALL_PREFIX=/whatever install".
#
# --with-krb5-dir  Declare where Kerberos 5 lives.  The libraries are expected
#		to live in the subdirectory lib/ and the header files in
#		include/.  A value is required.
# --with-krb5-lib  Declare where the Kerberos 5 libraries live.  A value is
#		required.
#		(Default: KRB5_DIR/lib)
# --with-krb5-include  Declare where the Kerberos 5 header files live.  A
#		value is required.
#		(Default: KRB5_DIR/include)
# --with-krb5-flavor  Declare what flavor of Kerberos 5 is used.  Currently
#		supported values are "MIT" and "Heimdal".  A value is required.
#
# --test-sanity Make a number of sanity checks on the data in this file.
#               This is a debugging tool for OpenSSL developers.
#
@@ -59,7 +47,6 @@ my $usage="Usage: Configure [no-<cipher> ...] [enable-<cipher> ...] [experimenta
# no-asm        do not use assembler
# no-dso        do not compile in any native shared-library methods. This
#               will ensure that all methods just return NULL.
# no-krb5       do not compile in any KRB5 library or code.
# [no-]zlib     [don't] compile support for zlib compression.
# zlib-dynamic	Like "zlib", but the zlib library is expected to be a shared
#		library and will be loaded in run-time by the OpenSSL library.
@@ -782,7 +769,6 @@ my $no_threads=0;
my $threads=0;
my $no_shared=0; # but "no-shared" is default
my $zlib=1;      # but "no-zlib" is default
my $no_krb5=0;   # but "no-krb5" is implied unless "--with-krb5-..." is used
my $no_rfc3779=1; # but "no-rfc3779" is default
my $no_asm=0;
my $no_dso=0;
@@ -856,7 +842,6 @@ my $openssl_thread_defines;
my $openssl_sys_defines="";
my $openssl_other_defines;
my $libs;
my $libkrb5="";
my $target;
my $options;
my $make_depend=0;
@@ -1005,10 +990,6 @@ PROCESS_ARGS:
				{
				$install_prefix=$1;
				}
			elsif (/^--with-krb5-(dir|lib|include|flavor)=(.*)$/)
				{
				$withargs{"krb5-".$1}=$2;
				}
			elsif (/^--with-zlib-lib=(.*)$/)
				{
				$withargs{"zlib-lib"}=$1;
@@ -1076,11 +1057,6 @@ if ($processor eq "386")
	$disabled{"sse2"} = "forced";
	}

if (!defined($withargs{"krb5-flavor"}) || $withargs{"krb5-flavor"} eq "")
	{
	$disabled{"krb5"} = "krb5-flavor not specified";
	}

if (!defined($disabled{"zlib-dynamic"}))
	{
	# "zlib-dynamic" was specifically enabled, so enable "zlib"
@@ -1223,10 +1199,6 @@ foreach (sort (keys %disabled))
			$openssl_algorithm_defines .= "#define OPENSSL_NO_$ALGO\n";
			print " OPENSSL_NO_$ALGO";

			if (/^krb5$/)
				{ $no_krb5 = 1; }
			else
				{
			push @skip, $algo;
			# fix-up crypto/directory name(s)
			$skip[$#skip]="whrlpool" if $algo eq "whirlpool";
@@ -1237,7 +1209,6 @@ foreach (sort (keys %disabled))
			$depflags .= " -DOPENSSL_NO_$ALGO";
			}
		}
		}

	print "\n";
	}
@@ -1354,62 +1325,6 @@ my $no_user_cflags=0;
if ($flags ne "")	{ $cflags="$flags$cflags"; }
else			{ $no_user_cflags=1;       }

# Kerberos settings.  The flavor must be provided from outside, either through
# the script "config" or manually.
if (!$no_krb5)
	{
	my ($lresolv, $lpath, $lext);
	if ($withargs{"krb5-flavor"} =~ /^[Hh]eimdal$/)
		{
		die "Sorry, Heimdal is currently not supported\n";
		}
	##### HACK to force use of Heimdal.
	##### WARNING: Since we don't really have adequate support for Heimdal,
	#####          using this will break the build.  You'll have to make
	#####          changes to the source, and if you do, please send
	#####          patches to openssl-dev@openssl.org
	if ($withargs{"krb5-flavor"} =~ /^force-[Hh]eimdal$/)
		{
		warn "Heimdal isn't really supported.  Your build WILL break\n";
		warn "If you fix the problems, please send a patch to openssl-dev\@openssl.org\n";
		$withargs{"krb5-dir"} = "/usr/heimdal"
			if $withargs{"krb5-dir"} eq "";
		$withargs{"krb5-lib"} = "-L".$withargs{"krb5-dir"}.
			"/lib -lgssapi -lkrb5 -lcom_err"
			if $withargs{"krb5-lib"} eq "" && !$IsMK1MF;
		$cflags="-DKRB5_HEIMDAL $cflags";
		}
	if ($withargs{"krb5-flavor"} =~ /^[Mm][Ii][Tt]/)
		{
		$withargs{"krb5-dir"} = "/usr/kerberos"
			if $withargs{"krb5-dir"} eq "";
		$withargs{"krb5-lib"} = "-L".$withargs{"krb5-dir"}.
			"/lib -lgssapi_krb5 -lkrb5 -lcom_err -lk5crypto"
			if $withargs{"krb5-lib"} eq "" && !$IsMK1MF;
		$cflags="-DKRB5_MIT $cflags";
		$withargs{"krb5-flavor"} =~ s/^[Mm][Ii][Tt][._-]*//;
		if ($withargs{"krb5-flavor"} =~ /^1[._-]*[01]/)
			{
			$cflags="-DKRB5_MIT_OLD11 $cflags";
			}
		}
	LRESOLV:
	foreach $lpath ("/lib", "/usr/lib")
		{
		foreach $lext ("a", "so")
			{
			$lresolv = "$lpath/libresolv.$lext";
			last LRESOLV	if (-r "$lresolv");
			$lresolv = "";
			}
		}
	$withargs{"krb5-lib"} .= " -lresolv"
		if ("$lresolv" ne "");
	$withargs{"krb5-include"} = "-I".$withargs{"krb5-dir"}."/include"
		if $withargs{"krb5-include"} eq "" &&
		   $withargs{"krb5-dir"} ne "";
	}

# The DSO code currently always implements all functions so that no
# applications will have to worry about that from a compilation point
# of view. However, the "method"s may return zero unless that platform
@@ -1827,8 +1742,6 @@ while (<IN>)
	s/^PROCESSOR=.*/PROCESSOR= $processor/;
	s/^ARFLAGS=.*/ARFLAGS= $arflags/;
	s/^PERL=.*/PERL= $perl/;
	s/^KRB5_INCLUDES=.*/KRB5_INCLUDES=$withargs{"krb5-include"}/;
	s/^LIBKRB5=.*/LIBKRB5=$withargs{"krb5-lib"}/;
	s/^LIBZLIB=.*/LIBZLIB=$withargs{"zlib-lib"}/;
	s/^ZLIB_INCLUDE=.*/ZLIB_INCLUDE=$withargs{"zlib-include"}/;
	s/^FIPSLIBDIR=.*/FIPSLIBDIR=$fipslibdir/;
@@ -1887,8 +1800,6 @@ print "PROCESSOR =$processor\n";
print "RANLIB        =$ranlib\n";
print "ARFLAGS       =$arflags\n";
print "PERL          =$perl\n";
print "KRB5_INCLUDES =",$withargs{"krb5-include"},"\n"
	if $withargs{"krb5-include"} ne "";

my $des_ptr=0;
my $des_risc1=0;
+1 −1
Original line number Diff line number Diff line
@@ -134,7 +134,7 @@ Currently, the logical names supported are:
                        disabling it is supported.  Supported algorithms to
                        do this with are: AES, BF, CAMELLIA, CAST, CMS, COMP,
                        DES, DGRAM, DH, DSA, EC, EC2M, ECDH, ECDSA, ENGINE,
                        ERR, GOST, HEARTBEATS, HMAC, IDEA, KRB5, MD2, MD4,
                        ERR, GOST, HEARTBEATS, HMAC, IDEA, MD2, MD4,
                        MD5, OCB, OCSP, PSK, RC2, RC4, RC5, RMD160, RSA, SCTP,
                        SEED, SOCK, SRP, SRTP, TLSEXT, WHIRLPOOL.  So, for
                        example, having the logical name OPENSSL_NO_RSA with
+2 −6
Original line number Diff line number Diff line
@@ -219,7 +219,6 @@ BUILDENV= PLATFORM='$(PLATFORM)' PROCESSOR='$(PROCESSOR)' \
		DEPFLAG='-DOPENSSL_NO_DEPRECATED $(DEPFLAG)'	\
		MAKEDEPPROG='$(MAKEDEPPROG)'			\
		SHARED_LDFLAGS='$(SHARED_LDFLAGS)'		\
		KRB5_INCLUDES='$(KRB5_INCLUDES)' LIBKRB5='$(LIBKRB5)'	\
		ZLIB_INCLUDE='$(ZLIB_INCLUDE)' LIBZLIB='$(LIBZLIB)'	\
		EXE_EXT='$(EXE_EXT)' SHARED_LIBS='$(SHARED_LIBS)'	\
		SHLIB_EXT='$(SHLIB_EXT)' SHLIB_TARGET='$(SHLIB_TARGET)'	\
@@ -340,9 +339,6 @@ build-shared: do_$(SHLIB_TARGET) link-shared

do_$(SHLIB_TARGET):
	@ set -e; libs='-L. $(SHLIBDEPS)'; for i in $(SHLIBDIRS); do \
		if [ "$$i" = "ssl" -a -n "$(LIBKRB5)" ]; then \
			libs="$(LIBKRB5) $$libs"; \
		fi; \
		$(CLEARENV) && $(MAKE) -f Makefile.shared -e $(BUILDENV) \
			LIBNAME=$$i LIBVERSION=$(SHLIB_MAJOR).$(SHLIB_MINOR) \
			LIBCOMPATVERSIONS=";$(SHLIB_VERSION_HISTORY)" \
@@ -363,7 +359,7 @@ libcrypto.pc: Makefile
	    echo 'Requires: '; \
	    echo 'Libs: -L$${libdir} -lcrypto'; \
	    echo 'Libs.private: $(EX_LIBS)'; \
	    echo 'Cflags: -I$${includedir} $(KRB5_INCLUDES)' ) > libcrypto.pc
	    echo 'Cflags: -I$${includedir}' ) > libcrypto.pc

libssl.pc: Makefile
	@ ( echo 'prefix=$(INSTALLTOP)'; \
@@ -377,7 +373,7 @@ libssl.pc: Makefile
	    echo 'Requires.private: libcrypto'; \
	    echo 'Libs: -L$${libdir} -lssl'; \
	    echo 'Libs.private: $(EX_LIBS)'; \
	    echo 'Cflags: -I$${includedir} $(KRB5_INCLUDES)' ) > libssl.pc
	    echo 'Cflags: -I$${includedir}' ) > libssl.pc

openssl.pc: Makefile
	@ ( echo 'prefix=$(INSTALLTOP)'; \
+0 −21
Original line number Diff line number Diff line
@@ -873,27 +873,6 @@ do
  fi
done

# Discover Kerberos 5 (since it's still a prototype, we don't
# do any guesses yet, that's why this section is commented away.
#if [ -d /usr/kerberos ]; then
#    krb5_dir=/usr/kerberos
#    if [ \( -f $krb5_dir/lib/libgssapi_krb5.a -o -f $krb5_dir/lib/libgssapi_krb5.so* \)\
#	-a \( -f $krb5_dir/lib/libkrb5.a -o -f $krb5_dir/lib/libkrb5.so* \)\
#	-a \( -f $krb5_dir/lib/libcom_err.a -o -f $krb5_dir/lib/libcom_err.so* \)\
#	-a \( -f $krb5_dir/lib/libk5crypto.a -o -f $krb5_dir/lib/libk5crypto.so* \)\
#	-a \( -f $krb5_dir/include/krb5.h \) ]; then
#	options="$options --with-krb5-flavor=MIT"
#    fi
#elif [ -d /usr/heimdal ]; then
#    krb5_dir=/usr/heimdal
#    if [ \( -f $krb5_dir/lib/libgssapi.a -o -f $krb5_dir/lib/libgssapi.so* \)\
#	-a \( -f $krb5_dir/lib/libkrb5.a -o -f $krb5_dir/lib/libkrb5.so* \)\
#	-a \( -f $krb5_dir/lib/libcom_err.a -o -f $krb5_dir/lib/libcom_err.so* \)\
#	-a \( -f $krb5_dir/include/krb5.h \) ]; then
#	options="$options --with-krb5-flavor=Heimdal"
#    fi
#fi

if [ -z "$OUT" ]; then
  OUT="$CC"
fi
+1 −2
Original line number Diff line number Diff line
@@ -127,7 +127,7 @@ $ ENCRYPT_TYPES = "Basic,"+ -
		    "DES,AES,RC2,RC4,RC5,IDEA,BF,CAST,CAMELLIA,SEED,MODES,"+ -
		    "BN,EC,RSA,DSA,ECDSA,DH,ECDH,DSO,ENGINE,"+ -
		    "BUFFER,BIO,STACK,LHASH,RAND,ERR,"+ -
		    "EVP,ASN1,PEM,X509,X509V3,CONF,TXT_DB,PKCS7,PKCS12,COMP,OCSP,UI,KRB5,"+ -
		    "EVP,ASN1,PEM,X509,X509V3,CONF,TXT_DB,PKCS7,PKCS12,COMP,OCSP,UI,"+ -
		    "CMS,PQUEUE,TS,JPAKE,SRP,STORE,CMAC"
$ ENDIF
$!
@@ -343,7 +343,6 @@ $ LIB_COMP = "comp_lib,comp_err,"+ -
$ LIB_OCSP = "ocsp_asn,ocsp_ext,ocsp_ht,ocsp_lib,ocsp_cl,"+ -
	"ocsp_srv,ocsp_prn,ocsp_vfy,ocsp_err,v3_ocsp"
$ LIB_UI = "ui_err,ui_lib,ui_openssl,ui_util"
$ LIB_KRB5 = "krb5_asn"
$ LIB_CMS = "cms_lib,cms_asn1,cms_att,cms_io,cms_smime,cms_err,"+ -
	"cms_sd,cms_dd,cms_cd,cms_env,cms_enc,cms_ess,"+ -
	"cms_pwri,cms_kari"
Loading