make old compilers happy

git-svn-id: https://www.opensc-project.org/svnp/opensc/trunk@2487 c6295689-39f2-0310-b995-f0e70906c6a9
This commit is contained in:
nils 2005-08-14 22:33:43 +00:00
parent 5adbeff6e0
commit d6e5facb0d
8 changed files with 136 additions and 81 deletions

View File

@ -856,30 +856,37 @@ cyberflex_encode_public_key(sc_profile_t *profile, sc_card_t *card,
}
static struct sc_pkcs15init_operations sc_pkcs15init_cryptoflex_operations = {
.erase_card = cflex_erase_card,
.init_card = cryptoflex_init_card,
.create_dir = cflex_create_dir,
.create_domain = cflex_create_domain,
.select_pin_reference = cflex_select_pin_reference,
.create_pin = cflex_create_pin,
.create_key = cflex_create_key,
.generate_key = cflex_generate_key,
.store_key = cflex_store_key,
.encode_private_key = cryptoflex_encode_private_key,
.encode_public_key = cryptoflex_encode_public_key
cflex_erase_card,
cryptoflex_init_card,
cflex_create_dir,
cflex_create_domain,
cflex_select_pin_reference,
cflex_create_pin,
NULL, /* select_key_reference */
cflex_create_key,
cflex_store_key,
cflex_generate_key,
cryptoflex_encode_private_key,
cryptoflex_encode_public_key,
NULL, /* finalize_card */
NULL, NULL, NULL, NULL, NULL /* old style api */
};
static struct sc_pkcs15init_operations sc_pkcs15init_cyberflex_operations = {
.erase_card = cflex_erase_card,
.create_dir = cflex_create_dir,
.create_domain = cflex_create_domain,
.select_pin_reference = cflex_select_pin_reference,
.create_pin = cflex_create_pin,
.create_key = cflex_create_key,
.generate_key = cflex_generate_key,
.store_key = cflex_store_key,
.encode_private_key = cyberflex_encode_private_key,
.encode_public_key = cyberflex_encode_public_key
cflex_erase_card,
NULL, /* init_card */
cflex_create_dir,
cflex_create_domain,
cflex_select_pin_reference,
cflex_create_pin,
NULL, /* select_key_reference */
cflex_create_key,
cflex_store_key,
cflex_generate_key,
cyberflex_encode_private_key,
cyberflex_encode_public_key,
NULL, /* finalize_card */
NULL, NULL, NULL, NULL, NULL /* old style api */
};
struct sc_pkcs15init_operations *

View File

@ -612,14 +612,19 @@ etoken_extract_pubkey(sc_card_t *card, int nr, u8 tag,
}
static struct sc_pkcs15init_operations sc_pkcs15init_etoken_operations = {
.erase_card = etoken_erase,
.create_dir = etoken_create_dir,
.select_pin_reference = etoken_select_pin_reference,
.create_pin = etoken_create_pin,
.select_key_reference = etoken_select_key_reference,
.create_key = etoken_create_key,
.store_key = etoken_store_key,
.generate_key = etoken_generate_key
etoken_erase,
NULL, /* init_card */
etoken_create_dir,
NULL, /* create_domain */
etoken_select_pin_reference,
etoken_create_pin,
etoken_select_key_reference,
etoken_create_key,
etoken_store_key,
etoken_generate_key,
NULL, NULL, /* encode private/public key */
NULL, /* finalize_card */
NULL, NULL, NULL, NULL, NULL /* old style api */
};
struct sc_pkcs15init_operations *

View File

@ -1117,13 +1117,19 @@ gpk_read_rsa_key(sc_card_t *card, struct sc_pkcs15_pubkey_rsa *rsa)
}
static struct sc_pkcs15init_operations sc_pkcs15init_gpk_operations = {
.erase_card = gpk_erase_card,
.create_dir = gpk_create_dir,
.select_pin_reference = gpk_select_pin_reference,
.create_pin = gpk_create_pin,
.create_key = gpk_create_key,
.generate_key = gpk_generate_key,
.store_key = gpk_store_key
gpk_erase_card,
NULL, /* init_card */
gpk_create_dir,
NULL, /* create_domain */
gpk_select_pin_reference,
gpk_create_pin,
NULL, /* select_key_reference */
gpk_create_key,
gpk_store_key,
gpk_generate_key,
NULL, NULL, /* encode private/public key */
NULL, /* finalize_card */
NULL, NULL, NULL, NULL, NULL /* old style api */
};
struct sc_pkcs15init_operations *sc_pkcs15init_get_gpk_ops(void)

View File

