svn rev #24995: trunk/src/util/gss-kernel-lib/

ghudson@MIT.EDU ghudson at MIT.EDU
Mon Jun 27 18:23:24 EDT 2011


http://src.mit.edu/fisheye/changelog/krb5/?cs=24995
Commit By: ghudson
Log Message:
Enable and fix warnings in util/gss-kernel-lib.


Changed Files:
U   trunk/src/util/gss-kernel-lib/Makefile.in
U   trunk/src/util/gss-kernel-lib/deps
U   trunk/src/util/gss-kernel-lib/kernel_gss.c
A   trunk/src/util/gss-kernel-lib/kernel_gss.h
U   trunk/src/util/gss-kernel-lib/t_kgss_common.c
U   trunk/src/util/gss-kernel-lib/t_kgss_kernel.c
U   trunk/src/util/gss-kernel-lib/t_kgss_user.c
Modified: trunk/src/util/gss-kernel-lib/Makefile.in
===================================================================
--- trunk/src/util/gss-kernel-lib/Makefile.in	2011-06-27 22:23:18 UTC (rev 24994)
+++ trunk/src/util/gss-kernel-lib/Makefile.in	2011-06-27 22:23:23 UTC (rev 24995)
@@ -4,7 +4,7 @@
 KRB5_RUN_ENV=@KRB5_RUN_ENV@
 
 DEFINES=-DKRB5_KERNEL
-ALL_CFLAGS=$(CFLAGS) $(DEFS) $(DEFINES) -I. -Igssapi
+ALL_CFLAGS=$(CFLAGS) $(WARN_CFLAGS) $(DEFS) $(DEFINES) -I. -Igssapi
 PROG_LIBPATH=-L$(TOPLIBD)
 
 SHLIB_EXPDEPS = \

Modified: trunk/src/util/gss-kernel-lib/deps
===================================================================
--- trunk/src/util/gss-kernel-lib/deps	2011-06-27 22:23:18 UTC (rev 24994)
+++ trunk/src/util/gss-kernel-lib/deps	2011-06-27 22:23:23 UTC (rev 24995)
@@ -6,9 +6,10 @@
   gssapiP_generic.h gssapiP_krb5.h gssapi_err_generic.h \
   gssapi_err_krb5.h gssapi_generic.h k5-buf.h k5-err.h \
   k5-gmt_mktime.h k5-int-pkinit.h k5-int.h k5-platform.h \
-  k5-plugin.h k5-thread.h k5-trace.h kernel_gss.c krb5.h \
-  krb5/authdata_plugin.h krb5/krb5.h krb5/plugin.h krb5/preauth_plugin.h \
-  osconf.h port-sockets.h profile.h socket-utils.h
+  k5-plugin.h k5-thread.h k5-trace.h kernel_gss.c kernel_gss.h \
+  krb5.h krb5/authdata_plugin.h krb5/krb5.h krb5/plugin.h \
+  krb5/preauth_plugin.h osconf.h port-sockets.h profile.h \
+  socket-utils.h
 $(OUTPRE)k5seal.$(OBJEXT): autoconf.h com_err.h gssapi/gssapi.h \
   gssapi/gssapi_ext.h gssapi/gssapi_krb5.h gssapiP_generic.h \
   gssapiP_krb5.h gssapi_err_generic.h gssapi_err_krb5.h \
@@ -106,7 +107,8 @@
   k5-buf.h k5-err.h k5-gmt_mktime.h k5-int-pkinit.h k5-int.h \
   k5-platform.h k5-plugin.h k5-thread.h k5-trace.h krb5.h \
   krb5/authdata_plugin.h krb5/krb5.h krb5/plugin.h krb5/preauth_plugin.h \
