summaryrefslogtreecommitdiff
path: root/source4/auth/gensec
diff options
context:
space:
mode:
authorAndrew Bartlett <abartlet@samba.org>2006-11-07 00:48:36 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 14:25:00 -0500
commit13dbee3ffea6065a826f010e50c9b4eb2c6ad109 (patch)
treeeede29a3bff4c6de3432c16f5555dc9640267327 /source4/auth/gensec
parentc755bb5025ee60ae41de9cc32d3fa54e3671941d (diff)
downloadsamba-13dbee3ffea6065a826f010e50c9b4eb2c6ad109.tar.gz
samba-13dbee3ffea6065a826f010e50c9b4eb2c6ad109.tar.bz2
samba-13dbee3ffea6065a826f010e50c9b4eb2c6ad109.zip
r19598: Ahead of a merge to current lorikeet-heimdal:
Break up auth/auth.h not to include the world. Add credentials_krb5.h with the kerberos dependent prototypes. Andrew Bartlett (This used to be commit 2b569c42e0fbb596ea82484d0e1cb22e193037b9)
Diffstat (limited to 'source4/auth/gensec')
-rw-r--r--source4/auth/gensec/config.mk9
-rw-r--r--source4/auth/gensec/cyrus_sasl.c2
-rw-r--r--source4/auth/gensec/gensec.c2
-rw-r--r--source4/auth/gensec/gensec.h3
-rw-r--r--source4/auth/gensec/gensec_krb5.c3
-rw-r--r--source4/auth/gensec/schannel.c2
-rw-r--r--source4/auth/gensec/schannel.h2
-rw-r--r--source4/auth/gensec/schannel_sign.c2
-rw-r--r--source4/auth/gensec/schannel_state.c3
-rw-r--r--source4/auth/gensec/spnego.c6
-rw-r--r--source4/auth/gensec/spnego.h5
-rw-r--r--source4/auth/gensec/spnego_parse.c3
12 files changed, 28 insertions, 14 deletions
diff --git a/source4/auth/gensec/config.mk b/source4/auth/gensec/config.mk
index 84947785db..a395dd205f 100644
--- a/source4/auth/gensec/config.mk
+++ b/source4/auth/gensec/config.mk
@@ -18,7 +18,7 @@ PUBLIC_DEPENDENCIES = \
SUBSYSTEM = gensec
INIT_FUNCTION = gensec_krb5_init
OBJ_FILES = gensec_krb5.o
-PUBLIC_DEPENDENCIES = KERBEROS auth auth_sam
+PUBLIC_DEPENDENCIES = CREDENTIALS_KRB5 KERBEROS auth auth_sam
# End MODULE gensec_krb5
################################################
@@ -28,7 +28,7 @@ PUBLIC_DEPENDENCIES = KERBEROS auth auth_sam
SUBSYSTEM = gensec
INIT_FUNCTION = gensec_gssapi_init
OBJ_FILES = gensec_gssapi.o
-PUBLIC_DEPENDENCIES = KERBEROS auth HEIMDAL_GSSAPI
+PUBLIC_DEPENDENCIES = CREDENTIALS_KRB5 KERBEROS auth HEIMDAL_GSSAPI
# End MODULE gensec_gssapi
################################################
@@ -38,7 +38,7 @@ PUBLIC_DEPENDENCIES = KERBEROS auth HEIMDAL_GSSAPI
SUBSYSTEM = gensec
INIT_FUNCTION = gensec_sasl_init
OBJ_FILES = cyrus_sasl.o
-PUBLIC_DEPENDENCIES = SASL auth
+PUBLIC_DEPENDENCIES = CREDENTIALS SASL auth
# End MODULE cyrus_sasl
################################################
@@ -49,6 +49,7 @@ SUBSYSTEM = gensec
INIT_FUNCTION = gensec_spnego_init
PRIVATE_PROTO_HEADER = spnego_proto.h
PRIVATE_DEPENDENCIES = ASN1_UTIL GENSEC_SOCKET
+PUBLIC_DEPENDENCIES = CREDENTIALS
OBJ_FILES = spnego.o \
spnego_parse.o
# End MODULE gensec_spnego
@@ -62,7 +63,7 @@ PRIVATE_PROTO_HEADER = schannel_proto.h
INIT_FUNCTION = gensec_schannel_init
OBJ_FILES = schannel.o \
schannel_sign.o
-PUBLIC_DEPENDENCIES = auth SCHANNELDB NDR_SCHANNEL
+PUBLIC_DEPENDENCIES = auth SCHANNELDB NDR_SCHANNEL CREDENTIALS
OUTPUT_TYPE = INTEGRATED
# End MODULE gensec_schannel
################################################
diff --git a/source4/auth/gensec/cyrus_sasl.c b/source4/auth/gensec/cyrus_sasl.c
index 17a0162e8d..c0dd314d3d 100644
--- a/source4/auth/gensec/cyrus_sasl.c
+++ b/source4/auth/gensec/cyrus_sasl.c
@@ -22,6 +22,8 @@
#include "includes.h"
#include "auth/auth.h"
+#include "auth/credentials/credentials.h"
+#include "auth/gensec/gensec.h"
#include "lib/socket/socket.h"
#include <sasl/sasl.h>
diff --git a/source4/auth/gensec/gensec.c b/source4/auth/gensec/gensec.c
index 619cf7c350..8c97a871ad 100644
--- a/source4/auth/gensec/gensec.c
+++ b/source4/auth/gensec/gensec.c
@@ -26,6 +26,8 @@
#include "lib/events/events.h"
#include "build.h"
#include "librpc/rpc/dcerpc.h"
+#include "auth/credentials/credentials.h"
+#include "auth/gensec/gensec.h"
/* the list of currently registered GENSEC backends */
static struct gensec_security_ops **generic_security_ops;
diff --git a/source4/auth/gensec/gensec.h b/source4/auth/gensec/gensec.h
index 97d9577d83..c70424800c 100644
--- a/source4/auth/gensec/gensec.h
+++ b/source4/auth/gensec/gensec.h
@@ -42,6 +42,8 @@ enum gensec_priority {
GENSEC_OTHER = 0
};
+enum credentials_use_kerberos;
+
struct gensec_security;
struct gensec_target {
const char *principal;
@@ -167,7 +169,6 @@ struct gensec_critical_sizes {
int sizeof_gensec_security;
};
-#include "auth/credentials/credentials.h"
#include "auth/gensec/gensec_proto.h"
#endif /* __GENSEC_H__ */
diff --git a/source4/auth/gensec/gensec_krb5.c b/source4/auth/gensec/gensec_krb5.c
index 3695454c76..d84f3dedf5 100644
--- a/source4/auth/gensec/gensec_krb5.c
+++ b/source4/auth/gensec/gensec_krb5.c
@@ -34,6 +34,9 @@
#include "system/network.h"
#include "lib/socket/socket.h"
#include "librpc/rpc/dcerpc.h"
+#include "auth/credentials/credentials.h"
+#include "auth/credentials/credentials_krb5.h"
+#include "auth/gensec/gensec.h"
enum GENSEC_KRB5_STATE {
GENSEC_KRB5_SERVER_START,
diff --git a/source4/auth/gensec/schannel.c b/source4/auth/gensec/schannel.c
index 9bcb307548..18c6222e13 100644
--- a/source4/auth/gensec/schannel.c
+++ b/source4/auth/gensec/schannel.c
@@ -24,6 +24,8 @@
#include "includes.h"
#include "librpc/gen_ndr/ndr_schannel.h"
#include "auth/auth.h"
+#include "auth/credentials/credentials.h"
+#include "auth/gensec/gensec.h"
#include "auth/gensec/schannel.h"
#include "auth/gensec/schannel_state.h"
#include "auth/gensec/schannel_proto.h"
diff --git a/source4/auth/gensec/schannel.h b/source4/auth/gensec/schannel.h
index c109387c7c..4a05f8ab1a 100644
--- a/source4/auth/gensec/schannel.h
+++ b/source4/auth/gensec/schannel.h
@@ -21,6 +21,8 @@
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
+#include "libcli/auth/credentials.h"
+
enum schannel_position {
SCHANNEL_STATE_START = 0,
SCHANNEL_STATE_UPDATE_1
diff --git a/source4/auth/gensec/schannel_sign.c b/source4/auth/gensec/schannel_sign.c
index b4549ddefd..ad424f0299 100644
--- a/source4/auth/gensec/schannel_sign.c
+++ b/source4/auth/gensec/schannel_sign.c
@@ -25,6 +25,8 @@
#include "lib/crypto/crypto.h"
#include "auth/auth.h"
#include "auth/gensec/schannel.h"
+#include "auth/credentials/credentials.h"
+#include "auth/gensec/gensec.h"
#define NETSEC_SIGN_SIGNATURE { 0x77, 0x00, 0xff, 0xff, 0xff, 0xff, 0x00, 0x00 }
#define NETSEC_SEAL_SIGNATURE { 0x77, 0x00, 0x7a, 0x00, 0xff, 0xff, 0x00, 0x00 }
diff --git a/source4/auth/gensec/schannel_state.c b/source4/auth/gensec/schannel_state.c
index e9c81f370c..3c9ff64147 100644
--- a/source4/auth/gensec/schannel_state.c
+++ b/source4/auth/gensec/schannel_state.c
@@ -21,11 +21,12 @@
*/
#include "includes.h"
-#include "auth/auth.h"
#include "lib/ldb/include/ldb.h"
#include "lib/ldb/include/ldb_errors.h"
#include "dsdb/samdb/samdb.h"
#include "db_wrap.h"
+#include "libcli/auth/libcli_auth.h"
+#include "auth/auth.h"
/**
connect to the schannel ldb
diff --git a/source4/auth/gensec/spnego.c b/source4/auth/gensec/spnego.c
index f989455a72..c647ba5333 100644
--- a/source4/auth/gensec/spnego.c
+++ b/source4/auth/gensec/spnego.c
@@ -23,10 +23,10 @@
*/
#include "includes.h"
-#include "auth/auth.h"
-#include "auth/gensec/spnego_proto.h"
+#include "auth/gensec/spnego.h"
#include "librpc/gen_ndr/ndr_dcerpc.h"
-#include "lib/socket/socket.h"
+#include "auth/credentials/credentials.h"
+#include "auth/gensec/gensec.h"
#include "auth/gensec/socket.h"
enum spnego_state_position {
diff --git a/source4/auth/gensec/spnego.h b/source4/auth/gensec/spnego.h
index 1064370146..78afbe0107 100644
--- a/source4/auth/gensec/spnego.h
+++ b/source4/auth/gensec/spnego.h
@@ -21,9 +21,6 @@
Foundation, Inc., 675 Mass Ave, Cambridge, MA 02139, USA.
*/
-#ifndef SAMBA_SPNEGO_H
-#define SAMBA_SPNEGO_H
-
#define SPNEGO_DELEG_FLAG 0x01
#define SPNEGO_MUTUAL_FLAG 0x02
#define SPNEGO_REPLAY_FLAG 0x04
@@ -66,4 +63,4 @@ enum spnego_message_type {
SPNEGO_NEG_TOKEN_TARG = 1,
};
-#endif
+#include "auth/gensec/spnego_proto.h"
diff --git a/source4/auth/gensec/spnego_parse.c b/source4/auth/gensec/spnego_parse.c
index 8dde78da48..66e24bdbe5 100644
--- a/source4/auth/gensec/spnego_parse.c
+++ b/source4/auth/gensec/spnego_parse.c
@@ -22,7 +22,8 @@
*/
#include "includes.h"
-#include "auth/auth.h"
+#include "auth/gensec/spnego.h"
+#include "auth/gensec/gensec.h"
#include "libcli/util/asn_1.h"
static BOOL read_negTokenInit(struct asn1_data *asn1, struct spnego_negTokenInit *token)