]> andersk Git - openssh.git/commitdiff
- dtucker@cvs.openbsd.org 2006/08/29 12:02:30
authordjm <djm>
Wed, 30 Aug 2006 01:08:04 +0000 (01:08 +0000)
committerdjm <djm>
Wed, 30 Aug 2006 01:08:04 +0000 (01:08 +0000)
     [gss-genr.c]
     Work around a problem in Heimdal that occurs when KRB5CCNAME file is
     missing, by checking whether or not kerberos allocated us a context
     before attempting to free it.  Patch from Simon Wilkinson, tested by
     biorn@, ok djm@

ChangeLog
gss-genr.c

index c4435140e99c91b59d310a2dfca275381e2c6dad..34a0ee65ed80ac49ce4f5a33d2c0a73c2eab88e2 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
      normalise some inconsistent (but harmless) NULL pointer checks
      spotted by the Stanford SATURN tool, via Isil Dillig;
      ok markus@ deraadt@
+   - dtucker@cvs.openbsd.org 2006/08/29 12:02:30
+     [gss-genr.c]
+     Work around a problem in Heimdal that occurs when KRB5CCNAME file is
+     missing, by checking whether or not kerberos allocated us a context
+     before attempting to free it.  Patch from Simon Wilkinson, tested by
+     biorn@, ok djm@
 
 20060824
  - (dtucker) [openbsd-compat/basename.c] Include errno.h.
index e962942d1a0b892a13bf7315fe21695d63a85879..57f12a2dc8e581d90a2ab45dbda0bd505cc145f4 100644 (file)
@@ -1,4 +1,4 @@
-/* $OpenBSD: gss-genr.c,v 1.16 2006/08/18 22:41:29 djm Exp $ */
+/* $OpenBSD: gss-genr.c,v 1.17 2006/08/29 12:02:30 dtucker Exp $ */
 
 /*
  * Copyright (c) 2001-2006 Simon Wilkinson. All rights reserved.
@@ -310,8 +310,9 @@ ssh_gssapi_check_mechanism(Gssctxt **ctx, gss_OID oid, const char *host)
                major = ssh_gssapi_init_ctx(*ctx, 0, GSS_C_NO_BUFFER, &token, 
                    NULL);
                gss_release_buffer(&minor, &token);
-               gss_delete_sec_context(&minor, &(*ctx)->context, 
-                   GSS_C_NO_BUFFER);
+               if ((*ctx)->context != GSS_C_NO_CONTEXT)
+                       gss_delete_sec_context(&minor, &(*ctx)->context,
+                           GSS_C_NO_BUFFER);
        }
 
        if (GSS_ERROR(major)) 
This page took 0.050777 seconds and 5 git commands to generate.