-  osconf.h port-sockets.h profile.h socket-utils.h t_kgss_common.c
+  osconf.h port-sockets.h profile.h socket-utils.h t_kgss_common.c \
+  t_kgss_common.h
 $(OUTPRE)t_kgss_user.$(OBJEXT): autoconf.h com_err.h \
   gssapi/gssapi.h gssapi/gssapi_ext.h gssapi/gssapi_krb5.h \
   k5-buf.h k5-err.h k5-gmt_mktime.h k5-int-pkinit.h k5-int.h \
@@ -116,7 +118,10 @@
   t_kgss_user.c
 $(OUTPRE)t_kgss_kernel.$(OBJEXT): autoconf.h com_err.h \
   gssapi/gssapi.h gssapi/gssapi_ext.h gssapi/gssapi_krb5.h \
-  k5-buf.h k5-err.h k5-gmt_mktime.h k5-int-pkinit.h k5-int.h \
-  k5-platform.h k5-plugin.h k5-thread.h k5-trace.h krb5.h \
+  gssapiP_generic.h gssapiP_krb5.h gssapi_err_generic.h \
+  gssapi_err_krb5.h gssapi_generic.h k5-buf.h k5-err.h \
+  k5-gmt_mktime.h k5-int-pkinit.h k5-int.h k5-platform.h \
+  k5-plugin.h k5-thread.h k5-trace.h kernel_gss.h krb5.h \
   krb5/authdata_plugin.h krb5/krb5.h krb5/plugin.h krb5/preauth_plugin.h \
-  osconf.h port-sockets.h profile.h socket-utils.h t_kgss_kernel.c
+  osconf.h port-sockets.h profile.h socket-utils.h t_kgss_common.h \
+  t_kgss_kernel.c

Modified: trunk/src/util/gss-kernel-lib/kernel_gss.c
===================================================================
--- trunk/src/util/gss-kernel-lib/kernel_gss.c	2011-06-27 22:23:18 UTC (rev 24994)
+++ trunk/src/util/gss-kernel-lib/kernel_gss.c	2011-06-27 22:23:23 UTC (rev 24995)
@@ -30,6 +30,7 @@
  */
 
 #include "gssapiP_krb5.h"
