libkrb5: Add missing KRB5_LIB_FUNCTION/KRB5_LIB_CALL

KRB5_LIB_FUNCTION and KRB5_LIB_CALL are necessary even on private
functions that are exported.

Change-Id: Iccd0cfe87ff0a9d851e29890e9cb55b3ae517ce1
This commit is contained in:
Jeffrey Altman
2013-06-22 18:10:01 -04:00
parent dd47d25e5d
commit 5f138a16ef
27 changed files with 61 additions and 61 deletions

View File

@@ -168,7 +168,7 @@ init_ccapi(krb5_context context)
#endif
}
void
KRB5_LIB_FUNCTION void KRB5_LIB_CALL
_heim_krb5_ipc_client_set_target_uid(uid_t uid)
{
init_ccapi(NULL);
@@ -176,7 +176,7 @@ _heim_krb5_ipc_client_set_target_uid(uid_t uid)
(*set_target_uid)(uid);
}
void
KRB5_LIB_FUNCTION void KRB5_LIB_CALL
_heim_krb5_ipc_client_clear_target(void)
{
init_ccapi(NULL);

View File

@@ -155,7 +155,7 @@ krb5_cc_register(krb5_context context,
* `ops'. Returns 0 or and error code.
*/
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_cc_allocate(krb5_context context,
const krb5_cc_ops *ops,
krb5_ccache *id)
@@ -406,7 +406,7 @@ krb5_cc_get_ops(krb5_context context, krb5_ccache id)
* Expand variables in `str' into `res'
*/
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_expand_default_cc_name(krb5_context context, const char *str, char **res)
{
return _krb5_expand_path_tokens(context, str, res);
@@ -1741,7 +1741,7 @@ krb5_cc_get_kdc_offset(krb5_context context, krb5_ccache id, krb5_deltat *offset
#ifdef _WIN32
#define REGPATH_MIT_KRB5 "SOFTWARE\\MIT\\Kerberos5"
char *
KRB5_LIB_FUNCTION char * KRB5_LIB_CALL
_krb5_get_default_cc_name_from_registry(krb5_context context)
{
HKEY hk_k5 = 0;
@@ -1763,7 +1763,7 @@ _krb5_get_default_cc_name_from_registry(krb5_context context)
return ccname;
}
int
KRB5_LIB_FUNCTION int KRB5_LIB_CALL
_krb5_set_default_cc_name_to_registry(krb5_context context, krb5_ccache id)
{
HKEY hk_k5 = 0;

View File

@@ -82,7 +82,7 @@ static krb5_error_code parse_list(struct fileptr *f, unsigned *lineno,
krb5_config_binding **parent,
const char **err_message);
krb5_config_section *
KRB5_LIB_FUNCTION krb5_config_section * KRB5_LIB_CALL
_krb5_config_get_entry(krb5_config_section **parent, const char *name, int type)
{
krb5_config_section **q;
@@ -692,7 +692,7 @@ _krb5_config_get (krb5_context context,
}
const void *
KRB5_LIB_FUNCTION const void * KRB5_LIB_CALL
_krb5_config_vget (krb5_context context,
const krb5_config_section *c,
int type,

View File

@@ -86,7 +86,7 @@
* krb5_set_error_message().
*
*/
int
KRB5_LIB_FUNCTION int KRB5_LIB_CALL
_krb5_store_string_to_reg_value(krb5_context context,
HKEY key, const char * valuename,
DWORD type, const char *data, DWORD cb_data,
@@ -212,7 +212,7 @@ _krb5_store_string_to_reg_value(krb5_context context,
*
* @see _krb5_parse_reg_value_as_multi_string()
*/
char *
KRB5_LIB_FUNCTION char * KRB5_LIB_CALL
_krb5_parse_reg_value_as_string(krb5_context context,
HKEY key, const char * valuename,
DWORD type, DWORD cb_data)
@@ -251,7 +251,7 @@ _krb5_parse_reg_value_as_string(krb5_context context,
* If NULL is returned, an error message has been set using
* krb5_set_error_message().
*/
char *
KRB5_LIB_FUNCTION char * KRB5_LIB_CALL
_krb5_parse_reg_value_as_multi_string(krb5_context context,
HKEY key, const char * valuename,
DWORD type, DWORD cb_data, char *separator)
@@ -620,7 +620,7 @@ load_config_from_regpath(krb5_context context,
*
* @see parse_reg_value() for details about how each type of value is handled.
*/
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_load_config_from_registry(krb5_context context,
krb5_config_section ** res)
{

View File

@@ -779,7 +779,7 @@ krb5_prepend_config_files_default(const char *filelist, char ***pfilenames)
* to find the configuration file location in the
* SOFTWARE\MIT\Kerberos registry key under the value "config".
*/
char *
KRB5_LIB_FUNCTION char * KRB5_LIB_CALL
_krb5_get_default_config_config_files_from_registry()
{
static const char * KeyName = "Software\\MIT\\Kerberos";
@@ -1485,7 +1485,7 @@ _krb5_init_etype(krb5_context context,
static HEIMDAL_MUTEX homedir_mutex = HEIMDAL_MUTEX_INITIALIZER;
static krb5_boolean allow_homedir = TRUE;
krb5_boolean
KRB5_LIB_FUNCTION krb5_boolean KRB5_LIB_CALL
_krb5_homedir_access(krb5_context context)
{
krb5_boolean allow;

View File

@@ -37,7 +37,7 @@ static u_long table[256];
#define CRC_GEN 0xEDB88320L
void
KRB5_LIB_FUNCTION void KRB5_LIB_CALL
_krb5_crc_init_table(void)
{
static int flag = 0;
@@ -60,7 +60,7 @@ _krb5_crc_init_table(void)
flag = 1;
}
uint32_t
KRB5_LIB_FUNCTION uint32_t KRB5_LIB_CALL
_krb5_crc_update (const char *p, size_t len, uint32_t res)
{
while (len--)

View File

@@ -265,7 +265,7 @@ ARCFOUR_subdecrypt(krb5_context context,
* draft-brezak-win2k-krb-rc4-hmac-04.txt
*/
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_usage2arcfour(krb5_context context, unsigned *usage)
{
switch (*usage) {

View File

@@ -39,7 +39,7 @@
* A = A xor B. A & B are 8 bytes.
*/
void
KRB5_LIB_FUNCTION void KRB5_LIB_CALL
_krb5_xor (DES_cblock *key, const unsigned char *b)
{
unsigned char *a = (unsigned char*)key;
@@ -54,7 +54,7 @@ _krb5_xor (DES_cblock *key, const unsigned char *b)
}
#if defined(DES3_OLD_ENCTYPE) || defined(HEIM_WEAK_CRYPTO)
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_des_checksum(krb5_context context,
const EVP_MD *evp_md,
struct _krb5_key_data *key,
@@ -85,7 +85,7 @@ _krb5_des_checksum(krb5_context context,
return 0;
}
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_des_verify(krb5_context context,
const EVP_MD *evp_md,
struct _krb5_key_data *key,

View File

@@ -35,7 +35,7 @@
#include <pkinit_asn1.h>
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_pk_octetstring2key(krb5_context context,
krb5_enctype type,
const void *dhdata,
@@ -191,7 +191,7 @@ encode_otherinfo(krb5_context context,
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_pk_kdf(krb5_context context,
const struct AlgorithmIdentifier *ai,
const void *dhdata,

View File

@@ -75,7 +75,7 @@ krb5_free_context(krb5_context context)
free(context);
}
krb5_boolean
KRB5_LIB_FUNCTION krb5_boolean KRB5_LIB_CALL
_krb5_homedir_access(krb5_context context) {
return 0;
}

View File

@@ -177,7 +177,7 @@ SHA1_checksum(krb5_context context,
}
/* HMAC according to RFC2104 */
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_internal_hmac(krb5_context context,
struct _krb5_checksum_type *cm,
const void *data,
@@ -298,7 +298,7 @@ struct _krb5_checksum_type _krb5_checksum_sha1 = {
NULL
};
struct _krb5_checksum_type *
KRB5_LIB_FUNCTION struct _krb5_checksum_type * KRB5_LIB_CALL
_krb5_find_checksum(krb5_cksumtype type)
{
int i;
@@ -636,7 +636,7 @@ krb5_checksum_disable(krb5_context context,
* *
************************************************************/
struct _krb5_encryption_type *
KRB5_LIB_FUNCTION struct _krb5_encryption_type * KRB5_LIB_CALL
_krb5_find_enctype(krb5_enctype type)
{
int i;
@@ -1824,7 +1824,7 @@ krb5_decrypt_EncryptedData(krb5_context context,
* *
************************************************************/
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_derive_key(krb5_context context,
struct _krb5_encryption_type *et,
struct _krb5_key_data *key,
@@ -2049,7 +2049,7 @@ free_key_schedule(krb5_context context,
krb5_free_data(context, key->schedule);
}
void
KRB5_LIB_FUNCTION void KRB5_LIB_CALL
_krb5_free_key_data(krb5_context context, struct _krb5_key_data *key,
struct _krb5_encryption_type *et)
{

View File

@@ -23,7 +23,7 @@ db_plugins_init(void *arg)
db_plugins_plcallback);
}
void
KRB5_LIB_FUNCTION void KRB5_LIB_CALL
_krb5_load_db_plugins(krb5_context context)
{
heim_base_once_f(&db_plugins_once, context, db_plugins_init);

View File

@@ -34,7 +34,7 @@
#include "krb5_locl.h"
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_fast_cf2(krb5_context context,
krb5_keyblock *key1,
const char *pepper1,
@@ -78,7 +78,7 @@ _krb5_fast_cf2(krb5_context context,
return ret;
}
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_fast_armor_key(krb5_context context,
krb5_keyblock *subkey,
krb5_keyblock *sessionkey,

View File

@@ -68,7 +68,7 @@ fcc_get_name(krb5_context context,
return FILENAME(id);
}
int
KRB5_LIB_FUNCTION int KRB5_LIB_CALL
_krb5_xlock(krb5_context context, int fd, krb5_boolean exclusive,
const char *filename)
{
@@ -112,7 +112,7 @@ _krb5_xlock(krb5_context context, int fd, krb5_boolean exclusive,
return ret;
}
int
KRB5_LIB_FUNCTION int KRB5_LIB_CALL
_krb5_xunlock(krb5_context context, int fd)
{
int ret;
@@ -244,7 +244,7 @@ scrub_file (int fd)
* hardlink)
*/
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_erase_file(krb5_context context, const char *filename)
{
int fd;

View File

@@ -291,7 +291,7 @@ fail:
return ret;
}
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_get_krbtgt(krb5_context context,
krb5_ccache id,
krb5_realm realm,
@@ -1078,7 +1078,7 @@ out:
* codebase.
*/
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_get_cred_kdc_any(krb5_context context,
krb5_kdc_flags flags,
krb5_ccache ccache,

View File

@@ -56,7 +56,7 @@ get_env_user(void)
* avoid recursive calls.
*/
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_get_default_principal_local (krb5_context context,
krb5_principal *princ)
{
@@ -100,7 +100,7 @@ _krb5_get_default_principal_local (krb5_context context,
#define SECURITY_WIN32
#include <security.h>
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_get_default_principal_local(krb5_context context,
krb5_principal *princ)
{

View File

@@ -550,7 +550,7 @@ krb5_kt_compare(krb5_context context,
return TRUE;
}
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_kt_principal_not_found(krb5_context context,
krb5_error_code ret,
krb5_keytab id,

View File

@@ -191,7 +191,7 @@ krbhst_get_default_port(struct krb5_krbhst_data *kd)
*
*/
const char *
KRB5_LIB_FUNCTION const char * KRB5_LIB_CALL
_krb5_krbhst_get_realm(krb5_krbhst_handle handle)
{
return handle->realm;
@@ -262,7 +262,7 @@ parse_hostspec(krb5_context context, struct krb5_krbhst_data *kd,
return hi;
}
void
KRB5_LIB_FUNCTION void KRB5_LIB_CALL
_krb5_free_krbhst_info(krb5_krbhst_info *hi)
{
if (hi->ai != NULL)
@@ -270,7 +270,7 @@ _krb5_free_krbhst_info(krb5_krbhst_info *hi)
free(hi);
}
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_krbhost_info_move(krb5_context context,
krb5_krbhst_info *from,
krb5_krbhst_info **to)
@@ -648,7 +648,7 @@ struct plctx {
unsigned long flags;
};
static krb5_error_code
static KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
plcallback(krb5_context context,
const void *plug, void *plugctx, void *userctx)
{
@@ -1025,7 +1025,7 @@ krb5_krbhst_next_as_string(krb5_context context,
*
*/
krb5_error_code KRB5_LIB_FUNCTION
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
krb5_krbhst_set_hostname(krb5_context context,
krb5_krbhst_handle handle,
const char *hostname)

View File

@@ -498,7 +498,7 @@ _krb5_debug(krb5_context context,
va_end(ap);
}
krb5_boolean KRB5_LIB_FUNCTION
KRB5_LIB_FUNCTION krb5_boolean KRB5_LIB_CALL
_krb5_have_debug(krb5_context context, int level)
{
if (context == NULL || context->debug_dest == NULL)

View File

@@ -76,7 +76,7 @@ _krb5_s4u2self_to_checksumdata(krb5_context context,
return ret;
}
void
KRB5_LIB_FUNCTION void KRB5_LIB_CALL
_krb5_debug_backtrace(krb5_context context)
{
#if defined(HAVE_BACKTRACE) && !defined(HEIMDAL_SMALLER)
@@ -93,7 +93,7 @@ _krb5_debug_backtrace(krb5_context context)
#endif
}
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_einval(krb5_context context, const char *func, unsigned long argn)
{
#ifndef HEIMDAL_SMALLER

View File

@@ -33,7 +33,7 @@
#include "krb5_locl.h"
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_mk_req_internal(krb5_context context,
krb5_auth_context *auth_context,
const krb5_flags ap_req_options,

View File

@@ -955,7 +955,7 @@ pac_checksum(krb5_context context,
return 0;
}
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_pac_sign(krb5_context context,
krb5_pac p,
time_t authtime,

View File

@@ -53,7 +53,7 @@ callback(krb5_context context, const void *plug, void *plugctx, void *userctx)
}
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_load_ccache_plugins(krb5_context context)
{
krb5_error_code userctx = 0;

View File

@@ -2022,7 +2022,7 @@ parse_integer(krb5_context context, char **p, const char *file, int lineno,
return 0;
}
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_parse_moduli_line(krb5_context context,
const char *file,
int lineno,
@@ -2098,7 +2098,7 @@ _krb5_parse_moduli_line(krb5_context context,
return ret;
}
void
KRB5_LIB_FUNCTION void KRB5_LIB_CALL
_krb5_free_moduli(struct krb5_dh_moduli **moduli)
{
int i;
@@ -2166,7 +2166,7 @@ static const char *default_moduli_rfc3526_MODP_group14 =
"EF15E5FB" "4AAC0B8C" "1CCAA4BE" "754AB572" "8AE9130C" "4C7D0288"
"0AB9472D" "45565534" "7FFFFFFF" "FFFFFFFF";
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_parse_moduli(krb5_context context, const char *file,
struct krb5_dh_moduli ***moduli)
{
@@ -2255,7 +2255,7 @@ _krb5_parse_moduli(krb5_context context, const char *file,
return 0;
}
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_dh_group_ok(krb5_context context, unsigned long bits,
heim_integer *p, heim_integer *g, heim_integer *q,
struct krb5_dh_moduli **moduli,

View File

@@ -134,7 +134,7 @@ add_symbol(krb5_context context, struct krb5_plugin **list, void *symbol)
return 0;
}
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_plugin_find(krb5_context context,
enum krb5_plugin_type type,
const char *name,
@@ -181,7 +181,7 @@ _krb5_plugin_find(krb5_context context,
return 0;
}
void
KRB5_LIB_FUNCTION void KRB5_LIB_CALL
_krb5_plugin_free(struct krb5_plugin *list)
{
struct krb5_plugin *next;
@@ -230,7 +230,7 @@ plug_dealloc(void *ptr)
* @name Name of plugin module (typically "krb5")
* @paths Array of directory paths where to look
*/
void
KRB5_LIB_FUNCTION void KRB5_LIB_CALL
_krb5_load_plugins(krb5_context context, const char *name, const char **paths)
{
#ifdef HAVE_DLOPEN
@@ -326,7 +326,7 @@ _krb5_load_plugins(krb5_context context, const char *name, const char **paths)
/**
* Unload plugins (new system)
*/
void
KRB5_LIB_FUNCTION void KRB5_LIB_CALL
_krb5_unload_plugins(krb5_context context, const char *name)
{
HEIMDAL_MUTEX_lock(&plugin_mutex);
@@ -448,7 +448,7 @@ eval_results(heim_object_t value, void *ctx, int *stop)
* Outputs: None, other than the return value and such outputs as are
* gathered by @func.
*/
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_plugin_run_f(krb5_context context,
const char *module,
const char *name,

View File

@@ -255,7 +255,7 @@ krb5_sendto_ctx_free(krb5_context context, krb5_sendto_ctx ctx)
heim_release(ctx);
}
krb5_error_code
KRB5_LIB_FUNCTION krb5_error_code KRB5_LIB_CALL
_krb5_kdc_retry(krb5_context context, krb5_sendto_ctx ctx, void *data,
const krb5_data *reply, int *action)
{

View File

@@ -645,7 +645,7 @@ decrypt_tkt (krb5_context context,
return 0;
}
int
KRB5_LIB_FUNCTION int KRB5_LIB_CALL
_krb5_extract_ticket(krb5_context context,
krb5_kdc_rep *rep,
krb5_creds *creds,