[3088] in Kerberos-V5-bugs

home help back first fref pref prev next nref lref last post

krb5-libs/729: krb5.h missing extern "C" {} around krb5_get_init_cred_* routines

daemon@ATHENA.MIT.EDU (Chas Williams)
Sun Jun 27 15:23:13 1999

Resent-From: gnats@rt-11.MIT.EDU (GNATS Management)
Resent-To: krb5-unassigned@RT-11.MIT.EDU
Resent-Reply-To: krb5-bugs@MIT.EDU, chas@cmf.nrl.navy.mil
Message-Id: <199906271922.PAA01083@fermi.cmf.nrl.navy.mil>
Date: Sun, 27 Jun 1999 15:22:30 -0400
From: Chas Williams <chas@cmf.nrl.navy.mil>
Reply-To: chas@cmf.nrl.navy.mil
To: krb5-bugs@MIT.EDU
Cc: kenh@cmf.nrl.navy.mil


>Number:         729
>Category:       krb5-libs
>Synopsis:       krb5.h missing extern "C" {} around various routines
>Confidential:   no
>Severity:       non-critical
>Priority:       medium
>Responsible:    krb5-unassigned
>State:          open
>Class:          sw-bug
>Submitter-Id:   unknown
>Arrival-Date:   Sun Jun 27 15:23:01 EDT 1999
>Last-Modified:
>Originator:     Chas Williams
>Organization:
	Naval Research Laboratory, Washington, DC
>Release:        krb5-current-19990626
>Environment:
	
System: SunOS fermi 5.6 Generic_105181-11 sun4d sparc SUNW,SPARCserver-1000
Architecture: sun4

>Description:

	krb5.h is missing extern "C" {} around various routines
	it defines.  this causes trouble when building c++ based
	utilties will call kerberos routines.  in particular,
	i am having trouble with:

		krb5_get_init_creds_opt_init
		krb5_get_init_creds_opt_set_tkt_life
		krb5_get_init_creds_opt_set_renew_life
		krb5_get_init_creds_opt_set_forwardable
		krb5_get_init_creds_opt_set_proxiable
		krb5_get_init_creds_opt_set_etype_list
		krb5_get_init_creds_opt_set_address_list
		krb5_get_init_creds_opt_set_preauth_list
		krb5_get_init_creds_opt_set_salt
		krb5_get_init_creds_password
		krb5_get_init_creds_keytab

	but various other places in krb5.h should have c linkage
	declarations.

	
>How-To-Repeat:

	build something with g++ and try to link one of the above.
	
>Fix:
	

	well, in my code, i just extern "C" { #include "krb5.h" }
	but the header should do this job, not me.  perhaps just
	wrapping the entire krb5.h with a single extern "C" would
	be better (i.e. less would fall through the cracks)
>Audit-Trail:
>Unformatted:

home help back first fref pref prev next nref lref last post