const struct GNUNET_CONFIGURATION_Handle *ccfg,
struct GNUNET_TESTING_Peer *peer)
{
- struct GNUNET_CRYPTO_RsaPublicKeyBinaryEncoded our_pkey;
- struct GNUNET_CRYPTO_RsaPublicKeyBinaryEncoded alice_pkey;
- struct GNUNET_CRYPTO_RsaPublicKeyBinaryEncoded bob_pkey;
- struct GNUNET_CRYPTO_RsaPrivateKey *our_key;
- struct GNUNET_CRYPTO_RsaPrivateKey *alice_key;
- struct GNUNET_CRYPTO_RsaPrivateKey *bob_key;
+ struct GNUNET_CRYPTO_EccPublicKeyBinaryEncoded our_pkey;
+ struct GNUNET_CRYPTO_EccPublicKeyBinaryEncoded alice_pkey;
+ struct GNUNET_CRYPTO_EccPublicKeyBinaryEncoded bob_pkey;
+ struct GNUNET_CRYPTO_EccPrivateKey *our_key;
+ struct GNUNET_CRYPTO_EccPrivateKey *alice_key;
+ struct GNUNET_CRYPTO_EccPrivateKey *bob_key;
struct GNUNET_CRYPTO_ShortHashCode bob_hash;
struct GNUNET_CRYPTO_ShortHashCode alice_hash;
- struct GNUNET_CRYPTO_RsaSignature *sig;
+ struct GNUNET_CRYPTO_EccSignature *sig;
char* our_keyfile;
cfg = ccfg;
return;
}
- our_key = GNUNET_CRYPTO_rsa_key_create_from_file (our_keyfile);
+ our_key = GNUNET_CRYPTO_ecc_key_create_from_file (our_keyfile);
GNUNET_free(our_keyfile);
- bob_key = GNUNET_CRYPTO_rsa_key_create_from_file (KEYFILE_BOB);
- alice_key = GNUNET_CRYPTO_rsa_key_create_from_file (KEYFILE_ALICE);
+ bob_key = GNUNET_CRYPTO_ecc_key_create_from_file (KEYFILE_BOB);
+ alice_key = GNUNET_CRYPTO_ecc_key_create_from_file (KEYFILE_ALICE);
- GNUNET_CRYPTO_rsa_key_get_public (our_key, &our_pkey);
- GNUNET_CRYPTO_rsa_key_get_public (alice_key, &alice_pkey);
- GNUNET_CRYPTO_rsa_key_get_public (bob_key, &bob_pkey);
+ GNUNET_CRYPTO_ecc_key_get_public (our_key, &our_pkey);
+ GNUNET_CRYPTO_ecc_key_get_public (alice_key, &alice_pkey);
+ GNUNET_CRYPTO_ecc_key_get_public (bob_key, &bob_pkey);
struct GNUNET_NAMESTORE_RecordData rd;
char* ip = TEST_IP;
rd.flags = GNUNET_NAMESTORE_RF_AUTHORITY;
/* put bob into our zone */
- GNUNET_NAMESTORE_record_create (namestore_handle,
- our_key,
- TEST_AUTHORITY_BOB,
- &rd,
- NULL,
- NULL);
+ GNUNET_NAMESTORE_record_put_by_authority (namestore_handle,
+ our_key,
+ TEST_AUTHORITY_BOB,
+ 1, &rd,
+ NULL,
+ NULL);
/* put alice into bobs zone */
GNUNET_CRYPTO_short_hash(&alice_pkey, sizeof(alice_pkey), &alice_hash);
&rd, 1);
GNUNET_NAMESTORE_record_put (namestore_handle,
- &bob_pkey,
- TEST_AUTHORITY_ALICE,
- GNUNET_TIME_UNIT_FOREVER_ABS,
- 1,
+ &bob_pkey,
+ TEST_AUTHORITY_ALICE,
+ GNUNET_TIME_UNIT_FOREVER_ABS,
+ 1,
&rd,
sig,
NULL,
GNUNET_free (web);
GNUNET_free (sig);
- GNUNET_CRYPTO_rsa_key_free (alice_key);
- GNUNET_CRYPTO_rsa_key_free (bob_key);
- GNUNET_CRYPTO_rsa_key_free (our_key);
+ GNUNET_CRYPTO_ecc_key_free (alice_key);
+ GNUNET_CRYPTO_ecc_key_free (bob_key);
+ GNUNET_CRYPTO_ecc_key_free (our_key);
}