summaryrefslogtreecommitdiffstats
path: root/src/lib/gssapi
diff options
context:
space:
mode:
authorTom Yu <tlyu@mit.edu>2002-07-14 22:37:52 +0000
committerTom Yu <tlyu@mit.edu>2002-07-14 22:37:52 +0000
commita68afdd3636a7b158d559f5f3e07763b180f7ce5 (patch)
tree7e0a5779c9dc3ad07047da04cb7497353054f7bd /src/lib/gssapi
parent8be40d6a17a44ce183350e3cb0eefb29fca32efd (diff)
downloadkrb5-a68afdd3636a7b158d559f5f3e07763b180f7ce5.tar.gz
krb5-a68afdd3636a7b158d559f5f3e07763b180f7ce5.tar.xz
krb5-a68afdd3636a7b158d559f5f3e07763b180f7ce5.zip
* gssapi_krb5.h: Added #include of gssapi.h and gssapi_generic.h
for the Mac because we can't assume people will include them and get the OID macro and the old names on the Mac. * disp_status.c: Updated Mac OS X header paths. * gssapiP_krb5.h: Updated Mac OS X header paths and added prototype on Mac. * gssapi_krb5.h: Updated Mac OS X headers to new framework layout * gssapi_krb5.h, gssapi_krb5.c: Added oids from rfc 1964 using the suggested names. [pullups from 1-2-2-branch] git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@14646 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src/lib/gssapi')
-rw-r--r--src/lib/gssapi/krb5/ChangeLog21
-rw-r--r--src/lib/gssapi/krb5/disp_status.c5
-rw-r--r--src/lib/gssapi/krb5/gssapiP_krb5.h8
-rw-r--r--src/lib/gssapi/krb5/gssapi_krb5.c17
-rw-r--r--src/lib/gssapi/krb5/gssapi_krb5.h54
5 files changed, 96 insertions, 9 deletions
diff --git a/src/lib/gssapi/krb5/ChangeLog b/src/lib/gssapi/krb5/ChangeLog
index b635d888d7..eb69c56a6a 100644
--- a/src/lib/gssapi/krb5/ChangeLog
+++ b/src/lib/gssapi/krb5/ChangeLog
@@ -1,3 +1,24 @@
+2002-07-14 Alexandra Ellwood <lxs@mit.edu>
+
+ * gssapi_krb5.h: Added #include of gssapi.h and gssapi_generic.h
+ for the Mac because we can't assume people will include them and
+ get the OID macro and the old names on the Mac.
+
+ * disp_status.c: Updated Mac OS X header paths.
+
+ * gssapiP_krb5.h: Updated Mac OS X header paths and added
+ prototype on Mac.
+
+ * gssapi_krb5.h: Updated Mac OS X headers to new framework layout
+
+ [pullups from 1-2-2-branch]
+
+2002-07-14 Miro Jurisic <meeroh@mit.edu>
+
+ * gssapi_krb5.h, gssapi_krb5.c: Added oids from rfc 1964 using the
+ suggested names.
+ [pullup from 1-2-2-branch]
+
2002-07-12 Ken Raeburn <raeburn@mit.edu>
* accept_sec_context.c (rd_and_store_for_creds): Remove
diff --git a/src/lib/gssapi/krb5/disp_status.c b/src/lib/gssapi/krb5/disp_status.c
index 0b296f6ce6..7725e4ddae 100644
--- a/src/lib/gssapi/krb5/disp_status.c
+++ b/src/lib/gssapi/krb5/disp_status.c
@@ -21,7 +21,12 @@
*/
#include "gssapiP_krb5.h"
+
+#if TARGET_OS_MAC
+#include <Kerberos/com_err.h>
+#else
#include "com_err.h"
+#endif
/* XXXX internationalization!! */
diff --git a/src/lib/gssapi/krb5/gssapiP_krb5.h b/src/lib/gssapi/krb5/gssapiP_krb5.h
index d8963f2e2c..a51db06bbc 100644
--- a/src/lib/gssapi/krb5/gssapiP_krb5.h
+++ b/src/lib/gssapi/krb5/gssapiP_krb5.h
@@ -47,7 +47,11 @@
#ifndef _GSSAPIP_KRB5_H_
#define _GSSAPIP_KRB5_H_
+#if TARGET_OS_MAC
+#include <Kerberos/krb5.h>
+#else
#include <krb5.h>
+#endif
#ifdef HAVE_MEMORY_H
#include <memory.h>
#endif
@@ -60,11 +64,7 @@
#undef minor
#endif
-#ifndef macintosh
-#include "../generic/gssapiP_generic.h"
-#else
#include "gssapiP_generic.h"
-#endif
/* The include of gssapi_krb5.h will dtrt with the above #defines in
* effect.
diff --git a/src/lib/gssapi/krb5/gssapi_krb5.c b/src/lib/gssapi/krb5/gssapi_krb5.c
index efcf36c86e..189c9449d5 100644
--- a/src/lib/gssapi/krb5/gssapi_krb5.c
+++ b/src/lib/gssapi/krb5/gssapi_krb5.c
@@ -93,15 +93,24 @@ const gss_OID_desc krb5_gss_oid_array[] = {
/* this is the v2 assigned OID */
{9, "\052\206\110\206\367\022\001\002\003"},
/* these two are name type OID's */
+
+ /* 2.1.1. Kerberos Principal Name Form: (rfc 1964)
+ * This name form shall be represented by the Object Identifier {iso(1)
+ * member-body(2) United States(840) mit(113554) infosys(1) gssapi(2)
+ * krb5(2) krb5_name(1)}. The recommended symbolic name for this type
+ * is "GSS_KRB5_NT_PRINCIPAL_NAME". */
{10, "\052\206\110\206\367\022\001\002\002\001"},
+
+ /* gss_nt_krb5_principal. Object identifier for a krb5_principal. Do not use. */
{10, "\052\206\110\206\367\022\001\002\002\002"},
{ 0, 0 }
};
-const gss_OID_desc * const gss_mech_krb5 = krb5_gss_oid_array+0;
-const gss_OID_desc * const gss_mech_krb5_old = krb5_gss_oid_array+1;
-const gss_OID_desc * const gss_nt_krb5_name = krb5_gss_oid_array+3;
-const gss_OID_desc * const gss_nt_krb5_principal = krb5_gss_oid_array+4;
+const gss_OID_desc * const gss_mech_krb5 = krb5_gss_oid_array+0;
+const gss_OID_desc * const gss_mech_krb5_old = krb5_gss_oid_array+1;
+const gss_OID_desc * const gss_nt_krb5_name = krb5_gss_oid_array+3;
+const gss_OID_desc * const gss_nt_krb5_principal = krb5_gss_oid_array+4;
+const gss_OID_desc * const GSS_KRB5_NT_PRINCIPAL_NAME = krb5_gss_oid_array+3;
static const gss_OID_set_desc oidsets[] = {
{1, (gss_OID) krb5_gss_oid_array+0},
diff --git a/src/lib/gssapi/krb5/gssapi_krb5.h b/src/lib/gssapi/krb5/gssapi_krb5.h
index da2e94e7e0..1de52d42ea 100644
--- a/src/lib/gssapi/krb5/gssapi_krb5.h
+++ b/src/lib/gssapi/krb5/gssapi_krb5.h
@@ -23,13 +23,65 @@
#ifndef _GSSAPI_KRB5_H_
#define _GSSAPI_KRB5_H_
-#include <krb5.h>
+#if defined(macintosh) || (defined(__MACH__) && defined(__APPLE__))
+# include <TargetConditionals.h>
+#endif
+
+#if TARGET_OS_MAC
+# include <Kerberos/krb5.h>
+# include <Kerberos/gssapi.h>
+# include <Kerberos/gssapi_generic.h>
+#else
+# include <krb5.h>
+#endif
/* C++ friendlyness */
#ifdef __cplusplus
extern "C" {
#endif /* __cplusplus */
+#if GSS_RFC_COMPLIANT_OIDS
+/* Reserved static storage for GSS_oids. See rfc 1964 for more details. */
+
+/* 2.1.1. Kerberos Principal Name Form: */
+GSS_DLLIMP extern const gss_OID_desc * const GSS_KRB5_NT_PRINCIPAL_NAME;
+/* This name form shall be represented by the Object Identifier {iso(1)
+ * member-body(2) United States(840) mit(113554) infosys(1) gssapi(2)
+ * krb5(2) krb5_name(1)}. The recommended symbolic name for this type
+ * is "GSS_KRB5_NT_PRINCIPAL_NAME". */
+
+/* 2.1.2. Host-Based Service Name Form */
+#define GSS_KRB5_NT_HOSTBASED_SERVICE_NAME GSS_C_NT_HOSTBASED_SERVICE
+/* This name form shall be represented by the Object Identifier {iso(1)
+ * member-body(2) United States(840) mit(113554) infosys(1) gssapi(2)
+ * generic(1) service_name(4)}. The previously recommended symbolic
+ * name for this type is "GSS_KRB5_NT_HOSTBASED_SERVICE_NAME". The
+ * currently preferred symbolic name for this type is
+ * "GSS_C_NT_HOSTBASED_SERVICE". */
+
+/* 2.2.1. User Name Form */
+#define GSS_KRB5_NT_USER_NAME GSS_C_NT_USER_NAME
+/* This name form shall be represented by the Object Identifier {iso(1)
+ * member-body(2) United States(840) mit(113554) infosys(1) gssapi(2)
+ * generic(1) user_name(1)}. The recommended symbolic name for this
+ * type is "GSS_KRB5_NT_USER_NAME". */
+
+/* 2.2.2. Machine UID Form */
+#define GSS_KRB5_NT_MACHINE_UID_NAME GSS_C_NT_MACHINE_UID_NAME
+/* This name form shall be represented by the Object Identifier {iso(1)
+ * member-body(2) United States(840) mit(113554) infosys(1) gssapi(2)
+ * generic(1) machine_uid_name(2)}. The recommended symbolic name for
+ * this type is "GSS_KRB5_NT_MACHINE_UID_NAME". */
+
+/* 2.2.3. String UID Form */
+#define GSS_KRB5_NT_STRING_UID_NAME GSS_C_NT_STRING_UID_NAME
+/* This name form shall be represented by the Object Identifier {iso(1)
+ * member-body(2) United States(840) mit(113554) infosys(1) gssapi(2)
+ * generic(1) string_uid_name(3)}. The recommended symbolic name for
+ * this type is "GSS_KRB5_NT_STRING_UID_NAME". */
+
+#endif /* GSS_RFC_COMPLIANT_OIDS */
+
extern const gss_OID_desc * const gss_mech_krb5;
extern const gss_OID_desc * const gss_mech_krb5_old;
extern const gss_OID_set_desc * const gss_mech_set_krb5;