@ -344,13 +344,20 @@ jcop_generate_key(sc_profile_t *profile, sc_card_t *card,
static struct sc_pkcs15init_operations sc_pkcs15init_jcop_operations = {
.erase_card = jcop_erase_card,
.init_app = jcop_init_app,
.select_pin_reference = jcop_select_pin_reference,
.create_pin = jcop_create_pin,
.create_key = jcop_create_key,
.store_key = jcop_store_key,
.generate_key = jcop_generate_key
jcop_erase_card,
NULL, /* init_card */
NULL, /* create_dir */
NULL, /* create_domain */
jcop_select_pin_reference,
jcop_create_pin,
NULL, /* select_key_reference */
jcop_create_key,
jcop_store_key,
jcop_generate_key,
NULL, NULL, /* encode private/public key */
NULL, /* finalize_card */
jcop_init_app, /* old */
NULL, NULL, NULL, NULL /* rest of old style api */
};
struct sc_pkcs15init_operations *sc_pkcs15init_get_jcop_ops(void)

View File

@ -202,10 +202,23 @@ miocos_new_key(struct sc_profile *profile, sc_card_t *card,
}
static struct sc_pkcs15init_operations sc_pkcs15init_miocos_operations = {
.init_app = miocos_init_app,
.new_pin = miocos_new_pin,
.new_key = miocos_new_key,
.new_file = miocos_new_file
NULL, /* erase_card */
NULL, /* init_card */
NULL, /* create_dir */
NULL, /* create_domain */
NULL, /* select_pin_reference */
NULL, /* create_pin */
NULL, /* select_key_reference */
NULL, /* create_key */
NULL, /* store_key */
NULL, /* generate_key */
NULL, NULL, /* encode private/public key */
NULL, /* finalize_card */
miocos_init_app, /* old */
miocos_new_pin,
miocos_new_key,
miocos_new_file,
NULL /* old_generate_key */
};
struct sc_pkcs15init_operations *sc_pkcs15init_get_miocos_ops(void)

View File

@ -687,15 +687,23 @@ failed:
static struct sc_pkcs15init_operations sc_pkcs15init_oberthur_operations = {
.erase_card = cosm_erase_card,
/* NEW */
.select_pin_reference = cosm_select_pin_reference,
.create_pin = cosm_create_pin,
/* OLD */
.init_app = cosm_init_app,
.new_key = cosm_new_key,
.new_file = cosm_new_file,
.old_generate_key = cosm_old_generate_key
cosm_erase_card,
NULL, /* init_card */
NULL, /* create_dir */
NULL, /* create_domain */
cosm_select_pin_reference,
cosm_create_pin,
NULL, /* select_key_reference */
NULL, /* create_key */
NULL, /* store_key */
NULL, /* generate_key */
NULL, NULL, /* encode private/public key */
NULL, /* finalize_card */
cosm_init_app, /* old */
NULL, /* new_pin */
cosm_new_key,
cosm_new_file,
cosm_old_generate_key
};
struct sc_pkcs15init_operations *

View File

@ -566,23 +566,29 @@ static int setcos_puk_retries(sc_profile_t *profile, int pin_ref)
return pin_info.tries_left;
}
static struct sc_pkcs15init_operations sc_pkcs15init_setcos_operations;
static struct sc_pkcs15init_operations sc_pkcs15init_setcos_operations = {
setcos_erase_card,
NULL, /* init_card */
NULL, /* create_dir */
NULL, /* create_domain */
setcos_select_pin_reference,
setcos_create_pin,
NULL, /* select_key_reference */
NULL, /* create_key */
NULL, /* store_key */
NULL, /* generate_key */
setcos_encode_private_key,
setcos_encode_public_key,
NULL, /* finalize_card */
setcos_init_app, /* old */
NULL, /* old style api */
setcos_new_key,
setcos_new_file,
setcos_old_generate_key
};
struct sc_pkcs15init_operations *
sc_pkcs15init_get_setcos_ops(void)
{
struct sc_pkcs15init_operations *ops;
ops = &sc_pkcs15init_setcos_operations;
ops->erase_card = setcos_erase_card;
ops->init_app = setcos_init_app;
ops->select_pin_reference = setcos_select_pin_reference;
ops->create_pin = setcos_create_pin;
ops->old_generate_key = setcos_old_generate_key;
ops->new_key = setcos_new_key;
ops->new_file = setcos_new_file;
ops->encode_private_key = setcos_encode_private_key;
ops->encode_public_key = setcos_encode_public_key;
return ops;
return &sc_pkcs15init_setcos_operations;
}

View File

@ -914,16 +914,19 @@ static int starcos_finalize_card(sc_card_t *card)
}
static struct sc_pkcs15init_operations sc_pkcs15init_starcos_operations = {
.erase_card = starcos_erase_card,
.init_card = starcos_init_card,
.create_dir = starcos_create_dir,
.select_pin_reference = starcos_pin_reference,
.create_pin = starcos_create_pin,
.select_key_reference = starcos_key_reference,
.create_key = starcos_create_key,
.store_key = starcos_store_key,
.generate_key = starcos_generate_key,
.finalize_card = starcos_finalize_card
starcos_erase_card,
starcos_init_card,
starcos_create_dir,
NULL, /* create_domain */
starcos_pin_reference,
starcos_create_pin,
starcos_key_reference,
starcos_create_key,
starcos_store_key,
starcos_generate_key,
NULL, NULL, /* encode private/public key */
starcos_finalize_card,
NULL, NULL, NULL, NULL, NULL /* old style api */
};
struct sc_pkcs15init_operations *sc_pkcs15init_get_starcos_ops(void)