+#include "kernel_gss.h"
 
 /* Normally defined in lib/gssapi/krb5/gssapi_krb5.c. */
 static const gss_OID_desc oid_array[] = {
@@ -44,7 +45,6 @@
 lkey_to_key(const gss_krb5_lucid_key_t *lkey, krb5_key *key_out)
 {
     krb5_keyblock kb;
-    krb5_key key;
 
     kb.enctype = lkey->type;
     kb.length = lkey->length;

Added: trunk/src/util/gss-kernel-lib/kernel_gss.h
===================================================================
--- trunk/src/util/gss-kernel-lib/kernel_gss.h	                        (rev 0)
+++ trunk/src/util/gss-kernel-lib/kernel_gss.h	2011-06-27 22:23:23 UTC (rev 24995)
@@ -0,0 +1,36 @@
+/* -*- mode: c; c-basic-offset: 4; indent-tabs-mode: nil -*- */
+/* util/gss-kernel-lib/kernel_gss.h - Declarations for kernel GSS library */
+/*
+ * Copyright (C) 2011 by the Massachusetts Institute of Technology.
+ * All rights reserved.
+ *
+ * Export of this software from the United States of America may
+ *   require a specific license from the United States Government.
+ *   It is the responsibility of any person or organization contemplating
+ *   export to obtain such a license before exporting.
+ *
+ * WITHIN THAT CONSTRAINT, permission to use, copy, modify, and
+ * distribute this software and its documentation for any purpose and
+ * without fee is hereby granted, provided that the above copyright
+ * notice appear in all copies and that both that copyright notice and
+ * this permission notice appear in supporting documentation, and that
+ * the name of M.I.T. not be used in advertising or publicity pertaining
+ * to distribution of the software without specific, written prior
+ * permission.  Furthermore if you modify this software you must label
+ * your software as modified software and not distribute it in such a
+ * fashion that it might be confused with the original M.I.T. software.
+ * M.I.T. makes no representations about the suitability of
+ * this software for any purpose.  It is provided "as is" without express
+ * or implied warranty.
+ */
+
+#ifndef KERNEL_GSS_H
+#define KERNEL_GSS_H
+
+#include <gssapi/gssapi_krb5.h>
+
+OM_uint32
+krb5_gss_import_lucid_sec_context(OM_uint32 *minor_status, void *lctx,
+                                  gss_ctx_id_t *context_handle_out);
+
+#endif /* KERNEL_GSS_H */

Modified: trunk/src/util/gss-kernel-lib/t_kgss_common.c
===================================================================
--- trunk/src/util/gss-kernel-lib/t_kgss_common.c	2011-06-27 22:23:18 UTC (rev 24994)
+++ trunk/src/util/gss-kernel-lib/t_kgss_common.c	2011-06-27 22:23:23 UTC (rev 24995)
@@ -27,6 +27,7 @@
 #include "k5-int.h"
 #include <unistd.h>
 #include <gssapi/gssapi_krb5.h>
+#include "t_kgss_common.h"
 
 /* Write len bytes of data to fd, aborting on failure. */
 void

Modified: trunk/src/util/gss-kernel-lib/t_kgss_kernel.c
===================================================================
--- trunk/src/util/gss-kernel-lib/t_kgss_kernel.c	2011-06-27 22:23:18 UTC (rev 24994)
+++ trunk/src/util/gss-kernel-lib/t_kgss_kernel.c	2011-06-27 22:23:23 UTC (rev 24995)
@@ -33,6 +33,9 @@
 #include "k5-int.h"
 #include <unistd.h>
 #include "gssapi_krb5.h"
+#include "gssapiP_krb5.h"
+#include "kernel_gss.h"
+#include "t_kgss_common.h"
 
 /* If major represents an error, display an error message and exit. */
 static void
@@ -101,8 +104,6 @@
 read_wrap_token(gss_ctx_id_t ctx)
 {
     OM_uint32 major, minor;
-    unsigned char *data;
-    size_t len;
     gss_buffer_desc wrapped, buf;
 
     read_data(STDIN_FILENO, &wrapped.value, &wrapped.length);
@@ -118,8 +119,6 @@
 read_mic_token(gss_ctx_id_t ctx)
 {
     OM_uint32 major, minor;
-    unsigned char *data;
-    size_t len;
     gss_buffer_desc mic, buf;
 
     read_data(STDIN_FILENO, &mic.value, &mic.length);

Modified: trunk/src/util/gss-kernel-lib/t_kgss_user.c
===================================================================
--- trunk/src/util/gss-kernel-lib/t_kgss_user.c	2011-06-27 22:23:18 UTC (rev 24994)
+++ trunk/src/util/gss-kernel-lib/t_kgss_user.c	2011-06-27 22:23:23 UTC (rev 24995)
@@ -176,7 +176,7 @@
     } else
         abort();
     assert(krb5int_buf_data(&buf) != NULL);
-    *data_out = krb5int_buf_data(&buf);
+    *data_out = (unsigned char *)krb5int_buf_data(&buf);
     *len_out = krb5int_buf_len(&buf);
 }
 
@@ -289,8 +289,6 @@
 read_wrap_token(gss_ctx_id_t ctx, int fd)
 {
     OM_uint32 major, minor;
-    unsigned char *data;
-    size_t len;
     gss_buffer_desc wrapped, buf;
 
     read_data(fd, &wrapped.value, &wrapped.length);
@@ -306,8 +304,6 @@
 read_mic_token(gss_ctx_id_t ctx, int fd)
 {
     OM_uint32 major, minor;
-    unsigned char *data;
-    size_t len;
     gss_buffer_desc mic, buf;
 
     read_data(fd, &mic.value, &mic.length);




More information about the cvs-krb5 mailing list