diff options
-rw-r--r-- | configure.ac | 18 | ||||
-rw-r--r-- | po/POTFILES.in | 192 | ||||
-rw-r--r-- | src/Makefile.am | 8 | ||||
-rw-r--r-- | src/abd/Makefile.am | 10 | ||||
-rw-r--r-- | src/abd/abd.h | 20 | ||||
-rw-r--r-- | src/abd/abd_api.c | 8 | ||||
-rw-r--r-- | src/abd/abd_serialization.c | 8 | ||||
-rw-r--r-- | src/abd/delegate_misc.c | 28 | ||||
-rw-r--r-- | src/abd/gnunet-abd.c | 38 | ||||
-rw-r--r-- | src/abd/gnunet-service-abd.c | 58 | ||||
-rw-r--r-- | src/abd/plugin_gnsrecord_abd.c | 4 | ||||
-rw-r--r-- | src/arm/Makefile.am | 14 | ||||
-rw-r--r-- | src/auction/Makefile.am | 10 | ||||
-rw-r--r-- | src/cadet/Makefile.am | 12 | ||||
-rw-r--r-- | src/cli/Makefile.am | 2 | ||||
-rw-r--r-- | src/cli/util/.gitignore | 10 | ||||
-rw-r--r-- | src/cli/util/Makefile.am | 108 | ||||
-rw-r--r-- | src/cli/util/crypto-test-vectors.json (renamed from src/util/crypto-test-vectors.json) | 0 | ||||
-rw-r--r-- | src/cli/util/gnunet-base32.c (renamed from src/util/gnunet-base32.c) | 0 | ||||
-rw-r--r-- | src/cli/util/gnunet-config-diff.c (renamed from src/util/gnunet-config-diff.c) | 0 | ||||
-rw-r--r-- | src/cli/util/gnunet-config.c (renamed from src/util/gnunet-config.c) | 0 | ||||
-rw-r--r-- | src/cli/util/gnunet-crypto-tvg.c (renamed from src/util/gnunet-crypto-tvg.c) | 0 | ||||
-rw-r--r-- | src/cli/util/gnunet-ecc.c (renamed from src/util/gnunet-ecc.c) | 0 | ||||
-rw-r--r-- | src/cli/util/gnunet-qr.c (renamed from src/util/gnunet-qr.c) | 0 | ||||
-rw-r--r-- | src/cli/util/gnunet-resolver.c (renamed from src/util/gnunet-resolver.c) | 0 | ||||
-rw-r--r-- | src/cli/util/gnunet-scrypt.c (renamed from src/util/gnunet-scrypt.c) | 0 | ||||
-rw-r--r-- | src/cli/util/gnunet-timeout.c (renamed from src/util/gnunet-timeout.c) | 0 | ||||
-rw-r--r-- | src/cli/util/gnunet-uri.c (renamed from src/util/gnunet-uri.c) | 0 | ||||
-rwxr-xr-x | src/cli/util/test_crypto_vectors.sh (renamed from src/util/test_crypto_vectors.sh) | 0 | ||||
-rw-r--r-- | src/consensus/Makefile.am | 14 | ||||
-rw-r--r-- | src/conversation/Makefile.am | 42 | ||||
-rw-r--r-- | src/conversation/conversation_api.c | 8 | ||||
-rw-r--r-- | src/conversation/conversation_api_call.c | 6 | ||||
-rw-r--r-- | src/conversation/gnunet-conversation.c | 6 | ||||
-rw-r--r-- | src/conversation/gnunet-service-conversation.c | 30 | ||||
-rw-r--r-- | src/conversation/test_conversation_api.c | 12 | ||||
-rw-r--r-- | src/conversation/test_conversation_api_reject.c | 12 | ||||
-rw-r--r-- | src/conversation/test_conversation_api_twocalls.c | 12 | ||||
-rw-r--r-- | src/core/Makefile.am | 16 | ||||
-rw-r--r-- | src/curl/Makefile.am | 4 | ||||
-rw-r--r-- | src/datacache/Makefile.am | 22 | ||||
-rw-r--r-- | src/datastore/Makefile.am | 44 | ||||
-rw-r--r-- | src/dht/Makefile.am | 30 | ||||
-rw-r--r-- | src/dhtu/Makefile.am | 10 | ||||
-rw-r--r-- | src/dns/Makefile.am | 16 | ||||
-rw-r--r-- | src/exit/Makefile.am | 2 | ||||
-rw-r--r-- | src/fs/Makefile.am | 92 | ||||
-rw-r--r-- | src/fs/gnunet-publish.c | 8 | ||||
-rw-r--r-- | src/gns/Makefile.am | 48 | ||||
-rw-r--r-- | src/gns/gns_api.c | 8 | ||||
-rw-r--r-- | src/gns/gns_tld_api.c | 14 | ||||
-rw-r--r-- | src/gns/gnunet-bcd.c | 4 | ||||
-rw-r--r-- | src/gns/gnunet-gns-import.c | 2 | ||||
-rw-r--r-- | src/gns/gnunet-service-gns.c | 10 | ||||
-rw-r--r-- | src/gns/gnunet-service-gns.h | 2 | ||||
-rw-r--r-- | src/gns/gnunet-service-gns_interceptor.c | 2 | ||||
-rw-r--r-- | src/gns/gnunet-service-gns_resolver.c | 16 | ||||
-rw-r--r-- | src/gns/gnunet-service-gns_resolver.h | 2 | ||||
-rw-r--r-- | src/gns/plugin_gnsrecord_gns.c | 10 | ||||
-rw-r--r-- | src/hello/gnunet-hello.c | 427 | ||||
-rw-r--r-- | src/hostlist/Makefile.am | 10 | ||||
-rw-r--r-- | src/identity/Makefile.am | 10 | ||||
-rw-r--r-- | src/identity/gnunet-identity.c | 38 | ||||
-rw-r--r-- | src/identity/gnunet-service-identity.c | 16 | ||||
-rw-r--r-- | src/identity/identity.h | 4 | ||||
-rw-r--r-- | src/identity/identity_api.c | 664 | ||||
-rw-r--r-- | src/identity/identity_api_lookup.c | 4 | ||||
-rw-r--r-- | src/identity/identity_api_suffix_lookup.c | 4 | ||||
-rw-r--r-- | src/identity/plugin_rest_identity.c | 22 | ||||
-rw-r--r-- | src/identity/test_identity.c | 18 | ||||
-rw-r--r-- | src/include/gnunet_abd_service.h | 28 | ||||
-rw-r--r-- | src/include/gnunet_conversation_service.h | 2 | ||||
-rw-r--r-- | src/include/gnunet_crypto_lib.h | 566 | ||||
-rw-r--r-- | src/include/gnunet_gns_service.h | 4 | ||||
-rw-r--r-- | src/include/gnunet_gnsrecord_lib.h | 28 | ||||
-rw-r--r-- | src/include/gnunet_identity_service.h | 575 | ||||
-rw-r--r-- | src/include/gnunet_messenger_service.h | 12 | ||||
-rw-r--r-- | src/include/gnunet_namestore_plugin.h | 14 | ||||
-rw-r--r-- | src/include/gnunet_namestore_service.h | 28 | ||||
-rw-r--r-- | src/include/gnunet_reclaim_service.h | 32 | ||||
-rw-r--r-- | src/include/gnunet_revocation_service.h | 6 | ||||
-rw-r--r-- | src/json/Makefile.am | 6 | ||||
-rw-r--r-- | src/lib/Makefile.am | 5 | ||||
-rw-r--r-- | src/lib/block/Makefile.am | 31 | ||||
-rw-r--r-- | src/lib/block/bg_bf.c (renamed from src/block/bg_bf.c) | 0 | ||||
-rw-r--r-- | src/lib/block/block.c (renamed from src/block/block.c) | 0 | ||||
-rw-r--r-- | src/lib/block/meson.build (renamed from src/block/meson.build) | 0 | ||||
-rw-r--r-- | src/lib/gnsrecord/.gitignore (renamed from src/gnsrecord/.gitignore) | 0 | ||||
-rw-r--r-- | src/lib/gnsrecord/Makefile.am (renamed from src/gnsrecord/Makefile.am) | 35 | ||||
-rw-r--r-- | src/lib/gnsrecord/gnsrecord.c (renamed from src/gnsrecord/gnsrecord.c) | 0 | ||||
-rw-r--r-- | src/lib/gnsrecord/gnsrecord_crypto.c (renamed from src/gnsrecord/gnsrecord_crypto.c) | 44 | ||||
-rw-r--r-- | src/lib/gnsrecord/gnsrecord_crypto.h (renamed from src/gnsrecord/gnsrecord_crypto.h) | 0 | ||||
-rw-r--r-- | src/lib/gnsrecord/gnsrecord_misc.c (renamed from src/gnsrecord/gnsrecord_misc.c) | 22 | ||||
-rw-r--r-- | src/lib/gnsrecord/gnsrecord_serialization.c (renamed from src/gnsrecord/gnsrecord_serialization.c) | 0 | ||||
-rw-r--r-- | src/lib/gnsrecord/gnunet-gnsrecord-tvg.c (renamed from src/gnsrecord/gnunet-gnsrecord-tvg.c) | 40 | ||||
-rw-r--r-- | src/lib/gnsrecord/json_gnsrecord.c (renamed from src/gnsrecord/json_gnsrecord.c) | 0 | ||||
-rw-r--r-- | src/lib/gnsrecord/meson.build (renamed from src/gnsrecord/meson.build) | 0 | ||||
-rw-r--r-- | src/lib/gnsrecord/perf_gnsrecord_crypto.c (renamed from src/gnsrecord/perf_gnsrecord_crypto.c) | 2 | ||||
-rw-r--r-- | src/lib/gnsrecord/test_gnsrecord_block_expiration.c (renamed from src/gnsrecord/test_gnsrecord_block_expiration.c) | 0 | ||||
-rw-r--r-- | src/lib/gnsrecord/test_gnsrecord_crypto.c (renamed from src/gnsrecord/test_gnsrecord_crypto.c) | 10 | ||||
-rw-r--r-- | src/lib/gnsrecord/test_gnsrecord_serialization.c (renamed from src/gnsrecord/test_gnsrecord_serialization.c) | 0 | ||||
-rw-r--r-- | src/lib/gnsrecord/test_gnsrecord_testvectors.c (renamed from src/gnsrecord/test_gnsrecord_testvectors.c) | 16 | ||||
-rw-r--r-- | src/lib/hello/.gitignore (renamed from src/hello/.gitignore) | 0 | ||||
-rw-r--r-- | src/lib/hello/Makefile.am (renamed from src/hello/Makefile.am) | 22 | ||||
-rw-r--r-- | src/lib/hello/address.c (renamed from src/hello/address.c) | 0 | ||||
-rw-r--r-- | src/lib/hello/hello-ng.c (renamed from src/hello/hello-ng.c) | 0 | ||||
-rw-r--r-- | src/lib/hello/hello-uri.c (renamed from src/hello/hello-uri.c) | 0 | ||||
-rw-r--r-- | src/lib/hello/hello.c (renamed from src/hello/hello.c) | 0 | ||||
-rw-r--r-- | src/lib/hello/meson.build (renamed from src/hello/meson.build) | 0 | ||||
-rw-r--r-- | src/lib/hello/test_friend_hello.c (renamed from src/hello/test_friend_hello.c) | 0 | ||||
-rw-r--r-- | src/lib/hello/test_hello-ng.c (renamed from src/hello/test_hello-ng.c) | 0 | ||||
-rw-r--r-- | src/lib/hello/test_hello-uri.c (renamed from src/hello/test_hello-uri.c) | 0 | ||||
-rw-r--r-- | src/lib/hello/test_hello.c (renamed from src/hello/test_hello.c) | 0 | ||||
-rw-r--r-- | src/lib/util/.gitignore (renamed from src/util/.gitignore) | 12 | ||||
-rw-r--r-- | src/lib/util/Makefile.am (renamed from src/util/Makefile.am) | 109 | ||||
-rw-r--r-- | src/lib/util/bandwidth.c (renamed from src/util/bandwidth.c) | 0 | ||||
-rw-r--r-- | src/lib/util/benchmark.c (renamed from src/util/benchmark.c) | 0 | ||||
-rw-r--r-- | src/lib/util/benchmark.h (renamed from src/util/benchmark.h) | 0 | ||||
-rw-r--r-- | src/lib/util/bio.c (renamed from src/util/bio.c) | 0 | ||||
-rw-r--r-- | src/lib/util/buffer.c (renamed from src/util/buffer.c) | 0 | ||||
-rw-r--r-- | src/lib/util/child_management.c (renamed from src/util/child_management.c) | 0 | ||||
-rwxr-xr-x | src/lib/util/child_management_test.sh (renamed from src/util/child_management_test.sh) | 0 | ||||
-rw-r--r-- | src/lib/util/client.c (renamed from src/util/client.c) | 0 | ||||
-rw-r--r-- | src/lib/util/common_allocation.c (renamed from src/util/common_allocation.c) | 0 | ||||
-rw-r--r-- | src/lib/util/common_endian.c (renamed from src/util/common_endian.c) | 0 | ||||
-rw-r--r-- | src/lib/util/common_logging.c (renamed from src/util/common_logging.c) | 0 | ||||
-rw-r--r-- | src/lib/util/compress.c (renamed from src/util/compress.c) | 0 | ||||
-rw-r--r-- | src/lib/util/configuration.c (renamed from src/util/configuration.c) | 0 | ||||
-rw-r--r-- | src/lib/util/configuration_helper.c (renamed from src/util/configuration_helper.c) | 0 | ||||
-rw-r--r-- | src/lib/util/consttime_memcmp.c (renamed from src/util/consttime_memcmp.c) | 0 | ||||
-rw-r--r-- | src/lib/util/container_bloomfilter.c (renamed from src/util/container_bloomfilter.c) | 0 | ||||
-rw-r--r-- | src/lib/util/container_heap.c (renamed from src/util/container_heap.c) | 0 | ||||
-rw-r--r-- | src/lib/util/container_multihashmap.c (renamed from src/util/container_multihashmap.c) | 0 | ||||
-rw-r--r-- | src/lib/util/container_multihashmap32.c (renamed from src/util/container_multihashmap32.c) | 0 | ||||
-rw-r--r-- | src/lib/util/container_multipeermap.c (renamed from src/util/container_multipeermap.c) | 0 | ||||
-rw-r--r-- | src/lib/util/container_multishortmap.c (renamed from src/util/container_multishortmap.c) | 0 | ||||
-rw-r--r-- | src/lib/util/container_multiuuidmap.c (renamed from src/util/container_multiuuidmap.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_crc.c (renamed from src/util/crypto_crc.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_cs.c (renamed from src/util/crypto_cs.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_ecc.c (renamed from src/util/crypto_ecc.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_ecc_dlog.c (renamed from src/util/crypto_ecc_dlog.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_ecc_gnsrecord.c (renamed from src/util/crypto_ecc_gnsrecord.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_ecc_setup.c (renamed from src/util/crypto_ecc_setup.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_edx25519.c (renamed from src/util/crypto_edx25519.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_hash.c (renamed from src/util/crypto_hash.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_hash_file.c (renamed from src/util/crypto_hash_file.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_hkdf.c (renamed from src/util/crypto_hkdf.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_kdf.c (renamed from src/util/crypto_kdf.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_mpi.c (renamed from src/util/crypto_mpi.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_paillier.c (renamed from src/util/crypto_paillier.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_pkey.c | 618 | ||||
-rw-r--r-- | src/lib/util/crypto_pow.c (renamed from src/util/crypto_pow.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_random.c (renamed from src/util/crypto_random.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_rsa.c (renamed from src/util/crypto_rsa.c) | 0 | ||||
-rw-r--r-- | src/lib/util/crypto_symmetric.c (renamed from src/util/crypto_symmetric.c) | 0 | ||||
-rw-r--r-- | src/lib/util/disk.c (renamed from src/util/disk.c) | 0 | ||||
-rw-r--r-- | src/lib/util/disk.h (renamed from src/util/disk.h) | 0 | ||||
-rw-r--r-- | src/lib/util/dnsparser.c (renamed from src/util/dnsparser.c) | 0 | ||||
-rw-r--r-- | src/lib/util/dnsstub.c (renamed from src/util/dnsstub.c) | 0 | ||||
-rw-r--r-- | src/lib/util/getopt.c (renamed from src/util/getopt.c) | 0 | ||||
-rw-r--r-- | src/lib/util/getopt_helpers.c (renamed from src/util/getopt_helpers.c) | 0 | ||||
-rw-r--r-- | src/lib/util/gnunet_error_codes.c (renamed from src/util/gnunet_error_codes.c) | 0 | ||||
-rw-r--r-- | src/lib/util/helper.c (renamed from src/util/helper.c) | 0 | ||||
-rw-r--r-- | src/lib/util/load.c (renamed from src/util/load.c) | 0 | ||||
-rw-r--r-- | src/lib/util/meson.build (renamed from src/util/meson.build) | 0 | ||||
-rw-r--r-- | src/lib/util/mq.c (renamed from src/util/mq.c) | 0 | ||||
-rw-r--r-- | src/lib/util/mst.c (renamed from src/util/mst.c) | 0 | ||||
-rw-r--r-- | src/lib/util/nc.c (renamed from src/util/nc.c) | 0 | ||||
-rw-r--r-- | src/lib/util/network.c (renamed from src/util/network.c) | 0 | ||||
-rw-r--r-- | src/lib/util/nt.c (renamed from src/util/nt.c) | 0 | ||||
-rw-r--r-- | src/lib/util/op.c (renamed from src/util/op.c) | 0 | ||||
-rw-r--r-- | src/lib/util/os_installation.c (renamed from src/util/os_installation.c) | 0 | ||||
-rw-r--r-- | src/lib/util/os_network.c (renamed from src/util/os_network.c) | 0 | ||||
-rw-r--r-- | src/lib/util/os_priority.c (renamed from src/util/os_priority.c) | 0 | ||||
-rw-r--r-- | src/lib/util/peer.c (renamed from src/util/peer.c) | 0 | ||||
-rw-r--r-- | src/lib/util/perf_crypto_asymmetric.c (renamed from src/util/perf_crypto_asymmetric.c) | 0 | ||||
-rw-r--r-- | src/lib/util/perf_crypto_cs.c (renamed from src/util/perf_crypto_cs.c) | 0 | ||||
-rw-r--r-- | src/lib/util/perf_crypto_ecc_dlog.c (renamed from src/util/perf_crypto_ecc_dlog.c) | 0 | ||||
-rw-r--r-- | src/lib/util/perf_crypto_hash.c (renamed from src/util/perf_crypto_hash.c) | 0 | ||||
-rw-r--r-- | src/lib/util/perf_crypto_paillier.c (renamed from src/util/perf_crypto_paillier.c) | 0 | ||||
-rw-r--r-- | src/lib/util/perf_crypto_rsa.c (renamed from src/util/perf_crypto_rsa.c) | 0 | ||||
-rw-r--r-- | src/lib/util/perf_crypto_symmetric.c (renamed from src/util/perf_crypto_symmetric.c) | 0 | ||||
-rw-r--r-- | src/lib/util/perf_malloc.c (renamed from src/util/perf_malloc.c) | 0 | ||||
-rw-r--r-- | src/lib/util/perf_mq.c (renamed from src/util/perf_mq.c) | 0 | ||||
-rw-r--r-- | src/lib/util/perf_scheduler.c (renamed from src/util/perf_scheduler.c) | 0 | ||||
-rw-r--r-- | src/lib/util/plugin.c (renamed from src/util/plugin.c) | 0 | ||||
-rw-r--r-- | src/lib/util/proc_compat.c (renamed from src/util/proc_compat.c) | 0 | ||||
-rw-r--r-- | src/lib/util/program.c (renamed from src/util/program.c) | 0 | ||||
-rw-r--r-- | src/lib/util/regex.c (renamed from src/util/regex.c) | 0 | ||||
-rw-r--r-- | src/lib/util/resolver.conf | 20 | ||||
-rw-r--r-- | src/lib/util/resolver.conf.in (renamed from src/util/resolver.conf.in) | 0 | ||||
-rw-r--r-- | src/lib/util/resolver.h (renamed from src/util/resolver.h) | 0 | ||||
-rw-r--r-- | src/lib/util/resolver_api.c (renamed from src/util/resolver_api.c) | 0 | ||||
-rw-r--r-- | src/lib/util/scheduler.c (renamed from src/util/scheduler.c) | 0 | ||||
-rw-r--r-- | src/lib/util/service.c (renamed from src/util/service.c) | 0 | ||||
-rw-r--r-- | src/lib/util/signal.c (renamed from src/util/signal.c) | 0 | ||||
-rw-r--r-- | src/lib/util/socks.c (renamed from src/util/socks.c) | 0 | ||||
-rw-r--r-- | src/lib/util/speedup.c (renamed from src/util/speedup.c) | 0 | ||||
-rw-r--r-- | src/lib/util/speedup.h (renamed from src/util/speedup.h) | 0 | ||||
-rw-r--r-- | src/lib/util/strings.c (renamed from src/util/strings.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_bio.c (renamed from src/util/test_bio.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_child_management.c (renamed from src/util/test_child_management.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_client.c (renamed from src/util/test_client.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_client_data.conf (renamed from src/util/test_client_data.conf) | 0 | ||||
-rw-r--r-- | src/lib/util/test_client_unix.conf (renamed from src/util/test_client_unix.conf) | 0 | ||||
-rw-r--r-- | src/lib/util/test_common_allocation.c (renamed from src/util/test_common_allocation.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_common_endian.c (renamed from src/util/test_common_endian.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_common_logging.c (renamed from src/util/test_common_logging.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_common_logging_dummy.c (renamed from src/util/test_common_logging_dummy.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_common_logging_runtime_loglevels.c (renamed from src/util/test_common_logging_runtime_loglevels.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_configuration.c (renamed from src/util/test_configuration.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_configuration_data.conf (renamed from src/util/test_configuration_data.conf) | 0 | ||||
-rw-r--r-- | src/lib/util/test_container_bloomfilter.c (renamed from src/util/test_container_bloomfilter.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_container_dll.c (renamed from src/util/test_container_dll.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_container_heap.c (renamed from src/util/test_container_heap.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_container_multihashmap.c (renamed from src/util/test_container_multihashmap.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_container_multihashmap32.c (renamed from src/util/test_container_multihashmap32.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_container_multipeermap.c (renamed from src/util/test_container_multipeermap.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_crc.c (renamed from src/util/test_crypto_crc.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_cs.c (renamed from src/util/test_crypto_cs.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_ecc_dlog.c (renamed from src/util/test_crypto_ecc_dlog.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_ecdh_ecdsa.c (renamed from src/util/test_crypto_ecdh_ecdsa.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_ecdh_eddsa.c (renamed from src/util/test_crypto_ecdh_eddsa.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_ecdhe.c (renamed from src/util/test_crypto_ecdhe.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_ecdsa.c (renamed from src/util/test_crypto_ecdsa.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_eddsa.c (renamed from src/util/test_crypto_eddsa.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_edx25519.c (renamed from src/util/test_crypto_edx25519.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_hash.c (renamed from src/util/test_crypto_hash.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_hash_context.c (renamed from src/util/test_crypto_hash_context.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_hkdf.c (renamed from src/util/test_crypto_hkdf.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_kdf.c (renamed from src/util/test_crypto_kdf.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_paillier.c (renamed from src/util/test_crypto_paillier.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_random.c (renamed from src/util/test_crypto_random.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_rsa.c (renamed from src/util/test_crypto_rsa.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_crypto_symmetric.c (renamed from src/util/test_crypto_symmetric.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_disk.c (renamed from src/util/test_disk.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_getopt.c (renamed from src/util/test_getopt.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_hexcoder.c (renamed from src/util/test_hexcoder.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_mq.c (renamed from src/util/test_mq.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_os_network.c (renamed from src/util/test_os_network.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_os_start_process.c (renamed from src/util/test_os_start_process.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_peer.c (renamed from src/util/test_peer.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_plugin.c (renamed from src/util/test_plugin.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_plugin_plug.c (renamed from src/util/test_plugin_plug.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_program.c (renamed from src/util/test_program.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_program_data.conf (renamed from src/util/test_program_data.conf) | 0 | ||||
-rw-r--r-- | src/lib/util/test_regex.c (renamed from src/util/test_regex.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_scheduler.c (renamed from src/util/test_scheduler.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_scheduler_delay.c (renamed from src/util/test_scheduler_delay.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_scheduler_hogging_cancel.c (renamed from src/util/test_scheduler_hogging_cancel.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_scheduler_hogging_priority.c (renamed from src/util/test_scheduler_hogging_priority.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_service.c (renamed from src/util/test_service.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_service_data.conf (renamed from src/util/test_service_data.conf) | 0 | ||||
-rw-r--r-- | src/lib/util/test_socks.c (renamed from src/util/test_socks.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_speedup.c (renamed from src/util/test_speedup.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_speedup_data.conf (renamed from src/util/test_speedup_data.conf) | 0 | ||||
-rw-r--r-- | src/lib/util/test_strings.c (renamed from src/util/test_strings.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_strings_to_data.c (renamed from src/util/test_strings_to_data.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_time.c (renamed from src/util/test_time.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_tun.c (renamed from src/util/test_tun.c) | 0 | ||||
-rw-r--r-- | src/lib/util/test_uri.c (renamed from src/util/test_uri.c) | 0 | ||||
-rw-r--r-- | src/lib/util/time.c (renamed from src/util/time.c) | 0 | ||||
-rw-r--r-- | src/lib/util/tun.c (renamed from src/util/tun.c) | 0 | ||||
-rw-r--r-- | src/lib/util/uri.c (renamed from src/util/uri.c) | 0 | ||||
-rw-r--r-- | src/lib/util/util.conf (renamed from src/util/util.conf) | 0 | ||||
-rw-r--r-- | src/lib/util/util.supp (renamed from src/util/util.supp) | 0 | ||||
-rw-r--r-- | src/messenger/Makefile.am | 12 | ||||
-rw-r--r-- | src/messenger/gnunet-service-messenger.c | 8 | ||||
-rw-r--r-- | src/messenger/gnunet-service-messenger_ego_store.c | 8 | ||||
-rw-r--r-- | src/messenger/gnunet-service-messenger_ego_store.h | 2 | ||||
-rw-r--r-- | src/messenger/gnunet-service-messenger_handle.c | 6 | ||||
-rw-r--r-- | src/messenger/gnunet-service-messenger_member.c | 8 | ||||
-rw-r--r-- | src/messenger/gnunet-service-messenger_member.h | 2 | ||||
-rw-r--r-- | src/messenger/gnunet-service-messenger_member_session.c | 16 | ||||
-rw-r--r-- | src/messenger/gnunet-service-messenger_member_session.h | 6 | ||||
-rw-r--r-- | src/messenger/gnunet-service-messenger_member_store.h | 2 | ||||
-rw-r--r-- | src/messenger/gnunet-service-messenger_message_kind.c | 4 | ||||
-rw-r--r-- | src/messenger/gnunet-service-messenger_message_kind.h | 2 | ||||
-rw-r--r-- | src/messenger/gnunet-service-messenger_message_recv.c | 2 | ||||
-rw-r--r-- | src/messenger/gnunet-service-messenger_room.c | 8 | ||||
-rw-r--r-- | src/messenger/gnunet-service-messenger_room.h | 2 | ||||
-rw-r--r-- | src/messenger/messenger_api.c | 24 | ||||
-rw-r--r-- | src/messenger/messenger_api_contact.c | 4 | ||||
-rw-r--r-- | src/messenger/messenger_api_contact.h | 6 | ||||
-rw-r--r-- | src/messenger/messenger_api_contact_store.c | 12 | ||||
-rw-r--r-- | src/messenger/messenger_api_contact_store.h | 4 | ||||
-rw-r--r-- | src/messenger/messenger_api_ego.h | 4 | ||||
-rw-r--r-- | src/messenger/messenger_api_handle.c | 6 | ||||
-rw-r--r-- | src/messenger/messenger_api_handle.h | 6 | ||||
-rw-r--r-- | src/messenger/messenger_api_message.c | 40 | ||||
-rw-r--r-- | src/messenger/messenger_api_message.h | 6 | ||||
-rw-r--r-- | src/messenger/messenger_api_util.c | 4 | ||||
-rw-r--r-- | src/messenger/messenger_api_util.h | 2 | ||||
-rw-r--r-- | src/messenger/test_messenger.c | 2 | ||||
-rw-r--r-- | src/messenger/test_messenger_anonymous.c | 2 | ||||
-rw-r--r-- | src/namecache/Makefile.am | 34 | ||||
-rw-r--r-- | src/namecache/gnunet-namecache.c | 4 | ||||
-rw-r--r-- | src/namecache/test_namecache_api_cache_block.c | 6 | ||||
-rw-r--r-- | src/namestore/Makefile.am | 164 | ||||
-rw-r--r-- | src/namestore/gnunet-namestore-fcfsd.c | 12 | ||||
-rw-r--r-- | src/namestore/gnunet-namestore-zonefile.c | 6 | ||||
-rw-r--r-- | src/namestore/gnunet-namestore.c | 52 | ||||
-rw-r--r-- | src/namestore/gnunet-service-namestore.c | 66 | ||||
-rw-r--r-- | src/namestore/gnunet-zoneimport.c | 4 | ||||
-rw-r--r-- | src/namestore/namestore_api.c | 58 | ||||
-rw-r--r-- | src/namestore/namestore_api_monitor.c | 16 | ||||
-rw-r--r-- | src/namestore/perf_namestore_api_import.c | 2 | ||||
-rw-r--r-- | src/namestore/perf_namestore_api_zone_iteration.c | 4 | ||||
-rw-r--r-- | src/namestore/plugin_namestore_flat.c | 30 | ||||
-rw-r--r-- | src/namestore/plugin_namestore_postgres.c | 20 | ||||
-rw-r--r-- | src/namestore/plugin_namestore_sqlite.c | 16 | ||||
-rw-r--r-- | src/namestore/plugin_rest_namestore.c | 14 | ||||
-rw-r--r-- | src/namestore/test_namestore_api_edit_records.c | 12 | ||||
-rw-r--r-- | src/namestore/test_namestore_api_lookup_nick.c | 8 | ||||
-rw-r--r-- | src/namestore/test_namestore_api_monitoring.c | 6 | ||||
-rw-r--r-- | src/namestore/test_namestore_api_monitoring_existing.c | 6 | ||||
-rw-r--r-- | src/namestore/test_namestore_api_remove.c | 6 | ||||
-rw-r--r-- | src/namestore/test_namestore_api_remove_not_existing_record.c | 6 | ||||
-rw-r--r-- | src/namestore/test_namestore_api_store.c | 6 | ||||
-rw-r--r-- | src/namestore/test_namestore_api_store_update.c | 8 | ||||
-rw-r--r-- | src/namestore/test_namestore_api_tx_rollback.c | 8 | ||||
-rw-r--r-- | src/namestore/test_namestore_api_zone_iteration.c | 8 | ||||
-rw-r--r-- | src/namestore/test_namestore_api_zone_iteration_nick.c | 8 | ||||
-rw-r--r-- | src/namestore/test_namestore_api_zone_iteration_specific_zone.c | 8 | ||||
-rw-r--r-- | src/namestore/test_namestore_api_zone_iteration_stop.c | 8 | ||||
-rw-r--r-- | src/namestore/test_namestore_api_zone_to_name.c | 10 | ||||
-rw-r--r-- | src/namestore/test_plugin_namestore.c | 6 | ||||
-rw-r--r-- | src/nat-auto/Makefile.am | 8 | ||||
-rw-r--r-- | src/nat/Makefile.am | 14 | ||||
-rw-r--r-- | src/nse/Makefile.am | 14 | ||||
-rw-r--r-- | src/peerstore/Makefile.am | 28 | ||||
-rw-r--r-- | src/plugin/Makefile.am | 3 | ||||
-rw-r--r-- | src/plugin/block/Makefile.am (renamed from src/block/Makefile.am) | 34 | ||||
-rw-r--r-- | src/plugin/block/plugin_block_template.c (renamed from src/block/plugin_block_template.c) | 0 | ||||
-rw-r--r-- | src/plugin/block/plugin_block_test.c (renamed from src/block/plugin_block_test.c) | 0 | ||||
-rw-r--r-- | src/plugin/gnsrecord/Makefile.am | 25 | ||||
-rw-r--r-- | src/plugin/gnsrecord/plugin_gnsrecord_dns.c (renamed from src/gnsrecord/plugin_gnsrecord_dns.c) | 0 | ||||
-rw-r--r-- | src/pq/Makefile.am | 4 | ||||
-rw-r--r-- | src/pt/Makefile.am | 14 | ||||
-rw-r--r-- | src/pt/test_gns_vpn.c | 2 | ||||
-rw-r--r-- | src/reclaim/Makefile.am | 40 | ||||
-rw-r--r-- | src/reclaim/did.h | 2 | ||||
-rw-r--r-- | src/reclaim/did_core.c | 10 | ||||
-rw-r--r-- | src/reclaim/did_helper.c | 18 | ||||
-rw-r--r-- | src/reclaim/did_helper.h | 10 | ||||
-rw-r--r-- | src/reclaim/did_misc.c | 8 | ||||
-rw-r--r-- | src/reclaim/gnunet-did.c | 6 | ||||
-rw-r--r-- | src/reclaim/gnunet-reclaim.c | 14 | ||||
-rw-r--r-- | src/reclaim/gnunet-service-reclaim.c | 86 | ||||
-rw-r--r-- | src/reclaim/gnunet-service-reclaim_tickets.c | 46 | ||||
-rw-r--r-- | src/reclaim/gnunet-service-reclaim_tickets.h | 12 | ||||
-rw-r--r-- | src/reclaim/oidc_helper.c | 42 | ||||
-rw-r--r-- | src/reclaim/oidc_helper.h | 14 | ||||
-rw-r--r-- | src/reclaim/plugin_rest_openid_connect.c | 50 | ||||
-rw-r--r-- | src/reclaim/plugin_rest_reclaim.c | 44 | ||||
-rw-r--r-- | src/reclaim/reclaim_api.c | 94 | ||||
-rw-r--r-- | src/reclaim/test_did_helper.c | 10 | ||||
-rw-r--r-- | src/regex/Makefile.am | 32 | ||||
-rw-r--r-- | src/rest/Makefile.am | 8 | ||||
-rw-r--r-- | src/revocation/Makefile.am | 18 | ||||
-rw-r--r-- | src/revocation/gnunet-revocation-tvg.c | 16 | ||||
-rw-r--r-- | src/revocation/gnunet-revocation.c | 10 | ||||
-rw-r--r-- | src/revocation/gnunet-service-revocation.c | 16 | ||||
-rw-r--r-- | src/revocation/plugin_block_revocation.c | 8 | ||||
-rw-r--r-- | src/revocation/revocation_api.c | 68 | ||||
-rw-r--r-- | src/revocation/test_revocation.c | 12 | ||||
-rw-r--r-- | src/revocation/test_revocation_testvectors.c | 12 | ||||
-rw-r--r-- | src/rps/Makefile.am | 16 | ||||
-rw-r--r-- | src/scalarproduct/Makefile.am | 14 | ||||
-rw-r--r-- | src/secretsharing/Makefile.am | 8 | ||||
-rw-r--r-- | src/service/Makefile.am | 2 | ||||
-rw-r--r-- | src/service/util/.gitignore | 2 | ||||
-rw-r--r-- | src/service/util/Makefile.am | 47 | ||||
-rw-r--r-- | src/service/util/gnunet-service-resolver.c (renamed from src/util/gnunet-service-resolver.c) | 2 | ||||
-rw-r--r-- | src/service/util/test_resolver_api.c (renamed from src/util/test_resolver_api.c) | 0 | ||||
-rw-r--r-- | src/service/util/test_resolver_api_data.conf (renamed from src/util/test_resolver_api_data.conf) | 0 | ||||
-rw-r--r-- | src/set/Makefile.am | 24 | ||||
-rw-r--r-- | src/seti/Makefile.am | 16 | ||||
-rw-r--r-- | src/setu/Makefile.am | 20 | ||||
-rw-r--r-- | src/sq/Makefile.am | 4 | ||||
-rw-r--r-- | src/statistics/Makefile.am | 14 | ||||
-rw-r--r-- | src/template/Makefile.am | 6 | ||||
-rw-r--r-- | src/testing/Makefile.am | 22 | ||||
-rw-r--r-- | src/topology/Makefile.am | 6 | ||||
-rw-r--r-- | src/transport/Makefile.am | 76 | ||||
-rw-r--r-- | src/vpn/Makefile.am | 8 | ||||
-rw-r--r-- | src/zonemaster/Makefile.am | 4 | ||||
-rw-r--r-- | src/zonemaster/gnunet-service-zonemaster.c | 10 |
388 files changed, 3119 insertions, 3422 deletions
diff --git a/configure.ac b/configure.ac index 69b2e4694..da5b39712 100644 --- a/configure.ac +++ b/configure.ac | |||
@@ -1231,7 +1231,11 @@ src/Makefile | |||
1231 | src/arm/Makefile | 1231 | src/arm/Makefile |
1232 | src/arm/arm.conf | 1232 | src/arm/arm.conf |
1233 | src/auction/Makefile | 1233 | src/auction/Makefile |
1234 | src/block/Makefile | 1234 | src/lib/block/Makefile |
1235 | src/lib/gnsrecord/Makefile | ||
1236 | src/plugin/Makefile | ||
1237 | src/plugin/block/Makefile | ||
1238 | src/plugin/gnsrecord/Makefile | ||
1235 | src/cadet/Makefile | 1239 | src/cadet/Makefile |
1236 | src/cadet/cadet.conf | 1240 | src/cadet/cadet.conf |
1237 | src/core/Makefile | 1241 | src/core/Makefile |
@@ -1255,8 +1259,7 @@ src/fs/fs.conf | |||
1255 | src/gns/Makefile | 1259 | src/gns/Makefile |
1256 | src/gns/gns.conf | 1260 | src/gns/gns.conf |
1257 | src/gns/nss/Makefile | 1261 | src/gns/nss/Makefile |
1258 | src/gnsrecord/Makefile | 1262 | src/lib/hello/Makefile |
1259 | src/hello/Makefile | ||
1260 | src/identity/Makefile | 1263 | src/identity/Makefile |
1261 | src/identity/identity.conf | 1264 | src/identity/identity.conf |
1262 | src/include/Makefile | 1265 | src/include/Makefile |
@@ -1301,8 +1304,13 @@ src/testing/Makefile | |||
1301 | src/topology/Makefile | 1304 | src/topology/Makefile |
1302 | src/transport/Makefile | 1305 | src/transport/Makefile |
1303 | src/transport/transport.conf | 1306 | src/transport/transport.conf |
1304 | src/util/Makefile | 1307 | src/lib/Makefile |
1305 | src/util/resolver.conf | 1308 | src/lib/util/Makefile |
1309 | src/lib/util/resolver.conf | ||
1310 | src/service/Makefile | ||
1311 | src/service/util/Makefile | ||
1312 | src/cli/Makefile | ||
1313 | src/cli/util/Makefile | ||
1306 | src/vpn/Makefile | 1314 | src/vpn/Makefile |
1307 | src/vpn/vpn.conf | 1315 | src/vpn/vpn.conf |
1308 | src/zonemaster/Makefile | 1316 | src/zonemaster/Makefile |
diff --git a/po/POTFILES.in b/po/POTFILES.in index 6edabad11..7ae248c18 100644 --- a/po/POTFILES.in +++ b/po/POTFILES.in | |||
@@ -13,10 +13,6 @@ src/auction/gnunet-auction-create.c | |||
13 | src/auction/gnunet-auction-info.c | 13 | src/auction/gnunet-auction-info.c |
14 | src/auction/gnunet-auction-join.c | 14 | src/auction/gnunet-auction-join.c |
15 | src/auction/gnunet-service-auction.c | 15 | src/auction/gnunet-service-auction.c |
16 | src/block/bg_bf.c | ||
17 | src/block/block.c | ||
18 | src/block/plugin_block_template.c | ||
19 | src/block/plugin_block_test.c | ||
20 | src/cadet/cadet_api.c | 16 | src/cadet/cadet_api.c |
21 | src/cadet/cadet_api_drop_message.c | 17 | src/cadet/cadet_api_drop_message.c |
22 | src/cadet/cadet_api_get_channel.c | 18 | src/cadet/cadet_api_get_channel.c |
@@ -36,6 +32,16 @@ src/cadet/gnunet-service-cadet_hello.c | |||
36 | src/cadet/gnunet-service-cadet_paths.c | 32 | src/cadet/gnunet-service-cadet_paths.c |
37 | src/cadet/gnunet-service-cadet_peer.c | 33 | src/cadet/gnunet-service-cadet_peer.c |
38 | src/cadet/gnunet-service-cadet_tunnels.c | 34 | src/cadet/gnunet-service-cadet_tunnels.c |
35 | src/cli/util/gnunet-base32.c | ||
36 | src/cli/util/gnunet-config-diff.c | ||
37 | src/cli/util/gnunet-config.c | ||
38 | src/cli/util/gnunet-crypto-tvg.c | ||
39 | src/cli/util/gnunet-ecc.c | ||
40 | src/cli/util/gnunet-qr.c | ||
41 | src/cli/util/gnunet-resolver.c | ||
42 | src/cli/util/gnunet-scrypt.c | ||
43 | src/cli/util/gnunet-timeout.c | ||
44 | src/cli/util/gnunet-uri.c | ||
39 | src/consensus/consensus_api.c | 45 | src/consensus/consensus_api.c |
40 | src/consensus/gnunet-service-consensus.c | 46 | src/consensus/gnunet-service-consensus.c |
41 | src/consensus/plugin_block_consensus.c | 47 | src/consensus/plugin_block_consensus.c |
@@ -156,18 +162,6 @@ src/gns/nss/nss_gns_query.c | |||
156 | src/gns/plugin_block_gns.c | 162 | src/gns/plugin_block_gns.c |
157 | src/gns/plugin_gnsrecord_gns.c | 163 | src/gns/plugin_gnsrecord_gns.c |
158 | src/gns/plugin_rest_gns.c | 164 | src/gns/plugin_rest_gns.c |
159 | src/gnsrecord/gnsrecord.c | ||
160 | src/gnsrecord/gnsrecord_crypto.c | ||
161 | src/gnsrecord/gnsrecord_misc.c | ||
162 | src/gnsrecord/gnsrecord_serialization.c | ||
163 | src/gnsrecord/gnunet-gnsrecord-tvg.c | ||
164 | src/gnsrecord/json_gnsrecord.c | ||
165 | src/gnsrecord/plugin_gnsrecord_dns.c | ||
166 | src/hello/address.c | ||
167 | src/hello/gnunet-hello.c | ||
168 | src/hello/hello-ng.c | ||
169 | src/hello/hello-uri.c | ||
170 | src/hello/hello.c | ||
171 | src/hostlist/gnunet-daemon-hostlist.c | 165 | src/hostlist/gnunet-daemon-hostlist.c |
172 | src/hostlist/gnunet-daemon-hostlist_client.c | 166 | src/hostlist/gnunet-daemon-hostlist_client.c |
173 | src/hostlist/gnunet-daemon-hostlist_server.c | 167 | src/hostlist/gnunet-daemon-hostlist_server.c |
@@ -182,6 +176,88 @@ src/json/json_generator.c | |||
182 | src/json/json_helper.c | 176 | src/json/json_helper.c |
183 | src/json/json_mhd.c | 177 | src/json/json_mhd.c |
184 | src/json/json_pack.c | 178 | src/json/json_pack.c |
179 | src/lib/block/bg_bf.c | ||
180 | src/lib/block/block.c | ||
181 | src/lib/gnsrecord/gnsrecord.c | ||
182 | src/lib/gnsrecord/gnsrecord_crypto.c | ||
183 | src/lib/gnsrecord/gnsrecord_misc.c | ||
184 | src/lib/gnsrecord/gnsrecord_serialization.c | ||
185 | src/lib/gnsrecord/gnunet-gnsrecord-tvg.c | ||
186 | src/lib/gnsrecord/json_gnsrecord.c | ||
187 | src/lib/hello/address.c | ||
188 | src/lib/hello/hello-ng.c | ||
189 | src/lib/hello/hello-uri.c | ||
190 | src/lib/hello/hello.c | ||
191 | src/lib/util/bandwidth.c | ||
192 | src/lib/util/benchmark.c | ||
193 | src/lib/util/bio.c | ||
194 | src/lib/util/buffer.c | ||
195 | src/lib/util/child_management.c | ||
196 | src/lib/util/client.c | ||
197 | src/lib/util/common_allocation.c | ||
198 | src/lib/util/common_endian.c | ||
199 | src/lib/util/common_logging.c | ||
200 | src/lib/util/compress.c | ||
201 | src/lib/util/configuration.c | ||
202 | src/lib/util/configuration_helper.c | ||
203 | src/lib/util/consttime_memcmp.c | ||
204 | src/lib/util/container_bloomfilter.c | ||
205 | src/lib/util/container_heap.c | ||
206 | src/lib/util/container_multihashmap.c | ||
207 | src/lib/util/container_multihashmap32.c | ||
208 | src/lib/util/container_multipeermap.c | ||
209 | src/lib/util/container_multishortmap.c | ||
210 | src/lib/util/container_multiuuidmap.c | ||
211 | src/lib/util/crypto_crc.c | ||
212 | src/lib/util/crypto_cs.c | ||
213 | src/lib/util/crypto_ecc.c | ||
214 | src/lib/util/crypto_ecc_dlog.c | ||
215 | src/lib/util/crypto_ecc_gnsrecord.c | ||
216 | src/lib/util/crypto_ecc_setup.c | ||
217 | src/lib/util/crypto_edx25519.c | ||
218 | src/lib/util/crypto_hash.c | ||
219 | src/lib/util/crypto_hash_file.c | ||
220 | src/lib/util/crypto_hkdf.c | ||
221 | src/lib/util/crypto_kdf.c | ||
222 | src/lib/util/crypto_mpi.c | ||
223 | src/lib/util/crypto_paillier.c | ||
224 | src/lib/util/crypto_pkey.c | ||
225 | src/lib/util/crypto_pow.c | ||
226 | src/lib/util/crypto_random.c | ||
227 | src/lib/util/crypto_rsa.c | ||
228 | src/lib/util/crypto_symmetric.c | ||
229 | src/lib/util/disk.c | ||
230 | src/lib/util/dnsparser.c | ||
231 | src/lib/util/dnsstub.c | ||
232 | src/lib/util/getopt.c | ||
233 | src/lib/util/getopt_helpers.c | ||
234 | src/lib/util/gnunet_error_codes.c | ||
235 | src/lib/util/helper.c | ||
236 | src/lib/util/load.c | ||
237 | src/lib/util/mq.c | ||
238 | src/lib/util/mst.c | ||
239 | src/lib/util/nc.c | ||
240 | src/lib/util/network.c | ||
241 | src/lib/util/nt.c | ||
242 | src/lib/util/op.c | ||
243 | src/lib/util/os_installation.c | ||
244 | src/lib/util/os_network.c | ||
245 | src/lib/util/os_priority.c | ||
246 | src/lib/util/peer.c | ||
247 | src/lib/util/plugin.c | ||
248 | src/lib/util/proc_compat.c | ||
249 | src/lib/util/program.c | ||
250 | src/lib/util/regex.c | ||
251 | src/lib/util/resolver_api.c | ||
252 | src/lib/util/scheduler.c | ||
253 | src/lib/util/service.c | ||
254 | src/lib/util/signal.c | ||
255 | src/lib/util/socks.c | ||
256 | src/lib/util/speedup.c | ||
257 | src/lib/util/strings.c | ||
258 | src/lib/util/time.c | ||
259 | src/lib/util/tun.c | ||
260 | src/lib/util/uri.c | ||
185 | src/messenger/gnunet-messenger.c | 261 | src/messenger/gnunet-messenger.c |
186 | src/messenger/gnunet-service-messenger.c | 262 | src/messenger/gnunet-service-messenger.c |
187 | src/messenger/gnunet-service-messenger_basement.c | 263 | src/messenger/gnunet-service-messenger_basement.c |
@@ -259,6 +335,9 @@ src/peerstore/peerstore_api.c | |||
259 | src/peerstore/peerstore_common.c | 335 | src/peerstore/peerstore_common.c |
260 | src/peerstore/plugin_peerstore_flat.c | 336 | src/peerstore/plugin_peerstore_flat.c |
261 | src/peerstore/plugin_peerstore_sqlite.c | 337 | src/peerstore/plugin_peerstore_sqlite.c |
338 | src/plugin/block/plugin_block_template.c | ||
339 | src/plugin/block/plugin_block_test.c | ||
340 | src/plugin/gnsrecord/plugin_gnsrecord_dns.c | ||
262 | src/pq/pq.c | 341 | src/pq/pq.c |
263 | src/pq/pq_connect.c | 342 | src/pq/pq_connect.c |
264 | src/pq/pq_eval.c | 343 | src/pq/pq_eval.c |
@@ -332,6 +411,7 @@ src/secretsharing/gnunet-secretsharing-profiler.c | |||
332 | src/secretsharing/gnunet-service-secretsharing.c | 411 | src/secretsharing/gnunet-service-secretsharing.c |
333 | src/secretsharing/secretsharing_api.c | 412 | src/secretsharing/secretsharing_api.c |
334 | src/secretsharing/secretsharing_common.c | 413 | src/secretsharing/secretsharing_common.c |
414 | src/service/util/gnunet-service-resolver.c | ||
335 | src/set/gnunet-service-set.c | 415 | src/set/gnunet-service-set.c |
336 | src/set/gnunet-service-set_intersection.c | 416 | src/set/gnunet-service-set_intersection.c |
337 | src/set/gnunet-service-set_union.c | 417 | src/set/gnunet-service-set_union.c |
@@ -410,86 +490,6 @@ src/transport/transport_api_cmd_send_simple_performance.c | |||
410 | src/transport/transport_api_cmd_start_peer.c | 490 | src/transport/transport_api_cmd_start_peer.c |
411 | src/transport/transport_api_cmd_stop_peer.c | 491 | src/transport/transport_api_cmd_stop_peer.c |
412 | src/transport/transport_api_traits.c | 492 | src/transport/transport_api_traits.c |
413 | src/util/bandwidth.c | ||
414 | src/util/benchmark.c | ||
415 | src/util/bio.c | ||
416 | src/util/buffer.c | ||
417 | src/util/child_management.c | ||
418 | src/util/client.c | ||
419 | src/util/common_allocation.c | ||
420 | src/util/common_endian.c | ||
421 | src/util/common_logging.c | ||
422 | src/util/compress.c | ||
423 | src/util/configuration.c | ||
424 | src/util/configuration_helper.c | ||
425 | src/util/consttime_memcmp.c | ||
426 | src/util/container_bloomfilter.c | ||
427 | src/util/container_heap.c | ||
428 | src/util/container_multihashmap.c | ||
429 | src/util/container_multihashmap32.c | ||
430 | src/util/container_multipeermap.c | ||
431 | src/util/container_multishortmap.c | ||
432 | src/util/container_multiuuidmap.c | ||
433 | src/util/crypto_crc.c | ||
434 | src/util/crypto_cs.c | ||
435 | src/util/crypto_ecc.c | ||
436 | src/util/crypto_ecc_dlog.c | ||
437 | src/util/crypto_ecc_gnsrecord.c | ||
438 | src/util/crypto_ecc_setup.c | ||
439 | src/util/crypto_edx25519.c | ||
440 | src/util/crypto_hash.c | ||
441 | src/util/crypto_hash_file.c | ||
442 | src/util/crypto_hkdf.c | ||
443 | src/util/crypto_kdf.c | ||
444 | src/util/crypto_mpi.c | ||
445 | src/util/crypto_paillier.c | ||
446 | src/util/crypto_pow.c | ||
447 | src/util/crypto_random.c | ||
448 | src/util/crypto_rsa.c | ||
449 | src/util/crypto_symmetric.c | ||
450 | src/util/disk.c | ||
451 | src/util/dnsparser.c | ||
452 | src/util/dnsstub.c | ||
453 | src/util/getopt.c | ||
454 | src/util/getopt_helpers.c | ||
455 | src/util/gnunet-base32.c | ||
456 | src/util/gnunet-config-diff.c | ||
457 | src/util/gnunet-config.c | ||
458 | src/util/gnunet-crypto-tvg.c | ||
459 | src/util/gnunet-ecc.c | ||
460 | src/util/gnunet-qr.c | ||
461 | src/util/gnunet-resolver.c | ||
462 | src/util/gnunet-scrypt.c | ||
463 | src/util/gnunet-service-resolver.c | ||
464 | src/util/gnunet-timeout.c | ||
465 | src/util/gnunet-uri.c | ||
466 | src/util/gnunet_error_codes.c | ||
467 | src/util/helper.c | ||
468 | src/util/load.c | ||
469 | src/util/mq.c | ||
470 | src/util/mst.c | ||
471 | src/util/nc.c | ||
472 | src/util/network.c | ||
473 | src/util/nt.c | ||
474 | src/util/op.c | ||
475 | src/util/os_installation.c | ||
476 | src/util/os_network.c | ||
477 | src/util/os_priority.c | ||
478 | src/util/peer.c | ||
479 | src/util/plugin.c | ||
480 | src/util/proc_compat.c | ||
481 | src/util/program.c | ||
482 | src/util/regex.c | ||
483 | src/util/resolver_api.c | ||
484 | src/util/scheduler.c | ||
485 | src/util/service.c | ||
486 | src/util/signal.c | ||
487 | src/util/socks.c | ||
488 | src/util/speedup.c | ||
489 | src/util/strings.c | ||
490 | src/util/time.c | ||
491 | src/util/tun.c | ||
492 | src/util/uri.c | ||
493 | src/vpn/gnunet-helper-vpn.c | 493 | src/vpn/gnunet-helper-vpn.c |
494 | src/vpn/gnunet-service-vpn.c | 494 | src/vpn/gnunet-service-vpn.c |
495 | src/vpn/gnunet-vpn.c | 495 | src/vpn/gnunet-vpn.c |
diff --git a/src/Makefile.am b/src/Makefile.am index 2112bfca8..3746c6b19 100644 --- a/src/Makefile.am +++ b/src/Makefile.am | |||
@@ -33,9 +33,10 @@ REST_DIR = rest | |||
33 | 33 | ||
34 | SUBDIRS = \ | 34 | SUBDIRS = \ |
35 | include $(INTLEMU_SUBDIRS) \ | 35 | include $(INTLEMU_SUBDIRS) \ |
36 | util \ | 36 | lib \ |
37 | hello \ | 37 | plugin \ |
38 | block \ | 38 | service \ |
39 | cli \ | ||
39 | statistics \ | 40 | statistics \ |
40 | arm \ | 41 | arm \ |
41 | $(TESTING) \ | 42 | $(TESTING) \ |
@@ -60,7 +61,6 @@ SUBDIRS = \ | |||
60 | regex \ | 61 | regex \ |
61 | dns \ | 62 | dns \ |
62 | identity \ | 63 | identity \ |
63 | gnsrecord \ | ||
64 | namecache \ | 64 | namecache \ |
65 | namestore \ | 65 | namestore \ |
66 | cadet \ | 66 | cadet \ |
diff --git a/src/abd/Makefile.am b/src/abd/Makefile.am index 69809291a..6fa2dc848 100644 --- a/src/abd/Makefile.am +++ b/src/abd/Makefile.am | |||
@@ -41,8 +41,8 @@ gnunet_abd_SOURCES = \ | |||
41 | gnunet-abd.c | 41 | gnunet-abd.c |
42 | gnunet_abd_LDADD = \ | 42 | gnunet_abd_LDADD = \ |
43 | libgnunetabd.la \ | 43 | libgnunetabd.la \ |
44 | $(top_builddir)/src/util/libgnunetutil.la \ | 44 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
45 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 45 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
46 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 46 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
47 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 47 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
48 | $(GN_LIBINTL) | 48 | $(GN_LIBINTL) |
@@ -52,7 +52,7 @@ libgnunet_plugin_gnsrecord_abd_la_SOURCES = \ | |||
52 | plugin_gnsrecord_abd.c | 52 | plugin_gnsrecord_abd.c |
53 | libgnunet_plugin_gnsrecord_abd_la_LIBADD = \ | 53 | libgnunet_plugin_gnsrecord_abd_la_LIBADD = \ |
54 | libgnunetabd.la \ | 54 | libgnunetabd.la \ |
55 | $(top_builddir)/src/util/libgnunetutil.la \ | 55 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
56 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 56 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
57 | $(LTLIBINTL) | 57 | $(LTLIBINTL) |
58 | libgnunet_plugin_gnsrecord_abd_la_LDFLAGS = \ | 58 | libgnunet_plugin_gnsrecord_abd_la_LDFLAGS = \ |
@@ -64,7 +64,7 @@ gnunet_service_abd_SOURCES = \ | |||
64 | gnunet-service-abd.c | 64 | gnunet-service-abd.c |
65 | gnunet_service_abd_LDADD = \ | 65 | gnunet_service_abd_LDADD = \ |
66 | libgnunetabd.la \ | 66 | libgnunetabd.la \ |
67 | $(top_builddir)/src/util/libgnunetutil.la \ | 67 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
68 | $(top_builddir)/src/gns/libgnunetgns.la \ | 68 | $(top_builddir)/src/gns/libgnunetgns.la \ |
69 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 69 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
70 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 70 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
@@ -79,7 +79,7 @@ libgnunetabd_la_SOURCES = \ | |||
79 | delegate_misc.c \ | 79 | delegate_misc.c \ |
80 | delegate_misc.h | 80 | delegate_misc.h |
81 | libgnunetabd_la_LIBADD = \ | 81 | libgnunetabd_la_LIBADD = \ |
82 | $(top_builddir)/src/util/libgnunetutil.la \ | 82 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
83 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 83 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
84 | $(XLIB) | 84 | $(XLIB) |
85 | libgnunetabd_la_LDFLAGS = \ | 85 | libgnunetabd_la_LDFLAGS = \ |
diff --git a/src/abd/abd.h b/src/abd/abd.h index 61210b3f7..26b8e222e 100644 --- a/src/abd/abd.h +++ b/src/abd/abd.h | |||
@@ -42,12 +42,12 @@ struct CollectMessage | |||
42 | /** | 42 | /** |
43 | * Subject public key | 43 | * Subject public key |
44 | */ | 44 | */ |
45 | struct GNUNET_IDENTITY_PrivateKey subject_key; | 45 | struct GNUNET_CRYPTO_PrivateKey subject_key; |
46 | 46 | ||
47 | /** | 47 | /** |
48 | * Trust anchor | 48 | * Trust anchor |
49 | */ | 49 | */ |
50 | struct GNUNET_IDENTITY_PublicKey issuer_key; | 50 | struct GNUNET_CRYPTO_PublicKey issuer_key; |
51 | 51 | ||
52 | /** | 52 | /** |
53 | * Length of the issuer attribute | 53 | * Length of the issuer attribute |
@@ -81,12 +81,12 @@ struct VerifyMessage | |||
81 | /** | 81 | /** |
82 | * Subject public key | 82 | * Subject public key |
83 | */ | 83 | */ |
84 | struct GNUNET_IDENTITY_PublicKey subject_key; | 84 | struct GNUNET_CRYPTO_PublicKey subject_key; |
85 | 85 | ||
86 | /** | 86 | /** |
87 | * Trust anchor | 87 | * Trust anchor |
88 | */ | 88 | */ |
89 | struct GNUNET_IDENTITY_PublicKey issuer_key; | 89 | struct GNUNET_CRYPTO_PublicKey issuer_key; |
90 | 90 | ||
91 | /** | 91 | /** |
92 | * Number of delegates | 92 | * Number of delegates |
@@ -170,7 +170,7 @@ struct DelegationRecordData | |||
170 | /** | 170 | /** |
171 | * Subject key | 171 | * Subject key |
172 | */ | 172 | */ |
173 | struct GNUNET_IDENTITY_PublicKey subject_key; | 173 | struct GNUNET_CRYPTO_PublicKey subject_key; |
174 | 174 | ||
175 | /** | 175 | /** |
176 | * Subject attributes | 176 | * Subject attributes |
@@ -184,12 +184,12 @@ struct ChainEntry | |||
184 | /** | 184 | /** |
185 | * Issuer key | 185 | * Issuer key |
186 | */ | 186 | */ |
187 | struct GNUNET_IDENTITY_PublicKey issuer_key; | 187 | struct GNUNET_CRYPTO_PublicKey issuer_key; |
188 | 188 | ||
189 | /** | 189 | /** |
190 | * Subject key | 190 | * Subject key |
191 | */ | 191 | */ |
192 | struct GNUNET_IDENTITY_PublicKey subject_key; | 192 | struct GNUNET_CRYPTO_PublicKey subject_key; |
193 | 193 | ||
194 | /** | 194 | /** |
195 | * Issuer attributes | 195 | * Issuer attributes |
@@ -208,7 +208,7 @@ struct DelegateEntry | |||
208 | /** | 208 | /** |
209 | * The signature for this credential by the issuer | 209 | * The signature for this credential by the issuer |
210 | */ | 210 | */ |
211 | struct GNUNET_IDENTITY_Signature signature; | 211 | struct GNUNET_CRYPTO_Signature signature; |
212 | 212 | ||
213 | /** | 213 | /** |
214 | * Signature meta | 214 | * Signature meta |
@@ -218,12 +218,12 @@ struct DelegateEntry | |||
218 | /** | 218 | /** |
219 | * Public key of the issuer | 219 | * Public key of the issuer |
220 | */ | 220 | */ |
221 | struct GNUNET_IDENTITY_PublicKey issuer_key; | 221 | struct GNUNET_CRYPTO_PublicKey issuer_key; |
222 | 222 | ||
223 | /** | 223 | /** |
224 | * Public key of the subject this credential was issued to | 224 | * Public key of the subject this credential was issued to |
225 | */ | 225 | */ |
226 | struct GNUNET_IDENTITY_PublicKey subject_key; | 226 | struct GNUNET_CRYPTO_PublicKey subject_key; |
227 | 227 | ||
228 | /** | 228 | /** |
229 | * Expiration time of this credential | 229 | * Expiration time of this credential |
diff --git a/src/abd/abd_api.c b/src/abd/abd_api.c index 0b3b4f61f..3682f41ba 100644 --- a/src/abd/abd_api.c +++ b/src/abd/abd_api.c | |||
@@ -422,9 +422,9 @@ GNUNET_ABD_request_cancel (struct GNUNET_ABD_Request *lr) | |||
422 | struct GNUNET_ABD_Request * | 422 | struct GNUNET_ABD_Request * |
423 | GNUNET_ABD_collect ( | 423 | GNUNET_ABD_collect ( |
424 | struct GNUNET_ABD_Handle *handle, | 424 | struct GNUNET_ABD_Handle *handle, |
425 | const struct GNUNET_IDENTITY_PublicKey *issuer_key, | 425 | const struct GNUNET_CRYPTO_PublicKey *issuer_key, |
426 | const char *issuer_attribute, | 426 | const char *issuer_attribute, |
427 | const struct GNUNET_IDENTITY_PrivateKey *subject_key, | 427 | const struct GNUNET_CRYPTO_PrivateKey *subject_key, |
428 | enum GNUNET_ABD_AlgoDirectionFlags direction, | 428 | enum GNUNET_ABD_AlgoDirectionFlags direction, |
429 | GNUNET_ABD_CredentialResultProcessor proc, | 429 | GNUNET_ABD_CredentialResultProcessor proc, |
430 | void *proc_cls, | 430 | void *proc_cls, |
@@ -496,9 +496,9 @@ GNUNET_ABD_collect ( | |||
496 | struct GNUNET_ABD_Request * | 496 | struct GNUNET_ABD_Request * |
497 | GNUNET_ABD_verify ( | 497 | GNUNET_ABD_verify ( |
498 | struct GNUNET_ABD_Handle *handle, | 498 | struct GNUNET_ABD_Handle *handle, |
499 | const struct GNUNET_IDENTITY_PublicKey *issuer_key, | 499 | const struct GNUNET_CRYPTO_PublicKey *issuer_key, |
500 | const char *issuer_attribute, | 500 | const char *issuer_attribute, |
501 | const struct GNUNET_IDENTITY_PublicKey *subject_key, | 501 | const struct GNUNET_CRYPTO_PublicKey *subject_key, |
502 | uint32_t delegate_count, | 502 | uint32_t delegate_count, |
503 | const struct GNUNET_ABD_Delegate *delegates, | 503 | const struct GNUNET_ABD_Delegate *delegates, |
504 | enum GNUNET_ABD_AlgoDirectionFlags direction, | 504 | enum GNUNET_ABD_AlgoDirectionFlags direction, |
diff --git a/src/abd/abd_serialization.c b/src/abd/abd_serialization.c index 2ed24ff2f..14960e804 100644 --- a/src/abd/abd_serialization.c +++ b/src/abd/abd_serialization.c | |||
@@ -199,7 +199,7 @@ GNUNET_ABD_delegates_serialize ( | |||
199 | c_rec.purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_DELEGATE); | 199 | c_rec.purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_DELEGATE); |
200 | c_rec.purpose.size = | 200 | c_rec.purpose.size = |
201 | htonl ((sizeof (struct DelegateEntry) + cd[i].issuer_attribute_len) | 201 | htonl ((sizeof (struct DelegateEntry) + cd[i].issuer_attribute_len) |
202 | - sizeof (struct GNUNET_IDENTITY_Signature)); | 202 | - sizeof (struct GNUNET_CRYPTO_Signature)); |
203 | c_rec.expiration = GNUNET_htonll (cd[i].expiration.abs_value_us); | 203 | c_rec.expiration = GNUNET_htonll (cd[i].expiration.abs_value_us); |
204 | if (off + sizeof (c_rec) > dest_size) | 204 | if (off + sizeof (c_rec) > dest_size) |
205 | return -1; | 205 | return -1; |
@@ -445,12 +445,12 @@ GNUNET_ABD_delegate_serialize (struct GNUNET_ABD_Delegate *dele, | |||
445 | } | 445 | } |
446 | cdata->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_DELEGATE); | 446 | cdata->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_DELEGATE); |
447 | cdata->purpose.size = | 447 | cdata->purpose.size = |
448 | htonl (size - sizeof (struct GNUNET_IDENTITY_Signature)); | 448 | htonl (size - sizeof (struct GNUNET_CRYPTO_Signature)); |
449 | 449 | ||
450 | GNUNET_memcpy (&cdata[1], tmp_str, attr_len); | 450 | GNUNET_memcpy (&cdata[1], tmp_str, attr_len); |
451 | 451 | ||
452 | if (GNUNET_OK != | 452 | if (GNUNET_OK != |
453 | GNUNET_IDENTITY_signature_verify_ (GNUNET_SIGNATURE_PURPOSE_DELEGATE, | 453 | GNUNET_CRYPTO_signature_verify_ (GNUNET_SIGNATURE_PURPOSE_DELEGATE, |
454 | &cdata->purpose, | 454 | &cdata->purpose, |
455 | &cdata->signature, | 455 | &cdata->signature, |
456 | &cdata->issuer_key)) | 456 | &cdata->issuer_key)) |
@@ -473,7 +473,7 @@ GNUNET_ABD_delegate_deserialize (const char *data, size_t data_size) | |||
473 | return NULL; | 473 | return NULL; |
474 | cdata = (struct DelegateEntry *) data; | 474 | cdata = (struct DelegateEntry *) data; |
475 | if (GNUNET_OK != | 475 | if (GNUNET_OK != |
476 | GNUNET_IDENTITY_signature_verify_ (GNUNET_SIGNATURE_PURPOSE_DELEGATE, | 476 | GNUNET_CRYPTO_signature_verify_ (GNUNET_SIGNATURE_PURPOSE_DELEGATE, |
477 | &cdata->purpose, | 477 | &cdata->purpose, |
478 | &cdata->signature, | 478 | &cdata->signature, |
479 | &cdata->issuer_key)) | 479 | &cdata->issuer_key)) |
diff --git a/src/abd/delegate_misc.c b/src/abd/delegate_misc.c index cc45cde04..446c0b8d2 100644 --- a/src/abd/delegate_misc.c +++ b/src/abd/delegate_misc.c | |||
@@ -42,10 +42,10 @@ GNUNET_ABD_delegate_to_string ( | |||
42 | char *issuer_pkey; | 42 | char *issuer_pkey; |
43 | char *signature; | 43 | char *signature; |
44 | 44 | ||
45 | subject_pkey = GNUNET_IDENTITY_public_key_to_string (&cred->subject_key); | 45 | subject_pkey = GNUNET_CRYPTO_public_key_to_string (&cred->subject_key); |
46 | issuer_pkey = GNUNET_IDENTITY_public_key_to_string (&cred->issuer_key); | 46 | issuer_pkey = GNUNET_CRYPTO_public_key_to_string (&cred->issuer_key); |
47 | GNUNET_STRINGS_base64_encode ((char *) &cred->signature, | 47 | GNUNET_STRINGS_base64_encode ((char *) &cred->signature, |
48 | sizeof (struct GNUNET_IDENTITY_Signature), | 48 | sizeof (struct GNUNET_CRYPTO_Signature), |
49 | &signature); | 49 | &signature); |
50 | if (0 == cred->subject_attribute_len) | 50 | if (0 == cred->subject_attribute_len) |
51 | { | 51 | { |
@@ -80,7 +80,7 @@ struct GNUNET_ABD_Delegate * | |||
80 | GNUNET_ABD_delegate_from_string (const char *s) | 80 | GNUNET_ABD_delegate_from_string (const char *s) |
81 | { | 81 | { |
82 | struct GNUNET_ABD_Delegate *dele; | 82 | struct GNUNET_ABD_Delegate *dele; |
83 | size_t enclen = (sizeof (struct GNUNET_IDENTITY_PublicKey)) * 8; | 83 | size_t enclen = (sizeof (struct GNUNET_CRYPTO_PublicKey)) * 8; |
84 | if (enclen % 5 > 0) | 84 | if (enclen % 5 > 0) |
85 | enclen += 5 - enclen % 5; | 85 | enclen += 5 - enclen % 5; |
86 | enclen /= 5; /* 260/5 = 52 */ | 86 | enclen /= 5; /* 260/5 = 52 */ |
@@ -91,7 +91,7 @@ GNUNET_ABD_delegate_from_string (const char *s) | |||
91 | char sub_attr[253 + 1] = ""; | 91 | char sub_attr[253 + 1] = ""; |
92 | char signature[256]; // TODO max payload size | 92 | char signature[256]; // TODO max payload size |
93 | 93 | ||
94 | struct GNUNET_IDENTITY_Signature *sig; | 94 | struct GNUNET_CRYPTO_Signature *sig; |
95 | struct GNUNET_TIME_Absolute etime_abs; | 95 | struct GNUNET_TIME_Absolute etime_abs; |
96 | 96 | ||
97 | // If it's A.a <- B.b... | 97 | // If it's A.a <- B.b... |
@@ -144,20 +144,20 @@ GNUNET_ABD_delegate_from_string (const char *s) | |||
144 | tmp_str[attr_len - 1] = '\0'; | 144 | tmp_str[attr_len - 1] = '\0'; |
145 | 145 | ||
146 | if (GNUNET_SYSERR == | 146 | if (GNUNET_SYSERR == |
147 | GNUNET_IDENTITY_public_key_from_string (subject_pkey, | 147 | GNUNET_CRYPTO_public_key_from_string (subject_pkey, |
148 | &dele->subject_key)) | 148 | &dele->subject_key)) |
149 | { | 149 | { |
150 | GNUNET_free (dele); | 150 | GNUNET_free (dele); |
151 | return NULL; | 151 | return NULL; |
152 | } | 152 | } |
153 | if (GNUNET_SYSERR == | 153 | if (GNUNET_SYSERR == |
154 | GNUNET_IDENTITY_public_key_from_string (issuer_pkey, | 154 | GNUNET_CRYPTO_public_key_from_string (issuer_pkey, |
155 | &dele->issuer_key)) | 155 | &dele->issuer_key)) |
156 | { | 156 | { |
157 | GNUNET_free (dele); | 157 | GNUNET_free (dele); |
158 | return NULL; | 158 | return NULL; |
159 | } | 159 | } |
160 | GNUNET_assert (sizeof (struct GNUNET_IDENTITY_Signature) == | 160 | GNUNET_assert (sizeof (struct GNUNET_CRYPTO_Signature) == |
161 | GNUNET_STRINGS_base64_decode (signature, | 161 | GNUNET_STRINGS_base64_decode (signature, |
162 | strlen (signature), | 162 | strlen (signature), |
163 | (void **) &sig)); | 163 | (void **) &sig)); |
@@ -196,8 +196,8 @@ GNUNET_ABD_delegate_from_string (const char *s) | |||
196 | 196 | ||
197 | struct GNUNET_ABD_Delegate * | 197 | struct GNUNET_ABD_Delegate * |
198 | GNUNET_ABD_delegate_issue ( | 198 | GNUNET_ABD_delegate_issue ( |
199 | const struct GNUNET_IDENTITY_PrivateKey *issuer, | 199 | const struct GNUNET_CRYPTO_PrivateKey *issuer, |
200 | struct GNUNET_IDENTITY_PublicKey *subject, | 200 | struct GNUNET_CRYPTO_PublicKey *subject, |
201 | const char *iss_attr, | 201 | const char *iss_attr, |
202 | const char *sub_attr, | 202 | const char *sub_attr, |
203 | struct GNUNET_TIME_Absolute *expiration) | 203 | struct GNUNET_TIME_Absolute *expiration) |
@@ -232,9 +232,9 @@ GNUNET_ABD_delegate_issue ( | |||
232 | 232 | ||
233 | del = GNUNET_malloc (size); | 233 | del = GNUNET_malloc (size); |
234 | del->purpose.size = | 234 | del->purpose.size = |
235 | htonl (size - sizeof (struct GNUNET_IDENTITY_Signature)); | 235 | htonl (size - sizeof (struct GNUNET_CRYPTO_Signature)); |
236 | del->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_DELEGATE); | 236 | del->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_DELEGATE); |
237 | GNUNET_IDENTITY_key_get_public (issuer, &del->issuer_key); | 237 | GNUNET_CRYPTO_key_get_public (issuer, &del->issuer_key); |
238 | del->subject_key = *subject; | 238 | del->subject_key = *subject; |
239 | del->expiration = GNUNET_htonll (expiration->abs_value_us); | 239 | del->expiration = GNUNET_htonll (expiration->abs_value_us); |
240 | del->issuer_attribute_len = htonl (strlen (iss_attr) + 1); | 240 | del->issuer_attribute_len = htonl (strlen (iss_attr) + 1); |
@@ -249,12 +249,12 @@ GNUNET_ABD_delegate_issue ( | |||
249 | 249 | ||
250 | GNUNET_memcpy (&del[1], tmp_str, attr_len); | 250 | GNUNET_memcpy (&del[1], tmp_str, attr_len); |
251 | 251 | ||
252 | GNUNET_IDENTITY_sign_ (issuer, &del->purpose, &del->signature); | 252 | GNUNET_CRYPTO_sign_ (issuer, &del->purpose, &del->signature); |
253 | 253 | ||
254 | dele = GNUNET_malloc (sizeof (struct GNUNET_ABD_Delegate) + attr_len); | 254 | dele = GNUNET_malloc (sizeof (struct GNUNET_ABD_Delegate) + attr_len); |
255 | dele->signature = del->signature; | 255 | dele->signature = del->signature; |
256 | dele->expiration = *expiration; | 256 | dele->expiration = *expiration; |
257 | GNUNET_IDENTITY_key_get_public (issuer, &dele->issuer_key); | 257 | GNUNET_CRYPTO_key_get_public (issuer, &dele->issuer_key); |
258 | 258 | ||
259 | dele->subject_key = *subject; | 259 | dele->subject_key = *subject; |
260 | 260 | ||
diff --git a/src/abd/gnunet-abd.c b/src/abd/gnunet-abd.c index 6f6521d98..1ed1adbe7 100644 --- a/src/abd/gnunet-abd.c +++ b/src/abd/gnunet-abd.c | |||
@@ -43,7 +43,7 @@ static struct GNUNET_NAMESTORE_Handle *ns; | |||
43 | /** | 43 | /** |
44 | * Private key for the our zone. | 44 | * Private key for the our zone. |
45 | */ | 45 | */ |
46 | static struct GNUNET_IDENTITY_PrivateKey zone_pkey; | 46 | static struct GNUNET_CRYPTO_PrivateKey zone_pkey; |
47 | 47 | ||
48 | /** | 48 | /** |
49 | * EgoLookup | 49 | * EgoLookup |
@@ -98,12 +98,12 @@ static char *expiration; | |||
98 | /** | 98 | /** |
99 | * Subject key | 99 | * Subject key |
100 | */ | 100 | */ |
101 | struct GNUNET_IDENTITY_PublicKey subject_pkey; | 101 | struct GNUNET_CRYPTO_PublicKey subject_pkey; |
102 | 102 | ||
103 | /** | 103 | /** |
104 | * Issuer key | 104 | * Issuer key |
105 | */ | 105 | */ |
106 | struct GNUNET_IDENTITY_PublicKey issuer_pkey; | 106 | struct GNUNET_CRYPTO_PublicKey issuer_pkey; |
107 | 107 | ||
108 | 108 | ||
109 | /** | 109 | /** |
@@ -277,9 +277,9 @@ handle_intermediate_result (void *cls, | |||
277 | 277 | ||
278 | printf ("%s Intermediate result: %s.%s <- %s.%s\n", | 278 | printf ("%s Intermediate result: %s.%s <- %s.%s\n", |
279 | prefix, | 279 | prefix, |
280 | GNUNET_IDENTITY_public_key_to_string (&dd->issuer_key), | 280 | GNUNET_CRYPTO_public_key_to_string (&dd->issuer_key), |
281 | dd->issuer_attribute, | 281 | dd->issuer_attribute, |
282 | GNUNET_IDENTITY_public_key_to_string (&dd->subject_key), | 282 | GNUNET_CRYPTO_public_key_to_string (&dd->subject_key), |
283 | dd->subject_attribute); | 283 | dd->subject_attribute); |
284 | } | 284 | } |
285 | 285 | ||
@@ -332,8 +332,8 @@ handle_verify_result (void *cls, | |||
332 | printf ("Delegation Chain:\n"); | 332 | printf ("Delegation Chain:\n"); |
333 | for (i = 0; i < d_count; i++) | 333 | for (i = 0; i < d_count; i++) |
334 | { | 334 | { |
335 | iss_key = GNUNET_IDENTITY_public_key_to_string (&dc[i].issuer_key); | 335 | iss_key = GNUNET_CRYPTO_public_key_to_string (&dc[i].issuer_key); |
336 | sub_key = GNUNET_IDENTITY_public_key_to_string (&dc[i].subject_key); | 336 | sub_key = GNUNET_CRYPTO_public_key_to_string (&dc[i].subject_key); |
337 | 337 | ||
338 | if (0 != dc[i].subject_attribute_len) | 338 | if (0 != dc[i].subject_attribute_len) |
339 | { | 339 | { |
@@ -358,8 +358,8 @@ handle_verify_result (void *cls, | |||
358 | printf ("\nDelegate(s):\n"); | 358 | printf ("\nDelegate(s):\n"); |
359 | for (i = 0; i < c_count; i++) | 359 | for (i = 0; i < c_count; i++) |
360 | { | 360 | { |
361 | iss_key = GNUNET_IDENTITY_public_key_to_string (&dele[i].issuer_key); | 361 | iss_key = GNUNET_CRYPTO_public_key_to_string (&dele[i].issuer_key); |
362 | sub_key = GNUNET_IDENTITY_public_key_to_string (&dele[i].subject_key); | 362 | sub_key = GNUNET_CRYPTO_public_key_to_string (&dele[i].subject_key); |
363 | printf ("%s.%s <- %s\n", iss_key, dele[i].issuer_attribute, sub_key); | 363 | printf ("%s.%s <- %s\n", iss_key, dele[i].issuer_attribute, sub_key); |
364 | GNUNET_free (iss_key); | 364 | GNUNET_free (iss_key); |
365 | GNUNET_free (sub_key); | 365 | GNUNET_free (sub_key); |
@@ -381,7 +381,7 @@ handle_verify_result (void *cls, | |||
381 | static void | 381 | static void |
382 | identity_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) | 382 | identity_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) |
383 | { | 383 | { |
384 | const struct GNUNET_IDENTITY_PrivateKey *privkey; | 384 | const struct GNUNET_CRYPTO_PrivateKey *privkey; |
385 | 385 | ||
386 | el = NULL; | 386 | el = NULL; |
387 | if (NULL == ego) | 387 | if (NULL == ego) |
@@ -400,7 +400,7 @@ identity_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
400 | { | 400 | { |
401 | 401 | ||
402 | if (GNUNET_OK != | 402 | if (GNUNET_OK != |
403 | GNUNET_IDENTITY_public_key_from_string (issuer_key, | 403 | GNUNET_CRYPTO_public_key_from_string (issuer_key, |
404 | &issuer_pkey)) | 404 | &issuer_pkey)) |
405 | { | 405 | { |
406 | fprintf (stderr, | 406 | fprintf (stderr, |
@@ -501,7 +501,7 @@ add_continuation (void *cls, int32_t success, const char *emsg) | |||
501 | 501 | ||
502 | static void | 502 | static void |
503 | get_existing_record (void *cls, | 503 | get_existing_record (void *cls, |
504 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, | 504 | const struct GNUNET_CRYPTO_PrivateKey *zone_key, |
505 | const char *rec_name, | 505 | const char *rec_name, |
506 | unsigned int rd_count, | 506 | unsigned int rd_count, |
507 | const struct GNUNET_GNSRECORD_Data *rd) | 507 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -545,7 +545,7 @@ store_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
545 | { | 545 | { |
546 | const struct GNUNET_CONFIGURATION_Handle *cfg = cls; | 546 | const struct GNUNET_CONFIGURATION_Handle *cfg = cls; |
547 | struct GNUNET_ABD_Delegate *cred; | 547 | struct GNUNET_ABD_Delegate *cred; |
548 | struct GNUNET_IDENTITY_PublicKey zone_pubkey; | 548 | struct GNUNET_CRYPTO_PublicKey zone_pubkey; |
549 | char *subject_pubkey_str; | 549 | char *subject_pubkey_str; |
550 | char *zone_pubkey_str; | 550 | char *zone_pubkey_str; |
551 | 551 | ||
@@ -586,12 +586,12 @@ store_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
586 | 586 | ||
587 | // Get import subject public key string | 587 | // Get import subject public key string |
588 | subject_pubkey_str = | 588 | subject_pubkey_str = |
589 | GNUNET_IDENTITY_public_key_to_string (&cred->subject_key); | 589 | GNUNET_CRYPTO_public_key_to_string (&cred->subject_key); |
590 | 590 | ||
591 | // Get zone public key string | 591 | // Get zone public key string |
592 | GNUNET_IDENTITY_ego_get_public_key (ego, &zone_pubkey); | 592 | GNUNET_IDENTITY_ego_get_public_key (ego, &zone_pubkey); |
593 | zone_pubkey_str = | 593 | zone_pubkey_str = |
594 | GNUNET_IDENTITY_public_key_to_string (&zone_pubkey); | 594 | GNUNET_CRYPTO_public_key_to_string (&zone_pubkey); |
595 | 595 | ||
596 | // Check if the subject key in the signed import matches the zone's key it is issued to | 596 | // Check if the subject key in the signed import matches the zone's key it is issued to |
597 | if (strcmp (zone_pubkey_str, subject_pubkey_str) != 0) | 597 | if (strcmp (zone_pubkey_str, subject_pubkey_str) != 0) |
@@ -668,7 +668,7 @@ store_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
668 | static void | 668 | static void |
669 | sign_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) | 669 | sign_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) |
670 | { | 670 | { |
671 | const struct GNUNET_IDENTITY_PrivateKey *privkey; | 671 | const struct GNUNET_CRYPTO_PrivateKey *privkey; |
672 | struct GNUNET_ABD_Delegate *dele; | 672 | struct GNUNET_ABD_Delegate *dele; |
673 | struct GNUNET_TIME_Absolute etime_abs; | 673 | struct GNUNET_TIME_Absolute etime_abs; |
674 | char *res; | 674 | char *res; |
@@ -718,7 +718,7 @@ sign_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
718 | return; | 718 | return; |
719 | } | 719 | } |
720 | if (GNUNET_OK != | 720 | if (GNUNET_OK != |
721 | GNUNET_IDENTITY_public_key_from_string (subject_pubkey_str, | 721 | GNUNET_CRYPTO_public_key_from_string (subject_pubkey_str, |
722 | &subject_pkey)) | 722 | &subject_pkey)) |
723 | { | 723 | { |
724 | fprintf (stderr, | 724 | fprintf (stderr, |
@@ -883,7 +883,7 @@ run (void *cls, | |||
883 | GNUNET_SCHEDULER_shutdown (); | 883 | GNUNET_SCHEDULER_shutdown (); |
884 | return; | 884 | return; |
885 | } | 885 | } |
886 | if (GNUNET_OK != GNUNET_IDENTITY_public_key_from_string (subject, | 886 | if (GNUNET_OK != GNUNET_CRYPTO_public_key_from_string (subject, |
887 | &subject_pkey)) | 887 | &subject_pkey)) |
888 | { | 888 | { |
889 | fprintf (stderr, | 889 | fprintf (stderr, |
@@ -902,7 +902,7 @@ run (void *cls, | |||
902 | return; | 902 | return; |
903 | } | 903 | } |
904 | if (GNUNET_OK != | 904 | if (GNUNET_OK != |
905 | GNUNET_IDENTITY_public_key_from_string (issuer_key, | 905 | GNUNET_CRYPTO_public_key_from_string (issuer_key, |
906 | &issuer_pkey)) | 906 | &issuer_pkey)) |
907 | { | 907 | { |
908 | fprintf (stderr, | 908 | fprintf (stderr, |
diff --git a/src/abd/gnunet-service-abd.c b/src/abd/gnunet-service-abd.c index 42b26eb9b..5cbc105f6 100644 --- a/src/abd/gnunet-service-abd.c +++ b/src/abd/gnunet-service-abd.c | |||
@@ -60,12 +60,12 @@ struct DelegationChainEntry | |||
60 | /** | 60 | /** |
61 | * The issuer | 61 | * The issuer |
62 | */ | 62 | */ |
63 | struct GNUNET_IDENTITY_PublicKey issuer_key; | 63 | struct GNUNET_CRYPTO_PublicKey issuer_key; |
64 | 64 | ||
65 | /** | 65 | /** |
66 | * The subject | 66 | * The subject |
67 | */ | 67 | */ |
68 | struct GNUNET_IDENTITY_PublicKey subject_key; | 68 | struct GNUNET_CRYPTO_PublicKey subject_key; |
69 | 69 | ||
70 | /** | 70 | /** |
71 | * The issued attribute | 71 | * The issued attribute |
@@ -165,7 +165,7 @@ struct DelegationSetQueueEntry | |||
165 | /** | 165 | /** |
166 | * Issuer key | 166 | * Issuer key |
167 | */ | 167 | */ |
168 | struct GNUNET_IDENTITY_PublicKey *issuer_key; | 168 | struct GNUNET_CRYPTO_PublicKey *issuer_key; |
169 | 169 | ||
170 | /** | 170 | /** |
171 | * Queue entries of this set | 171 | * Queue entries of this set |
@@ -266,7 +266,7 @@ struct VerifyRequestHandle | |||
266 | /** | 266 | /** |
267 | * Issuer public key | 267 | * Issuer public key |
268 | */ | 268 | */ |
269 | struct GNUNET_IDENTITY_PublicKey issuer_key; | 269 | struct GNUNET_CRYPTO_PublicKey issuer_key; |
270 | 270 | ||
271 | /** | 271 | /** |
272 | * Issuer attribute | 272 | * Issuer attribute |
@@ -276,7 +276,7 @@ struct VerifyRequestHandle | |||
276 | /** | 276 | /** |
277 | * Subject public key | 277 | * Subject public key |
278 | */ | 278 | */ |
279 | struct GNUNET_IDENTITY_PublicKey subject_key; | 279 | struct GNUNET_CRYPTO_PublicKey subject_key; |
280 | 280 | ||
281 | /** | 281 | /** |
282 | * Delegate DLL | 282 | * Delegate DLL |
@@ -351,10 +351,10 @@ print_deleset (struct DelegationSetQueueEntry *dsentry, char *text) | |||
351 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 351 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
352 | "%s %s.%s <- %s.%s\n", | 352 | "%s %s.%s <- %s.%s\n", |
353 | text, | 353 | text, |
354 | GNUNET_IDENTITY_public_key_to_string ( | 354 | GNUNET_CRYPTO_public_key_to_string ( |
355 | &dsentry->delegation_chain_entry->issuer_key), | 355 | &dsentry->delegation_chain_entry->issuer_key), |
356 | dsentry->delegation_chain_entry->issuer_attribute, | 356 | dsentry->delegation_chain_entry->issuer_attribute, |
357 | GNUNET_IDENTITY_public_key_to_string ( | 357 | GNUNET_CRYPTO_public_key_to_string ( |
358 | &dsentry->delegation_chain_entry->subject_key), | 358 | &dsentry->delegation_chain_entry->subject_key), |
359 | dsentry->delegation_chain_entry->subject_attribute); | 359 | dsentry->delegation_chain_entry->subject_attribute); |
360 | } | 360 | } |
@@ -698,7 +698,7 @@ handle_bidirectional_match (struct DelegationSetQueueEntry *actual_entry, | |||
698 | { | 698 | { |
699 | if (0 != memcmp (&last_entry->delegation_chain_entry->subject_key, | 699 | if (0 != memcmp (&last_entry->delegation_chain_entry->subject_key, |
700 | &del_entry->delegate->issuer_key, | 700 | &del_entry->delegate->issuer_key, |
701 | sizeof (struct GNUNET_IDENTITY_PublicKey))) | 701 | sizeof (struct GNUNET_CRYPTO_PublicKey))) |
702 | continue; | 702 | continue; |
703 | if (0 != strcmp (last_entry->delegation_chain_entry->subject_attribute, | 703 | if (0 != strcmp (last_entry->delegation_chain_entry->subject_attribute, |
704 | del_entry->delegate->issuer_attribute)) | 704 | del_entry->delegate->issuer_attribute)) |
@@ -832,10 +832,10 @@ forward_resolution (void *cls, | |||
832 | { | 832 | { |
833 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 833 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
834 | "Entry not relevant, discarding: %s.%s <- %s.%s\n", | 834 | "Entry not relevant, discarding: %s.%s <- %s.%s\n", |
835 | GNUNET_IDENTITY_public_key_to_string ( | 835 | GNUNET_CRYPTO_public_key_to_string ( |
836 | &del->issuer_key), | 836 | &del->issuer_key), |
837 | del->issuer_attribute, | 837 | del->issuer_attribute, |
838 | GNUNET_IDENTITY_public_key_to_string ( | 838 | GNUNET_CRYPTO_public_key_to_string ( |
839 | &del->subject_key), | 839 | &del->subject_key), |
840 | del->subject_attribute); | 840 | del->subject_attribute); |
841 | GNUNET_free (del); | 841 | GNUNET_free (del); |
@@ -849,10 +849,10 @@ forward_resolution (void *cls, | |||
849 | 849 | ||
850 | // Start: Credential Chain Entry | 850 | // Start: Credential Chain Entry |
851 | // issuer key is subject key, who needs to be contacted to resolve this (forward, therefore subject) | 851 | // issuer key is subject key, who needs to be contacted to resolve this (forward, therefore subject) |
852 | ds_entry->issuer_key = GNUNET_new (struct GNUNET_IDENTITY_PublicKey); | 852 | ds_entry->issuer_key = GNUNET_new (struct GNUNET_CRYPTO_PublicKey); |
853 | GNUNET_memcpy (ds_entry->issuer_key, | 853 | GNUNET_memcpy (ds_entry->issuer_key, |
854 | &del->subject_key, | 854 | &del->subject_key, |
855 | sizeof (struct GNUNET_IDENTITY_PublicKey)); | 855 | sizeof (struct GNUNET_CRYPTO_PublicKey)); |
856 | 856 | ||
857 | ds_entry->delegation_chain_entry = GNUNET_new (struct DelegationChainEntry); | 857 | ds_entry->delegation_chain_entry = GNUNET_new (struct DelegationChainEntry); |
858 | ds_entry->delegation_chain_entry->subject_key = del->subject_key; | 858 | ds_entry->delegation_chain_entry->subject_key = del->subject_key; |
@@ -873,7 +873,7 @@ forward_resolution (void *cls, | |||
873 | // if: issuer key we looking for | 873 | // if: issuer key we looking for |
874 | if (0 == memcmp (&del->issuer_key, | 874 | if (0 == memcmp (&del->issuer_key, |
875 | &vrh->issuer_key, | 875 | &vrh->issuer_key, |
876 | sizeof (struct GNUNET_IDENTITY_PublicKey))) | 876 | sizeof (struct GNUNET_CRYPTO_PublicKey))) |
877 | { | 877 | { |
878 | // if: issuer attr we looking for | 878 | // if: issuer attr we looking for |
879 | if (0 == strcmp (del->issuer_attribute, vrh->issuer_attribute)) | 879 | if (0 == strcmp (del->issuer_attribute, vrh->issuer_attribute)) |
@@ -904,7 +904,7 @@ forward_resolution (void *cls, | |||
904 | { | 904 | { |
905 | if (0 == memcmp (&del_entry->delegate->issuer_key, | 905 | if (0 == memcmp (&del_entry->delegate->issuer_key, |
906 | &vrh->delegation_chain_head->subject_key, | 906 | &vrh->delegation_chain_head->subject_key, |
907 | sizeof (struct GNUNET_IDENTITY_PublicKey))) | 907 | sizeof (struct GNUNET_CRYPTO_PublicKey))) |
908 | { | 908 | { |
909 | if (0 == strcmp (del_entry->delegate->issuer_attribute, | 909 | if (0 == strcmp (del_entry->delegate->issuer_attribute, |
910 | vrh->delegation_chain_head->subject_attribute)) | 910 | vrh->delegation_chain_head->subject_attribute)) |
@@ -932,7 +932,7 @@ forward_resolution (void *cls, | |||
932 | // key of list entry matches actual key | 932 | // key of list entry matches actual key |
933 | if (0 == memcmp (&del_entry->delegation_chain_entry->subject_key, | 933 | if (0 == memcmp (&del_entry->delegation_chain_entry->subject_key, |
934 | &ds_entry->delegation_chain_entry->issuer_key, | 934 | &ds_entry->delegation_chain_entry->issuer_key, |
935 | sizeof (struct GNUNET_IDENTITY_PublicKey))) | 935 | sizeof (struct GNUNET_CRYPTO_PublicKey))) |
936 | { | 936 | { |
937 | // compare entry subject attributes to this trailer (iss attr + old trailer) | 937 | // compare entry subject attributes to this trailer (iss attr + old trailer) |
938 | if (0 == strcmp (del_entry->unresolved_attribute_delegation, | 938 | if (0 == strcmp (del_entry->unresolved_attribute_delegation, |
@@ -962,7 +962,7 @@ forward_resolution (void *cls, | |||
962 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 962 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
963 | "Starting to look up trailer %s in zone %s\n", | 963 | "Starting to look up trailer %s in zone %s\n", |
964 | ds_entry->attr_trailer, | 964 | ds_entry->attr_trailer, |
965 | GNUNET_IDENTITY_public_key_to_string (&del->issuer_key)); | 965 | GNUNET_CRYPTO_public_key_to_string (&del->issuer_key)); |
966 | 966 | ||
967 | ds_entry->lookup_request = | 967 | ds_entry->lookup_request = |
968 | GNUNET_GNS_lookup (gns, | 968 | GNUNET_GNS_lookup (gns, |
@@ -1072,10 +1072,10 @@ backward_resolution (void *cls, | |||
1072 | ds_entry->delegation_chain_entry = | 1072 | ds_entry->delegation_chain_entry = |
1073 | GNUNET_new (struct DelegationChainEntry); | 1073 | GNUNET_new (struct DelegationChainEntry); |
1074 | ds_entry->delegation_chain_entry->subject_key = set[j].subject_key; | 1074 | ds_entry->delegation_chain_entry->subject_key = set[j].subject_key; |
1075 | ds_entry->issuer_key = GNUNET_new (struct GNUNET_IDENTITY_PublicKey); | 1075 | ds_entry->issuer_key = GNUNET_new (struct GNUNET_CRYPTO_PublicKey); |
1076 | GNUNET_memcpy (ds_entry->issuer_key, | 1076 | GNUNET_memcpy (ds_entry->issuer_key, |
1077 | &set[j].subject_key, | 1077 | &set[j].subject_key, |
1078 | sizeof (struct GNUNET_IDENTITY_PublicKey)); | 1078 | sizeof (struct GNUNET_CRYPTO_PublicKey)); |
1079 | if (0 < set[j].subject_attribute_len) | 1079 | if (0 < set[j].subject_attribute_len) |
1080 | ds_entry->delegation_chain_entry->subject_attribute = | 1080 | ds_entry->delegation_chain_entry->subject_attribute = |
1081 | GNUNET_strdup (set[j].subject_attribute); | 1081 | GNUNET_strdup (set[j].subject_attribute); |
@@ -1099,7 +1099,7 @@ backward_resolution (void *cls, | |||
1099 | // If key and attribute match credential: continue and backtrack | 1099 | // If key and attribute match credential: continue and backtrack |
1100 | if (0 != memcmp (&set[j].subject_key, | 1100 | if (0 != memcmp (&set[j].subject_key, |
1101 | &del_pointer->delegate->issuer_key, | 1101 | &del_pointer->delegate->issuer_key, |
1102 | sizeof (struct GNUNET_IDENTITY_PublicKey))) | 1102 | sizeof (struct GNUNET_CRYPTO_PublicKey))) |
1103 | continue; | 1103 | continue; |
1104 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1104 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1105 | "Checking if %s matches %s\n", | 1105 | "Checking if %s matches %s\n", |
@@ -1181,7 +1181,7 @@ backward_resolution (void *cls, | |||
1181 | // key of list entry matches actual key | 1181 | // key of list entry matches actual key |
1182 | if (0 == memcmp (&del_entry->delegation_chain_entry->issuer_key, | 1182 | if (0 == memcmp (&del_entry->delegation_chain_entry->issuer_key, |
1183 | &ds_entry->delegation_chain_entry->subject_key, | 1183 | &ds_entry->delegation_chain_entry->subject_key, |
1184 | sizeof (struct GNUNET_IDENTITY_PublicKey))) | 1184 | sizeof (struct GNUNET_CRYPTO_PublicKey))) |
1185 | { | 1185 | { |
1186 | // compare entry subject attributes to this trailer (iss attr + old trailer) | 1186 | // compare entry subject attributes to this trailer (iss attr + old trailer) |
1187 | if (0 == strcmp (del_entry->attr_trailer, | 1187 | if (0 == strcmp (del_entry->attr_trailer, |
@@ -1270,7 +1270,7 @@ delegation_chain_bw_resolution_start (void *cls) | |||
1270 | { | 1270 | { |
1271 | if (0 != memcmp (&del_entry->delegate->issuer_key, | 1271 | if (0 != memcmp (&del_entry->delegate->issuer_key, |
1272 | &vrh->issuer_key, | 1272 | &vrh->issuer_key, |
1273 | sizeof (struct GNUNET_IDENTITY_PublicKey))) | 1273 | sizeof (struct GNUNET_CRYPTO_PublicKey))) |
1274 | continue; | 1274 | continue; |
1275 | if (0 != | 1275 | if (0 != |
1276 | strcmp (del_entry->delegate->issuer_attribute, vrh->issuer_attribute)) | 1276 | strcmp (del_entry->delegate->issuer_attribute, vrh->issuer_attribute)) |
@@ -1292,10 +1292,10 @@ delegation_chain_bw_resolution_start (void *cls) | |||
1292 | ds_entry = GNUNET_new (struct DelegationSetQueueEntry); | 1292 | ds_entry = GNUNET_new (struct DelegationSetQueueEntry); |
1293 | GNUNET_CONTAINER_DLL_insert (vrh->dsq_head, vrh->dsq_tail, ds_entry); | 1293 | GNUNET_CONTAINER_DLL_insert (vrh->dsq_head, vrh->dsq_tail, ds_entry); |
1294 | ds_entry->from_bw = true; | 1294 | ds_entry->from_bw = true; |
1295 | ds_entry->issuer_key = GNUNET_new (struct GNUNET_IDENTITY_PublicKey); | 1295 | ds_entry->issuer_key = GNUNET_new (struct GNUNET_CRYPTO_PublicKey); |
1296 | GNUNET_memcpy (ds_entry->issuer_key, | 1296 | GNUNET_memcpy (ds_entry->issuer_key, |
1297 | &vrh->issuer_key, | 1297 | &vrh->issuer_key, |
1298 | sizeof (struct GNUNET_IDENTITY_PublicKey)); | 1298 | sizeof (struct GNUNET_CRYPTO_PublicKey)); |
1299 | ds_entry->issuer_attribute = GNUNET_strdup (vrh->issuer_attribute); | 1299 | ds_entry->issuer_attribute = GNUNET_strdup (vrh->issuer_attribute); |
1300 | 1300 | ||
1301 | ds_entry->delegation_chain_entry = GNUNET_new (struct DelegationChainEntry); | 1301 | ds_entry->delegation_chain_entry = GNUNET_new (struct DelegationChainEntry); |
@@ -1352,7 +1352,7 @@ delegation_chain_fw_resolution_start (void *cls) | |||
1352 | { | 1352 | { |
1353 | if (0 != memcmp (&del_entry->delegate->issuer_key, | 1353 | if (0 != memcmp (&del_entry->delegate->issuer_key, |
1354 | &vrh->issuer_key, | 1354 | &vrh->issuer_key, |
1355 | sizeof (struct GNUNET_IDENTITY_PublicKey))) | 1355 | sizeof (struct GNUNET_CRYPTO_PublicKey))) |
1356 | continue; | 1356 | continue; |
1357 | if (0 != | 1357 | if (0 != |
1358 | strcmp (del_entry->delegate->issuer_attribute, vrh->issuer_attribute)) | 1358 | strcmp (del_entry->delegate->issuer_attribute, vrh->issuer_attribute)) |
@@ -1374,17 +1374,17 @@ delegation_chain_fw_resolution_start (void *cls) | |||
1374 | 1374 | ||
1375 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1375 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1376 | "Looking for %s.%s\n", | 1376 | "Looking for %s.%s\n", |
1377 | GNUNET_IDENTITY_public_key_to_string ( | 1377 | GNUNET_CRYPTO_public_key_to_string ( |
1378 | &del_entry->delegate->issuer_key), | 1378 | &del_entry->delegate->issuer_key), |
1379 | del_entry->delegate->issuer_attribute); | 1379 | del_entry->delegate->issuer_attribute); |
1380 | 1380 | ||
1381 | ds_entry = GNUNET_new (struct DelegationSetQueueEntry); | 1381 | ds_entry = GNUNET_new (struct DelegationSetQueueEntry); |
1382 | GNUNET_CONTAINER_DLL_insert (vrh->dsq_head, vrh->dsq_tail, ds_entry); | 1382 | GNUNET_CONTAINER_DLL_insert (vrh->dsq_head, vrh->dsq_tail, ds_entry); |
1383 | ds_entry->from_bw = false; | 1383 | ds_entry->from_bw = false; |
1384 | ds_entry->issuer_key = GNUNET_new (struct GNUNET_IDENTITY_PublicKey); | 1384 | ds_entry->issuer_key = GNUNET_new (struct GNUNET_CRYPTO_PublicKey); |
1385 | GNUNET_memcpy (ds_entry->issuer_key, | 1385 | GNUNET_memcpy (ds_entry->issuer_key, |
1386 | &del_entry->delegate->subject_key, | 1386 | &del_entry->delegate->subject_key, |
1387 | sizeof (struct GNUNET_IDENTITY_PublicKey)); | 1387 | sizeof (struct GNUNET_CRYPTO_PublicKey)); |
1388 | 1388 | ||
1389 | ds_entry->delegation_chain_entry = GNUNET_new (struct DelegationChainEntry); | 1389 | ds_entry->delegation_chain_entry = GNUNET_new (struct DelegationChainEntry); |
1390 | ds_entry->delegation_chain_entry->subject_key = | 1390 | ds_entry->delegation_chain_entry->subject_key = |
@@ -1588,7 +1588,7 @@ delegate_collection_finished (void *cls) | |||
1588 | 1588 | ||
1589 | static void | 1589 | static void |
1590 | handle_delegate_collection_cb (void *cls, | 1590 | handle_delegate_collection_cb (void *cls, |
1591 | const struct GNUNET_IDENTITY_PrivateKey *key, | 1591 | const struct GNUNET_CRYPTO_PrivateKey *key, |
1592 | const char *label, | 1592 | const char *label, |
1593 | unsigned int rd_count, | 1593 | unsigned int rd_count, |
1594 | const struct GNUNET_GNSRECORD_Data *rd) | 1594 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1646,7 +1646,7 @@ handle_collect (void *cls, const struct CollectMessage *c_msg) | |||
1646 | vrh->client = client; | 1646 | vrh->client = client; |
1647 | vrh->request_id = c_msg->id; | 1647 | vrh->request_id = c_msg->id; |
1648 | vrh->issuer_key = c_msg->issuer_key; | 1648 | vrh->issuer_key = c_msg->issuer_key; |
1649 | GNUNET_IDENTITY_key_get_public (&c_msg->subject_key, &vrh->subject_key); | 1649 | GNUNET_CRYPTO_key_get_public (&c_msg->subject_key, &vrh->subject_key); |
1650 | vrh->issuer_attribute = GNUNET_strdup (issuer_attribute); | 1650 | vrh->issuer_attribute = GNUNET_strdup (issuer_attribute); |
1651 | vrh->resolution_algo = ntohs (c_msg->resolution_algo); | 1651 | vrh->resolution_algo = ntohs (c_msg->resolution_algo); |
1652 | 1652 | ||
diff --git a/src/abd/plugin_gnsrecord_abd.c b/src/abd/plugin_gnsrecord_abd.c index 7b2f4af5b..43abe578f 100644 --- a/src/abd/plugin_gnsrecord_abd.c +++ b/src/abd/plugin_gnsrecord_abd.c | |||
@@ -77,7 +77,7 @@ abd_value_to_string (void *cls, | |||
77 | for (i = 0; i < ntohl (sets.set_count); i++) | 77 | for (i = 0; i < ntohl (sets.set_count); i++) |
78 | { | 78 | { |
79 | subject_pkey = | 79 | subject_pkey = |
80 | GNUNET_IDENTITY_public_key_to_string (&set[i].subject_key); | 80 | GNUNET_CRYPTO_public_key_to_string (&set[i].subject_key); |
81 | 81 | ||
82 | if (0 == set[i].subject_attribute_len) | 82 | if (0 == set[i].subject_attribute_len) |
83 | { | 83 | { |
@@ -208,7 +208,7 @@ abd_string_to_value (void *cls, | |||
208 | 208 | ||
209 | // sets the public key for the set entry | 209 | // sets the public key for the set entry |
210 | if (GNUNET_SYSERR == | 210 | if (GNUNET_SYSERR == |
211 | GNUNET_IDENTITY_public_key_from_string (subject_pkey, | 211 | GNUNET_CRYPTO_public_key_from_string (subject_pkey, |
212 | &set[i].subject_key)) | 212 | &set[i].subject_key)) |
213 | { | 213 | { |
214 | GNUNET_free (tmp_str); | 214 | GNUNET_free (tmp_str); |
diff --git a/src/arm/Makefile.am b/src/arm/Makefile.am index 8a738c5a9..6ecc7ca7a 100644 --- a/src/arm/Makefile.am +++ b/src/arm/Makefile.am | |||
@@ -18,7 +18,7 @@ lib_LTLIBRARIES = libgnunetarm.la | |||
18 | libgnunetarm_la_SOURCES = \ | 18 | libgnunetarm_la_SOURCES = \ |
19 | arm_api.c arm_monitor_api.c arm.h | 19 | arm_api.c arm_monitor_api.c arm.h |
20 | libgnunetarm_la_LIBADD = \ | 20 | libgnunetarm_la_LIBADD = \ |
21 | $(top_builddir)/src/util/libgnunetutil.la \ | 21 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
22 | $(GN_LIBINTL) $(XLIB) | 22 | $(GN_LIBINTL) $(XLIB) |
23 | libgnunetarm_la_LDFLAGS = \ | 23 | libgnunetarm_la_LDFLAGS = \ |
24 | $(GN_LIB_LDFLAGS) \ | 24 | $(GN_LIB_LDFLAGS) \ |
@@ -38,19 +38,19 @@ gnunet_arm_SOURCES = \ | |||
38 | gnunet-arm.c | 38 | gnunet-arm.c |
39 | gnunet_arm_LDADD = \ | 39 | gnunet_arm_LDADD = \ |
40 | libgnunetarm.la \ | 40 | libgnunetarm.la \ |
41 | $(top_builddir)/src/util/libgnunetutil.la \ | 41 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
42 | $(GN_LIBINTL) | 42 | $(GN_LIBINTL) |
43 | 43 | ||
44 | gnunet_service_arm_SOURCES = \ | 44 | gnunet_service_arm_SOURCES = \ |
45 | gnunet-service-arm.c | 45 | gnunet-service-arm.c |
46 | gnunet_service_arm_LDADD = \ | 46 | gnunet_service_arm_LDADD = \ |
47 | $(top_builddir)/src/util/libgnunetutil.la \ | 47 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
48 | $(GN_LIBINTL) | 48 | $(GN_LIBINTL) |
49 | 49 | ||
50 | mockup_service_SOURCES = \ | 50 | mockup_service_SOURCES = \ |
51 | mockup-service.c | 51 | mockup-service.c |
52 | mockup_service_LDADD = \ | 52 | mockup_service_LDADD = \ |
53 | $(top_builddir)/src/util/libgnunetutil.la | 53 | $(top_builddir)/src/lib/util/libgnunetutil.la |
54 | mockup_service_LDFLAGS = \ | 54 | mockup_service_LDFLAGS = \ |
55 | $(GN_LIBINTL) | 55 | $(GN_LIBINTL) |
56 | 56 | ||
@@ -74,19 +74,19 @@ test_arm_api_SOURCES = \ | |||
74 | test_arm_api.c | 74 | test_arm_api.c |
75 | test_arm_api_LDADD = \ | 75 | test_arm_api_LDADD = \ |
76 | libgnunetarm.la \ | 76 | libgnunetarm.la \ |
77 | $(top_builddir)/src/util/libgnunetutil.la | 77 | $(top_builddir)/src/lib/util/libgnunetutil.la |
78 | 78 | ||
79 | test_exponential_backoff_SOURCES = \ | 79 | test_exponential_backoff_SOURCES = \ |
80 | test_exponential_backoff.c | 80 | test_exponential_backoff.c |
81 | test_exponential_backoff_LDADD = \ | 81 | test_exponential_backoff_LDADD = \ |
82 | libgnunetarm.la \ | 82 | libgnunetarm.la \ |
83 | $(top_builddir)/src/util/libgnunetutil.la | 83 | $(top_builddir)/src/lib/util/libgnunetutil.la |
84 | 84 | ||
85 | test_gnunet_service_arm_SOURCES = \ | 85 | test_gnunet_service_arm_SOURCES = \ |
86 | test_gnunet_service_arm.c | 86 | test_gnunet_service_arm.c |
87 | test_gnunet_service_arm_LDADD = \ | 87 | test_gnunet_service_arm_LDADD = \ |
88 | libgnunetarm.la \ | 88 | libgnunetarm.la \ |
89 | $(top_builddir)/src/util/libgnunetutil.la | 89 | $(top_builddir)/src/lib/util/libgnunetutil.la |
90 | 90 | ||
91 | SUFFIXES = .py.in .py | 91 | SUFFIXES = .py.in .py |
92 | .py.in.py: | 92 | .py.in.py: |
diff --git a/src/auction/Makefile.am b/src/auction/Makefile.am index 0cb5d5a84..ec0ffaf33 100644 --- a/src/auction/Makefile.am +++ b/src/auction/Makefile.am | |||
@@ -20,7 +20,7 @@ libexec_PROGRAMS = \ | |||
20 | gnunet_service_auction_SOURCES = \ | 20 | gnunet_service_auction_SOURCES = \ |
21 | gnunet-service-auction.c | 21 | gnunet-service-auction.c |
22 | gnunet_service_auction_LDADD = \ | 22 | gnunet_service_auction_LDADD = \ |
23 | $(top_builddir)/src/util/libgnunetutil.la \ | 23 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
24 | -ljansson \ | 24 | -ljansson \ |
25 | $(GN_LIBINTL) | 25 | $(GN_LIBINTL) |
26 | 26 | ||
@@ -33,21 +33,21 @@ bin_PROGRAMS = \ | |||
33 | gnunet_auction_create_SOURCES = \ | 33 | gnunet_auction_create_SOURCES = \ |
34 | gnunet-auction-create.c | 34 | gnunet-auction-create.c |
35 | gnunet_auction_create_LDADD = \ | 35 | gnunet_auction_create_LDADD = \ |
36 | $(top_builddir)/src/util/libgnunetutil.la \ | 36 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
37 | -ljansson \ | 37 | -ljansson \ |
38 | $(GN_LIBINTL) | 38 | $(GN_LIBINTL) |
39 | 39 | ||
40 | gnunet_auction_info_SOURCES = \ | 40 | gnunet_auction_info_SOURCES = \ |
41 | gnunet-auction-info.c | 41 | gnunet-auction-info.c |
42 | gnunet_auction_info_LDADD = \ | 42 | gnunet_auction_info_LDADD = \ |
43 | $(top_builddir)/src/util/libgnunetutil.la \ | 43 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
44 | -ljansson \ | 44 | -ljansson \ |
45 | $(GN_LIBINTL) | 45 | $(GN_LIBINTL) |
46 | 46 | ||
47 | gnunet_auction_join_SOURCES = \ | 47 | gnunet_auction_join_SOURCES = \ |
48 | gnunet-auction-join.c | 48 | gnunet-auction-join.c |
49 | gnunet_auction_join_LDADD = \ | 49 | gnunet_auction_join_LDADD = \ |
50 | $(top_builddir)/src/util/libgnunetutil.la \ | 50 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
51 | -ljansson \ | 51 | -ljansson \ |
52 | $(GN_LIBINTL) | 52 | $(GN_LIBINTL) |
53 | 53 | ||
@@ -58,7 +58,7 @@ check_PROGRAMS = \ | |||
58 | test_auction_api_SOURCES = \ | 58 | test_auction_api_SOURCES = \ |
59 | test_auction_api.c | 59 | test_auction_api.c |
60 | test_auction_api_LDADD = \ | 60 | test_auction_api_LDADD = \ |
61 | $(top_builddir)/src/util/libgnunetutil.la | 61 | $(top_builddir)/src/lib/util/libgnunetutil.la |
62 | 62 | ||
63 | 63 | ||
64 | check_SCRIPTS = \ | 64 | check_SCRIPTS = \ |
diff --git a/src/cadet/Makefile.am b/src/cadet/Makefile.am index 3f1c79de0..b28286197 100644 --- a/src/cadet/Makefile.am +++ b/src/cadet/Makefile.am | |||
@@ -35,7 +35,7 @@ libgnunetcadet_la_SOURCES = \ | |||
35 | cadet_api_list_tunnels.c \ | 35 | cadet_api_list_tunnels.c \ |
36 | cadet_api_helper.c | 36 | cadet_api_helper.c |
37 | libgnunetcadet_la_LIBADD = \ | 37 | libgnunetcadet_la_LIBADD = \ |
38 | $(top_builddir)/src/util/libgnunetutil.la \ | 38 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
39 | $(XLIB) \ | 39 | $(XLIB) \ |
40 | $(LTLIBINTL) | 40 | $(LTLIBINTL) |
41 | libgnunetcadet_la_LDFLAGS = \ | 41 | libgnunetcadet_la_LDFLAGS = \ |
@@ -46,7 +46,7 @@ gnunet_cadet_SOURCES = \ | |||
46 | gnunet-cadet.c | 46 | gnunet-cadet.c |
47 | gnunet_cadet_LDADD = \ | 47 | gnunet_cadet_LDADD = \ |
48 | libgnunetcadet.la \ | 48 | libgnunetcadet.la \ |
49 | $(top_builddir)/src/util/libgnunetutil.la | 49 | $(top_builddir)/src/lib/util/libgnunetutil.la |
50 | gnunet_cadet_LDFLAGS = \ | 50 | gnunet_cadet_LDFLAGS = \ |
51 | $(GN_LIBINTL) | 51 | $(GN_LIBINTL) |
52 | 52 | ||
@@ -61,14 +61,14 @@ gnunet_service_cadet_SOURCES = \ | |||
61 | gnunet-service-cadet_paths.c gnunet-service-cadet_paths.h \ | 61 | gnunet-service-cadet_paths.c gnunet-service-cadet_paths.h \ |
62 | gnunet-service-cadet_peer.c gnunet-service-cadet_peer.h | 62 | gnunet-service-cadet_peer.c gnunet-service-cadet_peer.h |
63 | gnunet_service_cadet_LDADD = \ | 63 | gnunet_service_cadet_LDADD = \ |
64 | $(top_builddir)/src/util/libgnunetutil.la \ | 64 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
65 | $(top_builddir)/src/core/libgnunetcore.la \ | 65 | $(top_builddir)/src/core/libgnunetcore.la \ |
66 | $(top_builddir)/src/dht/libgnunetdht.la \ | 66 | $(top_builddir)/src/dht/libgnunetdht.la \ |
67 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 67 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
68 | $(top_builddir)/src/transport/libgnunettransportapplication.la \ | 68 | $(top_builddir)/src/transport/libgnunettransportapplication.la \ |
69 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 69 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
70 | $(top_builddir)/src/hello/libgnunethello.la \ | 70 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
71 | $(top_builddir)/src/block/libgnunetblock.la | 71 | $(top_builddir)/src/lib/block/libgnunetblock.la |
72 | if LINUX | 72 | if LINUX |
73 | gnunet_service_cadet_LDFLAGS = -lrt \ | 73 | gnunet_service_cadet_LDFLAGS = -lrt \ |
74 | $(GN_LIBINTL) | 74 | $(GN_LIBINTL) |
@@ -80,7 +80,7 @@ test_cadet_local_mq_SOURCES = \ | |||
80 | test_cadet_local_mq_LDADD = \ | 80 | test_cadet_local_mq_LDADD = \ |
81 | libgnunetcadet.la \ | 81 | libgnunetcadet.la \ |
82 | $(top_builddir)/src/testing/libgnunettesting.la \ | 82 | $(top_builddir)/src/testing/libgnunettesting.la \ |
83 | $(top_builddir)/src/util/libgnunetutil.la | 83 | $(top_builddir)/src/lib/util/libgnunetutil.la |
84 | 84 | ||
85 | if ENABLE_TEST_RUN | 85 | if ENABLE_TEST_RUN |
86 | AM_TESTS_ENVIRONMENT=export GNUNET_PREFIX=$${GNUNET_PREFIX:-@libdir@};export PATH=$${GNUNET_PREFIX:-@prefix@}/bin:$$PATH;unset XDG_DATA_HOME;unset XDG_CONFIG_HOME; | 86 | AM_TESTS_ENVIRONMENT=export GNUNET_PREFIX=$${GNUNET_PREFIX:-@libdir@};export PATH=$${GNUNET_PREFIX:-@prefix@}/bin:$$PATH;unset XDG_DATA_HOME;unset XDG_CONFIG_HOME; |
diff --git a/src/cli/Makefile.am b/src/cli/Makefile.am new file mode 100644 index 000000000..d94046cde --- /dev/null +++ b/src/cli/Makefile.am | |||
@@ -0,0 +1,2 @@ | |||
1 | SUBDIRS = \ | ||
2 | util | ||
diff --git a/src/cli/util/.gitignore b/src/cli/util/.gitignore new file mode 100644 index 000000000..9e045f16f --- /dev/null +++ b/src/cli/util/.gitignore | |||
@@ -0,0 +1,10 @@ | |||
1 | gnunet-config | ||
2 | gnunet-config-diff | ||
3 | gnunet-crypto-tvg | ||
4 | gnunet-ecc | ||
5 | gnunet-qr | ||
6 | gnunet-resolver | ||
7 | gnunet-scrypt | ||
8 | gnunet-uri | ||
9 | gnunet-base32 | ||
10 | gnunet-timeout | ||
diff --git a/src/cli/util/Makefile.am b/src/cli/util/Makefile.am new file mode 100644 index 000000000..cac477e13 --- /dev/null +++ b/src/cli/util/Makefile.am | |||
@@ -0,0 +1,108 @@ | |||
1 | # This Makefile.am is in the public domain | ||
2 | AM_CPPFLAGS = -I$(top_srcdir)/src/include | ||
3 | |||
4 | plugindir = $(libdir)/gnunet | ||
5 | |||
6 | libexecdir= $(pkglibdir)/libexec/ | ||
7 | |||
8 | pkgcfgdir= $(pkgdatadir)/config.d/ | ||
9 | |||
10 | if USE_COVERAGE | ||
11 | AM_CFLAGS = --coverage -O0 | ||
12 | XLIB = -lgcov | ||
13 | endif | ||
14 | |||
15 | gnunet_config_diff_SOURCES = \ | ||
16 | gnunet-config-diff.c | ||
17 | gnunet_config_diff_LDADD = \ | ||
18 | $(top_builddir)/src/lib/util/libgnunetutil.la | ||
19 | |||
20 | GNUNET_ECC = gnunet-ecc | ||
21 | GNUNET_SCRYPT = gnunet-scrypt | ||
22 | |||
23 | libexec_PROGRAMS = \ | ||
24 | gnunet-timeout | ||
25 | |||
26 | bin_PROGRAMS = \ | ||
27 | gnunet-base32 \ | ||
28 | gnunet-config \ | ||
29 | gnunet-resolver \ | ||
30 | $(GNUNET_ECC) \ | ||
31 | $(GNUNET_SCRYPT) \ | ||
32 | gnunet-uri | ||
33 | if HAVE_ZBAR | ||
34 | bin_PROGRAMS += gnunet-qr | ||
35 | endif | ||
36 | |||
37 | noinst_PROGRAMS = \ | ||
38 | gnunet-config-diff \ | ||
39 | gnunet-crypto-tvg | ||
40 | |||
41 | if ENABLE_TEST_RUN | ||
42 | AM_TESTS_ENVIRONMENT=export GNUNET_PREFIX=$${GNUNET_PREFIX:-@libdir@};export PATH=$${GNUNET_PREFIX:-@prefix@}/bin:$$PATH;unset XDG_DATA_HOME;unset XDG_CONFIG_HOME; | ||
43 | TESTS = $(check_PROGRAMS) $(check_SCRIPTS) | ||
44 | endif | ||
45 | |||
46 | gnunet_timeout_SOURCES = \ | ||
47 | gnunet-timeout.c | ||
48 | |||
49 | gnunet_resolver_SOURCES = \ | ||
50 | gnunet-resolver.c | ||
51 | gnunet_resolver_LDADD = \ | ||
52 | $(top_builddir)/src/lib/util/libgnunetutil.la \ | ||
53 | $(GN_LIBINTL) | ||
54 | |||
55 | gnunet_crypto_tvg_SOURCES = \ | ||
56 | gnunet-crypto-tvg.c | ||
57 | gnunet_crypto_tvg_LDADD = \ | ||
58 | $(top_builddir)/src/lib/util/libgnunetutil.la \ | ||
59 | $(GN_LIBINTL) -lgcrypt -ljansson | ||
60 | |||
61 | gnunet_ecc_SOURCES = \ | ||
62 | gnunet-ecc.c | ||
63 | gnunet_ecc_LDADD = \ | ||
64 | $(top_builddir)/src/lib/util/libgnunetutil.la \ | ||
65 | $(GN_LIBINTL) -lgcrypt | ||
66 | |||
67 | gnunet_base32_SOURCES = \ | ||
68 | gnunet-base32.c | ||
69 | gnunet_base32_LDADD = \ | ||
70 | $(top_builddir)/src/lib/util/libgnunetutil.la \ | ||
71 | $(GN_LIBINTL) | ||
72 | |||
73 | gnunet_scrypt_SOURCES = \ | ||
74 | gnunet-scrypt.c | ||
75 | gnunet_scrypt_LDADD = \ | ||
76 | $(top_builddir)/src/lib/util/libgnunetutil.la \ | ||
77 | $(GN_LIBINTL) -lgcrypt | ||
78 | |||
79 | |||
80 | gnunet_config_SOURCES = \ | ||
81 | gnunet-config.c | ||
82 | gnunet_config_LDADD = \ | ||
83 | $(top_builddir)/src/lib/util/libgnunetutil.la \ | ||
84 | $(GN_LIBINTL) | ||
85 | |||
86 | gnunet_uri_SOURCES = \ | ||
87 | gnunet-uri.c | ||
88 | gnunet_uri_LDADD = \ | ||
89 | $(top_builddir)/src/lib/util/libgnunetutil.la \ | ||
90 | $(GN_LIBINTL) | ||
91 | |||
92 | |||
93 | gnunet_qr_SOURCES = \ | ||
94 | gnunet-qr.c | ||
95 | gnunet_qr_LDADD = \ | ||
96 | $(top_builddir)/src/lib/util/libgnunetutil.la \ | ||
97 | $(GN_LIBINTL) | ||
98 | gnunet_qr_LDFLAGS= -lzbar | ||
99 | if HAVE_PNG | ||
100 | gnunet_qr_LDFLAGS += -lpng | ||
101 | endif | ||
102 | |||
103 | check_SCRIPTS = \ | ||
104 | test_crypto_vectors.sh | ||
105 | |||
106 | EXTRA_DIST = \ | ||
107 | test_crypto_vectors.sh \ | ||
108 | crypto-test-vectors.json | ||
diff --git a/src/util/crypto-test-vectors.json b/src/cli/util/crypto-test-vectors.json index 972b62c3e..972b62c3e 100644 --- a/src/util/crypto-test-vectors.json +++ b/src/cli/util/crypto-test-vectors.json | |||
diff --git a/src/util/gnunet-base32.c b/src/cli/util/gnunet-base32.c index 209741740..209741740 100644 --- a/src/util/gnunet-base32.c +++ b/src/cli/util/gnunet-base32.c | |||
diff --git a/src/util/gnunet-config-diff.c b/src/cli/util/gnunet-config-diff.c index e1e3ffd5d..e1e3ffd5d 100644 --- a/src/util/gnunet-config-diff.c +++ b/src/cli/util/gnunet-config-diff.c | |||
diff --git a/src/util/gnunet-config.c b/src/cli/util/gnunet-config.c index 714c683dd..714c683dd 100644 --- a/src/util/gnunet-config.c +++ b/src/cli/util/gnunet-config.c | |||
diff --git a/src/util/gnunet-crypto-tvg.c b/src/cli/util/gnunet-crypto-tvg.c index 5a16bb8fc..5a16bb8fc 100644 --- a/src/util/gnunet-crypto-tvg.c +++ b/src/cli/util/gnunet-crypto-tvg.c | |||
diff --git a/src/util/gnunet-ecc.c b/src/cli/util/gnunet-ecc.c index 812745085..812745085 100644 --- a/src/util/gnunet-ecc.c +++ b/src/cli/util/gnunet-ecc.c | |||
diff --git a/src/util/gnunet-qr.c b/src/cli/util/gnunet-qr.c index d9b873c05..d9b873c05 100644 --- a/src/util/gnunet-qr.c +++ b/src/cli/util/gnunet-qr.c | |||
diff --git a/src/util/gnunet-resolver.c b/src/cli/util/gnunet-resolver.c index a23aeb4aa..a23aeb4aa 100644 --- a/src/util/gnunet-resolver.c +++ b/src/cli/util/gnunet-resolver.c | |||
diff --git a/src/util/gnunet-scrypt.c b/src/cli/util/gnunet-scrypt.c index 3d1b9c017..3d1b9c017 100644 --- a/src/util/gnunet-scrypt.c +++ b/src/cli/util/gnunet-scrypt.c | |||
diff --git a/src/util/gnunet-timeout.c b/src/cli/util/gnunet-timeout.c index 1d3002c08..1d3002c08 100644 --- a/src/util/gnunet-timeout.c +++ b/src/cli/util/gnunet-timeout.c | |||
diff --git a/src/util/gnunet-uri.c b/src/cli/util/gnunet-uri.c index 128167cc5..128167cc5 100644 --- a/src/util/gnunet-uri.c +++ b/src/cli/util/gnunet-uri.c | |||
diff --git a/src/util/test_crypto_vectors.sh b/src/cli/util/test_crypto_vectors.sh index 40700a324..40700a324 100755 --- a/src/util/test_crypto_vectors.sh +++ b/src/cli/util/test_crypto_vectors.sh | |||
diff --git a/src/consensus/Makefile.am b/src/consensus/Makefile.am index 49d111538..a88b8bc60 100644 --- a/src/consensus/Makefile.am +++ b/src/consensus/Makefile.am | |||
@@ -38,7 +38,7 @@ lib_LTLIBRARIES = \ | |||
38 | gnunet_service_consensus_SOURCES = \ | 38 | gnunet_service_consensus_SOURCES = \ |
39 | gnunet-service-consensus.c | 39 | gnunet-service-consensus.c |
40 | gnunet_service_consensus_LDADD = \ | 40 | gnunet_service_consensus_LDADD = \ |
41 | $(top_builddir)/src/util/libgnunetutil.la \ | 41 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
42 | $(top_builddir)/src/core/libgnunetcore.la \ | 42 | $(top_builddir)/src/core/libgnunetcore.la \ |
43 | $(top_builddir)/src/set/libgnunetset.la \ | 43 | $(top_builddir)/src/set/libgnunetset.la \ |
44 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 44 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
@@ -48,7 +48,7 @@ gnunet_service_evil_consensus_SOURCES = \ | |||
48 | gnunet-service-consensus.c \ | 48 | gnunet-service-consensus.c \ |
49 | consensus_protocol.h | 49 | consensus_protocol.h |
50 | gnunet_service_evil_consensus_LDADD = \ | 50 | gnunet_service_evil_consensus_LDADD = \ |
51 | $(top_builddir)/src/util/libgnunetutil.la \ | 51 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
52 | $(top_builddir)/src/core/libgnunetcore.la \ | 52 | $(top_builddir)/src/core/libgnunetcore.la \ |
53 | $(top_builddir)/src/set/libgnunetset.la \ | 53 | $(top_builddir)/src/set/libgnunetset.la \ |
54 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 54 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
@@ -59,7 +59,7 @@ libgnunetconsensus_la_SOURCES = \ | |||
59 | consensus_api.c \ | 59 | consensus_api.c \ |
60 | consensus.h | 60 | consensus.h |
61 | libgnunetconsensus_la_LIBADD = \ | 61 | libgnunetconsensus_la_LIBADD = \ |
62 | $(top_builddir)/src/util/libgnunetutil.la \ | 62 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
63 | $(LTLIBINTL) | 63 | $(LTLIBINTL) |
64 | libgnunetconsensus_la_LDFLAGS = \ | 64 | libgnunetconsensus_la_LDFLAGS = \ |
65 | $(GN_LIB_LDFLAGS) | 65 | $(GN_LIB_LDFLAGS) |
@@ -71,9 +71,9 @@ plugin_LTLIBRARIES = \ | |||
71 | libgnunet_plugin_block_consensus_la_SOURCES = \ | 71 | libgnunet_plugin_block_consensus_la_SOURCES = \ |
72 | plugin_block_consensus.c | 72 | plugin_block_consensus.c |
73 | libgnunet_plugin_block_consensus_la_LIBADD = \ | 73 | libgnunet_plugin_block_consensus_la_LIBADD = \ |
74 | $(top_builddir)/src/block/libgnunetblock.la \ | 74 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
75 | $(top_builddir)/src/block/libgnunetblockgroup.la \ | 75 | $(top_builddir)/src/lib/block/libgnunetblockgroup.la \ |
76 | $(top_builddir)/src/util/libgnunetutil.la \ | 76 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
77 | $(LTLIBINTL) | 77 | $(LTLIBINTL) |
78 | libgnunet_plugin_block_consensus_la_LDFLAGS = \ | 78 | libgnunet_plugin_block_consensus_la_LDFLAGS = \ |
79 | $(GN_PLUGIN_LDFLAGS) | 79 | $(GN_PLUGIN_LDFLAGS) |
@@ -91,7 +91,7 @@ endif | |||
91 | test_consensus_api_SOURCES = \ | 91 | test_consensus_api_SOURCES = \ |
92 | test_consensus_api.c | 92 | test_consensus_api.c |
93 | test_consensus_api_LDADD = \ | 93 | test_consensus_api_LDADD = \ |
94 | $(top_builddir)/src/util/libgnunetutil.la \ | 94 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
95 | $(top_builddir)/src/testing/libgnunettesting.la \ | 95 | $(top_builddir)/src/testing/libgnunettesting.la \ |
96 | libgnunetconsensus.la | 96 | libgnunetconsensus.la |
97 | 97 | ||
diff --git a/src/conversation/Makefile.am b/src/conversation/Makefile.am index 0f99a6526..0b8a34d36 100644 --- a/src/conversation/Makefile.am +++ b/src/conversation/Makefile.am | |||
@@ -41,7 +41,7 @@ plugin_LTLIBRARIES = \ | |||
41 | libgnunet_plugin_gnsrecord_conversation_la_SOURCES = \ | 41 | libgnunet_plugin_gnsrecord_conversation_la_SOURCES = \ |
42 | plugin_gnsrecord_conversation.c | 42 | plugin_gnsrecord_conversation.c |
43 | libgnunet_plugin_gnsrecord_conversation_la_LIBADD = \ | 43 | libgnunet_plugin_gnsrecord_conversation_la_LIBADD = \ |
44 | $(top_builddir)/src/util/libgnunetutil.la \ | 44 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
45 | $(LTLIBINTL) | 45 | $(LTLIBINTL) |
46 | libgnunet_plugin_gnsrecord_conversation_la_LDFLAGS = \ | 46 | libgnunet_plugin_gnsrecord_conversation_la_LDFLAGS = \ |
47 | $(GN_PLUGIN_LDFLAGS) | 47 | $(GN_PLUGIN_LDFLAGS) |
@@ -50,7 +50,7 @@ libgnunet_plugin_gnsrecord_conversation_la_LDFLAGS = \ | |||
50 | libgnunetmicrophone_la_SOURCES = \ | 50 | libgnunetmicrophone_la_SOURCES = \ |
51 | microphone.c | 51 | microphone.c |
52 | libgnunetmicrophone_la_LIBADD = \ | 52 | libgnunetmicrophone_la_LIBADD = \ |
53 | $(top_builddir)/src/util/libgnunetutil.la | 53 | $(top_builddir)/src/lib/util/libgnunetutil.la |
54 | libgnunetmicrophone_la_LDFLAGS = \ | 54 | libgnunetmicrophone_la_LDFLAGS = \ |
55 | $(GN_LIB_LDFLAGS) \ | 55 | $(GN_LIB_LDFLAGS) \ |
56 | -version-info 0:0:0 | 56 | -version-info 0:0:0 |
@@ -58,7 +58,7 @@ libgnunetmicrophone_la_LDFLAGS = \ | |||
58 | libgnunetspeaker_la_SOURCES = \ | 58 | libgnunetspeaker_la_SOURCES = \ |
59 | speaker.c | 59 | speaker.c |
60 | libgnunetspeaker_la_LIBADD = \ | 60 | libgnunetspeaker_la_LIBADD = \ |
61 | $(top_builddir)/src/util/libgnunetutil.la | 61 | $(top_builddir)/src/lib/util/libgnunetutil.la |
62 | libgnunetspeaker_la_LDFLAGS = \ | 62 | libgnunetspeaker_la_LDFLAGS = \ |
63 | $(GN_LIB_LDFLAGS) \ | 63 | $(GN_LIB_LDFLAGS) \ |
64 | -version-info 0:0:0 | 64 | -version-info 0:0:0 |
@@ -70,10 +70,10 @@ libgnunetconversation_la_SOURCES = \ | |||
70 | conversation.h | 70 | conversation.h |
71 | libgnunetconversation_la_LIBADD = \ | 71 | libgnunetconversation_la_LIBADD = \ |
72 | $(top_builddir)/src/gns/libgnunetgns.la \ | 72 | $(top_builddir)/src/gns/libgnunetgns.la \ |
73 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 73 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
74 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 74 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
75 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 75 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
76 | $(top_builddir)/src/util/libgnunetutil.la | 76 | $(top_builddir)/src/lib/util/libgnunetutil.la |
77 | 77 | ||
78 | libgnunetconversation_la_LDFLAGS = \ | 78 | libgnunetconversation_la_LDFLAGS = \ |
79 | $(GN_LIB_LDFLAGS) \ | 79 | $(GN_LIB_LDFLAGS) \ |
@@ -113,7 +113,7 @@ if BUILD_PULSE_HELPERS | |||
113 | gnunet_helper_audio_record_SOURCES = \ | 113 | gnunet_helper_audio_record_SOURCES = \ |
114 | gnunet-helper-audio-record.c | 114 | gnunet-helper-audio-record.c |
115 | gnunet_helper_audio_record_LDADD = \ | 115 | gnunet_helper_audio_record_LDADD = \ |
116 | $(top_builddir)/src/util/libgnunetutil.la \ | 116 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
117 | -lpulse -lopus -logg \ | 117 | -lpulse -lopus -logg \ |
118 | $(INTLLIBS) | 118 | $(INTLLIBS) |
119 | #gnunet_helper_audio_record_LDFLAGS = \ | 119 | #gnunet_helper_audio_record_LDFLAGS = \ |
@@ -122,7 +122,7 @@ gnunet_helper_audio_record_LDADD = \ | |||
122 | gnunet_helper_audio_playback_SOURCES = \ | 122 | gnunet_helper_audio_playback_SOURCES = \ |
123 | gnunet-helper-audio-playback.c | 123 | gnunet-helper-audio-playback.c |
124 | gnunet_helper_audio_playback_LDADD = \ | 124 | gnunet_helper_audio_playback_LDADD = \ |
125 | $(top_builddir)/src/util/libgnunetutil.la \ | 125 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
126 | -lpulse -lopus -logg \ | 126 | -lpulse -lopus -logg \ |
127 | $(INTLLIBS) | 127 | $(INTLLIBS) |
128 | #gnunet_helper_audio_playback_LDFLAGS = \ | 128 | #gnunet_helper_audio_playback_LDFLAGS = \ |
@@ -132,7 +132,7 @@ if BUILD_GST_HELPERS | |||
132 | gnunet_helper_audio_record_SOURCES = \ | 132 | gnunet_helper_audio_record_SOURCES = \ |
133 | gnunet-helper-audio-record-gst.c | 133 | gnunet-helper-audio-record-gst.c |
134 | gnunet_helper_audio_record_LDADD = \ | 134 | gnunet_helper_audio_record_LDADD = \ |
135 | $(top_builddir)/src/util/libgnunetutil.la \ | 135 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
136 | $(GST_LIBS) \ | 136 | $(GST_LIBS) \ |
137 | $(INTLLIBS) | 137 | $(INTLLIBS) |
138 | gnunet_helper_audio_record_LDFLAGS = \ | 138 | gnunet_helper_audio_record_LDFLAGS = \ |
@@ -143,7 +143,7 @@ gnunet_helper_audio_record_CFLAGS = \ | |||
143 | gnunet_helper_audio_playback_SOURCES = \ | 143 | gnunet_helper_audio_playback_SOURCES = \ |
144 | gnunet-helper-audio-playback-gst.c | 144 | gnunet-helper-audio-playback-gst.c |
145 | gnunet_helper_audio_playback_LDADD = \ | 145 | gnunet_helper_audio_playback_LDADD = \ |
146 | $(top_builddir)/src/util/libgnunetutil.la \ | 146 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
147 | $(GST_LIBS) \ | 147 | $(GST_LIBS) \ |
148 | $(INTLLIBS) | 148 | $(INTLLIBS) |
149 | gnunet_helper_audio_playback_LDFLAGS = \ | 149 | gnunet_helper_audio_playback_LDFLAGS = \ |
@@ -155,7 +155,7 @@ if BUILD_EXPERIMENTAL_HELPERS | |||
155 | gnunet_helper_audio_record_SOURCES = \ | 155 | gnunet_helper_audio_record_SOURCES = \ |
156 | gnunet_gst_test.c gnunet_gst.c | 156 | gnunet_gst_test.c gnunet_gst.c |
157 | gnunet_helper_audio_record_LDADD = \ | 157 | gnunet_helper_audio_record_LDADD = \ |
158 | $(top_builddir)/src/util/libgnunetutil.la \ | 158 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
159 | $(GST_LIBS) \ | 159 | $(GST_LIBS) \ |
160 | $(INTLLIBS) | 160 | $(INTLLIBS) |
161 | gnunet_helper_audio_record_LDFLAGS = \ | 161 | gnunet_helper_audio_record_LDFLAGS = \ |
@@ -166,7 +166,7 @@ gnunet_helper_audio_record_CFLAGS = \ | |||
166 | gnunet_helper_audio_playback_SOURCES = \ | 166 | gnunet_helper_audio_playback_SOURCES = \ |
167 | gnunet_gst_test.c gnunet_gst.c | 167 | gnunet_gst_test.c gnunet_gst.c |
168 | gnunet_helper_audio_playback_LDADD = \ | 168 | gnunet_helper_audio_playback_LDADD = \ |
169 | $(top_builddir)/src/util/libgnunetutil.la \ | 169 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
170 | $(GST_LIBS) \ | 170 | $(GST_LIBS) \ |
171 | $(INTLLIBS) | 171 | $(INTLLIBS) |
172 | gnunet_helper_audio_playback_LDFLAGS = \ | 172 | gnunet_helper_audio_playback_LDFLAGS = \ |
@@ -184,7 +184,7 @@ gnunet_service_conversation_LDADD = \ | |||
184 | libgnunetspeaker.la \ | 184 | libgnunetspeaker.la \ |
185 | libgnunetmicrophone.la \ | 185 | libgnunetmicrophone.la \ |
186 | $(top_builddir)/src/cadet/libgnunetcadet.la \ | 186 | $(top_builddir)/src/cadet/libgnunetcadet.la \ |
187 | $(top_builddir)/src/util/libgnunetutil.la \ | 187 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
188 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 188 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
189 | $(INTLLIBS) | 189 | $(INTLLIBS) |
190 | #gnunet_service_conversation_LDFLAGS = \ | 190 | #gnunet_service_conversation_LDFLAGS = \ |
@@ -197,10 +197,10 @@ gnunet_conversation_LDADD = \ | |||
197 | libgnunetspeaker.la \ | 197 | libgnunetspeaker.la \ |
198 | libgnunetconversation.la \ | 198 | libgnunetconversation.la \ |
199 | $(top_builddir)/src/gns/libgnunetgns.la \ | 199 | $(top_builddir)/src/gns/libgnunetgns.la \ |
200 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 200 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
201 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 201 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
202 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 202 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
203 | $(top_builddir)/src/util/libgnunetutil.la \ | 203 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
204 | $(INTLLIBS) | 204 | $(INTLLIBS) |
205 | #gnunet_conversation_LDFLAGS = \ | 205 | #gnunet_conversation_LDFLAGS = \ |
206 | # | 206 | # |
@@ -210,7 +210,7 @@ gnunet_conversation_test_SOURCES = \ | |||
210 | gnunet_conversation_test_LDADD = \ | 210 | gnunet_conversation_test_LDADD = \ |
211 | libgnunetmicrophone.la \ | 211 | libgnunetmicrophone.la \ |
212 | libgnunetspeaker.la \ | 212 | libgnunetspeaker.la \ |
213 | $(top_builddir)/src/util/libgnunetutil.la \ | 213 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
214 | $(INTLLIBS) | 214 | $(INTLLIBS) |
215 | #gnunet_conversation_test_LDFLAGS = \ | 215 | #gnunet_conversation_test_LDFLAGS = \ |
216 | # | 216 | # |
@@ -222,11 +222,11 @@ test_conversation_api_LDADD = \ | |||
222 | libgnunetconversation.la \ | 222 | libgnunetconversation.la \ |
223 | libgnunetspeaker.la \ | 223 | libgnunetspeaker.la \ |
224 | libgnunetmicrophone.la \ | 224 | libgnunetmicrophone.la \ |
225 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 225 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
226 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 226 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
227 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 227 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
228 | $(top_builddir)/src/testing/libgnunettesting.la \ | 228 | $(top_builddir)/src/testing/libgnunettesting.la \ |
229 | $(top_builddir)/src/util/libgnunetutil.la | 229 | $(top_builddir)/src/lib/util/libgnunetutil.la |
230 | test_conversation_api_LDFLAGS = \ | 230 | test_conversation_api_LDFLAGS = \ |
231 | -export-dynamic | 231 | -export-dynamic |
232 | 232 | ||
@@ -236,11 +236,11 @@ test_conversation_api_twocalls_LDADD = \ | |||
236 | libgnunetconversation.la \ | 236 | libgnunetconversation.la \ |
237 | libgnunetspeaker.la \ | 237 | libgnunetspeaker.la \ |
238 | libgnunetmicrophone.la \ | 238 | libgnunetmicrophone.la \ |
239 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 239 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
240 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 240 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
241 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 241 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
242 | $(top_builddir)/src/testing/libgnunettesting.la \ | 242 | $(top_builddir)/src/testing/libgnunettesting.la \ |
243 | $(top_builddir)/src/util/libgnunetutil.la | 243 | $(top_builddir)/src/lib/util/libgnunetutil.la |
244 | test_conversation_api_twocalls_LDFLAGS = \ | 244 | test_conversation_api_twocalls_LDFLAGS = \ |
245 | -export-dynamic | 245 | -export-dynamic |
246 | 246 | ||
@@ -250,11 +250,11 @@ test_conversation_api_reject_LDADD = \ | |||
250 | libgnunetconversation.la \ | 250 | libgnunetconversation.la \ |
251 | libgnunetspeaker.la \ | 251 | libgnunetspeaker.la \ |
252 | libgnunetmicrophone.la \ | 252 | libgnunetmicrophone.la \ |
253 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 253 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
254 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 254 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
255 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 255 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
256 | $(top_builddir)/src/testing/libgnunettesting.la \ | 256 | $(top_builddir)/src/testing/libgnunettesting.la \ |
257 | $(top_builddir)/src/util/libgnunetutil.la | 257 | $(top_builddir)/src/lib/util/libgnunetutil.la |
258 | test_conversation_api_reject_LDFLAGS = \ | 258 | test_conversation_api_reject_LDFLAGS = \ |
259 | -export-dynamic | 259 | -export-dynamic |
260 | 260 | ||
diff --git a/src/conversation/conversation_api.c b/src/conversation/conversation_api.c index 9c4c520be..ed22bf9cf 100644 --- a/src/conversation/conversation_api.c +++ b/src/conversation/conversation_api.c | |||
@@ -105,7 +105,7 @@ struct GNUNET_CONVERSATION_Caller | |||
105 | /** | 105 | /** |
106 | * Identity of the person calling us. | 106 | * Identity of the person calling us. |
107 | */ | 107 | */ |
108 | struct GNUNET_IDENTITY_PublicKey caller_id; | 108 | struct GNUNET_CRYPTO_PublicKey caller_id; |
109 | 109 | ||
110 | /** | 110 | /** |
111 | * Internal handle to identify the caller with the service. | 111 | * Internal handle to identify the caller with the service. |
@@ -192,7 +192,7 @@ struct GNUNET_CONVERSATION_Phone | |||
192 | /** | 192 | /** |
193 | * My GNS zone. | 193 | * My GNS zone. |
194 | */ | 194 | */ |
195 | struct GNUNET_IDENTITY_PrivateKey my_zone; | 195 | struct GNUNET_CRYPTO_PrivateKey my_zone; |
196 | 196 | ||
197 | /** | 197 | /** |
198 | * State machine for the phone. | 198 | * State machine for the phone. |
@@ -263,7 +263,7 @@ handle_phone_ring (void *cls, | |||
263 | { | 263 | { |
264 | struct GNUNET_CONVERSATION_Phone *phone = cls; | 264 | struct GNUNET_CONVERSATION_Phone *phone = cls; |
265 | struct GNUNET_CONVERSATION_Caller *caller; | 265 | struct GNUNET_CONVERSATION_Caller *caller; |
266 | struct GNUNET_IDENTITY_PublicKey caller_id; | 266 | struct GNUNET_CRYPTO_PublicKey caller_id; |
267 | size_t key_len; | 267 | size_t key_len; |
268 | size_t read; | 268 | size_t read; |
269 | 269 | ||
@@ -276,7 +276,7 @@ handle_phone_ring (void *cls, | |||
276 | 276 | ||
277 | case PS_READY: | 277 | case PS_READY: |
278 | if ((GNUNET_SYSERR == | 278 | if ((GNUNET_SYSERR == |
279 | GNUNET_IDENTITY_read_public_key_from_buffer (&ring[1], | 279 | GNUNET_CRYPTO_read_public_key_from_buffer (&ring[1], |
280 | key_len, | 280 | key_len, |
281 | &caller_id, | 281 | &caller_id, |
282 | &read)) || | 282 | &read)) || |
diff --git a/src/conversation/conversation_api_call.c b/src/conversation/conversation_api_call.c index 129192bf0..2650eb782 100644 --- a/src/conversation/conversation_api_call.c +++ b/src/conversation/conversation_api_call.c | |||
@@ -455,7 +455,7 @@ handle_gns_response (void *cls, | |||
455 | struct GNUNET_CONVERSATION_Call *call = cls; | 455 | struct GNUNET_CONVERSATION_Call *call = cls; |
456 | struct GNUNET_MQ_Envelope *e; | 456 | struct GNUNET_MQ_Envelope *e; |
457 | struct ClientCallMessage *ccm; | 457 | struct ClientCallMessage *ccm; |
458 | const struct GNUNET_IDENTITY_PrivateKey *caller_id; | 458 | const struct GNUNET_CRYPTO_PrivateKey *caller_id; |
459 | size_t key_len; | 459 | size_t key_len; |
460 | 460 | ||
461 | (void) was_gns; | 461 | (void) was_gns; |
@@ -475,12 +475,12 @@ handle_gns_response (void *cls, | |||
475 | rd[i].data, | 475 | rd[i].data, |
476 | rd[i].data_size); | 476 | rd[i].data_size); |
477 | caller_id = GNUNET_IDENTITY_ego_get_private_key (call->caller_id); | 477 | caller_id = GNUNET_IDENTITY_ego_get_private_key (call->caller_id); |
478 | key_len = GNUNET_IDENTITY_private_key_get_length (caller_id); | 478 | key_len = GNUNET_CRYPTO_private_key_get_length (caller_id); |
479 | e = GNUNET_MQ_msg_extra (ccm, key_len, | 479 | e = GNUNET_MQ_msg_extra (ccm, key_len, |
480 | GNUNET_MESSAGE_TYPE_CONVERSATION_CS_PHONE_CALL); | 480 | GNUNET_MESSAGE_TYPE_CONVERSATION_CS_PHONE_CALL); |
481 | ccm->line_port = call->phone_record.line_port; | 481 | ccm->line_port = call->phone_record.line_port; |
482 | ccm->target = call->phone_record.peer; | 482 | ccm->target = call->phone_record.peer; |
483 | GNUNET_IDENTITY_write_private_key_to_buffer (caller_id, | 483 | GNUNET_CRYPTO_write_private_key_to_buffer (caller_id, |
484 | &ccm[1], key_len); | 484 | &ccm[1], key_len); |
485 | ccm->key_len = htonl (key_len); | 485 | ccm->key_len = htonl (key_len); |
486 | GNUNET_MQ_send (call->mq, | 486 | GNUNET_MQ_send (call->mq, |
diff --git a/src/conversation/gnunet-conversation.c b/src/conversation/gnunet-conversation.c index 9ff0002e7..41fc7bd0b 100644 --- a/src/conversation/gnunet-conversation.c +++ b/src/conversation/gnunet-conversation.c | |||
@@ -116,7 +116,7 @@ struct CallList | |||
116 | /** | 116 | /** |
117 | * Public key identifying the caller. | 117 | * Public key identifying the caller. |
118 | */ | 118 | */ |
119 | struct GNUNET_IDENTITY_PublicKey caller_id; | 119 | struct GNUNET_CRYPTO_PublicKey caller_id; |
120 | 120 | ||
121 | /** | 121 | /** |
122 | * Unique number of the call. | 122 | * Unique number of the call. |
@@ -194,7 +194,7 @@ static char *ego_name; | |||
194 | /** | 194 | /** |
195 | * Public key of active conversation partner (if any). | 195 | * Public key of active conversation partner (if any). |
196 | */ | 196 | */ |
197 | static struct GNUNET_IDENTITY_PublicKey peer_key; | 197 | static struct GNUNET_CRYPTO_PublicKey peer_key; |
198 | 198 | ||
199 | /** | 199 | /** |
200 | * Name of active conversation partner (if any). | 200 | * Name of active conversation partner (if any). |
@@ -244,7 +244,7 @@ static void | |||
244 | phone_event_handler (void *cls, | 244 | phone_event_handler (void *cls, |
245 | enum GNUNET_CONVERSATION_PhoneEventCode code, | 245 | enum GNUNET_CONVERSATION_PhoneEventCode code, |
246 | struct GNUNET_CONVERSATION_Caller *caller, | 246 | struct GNUNET_CONVERSATION_Caller *caller, |
247 | const struct GNUNET_IDENTITY_PublicKey *caller_id) | 247 | const struct GNUNET_CRYPTO_PublicKey *caller_id) |
248 | { | 248 | { |
249 | struct CallList *cl; | 249 | struct CallList *cl; |
250 | 250 | ||
diff --git a/src/conversation/gnunet-service-conversation.c b/src/conversation/gnunet-service-conversation.c index 1fff8bd26..06721e535 100644 --- a/src/conversation/gnunet-service-conversation.c +++ b/src/conversation/gnunet-service-conversation.c | |||
@@ -756,8 +756,8 @@ handle_cadet_ring_message (void *cls, const struct CadetPhoneRingMessage *msg) | |||
756 | struct GNUNET_MQ_Envelope *env; | 756 | struct GNUNET_MQ_Envelope *env; |
757 | struct ClientPhoneRingMessage *cring; | 757 | struct ClientPhoneRingMessage *cring; |
758 | struct CadetPhoneRingInfoPS rs; | 758 | struct CadetPhoneRingInfoPS rs; |
759 | struct GNUNET_IDENTITY_PublicKey identity; | 759 | struct GNUNET_CRYPTO_PublicKey identity; |
760 | struct GNUNET_IDENTITY_Signature sig; | 760 | struct GNUNET_CRYPTO_Signature sig; |
761 | size_t key_len; | 761 | size_t key_len; |
762 | size_t sig_len; | 762 | size_t sig_len; |
763 | size_t read; | 763 | size_t read; |
@@ -771,7 +771,7 @@ handle_cadet_ring_message (void *cls, const struct CadetPhoneRingMessage *msg) | |||
771 | sig_len = ntohl (msg->sig_len); | 771 | sig_len = ntohl (msg->sig_len); |
772 | 772 | ||
773 | if ((GNUNET_SYSERR == | 773 | if ((GNUNET_SYSERR == |
774 | GNUNET_IDENTITY_read_public_key_from_buffer (&msg[1], | 774 | GNUNET_CRYPTO_read_public_key_from_buffer (&msg[1], |
775 | key_len, | 775 | key_len, |
776 | &identity, | 776 | &identity, |
777 | &read)) || | 777 | &read)) || |
@@ -781,11 +781,11 @@ handle_cadet_ring_message (void *cls, const struct CadetPhoneRingMessage *msg) | |||
781 | destroy_line_cadet_channels (ch); | 781 | destroy_line_cadet_channels (ch); |
782 | return; | 782 | return; |
783 | } | 783 | } |
784 | GNUNET_IDENTITY_read_signature_from_buffer (&sig, | 784 | GNUNET_CRYPTO_read_signature_from_buffer (&sig, |
785 | (char*) &msg[1] + read, | 785 | (char*) &msg[1] + read, |
786 | sig_len); | 786 | sig_len); |
787 | if (GNUNET_OK != | 787 | if (GNUNET_OK != |
788 | GNUNET_IDENTITY_signature_verify ( | 788 | GNUNET_CRYPTO_signature_verify ( |
789 | GNUNET_SIGNATURE_PURPOSE_CONVERSATION_RING, | 789 | GNUNET_SIGNATURE_PURPOSE_CONVERSATION_RING, |
790 | &rs, | 790 | &rs, |
791 | &sig, | 791 | &sig, |
@@ -1165,9 +1165,9 @@ handle_client_call_message (void *cls, const struct ClientCallMessage *msg) | |||
1165 | struct GNUNET_MQ_Envelope *e; | 1165 | struct GNUNET_MQ_Envelope *e; |
1166 | struct CadetPhoneRingMessage *ring; | 1166 | struct CadetPhoneRingMessage *ring; |
1167 | struct CadetPhoneRingInfoPS rs; | 1167 | struct CadetPhoneRingInfoPS rs; |
1168 | struct GNUNET_IDENTITY_PrivateKey caller_id; | 1168 | struct GNUNET_CRYPTO_PrivateKey caller_id; |
1169 | struct GNUNET_IDENTITY_PublicKey caller_id_pub; | 1169 | struct GNUNET_CRYPTO_PublicKey caller_id_pub; |
1170 | struct GNUNET_IDENTITY_Signature sig; | 1170 | struct GNUNET_CRYPTO_Signature sig; |
1171 | ssize_t written; | 1171 | ssize_t written; |
1172 | size_t key_len; | 1172 | size_t key_len; |
1173 | size_t pkey_len; | 1173 | size_t pkey_len; |
@@ -1183,7 +1183,7 @@ handle_client_call_message (void *cls, const struct ClientCallMessage *msg) | |||
1183 | GNUNET_TIME_absolute_hton (GNUNET_TIME_relative_to_absolute (RING_TIMEOUT)); | 1183 | GNUNET_TIME_absolute_hton (GNUNET_TIME_relative_to_absolute (RING_TIMEOUT)); |
1184 | key_len = ntohl (msg->key_len); | 1184 | key_len = ntohl (msg->key_len); |
1185 | if (GNUNET_SYSERR == | 1185 | if (GNUNET_SYSERR == |
1186 | GNUNET_IDENTITY_read_private_key_from_buffer (&msg[1], | 1186 | GNUNET_CRYPTO_read_private_key_from_buffer (&msg[1], |
1187 | key_len, | 1187 | key_len, |
1188 | &caller_id, | 1188 | &caller_id, |
1189 | &read)) | 1189 | &read)) |
@@ -1205,19 +1205,19 @@ handle_client_call_message (void *cls, const struct ClientCallMessage *msg) | |||
1205 | cadet_handlers); | 1205 | cadet_handlers); |
1206 | ch->mq = GNUNET_CADET_get_mq (ch->channel); | 1206 | ch->mq = GNUNET_CADET_get_mq (ch->channel); |
1207 | GNUNET_assert (read == key_len); | 1207 | GNUNET_assert (read == key_len); |
1208 | GNUNET_IDENTITY_sign (&caller_id, &rs, &sig); | 1208 | GNUNET_CRYPTO_sign (&caller_id, &rs, &sig); |
1209 | sig_len = GNUNET_IDENTITY_signature_get_length (&sig); | 1209 | sig_len = GNUNET_CRYPTO_signature_get_length (&sig); |
1210 | GNUNET_IDENTITY_key_get_public (&caller_id, &caller_id_pub); | 1210 | GNUNET_CRYPTO_key_get_public (&caller_id, &caller_id_pub); |
1211 | pkey_len = GNUNET_IDENTITY_public_key_get_length (&caller_id_pub); | 1211 | pkey_len = GNUNET_CRYPTO_public_key_get_length (&caller_id_pub); |
1212 | e = GNUNET_MQ_msg_extra (ring, pkey_len + sig_len, | 1212 | e = GNUNET_MQ_msg_extra (ring, pkey_len + sig_len, |
1213 | GNUNET_MESSAGE_TYPE_CONVERSATION_CADET_PHONE_RING); | 1213 | GNUNET_MESSAGE_TYPE_CONVERSATION_CADET_PHONE_RING); |
1214 | written = GNUNET_IDENTITY_write_public_key_to_buffer (&caller_id_pub, | 1214 | written = GNUNET_CRYPTO_write_public_key_to_buffer (&caller_id_pub, |
1215 | &ring[1], | 1215 | &ring[1], |
1216 | pkey_len); | 1216 | pkey_len); |
1217 | ring->expiration_time = rs.expiration_time; | 1217 | ring->expiration_time = rs.expiration_time; |
1218 | ring->key_len = htonl (pkey_len); | 1218 | ring->key_len = htonl (pkey_len); |
1219 | ring->sig_len = htonl (sig_len); | 1219 | ring->sig_len = htonl (sig_len); |
1220 | GNUNET_IDENTITY_write_signature_to_buffer (&sig, | 1220 | GNUNET_CRYPTO_write_signature_to_buffer (&sig, |
1221 | (char *) &ring[1] + written, | 1221 | (char *) &ring[1] + written, |
1222 | sig_len); | 1222 | sig_len); |
1223 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Sending RING message via CADET\n"); | 1223 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Sending RING message via CADET\n"); |
diff --git a/src/conversation/test_conversation_api.c b/src/conversation/test_conversation_api.c index 22e9b1dd9..2e804a485 100644 --- a/src/conversation/test_conversation_api.c +++ b/src/conversation/test_conversation_api.c | |||
@@ -305,7 +305,7 @@ static void | |||
305 | phone_event_handler (void *cls, | 305 | phone_event_handler (void *cls, |
306 | enum GNUNET_CONVERSATION_PhoneEventCode code, | 306 | enum GNUNET_CONVERSATION_PhoneEventCode code, |
307 | struct GNUNET_CONVERSATION_Caller *caller, | 307 | struct GNUNET_CONVERSATION_Caller *caller, |
308 | const struct GNUNET_IDENTITY_PublicKey *caller_id) | 308 | const struct GNUNET_CRYPTO_PublicKey *caller_id) |
309 | { | 309 | { |
310 | static enum GNUNET_CONVERSATION_PhoneEventCode expect = | 310 | static enum GNUNET_CONVERSATION_PhoneEventCode expect = |
311 | GNUNET_CONVERSATION_EC_PHONE_RING; | 311 | GNUNET_CONVERSATION_EC_PHONE_RING; |
@@ -385,7 +385,7 @@ call_event_handler (void *cls, enum GNUNET_CONVERSATION_CallEventCode code) | |||
385 | 385 | ||
386 | static void | 386 | static void |
387 | caller_ego_create_cont (void *cls, | 387 | caller_ego_create_cont (void *cls, |
388 | const struct GNUNET_IDENTITY_PrivateKey *pk, | 388 | const struct GNUNET_CRYPTO_PrivateKey *pk, |
389 | enum GNUNET_ErrorCode ec) | 389 | enum GNUNET_ErrorCode ec) |
390 | { | 390 | { |
391 | (void) cls; | 391 | (void) cls; |
@@ -402,7 +402,7 @@ namestore_put_cont (void *cls, enum GNUNET_ErrorCode ec) | |||
402 | GNUNET_assert (GNUNET_EC_NONE == ec); | 402 | GNUNET_assert (GNUNET_EC_NONE == ec); |
403 | GNUNET_assert (NULL == op); | 403 | GNUNET_assert (NULL == op); |
404 | op = GNUNET_IDENTITY_create (id, "caller-ego", NULL, | 404 | op = GNUNET_IDENTITY_create (id, "caller-ego", NULL, |
405 | GNUNET_IDENTITY_TYPE_ECDSA, | 405 | GNUNET_PUBLIC_KEY_TYPE_ECDSA, |
406 | &caller_ego_create_cont, | 406 | &caller_ego_create_cont, |
407 | NULL); | 407 | NULL); |
408 | } | 408 | } |
@@ -415,7 +415,7 @@ identity_cb (void *cls, | |||
415 | const char *name) | 415 | const char *name) |
416 | { | 416 | { |
417 | struct GNUNET_GNSRECORD_Data rd; | 417 | struct GNUNET_GNSRECORD_Data rd; |
418 | struct GNUNET_IDENTITY_PublicKey pub; | 418 | struct GNUNET_CRYPTO_PublicKey pub; |
419 | 419 | ||
420 | (void) cls; | 420 | (void) cls; |
421 | (void) ctx; | 421 | (void) ctx; |
@@ -466,7 +466,7 @@ identity_cb (void *cls, | |||
466 | 466 | ||
467 | static void | 467 | static void |
468 | phone_ego_create_cont (void *cls, | 468 | phone_ego_create_cont (void *cls, |
469 | const struct GNUNET_IDENTITY_PrivateKey *pk, | 469 | const struct GNUNET_CRYPTO_PrivateKey *pk, |
470 | enum GNUNET_ErrorCode ec) | 470 | enum GNUNET_ErrorCode ec) |
471 | { | 471 | { |
472 | (void) cls; | 472 | (void) cls; |
@@ -486,7 +486,7 @@ run (void *cls, | |||
486 | GNUNET_SCHEDULER_add_delayed (TIMEOUT, &end_test, NULL); | 486 | GNUNET_SCHEDULER_add_delayed (TIMEOUT, &end_test, NULL); |
487 | id = GNUNET_IDENTITY_connect (cfg, &identity_cb, NULL); | 487 | id = GNUNET_IDENTITY_connect (cfg, &identity_cb, NULL); |
488 | op = GNUNET_IDENTITY_create (id, "phone-ego", NULL, | 488 | op = GNUNET_IDENTITY_create (id, "phone-ego", NULL, |
489 | GNUNET_IDENTITY_TYPE_ECDSA, | 489 | GNUNET_PUBLIC_KEY_TYPE_ECDSA, |
490 | &phone_ego_create_cont, | 490 | &phone_ego_create_cont, |
491 | NULL); | 491 | NULL); |
492 | ns = GNUNET_NAMESTORE_connect (cfg); | 492 | ns = GNUNET_NAMESTORE_connect (cfg); |
diff --git a/src/conversation/test_conversation_api_reject.c b/src/conversation/test_conversation_api_reject.c index a7aab069f..37192f5b8 100644 --- a/src/conversation/test_conversation_api_reject.c +++ b/src/conversation/test_conversation_api_reject.c | |||
@@ -179,7 +179,7 @@ static void | |||
179 | phone_event_handler (void *cls, | 179 | phone_event_handler (void *cls, |
180 | enum GNUNET_CONVERSATION_PhoneEventCode code, | 180 | enum GNUNET_CONVERSATION_PhoneEventCode code, |
181 | struct GNUNET_CONVERSATION_Caller *caller, | 181 | struct GNUNET_CONVERSATION_Caller *caller, |
182 | const struct GNUNET_IDENTITY_PublicKey *caller_id) | 182 | const struct GNUNET_CRYPTO_PublicKey *caller_id) |
183 | { | 183 | { |
184 | static enum GNUNET_CONVERSATION_PhoneEventCode expect = | 184 | static enum GNUNET_CONVERSATION_PhoneEventCode expect = |
185 | GNUNET_CONVERSATION_EC_PHONE_RING; | 185 | GNUNET_CONVERSATION_EC_PHONE_RING; |
@@ -238,7 +238,7 @@ call_event_handler (void *cls, enum GNUNET_CONVERSATION_CallEventCode code) | |||
238 | 238 | ||
239 | static void | 239 | static void |
240 | caller_ego_create_cont (void *cls, | 240 | caller_ego_create_cont (void *cls, |
241 | const struct GNUNET_IDENTITY_PrivateKey *pk, | 241 | const struct GNUNET_CRYPTO_PrivateKey *pk, |
242 | enum GNUNET_ErrorCode ec) | 242 | enum GNUNET_ErrorCode ec) |
243 | { | 243 | { |
244 | (void) cls; | 244 | (void) cls; |
@@ -255,7 +255,7 @@ namestore_put_cont (void *cls, enum GNUNET_ErrorCode ec) | |||
255 | GNUNET_assert (GNUNET_EC_NONE == ec); | 255 | GNUNET_assert (GNUNET_EC_NONE == ec); |
256 | GNUNET_assert (NULL == op); | 256 | GNUNET_assert (NULL == op); |
257 | op = GNUNET_IDENTITY_create (id, "caller-ego", NULL, | 257 | op = GNUNET_IDENTITY_create (id, "caller-ego", NULL, |
258 | GNUNET_IDENTITY_TYPE_ECDSA, | 258 | GNUNET_PUBLIC_KEY_TYPE_ECDSA, |
259 | &caller_ego_create_cont, | 259 | &caller_ego_create_cont, |
260 | NULL); | 260 | NULL); |
261 | } | 261 | } |
@@ -268,7 +268,7 @@ identity_cb (void *cls, | |||
268 | const char *name) | 268 | const char *name) |
269 | { | 269 | { |
270 | struct GNUNET_GNSRECORD_Data rd; | 270 | struct GNUNET_GNSRECORD_Data rd; |
271 | struct GNUNET_IDENTITY_PublicKey pub; | 271 | struct GNUNET_CRYPTO_PublicKey pub; |
272 | 272 | ||
273 | (void) cls; | 273 | (void) cls; |
274 | (void) ctx; | 274 | (void) ctx; |
@@ -319,7 +319,7 @@ identity_cb (void *cls, | |||
319 | 319 | ||
320 | static void | 320 | static void |
321 | phone_ego_create_cont (void *cls, | 321 | phone_ego_create_cont (void *cls, |
322 | const struct GNUNET_IDENTITY_PrivateKey *pk, | 322 | const struct GNUNET_CRYPTO_PrivateKey *pk, |
323 | enum GNUNET_ErrorCode ec) | 323 | enum GNUNET_ErrorCode ec) |
324 | { | 324 | { |
325 | (void) cls; | 325 | (void) cls; |
@@ -339,7 +339,7 @@ run (void *cls, | |||
339 | GNUNET_SCHEDULER_add_delayed (TIMEOUT, &end_test, NULL); | 339 | GNUNET_SCHEDULER_add_delayed (TIMEOUT, &end_test, NULL); |
340 | id = GNUNET_IDENTITY_connect (cfg, &identity_cb, NULL); | 340 | id = GNUNET_IDENTITY_connect (cfg, &identity_cb, NULL); |
341 | op = GNUNET_IDENTITY_create (id, "phone-ego", NULL, | 341 | op = GNUNET_IDENTITY_create (id, "phone-ego", NULL, |
342 | GNUNET_IDENTITY_TYPE_ECDSA, | 342 | GNUNET_PUBLIC_KEY_TYPE_ECDSA, |
343 | &phone_ego_create_cont, | 343 | &phone_ego_create_cont, |
344 | NULL); | 344 | NULL); |
345 | ns = GNUNET_NAMESTORE_connect (cfg); | 345 | ns = GNUNET_NAMESTORE_connect (cfg); |
diff --git a/src/conversation/test_conversation_api_twocalls.c b/src/conversation/test_conversation_api_twocalls.c index 1bd2b4e22..2ca31854d 100644 --- a/src/conversation/test_conversation_api_twocalls.c +++ b/src/conversation/test_conversation_api_twocalls.c | |||
@@ -403,7 +403,7 @@ static void | |||
403 | phone_event_handler (void *cls, | 403 | phone_event_handler (void *cls, |
404 | enum GNUNET_CONVERSATION_PhoneEventCode code, | 404 | enum GNUNET_CONVERSATION_PhoneEventCode code, |
405 | struct GNUNET_CONVERSATION_Caller *caller, | 405 | struct GNUNET_CONVERSATION_Caller *caller, |
406 | const struct GNUNET_IDENTITY_PublicKey *caller_id) | 406 | const struct GNUNET_CRYPTO_PublicKey *caller_id) |
407 | { | 407 | { |
408 | const char *cid; | 408 | const char *cid; |
409 | 409 | ||
@@ -507,7 +507,7 @@ call_event_handler (void *cls, enum GNUNET_CONVERSATION_CallEventCode code) | |||
507 | 507 | ||
508 | static void | 508 | static void |
509 | caller_ego_create_cont (void *cls, | 509 | caller_ego_create_cont (void *cls, |
510 | const struct GNUNET_IDENTITY_PrivateKey *pk, | 510 | const struct GNUNET_CRYPTO_PrivateKey *pk, |
511 | enum GNUNET_ErrorCode ec) | 511 | enum GNUNET_ErrorCode ec) |
512 | { | 512 | { |
513 | (void) cls; | 513 | (void) cls; |
@@ -524,7 +524,7 @@ namestore_put_cont (void *cls, enum GNUNET_ErrorCode ec) | |||
524 | GNUNET_assert (GNUNET_EC_NONE == ec); | 524 | GNUNET_assert (GNUNET_EC_NONE == ec); |
525 | GNUNET_assert (NULL == op); | 525 | GNUNET_assert (NULL == op); |
526 | op = GNUNET_IDENTITY_create (id, "caller-ego", NULL, | 526 | op = GNUNET_IDENTITY_create (id, "caller-ego", NULL, |
527 | GNUNET_IDENTITY_TYPE_ECDSA, | 527 | GNUNET_PUBLIC_KEY_TYPE_ECDSA, |
528 | &caller_ego_create_cont, | 528 | &caller_ego_create_cont, |
529 | NULL); | 529 | NULL); |
530 | } | 530 | } |
@@ -537,7 +537,7 @@ identity_cb (void *cls, | |||
537 | const char *name) | 537 | const char *name) |
538 | { | 538 | { |
539 | struct GNUNET_GNSRECORD_Data rd; | 539 | struct GNUNET_GNSRECORD_Data rd; |
540 | struct GNUNET_IDENTITY_PublicKey pub; | 540 | struct GNUNET_CRYPTO_PublicKey pub; |
541 | 541 | ||
542 | (void) cls; | 542 | (void) cls; |
543 | (void) ctx; | 543 | (void) ctx; |
@@ -595,7 +595,7 @@ identity_cb (void *cls, | |||
595 | 595 | ||
596 | static void | 596 | static void |
597 | phone_ego_create_cont (void *cls, | 597 | phone_ego_create_cont (void *cls, |
598 | const struct GNUNET_IDENTITY_PrivateKey *pk, | 598 | const struct GNUNET_CRYPTO_PrivateKey *pk, |
599 | enum GNUNET_ErrorCode ec) | 599 | enum GNUNET_ErrorCode ec) |
600 | { | 600 | { |
601 | (void) cls; | 601 | (void) cls; |
@@ -616,7 +616,7 @@ run (void *cls, | |||
616 | GNUNET_SCHEDULER_add_shutdown (&do_shutdown, NULL); | 616 | GNUNET_SCHEDULER_add_shutdown (&do_shutdown, NULL); |
617 | id = GNUNET_IDENTITY_connect (cfg, &identity_cb, NULL); | 617 | id = GNUNET_IDENTITY_connect (cfg, &identity_cb, NULL); |
618 | op = GNUNET_IDENTITY_create (id, "phone-ego", NULL, | 618 | op = GNUNET_IDENTITY_create (id, "phone-ego", NULL, |
619 | GNUNET_IDENTITY_TYPE_ECDSA, | 619 | GNUNET_PUBLIC_KEY_TYPE_ECDSA, |
620 | &phone_ego_create_cont, | 620 | &phone_ego_create_cont, |
621 | NULL); | 621 | NULL); |
622 | ns = GNUNET_NAMESTORE_connect (cfg); | 622 | ns = GNUNET_NAMESTORE_connect (cfg); |
diff --git a/src/core/Makefile.am b/src/core/Makefile.am index 5e2a74ec3..7a9046c57 100644 --- a/src/core/Makefile.am +++ b/src/core/Makefile.am | |||
@@ -29,7 +29,7 @@ libgnunetcore_la_SOURCES = \ | |||
29 | core_api.c core.h \ | 29 | core_api.c core.h \ |
30 | core_api_monitor_peers.c | 30 | core_api_monitor_peers.c |
31 | libgnunetcore_la_LIBADD = \ | 31 | libgnunetcore_la_LIBADD = \ |
32 | $(top_builddir)/src/util/libgnunetutil.la \ | 32 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
33 | $(GN_LIBINTL) $(XLIB) | 33 | $(GN_LIBINTL) $(XLIB) |
34 | libgnunetcore_la_LDFLAGS = \ | 34 | libgnunetcore_la_LDFLAGS = \ |
35 | $(GN_LIB_LDFLAGS) \ | 35 | $(GN_LIB_LDFLAGS) \ |
@@ -44,9 +44,9 @@ libgnunet_test_core_plugin_cmd_just_run_la_LIBADD = \ | |||
44 | $(top_builddir)/src/testing/libgnunettesting.la \ | 44 | $(top_builddir)/src/testing/libgnunettesting.la \ |
45 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 45 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
46 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 46 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
47 | $(top_builddir)/src/hello/libgnunethello.la \ | 47 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
48 | $(top_builddir)/src/arm/libgnunetarm.la \ | 48 | $(top_builddir)/src/arm/libgnunetarm.la \ |
49 | $(top_builddir)/src/util/libgnunetutil.la \ | 49 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
50 | $(LTLIBINTL) | 50 | $(LTLIBINTL) |
51 | libgnunet_test_core_plugin_cmd_just_run_la_LDFLAGS = \ | 51 | libgnunet_test_core_plugin_cmd_just_run_la_LDFLAGS = \ |
52 | $(GN_PLUGIN_LDFLAGS) | 52 | $(GN_PLUGIN_LDFLAGS) |
@@ -58,7 +58,7 @@ libgnunetcoretesting_la_LIBADD = \ | |||
58 | $(top_builddir)/src/arm/libgnunetarm.la \ | 58 | $(top_builddir)/src/arm/libgnunetarm.la \ |
59 | $(top_builddir)/src/transport/libgnunettransportapplication.la \ | 59 | $(top_builddir)/src/transport/libgnunettransportapplication.la \ |
60 | $(top_builddir)/src/transport/libgnunettransportcore.la \ | 60 | $(top_builddir)/src/transport/libgnunettransportcore.la \ |
61 | $(top_builddir)/src/util/libgnunetutil.la | 61 | $(top_builddir)/src/lib/util/libgnunetutil.la |
62 | libgnunetcoretesting_la_LDFLAGS = \ | 62 | libgnunetcoretesting_la_LDFLAGS = \ |
63 | $(GN_LIBINTL) \ | 63 | $(GN_LIBINTL) \ |
64 | $(GN_LIB_LDFLAGS) \ | 64 | $(GN_LIB_LDFLAGS) \ |
@@ -80,7 +80,7 @@ gnunet_service_core_LDADD = \ | |||
80 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 80 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
81 | $(top_builddir)/src/transport/libgnunettransportapplication.la \ | 81 | $(top_builddir)/src/transport/libgnunettransportapplication.la \ |
82 | $(top_builddir)/src/transport/libgnunettransportcore.la \ | 82 | $(top_builddir)/src/transport/libgnunettransportcore.la \ |
83 | $(top_builddir)/src/util/libgnunetutil.la \ | 83 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
84 | $(GN_LIBINTL) $(Z_LIBS) | 84 | $(GN_LIBINTL) $(Z_LIBS) |
85 | 85 | ||
86 | 86 | ||
@@ -88,7 +88,7 @@ gnunet_core_SOURCES = \ | |||
88 | gnunet-core.c | 88 | gnunet-core.c |
89 | gnunet_core_LDADD = \ | 89 | gnunet_core_LDADD = \ |
90 | libgnunetcore.la \ | 90 | libgnunetcore.la \ |
91 | $(top_builddir)/src/util/libgnunetutil.la | 91 | $(top_builddir)/src/lib/util/libgnunetutil.la |
92 | gnunet_core_LDFLAGS = \ | 92 | gnunet_core_LDFLAGS = \ |
93 | $(GN_LIBINTL) | 93 | $(GN_LIBINTL) |
94 | 94 | ||
@@ -114,14 +114,14 @@ test_core_api_send_to_self_SOURCES = \ | |||
114 | test_core_api_send_to_self_LDADD = \ | 114 | test_core_api_send_to_self_LDADD = \ |
115 | libgnunetcore.la \ | 115 | libgnunetcore.la \ |
116 | $(top_builddir)/src/testing/libgnunettesting.la \ | 116 | $(top_builddir)/src/testing/libgnunettesting.la \ |
117 | $(top_builddir)/src/util/libgnunetutil.la | 117 | $(top_builddir)/src/lib/util/libgnunetutil.la |
118 | 118 | ||
119 | test_core_api_start_only_SOURCES = \ | 119 | test_core_api_start_only_SOURCES = \ |
120 | test_core_api_start_only.c | 120 | test_core_api_start_only.c |
121 | test_core_api_start_only_LDADD = \ | 121 | test_core_api_start_only_LDADD = \ |
122 | $(top_builddir)/src/testing/libgnunettesting.la \ | 122 | $(top_builddir)/src/testing/libgnunettesting.la \ |
123 | libgnunetcore.la \ | 123 | libgnunetcore.la \ |
124 | $(top_builddir)/src/util/libgnunetutil.la | 124 | $(top_builddir)/src/lib/util/libgnunetutil.la |
125 | 125 | ||
126 | EXTRA_DIST = \ | 126 | EXTRA_DIST = \ |
127 | test_core_start_testcase.sh \ | 127 | test_core_start_testcase.sh \ |
diff --git a/src/curl/Makefile.am b/src/curl/Makefile.am index bf18b0647..78eae4b97 100644 --- a/src/curl/Makefile.am +++ b/src/curl/Makefile.am | |||
@@ -17,7 +17,7 @@ libgnunetcurl_la_SOURCES = \ | |||
17 | curl.c \ | 17 | curl.c \ |
18 | curl_reschedule.c | 18 | curl_reschedule.c |
19 | libgnunetcurl_la_LIBADD = \ | 19 | libgnunetcurl_la_LIBADD = \ |
20 | $(top_builddir)/src/util/libgnunetutil.la \ | 20 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
21 | -ljansson \ | 21 | -ljansson \ |
22 | @LIBCURL@ \ | 22 | @LIBCURL@ \ |
23 | $(XLIB) | 23 | $(XLIB) |
@@ -34,5 +34,5 @@ libgnunetcurl_la_CPPFLAGS = \ | |||
34 | # test_curl.c | 34 | # test_curl.c |
35 | #test_curl_LDADD = \ | 35 | #test_curl_LDADD = \ |
36 | # libgnunetcurl.la \ | 36 | # libgnunetcurl.la \ |
37 | # $(top_builddir)/src/util/libgnunetutil.la \ | 37 | # $(top_builddir)/src/lib/util/libgnunetutil.la \ |
38 | # -ljansson -lcurl | 38 | # -ljansson -lcurl |
diff --git a/src/datacache/Makefile.am b/src/datacache/Makefile.am index 1ae4744a8..def1eb58e 100644 --- a/src/datacache/Makefile.am +++ b/src/datacache/Makefile.am | |||
@@ -34,7 +34,7 @@ libgnunetdatacache_la_SOURCES = \ | |||
34 | datacache.c | 34 | datacache.c |
35 | libgnunetdatacache_la_LIBADD = \ | 35 | libgnunetdatacache_la_LIBADD = \ |
36 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 36 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
37 | $(top_builddir)/src/util/libgnunetutil.la \ | 37 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
38 | $(GN_LIBINTL) | 38 | $(GN_LIBINTL) |
39 | libgnunetdatacache_la_LDFLAGS = \ | 39 | libgnunetdatacache_la_LDFLAGS = \ |
40 | $(GN_LIB_LDFLAGS) \ | 40 | $(GN_LIB_LDFLAGS) \ |
@@ -57,7 +57,7 @@ libgnunet_plugin_datacache_sqlite_la_SOURCES = \ | |||
57 | libgnunet_plugin_datacache_sqlite_la_LIBADD = \ | 57 | libgnunet_plugin_datacache_sqlite_la_LIBADD = \ |
58 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 58 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
59 | $(top_builddir)/src/sq/libgnunetsq.la \ | 59 | $(top_builddir)/src/sq/libgnunetsq.la \ |
60 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) -lsqlite3 \ | 60 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) -lsqlite3 \ |
61 | $(LTLIBINTL) | 61 | $(LTLIBINTL) |
62 | libgnunet_plugin_datacache_sqlite_la_LDFLAGS = \ | 62 | libgnunet_plugin_datacache_sqlite_la_LDFLAGS = \ |
63 | $(GN_PLUGIN_LDFLAGS) | 63 | $(GN_PLUGIN_LDFLAGS) |
@@ -66,7 +66,7 @@ libgnunet_plugin_datacache_heap_la_SOURCES = \ | |||
66 | plugin_datacache_heap.c | 66 | plugin_datacache_heap.c |
67 | libgnunet_plugin_datacache_heap_la_LIBADD = \ | 67 | libgnunet_plugin_datacache_heap_la_LIBADD = \ |
68 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 68 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
69 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 69 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) \ |
70 | $(LTLIBINTL) | 70 | $(LTLIBINTL) |
71 | libgnunet_plugin_datacache_heap_la_LDFLAGS = \ | 71 | libgnunet_plugin_datacache_heap_la_LDFLAGS = \ |
72 | $(GN_PLUGIN_LDFLAGS) | 72 | $(GN_PLUGIN_LDFLAGS) |
@@ -76,7 +76,7 @@ libgnunet_plugin_datacache_postgres_la_SOURCES = \ | |||
76 | libgnunet_plugin_datacache_postgres_la_LIBADD = \ | 76 | libgnunet_plugin_datacache_postgres_la_LIBADD = \ |
77 | $(top_builddir)/src/pq/libgnunetpq.la \ | 77 | $(top_builddir)/src/pq/libgnunetpq.la \ |
78 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 78 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
79 | $(top_builddir)/src/util/libgnunetutil.la \ | 79 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
80 | $(GN_PLUGIN_LDFLAGS) -lpq | 80 | $(GN_PLUGIN_LDFLAGS) -lpq |
81 | libgnunet_plugin_datacache_postgres_la_CPPFLAGS = \ | 81 | libgnunet_plugin_datacache_postgres_la_CPPFLAGS = \ |
82 | $(POSTGRESQL_CPPFLAGS) $(AM_CPPFLAGS) | 82 | $(POSTGRESQL_CPPFLAGS) $(AM_CPPFLAGS) |
@@ -86,7 +86,7 @@ libgnunet_plugin_datacache_postgres_la_LDFLAGS = \ | |||
86 | libgnunet_plugin_datacache_template_la_SOURCES = \ | 86 | libgnunet_plugin_datacache_template_la_SOURCES = \ |
87 | plugin_datacache_template.c | 87 | plugin_datacache_template.c |
88 | libgnunet_plugin_datacache_template_la_LIBADD = \ | 88 | libgnunet_plugin_datacache_template_la_LIBADD = \ |
89 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 89 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) \ |
90 | $(LTLIBINTL) | 90 | $(LTLIBINTL) |
91 | libgnunet_plugin_datacache_template_la_LDFLAGS = \ | 91 | libgnunet_plugin_datacache_template_la_LDFLAGS = \ |
92 | $(GN_PLUGIN_LDFLAGS) | 92 | $(GN_PLUGIN_LDFLAGS) |
@@ -126,42 +126,42 @@ test_datacache_sqlite_SOURCES = \ | |||
126 | test_datacache_sqlite_LDADD = \ | 126 | test_datacache_sqlite_LDADD = \ |
127 | $(top_builddir)/src/testing/libgnunettesting.la \ | 127 | $(top_builddir)/src/testing/libgnunettesting.la \ |
128 | libgnunetdatacache.la \ | 128 | libgnunetdatacache.la \ |
129 | $(top_builddir)/src/util/libgnunetutil.la | 129 | $(top_builddir)/src/lib/util/libgnunetutil.la |
130 | 130 | ||
131 | test_datacache_quota_sqlite_SOURCES = \ | 131 | test_datacache_quota_sqlite_SOURCES = \ |
132 | test_datacache_quota.c | 132 | test_datacache_quota.c |
133 | test_datacache_quota_sqlite_LDADD = \ | 133 | test_datacache_quota_sqlite_LDADD = \ |
134 | $(top_builddir)/src/testing/libgnunettesting.la \ | 134 | $(top_builddir)/src/testing/libgnunettesting.la \ |
135 | libgnunetdatacache.la \ | 135 | libgnunetdatacache.la \ |
136 | $(top_builddir)/src/util/libgnunetutil.la | 136 | $(top_builddir)/src/lib/util/libgnunetutil.la |
137 | 137 | ||
138 | test_datacache_heap_SOURCES = \ | 138 | test_datacache_heap_SOURCES = \ |
139 | test_datacache.c | 139 | test_datacache.c |
140 | test_datacache_heap_LDADD = \ | 140 | test_datacache_heap_LDADD = \ |
141 | $(top_builddir)/src/testing/libgnunettesting.la \ | 141 | $(top_builddir)/src/testing/libgnunettesting.la \ |
142 | libgnunetdatacache.la \ | 142 | libgnunetdatacache.la \ |
143 | $(top_builddir)/src/util/libgnunetutil.la | 143 | $(top_builddir)/src/lib/util/libgnunetutil.la |
144 | 144 | ||
145 | test_datacache_quota_heap_SOURCES = \ | 145 | test_datacache_quota_heap_SOURCES = \ |
146 | test_datacache_quota.c | 146 | test_datacache_quota.c |
147 | test_datacache_quota_heap_LDADD = \ | 147 | test_datacache_quota_heap_LDADD = \ |
148 | $(top_builddir)/src/testing/libgnunettesting.la \ | 148 | $(top_builddir)/src/testing/libgnunettesting.la \ |
149 | libgnunetdatacache.la \ | 149 | libgnunetdatacache.la \ |
150 | $(top_builddir)/src/util/libgnunetutil.la | 150 | $(top_builddir)/src/lib/util/libgnunetutil.la |
151 | 151 | ||
152 | test_datacache_postgres_SOURCES = \ | 152 | test_datacache_postgres_SOURCES = \ |
153 | test_datacache.c | 153 | test_datacache.c |
154 | test_datacache_postgres_LDADD = \ | 154 | test_datacache_postgres_LDADD = \ |
155 | $(top_builddir)/src/testing/libgnunettesting.la \ | 155 | $(top_builddir)/src/testing/libgnunettesting.la \ |
156 | libgnunetdatacache.la \ | 156 | libgnunetdatacache.la \ |
157 | $(top_builddir)/src/util/libgnunetutil.la | 157 | $(top_builddir)/src/lib/util/libgnunetutil.la |
158 | 158 | ||
159 | test_datacache_quota_postgres_SOURCES = \ | 159 | test_datacache_quota_postgres_SOURCES = \ |
160 | test_datacache_quota.c | 160 | test_datacache_quota.c |
161 | test_datacache_quota_postgres_LDADD = \ | 161 | test_datacache_quota_postgres_LDADD = \ |
162 | $(top_builddir)/src/testing/libgnunettesting.la \ | 162 | $(top_builddir)/src/testing/libgnunettesting.la \ |
163 | libgnunetdatacache.la \ | 163 | libgnunetdatacache.la \ |
164 | $(top_builddir)/src/util/libgnunetutil.la | 164 | $(top_builddir)/src/lib/util/libgnunetutil.la |
165 | 165 | ||
166 | EXTRA_DIST = \ | 166 | EXTRA_DIST = \ |
167 | test_datacache_data_sqlite.conf \ | 167 | test_datacache_data_sqlite.conf \ |
diff --git a/src/datastore/Makefile.am b/src/datastore/Makefile.am index 595c7da3d..e8ede4b3e 100644 --- a/src/datastore/Makefile.am +++ b/src/datastore/Makefile.am | |||
@@ -29,7 +29,7 @@ libgnunetdatastore_la_SOURCES = \ | |||
29 | datastore_api.c datastore.h | 29 | datastore_api.c datastore.h |
30 | libgnunetdatastore_la_LIBADD = \ | 30 | libgnunetdatastore_la_LIBADD = \ |
31 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 31 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
32 | $(top_builddir)/src/util/libgnunetutil.la \ | 32 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
33 | $(GN_LIBINTL) | 33 | $(GN_LIBINTL) |
34 | libgnunetdatastore_la_LDFLAGS = \ | 34 | libgnunetdatastore_la_LDFLAGS = \ |
35 | $(GN_LIB_LDFLAGS) \ | 35 | $(GN_LIB_LDFLAGS) \ |
@@ -45,14 +45,14 @@ gnunet_service_datastore_SOURCES = \ | |||
45 | gnunet-service-datastore.c | 45 | gnunet-service-datastore.c |
46 | gnunet_service_datastore_LDADD = \ | 46 | gnunet_service_datastore_LDADD = \ |
47 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 47 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
48 | $(top_builddir)/src/util/libgnunetutil.la \ | 48 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
49 | $(GN_LIBINTL) | 49 | $(GN_LIBINTL) |
50 | 50 | ||
51 | gnunet_datastore_SOURCES = \ | 51 | gnunet_datastore_SOURCES = \ |
52 | gnunet-datastore.c | 52 | gnunet-datastore.c |
53 | gnunet_datastore_LDADD = \ | 53 | gnunet_datastore_LDADD = \ |
54 | libgnunetdatastore.la \ | 54 | libgnunetdatastore.la \ |
55 | $(top_builddir)/src/util/libgnunetutil.la \ | 55 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
56 | $(GN_LIBINTL) | 56 | $(GN_LIBINTL) |
57 | 57 | ||
58 | 58 | ||
@@ -99,7 +99,7 @@ libgnunet_plugin_datastore_sqlite_la_SOURCES = \ | |||
99 | libgnunet_plugin_datastore_sqlite_la_LIBADD = \ | 99 | libgnunet_plugin_datastore_sqlite_la_LIBADD = \ |
100 | $(top_builddir)/src/sq/libgnunetsq.la \ | 100 | $(top_builddir)/src/sq/libgnunetsq.la \ |
101 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 101 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
102 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) -lsqlite3 \ | 102 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) -lsqlite3 \ |
103 | $(LTLIBINTL) | 103 | $(LTLIBINTL) |
104 | libgnunet_plugin_datastore_sqlite_la_LDFLAGS = \ | 104 | libgnunet_plugin_datastore_sqlite_la_LDFLAGS = \ |
105 | $(GN_PLUGIN_LDFLAGS) | 105 | $(GN_PLUGIN_LDFLAGS) |
@@ -108,7 +108,7 @@ libgnunet_plugin_datastore_sqlite_la_LDFLAGS = \ | |||
108 | libgnunet_plugin_datastore_heap_la_SOURCES = \ | 108 | libgnunet_plugin_datastore_heap_la_SOURCES = \ |
109 | plugin_datastore_heap.c | 109 | plugin_datastore_heap.c |
110 | libgnunet_plugin_datastore_heap_la_LIBADD = \ | 110 | libgnunet_plugin_datastore_heap_la_LIBADD = \ |
111 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 111 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) \ |
112 | $(LTLIBINTL) | 112 | $(LTLIBINTL) |
113 | libgnunet_plugin_datastore_heap_la_LDFLAGS = \ | 113 | libgnunet_plugin_datastore_heap_la_LDFLAGS = \ |
114 | $(GN_PLUGIN_LDFLAGS) | 114 | $(GN_PLUGIN_LDFLAGS) |
@@ -119,7 +119,7 @@ libgnunet_plugin_datastore_postgres_la_SOURCES = \ | |||
119 | libgnunet_plugin_datastore_postgres_la_LIBADD = \ | 119 | libgnunet_plugin_datastore_postgres_la_LIBADD = \ |
120 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 120 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
121 | $(top_builddir)/src/pq/libgnunetpq.la \ | 121 | $(top_builddir)/src/pq/libgnunetpq.la \ |
122 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) -lpq | 122 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) -lpq |
123 | libgnunet_plugin_datastore_postgres_la_LDFLAGS = \ | 123 | libgnunet_plugin_datastore_postgres_la_LDFLAGS = \ |
124 | $(GN_PLUGIN_LDFLAGS) $(POSTGRESQL_LDFLAGS) | 124 | $(GN_PLUGIN_LDFLAGS) $(POSTGRESQL_LDFLAGS) |
125 | libgnunet_plugin_datastore_postgres_la_CPPFLAGS = \ | 125 | libgnunet_plugin_datastore_postgres_la_CPPFLAGS = \ |
@@ -129,7 +129,7 @@ libgnunet_plugin_datastore_postgres_la_CPPFLAGS = \ | |||
129 | libgnunet_plugin_datastore_template_la_SOURCES = \ | 129 | libgnunet_plugin_datastore_template_la_SOURCES = \ |
130 | plugin_datastore_template.c | 130 | plugin_datastore_template.c |
131 | libgnunet_plugin_datastore_template_la_LIBADD = \ | 131 | libgnunet_plugin_datastore_template_la_LIBADD = \ |
132 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 132 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) \ |
133 | $(LTLIBINTL) | 133 | $(LTLIBINTL) |
134 | libgnunet_plugin_datastore_template_la_LDFLAGS = \ | 134 | libgnunet_plugin_datastore_template_la_LDFLAGS = \ |
135 | $(GN_PLUGIN_LDFLAGS) | 135 | $(GN_PLUGIN_LDFLAGS) |
@@ -153,33 +153,33 @@ test_datastore_api_heap_SOURCES = \ | |||
153 | test_datastore_api_heap_LDADD = \ | 153 | test_datastore_api_heap_LDADD = \ |
154 | $(top_builddir)/src/testing/libgnunettesting.la \ | 154 | $(top_builddir)/src/testing/libgnunettesting.la \ |
155 | libgnunetdatastore.la \ | 155 | libgnunetdatastore.la \ |
156 | $(top_builddir)/src/util/libgnunetutil.la | 156 | $(top_builddir)/src/lib/util/libgnunetutil.la |
157 | 157 | ||
158 | test_datastore_api_management_heap_SOURCES = \ | 158 | test_datastore_api_management_heap_SOURCES = \ |
159 | test_datastore_api_management.c | 159 | test_datastore_api_management.c |
160 | test_datastore_api_management_heap_LDADD = \ | 160 | test_datastore_api_management_heap_LDADD = \ |
161 | $(top_builddir)/src/testing/libgnunettesting.la \ | 161 | $(top_builddir)/src/testing/libgnunettesting.la \ |
162 | libgnunetdatastore.la \ | 162 | libgnunetdatastore.la \ |
163 | $(top_builddir)/src/util/libgnunetutil.la | 163 | $(top_builddir)/src/lib/util/libgnunetutil.la |
164 | 164 | ||
165 | perf_datastore_api_heap_SOURCES = \ | 165 | perf_datastore_api_heap_SOURCES = \ |
166 | perf_datastore_api.c | 166 | perf_datastore_api.c |
167 | perf_datastore_api_heap_LDADD = \ | 167 | perf_datastore_api_heap_LDADD = \ |
168 | $(top_builddir)/src/testing/libgnunettesting.la \ | 168 | $(top_builddir)/src/testing/libgnunettesting.la \ |
169 | libgnunetdatastore.la \ | 169 | libgnunetdatastore.la \ |
170 | $(top_builddir)/src/util/libgnunetutil.la | 170 | $(top_builddir)/src/lib/util/libgnunetutil.la |
171 | 171 | ||
172 | perf_plugin_datastore_heap_SOURCES = \ | 172 | perf_plugin_datastore_heap_SOURCES = \ |
173 | perf_plugin_datastore.c | 173 | perf_plugin_datastore.c |
174 | perf_plugin_datastore_heap_LDADD = \ | 174 | perf_plugin_datastore_heap_LDADD = \ |
175 | $(top_builddir)/src/testing/libgnunettesting.la \ | 175 | $(top_builddir)/src/testing/libgnunettesting.la \ |
176 | $(top_builddir)/src/util/libgnunetutil.la | 176 | $(top_builddir)/src/lib/util/libgnunetutil.la |
177 | 177 | ||
178 | test_plugin_datastore_heap_SOURCES = \ | 178 | test_plugin_datastore_heap_SOURCES = \ |
179 | test_plugin_datastore.c | 179 | test_plugin_datastore.c |
180 | test_plugin_datastore_heap_LDADD = \ | 180 | test_plugin_datastore_heap_LDADD = \ |
181 | $(top_builddir)/src/testing/libgnunettesting.la \ | 181 | $(top_builddir)/src/testing/libgnunettesting.la \ |
182 | $(top_builddir)/src/util/libgnunetutil.la | 182 | $(top_builddir)/src/lib/util/libgnunetutil.la |
183 | 183 | ||
184 | 184 | ||
185 | test_datastore_api_sqlite_SOURCES = \ | 185 | test_datastore_api_sqlite_SOURCES = \ |
@@ -187,33 +187,33 @@ test_datastore_api_sqlite_SOURCES = \ | |||
187 | test_datastore_api_sqlite_LDADD = \ | 187 | test_datastore_api_sqlite_LDADD = \ |
188 | $(top_builddir)/src/testing/libgnunettesting.la \ | 188 | $(top_builddir)/src/testing/libgnunettesting.la \ |
189 | libgnunetdatastore.la \ | 189 | libgnunetdatastore.la \ |
190 | $(top_builddir)/src/util/libgnunetutil.la | 190 | $(top_builddir)/src/lib/util/libgnunetutil.la |
191 | 191 | ||
192 | test_datastore_api_management_sqlite_SOURCES = \ | 192 | test_datastore_api_management_sqlite_SOURCES = \ |
193 | test_datastore_api_management.c | 193 | test_datastore_api_management.c |
194 | test_datastore_api_management_sqlite_LDADD = \ | 194 | test_datastore_api_management_sqlite_LDADD = \ |
195 | $(top_builddir)/src/testing/libgnunettesting.la \ | 195 | $(top_builddir)/src/testing/libgnunettesting.la \ |
196 | libgnunetdatastore.la \ | 196 | libgnunetdatastore.la \ |
197 | $(top_builddir)/src/util/libgnunetutil.la | 197 | $(top_builddir)/src/lib/util/libgnunetutil.la |
198 | 198 | ||
199 | perf_datastore_api_sqlite_SOURCES = \ | 199 | perf_datastore_api_sqlite_SOURCES = \ |
200 | perf_datastore_api.c | 200 | perf_datastore_api.c |
201 | perf_datastore_api_sqlite_LDADD = \ | 201 | perf_datastore_api_sqlite_LDADD = \ |
202 | $(top_builddir)/src/testing/libgnunettesting.la \ | 202 | $(top_builddir)/src/testing/libgnunettesting.la \ |
203 | libgnunetdatastore.la \ | 203 | libgnunetdatastore.la \ |
204 | $(top_builddir)/src/util/libgnunetutil.la | 204 | $(top_builddir)/src/lib/util/libgnunetutil.la |
205 | 205 | ||
206 | perf_plugin_datastore_sqlite_SOURCES = \ | 206 | perf_plugin_datastore_sqlite_SOURCES = \ |
207 | perf_plugin_datastore.c | 207 | perf_plugin_datastore.c |
208 | perf_plugin_datastore_sqlite_LDADD = \ | 208 | perf_plugin_datastore_sqlite_LDADD = \ |
209 | $(top_builddir)/src/testing/libgnunettesting.la \ | 209 | $(top_builddir)/src/testing/libgnunettesting.la \ |
210 | $(top_builddir)/src/util/libgnunetutil.la | 210 | $(top_builddir)/src/lib/util/libgnunetutil.la |
211 | 211 | ||
212 | test_plugin_datastore_sqlite_SOURCES = \ | 212 | test_plugin_datastore_sqlite_SOURCES = \ |
213 | test_plugin_datastore.c | 213 | test_plugin_datastore.c |
214 | test_plugin_datastore_sqlite_LDADD = \ | 214 | test_plugin_datastore_sqlite_LDADD = \ |
215 | $(top_builddir)/src/testing/libgnunettesting.la \ | 215 | $(top_builddir)/src/testing/libgnunettesting.la \ |
216 | $(top_builddir)/src/util/libgnunetutil.la | 216 | $(top_builddir)/src/lib/util/libgnunetutil.la |
217 | 217 | ||
218 | 218 | ||
219 | test_datastore_api_postgres_SOURCES = \ | 219 | test_datastore_api_postgres_SOURCES = \ |
@@ -221,33 +221,33 @@ test_datastore_api_postgres_SOURCES = \ | |||
221 | test_datastore_api_postgres_LDADD = \ | 221 | test_datastore_api_postgres_LDADD = \ |
222 | $(top_builddir)/src/testing/libgnunettesting.la \ | 222 | $(top_builddir)/src/testing/libgnunettesting.la \ |
223 | libgnunetdatastore.la \ | 223 | libgnunetdatastore.la \ |
224 | $(top_builddir)/src/util/libgnunetutil.la | 224 | $(top_builddir)/src/lib/util/libgnunetutil.la |
225 | 225 | ||
226 | test_datastore_api_management_postgres_SOURCES = \ | 226 | test_datastore_api_management_postgres_SOURCES = \ |
227 | test_datastore_api_management.c | 227 | test_datastore_api_management.c |
228 | test_datastore_api_management_postgres_LDADD = \ | 228 | test_datastore_api_management_postgres_LDADD = \ |
229 | $(top_builddir)/src/testing/libgnunettesting.la \ | 229 | $(top_builddir)/src/testing/libgnunettesting.la \ |
230 | libgnunetdatastore.la \ | 230 | libgnunetdatastore.la \ |
231 | $(top_builddir)/src/util/libgnunetutil.la | 231 | $(top_builddir)/src/lib/util/libgnunetutil.la |
232 | 232 | ||
233 | perf_datastore_api_postgres_SOURCES = \ | 233 | perf_datastore_api_postgres_SOURCES = \ |
234 | perf_datastore_api.c | 234 | perf_datastore_api.c |
235 | perf_datastore_api_postgres_LDADD = \ | 235 | perf_datastore_api_postgres_LDADD = \ |
236 | $(top_builddir)/src/testing/libgnunettesting.la \ | 236 | $(top_builddir)/src/testing/libgnunettesting.la \ |
237 | libgnunetdatastore.la \ | 237 | libgnunetdatastore.la \ |
238 | $(top_builddir)/src/util/libgnunetutil.la | 238 | $(top_builddir)/src/lib/util/libgnunetutil.la |
239 | 239 | ||
240 | test_plugin_datastore_postgres_SOURCES = \ | 240 | test_plugin_datastore_postgres_SOURCES = \ |
241 | test_plugin_datastore.c | 241 | test_plugin_datastore.c |
242 | test_plugin_datastore_postgres_LDADD = \ | 242 | test_plugin_datastore_postgres_LDADD = \ |
243 | $(top_builddir)/src/testing/libgnunettesting.la \ | 243 | $(top_builddir)/src/testing/libgnunettesting.la \ |
244 | $(top_builddir)/src/util/libgnunetutil.la | 244 | $(top_builddir)/src/lib/util/libgnunetutil.la |
245 | 245 | ||
246 | perf_plugin_datastore_postgres_SOURCES = \ | 246 | perf_plugin_datastore_postgres_SOURCES = \ |
247 | perf_plugin_datastore.c | 247 | perf_plugin_datastore.c |
248 | perf_plugin_datastore_postgres_LDADD = \ | 248 | perf_plugin_datastore_postgres_LDADD = \ |
249 | $(top_builddir)/src/testing/libgnunettesting.la \ | 249 | $(top_builddir)/src/testing/libgnunettesting.la \ |
250 | $(top_builddir)/src/util/libgnunetutil.la | 250 | $(top_builddir)/src/lib/util/libgnunetutil.la |
251 | 251 | ||
252 | 252 | ||
253 | EXTRA_DIST = \ | 253 | EXTRA_DIST = \ |
diff --git a/src/dht/Makefile.am b/src/dht/Makefile.am index 62b093c5d..1e3a5f8f8 100644 --- a/src/dht/Makefile.am +++ b/src/dht/Makefile.am | |||
@@ -21,7 +21,7 @@ lib_LTLIBRARIES = \ | |||
21 | libgnunetdht_la_SOURCES = \ | 21 | libgnunetdht_la_SOURCES = \ |
22 | dht_api.c dht.h | 22 | dht_api.c dht.h |
23 | libgnunetdht_la_LIBADD = \ | 23 | libgnunetdht_la_LIBADD = \ |
24 | $(top_builddir)/src/util/libgnunetutil.la \ | 24 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
25 | $(XLIB) \ | 25 | $(XLIB) \ |
26 | $(LTLIBINTL) | 26 | $(LTLIBINTL) |
27 | libgnunetdht_la_LDFLAGS = \ | 27 | libgnunetdht_la_LDFLAGS = \ |
@@ -35,10 +35,10 @@ plugin_LTLIBRARIES = \ | |||
35 | libgnunet_plugin_block_dht_la_SOURCES = \ | 35 | libgnunet_plugin_block_dht_la_SOURCES = \ |
36 | plugin_block_dht.c | 36 | plugin_block_dht.c |
37 | libgnunet_plugin_block_dht_la_LIBADD = \ | 37 | libgnunet_plugin_block_dht_la_LIBADD = \ |
38 | $(top_builddir)/src/hello/libgnunethello.la \ | 38 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
39 | $(top_builddir)/src/block/libgnunetblock.la \ | 39 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
40 | $(top_builddir)/src/block/libgnunetblockgroup.la \ | 40 | $(top_builddir)/src/lib/block/libgnunetblockgroup.la \ |
41 | $(top_builddir)/src/util/libgnunetutil.la \ | 41 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
42 | $(LTLIBINTL) | 42 | $(LTLIBINTL) |
43 | libgnunet_plugin_block_dht_la_LDFLAGS = \ | 43 | libgnunet_plugin_block_dht_la_LDFLAGS = \ |
44 | $(GN_PLUGIN_LDFLAGS) | 44 | $(GN_PLUGIN_LDFLAGS) |
@@ -64,11 +64,11 @@ gnunet_service_dht_LDADD = \ | |||
64 | $(top_builddir)/src/core/libgnunetcore.la \ | 64 | $(top_builddir)/src/core/libgnunetcore.la \ |
65 | $(top_builddir)/src/nse/libgnunetnse.la \ | 65 | $(top_builddir)/src/nse/libgnunetnse.la \ |
66 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 66 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
67 | $(top_builddir)/src/hello/libgnunethello.la \ | 67 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
68 | $(top_builddir)/src/block/libgnunetblock.la \ | 68 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
69 | $(top_builddir)/src/block/libgnunetblockgroup.la \ | 69 | $(top_builddir)/src/lib/block/libgnunetblockgroup.la \ |
70 | $(top_builddir)/src/datacache/libgnunetdatacache.la \ | 70 | $(top_builddir)/src/datacache/libgnunetdatacache.la \ |
71 | $(top_builddir)/src/util/libgnunetutil.la \ | 71 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
72 | -lm | 72 | -lm |
73 | gnunet_service_dht_LDFLAGS = \ | 73 | gnunet_service_dht_LDFLAGS = \ |
74 | $(GN_LIBINTL) | 74 | $(GN_LIBINTL) |
@@ -77,7 +77,7 @@ gnunet_dht_get_SOURCES = \ | |||
77 | gnunet-dht-get.c | 77 | gnunet-dht-get.c |
78 | gnunet_dht_get_LDADD = \ | 78 | gnunet_dht_get_LDADD = \ |
79 | libgnunetdht.la \ | 79 | libgnunetdht.la \ |
80 | $(top_builddir)/src/util/libgnunetutil.la | 80 | $(top_builddir)/src/lib/util/libgnunetutil.la |
81 | gnunet_dht_get_LDFLAGS = \ | 81 | gnunet_dht_get_LDFLAGS = \ |
82 | $(GN_LIBINTL) | 82 | $(GN_LIBINTL) |
83 | 83 | ||
@@ -85,7 +85,7 @@ gnunet_dht_hello_SOURCES = \ | |||
85 | gnunet-dht-hello.c | 85 | gnunet-dht-hello.c |
86 | gnunet_dht_hello_LDADD = \ | 86 | gnunet_dht_hello_LDADD = \ |
87 | libgnunetdht.la \ | 87 | libgnunetdht.la \ |
88 | $(top_builddir)/src/util/libgnunetutil.la | 88 | $(top_builddir)/src/lib/util/libgnunetutil.la |
89 | gnunet_dht_hello_LDFLAGS = \ | 89 | gnunet_dht_hello_LDFLAGS = \ |
90 | $(GN_LIBINTL) | 90 | $(GN_LIBINTL) |
91 | 91 | ||
@@ -93,7 +93,7 @@ gnunet_dht_put_SOURCES = \ | |||
93 | gnunet-dht-put.c | 93 | gnunet-dht-put.c |
94 | gnunet_dht_put_LDADD = \ | 94 | gnunet_dht_put_LDADD = \ |
95 | libgnunetdht.la \ | 95 | libgnunetdht.la \ |
96 | $(top_builddir)/src/util/libgnunetutil.la | 96 | $(top_builddir)/src/lib/util/libgnunetutil.la |
97 | gnunet_dht_put_LDFLAGS = \ | 97 | gnunet_dht_put_LDFLAGS = \ |
98 | $(GN_LIBINTL) | 98 | $(GN_LIBINTL) |
99 | 99 | ||
@@ -101,7 +101,7 @@ gnunet_dht_monitor_SOURCES = \ | |||
101 | gnunet-dht-monitor.c | 101 | gnunet-dht-monitor.c |
102 | gnunet_dht_monitor_LDADD = \ | 102 | gnunet_dht_monitor_LDADD = \ |
103 | libgnunetdht.la \ | 103 | libgnunetdht.la \ |
104 | $(top_builddir)/src/util/libgnunetutil.la | 104 | $(top_builddir)/src/lib/util/libgnunetutil.la |
105 | gnunet_dht_monitor_LDFLAGS = \ | 105 | gnunet_dht_monitor_LDFLAGS = \ |
106 | $(GN_LIBINTL) | 106 | $(GN_LIBINTL) |
107 | 107 | ||
@@ -112,9 +112,9 @@ endif | |||
112 | test_dht_api_SOURCES = \ | 112 | test_dht_api_SOURCES = \ |
113 | test_dht_api.c | 113 | test_dht_api.c |
114 | test_dht_api_LDADD = \ | 114 | test_dht_api_LDADD = \ |
115 | $(top_builddir)/src/util/libgnunetutil.la \ | 115 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
116 | $(top_builddir)/src/testing/libgnunettesting.la \ | 116 | $(top_builddir)/src/testing/libgnunettesting.la \ |
117 | $(top_builddir)/src/hello/libgnunethello.la \ | 117 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
118 | libgnunetdht.la | 118 | libgnunetdht.la |
119 | 119 | ||
120 | EXTRA_DIST = \ | 120 | EXTRA_DIST = \ |
diff --git a/src/dhtu/Makefile.am b/src/dhtu/Makefile.am index 732b37ff7..a22a72c89 100644 --- a/src/dhtu/Makefile.am +++ b/src/dhtu/Makefile.am | |||
@@ -22,7 +22,7 @@ plugin_LTLIBRARIES += libgnunet_plugin_dhtu_ip.la | |||
22 | libgnunet_plugin_dhtu_ip_la_SOURCES = \ | 22 | libgnunet_plugin_dhtu_ip_la_SOURCES = \ |
23 | plugin_dhtu_ip.c | 23 | plugin_dhtu_ip.c |
24 | libgnunet_plugin_dhtu_ip_la_LIBADD = \ | 24 | libgnunet_plugin_dhtu_ip_la_LIBADD = \ |
25 | $(top_builddir)/src/util/libgnunetutil.la \ | 25 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
26 | $(XLIBS) \ | 26 | $(XLIBS) \ |
27 | $(LTLIBINTL) | 27 | $(LTLIBINTL) |
28 | libgnunet_plugin_dhtu_ip_la_LDFLAGS = \ | 28 | libgnunet_plugin_dhtu_ip_la_LDFLAGS = \ |
@@ -36,9 +36,9 @@ libgnunet_plugin_dhtu_gnunet_la_LIBADD = \ | |||
36 | $(top_builddir)/src/core/libgnunetcore.la \ | 36 | $(top_builddir)/src/core/libgnunetcore.la \ |
37 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 37 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
38 | $(top_builddir)/src/transport/libgnunettransportapplication.la \ | 38 | $(top_builddir)/src/transport/libgnunettransportapplication.la \ |
39 | $(top_builddir)/src/hello/libgnunethello.la \ | 39 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
40 | $(top_builddir)/src/nse/libgnunetnse.la \ | 40 | $(top_builddir)/src/nse/libgnunetnse.la \ |
41 | $(top_builddir)/src/util/libgnunetutil.la \ | 41 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
42 | $(XLIBS) \ | 42 | $(XLIBS) \ |
43 | $(LTLIBINTL) | 43 | $(LTLIBINTL) |
44 | libgnunet_plugin_dhtu_gnunet_la_LDFLAGS = \ | 44 | libgnunet_plugin_dhtu_gnunet_la_LDFLAGS = \ |
@@ -53,7 +53,7 @@ libgnunettestingdhtu_la_SOURCES = \ | |||
53 | libgnunettestingdhtu_la_LIBADD = \ | 53 | libgnunettestingdhtu_la_LIBADD = \ |
54 | $(top_builddir)/src/testing/libgnunettesting.la \ | 54 | $(top_builddir)/src/testing/libgnunettesting.la \ |
55 | $(top_builddir)/src/arm/libgnunetarm.la \ | 55 | $(top_builddir)/src/arm/libgnunetarm.la \ |
56 | $(top_builddir)/src/util/libgnunetutil.la \ | 56 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
57 | $(LTLIBINTL) | 57 | $(LTLIBINTL) |
58 | libgnunettestingdhtu_la_LDFLAGS = \ | 58 | libgnunettestingdhtu_la_LDFLAGS = \ |
59 | $(GN_LIB_LDFLAGS) \ | 59 | $(GN_LIB_LDFLAGS) \ |
@@ -66,7 +66,7 @@ test_dhtu_ip_SOURCES = \ | |||
66 | test_dhtu_ip_LDADD = \ | 66 | test_dhtu_ip_LDADD = \ |
67 | $(top_builddir)/src/testing/libgnunettesting.la \ | 67 | $(top_builddir)/src/testing/libgnunettesting.la \ |
68 | $(top_builddir)/src/arm/libgnunetarm.la \ | 68 | $(top_builddir)/src/arm/libgnunetarm.la \ |
69 | $(top_builddir)/src/util/libgnunetutil.la | 69 | $(top_builddir)/src/lib/util/libgnunetutil.la |
70 | 70 | ||
71 | check_PROGRAMS = \ | 71 | check_PROGRAMS = \ |
72 | test_dhtu_ip | 72 | test_dhtu_ip |
diff --git a/src/dns/Makefile.am b/src/dns/Makefile.am index f8672d55e..6c7462d9a 100644 --- a/src/dns/Makefile.am +++ b/src/dns/Makefile.am | |||
@@ -45,33 +45,33 @@ gnunet_dns_monitor_SOURCES = \ | |||
45 | gnunet-dns-monitor.c | 45 | gnunet-dns-monitor.c |
46 | gnunet_dns_monitor_LDADD = \ | 46 | gnunet_dns_monitor_LDADD = \ |
47 | libgnunetdns.la \ | 47 | libgnunetdns.la \ |
48 | $(top_builddir)/src/util/libgnunetutil.la \ | 48 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
49 | $(GN_LIBINTL) | 49 | $(GN_LIBINTL) |
50 | 50 | ||
51 | gnunet_zonewalk_SOURCES = \ | 51 | gnunet_zonewalk_SOURCES = \ |
52 | gnunet-zonewalk.c | 52 | gnunet-zonewalk.c |
53 | gnunet_zonewalk_LDADD = \ | 53 | gnunet_zonewalk_LDADD = \ |
54 | $(top_builddir)/src/util/libgnunetutil.la \ | 54 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
55 | $(GN_LIBINTL) | 55 | $(GN_LIBINTL) |
56 | 56 | ||
57 | gnunet_dns_redirector_SOURCES = \ | 57 | gnunet_dns_redirector_SOURCES = \ |
58 | gnunet-dns-redirector.c | 58 | gnunet-dns-redirector.c |
59 | gnunet_dns_redirector_LDADD = \ | 59 | gnunet_dns_redirector_LDADD = \ |
60 | libgnunetdns.la \ | 60 | libgnunetdns.la \ |
61 | $(top_builddir)/src/util/libgnunetutil.la \ | 61 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
62 | $(GN_LIBINTL) | 62 | $(GN_LIBINTL) |
63 | 63 | ||
64 | gnunet_service_dns_SOURCES = \ | 64 | gnunet_service_dns_SOURCES = \ |
65 | gnunet-service-dns.c | 65 | gnunet-service-dns.c |
66 | gnunet_service_dns_LDADD = \ | 66 | gnunet_service_dns_LDADD = \ |
67 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 67 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
68 | $(top_builddir)/src/util/libgnunetutil.la \ | 68 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
69 | $(GN_LIBINTL) | 69 | $(GN_LIBINTL) |
70 | 70 | ||
71 | libgnunetdns_la_SOURCES = \ | 71 | libgnunetdns_la_SOURCES = \ |
72 | dns_api.c dns.h | 72 | dns_api.c dns.h |
73 | libgnunetdns_la_LIBADD = \ | 73 | libgnunetdns_la_LIBADD = \ |
74 | $(top_builddir)/src/util/libgnunetutil.la $(XLIB) | 74 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIB) |
75 | libgnunetdns_la_LDFLAGS = \ | 75 | libgnunetdns_la_LDFLAGS = \ |
76 | $(GN_LIBINTL) \ | 76 | $(GN_LIBINTL) \ |
77 | $(GN_LIB_LDFLAGS) \ | 77 | $(GN_LIB_LDFLAGS) \ |
@@ -80,9 +80,9 @@ libgnunetdns_la_LDFLAGS = \ | |||
80 | libgnunet_plugin_block_dns_la_SOURCES = \ | 80 | libgnunet_plugin_block_dns_la_SOURCES = \ |
81 | plugin_block_dns.c | 81 | plugin_block_dns.c |
82 | libgnunet_plugin_block_dns_la_LIBADD = \ | 82 | libgnunet_plugin_block_dns_la_LIBADD = \ |
83 | $(top_builddir)/src/block/libgnunetblockgroup.la \ | 83 | $(top_builddir)/src/lib/block/libgnunetblockgroup.la \ |
84 | $(top_builddir)/src/block/libgnunetblock.la \ | 84 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
85 | $(top_builddir)/src/util/libgnunetutil.la | 85 | $(top_builddir)/src/lib/util/libgnunetutil.la |
86 | libgnunet_plugin_block_dns_la_LDFLAGS = \ | 86 | libgnunet_plugin_block_dns_la_LDFLAGS = \ |
87 | $(GN_LIBINTL) \ | 87 | $(GN_LIBINTL) \ |
88 | $(top_builddir)/src/block/$(GN_PLUGIN_LDFLAGS) | 88 | $(top_builddir)/src/block/$(GN_PLUGIN_LDFLAGS) |
diff --git a/src/exit/Makefile.am b/src/exit/Makefile.am index c0323d0d6..9e36a5064 100644 --- a/src/exit/Makefile.am +++ b/src/exit/Makefile.am | |||
@@ -32,7 +32,7 @@ gnunet_daemon_exit_SOURCES = \ | |||
32 | gnunet_daemon_exit_LDADD = \ | 32 | gnunet_daemon_exit_LDADD = \ |
33 | $(top_builddir)/src/dht/libgnunetdht.la \ | 33 | $(top_builddir)/src/dht/libgnunetdht.la \ |
34 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 34 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
35 | $(top_builddir)/src/util/libgnunetutil.la \ | 35 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
36 | $(top_builddir)/src/cadet/libgnunetcadet.la \ | 36 | $(top_builddir)/src/cadet/libgnunetcadet.la \ |
37 | $(top_builddir)/src/regex/libgnunetregex.la \ | 37 | $(top_builddir)/src/regex/libgnunetregex.la \ |
38 | $(GN_LIBINTL) | 38 | $(GN_LIBINTL) |
diff --git a/src/fs/Makefile.am b/src/fs/Makefile.am index 9a7ff0011..573063301 100644 --- a/src/fs/Makefile.am +++ b/src/fs/Makefile.am | |||
@@ -44,7 +44,7 @@ libgnunetfs_la_SOURCES = \ | |||
44 | libgnunetfs_la_LIBADD = \ | 44 | libgnunetfs_la_LIBADD = \ |
45 | $(top_builddir)/src/datastore/libgnunetdatastore.la \ | 45 | $(top_builddir)/src/datastore/libgnunetdatastore.la \ |
46 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 46 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
47 | $(top_builddir)/src/util/libgnunetutil.la \ | 47 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
48 | $(GN_LIBINTL) $(XLIB) $(LIBGCRYPT_LIBS) -lunistring | 48 | $(GN_LIBINTL) $(XLIB) $(LIBGCRYPT_LIBS) -lunistring |
49 | 49 | ||
50 | if HAVE_LIBEXTRACTOR | 50 | if HAVE_LIBEXTRACTOR |
@@ -77,7 +77,7 @@ gnunet_directory_SOURCES = \ | |||
77 | gnunet-directory.c | 77 | gnunet-directory.c |
78 | gnunet_directory_LDADD = \ | 78 | gnunet_directory_LDADD = \ |
79 | libgnunetfs.la \ | 79 | libgnunetfs.la \ |
80 | $(top_builddir)/src/util/libgnunetutil.la \ | 80 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
81 | $(GN_LIBINTL) | 81 | $(GN_LIBINTL) |
82 | 82 | ||
83 | if HAVE_LIBEXTRACTOR | 83 | if HAVE_LIBEXTRACTOR |
@@ -89,7 +89,7 @@ gnunet_fs_SOURCES = \ | |||
89 | gnunet-fs.c | 89 | gnunet-fs.c |
90 | gnunet_fs_LDADD = \ | 90 | gnunet_fs_LDADD = \ |
91 | libgnunetfs.la \ | 91 | libgnunetfs.la \ |
92 | $(top_builddir)/src/util/libgnunetutil.la \ | 92 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
93 | $(GN_LIBINTL) | 93 | $(GN_LIBINTL) |
94 | 94 | ||
95 | if HAVE_LIBEXTRACTOR | 95 | if HAVE_LIBEXTRACTOR |
@@ -101,7 +101,7 @@ gnunet_download_SOURCES = \ | |||
101 | gnunet-download.c | 101 | gnunet-download.c |
102 | gnunet_download_LDADD = \ | 102 | gnunet_download_LDADD = \ |
103 | libgnunetfs.la \ | 103 | libgnunetfs.la \ |
104 | $(top_builddir)/src/util/libgnunetutil.la \ | 104 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
105 | $(GN_LIBINTL) | 105 | $(GN_LIBINTL) |
106 | 106 | ||
107 | gnunet_publish_SOURCES = \ | 107 | gnunet_publish_SOURCES = \ |
@@ -109,7 +109,7 @@ gnunet_publish_SOURCES = \ | |||
109 | gnunet_publish_LDADD = \ | 109 | gnunet_publish_LDADD = \ |
110 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 110 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
111 | libgnunetfs.la \ | 111 | libgnunetfs.la \ |
112 | $(top_builddir)/src/util/libgnunetutil.la \ | 112 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
113 | $(GN_LIBINTL) | 113 | $(GN_LIBINTL) |
114 | 114 | ||
115 | if HAVE_LIBEXTRACTOR | 115 | if HAVE_LIBEXTRACTOR |
@@ -120,7 +120,7 @@ endif | |||
120 | gnunet_auto_share_SOURCES = \ | 120 | gnunet_auto_share_SOURCES = \ |
121 | gnunet-auto-share.c | 121 | gnunet-auto-share.c |
122 | gnunet_auto_share_LDADD = \ | 122 | gnunet_auto_share_LDADD = \ |
123 | $(top_builddir)/src/util/libgnunetutil.la \ | 123 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
124 | $(GN_LIBINTL) | 124 | $(GN_LIBINTL) |
125 | 125 | ||
126 | if HAVE_LIBEXTRACTOR | 126 | if HAVE_LIBEXTRACTOR |
@@ -132,7 +132,7 @@ gnunet_helper_fs_publish_SOURCES = \ | |||
132 | gnunet-helper-fs-publish.c | 132 | gnunet-helper-fs-publish.c |
133 | gnunet_helper_fs_publish_LDADD = \ | 133 | gnunet_helper_fs_publish_LDADD = \ |
134 | libgnunetfs.la \ | 134 | libgnunetfs.la \ |
135 | $(top_builddir)/src/util/libgnunetutil.la \ | 135 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
136 | $(GN_LIBINTL) | 136 | $(GN_LIBINTL) |
137 | 137 | ||
138 | if HAVE_LIBEXTRACTOR | 138 | if HAVE_LIBEXTRACTOR |
@@ -144,7 +144,7 @@ gnunet_search_SOURCES = \ | |||
144 | gnunet-search.c | 144 | gnunet-search.c |
145 | gnunet_search_LDADD = \ | 145 | gnunet_search_LDADD = \ |
146 | libgnunetfs.la \ | 146 | libgnunetfs.la \ |
147 | $(top_builddir)/src/util/libgnunetutil.la \ | 147 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
148 | $(GN_LIBINTL) | 148 | $(GN_LIBINTL) |
149 | 149 | ||
150 | if HAVE_LIBEXTRACTOR | 150 | if HAVE_LIBEXTRACTOR |
@@ -158,7 +158,7 @@ gnunet_daemon_fsprofiler_SOURCES = \ | |||
158 | gnunet_daemon_fsprofiler_LDADD = \ | 158 | gnunet_daemon_fsprofiler_LDADD = \ |
159 | libgnunetfs.la \ | 159 | libgnunetfs.la \ |
160 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 160 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
161 | $(top_builddir)/src/util/libgnunetutil.la \ | 161 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
162 | $(GN_LIBINTL) | 162 | $(GN_LIBINTL) |
163 | 163 | ||
164 | gnunet_service_fs_SOURCES = \ | 164 | gnunet_service_fs_SOURCES = \ |
@@ -174,12 +174,12 @@ gnunet_service_fs_SOURCES = \ | |||
174 | gnunet_service_fs_LDADD = \ | 174 | gnunet_service_fs_LDADD = \ |
175 | libgnunetfs.la \ | 175 | libgnunetfs.la \ |
176 | $(top_builddir)/src/dht/libgnunetdht.la \ | 176 | $(top_builddir)/src/dht/libgnunetdht.la \ |
177 | $(top_builddir)/src/block/libgnunetblock.la \ | 177 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
178 | $(top_builddir)/src/datastore/libgnunetdatastore.la \ | 178 | $(top_builddir)/src/datastore/libgnunetdatastore.la \ |
179 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 179 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
180 | $(top_builddir)/src/cadet/libgnunetcadet.la \ | 180 | $(top_builddir)/src/cadet/libgnunetcadet.la \ |
181 | $(top_builddir)/src/core/libgnunetcore.la \ | 181 | $(top_builddir)/src/core/libgnunetcore.la \ |
182 | $(top_builddir)/src/util/libgnunetutil.la \ | 182 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
183 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 183 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
184 | $(GN_LIBINTL) -lm | 184 | $(GN_LIBINTL) -lm |
185 | 185 | ||
@@ -187,16 +187,16 @@ gnunet_unindex_SOURCES = \ | |||
187 | gnunet-unindex.c | 187 | gnunet-unindex.c |
188 | gnunet_unindex_LDADD = \ | 188 | gnunet_unindex_LDADD = \ |
189 | libgnunetfs.la \ | 189 | libgnunetfs.la \ |
190 | $(top_builddir)/src/util/libgnunetutil.la \ | 190 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
191 | $(GN_LIBINTL) | 191 | $(GN_LIBINTL) |
192 | 192 | ||
193 | libgnunet_plugin_block_fs_la_SOURCES = \ | 193 | libgnunet_plugin_block_fs_la_SOURCES = \ |
194 | plugin_block_fs.c | 194 | plugin_block_fs.c |
195 | libgnunet_plugin_block_fs_la_LIBADD = \ | 195 | libgnunet_plugin_block_fs_la_LIBADD = \ |
196 | $(top_builddir)/src/block/libgnunetblockgroup.la \ | 196 | $(top_builddir)/src/lib/block/libgnunetblockgroup.la \ |
197 | $(top_builddir)/src/block/libgnunetblock.la \ | 197 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
198 | libgnunetfs.la \ | 198 | libgnunetfs.la \ |
199 | $(top_builddir)/src/util/libgnunetutil.la \ | 199 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
200 | $(LTLIBINTL) | 200 | $(LTLIBINTL) |
201 | libgnunet_plugin_block_fs_la_LDFLAGS = \ | 201 | libgnunet_plugin_block_fs_la_LDFLAGS = \ |
202 | $(GN_PLUGIN_LDFLAGS) | 202 | $(GN_PLUGIN_LDFLAGS) |
@@ -231,8 +231,8 @@ check_PROGRAMS = \ | |||
231 | test_plugin_block_fs_SOURCES = \ | 231 | test_plugin_block_fs_SOURCES = \ |
232 | test_plugin_block_fs.c | 232 | test_plugin_block_fs.c |
233 | test_plugin_block_fs_LDADD = \ | 233 | test_plugin_block_fs_LDADD = \ |
234 | $(top_builddir)/src/block/libgnunetblock.la \ | 234 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
235 | $(top_builddir)/src/util/libgnunetutil.la | 235 | $(top_builddir)/src/lib/util/libgnunetutil.la |
236 | 236 | ||
237 | if HAVE_PYTHON | 237 | if HAVE_PYTHON |
238 | check_SCRIPTS = \ | 238 | check_SCRIPTS = \ |
@@ -267,7 +267,7 @@ test_fs_directory_SOURCES = \ | |||
267 | test_fs_directory.c | 267 | test_fs_directory.c |
268 | test_fs_directory_LDADD = \ | 268 | test_fs_directory_LDADD = \ |
269 | libgnunetfs.la \ | 269 | libgnunetfs.la \ |
270 | $(top_builddir)/src/util/libgnunetutil.la | 270 | $(top_builddir)/src/lib/util/libgnunetutil.la |
271 | 271 | ||
272 | if HAVE_LIBEXTRACTOR | 272 | if HAVE_LIBEXTRACTOR |
273 | test_fs_directory_LDADD += \ | 273 | test_fs_directory_LDADD += \ |
@@ -280,34 +280,34 @@ test_fs_download_SOURCES = \ | |||
280 | test_fs_download_LDADD = \ | 280 | test_fs_download_LDADD = \ |
281 | $(top_builddir)/src/testing/libgnunettesting.la \ | 281 | $(top_builddir)/src/testing/libgnunettesting.la \ |
282 | libgnunetfs.la \ | 282 | libgnunetfs.la \ |
283 | $(top_builddir)/src/util/libgnunetutil.la | 283 | $(top_builddir)/src/lib/util/libgnunetutil.la |
284 | 284 | ||
285 | test_fs_download_indexed_SOURCES = \ | 285 | test_fs_download_indexed_SOURCES = \ |
286 | test_fs_download.c | 286 | test_fs_download.c |
287 | test_fs_download_indexed_LDADD = \ | 287 | test_fs_download_indexed_LDADD = \ |
288 | $(top_builddir)/src/testing/libgnunettesting.la \ | 288 | $(top_builddir)/src/testing/libgnunettesting.la \ |
289 | libgnunetfs.la \ | 289 | libgnunetfs.la \ |
290 | $(top_builddir)/src/util/libgnunetutil.la | 290 | $(top_builddir)/src/lib/util/libgnunetutil.la |
291 | 291 | ||
292 | test_fs_download_cadet_SOURCES = \ | 292 | test_fs_download_cadet_SOURCES = \ |
293 | test_fs_download.c | 293 | test_fs_download.c |
294 | test_fs_download_cadet_LDADD = \ | 294 | test_fs_download_cadet_LDADD = \ |
295 | $(top_builddir)/src/testing/libgnunettesting.la \ | 295 | $(top_builddir)/src/testing/libgnunettesting.la \ |
296 | libgnunetfs.la \ | 296 | libgnunetfs.la \ |
297 | $(top_builddir)/src/util/libgnunetutil.la | 297 | $(top_builddir)/src/lib/util/libgnunetutil.la |
298 | 298 | ||
299 | test_fs_download_persistence_SOURCES = \ | 299 | test_fs_download_persistence_SOURCES = \ |
300 | test_fs_download_persistence.c | 300 | test_fs_download_persistence.c |
301 | test_fs_download_persistence_LDADD = \ | 301 | test_fs_download_persistence_LDADD = \ |
302 | $(top_builddir)/src/testing/libgnunettesting.la \ | 302 | $(top_builddir)/src/testing/libgnunettesting.la \ |
303 | libgnunetfs.la \ | 303 | libgnunetfs.la \ |
304 | $(top_builddir)/src/util/libgnunetutil.la | 304 | $(top_builddir)/src/lib/util/libgnunetutil.la |
305 | 305 | ||
306 | test_fs_file_information_SOURCES = \ | 306 | test_fs_file_information_SOURCES = \ |
307 | test_fs_file_information.c | 307 | test_fs_file_information.c |
308 | test_fs_file_information_LDADD = \ | 308 | test_fs_file_information_LDADD = \ |
309 | libgnunetfs.la \ | 309 | libgnunetfs.la \ |
310 | $(top_builddir)/src/util/libgnunetutil.la | 310 | $(top_builddir)/src/lib/util/libgnunetutil.la |
311 | 311 | ||
312 | if HAVE_LIBEXTRACTOR | 312 | if HAVE_LIBEXTRACTOR |
313 | test_fs_file_information_LDADD += \ | 313 | test_fs_file_information_LDADD += \ |
@@ -319,104 +319,104 @@ test_fs_getopt_SOURCES = \ | |||
319 | test_fs_getopt.c | 319 | test_fs_getopt.c |
320 | test_fs_getopt_LDADD = \ | 320 | test_fs_getopt_LDADD = \ |
321 | libgnunetfs.la \ | 321 | libgnunetfs.la \ |
322 | $(top_builddir)/src/util/libgnunetutil.la | 322 | $(top_builddir)/src/lib/util/libgnunetutil.la |
323 | 323 | ||
324 | test_fs_list_indexed_SOURCES = \ | 324 | test_fs_list_indexed_SOURCES = \ |
325 | test_fs_list_indexed.c | 325 | test_fs_list_indexed.c |
326 | test_fs_list_indexed_LDADD = \ | 326 | test_fs_list_indexed_LDADD = \ |
327 | $(top_builddir)/src/testing/libgnunettesting.la \ | 327 | $(top_builddir)/src/testing/libgnunettesting.la \ |
328 | libgnunetfs.la \ | 328 | libgnunetfs.la \ |
329 | $(top_builddir)/src/util/libgnunetutil.la | 329 | $(top_builddir)/src/lib/util/libgnunetutil.la |
330 | 330 | ||
331 | test_fs_namespace_SOURCES = \ | 331 | test_fs_namespace_SOURCES = \ |
332 | test_fs_namespace.c | 332 | test_fs_namespace.c |
333 | test_fs_namespace_LDADD = \ | 333 | test_fs_namespace_LDADD = \ |
334 | $(top_builddir)/src/testing/libgnunettesting.la \ | 334 | $(top_builddir)/src/testing/libgnunettesting.la \ |
335 | libgnunetfs.la \ | 335 | libgnunetfs.la \ |
336 | $(top_builddir)/src/util/libgnunetutil.la | 336 | $(top_builddir)/src/lib/util/libgnunetutil.la |
337 | 337 | ||
338 | test_fs_namespace_list_updateable_SOURCES = \ | 338 | test_fs_namespace_list_updateable_SOURCES = \ |
339 | test_fs_namespace_list_updateable.c | 339 | test_fs_namespace_list_updateable.c |
340 | test_fs_namespace_list_updateable_LDADD = \ | 340 | test_fs_namespace_list_updateable_LDADD = \ |
341 | $(top_builddir)/src/testing/libgnunettesting.la \ | 341 | $(top_builddir)/src/testing/libgnunettesting.la \ |
342 | libgnunetfs.la \ | 342 | libgnunetfs.la \ |
343 | $(top_builddir)/src/util/libgnunetutil.la | 343 | $(top_builddir)/src/lib/util/libgnunetutil.la |
344 | 344 | ||
345 | test_fs_publish_SOURCES = \ | 345 | test_fs_publish_SOURCES = \ |
346 | test_fs_publish.c | 346 | test_fs_publish.c |
347 | test_fs_publish_LDADD = \ | 347 | test_fs_publish_LDADD = \ |
348 | $(top_builddir)/src/testing/libgnunettesting.la \ | 348 | $(top_builddir)/src/testing/libgnunettesting.la \ |
349 | libgnunetfs.la \ | 349 | libgnunetfs.la \ |
350 | $(top_builddir)/src/util/libgnunetutil.la | 350 | $(top_builddir)/src/lib/util/libgnunetutil.la |
351 | 351 | ||
352 | test_fs_publish_persistence_SOURCES = \ | 352 | test_fs_publish_persistence_SOURCES = \ |
353 | test_fs_publish_persistence.c | 353 | test_fs_publish_persistence.c |
354 | test_fs_publish_persistence_LDADD = \ | 354 | test_fs_publish_persistence_LDADD = \ |
355 | $(top_builddir)/src/testing/libgnunettesting.la \ | 355 | $(top_builddir)/src/testing/libgnunettesting.la \ |
356 | libgnunetfs.la \ | 356 | libgnunetfs.la \ |
357 | $(top_builddir)/src/util/libgnunetutil.la | 357 | $(top_builddir)/src/lib/util/libgnunetutil.la |
358 | 358 | ||
359 | test_fs_search_SOURCES = \ | 359 | test_fs_search_SOURCES = \ |
360 | test_fs_search.c | 360 | test_fs_search.c |
361 | test_fs_search_LDADD = \ | 361 | test_fs_search_LDADD = \ |
362 | $(top_builddir)/src/testing/libgnunettesting.la \ | 362 | $(top_builddir)/src/testing/libgnunettesting.la \ |
363 | libgnunetfs.la \ | 363 | libgnunetfs.la \ |
364 | $(top_builddir)/src/util/libgnunetutil.la | 364 | $(top_builddir)/src/lib/util/libgnunetutil.la |
365 | 365 | ||
366 | test_fs_search_with_and_SOURCES = \ | 366 | test_fs_search_with_and_SOURCES = \ |
367 | test_fs_search_with_and.c | 367 | test_fs_search_with_and.c |
368 | test_fs_search_with_and_LDADD = \ | 368 | test_fs_search_with_and_LDADD = \ |
369 | $(top_builddir)/src/testing/libgnunettesting.la \ | 369 | $(top_builddir)/src/testing/libgnunettesting.la \ |
370 | libgnunetfs.la \ | 370 | libgnunetfs.la \ |
371 | $(top_builddir)/src/util/libgnunetutil.la | 371 | $(top_builddir)/src/lib/util/libgnunetutil.la |
372 | 372 | ||
373 | test_fs_search_probes_SOURCES = \ | 373 | test_fs_search_probes_SOURCES = \ |
374 | test_fs_search_probes.c | 374 | test_fs_search_probes.c |
375 | test_fs_search_probes_LDADD = \ | 375 | test_fs_search_probes_LDADD = \ |
376 | $(top_builddir)/src/testing/libgnunettesting.la \ | 376 | $(top_builddir)/src/testing/libgnunettesting.la \ |
377 | libgnunetfs.la \ | 377 | libgnunetfs.la \ |
378 | $(top_builddir)/src/util/libgnunetutil.la | 378 | $(top_builddir)/src/lib/util/libgnunetutil.la |
379 | 379 | ||
380 | test_fs_search_persistence_SOURCES = \ | 380 | test_fs_search_persistence_SOURCES = \ |
381 | test_fs_search_persistence.c | 381 | test_fs_search_persistence.c |
382 | test_fs_search_persistence_LDADD = \ | 382 | test_fs_search_persistence_LDADD = \ |
383 | $(top_builddir)/src/testing/libgnunettesting.la \ | 383 | $(top_builddir)/src/testing/libgnunettesting.la \ |
384 | libgnunetfs.la \ | 384 | libgnunetfs.la \ |
385 | $(top_builddir)/src/util/libgnunetutil.la | 385 | $(top_builddir)/src/lib/util/libgnunetutil.la |
386 | 386 | ||
387 | test_fs_start_stop_SOURCES = \ | 387 | test_fs_start_stop_SOURCES = \ |
388 | test_fs_start_stop.c | 388 | test_fs_start_stop.c |
389 | test_fs_start_stop_LDADD = \ | 389 | test_fs_start_stop_LDADD = \ |
390 | $(top_builddir)/src/testing/libgnunettesting.la \ | 390 | $(top_builddir)/src/testing/libgnunettesting.la \ |
391 | libgnunetfs.la \ | 391 | libgnunetfs.la \ |
392 | $(top_builddir)/src/util/libgnunetutil.la | 392 | $(top_builddir)/src/lib/util/libgnunetutil.la |
393 | 393 | ||
394 | test_fs_unindex_SOURCES = \ | 394 | test_fs_unindex_SOURCES = \ |
395 | test_fs_unindex.c | 395 | test_fs_unindex.c |
396 | test_fs_unindex_LDADD = \ | 396 | test_fs_unindex_LDADD = \ |
397 | $(top_builddir)/src/testing/libgnunettesting.la \ | 397 | $(top_builddir)/src/testing/libgnunettesting.la \ |
398 | libgnunetfs.la \ | 398 | libgnunetfs.la \ |
399 | $(top_builddir)/src/util/libgnunetutil.la | 399 | $(top_builddir)/src/lib/util/libgnunetutil.la |
400 | 400 | ||
401 | test_fs_unindex_persistence_SOURCES = \ | 401 | test_fs_unindex_persistence_SOURCES = \ |
402 | test_fs_unindex_persistence.c | 402 | test_fs_unindex_persistence.c |
403 | test_fs_unindex_persistence_LDADD = \ | 403 | test_fs_unindex_persistence_LDADD = \ |
404 | $(top_builddir)/src/testing/libgnunettesting.la \ | 404 | $(top_builddir)/src/testing/libgnunettesting.la \ |
405 | libgnunetfs.la \ | 405 | libgnunetfs.la \ |
406 | $(top_builddir)/src/util/libgnunetutil.la | 406 | $(top_builddir)/src/lib/util/libgnunetutil.la |
407 | 407 | ||
408 | test_fs_meta_data_SOURCES = \ | 408 | test_fs_meta_data_SOURCES = \ |
409 | test_fs_meta_data.c | 409 | test_fs_meta_data.c |
410 | test_fs_meta_data_LDADD = \ | 410 | test_fs_meta_data_LDADD = \ |
411 | libgnunetfs.la \ | 411 | libgnunetfs.la \ |
412 | $(top_builddir)/src/util/libgnunetutil.la | 412 | $(top_builddir)/src/lib/util/libgnunetutil.la |
413 | 413 | ||
414 | 414 | ||
415 | test_fs_uri_SOURCES = \ | 415 | test_fs_uri_SOURCES = \ |
416 | test_fs_uri.c | 416 | test_fs_uri.c |
417 | test_fs_uri_LDADD = \ | 417 | test_fs_uri_LDADD = \ |
418 | libgnunetfs.la \ | 418 | libgnunetfs.la \ |
419 | $(top_builddir)/src/util/libgnunetutil.la | 419 | $(top_builddir)/src/lib/util/libgnunetutil.la |
420 | 420 | ||
421 | # TNG | 421 | # TNG |
422 | #test_fs_test_lib_SOURCES = \ | 422 | #test_fs_test_lib_SOURCES = \ |
@@ -425,7 +425,7 @@ test_fs_uri_LDADD = \ | |||
425 | # libgnunetfstest.a \ | 425 | # libgnunetfstest.a \ |
426 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ | 426 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ |
427 | # libgnunetfs.la \ | 427 | # libgnunetfs.la \ |
428 | # $(top_builddir)/src/util/libgnunetutil.la | 428 | # $(top_builddir)/src/lib/util/libgnunetutil.la |
429 | 429 | ||
430 | #test_gnunet_service_fs_p2p_SOURCES = \ | 430 | #test_gnunet_service_fs_p2p_SOURCES = \ |
431 | # test_gnunet_service_fs_p2p.c | 431 | # test_gnunet_service_fs_p2p.c |
@@ -433,7 +433,7 @@ test_fs_uri_LDADD = \ | |||
433 | # libgnunetfstest.a \ | 433 | # libgnunetfstest.a \ |
434 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ | 434 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ |
435 | # libgnunetfs.la \ | 435 | # libgnunetfs.la \ |
436 | # $(top_builddir)/src/util/libgnunetutil.la | 436 | # $(top_builddir)/src/lib/util/libgnunetutil.la |
437 | # | 437 | # |
438 | #test_gnunet_service_fs_p2p_cadet_SOURCES = \ | 438 | #test_gnunet_service_fs_p2p_cadet_SOURCES = \ |
439 | # test_gnunet_service_fs_p2p.c | 439 | # test_gnunet_service_fs_p2p.c |
@@ -441,7 +441,7 @@ test_fs_uri_LDADD = \ | |||
441 | # libgnunetfstest.a \ | 441 | # libgnunetfstest.a \ |
442 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ | 442 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ |
443 | # libgnunetfs.la \ | 443 | # libgnunetfs.la \ |
444 | # $(top_builddir)/src/util/libgnunetutil.la | 444 | # $(top_builddir)/src/lib/util/libgnunetutil.la |
445 | # | 445 | # |
446 | #test_gnunet_service_fs_migration_SOURCES = \ | 446 | #test_gnunet_service_fs_migration_SOURCES = \ |
447 | # test_gnunet_service_fs_migration.c | 447 | # test_gnunet_service_fs_migration.c |
@@ -449,7 +449,7 @@ test_fs_uri_LDADD = \ | |||
449 | # libgnunetfstest.a \ | 449 | # libgnunetfstest.a \ |
450 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ | 450 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ |
451 | # libgnunetfs.la \ | 451 | # libgnunetfs.la \ |
452 | # $(top_builddir)/src/util/libgnunetutil.la | 452 | # $(top_builddir)/src/lib/util/libgnunetutil.la |
453 | # | 453 | # |
454 | #perf_gnunet_service_fs_p2p_SOURCES = \ | 454 | #perf_gnunet_service_fs_p2p_SOURCES = \ |
455 | # perf_gnunet_service_fs_p2p.c | 455 | # perf_gnunet_service_fs_p2p.c |
@@ -458,7 +458,7 @@ test_fs_uri_LDADD = \ | |||
458 | # $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 458 | # $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
459 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ | 459 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ |
460 | # libgnunetfs.la \ | 460 | # libgnunetfs.la \ |
461 | # $(top_builddir)/src/util/libgnunetutil.la | 461 | # $(top_builddir)/src/lib/util/libgnunetutil.la |
462 | # | 462 | # |
463 | #perf_gnunet_service_fs_p2p_index_SOURCES = \ | 463 | #perf_gnunet_service_fs_p2p_index_SOURCES = \ |
464 | # perf_gnunet_service_fs_p2p.c | 464 | # perf_gnunet_service_fs_p2p.c |
@@ -467,7 +467,7 @@ test_fs_uri_LDADD = \ | |||
467 | # $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 467 | # $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
468 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ | 468 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ |
469 | # libgnunetfs.la \ | 469 | # libgnunetfs.la \ |
470 | # $(top_builddir)/src/util/libgnunetutil.la | 470 | # $(top_builddir)/src/lib/util/libgnunetutil.la |
471 | # | 471 | # |
472 | #perf_gnunet_service_fs_p2p_dht_SOURCES = \ | 472 | #perf_gnunet_service_fs_p2p_dht_SOURCES = \ |
473 | # perf_gnunet_service_fs_p2p.c | 473 | # perf_gnunet_service_fs_p2p.c |
@@ -476,7 +476,7 @@ test_fs_uri_LDADD = \ | |||
476 | # $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 476 | # $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
477 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ | 477 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ |
478 | # libgnunetfs.la \ | 478 | # libgnunetfs.la \ |
479 | # $(top_builddir)/src/util/libgnunetutil.la | 479 | # $(top_builddir)/src/lib/util/libgnunetutil.la |
480 | # | 480 | # |
481 | #perf_gnunet_service_fs_p2p_respect_SOURCES = \ | 481 | #perf_gnunet_service_fs_p2p_respect_SOURCES = \ |
482 | # perf_gnunet_service_fs_p2p_respect.c | 482 | # perf_gnunet_service_fs_p2p_respect.c |
@@ -485,7 +485,7 @@ test_fs_uri_LDADD = \ | |||
485 | # $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 485 | # $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
486 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ | 486 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ |
487 | # libgnunetfs.la \ | 487 | # libgnunetfs.la \ |
488 | # $(top_builddir)/src/util/libgnunetutil.la | 488 | # $(top_builddir)/src/lib/util/libgnunetutil.la |
489 | 489 | ||
490 | test_gnunet_fs_psd.py: test_gnunet_fs_psd.py.in Makefile | 490 | test_gnunet_fs_psd.py: test_gnunet_fs_psd.py.in Makefile |
491 | $(AWK) -v bdir="$(bindir)" -v py="$(PYTHON)" -v awkay="$(AWK_BINARY)" -v pfx="$(prefix)" -v prl="$(PERL)" -v sysconfdirectory="$(sysconfdir)" -v pkgdatadirectory="$(pkgdatadir)" -f $(top_srcdir)/bin/dosubst.awk < $(srcdir)/test_gnunet_fs_psd.py.in > test_gnunet_fs_psd.py | 491 | $(AWK) -v bdir="$(bindir)" -v py="$(PYTHON)" -v awkay="$(AWK_BINARY)" -v pfx="$(prefix)" -v prl="$(PERL)" -v sysconfdirectory="$(sysconfdir)" -v pkgdatadirectory="$(pkgdatadir)" -f $(top_srcdir)/bin/dosubst.awk < $(srcdir)/test_gnunet_fs_psd.py.in > test_gnunet_fs_psd.py |
diff --git a/src/fs/gnunet-publish.c b/src/fs/gnunet-publish.c index 59f16210a..7a87130de 100644 --- a/src/fs/gnunet-publish.c +++ b/src/fs/gnunet-publish.c | |||
@@ -476,7 +476,7 @@ uri_ksk_continuation (void *cls, | |||
476 | const char *emsg) | 476 | const char *emsg) |
477 | { | 477 | { |
478 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *priv; | 478 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *priv; |
479 | const struct GNUNET_IDENTITY_PrivateKey *pk; | 479 | const struct GNUNET_CRYPTO_PrivateKey *pk; |
480 | 480 | ||
481 | if (NULL != emsg) | 481 | if (NULL != emsg) |
482 | { | 482 | { |
@@ -489,7 +489,7 @@ uri_ksk_continuation (void *cls, | |||
489 | return; | 489 | return; |
490 | } | 490 | } |
491 | pk = GNUNET_IDENTITY_ego_get_private_key (namespace); | 491 | pk = GNUNET_IDENTITY_ego_get_private_key (namespace); |
492 | if (GNUNET_IDENTITY_TYPE_ECDSA != ntohl (pk->type)) | 492 | if (GNUNET_PUBLIC_KEY_TYPE_ECDSA != ntohl (pk->type)) |
493 | return; | 493 | return; |
494 | priv = &pk->ecdsa_key; | 494 | priv = &pk->ecdsa_key; |
495 | GNUNET_FS_publish_sks (ctx, | 495 | GNUNET_FS_publish_sks (ctx, |
@@ -574,7 +574,7 @@ directory_trim_complete (struct GNUNET_FS_ShareTreeItem *directory_scan_result) | |||
574 | { | 574 | { |
575 | struct GNUNET_FS_FileInformation *fi; | 575 | struct GNUNET_FS_FileInformation *fi; |
576 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *priv; | 576 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *priv; |
577 | const struct GNUNET_IDENTITY_PrivateKey *pk; | 577 | const struct GNUNET_CRYPTO_PrivateKey *pk; |
578 | 578 | ||
579 | fi = get_file_information (directory_scan_result); | 579 | fi = get_file_information (directory_scan_result); |
580 | GNUNET_FS_share_tree_free (directory_scan_result); | 580 | GNUNET_FS_share_tree_free (directory_scan_result); |
@@ -596,7 +596,7 @@ directory_trim_complete (struct GNUNET_FS_ShareTreeItem *directory_scan_result) | |||
596 | if (NULL != namespace) | 596 | if (NULL != namespace) |
597 | { | 597 | { |
598 | pk = GNUNET_IDENTITY_ego_get_private_key (namespace); | 598 | pk = GNUNET_IDENTITY_ego_get_private_key (namespace); |
599 | GNUNET_assert (GNUNET_IDENTITY_TYPE_ECDSA == ntohl (pk->type)); | 599 | GNUNET_assert (GNUNET_PUBLIC_KEY_TYPE_ECDSA == ntohl (pk->type)); |
600 | priv = &pk->ecdsa_key; | 600 | priv = &pk->ecdsa_key; |
601 | } | 601 | } |
602 | pc = GNUNET_FS_publish_start (ctx, | 602 | pc = GNUNET_FS_publish_start (ctx, |
diff --git a/src/gns/Makefile.am b/src/gns/Makefile.am index 0c50bc83f..b1f4e5ab8 100644 --- a/src/gns/Makefile.am +++ b/src/gns/Makefile.am | |||
@@ -84,13 +84,13 @@ CLEANFILES = test_gnunet_gns.sh | |||
84 | libgnunet_plugin_rest_gns_la_SOURCES = \ | 84 | libgnunet_plugin_rest_gns_la_SOURCES = \ |
85 | plugin_rest_gns.c | 85 | plugin_rest_gns.c |
86 | libgnunet_plugin_rest_gns_la_LIBADD = \ | 86 | libgnunet_plugin_rest_gns_la_LIBADD = \ |
87 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 87 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
88 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecordjson.la \ | 88 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecordjson.la \ |
89 | libgnunetgns.la \ | 89 | libgnunetgns.la \ |
90 | $(top_builddir)/src/rest/libgnunetrest.la \ | 90 | $(top_builddir)/src/rest/libgnunetrest.la \ |
91 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 91 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
92 | $(top_builddir)/src/json/libgnunetjson.la \ | 92 | $(top_builddir)/src/json/libgnunetjson.la \ |
93 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 93 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) \ |
94 | $(LTLIBINTL) -ljansson $(MHD_LIBS) | 94 | $(LTLIBINTL) -ljansson $(MHD_LIBS) |
95 | libgnunet_plugin_rest_gns_la_LDFLAGS = \ | 95 | libgnunet_plugin_rest_gns_la_LDFLAGS = \ |
96 | $(GN_PLUGIN_LDFLAGS) | 96 | $(GN_PLUGIN_LDFLAGS) |
@@ -100,9 +100,9 @@ libgnunet_plugin_rest_gns_la_CFLAGS = $(MHD_CFLAGS) $(AM_CFLAGS) | |||
100 | libgnunet_plugin_gnsrecord_gns_la_SOURCES = \ | 100 | libgnunet_plugin_gnsrecord_gns_la_SOURCES = \ |
101 | plugin_gnsrecord_gns.c | 101 | plugin_gnsrecord_gns.c |
102 | libgnunet_plugin_gnsrecord_gns_la_LIBADD = \ | 102 | libgnunet_plugin_gnsrecord_gns_la_LIBADD = \ |
103 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 103 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
104 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 104 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
105 | $(top_builddir)/src/util/libgnunetutil.la \ | 105 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
106 | $(LTLIBINTL) | 106 | $(LTLIBINTL) |
107 | libgnunet_plugin_gnsrecord_gns_la_LDFLAGS = \ | 107 | libgnunet_plugin_gnsrecord_gns_la_LDFLAGS = \ |
108 | $(GN_PLUGIN_LDFLAGS) | 108 | $(GN_PLUGIN_LDFLAGS) |
@@ -112,9 +112,9 @@ gnunet_gns_SOURCES = \ | |||
112 | gnunet-gns.c | 112 | gnunet-gns.c |
113 | gnunet_gns_LDADD = \ | 113 | gnunet_gns_LDADD = \ |
114 | libgnunetgns.la \ | 114 | libgnunetgns.la \ |
115 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 115 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
116 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 116 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
117 | $(top_builddir)/src/util/libgnunetutil.la \ | 117 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
118 | $(LIBIDN) $(LIBIDN2) \ | 118 | $(LIBIDN) $(LIBIDN2) \ |
119 | $(GN_LIBINTL) | 119 | $(GN_LIBINTL) |
120 | 120 | ||
@@ -122,16 +122,16 @@ gnunet_gns_benchmark_SOURCES = \ | |||
122 | gnunet-gns-benchmark.c | 122 | gnunet-gns-benchmark.c |
123 | gnunet_gns_benchmark_LDADD = \ | 123 | gnunet_gns_benchmark_LDADD = \ |
124 | libgnunetgns.la \ | 124 | libgnunetgns.la \ |
125 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 125 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
126 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 126 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
127 | $(top_builddir)/src/util/libgnunetutil.la \ | 127 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
128 | $(GN_LIBINTL) | 128 | $(GN_LIBINTL) |
129 | 129 | ||
130 | 130 | ||
131 | gnunet_bcd_SOURCES = \ | 131 | gnunet_bcd_SOURCES = \ |
132 | gnunet-bcd.c | 132 | gnunet-bcd.c |
133 | gnunet_bcd_LDADD = \ | 133 | gnunet_bcd_LDADD = \ |
134 | $(top_builddir)/src/util/libgnunetutil.la \ | 134 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
135 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 135 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
136 | $(GN_LIBINTL) $(MHD_LIBS) | 136 | $(GN_LIBINTL) $(MHD_LIBS) |
137 | gnunet_bcd_CFLAGS = $(MHD_CFLAGS) $(AM_CFLAGS) | 137 | gnunet_bcd_CFLAGS = $(MHD_CFLAGS) $(AM_CFLAGS) |
@@ -140,9 +140,9 @@ gnunet_bcd_CFLAGS = $(MHD_CFLAGS) $(AM_CFLAGS) | |||
140 | gnunet_dns2gns_SOURCES = \ | 140 | gnunet_dns2gns_SOURCES = \ |
141 | gnunet-dns2gns.c | 141 | gnunet-dns2gns.c |
142 | gnunet_dns2gns_LDADD = \ | 142 | gnunet_dns2gns_LDADD = \ |
143 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 143 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
144 | libgnunetgns.la \ | 144 | libgnunetgns.la \ |
145 | $(top_builddir)/src/util/libgnunetutil.la \ | 145 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
146 | $(USE_VPN) \ | 146 | $(USE_VPN) \ |
147 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 147 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
148 | $(GN_LIBINTL) | 148 | $(GN_LIBINTL) |
@@ -168,7 +168,7 @@ gnunet_gns_proxy_SOURCES = \ | |||
168 | gnunet_gns_proxy_LDADD = $(MHD_LIBS) @LIBCURL@ -lgnutls \ | 168 | gnunet_gns_proxy_LDADD = $(MHD_LIBS) @LIBCURL@ -lgnutls \ |
169 | libgnunetgns.la \ | 169 | libgnunetgns.la \ |
170 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 170 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
171 | $(top_builddir)/src/util/libgnunetutil.la \ | 171 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
172 | $(GN_LIBINTL) | 172 | $(GN_LIBINTL) |
173 | if HAVE_GNUTLS_DANE | 173 | if HAVE_GNUTLS_DANE |
174 | gnunet_gns_proxy_LDADD += -lgnutls-dane | 174 | gnunet_gns_proxy_LDADD += -lgnutls-dane |
@@ -178,7 +178,7 @@ gnunet_gns_proxy_CFLAGS = $(MHD_CFLAGS) @LIBCURL_CPPFLAGS@ $(AM_CFLAGS) | |||
178 | test_gns_proxy_SOURCES = \ | 178 | test_gns_proxy_SOURCES = \ |
179 | test_gns_proxy.c | 179 | test_gns_proxy.c |
180 | test_gns_proxy_LDADD = $(MHD_LIBS) @LIBCURL@ -lgnutls \ | 180 | test_gns_proxy_LDADD = $(MHD_LIBS) @LIBCURL@ -lgnutls \ |
181 | $(top_builddir)/src/util/libgnunetutil.la \ | 181 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
182 | $(GN_LIBINTL) | 182 | $(GN_LIBINTL) |
183 | test_gns_proxy_CFLAGS = $(MHD_CFLAGS) @LIBCURL_CPPFLAGS@ $(AM_CFLAGS) | 183 | test_gns_proxy_CFLAGS = $(MHD_CFLAGS) @LIBCURL_CPPFLAGS@ $(AM_CFLAGS) |
184 | 184 | ||
@@ -187,8 +187,8 @@ test_gns_proxy_CFLAGS = $(MHD_CFLAGS) @LIBCURL_CPPFLAGS@ $(AM_CFLAGS) | |||
187 | #gnunet_gns_import_LDADD = \ | 187 | #gnunet_gns_import_LDADD = \ |
188 | # $(top_builddir)/src/identity/libgnunetidentity.la \ | 188 | # $(top_builddir)/src/identity/libgnunetidentity.la \ |
189 | # $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 189 | # $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
190 | # $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 190 | # $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
191 | # $(top_builddir)/src/util/libgnunetutil.la \ | 191 | # $(top_builddir)/src/lib/util/libgnunetutil.la \ |
192 | # $(GN_LIBINTL) | 192 | # $(GN_LIBINTL) |
193 | 193 | ||
194 | 194 | ||
@@ -198,11 +198,11 @@ gnunet_service_gns_SOURCES = \ | |||
198 | gnunet-service-gns_interceptor.c gnunet-service-gns_interceptor.h | 198 | gnunet-service-gns_interceptor.c gnunet-service-gns_interceptor.h |
199 | gnunet_service_gns_LDADD = \ | 199 | gnunet_service_gns_LDADD = \ |
200 | -lm \ | 200 | -lm \ |
201 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 201 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
202 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 202 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
203 | $(top_builddir)/src/revocation/libgnunetrevocation.la \ | 203 | $(top_builddir)/src/revocation/libgnunetrevocation.la \ |
204 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 204 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
205 | $(top_builddir)/src/util/libgnunetutil.la \ | 205 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
206 | $(top_builddir)/src/dns/libgnunetdns.la \ | 206 | $(top_builddir)/src/dns/libgnunetdns.la \ |
207 | $(top_builddir)/src/dht/libgnunetdht.la \ | 207 | $(top_builddir)/src/dht/libgnunetdht.la \ |
208 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ | 208 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ |
@@ -214,9 +214,9 @@ libgnunetgns_la_SOURCES = \ | |||
214 | gns_api.c gns_api.h \ | 214 | gns_api.c gns_api.h \ |
215 | gns_tld_api.c gns.h | 215 | gns_tld_api.c gns.h |
216 | libgnunetgns_la_LIBADD = \ | 216 | libgnunetgns_la_LIBADD = \ |
217 | $(top_builddir)/src/util/libgnunetutil.la $(XLIB) \ | 217 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIB) \ |
218 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 218 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
219 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la | 219 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la |
220 | libgnunetgns_la_LDFLAGS = \ | 220 | libgnunetgns_la_LDFLAGS = \ |
221 | $(GN_LIBINTL) \ | 221 | $(GN_LIBINTL) \ |
222 | $(GN_LIB_LDFLAGS) | 222 | $(GN_LIB_LDFLAGS) |
@@ -225,11 +225,11 @@ libgnunetgns_la_LDFLAGS = \ | |||
225 | libgnunet_plugin_block_gns_la_SOURCES = \ | 225 | libgnunet_plugin_block_gns_la_SOURCES = \ |
226 | plugin_block_gns.c | 226 | plugin_block_gns.c |
227 | libgnunet_plugin_block_gns_la_LIBADD = \ | 227 | libgnunet_plugin_block_gns_la_LIBADD = \ |
228 | $(top_builddir)/src/util/libgnunetutil.la \ | 228 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
229 | $(top_builddir)/src/block/libgnunetblock.la \ | 229 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
230 | $(top_builddir)/src/block/libgnunetblockgroup.la \ | 230 | $(top_builddir)/src/lib/block/libgnunetblockgroup.la \ |
231 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 231 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
232 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la | 232 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la |
233 | libgnunet_plugin_block_gns_la_LDFLAGS = \ | 233 | libgnunet_plugin_block_gns_la_LDFLAGS = \ |
234 | $(GN_LIBINTL) \ | 234 | $(GN_LIBINTL) \ |
235 | $(GN_PLUGIN_LDFLAGS) | 235 | $(GN_PLUGIN_LDFLAGS) |
diff --git a/src/gns/gns_api.c b/src/gns/gns_api.c index 2e5ddc2b7..0dc7580f9 100644 --- a/src/gns/gns_api.c +++ b/src/gns/gns_api.c | |||
@@ -342,7 +342,7 @@ GNUNET_GNS_lookup_cancel (struct GNUNET_GNS_LookupRequest *lr) | |||
342 | struct GNUNET_GNS_LookupRequest * | 342 | struct GNUNET_GNS_LookupRequest * |
343 | GNUNET_GNS_lookup_limited (struct GNUNET_GNS_Handle *handle, | 343 | GNUNET_GNS_lookup_limited (struct GNUNET_GNS_Handle *handle, |
344 | const char *name, | 344 | const char *name, |
345 | const struct GNUNET_IDENTITY_PublicKey *zone, | 345 | const struct GNUNET_CRYPTO_PublicKey *zone, |
346 | uint32_t type, | 346 | uint32_t type, |
347 | enum GNUNET_GNS_LocalOptions options, | 347 | enum GNUNET_GNS_LocalOptions options, |
348 | uint16_t recursion_depth_limit, | 348 | uint16_t recursion_depth_limit, |
@@ -376,7 +376,7 @@ GNUNET_GNS_lookup_limited (struct GNUNET_GNS_Handle *handle, | |||
376 | lr->lookup_proc = proc; | 376 | lr->lookup_proc = proc; |
377 | lr->proc_cls = proc_cls; | 377 | lr->proc_cls = proc_cls; |
378 | lr->r_id = handle->r_id_gen++; | 378 | lr->r_id = handle->r_id_gen++; |
379 | key_len = GNUNET_IDENTITY_public_key_get_length (zone); | 379 | key_len = GNUNET_CRYPTO_public_key_get_length (zone); |
380 | lr->env = GNUNET_MQ_msg_extra (lookup_msg, | 380 | lr->env = GNUNET_MQ_msg_extra (lookup_msg, |
381 | nlen + key_len, | 381 | nlen + key_len, |
382 | GNUNET_MESSAGE_TYPE_GNS_LOOKUP); | 382 | GNUNET_MESSAGE_TYPE_GNS_LOOKUP); |
@@ -386,7 +386,7 @@ GNUNET_GNS_lookup_limited (struct GNUNET_GNS_Handle *handle, | |||
386 | lookup_msg->recursion_depth_limit | 386 | lookup_msg->recursion_depth_limit |
387 | = htons (recursion_depth_limit); | 387 | = htons (recursion_depth_limit); |
388 | lookup_msg->key_len = htonl (key_len); | 388 | lookup_msg->key_len = htonl (key_len); |
389 | written = GNUNET_IDENTITY_write_public_key_to_buffer (zone, | 389 | written = GNUNET_CRYPTO_write_public_key_to_buffer (zone, |
390 | buf, | 390 | buf, |
391 | key_len); | 391 | key_len); |
392 | GNUNET_assert (0 <= written); | 392 | GNUNET_assert (0 <= written); |
@@ -420,7 +420,7 @@ GNUNET_GNS_lookup_limited (struct GNUNET_GNS_Handle *handle, | |||
420 | struct GNUNET_GNS_LookupRequest* | 420 | struct GNUNET_GNS_LookupRequest* |
421 | GNUNET_GNS_lookup (struct GNUNET_GNS_Handle *handle, | 421 | GNUNET_GNS_lookup (struct GNUNET_GNS_Handle *handle, |
422 | const char *name, | 422 | const char *name, |
423 | const struct GNUNET_IDENTITY_PublicKey *zone, | 423 | const struct GNUNET_CRYPTO_PublicKey *zone, |
424 | uint32_t type, | 424 | uint32_t type, |
425 | enum GNUNET_GNS_LocalOptions options, | 425 | enum GNUNET_GNS_LocalOptions options, |
426 | GNUNET_GNS_LookupResultProcessor proc, | 426 | GNUNET_GNS_LookupResultProcessor proc, |
diff --git a/src/gns/gns_tld_api.c b/src/gns/gns_tld_api.c index 78a70f14e..1ea87fd97 100644 --- a/src/gns/gns_tld_api.c +++ b/src/gns/gns_tld_api.c | |||
@@ -166,7 +166,7 @@ process_lookup_result (void *cls, | |||
166 | */ | 166 | */ |
167 | static void | 167 | static void |
168 | lookup_with_public_key (struct GNUNET_GNS_LookupWithTldRequest *ltr, | 168 | lookup_with_public_key (struct GNUNET_GNS_LookupWithTldRequest *ltr, |
169 | const struct GNUNET_IDENTITY_PublicKey *pkey) | 169 | const struct GNUNET_CRYPTO_PublicKey *pkey) |
170 | { | 170 | { |
171 | ltr->lr = GNUNET_GNS_lookup (ltr->gns_handle, | 171 | ltr->lr = GNUNET_GNS_lookup (ltr->gns_handle, |
172 | ltr->name, | 172 | ltr->name, |
@@ -189,11 +189,11 @@ lookup_with_public_key (struct GNUNET_GNS_LookupWithTldRequest *ltr, | |||
189 | */ | 189 | */ |
190 | static void | 190 | static void |
191 | identity_zone_cb (void *cls, | 191 | identity_zone_cb (void *cls, |
192 | const struct GNUNET_IDENTITY_PrivateKey *priv, | 192 | const struct GNUNET_CRYPTO_PrivateKey *priv, |
193 | const char *ego_name) | 193 | const char *ego_name) |
194 | { | 194 | { |
195 | struct GNUNET_GNS_LookupWithTldRequest *ltr = cls; | 195 | struct GNUNET_GNS_LookupWithTldRequest *ltr = cls; |
196 | struct GNUNET_IDENTITY_PublicKey pkey; | 196 | struct GNUNET_CRYPTO_PublicKey pkey; |
197 | 197 | ||
198 | ltr->id_co = NULL; | 198 | ltr->id_co = NULL; |
199 | if (NULL == priv) | 199 | if (NULL == priv) |
@@ -218,7 +218,7 @@ identity_zone_cb (void *cls, | |||
218 | ltr->options = GNUNET_GNS_LO_NO_DHT; | 218 | ltr->options = GNUNET_GNS_LO_NO_DHT; |
219 | else | 219 | else |
220 | ltr->options = GNUNET_GNS_LO_LOCAL_MASTER; | 220 | ltr->options = GNUNET_GNS_LO_LOCAL_MASTER; |
221 | GNUNET_IDENTITY_key_get_public (priv, &pkey); | 221 | GNUNET_CRYPTO_key_get_public (priv, &pkey); |
222 | lookup_with_public_key (ltr, &pkey); | 222 | lookup_with_public_key (ltr, &pkey); |
223 | } | 223 | } |
224 | 224 | ||
@@ -248,7 +248,7 @@ GNUNET_GNS_lookup_with_tld (struct GNUNET_GNS_Handle *handle, | |||
248 | const char *tld; | 248 | const char *tld; |
249 | char *dot_tld; | 249 | char *dot_tld; |
250 | char *zonestr; | 250 | char *zonestr; |
251 | struct GNUNET_IDENTITY_PublicKey pkey; | 251 | struct GNUNET_CRYPTO_PublicKey pkey; |
252 | 252 | ||
253 | ltr = GNUNET_new (struct GNUNET_GNS_LookupWithTldRequest); | 253 | ltr = GNUNET_new (struct GNUNET_GNS_LookupWithTldRequest); |
254 | ltr->gns_handle = handle; | 254 | ltr->gns_handle = handle; |
@@ -260,7 +260,7 @@ GNUNET_GNS_lookup_with_tld (struct GNUNET_GNS_Handle *handle, | |||
260 | /* start with trivial case: TLD is zkey */ | 260 | /* start with trivial case: TLD is zkey */ |
261 | tld = get_tld (ltr->name); | 261 | tld = get_tld (ltr->name); |
262 | if (GNUNET_OK == | 262 | if (GNUNET_OK == |
263 | GNUNET_IDENTITY_public_key_from_string (tld, &pkey)) | 263 | GNUNET_CRYPTO_public_key_from_string (tld, &pkey)) |
264 | { | 264 | { |
265 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 265 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
266 | "`%s' seems to be a valid zone key\n", tld); | 266 | "`%s' seems to be a valid zone key\n", tld); |
@@ -282,7 +282,7 @@ GNUNET_GNS_lookup_with_tld (struct GNUNET_GNS_Handle *handle, | |||
282 | &zonestr)) | 282 | &zonestr)) |
283 | { | 283 | { |
284 | if (GNUNET_OK != | 284 | if (GNUNET_OK != |
285 | GNUNET_IDENTITY_public_key_from_string (zonestr, | 285 | GNUNET_CRYPTO_public_key_from_string (zonestr, |
286 | &pkey)) | 286 | &pkey)) |
287 | { | 287 | { |
288 | GNUNET_log_config_invalid ( | 288 | GNUNET_log_config_invalid ( |
diff --git a/src/gns/gnunet-bcd.c b/src/gns/gnunet-bcd.c index 754f8ac6f..0f7fb6507 100644 --- a/src/gns/gnunet-bcd.c +++ b/src/gns/gnunet-bcd.c | |||
@@ -364,9 +364,9 @@ create_response (void *cls, | |||
364 | MHD_GET_ARGUMENT_KIND, | 364 | MHD_GET_ARGUMENT_KIND, |
365 | "gnspng"); | 365 | "gnspng"); |
366 | 366 | ||
367 | struct GNUNET_IDENTITY_PublicKey pk; | 367 | struct GNUNET_CRYPTO_PublicKey pk; |
368 | if (NULL == gnskey | 368 | if (NULL == gnskey |
369 | || GNUNET_OK != GNUNET_IDENTITY_public_key_from_string (gnskey, &pk)) | 369 | || GNUNET_OK != GNUNET_CRYPTO_public_key_from_string (gnskey, &pk)) |
370 | { | 370 | { |
371 | return MHD_queue_response (connection, | 371 | return MHD_queue_response (connection, |
372 | MHD_HTTP_BAD_REQUEST, | 372 | MHD_HTTP_BAD_REQUEST, |
diff --git a/src/gns/gnunet-gns-import.c b/src/gns/gnunet-gns-import.c index e99c4d3dd..5d4602682 100644 --- a/src/gns/gnunet-gns-import.c +++ b/src/gns/gnunet-gns-import.c | |||
@@ -168,7 +168,7 @@ check_pkey (unsigned int rd_len, const struct GNUNET_GNSRECORD_Data *rd, | |||
168 | char *pk, int *found_rec) | 168 | char *pk, int *found_rec) |
169 | { | 169 | { |
170 | int i; | 170 | int i; |
171 | struct GNUNET_IDENTITY_PublicKey pubkey; | 171 | struct GNUNET_CRYPTO_PublicKey pubkey; |
172 | 172 | ||
173 | for (i = 0; i < rd_len; i++) | 173 | for (i = 0; i < rd_len; i++) |
174 | { | 174 | { |
diff --git a/src/gns/gnunet-service-gns.c b/src/gns/gnunet-service-gns.c index fc8de860d..aaf82a557 100644 --- a/src/gns/gnunet-service-gns.c +++ b/src/gns/gnunet-service-gns.c | |||
@@ -122,7 +122,7 @@ struct GNS_TopLevelDomain | |||
122 | /** | 122 | /** |
123 | * Public key associated with the @a tld. | 123 | * Public key associated with the @a tld. |
124 | */ | 124 | */ |
125 | struct GNUNET_IDENTITY_PublicKey pkey; | 125 | struct GNUNET_CRYPTO_PublicKey pkey; |
126 | 126 | ||
127 | /** | 127 | /** |
128 | * Top-level domain as a string, including leading ".". | 128 | * Top-level domain as a string, including leading ".". |
@@ -176,7 +176,7 @@ static struct GNS_TopLevelDomain *tld_tail; | |||
176 | */ | 176 | */ |
177 | int | 177 | int |
178 | GNS_find_tld (const char *tld_str, | 178 | GNS_find_tld (const char *tld_str, |
179 | struct GNUNET_IDENTITY_PublicKey *pkey) | 179 | struct GNUNET_CRYPTO_PublicKey *pkey) |
180 | { | 180 | { |
181 | if ('\0' == *tld_str) | 181 | if ('\0' == *tld_str) |
182 | return GNUNET_NO; | 182 | return GNUNET_NO; |
@@ -420,7 +420,7 @@ handle_lookup (void *cls, | |||
420 | { | 420 | { |
421 | struct GnsClient *gc = cls; | 421 | struct GnsClient *gc = cls; |
422 | struct ClientLookupHandle *clh; | 422 | struct ClientLookupHandle *clh; |
423 | struct GNUNET_IDENTITY_PublicKey zone; | 423 | struct GNUNET_CRYPTO_PublicKey zone; |
424 | const char *name; | 424 | const char *name; |
425 | size_t key_len; | 425 | size_t key_len; |
426 | size_t read; | 426 | size_t read; |
@@ -434,7 +434,7 @@ handle_lookup (void *cls, | |||
434 | clh->gc = gc; | 434 | clh->gc = gc; |
435 | clh->request_id = sh_msg->id; | 435 | clh->request_id = sh_msg->id; |
436 | if ((GNUNET_SYSERR == | 436 | if ((GNUNET_SYSERR == |
437 | GNUNET_IDENTITY_read_public_key_from_buffer (&sh_msg[1], | 437 | GNUNET_CRYPTO_read_public_key_from_buffer (&sh_msg[1], |
438 | key_len, | 438 | key_len, |
439 | &zone, | 439 | &zone, |
440 | &read)) || | 440 | &read)) || |
@@ -498,7 +498,7 @@ read_service_conf (void *cls, | |||
498 | const char *option, | 498 | const char *option, |
499 | const char *value) | 499 | const char *value) |
500 | { | 500 | { |
501 | struct GNUNET_IDENTITY_PublicKey pk; | 501 | struct GNUNET_CRYPTO_PublicKey pk; |
502 | struct GNS_TopLevelDomain *tld; | 502 | struct GNS_TopLevelDomain *tld; |
503 | 503 | ||
504 | (void) cls; | 504 | (void) cls; |
diff --git a/src/gns/gnunet-service-gns.h b/src/gns/gnunet-service-gns.h index d4fb9ec9f..13e28349c 100644 --- a/src/gns/gnunet-service-gns.h +++ b/src/gns/gnunet-service-gns.h | |||
@@ -37,7 +37,7 @@ | |||
37 | */ | 37 | */ |
38 | int | 38 | int |
39 | GNS_find_tld (const char *tld_str, | 39 | GNS_find_tld (const char *tld_str, |
40 | struct GNUNET_IDENTITY_PublicKey *pkey); | 40 | struct GNUNET_CRYPTO_PublicKey *pkey); |
41 | 41 | ||
42 | 42 | ||
43 | /** | 43 | /** |
diff --git a/src/gns/gnunet-service-gns_interceptor.c b/src/gns/gnunet-service-gns_interceptor.c index 3358692da..f49d60b94 100644 --- a/src/gns/gnunet-service-gns_interceptor.c +++ b/src/gns/gnunet-service-gns_interceptor.c | |||
@@ -313,7 +313,7 @@ handle_dns_request (void *cls, | |||
313 | { | 313 | { |
314 | struct GNUNET_DNSPARSER_Packet *p; | 314 | struct GNUNET_DNSPARSER_Packet *p; |
315 | struct InterceptLookupHandle *ilh; | 315 | struct InterceptLookupHandle *ilh; |
316 | struct GNUNET_IDENTITY_PublicKey zone; | 316 | struct GNUNET_CRYPTO_PublicKey zone; |
317 | 317 | ||
318 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 318 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
319 | "Hijacked a DNS request. Processing.\n"); | 319 | "Hijacked a DNS request. Processing.\n"); |
diff --git a/src/gns/gnunet-service-gns_resolver.c b/src/gns/gnunet-service-gns_resolver.c index b6a81b3a1..aa0189b15 100644 --- a/src/gns/gnunet-service-gns_resolver.c +++ b/src/gns/gnunet-service-gns_resolver.c | |||
@@ -164,7 +164,7 @@ struct AuthorityChain | |||
164 | /** | 164 | /** |
165 | * The zone of the GNS authority | 165 | * The zone of the GNS authority |
166 | */ | 166 | */ |
167 | struct GNUNET_IDENTITY_PublicKey gns_authority; | 167 | struct GNUNET_CRYPTO_PublicKey gns_authority; |
168 | 168 | ||
169 | struct | 169 | struct |
170 | { | 170 | { |
@@ -264,7 +264,7 @@ struct GNS_ResolverHandle | |||
264 | /** | 264 | /** |
265 | * The top-level GNS authoritative zone to query | 265 | * The top-level GNS authoritative zone to query |
266 | */ | 266 | */ |
267 | struct GNUNET_IDENTITY_PublicKey authority_zone; | 267 | struct GNUNET_CRYPTO_PublicKey authority_zone; |
268 | 268 | ||
269 | /** | 269 | /** |
270 | * called when resolution phase finishes | 270 | * called when resolution phase finishes |
@@ -1213,7 +1213,7 @@ handle_gns_redirect_result (struct GNS_ResolverHandle *rh, | |||
1213 | const char *tld; | 1213 | const char *tld; |
1214 | struct AuthorityChain *ac; | 1214 | struct AuthorityChain *ac; |
1215 | int af; | 1215 | int af; |
1216 | struct GNUNET_IDENTITY_PublicKey zone; | 1216 | struct GNUNET_CRYPTO_PublicKey zone; |
1217 | 1217 | ||
1218 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1218 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1219 | "Handling GNS REDIRECT result `%s'\n", | 1219 | "Handling GNS REDIRECT result `%s'\n", |
@@ -1644,7 +1644,7 @@ recursive_pkey_resolution (struct GNS_ResolverHandle *rh, | |||
1644 | const struct GNUNET_GNSRECORD_Data *rd) | 1644 | const struct GNUNET_GNSRECORD_Data *rd) |
1645 | { | 1645 | { |
1646 | struct AuthorityChain *ac; | 1646 | struct AuthorityChain *ac; |
1647 | struct GNUNET_IDENTITY_PublicKey auth; | 1647 | struct GNUNET_CRYPTO_PublicKey auth; |
1648 | 1648 | ||
1649 | /* delegation to another zone */ | 1649 | /* delegation to another zone */ |
1650 | if (GNUNET_OK != GNUNET_GNSRECORD_identity_from_data (rd->data, | 1650 | if (GNUNET_OK != GNUNET_GNSRECORD_identity_from_data (rd->data, |
@@ -1703,7 +1703,7 @@ recursive_gns2dns_resolution (struct GNS_ResolverHandle *rh, | |||
1703 | char *n; | 1703 | char *n; |
1704 | size_t off; | 1704 | size_t off; |
1705 | struct Gns2DnsPending *gp; | 1705 | struct Gns2DnsPending *gp; |
1706 | struct GNUNET_IDENTITY_PublicKey zone; | 1706 | struct GNUNET_CRYPTO_PublicKey zone; |
1707 | struct sockaddr_in v4; | 1707 | struct sockaddr_in v4; |
1708 | struct sockaddr_in6 v6; | 1708 | struct sockaddr_in6 v6; |
1709 | 1709 | ||
@@ -2173,7 +2173,7 @@ handle_gns_resolution_result (void *cls, | |||
2173 | case GNUNET_GNSRECORD_TYPE_PKEY: | 2173 | case GNUNET_GNSRECORD_TYPE_PKEY: |
2174 | case GNUNET_GNSRECORD_TYPE_EDKEY: | 2174 | case GNUNET_GNSRECORD_TYPE_EDKEY: |
2175 | { | 2175 | { |
2176 | struct GNUNET_IDENTITY_PublicKey pubkey; | 2176 | struct GNUNET_CRYPTO_PublicKey pubkey; |
2177 | if (rd[i].data_size < sizeof(uint32_t)) | 2177 | if (rd[i].data_size < sizeof(uint32_t)) |
2178 | { | 2178 | { |
2179 | GNUNET_break_op (0); | 2179 | GNUNET_break_op (0); |
@@ -2530,7 +2530,7 @@ handle_namecache_block_response (void *cls, | |||
2530 | struct GNS_ResolverHandle *rh = cls; | 2530 | struct GNS_ResolverHandle *rh = cls; |
2531 | struct AuthorityChain *ac = rh->ac_tail; | 2531 | struct AuthorityChain *ac = rh->ac_tail; |
2532 | const char *label = ac->label; | 2532 | const char *label = ac->label; |
2533 | const struct GNUNET_IDENTITY_PublicKey *auth = | 2533 | const struct GNUNET_CRYPTO_PublicKey *auth = |
2534 | &ac->authority_info.gns_authority; | 2534 | &ac->authority_info.gns_authority; |
2535 | struct GNUNET_HashCode query; | 2535 | struct GNUNET_HashCode query; |
2536 | 2536 | ||
@@ -2790,7 +2790,7 @@ start_resolver_lookup (void *cls) | |||
2790 | * @return handle to cancel operation | 2790 | * @return handle to cancel operation |
2791 | */ | 2791 | */ |
2792 | struct GNS_ResolverHandle * | 2792 | struct GNS_ResolverHandle * |
2793 | GNS_resolver_lookup (const struct GNUNET_IDENTITY_PublicKey *zone, | 2793 | GNS_resolver_lookup (const struct GNUNET_CRYPTO_PublicKey *zone, |
2794 | uint32_t record_type, | 2794 | uint32_t record_type, |
2795 | const char *name, | 2795 | const char *name, |
2796 | enum GNUNET_GNS_LocalOptions options, | 2796 | enum GNUNET_GNS_LocalOptions options, |
diff --git a/src/gns/gnunet-service-gns_resolver.h b/src/gns/gnunet-service-gns_resolver.h index b099c5d65..908af58e7 100644 --- a/src/gns/gnunet-service-gns_resolver.h +++ b/src/gns/gnunet-service-gns_resolver.h | |||
@@ -86,7 +86,7 @@ typedef void | |||
86 | * @return handle to cancel operation | 86 | * @return handle to cancel operation |
87 | */ | 87 | */ |
88 | struct GNS_ResolverHandle * | 88 | struct GNS_ResolverHandle * |
89 | GNS_resolver_lookup (const struct GNUNET_IDENTITY_PublicKey *zone, | 89 | GNS_resolver_lookup (const struct GNUNET_CRYPTO_PublicKey *zone, |
90 | uint32_t record_type, | 90 | uint32_t record_type, |
91 | const char *name, | 91 | const char *name, |
92 | enum GNUNET_GNS_LocalOptions options, | 92 | enum GNUNET_GNS_LocalOptions options, |
diff --git a/src/gns/plugin_gnsrecord_gns.c b/src/gns/plugin_gnsrecord_gns.c index 7c1c9b2e6..65587172d 100644 --- a/src/gns/plugin_gnsrecord_gns.c +++ b/src/gns/plugin_gnsrecord_gns.c | |||
@@ -49,7 +49,7 @@ gns_value_to_string (void *cls, | |||
49 | size_t data_size) | 49 | size_t data_size) |
50 | { | 50 | { |
51 | const char *cdata; | 51 | const char *cdata; |
52 | struct GNUNET_IDENTITY_PublicKey pk; | 52 | struct GNUNET_CRYPTO_PublicKey pk; |
53 | 53 | ||
54 | switch (type) | 54 | switch (type) |
55 | { | 55 | { |
@@ -61,7 +61,7 @@ gns_value_to_string (void *cls, | |||
61 | type, | 61 | type, |
62 | &pk)) | 62 | &pk)) |
63 | return NULL; | 63 | return NULL; |
64 | return GNUNET_IDENTITY_public_key_to_string (&pk); | 64 | return GNUNET_CRYPTO_public_key_to_string (&pk); |
65 | 65 | ||
66 | case GNUNET_GNSRECORD_TYPE_NICK: | 66 | case GNUNET_GNSRECORD_TYPE_NICK: |
67 | case GNUNET_GNSRECORD_TYPE_REDIRECT: | 67 | case GNUNET_GNSRECORD_TYPE_REDIRECT: |
@@ -160,7 +160,7 @@ gns_string_to_value (void *cls, | |||
160 | void **data, | 160 | void **data, |
161 | size_t *data_size) | 161 | size_t *data_size) |
162 | { | 162 | { |
163 | struct GNUNET_IDENTITY_PublicKey pk; | 163 | struct GNUNET_CRYPTO_PublicKey pk; |
164 | uint32_t record_type; | 164 | uint32_t record_type; |
165 | 165 | ||
166 | if (NULL == s) | 166 | if (NULL == s) |
@@ -170,14 +170,14 @@ gns_string_to_value (void *cls, | |||
170 | case GNUNET_GNSRECORD_TYPE_PKEY: | 170 | case GNUNET_GNSRECORD_TYPE_PKEY: |
171 | case GNUNET_GNSRECORD_TYPE_EDKEY: | 171 | case GNUNET_GNSRECORD_TYPE_EDKEY: |
172 | if (GNUNET_OK != | 172 | if (GNUNET_OK != |
173 | GNUNET_IDENTITY_public_key_from_string (s, &pk)) | 173 | GNUNET_CRYPTO_public_key_from_string (s, &pk)) |
174 | { | 174 | { |
175 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | 175 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, |
176 | _ ("Unable to parse zone key record `%s'\n"), | 176 | _ ("Unable to parse zone key record `%s'\n"), |
177 | s); | 177 | s); |
178 | return GNUNET_SYSERR; | 178 | return GNUNET_SYSERR; |
179 | } | 179 | } |
180 | *data_size = GNUNET_IDENTITY_public_key_get_length (&pk); | 180 | *data_size = GNUNET_CRYPTO_public_key_get_length (&pk); |
181 | if (GNUNET_OK != | 181 | if (GNUNET_OK != |
182 | GNUNET_GNSRECORD_data_from_identity (&pk, | 182 | GNUNET_GNSRECORD_data_from_identity (&pk, |
183 | (char **) data, | 183 | (char **) data, |
diff --git a/src/hello/gnunet-hello.c b/src/hello/gnunet-hello.c deleted file mode 100644 index 302800598..000000000 --- a/src/hello/gnunet-hello.c +++ /dev/null | |||
@@ -1,427 +0,0 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet | ||
3 | Copyright (C) 2012 GNUnet e.V. | ||
4 | |||
5 | GNUnet is free software: you can redistribute it and/or modify it | ||
6 | under the terms of the GNU Affero General Public License as published | ||
7 | by the Free Software Foundation, either version 3 of the License, | ||
8 | or (at your option) any later version. | ||
9 | |||
10 | GNUnet is distributed in the hope that it will be useful, but | ||
11 | WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
13 | Affero General Public License for more details. | ||
14 | |||
15 | You should have received a copy of the GNU Affero General Public License | ||
16 | along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
17 | |||
18 | SPDX-License-Identifier: AGPL3.0-or-later | ||
19 | */ | ||
20 | /** | ||
21 | * @file hello/gnunet-hello.c | ||
22 | * @brief change HELLO files to never expire | ||
23 | * @author Christian Grothoff | ||
24 | */ | ||
25 | #include "platform.h" | ||
26 | #include "gnunet_protocols.h" | ||
27 | #include "gnunet_hello_lib.h" | ||
28 | #include "gnunet_hello_uri_lib.h" | ||
29 | #include "gnunet_transport_plugin.h" | ||
30 | |||
31 | /** | ||
32 | * Closure for #add_to_buf(). | ||
33 | */ | ||
34 | struct AddContext | ||
35 | { | ||
36 | /** | ||
37 | * Where to add. | ||
38 | */ | ||
39 | char *buf; | ||
40 | |||
41 | /** | ||
42 | * Maximum number of bytes left | ||
43 | */ | ||
44 | size_t max; | ||
45 | |||
46 | /** | ||
47 | * Number of bytes added so far. | ||
48 | */ | ||
49 | size_t ret; | ||
50 | |||
51 | struct GNUNET_HELLO_Builder *builder; | ||
52 | }; | ||
53 | |||
54 | /** | ||
55 | * Entry in doubly-linked list of all of our plugins. | ||
56 | */ | ||
57 | struct TransportPlugin | ||
58 | { | ||
59 | /** | ||
60 | * This is a doubly-linked list. | ||
61 | */ | ||
62 | struct TransportPlugin *next; | ||
63 | |||
64 | /** | ||
65 | * This is a doubly-linked list. | ||
66 | */ | ||
67 | struct TransportPlugin *prev; | ||
68 | |||
69 | /** | ||
70 | * API of the transport as returned by the plugin's | ||
71 | * initialization function. | ||
72 | */ | ||
73 | struct GNUNET_TRANSPORT_PluginFunctions *api; | ||
74 | |||
75 | /** | ||
76 | * Short name for the plugin (e.g. "tcp"). | ||
77 | */ | ||
78 | char *short_name; | ||
79 | |||
80 | /** | ||
81 | * Name of the library (e.g. "gnunet_plugin_transport_tcp"). | ||
82 | */ | ||
83 | char *lib_name; | ||
84 | |||
85 | /** | ||
86 | * Environment this transport service is using | ||
87 | * for this plugin. | ||
88 | */ | ||
89 | struct GNUNET_TRANSPORT_PluginEnvironment env; | ||
90 | }; | ||
91 | |||
92 | static int address_count; | ||
93 | |||
94 | /** | ||
95 | * Our private key. | ||
96 | */ | ||
97 | static struct GNUNET_CRYPTO_EddsaPrivateKey *my_private_key; | ||
98 | |||
99 | /** | ||
100 | * Local peer own ID. | ||
101 | */ | ||
102 | struct GNUNET_PeerIdentity my_full_id; | ||
103 | |||
104 | /** | ||
105 | * The file with hello in old style which we like to replace with the new one. | ||
106 | */ | ||
107 | static char *hello_file; | ||
108 | |||
109 | /** | ||
110 | * Head of DLL of all loaded plugins. | ||
111 | */ | ||
112 | static struct TransportPlugin *plugins_head; | ||
113 | |||
114 | /** | ||
115 | * Head of DLL of all loaded plugins. | ||
116 | */ | ||
117 | static struct TransportPlugin *plugins_tail; | ||
118 | |||
119 | static void | ||
120 | plugins_load (const struct GNUNET_CONFIGURATION_Handle *cfg) | ||
121 | { | ||
122 | struct TransportPlugin *plug; | ||
123 | struct TransportPlugin *next; | ||
124 | char *libname; | ||
125 | char *plugs; | ||
126 | char *pos; | ||
127 | |||
128 | if (NULL != plugins_head) | ||
129 | return; /* already loaded */ | ||
130 | if (GNUNET_OK != | ||
131 | GNUNET_CONFIGURATION_get_value_string (cfg, "TRANSPORT", "PLUGINS", | ||
132 | &plugs)) | ||
133 | return; | ||
134 | fprintf (stdout,"Starting transport plugins `%s'\n", | ||
135 | plugs); | ||
136 | for (pos = strtok (plugs, " "); pos != NULL; pos = strtok (NULL, " ")) | ||
137 | { | ||
138 | fprintf (stdout,"Loading `%s' transport plugin\n", | ||
139 | pos); | ||
140 | GNUNET_asprintf (&libname, "libgnunet_plugin_transport_%s", pos); | ||
141 | plug = GNUNET_new (struct TransportPlugin); | ||
142 | plug->short_name = GNUNET_strdup (pos); | ||
143 | plug->lib_name = libname; | ||
144 | plug->env.cfg = cfg; | ||
145 | plug->env.cls = plug->short_name; | ||
146 | GNUNET_CONTAINER_DLL_insert (plugins_head, plugins_tail, plug); | ||
147 | } | ||
148 | GNUNET_free (plugs); | ||
149 | next = plugins_head; | ||
150 | while (next != NULL) | ||
151 | { | ||
152 | plug = next; | ||
153 | next = plug->next; | ||
154 | plug->api = GNUNET_PLUGIN_load (plug->lib_name, &plug->env); | ||
155 | if (plug->api == NULL) | ||
156 | { | ||
157 | fprintf (stdout,"Failed to load transport plugin for `%s'\n", | ||
158 | plug->lib_name); | ||
159 | GNUNET_CONTAINER_DLL_remove (plugins_head, plugins_tail, plug); | ||
160 | GNUNET_free (plug->short_name); | ||
161 | GNUNET_free (plug->lib_name); | ||
162 | GNUNET_free (plug); | ||
163 | } | ||
164 | } | ||
165 | } | ||
166 | |||
167 | |||
168 | static int | ||
169 | add_to_builder (void *cls, | ||
170 | const struct GNUNET_HELLO_Address *address, | ||
171 | struct GNUNET_TIME_Absolute expiration) | ||
172 | { | ||
173 | struct GNUNET_HELLO_Builder *builder= cls; | ||
174 | struct TransportPlugin *pos = plugins_head; | ||
175 | const char *addr; | ||
176 | char *uri; | ||
177 | |||
178 | while (NULL != pos) | ||
179 | { | ||
180 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
181 | "short_name: %s transport_name: %s\n", | ||
182 | pos->short_name, | ||
183 | address->transport_name); | ||
184 | if (0 == strcmp (address->transport_name, pos->short_name)) | ||
185 | { | ||
186 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
187 | "short_name: %s transport_name: %s are the same\n", | ||
188 | pos->short_name, | ||
189 | address->transport_name); | ||
190 | addr = strchr (strchr (pos->api->address_to_string (pos, address, address->address_length), '.')+1, '.') + 1; | ||
191 | } | ||
192 | pos = pos->next; | ||
193 | } | ||
194 | |||
195 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
196 | "Hello address string: %s\n", | ||
197 | addr); | ||
198 | GNUNET_asprintf (&uri, "%s://%s", address->transport_name, addr); | ||
199 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
200 | "Hello address uri string: %s\n", | ||
201 | uri); | ||
202 | GNUNET_HELLO_builder_add_address (builder, | ||
203 | uri); | ||
204 | } | ||
205 | |||
206 | |||
207 | /** | ||
208 | * Add the given address with infinite expiration to the buffer. | ||
209 | * | ||
210 | * @param cls closure | ||
211 | * @param address address to add | ||
212 | * @param expiration old expiration | ||
213 | * @return #GNUNET_OK keep iterating | ||
214 | */ | ||
215 | static int | ||
216 | add_to_buf (void *cls, | ||
217 | const struct GNUNET_HELLO_Address *address, | ||
218 | struct GNUNET_TIME_Absolute expiration) | ||
219 | { | ||
220 | struct AddContext *ac = cls; | ||
221 | size_t ret; | ||
222 | |||
223 | ret = GNUNET_HELLO_add_address (address, | ||
224 | GNUNET_TIME_UNIT_FOREVER_ABS, | ||
225 | ac->buf, | ||
226 | ac->max); | ||
227 | |||
228 | ac->buf += ret; | ||
229 | ac->max -= ret; | ||
230 | ac->ret += ret; | ||
231 | address_count++; | ||
232 | return GNUNET_OK; | ||
233 | } | ||
234 | |||
235 | |||
236 | /** | ||
237 | * Add addresses from the address list to the HELLO. | ||
238 | * | ||
239 | * @param cls the HELLO with the addresses to add | ||
240 | * @param max maximum space available | ||
241 | * @param buf where to add the addresses | ||
242 | * @return number of bytes added, 0 to terminate | ||
243 | */ | ||
244 | static ssize_t | ||
245 | add_from_hello (void *cls, size_t max, void *buf) | ||
246 | { | ||
247 | struct GNUNET_HELLO_Message **orig = cls; | ||
248 | struct AddContext ac; | ||
249 | |||
250 | if (NULL == *orig) | ||
251 | return GNUNET_SYSERR; /* already done */ | ||
252 | ac.buf = buf; | ||
253 | ac.max = max; | ||
254 | ac.ret = 0; | ||
255 | GNUNET_assert ( | ||
256 | NULL == | ||
257 | GNUNET_HELLO_iterate_addresses (*orig, GNUNET_NO, &add_to_buf, &ac)); | ||
258 | *orig = NULL; | ||
259 | return ac.ret; | ||
260 | } | ||
261 | |||
262 | |||
263 | /** | ||
264 | * Main function that will be run without the scheduler. | ||
265 | * | ||
266 | * @param cls closure | ||
267 | * @param args remaining command-line arguments | ||
268 | * @param cfgfile name of the configuration file used (for saving, can be NULL!) | ||
269 | * @param c configuration | ||
270 | */ | ||
271 | static void | ||
272 | run (void *cls, | ||
273 | char *const *args, | ||
274 | const char *cfgfile, | ||
275 | const struct GNUNET_CONFIGURATION_Handle *c) | ||
276 | { | ||
277 | struct GNUNET_DISK_FileHandle *fh; | ||
278 | struct GNUNET_HELLO_Message *orig; | ||
279 | struct GNUNET_HELLO_Message *result; | ||
280 | struct GNUNET_PeerIdentity pid; | ||
281 | uint64_t fsize; | ||
282 | ssize_t size_written; | ||
283 | struct GNUNET_HELLO_Builder *builder; | ||
284 | char *url; | ||
285 | const struct GNUNET_MessageHeader *msg; | ||
286 | struct GNUNET_MQ_Envelope *env; | ||
287 | |||
288 | plugins_load (c); | ||
289 | address_count = 0; | ||
290 | |||
291 | my_private_key = | ||
292 | GNUNET_CRYPTO_eddsa_key_create_from_configuration (c); | ||
293 | GNUNET_CRYPTO_eddsa_key_get_public (my_private_key, | ||
294 | &my_full_id.public_key); | ||
295 | fprintf (stdout,"We are peer %s\n", GNUNET_i2s (&my_full_id)); | ||
296 | |||
297 | GNUNET_log_setup ("gnunet-hello", "DEBUG", NULL); | ||
298 | |||
299 | if (GNUNET_OK != | ||
300 | GNUNET_DISK_file_size (hello_file, &fsize, GNUNET_YES, GNUNET_YES)) | ||
301 | { | ||
302 | fprintf (stderr, | ||
303 | _ ("Error accessing file `%s': %s\n"), | ||
304 | hello_file, | ||
305 | strerror (errno)); | ||
306 | return; | ||
307 | } | ||
308 | if (fsize > 65536) | ||
309 | { | ||
310 | fprintf (stderr, _ ("File `%s' is too big to be a HELLO\n"), hello_file); | ||
311 | return; | ||
312 | } | ||
313 | if (fsize < sizeof(struct GNUNET_MessageHeader)) | ||
314 | { | ||
315 | fprintf (stderr, _ ("File `%s' is too small to be a HELLO\n"), hello_file); | ||
316 | return; | ||
317 | } | ||
318 | fh = GNUNET_DISK_file_open (hello_file, | ||
319 | GNUNET_DISK_OPEN_READ, | ||
320 | GNUNET_DISK_PERM_USER_READ); | ||
321 | if (NULL == fh) | ||
322 | { | ||
323 | fprintf (stderr, | ||
324 | _ ("Error opening file `%s': %s\n"), | ||
325 | hello_file, | ||
326 | strerror (errno)); | ||
327 | return; | ||
328 | } | ||
329 | { | ||
330 | char buf[fsize] GNUNET_ALIGN; | ||
331 | |||
332 | GNUNET_assert (fsize == GNUNET_DISK_file_read (fh, buf, fsize)); | ||
333 | GNUNET_assert (GNUNET_OK == GNUNET_DISK_file_close (fh)); | ||
334 | orig = (struct GNUNET_HELLO_Message *) buf; | ||
335 | if ((fsize < GNUNET_HELLO_size (orig)) || | ||
336 | (GNUNET_OK != GNUNET_HELLO_get_id (orig, &pid))) | ||
337 | { | ||
338 | fprintf (stderr, | ||
339 | _ ("Did not find well-formed HELLO in file `%s'\n"), | ||
340 | hello_file); | ||
341 | return; | ||
342 | } | ||
343 | { | ||
344 | char *pids; | ||
345 | |||
346 | pids = GNUNET_CRYPTO_eddsa_public_key_to_string (&pid.public_key); | ||
347 | fprintf (stdout, "Processing HELLO for peer `%s'\n", pids); | ||
348 | GNUNET_free (pids); | ||
349 | } | ||
350 | /* result = GNUNET_HELLO_create (&pid.public_key, */ | ||
351 | /* &add_from_hello, */ | ||
352 | /* &orig, */ | ||
353 | /* GNUNET_HELLO_is_friend_only (orig)); */ | ||
354 | |||
355 | builder = GNUNET_HELLO_builder_new (&pid); | ||
356 | GNUNET_assert ( | ||
357 | NULL == | ||
358 | GNUNET_HELLO_iterate_addresses ((const struct GNUNET_HELLO_Message *) orig, GNUNET_NO, &add_to_builder, builder)); | ||
359 | url = GNUNET_HELLO_builder_to_url (builder, my_private_key); | ||
360 | fprintf (stdout,"url: %s\n", url); | ||
361 | env = GNUNET_HELLO_builder_to_env (builder, | ||
362 | my_private_key, | ||
363 | GNUNET_TIME_UNIT_ZERO); | ||
364 | msg = GNUNET_MQ_env_get_msg (env); | ||
365 | //GNUNET_assert (NULL != result); | ||
366 | GNUNET_assert (NULL != msg); | ||
367 | fh = | ||
368 | GNUNET_DISK_file_open (hello_file, | ||
369 | GNUNET_DISK_OPEN_WRITE | GNUNET_DISK_OPEN_TRUNCATE, | ||
370 | GNUNET_DISK_PERM_USER_READ | ||
371 | | GNUNET_DISK_PERM_USER_WRITE); | ||
372 | if (NULL == fh) | ||
373 | { | ||
374 | fprintf (stderr, | ||
375 | _ ("Error opening file `%s': %s\n"), | ||
376 | hello_file, | ||
377 | strerror (errno)); | ||
378 | GNUNET_free (result); | ||
379 | return; | ||
380 | } | ||
381 | //fsize = GNUNET_HELLO_size (result); | ||
382 | size_written = GNUNET_DISK_file_write (fh, msg, ntohs (msg->size)); | ||
383 | if (ntohs (msg->size) != size_written) | ||
384 | { | ||
385 | fprintf (stderr, | ||
386 | _ ("Error writing HELLO to file `%s': %s expected size %u size written %u\n"), | ||
387 | hello_file, | ||
388 | strerror (errno)); | ||
389 | (void) GNUNET_DISK_file_close (fh); | ||
390 | return; | ||
391 | } | ||
392 | GNUNET_assert (GNUNET_OK == GNUNET_DISK_file_close (fh)); | ||
393 | } | ||
394 | fprintf (stderr, | ||
395 | _ ("Modified %u addresses, wrote %u bytes\n"), | ||
396 | address_count, | ||
397 | (unsigned int) ntohs (msg->size)); | ||
398 | GNUNET_HELLO_builder_free (builder); | ||
399 | } | ||
400 | |||
401 | |||
402 | int | ||
403 | main (int argc, char *argv[]) | ||
404 | { | ||
405 | struct GNUNET_GETOPT_CommandLineOption options[] = | ||
406 | { GNUNET_GETOPT_option_string ('h', | ||
407 | "hello-file", | ||
408 | "HELLO_FILE", | ||
409 | gettext_noop ("Hello file to read"), | ||
410 | &hello_file), | ||
411 | GNUNET_GETOPT_OPTION_END }; | ||
412 | int ret; | ||
413 | |||
414 | ret = (GNUNET_OK == | ||
415 | GNUNET_PROGRAM_run2 (argc, | ||
416 | argv, | ||
417 | "gnunet-peerinfo", | ||
418 | gettext_noop ("Print information about peers."), | ||
419 | options, | ||
420 | &run, | ||
421 | NULL, | ||
422 | GNUNET_YES)); | ||
423 | return ret; | ||
424 | } | ||
425 | |||
426 | |||
427 | /* end of gnunet-hello.c */ | ||
diff --git a/src/hostlist/Makefile.am b/src/hostlist/Makefile.am index 1fdab4a3d..c03e5bab2 100644 --- a/src/hostlist/Makefile.am +++ b/src/hostlist/Makefile.am | |||
@@ -27,10 +27,10 @@ gnunet_daemon_hostlist_SOURCES = \ | |||
27 | 27 | ||
28 | gnunet_daemon_hostlist_LDADD = \ | 28 | gnunet_daemon_hostlist_LDADD = \ |
29 | $(top_builddir)/src/core/libgnunetcore.la \ | 29 | $(top_builddir)/src/core/libgnunetcore.la \ |
30 | $(top_builddir)/src/hello/libgnunethello.la \ | 30 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
31 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 31 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
32 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 32 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
33 | $(top_builddir)/src/util/libgnunetutil.la \ | 33 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
34 | $(GN_LIBMHD) \ | 34 | $(GN_LIBMHD) \ |
35 | @LIBCURL@ \ | 35 | @LIBCURL@ \ |
36 | $(GN_LIBINTL) | 36 | $(GN_LIBINTL) |
@@ -55,13 +55,13 @@ endif | |||
55 | # test_gnunet_daemon_hostlist.c | 55 | # test_gnunet_daemon_hostlist.c |
56 | #test_gnunet_daemon_hostlist_LDADD = \ | 56 | #test_gnunet_daemon_hostlist_LDADD = \ |
57 | # $(top_builddir)/src/transport/libgnunettransport.la \ | 57 | # $(top_builddir)/src/transport/libgnunettransport.la \ |
58 | # $(top_builddir)/src/util/libgnunetutil.la | 58 | # $(top_builddir)/src/lib/util/libgnunetutil.la |
59 | # | 59 | # |
60 | #test_gnunet_daemon_hostlist_reconnect_SOURCES = \ | 60 | #test_gnunet_daemon_hostlist_reconnect_SOURCES = \ |
61 | # test_gnunet_daemon_hostlist_reconnect.c | 61 | # test_gnunet_daemon_hostlist_reconnect.c |
62 | #test_gnunet_daemon_hostlist_reconnect_LDADD = \ | 62 | #test_gnunet_daemon_hostlist_reconnect_LDADD = \ |
63 | # $(top_builddir)/src/transport/libgnunettransport.la \ | 63 | # $(top_builddir)/src/transport/libgnunettransport.la \ |
64 | # $(top_builddir)/src/util/libgnunetutil.la | 64 | # $(top_builddir)/src/lib/util/libgnunetutil.la |
65 | # | 65 | # |
66 | #test_gnunet_daemon_hostlist_learning_SOURCES = \ | 66 | #test_gnunet_daemon_hostlist_learning_SOURCES = \ |
67 | # test_gnunet_daemon_hostlist_learning.c | 67 | # test_gnunet_daemon_hostlist_learning.c |
@@ -69,7 +69,7 @@ endif | |||
69 | # $(top_builddir)/src/transport/libgnunettransport.la \ | 69 | # $(top_builddir)/src/transport/libgnunettransport.la \ |
70 | # $(top_builddir)/src/core/libgnunetcore.la \ | 70 | # $(top_builddir)/src/core/libgnunetcore.la \ |
71 | # $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 71 | # $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
72 | # $(top_builddir)/src/util/libgnunetutil.la | 72 | # $(top_builddir)/src/lib/util/libgnunetutil.la |
73 | 73 | ||
74 | EXTRA_DIST = \ | 74 | EXTRA_DIST = \ |
75 | test_hostlist_defaults.conf \ | 75 | test_hostlist_defaults.conf \ |
diff --git a/src/identity/Makefile.am b/src/identity/Makefile.am index fecfaea47..bd9712da3 100644 --- a/src/identity/Makefile.am +++ b/src/identity/Makefile.am | |||
@@ -26,7 +26,7 @@ libgnunet_plugin_rest_identity_la_SOURCES = \ | |||
26 | libgnunet_plugin_rest_identity_la_LIBADD = \ | 26 | libgnunet_plugin_rest_identity_la_LIBADD = \ |
27 | libgnunetidentity.la \ | 27 | libgnunetidentity.la \ |
28 | $(top_builddir)/src/rest/libgnunetrest.la \ | 28 | $(top_builddir)/src/rest/libgnunetrest.la \ |
29 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 29 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) \ |
30 | $(LTLIBINTL) -ljansson $(MHD_LIBS) | 30 | $(LTLIBINTL) -ljansson $(MHD_LIBS) |
31 | libgnunet_plugin_rest_identity_la_LDFLAGS = \ | 31 | libgnunet_plugin_rest_identity_la_LDFLAGS = \ |
32 | $(GN_PLUGIN_LDFLAGS) | 32 | $(GN_PLUGIN_LDFLAGS) |
@@ -39,7 +39,7 @@ libgnunetidentity_la_SOURCES = \ | |||
39 | identity_api_suffix_lookup.c \ | 39 | identity_api_suffix_lookup.c \ |
40 | identity.h | 40 | identity.h |
41 | libgnunetidentity_la_LIBADD = \ | 41 | libgnunetidentity_la_LIBADD = \ |
42 | $(top_builddir)/src/util/libgnunetutil.la \ | 42 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
43 | $(GN_LIBINTL) $(XLIB) | 43 | $(GN_LIBINTL) $(XLIB) |
44 | libgnunetidentity_la_LDFLAGS = \ | 44 | libgnunetidentity_la_LDFLAGS = \ |
45 | $(GN_LIB_LDFLAGS) \ | 45 | $(GN_LIB_LDFLAGS) \ |
@@ -57,7 +57,7 @@ gnunet_service_identity_SOURCES = \ | |||
57 | gnunet_service_identity_LDADD = \ | 57 | gnunet_service_identity_LDADD = \ |
58 | libgnunetidentity.la \ | 58 | libgnunetidentity.la \ |
59 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 59 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
60 | $(top_builddir)/src/util/libgnunetutil.la \ | 60 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
61 | $(GN_LIBINTL) | 61 | $(GN_LIBINTL) |
62 | 62 | ||
63 | 63 | ||
@@ -66,7 +66,7 @@ gnunet_identity_SOURCES = \ | |||
66 | gnunet_identity_LDADD = \ | 66 | gnunet_identity_LDADD = \ |
67 | libgnunetidentity.la \ | 67 | libgnunetidentity.la \ |
68 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 68 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
69 | $(top_builddir)/src/util/libgnunetutil.la \ | 69 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
70 | $(GN_LIBINTL) | 70 | $(GN_LIBINTL) |
71 | 71 | ||
72 | check_PROGRAMS = \ | 72 | check_PROGRAMS = \ |
@@ -86,7 +86,7 @@ test_identity_SOURCES = \ | |||
86 | test_identity_LDADD = \ | 86 | test_identity_LDADD = \ |
87 | libgnunetidentity.la \ | 87 | libgnunetidentity.la \ |
88 | $(top_builddir)/src/testing/libgnunettesting.la \ | 88 | $(top_builddir)/src/testing/libgnunettesting.la \ |
89 | $(top_builddir)/src/util/libgnunetutil.la | 89 | $(top_builddir)/src/lib/util/libgnunetutil.la |
90 | 90 | ||
91 | EXTRA_DIST = \ | 91 | EXTRA_DIST = \ |
92 | test_identity.conf \ | 92 | test_identity.conf \ |
diff --git a/src/identity/gnunet-identity.c b/src/identity/gnunet-identity.c index 7adc86eb8..9fe4ccc51 100644 --- a/src/identity/gnunet-identity.c +++ b/src/identity/gnunet-identity.c | |||
@@ -123,7 +123,7 @@ static struct GNUNET_IDENTITY_Operation *delete_op; | |||
123 | /** | 123 | /** |
124 | * Private key from command line option, or NULL. | 124 | * Private key from command line option, or NULL. |
125 | */ | 125 | */ |
126 | struct GNUNET_IDENTITY_PrivateKey pk; | 126 | struct GNUNET_CRYPTO_PrivateKey pk; |
127 | 127 | ||
128 | /** | 128 | /** |
129 | * Value to return from #main(). | 129 | * Value to return from #main(). |
@@ -213,7 +213,7 @@ delete_finished (void *cls, | |||
213 | */ | 213 | */ |
214 | static void | 214 | static void |
215 | create_finished (void *cls, | 215 | create_finished (void *cls, |
216 | const struct GNUNET_IDENTITY_PrivateKey *pk, | 216 | const struct GNUNET_CRYPTO_PrivateKey *pk, |
217 | enum GNUNET_ErrorCode ec) | 217 | enum GNUNET_ErrorCode ec) |
218 | { | 218 | { |
219 | struct GNUNET_IDENTITY_Operation **op = cls; | 219 | struct GNUNET_IDENTITY_Operation **op = cls; |
@@ -228,16 +228,16 @@ create_finished (void *cls, | |||
228 | } | 228 | } |
229 | else if (verbose) | 229 | else if (verbose) |
230 | { | 230 | { |
231 | struct GNUNET_IDENTITY_PublicKey pub; | 231 | struct GNUNET_CRYPTO_PublicKey pub; |
232 | char *pubs; | 232 | char *pubs; |
233 | 233 | ||
234 | GNUNET_IDENTITY_key_get_public (pk, &pub); | 234 | GNUNET_CRYPTO_key_get_public (pk, &pub); |
235 | pubs = GNUNET_IDENTITY_public_key_to_string (&pub); | 235 | pubs = GNUNET_CRYPTO_public_key_to_string (&pub); |
236 | if (private_keys) | 236 | if (private_keys) |
237 | { | 237 | { |
238 | char *privs; | 238 | char *privs; |
239 | 239 | ||
240 | privs = GNUNET_IDENTITY_private_key_to_string (pk); | 240 | privs = GNUNET_CRYPTO_private_key_to_string (pk); |
241 | fprintf (stdout, "%s - %s\n", pubs, privs); | 241 | fprintf (stdout, "%s - %s\n", pubs, privs); |
242 | GNUNET_free (privs); | 242 | GNUNET_free (privs); |
243 | } | 243 | } |
@@ -258,15 +258,15 @@ create_finished (void *cls, | |||
258 | static void | 258 | static void |
259 | write_encrypted_message (void) | 259 | write_encrypted_message (void) |
260 | { | 260 | { |
261 | struct GNUNET_IDENTITY_PublicKey recipient; | 261 | struct GNUNET_CRYPTO_PublicKey recipient; |
262 | size_t ct_len = strlen (write_msg) + 1 | 262 | size_t ct_len = strlen (write_msg) + 1 |
263 | + GNUNET_IDENTITY_ENCRYPT_OVERHEAD_BYTES; | 263 | + GNUNET_CRYPTO_ENCRYPT_OVERHEAD_BYTES; |
264 | unsigned char ct[ct_len]; | 264 | unsigned char ct[ct_len]; |
265 | if (GNUNET_IDENTITY_public_key_from_string (pubkey_msg, &recipient) != | 265 | if (GNUNET_CRYPTO_public_key_from_string (pubkey_msg, &recipient) != |
266 | GNUNET_SYSERR) | 266 | GNUNET_SYSERR) |
267 | { | 267 | { |
268 | size_t msg_len = strlen (write_msg) + 1; | 268 | size_t msg_len = strlen (write_msg) + 1; |
269 | if (GNUNET_OK == GNUNET_IDENTITY_encrypt (write_msg, | 269 | if (GNUNET_OK == GNUNET_CRYPTO_encrypt (write_msg, |
270 | msg_len, | 270 | msg_len, |
271 | &recipient, | 271 | &recipient, |
272 | ct, ct_len)) | 272 | ct, ct_len)) |
@@ -309,7 +309,7 @@ read_encrypted_message (struct GNUNET_IDENTITY_Ego *ego) | |||
309 | deserialized_msg, | 309 | deserialized_msg, |
310 | &msg_len)) | 310 | &msg_len)) |
311 | { | 311 | { |
312 | if (GNUNET_OK == GNUNET_IDENTITY_decrypt (deserialized_msg, | 312 | if (GNUNET_OK == GNUNET_CRYPTO_decrypt (deserialized_msg, |
313 | msg_len, | 313 | msg_len, |
314 | GNUNET_IDENTITY_ego_get_private_key ( | 314 | GNUNET_IDENTITY_ego_get_private_key ( |
315 | ego), | 315 | ego), |
@@ -373,7 +373,7 @@ print_ego (void *cls, | |||
373 | void **ctx, | 373 | void **ctx, |
374 | const char *identifier) | 374 | const char *identifier) |
375 | { | 375 | { |
376 | struct GNUNET_IDENTITY_PublicKey pk; | 376 | struct GNUNET_CRYPTO_PublicKey pk; |
377 | char *s; | 377 | char *s; |
378 | char *privs; | 378 | char *privs; |
379 | 379 | ||
@@ -405,8 +405,8 @@ print_ego (void *cls, | |||
405 | set_ego)) ) | 405 | set_ego)) ) |
406 | return; | 406 | return; |
407 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 407 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
408 | s = GNUNET_IDENTITY_public_key_to_string (&pk); | 408 | s = GNUNET_CRYPTO_public_key_to_string (&pk); |
409 | privs = GNUNET_IDENTITY_private_key_to_string ( | 409 | privs = GNUNET_CRYPTO_private_key_to_string ( |
410 | GNUNET_IDENTITY_ego_get_private_key (ego)); | 410 | GNUNET_IDENTITY_ego_get_private_key (ego)); |
411 | if ((NULL != read_msg) && (NULL != set_ego)) | 411 | if ((NULL != read_msg) && (NULL != set_ego)) |
412 | { | 412 | { |
@@ -429,12 +429,12 @@ print_ego (void *cls, | |||
429 | if (private_keys) | 429 | if (private_keys) |
430 | fprintf (stdout, "%s - %s - %s - %s\n", | 430 | fprintf (stdout, "%s - %s - %s - %s\n", |
431 | identifier, s, privs, | 431 | identifier, s, privs, |
432 | (ntohl (pk.type) == GNUNET_IDENTITY_TYPE_ECDSA) ? | 432 | (ntohl (pk.type) == GNUNET_PUBLIC_KEY_TYPE_ECDSA) ? |
433 | "ECDSA" : "EdDSA"); | 433 | "ECDSA" : "EdDSA"); |
434 | else | 434 | else |
435 | fprintf (stdout, "%s - %s - %s\n", | 435 | fprintf (stdout, "%s - %s - %s\n", |
436 | identifier, s, | 436 | identifier, s, |
437 | (ntohl (pk.type) == GNUNET_IDENTITY_TYPE_ECDSA) ? | 437 | (ntohl (pk.type) == GNUNET_PUBLIC_KEY_TYPE_ECDSA) ? |
438 | "ECDSA" : "EdDSA"); | 438 | "ECDSA" : "EdDSA"); |
439 | 439 | ||
440 | } | 440 | } |
@@ -497,7 +497,7 @@ run (void *cls, | |||
497 | strlen (privkey_ego), | 497 | strlen (privkey_ego), |
498 | &pk, | 498 | &pk, |
499 | sizeof(struct | 499 | sizeof(struct |
500 | GNUNET_IDENTITY_PrivateKey)); | 500 | GNUNET_CRYPTO_PrivateKey)); |
501 | create_op = | 501 | create_op = |
502 | GNUNET_IDENTITY_create (sh, | 502 | GNUNET_IDENTITY_create (sh, |
503 | create_ego, | 503 | create_ego, |
@@ -512,8 +512,8 @@ run (void *cls, | |||
512 | create_ego, | 512 | create_ego, |
513 | NULL, | 513 | NULL, |
514 | (type_eddsa) ? | 514 | (type_eddsa) ? |
515 | GNUNET_IDENTITY_TYPE_EDDSA : | 515 | GNUNET_PUBLIC_KEY_TYPE_EDDSA : |
516 | GNUNET_IDENTITY_TYPE_ECDSA, | 516 | GNUNET_PUBLIC_KEY_TYPE_ECDSA, |
517 | &create_finished, | 517 | &create_finished, |
518 | &create_op); | 518 | &create_op); |
519 | } | 519 | } |
diff --git a/src/identity/gnunet-service-identity.c b/src/identity/gnunet-service-identity.c index 07296a882..7ac4bf2b9 100644 --- a/src/identity/gnunet-service-identity.c +++ b/src/identity/gnunet-service-identity.c | |||
@@ -57,7 +57,7 @@ struct Ego | |||
57 | /** | 57 | /** |
58 | * Private key of the ego. | 58 | * Private key of the ego. |
59 | */ | 59 | */ |
60 | struct GNUNET_IDENTITY_PrivateKey pk; | 60 | struct GNUNET_CRYPTO_PrivateKey pk; |
61 | 61 | ||
62 | /** | 62 | /** |
63 | * String identifier for the ego. | 63 | * String identifier for the ego. |
@@ -238,7 +238,7 @@ create_update_message (struct Ego *ego) | |||
238 | size_t name_len; | 238 | size_t name_len; |
239 | ssize_t key_len; | 239 | ssize_t key_len; |
240 | 240 | ||
241 | key_len = GNUNET_IDENTITY_private_key_get_length (&ego->pk); | 241 | key_len = GNUNET_CRYPTO_private_key_get_length (&ego->pk); |
242 | name_len = (NULL == ego->identifier) ? 0 : (strlen (ego->identifier) + 1); | 242 | name_len = (NULL == ego->identifier) ? 0 : (strlen (ego->identifier) + 1); |
243 | env = GNUNET_MQ_msg_extra (um, name_len + key_len, | 243 | env = GNUNET_MQ_msg_extra (um, name_len + key_len, |
244 | GNUNET_MESSAGE_TYPE_IDENTITY_UPDATE); | 244 | GNUNET_MESSAGE_TYPE_IDENTITY_UPDATE); |
@@ -246,7 +246,7 @@ create_update_message (struct Ego *ego) | |||
246 | um->end_of_list = htons (GNUNET_NO); | 246 | um->end_of_list = htons (GNUNET_NO); |
247 | um->key_len = htons (key_len); | 247 | um->key_len = htons (key_len); |
248 | GNUNET_memcpy (&um[1], ego->identifier, name_len); | 248 | GNUNET_memcpy (&um[1], ego->identifier, name_len); |
249 | GNUNET_IDENTITY_write_private_key_to_buffer (&ego->pk, | 249 | GNUNET_CRYPTO_write_private_key_to_buffer (&ego->pk, |
250 | ((char*) &um[1]) + name_len, | 250 | ((char*) &um[1]) + name_len, |
251 | key_len); | 251 | key_len); |
252 | return env; | 252 | return env; |
@@ -422,7 +422,7 @@ notify_listeners (struct Ego *ego) | |||
422 | ssize_t key_len; | 422 | ssize_t key_len; |
423 | 423 | ||
424 | name_len = (NULL == ego->identifier) ? 0 : (strlen (ego->identifier) + 1); | 424 | name_len = (NULL == ego->identifier) ? 0 : (strlen (ego->identifier) + 1); |
425 | key_len = GNUNET_IDENTITY_private_key_get_length (&ego->pk); | 425 | key_len = GNUNET_CRYPTO_private_key_get_length (&ego->pk); |
426 | um = GNUNET_malloc (sizeof(struct UpdateMessage) + name_len + key_len); | 426 | um = GNUNET_malloc (sizeof(struct UpdateMessage) + name_len + key_len); |
427 | um->header.type = htons (GNUNET_MESSAGE_TYPE_IDENTITY_UPDATE); | 427 | um->header.type = htons (GNUNET_MESSAGE_TYPE_IDENTITY_UPDATE); |
428 | um->header.size = htons (sizeof(struct UpdateMessage) + name_len + key_len); | 428 | um->header.size = htons (sizeof(struct UpdateMessage) + name_len + key_len); |
@@ -430,7 +430,7 @@ notify_listeners (struct Ego *ego) | |||
430 | um->end_of_list = htons (GNUNET_NO); | 430 | um->end_of_list = htons (GNUNET_NO); |
431 | um->key_len = htons (key_len); | 431 | um->key_len = htons (key_len); |
432 | GNUNET_memcpy (&um[1], ego->identifier, name_len); | 432 | GNUNET_memcpy (&um[1], ego->identifier, name_len); |
433 | GNUNET_IDENTITY_write_private_key_to_buffer (&ego->pk, | 433 | GNUNET_CRYPTO_write_private_key_to_buffer (&ego->pk, |
434 | ((char*) &um[1]) + name_len, | 434 | ((char*) &um[1]) + name_len, |
435 | key_len); | 435 | key_len); |
436 | GNUNET_notification_context_broadcast (nc, &um->header, GNUNET_NO); | 436 | GNUNET_notification_context_broadcast (nc, &um->header, GNUNET_NO); |
@@ -487,7 +487,7 @@ static void | |||
487 | handle_create_message (void *cls, | 487 | handle_create_message (void *cls, |
488 | const struct CreateRequestMessage *crm) | 488 | const struct CreateRequestMessage *crm) |
489 | { | 489 | { |
490 | struct GNUNET_IDENTITY_PrivateKey private_key; | 490 | struct GNUNET_CRYPTO_PrivateKey private_key; |
491 | struct GNUNET_SERVICE_Client *client = cls; | 491 | struct GNUNET_SERVICE_Client *client = cls; |
492 | struct Ego *ego; | 492 | struct Ego *ego; |
493 | char *str; | 493 | char *str; |
@@ -498,7 +498,7 @@ handle_create_message (void *cls, | |||
498 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Received CREATE message from client\n"); | 498 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Received CREATE message from client\n"); |
499 | key_len = ntohs (crm->key_len); | 499 | key_len = ntohs (crm->key_len); |
500 | if ((GNUNET_SYSERR == | 500 | if ((GNUNET_SYSERR == |
501 | GNUNET_IDENTITY_read_private_key_from_buffer (&crm[1], | 501 | GNUNET_CRYPTO_read_private_key_from_buffer (&crm[1], |
502 | key_len, | 502 | key_len, |
503 | &private_key, | 503 | &private_key, |
504 | &kb_read)) || | 504 | &kb_read)) || |
@@ -531,7 +531,7 @@ handle_create_message (void *cls, | |||
531 | if (GNUNET_OK != | 531 | if (GNUNET_OK != |
532 | GNUNET_DISK_fn_write (fn, | 532 | GNUNET_DISK_fn_write (fn, |
533 | &private_key, | 533 | &private_key, |
534 | sizeof(struct GNUNET_IDENTITY_PrivateKey), | 534 | sizeof(struct GNUNET_CRYPTO_PrivateKey), |
535 | GNUNET_DISK_PERM_USER_READ | 535 | GNUNET_DISK_PERM_USER_READ |
536 | | GNUNET_DISK_PERM_USER_WRITE)) | 536 | | GNUNET_DISK_PERM_USER_WRITE)) |
537 | GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_ERROR, "write", fn); | 537 | GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_ERROR, "write", fn); |
diff --git a/src/identity/identity.h b/src/identity/identity.h index a3193ca2a..acb403736 100644 --- a/src/identity/identity.h +++ b/src/identity/identity.h | |||
@@ -43,12 +43,12 @@ struct GNUNET_IDENTITY_Ego | |||
43 | /** | 43 | /** |
44 | * The identity key pair | 44 | * The identity key pair |
45 | */ | 45 | */ |
46 | struct GNUNET_IDENTITY_PublicKey pub; | 46 | struct GNUNET_CRYPTO_PublicKey pub; |
47 | 47 | ||
48 | /** | 48 | /** |
49 | * The identity key pair | 49 | * The identity key pair |
50 | */ | 50 | */ |
51 | struct GNUNET_IDENTITY_PrivateKey pk; | 51 | struct GNUNET_CRYPTO_PrivateKey pk; |
52 | 52 | ||
53 | /** | 53 | /** |
54 | * Current name associated with this ego. | 54 | * Current name associated with this ego. |
diff --git a/src/identity/identity_api.c b/src/identity/identity_api.c index 3a9258aa4..fe789d643 100644 --- a/src/identity/identity_api.c +++ b/src/identity/identity_api.c | |||
@@ -75,7 +75,7 @@ struct GNUNET_IDENTITY_Operation | |||
75 | /** | 75 | /** |
76 | * Private key to return to @e create_cont, or NULL. | 76 | * Private key to return to @e create_cont, or NULL. |
77 | */ | 77 | */ |
78 | struct GNUNET_IDENTITY_PrivateKey pk; | 78 | struct GNUNET_CRYPTO_PrivateKey pk; |
79 | 79 | ||
80 | /** | 80 | /** |
81 | * Continuation to invoke with the result of the transmission for | 81 | * Continuation to invoke with the result of the transmission for |
@@ -162,10 +162,10 @@ GNUNET_IDENTITY_ego_get_anonymous () | |||
162 | 162 | ||
163 | if (setup) | 163 | if (setup) |
164 | return &anon; | 164 | return &anon; |
165 | anon.pk.type = htonl (GNUNET_IDENTITY_TYPE_ECDSA); | 165 | anon.pk.type = htonl (GNUNET_PUBLIC_KEY_TYPE_ECDSA); |
166 | anon.pub.type = htonl (GNUNET_IDENTITY_TYPE_ECDSA); | 166 | anon.pub.type = htonl (GNUNET_PUBLIC_KEY_TYPE_ECDSA); |
167 | anon.pk.ecdsa_key = *GNUNET_CRYPTO_ecdsa_key_get_anonymous (); | 167 | anon.pk.ecdsa_key = *GNUNET_CRYPTO_ecdsa_key_get_anonymous (); |
168 | key_len = GNUNET_IDENTITY_private_key_get_length (&anon.pk); | 168 | key_len = GNUNET_CRYPTO_private_key_get_length (&anon.pk); |
169 | GNUNET_assert (0 < key_len); | 169 | GNUNET_assert (0 < key_len); |
170 | GNUNET_CRYPTO_hash (&anon.pk, | 170 | GNUNET_CRYPTO_hash (&anon.pk, |
171 | key_len, | 171 | key_len, |
@@ -175,50 +175,6 @@ GNUNET_IDENTITY_ego_get_anonymous () | |||
175 | } | 175 | } |
176 | 176 | ||
177 | 177 | ||
178 | enum GNUNET_GenericReturnValue | ||
179 | GNUNET_IDENTITY_key_get_public (const struct | ||
180 | GNUNET_IDENTITY_PrivateKey *privkey, | ||
181 | struct GNUNET_IDENTITY_PublicKey *key) | ||
182 | { | ||
183 | key->type = privkey->type; | ||
184 | switch (ntohl (privkey->type)) | ||
185 | { | ||
186 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
187 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey->ecdsa_key, | ||
188 | &key->ecdsa_key); | ||
189 | break; | ||
190 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
191 | GNUNET_CRYPTO_eddsa_key_get_public (&privkey->eddsa_key, | ||
192 | &key->eddsa_key); | ||
193 | break; | ||
194 | default: | ||
195 | GNUNET_break (0); | ||
196 | return GNUNET_SYSERR; | ||
197 | } | ||
198 | return GNUNET_OK; | ||
199 | } | ||
200 | |||
201 | |||
202 | static enum GNUNET_GenericReturnValue | ||
203 | private_key_create (enum GNUNET_IDENTITY_KeyType ktype, | ||
204 | struct GNUNET_IDENTITY_PrivateKey *key) | ||
205 | { | ||
206 | key->type = htonl (ktype); | ||
207 | switch (ktype) | ||
208 | { | ||
209 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
210 | GNUNET_CRYPTO_ecdsa_key_create (&key->ecdsa_key); | ||
211 | break; | ||
212 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
213 | GNUNET_CRYPTO_eddsa_key_create (&key->eddsa_key); | ||
214 | break; | ||
215 | default: | ||
216 | GNUNET_break (0); | ||
217 | return GNUNET_SYSERR; | ||
218 | } | ||
219 | return GNUNET_OK; | ||
220 | } | ||
221 | |||
222 | 178 | ||
223 | /** | 179 | /** |
224 | * Try again to connect to the identity service. | 180 | * Try again to connect to the identity service. |
@@ -399,7 +355,7 @@ handle_identity_update (void *cls, | |||
399 | size_t kb_read; | 355 | size_t kb_read; |
400 | struct GNUNET_HashCode id; | 356 | struct GNUNET_HashCode id; |
401 | struct GNUNET_IDENTITY_Ego *ego; | 357 | struct GNUNET_IDENTITY_Ego *ego; |
402 | struct GNUNET_IDENTITY_PrivateKey private_key; | 358 | struct GNUNET_CRYPTO_PrivateKey private_key; |
403 | const char *tmp; | 359 | const char *tmp; |
404 | 360 | ||
405 | if (GNUNET_YES == ntohs (um->end_of_list)) | 361 | if (GNUNET_YES == ntohs (um->end_of_list)) |
@@ -414,13 +370,13 @@ handle_identity_update (void *cls, | |||
414 | memset (&private_key, 0, sizeof (private_key)); | 370 | memset (&private_key, 0, sizeof (private_key)); |
415 | key_len = ntohs (um->key_len); | 371 | key_len = ntohs (um->key_len); |
416 | GNUNET_assert (GNUNET_SYSERR != | 372 | GNUNET_assert (GNUNET_SYSERR != |
417 | GNUNET_IDENTITY_read_private_key_from_buffer (tmp + name_len, | 373 | GNUNET_CRYPTO_read_private_key_from_buffer (tmp + name_len, |
418 | key_len, | 374 | key_len, |
419 | &private_key, | 375 | &private_key, |
420 | &kb_read)); | 376 | &kb_read)); |
421 | GNUNET_assert (0 <= GNUNET_IDENTITY_private_key_get_length (&private_key)); | 377 | GNUNET_assert (0 <= GNUNET_CRYPTO_private_key_get_length (&private_key)); |
422 | GNUNET_CRYPTO_hash (&private_key, | 378 | GNUNET_CRYPTO_hash (&private_key, |
423 | GNUNET_IDENTITY_private_key_get_length (&private_key), | 379 | GNUNET_CRYPTO_private_key_get_length (&private_key), |
424 | &id); | 380 | &id); |
425 | ego = GNUNET_CONTAINER_multihashmap_get (h->egos, | 381 | ego = GNUNET_CONTAINER_multihashmap_get (h->egos, |
426 | &id); | 382 | &id); |
@@ -550,19 +506,19 @@ GNUNET_IDENTITY_connect (const struct GNUNET_CONFIGURATION_Handle *cfg, | |||
550 | } | 506 | } |
551 | 507 | ||
552 | 508 | ||
509 | |||
553 | /** | 510 | /** |
554 | * Obtain the ECC key associated with a ego. | 511 | * Obtain the ECC key associated with a ego. |
555 | * | 512 | * |
556 | * @param ego the ego | 513 | * @param ego the ego |
557 | * @return associated ECC key, valid as long as the ego is valid | 514 | * @return associated ECC key, valid as long as the ego is valid |
558 | */ | 515 | */ |
559 | const struct GNUNET_IDENTITY_PrivateKey * | 516 | const struct GNUNET_CRYPTO_PrivateKey * |
560 | GNUNET_IDENTITY_ego_get_private_key (const struct GNUNET_IDENTITY_Ego *ego) | 517 | GNUNET_IDENTITY_ego_get_private_key (const struct GNUNET_IDENTITY_Ego *ego) |
561 | { | 518 | { |
562 | return &ego->pk; | 519 | return &ego->pk; |
563 | } | 520 | } |
564 | 521 | ||
565 | |||
566 | /** | 522 | /** |
567 | * Get the identifier (public key) of an ego. | 523 | * Get the identifier (public key) of an ego. |
568 | * | 524 | * |
@@ -571,26 +527,45 @@ GNUNET_IDENTITY_ego_get_private_key (const struct GNUNET_IDENTITY_Ego *ego) | |||
571 | */ | 527 | */ |
572 | void | 528 | void |
573 | GNUNET_IDENTITY_ego_get_public_key (struct GNUNET_IDENTITY_Ego *ego, | 529 | GNUNET_IDENTITY_ego_get_public_key (struct GNUNET_IDENTITY_Ego *ego, |
574 | struct GNUNET_IDENTITY_PublicKey *pk) | 530 | struct GNUNET_CRYPTO_PublicKey *pk) |
575 | { | 531 | { |
576 | if (GNUNET_NO == ego->pub_initialized) | 532 | if (GNUNET_NO == ego->pub_initialized) |
577 | { | 533 | { |
578 | GNUNET_IDENTITY_key_get_public (&ego->pk, &ego->pub); | 534 | GNUNET_CRYPTO_key_get_public (&ego->pk, &ego->pub); |
579 | ego->pub_initialized = GNUNET_YES; | 535 | ego->pub_initialized = GNUNET_YES; |
580 | } | 536 | } |
581 | *pk = ego->pub; | 537 | *pk = ego->pub; |
582 | } | 538 | } |
583 | 539 | ||
540 | static enum GNUNET_GenericReturnValue | ||
541 | private_key_create (enum GNUNET_CRYPTO_KeyType ktype, | ||
542 | struct GNUNET_CRYPTO_PrivateKey *key) | ||
543 | { | ||
544 | key->type = htonl (ktype); | ||
545 | switch (ktype) | ||
546 | { | ||
547 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: | ||
548 | GNUNET_CRYPTO_ecdsa_key_create (&key->ecdsa_key); | ||
549 | break; | ||
550 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: | ||
551 | GNUNET_CRYPTO_eddsa_key_create (&key->eddsa_key); | ||
552 | break; | ||
553 | default: | ||
554 | GNUNET_break (0); | ||
555 | return GNUNET_SYSERR; | ||
556 | } | ||
557 | return GNUNET_OK; | ||
558 | } | ||
584 | 559 | ||
585 | struct GNUNET_IDENTITY_Operation * | 560 | struct GNUNET_IDENTITY_Operation * |
586 | GNUNET_IDENTITY_create (struct GNUNET_IDENTITY_Handle *h, | 561 | GNUNET_IDENTITY_create (struct GNUNET_IDENTITY_Handle *h, |
587 | const char *name, | 562 | const char *name, |
588 | const struct GNUNET_IDENTITY_PrivateKey *privkey, | 563 | const struct GNUNET_CRYPTO_PrivateKey *privkey, |
589 | enum GNUNET_IDENTITY_KeyType ktype, | 564 | enum GNUNET_CRYPTO_KeyType ktype, |
590 | GNUNET_IDENTITY_CreateContinuation cont, | 565 | GNUNET_IDENTITY_CreateContinuation cont, |
591 | void *cont_cls) | 566 | void *cont_cls) |
592 | { | 567 | { |
593 | struct GNUNET_IDENTITY_PrivateKey private_key; | 568 | struct GNUNET_CRYPTO_PrivateKey private_key; |
594 | struct GNUNET_IDENTITY_Operation *op; | 569 | struct GNUNET_IDENTITY_Operation *op; |
595 | struct GNUNET_MQ_Envelope *env; | 570 | struct GNUNET_MQ_Envelope *env; |
596 | struct CreateRequestMessage *crm; | 571 | struct CreateRequestMessage *crm; |
@@ -617,11 +592,11 @@ GNUNET_IDENTITY_create (struct GNUNET_IDENTITY_Handle *h, | |||
617 | } | 592 | } |
618 | else | 593 | else |
619 | private_key = *privkey; | 594 | private_key = *privkey; |
620 | key_len = GNUNET_IDENTITY_private_key_get_length (&private_key); | 595 | key_len = GNUNET_CRYPTO_private_key_get_length (&private_key); |
621 | env = GNUNET_MQ_msg_extra (crm, slen + key_len, | 596 | env = GNUNET_MQ_msg_extra (crm, slen + key_len, |
622 | GNUNET_MESSAGE_TYPE_IDENTITY_CREATE); | 597 | GNUNET_MESSAGE_TYPE_IDENTITY_CREATE); |
623 | crm->name_len = htons (slen); | 598 | crm->name_len = htons (slen); |
624 | GNUNET_IDENTITY_write_private_key_to_buffer (&private_key, | 599 | GNUNET_CRYPTO_write_private_key_to_buffer (&private_key, |
625 | &crm[1], | 600 | &crm[1], |
626 | key_len); | 601 | key_len); |
627 | crm->key_len = htons (key_len); | 602 | crm->key_len = htons (key_len); |
@@ -790,571 +765,4 @@ GNUNET_IDENTITY_disconnect (struct GNUNET_IDENTITY_Handle *h) | |||
790 | } | 765 | } |
791 | 766 | ||
792 | 767 | ||
793 | static enum GNUNET_GenericReturnValue | ||
794 | check_key_type (uint32_t type) | ||
795 | { | ||
796 | switch (type) | ||
797 | { | ||
798 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
799 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
800 | return GNUNET_OK; | ||
801 | default: | ||
802 | return GNUNET_SYSERR; | ||
803 | } | ||
804 | return GNUNET_SYSERR; | ||
805 | } | ||
806 | |||
807 | |||
808 | ssize_t | ||
809 | GNUNET_IDENTITY_private_key_get_length (const struct | ||
810 | GNUNET_IDENTITY_PrivateKey *key) | ||
811 | { | ||
812 | switch (ntohl (key->type)) | ||
813 | { | ||
814 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
815 | return sizeof (key->type) + sizeof (key->ecdsa_key); | ||
816 | break; | ||
817 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
818 | return sizeof (key->type) + sizeof (key->eddsa_key); | ||
819 | break; | ||
820 | default: | ||
821 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | ||
822 | "Got key type %u\n", ntohl (key->type)); | ||
823 | GNUNET_break (0); | ||
824 | } | ||
825 | return -1; | ||
826 | } | ||
827 | |||
828 | |||
829 | ssize_t | ||
830 | GNUNET_IDENTITY_public_key_get_length (const struct | ||
831 | GNUNET_IDENTITY_PublicKey *key) | ||
832 | { | ||
833 | switch (ntohl (key->type)) | ||
834 | { | ||
835 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
836 | return sizeof (key->type) + sizeof (key->ecdsa_key); | ||
837 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
838 | return sizeof (key->type) + sizeof (key->eddsa_key); | ||
839 | default: | ||
840 | GNUNET_break (0); | ||
841 | } | ||
842 | return -1; | ||
843 | } | ||
844 | |||
845 | |||
846 | ssize_t | ||
847 | GNUNET_IDENTITY_private_key_length_by_type (enum GNUNET_IDENTITY_KeyType kt) | ||
848 | { | ||
849 | switch (kt) | ||
850 | { | ||
851 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
852 | return sizeof (struct GNUNET_CRYPTO_EcdsaPrivateKey); | ||
853 | break; | ||
854 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
855 | return sizeof (struct GNUNET_CRYPTO_EcdsaPrivateKey); | ||
856 | break; | ||
857 | default: | ||
858 | GNUNET_break (0); | ||
859 | } | ||
860 | return -1; | ||
861 | } | ||
862 | |||
863 | |||
864 | enum GNUNET_GenericReturnValue | ||
865 | GNUNET_IDENTITY_read_public_key_from_buffer (const void *buffer, | ||
866 | size_t len, | ||
867 | struct GNUNET_IDENTITY_PublicKey * | ||
868 | key, | ||
869 | size_t *kb_read) | ||
870 | { | ||
871 | if (len < sizeof (key->type)) | ||
872 | return GNUNET_SYSERR; | ||
873 | GNUNET_memcpy (&key->type, | ||
874 | buffer, | ||
875 | sizeof (key->type)); | ||
876 | ssize_t length = GNUNET_IDENTITY_public_key_get_length (key); | ||
877 | if (len < length) | ||
878 | return GNUNET_SYSERR; | ||
879 | if (length < 0) | ||
880 | return GNUNET_SYSERR; | ||
881 | GNUNET_memcpy (&key->ecdsa_key, | ||
882 | buffer + sizeof (key->type), | ||
883 | length - sizeof (key->type)); | ||
884 | *kb_read = length; | ||
885 | return GNUNET_OK; | ||
886 | } | ||
887 | |||
888 | |||
889 | ssize_t | ||
890 | GNUNET_IDENTITY_write_public_key_to_buffer (const struct | ||
891 | GNUNET_IDENTITY_PublicKey *key, | ||
892 | void*buffer, | ||
893 | size_t len) | ||
894 | { | ||
895 | const ssize_t length = GNUNET_IDENTITY_public_key_get_length (key); | ||
896 | if (len < length) | ||
897 | return -1; | ||
898 | if (length < 0) | ||
899 | return -2; | ||
900 | GNUNET_memcpy (buffer, &(key->type), sizeof (key->type)); | ||
901 | GNUNET_memcpy (buffer + sizeof (key->type), &(key->ecdsa_key), length | ||
902 | - sizeof (key->type)); | ||
903 | return length; | ||
904 | } | ||
905 | |||
906 | |||
907 | enum GNUNET_GenericReturnValue | ||
908 | GNUNET_IDENTITY_read_private_key_from_buffer (const void *buffer, | ||
909 | size_t len, | ||
910 | struct | ||
911 | GNUNET_IDENTITY_PrivateKey *key, | ||
912 | size_t *kb_read) | ||
913 | { | ||
914 | if (len < sizeof (key->type)) | ||
915 | return GNUNET_SYSERR; | ||
916 | GNUNET_memcpy (&key->type, | ||
917 | buffer, | ||
918 | sizeof (key->type)); | ||
919 | ssize_t length = GNUNET_IDENTITY_private_key_get_length (key); | ||
920 | if (len < length) | ||
921 | return GNUNET_SYSERR; | ||
922 | if (length < 0) | ||
923 | return GNUNET_SYSERR; | ||
924 | GNUNET_memcpy (&key->ecdsa_key, | ||
925 | buffer + sizeof (key->type), | ||
926 | length - sizeof (key->type)); | ||
927 | *kb_read = length; | ||
928 | return GNUNET_OK; | ||
929 | } | ||
930 | |||
931 | |||
932 | ssize_t | ||
933 | GNUNET_IDENTITY_write_private_key_to_buffer (const struct | ||
934 | GNUNET_IDENTITY_PrivateKey *key, | ||
935 | void *buffer, | ||
936 | size_t len) | ||
937 | { | ||
938 | const ssize_t length = GNUNET_IDENTITY_private_key_get_length (key); | ||
939 | if (len < length) | ||
940 | return -1; | ||
941 | if (length < 0) | ||
942 | return -2; | ||
943 | GNUNET_memcpy (buffer, &(key->type), sizeof (key->type)); | ||
944 | GNUNET_memcpy (buffer + sizeof (key->type), &(key->ecdsa_key), length | ||
945 | - sizeof (key->type)); | ||
946 | return length; | ||
947 | } | ||
948 | |||
949 | |||
950 | ssize_t | ||
951 | GNUNET_IDENTITY_signature_get_length (const struct | ||
952 | GNUNET_IDENTITY_Signature *sig) | ||
953 | { | ||
954 | switch (ntohl (sig->type)) | ||
955 | { | ||
956 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
957 | return sizeof (sig->type) + sizeof (sig->ecdsa_signature); | ||
958 | break; | ||
959 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
960 | return sizeof (sig->type) + sizeof (sig->eddsa_signature); | ||
961 | break; | ||
962 | default: | ||
963 | GNUNET_break (0); | ||
964 | } | ||
965 | return -1; | ||
966 | } | ||
967 | |||
968 | |||
969 | ssize_t | ||
970 | GNUNET_IDENTITY_signature_get_raw_length_by_type (uint32_t type) | ||
971 | { | ||
972 | switch (ntohl (type)) | ||
973 | { | ||
974 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
975 | return sizeof (struct GNUNET_CRYPTO_EcdsaSignature); | ||
976 | break; | ||
977 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
978 | return sizeof (struct GNUNET_CRYPTO_EddsaSignature); | ||
979 | break; | ||
980 | default: | ||
981 | GNUNET_break (0); | ||
982 | } | ||
983 | return -1; | ||
984 | } | ||
985 | |||
986 | |||
987 | ssize_t | ||
988 | GNUNET_IDENTITY_read_signature_from_buffer (struct | ||
989 | GNUNET_IDENTITY_Signature *sig, | ||
990 | const void*buffer, | ||
991 | size_t len) | ||
992 | { | ||
993 | if (len < sizeof (sig->type)) | ||
994 | return -1; | ||
995 | GNUNET_memcpy (&(sig->type), buffer, sizeof (sig->type)); | ||
996 | const ssize_t length = GNUNET_IDENTITY_signature_get_length (sig); | ||
997 | if (len < length) | ||
998 | return -1; | ||
999 | if (length < 0) | ||
1000 | return -2; | ||
1001 | GNUNET_memcpy (&(sig->ecdsa_signature), buffer + sizeof (sig->type), length | ||
1002 | - sizeof (sig->type)); | ||
1003 | return length; | ||
1004 | } | ||
1005 | |||
1006 | |||
1007 | ssize_t | ||
1008 | GNUNET_IDENTITY_write_signature_to_buffer (const struct | ||
1009 | GNUNET_IDENTITY_Signature *sig, | ||
1010 | void*buffer, | ||
1011 | size_t len) | ||
1012 | { | ||
1013 | const ssize_t length = GNUNET_IDENTITY_signature_get_length (sig); | ||
1014 | if (len < length) | ||
1015 | return -1; | ||
1016 | if (length < 0) | ||
1017 | return -2; | ||
1018 | GNUNET_memcpy (buffer, &(sig->type), sizeof (sig->type)); | ||
1019 | GNUNET_memcpy (buffer + sizeof (sig->type), &(sig->ecdsa_signature), length | ||
1020 | - sizeof (sig->type)); | ||
1021 | return length; | ||
1022 | } | ||
1023 | |||
1024 | |||
1025 | enum GNUNET_GenericReturnValue | ||
1026 | GNUNET_IDENTITY_sign_raw_ (const struct | ||
1027 | GNUNET_IDENTITY_PrivateKey *priv, | ||
1028 | const struct | ||
1029 | GNUNET_CRYPTO_EccSignaturePurpose *purpose, | ||
1030 | unsigned char *sig) | ||
1031 | { | ||
1032 | switch (ntohl (priv->type)) | ||
1033 | { | ||
1034 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
1035 | return GNUNET_CRYPTO_ecdsa_sign_ (&(priv->ecdsa_key), purpose, | ||
1036 | (struct | ||
1037 | GNUNET_CRYPTO_EcdsaSignature*) sig); | ||
1038 | break; | ||
1039 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
1040 | return GNUNET_CRYPTO_eddsa_sign_ (&(priv->eddsa_key), purpose, | ||
1041 | (struct | ||
1042 | GNUNET_CRYPTO_EddsaSignature*) sig); | ||
1043 | break; | ||
1044 | default: | ||
1045 | GNUNET_break (0); | ||
1046 | } | ||
1047 | |||
1048 | return GNUNET_SYSERR; | ||
1049 | } | ||
1050 | |||
1051 | |||
1052 | enum GNUNET_GenericReturnValue | ||
1053 | GNUNET_IDENTITY_sign_ (const struct | ||
1054 | GNUNET_IDENTITY_PrivateKey *priv, | ||
1055 | const struct | ||
1056 | GNUNET_CRYPTO_EccSignaturePurpose *purpose, | ||
1057 | struct GNUNET_IDENTITY_Signature *sig) | ||
1058 | { | ||
1059 | sig->type = priv->type; | ||
1060 | switch (ntohl (priv->type)) | ||
1061 | { | ||
1062 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
1063 | return GNUNET_CRYPTO_ecdsa_sign_ (&(priv->ecdsa_key), purpose, | ||
1064 | &(sig->ecdsa_signature)); | ||
1065 | break; | ||
1066 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
1067 | return GNUNET_CRYPTO_eddsa_sign_ (&(priv->eddsa_key), purpose, | ||
1068 | &(sig->eddsa_signature)); | ||
1069 | break; | ||
1070 | default: | ||
1071 | GNUNET_break (0); | ||
1072 | } | ||
1073 | |||
1074 | return GNUNET_SYSERR; | ||
1075 | } | ||
1076 | |||
1077 | |||
1078 | enum GNUNET_GenericReturnValue | ||
1079 | GNUNET_IDENTITY_signature_verify_ (uint32_t purpose, | ||
1080 | const struct | ||
1081 | GNUNET_CRYPTO_EccSignaturePurpose *validate, | ||
1082 | const struct GNUNET_IDENTITY_Signature *sig, | ||
1083 | const struct GNUNET_IDENTITY_PublicKey *pub) | ||
1084 | { | ||
1085 | /* check type matching of 'sig' and 'pub' */ | ||
1086 | GNUNET_assert (ntohl (pub->type) == ntohl (sig->type)); | ||
1087 | switch (ntohl (pub->type)) | ||
1088 | { | ||
1089 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
1090 | return GNUNET_CRYPTO_ecdsa_verify_ (purpose, validate, | ||
1091 | &(sig->ecdsa_signature), | ||
1092 | &(pub->ecdsa_key)); | ||
1093 | break; | ||
1094 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
1095 | return GNUNET_CRYPTO_eddsa_verify_ (purpose, validate, | ||
1096 | &(sig->eddsa_signature), | ||
1097 | &(pub->eddsa_key)); | ||
1098 | break; | ||
1099 | default: | ||
1100 | GNUNET_break (0); | ||
1101 | } | ||
1102 | |||
1103 | return GNUNET_SYSERR; | ||
1104 | } | ||
1105 | |||
1106 | |||
1107 | enum GNUNET_GenericReturnValue | ||
1108 | GNUNET_IDENTITY_signature_verify_raw_ (uint32_t purpose, | ||
1109 | const struct | ||
1110 | GNUNET_CRYPTO_EccSignaturePurpose * | ||
1111 | validate, | ||
1112 | const unsigned char *sig, | ||
1113 | const struct | ||
1114 | GNUNET_IDENTITY_PublicKey *pub) | ||
1115 | { | ||
1116 | switch (ntohl (pub->type)) | ||
1117 | { | ||
1118 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
1119 | return GNUNET_CRYPTO_ecdsa_verify_ (purpose, validate, | ||
1120 | (struct | ||
1121 | GNUNET_CRYPTO_EcdsaSignature*) sig, | ||
1122 | &(pub->ecdsa_key)); | ||
1123 | break; | ||
1124 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
1125 | return GNUNET_CRYPTO_eddsa_verify_ (purpose, validate, | ||
1126 | (struct | ||
1127 | GNUNET_CRYPTO_EddsaSignature*) sig, | ||
1128 | &(pub->eddsa_key)); | ||
1129 | break; | ||
1130 | default: | ||
1131 | GNUNET_break (0); | ||
1132 | } | ||
1133 | |||
1134 | return GNUNET_SYSERR; | ||
1135 | } | ||
1136 | |||
1137 | |||
1138 | ssize_t | ||
1139 | GNUNET_IDENTITY_encrypt_old (const void *block, | ||
1140 | size_t size, | ||
1141 | const struct GNUNET_IDENTITY_PublicKey *pub, | ||
1142 | struct GNUNET_CRYPTO_EcdhePublicKey *ecc, | ||
1143 | void *result) | ||
1144 | { | ||
1145 | struct GNUNET_CRYPTO_EcdhePrivateKey pk; | ||
1146 | GNUNET_CRYPTO_ecdhe_key_create (&pk); | ||
1147 | struct GNUNET_HashCode hash; | ||
1148 | switch (ntohl (pub->type)) | ||
1149 | { | ||
1150 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
1151 | if (GNUNET_SYSERR == GNUNET_CRYPTO_ecdh_ecdsa (&pk, &(pub->ecdsa_key), | ||
1152 | &hash)) | ||
1153 | return -1; | ||
1154 | break; | ||
1155 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
1156 | if (GNUNET_SYSERR == GNUNET_CRYPTO_ecdh_eddsa (&pk, &(pub->eddsa_key), | ||
1157 | &hash)) | ||
1158 | return -1; | ||
1159 | break; | ||
1160 | default: | ||
1161 | return -1; | ||
1162 | } | ||
1163 | GNUNET_CRYPTO_ecdhe_key_get_public (&pk, ecc); | ||
1164 | GNUNET_CRYPTO_ecdhe_key_clear (&pk); | ||
1165 | struct GNUNET_CRYPTO_SymmetricSessionKey key; | ||
1166 | struct GNUNET_CRYPTO_SymmetricInitializationVector iv; | ||
1167 | GNUNET_CRYPTO_hash_to_aes_key (&hash, &key, &iv); | ||
1168 | GNUNET_CRYPTO_zero_keys (&hash, sizeof(hash)); | ||
1169 | const ssize_t encrypted = GNUNET_CRYPTO_symmetric_encrypt (block, size, &key, | ||
1170 | &iv, result); | ||
1171 | GNUNET_CRYPTO_zero_keys (&key, sizeof(key)); | ||
1172 | GNUNET_CRYPTO_zero_keys (&iv, sizeof(iv)); | ||
1173 | return encrypted; | ||
1174 | } | ||
1175 | |||
1176 | |||
1177 | enum GNUNET_GenericReturnValue | ||
1178 | GNUNET_IDENTITY_encrypt (const void *pt, | ||
1179 | size_t pt_size, | ||
1180 | const struct GNUNET_IDENTITY_PublicKey *pub, | ||
1181 | void *ct_buf, | ||
1182 | size_t ct_size) | ||
1183 | { | ||
1184 | struct GNUNET_HashCode k; | ||
1185 | struct GNUNET_CRYPTO_FoKemC kemc; | ||
1186 | struct GNUNET_CRYPTO_FoKemC *kemc_buf = (struct GNUNET_CRYPTO_FoKemC*) ct_buf; | ||
1187 | unsigned char *encrypted_data = (unsigned char*) &kemc_buf[1]; | ||
1188 | unsigned char nonce[crypto_secretbox_NONCEBYTES]; | ||
1189 | unsigned char key[crypto_secretbox_KEYBYTES]; | ||
1190 | |||
1191 | if (ct_size < pt_size + GNUNET_IDENTITY_ENCRYPT_OVERHEAD_BYTES) | ||
1192 | { | ||
1193 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | ||
1194 | "Output buffer size for ciphertext too small: Got %lu, want >=%lu\n", | ||
1195 | ct_size, pt_size + GNUNET_IDENTITY_ENCRYPT_OVERHEAD_BYTES); | ||
1196 | return GNUNET_SYSERR; | ||
1197 | } | ||
1198 | switch (ntohl (pub->type)) | ||
1199 | { | ||
1200 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
1201 | if (GNUNET_SYSERR == GNUNET_CRYPTO_ecdsa_fo_kem_encaps (&(pub->ecdsa_key), | ||
1202 | &kemc, | ||
1203 | &k)) | ||
1204 | return GNUNET_SYSERR; | ||
1205 | break; | ||
1206 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
1207 | if (GNUNET_SYSERR == GNUNET_CRYPTO_eddsa_fo_kem_encaps (&pub->eddsa_key, | ||
1208 | &kemc, | ||
1209 | &k)) | ||
1210 | return GNUNET_SYSERR; | ||
1211 | break; | ||
1212 | default: | ||
1213 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Unsupported key type\n"); | ||
1214 | return GNUNET_SYSERR; | ||
1215 | } | ||
1216 | memcpy (key, &k, crypto_secretbox_KEYBYTES); | ||
1217 | memcpy (nonce, ((char* ) &k) + crypto_secretbox_KEYBYTES, | ||
1218 | crypto_secretbox_NONCEBYTES); | ||
1219 | if (crypto_secretbox_easy (encrypted_data, pt, pt_size, nonce, key)) | ||
1220 | return GNUNET_SYSERR; | ||
1221 | memcpy (kemc_buf, &kemc, sizeof (kemc)); | ||
1222 | return GNUNET_OK; | ||
1223 | } | ||
1224 | |||
1225 | |||
1226 | enum GNUNET_GenericReturnValue | ||
1227 | GNUNET_IDENTITY_decrypt (const void *ct_buf, | ||
1228 | size_t ct_size, | ||
1229 | const struct GNUNET_IDENTITY_PrivateKey *priv, | ||
1230 | void *pt, | ||
1231 | size_t pt_size) | ||
1232 | { | ||
1233 | struct GNUNET_HashCode k; | ||
1234 | struct GNUNET_CRYPTO_FoKemC *kemc = (struct GNUNET_CRYPTO_FoKemC*) ct_buf; | ||
1235 | unsigned char *encrypted_data = (unsigned char*) &kemc[1]; | ||
1236 | unsigned char nonce[crypto_secretbox_NONCEBYTES]; | ||
1237 | unsigned char key[crypto_secretbox_KEYBYTES]; | ||
1238 | size_t expected_pt_len = ct_size - GNUNET_IDENTITY_ENCRYPT_OVERHEAD_BYTES; | ||
1239 | |||
1240 | if (pt_size < expected_pt_len) | ||
1241 | { | ||
1242 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | ||
1243 | "Output buffer size for plaintext too small: Got %lu, want >=%lu\n", | ||
1244 | pt_size, expected_pt_len); | ||
1245 | return GNUNET_SYSERR; | ||
1246 | } | ||
1247 | switch (ntohl (priv->type)) | ||
1248 | { | ||
1249 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
1250 | if (GNUNET_SYSERR == GNUNET_CRYPTO_ecdsa_fo_kem_decaps (&(priv->ecdsa_key), | ||
1251 | kemc, | ||
1252 | &k)) | ||
1253 | return GNUNET_SYSERR; | ||
1254 | break; | ||
1255 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
1256 | if (GNUNET_SYSERR == GNUNET_CRYPTO_eddsa_fo_kem_decaps (&(priv->eddsa_key), | ||
1257 | kemc, | ||
1258 | &k)) | ||
1259 | return GNUNET_SYSERR; | ||
1260 | break; | ||
1261 | default: | ||
1262 | return GNUNET_SYSERR; | ||
1263 | } | ||
1264 | memcpy (key, &k, crypto_secretbox_KEYBYTES); | ||
1265 | memcpy (nonce, ((char* ) &k) + crypto_secretbox_KEYBYTES, | ||
1266 | crypto_secretbox_NONCEBYTES); | ||
1267 | if (crypto_secretbox_open_easy (pt, encrypted_data, ct_size - sizeof (*kemc), | ||
1268 | nonce, key)) | ||
1269 | return GNUNET_SYSERR; | ||
1270 | return GNUNET_OK; | ||
1271 | } | ||
1272 | |||
1273 | |||
1274 | ssize_t | ||
1275 | GNUNET_IDENTITY_decrypt_old (const void *block, | ||
1276 | size_t size, | ||
1277 | const struct GNUNET_IDENTITY_PrivateKey *priv, | ||
1278 | const struct GNUNET_CRYPTO_EcdhePublicKey *ecc, | ||
1279 | void *result) | ||
1280 | { | ||
1281 | struct GNUNET_HashCode hash; | ||
1282 | switch (ntohl (priv->type)) | ||
1283 | { | ||
1284 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
1285 | if (GNUNET_SYSERR == GNUNET_CRYPTO_ecdsa_ecdh (&(priv->ecdsa_key), ecc, | ||
1286 | &hash)) | ||
1287 | return -1; | ||
1288 | break; | ||
1289 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
1290 | if (GNUNET_SYSERR == GNUNET_CRYPTO_eddsa_ecdh (&(priv->eddsa_key), ecc, | ||
1291 | &hash)) | ||
1292 | return -1; | ||
1293 | break; | ||
1294 | default: | ||
1295 | return -1; | ||
1296 | } | ||
1297 | struct GNUNET_CRYPTO_SymmetricSessionKey key; | ||
1298 | struct GNUNET_CRYPTO_SymmetricInitializationVector iv; | ||
1299 | GNUNET_CRYPTO_hash_to_aes_key (&hash, &key, &iv); | ||
1300 | GNUNET_CRYPTO_zero_keys (&hash, sizeof(hash)); | ||
1301 | const ssize_t decrypted = GNUNET_CRYPTO_symmetric_decrypt (block, size, &key, | ||
1302 | &iv, result); | ||
1303 | GNUNET_CRYPTO_zero_keys (&key, sizeof(key)); | ||
1304 | GNUNET_CRYPTO_zero_keys (&iv, sizeof(iv)); | ||
1305 | return decrypted; | ||
1306 | } | ||
1307 | |||
1308 | |||
1309 | char * | ||
1310 | GNUNET_IDENTITY_public_key_to_string (const struct | ||
1311 | GNUNET_IDENTITY_PublicKey *key) | ||
1312 | { | ||
1313 | size_t size = GNUNET_IDENTITY_public_key_get_length (key); | ||
1314 | return GNUNET_STRINGS_data_to_string_alloc (key, | ||
1315 | size); | ||
1316 | } | ||
1317 | |||
1318 | |||
1319 | char * | ||
1320 | GNUNET_IDENTITY_private_key_to_string (const struct | ||
1321 | GNUNET_IDENTITY_PrivateKey *key) | ||
1322 | { | ||
1323 | size_t size = GNUNET_IDENTITY_private_key_get_length (key); | ||
1324 | return GNUNET_STRINGS_data_to_string_alloc (key, | ||
1325 | size); | ||
1326 | } | ||
1327 | |||
1328 | |||
1329 | enum GNUNET_GenericReturnValue | ||
1330 | GNUNET_IDENTITY_public_key_from_string (const char *str, | ||
1331 | struct GNUNET_IDENTITY_PublicKey *key) | ||
1332 | { | ||
1333 | enum GNUNET_GenericReturnValue ret; | ||
1334 | ret = GNUNET_STRINGS_string_to_data (str, | ||
1335 | strlen (str), | ||
1336 | key, | ||
1337 | sizeof (*key)); | ||
1338 | if (GNUNET_OK != ret) | ||
1339 | return GNUNET_SYSERR; | ||
1340 | return check_key_type (ntohl (key->type)); | ||
1341 | |||
1342 | } | ||
1343 | |||
1344 | |||
1345 | enum GNUNET_GenericReturnValue | ||
1346 | GNUNET_IDENTITY_private_key_from_string (const char *str, | ||
1347 | struct GNUNET_IDENTITY_PrivateKey *key) | ||
1348 | { | ||
1349 | enum GNUNET_GenericReturnValue ret; | ||
1350 | ret = GNUNET_STRINGS_string_to_data (str, | ||
1351 | strlen (str), | ||
1352 | key, | ||
1353 | sizeof (*key)); | ||
1354 | if (GNUNET_OK != ret) | ||
1355 | return GNUNET_SYSERR; | ||
1356 | return check_key_type (ntohl (key->type)); | ||
1357 | } | ||
1358 | |||
1359 | |||
1360 | /* end of identity_api.c */ | 768 | /* end of identity_api.c */ |
diff --git a/src/identity/identity_api_lookup.c b/src/identity/identity_api_lookup.c index 4cc0b6334..03b229e08 100644 --- a/src/identity/identity_api_lookup.c +++ b/src/identity/identity_api_lookup.c | |||
@@ -131,7 +131,7 @@ handle_identity_update (void *cls, const struct UpdateMessage *um) | |||
131 | size_t kb_read; | 131 | size_t kb_read; |
132 | struct GNUNET_HashCode id; | 132 | struct GNUNET_HashCode id; |
133 | struct GNUNET_IDENTITY_Ego ego; | 133 | struct GNUNET_IDENTITY_Ego ego; |
134 | struct GNUNET_IDENTITY_PrivateKey private_key; | 134 | struct GNUNET_CRYPTO_PrivateKey private_key; |
135 | const char *tmp; | 135 | const char *tmp; |
136 | 136 | ||
137 | memset (&ego, 0, sizeof (ego)); | 137 | memset (&ego, 0, sizeof (ego)); |
@@ -142,7 +142,7 @@ handle_identity_update (void *cls, const struct UpdateMessage *um) | |||
142 | memset (&private_key, 0, sizeof (private_key)); | 142 | memset (&private_key, 0, sizeof (private_key)); |
143 | key_len = ntohs (um->header.size) - sizeof (*um) - name_len; | 143 | key_len = ntohs (um->header.size) - sizeof (*um) - name_len; |
144 | GNUNET_assert (GNUNET_SYSERR != | 144 | GNUNET_assert (GNUNET_SYSERR != |
145 | GNUNET_IDENTITY_read_private_key_from_buffer (tmp + name_len, | 145 | GNUNET_CRYPTO_read_private_key_from_buffer (tmp + name_len, |
146 | key_len, | 146 | key_len, |
147 | &private_key, | 147 | &private_key, |
148 | &kb_read)); | 148 | &kb_read)); |
diff --git a/src/identity/identity_api_suffix_lookup.c b/src/identity/identity_api_suffix_lookup.c index 4b459345d..7bc0d18f3 100644 --- a/src/identity/identity_api_suffix_lookup.c +++ b/src/identity/identity_api_suffix_lookup.c | |||
@@ -132,7 +132,7 @@ handle_identity_update (void *cls, const struct UpdateMessage *um) | |||
132 | const char *str; | 132 | const char *str; |
133 | size_t key_len; | 133 | size_t key_len; |
134 | size_t kb_read; | 134 | size_t kb_read; |
135 | struct GNUNET_IDENTITY_PrivateKey private_key; | 135 | struct GNUNET_CRYPTO_PrivateKey private_key; |
136 | const char *tmp; | 136 | const char *tmp; |
137 | 137 | ||
138 | tmp = (const char*) &um[1]; | 138 | tmp = (const char*) &um[1]; |
@@ -142,7 +142,7 @@ handle_identity_update (void *cls, const struct UpdateMessage *um) | |||
142 | if (0 < key_len) | 142 | if (0 < key_len) |
143 | { | 143 | { |
144 | GNUNET_assert (GNUNET_SYSERR != | 144 | GNUNET_assert (GNUNET_SYSERR != |
145 | GNUNET_IDENTITY_read_private_key_from_buffer (tmp + name_len, | 145 | GNUNET_CRYPTO_read_private_key_from_buffer (tmp + name_len, |
146 | key_len, | 146 | key_len, |
147 | &private_key, | 147 | &private_key, |
148 | &kb_read)); | 148 | &kb_read)); |
diff --git a/src/identity/plugin_rest_identity.c b/src/identity/plugin_rest_identity.c index 093a24c39..cae0e4d95 100644 --- a/src/identity/plugin_rest_identity.c +++ b/src/identity/plugin_rest_identity.c | |||
@@ -385,7 +385,7 @@ ego_get_all (struct GNUNET_REST_RequestHandle *con_handle, | |||
385 | GNUNET_CONTAINER_multihashmap_contains ( | 385 | GNUNET_CONTAINER_multihashmap_contains ( |
386 | handle->rest_handle->url_param_map, &key)) | 386 | handle->rest_handle->url_param_map, &key)) |
387 | { | 387 | { |
388 | privkey_str = GNUNET_IDENTITY_private_key_to_string ( | 388 | privkey_str = GNUNET_CRYPTO_private_key_to_string ( |
389 | GNUNET_IDENTITY_ego_get_private_key (ego_entry->ego)); | 389 | GNUNET_IDENTITY_ego_get_private_key (ego_entry->ego)); |
390 | json_object_set_new (json_ego, | 390 | json_object_set_new (json_ego, |
391 | GNUNET_REST_IDENTITY_PARAM_PRIVKEY, | 391 | GNUNET_REST_IDENTITY_PARAM_PRIVKEY, |
@@ -440,7 +440,7 @@ ego_get_response (struct RequestHandle *handle, struct EgoEntry *ego_entry) | |||
440 | GNUNET_CONTAINER_multihashmap_contains ( | 440 | GNUNET_CONTAINER_multihashmap_contains ( |
441 | handle->rest_handle->url_param_map, &key)) | 441 | handle->rest_handle->url_param_map, &key)) |
442 | { | 442 | { |
443 | privkey_str = GNUNET_IDENTITY_private_key_to_string ( | 443 | privkey_str = GNUNET_CRYPTO_private_key_to_string ( |
444 | GNUNET_IDENTITY_ego_get_private_key (ego_entry->ego)); | 444 | GNUNET_IDENTITY_ego_get_private_key (ego_entry->ego)); |
445 | json_object_set_new (json_ego, | 445 | json_object_set_new (json_ego, |
446 | GNUNET_REST_IDENTITY_PARAM_PRIVKEY, | 446 | GNUNET_REST_IDENTITY_PARAM_PRIVKEY, |
@@ -576,7 +576,7 @@ do_finished (void *cls, enum GNUNET_ErrorCode ec) | |||
576 | */ | 576 | */ |
577 | static void | 577 | static void |
578 | do_finished_create (void *cls, | 578 | do_finished_create (void *cls, |
579 | const struct GNUNET_IDENTITY_PrivateKey *pk, | 579 | const struct GNUNET_CRYPTO_PrivateKey *pk, |
580 | enum GNUNET_ErrorCode ec) | 580 | enum GNUNET_ErrorCode ec) |
581 | { | 581 | { |
582 | struct RequestHandle *handle = cls; | 582 | struct RequestHandle *handle = cls; |
@@ -762,8 +762,8 @@ ego_create (struct GNUNET_REST_RequestHandle *con_handle, | |||
762 | json_error_t err; | 762 | json_error_t err; |
763 | char *egoname; | 763 | char *egoname; |
764 | char *privkey; | 764 | char *privkey; |
765 | struct GNUNET_IDENTITY_PrivateKey pk; | 765 | struct GNUNET_CRYPTO_PrivateKey pk; |
766 | struct GNUNET_IDENTITY_PrivateKey *pk_ptr; | 766 | struct GNUNET_CRYPTO_PrivateKey *pk_ptr; |
767 | int json_unpack_state; | 767 | int json_unpack_state; |
768 | char term_data[handle->data_size + 1]; | 768 | char term_data[handle->data_size + 1]; |
769 | 769 | ||
@@ -825,7 +825,7 @@ ego_create (struct GNUNET_REST_RequestHandle *con_handle, | |||
825 | strlen (privkey), | 825 | strlen (privkey), |
826 | &pk, | 826 | &pk, |
827 | sizeof(struct | 827 | sizeof(struct |
828 | GNUNET_IDENTITY_PrivateKey)); | 828 | GNUNET_CRYPTO_PrivateKey)); |
829 | pk_ptr = &pk; | 829 | pk_ptr = &pk; |
830 | } | 830 | } |
831 | else | 831 | else |
@@ -834,7 +834,7 @@ ego_create (struct GNUNET_REST_RequestHandle *con_handle, | |||
834 | handle->op = GNUNET_IDENTITY_create (identity_handle, | 834 | handle->op = GNUNET_IDENTITY_create (identity_handle, |
835 | handle->name, | 835 | handle->name, |
836 | pk_ptr, | 836 | pk_ptr, |
837 | GNUNET_IDENTITY_TYPE_ECDSA, | 837 | GNUNET_PUBLIC_KEY_TYPE_ECDSA, |
838 | &do_finished_create, | 838 | &do_finished_create, |
839 | handle); | 839 | handle); |
840 | } | 840 | } |
@@ -945,7 +945,7 @@ ego_sign_data_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
945 | return; | 945 | return; |
946 | } | 946 | } |
947 | 947 | ||
948 | if (ntohl (ego->pk.type) != GNUNET_IDENTITY_TYPE_EDDSA) | 948 | if (ntohl (ego->pk.type) != GNUNET_PUBLIC_KEY_TYPE_EDDSA) |
949 | { | 949 | { |
950 | handle->ec = GNUNET_EC_IDENTITY_NOT_FOUND; | 950 | handle->ec = GNUNET_EC_IDENTITY_NOT_FOUND; |
951 | GNUNET_SCHEDULER_add_now (&do_error, handle); | 951 | GNUNET_SCHEDULER_add_now (&do_error, handle); |
@@ -1069,7 +1069,7 @@ list_ego (void *cls, | |||
1069 | const char *identifier) | 1069 | const char *identifier) |
1070 | { | 1070 | { |
1071 | struct EgoEntry *ego_entry; | 1071 | struct EgoEntry *ego_entry; |
1072 | struct GNUNET_IDENTITY_PublicKey pk; | 1072 | struct GNUNET_CRYPTO_PublicKey pk; |
1073 | 1073 | ||
1074 | if ((NULL == ego) && (ID_REST_STATE_INIT == state)) | 1074 | if ((NULL == ego) && (ID_REST_STATE_INIT == state)) |
1075 | { | 1075 | { |
@@ -1086,7 +1086,7 @@ list_ego (void *cls, | |||
1086 | { | 1086 | { |
1087 | ego_entry = GNUNET_new (struct EgoEntry); | 1087 | ego_entry = GNUNET_new (struct EgoEntry); |
1088 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 1088 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
1089 | ego_entry->keystring = GNUNET_IDENTITY_public_key_to_string (&pk); | 1089 | ego_entry->keystring = GNUNET_CRYPTO_public_key_to_string (&pk); |
1090 | ego_entry->ego = ego; | 1090 | ego_entry->ego = ego; |
1091 | ego_entry->identifier = GNUNET_strdup (identifier); | 1091 | ego_entry->identifier = GNUNET_strdup (identifier); |
1092 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, | 1092 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, |
@@ -1112,7 +1112,7 @@ list_ego (void *cls, | |||
1112 | /* Add */ | 1112 | /* Add */ |
1113 | ego_entry = GNUNET_new (struct EgoEntry); | 1113 | ego_entry = GNUNET_new (struct EgoEntry); |
1114 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 1114 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
1115 | ego_entry->keystring = GNUNET_IDENTITY_public_key_to_string (&pk); | 1115 | ego_entry->keystring = GNUNET_CRYPTO_public_key_to_string (&pk); |
1116 | ego_entry->ego = ego; | 1116 | ego_entry->ego = ego; |
1117 | ego_entry->identifier = GNUNET_strdup (identifier); | 1117 | ego_entry->identifier = GNUNET_strdup (identifier); |
1118 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, | 1118 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, |
diff --git a/src/identity/test_identity.c b/src/identity/test_identity.c index 92c074981..d133e3ee4 100644 --- a/src/identity/test_identity.c +++ b/src/identity/test_identity.c | |||
@@ -253,24 +253,24 @@ success_rename_cont (void *cls, enum GNUNET_ErrorCode ec) | |||
253 | */ | 253 | */ |
254 | static void | 254 | static void |
255 | create_cb (void *cls, | 255 | create_cb (void *cls, |
256 | const struct GNUNET_IDENTITY_PrivateKey *pk, | 256 | const struct GNUNET_CRYPTO_PrivateKey *pk, |
257 | enum GNUNET_ErrorCode ec) | 257 | enum GNUNET_ErrorCode ec) |
258 | { | 258 | { |
259 | CHECK (NULL != pk); | 259 | CHECK (NULL != pk); |
260 | CHECK (GNUNET_EC_NONE == ec); | 260 | CHECK (GNUNET_EC_NONE == ec); |
261 | struct GNUNET_IDENTITY_PublicKey pub; | 261 | struct GNUNET_CRYPTO_PublicKey pub; |
262 | size_t pt_len = strlen ("test") + 1; | 262 | size_t pt_len = strlen ("test") + 1; |
263 | unsigned char ct[pt_len + GNUNET_IDENTITY_ENCRYPT_OVERHEAD_BYTES]; | 263 | unsigned char ct[pt_len + GNUNET_CRYPTO_ENCRYPT_OVERHEAD_BYTES]; |
264 | char pt[pt_len]; | 264 | char pt[pt_len]; |
265 | enum GNUNET_GenericReturnValue res; | 265 | enum GNUNET_GenericReturnValue res; |
266 | 266 | ||
267 | GNUNET_IDENTITY_key_get_public (pk, &pub); | 267 | GNUNET_CRYPTO_key_get_public (pk, &pub); |
268 | res = GNUNET_IDENTITY_encrypt ("test", pt_len, &pub, ct, | 268 | res = GNUNET_CRYPTO_encrypt ("test", pt_len, &pub, ct, |
269 | pt_len | 269 | pt_len |
270 | + GNUNET_IDENTITY_ENCRYPT_OVERHEAD_BYTES); | 270 | + GNUNET_CRYPTO_ENCRYPT_OVERHEAD_BYTES); |
271 | CHECK (GNUNET_OK == res); | 271 | CHECK (GNUNET_OK == res); |
272 | res = GNUNET_IDENTITY_decrypt (ct, pt_len | 272 | res = GNUNET_CRYPTO_decrypt (ct, pt_len |
273 | + GNUNET_IDENTITY_ENCRYPT_OVERHEAD_BYTES, | 273 | + GNUNET_CRYPTO_ENCRYPT_OVERHEAD_BYTES, |
274 | pk, pt, pt_len); | 274 | pk, pt, pt_len); |
275 | CHECK (GNUNET_OK == res); | 275 | CHECK (GNUNET_OK == res); |
276 | CHECK (0 == strcmp (pt, "test")); | 276 | CHECK (0 == strcmp (pt, "test")); |
@@ -298,7 +298,7 @@ run (void *cls, | |||
298 | op = GNUNET_IDENTITY_create (h, | 298 | op = GNUNET_IDENTITY_create (h, |
299 | "test-id", | 299 | "test-id", |
300 | NULL, | 300 | NULL, |
301 | GNUNET_IDENTITY_TYPE_ECDSA, | 301 | GNUNET_PUBLIC_KEY_TYPE_ECDSA, |
302 | &create_cb, NULL); | 302 | &create_cb, NULL); |
303 | } | 303 | } |
304 | 304 | ||
diff --git a/src/include/gnunet_abd_service.h b/src/include/gnunet_abd_service.h index 75c1757ab..cb6e77256 100644 --- a/src/include/gnunet_abd_service.h +++ b/src/include/gnunet_abd_service.h | |||
@@ -107,7 +107,7 @@ struct GNUNET_ABD_DelegationRecordSet | |||
107 | /** | 107 | /** |
108 | * Public key of the subject this attribute was delegated to | 108 | * Public key of the subject this attribute was delegated to |
109 | */ | 109 | */ |
110 | struct GNUNET_IDENTITY_PublicKey subject_key; | 110 | struct GNUNET_CRYPTO_PublicKey subject_key; |
111 | 111 | ||
112 | /** | 112 | /** |
113 | * Length of attribute, may be 0 | 113 | * Length of attribute, may be 0 |
@@ -127,7 +127,7 @@ struct GNUNET_ABD_DelegationSet | |||
127 | /** | 127 | /** |
128 | * Public key of the subject this attribute was delegated to | 128 | * Public key of the subject this attribute was delegated to |
129 | */ | 129 | */ |
130 | struct GNUNET_IDENTITY_PublicKey subject_key; | 130 | struct GNUNET_CRYPTO_PublicKey subject_key; |
131 | 131 | ||
132 | uint32_t subject_attribute_len; | 132 | uint32_t subject_attribute_len; |
133 | 133 | ||
@@ -147,12 +147,12 @@ struct GNUNET_ABD_Delegation | |||
147 | /** | 147 | /** |
148 | * The issuer of the delegation | 148 | * The issuer of the delegation |
149 | */ | 149 | */ |
150 | struct GNUNET_IDENTITY_PublicKey issuer_key; | 150 | struct GNUNET_CRYPTO_PublicKey issuer_key; |
151 | 151 | ||
152 | /** | 152 | /** |
153 | * Public key of the subject this attribute was delegated to | 153 | * Public key of the subject this attribute was delegated to |
154 | */ | 154 | */ |
155 | struct GNUNET_IDENTITY_PublicKey subject_key; | 155 | struct GNUNET_CRYPTO_PublicKey subject_key; |
156 | 156 | ||
157 | /** | 157 | /** |
158 | * Length of the attribute | 158 | * Length of the attribute |
@@ -185,17 +185,17 @@ struct GNUNET_ABD_Delegate | |||
185 | /** | 185 | /** |
186 | * The issuer of the credential | 186 | * The issuer of the credential |
187 | */ | 187 | */ |
188 | struct GNUNET_IDENTITY_PublicKey issuer_key; | 188 | struct GNUNET_CRYPTO_PublicKey issuer_key; |
189 | 189 | ||
190 | /** | 190 | /** |
191 | * Public key of the subject this credential was issued to | 191 | * Public key of the subject this credential was issued to |
192 | */ | 192 | */ |
193 | struct GNUNET_IDENTITY_PublicKey subject_key; | 193 | struct GNUNET_CRYPTO_PublicKey subject_key; |
194 | 194 | ||
195 | /** | 195 | /** |
196 | * Signature of this credential | 196 | * Signature of this credential |
197 | */ | 197 | */ |
198 | struct GNUNET_IDENTITY_Signature signature; | 198 | struct GNUNET_CRYPTO_Signature signature; |
199 | 199 | ||
200 | /** | 200 | /** |
201 | * Expiration of this credential | 201 | * Expiration of this credential |
@@ -322,9 +322,9 @@ typedef void (*GNUNET_ABD_RemoveDelegateResultProcessor) (void *cls, | |||
322 | */ | 322 | */ |
323 | struct GNUNET_ABD_Request* | 323 | struct GNUNET_ABD_Request* |
324 | GNUNET_ABD_verify (struct GNUNET_ABD_Handle *handle, | 324 | GNUNET_ABD_verify (struct GNUNET_ABD_Handle *handle, |
325 | const struct GNUNET_IDENTITY_PublicKey *issuer_key, | 325 | const struct GNUNET_CRYPTO_PublicKey *issuer_key, |
326 | const char *issuer_attribute, | 326 | const char *issuer_attribute, |
327 | const struct GNUNET_IDENTITY_PublicKey *subject_key, | 327 | const struct GNUNET_CRYPTO_PublicKey *subject_key, |
328 | uint32_t delegate_count, | 328 | uint32_t delegate_count, |
329 | const struct GNUNET_ABD_Delegate *delegates, | 329 | const struct GNUNET_ABD_Delegate *delegates, |
330 | enum GNUNET_ABD_AlgoDirectionFlags direction, | 330 | enum GNUNET_ABD_AlgoDirectionFlags direction, |
@@ -335,9 +335,9 @@ struct GNUNET_ABD_Request* | |||
335 | 335 | ||
336 | struct GNUNET_ABD_Request* | 336 | struct GNUNET_ABD_Request* |
337 | GNUNET_ABD_collect (struct GNUNET_ABD_Handle *handle, | 337 | GNUNET_ABD_collect (struct GNUNET_ABD_Handle *handle, |
338 | const struct GNUNET_IDENTITY_PublicKey *issuer_key, | 338 | const struct GNUNET_CRYPTO_PublicKey *issuer_key, |
339 | const char *issuer_attribute, | 339 | const char *issuer_attribute, |
340 | const struct GNUNET_IDENTITY_PrivateKey *subject_key, | 340 | const struct GNUNET_CRYPTO_PrivateKey *subject_key, |
341 | enum GNUNET_ABD_AlgoDirectionFlags direction, | 341 | enum GNUNET_ABD_AlgoDirectionFlags direction, |
342 | GNUNET_ABD_CredentialResultProcessor proc, | 342 | GNUNET_ABD_CredentialResultProcessor proc, |
343 | void *proc_cls, | 343 | void *proc_cls, |
@@ -360,7 +360,7 @@ struct GNUNET_ABD_Request * | |||
360 | GNUNET_ABD_add_delegation (struct GNUNET_ABD_Handle *handle, | 360 | GNUNET_ABD_add_delegation (struct GNUNET_ABD_Handle *handle, |
361 | struct GNUNET_IDENTITY_Ego *issuer, | 361 | struct GNUNET_IDENTITY_Ego *issuer, |
362 | const char *attribute, | 362 | const char *attribute, |
363 | struct GNUNET_IDENTITY_PublicKey *subject, | 363 | struct GNUNET_CRYPTO_PublicKey *subject, |
364 | const char *delegated_attribute, | 364 | const char *delegated_attribute, |
365 | GNUNET_ABD_DelegateResultProcessor proc, | 365 | GNUNET_ABD_DelegateResultProcessor proc, |
366 | void *proc_cls); | 366 | void *proc_cls); |
@@ -393,8 +393,8 @@ GNUNET_ABD_remove_delegation (struct GNUNET_ABD_Handle *handle, | |||
393 | * @return handle to the queued request | 393 | * @return handle to the queued request |
394 | */ | 394 | */ |
395 | struct GNUNET_ABD_Delegate* | 395 | struct GNUNET_ABD_Delegate* |
396 | GNUNET_ABD_delegate_issue (const struct GNUNET_IDENTITY_PrivateKey *issuer, | 396 | GNUNET_ABD_delegate_issue (const struct GNUNET_CRYPTO_PrivateKey *issuer, |
397 | struct GNUNET_IDENTITY_PublicKey *subject, | 397 | struct GNUNET_CRYPTO_PublicKey *subject, |
398 | const char *iss_attr, | 398 | const char *iss_attr, |
399 | const char *sub_attr, | 399 | const char *sub_attr, |
400 | struct GNUNET_TIME_Absolute *expiration); | 400 | struct GNUNET_TIME_Absolute *expiration); |
diff --git a/src/include/gnunet_conversation_service.h b/src/include/gnunet_conversation_service.h index 7d54914d1..7857a49cf 100644 --- a/src/include/gnunet_conversation_service.h +++ b/src/include/gnunet_conversation_service.h | |||
@@ -151,7 +151,7 @@ typedef void | |||
151 | struct GNUNET_CONVERSATION_Caller * | 151 | struct GNUNET_CONVERSATION_Caller * |
152 | caller, | 152 | caller, |
153 | const struct | 153 | const struct |
154 | GNUNET_IDENTITY_PublicKey *caller_id); | 154 | GNUNET_CRYPTO_PublicKey *caller_id); |
155 | 155 | ||
156 | 156 | ||
157 | /** | 157 | /** |
diff --git a/src/include/gnunet_crypto_lib.h b/src/include/gnunet_crypto_lib.h index 44dfb4e44..ca51f586c 100644 --- a/src/include/gnunet_crypto_lib.h +++ b/src/include/gnunet_crypto_lib.h | |||
@@ -348,6 +348,105 @@ struct GNUNET_CRYPTO_Edx25519Signature | |||
348 | unsigned char s[256 / 8]; | 348 | unsigned char s[256 / 8]; |
349 | }; | 349 | }; |
350 | 350 | ||
351 | /** | ||
352 | * Key type for the generic public key union | ||
353 | */ | ||
354 | enum GNUNET_CRYPTO_KeyType | ||
355 | { | ||
356 | /** | ||
357 | * The identity type. The value is the same as the | ||
358 | * PKEY record type. | ||
359 | */ | ||
360 | GNUNET_PUBLIC_KEY_TYPE_ECDSA = 65536, | ||
361 | |||
362 | /** | ||
363 | * EDDSA identity. The value is the same as the EDKEY | ||
364 | * record type. | ||
365 | */ | ||
366 | GNUNET_PUBLIC_KEY_TYPE_EDDSA = 65556 | ||
367 | }; | ||
368 | |||
369 | /** | ||
370 | * A private key for an identity as per LSD0001. | ||
371 | * Note that these types are NOT packed and MUST NOT be used in RPC | ||
372 | * messages. Use the respective serialization functions. | ||
373 | */ | ||
374 | struct GNUNET_CRYPTO_PrivateKey | ||
375 | { | ||
376 | /** | ||
377 | * Type of public key. | ||
378 | * Defined by the GNS zone type value. | ||
379 | * In NBO. | ||
380 | */ | ||
381 | uint32_t type; | ||
382 | |||
383 | union | ||
384 | { | ||
385 | /** | ||
386 | * An ECDSA identity key. | ||
387 | */ | ||
388 | struct GNUNET_CRYPTO_EcdsaPrivateKey ecdsa_key; | ||
389 | |||
390 | /** | ||
391 | * AN EdDSA identtiy key | ||
392 | */ | ||
393 | struct GNUNET_CRYPTO_EddsaPrivateKey eddsa_key; | ||
394 | }; | ||
395 | }; | ||
396 | |||
397 | |||
398 | /** | ||
399 | * An identity key as per LSD0001. | ||
400 | */ | ||
401 | struct GNUNET_CRYPTO_PublicKey | ||
402 | { | ||
403 | /** | ||
404 | * Type of public key. | ||
405 | * Defined by the GNS zone type value. | ||
406 | * In NBO. | ||
407 | */ | ||
408 | uint32_t type; | ||
409 | |||
410 | union | ||
411 | { | ||
412 | /** | ||
413 | * An ECDSA identity key. | ||
414 | */ | ||
415 | struct GNUNET_CRYPTO_EcdsaPublicKey ecdsa_key; | ||
416 | |||
417 | /** | ||
418 | * AN EdDSA identtiy key | ||
419 | */ | ||
420 | struct GNUNET_CRYPTO_EddsaPublicKey eddsa_key; | ||
421 | }; | ||
422 | }; | ||
423 | |||
424 | |||
425 | /** | ||
426 | * An identity signature as per LSD0001. | ||
427 | */ | ||
428 | struct GNUNET_CRYPTO_Signature | ||
429 | { | ||
430 | /** | ||
431 | * Type of signature. | ||
432 | * Defined by the GNS zone type value. | ||
433 | * In NBO. | ||
434 | */ | ||
435 | uint32_t type; | ||
436 | |||
437 | union | ||
438 | { | ||
439 | /** | ||
440 | * An ECDSA signature | ||
441 | */ | ||
442 | struct GNUNET_CRYPTO_EcdsaSignature ecdsa_signature; | ||
443 | |||
444 | /** | ||
445 | * AN EdDSA signature | ||
446 | */ | ||
447 | struct GNUNET_CRYPTO_EddsaSignature eddsa_signature; | ||
448 | }; | ||
449 | }; | ||
351 | 450 | ||
352 | /** | 451 | /** |
353 | * @brief type for session keys | 452 | * @brief type for session keys |
@@ -3073,6 +3172,473 @@ GNUNET_CRYPTO_cs_verify (const struct GNUNET_CRYPTO_CsSignature *sig, | |||
3073 | size_t msg_len); | 3172 | size_t msg_len); |
3074 | 3173 | ||
3075 | 3174 | ||
3175 | /** | ||
3176 | * Get the compacted length of a #GNUNET_CRYPTO_PublicKey. | ||
3177 | * Compacted means that it returns the minimum number of bytes this | ||
3178 | * key is long, as opposed to the union structure inside | ||
3179 | * #GNUNET_CRYPTO_PublicKey. | ||
3180 | * Useful for compact serializations. | ||
3181 | * | ||
3182 | * @param key the key. | ||
3183 | * @return -1 on error, else the compacted length of the key. | ||
3184 | */ | ||
3185 | ssize_t | ||
3186 | GNUNET_CRYPTO_public_key_get_length (const struct | ||
3187 | GNUNET_CRYPTO_PublicKey *key); | ||
3188 | |||
3189 | /** | ||
3190 | * Reads a #GNUNET_CRYPTO_PublicKey from a compact buffer. | ||
3191 | * The buffer has to contain at least the compacted length of | ||
3192 | * a #GNUNET_CRYPTO_PublicKey in bytes. | ||
3193 | * If the buffer is too small, the function returns -1 as error. | ||
3194 | * If the buffer does not contain a valid key, it returns -2 as error. | ||
3195 | * | ||
3196 | * @param buffer the buffer | ||
3197 | * @param len the length of buffer | ||
3198 | * @param key the key | ||
3199 | * @param the amount of bytes read from the buffer | ||
3200 | * @return #GNUNET_SYSERR on error | ||
3201 | */ | ||
3202 | enum GNUNET_GenericReturnValue | ||
3203 | GNUNET_CRYPTO_read_public_key_from_buffer ( | ||
3204 | const void *buffer, | ||
3205 | size_t len, | ||
3206 | struct GNUNET_CRYPTO_PublicKey *key, | ||
3207 | size_t *read); | ||
3208 | |||
3209 | /** | ||
3210 | * Get the compacted length of a #GNUNET_CRYPTO_PrivateKey. | ||
3211 | * Compacted means that it returns the minimum number of bytes this | ||
3212 | * key is long, as opposed to the union structure inside | ||
3213 | * #GNUNET_CRYPTO_PrivateKey. | ||
3214 | * Useful for compact serializations. | ||
3215 | * | ||
3216 | * @param key the key. | ||
3217 | * @return -1 on error, else the compacted length of the key. | ||
3218 | */ | ||
3219 | ssize_t | ||
3220 | GNUNET_CRYPTO_private_key_get_length ( | ||
3221 | const struct GNUNET_CRYPTO_PrivateKey *key); | ||
3222 | |||
3223 | |||
3224 | /** | ||
3225 | * Writes a #GNUNET_CRYPTO_PublicKey to a compact buffer. | ||
3226 | * The buffer requires space for at least the compacted length of | ||
3227 | * a #GNUNET_CRYPTO_PublicKey in bytes. | ||
3228 | * If the buffer is too small, the function returns -1 as error. | ||
3229 | * If the key is not valid, it returns -2 as error. | ||
3230 | * | ||
3231 | * @param key the key | ||
3232 | * @param buffer the buffer | ||
3233 | * @param len the length of buffer | ||
3234 | * @return -1 or -2 on error, else the amount of bytes written to the buffer | ||
3235 | */ | ||
3236 | ssize_t | ||
3237 | GNUNET_CRYPTO_write_public_key_to_buffer (const struct | ||
3238 | GNUNET_CRYPTO_PublicKey *key, | ||
3239 | void*buffer, | ||
3240 | size_t len); | ||
3241 | |||
3242 | |||
3243 | /** | ||
3244 | * Reads a #GNUNET_CRYPTO_PrivateKey from a compact buffer. | ||
3245 | * The buffer has to contain at least the compacted length of | ||
3246 | * a #GNUNET_CRYPTO_PrivateKey in bytes. | ||
3247 | * If the buffer is too small, the function returns GNUNET_SYSERR as error. | ||
3248 | * | ||
3249 | * @param buffer the buffer | ||
3250 | * @param len the length of buffer | ||
3251 | * @param key the key | ||
3252 | * @param the amount of bytes read from the buffer | ||
3253 | * @return #GNUNET_SYSERR on error | ||
3254 | */ | ||
3255 | enum GNUNET_GenericReturnValue | ||
3256 | GNUNET_CRYPTO_read_private_key_from_buffer ( | ||
3257 | const void*buffer, | ||
3258 | size_t len, | ||
3259 | struct GNUNET_CRYPTO_PrivateKey *key, | ||
3260 | size_t *read); | ||
3261 | |||
3262 | |||
3263 | /** | ||
3264 | * Writes a #GNUNET_CRYPTO_PrivateKey to a compact buffer. | ||
3265 | * The buffer requires space for at least the compacted length of | ||
3266 | * a #GNUNET_CRYPTO_PrivateKey in bytes. | ||
3267 | * If the buffer is too small, the function returns -1 as error. | ||
3268 | * If the key is not valid, it returns -2 as error. | ||
3269 | * | ||
3270 | * @param key the key | ||
3271 | * @param buffer the buffer | ||
3272 | * @param len the length of buffer | ||
3273 | * @return -1 or -2 on error, else the amount of bytes written to the buffer | ||
3274 | */ | ||
3275 | ssize_t | ||
3276 | GNUNET_CRYPTO_write_private_key_to_buffer ( | ||
3277 | const struct GNUNET_CRYPTO_PrivateKey *key, | ||
3278 | void*buffer, | ||
3279 | size_t len); | ||
3280 | |||
3281 | |||
3282 | /** | ||
3283 | * Get the compacted length of a #GNUNET_CRYPTO_Signature. | ||
3284 | * Compacted means that it returns the minimum number of bytes this | ||
3285 | * signature is long, as opposed to the union structure inside | ||
3286 | * #GNUNET_CRYPTO_Signature. | ||
3287 | * Useful for compact serializations. | ||
3288 | * | ||
3289 | * @param sig the signature. | ||
3290 | * @return -1 on error, else the compacted length of the signature. | ||
3291 | */ | ||
3292 | ssize_t | ||
3293 | GNUNET_CRYPTO_signature_get_length ( | ||
3294 | const struct GNUNET_CRYPTO_Signature *sig); | ||
3295 | |||
3296 | |||
3297 | /** | ||
3298 | * Get the compacted length of a signature by type. | ||
3299 | * Compacted means that it returns the minimum number of bytes this | ||
3300 | * signature is long, as opposed to the union structure inside | ||
3301 | * #GNUNET_CRYPTO_Signature. | ||
3302 | * Useful for compact serializations. | ||
3303 | * | ||
3304 | * @param sig the signature. | ||
3305 | * @return -1 on error, else the compacted length of the signature. | ||
3306 | */ | ||
3307 | ssize_t | ||
3308 | GNUNET_CRYPTO_signature_get_raw_length_by_type (uint32_t type); | ||
3309 | |||
3310 | |||
3311 | /** | ||
3312 | * Reads a #GNUNET_CRYPTO_Signature from a compact buffer. | ||
3313 | * The buffer has to contain at least the compacted length of | ||
3314 | * a #GNUNET_CRYPTO_Signature in bytes. | ||
3315 | * If the buffer is too small, the function returns -1 as error. | ||
3316 | * If the buffer does not contain a valid key, it returns -2 as error. | ||
3317 | * | ||
3318 | * @param sig the signature | ||
3319 | * @param buffer the buffer | ||
3320 | * @param len the length of buffer | ||
3321 | * @return -1 or -2 on error, else the amount of bytes read from the buffer | ||
3322 | */ | ||
3323 | ssize_t | ||
3324 | GNUNET_CRYPTO_read_signature_from_buffer ( | ||
3325 | struct GNUNET_CRYPTO_Signature *sig, | ||
3326 | const void*buffer, | ||
3327 | size_t len); | ||
3328 | |||
3329 | |||
3330 | /** | ||
3331 | * Writes a #GNUNET_CRYPTO_Signature to a compact buffer. | ||
3332 | * The buffer requires space for at least the compacted length of | ||
3333 | * a #GNUNET_CRYPTO_Signature in bytes. | ||
3334 | * If the buffer is too small, the function returns -1 as error. | ||
3335 | * If the key is not valid, it returns -2 as error. | ||
3336 | * | ||
3337 | * @param sig the signature | ||
3338 | * @param buffer the buffer | ||
3339 | * @param len the length of buffer | ||
3340 | * @return -1 or -2 on error, else the amount of bytes written to the buffer | ||
3341 | */ | ||
3342 | ssize_t | ||
3343 | GNUNET_CRYPTO_write_signature_to_buffer ( | ||
3344 | const struct GNUNET_CRYPTO_Signature *sig, | ||
3345 | void*buffer, | ||
3346 | size_t len); | ||
3347 | |||
3348 | |||
3349 | /** | ||
3350 | * @brief Sign a given block. | ||
3351 | * | ||
3352 | * The @a purpose data is the beginning of the data of which the signature is | ||
3353 | * to be created. The `size` field in @a purpose must correctly indicate the | ||
3354 | * number of bytes of the data structure, including its header. If possible, | ||
3355 | * use #GNUNET_CRYPTO_sign() instead of this function. | ||
3356 | * | ||
3357 | * @param priv private key to use for the signing | ||
3358 | * @param purpose what to sign (size, purpose) | ||
3359 | * @param[out] sig where to write the signature | ||
3360 | * @return #GNUNET_SYSERR on error, #GNUNET_OK on success | ||
3361 | */ | ||
3362 | enum GNUNET_GenericReturnValue | ||
3363 | GNUNET_CRYPTO_sign_ ( | ||
3364 | const struct GNUNET_CRYPTO_PrivateKey *priv, | ||
3365 | const struct GNUNET_CRYPTO_EccSignaturePurpose *purpose, | ||
3366 | struct GNUNET_CRYPTO_Signature *sig); | ||
3367 | |||
3368 | /** | ||
3369 | * @brief Sign a given block. | ||
3370 | * | ||
3371 | * The @a purpose data is the beginning of the data of which the signature is | ||
3372 | * to be created. The `size` field in @a purpose must correctly indicate the | ||
3373 | * number of bytes of the data structure, including its header. | ||
3374 | * The signature payload and length depends on the key type. | ||
3375 | * | ||
3376 | * @param priv private key to use for the signing | ||
3377 | * @param purpose what to sign (size, purpose) | ||
3378 | * @param[out] sig where to write the signature | ||
3379 | * @return #GNUNET_SYSERR on error, #GNUNET_OK on success | ||
3380 | */ | ||
3381 | enum GNUNET_GenericReturnValue | ||
3382 | GNUNET_CRYPTO_sign_raw_ ( | ||
3383 | const struct GNUNET_CRYPTO_PrivateKey *priv, | ||
3384 | const struct GNUNET_CRYPTO_EccSignaturePurpose *purpose, | ||
3385 | unsigned char *sig); | ||
3386 | |||
3387 | |||
3388 | /** | ||
3389 | * @brief Sign a given block with #GNUNET_CRYPTO_PrivateKey. | ||
3390 | * | ||
3391 | * The @a ps data must be a fixed-size struct for which the signature is to be | ||
3392 | * created. The `size` field in @a ps->purpose must correctly indicate the | ||
3393 | * number of bytes of the data structure, including its header. | ||
3394 | * | ||
3395 | * @param priv private key to use for the signing | ||
3396 | * @param ps packed struct with what to sign, MUST begin with a purpose | ||
3397 | * @param[out] sig where to write the signature | ||
3398 | */ | ||
3399 | #define GNUNET_CRYPTO_sign(priv,ps,sig) do { \ | ||
3400 | /* check size is set correctly */ \ | ||
3401 | GNUNET_assert (ntohl ((ps)->purpose.size) == sizeof (*(ps))); \ | ||
3402 | /* check 'ps' begins with the purpose */ \ | ||
3403 | GNUNET_static_assert (((void*) (ps)) == \ | ||
3404 | ((void*) &(ps)->purpose)); \ | ||
3405 | GNUNET_assert (GNUNET_OK == \ | ||
3406 | GNUNET_CRYPTO_sign_ (priv, \ | ||
3407 | &(ps)->purpose, \ | ||
3408 | sig)); \ | ||
3409 | } while (0) | ||
3410 | |||
3411 | |||
3412 | /** | ||
3413 | * @brief Verify a given signature. | ||
3414 | * | ||
3415 | * The @a validate data is the beginning of the data of which the signature | ||
3416 | * is to be verified. The `size` field in @a validate must correctly indicate | ||
3417 | * the number of bytes of the data structure, including its header. If @a | ||
3418 | * purpose does not match the purpose given in @a validate (the latter must be | ||
3419 | * in big endian), signature verification fails. If possible, | ||
3420 | * use #GNUNET_CRYPTO_signature_verify() instead of this function (only if @a validate | ||
3421 | * is not fixed-size, you must use this function directly). | ||
3422 | * | ||
3423 | * @param purpose what is the purpose that the signature should have? | ||
3424 | * @param validate block to validate (size, purpose, data) | ||
3425 | * @param sig signature that is being validated | ||
3426 | * @param pub public key of the signer | ||
3427 | * @returns #GNUNET_OK if ok, #GNUNET_SYSERR if invalid | ||
3428 | */ | ||
3429 | enum GNUNET_GenericReturnValue | ||
3430 | GNUNET_CRYPTO_signature_verify_ ( | ||
3431 | uint32_t purpose, | ||
3432 | const struct GNUNET_CRYPTO_EccSignaturePurpose *validate, | ||
3433 | const struct GNUNET_CRYPTO_Signature *sig, | ||
3434 | const struct GNUNET_CRYPTO_PublicKey *pub); | ||
3435 | |||
3436 | /** | ||
3437 | * @brief Verify a given signature. | ||
3438 | * | ||
3439 | * The @a validate data is the beginning of the data of which the signature | ||
3440 | * is to be verified. The `size` field in @a validate must correctly indicate | ||
3441 | * the number of bytes of the data structure, including its header. If @a | ||
3442 | * purpose does not match the purpose given in @a validate (the latter must be | ||
3443 | * in big endian), signature verification fails. | ||
3444 | * | ||
3445 | * @param purpose what is the purpose that the signature should have? | ||
3446 | * @param validate block to validate (size, purpose, data) | ||
3447 | * @param sig signature that is being validated | ||
3448 | * @param pub public key of the signer | ||
3449 | * @returns #GNUNET_OK if ok, #GNUNET_SYSERR if invalid | ||
3450 | */ | ||
3451 | enum GNUNET_GenericReturnValue | ||
3452 | GNUNET_CRYPTO_signature_verify_raw_ ( | ||
3453 | uint32_t purpose, | ||
3454 | const struct GNUNET_CRYPTO_EccSignaturePurpose *validate, | ||
3455 | const unsigned char *sig, | ||
3456 | const struct GNUNET_CRYPTO_PublicKey *pub); | ||
3457 | |||
3458 | |||
3459 | /** | ||
3460 | * @brief Verify a given signature with #GNUNET_CRYPTO_PublicKey. | ||
3461 | * | ||
3462 | * The @a ps data must be a fixed-size struct for which the signature is to be | ||
3463 | * created. The `size` field in @a ps->purpose must correctly indicate the | ||
3464 | * number of bytes of the data structure, including its header. | ||
3465 | * | ||
3466 | * @param purp purpose of the signature, must match 'ps->purpose.purpose' | ||
3467 | * (except in host byte order) | ||
3468 | * @param ps packed struct with what to sign, MUST begin with a purpose | ||
3469 | * @param sig where to read the signature from | ||
3470 | * @param pub public key to use for the verifying | ||
3471 | */ | ||
3472 | #define GNUNET_CRYPTO_signature_verify(purp,ps,sig,pub) ({ \ | ||
3473 | /* check size is set correctly */ \ | ||
3474 | GNUNET_assert (ntohl ((ps)->purpose.size) == sizeof (*(ps))); \ | ||
3475 | /* check 'ps' begins with the purpose */ \ | ||
3476 | GNUNET_static_assert (((void*) (ps)) == \ | ||
3477 | ((void*) &(ps)->purpose)); \ | ||
3478 | GNUNET_CRYPTO_signature_verify_ (purp, \ | ||
3479 | &(ps)->purpose, \ | ||
3480 | sig, \ | ||
3481 | pub); \ | ||
3482 | }) | ||
3483 | |||
3484 | |||
3485 | /** | ||
3486 | * Encrypt a block with #GNUNET_CRYPTO_PublicKey and derives a | ||
3487 | * #GNUNET_CRYPTO_EcdhePublicKey which is required for decryption | ||
3488 | * using ecdh to derive a symmetric key. | ||
3489 | * | ||
3490 | * @param block the block to encrypt | ||
3491 | * @param size the size of the @a block | ||
3492 | * @param pub public key to use for ecdh | ||
3493 | * @param ecc where to write the ecc public key | ||
3494 | * @param result the output parameter in which to store the encrypted result | ||
3495 | * can be the same or overlap with @c block | ||
3496 | * @returns the size of the encrypted block, -1 for errors. | ||
3497 | * Due to the use of CFB and therefore an effective stream cipher, | ||
3498 | * this size should be the same as @c len. | ||
3499 | */ | ||
3500 | ssize_t | ||
3501 | GNUNET_CRYPTO_encrypt_old (const void *block, | ||
3502 | size_t size, | ||
3503 | const struct GNUNET_CRYPTO_PublicKey *pub, | ||
3504 | struct GNUNET_CRYPTO_EcdhePublicKey *ecc, | ||
3505 | void *result); | ||
3506 | |||
3507 | |||
3508 | /** | ||
3509 | * Decrypt a given block with #GNUNET_CRYPTO_PrivateKey and a given | ||
3510 | * #GNUNET_CRYPTO_EcdhePublicKey using ecdh to derive a symmetric key. | ||
3511 | * | ||
3512 | * @param block the data to decrypt, encoded as returned by encrypt | ||
3513 | * @param size the size of the @a block to decrypt | ||
3514 | * @param priv private key to use for ecdh | ||
3515 | * @param ecc the ecc public key | ||
3516 | * @param result address to store the result at | ||
3517 | * can be the same or overlap with @c block | ||
3518 | * @return -1 on failure, size of decrypted block on success. | ||
3519 | * Due to the use of CFB and therefore an effective stream cipher, | ||
3520 | * this size should be the same as @c size. | ||
3521 | */ | ||
3522 | ssize_t | ||
3523 | GNUNET_CRYPTO_decrypt_old ( | ||
3524 | const void *block, | ||
3525 | size_t size, | ||
3526 | const struct GNUNET_CRYPTO_PrivateKey *priv, | ||
3527 | const struct GNUNET_CRYPTO_EcdhePublicKey *ecc, | ||
3528 | void *result); | ||
3529 | |||
3530 | #define GNUNET_CRYPTO_ENCRYPT_OVERHEAD_BYTES (crypto_secretbox_MACBYTES \ | ||
3531 | + sizeof (struct \ | ||
3532 | GNUNET_CRYPTO_FoKemC)) | ||
3533 | |||
3534 | /** | ||
3535 | * Encrypt a block with #GNUNET_CRYPTO_PublicKey and derives a | ||
3536 | * #GNUNET_CRYPTO_EcdhePublicKey which is required for decryption | ||
3537 | * using ecdh to derive a symmetric key. | ||
3538 | * | ||
3539 | * Note that the result buffer for the ciphertext must be the length of | ||
3540 | * the message to encrypt plus #GNUNET_CRYPTO_ENCRYPT_OVERHEAD_BYTES. | ||
3541 | * | ||
3542 | * @param block the block to encrypt | ||
3543 | * @param size the size of the @a block | ||
3544 | * @param pub public key to encrypt for | ||
3545 | * @param result the output parameter in which to store the encrypted result | ||
3546 | * can be the same or overlap with @c block | ||
3547 | * @returns GNUNET_OK on success. | ||
3548 | */ | ||
3549 | enum GNUNET_GenericReturnValue | ||
3550 | GNUNET_CRYPTO_encrypt (const void *block, | ||
3551 | size_t size, | ||
3552 | const struct GNUNET_CRYPTO_PublicKey *pub, | ||
3553 | void *result, | ||
3554 | size_t result_size); | ||
3555 | |||
3556 | |||
3557 | /** | ||
3558 | * Decrypt a given block with #GNUNET_CRYPTO_PrivateKey and a given | ||
3559 | * #GNUNET_CRYPTO_EcdhePublicKey using ecdh to derive a symmetric key. | ||
3560 | * | ||
3561 | * @param block the data to decrypt, encoded as returned by encrypt | ||
3562 | * @param size the size of the @a block to decrypt | ||
3563 | * @param priv private key to use for ecdh | ||
3564 | * @param result address to store the result at | ||
3565 | * can be the same or overlap with @c block | ||
3566 | * @returns GNUNET_OK on success. | ||
3567 | */ | ||
3568 | enum GNUNET_GenericReturnValue | ||
3569 | GNUNET_CRYPTO_decrypt (const void *block, | ||
3570 | size_t size, | ||
3571 | const struct GNUNET_CRYPTO_PrivateKey *priv, | ||
3572 | void *result, | ||
3573 | size_t result_size); | ||
3574 | |||
3575 | |||
3576 | /** | ||
3577 | * Creates a (Base32) string representation of the public key. | ||
3578 | * The resulting string encodes a compacted representation of the key. | ||
3579 | * See also #GNUNET_CRYPTO_key_get_length. | ||
3580 | * | ||
3581 | * @param key the key. | ||
3582 | * @return the string representation of the key, or NULL on error. | ||
3583 | */ | ||
3584 | char * | ||
3585 | GNUNET_CRYPTO_public_key_to_string ( | ||
3586 | const struct GNUNET_CRYPTO_PublicKey *key); | ||
3587 | |||
3588 | |||
3589 | /** | ||
3590 | * Creates a (Base32) string representation of the private key. | ||
3591 | * The resulting string encodes a compacted representation of the key. | ||
3592 | * See also #GNUNET_CRYPTO_key_get_length. | ||
3593 | * | ||
3594 | * @param key the key. | ||
3595 | * @return the string representation of the key, or NULL on error. | ||
3596 | */ | ||
3597 | char * | ||
3598 | GNUNET_CRYPTO_private_key_to_string ( | ||
3599 | const struct GNUNET_CRYPTO_PrivateKey *key); | ||
3600 | |||
3601 | |||
3602 | /** | ||
3603 | * Parses a (Base32) string representation of the public key. | ||
3604 | * See also #GNUNET_CRYPTO_public_key_to_string. | ||
3605 | * | ||
3606 | * @param str the encoded key. | ||
3607 | * @param key where to write the key. | ||
3608 | * @return GNUNET_SYSERR on error. | ||
3609 | */ | ||
3610 | enum GNUNET_GenericReturnValue | ||
3611 | GNUNET_CRYPTO_public_key_from_string (const char*str, | ||
3612 | struct GNUNET_CRYPTO_PublicKey *key); | ||
3613 | |||
3614 | |||
3615 | /** | ||
3616 | * Parses a (Base32) string representation of the private key. | ||
3617 | * See also #GNUNET_CRYPTO_private_key_to_string. | ||
3618 | * | ||
3619 | * @param str the encoded key. | ||
3620 | * @param key where to write the key. | ||
3621 | * @return GNUNET_SYSERR on error. | ||
3622 | */ | ||
3623 | enum GNUNET_GenericReturnValue | ||
3624 | GNUNET_CRYPTO_private_key_from_string (const char*str, | ||
3625 | struct GNUNET_CRYPTO_PrivateKey *key); | ||
3626 | |||
3627 | |||
3628 | /** | ||
3629 | * Retrieves the public key representation of a private key. | ||
3630 | * | ||
3631 | * @param privkey the private key. | ||
3632 | * @param key the public key result. | ||
3633 | * @return GNUNET_SYSERR on error. | ||
3634 | */ | ||
3635 | enum GNUNET_GenericReturnValue | ||
3636 | GNUNET_CRYPTO_key_get_public (const struct | ||
3637 | GNUNET_CRYPTO_PrivateKey *privkey, | ||
3638 | struct GNUNET_CRYPTO_PublicKey *key); | ||
3639 | |||
3640 | |||
3641 | |||
3076 | #if 0 /* keep Emacsens' auto-indent happy */ | 3642 | #if 0 /* keep Emacsens' auto-indent happy */ |
3077 | { | 3643 | { |
3078 | #endif | 3644 | #endif |
diff --git a/src/include/gnunet_gns_service.h b/src/include/gnunet_gns_service.h index 1fcf7aa8b..1f19e58ac 100644 --- a/src/include/gnunet_gns_service.h +++ b/src/include/gnunet_gns_service.h | |||
@@ -137,7 +137,7 @@ enum GNUNET_GNS_LocalOptions | |||
137 | struct GNUNET_GNS_LookupRequest * | 137 | struct GNUNET_GNS_LookupRequest * |
138 | GNUNET_GNS_lookup (struct GNUNET_GNS_Handle *handle, | 138 | GNUNET_GNS_lookup (struct GNUNET_GNS_Handle *handle, |
139 | const char *name, | 139 | const char *name, |
140 | const struct GNUNET_IDENTITY_PublicKey *zone, | 140 | const struct GNUNET_CRYPTO_PublicKey *zone, |
141 | uint32_t type, | 141 | uint32_t type, |
142 | enum GNUNET_GNS_LocalOptions options, | 142 | enum GNUNET_GNS_LocalOptions options, |
143 | GNUNET_GNS_LookupResultProcessor proc, | 143 | GNUNET_GNS_LookupResultProcessor proc, |
@@ -161,7 +161,7 @@ GNUNET_GNS_lookup (struct GNUNET_GNS_Handle *handle, | |||
161 | struct GNUNET_GNS_LookupRequest * | 161 | struct GNUNET_GNS_LookupRequest * |
162 | GNUNET_GNS_lookup_limited (struct GNUNET_GNS_Handle *handle, | 162 | GNUNET_GNS_lookup_limited (struct GNUNET_GNS_Handle *handle, |
163 | const char *name, | 163 | const char *name, |
164 | const struct GNUNET_IDENTITY_PublicKey *zone, | 164 | const struct GNUNET_CRYPTO_PublicKey *zone, |
165 | uint32_t type, | 165 | uint32_t type, |
166 | enum GNUNET_GNS_LocalOptions options, | 166 | enum GNUNET_GNS_LocalOptions options, |
167 | uint16_t recursion_depth_limit, | 167 | uint16_t recursion_depth_limit, |
diff --git a/src/include/gnunet_gnsrecord_lib.h b/src/include/gnunet_gnsrecord_lib.h index 338f22223..d78e637e8 100644 --- a/src/include/gnunet_gnsrecord_lib.h +++ b/src/include/gnunet_gnsrecord_lib.h | |||
@@ -339,7 +339,7 @@ struct GNUNET_GNSRECORD_ReverseRecord | |||
339 | /** | 339 | /** |
340 | * The public key of the namespace the is delegating to our namespace | 340 | * The public key of the namespace the is delegating to our namespace |
341 | */ | 341 | */ |
342 | struct GNUNET_IDENTITY_PublicKey pkey; | 342 | struct GNUNET_CRYPTO_PublicKey pkey; |
343 | 343 | ||
344 | /** | 344 | /** |
345 | * The expiration time of the delegation | 345 | * The expiration time of the delegation |
@@ -494,7 +494,7 @@ GNUNET_GNSRECORD_string_normalize (const char *src); | |||
494 | * #GNUNET_GNSRECORD_z2s. | 494 | * #GNUNET_GNSRECORD_z2s. |
495 | */ | 495 | */ |
496 | const char * | 496 | const char * |
497 | GNUNET_GNSRECORD_z2s (const struct GNUNET_IDENTITY_PublicKey *z); | 497 | GNUNET_GNSRECORD_z2s (const struct GNUNET_CRYPTO_PublicKey *z); |
498 | 498 | ||
499 | 499 | ||
500 | /** | 500 | /** |
@@ -508,7 +508,7 @@ GNUNET_GNSRECORD_z2s (const struct GNUNET_IDENTITY_PublicKey *z); | |||
508 | * key in an encoding suitable for DNS labels. | 508 | * key in an encoding suitable for DNS labels. |
509 | */ | 509 | */ |
510 | const char * | 510 | const char * |
511 | GNUNET_GNSRECORD_pkey_to_zkey (const struct GNUNET_IDENTITY_PublicKey *pkey); | 511 | GNUNET_GNSRECORD_pkey_to_zkey (const struct GNUNET_CRYPTO_PublicKey *pkey); |
512 | 512 | ||
513 | 513 | ||
514 | /** | 514 | /** |
@@ -522,7 +522,7 @@ GNUNET_GNSRECORD_pkey_to_zkey (const struct GNUNET_IDENTITY_PublicKey *pkey); | |||
522 | */ | 522 | */ |
523 | int | 523 | int |
524 | GNUNET_GNSRECORD_zkey_to_pkey (const char *zkey, | 524 | GNUNET_GNSRECORD_zkey_to_pkey (const char *zkey, |
525 | struct GNUNET_IDENTITY_PublicKey *pkey); | 525 | struct GNUNET_CRYPTO_PublicKey *pkey); |
526 | 526 | ||
527 | 527 | ||
528 | /** | 528 | /** |
@@ -534,7 +534,7 @@ GNUNET_GNSRECORD_zkey_to_pkey (const char *zkey, | |||
534 | */ | 534 | */ |
535 | void | 535 | void |
536 | GNUNET_GNSRECORD_query_from_private_key ( | 536 | GNUNET_GNSRECORD_query_from_private_key ( |
537 | const struct GNUNET_IDENTITY_PrivateKey *zone, const char *label, | 537 | const struct GNUNET_CRYPTO_PrivateKey *zone, const char *label, |
538 | struct GNUNET_HashCode *query); | 538 | struct GNUNET_HashCode *query); |
539 | 539 | ||
540 | 540 | ||
@@ -548,7 +548,7 @@ GNUNET_GNSRECORD_query_from_private_key ( | |||
548 | */ | 548 | */ |
549 | void | 549 | void |
550 | GNUNET_GNSRECORD_query_from_public_key ( | 550 | GNUNET_GNSRECORD_query_from_public_key ( |
551 | const struct GNUNET_IDENTITY_PublicKey *pub, const char *label, | 551 | const struct GNUNET_CRYPTO_PublicKey *pub, const char *label, |
552 | struct GNUNET_HashCode *query); | 552 | struct GNUNET_HashCode *query); |
553 | 553 | ||
554 | 554 | ||
@@ -562,7 +562,7 @@ GNUNET_GNSRECORD_query_from_public_key ( | |||
562 | */ | 562 | */ |
563 | ssize_t | 563 | ssize_t |
564 | GNUNET_GNSRECORD_block_calculate_size (const struct | 564 | GNUNET_GNSRECORD_block_calculate_size (const struct |
565 | GNUNET_IDENTITY_PrivateKey *key, | 565 | GNUNET_CRYPTO_PrivateKey *key, |
566 | const struct GNUNET_GNSRECORD_Data *rd, | 566 | const struct GNUNET_GNSRECORD_Data *rd, |
567 | unsigned int rd_count); | 567 | unsigned int rd_count); |
568 | 568 | ||
@@ -576,7 +576,7 @@ GNUNET_GNSRECORD_block_calculate_size (const struct | |||
576 | */ | 576 | */ |
577 | enum GNUNET_GenericReturnValue | 577 | enum GNUNET_GenericReturnValue |
578 | GNUNET_GNSRECORD_block_sign (const struct | 578 | GNUNET_GNSRECORD_block_sign (const struct |
579 | GNUNET_IDENTITY_PrivateKey *key, | 579 | GNUNET_CRYPTO_PrivateKey *key, |
580 | const char *label, | 580 | const char *label, |
581 | struct GNUNET_GNSRECORD_Block *block); | 581 | struct GNUNET_GNSRECORD_Block *block); |
582 | 582 | ||
@@ -592,7 +592,7 @@ GNUNET_GNSRECORD_block_sign (const struct | |||
592 | * @return GNUNET_OK on success | 592 | * @return GNUNET_OK on success |
593 | */ | 593 | */ |
594 | enum GNUNET_GenericReturnValue | 594 | enum GNUNET_GenericReturnValue |
595 | GNUNET_GNSRECORD_block_create (const struct GNUNET_IDENTITY_PrivateKey *key, | 595 | GNUNET_GNSRECORD_block_create (const struct GNUNET_CRYPTO_PrivateKey *key, |
596 | struct GNUNET_TIME_Absolute expire, | 596 | struct GNUNET_TIME_Absolute expire, |
597 | const char *label, | 597 | const char *label, |
598 | const struct GNUNET_GNSRECORD_Data *rd, | 598 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -617,7 +617,7 @@ GNUNET_GNSRECORD_block_create (const struct GNUNET_IDENTITY_PrivateKey *key, | |||
617 | */ | 617 | */ |
618 | enum GNUNET_GenericReturnValue | 618 | enum GNUNET_GenericReturnValue |
619 | GNUNET_GNSRECORD_block_create_unsigned (const struct | 619 | GNUNET_GNSRECORD_block_create_unsigned (const struct |
620 | GNUNET_IDENTITY_PrivateKey *key, | 620 | GNUNET_CRYPTO_PrivateKey *key, |
621 | struct GNUNET_TIME_Absolute expire, | 621 | struct GNUNET_TIME_Absolute expire, |
622 | const char *label, | 622 | const char *label, |
623 | const struct GNUNET_GNSRECORD_Data *rd, | 623 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -639,7 +639,7 @@ GNUNET_GNSRECORD_block_create_unsigned (const struct | |||
639 | * @return GNUNET_OK on success. | 639 | * @return GNUNET_OK on success. |
640 | */ | 640 | */ |
641 | enum GNUNET_GenericReturnValue | 641 | enum GNUNET_GenericReturnValue |
642 | GNUNET_GNSRECORD_block_create2 (const struct GNUNET_IDENTITY_PrivateKey *key, | 642 | GNUNET_GNSRECORD_block_create2 (const struct GNUNET_CRYPTO_PrivateKey *key, |
643 | struct GNUNET_TIME_Absolute expire, | 643 | struct GNUNET_TIME_Absolute expire, |
644 | const char *label, | 644 | const char *label, |
645 | const struct GNUNET_GNSRECORD_Data *rd, | 645 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -672,7 +672,7 @@ GNUNET_GNSRECORD_block_verify (const struct GNUNET_GNSRECORD_Block *block); | |||
672 | enum GNUNET_GenericReturnValue | 672 | enum GNUNET_GenericReturnValue |
673 | GNUNET_GNSRECORD_block_decrypt ( | 673 | GNUNET_GNSRECORD_block_decrypt ( |
674 | const struct GNUNET_GNSRECORD_Block *block, | 674 | const struct GNUNET_GNSRECORD_Block *block, |
675 | const struct GNUNET_IDENTITY_PublicKey *zone_key, const char *label, | 675 | const struct GNUNET_CRYPTO_PublicKey *zone_key, const char *label, |
676 | GNUNET_GNSRECORD_RecordCallback proc, void *proc_cls); | 676 | GNUNET_GNSRECORD_RecordCallback proc, void *proc_cls); |
677 | 677 | ||
678 | 678 | ||
@@ -752,7 +752,7 @@ enum GNUNET_GenericReturnValue | |||
752 | GNUNET_GNSRECORD_identity_from_data (const char *data, | 752 | GNUNET_GNSRECORD_identity_from_data (const char *data, |
753 | size_t data_size, | 753 | size_t data_size, |
754 | uint32_t type, | 754 | uint32_t type, |
755 | struct GNUNET_IDENTITY_PublicKey *key); | 755 | struct GNUNET_CRYPTO_PublicKey *key); |
756 | 756 | ||
757 | 757 | ||
758 | /** | 758 | /** |
@@ -766,7 +766,7 @@ GNUNET_GNSRECORD_identity_from_data (const char *data, | |||
766 | */ | 766 | */ |
767 | enum GNUNET_GenericReturnValue | 767 | enum GNUNET_GenericReturnValue |
768 | GNUNET_GNSRECORD_data_from_identity (const struct | 768 | GNUNET_GNSRECORD_data_from_identity (const struct |
769 | GNUNET_IDENTITY_PublicKey *key, | 769 | GNUNET_CRYPTO_PublicKey *key, |
770 | char **data, | 770 | char **data, |
771 | size_t *data_size, | 771 | size_t *data_size, |
772 | uint32_t *type); | 772 | uint32_t *type); |
diff --git a/src/include/gnunet_identity_service.h b/src/include/gnunet_identity_service.h index fd0458f62..4743dbf7e 100644 --- a/src/include/gnunet_identity_service.h +++ b/src/include/gnunet_identity_service.h | |||
@@ -62,20 +62,6 @@ extern "C" { | |||
62 | */ | 62 | */ |
63 | #define GNUNET_IDENTITY_VERSION 0x00000100 | 63 | #define GNUNET_IDENTITY_VERSION 0x00000100 |
64 | 64 | ||
65 | enum GNUNET_IDENTITY_KeyType | ||
66 | { | ||
67 | /** | ||
68 | * The identity type. The value is the same as the | ||
69 | * PKEY record type. | ||
70 | */ | ||
71 | GNUNET_IDENTITY_TYPE_ECDSA = 65536, | ||
72 | |||
73 | /** | ||
74 | * EDDSA identity. The value is the same as the EDKEY | ||
75 | * record type. | ||
76 | */ | ||
77 | GNUNET_IDENTITY_TYPE_EDDSA = 65556 | ||
78 | }; | ||
79 | 65 | ||
80 | /** | 66 | /** |
81 | * Handle to access the identity service. | 67 | * Handle to access the identity service. |
@@ -88,89 +74,6 @@ struct GNUNET_IDENTITY_Handle; | |||
88 | struct GNUNET_IDENTITY_Ego; | 74 | struct GNUNET_IDENTITY_Ego; |
89 | 75 | ||
90 | /** | 76 | /** |
91 | * A private key for an identity as per LSD0001. | ||
92 | * Note that these types are NOT packed and MUST NOT be used in RPC | ||
93 | * messages. Use the respective serialization functions. | ||
94 | */ | ||
95 | struct GNUNET_IDENTITY_PrivateKey | ||
96 | { | ||
97 | /** | ||
98 | * Type of public key. | ||
99 | * Defined by the GNS zone type value. | ||
100 | * In NBO. | ||
101 | */ | ||
102 | uint32_t type; | ||
103 | |||
104 | union | ||
105 | { | ||
106 | /** | ||
107 | * An ECDSA identity key. | ||
108 | */ | ||
109 | struct GNUNET_CRYPTO_EcdsaPrivateKey ecdsa_key; | ||
110 | |||
111 | /** | ||
112 | * AN EdDSA identtiy key | ||
113 | */ | ||
114 | struct GNUNET_CRYPTO_EddsaPrivateKey eddsa_key; | ||
115 | }; | ||
116 | }; | ||
117 | |||
118 | |||
119 | /** | ||
120 | * An identity key as per LSD0001. | ||
121 | */ | ||
122 | struct GNUNET_IDENTITY_PublicKey | ||
123 | { | ||
124 | /** | ||
125 | * Type of public key. | ||
126 | * Defined by the GNS zone type value. | ||
127 | * In NBO. | ||
128 | */ | ||
129 | uint32_t type; | ||
130 | |||
131 | union | ||
132 | { | ||
133 | /** | ||
134 | * An ECDSA identity key. | ||
135 | */ | ||
136 | struct GNUNET_CRYPTO_EcdsaPublicKey ecdsa_key; | ||
137 | |||
138 | /** | ||
139 | * AN EdDSA identtiy key | ||
140 | */ | ||
141 | struct GNUNET_CRYPTO_EddsaPublicKey eddsa_key; | ||
142 | }; | ||
143 | }; | ||
144 | |||
145 | |||
146 | /** | ||
147 | * An identity signature as per LSD0001. | ||
148 | */ | ||
149 | struct GNUNET_IDENTITY_Signature | ||
150 | { | ||
151 | /** | ||
152 | * Type of signature. | ||
153 | * Defined by the GNS zone type value. | ||
154 | * In NBO. | ||
155 | */ | ||
156 | uint32_t type; | ||
157 | |||
158 | union | ||
159 | { | ||
160 | /** | ||
161 | * An ECDSA signature | ||
162 | */ | ||
163 | struct GNUNET_CRYPTO_EcdsaSignature ecdsa_signature; | ||
164 | |||
165 | /** | ||
166 | * AN EdDSA signature | ||
167 | */ | ||
168 | struct GNUNET_CRYPTO_EddsaSignature eddsa_signature; | ||
169 | }; | ||
170 | }; | ||
171 | |||
172 | |||
173 | /** | ||
174 | * Handle for an operation with the identity service. | 77 | * Handle for an operation with the identity service. |
175 | */ | 78 | */ |
176 | struct GNUNET_IDENTITY_Operation; | 79 | struct GNUNET_IDENTITY_Operation; |
@@ -182,7 +85,7 @@ struct GNUNET_IDENTITY_Operation; | |||
182 | * @param ego the ego | 85 | * @param ego the ego |
183 | * @return associated ECC key, valid as long as the ego is valid | 86 | * @return associated ECC key, valid as long as the ego is valid |
184 | */ | 87 | */ |
185 | const struct GNUNET_IDENTITY_PrivateKey * | 88 | const struct GNUNET_CRYPTO_PrivateKey * |
186 | GNUNET_IDENTITY_ego_get_private_key (const struct GNUNET_IDENTITY_Ego *ego); | 89 | GNUNET_IDENTITY_ego_get_private_key (const struct GNUNET_IDENTITY_Ego *ego); |
187 | 90 | ||
188 | 91 | ||
@@ -203,7 +106,7 @@ GNUNET_IDENTITY_ego_get_anonymous (void); | |||
203 | */ | 106 | */ |
204 | void | 107 | void |
205 | GNUNET_IDENTITY_ego_get_public_key (struct GNUNET_IDENTITY_Ego *ego, | 108 | GNUNET_IDENTITY_ego_get_public_key (struct GNUNET_IDENTITY_Ego *ego, |
206 | struct GNUNET_IDENTITY_PublicKey *pk); | 109 | struct GNUNET_CRYPTO_PublicKey *pk); |
207 | 110 | ||
208 | 111 | ||
209 | /** | 112 | /** |
@@ -326,7 +229,7 @@ GNUNET_IDENTITY_disconnect (struct GNUNET_IDENTITY_Handle *h); | |||
326 | typedef void | 229 | typedef void |
327 | (*GNUNET_IDENTITY_CreateContinuation) ( | 230 | (*GNUNET_IDENTITY_CreateContinuation) ( |
328 | void *cls, | 231 | void *cls, |
329 | const struct GNUNET_IDENTITY_PrivateKey *pk, | 232 | const struct GNUNET_CRYPTO_PrivateKey *pk, |
330 | enum GNUNET_ErrorCode ec); | 233 | enum GNUNET_ErrorCode ec); |
331 | 234 | ||
332 | 235 | ||
@@ -344,8 +247,8 @@ typedef void | |||
344 | struct GNUNET_IDENTITY_Operation * | 247 | struct GNUNET_IDENTITY_Operation * |
345 | GNUNET_IDENTITY_create (struct GNUNET_IDENTITY_Handle *id, | 248 | GNUNET_IDENTITY_create (struct GNUNET_IDENTITY_Handle *id, |
346 | const char *name, | 249 | const char *name, |
347 | const struct GNUNET_IDENTITY_PrivateKey *privkey, | 250 | const struct GNUNET_CRYPTO_PrivateKey *privkey, |
348 | enum GNUNET_IDENTITY_KeyType ktype, | 251 | enum GNUNET_CRYPTO_KeyType ktype, |
349 | GNUNET_IDENTITY_CreateContinuation cont, | 252 | GNUNET_IDENTITY_CreateContinuation cont, |
350 | void *cont_cls); | 253 | void *cont_cls); |
351 | 254 | ||
@@ -396,472 +299,6 @@ void | |||
396 | GNUNET_IDENTITY_cancel (struct GNUNET_IDENTITY_Operation *op); | 299 | GNUNET_IDENTITY_cancel (struct GNUNET_IDENTITY_Operation *op); |
397 | 300 | ||
398 | 301 | ||
399 | /** | ||
400 | * Get the compacted length of a #GNUNET_IDENTITY_PublicKey. | ||
401 | * Compacted means that it returns the minimum number of bytes this | ||
402 | * key is long, as opposed to the union structure inside | ||
403 | * #GNUNET_IDENTITY_PublicKey. | ||
404 | * Useful for compact serializations. | ||
405 | * | ||
406 | * @param key the key. | ||
407 | * @return -1 on error, else the compacted length of the key. | ||
408 | */ | ||
409 | ssize_t | ||
410 | GNUNET_IDENTITY_public_key_get_length (const struct | ||
411 | GNUNET_IDENTITY_PublicKey *key); | ||
412 | |||
413 | /** | ||
414 | * Reads a #GNUNET_IDENTITY_PublicKey from a compact buffer. | ||
415 | * The buffer has to contain at least the compacted length of | ||
416 | * a #GNUNET_IDENTITY_PublicKey in bytes. | ||
417 | * If the buffer is too small, the function returns -1 as error. | ||
418 | * If the buffer does not contain a valid key, it returns -2 as error. | ||
419 | * | ||
420 | * @param buffer the buffer | ||
421 | * @param len the length of buffer | ||
422 | * @param key the key | ||
423 | * @param the amount of bytes read from the buffer | ||
424 | * @return #GNUNET_SYSERR on error | ||
425 | */ | ||
426 | enum GNUNET_GenericReturnValue | ||
427 | GNUNET_IDENTITY_read_public_key_from_buffer ( | ||
428 | const void *buffer, | ||
429 | size_t len, | ||
430 | struct GNUNET_IDENTITY_PublicKey *key, | ||
431 | size_t *read); | ||
432 | |||
433 | /** | ||
434 | * Get the compacted length of a #GNUNET_IDENTITY_PrivateKey. | ||
435 | * Compacted means that it returns the minimum number of bytes this | ||
436 | * key is long, as opposed to the union structure inside | ||
437 | * #GNUNET_IDENTITY_PrivateKey. | ||
438 | * Useful for compact serializations. | ||
439 | * | ||
440 | * @param key the key. | ||
441 | * @return -1 on error, else the compacted length of the key. | ||
442 | */ | ||
443 | ssize_t | ||
444 | GNUNET_IDENTITY_private_key_get_length ( | ||
445 | const struct GNUNET_IDENTITY_PrivateKey *key); | ||
446 | |||
447 | |||
448 | /** | ||
449 | * Writes a #GNUNET_IDENTITY_PublicKey to a compact buffer. | ||
450 | * The buffer requires space for at least the compacted length of | ||
451 | * a #GNUNET_IDENTITY_PublicKey in bytes. | ||
452 | * If the buffer is too small, the function returns -1 as error. | ||
453 | * If the key is not valid, it returns -2 as error. | ||
454 | * | ||
455 | * @param key the key | ||
456 | * @param buffer the buffer | ||
457 | * @param len the length of buffer | ||
458 | * @return -1 or -2 on error, else the amount of bytes written to the buffer | ||
459 | */ | ||
460 | ssize_t | ||
461 | GNUNET_IDENTITY_write_public_key_to_buffer (const struct | ||
462 | GNUNET_IDENTITY_PublicKey *key, | ||
463 | void*buffer, | ||
464 | size_t len); | ||
465 | |||
466 | |||
467 | /** | ||
468 | * Reads a #GNUNET_IDENTITY_PrivateKey from a compact buffer. | ||
469 | * The buffer has to contain at least the compacted length of | ||
470 | * a #GNUNET_IDENTITY_PrivateKey in bytes. | ||
471 | * If the buffer is too small, the function returns GNUNET_SYSERR as error. | ||
472 | * | ||
473 | * @param buffer the buffer | ||
474 | * @param len the length of buffer | ||
475 | * @param key the key | ||
476 | * @param the amount of bytes read from the buffer | ||
477 | * @return #GNUNET_SYSERR on error | ||
478 | */ | ||
479 | enum GNUNET_GenericReturnValue | ||
480 | GNUNET_IDENTITY_read_private_key_from_buffer ( | ||
481 | const void*buffer, | ||
482 | size_t len, | ||
483 | struct GNUNET_IDENTITY_PrivateKey *key, | ||
484 | size_t *read); | ||
485 | |||
486 | |||
487 | /** | ||
488 | * Writes a #GNUNET_IDENTITY_PrivateKey to a compact buffer. | ||
489 | * The buffer requires space for at least the compacted length of | ||
490 | * a #GNUNET_IDENTITY_PrivateKey in bytes. | ||
491 | * If the buffer is too small, the function returns -1 as error. | ||
492 | * If the key is not valid, it returns -2 as error. | ||
493 | * | ||
494 | * @param key the key | ||
495 | * @param buffer the buffer | ||
496 | * @param len the length of buffer | ||
497 | * @return -1 or -2 on error, else the amount of bytes written to the buffer | ||
498 | */ | ||
499 | ssize_t | ||
500 | GNUNET_IDENTITY_write_private_key_to_buffer ( | ||
501 | const struct GNUNET_IDENTITY_PrivateKey *key, | ||
502 | void*buffer, | ||
503 | size_t len); | ||
504 | |||
505 | |||
506 | /** | ||
507 | * Get the compacted length of a #GNUNET_IDENTITY_Signature. | ||
508 | * Compacted means that it returns the minimum number of bytes this | ||
509 | * signature is long, as opposed to the union structure inside | ||
510 | * #GNUNET_IDENTITY_Signature. | ||
511 | * Useful for compact serializations. | ||
512 | * | ||
513 | * @param sig the signature. | ||
514 | * @return -1 on error, else the compacted length of the signature. | ||
515 | */ | ||
516 | ssize_t | ||
517 | GNUNET_IDENTITY_signature_get_length ( | ||
518 | const struct GNUNET_IDENTITY_Signature *sig); | ||
519 | |||
520 | |||
521 | /** | ||
522 | * Get the compacted length of a signature by type. | ||
523 | * Compacted means that it returns the minimum number of bytes this | ||
524 | * signature is long, as opposed to the union structure inside | ||
525 | * #GNUNET_IDENTITY_Signature. | ||
526 | * Useful for compact serializations. | ||
527 | * | ||
528 | * @param sig the signature. | ||
529 | * @return -1 on error, else the compacted length of the signature. | ||
530 | */ | ||
531 | ssize_t | ||
532 | GNUNET_IDENTITY_signature_get_raw_length_by_type (uint32_t type); | ||
533 | |||
534 | |||
535 | /** | ||
536 | * Reads a #GNUNET_IDENTITY_Signature from a compact buffer. | ||
537 | * The buffer has to contain at least the compacted length of | ||
538 | * a #GNUNET_IDENTITY_Signature in bytes. | ||
539 | * If the buffer is too small, the function returns -1 as error. | ||
540 | * If the buffer does not contain a valid key, it returns -2 as error. | ||
541 | * | ||
542 | * @param sig the signature | ||
543 | * @param buffer the buffer | ||
544 | * @param len the length of buffer | ||
545 | * @return -1 or -2 on error, else the amount of bytes read from the buffer | ||
546 | */ | ||
547 | ssize_t | ||
548 | GNUNET_IDENTITY_read_signature_from_buffer ( | ||
549 | struct GNUNET_IDENTITY_Signature *sig, | ||
550 | const void*buffer, | ||
551 | size_t len); | ||
552 | |||
553 | |||
554 | /** | ||
555 | * Writes a #GNUNET_IDENTITY_Signature to a compact buffer. | ||
556 | * The buffer requires space for at least the compacted length of | ||
557 | * a #GNUNET_IDENTITY_Signature in bytes. | ||
558 | * If the buffer is too small, the function returns -1 as error. | ||
559 | * If the key is not valid, it returns -2 as error. | ||
560 | * | ||
561 | * @param sig the signature | ||
562 | * @param buffer the buffer | ||
563 | * @param len the length of buffer | ||
564 | * @return -1 or -2 on error, else the amount of bytes written to the buffer | ||
565 | */ | ||
566 | ssize_t | ||
567 | GNUNET_IDENTITY_write_signature_to_buffer ( | ||
568 | const struct GNUNET_IDENTITY_Signature *sig, | ||
569 | void*buffer, | ||
570 | size_t len); | ||
571 | |||
572 | |||
573 | /** | ||
574 | * @brief Sign a given block. | ||
575 | * | ||
576 | * The @a purpose data is the beginning of the data of which the signature is | ||
577 | * to be created. The `size` field in @a purpose must correctly indicate the | ||
578 | * number of bytes of the data structure, including its header. If possible, | ||
579 | * use #GNUNET_IDENTITY_sign() instead of this function. | ||
580 | * | ||
581 | * @param priv private key to use for the signing | ||
582 | * @param purpose what to sign (size, purpose) | ||
583 | * @param[out] sig where to write the signature | ||
584 | * @return #GNUNET_SYSERR on error, #GNUNET_OK on success | ||
585 | */ | ||
586 | enum GNUNET_GenericReturnValue | ||
587 | GNUNET_IDENTITY_sign_ ( | ||
588 | const struct GNUNET_IDENTITY_PrivateKey *priv, | ||
589 | const struct GNUNET_CRYPTO_EccSignaturePurpose *purpose, | ||
590 | struct GNUNET_IDENTITY_Signature *sig); | ||
591 | |||
592 | /** | ||
593 | * @brief Sign a given block. | ||
594 | * | ||
595 | * The @a purpose data is the beginning of the data of which the signature is | ||
596 | * to be created. The `size` field in @a purpose must correctly indicate the | ||
597 | * number of bytes of the data structure, including its header. | ||
598 | * The signature payload and length depends on the key type. | ||
599 | * | ||
600 | * @param priv private key to use for the signing | ||
601 | * @param purpose what to sign (size, purpose) | ||
602 | * @param[out] sig where to write the signature | ||
603 | * @return #GNUNET_SYSERR on error, #GNUNET_OK on success | ||
604 | */ | ||
605 | enum GNUNET_GenericReturnValue | ||
606 | GNUNET_IDENTITY_sign_raw_ ( | ||
607 | const struct GNUNET_IDENTITY_PrivateKey *priv, | ||
608 | const struct GNUNET_CRYPTO_EccSignaturePurpose *purpose, | ||
609 | unsigned char *sig); | ||
610 | |||
611 | |||
612 | /** | ||
613 | * @brief Sign a given block with #GNUNET_IDENTITY_PrivateKey. | ||
614 | * | ||
615 | * The @a ps data must be a fixed-size struct for which the signature is to be | ||
616 | * created. The `size` field in @a ps->purpose must correctly indicate the | ||
617 | * number of bytes of the data structure, including its header. | ||
618 | * | ||
619 | * @param priv private key to use for the signing | ||
620 | * @param ps packed struct with what to sign, MUST begin with a purpose | ||
621 | * @param[out] sig where to write the signature | ||
622 | */ | ||
623 | #define GNUNET_IDENTITY_sign(priv,ps,sig) do { \ | ||
624 | /* check size is set correctly */ \ | ||
625 | GNUNET_assert (ntohl ((ps)->purpose.size) == sizeof (*(ps))); \ | ||
626 | /* check 'ps' begins with the purpose */ \ | ||
627 | GNUNET_static_assert (((void*) (ps)) == \ | ||
628 | ((void*) &(ps)->purpose)); \ | ||
629 | GNUNET_assert (GNUNET_OK == \ | ||
630 | GNUNET_IDENTITY_sign_ (priv, \ | ||
631 | &(ps)->purpose, \ | ||
632 | sig)); \ | ||
633 | } while (0) | ||
634 | |||
635 | |||
636 | /** | ||
637 | * @brief Verify a given signature. | ||
638 | * | ||
639 | * The @a validate data is the beginning of the data of which the signature | ||
640 | * is to be verified. The `size` field in @a validate must correctly indicate | ||
641 | * the number of bytes of the data structure, including its header. If @a | ||
642 | * purpose does not match the purpose given in @a validate (the latter must be | ||
643 | * in big endian), signature verification fails. If possible, | ||
644 | * use #GNUNET_IDENTITY_signature_verify() instead of this function (only if @a validate | ||
645 | * is not fixed-size, you must use this function directly). | ||
646 | * | ||
647 | * @param purpose what is the purpose that the signature should have? | ||
648 | * @param validate block to validate (size, purpose, data) | ||
649 | * @param sig signature that is being validated | ||
650 | * @param pub public key of the signer | ||
651 | * @returns #GNUNET_OK if ok, #GNUNET_SYSERR if invalid | ||
652 | */ | ||
653 | enum GNUNET_GenericReturnValue | ||
654 | GNUNET_IDENTITY_signature_verify_ ( | ||
655 | uint32_t purpose, | ||
656 | const struct GNUNET_CRYPTO_EccSignaturePurpose *validate, | ||
657 | const struct GNUNET_IDENTITY_Signature *sig, | ||
658 | const struct GNUNET_IDENTITY_PublicKey *pub); | ||
659 | |||
660 | /** | ||
661 | * @brief Verify a given signature. | ||
662 | * | ||
663 | * The @a validate data is the beginning of the data of which the signature | ||
664 | * is to be verified. The `size` field in @a validate must correctly indicate | ||
665 | * the number of bytes of the data structure, including its header. If @a | ||
666 | * purpose does not match the purpose given in @a validate (the latter must be | ||
667 | * in big endian), signature verification fails. | ||
668 | * | ||
669 | * @param purpose what is the purpose that the signature should have? | ||
670 | * @param validate block to validate (size, purpose, data) | ||
671 | * @param sig signature that is being validated | ||
672 | * @param pub public key of the signer | ||
673 | * @returns #GNUNET_OK if ok, #GNUNET_SYSERR if invalid | ||
674 | */ | ||
675 | enum GNUNET_GenericReturnValue | ||
676 | GNUNET_IDENTITY_signature_verify_raw_ ( | ||
677 | uint32_t purpose, | ||
678 | const struct GNUNET_CRYPTO_EccSignaturePurpose *validate, | ||
679 | const unsigned char *sig, | ||
680 | const struct GNUNET_IDENTITY_PublicKey *pub); | ||
681 | |||
682 | |||
683 | /** | ||
684 | * @brief Verify a given signature with #GNUNET_IDENTITY_PublicKey. | ||
685 | * | ||
686 | * The @a ps data must be a fixed-size struct for which the signature is to be | ||
687 | * created. The `size` field in @a ps->purpose must correctly indicate the | ||
688 | * number of bytes of the data structure, including its header. | ||
689 | * | ||
690 | * @param purp purpose of the signature, must match 'ps->purpose.purpose' | ||
691 | * (except in host byte order) | ||
692 | * @param ps packed struct with what to sign, MUST begin with a purpose | ||
693 | * @param sig where to read the signature from | ||
694 | * @param pub public key to use for the verifying | ||
695 | */ | ||
696 | #define GNUNET_IDENTITY_signature_verify(purp,ps,sig,pub) ({ \ | ||
697 | /* check size is set correctly */ \ | ||
698 | GNUNET_assert (ntohl ((ps)->purpose.size) == sizeof (*(ps))); \ | ||
699 | /* check 'ps' begins with the purpose */ \ | ||
700 | GNUNET_static_assert (((void*) (ps)) == \ | ||
701 | ((void*) &(ps)->purpose)); \ | ||
702 | GNUNET_IDENTITY_signature_verify_ (purp, \ | ||
703 | &(ps)->purpose, \ | ||
704 | sig, \ | ||
705 | pub); \ | ||
706 | }) | ||
707 | |||
708 | |||
709 | /** | ||
710 | * Encrypt a block with #GNUNET_IDENTITY_PublicKey and derives a | ||
711 | * #GNUNET_CRYPTO_EcdhePublicKey which is required for decryption | ||
712 | * using ecdh to derive a symmetric key. | ||
713 | * | ||
714 | * @param block the block to encrypt | ||
715 | * @param size the size of the @a block | ||
716 | * @param pub public key to use for ecdh | ||
717 | * @param ecc where to write the ecc public key | ||
718 | * @param result the output parameter in which to store the encrypted result | ||
719 | * can be the same or overlap with @c block | ||
720 | * @returns the size of the encrypted block, -1 for errors. | ||
721 | * Due to the use of CFB and therefore an effective stream cipher, | ||
722 | * this size should be the same as @c len. | ||
723 | */ | ||
724 | ssize_t | ||
725 | GNUNET_IDENTITY_encrypt_old (const void *block, | ||
726 | size_t size, | ||
727 | const struct GNUNET_IDENTITY_PublicKey *pub, | ||
728 | struct GNUNET_CRYPTO_EcdhePublicKey *ecc, | ||
729 | void *result); | ||
730 | |||
731 | |||
732 | /** | ||
733 | * Decrypt a given block with #GNUNET_IDENTITY_PrivateKey and a given | ||
734 | * #GNUNET_CRYPTO_EcdhePublicKey using ecdh to derive a symmetric key. | ||
735 | * | ||
736 | * @param block the data to decrypt, encoded as returned by encrypt | ||
737 | * @param size the size of the @a block to decrypt | ||
738 | * @param priv private key to use for ecdh | ||
739 | * @param ecc the ecc public key | ||
740 | * @param result address to store the result at | ||
741 | * can be the same or overlap with @c block | ||
742 | * @return -1 on failure, size of decrypted block on success. | ||
743 | * Due to the use of CFB and therefore an effective stream cipher, | ||
744 | * this size should be the same as @c size. | ||
745 | */ | ||
746 | ssize_t | ||
747 | GNUNET_IDENTITY_decrypt_old ( | ||
748 | const void *block, | ||
749 | size_t size, | ||
750 | const struct GNUNET_IDENTITY_PrivateKey *priv, | ||
751 | const struct GNUNET_CRYPTO_EcdhePublicKey *ecc, | ||
752 | void *result); | ||
753 | |||
754 | #define GNUNET_IDENTITY_ENCRYPT_OVERHEAD_BYTES (crypto_secretbox_MACBYTES \ | ||
755 | + sizeof (struct \ | ||
756 | GNUNET_CRYPTO_FoKemC)) | ||
757 | |||
758 | /** | ||
759 | * Encrypt a block with #GNUNET_IDENTITY_PublicKey and derives a | ||
760 | * #GNUNET_CRYPTO_EcdhePublicKey which is required for decryption | ||
761 | * using ecdh to derive a symmetric key. | ||
762 | * | ||
763 | * Note that the result buffer for the ciphertext must be the length of | ||
764 | * the message to encrypt plus #GNUNET_IDENTITY_ENCRYPT_OVERHEAD_BYTES. | ||
765 | * | ||
766 | * @param block the block to encrypt | ||
767 | * @param size the size of the @a block | ||
768 | * @param pub public key to encrypt for | ||
769 | * @param result the output parameter in which to store the encrypted result | ||
770 | * can be the same or overlap with @c block | ||
771 | * @returns GNUNET_OK on success. | ||
772 | */ | ||
773 | enum GNUNET_GenericReturnValue | ||
774 | GNUNET_IDENTITY_encrypt (const void *block, | ||
775 | size_t size, | ||
776 | const struct GNUNET_IDENTITY_PublicKey *pub, | ||
777 | void *result, | ||
778 | size_t result_size); | ||
779 | |||
780 | |||
781 | /** | ||
782 | * Decrypt a given block with #GNUNET_IDENTITY_PrivateKey and a given | ||
783 | * #GNUNET_CRYPTO_EcdhePublicKey using ecdh to derive a symmetric key. | ||
784 | * | ||
785 | * @param block the data to decrypt, encoded as returned by encrypt | ||
786 | * @param size the size of the @a block to decrypt | ||
787 | * @param priv private key to use for ecdh | ||
788 | * @param result address to store the result at | ||
789 | * can be the same or overlap with @c block | ||
790 | * @returns GNUNET_OK on success. | ||
791 | */ | ||
792 | enum GNUNET_GenericReturnValue | ||
793 | GNUNET_IDENTITY_decrypt (const void *block, | ||
794 | size_t size, | ||
795 | const struct GNUNET_IDENTITY_PrivateKey *priv, | ||
796 | void *result, | ||
797 | size_t result_size); | ||
798 | |||
799 | |||
800 | /** | ||
801 | * Creates a (Base32) string representation of the public key. | ||
802 | * The resulting string encodes a compacted representation of the key. | ||
803 | * See also #GNUNET_IDENTITY_key_get_length. | ||
804 | * | ||
805 | * @param key the key. | ||
806 | * @return the string representation of the key, or NULL on error. | ||
807 | */ | ||
808 | char * | ||
809 | GNUNET_IDENTITY_public_key_to_string ( | ||
810 | const struct GNUNET_IDENTITY_PublicKey *key); | ||
811 | |||
812 | |||
813 | /** | ||
814 | * Creates a (Base32) string representation of the private key. | ||
815 | * The resulting string encodes a compacted representation of the key. | ||
816 | * See also #GNUNET_IDENTITY_key_get_length. | ||
817 | * | ||
818 | * @param key the key. | ||
819 | * @return the string representation of the key, or NULL on error. | ||
820 | */ | ||
821 | char * | ||
822 | GNUNET_IDENTITY_private_key_to_string ( | ||
823 | const struct GNUNET_IDENTITY_PrivateKey *key); | ||
824 | |||
825 | |||
826 | /** | ||
827 | * Parses a (Base32) string representation of the public key. | ||
828 | * See also #GNUNET_IDENTITY_public_key_to_string. | ||
829 | * | ||
830 | * @param str the encoded key. | ||
831 | * @param key where to write the key. | ||
832 | * @return GNUNET_SYSERR on error. | ||
833 | */ | ||
834 | enum GNUNET_GenericReturnValue | ||
835 | GNUNET_IDENTITY_public_key_from_string (const char*str, | ||
836 | struct GNUNET_IDENTITY_PublicKey *key); | ||
837 | |||
838 | |||
839 | /** | ||
840 | * Parses a (Base32) string representation of the private key. | ||
841 | * See also #GNUNET_IDENTITY_private_key_to_string. | ||
842 | * | ||
843 | * @param str the encoded key. | ||
844 | * @param key where to write the key. | ||
845 | * @return GNUNET_SYSERR on error. | ||
846 | */ | ||
847 | enum GNUNET_GenericReturnValue | ||
848 | GNUNET_IDENTITY_private_key_from_string (const char*str, | ||
849 | struct GNUNET_IDENTITY_PrivateKey *key); | ||
850 | |||
851 | |||
852 | /** | ||
853 | * Retrieves the public key representation of a private key. | ||
854 | * | ||
855 | * @param privkey the private key. | ||
856 | * @param key the public key result. | ||
857 | * @return GNUNET_SYSERR on error. | ||
858 | */ | ||
859 | enum GNUNET_GenericReturnValue | ||
860 | GNUNET_IDENTITY_key_get_public (const struct | ||
861 | GNUNET_IDENTITY_PrivateKey *privkey, | ||
862 | struct GNUNET_IDENTITY_PublicKey *key); | ||
863 | |||
864 | |||
865 | /* ************* convenience API to lookup an ego ***************** */ | 302 | /* ************* convenience API to lookup an ego ***************** */ |
866 | 303 | ||
867 | /** | 304 | /** |
@@ -914,7 +351,7 @@ GNUNET_IDENTITY_ego_lookup_cancel (struct GNUNET_IDENTITY_EgoLookup *el); | |||
914 | typedef void | 351 | typedef void |
915 | (*GNUNET_IDENTITY_EgoSuffixCallback) ( | 352 | (*GNUNET_IDENTITY_EgoSuffixCallback) ( |
916 | void *cls, | 353 | void *cls, |
917 | const struct GNUNET_IDENTITY_PrivateKey *priv, | 354 | const struct GNUNET_CRYPTO_PrivateKey *priv, |
918 | const char *ego_name); | 355 | const char *ego_name); |
919 | 356 | ||
920 | 357 | ||
diff --git a/src/include/gnunet_messenger_service.h b/src/include/gnunet_messenger_service.h index 5f4207d2f..90004826a 100644 --- a/src/include/gnunet_messenger_service.h +++ b/src/include/gnunet_messenger_service.h | |||
@@ -224,7 +224,7 @@ struct GNUNET_MESSENGER_MessageHeader | |||
224 | /** | 224 | /** |
225 | * The signature of the senders private key. | 225 | * The signature of the senders private key. |
226 | */ | 226 | */ |
227 | struct GNUNET_IDENTITY_Signature signature; | 227 | struct GNUNET_CRYPTO_Signature signature; |
228 | 228 | ||
229 | /** | 229 | /** |
230 | * The timestamp of the message. | 230 | * The timestamp of the message. |
@@ -258,7 +258,7 @@ struct GNUNET_MESSENGER_MessageInfo | |||
258 | /** | 258 | /** |
259 | * The senders key to verify its signatures. | 259 | * The senders key to verify its signatures. |
260 | */ | 260 | */ |
261 | struct GNUNET_IDENTITY_PublicKey host_key; | 261 | struct GNUNET_CRYPTO_PublicKey host_key; |
262 | 262 | ||
263 | /** | 263 | /** |
264 | * The version of GNUnet Messenger API. | 264 | * The version of GNUnet Messenger API. |
@@ -281,7 +281,7 @@ struct GNUNET_MESSENGER_MessageJoin | |||
281 | /** | 281 | /** |
282 | * The senders public key to verify its signatures. | 282 | * The senders public key to verify its signatures. |
283 | */ | 283 | */ |
284 | struct GNUNET_IDENTITY_PublicKey key; | 284 | struct GNUNET_CRYPTO_PublicKey key; |
285 | }; | 285 | }; |
286 | 286 | ||
287 | /** | 287 | /** |
@@ -319,7 +319,7 @@ struct GNUNET_MESSENGER_MessageKey | |||
319 | /** | 319 | /** |
320 | * The new public key which replaces the current senders public key. | 320 | * The new public key which replaces the current senders public key. |
321 | */ | 321 | */ |
322 | struct GNUNET_IDENTITY_PublicKey key; | 322 | struct GNUNET_CRYPTO_PublicKey key; |
323 | }; | 323 | }; |
324 | 324 | ||
325 | /** | 325 | /** |
@@ -671,7 +671,7 @@ GNUNET_MESSENGER_set_name (struct GNUNET_MESSENGER_Handle *handle, | |||
671 | * @param[in] handle Messenger handle to use | 671 | * @param[in] handle Messenger handle to use |
672 | * @return Used ego's public key or NULL | 672 | * @return Used ego's public key or NULL |
673 | */ | 673 | */ |
674 | const struct GNUNET_IDENTITY_PublicKey* | 674 | const struct GNUNET_CRYPTO_PublicKey* |
675 | GNUNET_MESSENGER_get_key (const struct GNUNET_MESSENGER_Handle *handle); | 675 | GNUNET_MESSENGER_get_key (const struct GNUNET_MESSENGER_Handle *handle); |
676 | 676 | ||
677 | /** | 677 | /** |
@@ -783,7 +783,7 @@ GNUNET_MESSENGER_contact_get_name (const struct GNUNET_MESSENGER_Contact *contac | |||
783 | * @param[in] contact Contact handle | 783 | * @param[in] contact Contact handle |
784 | * @return Public key of the ego used by <i>contact</i> or NULL | 784 | * @return Public key of the ego used by <i>contact</i> or NULL |
785 | */ | 785 | */ |
786 | const struct GNUNET_IDENTITY_PublicKey* | 786 | const struct GNUNET_CRYPTO_PublicKey* |
787 | GNUNET_MESSENGER_contact_get_key (const struct GNUNET_MESSENGER_Contact *contact); | 787 | GNUNET_MESSENGER_contact_get_key (const struct GNUNET_MESSENGER_Contact *contact); |
788 | 788 | ||
789 | /** | 789 | /** |
diff --git a/src/include/gnunet_namestore_plugin.h b/src/include/gnunet_namestore_plugin.h index f2bdf7cc6..d8dde5af5 100644 --- a/src/include/gnunet_namestore_plugin.h +++ b/src/include/gnunet_namestore_plugin.h | |||
@@ -62,7 +62,7 @@ typedef void | |||
62 | (*GNUNET_NAMESTORE_RecordIterator) (void *cls, | 62 | (*GNUNET_NAMESTORE_RecordIterator) (void *cls, |
63 | uint64_t serial, | 63 | uint64_t serial, |
64 | const struct | 64 | const struct |
65 | GNUNET_IDENTITY_PrivateKey *private_key, | 65 | GNUNET_CRYPTO_PrivateKey *private_key, |
66 | const char *label, | 66 | const char *label, |
67 | unsigned int rd_count, | 67 | unsigned int rd_count, |
68 | const struct GNUNET_GNSRECORD_Data *rd); | 68 | const struct GNUNET_GNSRECORD_Data *rd); |
@@ -91,7 +91,7 @@ struct GNUNET_NAMESTORE_PluginFunctions | |||
91 | */ | 91 | */ |
92 | enum GNUNET_GenericReturnValue | 92 | enum GNUNET_GenericReturnValue |
93 | (*store_records)(void *cls, | 93 | (*store_records)(void *cls, |
94 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 94 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
95 | const char *label, | 95 | const char *label, |
96 | unsigned int rd_count, | 96 | unsigned int rd_count, |
97 | const struct GNUNET_GNSRECORD_Data *rd); | 97 | const struct GNUNET_GNSRECORD_Data *rd); |
@@ -108,7 +108,7 @@ struct GNUNET_NAMESTORE_PluginFunctions | |||
108 | */ | 108 | */ |
109 | enum GNUNET_GenericReturnValue | 109 | enum GNUNET_GenericReturnValue |
110 | (*lookup_records)(void *cls, | 110 | (*lookup_records)(void *cls, |
111 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 111 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
112 | const char *label, | 112 | const char *label, |
113 | GNUNET_NAMESTORE_RecordIterator iter, | 113 | GNUNET_NAMESTORE_RecordIterator iter, |
114 | void *iter_cls); | 114 | void *iter_cls); |
@@ -130,7 +130,7 @@ struct GNUNET_NAMESTORE_PluginFunctions | |||
130 | */ | 130 | */ |
131 | enum GNUNET_GenericReturnValue | 131 | enum GNUNET_GenericReturnValue |
132 | (*iterate_records)(void *cls, | 132 | (*iterate_records)(void *cls, |
133 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 133 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
134 | uint64_t serial, | 134 | uint64_t serial, |
135 | uint64_t limit, | 135 | uint64_t limit, |
136 | GNUNET_NAMESTORE_RecordIterator iter, | 136 | GNUNET_NAMESTORE_RecordIterator iter, |
@@ -150,8 +150,8 @@ struct GNUNET_NAMESTORE_PluginFunctions | |||
150 | */ | 150 | */ |
151 | enum GNUNET_GenericReturnValue | 151 | enum GNUNET_GenericReturnValue |
152 | (*zone_to_name)(void *cls, | 152 | (*zone_to_name)(void *cls, |
153 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 153 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
154 | const struct GNUNET_IDENTITY_PublicKey *value_zone, | 154 | const struct GNUNET_CRYPTO_PublicKey *value_zone, |
155 | GNUNET_NAMESTORE_RecordIterator iter, | 155 | GNUNET_NAMESTORE_RecordIterator iter, |
156 | void *iter_cls); | 156 | void *iter_cls); |
157 | 157 | ||
@@ -201,7 +201,7 @@ struct GNUNET_NAMESTORE_PluginFunctions | |||
201 | */ | 201 | */ |
202 | enum GNUNET_GenericReturnValue | 202 | enum GNUNET_GenericReturnValue |
203 | (*edit_records)(void *cls, | 203 | (*edit_records)(void *cls, |
204 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 204 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
205 | const char *label, | 205 | const char *label, |
206 | GNUNET_NAMESTORE_RecordIterator iter, | 206 | GNUNET_NAMESTORE_RecordIterator iter, |
207 | void *iter_cls); | 207 | void *iter_cls); |
diff --git a/src/include/gnunet_namestore_service.h b/src/include/gnunet_namestore_service.h index b93a345c7..61691ff55 100644 --- a/src/include/gnunet_namestore_service.h +++ b/src/include/gnunet_namestore_service.h | |||
@@ -153,7 +153,7 @@ typedef void | |||
153 | */ | 153 | */ |
154 | struct GNUNET_NAMESTORE_QueueEntry * | 154 | struct GNUNET_NAMESTORE_QueueEntry * |
155 | GNUNET_NAMESTORE_records_store (struct GNUNET_NAMESTORE_Handle *h, | 155 | GNUNET_NAMESTORE_records_store (struct GNUNET_NAMESTORE_Handle *h, |
156 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 156 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
157 | const char *label, | 157 | const char *label, |
158 | unsigned int rd_count, | 158 | unsigned int rd_count, |
159 | const struct GNUNET_GNSRECORD_Data *rd, | 159 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -187,7 +187,7 @@ GNUNET_NAMESTORE_records_store (struct GNUNET_NAMESTORE_Handle *h, | |||
187 | struct GNUNET_NAMESTORE_QueueEntry * | 187 | struct GNUNET_NAMESTORE_QueueEntry * |
188 | GNUNET_NAMESTORE_records_store2 ( | 188 | GNUNET_NAMESTORE_records_store2 ( |
189 | struct GNUNET_NAMESTORE_Handle *h, | 189 | struct GNUNET_NAMESTORE_Handle *h, |
190 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 190 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
191 | unsigned int rd_set_count, | 191 | unsigned int rd_set_count, |
192 | const struct GNUNET_NAMESTORE_RecordInfo *record_info, | 192 | const struct GNUNET_NAMESTORE_RecordInfo *record_info, |
193 | unsigned int *rds_sent, | 193 | unsigned int *rds_sent, |
@@ -217,7 +217,7 @@ GNUNET_NAMESTORE_records_store2 ( | |||
217 | */ | 217 | */ |
218 | struct GNUNET_NAMESTORE_QueueEntry * | 218 | struct GNUNET_NAMESTORE_QueueEntry * |
219 | GNUNET_NAMESTORE_records_store_ (struct GNUNET_NAMESTORE_Handle *h, | 219 | GNUNET_NAMESTORE_records_store_ (struct GNUNET_NAMESTORE_Handle *h, |
220 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 220 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
221 | const char *label, | 221 | const char *label, |
222 | unsigned int rd_count, | 222 | unsigned int rd_count, |
223 | const struct GNUNET_GNSRECORD_Data *rd, | 223 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -240,7 +240,7 @@ GNUNET_NAMESTORE_records_store_ (struct GNUNET_NAMESTORE_Handle *h, | |||
240 | typedef void | 240 | typedef void |
241 | (*GNUNET_NAMESTORE_RecordMonitor) (void *cls, | 241 | (*GNUNET_NAMESTORE_RecordMonitor) (void *cls, |
242 | const struct | 242 | const struct |
243 | GNUNET_IDENTITY_PrivateKey *zone, | 243 | GNUNET_CRYPTO_PrivateKey *zone, |
244 | const char *label, | 244 | const char *label, |
245 | unsigned int rd_count, | 245 | unsigned int rd_count, |
246 | const struct GNUNET_GNSRECORD_Data *rd); | 246 | const struct GNUNET_GNSRECORD_Data *rd); |
@@ -260,7 +260,7 @@ typedef void | |||
260 | typedef void | 260 | typedef void |
261 | (*GNUNET_NAMESTORE_RecordSetMonitor) (void *cls, | 261 | (*GNUNET_NAMESTORE_RecordSetMonitor) (void *cls, |
262 | const struct | 262 | const struct |
263 | GNUNET_IDENTITY_PrivateKey *zone, | 263 | GNUNET_CRYPTO_PrivateKey *zone, |
264 | const char *label, | 264 | const char *label, |
265 | unsigned int rd_count, | 265 | unsigned int rd_count, |
266 | const struct GNUNET_GNSRECORD_Data *rd, | 266 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -284,7 +284,7 @@ typedef void | |||
284 | struct GNUNET_NAMESTORE_QueueEntry * | 284 | struct GNUNET_NAMESTORE_QueueEntry * |
285 | GNUNET_NAMESTORE_records_lookup (struct GNUNET_NAMESTORE_Handle *h, | 285 | GNUNET_NAMESTORE_records_lookup (struct GNUNET_NAMESTORE_Handle *h, |
286 | const struct | 286 | const struct |
287 | GNUNET_IDENTITY_PrivateKey *pkey, | 287 | GNUNET_CRYPTO_PrivateKey *pkey, |
288 | const char *label, | 288 | const char *label, |
289 | GNUNET_SCHEDULER_TaskCallback error_cb, | 289 | GNUNET_SCHEDULER_TaskCallback error_cb, |
290 | void *error_cb_cls, | 290 | void *error_cb_cls, |
@@ -309,7 +309,7 @@ GNUNET_NAMESTORE_records_lookup (struct GNUNET_NAMESTORE_Handle *h, | |||
309 | struct GNUNET_NAMESTORE_QueueEntry * | 309 | struct GNUNET_NAMESTORE_QueueEntry * |
310 | GNUNET_NAMESTORE_records_lookup2 (struct GNUNET_NAMESTORE_Handle *h, | 310 | GNUNET_NAMESTORE_records_lookup2 (struct GNUNET_NAMESTORE_Handle *h, |
311 | const struct | 311 | const struct |
312 | GNUNET_IDENTITY_PrivateKey *pkey, | 312 | GNUNET_CRYPTO_PrivateKey *pkey, |
313 | const char *label, | 313 | const char *label, |
314 | GNUNET_SCHEDULER_TaskCallback error_cb, | 314 | GNUNET_SCHEDULER_TaskCallback error_cb, |
315 | void *error_cb_cls, | 315 | void *error_cb_cls, |
@@ -338,9 +338,9 @@ GNUNET_NAMESTORE_records_lookup2 (struct GNUNET_NAMESTORE_Handle *h, | |||
338 | */ | 338 | */ |
339 | struct GNUNET_NAMESTORE_QueueEntry * | 339 | struct GNUNET_NAMESTORE_QueueEntry * |
340 | GNUNET_NAMESTORE_zone_to_name (struct GNUNET_NAMESTORE_Handle *h, | 340 | GNUNET_NAMESTORE_zone_to_name (struct GNUNET_NAMESTORE_Handle *h, |
341 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 341 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
342 | const struct | 342 | const struct |
343 | GNUNET_IDENTITY_PublicKey *value_zone, | 343 | GNUNET_CRYPTO_PublicKey *value_zone, |
344 | GNUNET_SCHEDULER_TaskCallback error_cb, | 344 | GNUNET_SCHEDULER_TaskCallback error_cb, |
345 | void *error_cb_cls, | 345 | void *error_cb_cls, |
346 | GNUNET_NAMESTORE_RecordMonitor proc, | 346 | GNUNET_NAMESTORE_RecordMonitor proc, |
@@ -390,7 +390,7 @@ GNUNET_NAMESTORE_cancel (struct GNUNET_NAMESTORE_QueueEntry *qe); | |||
390 | struct GNUNET_NAMESTORE_ZoneIterator * | 390 | struct GNUNET_NAMESTORE_ZoneIterator * |
391 | GNUNET_NAMESTORE_zone_iteration_start (struct GNUNET_NAMESTORE_Handle *h, | 391 | GNUNET_NAMESTORE_zone_iteration_start (struct GNUNET_NAMESTORE_Handle *h, |
392 | const struct | 392 | const struct |
393 | GNUNET_IDENTITY_PrivateKey *zone, | 393 | GNUNET_CRYPTO_PrivateKey *zone, |
394 | GNUNET_SCHEDULER_TaskCallback error_cb, | 394 | GNUNET_SCHEDULER_TaskCallback error_cb, |
395 | void *error_cb_cls, | 395 | void *error_cb_cls, |
396 | GNUNET_NAMESTORE_RecordMonitor proc, | 396 | GNUNET_NAMESTORE_RecordMonitor proc, |
@@ -427,7 +427,7 @@ GNUNET_NAMESTORE_zone_iteration_start (struct GNUNET_NAMESTORE_Handle *h, | |||
427 | struct GNUNET_NAMESTORE_ZoneIterator * | 427 | struct GNUNET_NAMESTORE_ZoneIterator * |
428 | GNUNET_NAMESTORE_zone_iteration_start2 (struct GNUNET_NAMESTORE_Handle *h, | 428 | GNUNET_NAMESTORE_zone_iteration_start2 (struct GNUNET_NAMESTORE_Handle *h, |
429 | const struct | 429 | const struct |
430 | GNUNET_IDENTITY_PrivateKey *zone, | 430 | GNUNET_CRYPTO_PrivateKey *zone, |
431 | GNUNET_SCHEDULER_TaskCallback error_cb, | 431 | GNUNET_SCHEDULER_TaskCallback error_cb, |
432 | void *error_cb_cls, | 432 | void *error_cb_cls, |
433 | GNUNET_NAMESTORE_RecordSetMonitor proc, | 433 | GNUNET_NAMESTORE_RecordSetMonitor proc, |
@@ -501,7 +501,7 @@ struct GNUNET_NAMESTORE_ZoneMonitor; | |||
501 | struct GNUNET_NAMESTORE_ZoneMonitor * | 501 | struct GNUNET_NAMESTORE_ZoneMonitor * |
502 | GNUNET_NAMESTORE_zone_monitor_start ( | 502 | GNUNET_NAMESTORE_zone_monitor_start ( |
503 | const struct GNUNET_CONFIGURATION_Handle *cfg, | 503 | const struct GNUNET_CONFIGURATION_Handle *cfg, |
504 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 504 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
505 | int iterate_first, | 505 | int iterate_first, |
506 | GNUNET_SCHEDULER_TaskCallback error_cb, | 506 | GNUNET_SCHEDULER_TaskCallback error_cb, |
507 | void *error_cb_cls, | 507 | void *error_cb_cls, |
@@ -541,7 +541,7 @@ GNUNET_NAMESTORE_zone_monitor_start ( | |||
541 | struct GNUNET_NAMESTORE_ZoneMonitor * | 541 | struct GNUNET_NAMESTORE_ZoneMonitor * |
542 | GNUNET_NAMESTORE_zone_monitor_start2 ( | 542 | GNUNET_NAMESTORE_zone_monitor_start2 ( |
543 | const struct GNUNET_CONFIGURATION_Handle *cfg, | 543 | const struct GNUNET_CONFIGURATION_Handle *cfg, |
544 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 544 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
545 | int iterate_first, | 545 | int iterate_first, |
546 | GNUNET_SCHEDULER_TaskCallback error_cb, | 546 | GNUNET_SCHEDULER_TaskCallback error_cb, |
547 | void *error_cb_cls, | 547 | void *error_cb_cls, |
@@ -637,7 +637,7 @@ GNUNET_NAMESTORE_transaction_commit (struct GNUNET_NAMESTORE_Handle *h, | |||
637 | struct GNUNET_NAMESTORE_QueueEntry * | 637 | struct GNUNET_NAMESTORE_QueueEntry * |
638 | GNUNET_NAMESTORE_records_edit ( | 638 | GNUNET_NAMESTORE_records_edit ( |
639 | struct GNUNET_NAMESTORE_Handle *h, | 639 | struct GNUNET_NAMESTORE_Handle *h, |
640 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 640 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
641 | const char *label, | 641 | const char *label, |
642 | GNUNET_SCHEDULER_TaskCallback error_cb, | 642 | GNUNET_SCHEDULER_TaskCallback error_cb, |
643 | void *error_cb_cls, | 643 | void *error_cb_cls, |
diff --git a/src/include/gnunet_reclaim_service.h b/src/include/gnunet_reclaim_service.h index 49a006e91..a8ab8776e 100644 --- a/src/include/gnunet_reclaim_service.h +++ b/src/include/gnunet_reclaim_service.h | |||
@@ -74,12 +74,12 @@ struct GNUNET_RECLAIM_Ticket | |||
74 | /** | 74 | /** |
75 | * The ticket issuer (= the user) | 75 | * The ticket issuer (= the user) |
76 | */ | 76 | */ |
77 | struct GNUNET_IDENTITY_PublicKey identity; | 77 | struct GNUNET_CRYPTO_PublicKey identity; |
78 | 78 | ||
79 | /** | 79 | /** |
80 | * The ticket audience (= relying party) | 80 | * The ticket audience (= relying party) |
81 | */ | 81 | */ |
82 | struct GNUNET_IDENTITY_PublicKey audience; | 82 | struct GNUNET_CRYPTO_PublicKey audience; |
83 | 83 | ||
84 | /** | 84 | /** |
85 | * The ticket random identifier | 85 | * The ticket random identifier |
@@ -134,7 +134,7 @@ typedef void (*GNUNET_RECLAIM_ContinuationWithStatus) (void *cls, | |||
134 | * @param attr The attribute | 134 | * @param attr The attribute |
135 | */ | 135 | */ |
136 | typedef void (*GNUNET_RECLAIM_AttributeResult) ( | 136 | typedef void (*GNUNET_RECLAIM_AttributeResult) ( |
137 | void *cls, const struct GNUNET_IDENTITY_PublicKey *identity, | 137 | void *cls, const struct GNUNET_CRYPTO_PublicKey *identity, |
138 | const struct GNUNET_RECLAIM_Attribute *attr); | 138 | const struct GNUNET_RECLAIM_Attribute *attr); |
139 | 139 | ||
140 | /** | 140 | /** |
@@ -146,7 +146,7 @@ typedef void (*GNUNET_RECLAIM_AttributeResult) ( | |||
146 | * @param presentation The presentation for the credential (may be NULL) | 146 | * @param presentation The presentation for the credential (may be NULL) |
147 | */ | 147 | */ |
148 | typedef void (*GNUNET_RECLAIM_AttributeTicketResult) ( | 148 | typedef void (*GNUNET_RECLAIM_AttributeTicketResult) ( |
149 | void *cls, const struct GNUNET_IDENTITY_PublicKey *identity, | 149 | void *cls, const struct GNUNET_CRYPTO_PublicKey *identity, |
150 | const struct GNUNET_RECLAIM_Attribute *attr, | 150 | const struct GNUNET_RECLAIM_Attribute *attr, |
151 | const struct GNUNET_RECLAIM_Presentation *presentation); | 151 | const struct GNUNET_RECLAIM_Presentation *presentation); |
152 | 152 | ||
@@ -160,7 +160,7 @@ typedef void (*GNUNET_RECLAIM_AttributeTicketResult) ( | |||
160 | * @param attributes the parsed attributes | 160 | * @param attributes the parsed attributes |
161 | */ | 161 | */ |
162 | typedef void (*GNUNET_RECLAIM_CredentialResult) ( | 162 | typedef void (*GNUNET_RECLAIM_CredentialResult) ( |
163 | void *cls, const struct GNUNET_IDENTITY_PublicKey *identity, | 163 | void *cls, const struct GNUNET_CRYPTO_PublicKey *identity, |
164 | const struct GNUNET_RECLAIM_Credential *credential); | 164 | const struct GNUNET_RECLAIM_Credential *credential); |
165 | 165 | ||
166 | 166 | ||
@@ -189,7 +189,7 @@ GNUNET_RECLAIM_connect (const struct GNUNET_CONFIGURATION_Handle *cfg); | |||
189 | struct GNUNET_RECLAIM_Operation * | 189 | struct GNUNET_RECLAIM_Operation * |
190 | GNUNET_RECLAIM_attribute_store ( | 190 | GNUNET_RECLAIM_attribute_store ( |
191 | struct GNUNET_RECLAIM_Handle *h, | 191 | struct GNUNET_RECLAIM_Handle *h, |
192 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 192 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
193 | const struct GNUNET_RECLAIM_Attribute *attr, | 193 | const struct GNUNET_RECLAIM_Attribute *attr, |
194 | const struct GNUNET_TIME_Relative *exp_interval, | 194 | const struct GNUNET_TIME_Relative *exp_interval, |
195 | GNUNET_RECLAIM_ContinuationWithStatus cont, void *cont_cls); | 195 | GNUNET_RECLAIM_ContinuationWithStatus cont, void *cont_cls); |
@@ -210,7 +210,7 @@ GNUNET_RECLAIM_attribute_store ( | |||
210 | struct GNUNET_RECLAIM_Operation * | 210 | struct GNUNET_RECLAIM_Operation * |
211 | GNUNET_RECLAIM_credential_store ( | 211 | GNUNET_RECLAIM_credential_store ( |
212 | struct GNUNET_RECLAIM_Handle *h, | 212 | struct GNUNET_RECLAIM_Handle *h, |
213 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 213 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
214 | const struct GNUNET_RECLAIM_Credential *credential, | 214 | const struct GNUNET_RECLAIM_Credential *credential, |
215 | const struct GNUNET_TIME_Relative *exp_interval, | 215 | const struct GNUNET_TIME_Relative *exp_interval, |
216 | GNUNET_RECLAIM_ContinuationWithStatus cont, | 216 | GNUNET_RECLAIM_ContinuationWithStatus cont, |
@@ -231,7 +231,7 @@ GNUNET_RECLAIM_credential_store ( | |||
231 | struct GNUNET_RECLAIM_Operation * | 231 | struct GNUNET_RECLAIM_Operation * |
232 | GNUNET_RECLAIM_attribute_delete ( | 232 | GNUNET_RECLAIM_attribute_delete ( |
233 | struct GNUNET_RECLAIM_Handle *h, | 233 | struct GNUNET_RECLAIM_Handle *h, |
234 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 234 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
235 | const struct GNUNET_RECLAIM_Attribute *attr, | 235 | const struct GNUNET_RECLAIM_Attribute *attr, |
236 | GNUNET_RECLAIM_ContinuationWithStatus cont, void *cont_cls); | 236 | GNUNET_RECLAIM_ContinuationWithStatus cont, void *cont_cls); |
237 | 237 | ||
@@ -249,7 +249,7 @@ GNUNET_RECLAIM_attribute_delete ( | |||
249 | struct GNUNET_RECLAIM_Operation * | 249 | struct GNUNET_RECLAIM_Operation * |
250 | GNUNET_RECLAIM_credential_delete ( | 250 | GNUNET_RECLAIM_credential_delete ( |
251 | struct GNUNET_RECLAIM_Handle *h, | 251 | struct GNUNET_RECLAIM_Handle *h, |
252 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 252 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
253 | const struct GNUNET_RECLAIM_Credential *cred, | 253 | const struct GNUNET_RECLAIM_Credential *cred, |
254 | GNUNET_RECLAIM_ContinuationWithStatus cont, | 254 | GNUNET_RECLAIM_ContinuationWithStatus cont, |
255 | void *cont_cls); | 255 | void *cont_cls); |
@@ -281,7 +281,7 @@ GNUNET_RECLAIM_credential_delete ( | |||
281 | struct GNUNET_RECLAIM_AttributeIterator * | 281 | struct GNUNET_RECLAIM_AttributeIterator * |
282 | GNUNET_RECLAIM_get_attributes_start ( | 282 | GNUNET_RECLAIM_get_attributes_start ( |
283 | struct GNUNET_RECLAIM_Handle *h, | 283 | struct GNUNET_RECLAIM_Handle *h, |
284 | const struct GNUNET_IDENTITY_PrivateKey *identity, | 284 | const struct GNUNET_CRYPTO_PrivateKey *identity, |
285 | GNUNET_SCHEDULER_TaskCallback error_cb, void *error_cb_cls, | 285 | GNUNET_SCHEDULER_TaskCallback error_cb, void *error_cb_cls, |
286 | GNUNET_RECLAIM_AttributeResult proc, void *proc_cls, | 286 | GNUNET_RECLAIM_AttributeResult proc, void *proc_cls, |
287 | GNUNET_SCHEDULER_TaskCallback finish_cb, void *finish_cb_cls); | 287 | GNUNET_SCHEDULER_TaskCallback finish_cb, void *finish_cb_cls); |
@@ -337,7 +337,7 @@ GNUNET_RECLAIM_get_attributes_stop ( | |||
337 | struct GNUNET_RECLAIM_CredentialIterator * | 337 | struct GNUNET_RECLAIM_CredentialIterator * |
338 | GNUNET_RECLAIM_get_credentials_start ( | 338 | GNUNET_RECLAIM_get_credentials_start ( |
339 | struct GNUNET_RECLAIM_Handle *h, | 339 | struct GNUNET_RECLAIM_Handle *h, |
340 | const struct GNUNET_IDENTITY_PrivateKey *identity, | 340 | const struct GNUNET_CRYPTO_PrivateKey *identity, |
341 | GNUNET_SCHEDULER_TaskCallback error_cb, | 341 | GNUNET_SCHEDULER_TaskCallback error_cb, |
342 | void *error_cb_cls, | 342 | void *error_cb_cls, |
343 | GNUNET_RECLAIM_CredentialResult proc, | 343 | GNUNET_RECLAIM_CredentialResult proc, |
@@ -385,8 +385,8 @@ GNUNET_RECLAIM_get_credentials_stop ( | |||
385 | struct GNUNET_RECLAIM_Operation * | 385 | struct GNUNET_RECLAIM_Operation * |
386 | GNUNET_RECLAIM_ticket_issue ( | 386 | GNUNET_RECLAIM_ticket_issue ( |
387 | struct GNUNET_RECLAIM_Handle *h, | 387 | struct GNUNET_RECLAIM_Handle *h, |
388 | const struct GNUNET_IDENTITY_PrivateKey *iss, | 388 | const struct GNUNET_CRYPTO_PrivateKey *iss, |
389 | const struct GNUNET_IDENTITY_PublicKey *rp, | 389 | const struct GNUNET_CRYPTO_PublicKey *rp, |
390 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 390 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
391 | GNUNET_RECLAIM_IssueTicketCallback cb, void *cb_cls); | 391 | GNUNET_RECLAIM_IssueTicketCallback cb, void *cb_cls); |
392 | 392 | ||
@@ -407,7 +407,7 @@ GNUNET_RECLAIM_ticket_issue ( | |||
407 | struct GNUNET_RECLAIM_Operation * | 407 | struct GNUNET_RECLAIM_Operation * |
408 | GNUNET_RECLAIM_ticket_revoke ( | 408 | GNUNET_RECLAIM_ticket_revoke ( |
409 | struct GNUNET_RECLAIM_Handle *h, | 409 | struct GNUNET_RECLAIM_Handle *h, |
410 | const struct GNUNET_IDENTITY_PrivateKey *identity, | 410 | const struct GNUNET_CRYPTO_PrivateKey *identity, |
411 | const struct GNUNET_RECLAIM_Ticket *ticket, | 411 | const struct GNUNET_RECLAIM_Ticket *ticket, |
412 | GNUNET_RECLAIM_ContinuationWithStatus cb, void *cb_cls); | 412 | GNUNET_RECLAIM_ContinuationWithStatus cb, void *cb_cls); |
413 | 413 | ||
@@ -427,7 +427,7 @@ GNUNET_RECLAIM_ticket_revoke ( | |||
427 | struct GNUNET_RECLAIM_Operation * | 427 | struct GNUNET_RECLAIM_Operation * |
428 | GNUNET_RECLAIM_ticket_consume ( | 428 | GNUNET_RECLAIM_ticket_consume ( |
429 | struct GNUNET_RECLAIM_Handle *h, | 429 | struct GNUNET_RECLAIM_Handle *h, |
430 | const struct GNUNET_IDENTITY_PrivateKey *identity, | 430 | const struct GNUNET_CRYPTO_PrivateKey *identity, |
431 | const struct GNUNET_RECLAIM_Ticket *ticket, | 431 | const struct GNUNET_RECLAIM_Ticket *ticket, |
432 | GNUNET_RECLAIM_AttributeTicketResult cb, void *cb_cls); | 432 | GNUNET_RECLAIM_AttributeTicketResult cb, void *cb_cls); |
433 | 433 | ||
@@ -452,7 +452,7 @@ GNUNET_RECLAIM_ticket_consume ( | |||
452 | struct GNUNET_RECLAIM_TicketIterator * | 452 | struct GNUNET_RECLAIM_TicketIterator * |
453 | GNUNET_RECLAIM_ticket_iteration_start ( | 453 | GNUNET_RECLAIM_ticket_iteration_start ( |
454 | struct GNUNET_RECLAIM_Handle *h, | 454 | struct GNUNET_RECLAIM_Handle *h, |
455 | const struct GNUNET_IDENTITY_PrivateKey *identity, | 455 | const struct GNUNET_CRYPTO_PrivateKey *identity, |
456 | GNUNET_SCHEDULER_TaskCallback error_cb, void *error_cb_cls, | 456 | GNUNET_SCHEDULER_TaskCallback error_cb, void *error_cb_cls, |
457 | GNUNET_RECLAIM_TicketCallback proc, void *proc_cls, | 457 | GNUNET_RECLAIM_TicketCallback proc, void *proc_cls, |
458 | GNUNET_SCHEDULER_TaskCallback finish_cb, void *finish_cb_cls); | 458 | GNUNET_SCHEDULER_TaskCallback finish_cb, void *finish_cb_cls); |
diff --git a/src/include/gnunet_revocation_service.h b/src/include/gnunet_revocation_service.h index 81a90189b..de5eedbb9 100644 --- a/src/include/gnunet_revocation_service.h +++ b/src/include/gnunet_revocation_service.h | |||
@@ -60,7 +60,7 @@ extern "C" | |||
60 | * Maximum length of a revocation | 60 | * Maximum length of a revocation |
61 | */ | 61 | */ |
62 | #define GNUNET_REVOCATION_MAX_PROOF_SIZE sizeof(struct GNUNET_REVOCATION_PowP) +\ | 62 | #define GNUNET_REVOCATION_MAX_PROOF_SIZE sizeof(struct GNUNET_REVOCATION_PowP) +\ |
63 | sizeof(struct GNUNET_IDENTITY_PublicKey) +\ | 63 | sizeof(struct GNUNET_CRYPTO_PublicKey) +\ |
64 | 1024 //FIXME max sig_len | 64 | 1024 //FIXME max sig_len |
65 | 65 | ||
66 | /** | 66 | /** |
@@ -152,7 +152,7 @@ typedef void (*GNUNET_REVOCATION_Callback) (void *cls, | |||
152 | */ | 152 | */ |
153 | struct GNUNET_REVOCATION_Query * | 153 | struct GNUNET_REVOCATION_Query * |
154 | GNUNET_REVOCATION_query (const struct GNUNET_CONFIGURATION_Handle *cfg, | 154 | GNUNET_REVOCATION_query (const struct GNUNET_CONFIGURATION_Handle *cfg, |
155 | const struct GNUNET_IDENTITY_PublicKey *key, | 155 | const struct GNUNET_CRYPTO_PublicKey *key, |
156 | GNUNET_REVOCATION_Callback func, void *func_cls); | 156 | GNUNET_REVOCATION_Callback func, void *func_cls); |
157 | 157 | ||
158 | 158 | ||
@@ -219,7 +219,7 @@ GNUNET_REVOCATION_check_pow (const struct GNUNET_REVOCATION_PowP *pow, | |||
219 | * @param pow the pow object to work with in the calculation. | 219 | * @param pow the pow object to work with in the calculation. |
220 | */ | 220 | */ |
221 | void | 221 | void |
222 | GNUNET_REVOCATION_pow_init (const struct GNUNET_IDENTITY_PrivateKey *key, | 222 | GNUNET_REVOCATION_pow_init (const struct GNUNET_CRYPTO_PrivateKey *key, |
223 | struct GNUNET_REVOCATION_PowP *pow); | 223 | struct GNUNET_REVOCATION_PowP *pow); |
224 | 224 | ||
225 | 225 | ||
diff --git a/src/json/Makefile.am b/src/json/Makefile.am index 7743411d4..c67824ee4 100644 --- a/src/json/Makefile.am +++ b/src/json/Makefile.am | |||
@@ -23,7 +23,7 @@ libgnunetjson_la_SOURCES = \ | |||
23 | json_mhd.c \ | 23 | json_mhd.c \ |
24 | json_pack.c | 24 | json_pack.c |
25 | libgnunetjson_la_LIBADD = \ | 25 | libgnunetjson_la_LIBADD = \ |
26 | $(top_builddir)/src/util/libgnunetutil.la \ | 26 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
27 | -ljansson \ | 27 | -ljansson \ |
28 | $(MHD_LIBS) \ | 28 | $(MHD_LIBS) \ |
29 | $(XLIB) \ | 29 | $(XLIB) \ |
@@ -41,7 +41,7 @@ test_json_SOURCES = \ | |||
41 | test_json_CFLAGS = $(MHD_CFLAGS) $(AM_CFLAGS) | 41 | test_json_CFLAGS = $(MHD_CFLAGS) $(AM_CFLAGS) |
42 | test_json_LDADD = \ | 42 | test_json_LDADD = \ |
43 | libgnunetjson.la \ | 43 | libgnunetjson.la \ |
44 | $(top_builddir)/src/util/libgnunetutil.la \ | 44 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
45 | -ljansson | 45 | -ljansson |
46 | 46 | ||
47 | 47 | ||
@@ -49,7 +49,7 @@ test_json_mhd_SOURCES = \ | |||
49 | test_json_mhd.c | 49 | test_json_mhd.c |
50 | test_json_mhd_LDADD = \ | 50 | test_json_mhd_LDADD = \ |
51 | libgnunetjson.la \ | 51 | libgnunetjson.la \ |
52 | $(top_builddir)/src/util/libgnunetutil.la \ | 52 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
53 | -ljansson \ | 53 | -ljansson \ |
54 | $(MHD_LIBS) \ | 54 | $(MHD_LIBS) \ |
55 | $(Z_LIBS) \ | 55 | $(Z_LIBS) \ |
diff --git a/src/lib/Makefile.am b/src/lib/Makefile.am new file mode 100644 index 000000000..0b9a75dad --- /dev/null +++ b/src/lib/Makefile.am | |||
@@ -0,0 +1,5 @@ | |||
1 | SUBDIRS = \ | ||
2 | util \ | ||
3 | hello \ | ||
4 | block \ | ||
5 | gnsrecord | ||
diff --git a/src/lib/block/Makefile.am b/src/lib/block/Makefile.am new file mode 100644 index 000000000..f9a5a0347 --- /dev/null +++ b/src/lib/block/Makefile.am | |||
@@ -0,0 +1,31 @@ | |||
1 | # This Makefile.am is in the public domain | ||
2 | AM_CPPFLAGS = -I$(top_srcdir)/src/include | ||
3 | |||
4 | plugindir = $(libdir)/gnunet | ||
5 | |||
6 | if USE_COVERAGE | ||
7 | AM_CFLAGS = --coverage | ||
8 | endif | ||
9 | |||
10 | lib_LTLIBRARIES = \ | ||
11 | libgnunetblock.la \ | ||
12 | libgnunetblockgroup.la | ||
13 | |||
14 | libgnunetblock_la_SOURCES = \ | ||
15 | block.c | ||
16 | libgnunetblock_la_LIBADD = \ | ||
17 | $(top_builddir)/src/lib/util/libgnunetutil.la | ||
18 | libgnunetblock_la_LDFLAGS = \ | ||
19 | $(GN_LIB_LDFLAGS) \ | ||
20 | $(GN_LIBINTL) \ | ||
21 | -version-info 0:0:0 | ||
22 | |||
23 | libgnunetblockgroup_la_SOURCES = \ | ||
24 | bg_bf.c | ||
25 | libgnunetblockgroup_la_LIBADD = \ | ||
26 | libgnunetblock.la \ | ||
27 | $(top_builddir)/src/lib/util/libgnunetutil.la | ||
28 | libgnunetblockgroup_la_LDFLAGS = \ | ||
29 | $(GN_LIB_LDFLAGS) \ | ||
30 | $(GN_LIBINTL) \ | ||
31 | -version-info 0:0:0 | ||
diff --git a/src/block/bg_bf.c b/src/lib/block/bg_bf.c index c8269498e..c8269498e 100644 --- a/src/block/bg_bf.c +++ b/src/lib/block/bg_bf.c | |||
diff --git a/src/block/block.c b/src/lib/block/block.c index 9edc7ce5e..9edc7ce5e 100644 --- a/src/block/block.c +++ b/src/lib/block/block.c | |||
diff --git a/src/block/meson.build b/src/lib/block/meson.build index b9bde48f6..b9bde48f6 100644 --- a/src/block/meson.build +++ b/src/lib/block/meson.build | |||
diff --git a/src/gnsrecord/.gitignore b/src/lib/gnsrecord/.gitignore index dca3bd309..dca3bd309 100644 --- a/src/gnsrecord/.gitignore +++ b/src/lib/gnsrecord/.gitignore | |||
diff --git a/src/gnsrecord/Makefile.am b/src/lib/gnsrecord/Makefile.am index 7ef7c327e..9872ff74b 100644 --- a/src/gnsrecord/Makefile.am +++ b/src/lib/gnsrecord/Makefile.am | |||
@@ -38,8 +38,7 @@ gnunet_gnsrecord_tvg_SOURCES = \ | |||
38 | gnunet-gnsrecord-tvg.c \ | 38 | gnunet-gnsrecord-tvg.c \ |
39 | gnsrecord_crypto.h | 39 | gnsrecord_crypto.h |
40 | gnunet_gnsrecord_tvg_LDADD = \ | 40 | gnunet_gnsrecord_tvg_LDADD = \ |
41 | $(top_builddir)/src/util/libgnunetutil.la \ | 41 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
42 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
43 | libgnunetgnsrecord.la \ | 42 | libgnunetgnsrecord.la \ |
44 | $(GN_LIBINTL) | 43 | $(GN_LIBINTL) |
45 | 44 | ||
@@ -50,8 +49,7 @@ libgnunetgnsrecord_la_SOURCES = \ | |||
50 | gnsrecord_crypto.c \ | 49 | gnsrecord_crypto.c \ |
51 | gnsrecord_misc.c | 50 | gnsrecord_misc.c |
52 | libgnunetgnsrecord_la_LIBADD = \ | 51 | libgnunetgnsrecord_la_LIBADD = \ |
53 | $(top_builddir)/src/util/libgnunetutil.la \ | 52 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
54 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
55 | $(LIBGCRYPT_LIBS) \ | 53 | $(LIBGCRYPT_LIBS) \ |
56 | -lsodium \ | 54 | -lsodium \ |
57 | $(GN_LIBINTL) | 55 | $(GN_LIBINTL) |
@@ -62,8 +60,7 @@ libgnunetgnsrecord_la_LDFLAGS = \ | |||
62 | libgnunetgnsrecordjson_la_SOURCES = \ | 60 | libgnunetgnsrecordjson_la_SOURCES = \ |
63 | json_gnsrecord.c | 61 | json_gnsrecord.c |
64 | libgnunetgnsrecordjson_la_LIBADD = \ | 62 | libgnunetgnsrecordjson_la_LIBADD = \ |
65 | $(top_builddir)/src/util/libgnunetutil.la \ | 63 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
66 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
67 | libgnunetgnsrecord.la \ | 64 | libgnunetgnsrecord.la \ |
68 | -ljansson \ | 65 | -ljansson \ |
69 | $(GN_LIBINTL) | 66 | $(GN_LIBINTL) |
@@ -71,19 +68,6 @@ libgnunetgnsrecordjson_la_LDFLAGS = \ | |||
71 | $(GN_LIB_LDFLAGS) \ | 68 | $(GN_LIB_LDFLAGS) \ |
72 | -version-info 0:0:0 | 69 | -version-info 0:0:0 |
73 | 70 | ||
74 | plugin_LTLIBRARIES = \ | ||
75 | libgnunet_plugin_gnsrecord_dns.la | ||
76 | |||
77 | |||
78 | libgnunet_plugin_gnsrecord_dns_la_SOURCES = \ | ||
79 | plugin_gnsrecord_dns.c | ||
80 | libgnunet_plugin_gnsrecord_dns_la_LIBADD = \ | ||
81 | $(top_builddir)/src/util/libgnunetutil.la \ | ||
82 | $(LTLIBINTL) | ||
83 | libgnunet_plugin_gnsrecord_dns_la_LDFLAGS = \ | ||
84 | $(GN_PLUGIN_LDFLAGS) | ||
85 | |||
86 | |||
87 | EXTRA_DIST = \ | 71 | EXTRA_DIST = \ |
88 | $(check_SCRIPTS) | 72 | $(check_SCRIPTS) |
89 | 73 | ||
@@ -91,9 +75,8 @@ test_gnsrecord_lsd0001testvectors_SOURCES = \ | |||
91 | test_gnsrecord_testvectors.c | 75 | test_gnsrecord_testvectors.c |
92 | test_gnsrecord_lsd0001testvectors_LDADD = \ | 76 | test_gnsrecord_lsd0001testvectors_LDADD = \ |
93 | $(top_builddir)/src/testing/libgnunettesting.la \ | 77 | $(top_builddir)/src/testing/libgnunettesting.la \ |
94 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
95 | libgnunetgnsrecord.la \ | 78 | libgnunetgnsrecord.la \ |
96 | $(top_builddir)/src/util/libgnunetutil.la | 79 | $(top_builddir)/src/lib/util/libgnunetutil.la |
97 | 80 | ||
98 | 81 | ||
99 | test_gnsrecord_serialization_SOURCES = \ | 82 | test_gnsrecord_serialization_SOURCES = \ |
@@ -101,29 +84,27 @@ test_gnsrecord_serialization_SOURCES = \ | |||
101 | test_gnsrecord_serialization_LDADD = \ | 84 | test_gnsrecord_serialization_LDADD = \ |
102 | $(top_builddir)/src/testing/libgnunettesting.la \ | 85 | $(top_builddir)/src/testing/libgnunettesting.la \ |
103 | libgnunetgnsrecord.la \ | 86 | libgnunetgnsrecord.la \ |
104 | $(top_builddir)/src/util/libgnunetutil.la | 87 | $(top_builddir)/src/lib/util/libgnunetutil.la |
105 | 88 | ||
106 | test_gnsrecord_block_expiration_SOURCES = \ | 89 | test_gnsrecord_block_expiration_SOURCES = \ |
107 | test_gnsrecord_block_expiration.c | 90 | test_gnsrecord_block_expiration.c |
108 | test_gnsrecord_block_expiration_LDADD = \ | 91 | test_gnsrecord_block_expiration_LDADD = \ |
109 | $(top_builddir)/src/testing/libgnunettesting.la \ | 92 | $(top_builddir)/src/testing/libgnunettesting.la \ |
110 | libgnunetgnsrecord.la \ | 93 | libgnunetgnsrecord.la \ |
111 | $(top_builddir)/src/util/libgnunetutil.la | 94 | $(top_builddir)/src/lib/util/libgnunetutil.la |
112 | 95 | ||
113 | 96 | ||
114 | test_gnsrecord_crypto_SOURCES = \ | 97 | test_gnsrecord_crypto_SOURCES = \ |
115 | test_gnsrecord_crypto.c | 98 | test_gnsrecord_crypto.c |
116 | test_gnsrecord_crypto_LDADD = \ | 99 | test_gnsrecord_crypto_LDADD = \ |
117 | $(top_builddir)/src/testing/libgnunettesting.la \ | 100 | $(top_builddir)/src/testing/libgnunettesting.la \ |
118 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
119 | libgnunetgnsrecord.la \ | 101 | libgnunetgnsrecord.la \ |
120 | $(top_builddir)/src/util/libgnunetutil.la | 102 | $(top_builddir)/src/lib/util/libgnunetutil.la |
121 | 103 | ||
122 | 104 | ||
123 | perf_gnsrecord_crypto_SOURCES = \ | 105 | perf_gnsrecord_crypto_SOURCES = \ |
124 | perf_gnsrecord_crypto.c | 106 | perf_gnsrecord_crypto.c |
125 | perf_gnsrecord_crypto_LDADD = \ | 107 | perf_gnsrecord_crypto_LDADD = \ |
126 | $(top_builddir)/src/testing/libgnunettesting.la \ | 108 | $(top_builddir)/src/testing/libgnunettesting.la \ |
127 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
128 | libgnunetgnsrecord.la \ | 109 | libgnunetgnsrecord.la \ |
129 | $(top_builddir)/src/util/libgnunetutil.la | 110 | $(top_builddir)/src/lib/util/libgnunetutil.la |
diff --git a/src/gnsrecord/gnsrecord.c b/src/lib/gnsrecord/gnsrecord.c index c71dc1708..c71dc1708 100644 --- a/src/gnsrecord/gnsrecord.c +++ b/src/lib/gnsrecord/gnsrecord.c | |||
diff --git a/src/gnsrecord/gnsrecord_crypto.c b/src/lib/gnsrecord/gnsrecord_crypto.c index 384336c97..de0fa3ffd 100644 --- a/src/gnsrecord/gnsrecord_crypto.c +++ b/src/lib/gnsrecord/gnsrecord_crypto.c | |||
@@ -273,15 +273,15 @@ block_sign_eddsa (const struct | |||
273 | 273 | ||
274 | enum GNUNET_GenericReturnValue | 274 | enum GNUNET_GenericReturnValue |
275 | GNUNET_GNSRECORD_block_sign (const struct | 275 | GNUNET_GNSRECORD_block_sign (const struct |
276 | GNUNET_IDENTITY_PrivateKey *key, | 276 | GNUNET_CRYPTO_PrivateKey *key, |
277 | const char *label, | 277 | const char *label, |
278 | struct GNUNET_GNSRECORD_Block *block) | 278 | struct GNUNET_GNSRECORD_Block *block) |
279 | { | 279 | { |
280 | struct GNUNET_IDENTITY_PublicKey pkey; | 280 | struct GNUNET_CRYPTO_PublicKey pkey; |
281 | enum GNUNET_GenericReturnValue res = GNUNET_SYSERR; | 281 | enum GNUNET_GenericReturnValue res = GNUNET_SYSERR; |
282 | char *norm_label; | 282 | char *norm_label; |
283 | 283 | ||
284 | GNUNET_IDENTITY_key_get_public (key, | 284 | GNUNET_CRYPTO_key_get_public (key, |
285 | &pkey); | 285 | &pkey); |
286 | norm_label = GNUNET_GNSRECORD_string_normalize (label); | 286 | norm_label = GNUNET_GNSRECORD_string_normalize (label); |
287 | 287 | ||
@@ -510,14 +510,14 @@ block_create_eddsa (const struct GNUNET_CRYPTO_EddsaPrivateKey *key, | |||
510 | 510 | ||
511 | ssize_t | 511 | ssize_t |
512 | GNUNET_GNSRECORD_block_calculate_size (const struct | 512 | GNUNET_GNSRECORD_block_calculate_size (const struct |
513 | GNUNET_IDENTITY_PrivateKey *key, | 513 | GNUNET_CRYPTO_PrivateKey *key, |
514 | const struct GNUNET_GNSRECORD_Data *rd, | 514 | const struct GNUNET_GNSRECORD_Data *rd, |
515 | unsigned int rd_count) | 515 | unsigned int rd_count) |
516 | { | 516 | { |
517 | struct GNUNET_IDENTITY_PublicKey pkey; | 517 | struct GNUNET_CRYPTO_PublicKey pkey; |
518 | ssize_t res = -1; | 518 | ssize_t res = -1; |
519 | 519 | ||
520 | GNUNET_IDENTITY_key_get_public (key, | 520 | GNUNET_CRYPTO_key_get_public (key, |
521 | &pkey); | 521 | &pkey); |
522 | switch (ntohl (key->type)) | 522 | switch (ntohl (key->type)) |
523 | { | 523 | { |
@@ -536,18 +536,18 @@ GNUNET_GNSRECORD_block_calculate_size (const struct | |||
536 | 536 | ||
537 | 537 | ||
538 | enum GNUNET_GenericReturnValue | 538 | enum GNUNET_GenericReturnValue |
539 | GNUNET_GNSRECORD_block_create (const struct GNUNET_IDENTITY_PrivateKey *key, | 539 | GNUNET_GNSRECORD_block_create (const struct GNUNET_CRYPTO_PrivateKey *key, |
540 | struct GNUNET_TIME_Absolute expire, | 540 | struct GNUNET_TIME_Absolute expire, |
541 | const char *label, | 541 | const char *label, |
542 | const struct GNUNET_GNSRECORD_Data *rd, | 542 | const struct GNUNET_GNSRECORD_Data *rd, |
543 | unsigned int rd_count, | 543 | unsigned int rd_count, |
544 | struct GNUNET_GNSRECORD_Block **result) | 544 | struct GNUNET_GNSRECORD_Block **result) |
545 | { | 545 | { |
546 | struct GNUNET_IDENTITY_PublicKey pkey; | 546 | struct GNUNET_CRYPTO_PublicKey pkey; |
547 | enum GNUNET_GenericReturnValue res = GNUNET_SYSERR; | 547 | enum GNUNET_GenericReturnValue res = GNUNET_SYSERR; |
548 | char *norm_label; | 548 | char *norm_label; |
549 | 549 | ||
550 | GNUNET_IDENTITY_key_get_public (key, | 550 | GNUNET_CRYPTO_key_get_public (key, |
551 | &pkey); | 551 | &pkey); |
552 | norm_label = GNUNET_GNSRECORD_string_normalize (label); | 552 | norm_label = GNUNET_GNSRECORD_string_normalize (label); |
553 | 553 | ||
@@ -599,7 +599,7 @@ struct KeyCacheLine | |||
599 | 599 | ||
600 | 600 | ||
601 | static enum GNUNET_GenericReturnValue | 601 | static enum GNUNET_GenericReturnValue |
602 | block_create2 (const struct GNUNET_IDENTITY_PrivateKey *pkey, | 602 | block_create2 (const struct GNUNET_CRYPTO_PrivateKey *pkey, |
603 | struct GNUNET_TIME_Absolute expire, | 603 | struct GNUNET_TIME_Absolute expire, |
604 | const char *label, | 604 | const char *label, |
605 | const struct GNUNET_GNSRECORD_Data *rd, | 605 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -614,7 +614,7 @@ block_create2 (const struct GNUNET_IDENTITY_PrivateKey *pkey, | |||
614 | 614 | ||
615 | norm_label = GNUNET_GNSRECORD_string_normalize (label); | 615 | norm_label = GNUNET_GNSRECORD_string_normalize (label); |
616 | 616 | ||
617 | if (GNUNET_IDENTITY_TYPE_ECDSA == ntohl (pkey->type)) | 617 | if (GNUNET_PUBLIC_KEY_TYPE_ECDSA == ntohl (pkey->type)) |
618 | { | 618 | { |
619 | key = &pkey->ecdsa_key; | 619 | key = &pkey->ecdsa_key; |
620 | #define CSIZE 64 | 620 | #define CSIZE 64 |
@@ -641,7 +641,7 @@ block_create2 (const struct GNUNET_IDENTITY_PrivateKey *pkey, | |||
641 | result, | 641 | result, |
642 | sign); | 642 | sign); |
643 | } | 643 | } |
644 | else if (GNUNET_IDENTITY_TYPE_EDDSA == ntohl (pkey->type)) | 644 | else if (GNUNET_PUBLIC_KEY_TYPE_EDDSA == ntohl (pkey->type)) |
645 | { | 645 | { |
646 | GNUNET_CRYPTO_eddsa_key_get_public (&pkey->eddsa_key, | 646 | GNUNET_CRYPTO_eddsa_key_get_public (&pkey->eddsa_key, |
647 | &edpubkey); | 647 | &edpubkey); |
@@ -661,7 +661,7 @@ block_create2 (const struct GNUNET_IDENTITY_PrivateKey *pkey, | |||
661 | 661 | ||
662 | enum GNUNET_GenericReturnValue | 662 | enum GNUNET_GenericReturnValue |
663 | GNUNET_GNSRECORD_block_create_unsigned (const struct | 663 | GNUNET_GNSRECORD_block_create_unsigned (const struct |
664 | GNUNET_IDENTITY_PrivateKey *pkey, | 664 | GNUNET_CRYPTO_PrivateKey *pkey, |
665 | struct GNUNET_TIME_Absolute expire, | 665 | struct GNUNET_TIME_Absolute expire, |
666 | const char *label, | 666 | const char *label, |
667 | const struct GNUNET_GNSRECORD_Data *rd, | 667 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -673,7 +673,7 @@ GNUNET_GNSRECORD_block_create_unsigned (const struct | |||
673 | 673 | ||
674 | 674 | ||
675 | enum GNUNET_GenericReturnValue | 675 | enum GNUNET_GenericReturnValue |
676 | GNUNET_GNSRECORD_block_create2 (const struct GNUNET_IDENTITY_PrivateKey *pkey, | 676 | GNUNET_GNSRECORD_block_create2 (const struct GNUNET_CRYPTO_PrivateKey *pkey, |
677 | struct GNUNET_TIME_Absolute expire, | 677 | struct GNUNET_TIME_Absolute expire, |
678 | const char *label, | 678 | const char *label, |
679 | const struct GNUNET_GNSRECORD_Data *rd, | 679 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -984,7 +984,7 @@ block_decrypt_eddsa (const struct GNUNET_GNSRECORD_Block *block, | |||
984 | enum GNUNET_GenericReturnValue | 984 | enum GNUNET_GenericReturnValue |
985 | GNUNET_GNSRECORD_block_decrypt (const struct GNUNET_GNSRECORD_Block *block, | 985 | GNUNET_GNSRECORD_block_decrypt (const struct GNUNET_GNSRECORD_Block *block, |
986 | const struct | 986 | const struct |
987 | GNUNET_IDENTITY_PublicKey *zone_key, | 987 | GNUNET_CRYPTO_PublicKey *zone_key, |
988 | const char *label, | 988 | const char *label, |
989 | GNUNET_GNSRECORD_RecordCallback proc, | 989 | GNUNET_GNSRECORD_RecordCallback proc, |
990 | void *proc_cls) | 990 | void *proc_cls) |
@@ -995,12 +995,12 @@ GNUNET_GNSRECORD_block_decrypt (const struct GNUNET_GNSRECORD_Block *block, | |||
995 | norm_label = GNUNET_GNSRECORD_string_normalize (label); | 995 | norm_label = GNUNET_GNSRECORD_string_normalize (label); |
996 | switch (ntohl (zone_key->type)) | 996 | switch (ntohl (zone_key->type)) |
997 | { | 997 | { |
998 | case GNUNET_IDENTITY_TYPE_ECDSA: | 998 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: |
999 | res = block_decrypt_ecdsa (block, | 999 | res = block_decrypt_ecdsa (block, |
1000 | &zone_key->ecdsa_key, norm_label, proc, | 1000 | &zone_key->ecdsa_key, norm_label, proc, |
1001 | proc_cls); | 1001 | proc_cls); |
1002 | break; | 1002 | break; |
1003 | case GNUNET_IDENTITY_TYPE_EDDSA: | 1003 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: |
1004 | res = block_decrypt_eddsa (block, | 1004 | res = block_decrypt_eddsa (block, |
1005 | &zone_key->eddsa_key, norm_label, proc, | 1005 | &zone_key->eddsa_key, norm_label, proc, |
1006 | proc_cls); | 1006 | proc_cls); |
@@ -1022,12 +1022,12 @@ GNUNET_GNSRECORD_block_decrypt (const struct GNUNET_GNSRECORD_Block *block, | |||
1022 | */ | 1022 | */ |
1023 | void | 1023 | void |
1024 | GNUNET_GNSRECORD_query_from_private_key (const struct | 1024 | GNUNET_GNSRECORD_query_from_private_key (const struct |
1025 | GNUNET_IDENTITY_PrivateKey *zone, | 1025 | GNUNET_CRYPTO_PrivateKey *zone, |
1026 | const char *label, | 1026 | const char *label, |
1027 | struct GNUNET_HashCode *query) | 1027 | struct GNUNET_HashCode *query) |
1028 | { | 1028 | { |
1029 | char *norm_label; | 1029 | char *norm_label; |
1030 | struct GNUNET_IDENTITY_PublicKey pub; | 1030 | struct GNUNET_CRYPTO_PublicKey pub; |
1031 | 1031 | ||
1032 | norm_label = GNUNET_GNSRECORD_string_normalize (label); | 1032 | norm_label = GNUNET_GNSRECORD_string_normalize (label); |
1033 | switch (ntohl (zone->type)) | 1033 | switch (ntohl (zone->type)) |
@@ -1035,7 +1035,7 @@ GNUNET_GNSRECORD_query_from_private_key (const struct | |||
1035 | case GNUNET_GNSRECORD_TYPE_PKEY: | 1035 | case GNUNET_GNSRECORD_TYPE_PKEY: |
1036 | case GNUNET_GNSRECORD_TYPE_EDKEY: | 1036 | case GNUNET_GNSRECORD_TYPE_EDKEY: |
1037 | 1037 | ||
1038 | GNUNET_IDENTITY_key_get_public (zone, | 1038 | GNUNET_CRYPTO_key_get_public (zone, |
1039 | &pub); | 1039 | &pub); |
1040 | GNUNET_GNSRECORD_query_from_public_key (&pub, | 1040 | GNUNET_GNSRECORD_query_from_public_key (&pub, |
1041 | norm_label, | 1041 | norm_label, |
@@ -1050,12 +1050,12 @@ GNUNET_GNSRECORD_query_from_private_key (const struct | |||
1050 | 1050 | ||
1051 | void | 1051 | void |
1052 | GNUNET_GNSRECORD_query_from_public_key (const struct | 1052 | GNUNET_GNSRECORD_query_from_public_key (const struct |
1053 | GNUNET_IDENTITY_PublicKey *pub, | 1053 | GNUNET_CRYPTO_PublicKey *pub, |
1054 | const char *label, | 1054 | const char *label, |
1055 | struct GNUNET_HashCode *query) | 1055 | struct GNUNET_HashCode *query) |
1056 | { | 1056 | { |
1057 | char *norm_label; | 1057 | char *norm_label; |
1058 | struct GNUNET_IDENTITY_PublicKey pd; | 1058 | struct GNUNET_CRYPTO_PublicKey pd; |
1059 | 1059 | ||
1060 | norm_label = GNUNET_GNSRECORD_string_normalize (label); | 1060 | norm_label = GNUNET_GNSRECORD_string_normalize (label); |
1061 | 1061 | ||
diff --git a/src/gnsrecord/gnsrecord_crypto.h b/src/lib/gnsrecord/gnsrecord_crypto.h index 4f2e4a5ca..4f2e4a5ca 100644 --- a/src/gnsrecord/gnsrecord_crypto.h +++ b/src/lib/gnsrecord/gnsrecord_crypto.h | |||
diff --git a/src/gnsrecord/gnsrecord_misc.c b/src/lib/gnsrecord/gnsrecord_misc.c index 931654c49..888295148 100644 --- a/src/gnsrecord/gnsrecord_misc.c +++ b/src/lib/gnsrecord/gnsrecord_misc.c | |||
@@ -61,14 +61,14 @@ GNUNET_GNSRECORD_label_check (const char*label, char **emsg) | |||
61 | 61 | ||
62 | 62 | ||
63 | const char * | 63 | const char * |
64 | GNUNET_GNSRECORD_z2s (const struct GNUNET_IDENTITY_PublicKey *z) | 64 | GNUNET_GNSRECORD_z2s (const struct GNUNET_CRYPTO_PublicKey *z) |
65 | { | 65 | { |
66 | static char buf[sizeof(struct GNUNET_IDENTITY_PublicKey) * 8]; | 66 | static char buf[sizeof(struct GNUNET_CRYPTO_PublicKey) * 8]; |
67 | char *end; | 67 | char *end; |
68 | 68 | ||
69 | end = GNUNET_STRINGS_data_to_string ((const unsigned char *) z, | 69 | end = GNUNET_STRINGS_data_to_string ((const unsigned char *) z, |
70 | sizeof(struct | 70 | sizeof(struct |
71 | GNUNET_IDENTITY_PublicKey), | 71 | GNUNET_CRYPTO_PublicKey), |
72 | buf, sizeof(buf)); | 72 | buf, sizeof(buf)); |
73 | if (NULL == end) | 73 | if (NULL == end) |
74 | { | 74 | { |
@@ -228,12 +228,12 @@ GNUNET_GNSRECORD_is_expired (const struct GNUNET_GNSRECORD_Data *rd) | |||
228 | * key in an encoding suitable for DNS labels. | 228 | * key in an encoding suitable for DNS labels. |
229 | */ | 229 | */ |
230 | const char * | 230 | const char * |
231 | GNUNET_GNSRECORD_pkey_to_zkey (const struct GNUNET_IDENTITY_PublicKey *pkey) | 231 | GNUNET_GNSRECORD_pkey_to_zkey (const struct GNUNET_CRYPTO_PublicKey *pkey) |
232 | { | 232 | { |
233 | static char ret[128]; | 233 | static char ret[128]; |
234 | char *pkeys; | 234 | char *pkeys; |
235 | 235 | ||
236 | pkeys = GNUNET_IDENTITY_public_key_to_string (pkey); | 236 | pkeys = GNUNET_CRYPTO_public_key_to_string (pkey); |
237 | GNUNET_snprintf (ret, | 237 | GNUNET_snprintf (ret, |
238 | sizeof(ret), | 238 | sizeof(ret), |
239 | "%s", | 239 | "%s", |
@@ -254,10 +254,10 @@ GNUNET_GNSRECORD_pkey_to_zkey (const struct GNUNET_IDENTITY_PublicKey *pkey) | |||
254 | */ | 254 | */ |
255 | int | 255 | int |
256 | GNUNET_GNSRECORD_zkey_to_pkey (const char *zkey, | 256 | GNUNET_GNSRECORD_zkey_to_pkey (const char *zkey, |
257 | struct GNUNET_IDENTITY_PublicKey *pkey) | 257 | struct GNUNET_CRYPTO_PublicKey *pkey) |
258 | { | 258 | { |
259 | if (GNUNET_OK != | 259 | if (GNUNET_OK != |
260 | GNUNET_IDENTITY_public_key_from_string (zkey, | 260 | GNUNET_CRYPTO_public_key_from_string (zkey, |
261 | pkey)) | 261 | pkey)) |
262 | return GNUNET_SYSERR; | 262 | return GNUNET_SYSERR; |
263 | return GNUNET_OK; | 263 | return GNUNET_OK; |
@@ -268,7 +268,7 @@ enum GNUNET_GenericReturnValue | |||
268 | GNUNET_GNSRECORD_identity_from_data (const char *data, | 268 | GNUNET_GNSRECORD_identity_from_data (const char *data, |
269 | size_t data_size, | 269 | size_t data_size, |
270 | uint32_t type, | 270 | uint32_t type, |
271 | struct GNUNET_IDENTITY_PublicKey *key) | 271 | struct GNUNET_CRYPTO_PublicKey *key) |
272 | { | 272 | { |
273 | if (GNUNET_NO == GNUNET_GNSRECORD_is_zonekey_type (type)) | 273 | if (GNUNET_NO == GNUNET_GNSRECORD_is_zonekey_type (type)) |
274 | return GNUNET_SYSERR; | 274 | return GNUNET_SYSERR; |
@@ -295,14 +295,14 @@ GNUNET_GNSRECORD_identity_from_data (const char *data, | |||
295 | 295 | ||
296 | enum GNUNET_GenericReturnValue | 296 | enum GNUNET_GenericReturnValue |
297 | GNUNET_GNSRECORD_data_from_identity (const struct | 297 | GNUNET_GNSRECORD_data_from_identity (const struct |
298 | GNUNET_IDENTITY_PublicKey *key, | 298 | GNUNET_CRYPTO_PublicKey *key, |
299 | char **data, | 299 | char **data, |
300 | size_t *data_size, | 300 | size_t *data_size, |
301 | uint32_t *type) | 301 | uint32_t *type) |
302 | { | 302 | { |
303 | char *tmp; | 303 | char *tmp; |
304 | *type = ntohl (key->type); | 304 | *type = ntohl (key->type); |
305 | *data_size = GNUNET_IDENTITY_public_key_get_length (key) - sizeof (key->type); | 305 | *data_size = GNUNET_CRYPTO_public_key_get_length (key) - sizeof (key->type); |
306 | if (0 == *data_size) | 306 | if (0 == *data_size) |
307 | return GNUNET_SYSERR; | 307 | return GNUNET_SYSERR; |
308 | tmp = GNUNET_malloc (*data_size); | 308 | tmp = GNUNET_malloc (*data_size); |
@@ -378,7 +378,7 @@ GNUNET_GNSRECORD_query_from_block (const struct GNUNET_GNSRECORD_Block *block, | |||
378 | 378 | ||
379 | enum GNUNET_GenericReturnValue | 379 | enum GNUNET_GenericReturnValue |
380 | GNUNET_GNSRECORD_record_to_identity_key (const struct GNUNET_GNSRECORD_Data *rd, | 380 | GNUNET_GNSRECORD_record_to_identity_key (const struct GNUNET_GNSRECORD_Data *rd, |
381 | struct GNUNET_IDENTITY_PublicKey *key) | 381 | struct GNUNET_CRYPTO_PublicKey *key) |
382 | { | 382 | { |
383 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 383 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
384 | "Got record of type %u\n", | 384 | "Got record of type %u\n", |
diff --git a/src/gnsrecord/gnsrecord_serialization.c b/src/lib/gnsrecord/gnsrecord_serialization.c index 053edfd33..053edfd33 100644 --- a/src/gnsrecord/gnsrecord_serialization.c +++ b/src/lib/gnsrecord/gnsrecord_serialization.c | |||
diff --git a/src/gnsrecord/gnunet-gnsrecord-tvg.c b/src/lib/gnsrecord/gnunet-gnsrecord-tvg.c index eebbedf21..746e95c32 100644 --- a/src/gnsrecord/gnunet-gnsrecord-tvg.c +++ b/src/lib/gnsrecord/gnunet-gnsrecord-tvg.c | |||
@@ -146,10 +146,10 @@ run_pkey (struct GNUNET_GNSRECORD_Data *rd, int rd_count, const char *label) | |||
146 | struct GNUNET_TIME_Absolute expire; | 146 | struct GNUNET_TIME_Absolute expire; |
147 | struct GNUNET_GNSRECORD_Block *rrblock; | 147 | struct GNUNET_GNSRECORD_Block *rrblock; |
148 | char *bdata; | 148 | char *bdata; |
149 | struct GNUNET_IDENTITY_PrivateKey id_priv; | 149 | struct GNUNET_CRYPTO_PrivateKey id_priv; |
150 | struct GNUNET_IDENTITY_PublicKey id_pub; | 150 | struct GNUNET_CRYPTO_PublicKey id_pub; |
151 | struct GNUNET_IDENTITY_PrivateKey pkey_data_p; | 151 | struct GNUNET_CRYPTO_PrivateKey pkey_data_p; |
152 | struct GNUNET_IDENTITY_PublicKey pkey_data; | 152 | struct GNUNET_CRYPTO_PublicKey pkey_data; |
153 | struct GNUNET_HashCode query; | 153 | struct GNUNET_HashCode query; |
154 | char *rdata; | 154 | char *rdata; |
155 | char *conv_lbl; | 155 | char *conv_lbl; |
@@ -164,17 +164,17 @@ run_pkey (struct GNUNET_GNSRECORD_Data *rd, int rd_count, const char *label) | |||
164 | (char*) &id_priv.ecdsa_key, | 164 | (char*) &id_priv.ecdsa_key, |
165 | sizeof (id_priv.ecdsa_key), 1); | 165 | sizeof (id_priv.ecdsa_key), 1); |
166 | 166 | ||
167 | GNUNET_IDENTITY_key_get_public (&id_priv, | 167 | GNUNET_CRYPTO_key_get_public (&id_priv, |
168 | &id_pub); | 168 | &id_pub); |
169 | printf ("Zone private key (d, big-endian):\n"); | 169 | printf ("Zone private key (d, big-endian):\n"); |
170 | print_bytes_ (&id_priv.ecdsa_key, | 170 | print_bytes_ (&id_priv.ecdsa_key, |
171 | sizeof (struct GNUNET_CRYPTO_EcdsaPrivateKey), 8, 1); | 171 | sizeof (struct GNUNET_CRYPTO_EcdsaPrivateKey), 8, 1); |
172 | printf ("\n"); | 172 | printf ("\n"); |
173 | printf ("Zone identifier (ztype|zkey):\n"); | 173 | printf ("Zone identifier (ztype|zkey):\n"); |
174 | GNUNET_assert (0 < GNUNET_IDENTITY_public_key_get_length (&id_pub)); | 174 | GNUNET_assert (0 < GNUNET_CRYPTO_public_key_get_length (&id_pub)); |
175 | print_bytes (&id_pub, GNUNET_IDENTITY_public_key_get_length (&id_pub), 8); | 175 | print_bytes (&id_pub, GNUNET_CRYPTO_public_key_get_length (&id_pub), 8); |
176 | GNUNET_STRINGS_data_to_string (&id_pub, | 176 | GNUNET_STRINGS_data_to_string (&id_pub, |
177 | GNUNET_IDENTITY_public_key_get_length ( | 177 | GNUNET_CRYPTO_public_key_get_length ( |
178 | &id_pub), | 178 | &id_pub), |
179 | ztld, | 179 | ztld, |
180 | sizeof (ztld)); | 180 | sizeof (ztld)); |
@@ -185,7 +185,7 @@ run_pkey (struct GNUNET_GNSRECORD_Data *rd, int rd_count, const char *label) | |||
185 | 185 | ||
186 | pkey_data_p.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); | 186 | pkey_data_p.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
187 | GNUNET_CRYPTO_ecdsa_key_create (&pkey_data_p.ecdsa_key); | 187 | GNUNET_CRYPTO_ecdsa_key_create (&pkey_data_p.ecdsa_key); |
188 | GNUNET_IDENTITY_key_get_public (&pkey_data_p, | 188 | GNUNET_CRYPTO_key_get_public (&pkey_data_p, |
189 | &pkey_data); | 189 | &pkey_data); |
190 | conv_lbl = GNUNET_GNSRECORD_string_normalize (label); | 190 | conv_lbl = GNUNET_GNSRECORD_string_normalize (label); |
191 | printf ("Label:\n"); | 191 | printf ("Label:\n"); |
@@ -285,10 +285,10 @@ run_edkey (struct GNUNET_GNSRECORD_Data *rd, int rd_count, const char*label) | |||
285 | struct GNUNET_TIME_Absolute expire; | 285 | struct GNUNET_TIME_Absolute expire; |
286 | struct GNUNET_GNSRECORD_Block *rrblock; | 286 | struct GNUNET_GNSRECORD_Block *rrblock; |
287 | char *bdata; | 287 | char *bdata; |
288 | struct GNUNET_IDENTITY_PrivateKey id_priv; | 288 | struct GNUNET_CRYPTO_PrivateKey id_priv; |
289 | struct GNUNET_IDENTITY_PublicKey id_pub; | 289 | struct GNUNET_CRYPTO_PublicKey id_pub; |
290 | struct GNUNET_IDENTITY_PrivateKey pkey_data_p; | 290 | struct GNUNET_CRYPTO_PrivateKey pkey_data_p; |
291 | struct GNUNET_IDENTITY_PublicKey pkey_data; | 291 | struct GNUNET_CRYPTO_PublicKey pkey_data; |
292 | struct GNUNET_HashCode query; | 292 | struct GNUNET_HashCode query; |
293 | char *rdata; | 293 | char *rdata; |
294 | char *conv_lbl; | 294 | char *conv_lbl; |
@@ -300,15 +300,15 @@ run_edkey (struct GNUNET_GNSRECORD_Data *rd, int rd_count, const char*label) | |||
300 | 300 | ||
301 | id_priv.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); | 301 | id_priv.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
302 | GNUNET_CRYPTO_ecdsa_key_create (&id_priv.ecdsa_key); | 302 | GNUNET_CRYPTO_ecdsa_key_create (&id_priv.ecdsa_key); |
303 | GNUNET_IDENTITY_key_get_public (&id_priv, | 303 | GNUNET_CRYPTO_key_get_public (&id_priv, |
304 | &id_pub); | 304 | &id_pub); |
305 | 305 | ||
306 | id_priv.type = htonl (GNUNET_IDENTITY_TYPE_EDDSA); | 306 | id_priv.type = htonl (GNUNET_PUBLIC_KEY_TYPE_EDDSA); |
307 | GNUNET_CRYPTO_eddsa_key_create (&id_priv.eddsa_key); | 307 | GNUNET_CRYPTO_eddsa_key_create (&id_priv.eddsa_key); |
308 | parsehex (d_edkey, | 308 | parsehex (d_edkey, |
309 | (char*) &id_priv.eddsa_key, | 309 | (char*) &id_priv.eddsa_key, |
310 | sizeof (id_priv.eddsa_key), 0); | 310 | sizeof (id_priv.eddsa_key), 0); |
311 | GNUNET_IDENTITY_key_get_public (&id_priv, | 311 | GNUNET_CRYPTO_key_get_public (&id_priv, |
312 | &id_pub); | 312 | &id_pub); |
313 | fprintf (stdout, | 313 | fprintf (stdout, |
314 | "Zone private key (d):\n"); | 314 | "Zone private key (d):\n"); |
@@ -316,10 +316,10 @@ run_edkey (struct GNUNET_GNSRECORD_Data *rd, int rd_count, const char*label) | |||
316 | GNUNET_CRYPTO_EddsaPrivateKey), 8); | 316 | GNUNET_CRYPTO_EddsaPrivateKey), 8); |
317 | printf ("\n"); | 317 | printf ("\n"); |
318 | printf ("Zone identifier (ztype|zkey):\n"); | 318 | printf ("Zone identifier (ztype|zkey):\n"); |
319 | GNUNET_assert (0 < GNUNET_IDENTITY_public_key_get_length (&id_pub)); | 319 | GNUNET_assert (0 < GNUNET_CRYPTO_public_key_get_length (&id_pub)); |
320 | print_bytes (&id_pub, GNUNET_IDENTITY_public_key_get_length (&id_pub), 8); | 320 | print_bytes (&id_pub, GNUNET_CRYPTO_public_key_get_length (&id_pub), 8); |
321 | GNUNET_STRINGS_data_to_string (&id_pub, | 321 | GNUNET_STRINGS_data_to_string (&id_pub, |
322 | GNUNET_IDENTITY_public_key_get_length ( | 322 | GNUNET_CRYPTO_public_key_get_length ( |
323 | &id_pub), | 323 | &id_pub), |
324 | ztld, | 324 | ztld, |
325 | sizeof (ztld)); | 325 | sizeof (ztld)); |
@@ -330,7 +330,7 @@ run_edkey (struct GNUNET_GNSRECORD_Data *rd, int rd_count, const char*label) | |||
330 | 330 | ||
331 | pkey_data_p.type = htonl (GNUNET_GNSRECORD_TYPE_EDKEY); | 331 | pkey_data_p.type = htonl (GNUNET_GNSRECORD_TYPE_EDKEY); |
332 | GNUNET_CRYPTO_eddsa_key_create (&pkey_data_p.eddsa_key); | 332 | GNUNET_CRYPTO_eddsa_key_create (&pkey_data_p.eddsa_key); |
333 | GNUNET_IDENTITY_key_get_public (&pkey_data_p, | 333 | GNUNET_CRYPTO_key_get_public (&pkey_data_p, |
334 | &pkey_data); | 334 | &pkey_data); |
335 | conv_lbl = GNUNET_GNSRECORD_string_normalize (label); | 335 | conv_lbl = GNUNET_GNSRECORD_string_normalize (label); |
336 | printf ("Label:\n"); | 336 | printf ("Label:\n"); |
diff --git a/src/gnsrecord/json_gnsrecord.c b/src/lib/gnsrecord/json_gnsrecord.c index cc96e42fb..cc96e42fb 100644 --- a/src/gnsrecord/json_gnsrecord.c +++ b/src/lib/gnsrecord/json_gnsrecord.c | |||
diff --git a/src/gnsrecord/meson.build b/src/lib/gnsrecord/meson.build index 11b355796..11b355796 100644 --- a/src/gnsrecord/meson.build +++ b/src/lib/gnsrecord/meson.build | |||
diff --git a/src/gnsrecord/perf_gnsrecord_crypto.c b/src/lib/gnsrecord/perf_gnsrecord_crypto.c index 6b5f84235..1f9a3d4d4 100644 --- a/src/gnsrecord/perf_gnsrecord_crypto.c +++ b/src/lib/gnsrecord/perf_gnsrecord_crypto.c | |||
@@ -73,7 +73,7 @@ run (void *cls, | |||
73 | struct GNUNET_GNSRECORD_Data *s_rd; | 73 | struct GNUNET_GNSRECORD_Data *s_rd; |
74 | const char *s_name; | 74 | const char *s_name; |
75 | struct GNUNET_TIME_Absolute start_time; | 75 | struct GNUNET_TIME_Absolute start_time; |
76 | struct GNUNET_IDENTITY_PrivateKey privkey; | 76 | struct GNUNET_CRYPTO_PrivateKey privkey; |
77 | struct GNUNET_TIME_Absolute expire; | 77 | struct GNUNET_TIME_Absolute expire; |
78 | 78 | ||
79 | (void) cls; | 79 | (void) cls; |
diff --git a/src/gnsrecord/test_gnsrecord_block_expiration.c b/src/lib/gnsrecord/test_gnsrecord_block_expiration.c index 3ef02e631..3ef02e631 100644 --- a/src/gnsrecord/test_gnsrecord_block_expiration.c +++ b/src/lib/gnsrecord/test_gnsrecord_block_expiration.c | |||
diff --git a/src/gnsrecord/test_gnsrecord_crypto.c b/src/lib/gnsrecord/test_gnsrecord_crypto.c index 92a7a9f1f..ed5394e60 100644 --- a/src/gnsrecord/test_gnsrecord_crypto.c +++ b/src/lib/gnsrecord/test_gnsrecord_crypto.c | |||
@@ -93,10 +93,10 @@ rd_decrypt_cb (void *cls, | |||
93 | 93 | ||
94 | 94 | ||
95 | static void | 95 | static void |
96 | test_with_type (struct GNUNET_IDENTITY_PrivateKey *privkey) | 96 | test_with_type (struct GNUNET_CRYPTO_PrivateKey *privkey) |
97 | { | 97 | { |
98 | struct GNUNET_GNSRECORD_Block *block; | 98 | struct GNUNET_GNSRECORD_Block *block; |
99 | struct GNUNET_IDENTITY_PublicKey pubkey; | 99 | struct GNUNET_CRYPTO_PublicKey pubkey; |
100 | struct GNUNET_HashCode query_pub; | 100 | struct GNUNET_HashCode query_pub; |
101 | struct GNUNET_HashCode query_priv; | 101 | struct GNUNET_HashCode query_priv; |
102 | struct GNUNET_HashCode query_block; | 102 | struct GNUNET_HashCode query_block; |
@@ -104,7 +104,7 @@ test_with_type (struct GNUNET_IDENTITY_PrivateKey *privkey) | |||
104 | 104 | ||
105 | 105 | ||
106 | /* get public key */ | 106 | /* get public key */ |
107 | GNUNET_IDENTITY_key_get_public (privkey, | 107 | GNUNET_CRYPTO_key_get_public (privkey, |
108 | &pubkey); | 108 | &pubkey); |
109 | 109 | ||
110 | /* test query derivation */ | 110 | /* test query derivation */ |
@@ -155,8 +155,8 @@ run (void *cls, | |||
155 | const char *cfgfile, | 155 | const char *cfgfile, |
156 | const struct GNUNET_CONFIGURATION_Handle *cfg) | 156 | const struct GNUNET_CONFIGURATION_Handle *cfg) |
157 | { | 157 | { |
158 | struct GNUNET_IDENTITY_PrivateKey privkey; | 158 | struct GNUNET_CRYPTO_PrivateKey privkey; |
159 | struct GNUNET_IDENTITY_PrivateKey privkey_ed; | 159 | struct GNUNET_CRYPTO_PrivateKey privkey_ed; |
160 | struct GNUNET_TIME_Absolute start; | 160 | struct GNUNET_TIME_Absolute start; |
161 | struct GNUNET_TIME_Absolute end; | 161 | struct GNUNET_TIME_Absolute end; |
162 | 162 | ||
diff --git a/src/gnsrecord/test_gnsrecord_serialization.c b/src/lib/gnsrecord/test_gnsrecord_serialization.c index b06b3a0fe..b06b3a0fe 100644 --- a/src/gnsrecord/test_gnsrecord_serialization.c +++ b/src/lib/gnsrecord/test_gnsrecord_serialization.c | |||
diff --git a/src/gnsrecord/test_gnsrecord_testvectors.c b/src/lib/gnsrecord/test_gnsrecord_testvectors.c index e0d959f0e..04fd7f8bd 100644 --- a/src/gnsrecord/test_gnsrecord_testvectors.c +++ b/src/lib/gnsrecord/test_gnsrecord_testvectors.c | |||
@@ -528,7 +528,7 @@ res_checker (void *cls, | |||
528 | enum GNUNET_GenericReturnValue | 528 | enum GNUNET_GenericReturnValue |
529 | check_derivations_edkey (const char*label, | 529 | check_derivations_edkey (const char*label, |
530 | struct GNUNET_TIME_Absolute expire, | 530 | struct GNUNET_TIME_Absolute expire, |
531 | struct GNUNET_IDENTITY_PublicKey *pub, | 531 | struct GNUNET_CRYPTO_PublicKey *pub, |
532 | struct GnsTv *tv) | 532 | struct GnsTv *tv) |
533 | { | 533 | { |
534 | unsigned char nonce[crypto_secretbox_NONCEBYTES]; | 534 | unsigned char nonce[crypto_secretbox_NONCEBYTES]; |
@@ -566,7 +566,7 @@ check_derivations_edkey (const char*label, | |||
566 | enum GNUNET_GenericReturnValue | 566 | enum GNUNET_GenericReturnValue |
567 | check_derivations_pkey (const char*label, | 567 | check_derivations_pkey (const char*label, |
568 | struct GNUNET_TIME_Absolute expire, | 568 | struct GNUNET_TIME_Absolute expire, |
569 | struct GNUNET_IDENTITY_PublicKey *pub, | 569 | struct GNUNET_CRYPTO_PublicKey *pub, |
570 | struct GnsTv *tv) | 570 | struct GnsTv *tv) |
571 | { | 571 | { |
572 | unsigned char ctr[GNUNET_CRYPTO_AES_KEY_LENGTH / 2]; | 572 | unsigned char ctr[GNUNET_CRYPTO_AES_KEY_LENGTH / 2]; |
@@ -602,9 +602,9 @@ check_derivations_pkey (const char*label, | |||
602 | int | 602 | int |
603 | main () | 603 | main () |
604 | { | 604 | { |
605 | struct GNUNET_IDENTITY_PrivateKey priv; | 605 | struct GNUNET_CRYPTO_PrivateKey priv; |
606 | struct GNUNET_IDENTITY_PublicKey pub; | 606 | struct GNUNET_CRYPTO_PublicKey pub; |
607 | struct GNUNET_IDENTITY_PublicKey pub_parsed; | 607 | struct GNUNET_CRYPTO_PublicKey pub_parsed; |
608 | struct GNUNET_GNSRECORD_Block *rrblock; | 608 | struct GNUNET_GNSRECORD_Block *rrblock; |
609 | struct GNUNET_HashCode query; | 609 | struct GNUNET_HashCode query; |
610 | struct GNUNET_HashCode expected_query; | 610 | struct GNUNET_HashCode expected_query; |
@@ -624,8 +624,8 @@ main () | |||
624 | parsehex (tvs[i].d,(char*) &priv.ecdsa_key, sizeof (priv.ecdsa_key), | 624 | parsehex (tvs[i].d,(char*) &priv.ecdsa_key, sizeof (priv.ecdsa_key), |
625 | (GNUNET_GNSRECORD_TYPE_PKEY == ntohl (pub_parsed.type)) ? 1 : 0); | 625 | (GNUNET_GNSRECORD_TYPE_PKEY == ntohl (pub_parsed.type)) ? 1 : 0); |
626 | priv.type = pub_parsed.type; | 626 | priv.type = pub_parsed.type; |
627 | GNUNET_IDENTITY_key_get_public (&priv, &pub); | 627 | GNUNET_CRYPTO_key_get_public (&priv, &pub); |
628 | if (0 != memcmp (&pub, &pub_parsed, GNUNET_IDENTITY_public_key_get_length ( | 628 | if (0 != memcmp (&pub, &pub_parsed, GNUNET_CRYPTO_public_key_get_length ( |
629 | &pub))) | 629 | &pub))) |
630 | { | 630 | { |
631 | printf ("Wrong pubkey.\n"); | 631 | printf ("Wrong pubkey.\n"); |
@@ -635,7 +635,7 @@ main () | |||
635 | break; | 635 | break; |
636 | } | 636 | } |
637 | GNUNET_STRINGS_data_to_string (&pub, | 637 | GNUNET_STRINGS_data_to_string (&pub, |
638 | GNUNET_IDENTITY_public_key_get_length ( | 638 | GNUNET_CRYPTO_public_key_get_length ( |
639 | &pub), | 639 | &pub), |
640 | ztld, | 640 | ztld, |
641 | sizeof (ztld)); | 641 | sizeof (ztld)); |
diff --git a/src/hello/.gitignore b/src/lib/hello/.gitignore index d175d148e..d175d148e 100644 --- a/src/hello/.gitignore +++ b/src/lib/hello/.gitignore | |||
diff --git a/src/hello/Makefile.am b/src/lib/hello/Makefile.am index 5b923055b..4435dba42 100644 --- a/src/hello/Makefile.am +++ b/src/lib/hello/Makefile.am | |||
@@ -13,15 +13,12 @@ libgnunethello_la_SOURCES = \ | |||
13 | hello-ng.c \ | 13 | hello-ng.c \ |
14 | hello-uri.c | 14 | hello-uri.c |
15 | libgnunethello_la_LIBADD = \ | 15 | libgnunethello_la_LIBADD = \ |
16 | $(top_builddir)/src/util/libgnunetutil.la $(XLIB) \ | 16 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIB) \ |
17 | $(LTLIBINTL) | 17 | $(LTLIBINTL) |
18 | libgnunethello_la_LDFLAGS = \ | 18 | libgnunethello_la_LDFLAGS = \ |
19 | $(GN_LIB_LDFLAGS) \ | 19 | $(GN_LIB_LDFLAGS) \ |
20 | -version-info 1:0:1 | 20 | -version-info 1:0:1 |
21 | 21 | ||
22 | #noinst_PROGRAMS = \ | ||
23 | # gnunet-hello | ||
24 | |||
25 | check_PROGRAMS = \ | 22 | check_PROGRAMS = \ |
26 | test_hello \ | 23 | test_hello \ |
27 | test_hello-uri \ | 24 | test_hello-uri \ |
@@ -37,19 +34,19 @@ test_hello_SOURCES = \ | |||
37 | test_hello.c | 34 | test_hello.c |
38 | test_hello_LDADD = \ | 35 | test_hello_LDADD = \ |
39 | libgnunethello.la \ | 36 | libgnunethello.la \ |
40 | $(top_builddir)/src/util/libgnunetutil.la | 37 | $(top_builddir)/src/lib/util/libgnunetutil.la |
41 | 38 | ||
42 | test_hello_ng_SOURCES = \ | 39 | test_hello_ng_SOURCES = \ |
43 | test_hello-ng.c | 40 | test_hello-ng.c |
44 | test_hello_ng_LDADD = \ | 41 | test_hello_ng_LDADD = \ |
45 | libgnunethello.la \ | 42 | libgnunethello.la \ |
46 | $(top_builddir)/src/util/libgnunetutil.la | 43 | $(top_builddir)/src/lib/util/libgnunetutil.la |
47 | 44 | ||
48 | test_hello_uri_SOURCES = \ | 45 | test_hello_uri_SOURCES = \ |
49 | test_hello-uri.c | 46 | test_hello-uri.c |
50 | test_hello_uri_LDADD = \ | 47 | test_hello_uri_LDADD = \ |
51 | libgnunethello.la \ | 48 | libgnunethello.la \ |
52 | $(top_builddir)/src/util/libgnunetutil.la \ | 49 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
53 | -lgcrypt | 50 | -lgcrypt |
54 | 51 | ||
55 | 52 | ||
@@ -57,13 +54,4 @@ test_friend_hello_SOURCES = \ | |||
57 | test_friend_hello.c | 54 | test_friend_hello.c |
58 | test_friend_hello_LDADD = \ | 55 | test_friend_hello_LDADD = \ |
59 | libgnunethello.la \ | 56 | libgnunethello.la \ |
60 | $(top_builddir)/src/util/libgnunetutil.la | 57 | $(top_builddir)/src/lib/util/libgnunetutil.la |
61 | |||
62 | # Not TNG ready | ||
63 | #gnunet_hello_SOURCES = \ | ||
64 | # gnunet-hello.c | ||
65 | #gnunet_hello_LDADD = \ | ||
66 | # libgnunethello.la \ | ||
67 | # $(top_builddir)/src/util/libgnunetutil.la | ||
68 | #gnunet_hello_LDFLAGS = \ | ||
69 | # $(GN_LIBINTL) | ||
diff --git a/src/hello/address.c b/src/lib/hello/address.c index 6a1b68029..6a1b68029 100644 --- a/src/hello/address.c +++ b/src/lib/hello/address.c | |||
diff --git a/src/hello/hello-ng.c b/src/lib/hello/hello-ng.c index 9c255b361..9c255b361 100644 --- a/src/hello/hello-ng.c +++ b/src/lib/hello/hello-ng.c | |||
diff --git a/src/hello/hello-uri.c b/src/lib/hello/hello-uri.c index 83d43fa2b..83d43fa2b 100644 --- a/src/hello/hello-uri.c +++ b/src/lib/hello/hello-uri.c | |||
diff --git a/src/hello/hello.c b/src/lib/hello/hello.c index 45d27c5d4..45d27c5d4 100644 --- a/src/hello/hello.c +++ b/src/lib/hello/hello.c | |||
diff --git a/src/hello/meson.build b/src/lib/hello/meson.build index c0df8b76c..c0df8b76c 100644 --- a/src/hello/meson.build +++ b/src/lib/hello/meson.build | |||
diff --git a/src/hello/test_friend_hello.c b/src/lib/hello/test_friend_hello.c index 1b092c0b8..1b092c0b8 100644 --- a/src/hello/test_friend_hello.c +++ b/src/lib/hello/test_friend_hello.c | |||
diff --git a/src/hello/test_hello-ng.c b/src/lib/hello/test_hello-ng.c index ef84e2425..ef84e2425 100644 --- a/src/hello/test_hello-ng.c +++ b/src/lib/hello/test_hello-ng.c | |||
diff --git a/src/hello/test_hello-uri.c b/src/lib/hello/test_hello-uri.c index 1062f446b..1062f446b 100644 --- a/src/hello/test_hello-uri.c +++ b/src/lib/hello/test_hello-uri.c | |||
diff --git a/src/hello/test_hello.c b/src/lib/hello/test_hello.c index 8631d2af3..8631d2af3 100644 --- a/src/hello/test_hello.c +++ b/src/lib/hello/test_hello.c | |||
diff --git a/src/util/.gitignore b/src/lib/util/.gitignore index 6151c4f7a..bfb947ae6 100644 --- a/src/util/.gitignore +++ b/src/lib/util/.gitignore | |||
@@ -1,13 +1,4 @@ | |||
1 | test_common_logging_dummy | 1 | test_common_logging_dummy |
2 | gnunet-config | ||
3 | gnunet-config-diff | ||
4 | gnunet-crypto-tvg | ||
5 | gnunet-ecc | ||
6 | gnunet-qr | ||
7 | gnunet-resolver | ||
8 | gnunet-scrypt | ||
9 | gnunet-service-resolver | ||
10 | gnunet-uri | ||
11 | test_bio | 2 | test_bio |
12 | test_client.nc | 3 | test_client.nc |
13 | test_client_unix.nc | 4 | test_client_unix.nc |
@@ -54,7 +45,6 @@ test_os_start_process | |||
54 | test_peer | 45 | test_peer |
55 | test_plugin | 46 | test_plugin |
56 | test_program | 47 | test_program |
57 | test_resolver_api.nc | ||
58 | test_scheduler | 48 | test_scheduler |
59 | test_scheduler_delay | 49 | test_scheduler_delay |
60 | test_server.nc | 50 | test_server.nc |
@@ -79,11 +69,9 @@ test_hexcoder | |||
79 | test_regex | 69 | test_regex |
80 | test_tun | 70 | test_tun |
81 | test_uri | 71 | test_uri |
82 | gnunet-timeout | ||
83 | python27_location | 72 | python27_location |
84 | perf_malloc | 73 | perf_malloc |
85 | perf_mq | 74 | perf_mq |
86 | perf_scheduler | 75 | perf_scheduler |
87 | gnunet-base32 | ||
88 | test_crypto_cs | 76 | test_crypto_cs |
89 | test_crypto_ecc | 77 | test_crypto_ecc |
diff --git a/src/util/Makefile.am b/src/lib/util/Makefile.am index 3647ca08e..5d92dfdd6 100644 --- a/src/util/Makefile.am +++ b/src/lib/util/Makefile.am | |||
@@ -28,11 +28,6 @@ endif | |||
28 | DLOG = crypto_ecc_dlog.c | 28 | DLOG = crypto_ecc_dlog.c |
29 | DLOG_TEST = test_crypto_ecc_dlog | 29 | DLOG_TEST = test_crypto_ecc_dlog |
30 | 30 | ||
31 | gnunet_config_diff_SOURCES = \ | ||
32 | gnunet-config-diff.c | ||
33 | gnunet_config_diff_LDADD = \ | ||
34 | libgnunetutil.la | ||
35 | |||
36 | test_common_logging_dummy_SOURCES = \ | 31 | test_common_logging_dummy_SOURCES = \ |
37 | test_common_logging_dummy.c | 32 | test_common_logging_dummy.c |
38 | test_common_logging_dummy_LDADD = \ | 33 | test_common_logging_dummy_LDADD = \ |
@@ -73,6 +68,7 @@ libgnunetutil_la_SOURCES = \ | |||
73 | crypto_kdf.c \ | 68 | crypto_kdf.c \ |
74 | crypto_mpi.c \ | 69 | crypto_mpi.c \ |
75 | crypto_paillier.c \ | 70 | crypto_paillier.c \ |
71 | crypto_pkey.c \ | ||
76 | crypto_pow.c \ | 72 | crypto_pow.c \ |
77 | crypto_random.c \ | 73 | crypto_random.c \ |
78 | crypto_rsa.c \ | 74 | crypto_rsa.c \ |
@@ -152,103 +148,16 @@ libgnunetutil_la_LDFLAGS = \ | |||
152 | $(GN_LIB_LDFLAGS) \ | 148 | $(GN_LIB_LDFLAGS) \ |
153 | -version-info 15:0:0 | 149 | -version-info 15:0:0 |
154 | 150 | ||
155 | GNUNET_ECC = gnunet-ecc | ||
156 | GNUNET_SCRYPT = gnunet-scrypt | ||
157 | |||
158 | lib_LTLIBRARIES = libgnunetutil.la | 151 | lib_LTLIBRARIES = libgnunetutil.la |
159 | 152 | ||
160 | libexec_PROGRAMS = \ | ||
161 | gnunet-service-resolver \ | ||
162 | gnunet-timeout | ||
163 | |||
164 | bin_PROGRAMS = \ | ||
165 | gnunet-base32 \ | ||
166 | gnunet-config \ | ||
167 | gnunet-resolver \ | ||
168 | $(GNUNET_ECC) \ | ||
169 | $(GNUNET_SCRYPT) \ | ||
170 | gnunet-uri | ||
171 | if HAVE_ZBAR | ||
172 | bin_PROGRAMS += gnunet-qr | ||
173 | endif | ||
174 | |||
175 | noinst_PROGRAMS = \ | 153 | noinst_PROGRAMS = \ |
176 | gnunet-config-diff \ | 154 | test_common_logging_dummy |
177 | test_common_logging_dummy \ | ||
178 | gnunet-crypto-tvg | ||
179 | 155 | ||
180 | if ENABLE_TEST_RUN | 156 | if ENABLE_TEST_RUN |
181 | AM_TESTS_ENVIRONMENT=export GNUNET_PREFIX=$${GNUNET_PREFIX:-@libdir@};export PATH=$${GNUNET_PREFIX:-@prefix@}/bin:$$PATH;unset XDG_DATA_HOME;unset XDG_CONFIG_HOME; | 157 | AM_TESTS_ENVIRONMENT=export GNUNET_PREFIX=$${GNUNET_PREFIX:-@libdir@};export PATH=$${GNUNET_PREFIX:-@prefix@}/bin:$$PATH;unset XDG_DATA_HOME;unset XDG_CONFIG_HOME; |
182 | TESTS = $(check_PROGRAMS) $(check_SCRIPTS) | 158 | TESTS = $(check_PROGRAMS) $(check_SCRIPTS) |
183 | endif | 159 | endif |
184 | 160 | ||
185 | gnunet_timeout_SOURCES = \ | ||
186 | gnunet-timeout.c | ||
187 | |||
188 | gnunet_service_resolver_SOURCES = \ | ||
189 | gnunet-service-resolver.c | ||
190 | gnunet_service_resolver_LDADD = \ | ||
191 | libgnunetutil.la \ | ||
192 | $(GN_LIBINTL) | ||
193 | if HAVE_GETADDRINFO_A | ||
194 | gnunet_service_resolver_LDADD += -lanl | ||
195 | endif | ||
196 | |||
197 | |||
198 | gnunet_resolver_SOURCES = \ | ||
199 | gnunet-resolver.c | ||
200 | gnunet_resolver_LDADD = \ | ||
201 | libgnunetutil.la \ | ||
202 | $(GN_LIBINTL) | ||
203 | |||
204 | gnunet_crypto_tvg_SOURCES = \ | ||
205 | gnunet-crypto-tvg.c | ||
206 | gnunet_crypto_tvg_LDADD = \ | ||
207 | libgnunetutil.la \ | ||
208 | $(GN_LIBINTL) -lgcrypt -ljansson | ||
209 | |||
210 | gnunet_ecc_SOURCES = \ | ||
211 | gnunet-ecc.c | ||
212 | gnunet_ecc_LDADD = \ | ||
213 | libgnunetutil.la \ | ||
214 | $(GN_LIBINTL) -lgcrypt | ||
215 | |||
216 | gnunet_base32_SOURCES = \ | ||
217 | gnunet-base32.c | ||
218 | gnunet_base32_LDADD = \ | ||
219 | libgnunetutil.la \ | ||
220 | $(GN_LIBINTL) | ||
221 | |||
222 | gnunet_scrypt_SOURCES = \ | ||
223 | gnunet-scrypt.c | ||
224 | gnunet_scrypt_LDADD = \ | ||
225 | libgnunetutil.la \ | ||
226 | $(GN_LIBINTL) -lgcrypt | ||
227 | |||
228 | |||
229 | gnunet_config_SOURCES = \ | ||
230 | gnunet-config.c | ||
231 | gnunet_config_LDADD = \ | ||
232 | libgnunetutil.la \ | ||
233 | $(GN_LIBINTL) | ||
234 | |||
235 | gnunet_uri_SOURCES = \ | ||
236 | gnunet-uri.c | ||
237 | gnunet_uri_LDADD = \ | ||
238 | libgnunetutil.la \ | ||
239 | $(GN_LIBINTL) | ||
240 | |||
241 | |||
242 | gnunet_qr_SOURCES = \ | ||
243 | gnunet-qr.c | ||
244 | gnunet_qr_LDADD = \ | ||
245 | libgnunetutil.la \ | ||
246 | $(GN_LIBINTL) | ||
247 | gnunet_qr_LDFLAGS= -lzbar | ||
248 | if HAVE_PNG | ||
249 | gnunet_qr_LDFLAGS += -lpng | ||
250 | endif | ||
251 | |||
252 | plugin_LTLIBRARIES = \ | 161 | plugin_LTLIBRARIES = \ |
253 | libgnunet_plugin_utiltest.la | 162 | libgnunet_plugin_utiltest.la |
254 | 163 | ||
@@ -275,9 +184,6 @@ if HAVE_SSH_KEY | |||
275 | # SSH_USING_TESTS = test_socks.nc | 184 | # SSH_USING_TESTS = test_socks.nc |
276 | endif | 185 | endif |
277 | 186 | ||
278 | check_SCRIPTS = \ | ||
279 | test_crypto_vectors.sh | ||
280 | |||
281 | check_PROGRAMS = \ | 187 | check_PROGRAMS = \ |
282 | test_bio \ | 188 | test_bio \ |
283 | test_child_management \ | 189 | test_child_management \ |
@@ -319,7 +225,6 @@ check_PROGRAMS = \ | |||
319 | test_plugin \ | 225 | test_plugin \ |
320 | test_program \ | 226 | test_program \ |
321 | test_regex \ | 227 | test_regex \ |
322 | test_resolver_api.nc \ | ||
323 | test_scheduler \ | 228 | test_scheduler \ |
324 | test_scheduler_delay \ | 229 | test_scheduler_delay \ |
325 | test_scheduler_hogging_cancel \ | 230 | test_scheduler_hogging_cancel \ |
@@ -574,11 +479,6 @@ test_program_SOURCES = \ | |||
574 | test_program_LDADD = \ | 479 | test_program_LDADD = \ |
575 | libgnunetutil.la | 480 | libgnunetutil.la |
576 | 481 | ||
577 | test_resolver_api_nc_SOURCES = \ | ||
578 | test_resolver_api.c | ||
579 | test_resolver_api_nc_LDADD = \ | ||
580 | libgnunetutil.la | ||
581 | |||
582 | test_scheduler_SOURCES = \ | 482 | test_scheduler_SOURCES = \ |
583 | test_scheduler.c | 483 | test_scheduler.c |
584 | test_scheduler_LDADD = \ | 484 | test_scheduler_LDADD = \ |
@@ -688,9 +588,6 @@ EXTRA_DIST = \ | |||
688 | test_client_unix.conf \ | 588 | test_client_unix.conf \ |
689 | test_configuration_data.conf \ | 589 | test_configuration_data.conf \ |
690 | test_program_data.conf \ | 590 | test_program_data.conf \ |
691 | test_resolver_api_data.conf \ | ||
692 | test_service_data.conf \ | 591 | test_service_data.conf \ |
693 | test_speedup_data.conf \ | 592 | test_speedup_data.conf \ |
694 | child_management_test.sh \ | 593 | child_management_test.sh |
695 | test_crypto_vectors.sh \ | ||
696 | crypto-test-vectors.json | ||
diff --git a/src/util/bandwidth.c b/src/lib/util/bandwidth.c index 8411c12ee..8411c12ee 100644 --- a/src/util/bandwidth.c +++ b/src/lib/util/bandwidth.c | |||
diff --git a/src/util/benchmark.c b/src/lib/util/benchmark.c index c9fc8842e..c9fc8842e 100644 --- a/src/util/benchmark.c +++ b/src/lib/util/benchmark.c | |||
diff --git a/src/util/benchmark.h b/src/lib/util/benchmark.h index e35fa50bd..e35fa50bd 100644 --- a/src/util/benchmark.h +++ b/src/lib/util/benchmark.h | |||
diff --git a/src/util/bio.c b/src/lib/util/bio.c index caf533108..caf533108 100644 --- a/src/util/bio.c +++ b/src/lib/util/bio.c | |||
diff --git a/src/util/buffer.c b/src/lib/util/buffer.c index f88c56849..f88c56849 100644 --- a/src/util/buffer.c +++ b/src/lib/util/buffer.c | |||
diff --git a/src/util/child_management.c b/src/lib/util/child_management.c index e78ebac9f..e78ebac9f 100644 --- a/src/util/child_management.c +++ b/src/lib/util/child_management.c | |||
diff --git a/src/util/child_management_test.sh b/src/lib/util/child_management_test.sh index a35b865f3..a35b865f3 100755 --- a/src/util/child_management_test.sh +++ b/src/lib/util/child_management_test.sh | |||
diff --git a/src/util/client.c b/src/lib/util/client.c index fb2120ee8..fb2120ee8 100644 --- a/src/util/client.c +++ b/src/lib/util/client.c | |||
diff --git a/src/util/common_allocation.c b/src/lib/util/common_allocation.c index 36d49eddb..36d49eddb 100644 --- a/src/util/common_allocation.c +++ b/src/lib/util/common_allocation.c | |||
diff --git a/src/util/common_endian.c b/src/lib/util/common_endian.c index 59c15326d..59c15326d 100644 --- a/src/util/common_endian.c +++ b/src/lib/util/common_endian.c | |||
diff --git a/src/util/common_logging.c b/src/lib/util/common_logging.c index d27f70e83..d27f70e83 100644 --- a/src/util/common_logging.c +++ b/src/lib/util/common_logging.c | |||
diff --git a/src/util/compress.c b/src/lib/util/compress.c index 73fa25bd9..73fa25bd9 100644 --- a/src/util/compress.c +++ b/src/lib/util/compress.c | |||
diff --git a/src/util/configuration.c b/src/lib/util/configuration.c index 17ba253ff..17ba253ff 100644 --- a/src/util/configuration.c +++ b/src/lib/util/configuration.c | |||
diff --git a/src/util/configuration_helper.c b/src/lib/util/configuration_helper.c index d4d5fc732..d4d5fc732 100644 --- a/src/util/configuration_helper.c +++ b/src/lib/util/configuration_helper.c | |||
diff --git a/src/util/consttime_memcmp.c b/src/lib/util/consttime_memcmp.c index d4fa45a5b..d4fa45a5b 100644 --- a/src/util/consttime_memcmp.c +++ b/src/lib/util/consttime_memcmp.c | |||
diff --git a/src/util/container_bloomfilter.c b/src/lib/util/container_bloomfilter.c index 7e4faaf3f..7e4faaf3f 100644 --- a/src/util/container_bloomfilter.c +++ b/src/lib/util/container_bloomfilter.c | |||
diff --git a/src/util/container_heap.c b/src/lib/util/container_heap.c index 232e66bf9..232e66bf9 100644 --- a/src/util/container_heap.c +++ b/src/lib/util/container_heap.c | |||
diff --git a/src/util/container_multihashmap.c b/src/lib/util/container_multihashmap.c index 73333d22a..73333d22a 100644 --- a/src/util/container_multihashmap.c +++ b/src/lib/util/container_multihashmap.c | |||
diff --git a/src/util/container_multihashmap32.c b/src/lib/util/container_multihashmap32.c index 3b4c92426..3b4c92426 100644 --- a/src/util/container_multihashmap32.c +++ b/src/lib/util/container_multihashmap32.c | |||
diff --git a/src/util/container_multipeermap.c b/src/lib/util/container_multipeermap.c index 7ccfb62c8..7ccfb62c8 100644 --- a/src/util/container_multipeermap.c +++ b/src/lib/util/container_multipeermap.c | |||
diff --git a/src/util/container_multishortmap.c b/src/lib/util/container_multishortmap.c index c626b55e5..c626b55e5 100644 --- a/src/util/container_multishortmap.c +++ b/src/lib/util/container_multishortmap.c | |||
diff --git a/src/util/container_multiuuidmap.c b/src/lib/util/container_multiuuidmap.c index 3e957d47b..3e957d47b 100644 --- a/src/util/container_multiuuidmap.c +++ b/src/lib/util/container_multiuuidmap.c | |||
diff --git a/src/util/crypto_crc.c b/src/lib/util/crypto_crc.c index f93b5b0b3..f93b5b0b3 100644 --- a/src/util/crypto_crc.c +++ b/src/lib/util/crypto_crc.c | |||
diff --git a/src/util/crypto_cs.c b/src/lib/util/crypto_cs.c index 8506c7fa6..8506c7fa6 100644 --- a/src/util/crypto_cs.c +++ b/src/lib/util/crypto_cs.c | |||
diff --git a/src/util/crypto_ecc.c b/src/lib/util/crypto_ecc.c index 11c3e50d4..11c3e50d4 100644 --- a/src/util/crypto_ecc.c +++ b/src/lib/util/crypto_ecc.c | |||
diff --git a/src/util/crypto_ecc_dlog.c b/src/lib/util/crypto_ecc_dlog.c index 6e333686f..6e333686f 100644 --- a/src/util/crypto_ecc_dlog.c +++ b/src/lib/util/crypto_ecc_dlog.c | |||
diff --git a/src/util/crypto_ecc_gnsrecord.c b/src/lib/util/crypto_ecc_gnsrecord.c index fb8ba3ac9..fb8ba3ac9 100644 --- a/src/util/crypto_ecc_gnsrecord.c +++ b/src/lib/util/crypto_ecc_gnsrecord.c | |||
diff --git a/src/util/crypto_ecc_setup.c b/src/lib/util/crypto_ecc_setup.c index e07d1e448..e07d1e448 100644 --- a/src/util/crypto_ecc_setup.c +++ b/src/lib/util/crypto_ecc_setup.c | |||
diff --git a/src/util/crypto_edx25519.c b/src/lib/util/crypto_edx25519.c index 2d9a76aa3..2d9a76aa3 100644 --- a/src/util/crypto_edx25519.c +++ b/src/lib/util/crypto_edx25519.c | |||
diff --git a/src/util/crypto_hash.c b/src/lib/util/crypto_hash.c index 4f3acde77..4f3acde77 100644 --- a/src/util/crypto_hash.c +++ b/src/lib/util/crypto_hash.c | |||
diff --git a/src/util/crypto_hash_file.c b/src/lib/util/crypto_hash_file.c index 96d364d2b..96d364d2b 100644 --- a/src/util/crypto_hash_file.c +++ b/src/lib/util/crypto_hash_file.c | |||
diff --git a/src/util/crypto_hkdf.c b/src/lib/util/crypto_hkdf.c index e724bc9ba..e724bc9ba 100644 --- a/src/util/crypto_hkdf.c +++ b/src/lib/util/crypto_hkdf.c | |||
diff --git a/src/util/crypto_kdf.c b/src/lib/util/crypto_kdf.c index 7cfd8fea4..7cfd8fea4 100644 --- a/src/util/crypto_kdf.c +++ b/src/lib/util/crypto_kdf.c | |||
diff --git a/src/util/crypto_mpi.c b/src/lib/util/crypto_mpi.c index 06f2fd786..06f2fd786 100644 --- a/src/util/crypto_mpi.c +++ b/src/lib/util/crypto_mpi.c | |||
diff --git a/src/util/crypto_paillier.c b/src/lib/util/crypto_paillier.c index 169d1e49e..169d1e49e 100644 --- a/src/util/crypto_paillier.c +++ b/src/lib/util/crypto_paillier.c | |||
diff --git a/src/lib/util/crypto_pkey.c b/src/lib/util/crypto_pkey.c new file mode 100644 index 000000000..0a55b3b65 --- /dev/null +++ b/src/lib/util/crypto_pkey.c | |||
@@ -0,0 +1,618 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2013, 2016, 2021 GNUnet e.V. | ||
4 | |||
5 | GNUnet is free software: you can redistribute it and/or modify it | ||
6 | under the terms of the GNU Affero General Public License as published | ||
7 | by the Free Software Foundation, either version 3 of the License, | ||
8 | or (at your option) any later version. | ||
9 | |||
10 | GNUnet is distributed in the hope that it will be useful, but | ||
11 | WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
13 | Affero General Public License for more details. | ||
14 | |||
15 | You should have received a copy of the GNU Affero General Public License | ||
16 | along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
17 | |||
18 | SPDX-License-Identifier: AGPL3.0-or-later | ||
19 | */ | ||
20 | |||
21 | /** | ||
22 | * @file util/crypto_pkey.c | ||
23 | * @brief api to interact handle generic public keys | ||
24 | * @author Martin Schanzenbach | ||
25 | */ | ||
26 | |||
27 | #include "platform.h" | ||
28 | #include "gnunet_util_lib.h" | ||
29 | |||
30 | |||
31 | static enum GNUNET_GenericReturnValue | ||
32 | check_key_type (uint32_t type) | ||
33 | { | ||
34 | switch (type) | ||
35 | { | ||
36 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: | ||
37 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: | ||
38 | return GNUNET_OK; | ||
39 | default: | ||
40 | return GNUNET_SYSERR; | ||
41 | } | ||
42 | return GNUNET_SYSERR; | ||
43 | } | ||
44 | |||
45 | |||
46 | ssize_t | ||
47 | GNUNET_CRYPTO_private_key_get_length (const struct | ||
48 | GNUNET_CRYPTO_PrivateKey *key) | ||
49 | { | ||
50 | switch (ntohl (key->type)) | ||
51 | { | ||
52 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: | ||
53 | return sizeof (key->type) + sizeof (key->ecdsa_key); | ||
54 | break; | ||
55 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: | ||
56 | return sizeof (key->type) + sizeof (key->eddsa_key); | ||
57 | break; | ||
58 | default: | ||
59 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | ||
60 | "Got key type %u\n", ntohl (key->type)); | ||
61 | GNUNET_break (0); | ||
62 | } | ||
63 | return -1; | ||
64 | } | ||
65 | |||
66 | |||
67 | ssize_t | ||
68 | GNUNET_CRYPTO_public_key_get_length (const struct | ||
69 | GNUNET_CRYPTO_PublicKey *key) | ||
70 | { | ||
71 | switch (ntohl (key->type)) | ||
72 | { | ||
73 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: | ||
74 | return sizeof (key->type) + sizeof (key->ecdsa_key); | ||
75 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: | ||
76 | return sizeof (key->type) + sizeof (key->eddsa_key); | ||
77 | default: | ||
78 | GNUNET_break (0); | ||
79 | } | ||
80 | return -1; | ||
81 | } | ||
82 | |||
83 | |||
84 | ssize_t | ||
85 | GNUNET_CRYPTO_private_key_length_by_type (enum GNUNET_CRYPTO_KeyType kt) | ||
86 | { | ||
87 | switch (kt) | ||
88 | { | ||
89 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: | ||
90 | return sizeof (struct GNUNET_CRYPTO_EcdsaPrivateKey); | ||
91 | break; | ||
92 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: | ||
93 | return sizeof (struct GNUNET_CRYPTO_EcdsaPrivateKey); | ||
94 | break; | ||
95 | default: | ||
96 | GNUNET_break (0); | ||
97 | } | ||
98 | return -1; | ||
99 | } | ||
100 | |||
101 | |||
102 | enum GNUNET_GenericReturnValue | ||
103 | GNUNET_CRYPTO_read_public_key_from_buffer (const void *buffer, | ||
104 | size_t len, | ||
105 | struct GNUNET_CRYPTO_PublicKey * | ||
106 | key, | ||
107 | size_t *kb_read) | ||
108 | { | ||
109 | if (len < sizeof (key->type)) | ||
110 | return GNUNET_SYSERR; | ||
111 | GNUNET_memcpy (&key->type, | ||
112 | buffer, | ||
113 | sizeof (key->type)); | ||
114 | ssize_t length = GNUNET_CRYPTO_public_key_get_length (key); | ||
115 | if (len < length) | ||
116 | return GNUNET_SYSERR; | ||
117 | if (length < 0) | ||
118 | return GNUNET_SYSERR; | ||
119 | GNUNET_memcpy (&key->ecdsa_key, | ||
120 | buffer + sizeof (key->type), | ||
121 | length - sizeof (key->type)); | ||
122 | *kb_read = length; | ||
123 | return GNUNET_OK; | ||
124 | } | ||
125 | |||
126 | |||
127 | ssize_t | ||
128 | GNUNET_CRYPTO_write_public_key_to_buffer (const struct | ||
129 | GNUNET_CRYPTO_PublicKey *key, | ||
130 | void*buffer, | ||
131 | size_t len) | ||
132 | { | ||
133 | const ssize_t length = GNUNET_CRYPTO_public_key_get_length (key); | ||
134 | if (len < length) | ||
135 | return -1; | ||
136 | if (length < 0) | ||
137 | return -2; | ||
138 | GNUNET_memcpy (buffer, &(key->type), sizeof (key->type)); | ||
139 | GNUNET_memcpy (buffer + sizeof (key->type), &(key->ecdsa_key), length | ||
140 | - sizeof (key->type)); | ||
141 | return length; | ||
142 | } | ||
143 | |||
144 | |||
145 | enum GNUNET_GenericReturnValue | ||
146 | GNUNET_CRYPTO_read_private_key_from_buffer (const void *buffer, | ||
147 | size_t len, | ||
148 | struct | ||
149 | GNUNET_CRYPTO_PrivateKey *key, | ||
150 | size_t *kb_read) | ||
151 | { | ||
152 | if (len < sizeof (key->type)) | ||
153 | return GNUNET_SYSERR; | ||
154 | GNUNET_memcpy (&key->type, | ||
155 | buffer, | ||
156 | sizeof (key->type)); | ||
157 | ssize_t length = GNUNET_CRYPTO_private_key_get_length (key); | ||
158 | if (len < length) | ||
159 | return GNUNET_SYSERR; | ||
160 | if (length < 0) | ||
161 | return GNUNET_SYSERR; | ||
162 | GNUNET_memcpy (&key->ecdsa_key, | ||
163 | buffer + sizeof (key->type), | ||
164 | length - sizeof (key->type)); | ||
165 | *kb_read = length; | ||
166 | return GNUNET_OK; | ||
167 | } | ||
168 | |||
169 | |||
170 | ssize_t | ||
171 | GNUNET_CRYPTO_write_private_key_to_buffer (const struct | ||
172 | GNUNET_CRYPTO_PrivateKey *key, | ||
173 | void *buffer, | ||
174 | size_t len) | ||
175 | { | ||
176 | const ssize_t length = GNUNET_CRYPTO_private_key_get_length (key); | ||
177 | if (len < length) | ||
178 | return -1; | ||
179 | if (length < 0) | ||
180 | return -2; | ||
181 | GNUNET_memcpy (buffer, &(key->type), sizeof (key->type)); | ||
182 | GNUNET_memcpy (buffer + sizeof (key->type), &(key->ecdsa_key), length | ||
183 | - sizeof (key->type)); | ||
184 | return length; | ||
185 | } | ||
186 | |||
187 | |||
188 | ssize_t | ||
189 | GNUNET_CRYPTO_signature_get_length (const struct | ||
190 | GNUNET_CRYPTO_Signature *sig) | ||
191 | { | ||
192 | switch (ntohl (sig->type)) | ||
193 | { | ||
194 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: | ||
195 | return sizeof (sig->type) + sizeof (sig->ecdsa_signature); | ||
196 | break; | ||
197 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: | ||
198 | return sizeof (sig->type) + sizeof (sig->eddsa_signature); | ||
199 | break; | ||
200 | default: | ||
201 | GNUNET_break (0); | ||
202 | } | ||
203 | return -1; | ||
204 | } | ||
205 | |||
206 | |||
207 | ssize_t | ||
208 | GNUNET_CRYPTO_signature_get_raw_length_by_type (uint32_t type) | ||
209 | { | ||
210 | switch (ntohl (type)) | ||
211 | { | ||
212 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: | ||
213 | return sizeof (struct GNUNET_CRYPTO_EcdsaSignature); | ||
214 | break; | ||
215 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: | ||
216 | return sizeof (struct GNUNET_CRYPTO_EddsaSignature); | ||
217 | break; | ||
218 | default: | ||
219 | GNUNET_break (0); | ||
220 | } | ||
221 | return -1; | ||
222 | } | ||
223 | |||
224 | |||
225 | ssize_t | ||
226 | GNUNET_CRYPTO_read_signature_from_buffer (struct | ||
227 | GNUNET_CRYPTO_Signature *sig, | ||
228 | const void*buffer, | ||
229 | size_t len) | ||
230 | { | ||
231 | if (len < sizeof (sig->type)) | ||
232 | return -1; | ||
233 | GNUNET_memcpy (&(sig->type), buffer, sizeof (sig->type)); | ||
234 | const ssize_t length = GNUNET_CRYPTO_signature_get_length (sig); | ||
235 | if (len < length) | ||
236 | return -1; | ||
237 | if (length < 0) | ||
238 | return -2; | ||
239 | GNUNET_memcpy (&(sig->ecdsa_signature), buffer + sizeof (sig->type), length | ||
240 | - sizeof (sig->type)); | ||
241 | return length; | ||
242 | } | ||
243 | |||
244 | |||
245 | ssize_t | ||
246 | GNUNET_CRYPTO_write_signature_to_buffer (const struct | ||
247 | GNUNET_CRYPTO_Signature *sig, | ||
248 | void*buffer, | ||
249 | size_t len) | ||
250 | { | ||
251 | const ssize_t length = GNUNET_CRYPTO_signature_get_length (sig); | ||
252 | if (len < length) | ||
253 | return -1; | ||
254 | if (length < 0) | ||
255 | return -2; | ||
256 | GNUNET_memcpy (buffer, &(sig->type), sizeof (sig->type)); | ||
257 | GNUNET_memcpy (buffer + sizeof (sig->type), &(sig->ecdsa_signature), length | ||
258 | - sizeof (sig->type)); | ||
259 | return length; | ||
260 | } | ||
261 | |||
262 | |||
263 | enum GNUNET_GenericReturnValue | ||
264 | GNUNET_CRYPTO_sign_raw_ (const struct | ||
265 | GNUNET_CRYPTO_PrivateKey *priv, | ||
266 | const struct | ||
267 | GNUNET_CRYPTO_EccSignaturePurpose *purpose, | ||
268 | unsigned char *sig) | ||
269 | { | ||
270 | switch (ntohl (priv->type)) | ||
271 | { | ||
272 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: | ||
273 | return GNUNET_CRYPTO_ecdsa_sign_ (&(priv->ecdsa_key), purpose, | ||
274 | (struct | ||
275 | GNUNET_CRYPTO_EcdsaSignature*) sig); | ||
276 | break; | ||
277 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: | ||
278 | return GNUNET_CRYPTO_eddsa_sign_ (&(priv->eddsa_key), purpose, | ||
279 | (struct | ||
280 | GNUNET_CRYPTO_EddsaSignature*) sig); | ||
281 | break; | ||
282 | default: | ||
283 | GNUNET_break (0); | ||
284 | } | ||
285 | |||
286 | return GNUNET_SYSERR; | ||
287 | } | ||
288 | |||
289 | |||
290 | enum GNUNET_GenericReturnValue | ||
291 | GNUNET_CRYPTO_sign_ (const struct | ||
292 | GNUNET_CRYPTO_PrivateKey *priv, | ||
293 | const struct | ||
294 | GNUNET_CRYPTO_EccSignaturePurpose *purpose, | ||
295 | struct GNUNET_CRYPTO_Signature *sig) | ||
296 | { | ||
297 | sig->type = priv->type; | ||
298 | switch (ntohl (priv->type)) | ||
299 | { | ||
300 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: | ||
301 | return GNUNET_CRYPTO_ecdsa_sign_ (&(priv->ecdsa_key), purpose, | ||
302 | &(sig->ecdsa_signature)); | ||
303 | break; | ||
304 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: | ||
305 | return GNUNET_CRYPTO_eddsa_sign_ (&(priv->eddsa_key), purpose, | ||
306 | &(sig->eddsa_signature)); | ||
307 | break; | ||
308 | default: | ||
309 | GNUNET_break (0); | ||
310 | } | ||
311 | |||
312 | return GNUNET_SYSERR; | ||
313 | } | ||
314 | |||
315 | |||
316 | enum GNUNET_GenericReturnValue | ||
317 | GNUNET_CRYPTO_signature_verify_ (uint32_t purpose, | ||
318 | const struct | ||
319 | GNUNET_CRYPTO_EccSignaturePurpose *validate, | ||
320 | const struct GNUNET_CRYPTO_Signature *sig, | ||
321 | const struct GNUNET_CRYPTO_PublicKey *pub) | ||
322 | { | ||
323 | /* check type matching of 'sig' and 'pub' */ | ||
324 | GNUNET_assert (ntohl (pub->type) == ntohl (sig->type)); | ||
325 | switch (ntohl (pub->type)) | ||
326 | { | ||
327 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: | ||
328 | return GNUNET_CRYPTO_ecdsa_verify_ (purpose, validate, | ||
329 | &(sig->ecdsa_signature), | ||
330 | &(pub->ecdsa_key)); | ||
331 | break; | ||
332 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: | ||
333 | return GNUNET_CRYPTO_eddsa_verify_ (purpose, validate, | ||
334 | &(sig->eddsa_signature), | ||
335 | &(pub->eddsa_key)); | ||
336 | break; | ||
337 | default: | ||
338 | GNUNET_break (0); | ||
339 | } | ||
340 | |||
341 | return GNUNET_SYSERR; | ||
342 | } | ||
343 | |||
344 | |||
345 | enum GNUNET_GenericReturnValue | ||
346 | GNUNET_CRYPTO_signature_verify_raw_ (uint32_t purpose, | ||
347 | const struct | ||
348 | GNUNET_CRYPTO_EccSignaturePurpose * | ||
349 | validate, | ||
350 | const unsigned char *sig, | ||
351 | const struct | ||
352 | GNUNET_CRYPTO_PublicKey *pub) | ||
353 | { | ||
354 | switch (ntohl (pub->type)) | ||
355 | { | ||
356 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: | ||
357 | return GNUNET_CRYPTO_ecdsa_verify_ (purpose, validate, | ||
358 | (struct | ||
359 | GNUNET_CRYPTO_EcdsaSignature*) sig, | ||
360 | &(pub->ecdsa_key)); | ||
361 | break; | ||
362 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: | ||
363 | return GNUNET_CRYPTO_eddsa_verify_ (purpose, validate, | ||
364 | (struct | ||
365 | GNUNET_CRYPTO_EddsaSignature*) sig, | ||
366 | &(pub->eddsa_key)); | ||
367 | break; | ||
368 | default: | ||
369 | GNUNET_break (0); | ||
370 | } | ||
371 | |||
372 | return GNUNET_SYSERR; | ||
373 | } | ||
374 | |||
375 | |||
376 | ssize_t | ||
377 | GNUNET_CRYPTO_encrypt_old (const void *block, | ||
378 | size_t size, | ||
379 | const struct GNUNET_CRYPTO_PublicKey *pub, | ||
380 | struct GNUNET_CRYPTO_EcdhePublicKey *ecc, | ||
381 | void *result) | ||
382 | { | ||
383 | struct GNUNET_CRYPTO_EcdhePrivateKey pk; | ||
384 | GNUNET_CRYPTO_ecdhe_key_create (&pk); | ||
385 | struct GNUNET_HashCode hash; | ||
386 | switch (ntohl (pub->type)) | ||
387 | { | ||
388 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: | ||
389 | if (GNUNET_SYSERR == GNUNET_CRYPTO_ecdh_ecdsa (&pk, &(pub->ecdsa_key), | ||
390 | &hash)) | ||
391 | return -1; | ||
392 | break; | ||
393 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: | ||
394 | if (GNUNET_SYSERR == GNUNET_CRYPTO_ecdh_eddsa (&pk, &(pub->eddsa_key), | ||
395 | &hash)) | ||
396 | return -1; | ||
397 | break; | ||
398 | default: | ||
399 | return -1; | ||
400 | } | ||
401 | GNUNET_CRYPTO_ecdhe_key_get_public (&pk, ecc); | ||
402 | GNUNET_CRYPTO_ecdhe_key_clear (&pk); | ||
403 | struct GNUNET_CRYPTO_SymmetricSessionKey key; | ||
404 | struct GNUNET_CRYPTO_SymmetricInitializationVector iv; | ||
405 | GNUNET_CRYPTO_hash_to_aes_key (&hash, &key, &iv); | ||
406 | GNUNET_CRYPTO_zero_keys (&hash, sizeof(hash)); | ||
407 | const ssize_t encrypted = GNUNET_CRYPTO_symmetric_encrypt (block, size, &key, | ||
408 | &iv, result); | ||
409 | GNUNET_CRYPTO_zero_keys (&key, sizeof(key)); | ||
410 | GNUNET_CRYPTO_zero_keys (&iv, sizeof(iv)); | ||
411 | return encrypted; | ||
412 | } | ||
413 | |||
414 | |||
415 | enum GNUNET_GenericReturnValue | ||
416 | GNUNET_CRYPTO_encrypt (const void *pt, | ||
417 | size_t pt_size, | ||
418 | const struct GNUNET_CRYPTO_PublicKey *pub, | ||
419 | void *ct_buf, | ||
420 | size_t ct_size) | ||
421 | { | ||
422 | struct GNUNET_HashCode k; | ||
423 | struct GNUNET_CRYPTO_FoKemC kemc; | ||
424 | struct GNUNET_CRYPTO_FoKemC *kemc_buf = (struct GNUNET_CRYPTO_FoKemC*) ct_buf; | ||
425 | unsigned char *encrypted_data = (unsigned char*) &kemc_buf[1]; | ||
426 | unsigned char nonce[crypto_secretbox_NONCEBYTES]; | ||
427 | unsigned char key[crypto_secretbox_KEYBYTES]; | ||
428 | |||
429 | if (ct_size < pt_size + GNUNET_CRYPTO_ENCRYPT_OVERHEAD_BYTES) | ||
430 | { | ||
431 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | ||
432 | "Output buffer size for ciphertext too small: Got %lu, want >=%lu\n", | ||
433 | ct_size, pt_size + GNUNET_CRYPTO_ENCRYPT_OVERHEAD_BYTES); | ||
434 | return GNUNET_SYSERR; | ||
435 | } | ||
436 | switch (ntohl (pub->type)) | ||
437 | { | ||
438 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: | ||
439 | if (GNUNET_SYSERR == GNUNET_CRYPTO_ecdsa_fo_kem_encaps (&(pub->ecdsa_key), | ||
440 | &kemc, | ||
441 | &k)) | ||
442 | return GNUNET_SYSERR; | ||
443 | break; | ||
444 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: | ||
445 | if (GNUNET_SYSERR == GNUNET_CRYPTO_eddsa_fo_kem_encaps (&pub->eddsa_key, | ||
446 | &kemc, | ||
447 | &k)) | ||
448 | return GNUNET_SYSERR; | ||
449 | break; | ||
450 | default: | ||
451 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Unsupported key type\n"); | ||
452 | return GNUNET_SYSERR; | ||
453 | } | ||
454 | memcpy (key, &k, crypto_secretbox_KEYBYTES); | ||
455 | memcpy (nonce, ((char* ) &k) + crypto_secretbox_KEYBYTES, | ||
456 | crypto_secretbox_NONCEBYTES); | ||
457 | if (crypto_secretbox_easy (encrypted_data, pt, pt_size, nonce, key)) | ||
458 | return GNUNET_SYSERR; | ||
459 | memcpy (kemc_buf, &kemc, sizeof (kemc)); | ||
460 | return GNUNET_OK; | ||
461 | } | ||
462 | |||
463 | |||
464 | enum GNUNET_GenericReturnValue | ||
465 | GNUNET_CRYPTO_decrypt (const void *ct_buf, | ||
466 | size_t ct_size, | ||
467 | const struct GNUNET_CRYPTO_PrivateKey *priv, | ||
468 | void *pt, | ||
469 | size_t pt_size) | ||
470 | { | ||
471 | struct GNUNET_HashCode k; | ||
472 | struct GNUNET_CRYPTO_FoKemC *kemc = (struct GNUNET_CRYPTO_FoKemC*) ct_buf; | ||
473 | unsigned char *encrypted_data = (unsigned char*) &kemc[1]; | ||
474 | unsigned char nonce[crypto_secretbox_NONCEBYTES]; | ||
475 | unsigned char key[crypto_secretbox_KEYBYTES]; | ||
476 | size_t expected_pt_len = ct_size - GNUNET_CRYPTO_ENCRYPT_OVERHEAD_BYTES; | ||
477 | |||
478 | if (pt_size < expected_pt_len) | ||
479 | { | ||
480 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | ||
481 | "Output buffer size for plaintext too small: Got %lu, want >=%lu\n", | ||
482 | pt_size, expected_pt_len); | ||
483 | return GNUNET_SYSERR; | ||
484 | } | ||
485 | switch (ntohl (priv->type)) | ||
486 | { | ||
487 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: | ||
488 | if (GNUNET_SYSERR == GNUNET_CRYPTO_ecdsa_fo_kem_decaps (&(priv->ecdsa_key), | ||
489 | kemc, | ||
490 | &k)) | ||
491 | return GNUNET_SYSERR; | ||
492 | break; | ||
493 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: | ||
494 | if (GNUNET_SYSERR == GNUNET_CRYPTO_eddsa_fo_kem_decaps (&(priv->eddsa_key), | ||
495 | kemc, | ||
496 | &k)) | ||
497 | return GNUNET_SYSERR; | ||
498 | break; | ||
499 | default: | ||
500 | return GNUNET_SYSERR; | ||
501 | } | ||
502 | memcpy (key, &k, crypto_secretbox_KEYBYTES); | ||
503 | memcpy (nonce, ((char* ) &k) + crypto_secretbox_KEYBYTES, | ||
504 | crypto_secretbox_NONCEBYTES); | ||
505 | if (crypto_secretbox_open_easy (pt, encrypted_data, ct_size - sizeof (*kemc), | ||
506 | nonce, key)) | ||
507 | return GNUNET_SYSERR; | ||
508 | return GNUNET_OK; | ||
509 | } | ||
510 | |||
511 | |||
512 | ssize_t | ||
513 | GNUNET_CRYPTO_decrypt_old (const void *block, | ||
514 | size_t size, | ||
515 | const struct GNUNET_CRYPTO_PrivateKey *priv, | ||
516 | const struct GNUNET_CRYPTO_EcdhePublicKey *ecc, | ||
517 | void *result) | ||
518 | { | ||
519 | struct GNUNET_HashCode hash; | ||
520 | switch (ntohl (priv->type)) | ||
521 | { | ||
522 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: | ||
523 | if (GNUNET_SYSERR == GNUNET_CRYPTO_ecdsa_ecdh (&(priv->ecdsa_key), ecc, | ||
524 | &hash)) | ||
525 | return -1; | ||
526 | break; | ||
527 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: | ||
528 | if (GNUNET_SYSERR == GNUNET_CRYPTO_eddsa_ecdh (&(priv->eddsa_key), ecc, | ||
529 | &hash)) | ||
530 | return -1; | ||
531 | break; | ||
532 | default: | ||
533 | return -1; | ||
534 | } | ||
535 | struct GNUNET_CRYPTO_SymmetricSessionKey key; | ||
536 | struct GNUNET_CRYPTO_SymmetricInitializationVector iv; | ||
537 | GNUNET_CRYPTO_hash_to_aes_key (&hash, &key, &iv); | ||
538 | GNUNET_CRYPTO_zero_keys (&hash, sizeof(hash)); | ||
539 | const ssize_t decrypted = GNUNET_CRYPTO_symmetric_decrypt (block, size, &key, | ||
540 | &iv, result); | ||
541 | GNUNET_CRYPTO_zero_keys (&key, sizeof(key)); | ||
542 | GNUNET_CRYPTO_zero_keys (&iv, sizeof(iv)); | ||
543 | return decrypted; | ||
544 | } | ||
545 | |||
546 | |||
547 | char * | ||
548 | GNUNET_CRYPTO_public_key_to_string (const struct | ||
549 | GNUNET_CRYPTO_PublicKey *key) | ||
550 | { | ||
551 | size_t size = GNUNET_CRYPTO_public_key_get_length (key); | ||
552 | return GNUNET_STRINGS_data_to_string_alloc (key, | ||
553 | size); | ||
554 | } | ||
555 | |||
556 | |||
557 | char * | ||
558 | GNUNET_CRYPTO_private_key_to_string (const struct | ||
559 | GNUNET_CRYPTO_PrivateKey *key) | ||
560 | { | ||
561 | size_t size = GNUNET_CRYPTO_private_key_get_length (key); | ||
562 | return GNUNET_STRINGS_data_to_string_alloc (key, | ||
563 | size); | ||
564 | } | ||
565 | |||
566 | |||
567 | enum GNUNET_GenericReturnValue | ||
568 | GNUNET_CRYPTO_public_key_from_string (const char *str, | ||
569 | struct GNUNET_CRYPTO_PublicKey *key) | ||
570 | { | ||
571 | enum GNUNET_GenericReturnValue ret; | ||
572 | ret = GNUNET_STRINGS_string_to_data (str, | ||
573 | strlen (str), | ||
574 | key, | ||
575 | sizeof (*key)); | ||
576 | if (GNUNET_OK != ret) | ||
577 | return GNUNET_SYSERR; | ||
578 | return check_key_type (ntohl (key->type)); | ||
579 | |||
580 | } | ||
581 | |||
582 | |||
583 | enum GNUNET_GenericReturnValue | ||
584 | GNUNET_CRYPTO_private_key_from_string (const char *str, | ||
585 | struct GNUNET_CRYPTO_PrivateKey *key) | ||
586 | { | ||
587 | enum GNUNET_GenericReturnValue ret; | ||
588 | ret = GNUNET_STRINGS_string_to_data (str, | ||
589 | strlen (str), | ||
590 | key, | ||
591 | sizeof (*key)); | ||
592 | if (GNUNET_OK != ret) | ||
593 | return GNUNET_SYSERR; | ||
594 | return check_key_type (ntohl (key->type)); | ||
595 | } | ||
596 | |||
597 | enum GNUNET_GenericReturnValue | ||
598 | GNUNET_CRYPTO_key_get_public (const struct | ||
599 | GNUNET_CRYPTO_PrivateKey *privkey, | ||
600 | struct GNUNET_CRYPTO_PublicKey *key) | ||
601 | { | ||
602 | key->type = privkey->type; | ||
603 | switch (ntohl (privkey->type)) | ||
604 | { | ||
605 | case GNUNET_PUBLIC_KEY_TYPE_ECDSA: | ||
606 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey->ecdsa_key, | ||
607 | &key->ecdsa_key); | ||
608 | break; | ||
609 | case GNUNET_PUBLIC_KEY_TYPE_EDDSA: | ||
610 | GNUNET_CRYPTO_eddsa_key_get_public (&privkey->eddsa_key, | ||
611 | &key->eddsa_key); | ||
612 | break; | ||
613 | default: | ||
614 | GNUNET_break (0); | ||
615 | return GNUNET_SYSERR; | ||
616 | } | ||
617 | return GNUNET_OK; | ||
618 | } | ||
diff --git a/src/util/crypto_pow.c b/src/lib/util/crypto_pow.c index bfaaf555d..bfaaf555d 100644 --- a/src/util/crypto_pow.c +++ b/src/lib/util/crypto_pow.c | |||
diff --git a/src/util/crypto_random.c b/src/lib/util/crypto_random.c index 72474d04b..72474d04b 100644 --- a/src/util/crypto_random.c +++ b/src/lib/util/crypto_random.c | |||
diff --git a/src/util/crypto_rsa.c b/src/lib/util/crypto_rsa.c index 2c446d21a..2c446d21a 100644 --- a/src/util/crypto_rsa.c +++ b/src/lib/util/crypto_rsa.c | |||
diff --git a/src/util/crypto_symmetric.c b/src/lib/util/crypto_symmetric.c index a9217febd..a9217febd 100644 --- a/src/util/crypto_symmetric.c +++ b/src/lib/util/crypto_symmetric.c | |||
diff --git a/src/util/disk.c b/src/lib/util/disk.c index 567c2b5bc..567c2b5bc 100644 --- a/src/util/disk.c +++ b/src/lib/util/disk.c | |||
diff --git a/src/util/disk.h b/src/lib/util/disk.h index bca398e26..bca398e26 100644 --- a/src/util/disk.h +++ b/src/lib/util/disk.h | |||
diff --git a/src/util/dnsparser.c b/src/lib/util/dnsparser.c index dab38def7..dab38def7 100644 --- a/src/util/dnsparser.c +++ b/src/lib/util/dnsparser.c | |||
diff --git a/src/util/dnsstub.c b/src/lib/util/dnsstub.c index c259b51dd..c259b51dd 100644 --- a/src/util/dnsstub.c +++ b/src/lib/util/dnsstub.c | |||
diff --git a/src/util/getopt.c b/src/lib/util/getopt.c index b1737bbc7..b1737bbc7 100644 --- a/src/util/getopt.c +++ b/src/lib/util/getopt.c | |||
diff --git a/src/util/getopt_helpers.c b/src/lib/util/getopt_helpers.c index 31020f185..31020f185 100644 --- a/src/util/getopt_helpers.c +++ b/src/lib/util/getopt_helpers.c | |||
diff --git a/src/util/gnunet_error_codes.c b/src/lib/util/gnunet_error_codes.c index 11ce2d0c8..11ce2d0c8 100644 --- a/src/util/gnunet_error_codes.c +++ b/src/lib/util/gnunet_error_codes.c | |||
diff --git a/src/util/helper.c b/src/lib/util/helper.c index 1dd3e33e2..1dd3e33e2 100644 --- a/src/util/helper.c +++ b/src/lib/util/helper.c | |||
diff --git a/src/util/load.c b/src/lib/util/load.c index a64171bd4..a64171bd4 100644 --- a/src/util/load.c +++ b/src/lib/util/load.c | |||
diff --git a/src/util/meson.build b/src/lib/util/meson.build index 48a70cf0c..48a70cf0c 100644 --- a/src/util/meson.build +++ b/src/lib/util/meson.build | |||
diff --git a/src/util/mq.c b/src/lib/util/mq.c index de0cff0c2..de0cff0c2 100644 --- a/src/util/mq.c +++ b/src/lib/util/mq.c | |||
diff --git a/src/util/mst.c b/src/lib/util/mst.c index d8509b7ec..d8509b7ec 100644 --- a/src/util/mst.c +++ b/src/lib/util/mst.c | |||
diff --git a/src/util/nc.c b/src/lib/util/nc.c index 2a612917c..2a612917c 100644 --- a/src/util/nc.c +++ b/src/lib/util/nc.c | |||
diff --git a/src/util/network.c b/src/lib/util/network.c index 8c74c5626..8c74c5626 100644 --- a/src/util/network.c +++ b/src/lib/util/network.c | |||
diff --git a/src/util/nt.c b/src/lib/util/nt.c index 24471d9ad..24471d9ad 100644 --- a/src/util/nt.c +++ b/src/lib/util/nt.c | |||
diff --git a/src/util/op.c b/src/lib/util/op.c index a8fc3de4a..a8fc3de4a 100644 --- a/src/util/op.c +++ b/src/lib/util/op.c | |||
diff --git a/src/util/os_installation.c b/src/lib/util/os_installation.c index ff04a8a7f..ff04a8a7f 100644 --- a/src/util/os_installation.c +++ b/src/lib/util/os_installation.c | |||
diff --git a/src/util/os_network.c b/src/lib/util/os_network.c index ac9fa691f..ac9fa691f 100644 --- a/src/util/os_network.c +++ b/src/lib/util/os_network.c | |||
diff --git a/src/util/os_priority.c b/src/lib/util/os_priority.c index 63d18dbe4..63d18dbe4 100644 --- a/src/util/os_priority.c +++ b/src/lib/util/os_priority.c | |||
diff --git a/src/util/peer.c b/src/lib/util/peer.c index e5c15b098..e5c15b098 100644 --- a/src/util/peer.c +++ b/src/lib/util/peer.c | |||
diff --git a/src/util/perf_crypto_asymmetric.c b/src/lib/util/perf_crypto_asymmetric.c index c033a02ca..c033a02ca 100644 --- a/src/util/perf_crypto_asymmetric.c +++ b/src/lib/util/perf_crypto_asymmetric.c | |||
diff --git a/src/util/perf_crypto_cs.c b/src/lib/util/perf_crypto_cs.c index 43f32aae0..43f32aae0 100644 --- a/src/util/perf_crypto_cs.c +++ b/src/lib/util/perf_crypto_cs.c | |||
diff --git a/src/util/perf_crypto_ecc_dlog.c b/src/lib/util/perf_crypto_ecc_dlog.c index 698a3aafa..698a3aafa 100644 --- a/src/util/perf_crypto_ecc_dlog.c +++ b/src/lib/util/perf_crypto_ecc_dlog.c | |||
diff --git a/src/util/perf_crypto_hash.c b/src/lib/util/perf_crypto_hash.c index 4e37ef758..4e37ef758 100644 --- a/src/util/perf_crypto_hash.c +++ b/src/lib/util/perf_crypto_hash.c | |||
diff --git a/src/util/perf_crypto_paillier.c b/src/lib/util/perf_crypto_paillier.c index 53c717a66..53c717a66 100644 --- a/src/util/perf_crypto_paillier.c +++ b/src/lib/util/perf_crypto_paillier.c | |||
diff --git a/src/util/perf_crypto_rsa.c b/src/lib/util/perf_crypto_rsa.c index ab9f362cf..ab9f362cf 100644 --- a/src/util/perf_crypto_rsa.c +++ b/src/lib/util/perf_crypto_rsa.c | |||
diff --git a/src/util/perf_crypto_symmetric.c b/src/lib/util/perf_crypto_symmetric.c index 9be452015..9be452015 100644 --- a/src/util/perf_crypto_symmetric.c +++ b/src/lib/util/perf_crypto_symmetric.c | |||
diff --git a/src/util/perf_malloc.c b/src/lib/util/perf_malloc.c index 48a4a2ae7..48a4a2ae7 100644 --- a/src/util/perf_malloc.c +++ b/src/lib/util/perf_malloc.c | |||
diff --git a/src/util/perf_mq.c b/src/lib/util/perf_mq.c index 5c956e4e9..5c956e4e9 100644 --- a/src/util/perf_mq.c +++ b/src/lib/util/perf_mq.c | |||
diff --git a/src/util/perf_scheduler.c b/src/lib/util/perf_scheduler.c index af084e04a..af084e04a 100644 --- a/src/util/perf_scheduler.c +++ b/src/lib/util/perf_scheduler.c | |||
diff --git a/src/util/plugin.c b/src/lib/util/plugin.c index 62c2a1df0..62c2a1df0 100644 --- a/src/util/plugin.c +++ b/src/lib/util/plugin.c | |||
diff --git a/src/util/proc_compat.c b/src/lib/util/proc_compat.c index 0423a0d5c..0423a0d5c 100644 --- a/src/util/proc_compat.c +++ b/src/lib/util/proc_compat.c | |||
diff --git a/src/util/program.c b/src/lib/util/program.c index 21b616ee2..21b616ee2 100644 --- a/src/util/program.c +++ b/src/lib/util/program.c | |||
diff --git a/src/util/regex.c b/src/lib/util/regex.c index 282d3aa99..282d3aa99 100644 --- a/src/util/regex.c +++ b/src/lib/util/regex.c | |||
diff --git a/src/lib/util/resolver.conf b/src/lib/util/resolver.conf new file mode 100644 index 000000000..aae876952 --- /dev/null +++ b/src/lib/util/resolver.conf | |||
@@ -0,0 +1,20 @@ | |||
1 | [resolver] | ||
2 | START_ON_DEMAND = YES | ||
3 | #PORT = 2089 | ||
4 | HOSTNAME = localhost | ||
5 | BINARY = gnunet-service-resolver | ||
6 | ACCEPT_FROM = 127.0.0.1; | ||
7 | ACCEPT_FROM6 = ::1; | ||
8 | UNIXPATH = $GNUNET_RUNTIME_DIR/gnunet-service-resolver.sock | ||
9 | UNIX_MATCH_UID = NO | ||
10 | UNIX_MATCH_GID = NO | ||
11 | # DISABLE_SOCKET_FORWARDING = NO | ||
12 | # USERNAME = | ||
13 | # MAXBUF = | ||
14 | # TIMEOUT = | ||
15 | # DISABLEV6 = | ||
16 | # BINDTO = | ||
17 | # REJECT_FROM = | ||
18 | # REJECT_FROM6 = | ||
19 | # PREFIX = | ||
20 | |||
diff --git a/src/util/resolver.conf.in b/src/lib/util/resolver.conf.in index 6e2b9a869..6e2b9a869 100644 --- a/src/util/resolver.conf.in +++ b/src/lib/util/resolver.conf.in | |||
diff --git a/src/util/resolver.h b/src/lib/util/resolver.h index e487f6e6f..e487f6e6f 100644 --- a/src/util/resolver.h +++ b/src/lib/util/resolver.h | |||
diff --git a/src/util/resolver_api.c b/src/lib/util/resolver_api.c index 130363c77..130363c77 100644 --- a/src/util/resolver_api.c +++ b/src/lib/util/resolver_api.c | |||
diff --git a/src/util/scheduler.c b/src/lib/util/scheduler.c index 70193a0d2..70193a0d2 100644 --- a/src/util/scheduler.c +++ b/src/lib/util/scheduler.c | |||
diff --git a/src/util/service.c b/src/lib/util/service.c index 7aeabf687..7aeabf687 100644 --- a/src/util/service.c +++ b/src/lib/util/service.c | |||
diff --git a/src/util/signal.c b/src/lib/util/signal.c index 67849a7d6..67849a7d6 100644 --- a/src/util/signal.c +++ b/src/lib/util/signal.c | |||
diff --git a/src/util/socks.c b/src/lib/util/socks.c index ffde8a667..ffde8a667 100644 --- a/src/util/socks.c +++ b/src/lib/util/socks.c | |||
diff --git a/src/util/speedup.c b/src/lib/util/speedup.c index 02719e56e..02719e56e 100644 --- a/src/util/speedup.c +++ b/src/lib/util/speedup.c | |||
diff --git a/src/util/speedup.h b/src/lib/util/speedup.h index 505e73bf4..505e73bf4 100644 --- a/src/util/speedup.h +++ b/src/lib/util/speedup.h | |||
diff --git a/src/util/strings.c b/src/lib/util/strings.c index 86323bc83..86323bc83 100644 --- a/src/util/strings.c +++ b/src/lib/util/strings.c | |||
diff --git a/src/util/test_bio.c b/src/lib/util/test_bio.c index b407eccfe..b407eccfe 100644 --- a/src/util/test_bio.c +++ b/src/lib/util/test_bio.c | |||
diff --git a/src/util/test_child_management.c b/src/lib/util/test_child_management.c index 90cc74c72..90cc74c72 100644 --- a/src/util/test_child_management.c +++ b/src/lib/util/test_child_management.c | |||
diff --git a/src/util/test_client.c b/src/lib/util/test_client.c index 64c32f646..64c32f646 100644 --- a/src/util/test_client.c +++ b/src/lib/util/test_client.c | |||
diff --git a/src/util/test_client_data.conf b/src/lib/util/test_client_data.conf index fa9a0be03..fa9a0be03 100644 --- a/src/util/test_client_data.conf +++ b/src/lib/util/test_client_data.conf | |||
diff --git a/src/util/test_client_unix.conf b/src/lib/util/test_client_unix.conf index d3d90627d..d3d90627d 100644 --- a/src/util/test_client_unix.conf +++ b/src/lib/util/test_client_unix.conf | |||
diff --git a/src/util/test_common_allocation.c b/src/lib/util/test_common_allocation.c index d4cc4bb58..d4cc4bb58 100644 --- a/src/util/test_common_allocation.c +++ b/src/lib/util/test_common_allocation.c | |||
diff --git a/src/util/test_common_endian.c b/src/lib/util/test_common_endian.c index 2c11c594e..2c11c594e 100644 --- a/src/util/test_common_endian.c +++ b/src/lib/util/test_common_endian.c | |||
diff --git a/src/util/test_common_logging.c b/src/lib/util/test_common_logging.c index a2e49f20a..a2e49f20a 100644 --- a/src/util/test_common_logging.c +++ b/src/lib/util/test_common_logging.c | |||
diff --git a/src/util/test_common_logging_dummy.c b/src/lib/util/test_common_logging_dummy.c index 7e362c683..7e362c683 100644 --- a/src/util/test_common_logging_dummy.c +++ b/src/lib/util/test_common_logging_dummy.c | |||
diff --git a/src/util/test_common_logging_runtime_loglevels.c b/src/lib/util/test_common_logging_runtime_loglevels.c index f3f2fd64f..f3f2fd64f 100644 --- a/src/util/test_common_logging_runtime_loglevels.c +++ b/src/lib/util/test_common_logging_runtime_loglevels.c | |||
diff --git a/src/util/test_configuration.c b/src/lib/util/test_configuration.c index 75610fc74..75610fc74 100644 --- a/src/util/test_configuration.c +++ b/src/lib/util/test_configuration.c | |||
diff --git a/src/util/test_configuration_data.conf b/src/lib/util/test_configuration_data.conf index 93dfd128a..93dfd128a 100644 --- a/src/util/test_configuration_data.conf +++ b/src/lib/util/test_configuration_data.conf | |||
diff --git a/src/util/test_container_bloomfilter.c b/src/lib/util/test_container_bloomfilter.c index 244733dd9..244733dd9 100644 --- a/src/util/test_container_bloomfilter.c +++ b/src/lib/util/test_container_bloomfilter.c | |||
diff --git a/src/util/test_container_dll.c b/src/lib/util/test_container_dll.c index fcbef4e8b..fcbef4e8b 100644 --- a/src/util/test_container_dll.c +++ b/src/lib/util/test_container_dll.c | |||
diff --git a/src/util/test_container_heap.c b/src/lib/util/test_container_heap.c index f11070ed5..f11070ed5 100644 --- a/src/util/test_container_heap.c +++ b/src/lib/util/test_container_heap.c | |||
diff --git a/src/util/test_container_multihashmap.c b/src/lib/util/test_container_multihashmap.c index 233369257..233369257 100644 --- a/src/util/test_container_multihashmap.c +++ b/src/lib/util/test_container_multihashmap.c | |||
diff --git a/src/util/test_container_multihashmap32.c b/src/lib/util/test_container_multihashmap32.c index eab5ad795..eab5ad795 100644 --- a/src/util/test_container_multihashmap32.c +++ b/src/lib/util/test_container_multihashmap32.c | |||
diff --git a/src/util/test_container_multipeermap.c b/src/lib/util/test_container_multipeermap.c index 6639b05ea..6639b05ea 100644 --- a/src/util/test_container_multipeermap.c +++ b/src/lib/util/test_container_multipeermap.c | |||
diff --git a/src/util/test_crypto_crc.c b/src/lib/util/test_crypto_crc.c index d95eaf260..d95eaf260 100644 --- a/src/util/test_crypto_crc.c +++ b/src/lib/util/test_crypto_crc.c | |||
diff --git a/src/util/test_crypto_cs.c b/src/lib/util/test_crypto_cs.c index 6fd2361fb..6fd2361fb 100644 --- a/src/util/test_crypto_cs.c +++ b/src/lib/util/test_crypto_cs.c | |||
diff --git a/src/util/test_crypto_ecc_dlog.c b/src/lib/util/test_crypto_ecc_dlog.c index c3382a4fa..c3382a4fa 100644 --- a/src/util/test_crypto_ecc_dlog.c +++ b/src/lib/util/test_crypto_ecc_dlog.c | |||
diff --git a/src/util/test_crypto_ecdh_ecdsa.c b/src/lib/util/test_crypto_ecdh_ecdsa.c index 609f05282..609f05282 100644 --- a/src/util/test_crypto_ecdh_ecdsa.c +++ b/src/lib/util/test_crypto_ecdh_ecdsa.c | |||
diff --git a/src/util/test_crypto_ecdh_eddsa.c b/src/lib/util/test_crypto_ecdh_eddsa.c index 875f479c2..875f479c2 100644 --- a/src/util/test_crypto_ecdh_eddsa.c +++ b/src/lib/util/test_crypto_ecdh_eddsa.c | |||
diff --git a/src/util/test_crypto_ecdhe.c b/src/lib/util/test_crypto_ecdhe.c index cf59cfa64..cf59cfa64 100644 --- a/src/util/test_crypto_ecdhe.c +++ b/src/lib/util/test_crypto_ecdhe.c | |||
diff --git a/src/util/test_crypto_ecdsa.c b/src/lib/util/test_crypto_ecdsa.c index 9dc1f863d..9dc1f863d 100644 --- a/src/util/test_crypto_ecdsa.c +++ b/src/lib/util/test_crypto_ecdsa.c | |||
diff --git a/src/util/test_crypto_eddsa.c b/src/lib/util/test_crypto_eddsa.c index 820230fd2..820230fd2 100644 --- a/src/util/test_crypto_eddsa.c +++ b/src/lib/util/test_crypto_eddsa.c | |||
diff --git a/src/util/test_crypto_edx25519.c b/src/lib/util/test_crypto_edx25519.c index 85e235546..85e235546 100644 --- a/src/util/test_crypto_edx25519.c +++ b/src/lib/util/test_crypto_edx25519.c | |||
diff --git a/src/util/test_crypto_hash.c b/src/lib/util/test_crypto_hash.c index 337694a89..337694a89 100644 --- a/src/util/test_crypto_hash.c +++ b/src/lib/util/test_crypto_hash.c | |||
diff --git a/src/util/test_crypto_hash_context.c b/src/lib/util/test_crypto_hash_context.c index 08b63800f..08b63800f 100644 --- a/src/util/test_crypto_hash_context.c +++ b/src/lib/util/test_crypto_hash_context.c | |||
diff --git a/src/util/test_crypto_hkdf.c b/src/lib/util/test_crypto_hkdf.c index a9a4db7a0..a9a4db7a0 100644 --- a/src/util/test_crypto_hkdf.c +++ b/src/lib/util/test_crypto_hkdf.c | |||
diff --git a/src/util/test_crypto_kdf.c b/src/lib/util/test_crypto_kdf.c index 81e4b4451..81e4b4451 100644 --- a/src/util/test_crypto_kdf.c +++ b/src/lib/util/test_crypto_kdf.c | |||
diff --git a/src/util/test_crypto_paillier.c b/src/lib/util/test_crypto_paillier.c index 412ce5c23..412ce5c23 100644 --- a/src/util/test_crypto_paillier.c +++ b/src/lib/util/test_crypto_paillier.c | |||
diff --git a/src/util/test_crypto_random.c b/src/lib/util/test_crypto_random.c index b776aef18..b776aef18 100644 --- a/src/util/test_crypto_random.c +++ b/src/lib/util/test_crypto_random.c | |||
diff --git a/src/util/test_crypto_rsa.c b/src/lib/util/test_crypto_rsa.c index 9f2ddb66e..9f2ddb66e 100644 --- a/src/util/test_crypto_rsa.c +++ b/src/lib/util/test_crypto_rsa.c | |||
diff --git a/src/util/test_crypto_symmetric.c b/src/lib/util/test_crypto_symmetric.c index 4c8c2f0c2..4c8c2f0c2 100644 --- a/src/util/test_crypto_symmetric.c +++ b/src/lib/util/test_crypto_symmetric.c | |||
diff --git a/src/util/test_disk.c b/src/lib/util/test_disk.c index 35b4bd14a..35b4bd14a 100644 --- a/src/util/test_disk.c +++ b/src/lib/util/test_disk.c | |||
diff --git a/src/util/test_getopt.c b/src/lib/util/test_getopt.c index cad10504d..cad10504d 100644 --- a/src/util/test_getopt.c +++ b/src/lib/util/test_getopt.c | |||
diff --git a/src/util/test_hexcoder.c b/src/lib/util/test_hexcoder.c index e04631188..e04631188 100644 --- a/src/util/test_hexcoder.c +++ b/src/lib/util/test_hexcoder.c | |||
diff --git a/src/util/test_mq.c b/src/lib/util/test_mq.c index 522589daf..522589daf 100644 --- a/src/util/test_mq.c +++ b/src/lib/util/test_mq.c | |||
diff --git a/src/util/test_os_network.c b/src/lib/util/test_os_network.c index 74e98663b..74e98663b 100644 --- a/src/util/test_os_network.c +++ b/src/lib/util/test_os_network.c | |||
diff --git a/src/util/test_os_start_process.c b/src/lib/util/test_os_start_process.c index cdb1acf03..cdb1acf03 100644 --- a/src/util/test_os_start_process.c +++ b/src/lib/util/test_os_start_process.c | |||
diff --git a/src/util/test_peer.c b/src/lib/util/test_peer.c index ad4e6aac9..ad4e6aac9 100644 --- a/src/util/test_peer.c +++ b/src/lib/util/test_peer.c | |||
diff --git a/src/util/test_plugin.c b/src/lib/util/test_plugin.c index 0831f3068..0831f3068 100644 --- a/src/util/test_plugin.c +++ b/src/lib/util/test_plugin.c | |||
diff --git a/src/util/test_plugin_plug.c b/src/lib/util/test_plugin_plug.c index ed582517b..ed582517b 100644 --- a/src/util/test_plugin_plug.c +++ b/src/lib/util/test_plugin_plug.c | |||
diff --git a/src/util/test_program.c b/src/lib/util/test_program.c index 3d63b0336..3d63b0336 100644 --- a/src/util/test_program.c +++ b/src/lib/util/test_program.c | |||
diff --git a/src/util/test_program_data.conf b/src/lib/util/test_program_data.conf index fbf745644..fbf745644 100644 --- a/src/util/test_program_data.conf +++ b/src/lib/util/test_program_data.conf | |||
diff --git a/src/util/test_regex.c b/src/lib/util/test_regex.c index 968828755..968828755 100644 --- a/src/util/test_regex.c +++ b/src/lib/util/test_regex.c | |||
diff --git a/src/util/test_scheduler.c b/src/lib/util/test_scheduler.c index 4573518fd..4573518fd 100644 --- a/src/util/test_scheduler.c +++ b/src/lib/util/test_scheduler.c | |||
diff --git a/src/util/test_scheduler_delay.c b/src/lib/util/test_scheduler_delay.c index 41990272a..41990272a 100644 --- a/src/util/test_scheduler_delay.c +++ b/src/lib/util/test_scheduler_delay.c | |||
diff --git a/src/util/test_scheduler_hogging_cancel.c b/src/lib/util/test_scheduler_hogging_cancel.c index 7611338b3..7611338b3 100644 --- a/src/util/test_scheduler_hogging_cancel.c +++ b/src/lib/util/test_scheduler_hogging_cancel.c | |||
diff --git a/src/util/test_scheduler_hogging_priority.c b/src/lib/util/test_scheduler_hogging_priority.c index 217a39ce7..217a39ce7 100644 --- a/src/util/test_scheduler_hogging_priority.c +++ b/src/lib/util/test_scheduler_hogging_priority.c | |||
diff --git a/src/util/test_service.c b/src/lib/util/test_service.c index 198ae68ec..198ae68ec 100644 --- a/src/util/test_service.c +++ b/src/lib/util/test_service.c | |||
diff --git a/src/util/test_service_data.conf b/src/lib/util/test_service_data.conf index 3263a52c0..3263a52c0 100644 --- a/src/util/test_service_data.conf +++ b/src/lib/util/test_service_data.conf | |||
diff --git a/src/util/test_socks.c b/src/lib/util/test_socks.c index 680ecada5..680ecada5 100644 --- a/src/util/test_socks.c +++ b/src/lib/util/test_socks.c | |||
diff --git a/src/util/test_speedup.c b/src/lib/util/test_speedup.c index 58d78641b..58d78641b 100644 --- a/src/util/test_speedup.c +++ b/src/lib/util/test_speedup.c | |||
diff --git a/src/util/test_speedup_data.conf b/src/lib/util/test_speedup_data.conf index 699cdc933..699cdc933 100644 --- a/src/util/test_speedup_data.conf +++ b/src/lib/util/test_speedup_data.conf | |||
diff --git a/src/util/test_strings.c b/src/lib/util/test_strings.c index 0e39b9958..0e39b9958 100644 --- a/src/util/test_strings.c +++ b/src/lib/util/test_strings.c | |||
diff --git a/src/util/test_strings_to_data.c b/src/lib/util/test_strings_to_data.c index 75cbd135d..75cbd135d 100644 --- a/src/util/test_strings_to_data.c +++ b/src/lib/util/test_strings_to_data.c | |||
diff --git a/src/util/test_time.c b/src/lib/util/test_time.c index 35f270a44..35f270a44 100644 --- a/src/util/test_time.c +++ b/src/lib/util/test_time.c | |||
diff --git a/src/util/test_tun.c b/src/lib/util/test_tun.c index 1086ef3ca..1086ef3ca 100644 --- a/src/util/test_tun.c +++ b/src/lib/util/test_tun.c | |||
diff --git a/src/util/test_uri.c b/src/lib/util/test_uri.c index d8fa38e96..d8fa38e96 100644 --- a/src/util/test_uri.c +++ b/src/lib/util/test_uri.c | |||
diff --git a/src/util/time.c b/src/lib/util/time.c index 84957c6a8..84957c6a8 100644 --- a/src/util/time.c +++ b/src/lib/util/time.c | |||
diff --git a/src/util/tun.c b/src/lib/util/tun.c index c4ac6ff88..c4ac6ff88 100644 --- a/src/util/tun.c +++ b/src/lib/util/tun.c | |||
diff --git a/src/util/uri.c b/src/lib/util/uri.c index b09968581..b09968581 100644 --- a/src/util/uri.c +++ b/src/lib/util/uri.c | |||
diff --git a/src/util/util.conf b/src/lib/util/util.conf index 4f0860a49..4f0860a49 100644 --- a/src/util/util.conf +++ b/src/lib/util/util.conf | |||
diff --git a/src/util/util.supp b/src/lib/util/util.supp index f04775cac..f04775cac 100644 --- a/src/util/util.supp +++ b/src/lib/util/util.supp | |||
diff --git a/src/messenger/Makefile.am b/src/messenger/Makefile.am index 656017548..1af950b01 100644 --- a/src/messenger/Makefile.am +++ b/src/messenger/Makefile.am | |||
@@ -17,7 +17,7 @@ plugin_LTLIBRARIES = \ | |||
17 | libgnunet_plugin_gnsrecord_messenger_la_SOURCES = \ | 17 | libgnunet_plugin_gnsrecord_messenger_la_SOURCES = \ |
18 | plugin_gnsrecord_messenger.c | 18 | plugin_gnsrecord_messenger.c |
19 | libgnunet_plugin_gnsrecord_messenger_la_LIBADD = \ | 19 | libgnunet_plugin_gnsrecord_messenger_la_LIBADD = \ |
20 | $(top_builddir)/src/util/libgnunetutil.la \ | 20 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
21 | $(LTLIBINTL) | 21 | $(LTLIBINTL) |
22 | libgnunet_plugin_gnsrecord_messenger_la_LDFLAGS = \ | 22 | libgnunet_plugin_gnsrecord_messenger_la_LDFLAGS = \ |
23 | $(GN_PLUGIN_LDFLAGS) | 23 | $(GN_PLUGIN_LDFLAGS) |
@@ -52,7 +52,7 @@ libgnunetmessenger_la_SOURCES = \ | |||
52 | messenger_api_handle.c messenger_api_handle.h \ | 52 | messenger_api_handle.c messenger_api_handle.h \ |
53 | messenger_api_room.c messenger_api_room.h | 53 | messenger_api_room.c messenger_api_room.h |
54 | libgnunetmessenger_la_LIBADD = \ | 54 | libgnunetmessenger_la_LIBADD = \ |
55 | $(top_builddir)/src/util/libgnunetutil.la \ | 55 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
56 | $(top_builddir)/src/cadet/libgnunetcadet.la \ | 56 | $(top_builddir)/src/cadet/libgnunetcadet.la \ |
57 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 57 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
58 | $(XLIB) \ | 58 | $(XLIB) \ |
@@ -65,7 +65,7 @@ gnunet_messenger_SOURCES = \ | |||
65 | gnunet-messenger.c | 65 | gnunet-messenger.c |
66 | gnunet_messenger_LDADD = \ | 66 | gnunet_messenger_LDADD = \ |
67 | libgnunetmessenger.la \ | 67 | libgnunetmessenger.la \ |
68 | $(top_builddir)/src/util/libgnunetutil.la | 68 | $(top_builddir)/src/lib/util/libgnunetutil.la |
69 | gnunet_messenger_LDFLAGS = \ | 69 | gnunet_messenger_LDFLAGS = \ |
70 | $(GN_LIBINTL) | 70 | $(GN_LIBINTL) |
71 | 71 | ||
@@ -92,7 +92,7 @@ gnunet_service_messenger_SOURCES = \ | |||
92 | gnunet-service-messenger_tunnel.c gnunet-service-messenger_tunnel.h | 92 | gnunet-service-messenger_tunnel.c gnunet-service-messenger_tunnel.h |
93 | gnunet_service_messenger_LDADD = \ | 93 | gnunet_service_messenger_LDADD = \ |
94 | libgnunetmessenger.la \ | 94 | libgnunetmessenger.la \ |
95 | $(top_builddir)/src/util/libgnunetutil.la \ | 95 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
96 | $(top_builddir)/src/cadet/libgnunetcadet.la \ | 96 | $(top_builddir)/src/cadet/libgnunetcadet.la \ |
97 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 97 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
98 | $(GN_LIBINTL) | 98 | $(GN_LIBINTL) |
@@ -110,14 +110,14 @@ test_messenger_api_SOURCES = \ | |||
110 | test_messenger_api_LDADD = \ | 110 | test_messenger_api_LDADD = \ |
111 | libgnunetmessenger.la \ | 111 | libgnunetmessenger.la \ |
112 | $(top_builddir)/src/testing/libgnunettesting.la \ | 112 | $(top_builddir)/src/testing/libgnunettesting.la \ |
113 | $(top_builddir)/src/util/libgnunetutil.la | 113 | $(top_builddir)/src/lib/util/libgnunetutil.la |
114 | 114 | ||
115 | test_messenger_anonymous_SOURCES = \ | 115 | test_messenger_anonymous_SOURCES = \ |
116 | test_messenger_anonymous.c | 116 | test_messenger_anonymous.c |
117 | test_messenger_anonymous_LDADD = \ | 117 | test_messenger_anonymous_LDADD = \ |
118 | libgnunetmessenger.la \ | 118 | libgnunetmessenger.la \ |
119 | $(top_builddir)/src/testing/libgnunettesting.la \ | 119 | $(top_builddir)/src/testing/libgnunettesting.la \ |
120 | $(top_builddir)/src/util/libgnunetutil.la | 120 | $(top_builddir)/src/lib/util/libgnunetutil.la |
121 | 121 | ||
122 | EXTRA_DIST = \ | 122 | EXTRA_DIST = \ |
123 | test_messenger_api.conf | 123 | test_messenger_api.conf |
diff --git a/src/messenger/gnunet-service-messenger.c b/src/messenger/gnunet-service-messenger.c index f0bb853d7..fedaa2f60 100644 --- a/src/messenger/gnunet-service-messenger.c +++ b/src/messenger/gnunet-service-messenger.c | |||
@@ -213,14 +213,14 @@ check_send_message (void *cls, | |||
213 | 213 | ||
214 | const uint16_t length = full_length - sizeof(*msg); | 214 | const uint16_t length = full_length - sizeof(*msg); |
215 | const char *buffer = ((const char*) msg) + sizeof(*msg); | 215 | const char *buffer = ((const char*) msg) + sizeof(*msg); |
216 | struct GNUNET_IDENTITY_PublicKey public_key; | 216 | struct GNUNET_CRYPTO_PublicKey public_key; |
217 | 217 | ||
218 | 218 | ||
219 | size_t key_length = 0; | 219 | size_t key_length = 0; |
220 | 220 | ||
221 | if ((flags & GNUNET_MESSENGER_FLAG_PRIVATE)) | 221 | if ((flags & GNUNET_MESSENGER_FLAG_PRIVATE)) |
222 | if (GNUNET_SYSERR == | 222 | if (GNUNET_SYSERR == |
223 | GNUNET_IDENTITY_read_public_key_from_buffer (buffer, length, | 223 | GNUNET_CRYPTO_read_public_key_from_buffer (buffer, length, |
224 | &public_key, | 224 | &public_key, |
225 | &key_length)) | 225 | &key_length)) |
226 | return GNUNET_NO; | 226 | return GNUNET_NO; |
@@ -259,12 +259,12 @@ handle_send_message (void *cls, | |||
259 | const uint16_t length = ntohs (msg->header.size) - sizeof(*msg); | 259 | const uint16_t length = ntohs (msg->header.size) - sizeof(*msg); |
260 | size_t key_length = 0; | 260 | size_t key_length = 0; |
261 | 261 | ||
262 | struct GNUNET_IDENTITY_PublicKey public_key; | 262 | struct GNUNET_CRYPTO_PublicKey public_key; |
263 | 263 | ||
264 | if (flags & GNUNET_MESSENGER_FLAG_PRIVATE) | 264 | if (flags & GNUNET_MESSENGER_FLAG_PRIVATE) |
265 | { | 265 | { |
266 | GNUNET_assert (GNUNET_SYSERR != | 266 | GNUNET_assert (GNUNET_SYSERR != |
267 | GNUNET_IDENTITY_read_public_key_from_buffer (buffer, | 267 | GNUNET_CRYPTO_read_public_key_from_buffer (buffer, |
268 | length, | 268 | length, |
269 | &public_key, | 269 | &public_key, |
270 | &key_length)); | 270 | &key_length)); |
diff --git a/src/messenger/gnunet-service-messenger_ego_store.c b/src/messenger/gnunet-service-messenger_ego_store.c index 3eb313b08..a1ffdddab 100644 --- a/src/messenger/gnunet-service-messenger_ego_store.c +++ b/src/messenger/gnunet-service-messenger_ego_store.c | |||
@@ -139,7 +139,7 @@ iterate_create_ego (void *cls, | |||
139 | 139 | ||
140 | static void | 140 | static void |
141 | callback_ego_create (void *cls, | 141 | callback_ego_create (void *cls, |
142 | const struct GNUNET_IDENTITY_PrivateKey *key, | 142 | const struct GNUNET_CRYPTO_PrivateKey *key, |
143 | enum GNUNET_ErrorCode ec) | 143 | enum GNUNET_ErrorCode ec) |
144 | { | 144 | { |
145 | struct GNUNET_MESSENGER_EgoOperation *element = cls; | 145 | struct GNUNET_MESSENGER_EgoOperation *element = cls; |
@@ -190,7 +190,7 @@ create_store_ego (struct GNUNET_MESSENGER_EgoStore *store, | |||
190 | store->identity, | 190 | store->identity, |
191 | identifier, | 191 | identifier, |
192 | NULL, | 192 | NULL, |
193 | GNUNET_IDENTITY_TYPE_ECDSA, | 193 | GNUNET_PUBLIC_KEY_TYPE_ECDSA, |
194 | callback_ego_create, | 194 | callback_ego_create, |
195 | element | 195 | element |
196 | ); | 196 | ); |
@@ -310,7 +310,7 @@ lookup_store_ego(struct GNUNET_MESSENGER_EgoStore *store, | |||
310 | struct GNUNET_MESSENGER_Ego* | 310 | struct GNUNET_MESSENGER_Ego* |
311 | update_store_ego (struct GNUNET_MESSENGER_EgoStore *store, | 311 | update_store_ego (struct GNUNET_MESSENGER_EgoStore *store, |
312 | const char *identifier, | 312 | const char *identifier, |
313 | const struct GNUNET_IDENTITY_PrivateKey *key) | 313 | const struct GNUNET_CRYPTO_PrivateKey *key) |
314 | { | 314 | { |
315 | GNUNET_assert ((store) && (identifier) && (key)); | 315 | GNUNET_assert ((store) && (identifier) && (key)); |
316 | 316 | ||
@@ -329,7 +329,7 @@ update_store_ego (struct GNUNET_MESSENGER_EgoStore *store, | |||
329 | 329 | ||
330 | GNUNET_memcpy(&(ego->priv), key, sizeof(*key)); | 330 | GNUNET_memcpy(&(ego->priv), key, sizeof(*key)); |
331 | 331 | ||
332 | if (GNUNET_OK != GNUNET_IDENTITY_key_get_public (key, &(ego->pub))) | 332 | if (GNUNET_OK != GNUNET_CRYPTO_key_get_public (key, &(ego->pub))) |
333 | GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "Updating invalid ego key failed!\n"); | 333 | GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "Updating invalid ego key failed!\n"); |
334 | 334 | ||
335 | return ego; | 335 | return ego; |
diff --git a/src/messenger/gnunet-service-messenger_ego_store.h b/src/messenger/gnunet-service-messenger_ego_store.h index a5f8a69d8..bf901bf5e 100644 --- a/src/messenger/gnunet-service-messenger_ego_store.h +++ b/src/messenger/gnunet-service-messenger_ego_store.h | |||
@@ -165,7 +165,7 @@ lookup_store_ego (struct GNUNET_MESSENGER_EgoStore *store, | |||
165 | struct GNUNET_MESSENGER_Ego* | 165 | struct GNUNET_MESSENGER_Ego* |
166 | update_store_ego (struct GNUNET_MESSENGER_EgoStore *store, | 166 | update_store_ego (struct GNUNET_MESSENGER_EgoStore *store, |
167 | const char *identifier, | 167 | const char *identifier, |
168 | const struct GNUNET_IDENTITY_PrivateKey *key); | 168 | const struct GNUNET_CRYPTO_PrivateKey *key); |
169 | 169 | ||
170 | /** | 170 | /** |
171 | * Deletes the registration of an EGO in a <i>store</i> under | 171 | * Deletes the registration of an EGO in a <i>store</i> under |
diff --git a/src/messenger/gnunet-service-messenger_handle.c b/src/messenger/gnunet-service-messenger_handle.c index 17692761d..764331c4a 100644 --- a/src/messenger/gnunet-service-messenger_handle.c +++ b/src/messenger/gnunet-service-messenger_handle.c | |||
@@ -217,7 +217,7 @@ change_handle_ego (struct GNUNET_MESSENGER_SrvHandle *handle, | |||
217 | 217 | ||
218 | ego = get_srv_handle_ego (handle); | 218 | ego = get_srv_handle_ego (handle); |
219 | 219 | ||
220 | const uint16_t length = GNUNET_IDENTITY_public_key_get_length(&(ego->pub)); | 220 | const uint16_t length = GNUNET_CRYPTO_public_key_get_length(&(ego->pub)); |
221 | 221 | ||
222 | struct GNUNET_MESSENGER_KeyMessage *msg; | 222 | struct GNUNET_MESSENGER_KeyMessage *msg; |
223 | struct GNUNET_MQ_Envelope *env; | 223 | struct GNUNET_MQ_Envelope *env; |
@@ -226,7 +226,7 @@ change_handle_ego (struct GNUNET_MESSENGER_SrvHandle *handle, | |||
226 | 226 | ||
227 | char *extra = ((char*) msg) + sizeof(*msg); | 227 | char *extra = ((char*) msg) + sizeof(*msg); |
228 | 228 | ||
229 | if (GNUNET_IDENTITY_write_public_key_to_buffer(&(ego->pub), extra, length) < 0) | 229 | if (GNUNET_CRYPTO_write_public_key_to_buffer(&(ego->pub), extra, length) < 0) |
230 | GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "Could not write key to buffer.\n"); | 230 | GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "Could not write key to buffer.\n"); |
231 | 231 | ||
232 | GNUNET_MQ_send (handle->mq, env); | 232 | GNUNET_MQ_send (handle->mq, env); |
@@ -540,7 +540,7 @@ notify_srv_handle_message (struct GNUNET_MESSENGER_SrvHandle *handle, | |||
540 | return; | 540 | return; |
541 | } | 541 | } |
542 | 542 | ||
543 | const struct GNUNET_IDENTITY_PublicKey *pubkey = get_contact_key(session->contact); | 543 | const struct GNUNET_CRYPTO_PublicKey *pubkey = get_contact_key(session->contact); |
544 | 544 | ||
545 | struct GNUNET_HashCode sender; | 545 | struct GNUNET_HashCode sender; |
546 | GNUNET_CRYPTO_hash(pubkey, sizeof(*pubkey), &sender); | 546 | GNUNET_CRYPTO_hash(pubkey, sizeof(*pubkey), &sender); |
diff --git a/src/messenger/gnunet-service-messenger_member.c b/src/messenger/gnunet-service-messenger_member.c index 444148831..96b26cfb9 100644 --- a/src/messenger/gnunet-service-messenger_member.c +++ b/src/messenger/gnunet-service-messenger_member.c | |||
@@ -274,7 +274,7 @@ sync_member_contacts (struct GNUNET_MESSENGER_Member *member) | |||
274 | 274 | ||
275 | struct GNUNET_MESSENGER_MemberSession* | 275 | struct GNUNET_MESSENGER_MemberSession* |
276 | get_member_session (const struct GNUNET_MESSENGER_Member *member, | 276 | get_member_session (const struct GNUNET_MESSENGER_Member *member, |
277 | const struct GNUNET_IDENTITY_PublicKey *public_key) | 277 | const struct GNUNET_CRYPTO_PublicKey *public_key) |
278 | { | 278 | { |
279 | GNUNET_assert ((member) && (public_key)); | 279 | GNUNET_assert ((member) && (public_key)); |
280 | 280 | ||
@@ -308,7 +308,7 @@ iterate_search_session (void *cls, | |||
308 | 308 | ||
309 | static struct GNUNET_MESSENGER_MemberSession* | 309 | static struct GNUNET_MESSENGER_MemberSession* |
310 | try_member_session (struct GNUNET_MESSENGER_Member *member, | 310 | try_member_session (struct GNUNET_MESSENGER_Member *member, |
311 | const struct GNUNET_IDENTITY_PublicKey *public_key) | 311 | const struct GNUNET_CRYPTO_PublicKey *public_key) |
312 | { | 312 | { |
313 | struct GNUNET_MESSENGER_MemberSession* session = get_member_session(member, public_key); | 313 | struct GNUNET_MESSENGER_MemberSession* session = get_member_session(member, public_key); |
314 | 314 | ||
@@ -356,7 +356,7 @@ add_member_session (struct GNUNET_MESSENGER_Member *member, | |||
356 | 356 | ||
357 | GNUNET_assert((member) && (session->member == member)); | 357 | GNUNET_assert((member) && (session->member == member)); |
358 | 358 | ||
359 | const struct GNUNET_IDENTITY_PublicKey *public_key = get_member_session_public_key(session); | 359 | const struct GNUNET_CRYPTO_PublicKey *public_key = get_member_session_public_key(session); |
360 | 360 | ||
361 | struct GNUNET_HashCode hash; | 361 | struct GNUNET_HashCode hash; |
362 | GNUNET_CRYPTO_hash(public_key, sizeof(*public_key), &hash); | 362 | GNUNET_CRYPTO_hash(public_key, sizeof(*public_key), &hash); |
@@ -374,7 +374,7 @@ remove_member_session (struct GNUNET_MESSENGER_Member *member, | |||
374 | { | 374 | { |
375 | GNUNET_assert ((member) && (session) && (session->member == member)); | 375 | GNUNET_assert ((member) && (session) && (session->member == member)); |
376 | 376 | ||
377 | const struct GNUNET_IDENTITY_PublicKey *public_key = get_member_session_public_key(session); | 377 | const struct GNUNET_CRYPTO_PublicKey *public_key = get_member_session_public_key(session); |
378 | 378 | ||
379 | struct GNUNET_HashCode hash; | 379 | struct GNUNET_HashCode hash; |
380 | GNUNET_CRYPTO_hash(public_key, sizeof(*public_key), &hash); | 380 | GNUNET_CRYPTO_hash(public_key, sizeof(*public_key), &hash); |
diff --git a/src/messenger/gnunet-service-messenger_member.h b/src/messenger/gnunet-service-messenger_member.h index 0c5870fd3..c06be1df7 100644 --- a/src/messenger/gnunet-service-messenger_member.h +++ b/src/messenger/gnunet-service-messenger_member.h | |||
@@ -125,7 +125,7 @@ sync_member_contacts (struct GNUNET_MESSENGER_Member *member); | |||
125 | */ | 125 | */ |
126 | struct GNUNET_MESSENGER_MemberSession* | 126 | struct GNUNET_MESSENGER_MemberSession* |
127 | get_member_session (const struct GNUNET_MESSENGER_Member *member, | 127 | get_member_session (const struct GNUNET_MESSENGER_Member *member, |
128 | const struct GNUNET_IDENTITY_PublicKey *public_key); | 128 | const struct GNUNET_CRYPTO_PublicKey *public_key); |
129 | 129 | ||
130 | /** | 130 | /** |
131 | * Returns the member session of a <i>member</i> using a public key which can verify | 131 | * Returns the member session of a <i>member</i> using a public key which can verify |
diff --git a/src/messenger/gnunet-service-messenger_member_session.c b/src/messenger/gnunet-service-messenger_member_session.c index 519ac6f05..8ae1244c4 100644 --- a/src/messenger/gnunet-service-messenger_member_session.c +++ b/src/messenger/gnunet-service-messenger_member_session.c | |||
@@ -33,7 +33,7 @@ | |||
33 | 33 | ||
34 | struct GNUNET_MESSENGER_MemberSession* | 34 | struct GNUNET_MESSENGER_MemberSession* |
35 | create_member_session (struct GNUNET_MESSENGER_Member *member, | 35 | create_member_session (struct GNUNET_MESSENGER_Member *member, |
36 | const struct GNUNET_IDENTITY_PublicKey *pubkey) | 36 | const struct GNUNET_CRYPTO_PublicKey *pubkey) |
37 | { | 37 | { |
38 | if ((!member) || (!pubkey) || (!(member->store))) | 38 | if ((!member) || (!pubkey) || (!(member->store))) |
39 | return NULL; | 39 | return NULL; |
@@ -354,7 +354,7 @@ get_member_session_id (const struct GNUNET_MESSENGER_MemberSession* session) | |||
354 | return get_member_id(session->member); | 354 | return get_member_id(session->member); |
355 | } | 355 | } |
356 | 356 | ||
357 | const struct GNUNET_IDENTITY_PublicKey* | 357 | const struct GNUNET_CRYPTO_PublicKey* |
358 | get_member_session_public_key (const struct GNUNET_MESSENGER_MemberSession* session) | 358 | get_member_session_public_key (const struct GNUNET_MESSENGER_MemberSession* session) |
359 | { | 359 | { |
360 | GNUNET_assert(session); | 360 | GNUNET_assert(session); |
@@ -536,9 +536,9 @@ load_member_session (struct GNUNET_MESSENGER_Member *member, | |||
536 | if (GNUNET_OK != GNUNET_CONFIGURATION_get_value_string(cfg, "session", "key", &key_data)) | 536 | if (GNUNET_OK != GNUNET_CONFIGURATION_get_value_string(cfg, "session", "key", &key_data)) |
537 | goto destroy_config; | 537 | goto destroy_config; |
538 | 538 | ||
539 | struct GNUNET_IDENTITY_PublicKey key; | 539 | struct GNUNET_CRYPTO_PublicKey key; |
540 | 540 | ||
541 | enum GNUNET_GenericReturnValue key_return = GNUNET_IDENTITY_public_key_from_string(key_data, &key); | 541 | enum GNUNET_GenericReturnValue key_return = GNUNET_CRYPTO_public_key_from_string(key_data, &key); |
542 | 542 | ||
543 | GNUNET_free(key_data); | 543 | GNUNET_free(key_data); |
544 | 544 | ||
@@ -625,9 +625,9 @@ load_member_session_next (struct GNUNET_MESSENGER_MemberSession *session, | |||
625 | if (GNUNET_OK != GNUNET_CONFIGURATION_get_value_string(cfg, "session", "next_key", &key_data)) | 625 | if (GNUNET_OK != GNUNET_CONFIGURATION_get_value_string(cfg, "session", "next_key", &key_data)) |
626 | goto destroy_config; | 626 | goto destroy_config; |
627 | 627 | ||
628 | struct GNUNET_IDENTITY_PublicKey next_key; | 628 | struct GNUNET_CRYPTO_PublicKey next_key; |
629 | 629 | ||
630 | enum GNUNET_GenericReturnValue key_return = GNUNET_IDENTITY_public_key_from_string(key_data, &next_key); | 630 | enum GNUNET_GenericReturnValue key_return = GNUNET_CRYPTO_public_key_from_string(key_data, &next_key); |
631 | 631 | ||
632 | GNUNET_free(key_data); | 632 | GNUNET_free(key_data); |
633 | 633 | ||
@@ -710,7 +710,7 @@ save_member_session (struct GNUNET_MESSENGER_MemberSession *session, | |||
710 | 710 | ||
711 | struct GNUNET_CONFIGURATION_Handle *cfg = GNUNET_CONFIGURATION_create (); | 711 | struct GNUNET_CONFIGURATION_Handle *cfg = GNUNET_CONFIGURATION_create (); |
712 | 712 | ||
713 | char *key_data = GNUNET_IDENTITY_public_key_to_string(get_member_session_public_key(session)); | 713 | char *key_data = GNUNET_CRYPTO_public_key_to_string(get_member_session_public_key(session)); |
714 | 714 | ||
715 | if (key_data) | 715 | if (key_data) |
716 | { | 716 | { |
@@ -732,7 +732,7 @@ save_member_session (struct GNUNET_MESSENGER_MemberSession *session, | |||
732 | GNUNET_free(next_id_data); | 732 | GNUNET_free(next_id_data); |
733 | } | 733 | } |
734 | 734 | ||
735 | key_data = GNUNET_IDENTITY_public_key_to_string(get_member_session_public_key(session->next)); | 735 | key_data = GNUNET_CRYPTO_public_key_to_string(get_member_session_public_key(session->next)); |
736 | 736 | ||
737 | if (key_data) | 737 | if (key_data) |
738 | { | 738 | { |
diff --git a/src/messenger/gnunet-service-messenger_member_session.h b/src/messenger/gnunet-service-messenger_member_session.h index 9b4065d05..fad1ab041 100644 --- a/src/messenger/gnunet-service-messenger_member_session.h +++ b/src/messenger/gnunet-service-messenger_member_session.h | |||
@@ -38,7 +38,7 @@ | |||
38 | struct GNUNET_MESSENGER_MemberSession { | 38 | struct GNUNET_MESSENGER_MemberSession { |
39 | struct GNUNET_MESSENGER_Member *member; | 39 | struct GNUNET_MESSENGER_Member *member; |
40 | 40 | ||
41 | struct GNUNET_IDENTITY_PublicKey public_key; | 41 | struct GNUNET_CRYPTO_PublicKey public_key; |
42 | struct GNUNET_HashCode context; | 42 | struct GNUNET_HashCode context; |
43 | 43 | ||
44 | struct GNUNET_MESSENGER_Contact *contact; | 44 | struct GNUNET_MESSENGER_Contact *contact; |
@@ -67,7 +67,7 @@ struct GNUNET_MESSENGER_MemberSession { | |||
67 | */ | 67 | */ |
68 | struct GNUNET_MESSENGER_MemberSession* | 68 | struct GNUNET_MESSENGER_MemberSession* |
69 | create_member_session (struct GNUNET_MESSENGER_Member *member, | 69 | create_member_session (struct GNUNET_MESSENGER_Member *member, |
70 | const struct GNUNET_IDENTITY_PublicKey *pubkey); | 70 | const struct GNUNET_CRYPTO_PublicKey *pubkey); |
71 | 71 | ||
72 | /** | 72 | /** |
73 | * Creates and allocates a new member session closing and replacing a given | 73 | * Creates and allocates a new member session closing and replacing a given |
@@ -174,7 +174,7 @@ get_member_session_id (const struct GNUNET_MESSENGER_MemberSession* session); | |||
174 | * @param[in] session Member session | 174 | * @param[in] session Member session |
175 | * @return Public key of EGO | 175 | * @return Public key of EGO |
176 | */ | 176 | */ |
177 | const struct GNUNET_IDENTITY_PublicKey* | 177 | const struct GNUNET_CRYPTO_PublicKey* |
178 | get_member_session_public_key (const struct GNUNET_MESSENGER_MemberSession* session); | 178 | get_member_session_public_key (const struct GNUNET_MESSENGER_MemberSession* session); |
179 | 179 | ||
180 | /** | 180 | /** |
diff --git a/src/messenger/gnunet-service-messenger_member_store.h b/src/messenger/gnunet-service-messenger_member_store.h index 05b00f39a..337ddcf78 100644 --- a/src/messenger/gnunet-service-messenger_member_store.h +++ b/src/messenger/gnunet-service-messenger_member_store.h | |||
@@ -45,7 +45,7 @@ struct GNUNET_MESSENGER_MemberStore | |||
45 | 45 | ||
46 | typedef int (*GNUNET_MESSENGER_MemberIteratorCallback) ( | 46 | typedef int (*GNUNET_MESSENGER_MemberIteratorCallback) ( |
47 | void *cls, | 47 | void *cls, |
48 | const struct GNUNET_IDENTITY_PublicKey *public_key, | 48 | const struct GNUNET_CRYPTO_PublicKey *public_key, |
49 | struct GNUNET_MESSENGER_MemberSession *session); | 49 | struct GNUNET_MESSENGER_MemberSession *session); |
50 | 50 | ||
51 | /** | 51 | /** |
diff --git a/src/messenger/gnunet-service-messenger_message_kind.c b/src/messenger/gnunet-service-messenger_message_kind.c index 828e84d4f..d2923a5e3 100644 --- a/src/messenger/gnunet-service-messenger_message_kind.c +++ b/src/messenger/gnunet-service-messenger_message_kind.c | |||
@@ -84,7 +84,7 @@ create_message_name (const char *name) | |||
84 | } | 84 | } |
85 | 85 | ||
86 | struct GNUNET_MESSENGER_Message* | 86 | struct GNUNET_MESSENGER_Message* |
87 | create_message_key (const struct GNUNET_IDENTITY_PrivateKey *key) | 87 | create_message_key (const struct GNUNET_CRYPTO_PrivateKey *key) |
88 | { | 88 | { |
89 | if (!key) | 89 | if (!key) |
90 | return NULL; | 90 | return NULL; |
@@ -94,7 +94,7 @@ create_message_key (const struct GNUNET_IDENTITY_PrivateKey *key) | |||
94 | if (!message) | 94 | if (!message) |
95 | return NULL; | 95 | return NULL; |
96 | 96 | ||
97 | GNUNET_IDENTITY_key_get_public (key, &(message->body.key.key)); | 97 | GNUNET_CRYPTO_key_get_public (key, &(message->body.key.key)); |
98 | return message; | 98 | return message; |
99 | } | 99 | } |
100 | 100 | ||
diff --git a/src/messenger/gnunet-service-messenger_message_kind.h b/src/messenger/gnunet-service-messenger_message_kind.h index 102a70e33..d50317844 100644 --- a/src/messenger/gnunet-service-messenger_message_kind.h +++ b/src/messenger/gnunet-service-messenger_message_kind.h | |||
@@ -82,7 +82,7 @@ create_message_name (const char *name); | |||
82 | * @return New message | 82 | * @return New message |
83 | */ | 83 | */ |
84 | struct GNUNET_MESSENGER_Message* | 84 | struct GNUNET_MESSENGER_Message* |
85 | create_message_key (const struct GNUNET_IDENTITY_PrivateKey *key); | 85 | create_message_key (const struct GNUNET_CRYPTO_PrivateKey *key); |
86 | 86 | ||
87 | /** | 87 | /** |
88 | * Creates and allocates a new peer message containing a services peer identity. | 88 | * Creates and allocates a new peer message containing a services peer identity. |
diff --git a/src/messenger/gnunet-service-messenger_message_recv.c b/src/messenger/gnunet-service-messenger_message_recv.c index 94202fdca..ea309f893 100644 --- a/src/messenger/gnunet-service-messenger_message_recv.c +++ b/src/messenger/gnunet-service-messenger_message_recv.c | |||
@@ -58,7 +58,7 @@ forward_about_members (struct GNUNET_MESSENGER_SrvRoom *room, | |||
58 | 58 | ||
59 | static int | 59 | static int |
60 | iterate_forward_members (void *cls, | 60 | iterate_forward_members (void *cls, |
61 | const struct GNUNET_IDENTITY_PublicKey *public_key, | 61 | const struct GNUNET_CRYPTO_PublicKey *public_key, |
62 | struct GNUNET_MESSENGER_MemberSession *session) | 62 | struct GNUNET_MESSENGER_MemberSession *session) |
63 | { | 63 | { |
64 | struct GNUNET_MESSENGER_SrvTunnel *tunnel = cls; | 64 | struct GNUNET_MESSENGER_SrvTunnel *tunnel = cls; |
diff --git a/src/messenger/gnunet-service-messenger_room.c b/src/messenger/gnunet-service-messenger_room.c index 4b734cb40..f2f841c20 100644 --- a/src/messenger/gnunet-service-messenger_room.c +++ b/src/messenger/gnunet-service-messenger_room.c | |||
@@ -276,7 +276,7 @@ notify_about_members (struct GNUNET_MESSENGER_MemberNotify *notify, | |||
276 | 276 | ||
277 | static int | 277 | static int |
278 | iterate_notify_about_members (void *cls, | 278 | iterate_notify_about_members (void *cls, |
279 | const struct GNUNET_IDENTITY_PublicKey *public_key, | 279 | const struct GNUNET_CRYPTO_PublicKey *public_key, |
280 | struct GNUNET_MESSENGER_MemberSession *session) | 280 | struct GNUNET_MESSENGER_MemberSession *session) |
281 | { | 281 | { |
282 | struct GNUNET_MESSENGER_MemberNotify *notify = cls; | 282 | struct GNUNET_MESSENGER_MemberNotify *notify = cls; |
@@ -872,7 +872,7 @@ idle_request_room_messages (void *cls) | |||
872 | 872 | ||
873 | void | 873 | void |
874 | solve_srv_room_member_collisions (struct GNUNET_MESSENGER_SrvRoom *room, | 874 | solve_srv_room_member_collisions (struct GNUNET_MESSENGER_SrvRoom *room, |
875 | const struct GNUNET_IDENTITY_PublicKey *public_key, | 875 | const struct GNUNET_CRYPTO_PublicKey *public_key, |
876 | const struct GNUNET_ShortHashCode *member_id, | 876 | const struct GNUNET_ShortHashCode *member_id, |
877 | struct GNUNET_TIME_Absolute timestamp) | 877 | struct GNUNET_TIME_Absolute timestamp) |
878 | { | 878 | { |
@@ -1057,7 +1057,7 @@ struct GNUNET_MESSENGER_MemberUpdate | |||
1057 | 1057 | ||
1058 | static int | 1058 | static int |
1059 | iterate_update_member_sessions (void *cls, | 1059 | iterate_update_member_sessions (void *cls, |
1060 | const struct GNUNET_IDENTITY_PublicKey *public_key, | 1060 | const struct GNUNET_CRYPTO_PublicKey *public_key, |
1061 | struct GNUNET_MESSENGER_MemberSession *session) | 1061 | struct GNUNET_MESSENGER_MemberSession *session) |
1062 | { | 1062 | { |
1063 | struct GNUNET_MESSENGER_MemberUpdate *update = cls; | 1063 | struct GNUNET_MESSENGER_MemberUpdate *update = cls; |
@@ -1248,7 +1248,7 @@ remove_room_member_session (struct GNUNET_MESSENGER_SrvRoom *room, | |||
1248 | 1248 | ||
1249 | remove_member_session (session->member, session); | 1249 | remove_member_session (session->member, session); |
1250 | 1250 | ||
1251 | const struct GNUNET_IDENTITY_PublicKey *public_key = get_member_session_public_key(session); | 1251 | const struct GNUNET_CRYPTO_PublicKey *public_key = get_member_session_public_key(session); |
1252 | 1252 | ||
1253 | struct GNUNET_HashCode hash; | 1253 | struct GNUNET_HashCode hash; |
1254 | GNUNET_CRYPTO_hash(public_key, sizeof(*public_key), &hash); | 1254 | GNUNET_CRYPTO_hash(public_key, sizeof(*public_key), &hash); |
diff --git a/src/messenger/gnunet-service-messenger_room.h b/src/messenger/gnunet-service-messenger_room.h index 2e9382595..fb2a88aea 100644 --- a/src/messenger/gnunet-service-messenger_room.h +++ b/src/messenger/gnunet-service-messenger_room.h | |||
@@ -336,7 +336,7 @@ request_srv_room_message (struct GNUNET_MESSENGER_SrvRoom *room, | |||
336 | */ | 336 | */ |
337 | void | 337 | void |
338 | solve_srv_room_member_collisions (struct GNUNET_MESSENGER_SrvRoom *room, | 338 | solve_srv_room_member_collisions (struct GNUNET_MESSENGER_SrvRoom *room, |
339 | const struct GNUNET_IDENTITY_PublicKey *public_key, | 339 | const struct GNUNET_CRYPTO_PublicKey *public_key, |
340 | const struct GNUNET_ShortHashCode *member_id, | 340 | const struct GNUNET_ShortHashCode *member_id, |
341 | struct GNUNET_TIME_Absolute timestamp); | 341 | struct GNUNET_TIME_Absolute timestamp); |
342 | 342 | ||
diff --git a/src/messenger/messenger_api.c b/src/messenger/messenger_api.c index 610c979c4..3604d0569 100644 --- a/src/messenger/messenger_api.c +++ b/src/messenger/messenger_api.c | |||
@@ -105,10 +105,10 @@ check_get_key (void *cls, | |||
105 | const uint16_t length = full_length - sizeof(*msg); | 105 | const uint16_t length = full_length - sizeof(*msg); |
106 | const char *buffer = ((const char*) msg) + sizeof(*msg); | 106 | const char *buffer = ((const char*) msg) + sizeof(*msg); |
107 | 107 | ||
108 | struct GNUNET_IDENTITY_PublicKey pubkey; | 108 | struct GNUNET_CRYPTO_PublicKey pubkey; |
109 | size_t read; | 109 | size_t read; |
110 | if (GNUNET_SYSERR == | 110 | if (GNUNET_SYSERR == |
111 | GNUNET_IDENTITY_read_public_key_from_buffer(buffer, length, | 111 | GNUNET_CRYPTO_read_public_key_from_buffer(buffer, length, |
112 | &pubkey, &read)) | 112 | &pubkey, &read)) |
113 | return GNUNET_NO; | 113 | return GNUNET_NO; |
114 | 114 | ||
@@ -124,14 +124,14 @@ handle_get_key (void *cls, | |||
124 | const uint16_t length = ntohs (msg->header.size) - sizeof(*msg); | 124 | const uint16_t length = ntohs (msg->header.size) - sizeof(*msg); |
125 | const char *buffer = ((const char*) msg) + sizeof(*msg); | 125 | const char *buffer = ((const char*) msg) + sizeof(*msg); |
126 | 126 | ||
127 | struct GNUNET_IDENTITY_PublicKey pubkey; | 127 | struct GNUNET_CRYPTO_PublicKey pubkey; |
128 | size_t read; | 128 | size_t read; |
129 | if (GNUNET_SYSERR == | 129 | if (GNUNET_SYSERR == |
130 | GNUNET_IDENTITY_read_public_key_from_buffer(buffer, length, | 130 | GNUNET_CRYPTO_read_public_key_from_buffer(buffer, length, |
131 | &pubkey, &read)) | 131 | &pubkey, &read)) |
132 | return; | 132 | return; |
133 | 133 | ||
134 | char* str = GNUNET_IDENTITY_public_key_to_string (&pubkey); | 134 | char* str = GNUNET_CRYPTO_public_key_to_string (&pubkey); |
135 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Set key of handle: %s\n", str); | 135 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Set key of handle: %s\n", str); |
136 | GNUNET_free(str); | 136 | GNUNET_free(str); |
137 | 137 | ||
@@ -534,8 +534,8 @@ GNUNET_MESSENGER_set_name (struct GNUNET_MESSENGER_Handle *handle, | |||
534 | return GNUNET_YES; | 534 | return GNUNET_YES; |
535 | } | 535 | } |
536 | 536 | ||
537 | static const struct GNUNET_IDENTITY_PublicKey* | 537 | static const struct GNUNET_CRYPTO_PublicKey* |
538 | get_non_anonymous_key (const struct GNUNET_IDENTITY_PublicKey* public_key) | 538 | get_non_anonymous_key (const struct GNUNET_CRYPTO_PublicKey* public_key) |
539 | { | 539 | { |
540 | if (0 == GNUNET_memcmp(public_key, get_anonymous_public_key())) | 540 | if (0 == GNUNET_memcmp(public_key, get_anonymous_public_key())) |
541 | return NULL; | 541 | return NULL; |
@@ -543,7 +543,7 @@ get_non_anonymous_key (const struct GNUNET_IDENTITY_PublicKey* public_key) | |||
543 | return public_key; | 543 | return public_key; |
544 | } | 544 | } |
545 | 545 | ||
546 | const struct GNUNET_IDENTITY_PublicKey* | 546 | const struct GNUNET_CRYPTO_PublicKey* |
547 | GNUNET_MESSENGER_get_key (const struct GNUNET_MESSENGER_Handle *handle) | 547 | GNUNET_MESSENGER_get_key (const struct GNUNET_MESSENGER_Handle *handle) |
548 | { | 548 | { |
549 | if (!handle) | 549 | if (!handle) |
@@ -688,7 +688,7 @@ GNUNET_MESSENGER_contact_get_name (const struct GNUNET_MESSENGER_Contact *contac | |||
688 | return get_contact_name (contact); | 688 | return get_contact_name (contact); |
689 | } | 689 | } |
690 | 690 | ||
691 | const struct GNUNET_IDENTITY_PublicKey* | 691 | const struct GNUNET_CRYPTO_PublicKey* |
692 | GNUNET_MESSENGER_contact_get_key (const struct GNUNET_MESSENGER_Contact *contact) | 692 | GNUNET_MESSENGER_contact_get_key (const struct GNUNET_MESSENGER_Contact *contact) |
693 | { | 693 | { |
694 | if (!contact) | 694 | if (!contact) |
@@ -721,12 +721,12 @@ GNUNET_MESSENGER_send_message (struct GNUNET_MESSENGER_Room *room, | |||
721 | 721 | ||
722 | if (contact) | 722 | if (contact) |
723 | { | 723 | { |
724 | const struct GNUNET_IDENTITY_PublicKey *public_key = get_non_anonymous_key ( | 724 | const struct GNUNET_CRYPTO_PublicKey *public_key = get_non_anonymous_key ( |
725 | get_contact_key(contact) | 725 | get_contact_key(contact) |
726 | ); | 726 | ); |
727 | 727 | ||
728 | if (public_key) | 728 | if (public_key) |
729 | key_length = GNUNET_IDENTITY_public_key_get_length(public_key); | 729 | key_length = GNUNET_CRYPTO_public_key_get_length(public_key); |
730 | else | 730 | else |
731 | key_length = -1; | 731 | key_length = -1; |
732 | } | 732 | } |
@@ -759,7 +759,7 @@ GNUNET_MESSENGER_send_message (struct GNUNET_MESSENGER_Room *room, | |||
759 | char *msg_buffer = buffer + key_length; | 759 | char *msg_buffer = buffer + key_length; |
760 | 760 | ||
761 | if (key_length > 0) | 761 | if (key_length > 0) |
762 | GNUNET_IDENTITY_write_public_key_to_buffer(get_contact_key(contact), buffer, key_length); | 762 | GNUNET_CRYPTO_write_public_key_to_buffer(get_contact_key(contact), buffer, key_length); |
763 | 763 | ||
764 | encode_message (message, msg_length, msg_buffer, GNUNET_NO); | 764 | encode_message (message, msg_length, msg_buffer, GNUNET_NO); |
765 | 765 | ||
diff --git a/src/messenger/messenger_api_contact.c b/src/messenger/messenger_api_contact.c index a284c3b08..a11190c2c 100644 --- a/src/messenger/messenger_api_contact.c +++ b/src/messenger/messenger_api_contact.c | |||
@@ -27,7 +27,7 @@ | |||
27 | #include "messenger_api_contact.h" | 27 | #include "messenger_api_contact.h" |
28 | 28 | ||
29 | struct GNUNET_MESSENGER_Contact* | 29 | struct GNUNET_MESSENGER_Contact* |
30 | create_contact (const struct GNUNET_IDENTITY_PublicKey *key) | 30 | create_contact (const struct GNUNET_CRYPTO_PublicKey *key) |
31 | { | 31 | { |
32 | GNUNET_assert(key); | 32 | GNUNET_assert(key); |
33 | 33 | ||
@@ -72,7 +72,7 @@ set_contact_name (struct GNUNET_MESSENGER_Contact *contact, | |||
72 | contact->name = name ? GNUNET_strdup(name) : NULL; | 72 | contact->name = name ? GNUNET_strdup(name) : NULL; |
73 | } | 73 | } |
74 | 74 | ||
75 | const struct GNUNET_IDENTITY_PublicKey* | 75 | const struct GNUNET_CRYPTO_PublicKey* |
76 | get_contact_key (const struct GNUNET_MESSENGER_Contact *contact) | 76 | get_contact_key (const struct GNUNET_MESSENGER_Contact *contact) |
77 | { | 77 | { |
78 | GNUNET_assert(contact); | 78 | GNUNET_assert(contact); |
diff --git a/src/messenger/messenger_api_contact.h b/src/messenger/messenger_api_contact.h index e2919bcc3..4463aa746 100644 --- a/src/messenger/messenger_api_contact.h +++ b/src/messenger/messenger_api_contact.h | |||
@@ -35,7 +35,7 @@ struct GNUNET_MESSENGER_Contact | |||
35 | char *name; | 35 | char *name; |
36 | size_t rc; | 36 | size_t rc; |
37 | 37 | ||
38 | struct GNUNET_IDENTITY_PublicKey public_key; | 38 | struct GNUNET_CRYPTO_PublicKey public_key; |
39 | }; | 39 | }; |
40 | 40 | ||
41 | /** | 41 | /** |
@@ -45,7 +45,7 @@ struct GNUNET_MESSENGER_Contact | |||
45 | * @return New contact | 45 | * @return New contact |
46 | */ | 46 | */ |
47 | struct GNUNET_MESSENGER_Contact* | 47 | struct GNUNET_MESSENGER_Contact* |
48 | create_contact (const struct GNUNET_IDENTITY_PublicKey *key); | 48 | create_contact (const struct GNUNET_CRYPTO_PublicKey *key); |
49 | 49 | ||
50 | /** | 50 | /** |
51 | * Destroys a contact and frees its memory fully. | 51 | * Destroys a contact and frees its memory fully. |
@@ -80,7 +80,7 @@ set_contact_name (struct GNUNET_MESSENGER_Contact *contact, | |||
80 | * @param[in] contact Contact | 80 | * @param[in] contact Contact |
81 | * @return Public key of the contact | 81 | * @return Public key of the contact |
82 | */ | 82 | */ |
83 | const struct GNUNET_IDENTITY_PublicKey* | 83 | const struct GNUNET_CRYPTO_PublicKey* |
84 | get_contact_key (const struct GNUNET_MESSENGER_Contact *contact); | 84 | get_contact_key (const struct GNUNET_MESSENGER_Contact *contact); |
85 | 85 | ||
86 | /** | 86 | /** |
diff --git a/src/messenger/messenger_api_contact_store.c b/src/messenger/messenger_api_contact_store.c index d42155e20..b0e0d026b 100644 --- a/src/messenger/messenger_api_contact_store.c +++ b/src/messenger/messenger_api_contact_store.c | |||
@@ -65,7 +65,7 @@ select_store_contact_map (struct GNUNET_MESSENGER_ContactStore *store, | |||
65 | const struct GNUNET_HashCode *context, | 65 | const struct GNUNET_HashCode *context, |
66 | struct GNUNET_HashCode *hash) | 66 | struct GNUNET_HashCode *hash) |
67 | { | 67 | { |
68 | const struct GNUNET_IDENTITY_PublicKey *anonymous = get_anonymous_public_key (); | 68 | const struct GNUNET_CRYPTO_PublicKey *anonymous = get_anonymous_public_key (); |
69 | 69 | ||
70 | struct GNUNET_HashCode anonHash; | 70 | struct GNUNET_HashCode anonHash; |
71 | GNUNET_CRYPTO_hash (anonymous, sizeof(*anonymous), &anonHash); | 71 | GNUNET_CRYPTO_hash (anonymous, sizeof(*anonymous), &anonHash); |
@@ -99,7 +99,7 @@ get_store_contact_raw (struct GNUNET_MESSENGER_ContactStore *store, | |||
99 | struct GNUNET_MESSENGER_Contact* | 99 | struct GNUNET_MESSENGER_Contact* |
100 | get_store_contact (struct GNUNET_MESSENGER_ContactStore *store, | 100 | get_store_contact (struct GNUNET_MESSENGER_ContactStore *store, |
101 | const struct GNUNET_HashCode *context, | 101 | const struct GNUNET_HashCode *context, |
102 | const struct GNUNET_IDENTITY_PublicKey *pubkey) | 102 | const struct GNUNET_CRYPTO_PublicKey *pubkey) |
103 | { | 103 | { |
104 | GNUNET_assert ((store) && (store->contacts) && (context) && (pubkey)); | 104 | GNUNET_assert ((store) && (store->contacts) && (context) && (pubkey)); |
105 | 105 | ||
@@ -116,7 +116,7 @@ get_store_contact (struct GNUNET_MESSENGER_ContactStore *store, | |||
116 | { | 116 | { |
117 | if (0 != GNUNET_memcmp(pubkey, get_contact_key(contact))) | 117 | if (0 != GNUNET_memcmp(pubkey, get_contact_key(contact))) |
118 | { | 118 | { |
119 | char* str = GNUNET_IDENTITY_public_key_to_string (get_contact_key(contact)); | 119 | char* str = GNUNET_CRYPTO_public_key_to_string (get_contact_key(contact)); |
120 | GNUNET_log (GNUNET_ERROR_TYPE_INVALID, "Contact in store uses wrong key: %s\n", str); | 120 | GNUNET_log (GNUNET_ERROR_TYPE_INVALID, "Contact in store uses wrong key: %s\n", str); |
121 | GNUNET_free (str); | 121 | GNUNET_free (str); |
122 | return NULL; | 122 | return NULL; |
@@ -140,11 +140,11 @@ update_store_contact (struct GNUNET_MESSENGER_ContactStore *store, | |||
140 | struct GNUNET_MESSENGER_Contact* contact, | 140 | struct GNUNET_MESSENGER_Contact* contact, |
141 | const struct GNUNET_HashCode *context, | 141 | const struct GNUNET_HashCode *context, |
142 | const struct GNUNET_HashCode *next_context, | 142 | const struct GNUNET_HashCode *next_context, |
143 | const struct GNUNET_IDENTITY_PublicKey *pubkey) | 143 | const struct GNUNET_CRYPTO_PublicKey *pubkey) |
144 | { | 144 | { |
145 | GNUNET_assert ((store) && (store->contacts) && (contact) && (pubkey)); | 145 | GNUNET_assert ((store) && (store->contacts) && (contact) && (pubkey)); |
146 | 146 | ||
147 | const struct GNUNET_IDENTITY_PublicKey* oldkey = get_contact_key (contact); | 147 | const struct GNUNET_CRYPTO_PublicKey* oldkey = get_contact_key (contact); |
148 | 148 | ||
149 | struct GNUNET_HashCode hash; | 149 | struct GNUNET_HashCode hash; |
150 | GNUNET_CRYPTO_hash (oldkey, sizeof(*oldkey), &hash); | 150 | GNUNET_CRYPTO_hash (oldkey, sizeof(*oldkey), &hash); |
@@ -177,7 +177,7 @@ remove_store_contact (struct GNUNET_MESSENGER_ContactStore *store, | |||
177 | { | 177 | { |
178 | GNUNET_assert ((store) && (store->contacts) && (contact)); | 178 | GNUNET_assert ((store) && (store->contacts) && (contact)); |
179 | 179 | ||
180 | const struct GNUNET_IDENTITY_PublicKey* pubkey = get_contact_key(contact); | 180 | const struct GNUNET_CRYPTO_PublicKey* pubkey = get_contact_key(contact); |
181 | 181 | ||
182 | struct GNUNET_HashCode hash; | 182 | struct GNUNET_HashCode hash; |
183 | GNUNET_CRYPTO_hash (pubkey, sizeof(*pubkey), &hash); | 183 | GNUNET_CRYPTO_hash (pubkey, sizeof(*pubkey), &hash); |
diff --git a/src/messenger/messenger_api_contact_store.h b/src/messenger/messenger_api_contact_store.h index c74a67740..e012e42c1 100644 --- a/src/messenger/messenger_api_contact_store.h +++ b/src/messenger/messenger_api_contact_store.h | |||
@@ -89,7 +89,7 @@ get_store_contact_raw (struct GNUNET_MESSENGER_ContactStore *store, | |||
89 | struct GNUNET_MESSENGER_Contact* | 89 | struct GNUNET_MESSENGER_Contact* |
90 | get_store_contact (struct GNUNET_MESSENGER_ContactStore *store, | 90 | get_store_contact (struct GNUNET_MESSENGER_ContactStore *store, |
91 | const struct GNUNET_HashCode *context, | 91 | const struct GNUNET_HashCode *context, |
92 | const struct GNUNET_IDENTITY_PublicKey *pubkey); | 92 | const struct GNUNET_CRYPTO_PublicKey *pubkey); |
93 | 93 | ||
94 | /** | 94 | /** |
95 | * Moves a <i>contact</i> from the <i>store</i> to another location | 95 | * Moves a <i>contact</i> from the <i>store</i> to another location |
@@ -108,7 +108,7 @@ update_store_contact (struct GNUNET_MESSENGER_ContactStore *store, | |||
108 | struct GNUNET_MESSENGER_Contact* contact, | 108 | struct GNUNET_MESSENGER_Contact* contact, |
109 | const struct GNUNET_HashCode *context, | 109 | const struct GNUNET_HashCode *context, |
110 | const struct GNUNET_HashCode *next_context, | 110 | const struct GNUNET_HashCode *next_context, |
111 | const struct GNUNET_IDENTITY_PublicKey *pubkey); | 111 | const struct GNUNET_CRYPTO_PublicKey *pubkey); |
112 | 112 | ||
113 | /** | 113 | /** |
114 | * Removes a <i>contact</i> from the <i>store</i> which uses | 114 | * Removes a <i>contact</i> from the <i>store</i> which uses |
diff --git a/src/messenger/messenger_api_ego.h b/src/messenger/messenger_api_ego.h index b52b895f2..1d84c524f 100644 --- a/src/messenger/messenger_api_ego.h +++ b/src/messenger/messenger_api_ego.h | |||
@@ -31,8 +31,8 @@ | |||
31 | 31 | ||
32 | struct GNUNET_MESSENGER_Ego | 32 | struct GNUNET_MESSENGER_Ego |
33 | { | 33 | { |
34 | struct GNUNET_IDENTITY_PrivateKey priv; | 34 | struct GNUNET_CRYPTO_PrivateKey priv; |
35 | struct GNUNET_IDENTITY_PublicKey pub; | 35 | struct GNUNET_CRYPTO_PublicKey pub; |
36 | }; | 36 | }; |
37 | 37 | ||
38 | #endif //GNUNET_MESSENGER_API_EGO_H | 38 | #endif //GNUNET_MESSENGER_API_EGO_H |
diff --git a/src/messenger/messenger_api_handle.c b/src/messenger/messenger_api_handle.c index ec8d3dc7a..fddf73ad5 100644 --- a/src/messenger/messenger_api_handle.c +++ b/src/messenger/messenger_api_handle.c | |||
@@ -124,17 +124,17 @@ get_handle_name (const struct GNUNET_MESSENGER_Handle *handle) | |||
124 | 124 | ||
125 | void | 125 | void |
126 | set_handle_key (struct GNUNET_MESSENGER_Handle *handle, | 126 | set_handle_key (struct GNUNET_MESSENGER_Handle *handle, |
127 | const struct GNUNET_IDENTITY_PublicKey *pubkey) | 127 | const struct GNUNET_CRYPTO_PublicKey *pubkey) |
128 | { | 128 | { |
129 | GNUNET_assert(handle); | 129 | GNUNET_assert(handle); |
130 | 130 | ||
131 | if (!handle->pubkey) | 131 | if (!handle->pubkey) |
132 | handle->pubkey = GNUNET_new(struct GNUNET_IDENTITY_PublicKey); | 132 | handle->pubkey = GNUNET_new(struct GNUNET_CRYPTO_PublicKey); |
133 | 133 | ||
134 | GNUNET_memcpy(handle->pubkey, pubkey, sizeof(*pubkey)); | 134 | GNUNET_memcpy(handle->pubkey, pubkey, sizeof(*pubkey)); |
135 | } | 135 | } |
136 | 136 | ||
137 | const struct GNUNET_IDENTITY_PublicKey* | 137 | const struct GNUNET_CRYPTO_PublicKey* |
138 | get_handle_key (const struct GNUNET_MESSENGER_Handle *handle) | 138 | get_handle_key (const struct GNUNET_MESSENGER_Handle *handle) |
139 | { | 139 | { |
140 | GNUNET_assert(handle); | 140 | GNUNET_assert(handle); |
diff --git a/src/messenger/messenger_api_handle.h b/src/messenger/messenger_api_handle.h index d246855ff..09f44be8a 100644 --- a/src/messenger/messenger_api_handle.h +++ b/src/messenger/messenger_api_handle.h | |||
@@ -49,7 +49,7 @@ struct GNUNET_MESSENGER_Handle | |||
49 | void *msg_cls; | 49 | void *msg_cls; |
50 | 50 | ||
51 | char *name; | 51 | char *name; |
52 | struct GNUNET_IDENTITY_PublicKey *pubkey; | 52 | struct GNUNET_CRYPTO_PublicKey *pubkey; |
53 | 53 | ||
54 | struct GNUNET_TIME_Relative reconnect_time; | 54 | struct GNUNET_TIME_Relative reconnect_time; |
55 | struct GNUNET_SCHEDULER_Task *reconnect_task; | 55 | struct GNUNET_SCHEDULER_Task *reconnect_task; |
@@ -110,7 +110,7 @@ get_handle_name (const struct GNUNET_MESSENGER_Handle *handle); | |||
110 | */ | 110 | */ |
111 | void | 111 | void |
112 | set_handle_key (struct GNUNET_MESSENGER_Handle *handle, | 112 | set_handle_key (struct GNUNET_MESSENGER_Handle *handle, |
113 | const struct GNUNET_IDENTITY_PublicKey *pubkey); | 113 | const struct GNUNET_CRYPTO_PublicKey *pubkey); |
114 | 114 | ||
115 | /** | 115 | /** |
116 | * Returns the public key of a given <i>handle</i>. | 116 | * Returns the public key of a given <i>handle</i>. |
@@ -118,7 +118,7 @@ set_handle_key (struct GNUNET_MESSENGER_Handle *handle, | |||
118 | * @param[in] handle Handle | 118 | * @param[in] handle Handle |
119 | * @return Public key of the handle | 119 | * @return Public key of the handle |
120 | */ | 120 | */ |
121 | const struct GNUNET_IDENTITY_PublicKey* | 121 | const struct GNUNET_CRYPTO_PublicKey* |
122 | get_handle_key (const struct GNUNET_MESSENGER_Handle *handle); | 122 | get_handle_key (const struct GNUNET_MESSENGER_Handle *handle); |
123 | 123 | ||
124 | /** | 124 | /** |
diff --git a/src/messenger/messenger_api_message.c b/src/messenger/messenger_api_message.c index 31d0c94b8..1f7e8dbf2 100644 --- a/src/messenger/messenger_api_message.c +++ b/src/messenger/messenger_api_message.c | |||
@@ -276,16 +276,16 @@ get_message_body_size (enum GNUNET_MESSENGER_MessageKind kind, | |||
276 | switch (kind) | 276 | switch (kind) |
277 | { | 277 | { |
278 | case GNUNET_MESSENGER_KIND_INFO: | 278 | case GNUNET_MESSENGER_KIND_INFO: |
279 | length += GNUNET_IDENTITY_public_key_get_length (&(body->info.host_key)); | 279 | length += GNUNET_CRYPTO_public_key_get_length (&(body->info.host_key)); |
280 | break; | 280 | break; |
281 | case GNUNET_MESSENGER_KIND_JOIN: | 281 | case GNUNET_MESSENGER_KIND_JOIN: |
282 | length += GNUNET_IDENTITY_public_key_get_length (&(body->join.key)); | 282 | length += GNUNET_CRYPTO_public_key_get_length (&(body->join.key)); |
283 | break; | 283 | break; |
284 | case GNUNET_MESSENGER_KIND_NAME: | 284 | case GNUNET_MESSENGER_KIND_NAME: |
285 | length += (body->name.name ? strlen (body->name.name) : 0); | 285 | length += (body->name.name ? strlen (body->name.name) : 0); |
286 | break; | 286 | break; |
287 | case GNUNET_MESSENGER_KIND_KEY: | 287 | case GNUNET_MESSENGER_KIND_KEY: |
288 | length += GNUNET_IDENTITY_public_key_get_length (&(body->key.key)); | 288 | length += GNUNET_CRYPTO_public_key_get_length (&(body->key.key)); |
289 | break; | 289 | break; |
290 | case GNUNET_MESSENGER_KIND_TEXT: | 290 | case GNUNET_MESSENGER_KIND_TEXT: |
291 | length += strlen (body->text.text); | 291 | length += strlen (body->text.text); |
@@ -313,7 +313,7 @@ get_message_size (const struct GNUNET_MESSENGER_Message *message, | |||
313 | uint16_t length = 0; | 313 | uint16_t length = 0; |
314 | 314 | ||
315 | if (GNUNET_YES == include_header) | 315 | if (GNUNET_YES == include_header) |
316 | length += GNUNET_IDENTITY_signature_get_length ( | 316 | length += GNUNET_CRYPTO_signature_get_length ( |
317 | &(message->header.signature)); | 317 | &(message->header.signature)); |
318 | 318 | ||
319 | length += get_message_kind_size (message->header.kind, include_header); | 319 | length += get_message_kind_size (message->header.kind, include_header); |
@@ -399,7 +399,7 @@ calc_padded_length (uint16_t length) | |||
399 | } while (0) | 399 | } while (0) |
400 | 400 | ||
401 | #define encode_step_key(dst, offset, src, length) do { \ | 401 | #define encode_step_key(dst, offset, src, length) do { \ |
402 | ssize_t result = GNUNET_IDENTITY_write_public_key_to_buffer ( \ | 402 | ssize_t result = GNUNET_CRYPTO_write_public_key_to_buffer ( \ |
403 | src, dst + offset, length - offset \ | 403 | src, dst + offset, length - offset \ |
404 | ); \ | 404 | ); \ |
405 | if (result < 0) \ | 405 | if (result < 0) \ |
@@ -409,7 +409,7 @@ calc_padded_length (uint16_t length) | |||
409 | } while (0) | 409 | } while (0) |
410 | 410 | ||
411 | #define encode_step_signature(dst, offset, src, length) do { \ | 411 | #define encode_step_signature(dst, offset, src, length) do { \ |
412 | ssize_t result = GNUNET_IDENTITY_write_signature_to_buffer ( \ | 412 | ssize_t result = GNUNET_CRYPTO_write_signature_to_buffer ( \ |
413 | src, dst + offset, length - offset \ | 413 | src, dst + offset, length - offset \ |
414 | ); \ | 414 | ); \ |
415 | if (result < 0) \ | 415 | if (result < 0) \ |
@@ -581,7 +581,7 @@ encode_short_message (const struct GNUNET_MESSENGER_ShortMessage *message, | |||
581 | #define decode_step_key(src, offset, dst, length) do { \ | 581 | #define decode_step_key(src, offset, dst, length) do { \ |
582 | enum GNUNET_GenericReturnValue result; \ | 582 | enum GNUNET_GenericReturnValue result; \ |
583 | size_t read; \ | 583 | size_t read; \ |
584 | result = GNUNET_IDENTITY_read_public_key_from_buffer ( \ | 584 | result = GNUNET_CRYPTO_read_public_key_from_buffer ( \ |
585 | src + offset, length - offset, dst, &read \ | 585 | src + offset, length - offset, dst, &read \ |
586 | ); \ | 586 | ); \ |
587 | if (GNUNET_SYSERR == result) \ | 587 | if (GNUNET_SYSERR == result) \ |
@@ -695,7 +695,7 @@ decode_message (struct GNUNET_MESSENGER_Message *message, | |||
695 | 695 | ||
696 | if (GNUNET_YES == include_header) | 696 | if (GNUNET_YES == include_header) |
697 | { | 697 | { |
698 | ssize_t result = GNUNET_IDENTITY_read_signature_from_buffer ( | 698 | ssize_t result = GNUNET_CRYPTO_read_signature_from_buffer ( |
699 | &(message->header.signature), buffer, length - offset | 699 | &(message->header.signature), buffer, length - offset |
700 | ); | 700 | ); |
701 | 701 | ||
@@ -788,7 +788,7 @@ hash_message (const struct GNUNET_MESSENGER_Message *message, | |||
788 | { | 788 | { |
789 | GNUNET_assert ((message) && (buffer) && (hash)); | 789 | GNUNET_assert ((message) && (buffer) && (hash)); |
790 | 790 | ||
791 | const ssize_t offset = GNUNET_IDENTITY_signature_get_length ( | 791 | const ssize_t offset = GNUNET_CRYPTO_signature_get_length ( |
792 | &(message->header.signature) | 792 | &(message->header.signature) |
793 | ); | 793 | ); |
794 | 794 | ||
@@ -811,7 +811,7 @@ sign_message (struct GNUNET_MESSENGER_Message *message, | |||
811 | signature.purpose.size = htonl (sizeof(signature)); | 811 | signature.purpose.size = htonl (sizeof(signature)); |
812 | 812 | ||
813 | GNUNET_memcpy (&(signature.hash), hash, sizeof(struct GNUNET_HashCode)); | 813 | GNUNET_memcpy (&(signature.hash), hash, sizeof(struct GNUNET_HashCode)); |
814 | GNUNET_IDENTITY_sign (&(ego->priv), &signature, &(message->header.signature)); | 814 | GNUNET_CRYPTO_sign (&(ego->priv), &signature, &(message->header.signature)); |
815 | 815 | ||
816 | uint16_t offset = 0; | 816 | uint16_t offset = 0; |
817 | encode_step_signature (buffer, offset, &(message->header.signature), length); | 817 | encode_step_signature (buffer, offset, &(message->header.signature), length); |
@@ -821,7 +821,7 @@ sign_message (struct GNUNET_MESSENGER_Message *message, | |||
821 | int | 821 | int |
822 | verify_message (const struct GNUNET_MESSENGER_Message *message, | 822 | verify_message (const struct GNUNET_MESSENGER_Message *message, |
823 | const struct GNUNET_HashCode *hash, | 823 | const struct GNUNET_HashCode *hash, |
824 | const struct GNUNET_IDENTITY_PublicKey *key) | 824 | const struct GNUNET_CRYPTO_PublicKey *key) |
825 | { | 825 | { |
826 | GNUNET_assert ((message) && (hash) && (key)); | 826 | GNUNET_assert ((message) && (hash) && (key)); |
827 | 827 | ||
@@ -835,7 +835,7 @@ verify_message (const struct GNUNET_MESSENGER_Message *message, | |||
835 | 835 | ||
836 | GNUNET_memcpy (&(signature.hash), hash, sizeof(struct GNUNET_HashCode)); | 836 | GNUNET_memcpy (&(signature.hash), hash, sizeof(struct GNUNET_HashCode)); |
837 | 837 | ||
838 | return GNUNET_IDENTITY_signature_verify ( | 838 | return GNUNET_CRYPTO_signature_verify ( |
839 | GNUNET_SIGNATURE_PURPOSE_CHAT_MESSAGE, &signature, | 839 | GNUNET_SIGNATURE_PURPOSE_CHAT_MESSAGE, &signature, |
840 | &(message->header.signature), key); | 840 | &(message->header.signature), key); |
841 | } | 841 | } |
@@ -843,7 +843,7 @@ verify_message (const struct GNUNET_MESSENGER_Message *message, | |||
843 | 843 | ||
844 | int | 844 | int |
845 | encrypt_message (struct GNUNET_MESSENGER_Message *message, | 845 | encrypt_message (struct GNUNET_MESSENGER_Message *message, |
846 | const struct GNUNET_IDENTITY_PublicKey *key) | 846 | const struct GNUNET_CRYPTO_PublicKey *key) |
847 | { | 847 | { |
848 | GNUNET_assert ((message) && (key)); | 848 | GNUNET_assert ((message) && (key)); |
849 | 849 | ||
@@ -853,7 +853,7 @@ encrypt_message (struct GNUNET_MESSENGER_Message *message, | |||
853 | 853 | ||
854 | const uint16_t length = get_short_message_size (&shortened, GNUNET_YES); | 854 | const uint16_t length = get_short_message_size (&shortened, GNUNET_YES); |
855 | const uint16_t padded_length = calc_padded_length ( | 855 | const uint16_t padded_length = calc_padded_length ( |
856 | length + GNUNET_IDENTITY_ENCRYPT_OVERHEAD_BYTES | 856 | length + GNUNET_CRYPTO_ENCRYPT_OVERHEAD_BYTES |
857 | ); | 857 | ); |
858 | 858 | ||
859 | message->header.kind = GNUNET_MESSENGER_KIND_PRIVATE; | 859 | message->header.kind = GNUNET_MESSENGER_KIND_PRIVATE; |
@@ -861,12 +861,12 @@ encrypt_message (struct GNUNET_MESSENGER_Message *message, | |||
861 | message->body.privacy.length = padded_length; | 861 | message->body.privacy.length = padded_length; |
862 | 862 | ||
863 | const uint16_t encoded_length = ( | 863 | const uint16_t encoded_length = ( |
864 | padded_length - GNUNET_IDENTITY_ENCRYPT_OVERHEAD_BYTES | 864 | padded_length - GNUNET_CRYPTO_ENCRYPT_OVERHEAD_BYTES |
865 | ); | 865 | ); |
866 | 866 | ||
867 | encode_short_message (&shortened, encoded_length, message->body.privacy.data); | 867 | encode_short_message (&shortened, encoded_length, message->body.privacy.data); |
868 | 868 | ||
869 | if (GNUNET_OK != GNUNET_IDENTITY_encrypt (message->body.privacy.data, | 869 | if (GNUNET_OK != GNUNET_CRYPTO_encrypt (message->body.privacy.data, |
870 | encoded_length, | 870 | encoded_length, |
871 | key, | 871 | key, |
872 | message->body.privacy.data, | 872 | message->body.privacy.data, |
@@ -885,13 +885,13 @@ encrypt_message (struct GNUNET_MESSENGER_Message *message, | |||
885 | 885 | ||
886 | int | 886 | int |
887 | decrypt_message (struct GNUNET_MESSENGER_Message *message, | 887 | decrypt_message (struct GNUNET_MESSENGER_Message *message, |
888 | const struct GNUNET_IDENTITY_PrivateKey *key) | 888 | const struct GNUNET_CRYPTO_PrivateKey *key) |
889 | { | 889 | { |
890 | GNUNET_assert ((message) && (key)); | 890 | GNUNET_assert ((message) && (key)); |
891 | 891 | ||
892 | const uint16_t padded_length = message->body.privacy.length; | 892 | const uint16_t padded_length = message->body.privacy.length; |
893 | 893 | ||
894 | if (padded_length < GNUNET_IDENTITY_ENCRYPT_OVERHEAD_BYTES) | 894 | if (padded_length < GNUNET_CRYPTO_ENCRYPT_OVERHEAD_BYTES) |
895 | { | 895 | { |
896 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | 896 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, |
897 | "Message length too short to decrypt!\n"); | 897 | "Message length too short to decrypt!\n"); |
@@ -900,10 +900,10 @@ decrypt_message (struct GNUNET_MESSENGER_Message *message, | |||
900 | } | 900 | } |
901 | 901 | ||
902 | const uint16_t encoded_length = ( | 902 | const uint16_t encoded_length = ( |
903 | padded_length - GNUNET_IDENTITY_ENCRYPT_OVERHEAD_BYTES | 903 | padded_length - GNUNET_CRYPTO_ENCRYPT_OVERHEAD_BYTES |
904 | ); | 904 | ); |
905 | 905 | ||
906 | if (GNUNET_OK != GNUNET_IDENTITY_decrypt (message->body.privacy.data, | 906 | if (GNUNET_OK != GNUNET_CRYPTO_decrypt (message->body.privacy.data, |
907 | padded_length, | 907 | padded_length, |
908 | key, | 908 | key, |
909 | message->body.privacy.data, | 909 | message->body.privacy.data, |
diff --git a/src/messenger/messenger_api_message.h b/src/messenger/messenger_api_message.h index 688c72994..0c2d4acf2 100644 --- a/src/messenger/messenger_api_message.h +++ b/src/messenger/messenger_api_message.h | |||
@@ -188,7 +188,7 @@ sign_message (struct GNUNET_MESSENGER_Message *message, | |||
188 | int | 188 | int |
189 | verify_message (const struct GNUNET_MESSENGER_Message *message, | 189 | verify_message (const struct GNUNET_MESSENGER_Message *message, |
190 | const struct GNUNET_HashCode *hash, | 190 | const struct GNUNET_HashCode *hash, |
191 | const struct GNUNET_IDENTITY_PublicKey *key); | 191 | const struct GNUNET_CRYPTO_PublicKey *key); |
192 | 192 | ||
193 | /** | 193 | /** |
194 | * Encrypts a <i>message</i> using a given public <i>key</i> and replaces its body | 194 | * Encrypts a <i>message</i> using a given public <i>key</i> and replaces its body |
@@ -201,7 +201,7 @@ verify_message (const struct GNUNET_MESSENGER_Message *message, | |||
201 | */ | 201 | */ |
202 | int | 202 | int |
203 | encrypt_message (struct GNUNET_MESSENGER_Message *message, | 203 | encrypt_message (struct GNUNET_MESSENGER_Message *message, |
204 | const struct GNUNET_IDENTITY_PublicKey *key); | 204 | const struct GNUNET_CRYPTO_PublicKey *key); |
205 | 205 | ||
206 | /** | 206 | /** |
207 | * Decrypts a private <i>message</i> using a given private <i>key</i> and replaces its body | 207 | * Decrypts a private <i>message</i> using a given private <i>key</i> and replaces its body |
@@ -214,7 +214,7 @@ encrypt_message (struct GNUNET_MESSENGER_Message *message, | |||
214 | */ | 214 | */ |
215 | int | 215 | int |
216 | decrypt_message (struct GNUNET_MESSENGER_Message *message, | 216 | decrypt_message (struct GNUNET_MESSENGER_Message *message, |
217 | const struct GNUNET_IDENTITY_PrivateKey *key); | 217 | const struct GNUNET_CRYPTO_PrivateKey *key); |
218 | 218 | ||
219 | #define GNUNET_MESSENGER_PACK_MODE_ENVELOPE 0x1 | 219 | #define GNUNET_MESSENGER_PACK_MODE_ENVELOPE 0x1 |
220 | #define GNUNET_MESSENGER_PACK_MODE_UNKNOWN 0x0 | 220 | #define GNUNET_MESSENGER_PACK_MODE_UNKNOWN 0x0 |
diff --git a/src/messenger/messenger_api_util.c b/src/messenger/messenger_api_util.c index f56e2e201..9d23e2262 100644 --- a/src/messenger/messenger_api_util.c +++ b/src/messenger/messenger_api_util.c | |||
@@ -70,10 +70,10 @@ generate_free_member_id (struct GNUNET_ShortHashCode *id, | |||
70 | return GNUNET_NO; | 70 | return GNUNET_NO; |
71 | } | 71 | } |
72 | 72 | ||
73 | const struct GNUNET_IDENTITY_PublicKey* | 73 | const struct GNUNET_CRYPTO_PublicKey* |
74 | get_anonymous_public_key () | 74 | get_anonymous_public_key () |
75 | { | 75 | { |
76 | static struct GNUNET_IDENTITY_PublicKey public_key; | 76 | static struct GNUNET_CRYPTO_PublicKey public_key; |
77 | static struct GNUNET_IDENTITY_Ego* ego = NULL; | 77 | static struct GNUNET_IDENTITY_Ego* ego = NULL; |
78 | 78 | ||
79 | if (!ego) | 79 | if (!ego) |
diff --git a/src/messenger/messenger_api_util.h b/src/messenger/messenger_api_util.h index 3d68505a8..bad001da3 100644 --- a/src/messenger/messenger_api_util.h +++ b/src/messenger/messenger_api_util.h | |||
@@ -58,7 +58,7 @@ generate_free_member_id (struct GNUNET_ShortHashCode *id, | |||
58 | * | 58 | * |
59 | * @return anonymous public key | 59 | * @return anonymous public key |
60 | */ | 60 | */ |
61 | const struct GNUNET_IDENTITY_PublicKey* | 61 | const struct GNUNET_CRYPTO_PublicKey* |
62 | get_anonymous_public_key (); | 62 | get_anonymous_public_key (); |
63 | 63 | ||
64 | /** | 64 | /** |
diff --git a/src/messenger/test_messenger.c b/src/messenger/test_messenger.c index 8758ce562..660e6473c 100644 --- a/src/messenger/test_messenger.c +++ b/src/messenger/test_messenger.c | |||
@@ -117,7 +117,7 @@ on_identity (void *cls, | |||
117 | return; | 117 | return; |
118 | } | 118 | } |
119 | 119 | ||
120 | const struct GNUNET_IDENTITY_PublicKey *key = GNUNET_MESSENGER_get_key (handle); | 120 | const struct GNUNET_CRYPTO_PublicKey *key = GNUNET_MESSENGER_get_key (handle); |
121 | 121 | ||
122 | if (((!identity_counter) && (key)) || ((identity_counter) && (!key))) | 122 | if (((!identity_counter) && (key)) || ((identity_counter) && (!key))) |
123 | { | 123 | { |
diff --git a/src/messenger/test_messenger_anonymous.c b/src/messenger/test_messenger_anonymous.c index 13f2b6f0e..367d1c3b7 100644 --- a/src/messenger/test_messenger_anonymous.c +++ b/src/messenger/test_messenger_anonymous.c | |||
@@ -119,7 +119,7 @@ on_identity (void *cls, | |||
119 | return; | 119 | return; |
120 | } | 120 | } |
121 | 121 | ||
122 | const struct GNUNET_IDENTITY_PublicKey *key = GNUNET_MESSENGER_get_key (handle); | 122 | const struct GNUNET_CRYPTO_PublicKey *key = GNUNET_MESSENGER_get_key (handle); |
123 | 123 | ||
124 | if (key) | 124 | if (key) |
125 | { | 125 | { |
diff --git a/src/namecache/Makefile.am b/src/namecache/Makefile.am index f283d3f64..9ece350de 100644 --- a/src/namecache/Makefile.am +++ b/src/namecache/Makefile.am | |||
@@ -63,9 +63,9 @@ libgnunetnamecache_la_SOURCES = \ | |||
63 | namecache_api.c \ | 63 | namecache_api.c \ |
64 | namecache.h | 64 | namecache.h |
65 | libgnunetnamecache_la_LIBADD = \ | 65 | libgnunetnamecache_la_LIBADD = \ |
66 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 66 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
67 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 67 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
68 | $(top_builddir)/src/util/libgnunetutil.la \ | 68 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
69 | $(GN_LIBINTL) | 69 | $(GN_LIBINTL) |
70 | libgnunetnamecache_la_LDFLAGS = \ | 70 | libgnunetnamecache_la_LDFLAGS = \ |
71 | $(GN_LIB_LDFLAGS) \ | 71 | $(GN_LIB_LDFLAGS) \ |
@@ -81,9 +81,9 @@ bin_PROGRAMS = \ | |||
81 | gnunet_namecache_SOURCES = \ | 81 | gnunet_namecache_SOURCES = \ |
82 | gnunet-namecache.c | 82 | gnunet-namecache.c |
83 | gnunet_namecache_LDADD = \ | 83 | gnunet_namecache_LDADD = \ |
84 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 84 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
85 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 85 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
86 | $(top_builddir)/src/util/libgnunetutil.la \ | 86 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
87 | libgnunetnamecache.la \ | 87 | libgnunetnamecache.la \ |
88 | $(GN_LIBINTL) | 88 | $(GN_LIBINTL) |
89 | 89 | ||
@@ -91,10 +91,10 @@ gnunet_service_namecache_SOURCES = \ | |||
91 | gnunet-service-namecache.c | 91 | gnunet-service-namecache.c |
92 | 92 | ||
93 | gnunet_service_namecache_LDADD = \ | 93 | gnunet_service_namecache_LDADD = \ |
94 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 94 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
95 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 95 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
96 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 96 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
97 | $(top_builddir)/src/util/libgnunetutil.la \ | 97 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
98 | libgnunetnamecache.la \ | 98 | libgnunetnamecache.la \ |
99 | $(GN_LIBINTL) | 99 | $(GN_LIBINTL) |
100 | 100 | ||
@@ -109,9 +109,9 @@ libgnunet_plugin_namecache_flat_la_SOURCES = \ | |||
109 | libgnunet_plugin_namecache_flat_la_LIBADD = \ | 109 | libgnunet_plugin_namecache_flat_la_LIBADD = \ |
110 | libgnunetnamecache.la \ | 110 | libgnunetnamecache.la \ |
111 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 111 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
112 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 112 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
113 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 113 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
114 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 114 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) \ |
115 | $(LTLIBINTL) | 115 | $(LTLIBINTL) |
116 | libgnunet_plugin_namecache_flat_la_LDFLAGS = \ | 116 | libgnunet_plugin_namecache_flat_la_LDFLAGS = \ |
117 | $(GN_PLUGIN_LDFLAGS) | 117 | $(GN_PLUGIN_LDFLAGS) |
@@ -122,9 +122,9 @@ libgnunet_plugin_namecache_sqlite_la_LIBADD = \ | |||
122 | libgnunetnamecache.la \ | 122 | libgnunetnamecache.la \ |
123 | $(top_builddir)/src/sq/libgnunetsq.la \ | 123 | $(top_builddir)/src/sq/libgnunetsq.la \ |
124 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 124 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
125 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 125 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
126 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 126 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
127 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) -lsqlite3 \ | 127 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) -lsqlite3 \ |
128 | $(LTLIBINTL) | 128 | $(LTLIBINTL) |
129 | libgnunet_plugin_namecache_sqlite_la_LDFLAGS = \ | 129 | libgnunet_plugin_namecache_sqlite_la_LDFLAGS = \ |
130 | $(GN_PLUGIN_LDFLAGS) | 130 | $(GN_PLUGIN_LDFLAGS) |
@@ -136,9 +136,9 @@ libgnunet_plugin_namecache_postgres_la_LIBADD = \ | |||
136 | libgnunetnamecache.la \ | 136 | libgnunetnamecache.la \ |
137 | $(top_builddir)/src/pq/libgnunetpq.la \ | 137 | $(top_builddir)/src/pq/libgnunetpq.la \ |
138 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 138 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
139 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 139 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
140 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 140 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
141 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) -lpq \ | 141 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) -lpq \ |
142 | $(LTLIBINTL) | 142 | $(LTLIBINTL) |
143 | libgnunet_plugin_namecache_postgres_la_LDFLAGS = \ | 143 | libgnunet_plugin_namecache_postgres_la_LDFLAGS = \ |
144 | $(GN_PLUGIN_LDFLAGS) $(POSTGRESQL_LDFLAGS) | 144 | $(GN_PLUGIN_LDFLAGS) $(POSTGRESQL_LDFLAGS) |
@@ -146,30 +146,30 @@ libgnunet_plugin_namecache_postgres_la_LDFLAGS = \ | |||
146 | test_namecache_api_cache_block_SOURCES = \ | 146 | test_namecache_api_cache_block_SOURCES = \ |
147 | test_namecache_api_cache_block.c | 147 | test_namecache_api_cache_block.c |
148 | test_namecache_api_cache_block_LDADD = \ | 148 | test_namecache_api_cache_block_LDADD = \ |
149 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 149 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
150 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 150 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
151 | libgnunetnamecache.la \ | 151 | libgnunetnamecache.la \ |
152 | $(top_builddir)/src/testing/libgnunettesting.la \ | 152 | $(top_builddir)/src/testing/libgnunettesting.la \ |
153 | $(top_builddir)/src/util/libgnunetutil.la | 153 | $(top_builddir)/src/lib/util/libgnunetutil.la |
154 | 154 | ||
155 | 155 | ||
156 | test_plugin_namecache_flat_SOURCES = \ | 156 | test_plugin_namecache_flat_SOURCES = \ |
157 | test_plugin_namecache.c | 157 | test_plugin_namecache.c |
158 | test_plugin_namecache_flat_LDADD = \ | 158 | test_plugin_namecache_flat_LDADD = \ |
159 | $(top_builddir)/src/testing/libgnunettesting.la \ | 159 | $(top_builddir)/src/testing/libgnunettesting.la \ |
160 | $(top_builddir)/src/util/libgnunetutil.la | 160 | $(top_builddir)/src/lib/util/libgnunetutil.la |
161 | 161 | ||
162 | test_plugin_namecache_sqlite_SOURCES = \ | 162 | test_plugin_namecache_sqlite_SOURCES = \ |
163 | test_plugin_namecache.c | 163 | test_plugin_namecache.c |
164 | test_plugin_namecache_sqlite_LDADD = \ | 164 | test_plugin_namecache_sqlite_LDADD = \ |
165 | $(top_builddir)/src/testing/libgnunettesting.la \ | 165 | $(top_builddir)/src/testing/libgnunettesting.la \ |
166 | $(top_builddir)/src/util/libgnunetutil.la | 166 | $(top_builddir)/src/lib/util/libgnunetutil.la |
167 | 167 | ||
168 | test_plugin_namecache_postgres_SOURCES = \ | 168 | test_plugin_namecache_postgres_SOURCES = \ |
169 | test_plugin_namecache.c | 169 | test_plugin_namecache.c |
170 | test_plugin_namecache_postgres_LDADD = \ | 170 | test_plugin_namecache_postgres_LDADD = \ |
171 | $(top_builddir)/src/testing/libgnunettesting.la \ | 171 | $(top_builddir)/src/testing/libgnunettesting.la \ |
172 | $(top_builddir)/src/util/libgnunetutil.la | 172 | $(top_builddir)/src/lib/util/libgnunetutil.la |
173 | 173 | ||
174 | EXTRA_DIST = \ | 174 | EXTRA_DIST = \ |
175 | test_namecache_api.conf \ | 175 | test_namecache_api.conf \ |
diff --git a/src/namecache/gnunet-namecache.c b/src/namecache/gnunet-namecache.c index e58d3f960..0236609aa 100644 --- a/src/namecache/gnunet-namecache.c +++ b/src/namecache/gnunet-namecache.c | |||
@@ -50,7 +50,7 @@ static char *name; | |||
50 | /** | 50 | /** |
51 | * Public key of the zone to look in. | 51 | * Public key of the zone to look in. |
52 | */ | 52 | */ |
53 | static struct GNUNET_IDENTITY_PublicKey pubkey; | 53 | static struct GNUNET_CRYPTO_PublicKey pubkey; |
54 | 54 | ||
55 | /** | 55 | /** |
56 | * Public key of the zone to look in, in ASCII. | 56 | * Public key of the zone to look in, in ASCII. |
@@ -176,7 +176,7 @@ run (void *cls, | |||
176 | } | 176 | } |
177 | 177 | ||
178 | if (GNUNET_OK != | 178 | if (GNUNET_OK != |
179 | GNUNET_IDENTITY_public_key_from_string (pkey, &pubkey)) | 179 | GNUNET_CRYPTO_public_key_from_string (pkey, &pubkey)) |
180 | { | 180 | { |
181 | fprintf (stderr, _ ("Invalid public key for zone `%s'\n"), pkey); | 181 | fprintf (stderr, _ ("Invalid public key for zone `%s'\n"), pkey); |
182 | GNUNET_SCHEDULER_shutdown (); | 182 | GNUNET_SCHEDULER_shutdown (); |
diff --git a/src/namecache/test_namecache_api_cache_block.c b/src/namecache/test_namecache_api_cache_block.c index d83758e7d..3a18a72e1 100644 --- a/src/namecache/test_namecache_api_cache_block.c +++ b/src/namecache/test_namecache_api_cache_block.c | |||
@@ -38,9 +38,9 @@ static struct GNUNET_NAMECACHE_Handle *nsh; | |||
38 | 38 | ||
39 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 39 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
40 | 40 | ||
41 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 41 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
42 | 42 | ||
43 | static struct GNUNET_IDENTITY_PublicKey pubkey; | 43 | static struct GNUNET_CRYPTO_PublicKey pubkey; |
44 | 44 | ||
45 | static int res; | 45 | static int res; |
46 | 46 | ||
@@ -177,7 +177,7 @@ run (void *cls, | |||
177 | &endbadly, NULL); | 177 | &endbadly, NULL); |
178 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); | 178 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
179 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | 179 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
180 | GNUNET_IDENTITY_key_get_public (&privkey, &pubkey); | 180 | GNUNET_CRYPTO_key_get_public (&privkey, &pubkey); |
181 | 181 | ||
182 | 182 | ||
183 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us + 10000000000; | 183 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us + 10000000000; |
diff --git a/src/namestore/Makefile.am b/src/namestore/Makefile.am index 98ee228e1..8edc3b658 100644 --- a/src/namestore/Makefile.am +++ b/src/namestore/Makefile.am | |||
@@ -111,9 +111,9 @@ libgnunet_plugin_rest_namestore_la_LIBADD = \ | |||
111 | $(top_builddir)/src/rest/libgnunetrest.la \ | 111 | $(top_builddir)/src/rest/libgnunetrest.la \ |
112 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 112 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
113 | $(top_builddir)/src/json/libgnunetjson.la \ | 113 | $(top_builddir)/src/json/libgnunetjson.la \ |
114 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 114 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
115 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecordjson.la \ | 115 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecordjson.la \ |
116 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 116 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) \ |
117 | $(LTLIBINTL) -ljansson $(MHD_LIBS) | 117 | $(LTLIBINTL) -ljansson $(MHD_LIBS) |
118 | libgnunet_plugin_rest_namestore_la_LDFLAGS = \ | 118 | libgnunet_plugin_rest_namestore_la_LDFLAGS = \ |
119 | $(GN_PLUGIN_LDFLAGS) | 119 | $(GN_PLUGIN_LDFLAGS) |
@@ -125,10 +125,10 @@ libgnunetnamestore_la_SOURCES = \ | |||
125 | namestore_api_monitor.c \ | 125 | namestore_api_monitor.c \ |
126 | namestore.h | 126 | namestore.h |
127 | libgnunetnamestore_la_LIBADD = \ | 127 | libgnunetnamestore_la_LIBADD = \ |
128 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 128 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
129 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 129 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
130 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 130 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
131 | $(top_builddir)/src/util/libgnunetutil.la \ | 131 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
132 | $(GN_LIBINTL) | 132 | $(GN_LIBINTL) |
133 | libgnunetnamestore_la_LDFLAGS = \ | 133 | libgnunetnamestore_la_LDFLAGS = \ |
134 | $(GN_LIB_LDFLAGS) \ | 134 | $(GN_LIB_LDFLAGS) \ |
@@ -139,8 +139,8 @@ gnunet_namestore_zonefile_SOURCES = \ | |||
139 | gnunet_namestore_zonefile_LDADD = \ | 139 | gnunet_namestore_zonefile_LDADD = \ |
140 | libgnunetnamestore.la \ | 140 | libgnunetnamestore.la \ |
141 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 141 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
142 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 142 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
143 | $(top_builddir)/src/util/libgnunetutil.la \ | 143 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
144 | $(GN_LIBINTL) | 144 | $(GN_LIBINTL) |
145 | 145 | ||
146 | gnunet_zoneimport_SOURCES = \ | 146 | gnunet_zoneimport_SOURCES = \ |
@@ -149,23 +149,23 @@ gnunet_zoneimport_LDADD = \ | |||
149 | libgnunetnamestore.la \ | 149 | libgnunetnamestore.la \ |
150 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 150 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
151 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 151 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
152 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 152 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
153 | $(top_builddir)/src/util/libgnunetutil.la \ | 153 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
154 | $(GN_LIBINTL) | 154 | $(GN_LIBINTL) |
155 | 155 | ||
156 | gnunet_namestore_SOURCES = \ | 156 | gnunet_namestore_SOURCES = \ |
157 | gnunet-namestore.c | 157 | gnunet-namestore.c |
158 | gnunet_namestore_LDADD = \ | 158 | gnunet_namestore_LDADD = \ |
159 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 159 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
160 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 160 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
161 | $(top_builddir)/src/util/libgnunetutil.la \ | 161 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
162 | libgnunetnamestore.la \ | 162 | libgnunetnamestore.la \ |
163 | $(GN_LIBINTL) | 163 | $(GN_LIBINTL) |
164 | 164 | ||
165 | gnunet_namestore_dbtool_SOURCES = \ | 165 | gnunet_namestore_dbtool_SOURCES = \ |
166 | gnunet-namestore-dbtool.c | 166 | gnunet-namestore-dbtool.c |
167 | gnunet_namestore_dbtool_LDADD = \ | 167 | gnunet_namestore_dbtool_LDADD = \ |
168 | $(top_builddir)/src/util/libgnunetutil.la \ | 168 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
169 | libgnunetnamestore.la \ | 169 | libgnunetnamestore.la \ |
170 | $(GN_LIBINTL) | 170 | $(GN_LIBINTL) |
171 | 171 | ||
@@ -174,10 +174,10 @@ gnunet_namestore_dbtool_LDADD = \ | |||
174 | gnunet_namestore_fcfsd_SOURCES = \ | 174 | gnunet_namestore_fcfsd_SOURCES = \ |
175 | gnunet-namestore-fcfsd.c | 175 | gnunet-namestore-fcfsd.c |
176 | gnunet_namestore_fcfsd_LDADD = $(MHD_LIBS) \ | 176 | gnunet_namestore_fcfsd_LDADD = $(MHD_LIBS) \ |
177 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 177 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
178 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 178 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
179 | libgnunetnamestore.la \ | 179 | libgnunetnamestore.la \ |
180 | $(top_builddir)/src/util/libgnunetutil.la \ | 180 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
181 | $(top_builddir)/src/json/libgnunetjson.la \ | 181 | $(top_builddir)/src/json/libgnunetjson.la \ |
182 | $(GN_LIBINTL) -ljansson | 182 | $(GN_LIBINTL) -ljansson |
183 | gnunet_namestore_fcfsd_CFLAGS = $(MHD_CFLAGS) $(AM_CFLAGS) | 183 | gnunet_namestore_fcfsd_CFLAGS = $(MHD_CFLAGS) $(AM_CFLAGS) |
@@ -187,10 +187,10 @@ gnunet_service_namestore_SOURCES = \ | |||
187 | gnunet-service-namestore.c | 187 | gnunet-service-namestore.c |
188 | gnunet_service_namestore_LDADD = \ | 188 | gnunet_service_namestore_LDADD = \ |
189 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ | 189 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ |
190 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 190 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
191 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 191 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
192 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 192 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
193 | $(top_builddir)/src/util/libgnunetutil.la \ | 193 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
194 | libgnunetnamestore.la \ | 194 | libgnunetnamestore.la \ |
195 | $(GN_LIBINTL) | 195 | $(GN_LIBINTL) |
196 | 196 | ||
@@ -199,11 +199,11 @@ gnunet_service_namestore_LDADD = \ | |||
199 | libgnunet_plugin_namestore_sqlite_la_SOURCES = \ | 199 | libgnunet_plugin_namestore_sqlite_la_SOURCES = \ |
200 | plugin_namestore_sqlite.c | 200 | plugin_namestore_sqlite.c |
201 | libgnunet_plugin_namestore_sqlite_la_LIBADD = \ | 201 | libgnunet_plugin_namestore_sqlite_la_LIBADD = \ |
202 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 202 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
203 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 203 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
204 | $(top_builddir)/src/sq/libgnunetsq.la \ | 204 | $(top_builddir)/src/sq/libgnunetsq.la \ |
205 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 205 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
206 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) -lsqlite3 \ | 206 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) -lsqlite3 \ |
207 | $(LTLIBINTL) | 207 | $(LTLIBINTL) |
208 | libgnunet_plugin_namestore_sqlite_la_LDFLAGS = \ | 208 | libgnunet_plugin_namestore_sqlite_la_LDFLAGS = \ |
209 | $(GN_PLUGIN_LDFLAGS) | 209 | $(GN_PLUGIN_LDFLAGS) |
@@ -211,11 +211,11 @@ libgnunet_plugin_namestore_sqlite_la_LDFLAGS = \ | |||
211 | libgnunet_plugin_namestore_postgres_la_SOURCES = \ | 211 | libgnunet_plugin_namestore_postgres_la_SOURCES = \ |
212 | plugin_namestore_postgres.c | 212 | plugin_namestore_postgres.c |
213 | libgnunet_plugin_namestore_postgres_la_LIBADD = \ | 213 | libgnunet_plugin_namestore_postgres_la_LIBADD = \ |
214 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 214 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
215 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 215 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
216 | $(top_builddir)/src/pq/libgnunetpq.la \ | 216 | $(top_builddir)/src/pq/libgnunetpq.la \ |
217 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 217 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
218 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) -lpq \ | 218 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) -lpq \ |
219 | $(LTLIBINTL) | 219 | $(LTLIBINTL) |
220 | libgnunet_plugin_namestore_postgres_la_LDFLAGS = \ | 220 | libgnunet_plugin_namestore_postgres_la_LDFLAGS = \ |
221 | $(GN_PLUGIN_LDFLAGS) $(POSTGRESQL_LDFLAGS) | 221 | $(GN_PLUGIN_LDFLAGS) $(POSTGRESQL_LDFLAGS) |
@@ -224,8 +224,8 @@ test_namestore_api_store_sqlite_SOURCES = \ | |||
224 | test_namestore_api_store.c | 224 | test_namestore_api_store.c |
225 | test_namestore_api_store_sqlite_LDADD = \ | 225 | test_namestore_api_store_sqlite_LDADD = \ |
226 | $(top_builddir)/src/testing/libgnunettesting.la \ | 226 | $(top_builddir)/src/testing/libgnunettesting.la \ |
227 | $(top_builddir)/src/util/libgnunetutil.la \ | 227 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
228 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 228 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
229 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 229 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
230 | libgnunetnamestore.la | 230 | libgnunetnamestore.la |
231 | 231 | ||
@@ -233,8 +233,8 @@ test_namestore_api_store_postgres_SOURCES = \ | |||
233 | test_namestore_api_store.c | 233 | test_namestore_api_store.c |
234 | test_namestore_api_store_postgres_LDADD = \ | 234 | test_namestore_api_store_postgres_LDADD = \ |
235 | $(top_builddir)/src/testing/libgnunettesting.la \ | 235 | $(top_builddir)/src/testing/libgnunettesting.la \ |
236 | $(top_builddir)/src/util/libgnunetutil.la \ | 236 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
237 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 237 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
238 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 238 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
239 | libgnunetnamestore.la | 239 | libgnunetnamestore.la |
240 | 240 | ||
@@ -242,9 +242,9 @@ test_namestore_api_store_update_sqlite_SOURCES = \ | |||
242 | test_namestore_api_store_update.c | 242 | test_namestore_api_store_update.c |
243 | test_namestore_api_store_update_sqlite_LDADD = \ | 243 | test_namestore_api_store_update_sqlite_LDADD = \ |
244 | $(top_builddir)/src/testing/libgnunettesting.la \ | 244 | $(top_builddir)/src/testing/libgnunettesting.la \ |
245 | $(top_builddir)/src/util/libgnunetutil.la \ | 245 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
246 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 246 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
247 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 247 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
248 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ | 248 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ |
249 | libgnunetnamestore.la | 249 | libgnunetnamestore.la |
250 | 250 | ||
@@ -252,9 +252,9 @@ test_namestore_api_store_update_postgres_SOURCES = \ | |||
252 | test_namestore_api_store_update.c | 252 | test_namestore_api_store_update.c |
253 | test_namestore_api_store_update_postgres_LDADD = \ | 253 | test_namestore_api_store_update_postgres_LDADD = \ |
254 | $(top_builddir)/src/testing/libgnunettesting.la \ | 254 | $(top_builddir)/src/testing/libgnunettesting.la \ |
255 | $(top_builddir)/src/util/libgnunetutil.la \ | 255 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
256 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 256 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
257 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 257 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
258 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ | 258 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ |
259 | libgnunetnamestore.la | 259 | libgnunetnamestore.la |
260 | 260 | ||
@@ -262,9 +262,9 @@ test_namestore_api_lookup_nick_sqlite_SOURCES = \ | |||
262 | test_namestore_api_lookup_nick.c | 262 | test_namestore_api_lookup_nick.c |
263 | test_namestore_api_lookup_nick_sqlite_LDADD = \ | 263 | test_namestore_api_lookup_nick_sqlite_LDADD = \ |
264 | $(top_builddir)/src/testing/libgnunettesting.la \ | 264 | $(top_builddir)/src/testing/libgnunettesting.la \ |
265 | $(top_builddir)/src/util/libgnunetutil.la \ | 265 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
266 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 266 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
267 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 267 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
268 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ | 268 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ |
269 | libgnunetnamestore.la | 269 | libgnunetnamestore.la |
270 | 270 | ||
@@ -272,9 +272,9 @@ test_namestore_api_lookup_nick_postgres_SOURCES = \ | |||
272 | test_namestore_api_lookup_nick.c | 272 | test_namestore_api_lookup_nick.c |
273 | test_namestore_api_lookup_nick_postgres_LDADD = \ | 273 | test_namestore_api_lookup_nick_postgres_LDADD = \ |
274 | $(top_builddir)/src/testing/libgnunettesting.la \ | 274 | $(top_builddir)/src/testing/libgnunettesting.la \ |
275 | $(top_builddir)/src/util/libgnunetutil.la \ | 275 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
276 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 276 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
277 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 277 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
278 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ | 278 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ |
279 | libgnunetnamestore.la | 279 | libgnunetnamestore.la |
280 | 280 | ||
@@ -283,8 +283,8 @@ test_namestore_api_remove_sqlite_SOURCES = \ | |||
283 | test_namestore_api_remove_sqlite_LDADD = \ | 283 | test_namestore_api_remove_sqlite_LDADD = \ |
284 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 284 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
285 | $(top_builddir)/src/testing/libgnunettesting.la \ | 285 | $(top_builddir)/src/testing/libgnunettesting.la \ |
286 | $(top_builddir)/src/util/libgnunetutil.la \ | 286 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
287 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 287 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
288 | libgnunetnamestore.la | 288 | libgnunetnamestore.la |
289 | 289 | ||
290 | test_namestore_api_remove_postgres_SOURCES = \ | 290 | test_namestore_api_remove_postgres_SOURCES = \ |
@@ -292,17 +292,17 @@ test_namestore_api_remove_postgres_SOURCES = \ | |||
292 | test_namestore_api_remove_postgres_LDADD = \ | 292 | test_namestore_api_remove_postgres_LDADD = \ |
293 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 293 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
294 | $(top_builddir)/src/testing/libgnunettesting.la \ | 294 | $(top_builddir)/src/testing/libgnunettesting.la \ |
295 | $(top_builddir)/src/util/libgnunetutil.la \ | 295 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
296 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 296 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
297 | libgnunetnamestore.la | 297 | libgnunetnamestore.la |
298 | 298 | ||
299 | test_namestore_api_remove_not_existing_record_sqlite_SOURCES = \ | 299 | test_namestore_api_remove_not_existing_record_sqlite_SOURCES = \ |
300 | test_namestore_api_remove_not_existing_record.c | 300 | test_namestore_api_remove_not_existing_record.c |
301 | test_namestore_api_remove_not_existing_record_sqlite_LDADD = \ | 301 | test_namestore_api_remove_not_existing_record_sqlite_LDADD = \ |
302 | $(top_builddir)/src/testing/libgnunettesting.la \ | 302 | $(top_builddir)/src/testing/libgnunettesting.la \ |
303 | $(top_builddir)/src/util/libgnunetutil.la \ | 303 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
304 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 304 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
305 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 305 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
306 | libgnunetnamestore.la | 306 | libgnunetnamestore.la |
307 | 307 | ||
308 | test_namestore_api_remove_not_existing_record_postgres_SOURCES = \ | 308 | test_namestore_api_remove_not_existing_record_postgres_SOURCES = \ |
@@ -310,8 +310,8 @@ test_namestore_api_remove_not_existing_record_postgres_SOURCES = \ | |||
310 | test_namestore_api_remove_not_existing_record_postgres_LDADD = \ | 310 | test_namestore_api_remove_not_existing_record_postgres_LDADD = \ |
311 | $(top_builddir)/src/testing/libgnunettesting.la \ | 311 | $(top_builddir)/src/testing/libgnunettesting.la \ |
312 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 312 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
313 | $(top_builddir)/src/util/libgnunetutil.la \ | 313 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
314 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 314 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
315 | libgnunetnamestore.la | 315 | libgnunetnamestore.la |
316 | 316 | ||
317 | test_namestore_api_zone_to_name_sqlite_SOURCES = \ | 317 | test_namestore_api_zone_to_name_sqlite_SOURCES = \ |
@@ -319,7 +319,7 @@ test_namestore_api_zone_to_name_sqlite_SOURCES = \ | |||
319 | test_namestore_api_zone_to_name_sqlite_LDADD = \ | 319 | test_namestore_api_zone_to_name_sqlite_LDADD = \ |
320 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 320 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
321 | $(top_builddir)/src/testing/libgnunettesting.la \ | 321 | $(top_builddir)/src/testing/libgnunettesting.la \ |
322 | $(top_builddir)/src/util/libgnunetutil.la \ | 322 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
323 | libgnunetnamestore.la | 323 | libgnunetnamestore.la |
324 | 324 | ||
325 | test_namestore_api_zone_to_name_postgres_SOURCES = \ | 325 | test_namestore_api_zone_to_name_postgres_SOURCES = \ |
@@ -327,7 +327,7 @@ test_namestore_api_zone_to_name_postgres_SOURCES = \ | |||
327 | test_namestore_api_zone_to_name_postgres_LDADD = \ | 327 | test_namestore_api_zone_to_name_postgres_LDADD = \ |
328 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 328 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
329 | $(top_builddir)/src/testing/libgnunettesting.la \ | 329 | $(top_builddir)/src/testing/libgnunettesting.la \ |
330 | $(top_builddir)/src/util/libgnunetutil.la \ | 330 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
331 | libgnunetnamestore.la | 331 | libgnunetnamestore.la |
332 | 332 | ||
333 | test_namestore_api_monitoring_sqlite_SOURCES = \ | 333 | test_namestore_api_monitoring_sqlite_SOURCES = \ |
@@ -336,8 +336,8 @@ test_namestore_api_monitoring_sqlite_LDADD = \ | |||
336 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 336 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
337 | $(top_builddir)/src/testing/libgnunettesting.la \ | 337 | $(top_builddir)/src/testing/libgnunettesting.la \ |
338 | libgnunetnamestore.la \ | 338 | libgnunetnamestore.la \ |
339 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 339 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
340 | $(top_builddir)/src/util/libgnunetutil.la | 340 | $(top_builddir)/src/lib/util/libgnunetutil.la |
341 | 341 | ||
342 | test_namestore_api_monitoring_postgres_SOURCES = \ | 342 | test_namestore_api_monitoring_postgres_SOURCES = \ |
343 | test_namestore_api_monitoring.c | 343 | test_namestore_api_monitoring.c |
@@ -345,8 +345,8 @@ test_namestore_api_monitoring_postgres_LDADD = \ | |||
345 | $(top_builddir)/src/testing/libgnunettesting.la \ | 345 | $(top_builddir)/src/testing/libgnunettesting.la \ |
346 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 346 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
347 | libgnunetnamestore.la \ | 347 | libgnunetnamestore.la \ |
348 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 348 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
349 | $(top_builddir)/src/util/libgnunetutil.la | 349 | $(top_builddir)/src/lib/util/libgnunetutil.la |
350 | 350 | ||
351 | test_namestore_api_monitoring_existing_sqlite_SOURCES = \ | 351 | test_namestore_api_monitoring_existing_sqlite_SOURCES = \ |
352 | test_namestore_api_monitoring_existing.c | 352 | test_namestore_api_monitoring_existing.c |
@@ -354,17 +354,17 @@ test_namestore_api_monitoring_existing_sqlite_LDADD = \ | |||
354 | $(top_builddir)/src/testing/libgnunettesting.la \ | 354 | $(top_builddir)/src/testing/libgnunettesting.la \ |
355 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 355 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
356 | libgnunetnamestore.la \ | 356 | libgnunetnamestore.la \ |
357 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 357 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
358 | $(top_builddir)/src/util/libgnunetutil.la | 358 | $(top_builddir)/src/lib/util/libgnunetutil.la |
359 | 359 | ||
360 | test_namestore_api_monitoring_existing_postgres_SOURCES = \ | 360 | test_namestore_api_monitoring_existing_postgres_SOURCES = \ |
361 | test_namestore_api_monitoring_existing.c | 361 | test_namestore_api_monitoring_existing.c |
362 | test_namestore_api_monitoring_existing_postgres_LDADD = \ | 362 | test_namestore_api_monitoring_existing_postgres_LDADD = \ |
363 | $(top_builddir)/src/testing/libgnunettesting.la \ | 363 | $(top_builddir)/src/testing/libgnunettesting.la \ |
364 | libgnunetnamestore.la \ | 364 | libgnunetnamestore.la \ |
365 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 365 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
366 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 366 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
367 | $(top_builddir)/src/util/libgnunetutil.la | 367 | $(top_builddir)/src/lib/util/libgnunetutil.la |
368 | 368 | ||
369 | test_namestore_api_tx_rollback_sqlite_SOURCES = \ | 369 | test_namestore_api_tx_rollback_sqlite_SOURCES = \ |
370 | test_namestore_api_tx_rollback.c | 370 | test_namestore_api_tx_rollback.c |
@@ -372,8 +372,8 @@ test_namestore_api_tx_rollback_sqlite_LDADD = \ | |||
372 | $(top_builddir)/src/testing/libgnunettesting.la \ | 372 | $(top_builddir)/src/testing/libgnunettesting.la \ |
373 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 373 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
374 | libgnunetnamestore.la \ | 374 | libgnunetnamestore.la \ |
375 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 375 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
376 | $(top_builddir)/src/util/libgnunetutil.la | 376 | $(top_builddir)/src/lib/util/libgnunetutil.la |
377 | 377 | ||
378 | test_namestore_api_tx_rollback_postgres_SOURCES = \ | 378 | test_namestore_api_tx_rollback_postgres_SOURCES = \ |
379 | test_namestore_api_tx_rollback.c | 379 | test_namestore_api_tx_rollback.c |
@@ -381,8 +381,8 @@ test_namestore_api_tx_rollback_postgres_LDADD = \ | |||
381 | $(top_builddir)/src/testing/libgnunettesting.la \ | 381 | $(top_builddir)/src/testing/libgnunettesting.la \ |
382 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 382 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
383 | libgnunetnamestore.la \ | 383 | libgnunetnamestore.la \ |
384 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 384 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
385 | $(top_builddir)/src/util/libgnunetutil.la | 385 | $(top_builddir)/src/lib/util/libgnunetutil.la |
386 | 386 | ||
387 | if HAVE_EXPERIMENTAL | 387 | if HAVE_EXPERIMENTAL |
388 | test_namestore_api_edit_records_postgres_SOURCES = \ | 388 | test_namestore_api_edit_records_postgres_SOURCES = \ |
@@ -391,8 +391,8 @@ test_namestore_api_edit_records_postgres_LDADD = \ | |||
391 | $(top_builddir)/src/testing/libgnunettesting.la \ | 391 | $(top_builddir)/src/testing/libgnunettesting.la \ |
392 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 392 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
393 | libgnunetnamestore.la \ | 393 | libgnunetnamestore.la \ |
394 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 394 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
395 | $(top_builddir)/src/util/libgnunetutil.la | 395 | $(top_builddir)/src/lib/util/libgnunetutil.la |
396 | endif | 396 | endif |
397 | 397 | ||
398 | test_namestore_api_zone_iteration_sqlite_SOURCES = \ | 398 | test_namestore_api_zone_iteration_sqlite_SOURCES = \ |
@@ -400,8 +400,8 @@ test_namestore_api_zone_iteration_sqlite_SOURCES = \ | |||
400 | test_namestore_api_zone_iteration_sqlite_LDADD = \ | 400 | test_namestore_api_zone_iteration_sqlite_LDADD = \ |
401 | $(top_builddir)/src/testing/libgnunettesting.la \ | 401 | $(top_builddir)/src/testing/libgnunettesting.la \ |
402 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 402 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
403 | $(top_builddir)/src/util/libgnunetutil.la \ | 403 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
404 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 404 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
405 | libgnunetnamestore.la | 405 | libgnunetnamestore.la |
406 | 406 | ||
407 | test_namestore_api_zone_iteration_postgres_SOURCES = \ | 407 | test_namestore_api_zone_iteration_postgres_SOURCES = \ |
@@ -409,35 +409,35 @@ test_namestore_api_zone_iteration_postgres_SOURCES = \ | |||
409 | test_namestore_api_zone_iteration_postgres_LDADD = \ | 409 | test_namestore_api_zone_iteration_postgres_LDADD = \ |
410 | $(top_builddir)/src/testing/libgnunettesting.la \ | 410 | $(top_builddir)/src/testing/libgnunettesting.la \ |
411 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 411 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
412 | $(top_builddir)/src/util/libgnunetutil.la \ | 412 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
413 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 413 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
414 | libgnunetnamestore.la | 414 | libgnunetnamestore.la |
415 | 415 | ||
416 | perf_namestore_api_zone_iteration_postgres_SOURCES = \ | 416 | perf_namestore_api_zone_iteration_postgres_SOURCES = \ |
417 | perf_namestore_api_zone_iteration.c | 417 | perf_namestore_api_zone_iteration.c |
418 | perf_namestore_api_zone_iteration_postgres_LDADD = \ | 418 | perf_namestore_api_zone_iteration_postgres_LDADD = \ |
419 | $(top_builddir)/src/testing/libgnunettesting.la \ | 419 | $(top_builddir)/src/testing/libgnunettesting.la \ |
420 | $(top_builddir)/src/util/libgnunetutil.la \ | 420 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
421 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 421 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
422 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 422 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
423 | libgnunetnamestore.la | 423 | libgnunetnamestore.la |
424 | 424 | ||
425 | perf_namestore_api_import_sqlite_SOURCES = \ | 425 | perf_namestore_api_import_sqlite_SOURCES = \ |
426 | perf_namestore_api_import.c | 426 | perf_namestore_api_import.c |
427 | perf_namestore_api_import_sqlite_LDADD = \ | 427 | perf_namestore_api_import_sqlite_LDADD = \ |
428 | $(top_builddir)/src/testing/libgnunettesting.la \ | 428 | $(top_builddir)/src/testing/libgnunettesting.la \ |
429 | $(top_builddir)/src/util/libgnunetutil.la \ | 429 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
430 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 430 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
431 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 431 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
432 | libgnunetnamestore.la | 432 | libgnunetnamestore.la |
433 | 433 | ||
434 | perf_namestore_api_import_postgres_SOURCES = \ | 434 | perf_namestore_api_import_postgres_SOURCES = \ |
435 | perf_namestore_api_import.c | 435 | perf_namestore_api_import.c |
436 | perf_namestore_api_import_postgres_LDADD = \ | 436 | perf_namestore_api_import_postgres_LDADD = \ |
437 | $(top_builddir)/src/testing/libgnunettesting.la \ | 437 | $(top_builddir)/src/testing/libgnunettesting.la \ |
438 | $(top_builddir)/src/util/libgnunetutil.la \ | 438 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
439 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 439 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
440 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 440 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
441 | libgnunetnamestore.la | 441 | libgnunetnamestore.la |
442 | 442 | ||
443 | 443 | ||
@@ -446,8 +446,8 @@ perf_namestore_api_zone_iteration_sqlite_SOURCES = \ | |||
446 | perf_namestore_api_zone_iteration_sqlite_LDADD = \ | 446 | perf_namestore_api_zone_iteration_sqlite_LDADD = \ |
447 | $(top_builddir)/src/testing/libgnunettesting.la \ | 447 | $(top_builddir)/src/testing/libgnunettesting.la \ |
448 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 448 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
449 | $(top_builddir)/src/util/libgnunetutil.la \ | 449 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
450 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 450 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
451 | libgnunetnamestore.la | 451 | libgnunetnamestore.la |
452 | 452 | ||
453 | test_namestore_api_zone_iteration_nick_sqlite_SOURCES = \ | 453 | test_namestore_api_zone_iteration_nick_sqlite_SOURCES = \ |
@@ -455,8 +455,8 @@ test_namestore_api_zone_iteration_nick_sqlite_SOURCES = \ | |||
455 | test_namestore_api_zone_iteration_nick_sqlite_LDADD = \ | 455 | test_namestore_api_zone_iteration_nick_sqlite_LDADD = \ |
456 | $(top_builddir)/src/testing/libgnunettesting.la \ | 456 | $(top_builddir)/src/testing/libgnunettesting.la \ |
457 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 457 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
458 | $(top_builddir)/src/util/libgnunetutil.la \ | 458 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
459 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 459 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
460 | libgnunetnamestore.la | 460 | libgnunetnamestore.la |
461 | 461 | ||
462 | test_namestore_api_zone_iteration_nick_postgres_SOURCES = \ | 462 | test_namestore_api_zone_iteration_nick_postgres_SOURCES = \ |
@@ -464,8 +464,8 @@ test_namestore_api_zone_iteration_nick_postgres_SOURCES = \ | |||
464 | test_namestore_api_zone_iteration_nick_postgres_LDADD = \ | 464 | test_namestore_api_zone_iteration_nick_postgres_LDADD = \ |
465 | $(top_builddir)/src/testing/libgnunettesting.la \ | 465 | $(top_builddir)/src/testing/libgnunettesting.la \ |
466 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 466 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
467 | $(top_builddir)/src/util/libgnunetutil.la \ | 467 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
468 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 468 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
469 | libgnunetnamestore.la | 469 | libgnunetnamestore.la |
470 | 470 | ||
471 | test_namestore_api_zone_iteration_specific_zone_sqlite_SOURCES = \ | 471 | test_namestore_api_zone_iteration_specific_zone_sqlite_SOURCES = \ |
@@ -473,8 +473,8 @@ test_namestore_api_zone_iteration_specific_zone_sqlite_SOURCES = \ | |||
473 | test_namestore_api_zone_iteration_specific_zone_sqlite_LDADD = \ | 473 | test_namestore_api_zone_iteration_specific_zone_sqlite_LDADD = \ |
474 | $(top_builddir)/src/testing/libgnunettesting.la \ | 474 | $(top_builddir)/src/testing/libgnunettesting.la \ |
475 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 475 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
476 | $(top_builddir)/src/util/libgnunetutil.la \ | 476 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
477 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 477 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
478 | libgnunetnamestore.la | 478 | libgnunetnamestore.la |
479 | 479 | ||
480 | test_namestore_api_zone_iteration_specific_zone_postgres_SOURCES = \ | 480 | test_namestore_api_zone_iteration_specific_zone_postgres_SOURCES = \ |
@@ -482,8 +482,8 @@ test_namestore_api_zone_iteration_specific_zone_postgres_SOURCES = \ | |||
482 | test_namestore_api_zone_iteration_specific_zone_postgres_LDADD = \ | 482 | test_namestore_api_zone_iteration_specific_zone_postgres_LDADD = \ |
483 | $(top_builddir)/src/testing/libgnunettesting.la \ | 483 | $(top_builddir)/src/testing/libgnunettesting.la \ |
484 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 484 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
485 | $(top_builddir)/src/util/libgnunetutil.la \ | 485 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
486 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 486 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
487 | libgnunetnamestore.la | 487 | libgnunetnamestore.la |
488 | 488 | ||
489 | test_namestore_api_zone_iteration_stop_sqlite_SOURCES = \ | 489 | test_namestore_api_zone_iteration_stop_sqlite_SOURCES = \ |
@@ -491,8 +491,8 @@ test_namestore_api_zone_iteration_stop_sqlite_SOURCES = \ | |||
491 | test_namestore_api_zone_iteration_stop_sqlite_LDADD = \ | 491 | test_namestore_api_zone_iteration_stop_sqlite_LDADD = \ |
492 | $(top_builddir)/src/testing/libgnunettesting.la \ | 492 | $(top_builddir)/src/testing/libgnunettesting.la \ |
493 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 493 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
494 | $(top_builddir)/src/util/libgnunetutil.la \ | 494 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
495 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 495 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
496 | libgnunetnamestore.la | 496 | libgnunetnamestore.la |
497 | 497 | ||
498 | test_namestore_api_zone_iteration_stop_postgres_SOURCES = \ | 498 | test_namestore_api_zone_iteration_stop_postgres_SOURCES = \ |
@@ -500,8 +500,8 @@ test_namestore_api_zone_iteration_stop_postgres_SOURCES = \ | |||
500 | test_namestore_api_zone_iteration_stop_postgres_LDADD = \ | 500 | test_namestore_api_zone_iteration_stop_postgres_LDADD = \ |
501 | $(top_builddir)/src/testing/libgnunettesting.la \ | 501 | $(top_builddir)/src/testing/libgnunettesting.la \ |
502 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 502 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
503 | $(top_builddir)/src/util/libgnunetutil.la \ | 503 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
504 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 504 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
505 | libgnunetnamestore.la | 505 | libgnunetnamestore.la |
506 | 506 | ||
507 | test_plugin_namestore_sqlite_SOURCES = \ | 507 | test_plugin_namestore_sqlite_SOURCES = \ |
@@ -509,14 +509,14 @@ test_plugin_namestore_sqlite_SOURCES = \ | |||
509 | test_plugin_namestore_sqlite_LDADD = \ | 509 | test_plugin_namestore_sqlite_LDADD = \ |
510 | $(top_builddir)/src/testing/libgnunettesting.la \ | 510 | $(top_builddir)/src/testing/libgnunettesting.la \ |
511 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 511 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
512 | $(top_builddir)/src/util/libgnunetutil.la | 512 | $(top_builddir)/src/lib/util/libgnunetutil.la |
513 | 513 | ||
514 | test_plugin_namestore_postgres_SOURCES = \ | 514 | test_plugin_namestore_postgres_SOURCES = \ |
515 | test_plugin_namestore.c | 515 | test_plugin_namestore.c |
516 | test_plugin_namestore_postgres_LDADD = \ | 516 | test_plugin_namestore_postgres_LDADD = \ |
517 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 517 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
518 | $(top_builddir)/src/testing/libgnunettesting.la \ | 518 | $(top_builddir)/src/testing/libgnunettesting.la \ |
519 | $(top_builddir)/src/util/libgnunetutil.la | 519 | $(top_builddir)/src/lib/util/libgnunetutil.la |
520 | 520 | ||
521 | check_SCRIPTS = \ | 521 | check_SCRIPTS = \ |
522 | test_namestore_put.sh \ | 522 | test_namestore_put.sh \ |
diff --git a/src/namestore/gnunet-namestore-fcfsd.c b/src/namestore/gnunet-namestore-fcfsd.c index 857b16def..4948ae441 100644 --- a/src/namestore/gnunet-namestore-fcfsd.c +++ b/src/namestore/gnunet-namestore-fcfsd.c | |||
@@ -110,7 +110,7 @@ struct RequestData | |||
110 | /** | 110 | /** |
111 | * Key to be associated with the requested name. | 111 | * Key to be associated with the requested name. |
112 | */ | 112 | */ |
113 | struct GNUNET_IDENTITY_PublicKey key; | 113 | struct GNUNET_CRYPTO_PublicKey key; |
114 | }; | 114 | }; |
115 | 115 | ||
116 | /** | 116 | /** |
@@ -136,7 +136,7 @@ static struct GNUNET_IDENTITY_Handle *identity = NULL; | |||
136 | /** | 136 | /** |
137 | * Private key of the zone. | 137 | * Private key of the zone. |
138 | */ | 138 | */ |
139 | static const struct GNUNET_IDENTITY_PrivateKey *zone_key = NULL; | 139 | static const struct GNUNET_CRYPTO_PrivateKey *zone_key = NULL; |
140 | 140 | ||
141 | /** | 141 | /** |
142 | * The HTTP daemon. | 142 | * The HTTP daemon. |
@@ -389,7 +389,7 @@ search_error_cb (void *cls) | |||
389 | */ | 389 | */ |
390 | static void | 390 | static void |
391 | search_done_cb (void *cls, | 391 | search_done_cb (void *cls, |
392 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 392 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
393 | const char *label, | 393 | const char *label, |
394 | unsigned int count, | 394 | unsigned int count, |
395 | const struct GNUNET_GNSRECORD_Data *d) | 395 | const struct GNUNET_GNSRECORD_Data *d) |
@@ -478,7 +478,7 @@ register_done_cb (void *cls, | |||
478 | */ | 478 | */ |
479 | static void | 479 | static void |
480 | register_do_cb (void *cls, | 480 | register_do_cb (void *cls, |
481 | const struct GNUNET_IDENTITY_PrivateKey *key, | 481 | const struct GNUNET_CRYPTO_PrivateKey *key, |
482 | const char *label, | 482 | const char *label, |
483 | unsigned int count, | 483 | unsigned int count, |
484 | const struct GNUNET_GNSRECORD_Data *d) | 484 | const struct GNUNET_GNSRECORD_Data *d) |
@@ -577,7 +577,7 @@ iterate_error_cb (void *cls) | |||
577 | */ | 577 | */ |
578 | static void | 578 | static void |
579 | iterate_do_cb (void *cls, | 579 | iterate_do_cb (void *cls, |
580 | const struct GNUNET_IDENTITY_PrivateKey *key, | 580 | const struct GNUNET_CRYPTO_PrivateKey *key, |
581 | const char *label, | 581 | const char *label, |
582 | unsigned int count, | 582 | unsigned int count, |
583 | const struct GNUNET_GNSRECORD_Data *d) | 583 | const struct GNUNET_GNSRECORD_Data *d) |
@@ -838,7 +838,7 @@ create_response (void *cls, | |||
838 | return MHD_YES; | 838 | return MHD_YES; |
839 | } | 839 | } |
840 | 840 | ||
841 | if (GNUNET_OK != GNUNET_IDENTITY_public_key_from_string (rd->register_key, | 841 | if (GNUNET_OK != GNUNET_CRYPTO_public_key_from_string (rd->register_key, |
842 | &(rd->key))) | 842 | &(rd->key))) |
843 | { | 843 | { |
844 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | 844 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, |
diff --git a/src/namestore/gnunet-namestore-zonefile.c b/src/namestore/gnunet-namestore-zonefile.c index d9331aa32..dfd438e94 100644 --- a/src/namestore/gnunet-namestore-zonefile.c +++ b/src/namestore/gnunet-namestore-zonefile.c | |||
@@ -94,7 +94,7 @@ static struct GNUNET_IDENTITY_EgoLookup *el; | |||
94 | /** | 94 | /** |
95 | * Private key for the our zone. | 95 | * Private key for the our zone. |
96 | */ | 96 | */ |
97 | static struct GNUNET_IDENTITY_PrivateKey zone_pkey; | 97 | static struct GNUNET_CRYPTO_PrivateKey zone_pkey; |
98 | 98 | ||
99 | /** | 99 | /** |
100 | * Queue entry for the 'add' operation. | 100 | * Queue entry for the 'add' operation. |
@@ -282,7 +282,7 @@ parse_origin (char *token, char *origin) | |||
282 | } | 282 | } |
283 | 283 | ||
284 | static void | 284 | static void |
285 | origin_create_cb (void *cls, const struct GNUNET_IDENTITY_PrivateKey *pk, | 285 | origin_create_cb (void *cls, const struct GNUNET_CRYPTO_PrivateKey *pk, |
286 | enum GNUNET_ErrorCode ec) | 286 | enum GNUNET_ErrorCode ec) |
287 | { | 287 | { |
288 | id_op = NULL; | 288 | id_op = NULL; |
@@ -309,7 +309,7 @@ origin_lookup_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
309 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 309 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
310 | "$ORIGIN %s does not exist, creating...\n", ego_name); | 310 | "$ORIGIN %s does not exist, creating...\n", ego_name); |
311 | id_op = GNUNET_IDENTITY_create (id, ego_name, NULL, | 311 | id_op = GNUNET_IDENTITY_create (id, ego_name, NULL, |
312 | GNUNET_IDENTITY_TYPE_ECDSA, // FIXME make configurable | 312 | GNUNET_PUBLIC_KEY_TYPE_ECDSA, // FIXME make configurable |
313 | origin_create_cb, | 313 | origin_create_cb, |
314 | NULL); | 314 | NULL); |
315 | return; | 315 | return; |
diff --git a/src/namestore/gnunet-namestore.c b/src/namestore/gnunet-namestore.c index 0329c9c63..baa036ac7 100644 --- a/src/namestore/gnunet-namestore.c +++ b/src/namestore/gnunet-namestore.c | |||
@@ -79,7 +79,7 @@ struct MarkedRecord | |||
79 | /** | 79 | /** |
80 | * The zone key | 80 | * The zone key |
81 | */ | 81 | */ |
82 | struct GNUNET_IDENTITY_PrivateKey key; | 82 | struct GNUNET_CRYPTO_PrivateKey key; |
83 | }; | 83 | }; |
84 | 84 | ||
85 | /** | 85 | /** |
@@ -116,7 +116,7 @@ static struct GNUNET_NAMESTORE_Handle *ns; | |||
116 | /** | 116 | /** |
117 | * Private key for the our zone. | 117 | * Private key for the our zone. |
118 | */ | 118 | */ |
119 | static struct GNUNET_IDENTITY_PrivateKey zone_pkey; | 119 | static struct GNUNET_CRYPTO_PrivateKey zone_pkey; |
120 | 120 | ||
121 | /** | 121 | /** |
122 | * Identity service handle | 122 | * Identity service handle |
@@ -765,7 +765,7 @@ zone_iteration_error_cb (void *cls) | |||
765 | 765 | ||
766 | static void | 766 | static void |
767 | collect_zone_records_to_purge (const struct | 767 | collect_zone_records_to_purge (const struct |
768 | GNUNET_IDENTITY_PrivateKey *zone_key, | 768 | GNUNET_CRYPTO_PrivateKey *zone_key, |
769 | const char *rname, | 769 | const char *rname, |
770 | unsigned int rd_len, | 770 | unsigned int rd_len, |
771 | const struct GNUNET_GNSRECORD_Data *rd) | 771 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -782,7 +782,7 @@ collect_zone_records_to_purge (const struct | |||
782 | 782 | ||
783 | 783 | ||
784 | static void | 784 | static void |
785 | collect_orphans (const struct GNUNET_IDENTITY_PrivateKey *zone_key, | 785 | collect_orphans (const struct GNUNET_CRYPTO_PrivateKey *zone_key, |
786 | const char *rname, | 786 | const char *rname, |
787 | unsigned int rd_len, | 787 | unsigned int rd_len, |
788 | const struct GNUNET_GNSRECORD_Data *rd) | 788 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -820,7 +820,7 @@ collect_orphans (const struct GNUNET_IDENTITY_PrivateKey *zone_key, | |||
820 | * @param rd array of records with data to store | 820 | * @param rd array of records with data to store |
821 | */ | 821 | */ |
822 | static void | 822 | static void |
823 | display_record (const struct GNUNET_IDENTITY_PrivateKey *zone_key, | 823 | display_record (const struct GNUNET_CRYPTO_PrivateKey *zone_key, |
824 | const char *rname, | 824 | const char *rname, |
825 | unsigned int rd_len, | 825 | unsigned int rd_len, |
826 | const struct GNUNET_GNSRECORD_Data *rd) | 826 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -864,7 +864,7 @@ display_record (const struct GNUNET_IDENTITY_PrivateKey *zone_key, | |||
864 | return; | 864 | return; |
865 | if (! list_orphaned && is_orphaned) | 865 | if (! list_orphaned && is_orphaned) |
866 | return; | 866 | return; |
867 | orphaned_str = GNUNET_IDENTITY_private_key_to_string (zone_key); | 867 | orphaned_str = GNUNET_CRYPTO_private_key_to_string (zone_key); |
868 | fprintf (stdout, "%s.%s:\n", rname, is_orphaned ? orphaned_str : | 868 | fprintf (stdout, "%s.%s:\n", rname, is_orphaned ? orphaned_str : |
869 | ego->identifier); | 869 | ego->identifier); |
870 | GNUNET_free (orphaned_str); | 870 | GNUNET_free (orphaned_str); |
@@ -931,7 +931,7 @@ display_record (const struct GNUNET_IDENTITY_PrivateKey *zone_key, | |||
931 | 931 | ||
932 | static void | 932 | static void |
933 | purge_zone_iterator (void *cls, | 933 | purge_zone_iterator (void *cls, |
934 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, | 934 | const struct GNUNET_CRYPTO_PrivateKey *zone_key, |
935 | const char *rname, | 935 | const char *rname, |
936 | unsigned int rd_len, | 936 | unsigned int rd_len, |
937 | const struct GNUNET_GNSRECORD_Data *rd, | 937 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -947,7 +947,7 @@ purge_zone_iterator (void *cls, | |||
947 | 947 | ||
948 | static void | 948 | static void |
949 | purge_orphans_iterator (void *cls, | 949 | purge_orphans_iterator (void *cls, |
950 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, | 950 | const struct GNUNET_CRYPTO_PrivateKey *zone_key, |
951 | const char *rname, | 951 | const char *rname, |
952 | unsigned int rd_len, | 952 | unsigned int rd_len, |
953 | const struct GNUNET_GNSRECORD_Data *rd, | 953 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -972,7 +972,7 @@ purge_orphans_iterator (void *cls, | |||
972 | */ | 972 | */ |
973 | static void | 973 | static void |
974 | display_record_iterator (void *cls, | 974 | display_record_iterator (void *cls, |
975 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, | 975 | const struct GNUNET_CRYPTO_PrivateKey *zone_key, |
976 | const char *rname, | 976 | const char *rname, |
977 | unsigned int rd_len, | 977 | unsigned int rd_len, |
978 | const struct GNUNET_GNSRECORD_Data *rd, | 978 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -997,7 +997,7 @@ display_record_iterator (void *cls, | |||
997 | */ | 997 | */ |
998 | static void | 998 | static void |
999 | display_record_monitor (void *cls, | 999 | display_record_monitor (void *cls, |
1000 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, | 1000 | const struct GNUNET_CRYPTO_PrivateKey *zone_key, |
1001 | const char *rname, | 1001 | const char *rname, |
1002 | unsigned int rd_len, | 1002 | unsigned int rd_len, |
1003 | const struct GNUNET_GNSRECORD_Data *rd, | 1003 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -1022,7 +1022,7 @@ display_record_monitor (void *cls, | |||
1022 | */ | 1022 | */ |
1023 | static void | 1023 | static void |
1024 | display_record_lookup (void *cls, | 1024 | display_record_lookup (void *cls, |
1025 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, | 1025 | const struct GNUNET_CRYPTO_PrivateKey *zone_key, |
1026 | const char *rname, | 1026 | const char *rname, |
1027 | unsigned int rd_len, | 1027 | unsigned int rd_len, |
1028 | const struct GNUNET_GNSRECORD_Data *rd) | 1028 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1102,7 +1102,7 @@ add_error_cb (void *cls) | |||
1102 | */ | 1102 | */ |
1103 | static void | 1103 | static void |
1104 | get_existing_record (void *cls, | 1104 | get_existing_record (void *cls, |
1105 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, | 1105 | const struct GNUNET_CRYPTO_PrivateKey *zone_key, |
1106 | const char *rec_name, | 1106 | const char *rec_name, |
1107 | unsigned int rd_count, | 1107 | unsigned int rd_count, |
1108 | const struct GNUNET_GNSRECORD_Data *rd) | 1108 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1194,7 +1194,7 @@ reverse_error_cb (void *cls) | |||
1194 | */ | 1194 | */ |
1195 | static void | 1195 | static void |
1196 | handle_reverse_lookup (void *cls, | 1196 | handle_reverse_lookup (void *cls, |
1197 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 1197 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
1198 | const char *label, | 1198 | const char *label, |
1199 | unsigned int rd_count, | 1199 | unsigned int rd_count, |
1200 | const struct GNUNET_GNSRECORD_Data *rd) | 1200 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1239,7 +1239,7 @@ del_lookup_error_cb (void *cls) | |||
1239 | */ | 1239 | */ |
1240 | static void | 1240 | static void |
1241 | del_monitor (void *cls, | 1241 | del_monitor (void *cls, |
1242 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 1242 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
1243 | const char *label, | 1243 | const char *label, |
1244 | unsigned int rd_count, | 1244 | unsigned int rd_count, |
1245 | const struct GNUNET_GNSRECORD_Data *rd) | 1245 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1622,7 +1622,7 @@ run_with_zone_pkey (const struct GNUNET_CONFIGURATION_Handle *cfg) | |||
1622 | } | 1622 | } |
1623 | if (NULL != reverse_pkey) | 1623 | if (NULL != reverse_pkey) |
1624 | { | 1624 | { |
1625 | struct GNUNET_IDENTITY_PublicKey pubkey; | 1625 | struct GNUNET_CRYPTO_PublicKey pubkey; |
1626 | 1626 | ||
1627 | if (NULL == ego_name) | 1627 | if (NULL == ego_name) |
1628 | { | 1628 | { |
@@ -1635,7 +1635,7 @@ run_with_zone_pkey (const struct GNUNET_CONFIGURATION_Handle *cfg) | |||
1635 | return; | 1635 | return; |
1636 | } | 1636 | } |
1637 | if (GNUNET_OK != | 1637 | if (GNUNET_OK != |
1638 | GNUNET_IDENTITY_public_key_from_string (reverse_pkey, | 1638 | GNUNET_CRYPTO_public_key_from_string (reverse_pkey, |
1639 | &pubkey)) | 1639 | &pubkey)) |
1640 | { | 1640 | { |
1641 | fprintf (stderr, | 1641 | fprintf (stderr, |
@@ -1657,7 +1657,7 @@ run_with_zone_pkey (const struct GNUNET_CONFIGURATION_Handle *cfg) | |||
1657 | { | 1657 | { |
1658 | char sh[105]; | 1658 | char sh[105]; |
1659 | char sname[64]; | 1659 | char sname[64]; |
1660 | struct GNUNET_IDENTITY_PublicKey pkey; | 1660 | struct GNUNET_CRYPTO_PublicKey pkey; |
1661 | if (NULL == ego_name) | 1661 | if (NULL == ego_name) |
1662 | { | 1662 | { |
1663 | fprintf (stderr, | 1663 | fprintf (stderr, |
@@ -1674,7 +1674,7 @@ run_with_zone_pkey (const struct GNUNET_CONFIGURATION_Handle *cfg) | |||
1674 | 1674 | ||
1675 | if ((2 != (sscanf (uri, "gnunet://gns/%58s/%63s", sh, sname))) || | 1675 | if ((2 != (sscanf (uri, "gnunet://gns/%58s/%63s", sh, sname))) || |
1676 | (GNUNET_OK != | 1676 | (GNUNET_OK != |
1677 | GNUNET_IDENTITY_public_key_from_string (sh, &pkey))) | 1677 | GNUNET_CRYPTO_public_key_from_string (sh, &pkey))) |
1678 | { | 1678 | { |
1679 | fprintf (stderr, _ ("Invalid URI `%s'\n"), uri); | 1679 | fprintf (stderr, _ ("Invalid URI `%s'\n"), uri); |
1680 | ret = 1; | 1680 | ret = 1; |
@@ -1700,7 +1700,7 @@ run_with_zone_pkey (const struct GNUNET_CONFIGURATION_Handle *cfg) | |||
1700 | } | 1700 | } |
1701 | memset (&rd, 0, sizeof(rd)); | 1701 | memset (&rd, 0, sizeof(rd)); |
1702 | rd.data = &pkey; | 1702 | rd.data = &pkey; |
1703 | rd.data_size = GNUNET_IDENTITY_public_key_get_length (&pkey); | 1703 | rd.data_size = GNUNET_CRYPTO_public_key_get_length (&pkey); |
1704 | rd.record_type = ntohl (pkey.type); | 1704 | rd.record_type = ntohl (pkey.type); |
1705 | rd.expiration_time = etime; | 1705 | rd.expiration_time = etime; |
1706 | if (GNUNET_YES == etime_is_rel) | 1706 | if (GNUNET_YES == etime_is_rel) |
@@ -1737,14 +1737,14 @@ run_with_zone_pkey (const struct GNUNET_CONFIGURATION_Handle *cfg) | |||
1737 | 1737 | ||
1738 | static int | 1738 | static int |
1739 | get_identity_for_string (const char *str, | 1739 | get_identity_for_string (const char *str, |
1740 | struct GNUNET_IDENTITY_PrivateKey *zk) | 1740 | struct GNUNET_CRYPTO_PrivateKey *zk) |
1741 | { | 1741 | { |
1742 | const struct GNUNET_IDENTITY_PrivateKey *privkey; | 1742 | const struct GNUNET_CRYPTO_PrivateKey *privkey; |
1743 | struct GNUNET_IDENTITY_PublicKey pubkey; | 1743 | struct GNUNET_CRYPTO_PublicKey pubkey; |
1744 | struct GNUNET_IDENTITY_PublicKey ego_pubkey; | 1744 | struct GNUNET_CRYPTO_PublicKey ego_pubkey; |
1745 | struct EgoEntry *ego_entry; | 1745 | struct EgoEntry *ego_entry; |
1746 | 1746 | ||
1747 | if (GNUNET_OK == GNUNET_IDENTITY_public_key_from_string (str, | 1747 | if (GNUNET_OK == GNUNET_CRYPTO_public_key_from_string (str, |
1748 | &pubkey)) | 1748 | &pubkey)) |
1749 | { | 1749 | { |
1750 | for (ego_entry = ego_head; | 1750 | for (ego_entry = ego_head; |
@@ -1777,7 +1777,7 @@ static void | |||
1777 | process_command_stdin () | 1777 | process_command_stdin () |
1778 | { | 1778 | { |
1779 | char buf[MAX_LINE_LEN]; | 1779 | char buf[MAX_LINE_LEN]; |
1780 | static struct GNUNET_IDENTITY_PrivateKey next_zone_key; | 1780 | static struct GNUNET_CRYPTO_PrivateKey next_zone_key; |
1781 | static char next_name[GNUNET_DNSPARSER_MAX_NAME_LENGTH]; | 1781 | static char next_name[GNUNET_DNSPARSER_MAX_NAME_LENGTH]; |
1782 | static int finished = GNUNET_NO; | 1782 | static int finished = GNUNET_NO; |
1783 | static int have_next_zonekey = GNUNET_NO; | 1783 | static int have_next_zonekey = GNUNET_NO; |
@@ -1900,7 +1900,7 @@ id_connect_cb (void *cls, | |||
1900 | void **ctx, | 1900 | void **ctx, |
1901 | const char *name) | 1901 | const char *name) |
1902 | { | 1902 | { |
1903 | struct GNUNET_IDENTITY_PublicKey pk; | 1903 | struct GNUNET_CRYPTO_PublicKey pk; |
1904 | struct EgoEntry *ego_entry; | 1904 | struct EgoEntry *ego_entry; |
1905 | 1905 | ||
1906 | (void) ctx; | 1906 | (void) ctx; |
diff --git a/src/namestore/gnunet-service-namestore.c b/src/namestore/gnunet-service-namestore.c index f6594c6f9..26de295bf 100644 --- a/src/namestore/gnunet-service-namestore.c +++ b/src/namestore/gnunet-service-namestore.c | |||
@@ -80,7 +80,7 @@ struct ZoneIteration | |||
80 | /** | 80 | /** |
81 | * Key of the zone we are iterating over. | 81 | * Key of the zone we are iterating over. |
82 | */ | 82 | */ |
83 | struct GNUNET_IDENTITY_PrivateKey zone; | 83 | struct GNUNET_CRYPTO_PrivateKey zone; |
84 | 84 | ||
85 | /** | 85 | /** |
86 | * The record set filter | 86 | * The record set filter |
@@ -191,7 +191,7 @@ struct ZoneMonitor | |||
191 | /** | 191 | /** |
192 | * Private key of the zone. | 192 | * Private key of the zone. |
193 | */ | 193 | */ |
194 | struct GNUNET_IDENTITY_PrivateKey zone; | 194 | struct GNUNET_CRYPTO_PrivateKey zone; |
195 | 195 | ||
196 | /** | 196 | /** |
197 | * The record set filter | 197 | * The record set filter |
@@ -302,7 +302,7 @@ struct StoreActivity | |||
302 | /** | 302 | /** |
303 | * The zone private key | 303 | * The zone private key |
304 | */ | 304 | */ |
305 | struct GNUNET_IDENTITY_PrivateKey private_key; | 305 | struct GNUNET_CRYPTO_PrivateKey private_key; |
306 | 306 | ||
307 | /** | 307 | /** |
308 | * Copy of the original record set (as data fields in @e rd will | 308 | * Copy of the original record set (as data fields in @e rd will |
@@ -326,7 +326,7 @@ struct NickCache | |||
326 | /** | 326 | /** |
327 | * Zone the cache entry is for. | 327 | * Zone the cache entry is for. |
328 | */ | 328 | */ |
329 | struct GNUNET_IDENTITY_PrivateKey zone; | 329 | struct GNUNET_CRYPTO_PrivateKey zone; |
330 | 330 | ||
331 | /** | 331 | /** |
332 | * Cached record data. | 332 | * Cached record data. |
@@ -347,7 +347,7 @@ static struct NickCache nick_cache[NC_SIZE]; | |||
347 | /** | 347 | /** |
348 | * Public key of all zeros. | 348 | * Public key of all zeros. |
349 | */ | 349 | */ |
350 | static const struct GNUNET_IDENTITY_PrivateKey zero; | 350 | static const struct GNUNET_CRYPTO_PrivateKey zero; |
351 | 351 | ||
352 | /** | 352 | /** |
353 | * Configuration handle. | 353 | * Configuration handle. |
@@ -453,7 +453,7 @@ free_store_activity (struct StoreActivity *sa) | |||
453 | static void | 453 | static void |
454 | lookup_nick_it (void *cls, | 454 | lookup_nick_it (void *cls, |
455 | uint64_t seq, | 455 | uint64_t seq, |
456 | const struct GNUNET_IDENTITY_PrivateKey *private_key, | 456 | const struct GNUNET_CRYPTO_PrivateKey *private_key, |
457 | const char *label, | 457 | const char *label, |
458 | unsigned int rd_count, | 458 | unsigned int rd_count, |
459 | const struct GNUNET_GNSRECORD_Data *rd) | 459 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -493,7 +493,7 @@ lookup_nick_it (void *cls, | |||
493 | * @param nick nick entry to cache | 493 | * @param nick nick entry to cache |
494 | */ | 494 | */ |
495 | static void | 495 | static void |
496 | cache_nick (const struct GNUNET_IDENTITY_PrivateKey *zone, | 496 | cache_nick (const struct GNUNET_CRYPTO_PrivateKey *zone, |
497 | const struct GNUNET_GNSRECORD_Data *nick) | 497 | const struct GNUNET_GNSRECORD_Data *nick) |
498 | { | 498 | { |
499 | struct NickCache *oldest; | 499 | struct NickCache *oldest; |
@@ -537,9 +537,9 @@ cache_nick (const struct GNUNET_IDENTITY_PrivateKey *zone, | |||
537 | * @return NULL if no NICK record was found | 537 | * @return NULL if no NICK record was found |
538 | */ | 538 | */ |
539 | static struct GNUNET_GNSRECORD_Data * | 539 | static struct GNUNET_GNSRECORD_Data * |
540 | get_nick_record (const struct GNUNET_IDENTITY_PrivateKey *zone) | 540 | get_nick_record (const struct GNUNET_CRYPTO_PrivateKey *zone) |
541 | { | 541 | { |
542 | struct GNUNET_IDENTITY_PublicKey pub; | 542 | struct GNUNET_CRYPTO_PublicKey pub; |
543 | struct GNUNET_GNSRECORD_Data *nick; | 543 | struct GNUNET_GNSRECORD_Data *nick; |
544 | int res; | 544 | int res; |
545 | 545 | ||
@@ -579,7 +579,7 @@ get_nick_record (const struct GNUNET_IDENTITY_PrivateKey *zone) | |||
579 | __LINE__); | 579 | __LINE__); |
580 | if (1 == do_log) | 580 | if (1 == do_log) |
581 | { | 581 | { |
582 | GNUNET_IDENTITY_key_get_public (zone, &pub); | 582 | GNUNET_CRYPTO_key_get_public (zone, &pub); |
583 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG | GNUNET_ERROR_TYPE_BULK, | 583 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG | GNUNET_ERROR_TYPE_BULK, |
584 | "No nick name set for zone `%s'\n", | 584 | "No nick name set for zone `%s'\n", |
585 | GNUNET_GNSRECORD_z2s (&pub)); | 585 | GNUNET_GNSRECORD_z2s (&pub)); |
@@ -695,7 +695,7 @@ static int | |||
695 | send_lookup_response_with_filter (struct NamestoreClient *nc, | 695 | send_lookup_response_with_filter (struct NamestoreClient *nc, |
696 | uint32_t request_id, | 696 | uint32_t request_id, |
697 | const struct | 697 | const struct |
698 | GNUNET_IDENTITY_PrivateKey *zone_key, | 698 | GNUNET_CRYPTO_PrivateKey *zone_key, |
699 | const char *name, | 699 | const char *name, |
700 | unsigned int rd_count, | 700 | unsigned int rd_count, |
701 | const struct GNUNET_GNSRECORD_Data *rd, | 701 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -778,7 +778,7 @@ send_lookup_response_with_filter (struct NamestoreClient *nc, | |||
778 | GNUNET_SERVICE_client_drop (nc->client); | 778 | GNUNET_SERVICE_client_drop (nc->client); |
779 | return 0; | 779 | return 0; |
780 | } | 780 | } |
781 | key_len = GNUNET_IDENTITY_private_key_get_length (zone_key); | 781 | key_len = GNUNET_CRYPTO_private_key_get_length (zone_key); |
782 | env = GNUNET_MQ_msg_extra (zir_msg, | 782 | env = GNUNET_MQ_msg_extra (zir_msg, |
783 | name_len + rd_ser_len + key_len, | 783 | name_len + rd_ser_len + key_len, |
784 | GNUNET_MESSAGE_TYPE_NAMESTORE_RECORD_RESULT); | 784 | GNUNET_MESSAGE_TYPE_NAMESTORE_RECORD_RESULT); |
@@ -787,7 +787,7 @@ send_lookup_response_with_filter (struct NamestoreClient *nc, | |||
787 | zir_msg->rd_count = htons (res_count); | 787 | zir_msg->rd_count = htons (res_count); |
788 | zir_msg->rd_len = htons ((uint16_t) rd_ser_len); | 788 | zir_msg->rd_len = htons ((uint16_t) rd_ser_len); |
789 | zir_msg->key_len = htons (key_len); | 789 | zir_msg->key_len = htons (key_len); |
790 | GNUNET_IDENTITY_write_private_key_to_buffer (zone_key, | 790 | GNUNET_CRYPTO_write_private_key_to_buffer (zone_key, |
791 | &zir_msg[1], | 791 | &zir_msg[1], |
792 | key_len); | 792 | key_len); |
793 | zir_msg->expire = GNUNET_TIME_absolute_hton (block_exp); | 793 | zir_msg->expire = GNUNET_TIME_absolute_hton (block_exp); |
@@ -1194,7 +1194,7 @@ struct RecordLookupContext | |||
1194 | static void | 1194 | static void |
1195 | lookup_it (void *cls, | 1195 | lookup_it (void *cls, |
1196 | uint64_t seq, | 1196 | uint64_t seq, |
1197 | const struct GNUNET_IDENTITY_PrivateKey *private_key, | 1197 | const struct GNUNET_CRYPTO_PrivateKey *private_key, |
1198 | const char *label, | 1198 | const char *label, |
1199 | unsigned int rd_count_nf, | 1199 | unsigned int rd_count_nf, |
1200 | const struct GNUNET_GNSRECORD_Data *rd_nf) | 1200 | const struct GNUNET_GNSRECORD_Data *rd_nf) |
@@ -1337,7 +1337,7 @@ check_record_lookup (void *cls, const struct LabelLookupMessage *ll_msg) | |||
1337 | static void | 1337 | static void |
1338 | handle_record_lookup (void *cls, const struct LabelLookupMessage *ll_msg) | 1338 | handle_record_lookup (void *cls, const struct LabelLookupMessage *ll_msg) |
1339 | { | 1339 | { |
1340 | struct GNUNET_IDENTITY_PrivateKey zone; | 1340 | struct GNUNET_CRYPTO_PrivateKey zone; |
1341 | struct NamestoreClient *nc = cls; | 1341 | struct NamestoreClient *nc = cls; |
1342 | struct GNUNET_MQ_Envelope *env; | 1342 | struct GNUNET_MQ_Envelope *env; |
1343 | struct LabelLookupResponseMessage *llr_msg; | 1343 | struct LabelLookupResponseMessage *llr_msg; |
@@ -1352,7 +1352,7 @@ handle_record_lookup (void *cls, const struct LabelLookupMessage *ll_msg) | |||
1352 | 1352 | ||
1353 | key_len = ntohs (ll_msg->key_len); | 1353 | key_len = ntohs (ll_msg->key_len); |
1354 | if ((GNUNET_SYSERR == | 1354 | if ((GNUNET_SYSERR == |
1355 | GNUNET_IDENTITY_read_private_key_from_buffer (&ll_msg[1], | 1355 | GNUNET_CRYPTO_read_private_key_from_buffer (&ll_msg[1], |
1356 | key_len, | 1356 | key_len, |
1357 | &zone, | 1357 | &zone, |
1358 | &kb_read)) || | 1358 | &kb_read)) || |
@@ -1489,7 +1489,7 @@ static void | |||
1489 | get_existing_rd_exp (void *cls, | 1489 | get_existing_rd_exp (void *cls, |
1490 | uint64_t seq, | 1490 | uint64_t seq, |
1491 | const struct | 1491 | const struct |
1492 | GNUNET_IDENTITY_PrivateKey *private_key, | 1492 | GNUNET_CRYPTO_PrivateKey *private_key, |
1493 | const char *label, | 1493 | const char *label, |
1494 | unsigned int rd_count, | 1494 | unsigned int rd_count, |
1495 | const struct GNUNET_GNSRECORD_Data *rd) | 1495 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1523,7 +1523,7 @@ get_existing_rd_exp (void *cls, | |||
1523 | 1523 | ||
1524 | static enum GNUNET_ErrorCode | 1524 | static enum GNUNET_ErrorCode |
1525 | store_record_set (struct NamestoreClient *nc, | 1525 | store_record_set (struct NamestoreClient *nc, |
1526 | const struct GNUNET_IDENTITY_PrivateKey *private_key, | 1526 | const struct GNUNET_CRYPTO_PrivateKey *private_key, |
1527 | const struct RecordSet *rd_set, | 1527 | const struct RecordSet *rd_set, |
1528 | ssize_t *len) | 1528 | ssize_t *len) |
1529 | { | 1529 | { |
@@ -1727,7 +1727,7 @@ store_record_set (struct NamestoreClient *nc, | |||
1727 | static void | 1727 | static void |
1728 | handle_record_store (void *cls, const struct RecordStoreMessage *rp_msg) | 1728 | handle_record_store (void *cls, const struct RecordStoreMessage *rp_msg) |
1729 | { | 1729 | { |
1730 | struct GNUNET_IDENTITY_PrivateKey zone; | 1730 | struct GNUNET_CRYPTO_PrivateKey zone; |
1731 | struct NamestoreClient *nc = cls; | 1731 | struct NamestoreClient *nc = cls; |
1732 | uint32_t rid; | 1732 | uint32_t rid; |
1733 | uint16_t rd_set_count; | 1733 | uint16_t rd_set_count; |
@@ -1747,7 +1747,7 @@ handle_record_store (void *cls, const struct RecordStoreMessage *rp_msg) | |||
1747 | rs_off = sizeof (*rp_msg) + key_len; | 1747 | rs_off = sizeof (*rp_msg) + key_len; |
1748 | rs_len = rp_msg_len - rs_off; | 1748 | rs_len = rp_msg_len - rs_off; |
1749 | if ((GNUNET_SYSERR == | 1749 | if ((GNUNET_SYSERR == |
1750 | GNUNET_IDENTITY_read_private_key_from_buffer (&rp_msg[1], | 1750 | GNUNET_CRYPTO_read_private_key_from_buffer (&rp_msg[1], |
1751 | key_len, | 1751 | key_len, |
1752 | &zone, | 1752 | &zone, |
1753 | &kb_read)) || | 1753 | &kb_read)) || |
@@ -1949,7 +1949,7 @@ struct ZoneToNameCtx | |||
1949 | static void | 1949 | static void |
1950 | handle_zone_to_name_it (void *cls, | 1950 | handle_zone_to_name_it (void *cls, |
1951 | uint64_t seq, | 1951 | uint64_t seq, |
1952 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, | 1952 | const struct GNUNET_CRYPTO_PrivateKey *zone_key, |
1953 | const char *name, | 1953 | const char *name, |
1954 | unsigned int rd_count, | 1954 | unsigned int rd_count, |
1955 | const struct GNUNET_GNSRECORD_Data *rd) | 1955 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1977,7 +1977,7 @@ handle_zone_to_name_it (void *cls, | |||
1977 | ztn_ctx->ec = htonl (GNUNET_EC_NAMESTORE_UNKNOWN); | 1977 | ztn_ctx->ec = htonl (GNUNET_EC_NAMESTORE_UNKNOWN); |
1978 | return; | 1978 | return; |
1979 | } | 1979 | } |
1980 | key_len = GNUNET_IDENTITY_private_key_get_length (zone_key); | 1980 | key_len = GNUNET_CRYPTO_private_key_get_length (zone_key); |
1981 | msg_size = sizeof(struct ZoneToNameResponseMessage) | 1981 | msg_size = sizeof(struct ZoneToNameResponseMessage) |
1982 | + name_len + rd_ser_len + key_len; | 1982 | + name_len + rd_ser_len + key_len; |
1983 | if (msg_size >= GNUNET_MAX_MESSAGE_SIZE) | 1983 | if (msg_size >= GNUNET_MAX_MESSAGE_SIZE) |
@@ -1997,7 +1997,7 @@ handle_zone_to_name_it (void *cls, | |||
1997 | ztnr_msg->rd_count = htons (rd_count); | 1997 | ztnr_msg->rd_count = htons (rd_count); |
1998 | ztnr_msg->name_len = htons (name_len); | 1998 | ztnr_msg->name_len = htons (name_len); |
1999 | ztnr_msg->key_len = htons (key_len); | 1999 | ztnr_msg->key_len = htons (key_len); |
2000 | GNUNET_IDENTITY_write_private_key_to_buffer (zone_key, | 2000 | GNUNET_CRYPTO_write_private_key_to_buffer (zone_key, |
2001 | &ztnr_msg[1], | 2001 | &ztnr_msg[1], |
2002 | key_len); | 2002 | key_len); |
2003 | name_tmp = (char *) &ztnr_msg[1] + key_len; | 2003 | name_tmp = (char *) &ztnr_msg[1] + key_len; |
@@ -2027,8 +2027,8 @@ check_zone_to_name (void *cls, | |||
2027 | static void | 2027 | static void |
2028 | handle_zone_to_name (void *cls, const struct ZoneToNameMessage *ztn_msg) | 2028 | handle_zone_to_name (void *cls, const struct ZoneToNameMessage *ztn_msg) |
2029 | { | 2029 | { |
2030 | struct GNUNET_IDENTITY_PrivateKey zone; | 2030 | struct GNUNET_CRYPTO_PrivateKey zone; |
2031 | struct GNUNET_IDENTITY_PublicKey value_zone; | 2031 | struct GNUNET_CRYPTO_PublicKey value_zone; |
2032 | struct NamestoreClient *nc = cls; | 2032 | struct NamestoreClient *nc = cls; |
2033 | struct ZoneToNameCtx ztn_ctx; | 2033 | struct ZoneToNameCtx ztn_ctx; |
2034 | struct GNUNET_MQ_Envelope *env; | 2034 | struct GNUNET_MQ_Envelope *env; |
@@ -2043,7 +2043,7 @@ handle_zone_to_name (void *cls, const struct ZoneToNameMessage *ztn_msg) | |||
2043 | ztn_ctx.ec = GNUNET_EC_NAMESTORE_ZONE_NOT_FOUND; | 2043 | ztn_ctx.ec = GNUNET_EC_NAMESTORE_ZONE_NOT_FOUND; |
2044 | key_len = ntohs (ztn_msg->key_len); | 2044 | key_len = ntohs (ztn_msg->key_len); |
2045 | if ((GNUNET_SYSERR == | 2045 | if ((GNUNET_SYSERR == |
2046 | GNUNET_IDENTITY_read_private_key_from_buffer (&ztn_msg[1], | 2046 | GNUNET_CRYPTO_read_private_key_from_buffer (&ztn_msg[1], |
2047 | key_len, | 2047 | key_len, |
2048 | &zone, | 2048 | &zone, |
2049 | &kb_read)) || | 2049 | &kb_read)) || |
@@ -2057,7 +2057,7 @@ handle_zone_to_name (void *cls, const struct ZoneToNameMessage *ztn_msg) | |||
2057 | } | 2057 | } |
2058 | pkey_len = ntohs (ztn_msg->pkey_len); | 2058 | pkey_len = ntohs (ztn_msg->pkey_len); |
2059 | if ((GNUNET_SYSERR == | 2059 | if ((GNUNET_SYSERR == |
2060 | GNUNET_IDENTITY_read_public_key_from_buffer ((char*) &ztn_msg[1] | 2060 | GNUNET_CRYPTO_read_public_key_from_buffer ((char*) &ztn_msg[1] |
2061 | + key_len, | 2061 | + key_len, |
2062 | pkey_len, | 2062 | pkey_len, |
2063 | &value_zone, | 2063 | &value_zone, |
@@ -2133,7 +2133,7 @@ struct ZoneIterationProcResult | |||
2133 | static void | 2133 | static void |
2134 | zone_iterate_proc (void *cls, | 2134 | zone_iterate_proc (void *cls, |
2135 | uint64_t seq, | 2135 | uint64_t seq, |
2136 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, | 2136 | const struct GNUNET_CRYPTO_PrivateKey *zone_key, |
2137 | const char *name, | 2137 | const char *name, |
2138 | unsigned int rd_count, | 2138 | unsigned int rd_count, |
2139 | const struct GNUNET_GNSRECORD_Data *rd) | 2139 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -2254,7 +2254,7 @@ static void | |||
2254 | handle_iteration_start (void *cls, | 2254 | handle_iteration_start (void *cls, |
2255 | const struct ZoneIterationStartMessage *zis_msg) | 2255 | const struct ZoneIterationStartMessage *zis_msg) |
2256 | { | 2256 | { |
2257 | struct GNUNET_IDENTITY_PrivateKey zone; | 2257 | struct GNUNET_CRYPTO_PrivateKey zone; |
2258 | struct NamestoreClient *nc = cls; | 2258 | struct NamestoreClient *nc = cls; |
2259 | struct ZoneIteration *zi; | 2259 | struct ZoneIteration *zi; |
2260 | size_t key_len; | 2260 | size_t key_len; |
@@ -2267,7 +2267,7 @@ handle_iteration_start (void *cls, | |||
2267 | if (0 < key_len) | 2267 | if (0 < key_len) |
2268 | { | 2268 | { |
2269 | if ((GNUNET_SYSERR == | 2269 | if ((GNUNET_SYSERR == |
2270 | GNUNET_IDENTITY_read_private_key_from_buffer (&zis_msg[1], | 2270 | GNUNET_CRYPTO_read_private_key_from_buffer (&zis_msg[1], |
2271 | key_len, | 2271 | key_len, |
2272 | &zone, | 2272 | &zone, |
2273 | &kb_read)) || | 2273 | &kb_read)) || |
@@ -2443,7 +2443,7 @@ monitor_iteration_next (void *cls); | |||
2443 | static void | 2443 | static void |
2444 | monitor_iterate_cb (void *cls, | 2444 | monitor_iterate_cb (void *cls, |
2445 | uint64_t seq, | 2445 | uint64_t seq, |
2446 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, | 2446 | const struct GNUNET_CRYPTO_PrivateKey *zone_key, |
2447 | const char *name, | 2447 | const char *name, |
2448 | unsigned int rd_count, | 2448 | unsigned int rd_count, |
2449 | const struct GNUNET_GNSRECORD_Data *rd) | 2449 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -2505,7 +2505,7 @@ static void | |||
2505 | handle_monitor_start (void *cls, const struct | 2505 | handle_monitor_start (void *cls, const struct |
2506 | ZoneMonitorStartMessage *zis_msg) | 2506 | ZoneMonitorStartMessage *zis_msg) |
2507 | { | 2507 | { |
2508 | struct GNUNET_IDENTITY_PrivateKey zone; | 2508 | struct GNUNET_CRYPTO_PrivateKey zone; |
2509 | struct NamestoreClient *nc = cls; | 2509 | struct NamestoreClient *nc = cls; |
2510 | struct ZoneMonitor *zm; | 2510 | struct ZoneMonitor *zm; |
2511 | size_t key_len; | 2511 | size_t key_len; |
@@ -2519,7 +2519,7 @@ handle_monitor_start (void *cls, const struct | |||
2519 | if (0 < key_len) | 2519 | if (0 < key_len) |
2520 | { | 2520 | { |
2521 | if ((GNUNET_SYSERR == | 2521 | if ((GNUNET_SYSERR == |
2522 | GNUNET_IDENTITY_read_private_key_from_buffer (&zis_msg[1], | 2522 | GNUNET_CRYPTO_read_private_key_from_buffer (&zis_msg[1], |
2523 | key_len, | 2523 | key_len, |
2524 | &zone, | 2524 | &zone, |
2525 | &kb_read)) || | 2525 | &kb_read)) || |
diff --git a/src/namestore/gnunet-zoneimport.c b/src/namestore/gnunet-zoneimport.c index 485df4924..c7e0cf65f 100644 --- a/src/namestore/gnunet-zoneimport.c +++ b/src/namestore/gnunet-zoneimport.c | |||
@@ -94,7 +94,7 @@ struct Zone | |||
94 | /** | 94 | /** |
95 | * Private key of the zone. | 95 | * Private key of the zone. |
96 | */ | 96 | */ |
97 | struct GNUNET_IDENTITY_PrivateKey key; | 97 | struct GNUNET_CRYPTO_PrivateKey key; |
98 | }; | 98 | }; |
99 | 99 | ||
100 | 100 | ||
@@ -1393,7 +1393,7 @@ ns_lookup_error_cb (void *cls) | |||
1393 | */ | 1393 | */ |
1394 | static void | 1394 | static void |
1395 | ns_lookup_result_cb (void *cls, | 1395 | ns_lookup_result_cb (void *cls, |
1396 | const struct GNUNET_IDENTITY_PrivateKey *key, | 1396 | const struct GNUNET_CRYPTO_PrivateKey *key, |
1397 | const char *label, | 1397 | const char *label, |
1398 | unsigned int rd_count, | 1398 | unsigned int rd_count, |
1399 | const struct GNUNET_GNSRECORD_Data *rd) | 1399 | const struct GNUNET_GNSRECORD_Data *rd) |
diff --git a/src/namestore/namestore_api.c b/src/namestore/namestore_api.c index 2c5efb745..7a4438e30 100644 --- a/src/namestore/namestore_api.c +++ b/src/namestore/namestore_api.c | |||
@@ -183,7 +183,7 @@ struct GNUNET_NAMESTORE_ZoneIterator | |||
183 | /** | 183 | /** |
184 | * Private key of the zone. | 184 | * Private key of the zone. |
185 | */ | 185 | */ |
186 | struct GNUNET_IDENTITY_PrivateKey zone; | 186 | struct GNUNET_CRYPTO_PrivateKey zone; |
187 | 187 | ||
188 | /** | 188 | /** |
189 | * The operation id this zone iteration operation has | 189 | * The operation id this zone iteration operation has |
@@ -448,7 +448,7 @@ handle_lookup_result (void *cls, const struct LabelLookupResponseMessage *msg) | |||
448 | { | 448 | { |
449 | struct GNUNET_NAMESTORE_Handle *h = cls; | 449 | struct GNUNET_NAMESTORE_Handle *h = cls; |
450 | struct GNUNET_NAMESTORE_QueueEntry *qe; | 450 | struct GNUNET_NAMESTORE_QueueEntry *qe; |
451 | struct GNUNET_IDENTITY_PrivateKey private_key; | 451 | struct GNUNET_CRYPTO_PrivateKey private_key; |
452 | const char *name; | 452 | const char *name; |
453 | const char *rd_tmp; | 453 | const char *rd_tmp; |
454 | size_t name_len; | 454 | size_t name_len; |
@@ -468,7 +468,7 @@ handle_lookup_result (void *cls, const struct LabelLookupResponseMessage *msg) | |||
468 | name_len = ntohs (msg->name_len); | 468 | name_len = ntohs (msg->name_len); |
469 | key_len = ntohs (msg->key_len); | 469 | key_len = ntohs (msg->key_len); |
470 | GNUNET_assert (GNUNET_SYSERR != | 470 | GNUNET_assert (GNUNET_SYSERR != |
471 | GNUNET_IDENTITY_read_private_key_from_buffer (&msg[1], | 471 | GNUNET_CRYPTO_read_private_key_from_buffer (&msg[1], |
472 | key_len, | 472 | key_len, |
473 | &private_key, | 473 | &private_key, |
474 | &kbytes_read)); | 474 | &kbytes_read)); |
@@ -566,7 +566,7 @@ handle_record_result (void *cls, const struct RecordResultMessage *msg) | |||
566 | struct GNUNET_NAMESTORE_Handle *h = cls; | 566 | struct GNUNET_NAMESTORE_Handle *h = cls; |
567 | struct GNUNET_NAMESTORE_QueueEntry *qe; | 567 | struct GNUNET_NAMESTORE_QueueEntry *qe; |
568 | struct GNUNET_NAMESTORE_ZoneIterator *ze; | 568 | struct GNUNET_NAMESTORE_ZoneIterator *ze; |
569 | struct GNUNET_IDENTITY_PrivateKey private_key; | 569 | struct GNUNET_CRYPTO_PrivateKey private_key; |
570 | const char *name; | 570 | const char *name; |
571 | const char *rd_tmp; | 571 | const char *rd_tmp; |
572 | size_t name_len; | 572 | size_t name_len; |
@@ -592,7 +592,7 @@ handle_record_result (void *cls, const struct RecordResultMessage *msg) | |||
592 | } | 592 | } |
593 | name = (const char *) &msg[1] + key_len; | 593 | name = (const char *) &msg[1] + key_len; |
594 | GNUNET_assert (GNUNET_SYSERR != | 594 | GNUNET_assert (GNUNET_SYSERR != |
595 | GNUNET_IDENTITY_read_private_key_from_buffer (&msg[1], | 595 | GNUNET_CRYPTO_read_private_key_from_buffer (&msg[1], |
596 | key_len, | 596 | key_len, |
597 | &private_key, | 597 | &private_key, |
598 | &kbytes_read)); | 598 | &kbytes_read)); |
@@ -747,7 +747,7 @@ handle_zone_to_name_response (void *cls, | |||
747 | { | 747 | { |
748 | struct GNUNET_NAMESTORE_Handle *h = cls; | 748 | struct GNUNET_NAMESTORE_Handle *h = cls; |
749 | struct GNUNET_NAMESTORE_QueueEntry *qe; | 749 | struct GNUNET_NAMESTORE_QueueEntry *qe; |
750 | struct GNUNET_IDENTITY_PrivateKey zone; | 750 | struct GNUNET_CRYPTO_PrivateKey zone; |
751 | enum GNUNET_ErrorCode res; | 751 | enum GNUNET_ErrorCode res; |
752 | size_t name_len; | 752 | size_t name_len; |
753 | size_t rd_ser_len; | 753 | size_t rd_ser_len; |
@@ -768,7 +768,7 @@ handle_zone_to_name_response (void *cls, | |||
768 | res = ntohl (msg->ec); | 768 | res = ntohl (msg->ec); |
769 | key_len = ntohs (msg->key_len); | 769 | key_len = ntohs (msg->key_len); |
770 | GNUNET_assert (GNUNET_SYSERR != | 770 | GNUNET_assert (GNUNET_SYSERR != |
771 | GNUNET_IDENTITY_read_private_key_from_buffer (&msg[1], | 771 | GNUNET_CRYPTO_read_private_key_from_buffer (&msg[1], |
772 | key_len, | 772 | key_len, |
773 | &zone, | 773 | &zone, |
774 | &kbytes_read)); | 774 | &kbytes_read)); |
@@ -1050,7 +1050,7 @@ warn_delay (void *cls) | |||
1050 | struct GNUNET_NAMESTORE_QueueEntry * | 1050 | struct GNUNET_NAMESTORE_QueueEntry * |
1051 | GNUNET_NAMESTORE_records_store ( | 1051 | GNUNET_NAMESTORE_records_store ( |
1052 | struct GNUNET_NAMESTORE_Handle *h, | 1052 | struct GNUNET_NAMESTORE_Handle *h, |
1053 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 1053 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
1054 | const char *label, | 1054 | const char *label, |
1055 | unsigned int rd_count, | 1055 | unsigned int rd_count, |
1056 | const struct GNUNET_GNSRECORD_Data *rd, | 1056 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -1069,7 +1069,7 @@ GNUNET_NAMESTORE_records_store ( | |||
1069 | struct GNUNET_NAMESTORE_QueueEntry * | 1069 | struct GNUNET_NAMESTORE_QueueEntry * |
1070 | GNUNET_NAMESTORE_records_store2 ( | 1070 | GNUNET_NAMESTORE_records_store2 ( |
1071 | struct GNUNET_NAMESTORE_Handle *h, | 1071 | struct GNUNET_NAMESTORE_Handle *h, |
1072 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 1072 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
1073 | unsigned int rd_set_count, | 1073 | unsigned int rd_set_count, |
1074 | const struct GNUNET_NAMESTORE_RecordInfo *record_info, | 1074 | const struct GNUNET_NAMESTORE_RecordInfo *record_info, |
1075 | unsigned int *rds_sent, | 1075 | unsigned int *rds_sent, |
@@ -1093,7 +1093,7 @@ GNUNET_NAMESTORE_records_store2 ( | |||
1093 | size_t rd_set_len = 0; | 1093 | size_t rd_set_len = 0; |
1094 | size_t key_len = 0; | 1094 | size_t key_len = 0; |
1095 | size_t max_len; | 1095 | size_t max_len; |
1096 | key_len = GNUNET_IDENTITY_private_key_get_length (pkey); | 1096 | key_len = GNUNET_CRYPTO_private_key_get_length (pkey); |
1097 | max_len = UINT16_MAX - key_len - sizeof (struct RecordStoreMessage); | 1097 | max_len = UINT16_MAX - key_len - sizeof (struct RecordStoreMessage); |
1098 | 1098 | ||
1099 | *rds_sent = 0; | 1099 | *rds_sent = 0; |
@@ -1146,7 +1146,7 @@ GNUNET_NAMESTORE_records_store2 ( | |||
1146 | msg->gns_header.r_id = htonl (rid); | 1146 | msg->gns_header.r_id = htonl (rid); |
1147 | msg->key_len = htons (key_len); | 1147 | msg->key_len = htons (key_len); |
1148 | msg->rd_set_count = htons ((uint16_t) (*rds_sent)); | 1148 | msg->rd_set_count = htons ((uint16_t) (*rds_sent)); |
1149 | GNUNET_IDENTITY_write_private_key_to_buffer (pkey, | 1149 | GNUNET_CRYPTO_write_private_key_to_buffer (pkey, |
1150 | &msg[1], | 1150 | &msg[1], |
1151 | key_len); | 1151 | key_len); |
1152 | rd_set = (struct RecordSet*) (((char*) &msg[1]) + key_len); | 1152 | rd_set = (struct RecordSet*) (((char*) &msg[1]) + key_len); |
@@ -1195,7 +1195,7 @@ GNUNET_NAMESTORE_records_store2 ( | |||
1195 | static struct GNUNET_NAMESTORE_QueueEntry * | 1195 | static struct GNUNET_NAMESTORE_QueueEntry * |
1196 | records_lookup ( | 1196 | records_lookup ( |
1197 | struct GNUNET_NAMESTORE_Handle *h, | 1197 | struct GNUNET_NAMESTORE_Handle *h, |
1198 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 1198 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
1199 | const char *label, | 1199 | const char *label, |
1200 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1200 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1201 | void *error_cb_cls, | 1201 | void *error_cb_cls, |
@@ -1225,12 +1225,12 @@ records_lookup ( | |||
1225 | qe->op_id = get_op_id (h); | 1225 | qe->op_id = get_op_id (h); |
1226 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, qe); | 1226 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, qe); |
1227 | 1227 | ||
1228 | key_len = GNUNET_IDENTITY_private_key_get_length (pkey); | 1228 | key_len = GNUNET_CRYPTO_private_key_get_length (pkey); |
1229 | env = GNUNET_MQ_msg_extra (msg, | 1229 | env = GNUNET_MQ_msg_extra (msg, |
1230 | label_len + key_len, | 1230 | label_len + key_len, |
1231 | GNUNET_MESSAGE_TYPE_NAMESTORE_RECORD_LOOKUP); | 1231 | GNUNET_MESSAGE_TYPE_NAMESTORE_RECORD_LOOKUP); |
1232 | msg->gns_header.r_id = htonl (qe->op_id); | 1232 | msg->gns_header.r_id = htonl (qe->op_id); |
1233 | GNUNET_IDENTITY_write_private_key_to_buffer (pkey, | 1233 | GNUNET_CRYPTO_write_private_key_to_buffer (pkey, |
1234 | &msg[1], | 1234 | &msg[1], |
1235 | key_len); | 1235 | key_len); |
1236 | 1236 | ||
@@ -1249,7 +1249,7 @@ records_lookup ( | |||
1249 | struct GNUNET_NAMESTORE_QueueEntry * | 1249 | struct GNUNET_NAMESTORE_QueueEntry * |
1250 | GNUNET_NAMESTORE_records_lookup ( | 1250 | GNUNET_NAMESTORE_records_lookup ( |
1251 | struct GNUNET_NAMESTORE_Handle *h, | 1251 | struct GNUNET_NAMESTORE_Handle *h, |
1252 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 1252 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
1253 | const char *label, | 1253 | const char *label, |
1254 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1254 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1255 | void *error_cb_cls, | 1255 | void *error_cb_cls, |
@@ -1265,7 +1265,7 @@ GNUNET_NAMESTORE_records_lookup ( | |||
1265 | struct GNUNET_NAMESTORE_QueueEntry * | 1265 | struct GNUNET_NAMESTORE_QueueEntry * |
1266 | GNUNET_NAMESTORE_records_lookup2 ( | 1266 | GNUNET_NAMESTORE_records_lookup2 ( |
1267 | struct GNUNET_NAMESTORE_Handle *h, | 1267 | struct GNUNET_NAMESTORE_Handle *h, |
1268 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 1268 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
1269 | const char *label, | 1269 | const char *label, |
1270 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1270 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1271 | void *error_cb_cls, | 1271 | void *error_cb_cls, |
@@ -1283,7 +1283,7 @@ GNUNET_NAMESTORE_records_lookup2 ( | |||
1283 | struct GNUNET_NAMESTORE_QueueEntry * | 1283 | struct GNUNET_NAMESTORE_QueueEntry * |
1284 | GNUNET_NAMESTORE_records_edit ( | 1284 | GNUNET_NAMESTORE_records_edit ( |
1285 | struct GNUNET_NAMESTORE_Handle *h, | 1285 | struct GNUNET_NAMESTORE_Handle *h, |
1286 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 1286 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
1287 | const char *label, | 1287 | const char *label, |
1288 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1288 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1289 | void *error_cb_cls, | 1289 | void *error_cb_cls, |
@@ -1298,8 +1298,8 @@ GNUNET_NAMESTORE_records_edit ( | |||
1298 | struct GNUNET_NAMESTORE_QueueEntry * | 1298 | struct GNUNET_NAMESTORE_QueueEntry * |
1299 | GNUNET_NAMESTORE_zone_to_name ( | 1299 | GNUNET_NAMESTORE_zone_to_name ( |
1300 | struct GNUNET_NAMESTORE_Handle *h, | 1300 | struct GNUNET_NAMESTORE_Handle *h, |
1301 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 1301 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
1302 | const struct GNUNET_IDENTITY_PublicKey *value_zone, | 1302 | const struct GNUNET_CRYPTO_PublicKey *value_zone, |
1303 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1303 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1304 | void *error_cb_cls, | 1304 | void *error_cb_cls, |
1305 | GNUNET_NAMESTORE_RecordMonitor proc, | 1305 | GNUNET_NAMESTORE_RecordMonitor proc, |
@@ -1322,15 +1322,15 @@ GNUNET_NAMESTORE_zone_to_name ( | |||
1322 | qe->op_id = rid; | 1322 | qe->op_id = rid; |
1323 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, qe); | 1323 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, qe); |
1324 | 1324 | ||
1325 | key_len = GNUNET_IDENTITY_private_key_get_length (zone); | 1325 | key_len = GNUNET_CRYPTO_private_key_get_length (zone); |
1326 | pkey_len = GNUNET_IDENTITY_public_key_get_length (value_zone); | 1326 | pkey_len = GNUNET_CRYPTO_public_key_get_length (value_zone); |
1327 | env = GNUNET_MQ_msg_extra (msg, key_len + pkey_len, | 1327 | env = GNUNET_MQ_msg_extra (msg, key_len + pkey_len, |
1328 | GNUNET_MESSAGE_TYPE_NAMESTORE_ZONE_TO_NAME); | 1328 | GNUNET_MESSAGE_TYPE_NAMESTORE_ZONE_TO_NAME); |
1329 | msg->gns_header.r_id = htonl (rid); | 1329 | msg->gns_header.r_id = htonl (rid); |
1330 | msg->key_len = htons (key_len); | 1330 | msg->key_len = htons (key_len); |
1331 | msg->pkey_len = htons (pkey_len); | 1331 | msg->pkey_len = htons (pkey_len); |
1332 | GNUNET_IDENTITY_write_private_key_to_buffer (zone, &msg[1], key_len); | 1332 | GNUNET_CRYPTO_write_private_key_to_buffer (zone, &msg[1], key_len); |
1333 | GNUNET_IDENTITY_write_public_key_to_buffer (value_zone, | 1333 | GNUNET_CRYPTO_write_public_key_to_buffer (value_zone, |
1334 | (char*) &msg[1] + key_len, | 1334 | (char*) &msg[1] + key_len, |
1335 | pkey_len); | 1335 | pkey_len); |
1336 | if (NULL == h->mq) | 1336 | if (NULL == h->mq) |
@@ -1344,7 +1344,7 @@ GNUNET_NAMESTORE_zone_to_name ( | |||
1344 | struct GNUNET_NAMESTORE_ZoneIterator * | 1344 | struct GNUNET_NAMESTORE_ZoneIterator * |
1345 | GNUNET_NAMESTORE_zone_iteration_start ( | 1345 | GNUNET_NAMESTORE_zone_iteration_start ( |
1346 | struct GNUNET_NAMESTORE_Handle *h, | 1346 | struct GNUNET_NAMESTORE_Handle *h, |
1347 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 1347 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
1348 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1348 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1349 | void *error_cb_cls, | 1349 | void *error_cb_cls, |
1350 | GNUNET_NAMESTORE_RecordMonitor proc, | 1350 | GNUNET_NAMESTORE_RecordMonitor proc, |
@@ -1372,7 +1372,7 @@ GNUNET_NAMESTORE_zone_iteration_start ( | |||
1372 | if (NULL != zone) | 1372 | if (NULL != zone) |
1373 | { | 1373 | { |
1374 | it->zone = *zone; | 1374 | it->zone = *zone; |
1375 | key_len = GNUNET_IDENTITY_private_key_get_length (zone); | 1375 | key_len = GNUNET_CRYPTO_private_key_get_length (zone); |
1376 | } | 1376 | } |
1377 | GNUNET_CONTAINER_DLL_insert_tail (h->z_head, h->z_tail, it); | 1377 | GNUNET_CONTAINER_DLL_insert_tail (h->z_head, h->z_tail, it); |
1378 | env = GNUNET_MQ_msg_extra (msg, | 1378 | env = GNUNET_MQ_msg_extra (msg, |
@@ -1381,7 +1381,7 @@ GNUNET_NAMESTORE_zone_iteration_start ( | |||
1381 | msg->gns_header.r_id = htonl (rid); | 1381 | msg->gns_header.r_id = htonl (rid); |
1382 | msg->key_len = htons (key_len); | 1382 | msg->key_len = htons (key_len); |
1383 | if (NULL != zone) | 1383 | if (NULL != zone) |
1384 | GNUNET_IDENTITY_write_private_key_to_buffer (zone, &msg[1], key_len); | 1384 | GNUNET_CRYPTO_write_private_key_to_buffer (zone, &msg[1], key_len); |
1385 | if (NULL == h->mq) | 1385 | if (NULL == h->mq) |
1386 | it->env = env; | 1386 | it->env = env; |
1387 | else | 1387 | else |
@@ -1392,7 +1392,7 @@ GNUNET_NAMESTORE_zone_iteration_start ( | |||
1392 | struct GNUNET_NAMESTORE_ZoneIterator * | 1392 | struct GNUNET_NAMESTORE_ZoneIterator * |
1393 | GNUNET_NAMESTORE_zone_iteration_start2 ( | 1393 | GNUNET_NAMESTORE_zone_iteration_start2 ( |
1394 | struct GNUNET_NAMESTORE_Handle *h, | 1394 | struct GNUNET_NAMESTORE_Handle *h, |
1395 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 1395 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
1396 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1396 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1397 | void *error_cb_cls, | 1397 | void *error_cb_cls, |
1398 | GNUNET_NAMESTORE_RecordSetMonitor proc, | 1398 | GNUNET_NAMESTORE_RecordSetMonitor proc, |
@@ -1421,7 +1421,7 @@ GNUNET_NAMESTORE_zone_iteration_start2 ( | |||
1421 | if (NULL != zone) | 1421 | if (NULL != zone) |
1422 | { | 1422 | { |
1423 | it->zone = *zone; | 1423 | it->zone = *zone; |
1424 | key_len = GNUNET_IDENTITY_private_key_get_length (zone); | 1424 | key_len = GNUNET_CRYPTO_private_key_get_length (zone); |
1425 | } | 1425 | } |
1426 | GNUNET_CONTAINER_DLL_insert_tail (h->z_head, h->z_tail, it); | 1426 | GNUNET_CONTAINER_DLL_insert_tail (h->z_head, h->z_tail, it); |
1427 | env = GNUNET_MQ_msg_extra (msg, | 1427 | env = GNUNET_MQ_msg_extra (msg, |
@@ -1431,7 +1431,7 @@ GNUNET_NAMESTORE_zone_iteration_start2 ( | |||
1431 | msg->key_len = htons (key_len); | 1431 | msg->key_len = htons (key_len); |
1432 | msg->filter = htons ((uint16_t) filter); | 1432 | msg->filter = htons ((uint16_t) filter); |
1433 | if (NULL != zone) | 1433 | if (NULL != zone) |
1434 | GNUNET_IDENTITY_write_private_key_to_buffer (zone, &msg[1], key_len); | 1434 | GNUNET_CRYPTO_write_private_key_to_buffer (zone, &msg[1], key_len); |
1435 | if (NULL == h->mq) | 1435 | if (NULL == h->mq) |
1436 | it->env = env; | 1436 | it->env = env; |
1437 | else | 1437 | else |
diff --git a/src/namestore/namestore_api_monitor.c b/src/namestore/namestore_api_monitor.c index a99b386d0..ec4ba879b 100644 --- a/src/namestore/namestore_api_monitor.c +++ b/src/namestore/namestore_api_monitor.c | |||
@@ -90,7 +90,7 @@ struct GNUNET_NAMESTORE_ZoneMonitor | |||
90 | /** | 90 | /** |
91 | * Monitored zone. | 91 | * Monitored zone. |
92 | */ | 92 | */ |
93 | struct GNUNET_IDENTITY_PrivateKey zone; | 93 | struct GNUNET_CRYPTO_PrivateKey zone; |
94 | 94 | ||
95 | /** | 95 | /** |
96 | * Do we first iterate over all existing records? | 96 | * Do we first iterate over all existing records? |
@@ -211,7 +211,7 @@ static void | |||
211 | handle_result (void *cls, const struct RecordResultMessage *lrm) | 211 | handle_result (void *cls, const struct RecordResultMessage *lrm) |
212 | { | 212 | { |
213 | struct GNUNET_NAMESTORE_ZoneMonitor *zm = cls; | 213 | struct GNUNET_NAMESTORE_ZoneMonitor *zm = cls; |
214 | struct GNUNET_IDENTITY_PrivateKey private_key; | 214 | struct GNUNET_CRYPTO_PrivateKey private_key; |
215 | size_t name_len; | 215 | size_t name_len; |
216 | size_t rd_len; | 216 | size_t rd_len; |
217 | size_t key_len; | 217 | size_t key_len; |
@@ -226,7 +226,7 @@ handle_result (void *cls, const struct RecordResultMessage *lrm) | |||
226 | name_len = ntohs (lrm->name_len); | 226 | name_len = ntohs (lrm->name_len); |
227 | name_tmp = (const char *) &lrm[1] + key_len; | 227 | name_tmp = (const char *) &lrm[1] + key_len; |
228 | GNUNET_assert (GNUNET_SYSERR != | 228 | GNUNET_assert (GNUNET_SYSERR != |
229 | GNUNET_IDENTITY_read_private_key_from_buffer (&lrm[1], | 229 | GNUNET_CRYPTO_read_private_key_from_buffer (&lrm[1], |
230 | key_len, | 230 | key_len, |
231 | &private_key, | 231 | &private_key, |
232 | &kbytes_read)); | 232 | &kbytes_read)); |
@@ -303,7 +303,7 @@ reconnect (struct GNUNET_NAMESTORE_ZoneMonitor *zm) | |||
303 | GNUNET_MESSAGE_TYPE_NAMESTORE_MONITOR_START); | 303 | GNUNET_MESSAGE_TYPE_NAMESTORE_MONITOR_START); |
304 | sm->iterate_first = htonl (zm->iterate_first); | 304 | sm->iterate_first = htonl (zm->iterate_first); |
305 | if (0 < zm->key_len) | 305 | if (0 < zm->key_len) |
306 | GNUNET_IDENTITY_write_private_key_to_buffer (&zm->zone, | 306 | GNUNET_CRYPTO_write_private_key_to_buffer (&zm->zone, |
307 | &sm[1], | 307 | &sm[1], |
308 | zm->key_len); | 308 | zm->key_len); |
309 | sm->key_len = htons (zm->key_len); | 309 | sm->key_len = htons (zm->key_len); |
@@ -315,7 +315,7 @@ reconnect (struct GNUNET_NAMESTORE_ZoneMonitor *zm) | |||
315 | struct GNUNET_NAMESTORE_ZoneMonitor * | 315 | struct GNUNET_NAMESTORE_ZoneMonitor * |
316 | GNUNET_NAMESTORE_zone_monitor_start ( | 316 | GNUNET_NAMESTORE_zone_monitor_start ( |
317 | const struct GNUNET_CONFIGURATION_Handle *cfg, | 317 | const struct GNUNET_CONFIGURATION_Handle *cfg, |
318 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 318 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
319 | int iterate_first, | 319 | int iterate_first, |
320 | GNUNET_SCHEDULER_TaskCallback error_cb, | 320 | GNUNET_SCHEDULER_TaskCallback error_cb, |
321 | void *error_cb_cls, | 321 | void *error_cb_cls, |
@@ -329,7 +329,7 @@ GNUNET_NAMESTORE_zone_monitor_start ( | |||
329 | zm = GNUNET_new (struct GNUNET_NAMESTORE_ZoneMonitor); | 329 | zm = GNUNET_new (struct GNUNET_NAMESTORE_ZoneMonitor); |
330 | if (NULL != zone) | 330 | if (NULL != zone) |
331 | { | 331 | { |
332 | zm->key_len = GNUNET_IDENTITY_private_key_get_length (zone); | 332 | zm->key_len = GNUNET_CRYPTO_private_key_get_length (zone); |
333 | zm->zone = *zone; | 333 | zm->zone = *zone; |
334 | } | 334 | } |
335 | zm->iterate_first = iterate_first; | 335 | zm->iterate_first = iterate_first; |
@@ -352,7 +352,7 @@ GNUNET_NAMESTORE_zone_monitor_start ( | |||
352 | struct GNUNET_NAMESTORE_ZoneMonitor * | 352 | struct GNUNET_NAMESTORE_ZoneMonitor * |
353 | GNUNET_NAMESTORE_zone_monitor_start2 ( | 353 | GNUNET_NAMESTORE_zone_monitor_start2 ( |
354 | const struct GNUNET_CONFIGURATION_Handle *cfg, | 354 | const struct GNUNET_CONFIGURATION_Handle *cfg, |
355 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 355 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
356 | int iterate_first, | 356 | int iterate_first, |
357 | GNUNET_SCHEDULER_TaskCallback error_cb, | 357 | GNUNET_SCHEDULER_TaskCallback error_cb, |
358 | void *error_cb_cls, | 358 | void *error_cb_cls, |
@@ -367,7 +367,7 @@ GNUNET_NAMESTORE_zone_monitor_start2 ( | |||
367 | zm = GNUNET_new (struct GNUNET_NAMESTORE_ZoneMonitor); | 367 | zm = GNUNET_new (struct GNUNET_NAMESTORE_ZoneMonitor); |
368 | if (NULL != zone) | 368 | if (NULL != zone) |
369 | { | 369 | { |
370 | zm->key_len = GNUNET_IDENTITY_private_key_get_length (zone); | 370 | zm->key_len = GNUNET_CRYPTO_private_key_get_length (zone); |
371 | zm->zone = *zone; | 371 | zm->zone = *zone; |
372 | } | 372 | } |
373 | zm->iterate_first = iterate_first; | 373 | zm->iterate_first = iterate_first; |
diff --git a/src/namestore/perf_namestore_api_import.c b/src/namestore/perf_namestore_api_import.c index b4f17f742..e56fb961c 100644 --- a/src/namestore/perf_namestore_api_import.c +++ b/src/namestore/perf_namestore_api_import.c | |||
@@ -65,7 +65,7 @@ static struct GNUNET_SCHEDULER_Task *timeout_task; | |||
65 | 65 | ||
66 | static struct GNUNET_SCHEDULER_Task *t; | 66 | static struct GNUNET_SCHEDULER_Task *t; |
67 | 67 | ||
68 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 68 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
69 | 69 | ||
70 | static struct GNUNET_NAMESTORE_QueueEntry *qe; | 70 | static struct GNUNET_NAMESTORE_QueueEntry *qe; |
71 | 71 | ||
diff --git a/src/namestore/perf_namestore_api_zone_iteration.c b/src/namestore/perf_namestore_api_zone_iteration.c index bf89d6225..e16748f5b 100644 --- a/src/namestore/perf_namestore_api_zone_iteration.c +++ b/src/namestore/perf_namestore_api_zone_iteration.c | |||
@@ -63,7 +63,7 @@ static struct GNUNET_SCHEDULER_Task *timeout_task; | |||
63 | 63 | ||
64 | static struct GNUNET_SCHEDULER_Task *t; | 64 | static struct GNUNET_SCHEDULER_Task *t; |
65 | 65 | ||
66 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 66 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
67 | 67 | ||
68 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; | 68 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; |
69 | 69 | ||
@@ -187,7 +187,7 @@ fail_cb (void *cls) | |||
187 | 187 | ||
188 | static void | 188 | static void |
189 | zone_proc (void *cls, | 189 | zone_proc (void *cls, |
190 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 190 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
191 | const char *label, | 191 | const char *label, |
192 | unsigned int rd_count, | 192 | unsigned int rd_count, |
193 | const struct GNUNET_GNSRECORD_Data *rd) | 193 | const struct GNUNET_GNSRECORD_Data *rd) |
diff --git a/src/namestore/plugin_namestore_flat.c b/src/namestore/plugin_namestore_flat.c index 3249d524a..8b574d2cf 100644 --- a/src/namestore/plugin_namestore_flat.c +++ b/src/namestore/plugin_namestore_flat.c | |||
@@ -54,7 +54,7 @@ struct FlatFileEntry | |||
54 | /** | 54 | /** |
55 | * Entry zone | 55 | * Entry zone |
56 | */ | 56 | */ |
57 | struct GNUNET_IDENTITY_PrivateKey private_key; | 57 | struct GNUNET_CRYPTO_PrivateKey private_key; |
58 | 58 | ||
59 | /** | 59 | /** |
60 | * Record count. | 60 | * Record count. |
@@ -86,7 +86,7 @@ struct FlatFileEntry | |||
86 | * @param[out] h initialized hash | 86 | * @param[out] h initialized hash |
87 | */ | 87 | */ |
88 | static void | 88 | static void |
89 | hash_pkey_and_label (const struct GNUNET_IDENTITY_PrivateKey *pkey, | 89 | hash_pkey_and_label (const struct GNUNET_CRYPTO_PrivateKey *pkey, |
90 | const char *label, | 90 | const char *label, |
91 | struct GNUNET_HashCode *h) | 91 | struct GNUNET_HashCode *h) |
92 | { | 92 | { |
@@ -95,14 +95,14 @@ hash_pkey_and_label (const struct GNUNET_IDENTITY_PrivateKey *pkey, | |||
95 | size_t key_len; | 95 | size_t key_len; |
96 | 96 | ||
97 | label_len = strlen (label); | 97 | label_len = strlen (label); |
98 | key_len = label_len + sizeof(struct GNUNET_IDENTITY_PrivateKey); | 98 | key_len = label_len + sizeof(struct GNUNET_CRYPTO_PrivateKey); |
99 | key = GNUNET_malloc (key_len); | 99 | key = GNUNET_malloc (key_len); |
100 | GNUNET_memcpy (key, | 100 | GNUNET_memcpy (key, |
101 | label, | 101 | label, |
102 | label_len); | 102 | label_len); |
103 | GNUNET_memcpy (key + label_len, | 103 | GNUNET_memcpy (key + label_len, |
104 | pkey, | 104 | pkey, |
105 | sizeof(struct GNUNET_IDENTITY_PrivateKey)); | 105 | sizeof(struct GNUNET_CRYPTO_PrivateKey)); |
106 | GNUNET_CRYPTO_hash (key, | 106 | GNUNET_CRYPTO_hash (key, |
107 | key_len, | 107 | key_len, |
108 | h); | 108 | h); |
@@ -296,7 +296,7 @@ database_setup (struct Plugin *plugin) | |||
296 | GNUNET_free (record_data); | 296 | GNUNET_free (record_data); |
297 | 297 | ||
298 | { | 298 | { |
299 | struct GNUNET_IDENTITY_PrivateKey *private_key; | 299 | struct GNUNET_CRYPTO_PrivateKey *private_key; |
300 | 300 | ||
301 | GNUNET_STRINGS_base64_decode (zone_private_key, | 301 | GNUNET_STRINGS_base64_decode (zone_private_key, |
302 | strlen (zone_private_key), | 302 | strlen (zone_private_key), |
@@ -345,7 +345,7 @@ store_and_free_entries (void *cls, | |||
345 | 345 | ||
346 | (void) key; | 346 | (void) key; |
347 | GNUNET_STRINGS_base64_encode (&entry->private_key, | 347 | GNUNET_STRINGS_base64_encode (&entry->private_key, |
348 | sizeof(struct GNUNET_IDENTITY_PrivateKey), | 348 | sizeof(struct GNUNET_CRYPTO_PrivateKey), |
349 | &zone_private_key); | 349 | &zone_private_key); |
350 | data_size = GNUNET_GNSRECORD_records_get_size (entry->record_count, | 350 | data_size = GNUNET_GNSRECORD_records_get_size (entry->record_count, |
351 | entry->record_data); | 351 | entry->record_data); |
@@ -452,7 +452,7 @@ database_shutdown (struct Plugin *plugin) | |||
452 | static int | 452 | static int |
453 | namestore_flat_store_records (void *cls, | 453 | namestore_flat_store_records (void *cls, |
454 | const struct | 454 | const struct |
455 | GNUNET_IDENTITY_PrivateKey *zone_key, | 455 | GNUNET_CRYPTO_PrivateKey *zone_key, |
456 | const char *label, | 456 | const char *label, |
457 | unsigned int rd_count, | 457 | unsigned int rd_count, |
458 | const struct GNUNET_GNSRECORD_Data *rd) | 458 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -482,7 +482,7 @@ namestore_flat_store_records (void *cls, | |||
482 | strlen (label)); | 482 | strlen (label)); |
483 | GNUNET_memcpy (&entry->private_key, | 483 | GNUNET_memcpy (&entry->private_key, |
484 | zone_key, | 484 | zone_key, |
485 | sizeof(struct GNUNET_IDENTITY_PrivateKey)); | 485 | sizeof(struct GNUNET_CRYPTO_PrivateKey)); |
486 | entry->rvalue = rvalue; | 486 | entry->rvalue = rvalue; |
487 | entry->record_count = rd_count; | 487 | entry->record_count = rd_count; |
488 | entry->record_data = GNUNET_new_array (rd_count, | 488 | entry->record_data = GNUNET_new_array (rd_count, |
@@ -517,7 +517,7 @@ namestore_flat_store_records (void *cls, | |||
517 | */ | 517 | */ |
518 | static int | 518 | static int |
519 | namestore_flat_lookup_records (void *cls, | 519 | namestore_flat_lookup_records (void *cls, |
520 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 520 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
521 | const char *label, | 521 | const char *label, |
522 | GNUNET_NAMESTORE_RecordIterator iter, | 522 | GNUNET_NAMESTORE_RecordIterator iter, |
523 | void *iter_cls) | 523 | void *iter_cls) |
@@ -574,7 +574,7 @@ struct IterateContext | |||
574 | /** | 574 | /** |
575 | * Target zone. | 575 | * Target zone. |
576 | */ | 576 | */ |
577 | const struct GNUNET_IDENTITY_PrivateKey *zone; | 577 | const struct GNUNET_CRYPTO_PrivateKey *zone; |
578 | 578 | ||
579 | /** | 579 | /** |
580 | * Function to call on each record. | 580 | * Function to call on each record. |
@@ -647,7 +647,7 @@ iterate_zones (void *cls, | |||
647 | static int | 647 | static int |
648 | namestore_flat_iterate_records (void *cls, | 648 | namestore_flat_iterate_records (void *cls, |
649 | const struct | 649 | const struct |
650 | GNUNET_IDENTITY_PrivateKey *zone, | 650 | GNUNET_CRYPTO_PrivateKey *zone, |
651 | uint64_t serial, | 651 | uint64_t serial, |
652 | uint64_t limit, | 652 | uint64_t limit, |
653 | GNUNET_NAMESTORE_RecordIterator iter, | 653 | GNUNET_NAMESTORE_RecordIterator iter, |
@@ -674,8 +674,8 @@ namestore_flat_iterate_records (void *cls, | |||
674 | */ | 674 | */ |
675 | struct ZoneToNameContext | 675 | struct ZoneToNameContext |
676 | { | 676 | { |
677 | const struct GNUNET_IDENTITY_PrivateKey *zone; | 677 | const struct GNUNET_CRYPTO_PrivateKey *zone; |
678 | const struct GNUNET_IDENTITY_PublicKey *value_zone; | 678 | const struct GNUNET_CRYPTO_PublicKey *value_zone; |
679 | GNUNET_NAMESTORE_RecordIterator iter; | 679 | GNUNET_NAMESTORE_RecordIterator iter; |
680 | void *iter_cls; | 680 | void *iter_cls; |
681 | 681 | ||
@@ -733,9 +733,9 @@ zone_to_name (void *cls, | |||
733 | */ | 733 | */ |
734 | static int | 734 | static int |
735 | namestore_flat_zone_to_name (void *cls, | 735 | namestore_flat_zone_to_name (void *cls, |
736 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 736 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
737 | const struct | 737 | const struct |
738 | GNUNET_IDENTITY_PublicKey *value_zone, | 738 | GNUNET_CRYPTO_PublicKey *value_zone, |
739 | GNUNET_NAMESTORE_RecordIterator iter, | 739 | GNUNET_NAMESTORE_RecordIterator iter, |
740 | void *iter_cls) | 740 | void *iter_cls) |
741 | { | 741 | { |
diff --git a/src/namestore/plugin_namestore_postgres.c b/src/namestore/plugin_namestore_postgres.c index de819f196..c6debf3a9 100644 --- a/src/namestore/plugin_namestore_postgres.c +++ b/src/namestore/plugin_namestore_postgres.c | |||
@@ -224,13 +224,13 @@ database_connect (struct Plugin *plugin) | |||
224 | static enum GNUNET_GenericReturnValue | 224 | static enum GNUNET_GenericReturnValue |
225 | namestore_postgres_store_records (void *cls, | 225 | namestore_postgres_store_records (void *cls, |
226 | const struct | 226 | const struct |
227 | GNUNET_IDENTITY_PrivateKey *zone_key, | 227 | GNUNET_CRYPTO_PrivateKey *zone_key, |
228 | const char *label, | 228 | const char *label, |
229 | unsigned int rd_count, | 229 | unsigned int rd_count, |
230 | const struct GNUNET_GNSRECORD_Data *rd) | 230 | const struct GNUNET_GNSRECORD_Data *rd) |
231 | { | 231 | { |
232 | struct Plugin *plugin = cls; | 232 | struct Plugin *plugin = cls; |
233 | struct GNUNET_IDENTITY_PublicKey pkey; | 233 | struct GNUNET_CRYPTO_PublicKey pkey; |
234 | uint64_t rvalue; | 234 | uint64_t rvalue; |
235 | uint32_t rd_count32 = (uint32_t) rd_count; | 235 | uint32_t rd_count32 = (uint32_t) rd_count; |
236 | ssize_t data_size; | 236 | ssize_t data_size; |
@@ -342,7 +342,7 @@ struct ParserContext | |||
342 | /** | 342 | /** |
343 | * Zone key, NULL if part of record. | 343 | * Zone key, NULL if part of record. |
344 | */ | 344 | */ |
345 | const struct GNUNET_IDENTITY_PrivateKey *zone_key; | 345 | const struct GNUNET_CRYPTO_PrivateKey *zone_key; |
346 | 346 | ||
347 | /** | 347 | /** |
348 | * Number of results still to return (counted down by | 348 | * Number of results still to return (counted down by |
@@ -378,7 +378,7 @@ parse_result_call_iterator (void *cls, | |||
378 | size_t data_size; | 378 | size_t data_size; |
379 | uint32_t record_count; | 379 | uint32_t record_count; |
380 | char *label; | 380 | char *label; |
381 | struct GNUNET_IDENTITY_PrivateKey zk; | 381 | struct GNUNET_CRYPTO_PrivateKey zk; |
382 | struct GNUNET_PQ_ResultSpec rs_with_zone[] = { | 382 | struct GNUNET_PQ_ResultSpec rs_with_zone[] = { |
383 | GNUNET_PQ_result_spec_uint64 ("seq", &serial), | 383 | GNUNET_PQ_result_spec_uint64 ("seq", &serial), |
384 | GNUNET_PQ_result_spec_uint32 ("record_count", &record_count), | 384 | GNUNET_PQ_result_spec_uint32 ("record_count", &record_count), |
@@ -456,7 +456,7 @@ parse_result_call_iterator (void *cls, | |||
456 | static enum GNUNET_GenericReturnValue | 456 | static enum GNUNET_GenericReturnValue |
457 | lookup_records (void *cls, | 457 | lookup_records (void *cls, |
458 | const struct | 458 | const struct |
459 | GNUNET_IDENTITY_PrivateKey *zone, | 459 | GNUNET_CRYPTO_PrivateKey *zone, |
460 | const char *label, | 460 | const char *label, |
461 | GNUNET_NAMESTORE_RecordIterator iter, | 461 | GNUNET_NAMESTORE_RecordIterator iter, |
462 | void *iter_cls, | 462 | void *iter_cls, |
@@ -506,7 +506,7 @@ lookup_records (void *cls, | |||
506 | static enum GNUNET_GenericReturnValue | 506 | static enum GNUNET_GenericReturnValue |
507 | namestore_postgres_lookup_records (void *cls, | 507 | namestore_postgres_lookup_records (void *cls, |
508 | const struct | 508 | const struct |
509 | GNUNET_IDENTITY_PrivateKey *zone, | 509 | GNUNET_CRYPTO_PrivateKey *zone, |
510 | const char *label, | 510 | const char *label, |
511 | GNUNET_NAMESTORE_RecordIterator iter, | 511 | GNUNET_NAMESTORE_RecordIterator iter, |
512 | void *iter_cls) | 512 | void *iter_cls) |
@@ -528,7 +528,7 @@ namestore_postgres_lookup_records (void *cls, | |||
528 | static int | 528 | static int |
529 | namestore_postgres_edit_records (void *cls, | 529 | namestore_postgres_edit_records (void *cls, |
530 | const struct | 530 | const struct |
531 | GNUNET_IDENTITY_PrivateKey *zone, | 531 | GNUNET_CRYPTO_PrivateKey *zone, |
532 | const char *label, | 532 | const char *label, |
533 | GNUNET_NAMESTORE_RecordIterator iter, | 533 | GNUNET_NAMESTORE_RecordIterator iter, |
534 | void *iter_cls) | 534 | void *iter_cls) |
@@ -552,7 +552,7 @@ namestore_postgres_edit_records (void *cls, | |||
552 | static enum GNUNET_GenericReturnValue | 552 | static enum GNUNET_GenericReturnValue |
553 | namestore_postgres_iterate_records (void *cls, | 553 | namestore_postgres_iterate_records (void *cls, |
554 | const struct | 554 | const struct |
555 | GNUNET_IDENTITY_PrivateKey *zone, | 555 | GNUNET_CRYPTO_PrivateKey *zone, |
556 | uint64_t serial, | 556 | uint64_t serial, |
557 | uint64_t limit, | 557 | uint64_t limit, |
558 | GNUNET_NAMESTORE_RecordIterator iter, | 558 | GNUNET_NAMESTORE_RecordIterator iter, |
@@ -620,9 +620,9 @@ namestore_postgres_iterate_records (void *cls, | |||
620 | static enum GNUNET_GenericReturnValue | 620 | static enum GNUNET_GenericReturnValue |
621 | namestore_postgres_zone_to_name (void *cls, | 621 | namestore_postgres_zone_to_name (void *cls, |
622 | const struct | 622 | const struct |
623 | GNUNET_IDENTITY_PrivateKey *zone, | 623 | GNUNET_CRYPTO_PrivateKey *zone, |
624 | const struct | 624 | const struct |
625 | GNUNET_IDENTITY_PublicKey *value_zone, | 625 | GNUNET_CRYPTO_PublicKey *value_zone, |
626 | GNUNET_NAMESTORE_RecordIterator iter, | 626 | GNUNET_NAMESTORE_RecordIterator iter, |
627 | void *iter_cls) | 627 | void *iter_cls) |
628 | { | 628 | { |
diff --git a/src/namestore/plugin_namestore_sqlite.c b/src/namestore/plugin_namestore_sqlite.c index 15a6586b5..d66271ffa 100644 --- a/src/namestore/plugin_namestore_sqlite.c +++ b/src/namestore/plugin_namestore_sqlite.c | |||
@@ -268,14 +268,14 @@ database_shutdown (struct Plugin *plugin) | |||
268 | static enum GNUNET_GenericReturnValue | 268 | static enum GNUNET_GenericReturnValue |
269 | namestore_sqlite_store_records (void *cls, | 269 | namestore_sqlite_store_records (void *cls, |
270 | const struct | 270 | const struct |
271 | GNUNET_IDENTITY_PrivateKey *zone_key, | 271 | GNUNET_CRYPTO_PrivateKey *zone_key, |
272 | const char *label, | 272 | const char *label, |
273 | unsigned int rd_count, | 273 | unsigned int rd_count, |
274 | const struct GNUNET_GNSRECORD_Data *rd) | 274 | const struct GNUNET_GNSRECORD_Data *rd) |
275 | { | 275 | { |
276 | struct Plugin *plugin = cls; | 276 | struct Plugin *plugin = cls; |
277 | int n; | 277 | int n; |
278 | struct GNUNET_IDENTITY_PublicKey pkey; | 278 | struct GNUNET_CRYPTO_PublicKey pkey; |
279 | uint64_t rvalue; | 279 | uint64_t rvalue; |
280 | ssize_t data_size; | 280 | ssize_t data_size; |
281 | 281 | ||
@@ -426,7 +426,7 @@ static enum GNUNET_GenericReturnValue | |||
426 | get_records_and_call_iterator (struct Plugin *plugin, | 426 | get_records_and_call_iterator (struct Plugin *plugin, |
427 | sqlite3_stmt *stmt, | 427 | sqlite3_stmt *stmt, |
428 | const struct | 428 | const struct |
429 | GNUNET_IDENTITY_PrivateKey *zone_key, | 429 | GNUNET_CRYPTO_PrivateKey *zone_key, |
430 | uint64_t limit, | 430 | uint64_t limit, |
431 | GNUNET_NAMESTORE_RecordIterator iter, | 431 | GNUNET_NAMESTORE_RecordIterator iter, |
432 | void *iter_cls) | 432 | void *iter_cls) |
@@ -461,7 +461,7 @@ get_records_and_call_iterator (struct Plugin *plugin, | |||
461 | size_t data_size; | 461 | size_t data_size; |
462 | void *data; | 462 | void *data; |
463 | char *label; | 463 | char *label; |
464 | struct GNUNET_IDENTITY_PrivateKey zk; | 464 | struct GNUNET_CRYPTO_PrivateKey zk; |
465 | struct GNUNET_SQ_ResultSpec rs[] = { | 465 | struct GNUNET_SQ_ResultSpec rs[] = { |
466 | GNUNET_SQ_result_spec_uint64 (&seq), | 466 | GNUNET_SQ_result_spec_uint64 (&seq), |
467 | GNUNET_SQ_result_spec_uint32 (&record_count), | 467 | GNUNET_SQ_result_spec_uint32 (&record_count), |
@@ -543,7 +543,7 @@ get_records_and_call_iterator (struct Plugin *plugin, | |||
543 | static enum GNUNET_GenericReturnValue | 543 | static enum GNUNET_GenericReturnValue |
544 | namestore_sqlite_lookup_records (void *cls, | 544 | namestore_sqlite_lookup_records (void *cls, |
545 | const struct | 545 | const struct |
546 | GNUNET_IDENTITY_PrivateKey *zone, | 546 | GNUNET_CRYPTO_PrivateKey *zone, |
547 | const char *label, | 547 | const char *label, |
548 | GNUNET_NAMESTORE_RecordIterator iter, | 548 | GNUNET_NAMESTORE_RecordIterator iter, |
549 | void *iter_cls) | 549 | void *iter_cls) |
@@ -595,7 +595,7 @@ namestore_sqlite_lookup_records (void *cls, | |||
595 | static enum GNUNET_GenericReturnValue | 595 | static enum GNUNET_GenericReturnValue |
596 | namestore_sqlite_iterate_records (void *cls, | 596 | namestore_sqlite_iterate_records (void *cls, |
597 | const struct | 597 | const struct |
598 | GNUNET_IDENTITY_PrivateKey *zone, | 598 | GNUNET_CRYPTO_PrivateKey *zone, |
599 | uint64_t serial, | 599 | uint64_t serial, |
600 | uint64_t limit, | 600 | uint64_t limit, |
601 | GNUNET_NAMESTORE_RecordIterator iter, | 601 | GNUNET_NAMESTORE_RecordIterator iter, |
@@ -662,9 +662,9 @@ namestore_sqlite_iterate_records (void *cls, | |||
662 | */ | 662 | */ |
663 | static enum GNUNET_GenericReturnValue | 663 | static enum GNUNET_GenericReturnValue |
664 | namestore_sqlite_zone_to_name (void *cls, | 664 | namestore_sqlite_zone_to_name (void *cls, |
665 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 665 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
666 | const struct | 666 | const struct |
667 | GNUNET_IDENTITY_PublicKey *value_zone, | 667 | GNUNET_CRYPTO_PublicKey *value_zone, |
668 | GNUNET_NAMESTORE_RecordIterator iter, | 668 | GNUNET_NAMESTORE_RecordIterator iter, |
669 | void *iter_cls) | 669 | void *iter_cls) |
670 | { | 670 | { |
diff --git a/src/namestore/plugin_rest_namestore.c b/src/namestore/plugin_rest_namestore.c index 1f2f58097..31e78e6dd 100644 --- a/src/namestore/plugin_rest_namestore.c +++ b/src/namestore/plugin_rest_namestore.c | |||
@@ -214,7 +214,7 @@ struct RequestHandle | |||
214 | /** | 214 | /** |
215 | * Private key for the zone | 215 | * Private key for the zone |
216 | */ | 216 | */ |
217 | const struct GNUNET_IDENTITY_PrivateKey *zone_pkey; | 217 | const struct GNUNET_CRYPTO_PrivateKey *zone_pkey; |
218 | 218 | ||
219 | /** | 219 | /** |
220 | * IDENTITY Operation | 220 | * IDENTITY Operation |
@@ -482,7 +482,7 @@ namestore_list_finished (void *cls) | |||
482 | */ | 482 | */ |
483 | static void | 483 | static void |
484 | namestore_list_iteration (void *cls, | 484 | namestore_list_iteration (void *cls, |
485 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, | 485 | const struct GNUNET_CRYPTO_PrivateKey *zone_key, |
486 | const char *rname, | 486 | const char *rname, |
487 | unsigned int rd_len, | 487 | unsigned int rd_len, |
488 | const struct GNUNET_GNSRECORD_Data *rd, | 488 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -541,7 +541,7 @@ ns_lookup_error_cb (void *cls) | |||
541 | 541 | ||
542 | static void | 542 | static void |
543 | ns_get_lookup_cb (void *cls, | 543 | ns_get_lookup_cb (void *cls, |
544 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 544 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
545 | const char *label, | 545 | const char *label, |
546 | unsigned int rd_len, | 546 | unsigned int rd_len, |
547 | const struct GNUNET_GNSRECORD_Data *rd) | 547 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -692,7 +692,7 @@ namestore_get (struct GNUNET_REST_RequestHandle *con_handle, | |||
692 | 692 | ||
693 | static void | 693 | static void |
694 | ns_lookup_cb (void *cls, | 694 | ns_lookup_cb (void *cls, |
695 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 695 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
696 | const char *label, | 696 | const char *label, |
697 | unsigned int rd_count, | 697 | unsigned int rd_count, |
698 | const struct GNUNET_GNSRECORD_Data *rd) | 698 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1152,7 +1152,7 @@ list_ego (void *cls, | |||
1152 | const char *identifier) | 1152 | const char *identifier) |
1153 | { | 1153 | { |
1154 | struct EgoEntry *ego_entry; | 1154 | struct EgoEntry *ego_entry; |
1155 | struct GNUNET_IDENTITY_PublicKey pk; | 1155 | struct GNUNET_CRYPTO_PublicKey pk; |
1156 | 1156 | ||
1157 | if ((NULL == ego) && (ID_REST_STATE_INIT == state)) | 1157 | if ((NULL == ego) && (ID_REST_STATE_INIT == state)) |
1158 | { | 1158 | { |
@@ -1169,7 +1169,7 @@ list_ego (void *cls, | |||
1169 | { | 1169 | { |
1170 | ego_entry = GNUNET_new (struct EgoEntry); | 1170 | ego_entry = GNUNET_new (struct EgoEntry); |
1171 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 1171 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
1172 | ego_entry->keystring = GNUNET_IDENTITY_public_key_to_string (&pk); | 1172 | ego_entry->keystring = GNUNET_CRYPTO_public_key_to_string (&pk); |
1173 | ego_entry->ego = ego; | 1173 | ego_entry->ego = ego; |
1174 | ego_entry->identifier = GNUNET_strdup (identifier); | 1174 | ego_entry->identifier = GNUNET_strdup (identifier); |
1175 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, | 1175 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, |
@@ -1195,7 +1195,7 @@ list_ego (void *cls, | |||
1195 | /* Add */ | 1195 | /* Add */ |
1196 | ego_entry = GNUNET_new (struct EgoEntry); | 1196 | ego_entry = GNUNET_new (struct EgoEntry); |
1197 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 1197 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
1198 | ego_entry->keystring = GNUNET_IDENTITY_public_key_to_string (&pk); | 1198 | ego_entry->keystring = GNUNET_CRYPTO_public_key_to_string (&pk); |
1199 | ego_entry->ego = ego; | 1199 | ego_entry->ego = ego; |
1200 | ego_entry->identifier = GNUNET_strdup (identifier); | 1200 | ego_entry->identifier = GNUNET_strdup (identifier); |
1201 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, | 1201 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, |
diff --git a/src/namestore/test_namestore_api_edit_records.c b/src/namestore/test_namestore_api_edit_records.c index fbee57432..a6bce7c17 100644 --- a/src/namestore/test_namestore_api_edit_records.c +++ b/src/namestore/test_namestore_api_edit_records.c | |||
@@ -40,9 +40,9 @@ static struct GNUNET_NAMESTORE_Handle *nsh2; | |||
40 | 40 | ||
41 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 41 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
42 | 42 | ||
43 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 43 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
44 | 44 | ||
45 | static struct GNUNET_IDENTITY_PublicKey pubkey; | 45 | static struct GNUNET_CRYPTO_PublicKey pubkey; |
46 | 46 | ||
47 | static int res; | 47 | static int res; |
48 | 48 | ||
@@ -91,7 +91,7 @@ end (void *cls) | |||
91 | 91 | ||
92 | static void | 92 | static void |
93 | lookup_it (void *cls, | 93 | lookup_it (void *cls, |
94 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 94 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
95 | const char *label, | 95 | const char *label, |
96 | unsigned int rd_count, | 96 | unsigned int rd_count, |
97 | const struct GNUNET_GNSRECORD_Data *rd) | 97 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -138,7 +138,7 @@ fail_cb_lock (void *cls); | |||
138 | 138 | ||
139 | static void | 139 | static void |
140 | edit_cont_b (void *cls, | 140 | edit_cont_b (void *cls, |
141 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 141 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
142 | const char *label, | 142 | const char *label, |
143 | unsigned int rd_count, | 143 | unsigned int rd_count, |
144 | const struct GNUNET_GNSRECORD_Data *rd) | 144 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -243,7 +243,7 @@ begin_cont_b (void *cls, | |||
243 | 243 | ||
244 | static void | 244 | static void |
245 | edit_cont (void *cls, | 245 | edit_cont (void *cls, |
246 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 246 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
247 | const char *label, | 247 | const char *label, |
248 | unsigned int rd_count, | 248 | unsigned int rd_count, |
249 | const struct GNUNET_GNSRECORD_Data *rd) | 249 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -322,7 +322,7 @@ run (void *cls, | |||
322 | 322 | ||
323 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); | 323 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
324 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | 324 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
325 | GNUNET_IDENTITY_key_get_public (&privkey, | 325 | GNUNET_CRYPTO_key_get_public (&privkey, |
326 | &pubkey); | 326 | &pubkey); |
327 | 327 | ||
328 | removed = GNUNET_NO; | 328 | removed = GNUNET_NO; |
diff --git a/src/namestore/test_namestore_api_lookup_nick.c b/src/namestore/test_namestore_api_lookup_nick.c index b26674a95..21fc1ef79 100644 --- a/src/namestore/test_namestore_api_lookup_nick.c +++ b/src/namestore/test_namestore_api_lookup_nick.c | |||
@@ -40,9 +40,9 @@ static struct GNUNET_NAMESTORE_Handle *nsh; | |||
40 | 40 | ||
41 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 41 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
42 | 42 | ||
43 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 43 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
44 | 44 | ||
45 | static struct GNUNET_IDENTITY_PublicKey pubkey; | 45 | static struct GNUNET_CRYPTO_PublicKey pubkey; |
46 | 46 | ||
47 | static int res; | 47 | static int res; |
48 | 48 | ||
@@ -97,7 +97,7 @@ end (void *cls) | |||
97 | 97 | ||
98 | static void | 98 | static void |
99 | lookup_it (void *cls, | 99 | lookup_it (void *cls, |
100 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 100 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
101 | const char *label, | 101 | const char *label, |
102 | unsigned int rd_count, | 102 | unsigned int rd_count, |
103 | const struct GNUNET_GNSRECORD_Data *rd) | 103 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -289,7 +289,7 @@ run (void *cls, | |||
289 | NULL); | 289 | NULL); |
290 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); | 290 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
291 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | 291 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
292 | GNUNET_IDENTITY_key_get_public (&privkey, | 292 | GNUNET_CRYPTO_key_get_public (&privkey, |
293 | &pubkey); | 293 | &pubkey); |
294 | 294 | ||
295 | nsh = GNUNET_NAMESTORE_connect (cfg); | 295 | nsh = GNUNET_NAMESTORE_connect (cfg); |
diff --git a/src/namestore/test_namestore_api_monitoring.c b/src/namestore/test_namestore_api_monitoring.c index 271f4c40b..74dad3749 100644 --- a/src/namestore/test_namestore_api_monitoring.c +++ b/src/namestore/test_namestore_api_monitoring.c | |||
@@ -36,9 +36,9 @@ static struct GNUNET_NAMESTORE_Handle *nsh; | |||
36 | 36 | ||
37 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 37 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
38 | 38 | ||
39 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 39 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
40 | 40 | ||
41 | static struct GNUNET_IDENTITY_PrivateKey privkey2; | 41 | static struct GNUNET_CRYPTO_PrivateKey privkey2; |
42 | 42 | ||
43 | static struct GNUNET_NAMESTORE_ZoneMonitor *zm; | 43 | static struct GNUNET_NAMESTORE_ZoneMonitor *zm; |
44 | 44 | ||
@@ -132,7 +132,7 @@ end (void *cls) | |||
132 | 132 | ||
133 | static void | 133 | static void |
134 | zone_proc (void *cls, | 134 | zone_proc (void *cls, |
135 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, | 135 | const struct GNUNET_CRYPTO_PrivateKey *zone_key, |
136 | const char *name, | 136 | const char *name, |
137 | unsigned int rd_count, | 137 | unsigned int rd_count, |
138 | const struct GNUNET_GNSRECORD_Data *rd) | 138 | const struct GNUNET_GNSRECORD_Data *rd) |
diff --git a/src/namestore/test_namestore_api_monitoring_existing.c b/src/namestore/test_namestore_api_monitoring_existing.c index 87476b309..fe17833c8 100644 --- a/src/namestore/test_namestore_api_monitoring_existing.c +++ b/src/namestore/test_namestore_api_monitoring_existing.c | |||
@@ -37,9 +37,9 @@ static struct GNUNET_NAMESTORE_Handle *nsh; | |||
37 | 37 | ||
38 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 38 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
39 | 39 | ||
40 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 40 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
41 | 41 | ||
42 | static struct GNUNET_IDENTITY_PrivateKey privkey2; | 42 | static struct GNUNET_CRYPTO_PrivateKey privkey2; |
43 | 43 | ||
44 | static struct GNUNET_NAMESTORE_ZoneMonitor *zm; | 44 | static struct GNUNET_NAMESTORE_ZoneMonitor *zm; |
45 | 45 | ||
@@ -128,7 +128,7 @@ end (void *cls) | |||
128 | 128 | ||
129 | static void | 129 | static void |
130 | zone_proc (void *cls, | 130 | zone_proc (void *cls, |
131 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, | 131 | const struct GNUNET_CRYPTO_PrivateKey *zone_key, |
132 | const char *name, | 132 | const char *name, |
133 | unsigned int rd_count, | 133 | unsigned int rd_count, |
134 | const struct GNUNET_GNSRECORD_Data *rd) | 134 | const struct GNUNET_GNSRECORD_Data *rd) |
diff --git a/src/namestore/test_namestore_api_remove.c b/src/namestore/test_namestore_api_remove.c index 9c00cdfad..1a4a7c867 100644 --- a/src/namestore/test_namestore_api_remove.c +++ b/src/namestore/test_namestore_api_remove.c | |||
@@ -38,9 +38,9 @@ static struct GNUNET_NAMESTORE_Handle *nsh; | |||
38 | 38 | ||
39 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 39 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
40 | 40 | ||
41 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 41 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
42 | 42 | ||
43 | static struct GNUNET_IDENTITY_PublicKey pubkey; | 43 | static struct GNUNET_CRYPTO_PublicKey pubkey; |
44 | 44 | ||
45 | static int res; | 45 | static int res; |
46 | 46 | ||
@@ -157,7 +157,7 @@ run (void *cls, | |||
157 | NULL); | 157 | NULL); |
158 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); | 158 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
159 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | 159 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
160 | GNUNET_IDENTITY_key_get_public (&privkey, | 160 | GNUNET_CRYPTO_key_get_public (&privkey, |
161 | &pubkey); | 161 | &pubkey); |
162 | 162 | ||
163 | removed = GNUNET_NO; | 163 | removed = GNUNET_NO; |
diff --git a/src/namestore/test_namestore_api_remove_not_existing_record.c b/src/namestore/test_namestore_api_remove_not_existing_record.c index 9a3eabbee..11a69bea1 100644 --- a/src/namestore/test_namestore_api_remove_not_existing_record.c +++ b/src/namestore/test_namestore_api_remove_not_existing_record.c | |||
@@ -38,9 +38,9 @@ static struct GNUNET_NAMESTORE_Handle *nsh; | |||
38 | 38 | ||
39 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 39 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
40 | 40 | ||
41 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 41 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
42 | 42 | ||
43 | static struct GNUNET_IDENTITY_PublicKey pubkey; | 43 | static struct GNUNET_CRYPTO_PublicKey pubkey; |
44 | 44 | ||
45 | static int res; | 45 | static int res; |
46 | 46 | ||
@@ -132,7 +132,7 @@ run (void *cls, | |||
132 | NULL); | 132 | NULL); |
133 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); | 133 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
134 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | 134 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
135 | GNUNET_IDENTITY_key_get_public (&privkey, &pubkey); | 135 | GNUNET_CRYPTO_key_get_public (&privkey, &pubkey); |
136 | 136 | ||
137 | nsh = GNUNET_NAMESTORE_connect (cfg); | 137 | nsh = GNUNET_NAMESTORE_connect (cfg); |
138 | GNUNET_break (NULL != nsh); | 138 | GNUNET_break (NULL != nsh); |
diff --git a/src/namestore/test_namestore_api_store.c b/src/namestore/test_namestore_api_store.c index f8a3dd412..22b92fbe5 100644 --- a/src/namestore/test_namestore_api_store.c +++ b/src/namestore/test_namestore_api_store.c | |||
@@ -38,9 +38,9 @@ static struct GNUNET_NAMESTORE_Handle *nsh; | |||
38 | 38 | ||
39 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 39 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
40 | 40 | ||
41 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 41 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
42 | 42 | ||
43 | static struct GNUNET_IDENTITY_PublicKey pubkey; | 43 | static struct GNUNET_CRYPTO_PublicKey pubkey; |
44 | 44 | ||
45 | static int res; | 45 | static int res; |
46 | 46 | ||
@@ -114,7 +114,7 @@ run (void *cls, | |||
114 | &endbadly, NULL); | 114 | &endbadly, NULL); |
115 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); | 115 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
116 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | 116 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
117 | GNUNET_IDENTITY_key_get_public (&privkey, &pubkey); | 117 | GNUNET_CRYPTO_key_get_public (&privkey, &pubkey); |
118 | 118 | ||
119 | 119 | ||
120 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us; | 120 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us; |
diff --git a/src/namestore/test_namestore_api_store_update.c b/src/namestore/test_namestore_api_store_update.c index 9baa4becd..86495e261 100644 --- a/src/namestore/test_namestore_api_store_update.c +++ b/src/namestore/test_namestore_api_store_update.c | |||
@@ -44,9 +44,9 @@ static struct GNUNET_NAMESTORE_Handle *nsh; | |||
44 | 44 | ||
45 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 45 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
46 | 46 | ||
47 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 47 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
48 | 48 | ||
49 | static struct GNUNET_IDENTITY_PublicKey pubkey; | 49 | static struct GNUNET_CRYPTO_PublicKey pubkey; |
50 | 50 | ||
51 | static int res; | 51 | static int res; |
52 | 52 | ||
@@ -100,7 +100,7 @@ put_cont (void *cls, | |||
100 | 100 | ||
101 | static void | 101 | static void |
102 | lookup_success (void *cls, | 102 | lookup_success (void *cls, |
103 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 103 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
104 | const char* label, | 104 | const char* label, |
105 | unsigned int rd_count, | 105 | unsigned int rd_count, |
106 | const struct GNUNET_GNSRECORD_Data *rd) | 106 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -210,7 +210,7 @@ run (void *cls, | |||
210 | memset (&privkey, 0, sizeof (privkey)); | 210 | memset (&privkey, 0, sizeof (privkey)); |
211 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); | 211 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
212 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | 212 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
213 | GNUNET_IDENTITY_key_get_public (&privkey, &pubkey); | 213 | GNUNET_CRYPTO_key_get_public (&privkey, &pubkey); |
214 | rd.flags = GNUNET_GNSRECORD_RF_NONE; | 214 | rd.flags = GNUNET_GNSRECORD_RF_NONE; |
215 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us + 1000000000; | 215 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us + 1000000000; |
216 | rd.record_type = TEST_RECORD_TYPE; | 216 | rd.record_type = TEST_RECORD_TYPE; |
diff --git a/src/namestore/test_namestore_api_tx_rollback.c b/src/namestore/test_namestore_api_tx_rollback.c index 1b1d00c96..4a701f60e 100644 --- a/src/namestore/test_namestore_api_tx_rollback.c +++ b/src/namestore/test_namestore_api_tx_rollback.c | |||
@@ -38,9 +38,9 @@ static struct GNUNET_NAMESTORE_Handle *nsh; | |||
38 | 38 | ||
39 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 39 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
40 | 40 | ||
41 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 41 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
42 | 42 | ||
43 | static struct GNUNET_IDENTITY_PublicKey pubkey; | 43 | static struct GNUNET_CRYPTO_PublicKey pubkey; |
44 | 44 | ||
45 | static int res; | 45 | static int res; |
46 | 46 | ||
@@ -88,7 +88,7 @@ end (void *cls) | |||
88 | 88 | ||
89 | static void | 89 | static void |
90 | lookup_it (void *cls, | 90 | lookup_it (void *cls, |
91 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 91 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
92 | const char *label, | 92 | const char *label, |
93 | unsigned int rd_count, | 93 | unsigned int rd_count, |
94 | const struct GNUNET_GNSRECORD_Data *rd) | 94 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -173,7 +173,7 @@ begin_cont (void *cls, | |||
173 | GNUNET_assert (GNUNET_EC_NONE == ec); | 173 | GNUNET_assert (GNUNET_EC_NONE == ec); |
174 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); | 174 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
175 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | 175 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
176 | GNUNET_IDENTITY_key_get_public (&privkey, | 176 | GNUNET_CRYPTO_key_get_public (&privkey, |
177 | &pubkey); | 177 | &pubkey); |
178 | 178 | ||
179 | removed = GNUNET_NO; | 179 | removed = GNUNET_NO; |
diff --git a/src/namestore/test_namestore_api_zone_iteration.c b/src/namestore/test_namestore_api_zone_iteration.c index f9bf4986b..fb69fffcc 100644 --- a/src/namestore/test_namestore_api_zone_iteration.c +++ b/src/namestore/test_namestore_api_zone_iteration.c | |||
@@ -36,9 +36,9 @@ static struct GNUNET_NAMESTORE_Handle *nsh; | |||
36 | 36 | ||
37 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 37 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
38 | 38 | ||
39 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 39 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
40 | 40 | ||
41 | static struct GNUNET_IDENTITY_PrivateKey privkey2; | 41 | static struct GNUNET_CRYPTO_PrivateKey privkey2; |
42 | 42 | ||
43 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; | 43 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; |
44 | 44 | ||
@@ -141,7 +141,7 @@ fail_cb (void *cls) | |||
141 | 141 | ||
142 | static void | 142 | static void |
143 | zone_proc (void *cls, | 143 | zone_proc (void *cls, |
144 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 144 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
145 | const char *label, | 145 | const char *label, |
146 | unsigned int rd_count, | 146 | unsigned int rd_count, |
147 | const struct GNUNET_GNSRECORD_Data *rd) | 147 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -329,7 +329,7 @@ create_record (unsigned int count) | |||
329 | */ | 329 | */ |
330 | static void | 330 | static void |
331 | empty_zone_proc (void *cls, | 331 | empty_zone_proc (void *cls, |
332 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 332 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
333 | const char *label, | 333 | const char *label, |
334 | unsigned int rd_count, | 334 | unsigned int rd_count, |
335 | const struct GNUNET_GNSRECORD_Data *rd) | 335 | const struct GNUNET_GNSRECORD_Data *rd) |
diff --git a/src/namestore/test_namestore_api_zone_iteration_nick.c b/src/namestore/test_namestore_api_zone_iteration_nick.c index 5855b1e87..c494051d0 100644 --- a/src/namestore/test_namestore_api_zone_iteration_nick.c +++ b/src/namestore/test_namestore_api_zone_iteration_nick.c | |||
@@ -37,9 +37,9 @@ | |||
37 | 37 | ||
38 | static struct GNUNET_NAMESTORE_Handle *nsh; | 38 | static struct GNUNET_NAMESTORE_Handle *nsh; |
39 | 39 | ||
40 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 40 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
41 | 41 | ||
42 | static struct GNUNET_IDENTITY_PrivateKey privkey2; | 42 | static struct GNUNET_CRYPTO_PrivateKey privkey2; |
43 | 43 | ||
44 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; | 44 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; |
45 | 45 | ||
@@ -152,7 +152,7 @@ zone_proc_end (void *cls) | |||
152 | 152 | ||
153 | static void | 153 | static void |
154 | zone_proc (void *cls, | 154 | zone_proc (void *cls, |
155 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 155 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
156 | const char *label, | 156 | const char *label, |
157 | unsigned int rd_count, | 157 | unsigned int rd_count, |
158 | const struct GNUNET_GNSRECORD_Data *rd) | 158 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -342,7 +342,7 @@ nick_1_cont (void *cls, enum GNUNET_ErrorCode ec) | |||
342 | */ | 342 | */ |
343 | static void | 343 | static void |
344 | empty_zone_proc (void *cls, | 344 | empty_zone_proc (void *cls, |
345 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 345 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
346 | const char *label, | 346 | const char *label, |
347 | unsigned int rd_count, | 347 | unsigned int rd_count, |
348 | const struct GNUNET_GNSRECORD_Data *rd) | 348 | const struct GNUNET_GNSRECORD_Data *rd) |
diff --git a/src/namestore/test_namestore_api_zone_iteration_specific_zone.c b/src/namestore/test_namestore_api_zone_iteration_specific_zone.c index 519383169..02587706c 100644 --- a/src/namestore/test_namestore_api_zone_iteration_specific_zone.c +++ b/src/namestore/test_namestore_api_zone_iteration_specific_zone.c | |||
@@ -37,9 +37,9 @@ static struct GNUNET_NAMESTORE_Handle *nsh; | |||
37 | 37 | ||
38 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 38 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
39 | 39 | ||
40 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 40 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
41 | 41 | ||
42 | static struct GNUNET_IDENTITY_PrivateKey privkey2; | 42 | static struct GNUNET_CRYPTO_PrivateKey privkey2; |
43 | 43 | ||
44 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; | 44 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; |
45 | 45 | ||
@@ -123,7 +123,7 @@ fail_cb (void *cls) | |||
123 | 123 | ||
124 | static void | 124 | static void |
125 | zone_proc (void *cls, | 125 | zone_proc (void *cls, |
126 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 126 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
127 | const char *label, | 127 | const char *label, |
128 | unsigned int rd_count, | 128 | unsigned int rd_count, |
129 | const struct GNUNET_GNSRECORD_Data *rd) | 129 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -307,7 +307,7 @@ create_record (unsigned int count) | |||
307 | */ | 307 | */ |
308 | static void | 308 | static void |
309 | empty_zone_proc (void *cls, | 309 | empty_zone_proc (void *cls, |
310 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 310 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
311 | const char *label, | 311 | const char *label, |
312 | unsigned int rd_count, | 312 | unsigned int rd_count, |
313 | const struct GNUNET_GNSRECORD_Data *rd) | 313 | const struct GNUNET_GNSRECORD_Data *rd) |
diff --git a/src/namestore/test_namestore_api_zone_iteration_stop.c b/src/namestore/test_namestore_api_zone_iteration_stop.c index 4fe86301c..b6b0787ef 100644 --- a/src/namestore/test_namestore_api_zone_iteration_stop.c +++ b/src/namestore/test_namestore_api_zone_iteration_stop.c | |||
@@ -33,9 +33,9 @@ | |||
33 | 33 | ||
34 | static struct GNUNET_NAMESTORE_Handle *nsh; | 34 | static struct GNUNET_NAMESTORE_Handle *nsh; |
35 | 35 | ||
36 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 36 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
37 | 37 | ||
38 | static struct GNUNET_IDENTITY_PrivateKey privkey2; | 38 | static struct GNUNET_CRYPTO_PrivateKey privkey2; |
39 | 39 | ||
40 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; | 40 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; |
41 | 41 | ||
@@ -111,7 +111,7 @@ fail_cb (void *cls) | |||
111 | 111 | ||
112 | static void | 112 | static void |
113 | zone_proc (void *cls, | 113 | zone_proc (void *cls, |
114 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 114 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
115 | const char *label, | 115 | const char *label, |
116 | unsigned int rd_count, | 116 | unsigned int rd_count, |
117 | const struct GNUNET_GNSRECORD_Data *rd) | 117 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -317,7 +317,7 @@ create_record (unsigned int count) | |||
317 | */ | 317 | */ |
318 | static void | 318 | static void |
319 | empty_zone_proc (void *cls, | 319 | empty_zone_proc (void *cls, |
320 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 320 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
321 | const char *label, | 321 | const char *label, |
322 | unsigned int rd_count, | 322 | unsigned int rd_count, |
323 | const struct GNUNET_GNSRECORD_Data *rd) | 323 | const struct GNUNET_GNSRECORD_Data *rd) |
diff --git a/src/namestore/test_namestore_api_zone_to_name.c b/src/namestore/test_namestore_api_zone_to_name.c index a99b7bc71..c70eef53a 100644 --- a/src/namestore/test_namestore_api_zone_to_name.c +++ b/src/namestore/test_namestore_api_zone_to_name.c | |||
@@ -41,11 +41,11 @@ static struct GNUNET_NAMESTORE_Handle *nsh; | |||
41 | 41 | ||
42 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 42 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
43 | 43 | ||
44 | static struct GNUNET_IDENTITY_PrivateKey privkey; | 44 | static struct GNUNET_CRYPTO_PrivateKey privkey; |
45 | 45 | ||
46 | static struct GNUNET_IDENTITY_PublicKey pubkey; | 46 | static struct GNUNET_CRYPTO_PublicKey pubkey; |
47 | 47 | ||
48 | static struct GNUNET_IDENTITY_PublicKey s_zone_value; | 48 | static struct GNUNET_CRYPTO_PublicKey s_zone_value; |
49 | 49 | ||
50 | static char *s_name; | 50 | static char *s_name; |
51 | 51 | ||
@@ -91,7 +91,7 @@ end (void *cls) | |||
91 | 91 | ||
92 | static void | 92 | static void |
93 | zone_to_name_proc (void *cls, | 93 | zone_to_name_proc (void *cls, |
94 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, | 94 | const struct GNUNET_CRYPTO_PrivateKey *zone_key, |
95 | const char *n, | 95 | const char *n, |
96 | unsigned int rd_count, | 96 | unsigned int rd_count, |
97 | const struct GNUNET_GNSRECORD_Data *rd) | 97 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -205,7 +205,7 @@ run (void *cls, | |||
205 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); | 205 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
206 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | 206 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
207 | /* get public key */ | 207 | /* get public key */ |
208 | GNUNET_IDENTITY_key_get_public (&privkey, | 208 | GNUNET_CRYPTO_key_get_public (&privkey, |
209 | &pubkey); | 209 | &pubkey); |
210 | 210 | ||
211 | GNUNET_CRYPTO_random_block (GNUNET_CRYPTO_QUALITY_WEAK, | 211 | GNUNET_CRYPTO_random_block (GNUNET_CRYPTO_QUALITY_WEAK, |
diff --git a/src/namestore/test_plugin_namestore.c b/src/namestore/test_plugin_namestore.c index d82a3d349..388b23f57 100644 --- a/src/namestore/test_plugin_namestore.c +++ b/src/namestore/test_plugin_namestore.c | |||
@@ -98,14 +98,14 @@ load_plugin (const struct GNUNET_CONFIGURATION_Handle *cfg) | |||
98 | static void | 98 | static void |
99 | test_record (void *cls, | 99 | test_record (void *cls, |
100 | uint64_t seq, | 100 | uint64_t seq, |
101 | const struct GNUNET_IDENTITY_PrivateKey *private_key, | 101 | const struct GNUNET_CRYPTO_PrivateKey *private_key, |
102 | const char *label, | 102 | const char *label, |
103 | unsigned int rd_count, | 103 | unsigned int rd_count, |
104 | const struct GNUNET_GNSRECORD_Data *rd) | 104 | const struct GNUNET_GNSRECORD_Data *rd) |
105 | { | 105 | { |
106 | int *idp = cls; | 106 | int *idp = cls; |
107 | int id = *idp; | 107 | int id = *idp; |
108 | struct GNUNET_IDENTITY_PrivateKey tzone_private_key; | 108 | struct GNUNET_CRYPTO_PrivateKey tzone_private_key; |
109 | char tname[64]; | 109 | char tname[64]; |
110 | unsigned int trd_count = 1 + (id % 1024); | 110 | unsigned int trd_count = 1 + (id % 1024); |
111 | 111 | ||
@@ -136,7 +136,7 @@ get_record (struct GNUNET_NAMESTORE_PluginFunctions *nsp, int id) | |||
136 | static void | 136 | static void |
137 | put_record (struct GNUNET_NAMESTORE_PluginFunctions *nsp, int id) | 137 | put_record (struct GNUNET_NAMESTORE_PluginFunctions *nsp, int id) |
138 | { | 138 | { |
139 | struct GNUNET_IDENTITY_PrivateKey zone_private_key; | 139 | struct GNUNET_CRYPTO_PrivateKey zone_private_key; |
140 | char label[64]; | 140 | char label[64]; |
141 | unsigned int rd_count = 1 + (id % 1024); | 141 | unsigned int rd_count = 1 + (id % 1024); |
142 | struct GNUNET_GNSRECORD_Data rd[GNUNET_NZL (rd_count)]; | 142 | struct GNUNET_GNSRECORD_Data rd[GNUNET_NZL (rd_count)]; |
diff --git a/src/nat-auto/Makefile.am b/src/nat-auto/Makefile.am index 48ea93d9f..0ca5da4dc 100644 --- a/src/nat-auto/Makefile.am +++ b/src/nat-auto/Makefile.am | |||
@@ -19,7 +19,7 @@ gnunet_nat_server_SOURCES = \ | |||
19 | gnunet-nat-server.c nat-auto.h | 19 | gnunet-nat-server.c nat-auto.h |
20 | gnunet_nat_server_LDADD = \ | 20 | gnunet_nat_server_LDADD = \ |
21 | $(top_builddir)/src/nat/libgnunetnatnew.la \ | 21 | $(top_builddir)/src/nat/libgnunetnatnew.la \ |
22 | $(top_builddir)/src/util/libgnunetutil.la | 22 | $(top_builddir)/src/lib/util/libgnunetutil.la |
23 | gnunet_nat_server_LDFLAGS = \ | 23 | gnunet_nat_server_LDFLAGS = \ |
24 | $(GN_LIBINTL) | 24 | $(GN_LIBINTL) |
25 | 25 | ||
@@ -27,7 +27,7 @@ gnunet_nat_auto_SOURCES = \ | |||
27 | gnunet-nat-auto.c nat-auto.h | 27 | gnunet-nat-auto.c nat-auto.h |
28 | gnunet_nat_auto_LDADD = \ | 28 | gnunet_nat_auto_LDADD = \ |
29 | libgnunetnatauto.la \ | 29 | libgnunetnatauto.la \ |
30 | $(top_builddir)/src/util/libgnunetutil.la | 30 | $(top_builddir)/src/lib/util/libgnunetutil.la |
31 | gnunet_nat_auto_LDFLAGS = \ | 31 | gnunet_nat_auto_LDFLAGS = \ |
32 | $(GN_LIBINTL) | 32 | $(GN_LIBINTL) |
33 | 33 | ||
@@ -43,7 +43,7 @@ libgnunetnatauto_la_SOURCES = \ | |||
43 | nat_auto_api_test.c | 43 | nat_auto_api_test.c |
44 | libgnunetnatauto_la_LIBADD = \ | 44 | libgnunetnatauto_la_LIBADD = \ |
45 | $(top_builddir)/src/nat/libgnunetnatnew.la \ | 45 | $(top_builddir)/src/nat/libgnunetnatnew.la \ |
46 | $(top_builddir)/src/util/libgnunetutil.la \ | 46 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
47 | $(GN_LIBINTL) @EXT_LIBS@ | 47 | $(GN_LIBINTL) @EXT_LIBS@ |
48 | libgnunetnatauto_la_LDFLAGS = \ | 48 | libgnunetnatauto_la_LDFLAGS = \ |
49 | $(GN_LIB_LDFLAGS) \ | 49 | $(GN_LIB_LDFLAGS) \ |
@@ -52,7 +52,7 @@ libgnunetnatauto_la_LDFLAGS = \ | |||
52 | gnunet_service_nat_auto_SOURCES = \ | 52 | gnunet_service_nat_auto_SOURCES = \ |
53 | gnunet-service-nat-auto.c | 53 | gnunet-service-nat-auto.c |
54 | gnunet_service_nat_auto_LDADD = \ | 54 | gnunet_service_nat_auto_LDADD = \ |
55 | $(top_builddir)/src/util/libgnunetutil.la \ | 55 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
56 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 56 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
57 | $(top_builddir)/src/nat/libgnunetnatnew.la \ | 57 | $(top_builddir)/src/nat/libgnunetnatnew.la \ |
58 | $(LIBGCRYPT_LIBS) \ | 58 | $(LIBGCRYPT_LIBS) \ |
diff --git a/src/nat/Makefile.am b/src/nat/Makefile.am index 3eea5e2a4..78ba9b92c 100644 --- a/src/nat/Makefile.am +++ b/src/nat/Makefile.am | |||
@@ -41,7 +41,7 @@ gnunet_nat_SOURCES = \ | |||
41 | gnunet-nat.c nat.h | 41 | gnunet-nat.c nat.h |
42 | gnunet_nat_LDADD = \ | 42 | gnunet_nat_LDADD = \ |
43 | libgnunetnatnew.la \ | 43 | libgnunetnatnew.la \ |
44 | $(top_builddir)/src/util/libgnunetutil.la | 44 | $(top_builddir)/src/lib/util/libgnunetutil.la |
45 | gnunet_nat_LDFLAGS = \ | 45 | gnunet_nat_LDFLAGS = \ |
46 | $(GN_LIBINTL) | 46 | $(GN_LIBINTL) |
47 | 47 | ||
@@ -58,7 +58,7 @@ libgnunetnatnew_la_SOURCES = \ | |||
58 | nat_api_stun.c nat_stun.h \ | 58 | nat_api_stun.c nat_stun.h \ |
59 | nat.h | 59 | nat.h |
60 | libgnunetnatnew_la_LIBADD = \ | 60 | libgnunetnatnew_la_LIBADD = \ |
61 | $(top_builddir)/src/util/libgnunetutil.la \ | 61 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
62 | $(GN_LIBINTL) @EXT_LIBS@ | 62 | $(GN_LIBINTL) @EXT_LIBS@ |
63 | libgnunetnatnew_la_LDFLAGS = \ | 63 | libgnunetnatnew_la_LDFLAGS = \ |
64 | $(GN_LIB_LDFLAGS) \ | 64 | $(GN_LIB_LDFLAGS) \ |
@@ -71,7 +71,7 @@ gnunet_service_nat_SOURCES = \ | |||
71 | gnunet-service-nat_mini.c gnunet-service-nat_mini.h \ | 71 | gnunet-service-nat_mini.c gnunet-service-nat_mini.h \ |
72 | gnunet-service-nat_helper.c gnunet-service-nat_helper.h | 72 | gnunet-service-nat_helper.c gnunet-service-nat_helper.h |
73 | gnunet_service_nat_LDADD = \ | 73 | gnunet_service_nat_LDADD = \ |
74 | $(top_builddir)/src/util/libgnunetutil.la \ | 74 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
75 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 75 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
76 | $(LIBGCRYPT_LIBS) \ | 76 | $(LIBGCRYPT_LIBS) \ |
77 | -lgcrypt \ | 77 | -lgcrypt \ |
@@ -92,25 +92,25 @@ endif | |||
92 | # test_nat.c | 92 | # test_nat.c |
93 | #test_nat_LDADD = \ | 93 | #test_nat_LDADD = \ |
94 | # libgnunetnat.la \ | 94 | # libgnunetnat.la \ |
95 | # $(top_builddir)/src/util/libgnunetutil.la | 95 | # $(top_builddir)/src/lib/util/libgnunetutil.la |
96 | 96 | ||
97 | #test_nat_mini_SOURCES = \ | 97 | #test_nat_mini_SOURCES = \ |
98 | # test_nat_mini.c | 98 | # test_nat_mini.c |
99 | #test_nat_mini_LDADD = \ | 99 | #test_nat_mini_LDADD = \ |
100 | # libgnunetnat.la \ | 100 | # libgnunetnat.la \ |
101 | # $(top_builddir)/src/util/libgnunetutil.la | 101 | # $(top_builddir)/src/lib/util/libgnunetutil.la |
102 | 102 | ||
103 | #test_nat_test_SOURCES = \ | 103 | #test_nat_test_SOURCES = \ |
104 | # test_nat_test.c | 104 | # test_nat_test.c |
105 | #test_nat_test_LDADD = \ | 105 | #test_nat_test_LDADD = \ |
106 | # libgnunetnat.la \ | 106 | # libgnunetnat.la \ |
107 | # $(top_builddir)/src/util/libgnunetutil.la | 107 | # $(top_builddir)/src/lib/util/libgnunetutil.la |
108 | 108 | ||
109 | #test_stun_SOURCES = \ | 109 | #test_stun_SOURCES = \ |
110 | # test_stun.c | 110 | # test_stun.c |
111 | #test_stun_LDADD = \ | 111 | #test_stun_LDADD = \ |
112 | # libgnunetnat.la \ | 112 | # libgnunetnat.la \ |
113 | # $(top_builddir)/src/util/libgnunetutil.la | 113 | # $(top_builddir)/src/lib/util/libgnunetutil.la |
114 | 114 | ||
115 | EXTRA_DIST = \ | 115 | EXTRA_DIST = \ |
116 | test_nat_data.conf \ | 116 | test_nat_data.conf \ |
diff --git a/src/nse/Makefile.am b/src/nse/Makefile.am index 460e68e02..a6f2b8b36 100644 --- a/src/nse/Makefile.am +++ b/src/nse/Makefile.am | |||
@@ -18,7 +18,7 @@ bin_PROGRAMS = gnunet-nse | |||
18 | gnunet_nse_SOURCES = gnunet-nse.c | 18 | gnunet_nse_SOURCES = gnunet-nse.c |
19 | gnunet_nse_LDADD = \ | 19 | gnunet_nse_LDADD = \ |
20 | libgnunetnse.la \ | 20 | libgnunetnse.la \ |
21 | $(top_builddir)/src/util/libgnunetutil.la \ | 21 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
22 | $(XLIB) $(GN_LIBINTL) | 22 | $(XLIB) $(GN_LIBINTL) |
23 | 23 | ||
24 | lib_LTLIBRARIES = libgnunetnse.la | 24 | lib_LTLIBRARIES = libgnunetnse.la |
@@ -26,7 +26,7 @@ lib_LTLIBRARIES = libgnunetnse.la | |||
26 | libgnunetnse_la_SOURCES = \ | 26 | libgnunetnse_la_SOURCES = \ |
27 | nse_api.c nse.h | 27 | nse_api.c nse.h |
28 | libgnunetnse_la_LIBADD = \ | 28 | libgnunetnse_la_LIBADD = \ |
29 | $(top_builddir)/src/util/libgnunetutil.la \ | 29 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
30 | $(GN_LIBINTL) $(XLIB) | 30 | $(GN_LIBINTL) $(XLIB) |
31 | libgnunetnse_la_LDFLAGS = \ | 31 | libgnunetnse_la_LDFLAGS = \ |
32 | $(GN_LIB_LDFLAGS) \ | 32 | $(GN_LIB_LDFLAGS) \ |
@@ -44,7 +44,7 @@ libexec_PROGRAMS = \ | |||
44 | # gnunet-nse-profiler.c | 44 | # gnunet-nse-profiler.c |
45 | #gnunet_nse_profiler_LDADD = -lm \ | 45 | #gnunet_nse_profiler_LDADD = -lm \ |
46 | # libgnunetnse.la \ | 46 | # libgnunetnse.la \ |
47 | # $(top_builddir)/src/util/libgnunetutil.la \ | 47 | # $(top_builddir)/src/lib/util/libgnunetutil.la \ |
48 | # $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 48 | # $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
49 | # $(top_builddir)/src/testing/libgnunettesting.la \ | 49 | # $(top_builddir)/src/testing/libgnunettesting.la \ |
50 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ | 50 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ |
@@ -54,7 +54,7 @@ gnunet_service_nse_SOURCES = \ | |||
54 | gnunet-service-nse.c | 54 | gnunet-service-nse.c |
55 | gnunet_service_nse_LDADD = \ | 55 | gnunet_service_nse_LDADD = \ |
56 | libgnunetnse.la \ | 56 | libgnunetnse.la \ |
57 | $(top_builddir)/src/util/libgnunetutil.la \ | 57 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
58 | $(top_builddir)/src/core/libgnunetcore.la \ | 58 | $(top_builddir)/src/core/libgnunetcore.la \ |
59 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 59 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
60 | $(LIBGCRYPT_LIBS) \ | 60 | $(LIBGCRYPT_LIBS) \ |
@@ -85,20 +85,20 @@ test_nse_api_SOURCES = \ | |||
85 | test_nse_api_LDADD = \ | 85 | test_nse_api_LDADD = \ |
86 | libgnunetnse.la \ | 86 | libgnunetnse.la \ |
87 | $(top_builddir)/src/testing/libgnunettesting.la \ | 87 | $(top_builddir)/src/testing/libgnunettesting.la \ |
88 | $(top_builddir)/src/util/libgnunetutil.la | 88 | $(top_builddir)/src/lib/util/libgnunetutil.la |
89 | 89 | ||
90 | test_nse_multipeer_SOURCES = \ | 90 | test_nse_multipeer_SOURCES = \ |
91 | test_nse_multipeer.c | 91 | test_nse_multipeer.c |
92 | test_nse_multipeer_LDADD = \ | 92 | test_nse_multipeer_LDADD = \ |
93 | libgnunetnse.la \ | 93 | libgnunetnse.la \ |
94 | $(top_builddir)/src/util/libgnunetutil.la \ | 94 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
95 | $(top_builddir)/src/testbed/libgnunettestbed.la \ | 95 | $(top_builddir)/src/testbed/libgnunettestbed.la \ |
96 | -lm | 96 | -lm |
97 | 97 | ||
98 | perf_kdf_SOURCES = \ | 98 | perf_kdf_SOURCES = \ |
99 | perf_kdf.c | 99 | perf_kdf.c |
100 | perf_kdf_LDADD = \ | 100 | perf_kdf_LDADD = \ |
101 | $(top_builddir)/src/util/libgnunetutil.la \ | 101 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
102 | $(LIBGCRYPT_LIBS) \ | 102 | $(LIBGCRYPT_LIBS) \ |
103 | -lgcrypt | 103 | -lgcrypt |
104 | 104 | ||
diff --git a/src/peerstore/Makefile.am b/src/peerstore/Makefile.am index 7220492f2..e9835eb31 100644 --- a/src/peerstore/Makefile.am +++ b/src/peerstore/Makefile.am | |||
@@ -27,7 +27,7 @@ lib_LTLIBRARIES = \ | |||
27 | gnunet_peerstore_SOURCES = \ | 27 | gnunet_peerstore_SOURCES = \ |
28 | gnunet-peerstore.c | 28 | gnunet-peerstore.c |
29 | gnunet_peerstore_LDADD = \ | 29 | gnunet_peerstore_LDADD = \ |
30 | $(top_builddir)/src/util/libgnunetutil.la \ | 30 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
31 | libgnunetpeerstore.la \ | 31 | libgnunetpeerstore.la \ |
32 | $(GN_LIBINTL) | 32 | $(GN_LIBINTL) |
33 | 33 | ||
@@ -37,16 +37,16 @@ gnunet_service_peerstore_SOURCES = \ | |||
37 | peerstore.h | 37 | peerstore.h |
38 | gnunet_service_peerstore_CFLAGS = $(AM_CFLAGS) | 38 | gnunet_service_peerstore_CFLAGS = $(AM_CFLAGS) |
39 | gnunet_service_peerstore_LDADD = \ | 39 | gnunet_service_peerstore_LDADD = \ |
40 | $(top_builddir)/src/util/libgnunetutil.la \ | 40 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
41 | $(top_builddir)/src/hello/libgnunethello.la \ | 41 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
42 | $(GN_LIBINTL) | 42 | $(GN_LIBINTL) |
43 | 43 | ||
44 | libgnunetpeerstore_la_SOURCES = \ | 44 | libgnunetpeerstore_la_SOURCES = \ |
45 | peerstore_api.c \ | 45 | peerstore_api.c \ |
46 | peerstore_common.c | 46 | peerstore_common.c |
47 | libgnunetpeerstore_la_LIBADD = \ | 47 | libgnunetpeerstore_la_LIBADD = \ |
48 | $(top_builddir)/src/util/libgnunetutil.la \ | 48 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
49 | $(top_builddir)/src/hello/libgnunethello.la | 49 | $(top_builddir)/src/lib/hello/libgnunethello.la |
50 | libgnunetpeerstore_la_LDFLAGS = \ | 50 | libgnunetpeerstore_la_LDFLAGS = \ |
51 | $(GN_LIBINTL) \ | 51 | $(GN_LIBINTL) \ |
52 | $(GN_LIB_LDFLAGS) | 52 | $(GN_LIB_LDFLAGS) |
@@ -58,7 +58,7 @@ libgnunet_plugin_peerstore_flat_la_SOURCES = \ | |||
58 | plugin_peerstore_flat.c | 58 | plugin_peerstore_flat.c |
59 | libgnunet_plugin_peerstore_flat_la_LIBADD = \ | 59 | libgnunet_plugin_peerstore_flat_la_LIBADD = \ |
60 | libgnunetpeerstore.la \ | 60 | libgnunetpeerstore.la \ |
61 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 61 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) \ |
62 | $(LTLIBINTL) | 62 | $(LTLIBINTL) |
63 | libgnunet_plugin_peerstore_flat_la_LDFLAGS = \ | 63 | libgnunet_plugin_peerstore_flat_la_LDFLAGS = \ |
64 | $(GN_PLUGIN_LDFLAGS) | 64 | $(GN_PLUGIN_LDFLAGS) |
@@ -72,7 +72,7 @@ libgnunet_plugin_peerstore_sqlite_la_SOURCES = \ | |||
72 | libgnunet_plugin_peerstore_sqlite_la_LIBADD = \ | 72 | libgnunet_plugin_peerstore_sqlite_la_LIBADD = \ |
73 | libgnunetpeerstore.la \ | 73 | libgnunetpeerstore.la \ |
74 | $(top_builddir)/src/sq/libgnunetsq.la \ | 74 | $(top_builddir)/src/sq/libgnunetsq.la \ |
75 | $(top_builddir)/src/util/libgnunetutil.la \ | 75 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
76 | $(XLIBS) -lsqlite3 \ | 76 | $(XLIBS) -lsqlite3 \ |
77 | $(LTLIBINTL) | 77 | $(LTLIBINTL) |
78 | libgnunet_plugin_peerstore_sqlite_la_LDFLAGS = \ | 78 | libgnunet_plugin_peerstore_sqlite_la_LDFLAGS = \ |
@@ -87,13 +87,13 @@ test_plugin_peerstore_sqlite_SOURCES = \ | |||
87 | test_plugin_peerstore.c | 87 | test_plugin_peerstore.c |
88 | test_plugin_peerstore_sqlite_LDADD = \ | 88 | test_plugin_peerstore_sqlite_LDADD = \ |
89 | $(top_builddir)/src/testing/libgnunettesting.la \ | 89 | $(top_builddir)/src/testing/libgnunettesting.la \ |
90 | $(top_builddir)/src/util/libgnunetutil.la | 90 | $(top_builddir)/src/lib/util/libgnunetutil.la |
91 | 91 | ||
92 | test_plugin_peerstore_flat_SOURCES = \ | 92 | test_plugin_peerstore_flat_SOURCES = \ |
93 | test_plugin_peerstore.c | 93 | test_plugin_peerstore.c |
94 | test_plugin_peerstore_flat_LDADD = \ | 94 | test_plugin_peerstore_flat_LDADD = \ |
95 | $(top_builddir)/src/testing/libgnunettesting.la \ | 95 | $(top_builddir)/src/testing/libgnunettesting.la \ |
96 | $(top_builddir)/src/util/libgnunetutil.la | 96 | $(top_builddir)/src/lib/util/libgnunetutil.la |
97 | 97 | ||
98 | check_PROGRAMS = \ | 98 | check_PROGRAMS = \ |
99 | test_peerstore_api_store \ | 99 | test_peerstore_api_store \ |
@@ -119,32 +119,32 @@ test_peerstore_api_store_SOURCES = \ | |||
119 | test_peerstore_api_store_LDADD = \ | 119 | test_peerstore_api_store_LDADD = \ |
120 | libgnunetpeerstore.la \ | 120 | libgnunetpeerstore.la \ |
121 | $(top_builddir)/src/testing/libgnunettesting.la \ | 121 | $(top_builddir)/src/testing/libgnunettesting.la \ |
122 | $(top_builddir)/src/util/libgnunetutil.la | 122 | $(top_builddir)/src/lib/util/libgnunetutil.la |
123 | 123 | ||
124 | test_peerstore_api_iterate_SOURCES = \ | 124 | test_peerstore_api_iterate_SOURCES = \ |
125 | test_peerstore_api_iterate.c | 125 | test_peerstore_api_iterate.c |
126 | test_peerstore_api_iterate_LDADD = \ | 126 | test_peerstore_api_iterate_LDADD = \ |
127 | libgnunetpeerstore.la \ | 127 | libgnunetpeerstore.la \ |
128 | $(top_builddir)/src/testing/libgnunettesting.la \ | 128 | $(top_builddir)/src/testing/libgnunettesting.la \ |
129 | $(top_builddir)/src/util/libgnunetutil.la | 129 | $(top_builddir)/src/lib/util/libgnunetutil.la |
130 | 130 | ||
131 | test_peerstore_api_watch_SOURCES = \ | 131 | test_peerstore_api_watch_SOURCES = \ |
132 | test_peerstore_api_watch.c | 132 | test_peerstore_api_watch.c |
133 | test_peerstore_api_watch_LDADD = \ | 133 | test_peerstore_api_watch_LDADD = \ |
134 | libgnunetpeerstore.la \ | 134 | libgnunetpeerstore.la \ |
135 | $(top_builddir)/src/testing/libgnunettesting.la \ | 135 | $(top_builddir)/src/testing/libgnunettesting.la \ |
136 | $(top_builddir)/src/util/libgnunetutil.la | 136 | $(top_builddir)/src/lib/util/libgnunetutil.la |
137 | 137 | ||
138 | test_peerstore_api_sync_SOURCES = \ | 138 | test_peerstore_api_sync_SOURCES = \ |
139 | test_peerstore_api_sync.c | 139 | test_peerstore_api_sync.c |
140 | test_peerstore_api_sync_LDADD = \ | 140 | test_peerstore_api_sync_LDADD = \ |
141 | libgnunetpeerstore.la \ | 141 | libgnunetpeerstore.la \ |
142 | $(top_builddir)/src/testing/libgnunettesting.la \ | 142 | $(top_builddir)/src/testing/libgnunettesting.la \ |
143 | $(top_builddir)/src/util/libgnunetutil.la | 143 | $(top_builddir)/src/lib/util/libgnunetutil.la |
144 | 144 | ||
145 | perf_peerstore_store_SOURCES = \ | 145 | perf_peerstore_store_SOURCES = \ |
146 | perf_peerstore_store.c | 146 | perf_peerstore_store.c |
147 | perf_peerstore_store_LDADD = \ | 147 | perf_peerstore_store_LDADD = \ |
148 | libgnunetpeerstore.la \ | 148 | libgnunetpeerstore.la \ |
149 | $(top_builddir)/src/testing/libgnunettesting.la \ | 149 | $(top_builddir)/src/testing/libgnunettesting.la \ |
150 | $(top_builddir)/src/util/libgnunetutil.la | 150 | $(top_builddir)/src/lib/util/libgnunetutil.la |
diff --git a/src/plugin/Makefile.am b/src/plugin/Makefile.am new file mode 100644 index 000000000..c3e06bca8 --- /dev/null +++ b/src/plugin/Makefile.am | |||
@@ -0,0 +1,3 @@ | |||
1 | SUBDIRS = \ | ||
2 | block \ | ||
3 | gnsrecord | ||
diff --git a/src/block/Makefile.am b/src/plugin/block/Makefile.am index ea796bf8f..9b72e4e3c 100644 --- a/src/block/Makefile.am +++ b/src/plugin/block/Makefile.am | |||
@@ -7,10 +7,6 @@ if USE_COVERAGE | |||
7 | AM_CFLAGS = --coverage | 7 | AM_CFLAGS = --coverage |
8 | endif | 8 | endif |
9 | 9 | ||
10 | lib_LTLIBRARIES = \ | ||
11 | libgnunetblock.la \ | ||
12 | libgnunetblockgroup.la | ||
13 | |||
14 | plugin_LTLIBRARIES = \ | 10 | plugin_LTLIBRARIES = \ |
15 | libgnunet_plugin_block_test.la | 11 | libgnunet_plugin_block_test.la |
16 | 12 | ||
@@ -22,9 +18,9 @@ noinst_LTLIBRARIES = \ | |||
22 | libgnunet_plugin_block_template_la_SOURCES = \ | 18 | libgnunet_plugin_block_template_la_SOURCES = \ |
23 | plugin_block_template.c | 19 | plugin_block_template.c |
24 | libgnunet_plugin_block_template_la_LIBADD = \ | 20 | libgnunet_plugin_block_template_la_LIBADD = \ |
25 | libgnunetblockgroup.la \ | 21 | $(top_builddir)/src/lib/block/libgnunetblockgroup.la \ |
26 | libgnunetblock.la \ | 22 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
27 | $(top_builddir)/src/util/libgnunetutil.la \ | 23 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
28 | $(LTLIBINTL) | 24 | $(LTLIBINTL) |
29 | libgnunet_plugin_block_template_la_LDFLAGS = \ | 25 | libgnunet_plugin_block_template_la_LDFLAGS = \ |
30 | $(GN_PLUGIN_LDFLAGS) | 26 | $(GN_PLUGIN_LDFLAGS) |
@@ -32,28 +28,10 @@ libgnunet_plugin_block_template_la_LDFLAGS = \ | |||
32 | libgnunet_plugin_block_test_la_SOURCES = \ | 28 | libgnunet_plugin_block_test_la_SOURCES = \ |
33 | plugin_block_test.c | 29 | plugin_block_test.c |
34 | libgnunet_plugin_block_test_la_LIBADD = \ | 30 | libgnunet_plugin_block_test_la_LIBADD = \ |
35 | libgnunetblockgroup.la \ | 31 | $(top_builddir)/src/lib/block/libgnunetblockgroup.la \ |
36 | libgnunetblock.la \ | 32 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
37 | $(top_builddir)/src/util/libgnunetutil.la \ | 33 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
38 | $(LTLIBINTL) | 34 | $(LTLIBINTL) |
39 | libgnunet_plugin_block_test_la_LDFLAGS = \ | 35 | libgnunet_plugin_block_test_la_LDFLAGS = \ |
40 | $(GN_PLUGIN_LDFLAGS) | 36 | $(GN_PLUGIN_LDFLAGS) |
41 | 37 | ||
42 | libgnunetblock_la_SOURCES = \ | ||
43 | block.c | ||
44 | libgnunetblock_la_LIBADD = \ | ||
45 | $(top_builddir)/src/util/libgnunetutil.la | ||
46 | libgnunetblock_la_LDFLAGS = \ | ||
47 | $(GN_LIB_LDFLAGS) \ | ||
48 | $(GN_LIBINTL) \ | ||
49 | -version-info 0:0:0 | ||
50 | |||
51 | libgnunetblockgroup_la_SOURCES = \ | ||
52 | bg_bf.c | ||
53 | libgnunetblockgroup_la_LIBADD = \ | ||
54 | libgnunetblock.la \ | ||
55 | $(top_builddir)/src/util/libgnunetutil.la | ||
56 | libgnunetblockgroup_la_LDFLAGS = \ | ||
57 | $(GN_LIB_LDFLAGS) \ | ||
58 | $(GN_LIBINTL) \ | ||
59 | -version-info 0:0:0 | ||
diff --git a/src/block/plugin_block_template.c b/src/plugin/block/plugin_block_template.c index 4a271fa42..4a271fa42 100644 --- a/src/block/plugin_block_template.c +++ b/src/plugin/block/plugin_block_template.c | |||
diff --git a/src/block/plugin_block_test.c b/src/plugin/block/plugin_block_test.c index 5afac9205..5afac9205 100644 --- a/src/block/plugin_block_test.c +++ b/src/plugin/block/plugin_block_test.c | |||
diff --git a/src/plugin/gnsrecord/Makefile.am b/src/plugin/gnsrecord/Makefile.am new file mode 100644 index 000000000..1b008cf62 --- /dev/null +++ b/src/plugin/gnsrecord/Makefile.am | |||
@@ -0,0 +1,25 @@ | |||
1 | # This Makefile.am is in the public domain | ||
2 | AM_CPPFLAGS = -I$(top_srcdir)/src/include ${MHD_CFLAGS} | ||
3 | |||
4 | plugindir = $(libdir)/gnunet | ||
5 | |||
6 | pkgcfgdir= $(pkgdatadir)/config.d/ | ||
7 | |||
8 | libexecdir= $(pkglibdir)/libexec/ | ||
9 | |||
10 | if USE_COVERAGE | ||
11 | AM_CFLAGS = --coverage -O0 | ||
12 | XLIBS = -lgcov | ||
13 | endif | ||
14 | |||
15 | plugin_LTLIBRARIES = \ | ||
16 | libgnunet_plugin_gnsrecord_dns.la | ||
17 | |||
18 | |||
19 | libgnunet_plugin_gnsrecord_dns_la_SOURCES = \ | ||
20 | plugin_gnsrecord_dns.c | ||
21 | libgnunet_plugin_gnsrecord_dns_la_LIBADD = \ | ||
22 | $(top_builddir)/src/lib/util/libgnunetutil.la \ | ||
23 | $(LTLIBINTL) | ||
24 | libgnunet_plugin_gnsrecord_dns_la_LDFLAGS = \ | ||
25 | $(GN_PLUGIN_LDFLAGS) | ||
diff --git a/src/gnsrecord/plugin_gnsrecord_dns.c b/src/plugin/gnsrecord/plugin_gnsrecord_dns.c index 5844d9eda..5844d9eda 100644 --- a/src/gnsrecord/plugin_gnsrecord_dns.c +++ b/src/plugin/gnsrecord/plugin_gnsrecord_dns.c | |||
diff --git a/src/pq/Makefile.am b/src/pq/Makefile.am index c91f874f7..6a42499ca 100644 --- a/src/pq/Makefile.am +++ b/src/pq/Makefile.am | |||
@@ -28,7 +28,7 @@ libgnunetpq_la_SOURCES = \ | |||
28 | pq_query_helper.c \ | 28 | pq_query_helper.c \ |
29 | pq_result_helper.c | 29 | pq_result_helper.c |
30 | libgnunetpq_la_LIBADD = -lpq \ | 30 | libgnunetpq_la_LIBADD = -lpq \ |
31 | $(top_builddir)/src/util/libgnunetutil.la | 31 | $(top_builddir)/src/lib/util/libgnunetutil.la |
32 | libgnunetpq_la_LDFLAGS = \ | 32 | libgnunetpq_la_LDFLAGS = \ |
33 | $(POSTGRESQL_LDFLAGS) \ | 33 | $(POSTGRESQL_LDFLAGS) \ |
34 | $(GN_LIB_LDFLAGS) \ | 34 | $(GN_LIB_LDFLAGS) \ |
@@ -47,5 +47,5 @@ test_pq_SOURCES = \ | |||
47 | test_pq.c | 47 | test_pq.c |
48 | test_pq_LDADD = \ | 48 | test_pq_LDADD = \ |
49 | libgnunetpq.la \ | 49 | libgnunetpq.la \ |
50 | $(top_builddir)/src/util/libgnunetutil.la \ | 50 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
51 | -lpq $(XLIB) | 51 | -lpq $(XLIB) |
diff --git a/src/pt/Makefile.am b/src/pt/Makefile.am index f4202457d..c2d2ae505 100644 --- a/src/pt/Makefile.am +++ b/src/pt/Makefile.am | |||
@@ -25,7 +25,7 @@ gnunet_daemon_pt_LDADD = \ | |||
25 | $(top_builddir)/src/dht/libgnunetdht.la \ | 25 | $(top_builddir)/src/dht/libgnunetdht.la \ |
26 | $(top_builddir)/src/dns/libgnunetdns.la \ | 26 | $(top_builddir)/src/dns/libgnunetdns.la \ |
27 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 27 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
28 | $(top_builddir)/src/util/libgnunetutil.la \ | 28 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
29 | $(GN_LIBINTL) | 29 | $(GN_LIBINTL) |
30 | 30 | ||
31 | if LINUX | 31 | if LINUX |
@@ -55,9 +55,9 @@ test_gns_vpn_SOURCES = \ | |||
55 | test_gns_vpn_LDADD = $(MHD_LIBS) @LIBCURL@ \ | 55 | test_gns_vpn_LDADD = $(MHD_LIBS) @LIBCURL@ \ |
56 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 56 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
57 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 57 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
58 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 58 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
59 | $(top_builddir)/src/testing/libgnunettesting.la \ | 59 | $(top_builddir)/src/testing/libgnunettesting.la \ |
60 | $(top_builddir)/src/util/libgnunetutil.la | 60 | $(top_builddir)/src/lib/util/libgnunetutil.la |
61 | test_gns_vpn_CFLAGS = $(MHD_CFLAGS) @LIBCURL_CPPFLAGS@ $(AM_CFLAGS) | 61 | test_gns_vpn_CFLAGS = $(MHD_CFLAGS) @LIBCURL_CPPFLAGS@ $(AM_CFLAGS) |
62 | 62 | ||
63 | test_gnunet_vpn_4_over_SOURCES = \ | 63 | test_gnunet_vpn_4_over_SOURCES = \ |
@@ -65,7 +65,7 @@ test_gnunet_vpn_4_over_SOURCES = \ | |||
65 | test_gnunet_vpn_4_over_LDADD = $(MHD_LIBS) @LIBCURL@ \ | 65 | test_gnunet_vpn_4_over_LDADD = $(MHD_LIBS) @LIBCURL@ \ |
66 | $(top_builddir)/src/vpn/libgnunetvpn.la \ | 66 | $(top_builddir)/src/vpn/libgnunetvpn.la \ |
67 | $(top_builddir)/src/testing/libgnunettesting.la \ | 67 | $(top_builddir)/src/testing/libgnunettesting.la \ |
68 | $(top_builddir)/src/util/libgnunetutil.la | 68 | $(top_builddir)/src/lib/util/libgnunetutil.la |
69 | test_gnunet_vpn_4_over_CFLAGS = $(MHD_CFLAGS) @LIBCURL_CPPFLAGS@ $(AM_CFLAGS) | 69 | test_gnunet_vpn_4_over_CFLAGS = $(MHD_CFLAGS) @LIBCURL_CPPFLAGS@ $(AM_CFLAGS) |
70 | 70 | ||
71 | test_gnunet_vpn_6_over_SOURCES = \ | 71 | test_gnunet_vpn_6_over_SOURCES = \ |
@@ -73,7 +73,7 @@ test_gnunet_vpn_6_over_SOURCES = \ | |||
73 | test_gnunet_vpn_6_over_LDADD = $(MHD_LIBS) @LIBCURL@ \ | 73 | test_gnunet_vpn_6_over_LDADD = $(MHD_LIBS) @LIBCURL@ \ |
74 | $(top_builddir)/src/vpn/libgnunetvpn.la \ | 74 | $(top_builddir)/src/vpn/libgnunetvpn.la \ |
75 | $(top_builddir)/src/testing/libgnunettesting.la \ | 75 | $(top_builddir)/src/testing/libgnunettesting.la \ |
76 | $(top_builddir)/src/util/libgnunetutil.la | 76 | $(top_builddir)/src/lib/util/libgnunetutil.la |
77 | test_gnunet_vpn_6_over_CFLAGS = $(MHD_CFLAGS) @LIBCURL_CPPFLAGS@ $(AM_CFLAGS) | 77 | test_gnunet_vpn_6_over_CFLAGS = $(MHD_CFLAGS) @LIBCURL_CPPFLAGS@ $(AM_CFLAGS) |
78 | 78 | ||
79 | test_gnunet_vpn_4_to_6_SOURCES = \ | 79 | test_gnunet_vpn_4_to_6_SOURCES = \ |
@@ -81,7 +81,7 @@ test_gnunet_vpn_4_to_6_SOURCES = \ | |||
81 | test_gnunet_vpn_4_to_6_LDADD = $(MHD_LIBS) @LIBCURL@ \ | 81 | test_gnunet_vpn_4_to_6_LDADD = $(MHD_LIBS) @LIBCURL@ \ |
82 | $(top_builddir)/src/vpn/libgnunetvpn.la \ | 82 | $(top_builddir)/src/vpn/libgnunetvpn.la \ |
83 | $(top_builddir)/src/testing/libgnunettesting.la \ | 83 | $(top_builddir)/src/testing/libgnunettesting.la \ |
84 | $(top_builddir)/src/util/libgnunetutil.la | 84 | $(top_builddir)/src/lib/util/libgnunetutil.la |
85 | test_gnunet_vpn_4_to_6_CFLAGS = $(MHD_CFLAGS) @LIBCURL_CPPFLAGS@ $(AM_CFLAGS) | 85 | test_gnunet_vpn_4_to_6_CFLAGS = $(MHD_CFLAGS) @LIBCURL_CPPFLAGS@ $(AM_CFLAGS) |
86 | 86 | ||
87 | test_gnunet_vpn_6_to_4_SOURCES = \ | 87 | test_gnunet_vpn_6_to_4_SOURCES = \ |
@@ -89,5 +89,5 @@ test_gnunet_vpn_6_to_4_SOURCES = \ | |||
89 | test_gnunet_vpn_6_to_4_LDADD = $(MHD_LIBS) @LIBCURL@ \ | 89 | test_gnunet_vpn_6_to_4_LDADD = $(MHD_LIBS) @LIBCURL@ \ |
90 | $(top_builddir)/src/vpn/libgnunetvpn.la \ | 90 | $(top_builddir)/src/vpn/libgnunetvpn.la \ |
91 | $(top_builddir)/src/testing/libgnunettesting.la \ | 91 | $(top_builddir)/src/testing/libgnunettesting.la \ |
92 | $(top_builddir)/src/util/libgnunetutil.la | 92 | $(top_builddir)/src/lib/util/libgnunetutil.la |
93 | test_gnunet_vpn_6_to_4_CFLAGS = $(MHD_CFLAGS) @LIBCURL_CPPFLAGS@ $(AM_CFLAGS) | 93 | test_gnunet_vpn_6_to_4_CFLAGS = $(MHD_CFLAGS) @LIBCURL_CPPFLAGS@ $(AM_CFLAGS) |
diff --git a/src/pt/test_gns_vpn.c b/src/pt/test_gns_vpn.c index b2797bc83..4db7bf274 100644 --- a/src/pt/test_gns_vpn.c +++ b/src/pt/test_gns_vpn.c | |||
@@ -557,7 +557,7 @@ identity_cb (void *cls, | |||
557 | void **ctx, | 557 | void **ctx, |
558 | const char *name) | 558 | const char *name) |
559 | { | 559 | { |
560 | const struct GNUNET_IDENTITY_PrivateKey *zone_key; | 560 | const struct GNUNET_CRYPTO_PrivateKey *zone_key; |
561 | struct GNUNET_GNSRECORD_Data rd; | 561 | struct GNUNET_GNSRECORD_Data rd; |
562 | char *rd_string; | 562 | char *rd_string; |
563 | char *peername; | 563 | char *peername; |
diff --git a/src/reclaim/Makefile.am b/src/reclaim/Makefile.am index 4c84a8efc..ac3332ecf 100644 --- a/src/reclaim/Makefile.am +++ b/src/reclaim/Makefile.am | |||
@@ -61,10 +61,10 @@ libgnunet_plugin_rest_reclaim_la_LIBADD = \ | |||
61 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 61 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
62 | libgnunetreclaim.la \ | 62 | libgnunetreclaim.la \ |
63 | $(top_builddir)/src/json/libgnunetjson.la \ | 63 | $(top_builddir)/src/json/libgnunetjson.la \ |
64 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 64 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
65 | $(top_builddir)/src/rest/libgnunetrest.la \ | 65 | $(top_builddir)/src/rest/libgnunetrest.la \ |
66 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 66 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
67 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 67 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) \ |
68 | $(LTLIBINTL) -ljansson $(MHD_LIBS) | 68 | $(LTLIBINTL) -ljansson $(MHD_LIBS) |
69 | libgnunet_plugin_rest_reclaim_la_LDFLAGS = \ | 69 | libgnunet_plugin_rest_reclaim_la_LDFLAGS = \ |
70 | $(GN_PLUGIN_LDFLAGS) | 70 | $(GN_PLUGIN_LDFLAGS) |
@@ -81,8 +81,8 @@ libgnunet_plugin_rest_openid_connect_la_LIBADD = \ | |||
81 | $(top_builddir)/src/rest/libgnunetrest.la \ | 81 | $(top_builddir)/src/rest/libgnunetrest.la \ |
82 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 82 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
83 | $(top_builddir)/src/gns/libgnunetgns.la \ | 83 | $(top_builddir)/src/gns/libgnunetgns.la \ |
84 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 84 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
85 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 85 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) \ |
86 | $(LTLIBINTL) -ljansson -ljose $(MHD_LIBS) \ | 86 | $(LTLIBINTL) -ljansson -ljose $(MHD_LIBS) \ |
87 | $(LIBGCRYPT_LIBS) | 87 | $(LIBGCRYPT_LIBS) |
88 | libgnunet_plugin_rest_openid_connect_la_LDFLAGS = \ | 88 | libgnunet_plugin_rest_openid_connect_la_LDFLAGS = \ |
@@ -98,7 +98,7 @@ libgnunet_plugin_rest_pabc_la_LIBADD = \ | |||
98 | libgnunetreclaim.la \ | 98 | libgnunetreclaim.la \ |
99 | $(top_builddir)/src/json/libgnunetjson.la \ | 99 | $(top_builddir)/src/json/libgnunetjson.la \ |
100 | $(top_builddir)/src/rest/libgnunetrest.la \ | 100 | $(top_builddir)/src/rest/libgnunetrest.la \ |
101 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 101 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) \ |
102 | $(LTLIBINTL) -ljansson -lpabc $(MHD_LIBS) | 102 | $(LTLIBINTL) -ljansson -lpabc $(MHD_LIBS) |
103 | libgnunet_plugin_rest_pabc_la_LDFLAGS = \ | 103 | libgnunet_plugin_rest_pabc_la_LDFLAGS = \ |
104 | $(GN_PLUGIN_LDFLAGS) | 104 | $(GN_PLUGIN_LDFLAGS) |
@@ -109,7 +109,7 @@ endif | |||
109 | libgnunet_plugin_gnsrecord_reclaim_la_SOURCES = \ | 109 | libgnunet_plugin_gnsrecord_reclaim_la_SOURCES = \ |
110 | plugin_gnsrecord_reclaim.c | 110 | plugin_gnsrecord_reclaim.c |
111 | libgnunet_plugin_gnsrecord_reclaim_la_LIBADD = \ | 111 | libgnunet_plugin_gnsrecord_reclaim_la_LIBADD = \ |
112 | $(top_builddir)/src/util/libgnunetutil.la \ | 112 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
113 | $(LTLIBINTL) | 113 | $(LTLIBINTL) |
114 | libgnunet_plugin_gnsrecord_reclaim_la_LDFLAGS = \ | 114 | libgnunet_plugin_gnsrecord_reclaim_la_LDFLAGS = \ |
115 | $(GN_PLUGIN_LDFLAGS) | 115 | $(GN_PLUGIN_LDFLAGS) |
@@ -120,9 +120,9 @@ gnunet_service_reclaim_SOURCES = \ | |||
120 | gnunet-service-reclaim_tickets.c \ | 120 | gnunet-service-reclaim_tickets.c \ |
121 | gnunet-service-reclaim_tickets.h | 121 | gnunet-service-reclaim_tickets.h |
122 | gnunet_service_reclaim_LDADD = \ | 122 | gnunet_service_reclaim_LDADD = \ |
123 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 123 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
124 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 124 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
125 | $(top_builddir)/src/util/libgnunetutil.la \ | 125 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
126 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 126 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
127 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 127 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
128 | libgnunetreclaim.la \ | 128 | libgnunetreclaim.la \ |
@@ -137,7 +137,7 @@ libgnunetreclaim_la_SOURCES = \ | |||
137 | reclaim_credential.c \ | 137 | reclaim_credential.c \ |
138 | reclaim_credential.h | 138 | reclaim_credential.h |
139 | libgnunetreclaim_la_LIBADD = \ | 139 | libgnunetreclaim_la_LIBADD = \ |
140 | $(top_builddir)/src/util/libgnunetutil.la \ | 140 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
141 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 141 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
142 | $(GN_LIBINTL) $(XLIB) | 142 | $(GN_LIBINTL) $(XLIB) |
143 | libgnunetreclaim_la_LDFLAGS = \ | 143 | libgnunetreclaim_la_LDFLAGS = \ |
@@ -150,9 +150,9 @@ libgnunetdid_la_SOURCES = \ | |||
150 | did_core.h \ | 150 | did_core.h \ |
151 | did_core.c | 151 | did_core.c |
152 | libgnunetdid_la_LIBADD = \ | 152 | libgnunetdid_la_LIBADD = \ |
153 | $(top_builddir)/src/util/libgnunetutil.la \ | 153 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
154 | $(top_builddir)/src/gns/libgnunetgns.la \ | 154 | $(top_builddir)/src/gns/libgnunetgns.la \ |
155 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 155 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
156 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 156 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
157 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 157 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
158 | -ljansson \ | 158 | -ljansson \ |
@@ -164,7 +164,7 @@ libgnunetdid_la_LDFLAGS = \ | |||
164 | libgnunet_plugin_reclaim_attribute_basic_la_SOURCES = \ | 164 | libgnunet_plugin_reclaim_attribute_basic_la_SOURCES = \ |
165 | plugin_reclaim_attribute_basic.c | 165 | plugin_reclaim_attribute_basic.c |
166 | libgnunet_plugin_reclaim_attribute_basic_la_LIBADD = \ | 166 | libgnunet_plugin_reclaim_attribute_basic_la_LIBADD = \ |
167 | $(top_builddir)/src/util/libgnunetutil.la \ | 167 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
168 | $(LTLIBINTL) | 168 | $(LTLIBINTL) |
169 | libgnunet_plugin_reclaim_attribute_basic_la_LDFLAGS = \ | 169 | libgnunet_plugin_reclaim_attribute_basic_la_LDFLAGS = \ |
170 | $(GN_PLUGIN_LDFLAGS) | 170 | $(GN_PLUGIN_LDFLAGS) |
@@ -175,7 +175,7 @@ libgnunet_plugin_reclaim_credential_pabc_la_SOURCES = \ | |||
175 | pabc_helper.c \ | 175 | pabc_helper.c \ |
176 | pabc_helper.h | 176 | pabc_helper.h |
177 | libgnunet_plugin_reclaim_credential_pabc_la_LIBADD = \ | 177 | libgnunet_plugin_reclaim_credential_pabc_la_LIBADD = \ |
178 | $(top_builddir)/src/util/libgnunetutil.la \ | 178 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
179 | libgnunetreclaim.la \ | 179 | libgnunetreclaim.la \ |
180 | -ljansson\ | 180 | -ljansson\ |
181 | -lpabc \ | 181 | -lpabc \ |
@@ -189,7 +189,7 @@ libgnunet_plugin_reclaim_credential_jwt_la_SOURCES = \ | |||
189 | plugin_reclaim_credential_jwt.c | 189 | plugin_reclaim_credential_jwt.c |
190 | libgnunet_plugin_reclaim_credential_jwt_la_LIBADD = \ | 190 | libgnunet_plugin_reclaim_credential_jwt_la_LIBADD = \ |
191 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 191 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
192 | $(top_builddir)/src/util/libgnunetutil.la \ | 192 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
193 | libgnunetreclaim.la \ | 193 | libgnunetreclaim.la \ |
194 | -ljansson\ | 194 | -ljansson\ |
195 | $(LTLIBINTL) | 195 | $(LTLIBINTL) |
@@ -199,7 +199,7 @@ libgnunet_plugin_reclaim_credential_jwt_la_LDFLAGS = \ | |||
199 | gnunet_reclaim_SOURCES = \ | 199 | gnunet_reclaim_SOURCES = \ |
200 | gnunet-reclaim.c | 200 | gnunet-reclaim.c |
201 | gnunet_reclaim_LDADD = \ | 201 | gnunet_reclaim_LDADD = \ |
202 | $(top_builddir)/src/util/libgnunetutil.la \ | 202 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
203 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 203 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
204 | libgnunetreclaim.la \ | 204 | libgnunetreclaim.la \ |
205 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 205 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
@@ -208,16 +208,16 @@ gnunet_reclaim_LDADD = \ | |||
208 | test_reclaim_attribute_SOURCES = \ | 208 | test_reclaim_attribute_SOURCES = \ |
209 | test_reclaim_attribute.c | 209 | test_reclaim_attribute.c |
210 | test_reclaim_attribute_LDADD = \ | 210 | test_reclaim_attribute_LDADD = \ |
211 | $(top_builddir)/src/util/libgnunetutil.la \ | 211 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
212 | libgnunetreclaim.la \ | 212 | libgnunetreclaim.la \ |
213 | $(GN_LIBINTL) | 213 | $(GN_LIBINTL) |
214 | 214 | ||
215 | gnunet_did_SOURCES = \ | 215 | gnunet_did_SOURCES = \ |
216 | gnunet-did.c | 216 | gnunet-did.c |
217 | gnunet_did_LDADD = \ | 217 | gnunet_did_LDADD = \ |
218 | $(top_builddir)/src/util/libgnunetutil.la \ | 218 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
219 | $(top_builddir)/src/gns/libgnunetgns.la \ | 219 | $(top_builddir)/src/gns/libgnunetgns.la \ |
220 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 220 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
221 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 221 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
222 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 222 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
223 | libgnunetdid.la \ | 223 | libgnunetdid.la \ |
@@ -227,9 +227,9 @@ gnunet_did_LDADD = \ | |||
227 | test_did_helper_SOURCES = \ | 227 | test_did_helper_SOURCES = \ |
228 | test_did_helper.c | 228 | test_did_helper.c |
229 | test_did_helper_LDADD = \ | 229 | test_did_helper_LDADD = \ |
230 | $(top_builddir)/src/util/libgnunetutil.la \ | 230 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
231 | $(top_builddir)/src/gns/libgnunetgns.la \ | 231 | $(top_builddir)/src/gns/libgnunetgns.la \ |
232 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 232 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
233 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 233 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
234 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 234 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
235 | libgnunetdid.la \ | 235 | libgnunetdid.la \ |
diff --git a/src/reclaim/did.h b/src/reclaim/did.h index 42f65db26..ab1b65925 100644 --- a/src/reclaim/did.h +++ b/src/reclaim/did.h | |||
@@ -44,6 +44,6 @@ DID_ego_to_did (struct GNUNET_IDENTITY_Ego *ego); | |||
44 | */ | 44 | */ |
45 | enum GNUNET_GenericReturnValue | 45 | enum GNUNET_GenericReturnValue |
46 | DID_public_key_from_did (const char* did, | 46 | DID_public_key_from_did (const char* did, |
47 | struct GNUNET_IDENTITY_PublicKey *pk); | 47 | struct GNUNET_CRYPTO_PublicKey *pk); |
48 | 48 | ||
49 | #endif | 49 | #endif |
diff --git a/src/reclaim/did_core.c b/src/reclaim/did_core.c index 4f2bd5a87..ce3336b91 100644 --- a/src/reclaim/did_core.c +++ b/src/reclaim/did_core.c | |||
@@ -90,7 +90,7 @@ DID_resolve (const char *did, | |||
90 | DID_resolve_callback *cont, | 90 | DID_resolve_callback *cont, |
91 | void *cls) | 91 | void *cls) |
92 | { | 92 | { |
93 | struct GNUNET_IDENTITY_PublicKey pkey; | 93 | struct GNUNET_CRYPTO_PublicKey pkey; |
94 | 94 | ||
95 | // did, gns_handle and cont must me set | 95 | // did, gns_handle and cont must me set |
96 | if ((did == NULL) || (gns_handle == NULL) || (cont == NULL)) | 96 | if ((did == NULL) || (gns_handle == NULL) || (cont == NULL)) |
@@ -151,13 +151,13 @@ struct DID_create_namestore_lookup_closure | |||
151 | static void | 151 | static void |
152 | DID_create_namestore_lookup_cb (void *cls, | 152 | DID_create_namestore_lookup_cb (void *cls, |
153 | const struct | 153 | const struct |
154 | GNUNET_IDENTITY_PrivateKey *zone, | 154 | GNUNET_CRYPTO_PrivateKey *zone, |
155 | const char *label, | 155 | const char *label, |
156 | unsigned int rd_count, | 156 | unsigned int rd_count, |
157 | const struct GNUNET_GNSRECORD_Data *rd) | 157 | const struct GNUNET_GNSRECORD_Data *rd) |
158 | { | 158 | { |
159 | struct GNUNET_GNSRECORD_Data record_data; | 159 | struct GNUNET_GNSRECORD_Data record_data; |
160 | struct GNUNET_IDENTITY_PublicKey pkey; | 160 | struct GNUNET_CRYPTO_PublicKey pkey; |
161 | 161 | ||
162 | const char *did_document | 162 | const char *did_document |
163 | = ((struct DID_create_namestore_lookup_closure *) cls)->did_document; | 163 | = ((struct DID_create_namestore_lookup_closure *) cls)->did_document; |
@@ -180,7 +180,7 @@ DID_create_namestore_lookup_cb (void *cls, | |||
180 | } | 180 | } |
181 | else { | 181 | else { |
182 | // Get public key | 182 | // Get public key |
183 | GNUNET_IDENTITY_key_get_public (zone, &pkey); | 183 | GNUNET_CRYPTO_key_get_public (zone, &pkey); |
184 | 184 | ||
185 | // If no DID Document is given a default one is created | 185 | // If no DID Document is given a default one is created |
186 | if (did_document != NULL) | 186 | if (did_document != NULL) |
@@ -225,7 +225,7 @@ DID_create (const struct GNUNET_IDENTITY_Ego *ego, | |||
225 | DID_action_callback *cont, | 225 | DID_action_callback *cont, |
226 | void *cls) | 226 | void *cls) |
227 | { | 227 | { |
228 | struct GNUNET_IDENTITY_PublicKey pkey; | 228 | struct GNUNET_CRYPTO_PublicKey pkey; |
229 | 229 | ||
230 | // Ego, namestore_handle and cont must be set | 230 | // Ego, namestore_handle and cont must be set |
231 | if ((ego == NULL) || (namestore_handle == NULL) || (cont == NULL)) | 231 | if ((ego == NULL) || (namestore_handle == NULL) || (cont == NULL)) |
diff --git a/src/reclaim/did_helper.c b/src/reclaim/did_helper.c index 17f3b21b2..3aac027ee 100644 --- a/src/reclaim/did_helper.c +++ b/src/reclaim/did_helper.c | |||
@@ -42,12 +42,12 @@ | |||
42 | * TODO: Check if EdDSA | 42 | * TODO: Check if EdDSA |
43 | */ | 43 | */ |
44 | char* | 44 | char* |
45 | DID_pkey_to_did (struct GNUNET_IDENTITY_PublicKey *pkey) | 45 | DID_pkey_to_did (struct GNUNET_CRYPTO_PublicKey *pkey) |
46 | { | 46 | { |
47 | char *pkey_str; | 47 | char *pkey_str; |
48 | char *did_str; | 48 | char *did_str; |
49 | 49 | ||
50 | pkey_str = GNUNET_IDENTITY_public_key_to_string (pkey); | 50 | pkey_str = GNUNET_CRYPTO_public_key_to_string (pkey); |
51 | GNUNET_asprintf (&did_str, "%s%s", | 51 | GNUNET_asprintf (&did_str, "%s%s", |
52 | GNUNET_DID_METHOD_PREFIX, | 52 | GNUNET_DID_METHOD_PREFIX, |
53 | pkey_str); | 53 | pkey_str); |
@@ -66,7 +66,7 @@ DID_pkey_to_did (struct GNUNET_IDENTITY_PublicKey *pkey) | |||
66 | char* | 66 | char* |
67 | DID_identity_to_did (struct GNUNET_IDENTITY_Ego *ego) | 67 | DID_identity_to_did (struct GNUNET_IDENTITY_Ego *ego) |
68 | { | 68 | { |
69 | struct GNUNET_IDENTITY_PublicKey pkey; | 69 | struct GNUNET_CRYPTO_PublicKey pkey; |
70 | 70 | ||
71 | GNUNET_IDENTITY_ego_get_public_key (ego, &pkey); | 71 | GNUNET_IDENTITY_ego_get_public_key (ego, &pkey); |
72 | return DID_pkey_to_did (&pkey); | 72 | return DID_pkey_to_did (&pkey); |
@@ -76,7 +76,7 @@ DID_identity_to_did (struct GNUNET_IDENTITY_Ego *ego) | |||
76 | * @brief Return the public key of a DID | 76 | * @brief Return the public key of a DID |
77 | */ | 77 | */ |
78 | enum GNUNET_GenericReturnValue | 78 | enum GNUNET_GenericReturnValue |
79 | DID_did_to_pkey (const char *did, struct GNUNET_IDENTITY_PublicKey *pkey) | 79 | DID_did_to_pkey (const char *did, struct GNUNET_CRYPTO_PublicKey *pkey) |
80 | { | 80 | { |
81 | char pkey_str[MAX_DID_SPECIFIC_IDENTIFIER_LENGTH + 1]; /* 0-term */ | 81 | char pkey_str[MAX_DID_SPECIFIC_IDENTIFIER_LENGTH + 1]; /* 0-term */ |
82 | 82 | ||
@@ -84,7 +84,7 @@ DID_did_to_pkey (const char *did, struct GNUNET_IDENTITY_PublicKey *pkey) | |||
84 | GNUNET_DID_METHOD_PREFIX "%" | 84 | GNUNET_DID_METHOD_PREFIX "%" |
85 | STR (MAX_DID_SPECIFIC_IDENTIFIER_LENGTH) | 85 | STR (MAX_DID_SPECIFIC_IDENTIFIER_LENGTH) |
86 | "s", pkey_str))) || | 86 | "s", pkey_str))) || |
87 | (GNUNET_OK != GNUNET_IDENTITY_public_key_from_string (pkey_str, pkey))) | 87 | (GNUNET_OK != GNUNET_CRYPTO_public_key_from_string (pkey_str, pkey))) |
88 | { | 88 | { |
89 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, "Could not decode given DID: %s\n", | 89 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, "Could not decode given DID: %s\n", |
90 | did); | 90 | did); |
@@ -97,7 +97,7 @@ DID_did_to_pkey (const char *did, struct GNUNET_IDENTITY_PublicKey *pkey) | |||
97 | /** | 97 | /** |
98 | * @brief Convert a base 64 encoded public key to a GNUNET key | 98 | * @brief Convert a base 64 encoded public key to a GNUNET key |
99 | */ | 99 | */ |
100 | struct GNUNET_IDENTITY_PublicKey * | 100 | struct GNUNET_CRYPTO_PublicKey * |
101 | GNUNET_DID_key_convert_multibase_base64_to_gnunet (char *pkey_str) | 101 | GNUNET_DID_key_convert_multibase_base64_to_gnunet (char *pkey_str) |
102 | { | 102 | { |
103 | return NULL; | 103 | return NULL; |
@@ -108,7 +108,7 @@ GNUNET_DID_key_convert_multibase_base64_to_gnunet (char *pkey_str) | |||
108 | */ | 108 | */ |
109 | char * | 109 | char * |
110 | DID_key_convert_gnunet_to_multibase_base64 (struct | 110 | DID_key_convert_gnunet_to_multibase_base64 (struct |
111 | GNUNET_IDENTITY_PublicKey * | 111 | GNUNET_CRYPTO_PublicKey * |
112 | pkey) | 112 | pkey) |
113 | { | 113 | { |
114 | struct GNUNET_CRYPTO_EddsaPublicKey pubkey = pkey->eddsa_key; | 114 | struct GNUNET_CRYPTO_EddsaPublicKey pubkey = pkey->eddsa_key; |
@@ -135,7 +135,7 @@ DID_key_convert_gnunet_to_multibase_base64 (struct | |||
135 | * @return void* Return pointer to the DID Document | 135 | * @return void* Return pointer to the DID Document |
136 | */ | 136 | */ |
137 | char * | 137 | char * |
138 | DID_pkey_to_did_document (struct GNUNET_IDENTITY_PublicKey *pkey) | 138 | DID_pkey_to_did_document (struct GNUNET_CRYPTO_PublicKey *pkey) |
139 | { | 139 | { |
140 | 140 | ||
141 | /* FIXME-MSC: This is effectively creating a DID Document default template for | 141 | /* FIXME-MSC: This is effectively creating a DID Document default template for |
@@ -196,7 +196,7 @@ DID_pkey_to_did_document (struct GNUNET_IDENTITY_PublicKey *pkey) | |||
196 | char * | 196 | char * |
197 | DID_identity_to_did_document (struct GNUNET_IDENTITY_Ego *ego) | 197 | DID_identity_to_did_document (struct GNUNET_IDENTITY_Ego *ego) |
198 | { | 198 | { |
199 | struct GNUNET_IDENTITY_PublicKey pkey; | 199 | struct GNUNET_CRYPTO_PublicKey pkey; |
200 | 200 | ||
201 | GNUNET_IDENTITY_ego_get_public_key (ego, &pkey); | 201 | GNUNET_IDENTITY_ego_get_public_key (ego, &pkey); |
202 | return DID_pkey_to_did (&pkey); | 202 | return DID_pkey_to_did (&pkey); |
diff --git a/src/reclaim/did_helper.h b/src/reclaim/did_helper.h index fea86af5e..d61992c68 100644 --- a/src/reclaim/did_helper.h +++ b/src/reclaim/did_helper.h | |||
@@ -31,7 +31,7 @@ | |||
31 | * @brief Return a DID for a given GNUNET public key | 31 | * @brief Return a DID for a given GNUNET public key |
32 | */ | 32 | */ |
33 | char * | 33 | char * |
34 | DID_pkey_to_did (struct GNUNET_IDENTITY_PublicKey *pkey); | 34 | DID_pkey_to_did (struct GNUNET_CRYPTO_PublicKey *pkey); |
35 | 35 | ||
36 | /** | 36 | /** |
37 | * @brief Generate a DID for a given gnunet EGO | 37 | * @brief Generate a DID for a given gnunet EGO |
@@ -46,12 +46,12 @@ DID_identity_to_did (struct GNUNET_IDENTITY_Ego *ego); | |||
46 | * @brief Return the public key of a DID | 46 | * @brief Return the public key of a DID |
47 | */ | 47 | */ |
48 | enum GNUNET_GenericReturnValue | 48 | enum GNUNET_GenericReturnValue |
49 | DID_did_to_pkey (const char *did, struct GNUNET_IDENTITY_PublicKey *pkey); | 49 | DID_did_to_pkey (const char *did, struct GNUNET_CRYPTO_PublicKey *pkey); |
50 | 50 | ||
51 | // /** | 51 | // /** |
52 | // * @brief Convert a base 64 encoded public key to a GNUNET key | 52 | // * @brief Convert a base 64 encoded public key to a GNUNET key |
53 | // */ | 53 | // */ |
54 | // struct GNUNET_IDENTITY_PublicKey * | 54 | // struct GNUNET_CRYPTO_PublicKey * |
55 | // GNUNET_DID_key_convert_multibase_base64_to_gnunet(char *); | 55 | // GNUNET_DID_key_convert_multibase_base64_to_gnunet(char *); |
56 | 56 | ||
57 | /** | 57 | /** |
@@ -59,13 +59,13 @@ DID_did_to_pkey (const char *did, struct GNUNET_IDENTITY_PublicKey *pkey); | |||
59 | */ | 59 | */ |
60 | char * | 60 | char * |
61 | DID_key_convert_gnunet_to_multibase_base64 (struct | 61 | DID_key_convert_gnunet_to_multibase_base64 (struct |
62 | GNUNET_IDENTITY_PublicKey *); | 62 | GNUNET_CRYPTO_PublicKey *); |
63 | 63 | ||
64 | /** | 64 | /** |
65 | * @brief Generate the default DID document for a GNUNET public key | 65 | * @brief Generate the default DID document for a GNUNET public key |
66 | */ | 66 | */ |
67 | char * | 67 | char * |
68 | DID_pkey_to_did_document (struct GNUNET_IDENTITY_PublicKey *pkey); | 68 | DID_pkey_to_did_document (struct GNUNET_CRYPTO_PublicKey *pkey); |
69 | 69 | ||
70 | /** | 70 | /** |
71 | * @brief Generate the default DID document for a GNUNET ego | 71 | * @brief Generate the default DID document for a GNUNET ego |
diff --git a/src/reclaim/did_misc.c b/src/reclaim/did_misc.c index 44b72a69f..32b127b2b 100644 --- a/src/reclaim/did_misc.c +++ b/src/reclaim/did_misc.c | |||
@@ -33,14 +33,14 @@ | |||
33 | char* | 33 | char* |
34 | DID_ego_to_did (struct GNUNET_IDENTITY_Ego *ego) | 34 | DID_ego_to_did (struct GNUNET_IDENTITY_Ego *ego) |
35 | { | 35 | { |
36 | struct GNUNET_IDENTITY_PublicKey pkey; // Get Public key | 36 | struct GNUNET_CRYPTO_PublicKey pkey; // Get Public key |
37 | char *pkey_str; | 37 | char *pkey_str; |
38 | char *did_str; | 38 | char *did_str; |
39 | size_t pkey_len; | 39 | size_t pkey_len; |
40 | 40 | ||
41 | GNUNET_IDENTITY_ego_get_public_key (ego, &pkey); | 41 | GNUNET_IDENTITY_ego_get_public_key (ego, &pkey); |
42 | 42 | ||
43 | pkey_str = GNUNET_IDENTITY_public_key_to_string (&pkey); | 43 | pkey_str = GNUNET_CRYPTO_public_key_to_string (&pkey); |
44 | GNUNET_asprintf (&did_str, "%s%s", | 44 | GNUNET_asprintf (&did_str, "%s%s", |
45 | GNUNET_RECLAIM_DID_METHOD_PREFIX, | 45 | GNUNET_RECLAIM_DID_METHOD_PREFIX, |
46 | pkey_str); | 46 | pkey_str); |
@@ -51,7 +51,7 @@ DID_ego_to_did (struct GNUNET_IDENTITY_Ego *ego) | |||
51 | 51 | ||
52 | enum GNUNET_GenericReturnValue | 52 | enum GNUNET_GenericReturnValue |
53 | DID_public_key_from_did (const char* did, | 53 | DID_public_key_from_did (const char* did, |
54 | struct GNUNET_IDENTITY_PublicKey *pk) | 54 | struct GNUNET_CRYPTO_PublicKey *pk) |
55 | { | 55 | { |
56 | /* FIXME-MSC: I suggest introducing a | 56 | /* FIXME-MSC: I suggest introducing a |
57 | * #define MAX_DID_LENGTH <something> | 57 | * #define MAX_DID_LENGTH <something> |
@@ -60,7 +60,7 @@ DID_public_key_from_did (const char* did, | |||
60 | char pkey_str[59]; | 60 | char pkey_str[59]; |
61 | 61 | ||
62 | if ((1 != (sscanf (did, GNUNET_RECLAIM_DID_METHOD_PREFIX"%58s", pkey_str))) || | 62 | if ((1 != (sscanf (did, GNUNET_RECLAIM_DID_METHOD_PREFIX"%58s", pkey_str))) || |
63 | (GNUNET_OK != GNUNET_IDENTITY_public_key_from_string (pkey_str, pk))) | 63 | (GNUNET_OK != GNUNET_CRYPTO_public_key_from_string (pkey_str, pk))) |
64 | { | 64 | { |
65 | return GNUNET_SYSERR; | 65 | return GNUNET_SYSERR; |
66 | } | 66 | } |
diff --git a/src/reclaim/gnunet-did.c b/src/reclaim/gnunet-did.c index 1f91e0ee2..e88a3671e 100644 --- a/src/reclaim/gnunet-did.c +++ b/src/reclaim/gnunet-did.c | |||
@@ -263,7 +263,7 @@ remove_did_document_namestore_cb (void *cls, enum GNUNET_ErrorCode ec) | |||
263 | static void | 263 | static void |
264 | remove_did_document_ego_lookup_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) | 264 | remove_did_document_ego_lookup_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) |
265 | { | 265 | { |
266 | const struct GNUNET_IDENTITY_PrivateKey *skey = | 266 | const struct GNUNET_CRYPTO_PrivateKey *skey = |
267 | GNUNET_IDENTITY_ego_get_private_key (ego); | 267 | GNUNET_IDENTITY_ego_get_private_key (ego); |
268 | 268 | ||
269 | GNUNET_NAMESTORE_records_store (namestore_handle, | 269 | GNUNET_NAMESTORE_records_store (namestore_handle, |
@@ -335,7 +335,7 @@ create_did_cb (enum GNUNET_GenericReturnValue status, void *cls) | |||
335 | */ | 335 | */ |
336 | static void | 336 | static void |
337 | create_did_ego_create_cb (void *cls, | 337 | create_did_ego_create_cb (void *cls, |
338 | const struct GNUNET_IDENTITY_PrivateKey *pk, | 338 | const struct GNUNET_CRYPTO_PrivateKey *pk, |
339 | enum GNUNET_ErrorCode ec) | 339 | enum GNUNET_ErrorCode ec) |
340 | { | 340 | { |
341 | if (GNUNET_EC_NONE != ec) | 341 | if (GNUNET_EC_NONE != ec) |
@@ -366,7 +366,7 @@ create_did_ego_lockup_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
366 | GNUNET_IDENTITY_create (identity_handle, | 366 | GNUNET_IDENTITY_create (identity_handle, |
367 | egoname, | 367 | egoname, |
368 | NULL, | 368 | NULL, |
369 | GNUNET_IDENTITY_TYPE_EDDSA, | 369 | GNUNET_PUBLIC_KEY_TYPE_EDDSA, |
370 | &create_did_ego_create_cb, | 370 | &create_did_ego_create_cb, |
371 | egoname); | 371 | egoname); |
372 | } | 372 | } |
diff --git a/src/reclaim/gnunet-reclaim.c b/src/reclaim/gnunet-reclaim.c index cb8703495..efb2c2902 100644 --- a/src/reclaim/gnunet-reclaim.c +++ b/src/reclaim/gnunet-reclaim.c | |||
@@ -152,12 +152,12 @@ static struct GNUNET_RECLAIM_TicketIterator *ticket_iterator; | |||
152 | /** | 152 | /** |
153 | * ego private key | 153 | * ego private key |
154 | */ | 154 | */ |
155 | static const struct GNUNET_IDENTITY_PrivateKey *pkey; | 155 | static const struct GNUNET_CRYPTO_PrivateKey *pkey; |
156 | 156 | ||
157 | /** | 157 | /** |
158 | * rp public key | 158 | * rp public key |
159 | */ | 159 | */ |
160 | static struct GNUNET_IDENTITY_PublicKey rp_key; | 160 | static struct GNUNET_CRYPTO_PublicKey rp_key; |
161 | 161 | ||
162 | /** | 162 | /** |
163 | * Ticket to consume | 163 | * Ticket to consume |
@@ -264,7 +264,7 @@ store_cont (void *cls, int32_t success, const char *emsg) | |||
264 | 264 | ||
265 | static void | 265 | static void |
266 | process_attrs (void *cls, | 266 | process_attrs (void *cls, |
267 | const struct GNUNET_IDENTITY_PublicKey *identity, | 267 | const struct GNUNET_CRYPTO_PublicKey *identity, |
268 | const struct GNUNET_RECLAIM_Attribute *attr, | 268 | const struct GNUNET_RECLAIM_Attribute *attr, |
269 | const struct GNUNET_RECLAIM_Presentation *presentation) | 269 | const struct GNUNET_RECLAIM_Presentation *presentation) |
270 | { | 270 | { |
@@ -349,7 +349,7 @@ ticket_iter (void *cls, const struct GNUNET_RECLAIM_Ticket *ticket) | |||
349 | aud = | 349 | aud = |
350 | GNUNET_STRINGS_data_to_string_alloc (&ticket->audience, | 350 | GNUNET_STRINGS_data_to_string_alloc (&ticket->audience, |
351 | sizeof(struct | 351 | sizeof(struct |
352 | GNUNET_IDENTITY_PublicKey)); | 352 | GNUNET_CRYPTO_PublicKey)); |
353 | ref = GNUNET_STRINGS_data_to_string_alloc (&ticket->rnd, sizeof(ticket->rnd)); | 353 | ref = GNUNET_STRINGS_data_to_string_alloc (&ticket->rnd, sizeof(ticket->rnd)); |
354 | tkt = | 354 | tkt = |
355 | GNUNET_STRINGS_data_to_string_alloc (ticket, | 355 | GNUNET_STRINGS_data_to_string_alloc (ticket, |
@@ -514,7 +514,7 @@ iter_finished (void *cls) | |||
514 | 514 | ||
515 | static void | 515 | static void |
516 | iter_cb (void *cls, | 516 | iter_cb (void *cls, |
517 | const struct GNUNET_IDENTITY_PublicKey *identity, | 517 | const struct GNUNET_CRYPTO_PublicKey *identity, |
518 | const struct GNUNET_RECLAIM_Attribute *attr) | 518 | const struct GNUNET_RECLAIM_Attribute *attr) |
519 | { | 519 | { |
520 | struct GNUNET_RECLAIM_AttributeListEntry *le; | 520 | struct GNUNET_RECLAIM_AttributeListEntry *le; |
@@ -657,7 +657,7 @@ cred_iter_finished (void *cls) | |||
657 | 657 | ||
658 | static void | 658 | static void |
659 | cred_iter_cb (void *cls, | 659 | cred_iter_cb (void *cls, |
660 | const struct GNUNET_IDENTITY_PublicKey *identity, | 660 | const struct GNUNET_CRYPTO_PublicKey *identity, |
661 | const struct GNUNET_RECLAIM_Credential *cred) | 661 | const struct GNUNET_RECLAIM_Credential *cred) |
662 | { | 662 | { |
663 | char *cred_str; | 663 | char *cred_str; |
@@ -738,7 +738,7 @@ start_process () | |||
738 | 738 | ||
739 | if ((NULL != rp) && | 739 | if ((NULL != rp) && |
740 | (GNUNET_OK != | 740 | (GNUNET_OK != |
741 | GNUNET_IDENTITY_public_key_from_string (rp, &rp_key)) ) | 741 | GNUNET_CRYPTO_public_key_from_string (rp, &rp_key)) ) |
742 | { | 742 | { |
743 | fprintf (stderr, "%s is not a public key!\n", rp); | 743 | fprintf (stderr, "%s is not a public key!\n", rp); |
744 | cleanup_task = GNUNET_SCHEDULER_add_now (&do_cleanup, NULL); | 744 | cleanup_task = GNUNET_SCHEDULER_add_now (&do_cleanup, NULL); |
diff --git a/src/reclaim/gnunet-service-reclaim.c b/src/reclaim/gnunet-service-reclaim.c index 8b468fc8e..47a86a3e8 100644 --- a/src/reclaim/gnunet-service-reclaim.c +++ b/src/reclaim/gnunet-service-reclaim.c | |||
@@ -110,7 +110,7 @@ struct Iterator | |||
110 | /** | 110 | /** |
111 | * Key of the zone we are iterating over. | 111 | * Key of the zone we are iterating over. |
112 | */ | 112 | */ |
113 | struct GNUNET_IDENTITY_PrivateKey identity; | 113 | struct GNUNET_CRYPTO_PrivateKey identity; |
114 | 114 | ||
115 | /** | 115 | /** |
116 | * Namestore iterator | 116 | * Namestore iterator |
@@ -266,7 +266,7 @@ struct AttributeDeleteHandle | |||
266 | /** | 266 | /** |
267 | * Identity | 267 | * Identity |
268 | */ | 268 | */ |
269 | struct GNUNET_IDENTITY_PrivateKey identity; | 269 | struct GNUNET_CRYPTO_PrivateKey identity; |
270 | 270 | ||
271 | 271 | ||
272 | /** | 272 | /** |
@@ -344,12 +344,12 @@ struct AttributeStoreHandle | |||
344 | /** | 344 | /** |
345 | * Identity | 345 | * Identity |
346 | */ | 346 | */ |
347 | struct GNUNET_IDENTITY_PrivateKey identity; | 347 | struct GNUNET_CRYPTO_PrivateKey identity; |
348 | 348 | ||
349 | /** | 349 | /** |
350 | * Identity pubkey | 350 | * Identity pubkey |
351 | */ | 351 | */ |
352 | struct GNUNET_IDENTITY_PublicKey identity_pkey; | 352 | struct GNUNET_CRYPTO_PublicKey identity_pkey; |
353 | 353 | ||
354 | /** | 354 | /** |
355 | * QueueEntry | 355 | * QueueEntry |
@@ -771,8 +771,8 @@ handle_issue_ticket_message (void *cls, const struct IssueTicketMessage *im) | |||
771 | struct IdpClient *idp = cls; | 771 | struct IdpClient *idp = cls; |
772 | struct GNUNET_RECLAIM_AttributeList *attrs; | 772 | struct GNUNET_RECLAIM_AttributeList *attrs; |
773 | struct GNUNET_RECLAIM_AttributeListEntry *le; | 773 | struct GNUNET_RECLAIM_AttributeListEntry *le; |
774 | struct GNUNET_IDENTITY_PrivateKey identity; | 774 | struct GNUNET_CRYPTO_PrivateKey identity; |
775 | struct GNUNET_IDENTITY_PublicKey rp; | 775 | struct GNUNET_CRYPTO_PublicKey rp; |
776 | size_t attrs_len; | 776 | size_t attrs_len; |
777 | size_t key_len; | 777 | size_t key_len; |
778 | size_t pkey_len; | 778 | size_t pkey_len; |
@@ -783,7 +783,7 @@ handle_issue_ticket_message (void *cls, const struct IssueTicketMessage *im) | |||
783 | key_len = ntohs (im->key_len); | 783 | key_len = ntohs (im->key_len); |
784 | buf = (char *) &im[1]; | 784 | buf = (char *) &im[1]; |
785 | if ((GNUNET_SYSERR == | 785 | if ((GNUNET_SYSERR == |
786 | GNUNET_IDENTITY_read_private_key_from_buffer (buf, key_len, | 786 | GNUNET_CRYPTO_read_private_key_from_buffer (buf, key_len, |
787 | &identity, &read)) || | 787 | &identity, &read)) || |
788 | (read != key_len)) | 788 | (read != key_len)) |
789 | { | 789 | { |
@@ -795,7 +795,7 @@ handle_issue_ticket_message (void *cls, const struct IssueTicketMessage *im) | |||
795 | buf += read; | 795 | buf += read; |
796 | pkey_len = ntohs (im->pkey_len); | 796 | pkey_len = ntohs (im->pkey_len); |
797 | if ((GNUNET_SYSERR == | 797 | if ((GNUNET_SYSERR == |
798 | GNUNET_IDENTITY_read_public_key_from_buffer (buf, pkey_len, | 798 | GNUNET_CRYPTO_read_public_key_from_buffer (buf, pkey_len, |
799 | &rp, &read)) || | 799 | &rp, &read)) || |
800 | (read != pkey_len)) | 800 | (read != pkey_len)) |
801 | { | 801 | { |
@@ -890,7 +890,7 @@ handle_revoke_ticket_message (void *cls, const struct RevokeTicketMessage *rm) | |||
890 | { | 890 | { |
891 | struct TicketRevocationOperation *rop; | 891 | struct TicketRevocationOperation *rop; |
892 | struct IdpClient *idp = cls; | 892 | struct IdpClient *idp = cls; |
893 | struct GNUNET_IDENTITY_PrivateKey identity; | 893 | struct GNUNET_CRYPTO_PrivateKey identity; |
894 | struct GNUNET_RECLAIM_Ticket ticket; | 894 | struct GNUNET_RECLAIM_Ticket ticket; |
895 | size_t key_len; | 895 | size_t key_len; |
896 | size_t tkt_len; | 896 | size_t tkt_len; |
@@ -901,7 +901,7 @@ handle_revoke_ticket_message (void *cls, const struct RevokeTicketMessage *rm) | |||
901 | key_len = ntohs (rm->key_len); | 901 | key_len = ntohs (rm->key_len); |
902 | buf = (char *) &rm[1]; | 902 | buf = (char *) &rm[1]; |
903 | if ((GNUNET_SYSERR == | 903 | if ((GNUNET_SYSERR == |
904 | GNUNET_IDENTITY_read_private_key_from_buffer (buf, key_len, | 904 | GNUNET_CRYPTO_read_private_key_from_buffer (buf, key_len, |
905 | &identity, &read)) || | 905 | &identity, &read)) || |
906 | (read != key_len)) | 906 | (read != key_len)) |
907 | { | 907 | { |
@@ -943,7 +943,7 @@ handle_revoke_ticket_message (void *cls, const struct RevokeTicketMessage *rm) | |||
943 | */ | 943 | */ |
944 | static void | 944 | static void |
945 | consume_result_cb (void *cls, | 945 | consume_result_cb (void *cls, |
946 | const struct GNUNET_IDENTITY_PublicKey *identity, | 946 | const struct GNUNET_CRYPTO_PublicKey *identity, |
947 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 947 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
948 | const struct GNUNET_RECLAIM_PresentationList *presentations, | 948 | const struct GNUNET_RECLAIM_PresentationList *presentations, |
949 | int32_t success, | 949 | int32_t success, |
@@ -965,7 +965,7 @@ consume_result_cb (void *cls, | |||
965 | attrs_len = GNUNET_RECLAIM_attribute_list_serialize_get_size (attrs); | 965 | attrs_len = GNUNET_RECLAIM_attribute_list_serialize_get_size (attrs); |
966 | pres_len = GNUNET_RECLAIM_presentation_list_serialize_get_size ( | 966 | pres_len = GNUNET_RECLAIM_presentation_list_serialize_get_size ( |
967 | presentations); | 967 | presentations); |
968 | key_len = GNUNET_IDENTITY_public_key_get_length (identity); | 968 | key_len = GNUNET_CRYPTO_public_key_get_length (identity); |
969 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 969 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
970 | "Sending CONSUME_TICKET_RESULT message\n"); | 970 | "Sending CONSUME_TICKET_RESULT message\n"); |
971 | env = GNUNET_MQ_msg_extra (crm, | 971 | env = GNUNET_MQ_msg_extra (crm, |
@@ -977,7 +977,7 @@ consume_result_cb (void *cls, | |||
977 | crm->key_len = htons (key_len); | 977 | crm->key_len = htons (key_len); |
978 | crm->result = htons (success); | 978 | crm->result = htons (success); |
979 | data_tmp = (char *) &crm[1]; | 979 | data_tmp = (char *) &crm[1]; |
980 | written = GNUNET_IDENTITY_write_public_key_to_buffer (identity, | 980 | written = GNUNET_CRYPTO_write_public_key_to_buffer (identity, |
981 | data_tmp, | 981 | data_tmp, |
982 | key_len); | 982 | key_len); |
983 | GNUNET_assert (0 <= written); | 983 | GNUNET_assert (0 <= written); |
@@ -1025,7 +1025,7 @@ handle_consume_ticket_message (void *cls, const struct ConsumeTicketMessage *cm) | |||
1025 | { | 1025 | { |
1026 | struct ConsumeTicketOperation *cop; | 1026 | struct ConsumeTicketOperation *cop; |
1027 | struct IdpClient *idp = cls; | 1027 | struct IdpClient *idp = cls; |
1028 | struct GNUNET_IDENTITY_PrivateKey identity; | 1028 | struct GNUNET_CRYPTO_PrivateKey identity; |
1029 | struct GNUNET_RECLAIM_Ticket ticket; | 1029 | struct GNUNET_RECLAIM_Ticket ticket; |
1030 | size_t key_len; | 1030 | size_t key_len; |
1031 | size_t tkt_len; | 1031 | size_t tkt_len; |
@@ -1036,7 +1036,7 @@ handle_consume_ticket_message (void *cls, const struct ConsumeTicketMessage *cm) | |||
1036 | key_len = ntohs (cm->key_len); | 1036 | key_len = ntohs (cm->key_len); |
1037 | buf = (char *) &cm[1]; | 1037 | buf = (char *) &cm[1]; |
1038 | if ((GNUNET_SYSERR == | 1038 | if ((GNUNET_SYSERR == |
1039 | GNUNET_IDENTITY_read_private_key_from_buffer (buf, key_len, | 1039 | GNUNET_CRYPTO_read_private_key_from_buffer (buf, key_len, |
1040 | &identity, &read)) || | 1040 | &identity, &read)) || |
1041 | (read != key_len)) | 1041 | (read != key_len)) |
1042 | { | 1042 | { |
@@ -1188,7 +1188,7 @@ handle_attribute_store_message (void *cls, | |||
1188 | { | 1188 | { |
1189 | struct AttributeStoreHandle *ash; | 1189 | struct AttributeStoreHandle *ash; |
1190 | struct IdpClient *idp = cls; | 1190 | struct IdpClient *idp = cls; |
1191 | struct GNUNET_IDENTITY_PrivateKey identity; | 1191 | struct GNUNET_CRYPTO_PrivateKey identity; |
1192 | size_t data_len; | 1192 | size_t data_len; |
1193 | size_t key_len; | 1193 | size_t key_len; |
1194 | size_t read; | 1194 | size_t read; |
@@ -1200,7 +1200,7 @@ handle_attribute_store_message (void *cls, | |||
1200 | key_len = ntohs (sam->key_len); | 1200 | key_len = ntohs (sam->key_len); |
1201 | buf = (char *) &sam[1]; | 1201 | buf = (char *) &sam[1]; |
1202 | if ((GNUNET_SYSERR == | 1202 | if ((GNUNET_SYSERR == |
1203 | GNUNET_IDENTITY_read_private_key_from_buffer (buf, key_len, | 1203 | GNUNET_CRYPTO_read_private_key_from_buffer (buf, key_len, |
1204 | &identity, &read)) || | 1204 | &identity, &read)) || |
1205 | (read != key_len)) | 1205 | (read != key_len)) |
1206 | { | 1206 | { |
@@ -1218,7 +1218,7 @@ handle_attribute_store_message (void *cls, | |||
1218 | ash->r_id = ntohl (sam->id); | 1218 | ash->r_id = ntohl (sam->id); |
1219 | ash->identity = identity; | 1219 | ash->identity = identity; |
1220 | ash->exp.rel_value_us = GNUNET_ntohll (sam->exp); | 1220 | ash->exp.rel_value_us = GNUNET_ntohll (sam->exp); |
1221 | GNUNET_IDENTITY_key_get_public (&identity, &ash->identity_pkey); | 1221 | GNUNET_CRYPTO_key_get_public (&identity, &ash->identity_pkey); |
1222 | 1222 | ||
1223 | GNUNET_SERVICE_client_continue (idp->client); | 1223 | GNUNET_SERVICE_client_continue (idp->client); |
1224 | ash->client = idp; | 1224 | ash->client = idp; |
@@ -1293,7 +1293,7 @@ cred_error (void *cls) | |||
1293 | */ | 1293 | */ |
1294 | static void | 1294 | static void |
1295 | cred_add_cb (void *cls, | 1295 | cred_add_cb (void *cls, |
1296 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 1296 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
1297 | const char *label, | 1297 | const char *label, |
1298 | unsigned int rd_count, | 1298 | unsigned int rd_count, |
1299 | const struct GNUNET_GNSRECORD_Data *rd) | 1299 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1389,7 +1389,7 @@ handle_credential_store_message (void *cls, | |||
1389 | { | 1389 | { |
1390 | struct AttributeStoreHandle *ash; | 1390 | struct AttributeStoreHandle *ash; |
1391 | struct IdpClient *idp = cls; | 1391 | struct IdpClient *idp = cls; |
1392 | struct GNUNET_IDENTITY_PrivateKey identity; | 1392 | struct GNUNET_CRYPTO_PrivateKey identity; |
1393 | size_t data_len; | 1393 | size_t data_len; |
1394 | size_t key_len; | 1394 | size_t key_len; |
1395 | size_t read; | 1395 | size_t read; |
@@ -1401,7 +1401,7 @@ handle_credential_store_message (void *cls, | |||
1401 | key_len = ntohs (sam->key_len); | 1401 | key_len = ntohs (sam->key_len); |
1402 | buf = (char *) &sam[1]; | 1402 | buf = (char *) &sam[1]; |
1403 | if ((GNUNET_SYSERR == | 1403 | if ((GNUNET_SYSERR == |
1404 | GNUNET_IDENTITY_read_private_key_from_buffer (buf, key_len, | 1404 | GNUNET_CRYPTO_read_private_key_from_buffer (buf, key_len, |
1405 | &identity, &read)) || | 1405 | &identity, &read)) || |
1406 | (read != key_len)) | 1406 | (read != key_len)) |
1407 | { | 1407 | { |
@@ -1418,7 +1418,7 @@ handle_credential_store_message (void *cls, | |||
1418 | ash->r_id = ntohl (sam->id); | 1418 | ash->r_id = ntohl (sam->id); |
1419 | ash->identity = identity; | 1419 | ash->identity = identity; |
1420 | ash->exp.rel_value_us = GNUNET_ntohll (sam->exp); | 1420 | ash->exp.rel_value_us = GNUNET_ntohll (sam->exp); |
1421 | GNUNET_IDENTITY_key_get_public (&identity, &ash->identity_pkey); | 1421 | GNUNET_CRYPTO_key_get_public (&identity, &ash->identity_pkey); |
1422 | 1422 | ||
1423 | GNUNET_SERVICE_client_continue (idp->client); | 1423 | GNUNET_SERVICE_client_continue (idp->client); |
1424 | ash->client = idp; | 1424 | ash->client = idp; |
@@ -1463,7 +1463,7 @@ send_delete_response (struct AttributeDeleteHandle *adh, int32_t success) | |||
1463 | */ | 1463 | */ |
1464 | static void | 1464 | static void |
1465 | consistency_iter (void *cls, | 1465 | consistency_iter (void *cls, |
1466 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 1466 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
1467 | const char *label, | 1467 | const char *label, |
1468 | unsigned int rd_count, | 1468 | unsigned int rd_count, |
1469 | const struct GNUNET_GNSRECORD_Data *rd) | 1469 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1860,7 +1860,7 @@ handle_attribute_delete_message (void *cls, | |||
1860 | { | 1860 | { |
1861 | struct AttributeDeleteHandle *adh; | 1861 | struct AttributeDeleteHandle *adh; |
1862 | struct IdpClient *idp = cls; | 1862 | struct IdpClient *idp = cls; |
1863 | struct GNUNET_IDENTITY_PrivateKey identity; | 1863 | struct GNUNET_CRYPTO_PrivateKey identity; |
1864 | size_t data_len; | 1864 | size_t data_len; |
1865 | size_t key_len; | 1865 | size_t key_len; |
1866 | size_t read; | 1866 | size_t read; |
@@ -1872,7 +1872,7 @@ handle_attribute_delete_message (void *cls, | |||
1872 | key_len = ntohs (dam->key_len); | 1872 | key_len = ntohs (dam->key_len); |
1873 | buf = (char *) &dam[1]; | 1873 | buf = (char *) &dam[1]; |
1874 | if ((GNUNET_SYSERR == | 1874 | if ((GNUNET_SYSERR == |
1875 | GNUNET_IDENTITY_read_private_key_from_buffer (buf, key_len, | 1875 | GNUNET_CRYPTO_read_private_key_from_buffer (buf, key_len, |
1876 | &identity, &read)) || | 1876 | &identity, &read)) || |
1877 | (read != key_len)) | 1877 | (read != key_len)) |
1878 | { | 1878 | { |
@@ -1967,7 +1967,7 @@ handle_credential_delete_message (void *cls, | |||
1967 | { | 1967 | { |
1968 | struct AttributeDeleteHandle *adh; | 1968 | struct AttributeDeleteHandle *adh; |
1969 | struct IdpClient *idp = cls; | 1969 | struct IdpClient *idp = cls; |
1970 | struct GNUNET_IDENTITY_PrivateKey identity; | 1970 | struct GNUNET_CRYPTO_PrivateKey identity; |
1971 | size_t data_len; | 1971 | size_t data_len; |
1972 | size_t key_len; | 1972 | size_t key_len; |
1973 | size_t read; | 1973 | size_t read; |
@@ -1979,7 +1979,7 @@ handle_credential_delete_message (void *cls, | |||
1979 | key_len = ntohs (dam->key_len); | 1979 | key_len = ntohs (dam->key_len); |
1980 | buf = (char *) &dam[1]; | 1980 | buf = (char *) &dam[1]; |
1981 | if ((GNUNET_SYSERR == | 1981 | if ((GNUNET_SYSERR == |
1982 | GNUNET_IDENTITY_read_private_key_from_buffer (buf, key_len, | 1982 | GNUNET_CRYPTO_read_private_key_from_buffer (buf, key_len, |
1983 | &identity, &read)) || | 1983 | &identity, &read)) || |
1984 | (read != key_len)) | 1984 | (read != key_len)) |
1985 | { | 1985 | { |
@@ -2068,14 +2068,14 @@ attr_iter_error (void *cls) | |||
2068 | */ | 2068 | */ |
2069 | static void | 2069 | static void |
2070 | attr_iter_cb (void *cls, | 2070 | attr_iter_cb (void *cls, |
2071 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 2071 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
2072 | const char *label, | 2072 | const char *label, |
2073 | unsigned int rd_count, | 2073 | unsigned int rd_count, |
2074 | const struct GNUNET_GNSRECORD_Data *rd) | 2074 | const struct GNUNET_GNSRECORD_Data *rd) |
2075 | { | 2075 | { |
2076 | struct Iterator *ai = cls; | 2076 | struct Iterator *ai = cls; |
2077 | struct GNUNET_MQ_Envelope *env; | 2077 | struct GNUNET_MQ_Envelope *env; |
2078 | struct GNUNET_IDENTITY_PublicKey identity; | 2078 | struct GNUNET_CRYPTO_PublicKey identity; |
2079 | char *data_tmp; | 2079 | char *data_tmp; |
2080 | size_t key_len; | 2080 | size_t key_len; |
2081 | ssize_t written; | 2081 | ssize_t written; |
@@ -2091,8 +2091,8 @@ attr_iter_cb (void *cls, | |||
2091 | label); | 2091 | label); |
2092 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 2092 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
2093 | "Sending ATTRIBUTE_RESULT message\n"); | 2093 | "Sending ATTRIBUTE_RESULT message\n"); |
2094 | GNUNET_IDENTITY_key_get_public (zone, &identity); | 2094 | GNUNET_CRYPTO_key_get_public (zone, &identity); |
2095 | key_len = GNUNET_IDENTITY_public_key_get_length (&identity); | 2095 | key_len = GNUNET_CRYPTO_public_key_get_length (&identity); |
2096 | env = GNUNET_MQ_msg_extra (arm, | 2096 | env = GNUNET_MQ_msg_extra (arm, |
2097 | rd->data_size + key_len, | 2097 | rd->data_size + key_len, |
2098 | GNUNET_MESSAGE_TYPE_RECLAIM_ATTRIBUTE_RESULT); | 2098 | GNUNET_MESSAGE_TYPE_RECLAIM_ATTRIBUTE_RESULT); |
@@ -2100,7 +2100,7 @@ attr_iter_cb (void *cls, | |||
2100 | arm->attr_len = htons (rd->data_size); | 2100 | arm->attr_len = htons (rd->data_size); |
2101 | data_tmp = (char *) &arm[1]; | 2101 | data_tmp = (char *) &arm[1]; |
2102 | arm->pkey_len = htons (key_len); | 2102 | arm->pkey_len = htons (key_len); |
2103 | written = GNUNET_IDENTITY_write_public_key_to_buffer (&identity, | 2103 | written = GNUNET_CRYPTO_write_public_key_to_buffer (&identity, |
2104 | data_tmp, | 2104 | data_tmp, |
2105 | key_len); | 2105 | key_len); |
2106 | GNUNET_assert (0 <= written); | 2106 | GNUNET_assert (0 <= written); |
@@ -2141,7 +2141,7 @@ handle_iteration_start (void *cls, | |||
2141 | { | 2141 | { |
2142 | struct IdpClient *idp = cls; | 2142 | struct IdpClient *idp = cls; |
2143 | struct Iterator *ai; | 2143 | struct Iterator *ai; |
2144 | struct GNUNET_IDENTITY_PrivateKey identity; | 2144 | struct GNUNET_CRYPTO_PrivateKey identity; |
2145 | size_t key_len; | 2145 | size_t key_len; |
2146 | size_t read; | 2146 | size_t read; |
2147 | 2147 | ||
@@ -2149,7 +2149,7 @@ handle_iteration_start (void *cls, | |||
2149 | "Received ATTRIBUTE_ITERATION_START message\n"); | 2149 | "Received ATTRIBUTE_ITERATION_START message\n"); |
2150 | key_len = ntohs (ais_msg->key_len); | 2150 | key_len = ntohs (ais_msg->key_len); |
2151 | if ((GNUNET_SYSERR == | 2151 | if ((GNUNET_SYSERR == |
2152 | GNUNET_IDENTITY_read_private_key_from_buffer (&ais_msg[1], | 2152 | GNUNET_CRYPTO_read_private_key_from_buffer (&ais_msg[1], |
2153 | key_len, | 2153 | key_len, |
2154 | &identity, | 2154 | &identity, |
2155 | &read)) || | 2155 | &read)) || |
@@ -2298,7 +2298,7 @@ cred_iter_error (void *cls) | |||
2298 | */ | 2298 | */ |
2299 | static void | 2299 | static void |
2300 | cred_iter_cb (void *cls, | 2300 | cred_iter_cb (void *cls, |
2301 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 2301 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
2302 | const char *label, | 2302 | const char *label, |
2303 | unsigned int rd_count, | 2303 | unsigned int rd_count, |
2304 | const struct GNUNET_GNSRECORD_Data *rd) | 2304 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -2306,7 +2306,7 @@ cred_iter_cb (void *cls, | |||
2306 | struct Iterator *ai = cls; | 2306 | struct Iterator *ai = cls; |
2307 | struct GNUNET_MQ_Envelope *env; | 2307 | struct GNUNET_MQ_Envelope *env; |
2308 | struct CredentialResultMessage *arm; | 2308 | struct CredentialResultMessage *arm; |
2309 | struct GNUNET_IDENTITY_PublicKey identity; | 2309 | struct GNUNET_CRYPTO_PublicKey identity; |
2310 | char *data_tmp; | 2310 | char *data_tmp; |
2311 | size_t key_len; | 2311 | size_t key_len; |
2312 | ssize_t written; | 2312 | ssize_t written; |
@@ -2321,8 +2321,8 @@ cred_iter_cb (void *cls, | |||
2321 | label); | 2321 | label); |
2322 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 2322 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
2323 | "Sending CREDENTIAL_RESULT message\n"); | 2323 | "Sending CREDENTIAL_RESULT message\n"); |
2324 | GNUNET_IDENTITY_key_get_public (zone, &identity); | 2324 | GNUNET_CRYPTO_key_get_public (zone, &identity); |
2325 | key_len = GNUNET_IDENTITY_public_key_get_length (&identity); | 2325 | key_len = GNUNET_CRYPTO_public_key_get_length (&identity); |
2326 | env = GNUNET_MQ_msg_extra (arm, | 2326 | env = GNUNET_MQ_msg_extra (arm, |
2327 | rd->data_size + key_len, | 2327 | rd->data_size + key_len, |
2328 | GNUNET_MESSAGE_TYPE_RECLAIM_CREDENTIAL_RESULT); | 2328 | GNUNET_MESSAGE_TYPE_RECLAIM_CREDENTIAL_RESULT); |
@@ -2330,7 +2330,7 @@ cred_iter_cb (void *cls, | |||
2330 | arm->credential_len = htons (rd->data_size); | 2330 | arm->credential_len = htons (rd->data_size); |
2331 | arm->key_len = htons (key_len); | 2331 | arm->key_len = htons (key_len); |
2332 | data_tmp = (char *) &arm[1]; | 2332 | data_tmp = (char *) &arm[1]; |
2333 | written = GNUNET_IDENTITY_write_public_key_to_buffer (&identity, | 2333 | written = GNUNET_CRYPTO_write_public_key_to_buffer (&identity, |
2334 | data_tmp, | 2334 | data_tmp, |
2335 | key_len); | 2335 | key_len); |
2336 | GNUNET_assert (written >= 0); | 2336 | GNUNET_assert (written >= 0); |
@@ -2372,7 +2372,7 @@ handle_credential_iteration_start (void *cls, | |||
2372 | { | 2372 | { |
2373 | struct IdpClient *idp = cls; | 2373 | struct IdpClient *idp = cls; |
2374 | struct Iterator *ai; | 2374 | struct Iterator *ai; |
2375 | struct GNUNET_IDENTITY_PrivateKey identity; | 2375 | struct GNUNET_CRYPTO_PrivateKey identity; |
2376 | size_t key_len; | 2376 | size_t key_len; |
2377 | size_t read; | 2377 | size_t read; |
2378 | 2378 | ||
@@ -2380,7 +2380,7 @@ handle_credential_iteration_start (void *cls, | |||
2380 | "Received CREDENTIAL_ITERATION_START message\n"); | 2380 | "Received CREDENTIAL_ITERATION_START message\n"); |
2381 | key_len = ntohs (ais_msg->key_len); | 2381 | key_len = ntohs (ais_msg->key_len); |
2382 | if ((GNUNET_SYSERR == | 2382 | if ((GNUNET_SYSERR == |
2383 | GNUNET_IDENTITY_read_private_key_from_buffer (&ais_msg[1], | 2383 | GNUNET_CRYPTO_read_private_key_from_buffer (&ais_msg[1], |
2384 | key_len, | 2384 | key_len, |
2385 | &identity, | 2385 | &identity, |
2386 | &read)) || | 2386 | &read)) || |
@@ -2554,7 +2554,7 @@ handle_ticket_iteration_start ( | |||
2554 | void *cls, | 2554 | void *cls, |
2555 | const struct TicketIterationStartMessage *tis_msg) | 2555 | const struct TicketIterationStartMessage *tis_msg) |
2556 | { | 2556 | { |
2557 | struct GNUNET_IDENTITY_PrivateKey identity; | 2557 | struct GNUNET_CRYPTO_PrivateKey identity; |
2558 | struct IdpClient *client = cls; | 2558 | struct IdpClient *client = cls; |
2559 | struct TicketIteration *ti; | 2559 | struct TicketIteration *ti; |
2560 | size_t key_len; | 2560 | size_t key_len; |
@@ -2564,7 +2564,7 @@ handle_ticket_iteration_start ( | |||
2564 | "Received TICKET_ITERATION_START message\n"); | 2564 | "Received TICKET_ITERATION_START message\n"); |
2565 | key_len = ntohs (tis_msg->key_len); | 2565 | key_len = ntohs (tis_msg->key_len); |
2566 | if ((GNUNET_SYSERR == | 2566 | if ((GNUNET_SYSERR == |
2567 | GNUNET_IDENTITY_read_private_key_from_buffer (&tis_msg[1], | 2567 | GNUNET_CRYPTO_read_private_key_from_buffer (&tis_msg[1], |
2568 | key_len, | 2568 | key_len, |
2569 | &identity, | 2569 | &identity, |
2570 | &read)) || | 2570 | &read)) || |
diff --git a/src/reclaim/gnunet-service-reclaim_tickets.c b/src/reclaim/gnunet-service-reclaim_tickets.c index 0c2fadd96..689fbc429 100644 --- a/src/reclaim/gnunet-service-reclaim_tickets.c +++ b/src/reclaim/gnunet-service-reclaim_tickets.c | |||
@@ -87,12 +87,12 @@ struct RECLAIM_TICKETS_ConsumeHandle | |||
87 | /** | 87 | /** |
88 | * Audience Key | 88 | * Audience Key |
89 | */ | 89 | */ |
90 | struct GNUNET_IDENTITY_PrivateKey identity; | 90 | struct GNUNET_CRYPTO_PrivateKey identity; |
91 | 91 | ||
92 | /** | 92 | /** |
93 | * Audience Key | 93 | * Audience Key |
94 | */ | 94 | */ |
95 | struct GNUNET_IDENTITY_PublicKey identity_pub; | 95 | struct GNUNET_CRYPTO_PublicKey identity_pub; |
96 | 96 | ||
97 | /** | 97 | /** |
98 | * Lookup DLL | 98 | * Lookup DLL |
@@ -181,7 +181,7 @@ struct TicketIssueHandle | |||
181 | /** | 181 | /** |
182 | * Issuer Key | 182 | * Issuer Key |
183 | */ | 183 | */ |
184 | struct GNUNET_IDENTITY_PrivateKey identity; | 184 | struct GNUNET_CRYPTO_PrivateKey identity; |
185 | 185 | ||
186 | /** | 186 | /** |
187 | * Ticket to issue | 187 | * Ticket to issue |
@@ -264,7 +264,7 @@ struct RECLAIM_TICKETS_RevokeHandle | |||
264 | /** | 264 | /** |
265 | * Issuer Key | 265 | * Issuer Key |
266 | */ | 266 | */ |
267 | struct GNUNET_IDENTITY_PrivateKey identity; | 267 | struct GNUNET_CRYPTO_PrivateKey identity; |
268 | 268 | ||
269 | /** | 269 | /** |
270 | * Callback | 270 | * Callback |
@@ -491,7 +491,7 @@ rvk_ticket_update_finished (void *cls) | |||
491 | */ | 491 | */ |
492 | static void | 492 | static void |
493 | rvk_ticket_update (void *cls, | 493 | rvk_ticket_update (void *cls, |
494 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 494 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
495 | const char *label, | 495 | const char *label, |
496 | unsigned int rd_count, | 496 | unsigned int rd_count, |
497 | const struct GNUNET_GNSRECORD_Data *rd) | 497 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -667,7 +667,7 @@ move_attr_finished (void *cls, enum GNUNET_ErrorCode ec) | |||
667 | */ | 667 | */ |
668 | static void | 668 | static void |
669 | rvk_move_attr_cb (void *cls, | 669 | rvk_move_attr_cb (void *cls, |
670 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 670 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
671 | const char *label, | 671 | const char *label, |
672 | unsigned int rd_count, | 672 | unsigned int rd_count, |
673 | const struct GNUNET_GNSRECORD_Data *rd) | 673 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -845,7 +845,7 @@ remove_ticket_cont (void *cls, enum GNUNET_ErrorCode ec) | |||
845 | */ | 845 | */ |
846 | static void | 846 | static void |
847 | revoke_attrs_cb (void *cls, | 847 | revoke_attrs_cb (void *cls, |
848 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 848 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
849 | const char *label, | 849 | const char *label, |
850 | unsigned int rd_count, | 850 | unsigned int rd_count, |
851 | const struct GNUNET_GNSRECORD_Data *rd) | 851 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -908,7 +908,7 @@ rvk_attrs_err_cb (void *cls) | |||
908 | */ | 908 | */ |
909 | struct RECLAIM_TICKETS_RevokeHandle * | 909 | struct RECLAIM_TICKETS_RevokeHandle * |
910 | RECLAIM_TICKETS_revoke (const struct GNUNET_RECLAIM_Ticket *ticket, | 910 | RECLAIM_TICKETS_revoke (const struct GNUNET_RECLAIM_Ticket *ticket, |
911 | const struct GNUNET_IDENTITY_PrivateKey *identity, | 911 | const struct GNUNET_CRYPTO_PrivateKey *identity, |
912 | RECLAIM_TICKETS_RevokeCallback cb, | 912 | RECLAIM_TICKETS_RevokeCallback cb, |
913 | void *cb_cls) | 913 | void *cb_cls) |
914 | { | 914 | { |
@@ -920,7 +920,7 @@ RECLAIM_TICKETS_revoke (const struct GNUNET_RECLAIM_Ticket *ticket, | |||
920 | rvk->cb_cls = cb_cls; | 920 | rvk->cb_cls = cb_cls; |
921 | rvk->identity = *identity; | 921 | rvk->identity = *identity; |
922 | rvk->ticket = *ticket; | 922 | rvk->ticket = *ticket; |
923 | GNUNET_IDENTITY_key_get_public (&rvk->identity, &rvk->ticket.identity); | 923 | GNUNET_CRYPTO_key_get_public (&rvk->identity, &rvk->ticket.identity); |
924 | /** Get shared attributes **/ | 924 | /** Get shared attributes **/ |
925 | label = GNUNET_STRINGS_data_to_string_alloc (&ticket->rnd, | 925 | label = GNUNET_STRINGS_data_to_string_alloc (&ticket->rnd, |
926 | sizeof(ticket->rnd)); | 926 | sizeof(ticket->rnd)); |
@@ -1179,7 +1179,7 @@ lookup_authz_cb (void *cls, | |||
1179 | * @return handle to the operation | 1179 | * @return handle to the operation |
1180 | */ | 1180 | */ |
1181 | struct RECLAIM_TICKETS_ConsumeHandle * | 1181 | struct RECLAIM_TICKETS_ConsumeHandle * |
1182 | RECLAIM_TICKETS_consume (const struct GNUNET_IDENTITY_PrivateKey *id, | 1182 | RECLAIM_TICKETS_consume (const struct GNUNET_CRYPTO_PrivateKey *id, |
1183 | const struct GNUNET_RECLAIM_Ticket *ticket, | 1183 | const struct GNUNET_RECLAIM_Ticket *ticket, |
1184 | RECLAIM_TICKETS_ConsumeCallback cb, | 1184 | RECLAIM_TICKETS_ConsumeCallback cb, |
1185 | void *cb_cls) | 1185 | void *cb_cls) |
@@ -1190,7 +1190,7 @@ RECLAIM_TICKETS_consume (const struct GNUNET_IDENTITY_PrivateKey *id, | |||
1190 | cth = GNUNET_new (struct RECLAIM_TICKETS_ConsumeHandle); | 1190 | cth = GNUNET_new (struct RECLAIM_TICKETS_ConsumeHandle); |
1191 | 1191 | ||
1192 | cth->identity = *id; | 1192 | cth->identity = *id; |
1193 | GNUNET_IDENTITY_key_get_public (&cth->identity, &cth->identity_pub); | 1193 | GNUNET_CRYPTO_key_get_public (&cth->identity, &cth->identity_pub); |
1194 | cth->attrs = GNUNET_new (struct GNUNET_RECLAIM_AttributeList); | 1194 | cth->attrs = GNUNET_new (struct GNUNET_RECLAIM_AttributeList); |
1195 | cth->presentations = GNUNET_new (struct GNUNET_RECLAIM_PresentationList); | 1195 | cth->presentations = GNUNET_new (struct GNUNET_RECLAIM_PresentationList); |
1196 | cth->ticket = *ticket; | 1196 | cth->ticket = *ticket; |
@@ -1199,7 +1199,7 @@ RECLAIM_TICKETS_consume (const struct GNUNET_IDENTITY_PrivateKey *id, | |||
1199 | label = | 1199 | label = |
1200 | GNUNET_STRINGS_data_to_string_alloc (&cth->ticket.rnd, | 1200 | GNUNET_STRINGS_data_to_string_alloc (&cth->ticket.rnd, |
1201 | sizeof(cth->ticket.rnd)); | 1201 | sizeof(cth->ticket.rnd)); |
1202 | char *str = GNUNET_IDENTITY_public_key_to_string (&cth->ticket.identity); | 1202 | char *str = GNUNET_CRYPTO_public_key_to_string (&cth->ticket.identity); |
1203 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1203 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1204 | "Looking for AuthZ info under %s in %s\n", | 1204 | "Looking for AuthZ info under %s in %s\n", |
1205 | label, str); | 1205 | label, str); |
@@ -1397,10 +1397,10 @@ issue_ticket (struct TicketIssueHandle *ih) | |||
1397 | label = | 1397 | label = |
1398 | GNUNET_STRINGS_data_to_string_alloc (&ih->ticket.rnd, | 1398 | GNUNET_STRINGS_data_to_string_alloc (&ih->ticket.rnd, |
1399 | sizeof(ih->ticket.rnd)); | 1399 | sizeof(ih->ticket.rnd)); |
1400 | struct GNUNET_IDENTITY_PublicKey pub; | 1400 | struct GNUNET_CRYPTO_PublicKey pub; |
1401 | GNUNET_IDENTITY_key_get_public (&ih->identity, | 1401 | GNUNET_CRYPTO_key_get_public (&ih->identity, |
1402 | &pub); | 1402 | &pub); |
1403 | char *str = GNUNET_IDENTITY_public_key_to_string (&pub); | 1403 | char *str = GNUNET_CRYPTO_public_key_to_string (&pub); |
1404 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1404 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1405 | "Storing AuthZ information under %s in %s\n", label, str); | 1405 | "Storing AuthZ information under %s in %s\n", label, str); |
1406 | GNUNET_free (str); | 1406 | GNUNET_free (str); |
@@ -1466,7 +1466,7 @@ filter_tickets_error_cb (void *cls) | |||
1466 | */ | 1466 | */ |
1467 | static void | 1467 | static void |
1468 | filter_tickets_cb (void *cls, | 1468 | filter_tickets_cb (void *cls, |
1469 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 1469 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
1470 | const char *label, | 1470 | const char *label, |
1471 | unsigned int rd_count, | 1471 | unsigned int rd_count, |
1472 | const struct GNUNET_GNSRECORD_Data *rd) | 1472 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1512,11 +1512,11 @@ filter_tickets_cb (void *cls, | |||
1512 | continue; | 1512 | continue; |
1513 | } | 1513 | } |
1514 | // cmp audience | 1514 | // cmp audience |
1515 | // FIXME this is ugly, GNUNET_IDENTITY_PublicKey cannot be compared | 1515 | // FIXME this is ugly, GNUNET_CRYPTO_PublicKey cannot be compared |
1516 | // like this | 1516 | // like this |
1517 | if (0 == memcmp (&tih->ticket.audience, | 1517 | if (0 == memcmp (&tih->ticket.audience, |
1518 | &ticket.audience, | 1518 | &ticket.audience, |
1519 | sizeof(struct GNUNET_IDENTITY_PublicKey))) | 1519 | sizeof(struct GNUNET_CRYPTO_PublicKey))) |
1520 | { | 1520 | { |
1521 | tih->ticket = ticket; | 1521 | tih->ticket = ticket; |
1522 | ticket_found = GNUNET_YES; | 1522 | ticket_found = GNUNET_YES; |
@@ -1631,7 +1631,7 @@ filter_tickets_finished_cb (void *cls) | |||
1631 | { | 1631 | { |
1632 | struct TicketIssueHandle *tih = cls; | 1632 | struct TicketIssueHandle *tih = cls; |
1633 | 1633 | ||
1634 | GNUNET_IDENTITY_key_get_public (&tih->identity, &tih->ticket.identity); | 1634 | GNUNET_CRYPTO_key_get_public (&tih->identity, &tih->ticket.identity); |
1635 | GNUNET_RECLAIM_id_generate (&tih->ticket.rnd); | 1635 | GNUNET_RECLAIM_id_generate (&tih->ticket.rnd); |
1636 | issue_ticket (tih); | 1636 | issue_ticket (tih); |
1637 | } | 1637 | } |
@@ -1649,9 +1649,9 @@ filter_tickets_finished_cb (void *cls) | |||
1649 | * FIXME: Return handle?? | 1649 | * FIXME: Return handle?? |
1650 | */ | 1650 | */ |
1651 | void | 1651 | void |
1652 | RECLAIM_TICKETS_issue (const struct GNUNET_IDENTITY_PrivateKey *identity, | 1652 | RECLAIM_TICKETS_issue (const struct GNUNET_CRYPTO_PrivateKey *identity, |
1653 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 1653 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
1654 | const struct GNUNET_IDENTITY_PublicKey *audience, | 1654 | const struct GNUNET_CRYPTO_PublicKey *audience, |
1655 | RECLAIM_TICKETS_TicketResult cb, | 1655 | RECLAIM_TICKETS_TicketResult cb, |
1656 | void *cb_cls) | 1656 | void *cb_cls) |
1657 | { | 1657 | { |
@@ -1709,7 +1709,7 @@ cleanup_iter (struct RECLAIM_TICKETS_Iterator *iter) | |||
1709 | */ | 1709 | */ |
1710 | static void | 1710 | static void |
1711 | collect_tickets_cb (void *cls, | 1711 | collect_tickets_cb (void *cls, |
1712 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 1712 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
1713 | const char *label, | 1713 | const char *label, |
1714 | unsigned int rd_count, | 1714 | unsigned int rd_count, |
1715 | const struct GNUNET_GNSRECORD_Data *rd) | 1715 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1807,7 +1807,7 @@ RECLAIM_TICKETS_iteration_stop (struct RECLAIM_TICKETS_Iterator *iter) | |||
1807 | */ | 1807 | */ |
1808 | struct RECLAIM_TICKETS_Iterator * | 1808 | struct RECLAIM_TICKETS_Iterator * |
1809 | RECLAIM_TICKETS_iteration_start ( | 1809 | RECLAIM_TICKETS_iteration_start ( |
1810 | const struct GNUNET_IDENTITY_PrivateKey *identity, | 1810 | const struct GNUNET_CRYPTO_PrivateKey *identity, |
1811 | RECLAIM_TICKETS_TicketIter cb, | 1811 | RECLAIM_TICKETS_TicketIter cb, |
1812 | void *cb_cls) | 1812 | void *cb_cls) |
1813 | { | 1813 | { |
diff --git a/src/reclaim/gnunet-service-reclaim_tickets.h b/src/reclaim/gnunet-service-reclaim_tickets.h index 9c31a6143..0ec232f49 100644 --- a/src/reclaim/gnunet-service-reclaim_tickets.h +++ b/src/reclaim/gnunet-service-reclaim_tickets.h | |||
@@ -138,7 +138,7 @@ typedef void (*RECLAIM_TICKETS_TicketResult) ( | |||
138 | */ | 138 | */ |
139 | typedef void (*RECLAIM_TICKETS_ConsumeCallback) ( | 139 | typedef void (*RECLAIM_TICKETS_ConsumeCallback) ( |
140 | void *cls, | 140 | void *cls, |
141 | const struct GNUNET_IDENTITY_PublicKey *identity, | 141 | const struct GNUNET_CRYPTO_PublicKey *identity, |
142 | const struct GNUNET_RECLAIM_AttributeList *attributes, | 142 | const struct GNUNET_RECLAIM_AttributeList *attributes, |
143 | const struct GNUNET_RECLAIM_PresentationList *presentations, | 143 | const struct GNUNET_RECLAIM_PresentationList *presentations, |
144 | int32_t success, | 144 | int32_t success, |
@@ -167,7 +167,7 @@ typedef void (*RECLAIM_TICKETS_RevokeCallback) (void *cls, int32_t success); | |||
167 | */ | 167 | */ |
168 | struct RECLAIM_TICKETS_RevokeHandle * | 168 | struct RECLAIM_TICKETS_RevokeHandle * |
169 | RECLAIM_TICKETS_revoke (const struct GNUNET_RECLAIM_Ticket *ticket, | 169 | RECLAIM_TICKETS_revoke (const struct GNUNET_RECLAIM_Ticket *ticket, |
170 | const struct GNUNET_IDENTITY_PrivateKey *identity, | 170 | const struct GNUNET_CRYPTO_PrivateKey *identity, |
171 | RECLAIM_TICKETS_RevokeCallback cb, | 171 | RECLAIM_TICKETS_RevokeCallback cb, |
172 | void *cb_cls); | 172 | void *cb_cls); |
173 | 173 | ||
@@ -193,7 +193,7 @@ RECLAIM_TICKETS_revoke_cancel (struct RECLAIM_TICKETS_RevokeHandle *rh); | |||
193 | * @return handle to the operation | 193 | * @return handle to the operation |
194 | */ | 194 | */ |
195 | struct RECLAIM_TICKETS_ConsumeHandle * | 195 | struct RECLAIM_TICKETS_ConsumeHandle * |
196 | RECLAIM_TICKETS_consume (const struct GNUNET_IDENTITY_PrivateKey *id, | 196 | RECLAIM_TICKETS_consume (const struct GNUNET_CRYPTO_PrivateKey *id, |
197 | const struct GNUNET_RECLAIM_Ticket *ticket, | 197 | const struct GNUNET_RECLAIM_Ticket *ticket, |
198 | RECLAIM_TICKETS_ConsumeCallback cb, | 198 | RECLAIM_TICKETS_ConsumeCallback cb, |
199 | void *cb_cls); | 199 | void *cb_cls); |
@@ -220,9 +220,9 @@ RECLAIM_TICKETS_consume_cancel (struct RECLAIM_TICKETS_ConsumeHandle *cth); | |||
220 | * FIXME: Return handle?? | 220 | * FIXME: Return handle?? |
221 | */ | 221 | */ |
222 | void | 222 | void |
223 | RECLAIM_TICKETS_issue (const struct GNUNET_IDENTITY_PrivateKey *identity, | 223 | RECLAIM_TICKETS_issue (const struct GNUNET_CRYPTO_PrivateKey *identity, |
224 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 224 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
225 | const struct GNUNET_IDENTITY_PublicKey *audience, | 225 | const struct GNUNET_CRYPTO_PublicKey *audience, |
226 | RECLAIM_TICKETS_TicketResult cb, | 226 | RECLAIM_TICKETS_TicketResult cb, |
227 | void *cb_cls); | 227 | void *cb_cls); |
228 | 228 | ||
@@ -255,7 +255,7 @@ RECLAIM_TICKETS_iteration_stop (struct RECLAIM_TICKETS_Iterator *iter); | |||
255 | */ | 255 | */ |
256 | struct RECLAIM_TICKETS_Iterator * | 256 | struct RECLAIM_TICKETS_Iterator * |
257 | RECLAIM_TICKETS_iteration_start ( | 257 | RECLAIM_TICKETS_iteration_start ( |
258 | const struct GNUNET_IDENTITY_PrivateKey *identity, | 258 | const struct GNUNET_CRYPTO_PrivateKey *identity, |
259 | RECLAIM_TICKETS_TicketIter cb, | 259 | RECLAIM_TICKETS_TicketIter cb, |
260 | void *cb_cls); | 260 | void *cb_cls); |
261 | 261 | ||
diff --git a/src/reclaim/oidc_helper.c b/src/reclaim/oidc_helper.c index 90c33375f..a2da7312b 100644 --- a/src/reclaim/oidc_helper.c +++ b/src/reclaim/oidc_helper.c | |||
@@ -158,7 +158,7 @@ fix_base64 (char *str) | |||
158 | 158 | ||
159 | 159 | ||
160 | static json_t* | 160 | static json_t* |
161 | generate_userinfo_json (const struct GNUNET_IDENTITY_PublicKey *sub_key, | 161 | generate_userinfo_json (const struct GNUNET_CRYPTO_PublicKey *sub_key, |
162 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 162 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
163 | const struct | 163 | const struct |
164 | GNUNET_RECLAIM_PresentationList *presentations) | 164 | GNUNET_RECLAIM_PresentationList *presentations) |
@@ -184,7 +184,7 @@ generate_userinfo_json (const struct GNUNET_IDENTITY_PublicKey *sub_key, | |||
184 | subject = | 184 | subject = |
185 | GNUNET_STRINGS_data_to_string_alloc (sub_key, | 185 | GNUNET_STRINGS_data_to_string_alloc (sub_key, |
186 | sizeof(struct | 186 | sizeof(struct |
187 | GNUNET_IDENTITY_PublicKey)); | 187 | GNUNET_CRYPTO_PublicKey)); |
188 | body = json_object (); | 188 | body = json_object (); |
189 | aggr_names = json_object (); | 189 | aggr_names = json_object (); |
190 | aggr_sources = json_object (); | 190 | aggr_sources = json_object (); |
@@ -343,7 +343,7 @@ generate_userinfo_json (const struct GNUNET_IDENTITY_PublicKey *sub_key, | |||
343 | * @return Userinfo JSON | 343 | * @return Userinfo JSON |
344 | */ | 344 | */ |
345 | char * | 345 | char * |
346 | OIDC_generate_userinfo (const struct GNUNET_IDENTITY_PublicKey *sub_key, | 346 | OIDC_generate_userinfo (const struct GNUNET_CRYPTO_PublicKey *sub_key, |
347 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 347 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
348 | const struct | 348 | const struct |
349 | GNUNET_RECLAIM_PresentationList *presentations) | 349 | GNUNET_RECLAIM_PresentationList *presentations) |
@@ -359,8 +359,8 @@ OIDC_generate_userinfo (const struct GNUNET_IDENTITY_PublicKey *sub_key, | |||
359 | 359 | ||
360 | 360 | ||
361 | char * | 361 | char * |
362 | generate_id_token_body (const struct GNUNET_IDENTITY_PublicKey *aud_key, | 362 | generate_id_token_body (const struct GNUNET_CRYPTO_PublicKey *aud_key, |
363 | const struct GNUNET_IDENTITY_PublicKey *sub_key, | 363 | const struct GNUNET_CRYPTO_PublicKey *sub_key, |
364 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 364 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
365 | const struct | 365 | const struct |
366 | GNUNET_RECLAIM_PresentationList *presentations, | 366 | GNUNET_RECLAIM_PresentationList *presentations, |
@@ -387,11 +387,11 @@ generate_id_token_body (const struct GNUNET_IDENTITY_PublicKey *aud_key, | |||
387 | subject = | 387 | subject = |
388 | GNUNET_STRINGS_data_to_string_alloc (sub_key, | 388 | GNUNET_STRINGS_data_to_string_alloc (sub_key, |
389 | sizeof(struct | 389 | sizeof(struct |
390 | GNUNET_IDENTITY_PublicKey)); | 390 | GNUNET_CRYPTO_PublicKey)); |
391 | audience = | 391 | audience = |
392 | GNUNET_STRINGS_data_to_string_alloc (aud_key, | 392 | GNUNET_STRINGS_data_to_string_alloc (aud_key, |
393 | sizeof(struct | 393 | sizeof(struct |
394 | GNUNET_IDENTITY_PublicKey)); | 394 | GNUNET_CRYPTO_PublicKey)); |
395 | 395 | ||
396 | // aud REQUIRED public key client_id must be there | 396 | // aud REQUIRED public key client_id must be there |
397 | json_object_set_new (body, "aud", json_string (audience)); | 397 | json_object_set_new (body, "aud", json_string (audience)); |
@@ -424,8 +424,8 @@ generate_id_token_body (const struct GNUNET_IDENTITY_PublicKey *aud_key, | |||
424 | 424 | ||
425 | 425 | ||
426 | char * | 426 | char * |
427 | OIDC_generate_id_token_rsa (const struct GNUNET_IDENTITY_PublicKey *aud_key, | 427 | OIDC_generate_id_token_rsa (const struct GNUNET_CRYPTO_PublicKey *aud_key, |
428 | const struct GNUNET_IDENTITY_PublicKey *sub_key, | 428 | const struct GNUNET_CRYPTO_PublicKey *sub_key, |
429 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 429 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
430 | const struct | 430 | const struct |
431 | GNUNET_RECLAIM_PresentationList *presentations, | 431 | GNUNET_RECLAIM_PresentationList *presentations, |
@@ -486,8 +486,8 @@ OIDC_generate_id_token_rsa (const struct GNUNET_IDENTITY_PublicKey *aud_key, | |||
486 | * @return a new base64-encoded JWT string. | 486 | * @return a new base64-encoded JWT string. |
487 | */ | 487 | */ |
488 | char * | 488 | char * |
489 | OIDC_generate_id_token_hmac (const struct GNUNET_IDENTITY_PublicKey *aud_key, | 489 | OIDC_generate_id_token_hmac (const struct GNUNET_CRYPTO_PublicKey *aud_key, |
490 | const struct GNUNET_IDENTITY_PublicKey *sub_key, | 490 | const struct GNUNET_CRYPTO_PublicKey *sub_key, |
491 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 491 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
492 | const struct | 492 | const struct |
493 | GNUNET_RECLAIM_PresentationList *presentations, | 493 | GNUNET_RECLAIM_PresentationList *presentations, |
@@ -578,7 +578,7 @@ OIDC_generate_id_token_hmac (const struct GNUNET_IDENTITY_PublicKey *aud_key, | |||
578 | * @return a new authorization code (caller must free) | 578 | * @return a new authorization code (caller must free) |
579 | */ | 579 | */ |
580 | char * | 580 | char * |
581 | OIDC_build_authz_code (const struct GNUNET_IDENTITY_PrivateKey *issuer, | 581 | OIDC_build_authz_code (const struct GNUNET_CRYPTO_PrivateKey *issuer, |
582 | const struct GNUNET_RECLAIM_Ticket *ticket, | 582 | const struct GNUNET_RECLAIM_Ticket *ticket, |
583 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 583 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
584 | const struct | 584 | const struct |
@@ -671,7 +671,7 @@ OIDC_build_authz_code (const struct GNUNET_IDENTITY_PrivateKey *issuer, | |||
671 | // Get length | 671 | // Get length |
672 | code_payload_len = sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) | 672 | code_payload_len = sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) |
673 | + payload_len + sizeof(struct | 673 | + payload_len + sizeof(struct |
674 | GNUNET_IDENTITY_Signature); | 674 | GNUNET_CRYPTO_Signature); |
675 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 675 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
676 | "Length of data to encode: %lu\n", | 676 | "Length of data to encode: %lu\n", |
677 | code_payload_len); | 677 | code_payload_len); |
@@ -690,9 +690,9 @@ OIDC_build_authz_code (const struct GNUNET_IDENTITY_PrivateKey *issuer, | |||
690 | buf_ptr += payload_len; | 690 | buf_ptr += payload_len; |
691 | // Sign and store signature | 691 | // Sign and store signature |
692 | if (GNUNET_SYSERR == | 692 | if (GNUNET_SYSERR == |
693 | GNUNET_IDENTITY_sign_ (issuer, | 693 | GNUNET_CRYPTO_sign_ (issuer, |
694 | purpose, | 694 | purpose, |
695 | (struct GNUNET_IDENTITY_Signature *) | 695 | (struct GNUNET_CRYPTO_Signature *) |
696 | buf_ptr)) | 696 | buf_ptr)) |
697 | { | 697 | { |
698 | GNUNET_break (0); | 698 | GNUNET_break (0); |
@@ -764,7 +764,7 @@ check_code_challenge (const char *code_challenge, | |||
764 | * @return GNUNET_OK if successful, else GNUNET_SYSERR | 764 | * @return GNUNET_OK if successful, else GNUNET_SYSERR |
765 | */ | 765 | */ |
766 | int | 766 | int |
767 | OIDC_parse_authz_code (const struct GNUNET_IDENTITY_PublicKey *audience, | 767 | OIDC_parse_authz_code (const struct GNUNET_CRYPTO_PublicKey *audience, |
768 | const char *code, | 768 | const char *code, |
769 | const char *code_verifier, | 769 | const char *code_verifier, |
770 | struct GNUNET_RECLAIM_Ticket *ticket, | 770 | struct GNUNET_RECLAIM_Ticket *ticket, |
@@ -780,7 +780,7 @@ OIDC_parse_authz_code (const struct GNUNET_IDENTITY_PublicKey *audience, | |||
780 | char *presentations_ser; | 780 | char *presentations_ser; |
781 | char *code_challenge; | 781 | char *code_challenge; |
782 | struct GNUNET_CRYPTO_EccSignaturePurpose *purpose; | 782 | struct GNUNET_CRYPTO_EccSignaturePurpose *purpose; |
783 | struct GNUNET_IDENTITY_Signature *signature; | 783 | struct GNUNET_CRYPTO_Signature *signature; |
784 | uint32_t code_challenge_len; | 784 | uint32_t code_challenge_len; |
785 | uint32_t attrs_ser_len; | 785 | uint32_t attrs_ser_len; |
786 | uint32_t pres_ser_len; | 786 | uint32_t pres_ser_len; |
@@ -796,7 +796,7 @@ OIDC_parse_authz_code (const struct GNUNET_IDENTITY_PublicKey *audience, | |||
796 | (void **) &code_payload); | 796 | (void **) &code_payload); |
797 | if (code_payload_len < sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) | 797 | if (code_payload_len < sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) |
798 | + sizeof(struct OIDC_Parameters) | 798 | + sizeof(struct OIDC_Parameters) |
799 | + sizeof(struct GNUNET_IDENTITY_Signature)) | 799 | + sizeof(struct GNUNET_CRYPTO_Signature)) |
800 | { | 800 | { |
801 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Authorization code malformed\n"); | 801 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Authorization code malformed\n"); |
802 | GNUNET_free (code_payload); | 802 | GNUNET_free (code_payload); |
@@ -807,10 +807,10 @@ OIDC_parse_authz_code (const struct GNUNET_IDENTITY_PublicKey *audience, | |||
807 | plaintext_len = code_payload_len; | 807 | plaintext_len = code_payload_len; |
808 | plaintext_len -= sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose); | 808 | plaintext_len -= sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose); |
809 | ptr = (char *) &purpose[1]; | 809 | ptr = (char *) &purpose[1]; |
810 | plaintext_len -= sizeof(struct GNUNET_IDENTITY_Signature); | 810 | plaintext_len -= sizeof(struct GNUNET_CRYPTO_Signature); |
811 | plaintext = ptr; | 811 | plaintext = ptr; |
812 | ptr += plaintext_len; | 812 | ptr += plaintext_len; |
813 | signature = (struct GNUNET_IDENTITY_Signature *) ptr; | 813 | signature = (struct GNUNET_CRYPTO_Signature *) ptr; |
814 | params = (struct OIDC_Parameters *) plaintext; | 814 | params = (struct OIDC_Parameters *) plaintext; |
815 | 815 | ||
816 | // cmp code_challenge code_verifier | 816 | // cmp code_challenge code_verifier |
@@ -848,7 +848,7 @@ OIDC_parse_authz_code (const struct GNUNET_IDENTITY_PublicKey *audience, | |||
848 | return GNUNET_SYSERR; | 848 | return GNUNET_SYSERR; |
849 | } | 849 | } |
850 | if (GNUNET_OK != | 850 | if (GNUNET_OK != |
851 | GNUNET_IDENTITY_signature_verify_ ( | 851 | GNUNET_CRYPTO_signature_verify_ ( |
852 | GNUNET_SIGNATURE_PURPOSE_RECLAIM_CODE_SIGN, | 852 | GNUNET_SIGNATURE_PURPOSE_RECLAIM_CODE_SIGN, |
853 | purpose, | 853 | purpose, |
854 | signature, | 854 | signature, |
diff --git a/src/reclaim/oidc_helper.h b/src/reclaim/oidc_helper.h index 81eadf2ed..de788fbdb 100644 --- a/src/reclaim/oidc_helper.h +++ b/src/reclaim/oidc_helper.h | |||
@@ -61,8 +61,8 @@ enum OIDC_VerificationOptions | |||
61 | * @return a new base64-encoded JWT string. | 61 | * @return a new base64-encoded JWT string. |
62 | */ | 62 | */ |
63 | char * | 63 | char * |
64 | OIDC_generate_id_token_rsa (const struct GNUNET_IDENTITY_PublicKey *aud_key, | 64 | OIDC_generate_id_token_rsa (const struct GNUNET_CRYPTO_PublicKey *aud_key, |
65 | const struct GNUNET_IDENTITY_PublicKey *sub_key, | 65 | const struct GNUNET_CRYPTO_PublicKey *sub_key, |
66 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 66 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
67 | const struct | 67 | const struct |
68 | GNUNET_RECLAIM_PresentationList *presentations, | 68 | GNUNET_RECLAIM_PresentationList *presentations, |
@@ -82,8 +82,8 @@ OIDC_generate_id_token_rsa (const struct GNUNET_IDENTITY_PublicKey *aud_key, | |||
82 | * @return a new base64-encoded JWT string. | 82 | * @return a new base64-encoded JWT string. |
83 | */ | 83 | */ |
84 | char* | 84 | char* |
85 | OIDC_generate_id_token_hmac (const struct GNUNET_IDENTITY_PublicKey *aud_key, | 85 | OIDC_generate_id_token_hmac (const struct GNUNET_CRYPTO_PublicKey *aud_key, |
86 | const struct GNUNET_IDENTITY_PublicKey *sub_key, | 86 | const struct GNUNET_CRYPTO_PublicKey *sub_key, |
87 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 87 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
88 | const struct | 88 | const struct |
89 | GNUNET_RECLAIM_PresentationList *presentations, | 89 | GNUNET_RECLAIM_PresentationList *presentations, |
@@ -105,7 +105,7 @@ OIDC_generate_id_token_hmac (const struct GNUNET_IDENTITY_PublicKey *aud_key, | |||
105 | * @return a new authorization code (caller must free) | 105 | * @return a new authorization code (caller must free) |
106 | */ | 106 | */ |
107 | char* | 107 | char* |
108 | OIDC_build_authz_code (const struct GNUNET_IDENTITY_PrivateKey *issuer, | 108 | OIDC_build_authz_code (const struct GNUNET_CRYPTO_PrivateKey *issuer, |
109 | const struct GNUNET_RECLAIM_Ticket *ticket, | 109 | const struct GNUNET_RECLAIM_Ticket *ticket, |
110 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 110 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
111 | const struct | 111 | const struct |
@@ -128,7 +128,7 @@ OIDC_build_authz_code (const struct GNUNET_IDENTITY_PrivateKey *issuer, | |||
128 | * @return GNUNET_OK if successful, else GNUNET_SYSERR | 128 | * @return GNUNET_OK if successful, else GNUNET_SYSERR |
129 | */ | 129 | */ |
130 | int | 130 | int |
131 | OIDC_parse_authz_code (const struct GNUNET_IDENTITY_PublicKey *ecdsa_pub, | 131 | OIDC_parse_authz_code (const struct GNUNET_CRYPTO_PublicKey *ecdsa_pub, |
132 | const char *code, | 132 | const char *code, |
133 | const char *code_verifier, | 133 | const char *code_verifier, |
134 | struct GNUNET_RECLAIM_Ticket *ticket, | 134 | struct GNUNET_RECLAIM_Ticket *ticket, |
@@ -188,7 +188,7 @@ OIDC_check_scopes_for_claim_request (const char *scopes, | |||
188 | * @return Userinfo JSON | 188 | * @return Userinfo JSON |
189 | */ | 189 | */ |
190 | char * | 190 | char * |
191 | OIDC_generate_userinfo (const struct GNUNET_IDENTITY_PublicKey *sub_key, | 191 | OIDC_generate_userinfo (const struct GNUNET_CRYPTO_PublicKey *sub_key, |
192 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 192 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
193 | const struct | 193 | const struct |
194 | GNUNET_RECLAIM_PresentationList *presentations); | 194 | GNUNET_RECLAIM_PresentationList *presentations); |
diff --git a/src/reclaim/plugin_rest_openid_connect.c b/src/reclaim/plugin_rest_openid_connect.c index ff882aca1..d0aee043e 100644 --- a/src/reclaim/plugin_rest_openid_connect.c +++ b/src/reclaim/plugin_rest_openid_connect.c | |||
@@ -331,7 +331,7 @@ struct OIDC_Variables | |||
331 | /** | 331 | /** |
332 | * The RP client public key | 332 | * The RP client public key |
333 | */ | 333 | */ |
334 | struct GNUNET_IDENTITY_PublicKey client_pkey; | 334 | struct GNUNET_CRYPTO_PublicKey client_pkey; |
335 | 335 | ||
336 | /** | 336 | /** |
337 | * The OIDC client id of the RP | 337 | * The OIDC client id of the RP |
@@ -442,7 +442,7 @@ struct RequestHandle | |||
442 | /** | 442 | /** |
443 | * Pointer to ego private key | 443 | * Pointer to ego private key |
444 | */ | 444 | */ |
445 | struct GNUNET_IDENTITY_PrivateKey priv_key; | 445 | struct GNUNET_CRYPTO_PrivateKey priv_key; |
446 | 446 | ||
447 | /** | 447 | /** |
448 | * OIDC variables | 448 | * OIDC variables |
@@ -1257,7 +1257,7 @@ oidc_cred_collect_finished_cb (void *cls) | |||
1257 | */ | 1257 | */ |
1258 | static void | 1258 | static void |
1259 | oidc_cred_collect (void *cls, | 1259 | oidc_cred_collect (void *cls, |
1260 | const struct GNUNET_IDENTITY_PublicKey *identity, | 1260 | const struct GNUNET_CRYPTO_PublicKey *identity, |
1261 | const struct GNUNET_RECLAIM_Credential *cred) | 1261 | const struct GNUNET_RECLAIM_Credential *cred) |
1262 | { | 1262 | { |
1263 | struct RequestHandle *handle = cls; | 1263 | struct RequestHandle *handle = cls; |
@@ -1380,7 +1380,7 @@ attr_in_userinfo_request (struct RequestHandle *handle, | |||
1380 | */ | 1380 | */ |
1381 | static void | 1381 | static void |
1382 | oidc_attr_collect (void *cls, | 1382 | oidc_attr_collect (void *cls, |
1383 | const struct GNUNET_IDENTITY_PublicKey *identity, | 1383 | const struct GNUNET_CRYPTO_PublicKey *identity, |
1384 | const struct GNUNET_RECLAIM_Attribute *attr) | 1384 | const struct GNUNET_RECLAIM_Attribute *attr) |
1385 | { | 1385 | { |
1386 | struct RequestHandle *handle = cls; | 1386 | struct RequestHandle *handle = cls; |
@@ -1429,8 +1429,8 @@ code_redirect (void *cls) | |||
1429 | struct RequestHandle *handle = cls; | 1429 | struct RequestHandle *handle = cls; |
1430 | struct GNUNET_TIME_Absolute current_time; | 1430 | struct GNUNET_TIME_Absolute current_time; |
1431 | struct GNUNET_TIME_Absolute *relog_time; | 1431 | struct GNUNET_TIME_Absolute *relog_time; |
1432 | struct GNUNET_IDENTITY_PublicKey pubkey; | 1432 | struct GNUNET_CRYPTO_PublicKey pubkey; |
1433 | struct GNUNET_IDENTITY_PublicKey ego_pkey; | 1433 | struct GNUNET_CRYPTO_PublicKey ego_pkey; |
1434 | struct GNUNET_HashCode cache_key; | 1434 | struct GNUNET_HashCode cache_key; |
1435 | char *identity_cookie; | 1435 | char *identity_cookie; |
1436 | 1436 | ||
@@ -1450,7 +1450,7 @@ code_redirect (void *cls) | |||
1450 | if (current_time.abs_value_us <= relog_time->abs_value_us) | 1450 | if (current_time.abs_value_us <= relog_time->abs_value_us) |
1451 | { | 1451 | { |
1452 | if (GNUNET_OK != | 1452 | if (GNUNET_OK != |
1453 | GNUNET_IDENTITY_public_key_from_string (handle->oidc | 1453 | GNUNET_CRYPTO_public_key_from_string (handle->oidc |
1454 | ->login_identity, | 1454 | ->login_identity, |
1455 | &pubkey)) | 1455 | &pubkey)) |
1456 | { | 1456 | { |
@@ -1544,7 +1544,7 @@ lookup_redirect_uri_result (void *cls, | |||
1544 | char *tmp; | 1544 | char *tmp; |
1545 | char *tmp_key_str; | 1545 | char *tmp_key_str; |
1546 | char *pos; | 1546 | char *pos; |
1547 | struct GNUNET_IDENTITY_PublicKey redirect_zone; | 1547 | struct GNUNET_CRYPTO_PublicKey redirect_zone; |
1548 | 1548 | ||
1549 | handle->gns_op = NULL; | 1549 | handle->gns_op = NULL; |
1550 | if (0 == rd_count) | 1550 | if (0 == rd_count) |
@@ -1776,10 +1776,10 @@ static void | |||
1776 | tld_iter (void *cls, const char *section, const char *option, const char *value) | 1776 | tld_iter (void *cls, const char *section, const char *option, const char *value) |
1777 | { | 1777 | { |
1778 | struct RequestHandle *handle = cls; | 1778 | struct RequestHandle *handle = cls; |
1779 | struct GNUNET_IDENTITY_PublicKey pkey; | 1779 | struct GNUNET_CRYPTO_PublicKey pkey; |
1780 | 1780 | ||
1781 | if (GNUNET_OK != | 1781 | if (GNUNET_OK != |
1782 | GNUNET_IDENTITY_public_key_from_string (value, &pkey)) | 1782 | GNUNET_CRYPTO_public_key_from_string (value, &pkey)) |
1783 | { | 1783 | { |
1784 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Skipping non key %s\n", value); | 1784 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Skipping non key %s\n", value); |
1785 | return; | 1785 | return; |
@@ -1803,8 +1803,8 @@ authorize_endpoint (struct GNUNET_REST_RequestHandle *con_handle, | |||
1803 | { | 1803 | { |
1804 | struct RequestHandle *handle = cls; | 1804 | struct RequestHandle *handle = cls; |
1805 | struct EgoEntry *tmp_ego; | 1805 | struct EgoEntry *tmp_ego; |
1806 | const struct GNUNET_IDENTITY_PrivateKey *priv_key; | 1806 | const struct GNUNET_CRYPTO_PrivateKey *priv_key; |
1807 | struct GNUNET_IDENTITY_PublicKey pkey; | 1807 | struct GNUNET_CRYPTO_PublicKey pkey; |
1808 | 1808 | ||
1809 | cookie_identity_interpretation (handle); | 1809 | cookie_identity_interpretation (handle); |
1810 | 1810 | ||
@@ -1832,7 +1832,7 @@ authorize_endpoint (struct GNUNET_REST_RequestHandle *con_handle, | |||
1832 | } | 1832 | } |
1833 | 1833 | ||
1834 | if (GNUNET_OK != | 1834 | if (GNUNET_OK != |
1835 | GNUNET_IDENTITY_public_key_from_string (handle->oidc->client_id, | 1835 | GNUNET_CRYPTO_public_key_from_string (handle->oidc->client_id, |
1836 | &handle->oidc->client_pkey)) | 1836 | &handle->oidc->client_pkey)) |
1837 | { | 1837 | { |
1838 | handle->emsg = GNUNET_strdup (OIDC_ERROR_KEY_UNAUTHORIZED_CLIENT); | 1838 | handle->emsg = GNUNET_strdup (OIDC_ERROR_KEY_UNAUTHORIZED_CLIENT); |
@@ -1848,7 +1848,7 @@ authorize_endpoint (struct GNUNET_REST_RequestHandle *con_handle, | |||
1848 | for (tmp_ego = ego_head; NULL != tmp_ego; tmp_ego = tmp_ego->next) | 1848 | for (tmp_ego = ego_head; NULL != tmp_ego; tmp_ego = tmp_ego->next) |
1849 | { | 1849 | { |
1850 | priv_key = GNUNET_IDENTITY_ego_get_private_key (tmp_ego->ego); | 1850 | priv_key = GNUNET_IDENTITY_ego_get_private_key (tmp_ego->ego); |
1851 | GNUNET_IDENTITY_key_get_public (priv_key, &pkey); | 1851 | GNUNET_CRYPTO_key_get_public (priv_key, &pkey); |
1852 | if (0 == GNUNET_memcmp (&pkey, &handle->oidc->client_pkey)) | 1852 | if (0 == GNUNET_memcmp (&pkey, &handle->oidc->client_pkey)) |
1853 | { | 1853 | { |
1854 | handle->tld = GNUNET_strdup (tmp_ego->identifier); | 1854 | handle->tld = GNUNET_strdup (tmp_ego->identifier); |
@@ -2041,7 +2041,7 @@ parse_credentials_post_body (struct RequestHandle *handle, | |||
2041 | 2041 | ||
2042 | static int | 2042 | static int |
2043 | check_authorization (struct RequestHandle *handle, | 2043 | check_authorization (struct RequestHandle *handle, |
2044 | struct GNUNET_IDENTITY_PublicKey *cid) | 2044 | struct GNUNET_CRYPTO_PublicKey *cid) |
2045 | { | 2045 | { |
2046 | char *expected_pass; | 2046 | char *expected_pass; |
2047 | char *received_cid; | 2047 | char *received_cid; |
@@ -2078,7 +2078,7 @@ check_authorization (struct RequestHandle *handle, | |||
2078 | GNUNET_STRINGS_string_to_data (received_cid, | 2078 | GNUNET_STRINGS_string_to_data (received_cid, |
2079 | strlen (received_cid), | 2079 | strlen (received_cid), |
2080 | cid, | 2080 | cid, |
2081 | sizeof(struct GNUNET_IDENTITY_PublicKey)); | 2081 | sizeof(struct GNUNET_CRYPTO_PublicKey)); |
2082 | GNUNET_free (received_cid); | 2082 | GNUNET_free (received_cid); |
2083 | return GNUNET_OK; | 2083 | return GNUNET_OK; |
2084 | 2084 | ||
@@ -2128,7 +2128,7 @@ check_authorization (struct RequestHandle *handle, | |||
2128 | GNUNET_STRINGS_string_to_data (received_cid, | 2128 | GNUNET_STRINGS_string_to_data (received_cid, |
2129 | strlen (received_cid), | 2129 | strlen (received_cid), |
2130 | cid, | 2130 | cid, |
2131 | sizeof(struct GNUNET_IDENTITY_PublicKey)); | 2131 | sizeof(struct GNUNET_CRYPTO_PublicKey)); |
2132 | 2132 | ||
2133 | GNUNET_free (received_cpw); | 2133 | GNUNET_free (received_cpw); |
2134 | GNUNET_free (received_cid); | 2134 | GNUNET_free (received_cid); |
@@ -2138,10 +2138,10 @@ check_authorization (struct RequestHandle *handle, | |||
2138 | 2138 | ||
2139 | const struct EgoEntry * | 2139 | const struct EgoEntry * |
2140 | find_ego (struct RequestHandle *handle, | 2140 | find_ego (struct RequestHandle *handle, |
2141 | struct GNUNET_IDENTITY_PublicKey *test_key) | 2141 | struct GNUNET_CRYPTO_PublicKey *test_key) |
2142 | { | 2142 | { |
2143 | struct EgoEntry *ego_entry; | 2143 | struct EgoEntry *ego_entry; |
2144 | struct GNUNET_IDENTITY_PublicKey pub_key; | 2144 | struct GNUNET_CRYPTO_PublicKey pub_key; |
2145 | 2145 | ||
2146 | for (ego_entry = ego_head; NULL != ego_entry; | 2146 | for (ego_entry = ego_head; NULL != ego_entry; |
2147 | ego_entry = ego_entry->next) | 2147 | ego_entry = ego_entry->next) |
@@ -2172,7 +2172,7 @@ token_endpoint (struct GNUNET_REST_RequestHandle *con_handle, | |||
2172 | struct GNUNET_RECLAIM_AttributeList *cl = NULL; | 2172 | struct GNUNET_RECLAIM_AttributeList *cl = NULL; |
2173 | struct GNUNET_RECLAIM_PresentationList *pl = NULL; | 2173 | struct GNUNET_RECLAIM_PresentationList *pl = NULL; |
2174 | struct GNUNET_RECLAIM_Ticket ticket; | 2174 | struct GNUNET_RECLAIM_Ticket ticket; |
2175 | struct GNUNET_IDENTITY_PublicKey cid; | 2175 | struct GNUNET_CRYPTO_PublicKey cid; |
2176 | struct GNUNET_HashCode cache_key; | 2176 | struct GNUNET_HashCode cache_key; |
2177 | struct MHD_Response *resp = NULL; | 2177 | struct MHD_Response *resp = NULL; |
2178 | char *grant_type = NULL; | 2178 | char *grant_type = NULL; |
@@ -2439,7 +2439,7 @@ token_endpoint (struct GNUNET_REST_RequestHandle *con_handle, | |||
2439 | */ | 2439 | */ |
2440 | static void | 2440 | static void |
2441 | consume_ticket (void *cls, | 2441 | consume_ticket (void *cls, |
2442 | const struct GNUNET_IDENTITY_PublicKey *identity, | 2442 | const struct GNUNET_CRYPTO_PublicKey *identity, |
2443 | const struct GNUNET_RECLAIM_Attribute *attr, | 2443 | const struct GNUNET_RECLAIM_Attribute *attr, |
2444 | const struct GNUNET_RECLAIM_Presentation *presentation) | 2444 | const struct GNUNET_RECLAIM_Presentation *presentation) |
2445 | { | 2445 | { |
@@ -2620,7 +2620,7 @@ userinfo_endpoint (struct GNUNET_REST_RequestHandle *con_handle, | |||
2620 | char *authorization_type; | 2620 | char *authorization_type; |
2621 | char *authorization_access_token; | 2621 | char *authorization_access_token; |
2622 | const struct EgoEntry *aud_ego; | 2622 | const struct EgoEntry *aud_ego; |
2623 | const struct GNUNET_IDENTITY_PrivateKey *privkey; | 2623 | const struct GNUNET_CRYPTO_PrivateKey *privkey; |
2624 | 2624 | ||
2625 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Getting userinfo\n"); | 2625 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Getting userinfo\n"); |
2626 | GNUNET_CRYPTO_hash (OIDC_AUTHORIZATION_HEADER_KEY, | 2626 | GNUNET_CRYPTO_hash (OIDC_AUTHORIZATION_HEADER_KEY, |
@@ -2802,7 +2802,7 @@ list_ego (void *cls, | |||
2802 | const char *identifier) | 2802 | const char *identifier) |
2803 | { | 2803 | { |
2804 | struct EgoEntry *ego_entry; | 2804 | struct EgoEntry *ego_entry; |
2805 | struct GNUNET_IDENTITY_PublicKey pk; | 2805 | struct GNUNET_CRYPTO_PublicKey pk; |
2806 | 2806 | ||
2807 | if (NULL == ego) | 2807 | if (NULL == ego) |
2808 | { | 2808 | { |
@@ -2814,7 +2814,7 @@ list_ego (void *cls, | |||
2814 | { | 2814 | { |
2815 | ego_entry = GNUNET_new (struct EgoEntry); | 2815 | ego_entry = GNUNET_new (struct EgoEntry); |
2816 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 2816 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
2817 | ego_entry->keystring = GNUNET_IDENTITY_public_key_to_string (&pk); | 2817 | ego_entry->keystring = GNUNET_CRYPTO_public_key_to_string (&pk); |
2818 | ego_entry->ego = ego; | 2818 | ego_entry->ego = ego; |
2819 | ego_entry->identifier = GNUNET_strdup (identifier); | 2819 | ego_entry->identifier = GNUNET_strdup (identifier); |
2820 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, | 2820 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, |
@@ -2841,7 +2841,7 @@ list_ego (void *cls, | |||
2841 | /* Add */ | 2841 | /* Add */ |
2842 | ego_entry = GNUNET_new (struct EgoEntry); | 2842 | ego_entry = GNUNET_new (struct EgoEntry); |
2843 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 2843 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
2844 | ego_entry->keystring = GNUNET_IDENTITY_public_key_to_string (&pk); | 2844 | ego_entry->keystring = GNUNET_CRYPTO_public_key_to_string (&pk); |
2845 | ego_entry->ego = ego; | 2845 | ego_entry->ego = ego; |
2846 | ego_entry->identifier = GNUNET_strdup (identifier); | 2846 | ego_entry->identifier = GNUNET_strdup (identifier); |
2847 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, | 2847 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, |
diff --git a/src/reclaim/plugin_rest_reclaim.c b/src/reclaim/plugin_rest_reclaim.c index 9cc41bf1a..b2586109a 100644 --- a/src/reclaim/plugin_rest_reclaim.c +++ b/src/reclaim/plugin_rest_reclaim.c | |||
@@ -172,7 +172,7 @@ struct RequestHandle | |||
172 | /** | 172 | /** |
173 | * Pointer to ego private key | 173 | * Pointer to ego private key |
174 | */ | 174 | */ |
175 | struct GNUNET_IDENTITY_PrivateKey priv_key; | 175 | struct GNUNET_CRYPTO_PrivateKey priv_key; |
176 | 176 | ||
177 | /** | 177 | /** |
178 | * Rest connection | 178 | * Rest connection |
@@ -449,14 +449,14 @@ ticket_collect (void *cls, const struct GNUNET_RECLAIM_Ticket *ticket) | |||
449 | tmp = | 449 | tmp = |
450 | GNUNET_STRINGS_data_to_string_alloc (&ticket->identity, | 450 | GNUNET_STRINGS_data_to_string_alloc (&ticket->identity, |
451 | sizeof(struct | 451 | sizeof(struct |
452 | GNUNET_IDENTITY_PublicKey)); | 452 | GNUNET_CRYPTO_PublicKey)); |
453 | value = json_string (tmp); | 453 | value = json_string (tmp); |
454 | json_object_set_new (json_resource, "issuer", value); | 454 | json_object_set_new (json_resource, "issuer", value); |
455 | GNUNET_free (tmp); | 455 | GNUNET_free (tmp); |
456 | tmp = | 456 | tmp = |
457 | GNUNET_STRINGS_data_to_string_alloc (&ticket->audience, | 457 | GNUNET_STRINGS_data_to_string_alloc (&ticket->audience, |
458 | sizeof(struct | 458 | sizeof(struct |
459 | GNUNET_IDENTITY_PublicKey)); | 459 | GNUNET_CRYPTO_PublicKey)); |
460 | value = json_string (tmp); | 460 | value = json_string (tmp); |
461 | json_object_set_new (json_resource, "audience", value); | 461 | json_object_set_new (json_resource, "audience", value); |
462 | GNUNET_free (tmp); | 462 | GNUNET_free (tmp); |
@@ -474,7 +474,7 @@ add_credential_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
474 | void *cls) | 474 | void *cls) |
475 | { | 475 | { |
476 | struct RequestHandle *handle = cls; | 476 | struct RequestHandle *handle = cls; |
477 | const struct GNUNET_IDENTITY_PrivateKey *identity_priv; | 477 | const struct GNUNET_CRYPTO_PrivateKey *identity_priv; |
478 | const char *identity; | 478 | const char *identity; |
479 | struct EgoEntry *ego_entry; | 479 | struct EgoEntry *ego_entry; |
480 | struct GNUNET_RECLAIM_Credential *attribute; | 480 | struct GNUNET_RECLAIM_Credential *attribute; |
@@ -562,7 +562,7 @@ add_credential_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
562 | */ | 562 | */ |
563 | static void | 563 | static void |
564 | cred_collect (void *cls, | 564 | cred_collect (void *cls, |
565 | const struct GNUNET_IDENTITY_PublicKey *identity, | 565 | const struct GNUNET_CRYPTO_PublicKey *identity, |
566 | const struct GNUNET_RECLAIM_Credential *cred) | 566 | const struct GNUNET_RECLAIM_Credential *cred) |
567 | { | 567 | { |
568 | struct RequestHandle *handle = cls; | 568 | struct RequestHandle *handle = cls; |
@@ -649,7 +649,7 @@ list_credential_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
649 | void *cls) | 649 | void *cls) |
650 | { | 650 | { |
651 | struct RequestHandle *handle = cls; | 651 | struct RequestHandle *handle = cls; |
652 | const struct GNUNET_IDENTITY_PrivateKey *priv_key; | 652 | const struct GNUNET_CRYPTO_PrivateKey *priv_key; |
653 | struct EgoEntry *ego_entry; | 653 | struct EgoEntry *ego_entry; |
654 | char *identity; | 654 | char *identity; |
655 | 655 | ||
@@ -706,7 +706,7 @@ delete_credential_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
706 | void *cls) | 706 | void *cls) |
707 | { | 707 | { |
708 | struct RequestHandle *handle = cls; | 708 | struct RequestHandle *handle = cls; |
709 | const struct GNUNET_IDENTITY_PrivateKey *priv_key; | 709 | const struct GNUNET_CRYPTO_PrivateKey *priv_key; |
710 | struct GNUNET_RECLAIM_Credential attr; | 710 | struct GNUNET_RECLAIM_Credential attr; |
711 | struct EgoEntry *ego_entry; | 711 | struct EgoEntry *ego_entry; |
712 | char *identity_id_str; | 712 | char *identity_id_str; |
@@ -772,7 +772,7 @@ list_tickets_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
772 | const char *url, | 772 | const char *url, |
773 | void *cls) | 773 | void *cls) |
774 | { | 774 | { |
775 | const struct GNUNET_IDENTITY_PrivateKey *priv_key; | 775 | const struct GNUNET_CRYPTO_PrivateKey *priv_key; |
776 | struct RequestHandle *handle = cls; | 776 | struct RequestHandle *handle = cls; |
777 | struct EgoEntry *ego_entry; | 777 | struct EgoEntry *ego_entry; |
778 | char *identity; | 778 | char *identity; |
@@ -819,7 +819,7 @@ add_attribute_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
819 | const char *url, | 819 | const char *url, |
820 | void *cls) | 820 | void *cls) |
821 | { | 821 | { |
822 | const struct GNUNET_IDENTITY_PrivateKey *identity_priv; | 822 | const struct GNUNET_CRYPTO_PrivateKey *identity_priv; |
823 | const char *identity; | 823 | const char *identity; |
824 | struct RequestHandle *handle = cls; | 824 | struct RequestHandle *handle = cls; |
825 | struct EgoEntry *ego_entry; | 825 | struct EgoEntry *ego_entry; |
@@ -967,7 +967,7 @@ parse_jwt (const struct GNUNET_RECLAIM_Credential *cred, | |||
967 | */ | 967 | */ |
968 | static void | 968 | static void |
969 | attr_collect (void *cls, | 969 | attr_collect (void *cls, |
970 | const struct GNUNET_IDENTITY_PublicKey *identity, | 970 | const struct GNUNET_CRYPTO_PublicKey *identity, |
971 | const struct GNUNET_RECLAIM_Attribute *attr) | 971 | const struct GNUNET_RECLAIM_Attribute *attr) |
972 | { | 972 | { |
973 | struct RequestHandle *handle = cls; | 973 | struct RequestHandle *handle = cls; |
@@ -1016,7 +1016,7 @@ list_attribute_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
1016 | const char *url, | 1016 | const char *url, |
1017 | void *cls) | 1017 | void *cls) |
1018 | { | 1018 | { |
1019 | const struct GNUNET_IDENTITY_PrivateKey *priv_key; | 1019 | const struct GNUNET_CRYPTO_PrivateKey *priv_key; |
1020 | struct RequestHandle *handle = cls; | 1020 | struct RequestHandle *handle = cls; |
1021 | struct EgoEntry *ego_entry; | 1021 | struct EgoEntry *ego_entry; |
1022 | char *identity; | 1022 | char *identity; |
@@ -1070,7 +1070,7 @@ delete_attribute_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
1070 | const char *url, | 1070 | const char *url, |
1071 | void *cls) | 1071 | void *cls) |
1072 | { | 1072 | { |
1073 | const struct GNUNET_IDENTITY_PrivateKey *priv_key; | 1073 | const struct GNUNET_CRYPTO_PrivateKey *priv_key; |
1074 | struct RequestHandle *handle = cls; | 1074 | struct RequestHandle *handle = cls; |
1075 | struct GNUNET_RECLAIM_Attribute attr; | 1075 | struct GNUNET_RECLAIM_Attribute attr; |
1076 | struct EgoEntry *ego_entry; | 1076 | struct EgoEntry *ego_entry; |
@@ -1128,11 +1128,11 @@ revoke_ticket_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
1128 | const char *url, | 1128 | const char *url, |
1129 | void *cls) | 1129 | void *cls) |
1130 | { | 1130 | { |
1131 | const struct GNUNET_IDENTITY_PrivateKey *identity_priv; | 1131 | const struct GNUNET_CRYPTO_PrivateKey *identity_priv; |
1132 | struct RequestHandle *handle = cls; | 1132 | struct RequestHandle *handle = cls; |
1133 | struct EgoEntry *ego_entry; | 1133 | struct EgoEntry *ego_entry; |
1134 | struct GNUNET_RECLAIM_Ticket *ticket = NULL; | 1134 | struct GNUNET_RECLAIM_Ticket *ticket = NULL; |
1135 | struct GNUNET_IDENTITY_PublicKey tmp_pk; | 1135 | struct GNUNET_CRYPTO_PublicKey tmp_pk; |
1136 | char term_data[handle->rest_handle->data_size + 1]; | 1136 | char term_data[handle->rest_handle->data_size + 1]; |
1137 | json_t *data_json; | 1137 | json_t *data_json; |
1138 | json_error_t err; | 1138 | json_error_t err; |
@@ -1176,7 +1176,7 @@ revoke_ticket_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
1176 | GNUNET_IDENTITY_ego_get_public_key (ego_entry->ego, &tmp_pk); | 1176 | GNUNET_IDENTITY_ego_get_public_key (ego_entry->ego, &tmp_pk); |
1177 | if (0 == memcmp (&ticket->identity, | 1177 | if (0 == memcmp (&ticket->identity, |
1178 | &tmp_pk, | 1178 | &tmp_pk, |
1179 | sizeof(struct GNUNET_IDENTITY_PublicKey))) | 1179 | sizeof(struct GNUNET_CRYPTO_PublicKey))) |
1180 | break; | 1180 | break; |
1181 | } | 1181 | } |
1182 | if (NULL == ego_entry) | 1182 | if (NULL == ego_entry) |
@@ -1198,7 +1198,7 @@ revoke_ticket_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
1198 | 1198 | ||
1199 | static void | 1199 | static void |
1200 | consume_cont (void *cls, | 1200 | consume_cont (void *cls, |
1201 | const struct GNUNET_IDENTITY_PublicKey *identity, | 1201 | const struct GNUNET_CRYPTO_PublicKey *identity, |
1202 | const struct GNUNET_RECLAIM_Attribute *attr, | 1202 | const struct GNUNET_RECLAIM_Attribute *attr, |
1203 | const struct GNUNET_RECLAIM_Presentation *presentation) | 1203 | const struct GNUNET_RECLAIM_Presentation *presentation) |
1204 | { | 1204 | { |
@@ -1235,11 +1235,11 @@ consume_ticket_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
1235 | const char *url, | 1235 | const char *url, |
1236 | void *cls) | 1236 | void *cls) |
1237 | { | 1237 | { |
1238 | const struct GNUNET_IDENTITY_PrivateKey *identity_priv; | 1238 | const struct GNUNET_CRYPTO_PrivateKey *identity_priv; |
1239 | struct RequestHandle *handle = cls; | 1239 | struct RequestHandle *handle = cls; |
1240 | struct EgoEntry *ego_entry; | 1240 | struct EgoEntry *ego_entry; |
1241 | struct GNUNET_RECLAIM_Ticket *ticket; | 1241 | struct GNUNET_RECLAIM_Ticket *ticket; |
1242 | struct GNUNET_IDENTITY_PublicKey tmp_pk; | 1242 | struct GNUNET_CRYPTO_PublicKey tmp_pk; |
1243 | char term_data[handle->rest_handle->data_size + 1]; | 1243 | char term_data[handle->rest_handle->data_size + 1]; |
1244 | json_t *data_json; | 1244 | json_t *data_json; |
1245 | json_error_t err; | 1245 | json_error_t err; |
@@ -1279,7 +1279,7 @@ consume_ticket_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
1279 | GNUNET_IDENTITY_ego_get_public_key (ego_entry->ego, &tmp_pk); | 1279 | GNUNET_IDENTITY_ego_get_public_key (ego_entry->ego, &tmp_pk); |
1280 | if (0 == memcmp (&ticket->audience, | 1280 | if (0 == memcmp (&ticket->audience, |
1281 | &tmp_pk, | 1281 | &tmp_pk, |
1282 | sizeof(struct GNUNET_IDENTITY_PublicKey))) | 1282 | sizeof(struct GNUNET_CRYPTO_PublicKey))) |
1283 | break; | 1283 | break; |
1284 | } | 1284 | } |
1285 | if (NULL == ego_entry) | 1285 | if (NULL == ego_entry) |
@@ -1362,7 +1362,7 @@ list_ego (void *cls, | |||
1362 | const char *identifier) | 1362 | const char *identifier) |
1363 | { | 1363 | { |
1364 | struct EgoEntry *ego_entry; | 1364 | struct EgoEntry *ego_entry; |
1365 | struct GNUNET_IDENTITY_PublicKey pk; | 1365 | struct GNUNET_CRYPTO_PublicKey pk; |
1366 | 1366 | ||
1367 | if (NULL == ego) | 1367 | if (NULL == ego) |
1368 | { | 1368 | { |
@@ -1373,7 +1373,7 @@ list_ego (void *cls, | |||
1373 | { | 1373 | { |
1374 | ego_entry = GNUNET_new (struct EgoEntry); | 1374 | ego_entry = GNUNET_new (struct EgoEntry); |
1375 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 1375 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
1376 | ego_entry->keystring = GNUNET_IDENTITY_public_key_to_string (&pk); | 1376 | ego_entry->keystring = GNUNET_CRYPTO_public_key_to_string (&pk); |
1377 | ego_entry->ego = ego; | 1377 | ego_entry->ego = ego; |
1378 | ego_entry->identifier = GNUNET_strdup (identifier); | 1378 | ego_entry->identifier = GNUNET_strdup (identifier); |
1379 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, | 1379 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, |
@@ -1399,7 +1399,7 @@ list_ego (void *cls, | |||
1399 | /* Add */ | 1399 | /* Add */ |
1400 | ego_entry = GNUNET_new (struct EgoEntry); | 1400 | ego_entry = GNUNET_new (struct EgoEntry); |
1401 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 1401 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
1402 | ego_entry->keystring = GNUNET_IDENTITY_public_key_to_string (&pk); | 1402 | ego_entry->keystring = GNUNET_CRYPTO_public_key_to_string (&pk); |
1403 | ego_entry->ego = ego; | 1403 | ego_entry->ego = ego; |
1404 | ego_entry->identifier = GNUNET_strdup (identifier); | 1404 | ego_entry->identifier = GNUNET_strdup (identifier); |
1405 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, | 1405 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, |
diff --git a/src/reclaim/reclaim_api.c b/src/reclaim/reclaim_api.c index fedee3fff..e9a34dd95 100644 --- a/src/reclaim/reclaim_api.c +++ b/src/reclaim/reclaim_api.c | |||
@@ -234,7 +234,7 @@ struct GNUNET_RECLAIM_AttributeIterator | |||
234 | /** | 234 | /** |
235 | * Private key of the zone. | 235 | * Private key of the zone. |
236 | */ | 236 | */ |
237 | struct GNUNET_IDENTITY_PrivateKey identity; | 237 | struct GNUNET_CRYPTO_PrivateKey identity; |
238 | 238 | ||
239 | /** | 239 | /** |
240 | * The operation id this zone iteration operation has | 240 | * The operation id this zone iteration operation has |
@@ -301,7 +301,7 @@ struct GNUNET_RECLAIM_CredentialIterator | |||
301 | /** | 301 | /** |
302 | * Private key of the zone. | 302 | * Private key of the zone. |
303 | */ | 303 | */ |
304 | struct GNUNET_IDENTITY_PrivateKey identity; | 304 | struct GNUNET_CRYPTO_PrivateKey identity; |
305 | 305 | ||
306 | /** | 306 | /** |
307 | * The operation id this zone iteration operation has | 307 | * The operation id this zone iteration operation has |
@@ -592,7 +592,7 @@ static void | |||
592 | handle_consume_ticket_result (void *cls, | 592 | handle_consume_ticket_result (void *cls, |
593 | const struct ConsumeTicketResultMessage *msg) | 593 | const struct ConsumeTicketResultMessage *msg) |
594 | { | 594 | { |
595 | struct GNUNET_IDENTITY_PublicKey identity; | 595 | struct GNUNET_CRYPTO_PublicKey identity; |
596 | struct GNUNET_RECLAIM_Handle *h = cls; | 596 | struct GNUNET_RECLAIM_Handle *h = cls; |
597 | struct GNUNET_RECLAIM_Operation *op; | 597 | struct GNUNET_RECLAIM_Operation *op; |
598 | size_t attrs_len; | 598 | size_t attrs_len; |
@@ -621,7 +621,7 @@ handle_consume_ticket_result (void *cls, | |||
621 | struct GNUNET_RECLAIM_PresentationListEntry *ple; | 621 | struct GNUNET_RECLAIM_PresentationListEntry *ple; |
622 | read_ptr = (char *) &msg[1]; | 622 | read_ptr = (char *) &msg[1]; |
623 | GNUNET_assert (GNUNET_SYSERR != | 623 | GNUNET_assert (GNUNET_SYSERR != |
624 | GNUNET_IDENTITY_read_public_key_from_buffer (read_ptr, | 624 | GNUNET_CRYPTO_read_public_key_from_buffer (read_ptr, |
625 | key_len, | 625 | key_len, |
626 | &identity, | 626 | &identity, |
627 | &read)); | 627 | &read)); |
@@ -714,7 +714,7 @@ check_attribute_result (void *cls, const struct AttributeResultMessage *msg) | |||
714 | static void | 714 | static void |
715 | handle_attribute_result (void *cls, const struct AttributeResultMessage *msg) | 715 | handle_attribute_result (void *cls, const struct AttributeResultMessage *msg) |
716 | { | 716 | { |
717 | static struct GNUNET_IDENTITY_PublicKey identity; | 717 | static struct GNUNET_CRYPTO_PublicKey identity; |
718 | struct GNUNET_RECLAIM_Handle *h = cls; | 718 | struct GNUNET_RECLAIM_Handle *h = cls; |
719 | struct GNUNET_RECLAIM_AttributeIterator *it; | 719 | struct GNUNET_RECLAIM_AttributeIterator *it; |
720 | struct GNUNET_RECLAIM_Operation *op; | 720 | struct GNUNET_RECLAIM_Operation *op; |
@@ -765,7 +765,7 @@ handle_attribute_result (void *cls, const struct AttributeResultMessage *msg) | |||
765 | { | 765 | { |
766 | struct GNUNET_RECLAIM_Attribute *attr; | 766 | struct GNUNET_RECLAIM_Attribute *attr; |
767 | GNUNET_assert (GNUNET_SYSERR != | 767 | GNUNET_assert (GNUNET_SYSERR != |
768 | GNUNET_IDENTITY_read_public_key_from_buffer (buf, | 768 | GNUNET_CRYPTO_read_public_key_from_buffer (buf, |
769 | key_len, | 769 | key_len, |
770 | &identity, | 770 | &identity, |
771 | &read)); | 771 | &read)); |
@@ -826,7 +826,7 @@ static void | |||
826 | handle_credential_result (void *cls, const struct | 826 | handle_credential_result (void *cls, const struct |
827 | CredentialResultMessage *msg) | 827 | CredentialResultMessage *msg) |
828 | { | 828 | { |
829 | struct GNUNET_IDENTITY_PublicKey identity; | 829 | struct GNUNET_CRYPTO_PublicKey identity; |
830 | struct GNUNET_RECLAIM_Handle *h = cls; | 830 | struct GNUNET_RECLAIM_Handle *h = cls; |
831 | struct GNUNET_RECLAIM_CredentialIterator *it; | 831 | struct GNUNET_RECLAIM_CredentialIterator *it; |
832 | struct GNUNET_RECLAIM_Operation *op; | 832 | struct GNUNET_RECLAIM_Operation *op; |
@@ -854,7 +854,7 @@ handle_credential_result (void *cls, const struct | |||
854 | if (0 < key_len) | 854 | if (0 < key_len) |
855 | { | 855 | { |
856 | GNUNET_assert (GNUNET_SYSERR != | 856 | GNUNET_assert (GNUNET_SYSERR != |
857 | GNUNET_IDENTITY_read_public_key_from_buffer (buf, | 857 | GNUNET_CRYPTO_read_public_key_from_buffer (buf, |
858 | key_len, | 858 | key_len, |
859 | &identity, | 859 | &identity, |
860 | &read)); | 860 | &read)); |
@@ -1161,7 +1161,7 @@ GNUNET_RECLAIM_disconnect (struct GNUNET_RECLAIM_Handle *h) | |||
1161 | struct GNUNET_RECLAIM_Operation * | 1161 | struct GNUNET_RECLAIM_Operation * |
1162 | GNUNET_RECLAIM_attribute_store ( | 1162 | GNUNET_RECLAIM_attribute_store ( |
1163 | struct GNUNET_RECLAIM_Handle *h, | 1163 | struct GNUNET_RECLAIM_Handle *h, |
1164 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 1164 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
1165 | const struct GNUNET_RECLAIM_Attribute *attr, | 1165 | const struct GNUNET_RECLAIM_Attribute *attr, |
1166 | const struct GNUNET_TIME_Relative *exp_interval, | 1166 | const struct GNUNET_TIME_Relative *exp_interval, |
1167 | GNUNET_RECLAIM_ContinuationWithStatus cont, | 1167 | GNUNET_RECLAIM_ContinuationWithStatus cont, |
@@ -1180,14 +1180,14 @@ GNUNET_RECLAIM_attribute_store ( | |||
1180 | op->cls = cont_cls; | 1180 | op->cls = cont_cls; |
1181 | op->r_id = h->r_id_gen++; | 1181 | op->r_id = h->r_id_gen++; |
1182 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, op); | 1182 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, op); |
1183 | key_len = GNUNET_IDENTITY_private_key_get_length (pkey); | 1183 | key_len = GNUNET_CRYPTO_private_key_get_length (pkey); |
1184 | attr_len = GNUNET_RECLAIM_attribute_serialize_get_size (attr); | 1184 | attr_len = GNUNET_RECLAIM_attribute_serialize_get_size (attr); |
1185 | op->env = GNUNET_MQ_msg_extra (sam, | 1185 | op->env = GNUNET_MQ_msg_extra (sam, |
1186 | attr_len + key_len, | 1186 | attr_len + key_len, |
1187 | GNUNET_MESSAGE_TYPE_RECLAIM_ATTRIBUTE_STORE); | 1187 | GNUNET_MESSAGE_TYPE_RECLAIM_ATTRIBUTE_STORE); |
1188 | sam->key_len = htons (key_len); | 1188 | sam->key_len = htons (key_len); |
1189 | buf = (char *) &sam[1]; | 1189 | buf = (char *) &sam[1]; |
1190 | written = GNUNET_IDENTITY_write_private_key_to_buffer (pkey, buf, key_len); | 1190 | written = GNUNET_CRYPTO_write_private_key_to_buffer (pkey, buf, key_len); |
1191 | GNUNET_assert (0 < written); | 1191 | GNUNET_assert (0 < written); |
1192 | buf += written; | 1192 | buf += written; |
1193 | sam->id = htonl (op->r_id); | 1193 | sam->id = htonl (op->r_id); |
@@ -1205,7 +1205,7 @@ GNUNET_RECLAIM_attribute_store ( | |||
1205 | struct GNUNET_RECLAIM_Operation * | 1205 | struct GNUNET_RECLAIM_Operation * |
1206 | GNUNET_RECLAIM_attribute_delete ( | 1206 | GNUNET_RECLAIM_attribute_delete ( |
1207 | struct GNUNET_RECLAIM_Handle *h, | 1207 | struct GNUNET_RECLAIM_Handle *h, |
1208 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 1208 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
1209 | const struct GNUNET_RECLAIM_Attribute *attr, | 1209 | const struct GNUNET_RECLAIM_Attribute *attr, |
1210 | GNUNET_RECLAIM_ContinuationWithStatus cont, | 1210 | GNUNET_RECLAIM_ContinuationWithStatus cont, |
1211 | void *cont_cls) | 1211 | void *cont_cls) |
@@ -1223,14 +1223,14 @@ GNUNET_RECLAIM_attribute_delete ( | |||
1223 | op->cls = cont_cls; | 1223 | op->cls = cont_cls; |
1224 | op->r_id = h->r_id_gen++; | 1224 | op->r_id = h->r_id_gen++; |
1225 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, op); | 1225 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, op); |
1226 | key_len = GNUNET_IDENTITY_private_key_get_length (pkey); | 1226 | key_len = GNUNET_CRYPTO_private_key_get_length (pkey); |
1227 | attr_len = GNUNET_RECLAIM_attribute_serialize_get_size (attr); | 1227 | attr_len = GNUNET_RECLAIM_attribute_serialize_get_size (attr); |
1228 | op->env = GNUNET_MQ_msg_extra (dam, | 1228 | op->env = GNUNET_MQ_msg_extra (dam, |
1229 | attr_len + key_len, | 1229 | attr_len + key_len, |
1230 | GNUNET_MESSAGE_TYPE_RECLAIM_ATTRIBUTE_DELETE); | 1230 | GNUNET_MESSAGE_TYPE_RECLAIM_ATTRIBUTE_DELETE); |
1231 | dam->key_len = htons (key_len); | 1231 | dam->key_len = htons (key_len); |
1232 | buf = (char *) &dam[1]; | 1232 | buf = (char *) &dam[1]; |
1233 | written = GNUNET_IDENTITY_write_private_key_to_buffer (pkey, buf, key_len); | 1233 | written = GNUNET_CRYPTO_write_private_key_to_buffer (pkey, buf, key_len); |
1234 | GNUNET_assert (0 < written); | 1234 | GNUNET_assert (0 < written); |
1235 | buf += written; | 1235 | buf += written; |
1236 | dam->id = htonl (op->r_id); | 1236 | dam->id = htonl (op->r_id); |
@@ -1246,7 +1246,7 @@ GNUNET_RECLAIM_attribute_delete ( | |||
1246 | struct GNUNET_RECLAIM_Operation * | 1246 | struct GNUNET_RECLAIM_Operation * |
1247 | GNUNET_RECLAIM_credential_store ( | 1247 | GNUNET_RECLAIM_credential_store ( |
1248 | struct GNUNET_RECLAIM_Handle *h, | 1248 | struct GNUNET_RECLAIM_Handle *h, |
1249 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 1249 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
1250 | const struct GNUNET_RECLAIM_Credential *credential, | 1250 | const struct GNUNET_RECLAIM_Credential *credential, |
1251 | const struct GNUNET_TIME_Relative *exp_interval, | 1251 | const struct GNUNET_TIME_Relative *exp_interval, |
1252 | GNUNET_RECLAIM_ContinuationWithStatus cont, | 1252 | GNUNET_RECLAIM_ContinuationWithStatus cont, |
@@ -1264,7 +1264,7 @@ GNUNET_RECLAIM_credential_store ( | |||
1264 | op->as_cb = cont; | 1264 | op->as_cb = cont; |
1265 | op->cls = cont_cls; | 1265 | op->cls = cont_cls; |
1266 | op->r_id = h->r_id_gen++; | 1266 | op->r_id = h->r_id_gen++; |
1267 | key_len = GNUNET_IDENTITY_private_key_get_length (pkey); | 1267 | key_len = GNUNET_CRYPTO_private_key_get_length (pkey); |
1268 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, op); | 1268 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, op); |
1269 | attr_len = GNUNET_RECLAIM_credential_serialize_get_size (credential); | 1269 | attr_len = GNUNET_RECLAIM_credential_serialize_get_size (credential); |
1270 | op->env = GNUNET_MQ_msg_extra (sam, | 1270 | op->env = GNUNET_MQ_msg_extra (sam, |
@@ -1272,7 +1272,7 @@ GNUNET_RECLAIM_credential_store ( | |||
1272 | GNUNET_MESSAGE_TYPE_RECLAIM_CREDENTIAL_STORE); | 1272 | GNUNET_MESSAGE_TYPE_RECLAIM_CREDENTIAL_STORE); |
1273 | sam->key_len = htons (key_len); | 1273 | sam->key_len = htons (key_len); |
1274 | buf = (char *) &sam[1]; | 1274 | buf = (char *) &sam[1]; |
1275 | written = GNUNET_IDENTITY_write_private_key_to_buffer (pkey, buf, key_len); | 1275 | written = GNUNET_CRYPTO_write_private_key_to_buffer (pkey, buf, key_len); |
1276 | GNUNET_assert (0 <= written); | 1276 | GNUNET_assert (0 <= written); |
1277 | buf += written; | 1277 | buf += written; |
1278 | sam->id = htonl (op->r_id); | 1278 | sam->id = htonl (op->r_id); |
@@ -1290,7 +1290,7 @@ GNUNET_RECLAIM_credential_store ( | |||
1290 | struct GNUNET_RECLAIM_Operation * | 1290 | struct GNUNET_RECLAIM_Operation * |
1291 | GNUNET_RECLAIM_credential_delete ( | 1291 | GNUNET_RECLAIM_credential_delete ( |
1292 | struct GNUNET_RECLAIM_Handle *h, | 1292 | struct GNUNET_RECLAIM_Handle *h, |
1293 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 1293 | const struct GNUNET_CRYPTO_PrivateKey *pkey, |
1294 | const struct GNUNET_RECLAIM_Credential *attr, | 1294 | const struct GNUNET_RECLAIM_Credential *attr, |
1295 | GNUNET_RECLAIM_ContinuationWithStatus cont, | 1295 | GNUNET_RECLAIM_ContinuationWithStatus cont, |
1296 | void *cont_cls) | 1296 | void *cont_cls) |
@@ -1307,7 +1307,7 @@ GNUNET_RECLAIM_credential_delete ( | |||
1307 | op->as_cb = cont; | 1307 | op->as_cb = cont; |
1308 | op->cls = cont_cls; | 1308 | op->cls = cont_cls; |
1309 | op->r_id = h->r_id_gen++; | 1309 | op->r_id = h->r_id_gen++; |
1310 | key_len = GNUNET_IDENTITY_private_key_get_length (pkey); | 1310 | key_len = GNUNET_CRYPTO_private_key_get_length (pkey); |
1311 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, op); | 1311 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, op); |
1312 | attr_len = GNUNET_RECLAIM_credential_serialize_get_size (attr); | 1312 | attr_len = GNUNET_RECLAIM_credential_serialize_get_size (attr); |
1313 | op->env = GNUNET_MQ_msg_extra (dam, | 1313 | op->env = GNUNET_MQ_msg_extra (dam, |
@@ -1315,7 +1315,7 @@ GNUNET_RECLAIM_credential_delete ( | |||
1315 | GNUNET_MESSAGE_TYPE_RECLAIM_CREDENTIAL_DELETE); | 1315 | GNUNET_MESSAGE_TYPE_RECLAIM_CREDENTIAL_DELETE); |
1316 | dam->key_len = htons (key_len); | 1316 | dam->key_len = htons (key_len); |
1317 | buf = (char *) &dam[1]; | 1317 | buf = (char *) &dam[1]; |
1318 | written = GNUNET_IDENTITY_write_private_key_to_buffer (pkey, buf, key_len); | 1318 | written = GNUNET_CRYPTO_write_private_key_to_buffer (pkey, buf, key_len); |
1319 | GNUNET_assert (0 <= written); | 1319 | GNUNET_assert (0 <= written); |
1320 | buf += written; | 1320 | buf += written; |
1321 | dam->id = htonl (op->r_id); | 1321 | dam->id = htonl (op->r_id); |
@@ -1331,7 +1331,7 @@ GNUNET_RECLAIM_credential_delete ( | |||
1331 | struct GNUNET_RECLAIM_AttributeIterator * | 1331 | struct GNUNET_RECLAIM_AttributeIterator * |
1332 | GNUNET_RECLAIM_get_attributes_start ( | 1332 | GNUNET_RECLAIM_get_attributes_start ( |
1333 | struct GNUNET_RECLAIM_Handle *h, | 1333 | struct GNUNET_RECLAIM_Handle *h, |
1334 | const struct GNUNET_IDENTITY_PrivateKey *identity, | 1334 | const struct GNUNET_CRYPTO_PrivateKey *identity, |
1335 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1335 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1336 | void *error_cb_cls, | 1336 | void *error_cb_cls, |
1337 | GNUNET_RECLAIM_AttributeResult proc, | 1337 | GNUNET_RECLAIM_AttributeResult proc, |
@@ -1356,7 +1356,7 @@ GNUNET_RECLAIM_get_attributes_start ( | |||
1356 | it->proc_cls = proc_cls; | 1356 | it->proc_cls = proc_cls; |
1357 | it->r_id = rid; | 1357 | it->r_id = rid; |
1358 | it->identity = *identity; | 1358 | it->identity = *identity; |
1359 | key_len = GNUNET_IDENTITY_private_key_get_length (identity); | 1359 | key_len = GNUNET_CRYPTO_private_key_get_length (identity); |
1360 | GNUNET_CONTAINER_DLL_insert_tail (h->it_head, h->it_tail, it); | 1360 | GNUNET_CONTAINER_DLL_insert_tail (h->it_head, h->it_tail, it); |
1361 | env = | 1361 | env = |
1362 | GNUNET_MQ_msg_extra (msg, | 1362 | GNUNET_MQ_msg_extra (msg, |
@@ -1364,7 +1364,7 @@ GNUNET_RECLAIM_get_attributes_start ( | |||
1364 | GNUNET_MESSAGE_TYPE_RECLAIM_ATTRIBUTE_ITERATION_START); | 1364 | GNUNET_MESSAGE_TYPE_RECLAIM_ATTRIBUTE_ITERATION_START); |
1365 | msg->id = htonl (rid); | 1365 | msg->id = htonl (rid); |
1366 | msg->key_len = htons (key_len); | 1366 | msg->key_len = htons (key_len); |
1367 | GNUNET_IDENTITY_write_private_key_to_buffer (identity, &msg[1], key_len); | 1367 | GNUNET_CRYPTO_write_private_key_to_buffer (identity, &msg[1], key_len); |
1368 | if (NULL == h->mq) | 1368 | if (NULL == h->mq) |
1369 | it->env = env; | 1369 | it->env = env; |
1370 | else | 1370 | else |
@@ -1408,7 +1408,7 @@ GNUNET_RECLAIM_get_attributes_stop (struct GNUNET_RECLAIM_AttributeIterator *it) | |||
1408 | struct GNUNET_RECLAIM_CredentialIterator * | 1408 | struct GNUNET_RECLAIM_CredentialIterator * |
1409 | GNUNET_RECLAIM_get_credentials_start ( | 1409 | GNUNET_RECLAIM_get_credentials_start ( |
1410 | struct GNUNET_RECLAIM_Handle *h, | 1410 | struct GNUNET_RECLAIM_Handle *h, |
1411 | const struct GNUNET_IDENTITY_PrivateKey *identity, | 1411 | const struct GNUNET_CRYPTO_PrivateKey *identity, |
1412 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1412 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1413 | void *error_cb_cls, | 1413 | void *error_cb_cls, |
1414 | GNUNET_RECLAIM_CredentialResult proc, | 1414 | GNUNET_RECLAIM_CredentialResult proc, |
@@ -1433,7 +1433,7 @@ GNUNET_RECLAIM_get_credentials_start ( | |||
1433 | ait->proc_cls = proc_cls; | 1433 | ait->proc_cls = proc_cls; |
1434 | ait->r_id = rid; | 1434 | ait->r_id = rid; |
1435 | ait->identity = *identity; | 1435 | ait->identity = *identity; |
1436 | key_len = GNUNET_IDENTITY_private_key_get_length (identity); | 1436 | key_len = GNUNET_CRYPTO_private_key_get_length (identity); |
1437 | GNUNET_CONTAINER_DLL_insert_tail (h->ait_head, h->ait_tail, ait); | 1437 | GNUNET_CONTAINER_DLL_insert_tail (h->ait_head, h->ait_tail, ait); |
1438 | env = | 1438 | env = |
1439 | GNUNET_MQ_msg_extra (msg, | 1439 | GNUNET_MQ_msg_extra (msg, |
@@ -1441,7 +1441,7 @@ GNUNET_RECLAIM_get_credentials_start ( | |||
1441 | GNUNET_MESSAGE_TYPE_RECLAIM_CREDENTIAL_ITERATION_START); | 1441 | GNUNET_MESSAGE_TYPE_RECLAIM_CREDENTIAL_ITERATION_START); |
1442 | msg->id = htonl (rid); | 1442 | msg->id = htonl (rid); |
1443 | msg->key_len = htons (key_len); | 1443 | msg->key_len = htons (key_len); |
1444 | GNUNET_IDENTITY_write_private_key_to_buffer (identity, &msg[1], key_len); | 1444 | GNUNET_CRYPTO_write_private_key_to_buffer (identity, &msg[1], key_len); |
1445 | if (NULL == h->mq) | 1445 | if (NULL == h->mq) |
1446 | ait->env = env; | 1446 | ait->env = env; |
1447 | else | 1447 | else |
@@ -1488,8 +1488,8 @@ GNUNET_RECLAIM_get_credentials_stop (struct | |||
1488 | struct GNUNET_RECLAIM_Operation * | 1488 | struct GNUNET_RECLAIM_Operation * |
1489 | GNUNET_RECLAIM_ticket_issue ( | 1489 | GNUNET_RECLAIM_ticket_issue ( |
1490 | struct GNUNET_RECLAIM_Handle *h, | 1490 | struct GNUNET_RECLAIM_Handle *h, |
1491 | const struct GNUNET_IDENTITY_PrivateKey *iss, | 1491 | const struct GNUNET_CRYPTO_PrivateKey *iss, |
1492 | const struct GNUNET_IDENTITY_PublicKey *rp, | 1492 | const struct GNUNET_CRYPTO_PublicKey *rp, |
1493 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 1493 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
1494 | GNUNET_RECLAIM_IssueTicketCallback cb, | 1494 | GNUNET_RECLAIM_IssueTicketCallback cb, |
1495 | void *cb_cls) | 1495 | void *cb_cls) |
@@ -1507,8 +1507,8 @@ GNUNET_RECLAIM_ticket_issue ( | |||
1507 | op->ti_cb = cb; | 1507 | op->ti_cb = cb; |
1508 | op->cls = cb_cls; | 1508 | op->cls = cb_cls; |
1509 | op->r_id = h->r_id_gen++; | 1509 | op->r_id = h->r_id_gen++; |
1510 | key_len = GNUNET_IDENTITY_private_key_get_length (iss); | 1510 | key_len = GNUNET_CRYPTO_private_key_get_length (iss); |
1511 | rpk_len = GNUNET_IDENTITY_public_key_get_length (rp); | 1511 | rpk_len = GNUNET_CRYPTO_public_key_get_length (rp); |
1512 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, op); | 1512 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, op); |
1513 | attr_len = GNUNET_RECLAIM_attribute_list_serialize_get_size (attrs); | 1513 | attr_len = GNUNET_RECLAIM_attribute_list_serialize_get_size (attrs); |
1514 | op->env = GNUNET_MQ_msg_extra (tim, | 1514 | op->env = GNUNET_MQ_msg_extra (tim, |
@@ -1517,10 +1517,10 @@ GNUNET_RECLAIM_ticket_issue ( | |||
1517 | tim->key_len = htons (key_len); | 1517 | tim->key_len = htons (key_len); |
1518 | tim->pkey_len = htons (rpk_len); | 1518 | tim->pkey_len = htons (rpk_len); |
1519 | buf = (char *) &tim[1]; | 1519 | buf = (char *) &tim[1]; |
1520 | written = GNUNET_IDENTITY_write_private_key_to_buffer (iss, buf, key_len); | 1520 | written = GNUNET_CRYPTO_write_private_key_to_buffer (iss, buf, key_len); |
1521 | GNUNET_assert (0 <= written); | 1521 | GNUNET_assert (0 <= written); |
1522 | buf += written; | 1522 | buf += written; |
1523 | written = GNUNET_IDENTITY_write_public_key_to_buffer (rp, buf, rpk_len); | 1523 | written = GNUNET_CRYPTO_write_public_key_to_buffer (rp, buf, rpk_len); |
1524 | GNUNET_assert (0 <= written); | 1524 | GNUNET_assert (0 <= written); |
1525 | buf += written; | 1525 | buf += written; |
1526 | tim->id = htonl (op->r_id); | 1526 | tim->id = htonl (op->r_id); |
@@ -1548,7 +1548,7 @@ GNUNET_RECLAIM_ticket_issue ( | |||
1548 | struct GNUNET_RECLAIM_Operation * | 1548 | struct GNUNET_RECLAIM_Operation * |
1549 | GNUNET_RECLAIM_ticket_consume ( | 1549 | GNUNET_RECLAIM_ticket_consume ( |
1550 | struct GNUNET_RECLAIM_Handle *h, | 1550 | struct GNUNET_RECLAIM_Handle *h, |
1551 | const struct GNUNET_IDENTITY_PrivateKey *identity, | 1551 | const struct GNUNET_CRYPTO_PrivateKey *identity, |
1552 | const struct GNUNET_RECLAIM_Ticket *ticket, | 1552 | const struct GNUNET_RECLAIM_Ticket *ticket, |
1553 | GNUNET_RECLAIM_AttributeTicketResult cb, | 1553 | GNUNET_RECLAIM_AttributeTicketResult cb, |
1554 | void *cb_cls) | 1554 | void *cb_cls) |
@@ -1564,7 +1564,7 @@ GNUNET_RECLAIM_ticket_consume ( | |||
1564 | op->atr_cb = cb; | 1564 | op->atr_cb = cb; |
1565 | op->cls = cb_cls; | 1565 | op->cls = cb_cls; |
1566 | op->r_id = h->r_id_gen++; | 1566 | op->r_id = h->r_id_gen++; |
1567 | key_len = GNUNET_IDENTITY_private_key_get_length (identity); | 1567 | key_len = GNUNET_CRYPTO_private_key_get_length (identity); |
1568 | tkt_len = GNUNET_RECLAIM_ticket_serialize_get_size (ticket); | 1568 | tkt_len = GNUNET_RECLAIM_ticket_serialize_get_size (ticket); |
1569 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, op); | 1569 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, op); |
1570 | op->env = GNUNET_MQ_msg_extra (ctm, | 1570 | op->env = GNUNET_MQ_msg_extra (ctm, |
@@ -1572,7 +1572,7 @@ GNUNET_RECLAIM_ticket_consume ( | |||
1572 | GNUNET_MESSAGE_TYPE_RECLAIM_CONSUME_TICKET); | 1572 | GNUNET_MESSAGE_TYPE_RECLAIM_CONSUME_TICKET); |
1573 | ctm->key_len = htons (key_len); | 1573 | ctm->key_len = htons (key_len); |
1574 | buf = (char*) &ctm[1]; | 1574 | buf = (char*) &ctm[1]; |
1575 | GNUNET_IDENTITY_write_private_key_to_buffer (identity, buf, key_len); | 1575 | GNUNET_CRYPTO_write_private_key_to_buffer (identity, buf, key_len); |
1576 | buf += key_len; | 1576 | buf += key_len; |
1577 | ctm->tkt_len = htons (tkt_len); | 1577 | ctm->tkt_len = htons (tkt_len); |
1578 | GNUNET_RECLAIM_write_ticket_to_buffer (ticket, buf, tkt_len); | 1578 | GNUNET_RECLAIM_write_ticket_to_buffer (ticket, buf, tkt_len); |
@@ -1588,7 +1588,7 @@ GNUNET_RECLAIM_ticket_consume ( | |||
1588 | struct GNUNET_RECLAIM_TicketIterator * | 1588 | struct GNUNET_RECLAIM_TicketIterator * |
1589 | GNUNET_RECLAIM_ticket_iteration_start ( | 1589 | GNUNET_RECLAIM_ticket_iteration_start ( |
1590 | struct GNUNET_RECLAIM_Handle *h, | 1590 | struct GNUNET_RECLAIM_Handle *h, |
1591 | const struct GNUNET_IDENTITY_PrivateKey *identity, | 1591 | const struct GNUNET_CRYPTO_PrivateKey *identity, |
1592 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1592 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1593 | void *error_cb_cls, | 1593 | void *error_cb_cls, |
1594 | GNUNET_RECLAIM_TicketCallback proc, | 1594 | GNUNET_RECLAIM_TicketCallback proc, |
@@ -1613,14 +1613,14 @@ GNUNET_RECLAIM_ticket_iteration_start ( | |||
1613 | it->cls = proc_cls; | 1613 | it->cls = proc_cls; |
1614 | it->r_id = rid; | 1614 | it->r_id = rid; |
1615 | 1615 | ||
1616 | key_len = GNUNET_IDENTITY_private_key_get_length (identity); | 1616 | key_len = GNUNET_CRYPTO_private_key_get_length (identity); |
1617 | GNUNET_CONTAINER_DLL_insert_tail (h->ticket_it_head, h->ticket_it_tail, it); | 1617 | GNUNET_CONTAINER_DLL_insert_tail (h->ticket_it_head, h->ticket_it_tail, it); |
1618 | env = GNUNET_MQ_msg_extra (msg, | 1618 | env = GNUNET_MQ_msg_extra (msg, |
1619 | key_len, | 1619 | key_len, |
1620 | GNUNET_MESSAGE_TYPE_RECLAIM_TICKET_ITERATION_START); | 1620 | GNUNET_MESSAGE_TYPE_RECLAIM_TICKET_ITERATION_START); |
1621 | msg->id = htonl (rid); | 1621 | msg->id = htonl (rid); |
1622 | msg->key_len = htons (key_len); | 1622 | msg->key_len = htons (key_len); |
1623 | GNUNET_IDENTITY_write_private_key_to_buffer (identity, | 1623 | GNUNET_CRYPTO_write_private_key_to_buffer (identity, |
1624 | &msg[1], | 1624 | &msg[1], |
1625 | key_len); | 1625 | key_len); |
1626 | if (NULL == h->mq) | 1626 | if (NULL == h->mq) |
@@ -1691,7 +1691,7 @@ GNUNET_RECLAIM_ticket_iteration_stop (struct GNUNET_RECLAIM_TicketIterator *it) | |||
1691 | struct GNUNET_RECLAIM_Operation * | 1691 | struct GNUNET_RECLAIM_Operation * |
1692 | GNUNET_RECLAIM_ticket_revoke ( | 1692 | GNUNET_RECLAIM_ticket_revoke ( |
1693 | struct GNUNET_RECLAIM_Handle *h, | 1693 | struct GNUNET_RECLAIM_Handle *h, |
1694 | const struct GNUNET_IDENTITY_PrivateKey *identity, | 1694 | const struct GNUNET_CRYPTO_PrivateKey *identity, |
1695 | const struct GNUNET_RECLAIM_Ticket *ticket, | 1695 | const struct GNUNET_RECLAIM_Ticket *ticket, |
1696 | GNUNET_RECLAIM_ContinuationWithStatus cb, | 1696 | GNUNET_RECLAIM_ContinuationWithStatus cb, |
1697 | void *cb_cls) | 1697 | void *cb_cls) |
@@ -1711,7 +1711,7 @@ GNUNET_RECLAIM_ticket_revoke ( | |||
1711 | op->cls = cb_cls; | 1711 | op->cls = cb_cls; |
1712 | op->r_id = rid; | 1712 | op->r_id = rid; |
1713 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, op); | 1713 | GNUNET_CONTAINER_DLL_insert_tail (h->op_head, h->op_tail, op); |
1714 | key_len = GNUNET_IDENTITY_private_key_get_length (identity); | 1714 | key_len = GNUNET_CRYPTO_private_key_get_length (identity); |
1715 | tkt_len = GNUNET_RECLAIM_ticket_serialize_get_size (ticket); | 1715 | tkt_len = GNUNET_RECLAIM_ticket_serialize_get_size (ticket); |
1716 | op->env = GNUNET_MQ_msg_extra (msg, | 1716 | op->env = GNUNET_MQ_msg_extra (msg, |
1717 | key_len + tkt_len, | 1717 | key_len + tkt_len, |
@@ -1720,7 +1720,7 @@ GNUNET_RECLAIM_ticket_revoke ( | |||
1720 | msg->key_len = htons (key_len); | 1720 | msg->key_len = htons (key_len); |
1721 | msg->tkt_len = htons (tkt_len); | 1721 | msg->tkt_len = htons (tkt_len); |
1722 | buf = (char*) &msg[1]; | 1722 | buf = (char*) &msg[1]; |
1723 | written = GNUNET_IDENTITY_write_private_key_to_buffer (identity, | 1723 | written = GNUNET_CRYPTO_write_private_key_to_buffer (identity, |
1724 | buf, | 1724 | buf, |
1725 | key_len); | 1725 | key_len); |
1726 | GNUNET_assert (0 <= written); | 1726 | GNUNET_assert (0 <= written); |
@@ -1741,8 +1741,8 @@ GNUNET_RECLAIM_ticket_serialize_get_size (const struct | |||
1741 | GNUNET_RECLAIM_Ticket *tkt) | 1741 | GNUNET_RECLAIM_Ticket *tkt) |
1742 | { | 1742 | { |
1743 | size_t size = sizeof (tkt->rnd); | 1743 | size_t size = sizeof (tkt->rnd); |
1744 | size += GNUNET_IDENTITY_public_key_get_length (&tkt->identity); | 1744 | size += GNUNET_CRYPTO_public_key_get_length (&tkt->identity); |
1745 | size += GNUNET_IDENTITY_public_key_get_length (&tkt->audience); | 1745 | size += GNUNET_CRYPTO_public_key_get_length (&tkt->audience); |
1746 | return size; | 1746 | return size; |
1747 | } | 1747 | } |
1748 | 1748 | ||
@@ -1756,7 +1756,7 @@ GNUNET_RECLAIM_read_ticket_from_buffer (const void *buffer, | |||
1756 | size_t read = 0; | 1756 | size_t read = 0; |
1757 | size_t left = len; | 1757 | size_t left = len; |
1758 | if (GNUNET_SYSERR == | 1758 | if (GNUNET_SYSERR == |
1759 | GNUNET_IDENTITY_read_public_key_from_buffer (tmp, | 1759 | GNUNET_CRYPTO_read_public_key_from_buffer (tmp, |
1760 | left, | 1760 | left, |
1761 | &tkt->identity, | 1761 | &tkt->identity, |
1762 | &read)) | 1762 | &read)) |
@@ -1764,7 +1764,7 @@ GNUNET_RECLAIM_read_ticket_from_buffer (const void *buffer, | |||
1764 | left -= read; | 1764 | left -= read; |
1765 | tmp += read; | 1765 | tmp += read; |
1766 | if (GNUNET_SYSERR == | 1766 | if (GNUNET_SYSERR == |
1767 | GNUNET_IDENTITY_read_public_key_from_buffer (tmp, | 1767 | GNUNET_CRYPTO_read_public_key_from_buffer (tmp, |
1768 | left, | 1768 | left, |
1769 | &tkt->audience, | 1769 | &tkt->audience, |
1770 | &read)) | 1770 | &read)) |
@@ -1788,14 +1788,14 @@ GNUNET_RECLAIM_write_ticket_to_buffer (const struct | |||
1788 | char *tmp = buffer; | 1788 | char *tmp = buffer; |
1789 | size_t left = len; | 1789 | size_t left = len; |
1790 | ssize_t written = 0; | 1790 | ssize_t written = 0; |
1791 | written = GNUNET_IDENTITY_write_public_key_to_buffer (&tkt->identity, | 1791 | written = GNUNET_CRYPTO_write_public_key_to_buffer (&tkt->identity, |
1792 | buffer, | 1792 | buffer, |
1793 | left); | 1793 | left); |
1794 | if (0 > written) | 1794 | if (0 > written) |
1795 | return written; | 1795 | return written; |
1796 | left -= written; | 1796 | left -= written; |
1797 | tmp += written; | 1797 | tmp += written; |
1798 | written = GNUNET_IDENTITY_write_public_key_to_buffer (&tkt->audience, | 1798 | written = GNUNET_CRYPTO_write_public_key_to_buffer (&tkt->audience, |
1799 | tmp, | 1799 | tmp, |
1800 | left); | 1800 | left); |
1801 | if (0 > written) | 1801 | if (0 > written) |
diff --git a/src/reclaim/test_did_helper.c b/src/reclaim/test_did_helper.c index 02db28925..c11f47540 100644 --- a/src/reclaim/test_did_helper.c +++ b/src/reclaim/test_did_helper.c | |||
@@ -58,8 +58,8 @@ static const char *test_did_document_format_str = | |||
58 | \"authentication\":[\"#key-1\"],\ | 58 | \"authentication\":[\"#key-1\"],\ |
59 | \"assertionMethod\":[\"#key-1\"]}"; | 59 | \"assertionMethod\":[\"#key-1\"]}"; |
60 | 60 | ||
61 | static struct GNUNET_IDENTITY_PrivateKey test_skey; | 61 | static struct GNUNET_CRYPTO_PrivateKey test_skey; |
62 | static struct GNUNET_IDENTITY_PublicKey test_pkey; | 62 | static struct GNUNET_CRYPTO_PublicKey test_pkey; |
63 | static struct json_t *test_did_document; | 63 | static struct json_t *test_did_document; |
64 | static char *test_did_document_str; | 64 | static char *test_did_document_str; |
65 | 65 | ||
@@ -75,7 +75,7 @@ test_GNUNET_DID_pkey_to_did () | |||
75 | void | 75 | void |
76 | test_GNUNET_DID_did_to_pkey () | 76 | test_GNUNET_DID_did_to_pkey () |
77 | { | 77 | { |
78 | struct GNUNET_IDENTITY_PublicKey pkey; | 78 | struct GNUNET_CRYPTO_PublicKey pkey; |
79 | DID_did_to_pkey ((char *) test_did, &pkey); | 79 | DID_did_to_pkey ((char *) test_did, &pkey); |
80 | 80 | ||
81 | GNUNET_assert (test_pkey.type = pkey.type); | 81 | GNUNET_assert (test_pkey.type = pkey.type); |
@@ -112,11 +112,11 @@ int | |||
112 | main () | 112 | main () |
113 | { | 113 | { |
114 | // Setup key | 114 | // Setup key |
115 | test_skey.type = htonl (GNUNET_IDENTITY_TYPE_EDDSA); | 115 | test_skey.type = htonl (GNUNET_PUBLIC_KEY_TYPE_EDDSA); |
116 | memcpy (&(test_skey.eddsa_key), | 116 | memcpy (&(test_skey.eddsa_key), |
117 | test_skey_bytes, | 117 | test_skey_bytes, |
118 | sizeof(struct GNUNET_CRYPTO_EddsaPrivateKey)); | 118 | sizeof(struct GNUNET_CRYPTO_EddsaPrivateKey)); |
119 | GNUNET_IDENTITY_key_get_public (&test_skey, &test_pkey); | 119 | GNUNET_CRYPTO_key_get_public (&test_skey, &test_pkey); |
120 | 120 | ||
121 | // Setup did document | 121 | // Setup did document |
122 | GNUNET_asprintf (&test_did_document_str, | 122 | GNUNET_asprintf (&test_did_document_str, |
diff --git a/src/regex/Makefile.am b/src/regex/Makefile.am index b526a0c8c..cd96f2508 100644 --- a/src/regex/Makefile.am +++ b/src/regex/Makefile.am | |||
@@ -34,7 +34,7 @@ gnunet_service_regex_LDADD = -lm \ | |||
34 | libgnunetregexblock.la \ | 34 | libgnunetregexblock.la \ |
35 | $(top_builddir)/src/dht/libgnunetdht.la \ | 35 | $(top_builddir)/src/dht/libgnunetdht.la \ |
36 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 36 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
37 | $(top_builddir)/src/util/libgnunetutil.la \ | 37 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
38 | $(GN_LIBINTL) | 38 | $(GN_LIBINTL) |
39 | 39 | ||
40 | lib_LTLIBRARIES = \ | 40 | lib_LTLIBRARIES = \ |
@@ -44,7 +44,7 @@ lib_LTLIBRARIES = \ | |||
44 | libgnunetregexblock_la_SOURCES = \ | 44 | libgnunetregexblock_la_SOURCES = \ |
45 | regex_block_lib.c regex_block_lib.h | 45 | regex_block_lib.c regex_block_lib.h |
46 | libgnunetregexblock_la_LIBADD = \ | 46 | libgnunetregexblock_la_LIBADD = \ |
47 | $(top_builddir)/src/util/libgnunetutil.la \ | 47 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
48 | $(XLIB) \ | 48 | $(XLIB) \ |
49 | $(LTLIBINTL) | 49 | $(LTLIBINTL) |
50 | libgnunetregexblock_la_LDFLAGS = \ | 50 | libgnunetregexblock_la_LDFLAGS = \ |
@@ -57,7 +57,7 @@ libgnunetregex_la_SOURCES = \ | |||
57 | regex_api_search.c \ | 57 | regex_api_search.c \ |
58 | regex_ipc.h | 58 | regex_ipc.h |
59 | libgnunetregex_la_LIBADD = \ | 59 | libgnunetregex_la_LIBADD = \ |
60 | $(top_builddir)/src/util/libgnunetutil.la | 60 | $(top_builddir)/src/lib/util/libgnunetutil.la |
61 | libgnunetregex_la_LDFLAGS = \ | 61 | libgnunetregex_la_LDFLAGS = \ |
62 | $(GN_LIBINTL) \ | 62 | $(GN_LIBINTL) \ |
63 | $(GN_LIB_LDFLAGS) \ | 63 | $(GN_LIB_LDFLAGS) \ |
@@ -71,9 +71,9 @@ libgnunet_plugin_block_regex_la_SOURCES = \ | |||
71 | plugin_block_regex.c | 71 | plugin_block_regex.c |
72 | libgnunet_plugin_block_regex_la_LIBADD = \ | 72 | libgnunet_plugin_block_regex_la_LIBADD = \ |
73 | libgnunetregexblock.la \ | 73 | libgnunetregexblock.la \ |
74 | $(top_builddir)/src/block/libgnunetblock.la \ | 74 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
75 | $(top_builddir)/src/block/libgnunetblockgroup.la \ | 75 | $(top_builddir)/src/lib/block/libgnunetblockgroup.la \ |
76 | $(top_builddir)/src/util/libgnunetutil.la | 76 | $(top_builddir)/src/lib/util/libgnunetutil.la |
77 | libgnunet_plugin_block_regex_la_LDFLAGS = \ | 77 | libgnunet_plugin_block_regex_la_LDFLAGS = \ |
78 | $(GN_LIBINTL) \ | 78 | $(GN_LIBINTL) \ |
79 | $(GN_PLUGIN_LDFLAGS) | 79 | $(GN_PLUGIN_LDFLAGS) |
@@ -87,9 +87,9 @@ libgnunet_plugin_block_regex_la_LDFLAGS = \ | |||
87 | # $(REGEX_INTERNAL) gnunet-regex-simulation-profiler.c | 87 | # $(REGEX_INTERNAL) gnunet-regex-simulation-profiler.c |
88 | #gnunet_regex_simulation_profiler_LDADD = \ | 88 | #gnunet_regex_simulation_profiler_LDADD = \ |
89 | # libgnunetregexblock.la \ | 89 | # libgnunetregexblock.la \ |
90 | # $(top_builddir)/src/util/libgnunetutil.la \ | 90 | # $(top_builddir)/src/lib/util/libgnunetutil.la \ |
91 | # $(top_builddir)/src/dht/libgnunetdht.la \ | 91 | # $(top_builddir)/src/dht/libgnunetdht.la \ |
92 | # $(top_builddir)/src/block/libgnunetblock.la \ | 92 | # $(top_builddir)/src/lib/block/libgnunetblock.la \ |
93 | # $(top_builddir)/src/statistics/libgnunetstatistics.la | 93 | # $(top_builddir)/src/statistics/libgnunetstatistics.la |
94 | #endif | 94 | #endif |
95 | 95 | ||
@@ -101,7 +101,7 @@ perf_regex_SOURCES = \ | |||
101 | perf_regex_LDADD = -lm \ | 101 | perf_regex_LDADD = -lm \ |
102 | $(top_builddir)/src/dht/libgnunetdht.la \ | 102 | $(top_builddir)/src/dht/libgnunetdht.la \ |
103 | libgnunetregexblock.la \ | 103 | libgnunetregexblock.la \ |
104 | $(top_builddir)/src/util/libgnunetutil.la \ | 104 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
105 | $(top_builddir)/src/statistics/libgnunetstatistics.la | 105 | $(top_builddir)/src/statistics/libgnunetstatistics.la |
106 | perf_regex_LDFLAGS = \ | 106 | perf_regex_LDFLAGS = \ |
107 | $(GN_LIBINTL) | 107 | $(GN_LIBINTL) |
@@ -112,7 +112,7 @@ gnunet_daemon_regexprofiler_LDADD = -lm \ | |||
112 | $(top_builddir)/src/dht/libgnunetdht.la \ | 112 | $(top_builddir)/src/dht/libgnunetdht.la \ |
113 | libgnunetregexblock.la \ | 113 | libgnunetregexblock.la \ |
114 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 114 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
115 | $(top_builddir)/src/util/libgnunetutil.la | 115 | $(top_builddir)/src/lib/util/libgnunetutil.la |
116 | gnunet_daemon_regexprofiler_LDFLAGS = \ | 116 | gnunet_daemon_regexprofiler_LDFLAGS = \ |
117 | $(GN_LIBINTL) | 117 | $(GN_LIBINTL) |
118 | 118 | ||
@@ -135,21 +135,21 @@ test_regex_eval_api_LDADD = -lm \ | |||
135 | $(top_builddir)/src/dht/libgnunetdht.la \ | 135 | $(top_builddir)/src/dht/libgnunetdht.la \ |
136 | libgnunetregexblock.la \ | 136 | libgnunetregexblock.la \ |
137 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 137 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
138 | $(top_builddir)/src/util/libgnunetutil.la | 138 | $(top_builddir)/src/lib/util/libgnunetutil.la |
139 | 139 | ||
140 | test_regex_integration_SOURCES = \ | 140 | test_regex_integration_SOURCES = \ |
141 | test_regex_integration.c | 141 | test_regex_integration.c |
142 | test_regex_integration_LDADD = -lm \ | 142 | test_regex_integration_LDADD = -lm \ |
143 | libgnunetregex.la \ | 143 | libgnunetregex.la \ |
144 | $(top_builddir)/src/testing/libgnunettesting.la \ | 144 | $(top_builddir)/src/testing/libgnunettesting.la \ |
145 | $(top_builddir)/src/util/libgnunetutil.la | 145 | $(top_builddir)/src/lib/util/libgnunetutil.la |
146 | 146 | ||
147 | test_regex_api_SOURCES = \ | 147 | test_regex_api_SOURCES = \ |
148 | test_regex_api.c | 148 | test_regex_api.c |
149 | test_regex_api_LDADD = -lm \ | 149 | test_regex_api_LDADD = -lm \ |
150 | libgnunetregex.la \ | 150 | libgnunetregex.la \ |
151 | $(top_builddir)/src/testing/libgnunettesting.la \ | 151 | $(top_builddir)/src/testing/libgnunettesting.la \ |
152 | $(top_builddir)/src/util/libgnunetutil.la | 152 | $(top_builddir)/src/lib/util/libgnunetutil.la |
153 | 153 | ||
154 | test_regex_iterate_api_SOURCES = \ | 154 | test_regex_iterate_api_SOURCES = \ |
155 | $(REGEX_INTERNAL) test_regex_iterate_api.c | 155 | $(REGEX_INTERNAL) test_regex_iterate_api.c |
@@ -157,7 +157,7 @@ test_regex_iterate_api_LDADD = -lm \ | |||
157 | libgnunetregexblock.la \ | 157 | libgnunetregexblock.la \ |
158 | $(top_builddir)/src/dht/libgnunetdht.la \ | 158 | $(top_builddir)/src/dht/libgnunetdht.la \ |
159 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 159 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
160 | $(top_builddir)/src/util/libgnunetutil.la | 160 | $(top_builddir)/src/lib/util/libgnunetutil.la |
161 | 161 | ||
162 | test_regex_proofs_SOURCES = \ | 162 | test_regex_proofs_SOURCES = \ |
163 | $(REGEX_INTERNAL_TEST) test_regex_proofs.c | 163 | $(REGEX_INTERNAL_TEST) test_regex_proofs.c |
@@ -165,7 +165,7 @@ test_regex_proofs_LDADD = -lm \ | |||
165 | $(top_builddir)/src/dht/libgnunetdht.la \ | 165 | $(top_builddir)/src/dht/libgnunetdht.la \ |
166 | libgnunetregexblock.la \ | 166 | libgnunetregexblock.la \ |
167 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 167 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
168 | $(top_builddir)/src/util/libgnunetutil.la | 168 | $(top_builddir)/src/lib/util/libgnunetutil.la |
169 | 169 | ||
170 | test_regex_graph_api_SOURCES = \ | 170 | test_regex_graph_api_SOURCES = \ |
171 | $(REGEX_INTERNAL_TEST) test_regex_graph_api.c | 171 | $(REGEX_INTERNAL_TEST) test_regex_graph_api.c |
@@ -173,7 +173,7 @@ test_regex_graph_api_LDADD = -lm \ | |||
173 | $(top_builddir)/src/dht/libgnunetdht.la \ | 173 | $(top_builddir)/src/dht/libgnunetdht.la \ |
174 | libgnunetregexblock.la \ | 174 | libgnunetregexblock.la \ |
175 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 175 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
176 | $(top_builddir)/src/util/libgnunetutil.la | 176 | $(top_builddir)/src/lib/util/libgnunetutil.la |
177 | 177 | ||
178 | 178 | ||
179 | EXTRA_DIST = \ | 179 | EXTRA_DIST = \ |
diff --git a/src/rest/Makefile.am b/src/rest/Makefile.am index 41b4c6508..e3952a45e 100644 --- a/src/rest/Makefile.am +++ b/src/rest/Makefile.am | |||
@@ -32,7 +32,7 @@ libgnunet_plugin_rest_copying_la_SOURCES = \ | |||
32 | plugin_rest_copying.c | 32 | plugin_rest_copying.c |
33 | libgnunet_plugin_rest_copying_la_LIBADD = \ | 33 | libgnunet_plugin_rest_copying_la_LIBADD = \ |
34 | libgnunetrest.la \ | 34 | libgnunetrest.la \ |
35 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 35 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) \ |
36 | $(LTLIBINTL) $(MHD_LIBS) | 36 | $(LTLIBINTL) $(MHD_LIBS) |
37 | libgnunet_plugin_rest_copying_la_LDFLAGS = \ | 37 | libgnunet_plugin_rest_copying_la_LDFLAGS = \ |
38 | $(GN_PLUGIN_LDFLAGS) | 38 | $(GN_PLUGIN_LDFLAGS) |
@@ -42,7 +42,7 @@ libgnunet_plugin_rest_config_la_SOURCES = \ | |||
42 | plugin_rest_config.c | 42 | plugin_rest_config.c |
43 | libgnunet_plugin_rest_config_la_LIBADD = \ | 43 | libgnunet_plugin_rest_config_la_LIBADD = \ |
44 | libgnunetrest.la \ | 44 | libgnunetrest.la \ |
45 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 45 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIBS) \ |
46 | $(LTLIBINTL) $(MHD_LIBS) -ljansson | 46 | $(LTLIBINTL) $(MHD_LIBS) -ljansson |
47 | libgnunet_plugin_rest_config_la_LDFLAGS = \ | 47 | libgnunet_plugin_rest_config_la_LDFLAGS = \ |
48 | $(GN_PLUGIN_LDFLAGS) | 48 | $(GN_PLUGIN_LDFLAGS) |
@@ -53,14 +53,14 @@ libgnunet_plugin_rest_config_la_CFLAGS = $(MHD_CFLAGS) $(AM_CFLAGS) | |||
53 | gnunet_rest_server_SOURCES = \ | 53 | gnunet_rest_server_SOURCES = \ |
54 | gnunet-rest-server.c | 54 | gnunet-rest-server.c |
55 | gnunet_rest_server_LDADD = \ | 55 | gnunet_rest_server_LDADD = \ |
56 | $(top_builddir)/src/util/libgnunetutil.la \ | 56 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
57 | $(GN_LIBINTL) $(MHD_LIBS) | 57 | $(GN_LIBINTL) $(MHD_LIBS) |
58 | gnunet_rest_server_CFLAGS = $(MHD_CFLAGS) $(AM_CFLAGS) | 58 | gnunet_rest_server_CFLAGS = $(MHD_CFLAGS) $(AM_CFLAGS) |
59 | 59 | ||
60 | libgnunetrest_la_SOURCES = \ | 60 | libgnunetrest_la_SOURCES = \ |
61 | rest.c | 61 | rest.c |
62 | libgnunetrest_la_LIBADD = \ | 62 | libgnunetrest_la_LIBADD = \ |
63 | $(top_builddir)/src/util/libgnunetutil.la $(XLIB) \ | 63 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIB) \ |
64 | $(GN_LIBINTL) $(MHD_LIBS) | 64 | $(GN_LIBINTL) $(MHD_LIBS) |
65 | libgnunetrest_la_LDFLAGS = \ | 65 | libgnunetrest_la_LDFLAGS = \ |
66 | $(GN_LIB_LDFLAGS) \ | 66 | $(GN_LIB_LDFLAGS) \ |
diff --git a/src/revocation/Makefile.am b/src/revocation/Makefile.am index a375b7587..8afb58a80 100644 --- a/src/revocation/Makefile.am +++ b/src/revocation/Makefile.am | |||
@@ -25,9 +25,9 @@ libgnunet_plugin_block_revocation_la_SOURCES = \ | |||
25 | plugin_block_revocation.c | 25 | plugin_block_revocation.c |
26 | libgnunet_plugin_block_revocation_la_LIBADD = \ | 26 | libgnunet_plugin_block_revocation_la_LIBADD = \ |
27 | libgnunetrevocation.la \ | 27 | libgnunetrevocation.la \ |
28 | $(top_builddir)/src/block/libgnunetblockgroup.la \ | 28 | $(top_builddir)/src/lib/block/libgnunetblockgroup.la \ |
29 | $(top_builddir)/src/block/libgnunetblock.la \ | 29 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
30 | $(top_builddir)/src/util/libgnunetutil.la \ | 30 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
31 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 31 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
32 | $(LTLIBINTL) | 32 | $(LTLIBINTL) |
33 | libgnunet_plugin_block_revocation_la_LDFLAGS = \ | 33 | libgnunet_plugin_block_revocation_la_LDFLAGS = \ |
@@ -39,7 +39,7 @@ gnunet_revocation_SOURCES = \ | |||
39 | gnunet_revocation_LDADD = \ | 39 | gnunet_revocation_LDADD = \ |
40 | libgnunetrevocation.la \ | 40 | libgnunetrevocation.la \ |
41 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 41 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
42 | $(top_builddir)/src/util/libgnunetutil.la \ | 42 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
43 | $(GN_LIBINTL) | 43 | $(GN_LIBINTL) |
44 | 44 | ||
45 | gnunet_revocation_tvg_SOURCES = \ | 45 | gnunet_revocation_tvg_SOURCES = \ |
@@ -47,7 +47,7 @@ gnunet_revocation_tvg_SOURCES = \ | |||
47 | gnunet_revocation_tvg_LDADD = \ | 47 | gnunet_revocation_tvg_LDADD = \ |
48 | libgnunetrevocation.la \ | 48 | libgnunetrevocation.la \ |
49 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 49 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
50 | $(top_builddir)/src/util/libgnunetutil.la \ | 50 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
51 | $(GN_LIBINTL) | 51 | $(GN_LIBINTL) |
52 | 52 | ||
53 | test_revocation_lsd0001testvectors_SOURCES = \ | 53 | test_revocation_lsd0001testvectors_SOURCES = \ |
@@ -56,14 +56,14 @@ test_revocation_lsd0001testvectors_LDADD = \ | |||
56 | $(top_builddir)/src/testing/libgnunettesting.la \ | 56 | $(top_builddir)/src/testing/libgnunettesting.la \ |
57 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 57 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
58 | libgnunetrevocation.la \ | 58 | libgnunetrevocation.la \ |
59 | $(top_builddir)/src/util/libgnunetutil.la | 59 | $(top_builddir)/src/lib/util/libgnunetutil.la |
60 | 60 | ||
61 | lib_LTLIBRARIES = libgnunetrevocation.la | 61 | lib_LTLIBRARIES = libgnunetrevocation.la |
62 | 62 | ||
63 | libgnunetrevocation_la_SOURCES = \ | 63 | libgnunetrevocation_la_SOURCES = \ |
64 | revocation_api.c revocation.h | 64 | revocation_api.c revocation.h |
65 | libgnunetrevocation_la_LIBADD = \ | 65 | libgnunetrevocation_la_LIBADD = \ |
66 | $(top_builddir)/src/util/libgnunetutil.la \ | 66 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
67 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 67 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
68 | $(LIBGCRYPT_LIBS) \ | 68 | $(LIBGCRYPT_LIBS) \ |
69 | $(GN_LIBINTL) $(XLIB) -lgcrypt | 69 | $(GN_LIBINTL) $(XLIB) -lgcrypt |
@@ -85,7 +85,7 @@ gnunet_service_revocation_LDADD = \ | |||
85 | $(top_builddir)/src/setu/libgnunetsetu.la \ | 85 | $(top_builddir)/src/setu/libgnunetsetu.la \ |
86 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 86 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
87 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 87 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
88 | $(top_builddir)/src/util/libgnunetutil.la \ | 88 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
89 | -lm \ | 89 | -lm \ |
90 | $(GN_LIBINTL) | 90 | $(GN_LIBINTL) |
91 | 91 | ||
@@ -95,7 +95,7 @@ test_revocation_LDADD = \ | |||
95 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 95 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
96 | libgnunetrevocation.la \ | 96 | libgnunetrevocation.la \ |
97 | $(top_builddir)/src//core/libgnunetcore.la \ | 97 | $(top_builddir)/src//core/libgnunetcore.la \ |
98 | $(top_builddir)/src/util/libgnunetutil.la \ | 98 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
99 | $(top_builddir)/src/testbed/libgnunettestbed.la | 99 | $(top_builddir)/src/testbed/libgnunettestbed.la |
100 | 100 | ||
101 | check_PROGRAMS = \ | 101 | check_PROGRAMS = \ |
diff --git a/src/revocation/gnunet-revocation-tvg.c b/src/revocation/gnunet-revocation-tvg.c index e8b0820bb..b59b7ba62 100644 --- a/src/revocation/gnunet-revocation-tvg.c +++ b/src/revocation/gnunet-revocation-tvg.c | |||
@@ -101,25 +101,25 @@ print_bytes (void *buf, | |||
101 | 101 | ||
102 | 102 | ||
103 | static void | 103 | static void |
104 | run_with_key (struct GNUNET_IDENTITY_PrivateKey *id_priv) | 104 | run_with_key (struct GNUNET_CRYPTO_PrivateKey *id_priv) |
105 | { | 105 | { |
106 | struct GNUNET_IDENTITY_PublicKey id_pub; | 106 | struct GNUNET_CRYPTO_PublicKey id_pub; |
107 | struct GNUNET_REVOCATION_PowP *pow; | 107 | struct GNUNET_REVOCATION_PowP *pow; |
108 | struct GNUNET_REVOCATION_PowCalculationHandle *ph; | 108 | struct GNUNET_REVOCATION_PowCalculationHandle *ph; |
109 | struct GNUNET_TIME_Relative exp; | 109 | struct GNUNET_TIME_Relative exp; |
110 | char ztld[128]; | 110 | char ztld[128]; |
111 | ssize_t key_len; | 111 | ssize_t key_len; |
112 | 112 | ||
113 | GNUNET_IDENTITY_key_get_public (id_priv, | 113 | GNUNET_CRYPTO_key_get_public (id_priv, |
114 | &id_pub); | 114 | &id_pub); |
115 | GNUNET_STRINGS_data_to_string (&id_pub, | 115 | GNUNET_STRINGS_data_to_string (&id_pub, |
116 | GNUNET_IDENTITY_public_key_get_length ( | 116 | GNUNET_CRYPTO_public_key_get_length ( |
117 | &id_pub), | 117 | &id_pub), |
118 | ztld, | 118 | ztld, |
119 | sizeof (ztld)); | 119 | sizeof (ztld)); |
120 | fprintf (stdout, "\n"); | 120 | fprintf (stdout, "\n"); |
121 | fprintf (stdout, "Zone identifier (ztype|zkey):\n"); | 121 | fprintf (stdout, "Zone identifier (ztype|zkey):\n"); |
122 | key_len = GNUNET_IDENTITY_public_key_get_length (&id_pub); | 122 | key_len = GNUNET_CRYPTO_public_key_get_length (&id_pub); |
123 | GNUNET_assert (0 < key_len); | 123 | GNUNET_assert (0 < key_len); |
124 | print_bytes (&id_pub, key_len, 8); | 124 | print_bytes (&id_pub, key_len, 8); |
125 | fprintf (stdout, "\n"); | 125 | fprintf (stdout, "\n"); |
@@ -178,16 +178,16 @@ run (void *cls, | |||
178 | const char *cfgfile, | 178 | const char *cfgfile, |
179 | const struct GNUNET_CONFIGURATION_Handle *cfg) | 179 | const struct GNUNET_CONFIGURATION_Handle *cfg) |
180 | { | 180 | { |
181 | struct GNUNET_IDENTITY_PrivateKey id_priv; | 181 | struct GNUNET_CRYPTO_PrivateKey id_priv; |
182 | 182 | ||
183 | id_priv.type = htonl (GNUNET_IDENTITY_TYPE_ECDSA); | 183 | id_priv.type = htonl (GNUNET_PUBLIC_KEY_TYPE_ECDSA); |
184 | parsehex (d_pkey,(char*) &id_priv.ecdsa_key, sizeof (id_priv.ecdsa_key), 1); | 184 | parsehex (d_pkey,(char*) &id_priv.ecdsa_key, sizeof (id_priv.ecdsa_key), 1); |
185 | 185 | ||
186 | fprintf (stdout, "Zone private key (d, big-endian):\n"); | 186 | fprintf (stdout, "Zone private key (d, big-endian):\n"); |
187 | print_bytes_ (&id_priv.ecdsa_key, sizeof(id_priv.ecdsa_key), 8, 1); | 187 | print_bytes_ (&id_priv.ecdsa_key, sizeof(id_priv.ecdsa_key), 8, 1); |
188 | run_with_key (&id_priv); | 188 | run_with_key (&id_priv); |
189 | printf ("\n"); | 189 | printf ("\n"); |
190 | id_priv.type = htonl (GNUNET_IDENTITY_TYPE_EDDSA); | 190 | id_priv.type = htonl (GNUNET_PUBLIC_KEY_TYPE_EDDSA); |
191 | parsehex (d_edkey,(char*) &id_priv.eddsa_key, sizeof (id_priv.eddsa_key), 0); | 191 | parsehex (d_edkey,(char*) &id_priv.eddsa_key, sizeof (id_priv.eddsa_key), 0); |
192 | 192 | ||
193 | fprintf (stdout, "Zone private key (d):\n"); | 193 | fprintf (stdout, "Zone private key (d):\n"); |
diff --git a/src/revocation/gnunet-revocation.c b/src/revocation/gnunet-revocation.c index 853ca0f71..9667e7655 100644 --- a/src/revocation/gnunet-revocation.c +++ b/src/revocation/gnunet-revocation.c | |||
@@ -323,8 +323,8 @@ calculate_pow (void *cls) | |||
323 | static void | 323 | static void |
324 | ego_callback (void *cls, struct GNUNET_IDENTITY_Ego *ego) | 324 | ego_callback (void *cls, struct GNUNET_IDENTITY_Ego *ego) |
325 | { | 325 | { |
326 | struct GNUNET_IDENTITY_PublicKey key; | 326 | struct GNUNET_CRYPTO_PublicKey key; |
327 | const struct GNUNET_IDENTITY_PrivateKey *privkey; | 327 | const struct GNUNET_CRYPTO_PrivateKey *privkey; |
328 | struct GNUNET_REVOCATION_PowCalculationHandle *ph = NULL; | 328 | struct GNUNET_REVOCATION_PowCalculationHandle *ph = NULL; |
329 | size_t psize; | 329 | size_t psize; |
330 | 330 | ||
@@ -343,7 +343,7 @@ ego_callback (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
343 | GNUNET_DISK_fn_read (filename, proof_of_work, | 343 | GNUNET_DISK_fn_read (filename, proof_of_work, |
344 | GNUNET_REVOCATION_MAX_PROOF_SIZE)))) | 344 | GNUNET_REVOCATION_MAX_PROOF_SIZE)))) |
345 | { | 345 | { |
346 | ssize_t ksize = GNUNET_IDENTITY_public_key_get_length (&key); | 346 | ssize_t ksize = GNUNET_CRYPTO_public_key_get_length (&key); |
347 | if (0 > ksize) | 347 | if (0 > ksize) |
348 | { | 348 | { |
349 | fprintf (stderr, | 349 | fprintf (stderr, |
@@ -411,14 +411,14 @@ run (void *cls, | |||
411 | const char *cfgfile, | 411 | const char *cfgfile, |
412 | const struct GNUNET_CONFIGURATION_Handle *c) | 412 | const struct GNUNET_CONFIGURATION_Handle *c) |
413 | { | 413 | { |
414 | struct GNUNET_IDENTITY_PublicKey pk; | 414 | struct GNUNET_CRYPTO_PublicKey pk; |
415 | size_t psize; | 415 | size_t psize; |
416 | 416 | ||
417 | cfg = c; | 417 | cfg = c; |
418 | if (NULL != test_ego) | 418 | if (NULL != test_ego) |
419 | { | 419 | { |
420 | if (GNUNET_OK != | 420 | if (GNUNET_OK != |
421 | GNUNET_IDENTITY_public_key_from_string (test_ego, | 421 | GNUNET_CRYPTO_public_key_from_string (test_ego, |
422 | &pk)) | 422 | &pk)) |
423 | { | 423 | { |
424 | fprintf (stderr, _ ("Public key `%s' malformed\n"), test_ego); | 424 | fprintf (stderr, _ ("Public key `%s' malformed\n"), test_ego); |
diff --git a/src/revocation/gnunet-service-revocation.c b/src/revocation/gnunet-service-revocation.c index 2cee70857..3755b87e5 100644 --- a/src/revocation/gnunet-service-revocation.c +++ b/src/revocation/gnunet-service-revocation.c | |||
@@ -250,7 +250,7 @@ handle_query_message (void *cls, | |||
250 | const struct QueryMessage *qm) | 250 | const struct QueryMessage *qm) |
251 | { | 251 | { |
252 | struct GNUNET_SERVICE_Client *client = cls; | 252 | struct GNUNET_SERVICE_Client *client = cls; |
253 | struct GNUNET_IDENTITY_PublicKey zone; | 253 | struct GNUNET_CRYPTO_PublicKey zone; |
254 | struct GNUNET_MQ_Envelope *env; | 254 | struct GNUNET_MQ_Envelope *env; |
255 | struct QueryResponseMessage *qrm; | 255 | struct QueryResponseMessage *qrm; |
256 | struct GNUNET_HashCode hc; | 256 | struct GNUNET_HashCode hc; |
@@ -260,7 +260,7 @@ handle_query_message (void *cls, | |||
260 | 260 | ||
261 | key_len = ntohl (qm->key_len); | 261 | key_len = ntohl (qm->key_len); |
262 | if ((GNUNET_SYSERR == | 262 | if ((GNUNET_SYSERR == |
263 | GNUNET_IDENTITY_read_public_key_from_buffer (&qm[1], key_len, | 263 | GNUNET_CRYPTO_read_public_key_from_buffer (&qm[1], key_len, |
264 | &zone, &read)) || | 264 | &zone, &read)) || |
265 | (read != key_len)) | 265 | (read != key_len)) |
266 | { | 266 | { |
@@ -344,11 +344,11 @@ publicize_rm (const struct RevokeMessage *rm) | |||
344 | ssize_t pklen; | 344 | ssize_t pklen; |
345 | const struct GNUNET_REVOCATION_PowP *pow | 345 | const struct GNUNET_REVOCATION_PowP *pow |
346 | = (const struct GNUNET_REVOCATION_PowP *) &rm[1]; | 346 | = (const struct GNUNET_REVOCATION_PowP *) &rm[1]; |
347 | const struct GNUNET_IDENTITY_PublicKey *pk | 347 | const struct GNUNET_CRYPTO_PublicKey *pk |
348 | = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | 348 | = (const struct GNUNET_CRYPTO_PublicKey *) &pow[1]; |
349 | 349 | ||
350 | /** FIXME yeah this works, but should we have a key length somewhere? */ | 350 | /** FIXME yeah this works, but should we have a key length somewhere? */ |
351 | pklen = GNUNET_IDENTITY_public_key_get_length (pk); | 351 | pklen = GNUNET_CRYPTO_public_key_get_length (pk); |
352 | if (0 > pklen) | 352 | if (0 > pklen) |
353 | { | 353 | { |
354 | GNUNET_break_op (0); | 354 | GNUNET_break_op (0); |
@@ -879,7 +879,7 @@ run (void *cls, | |||
879 | uint64_t left; | 879 | uint64_t left; |
880 | struct RevokeMessage *rm; | 880 | struct RevokeMessage *rm; |
881 | struct GNUNET_HashCode hc; | 881 | struct GNUNET_HashCode hc; |
882 | const struct GNUNET_IDENTITY_PublicKey *pk; | 882 | const struct GNUNET_CRYPTO_PublicKey *pk; |
883 | 883 | ||
884 | GNUNET_CRYPTO_hash ("revocation-set-union-application-id", | 884 | GNUNET_CRYPTO_hash ("revocation-set-union-application-id", |
885 | strlen ("revocation-set-union-application-id"), | 885 | strlen ("revocation-set-union-application-id"), |
@@ -983,8 +983,8 @@ run (void *cls, | |||
983 | struct GNUNET_REVOCATION_PowP *pow = (struct | 983 | struct GNUNET_REVOCATION_PowP *pow = (struct |
984 | GNUNET_REVOCATION_PowP *) &rm[1]; | 984 | GNUNET_REVOCATION_PowP *) &rm[1]; |
985 | ssize_t ksize; | 985 | ssize_t ksize; |
986 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | 986 | pk = (const struct GNUNET_CRYPTO_PublicKey *) &pow[1]; |
987 | ksize = GNUNET_IDENTITY_public_key_get_length (pk); | 987 | ksize = GNUNET_CRYPTO_public_key_get_length (pk); |
988 | if (0 > ksize) | 988 | if (0 > ksize) |
989 | { | 989 | { |
990 | GNUNET_break_op (0); | 990 | GNUNET_break_op (0); |
diff --git a/src/revocation/plugin_block_revocation.c b/src/revocation/plugin_block_revocation.c index 7de4fafe9..9686f23ff 100644 --- a/src/revocation/plugin_block_revocation.c +++ b/src/revocation/plugin_block_revocation.c | |||
@@ -94,7 +94,7 @@ block_plugin_revocation_check_block (void *cls, | |||
94 | const struct RevokeMessage *rm = block; | 94 | const struct RevokeMessage *rm = block; |
95 | const struct GNUNET_REVOCATION_PowP *pow | 95 | const struct GNUNET_REVOCATION_PowP *pow |
96 | = (const struct GNUNET_REVOCATION_PowP *) &rm[1]; | 96 | = (const struct GNUNET_REVOCATION_PowP *) &rm[1]; |
97 | struct GNUNET_IDENTITY_PublicKey pk; | 97 | struct GNUNET_CRYPTO_PublicKey pk; |
98 | size_t pklen; | 98 | size_t pklen; |
99 | size_t left; | 99 | size_t left; |
100 | 100 | ||
@@ -115,7 +115,7 @@ block_plugin_revocation_check_block (void *cls, | |||
115 | } | 115 | } |
116 | left = block_size - sizeof (*rm) - sizeof (*pow); | 116 | left = block_size - sizeof (*rm) - sizeof (*pow); |
117 | if (GNUNET_SYSERR == | 117 | if (GNUNET_SYSERR == |
118 | GNUNET_IDENTITY_read_public_key_from_buffer (&pow[1], | 118 | GNUNET_CRYPTO_read_public_key_from_buffer (&pow[1], |
119 | left, | 119 | left, |
120 | &pk, | 120 | &pk, |
121 | &pklen)) | 121 | &pklen)) |
@@ -204,7 +204,7 @@ block_plugin_revocation_get_key (void *cls, | |||
204 | const struct RevokeMessage *rm = block; | 204 | const struct RevokeMessage *rm = block; |
205 | const struct GNUNET_REVOCATION_PowP *pow | 205 | const struct GNUNET_REVOCATION_PowP *pow |
206 | = (const struct GNUNET_REVOCATION_PowP *) &rm[1]; | 206 | = (const struct GNUNET_REVOCATION_PowP *) &rm[1]; |
207 | struct GNUNET_IDENTITY_PublicKey pk; | 207 | struct GNUNET_CRYPTO_PublicKey pk; |
208 | size_t pklen; | 208 | size_t pklen; |
209 | size_t left; | 209 | size_t left; |
210 | 210 | ||
@@ -224,7 +224,7 @@ block_plugin_revocation_get_key (void *cls, | |||
224 | return GNUNET_NO; | 224 | return GNUNET_NO; |
225 | } | 225 | } |
226 | left = block_size - sizeof (*rm) - sizeof (*pow); | 226 | left = block_size - sizeof (*rm) - sizeof (*pow); |
227 | if (GNUNET_SYSERR == GNUNET_IDENTITY_read_public_key_from_buffer (&pow[1], | 227 | if (GNUNET_SYSERR == GNUNET_CRYPTO_read_public_key_from_buffer (&pow[1], |
228 | left, | 228 | left, |
229 | &pk, | 229 | &pk, |
230 | &pklen)) | 230 | &pklen)) |
diff --git a/src/revocation/revocation_api.c b/src/revocation/revocation_api.c index 819c34b71..3b7d83710 100644 --- a/src/revocation/revocation_api.c +++ b/src/revocation/revocation_api.c | |||
@@ -160,7 +160,7 @@ handle_revocation_query_response (void *cls, | |||
160 | */ | 160 | */ |
161 | struct GNUNET_REVOCATION_Query * | 161 | struct GNUNET_REVOCATION_Query * |
162 | GNUNET_REVOCATION_query (const struct GNUNET_CONFIGURATION_Handle *cfg, | 162 | GNUNET_REVOCATION_query (const struct GNUNET_CONFIGURATION_Handle *cfg, |
163 | const struct GNUNET_IDENTITY_PublicKey *key, | 163 | const struct GNUNET_CRYPTO_PublicKey *key, |
164 | GNUNET_REVOCATION_Callback func, | 164 | GNUNET_REVOCATION_Callback func, |
165 | void *func_cls) | 165 | void *func_cls) |
166 | { | 166 | { |
@@ -189,10 +189,10 @@ GNUNET_REVOCATION_query (const struct GNUNET_CONFIGURATION_Handle *cfg, | |||
189 | } | 189 | } |
190 | q->func = func; | 190 | q->func = func; |
191 | q->func_cls = func_cls; | 191 | q->func_cls = func_cls; |
192 | key_len = GNUNET_IDENTITY_public_key_get_length (key); | 192 | key_len = GNUNET_CRYPTO_public_key_get_length (key); |
193 | env = GNUNET_MQ_msg_extra (qm, key_len, | 193 | env = GNUNET_MQ_msg_extra (qm, key_len, |
194 | GNUNET_MESSAGE_TYPE_REVOCATION_QUERY); | 194 | GNUNET_MESSAGE_TYPE_REVOCATION_QUERY); |
195 | GNUNET_IDENTITY_write_public_key_to_buffer (key, &qm[1], key_len); | 195 | GNUNET_CRYPTO_write_public_key_to_buffer (key, &qm[1], key_len); |
196 | qm->key_len = htonl (key_len); | 196 | qm->key_len = htonl (key_len); |
197 | GNUNET_MQ_send (q->mq, | 197 | GNUNET_MQ_send (q->mq, |
198 | env); | 198 | env); |
@@ -406,16 +406,16 @@ struct GNUNET_REVOCATION_SignaturePurposePS * | |||
406 | REV_create_signature_message (const struct GNUNET_REVOCATION_PowP *pow) | 406 | REV_create_signature_message (const struct GNUNET_REVOCATION_PowP *pow) |
407 | { | 407 | { |
408 | struct GNUNET_REVOCATION_SignaturePurposePS *spurp; | 408 | struct GNUNET_REVOCATION_SignaturePurposePS *spurp; |
409 | const struct GNUNET_IDENTITY_PublicKey *pk; | 409 | const struct GNUNET_CRYPTO_PublicKey *pk; |
410 | size_t ksize; | 410 | size_t ksize; |
411 | 411 | ||
412 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | 412 | pk = (const struct GNUNET_CRYPTO_PublicKey *) &pow[1]; |
413 | ksize = GNUNET_IDENTITY_public_key_get_length (pk); | 413 | ksize = GNUNET_CRYPTO_public_key_get_length (pk); |
414 | spurp = GNUNET_malloc (sizeof (*spurp) + ksize); | 414 | spurp = GNUNET_malloc (sizeof (*spurp) + ksize); |
415 | spurp->timestamp = pow->timestamp; | 415 | spurp->timestamp = pow->timestamp; |
416 | spurp->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_GNS_REVOCATION); | 416 | spurp->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_GNS_REVOCATION); |
417 | spurp->purpose.size = htonl (sizeof(*spurp) + ksize); | 417 | spurp->purpose.size = htonl (sizeof(*spurp) + ksize); |
418 | GNUNET_IDENTITY_write_public_key_to_buffer (pk, | 418 | GNUNET_CRYPTO_write_public_key_to_buffer (pk, |
419 | (char*) &spurp[1], | 419 | (char*) &spurp[1], |
420 | ksize); | 420 | ksize); |
421 | return spurp; | 421 | return spurp; |
@@ -424,18 +424,18 @@ REV_create_signature_message (const struct GNUNET_REVOCATION_PowP *pow) | |||
424 | 424 | ||
425 | enum GNUNET_GenericReturnValue | 425 | enum GNUNET_GenericReturnValue |
426 | check_signature_identity (const struct GNUNET_REVOCATION_PowP *pow, | 426 | check_signature_identity (const struct GNUNET_REVOCATION_PowP *pow, |
427 | const struct GNUNET_IDENTITY_PublicKey *key) | 427 | const struct GNUNET_CRYPTO_PublicKey *key) |
428 | { | 428 | { |
429 | struct GNUNET_REVOCATION_SignaturePurposePS *spurp; | 429 | struct GNUNET_REVOCATION_SignaturePurposePS *spurp; |
430 | unsigned char *sig; | 430 | unsigned char *sig; |
431 | size_t ksize; | 431 | size_t ksize; |
432 | int ret; | 432 | int ret; |
433 | 433 | ||
434 | ksize = GNUNET_IDENTITY_public_key_get_length (key); | 434 | ksize = GNUNET_CRYPTO_public_key_get_length (key); |
435 | spurp = REV_create_signature_message (pow); | 435 | spurp = REV_create_signature_message (pow); |
436 | sig = ((unsigned char*) &pow[1] + ksize); | 436 | sig = ((unsigned char*) &pow[1] + ksize); |
437 | ret = | 437 | ret = |
438 | GNUNET_IDENTITY_signature_verify_raw_ ( | 438 | GNUNET_CRYPTO_signature_verify_raw_ ( |
439 | GNUNET_SIGNATURE_PURPOSE_GNS_REVOCATION, | 439 | GNUNET_SIGNATURE_PURPOSE_GNS_REVOCATION, |
440 | &spurp->purpose, | 440 | &spurp->purpose, |
441 | sig, | 441 | sig, |
@@ -448,9 +448,9 @@ check_signature_identity (const struct GNUNET_REVOCATION_PowP *pow, | |||
448 | enum GNUNET_GenericReturnValue | 448 | enum GNUNET_GenericReturnValue |
449 | check_signature (const struct GNUNET_REVOCATION_PowP *pow) | 449 | check_signature (const struct GNUNET_REVOCATION_PowP *pow) |
450 | { | 450 | { |
451 | const struct GNUNET_IDENTITY_PublicKey *pk; | 451 | const struct GNUNET_CRYPTO_PublicKey *pk; |
452 | 452 | ||
453 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | 453 | pk = (const struct GNUNET_CRYPTO_PublicKey *) &pow[1]; |
454 | return check_signature_identity (pow, pk); | 454 | return check_signature_identity (pow, pk); |
455 | } | 455 | } |
456 | 456 | ||
@@ -468,7 +468,7 @@ GNUNET_REVOCATION_check_pow (const struct GNUNET_REVOCATION_PowP *pow, | |||
468 | unsigned int difficulty, | 468 | unsigned int difficulty, |
469 | struct GNUNET_TIME_Relative epoch_duration) | 469 | struct GNUNET_TIME_Relative epoch_duration) |
470 | { | 470 | { |
471 | char buf[sizeof(struct GNUNET_IDENTITY_PublicKey) | 471 | char buf[sizeof(struct GNUNET_CRYPTO_PublicKey) |
472 | + sizeof (struct GNUNET_TIME_AbsoluteNBO) | 472 | + sizeof (struct GNUNET_TIME_AbsoluteNBO) |
473 | + sizeof (uint64_t)] GNUNET_ALIGN; | 473 | + sizeof (uint64_t)] GNUNET_ALIGN; |
474 | struct GNUNET_HashCode result; | 474 | struct GNUNET_HashCode result; |
@@ -482,9 +482,9 @@ GNUNET_REVOCATION_check_pow (const struct GNUNET_REVOCATION_PowP *pow, | |||
482 | unsigned int epochs; | 482 | unsigned int epochs; |
483 | uint64_t pow_val; | 483 | uint64_t pow_val; |
484 | ssize_t pklen; | 484 | ssize_t pklen; |
485 | const struct GNUNET_IDENTITY_PublicKey *pk; | 485 | const struct GNUNET_CRYPTO_PublicKey *pk; |
486 | 486 | ||
487 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | 487 | pk = (const struct GNUNET_CRYPTO_PublicKey *) &pow[1]; |
488 | 488 | ||
489 | /** | 489 | /** |
490 | * Check if signature valid | 490 | * Check if signature valid |
@@ -507,7 +507,7 @@ GNUNET_REVOCATION_check_pow (const struct GNUNET_REVOCATION_PowP *pow, | |||
507 | GNUNET_memcpy (&buf[sizeof(uint64_t)], | 507 | GNUNET_memcpy (&buf[sizeof(uint64_t)], |
508 | &pow->timestamp, | 508 | &pow->timestamp, |
509 | sizeof (uint64_t)); | 509 | sizeof (uint64_t)); |
510 | pklen = GNUNET_IDENTITY_public_key_get_length (pk); | 510 | pklen = GNUNET_CRYPTO_public_key_get_length (pk); |
511 | if (0 > pklen) | 511 | if (0 > pklen) |
512 | { | 512 | { |
513 | GNUNET_break (0); | 513 | GNUNET_break (0); |
@@ -566,12 +566,12 @@ GNUNET_REVOCATION_check_pow (const struct GNUNET_REVOCATION_PowP *pow, | |||
566 | 566 | ||
567 | 567 | ||
568 | enum GNUNET_GenericReturnValue | 568 | enum GNUNET_GenericReturnValue |
569 | sign_pow_identity (const struct GNUNET_IDENTITY_PrivateKey *key, | 569 | sign_pow_identity (const struct GNUNET_CRYPTO_PrivateKey *key, |
570 | struct GNUNET_REVOCATION_PowP *pow) | 570 | struct GNUNET_REVOCATION_PowP *pow) |
571 | { | 571 | { |
572 | struct GNUNET_TIME_Absolute ts = GNUNET_TIME_absolute_get (); | 572 | struct GNUNET_TIME_Absolute ts = GNUNET_TIME_absolute_get (); |
573 | struct GNUNET_REVOCATION_SignaturePurposePS *rp; | 573 | struct GNUNET_REVOCATION_SignaturePurposePS *rp; |
574 | const struct GNUNET_IDENTITY_PublicKey *pk; | 574 | const struct GNUNET_CRYPTO_PublicKey *pk; |
575 | size_t ksize; | 575 | size_t ksize; |
576 | char *sig; | 576 | char *sig; |
577 | 577 | ||
@@ -581,12 +581,12 @@ sign_pow_identity (const struct GNUNET_IDENTITY_PrivateKey *key, | |||
581 | */ | 581 | */ |
582 | ts = GNUNET_TIME_absolute_subtract (ts, | 582 | ts = GNUNET_TIME_absolute_subtract (ts, |
583 | GNUNET_TIME_UNIT_WEEKS); | 583 | GNUNET_TIME_UNIT_WEEKS); |
584 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | 584 | pk = (const struct GNUNET_CRYPTO_PublicKey *) &pow[1]; |
585 | ksize = GNUNET_IDENTITY_public_key_get_length (pk); | 585 | ksize = GNUNET_CRYPTO_public_key_get_length (pk); |
586 | pow->timestamp = GNUNET_TIME_absolute_hton (ts); | 586 | pow->timestamp = GNUNET_TIME_absolute_hton (ts); |
587 | rp = REV_create_signature_message (pow); | 587 | rp = REV_create_signature_message (pow); |
588 | sig = ((char*) &pow[1]) + ksize; | 588 | sig = ((char*) &pow[1]) + ksize; |
589 | int result = GNUNET_IDENTITY_sign_raw_ (key, | 589 | int result = GNUNET_CRYPTO_sign_raw_ (key, |
590 | &rp->purpose, | 590 | &rp->purpose, |
591 | (void*) sig); | 591 | (void*) sig); |
592 | GNUNET_free (rp); | 592 | GNUNET_free (rp); |
@@ -598,13 +598,13 @@ sign_pow_identity (const struct GNUNET_IDENTITY_PrivateKey *key, | |||
598 | 598 | ||
599 | 599 | ||
600 | enum GNUNET_GenericReturnValue | 600 | enum GNUNET_GenericReturnValue |
601 | sign_pow (const struct GNUNET_IDENTITY_PrivateKey *key, | 601 | sign_pow (const struct GNUNET_CRYPTO_PrivateKey *key, |
602 | struct GNUNET_REVOCATION_PowP *pow) | 602 | struct GNUNET_REVOCATION_PowP *pow) |
603 | { | 603 | { |
604 | struct GNUNET_IDENTITY_PublicKey *pk; | 604 | struct GNUNET_CRYPTO_PublicKey *pk; |
605 | 605 | ||
606 | pk = (struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | 606 | pk = (struct GNUNET_CRYPTO_PublicKey *) &pow[1]; |
607 | GNUNET_IDENTITY_key_get_public (key, pk); | 607 | GNUNET_CRYPTO_key_get_public (key, pk); |
608 | return sign_pow_identity (key, pow); | 608 | return sign_pow_identity (key, pow); |
609 | } | 609 | } |
610 | 610 | ||
@@ -616,7 +616,7 @@ sign_pow (const struct GNUNET_IDENTITY_PrivateKey *key, | |||
616 | * @param[out] pow starting point for PoW calculation (not yet valid) | 616 | * @param[out] pow starting point for PoW calculation (not yet valid) |
617 | */ | 617 | */ |
618 | void | 618 | void |
619 | GNUNET_REVOCATION_pow_init (const struct GNUNET_IDENTITY_PrivateKey *key, | 619 | GNUNET_REVOCATION_pow_init (const struct GNUNET_CRYPTO_PrivateKey *key, |
620 | struct GNUNET_REVOCATION_PowP *pow) | 620 | struct GNUNET_REVOCATION_PowP *pow) |
621 | { | 621 | { |
622 | GNUNET_assert (GNUNET_OK == sign_pow (key, pow)); | 622 | GNUNET_assert (GNUNET_OK == sign_pow (key, pow)); |
@@ -672,18 +672,18 @@ cmp_pow_value (const void *a, const void *b) | |||
672 | enum GNUNET_GenericReturnValue | 672 | enum GNUNET_GenericReturnValue |
673 | GNUNET_REVOCATION_pow_round (struct GNUNET_REVOCATION_PowCalculationHandle *pc) | 673 | GNUNET_REVOCATION_pow_round (struct GNUNET_REVOCATION_PowCalculationHandle *pc) |
674 | { | 674 | { |
675 | char buf[sizeof(struct GNUNET_IDENTITY_PublicKey) | 675 | char buf[sizeof(struct GNUNET_CRYPTO_PublicKey) |
676 | + sizeof (uint64_t) | 676 | + sizeof (uint64_t) |
677 | + sizeof (uint64_t)] GNUNET_ALIGN; | 677 | + sizeof (uint64_t)] GNUNET_ALIGN; |
678 | struct GNUNET_HashCode result; | 678 | struct GNUNET_HashCode result; |
679 | const struct GNUNET_IDENTITY_PublicKey *pk; | 679 | const struct GNUNET_CRYPTO_PublicKey *pk; |
680 | unsigned int zeros; | 680 | unsigned int zeros; |
681 | int ret; | 681 | int ret; |
682 | uint64_t pow_nbo; | 682 | uint64_t pow_nbo; |
683 | ssize_t ksize; | 683 | ssize_t ksize; |
684 | 684 | ||
685 | pc->current_pow++; | 685 | pc->current_pow++; |
686 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &(pc->pow[1]); | 686 | pk = (const struct GNUNET_CRYPTO_PublicKey *) &(pc->pow[1]); |
687 | 687 | ||
688 | /** | 688 | /** |
689 | * Do not try duplicates | 689 | * Do not try duplicates |
@@ -696,7 +696,7 @@ GNUNET_REVOCATION_pow_round (struct GNUNET_REVOCATION_PowCalculationHandle *pc) | |||
696 | GNUNET_memcpy (&buf[sizeof(uint64_t)], | 696 | GNUNET_memcpy (&buf[sizeof(uint64_t)], |
697 | &pc->pow->timestamp, | 697 | &pc->pow->timestamp, |
698 | sizeof (uint64_t)); | 698 | sizeof (uint64_t)); |
699 | ksize = GNUNET_IDENTITY_public_key_get_length (pk); | 699 | ksize = GNUNET_CRYPTO_public_key_get_length (pk); |
700 | GNUNET_assert (0 < ksize); | 700 | GNUNET_assert (0 < ksize); |
701 | GNUNET_memcpy (&buf[sizeof(uint64_t) * 2], | 701 | GNUNET_memcpy (&buf[sizeof(uint64_t) * 2], |
702 | pk, | 702 | pk, |
@@ -750,13 +750,13 @@ GNUNET_REVOCATION_proof_get_size (const struct GNUNET_REVOCATION_PowP *pow) | |||
750 | { | 750 | { |
751 | size_t size; | 751 | size_t size; |
752 | size_t ksize; | 752 | size_t ksize; |
753 | const struct GNUNET_IDENTITY_PublicKey *pk; | 753 | const struct GNUNET_CRYPTO_PublicKey *pk; |
754 | 754 | ||
755 | size = sizeof (struct GNUNET_REVOCATION_PowP); | 755 | size = sizeof (struct GNUNET_REVOCATION_PowP); |
756 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | 756 | pk = (const struct GNUNET_CRYPTO_PublicKey *) &pow[1]; |
757 | ksize = GNUNET_IDENTITY_public_key_get_length (pk); | 757 | ksize = GNUNET_CRYPTO_public_key_get_length (pk); |
758 | size += ksize; | 758 | size += ksize; |
759 | size += GNUNET_IDENTITY_signature_get_raw_length_by_type (pk->type); | 759 | size += GNUNET_CRYPTO_signature_get_raw_length_by_type (pk->type); |
760 | return size; | 760 | return size; |
761 | } | 761 | } |
762 | 762 | ||
diff --git a/src/revocation/test_revocation.c b/src/revocation/test_revocation.c index e6dd1a0db..0fc3ac7e5 100644 --- a/src/revocation/test_revocation.c +++ b/src/revocation/test_revocation.c | |||
@@ -38,8 +38,8 @@ struct TestPeer | |||
38 | struct GNUNET_TESTBED_Operation *core_op; | 38 | struct GNUNET_TESTBED_Operation *core_op; |
39 | struct GNUNET_IDENTITY_Handle *idh; | 39 | struct GNUNET_IDENTITY_Handle *idh; |
40 | const struct GNUNET_CONFIGURATION_Handle *cfg; | 40 | const struct GNUNET_CONFIGURATION_Handle *cfg; |
41 | const struct GNUNET_IDENTITY_PrivateKey *privkey; | 41 | const struct GNUNET_CRYPTO_PrivateKey *privkey; |
42 | struct GNUNET_IDENTITY_PublicKey pubkey; | 42 | struct GNUNET_CRYPTO_PublicKey pubkey; |
43 | struct GNUNET_CRYPTO_EcdsaSignature sig; | 43 | struct GNUNET_CRYPTO_EcdsaSignature sig; |
44 | struct GNUNET_IDENTITY_Operation *create_id_op; | 44 | struct GNUNET_IDENTITY_Operation *create_id_op; |
45 | struct GNUNET_IDENTITY_EgoLookup *ego_lookup; | 45 | struct GNUNET_IDENTITY_EgoLookup *ego_lookup; |
@@ -148,7 +148,7 @@ static void | |||
148 | ego_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) | 148 | ego_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) |
149 | { | 149 | { |
150 | static int completed = 0; | 150 | static int completed = 0; |
151 | const struct GNUNET_IDENTITY_PrivateKey *privkey; | 151 | const struct GNUNET_CRYPTO_PrivateKey *privkey; |
152 | 152 | ||
153 | if ((NULL != ego) && (cls == &testpeers[0])) | 153 | if ((NULL != ego) && (cls == &testpeers[0])) |
154 | { | 154 | { |
@@ -194,7 +194,7 @@ ego_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
194 | 194 | ||
195 | static void | 195 | static void |
196 | identity_create_cb (void *cls, | 196 | identity_create_cb (void *cls, |
197 | const struct GNUNET_IDENTITY_PrivateKey *pk, | 197 | const struct GNUNET_CRYPTO_PrivateKey *pk, |
198 | enum GNUNET_ErrorCode ec) | 198 | enum GNUNET_ErrorCode ec) |
199 | { | 199 | { |
200 | static int completed = 0; | 200 | static int completed = 0; |
@@ -238,13 +238,13 @@ identity_completion_cb (void *cls, | |||
238 | testpeers[0].create_id_op = GNUNET_IDENTITY_create (testpeers[0].idh, | 238 | testpeers[0].create_id_op = GNUNET_IDENTITY_create (testpeers[0].idh, |
239 | "client", | 239 | "client", |
240 | NULL, | 240 | NULL, |
241 | GNUNET_IDENTITY_TYPE_ECDSA, | 241 | GNUNET_PUBLIC_KEY_TYPE_ECDSA, |
242 | &identity_create_cb, | 242 | &identity_create_cb, |
243 | &testpeers[0]); | 243 | &testpeers[0]); |
244 | testpeers[1].create_id_op = GNUNET_IDENTITY_create (testpeers[1].idh, | 244 | testpeers[1].create_id_op = GNUNET_IDENTITY_create (testpeers[1].idh, |
245 | "toberevoked", | 245 | "toberevoked", |
246 | NULL, | 246 | NULL, |
247 | GNUNET_IDENTITY_TYPE_ECDSA, | 247 | GNUNET_PUBLIC_KEY_TYPE_ECDSA, |
248 | &identity_create_cb, | 248 | &identity_create_cb, |
249 | &testpeers[1]); | 249 | &testpeers[1]); |
250 | } | 250 | } |
diff --git a/src/revocation/test_revocation_testvectors.c b/src/revocation/test_revocation_testvectors.c index 355576fb7..a669e1b7e 100644 --- a/src/revocation/test_revocation_testvectors.c +++ b/src/revocation/test_revocation_testvectors.c | |||
@@ -239,9 +239,9 @@ parsehex (char *src, char *dst, size_t dstlen, int invert) | |||
239 | int | 239 | int |
240 | main () | 240 | main () |
241 | { | 241 | { |
242 | struct GNUNET_IDENTITY_PrivateKey priv; | 242 | struct GNUNET_CRYPTO_PrivateKey priv; |
243 | struct GNUNET_IDENTITY_PublicKey pub; | 243 | struct GNUNET_CRYPTO_PublicKey pub; |
244 | struct GNUNET_IDENTITY_PublicKey pub_parsed; | 244 | struct GNUNET_CRYPTO_PublicKey pub_parsed; |
245 | struct GNUNET_TIME_Relative exprel; | 245 | struct GNUNET_TIME_Relative exprel; |
246 | struct GNUNET_REVOCATION_PowP *pow; | 246 | struct GNUNET_REVOCATION_PowP *pow; |
247 | char m[8096]; | 247 | char m[8096]; |
@@ -255,8 +255,8 @@ main () | |||
255 | parsehex (rtvs[i].d,(char*) &priv.ecdsa_key, sizeof (priv.ecdsa_key), | 255 | parsehex (rtvs[i].d,(char*) &priv.ecdsa_key, sizeof (priv.ecdsa_key), |
256 | (GNUNET_GNSRECORD_TYPE_PKEY == ntohl (pub_parsed.type)) ? 1 : 0); | 256 | (GNUNET_GNSRECORD_TYPE_PKEY == ntohl (pub_parsed.type)) ? 1 : 0); |
257 | priv.type = pub_parsed.type; | 257 | priv.type = pub_parsed.type; |
258 | GNUNET_IDENTITY_key_get_public (&priv, &pub); | 258 | GNUNET_CRYPTO_key_get_public (&priv, &pub); |
259 | if (0 != memcmp (&pub, &pub_parsed, GNUNET_IDENTITY_public_key_get_length ( | 259 | if (0 != memcmp (&pub, &pub_parsed, GNUNET_CRYPTO_public_key_get_length ( |
260 | &pub))) | 260 | &pub))) |
261 | { | 261 | { |
262 | printf ("Wrong pubkey.\n"); | 262 | printf ("Wrong pubkey.\n"); |
@@ -266,7 +266,7 @@ main () | |||
266 | break; | 266 | break; |
267 | } | 267 | } |
268 | GNUNET_STRINGS_data_to_string (&pub, | 268 | GNUNET_STRINGS_data_to_string (&pub, |
269 | GNUNET_IDENTITY_public_key_get_length ( | 269 | GNUNET_CRYPTO_public_key_get_length ( |
270 | &pub), | 270 | &pub), |
271 | ztld, | 271 | ztld, |
272 | sizeof (ztld)); | 272 | sizeof (ztld)); |
diff --git a/src/rps/Makefile.am b/src/rps/Makefile.am index db3174a82..bf34a29d7 100644 --- a/src/rps/Makefile.am +++ b/src/rps/Makefile.am | |||
@@ -20,7 +20,7 @@ gnunet_rps_SOURCES = \ | |||
20 | 20 | ||
21 | gnunet_rps_LDADD = \ | 21 | gnunet_rps_LDADD = \ |
22 | libgnunetrps.la \ | 22 | libgnunetrps.la \ |
23 | $(top_builddir)/src/util/libgnunetutil.la \ | 23 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
24 | $(XLIB) $(GN_LIBINTL) | 24 | $(XLIB) $(GN_LIBINTL) |
25 | 25 | ||
26 | lib_LTLIBRARIES = libgnunetrps.la | 26 | lib_LTLIBRARIES = libgnunetrps.la |
@@ -33,7 +33,7 @@ libgnunetrps_la_SOURCES = \ | |||
33 | rps_api.c rps.h | 33 | rps_api.c rps.h |
34 | libgnunetrps_la_LIBADD = \ | 34 | libgnunetrps_la_LIBADD = \ |
35 | $(top_builddir)/src/nse/libgnunetnse.la \ | 35 | $(top_builddir)/src/nse/libgnunetnse.la \ |
36 | $(top_builddir)/src/util/libgnunetutil.la \ | 36 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
37 | $(GN_LIBINTL) $(XLIB) | 37 | $(GN_LIBINTL) $(XLIB) |
38 | libgnunetrps_la_LDFLAGS = \ | 38 | libgnunetrps_la_LDFLAGS = \ |
39 | $(GN_LIB_LDFLAGS) \ | 39 | $(GN_LIB_LDFLAGS) \ |
@@ -60,7 +60,7 @@ gnunet_service_rps_SOURCES = \ | |||
60 | 60 | ||
61 | gnunet_service_rps_LDADD = \ | 61 | gnunet_service_rps_LDADD = \ |
62 | libgnunetrps.la \ | 62 | libgnunetrps.la \ |
63 | $(top_builddir)/src/util/libgnunetutil.la \ | 63 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
64 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 64 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
65 | $(top_builddir)/src/cadet/libgnunetcadet.la \ | 65 | $(top_builddir)/src/cadet/libgnunetcadet.la \ |
66 | $(top_builddir)/src/nse/libgnunetnse.la \ | 66 | $(top_builddir)/src/nse/libgnunetnse.la \ |
@@ -95,7 +95,7 @@ rps_test_src = \ | |||
95 | 95 | ||
96 | #ld_rps_test_lib = \ | 96 | #ld_rps_test_lib = \ |
97 | # libgnunetrps.la \ | 97 | # libgnunetrps.la \ |
98 | # $(top_builddir)/src/util/libgnunetutil.la \ | 98 | # $(top_builddir)/src/lib/util/libgnunetutil.la \ |
99 | # $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 99 | # $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
100 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ | 100 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ |
101 | # -lm | 101 | # -lm |
@@ -108,19 +108,19 @@ endif | |||
108 | test_service_rps_view_SOURCES = \ | 108 | test_service_rps_view_SOURCES = \ |
109 | gnunet-service-rps_view.h gnunet-service-rps_view.c \ | 109 | gnunet-service-rps_view.h gnunet-service-rps_view.c \ |
110 | test_service_rps_view.c | 110 | test_service_rps_view.c |
111 | test_service_rps_view_LDADD = $(top_builddir)/src/util/libgnunetutil.la | 111 | test_service_rps_view_LDADD = $(top_builddir)/src/lib/util/libgnunetutil.la |
112 | 112 | ||
113 | test_service_rps_custommap_SOURCES = \ | 113 | test_service_rps_custommap_SOURCES = \ |
114 | gnunet-service-rps_custommap.h gnunet-service-rps_custommap.c \ | 114 | gnunet-service-rps_custommap.h gnunet-service-rps_custommap.c \ |
115 | test_service_rps_custommap.c | 115 | test_service_rps_custommap.c |
116 | test_service_rps_custommap_LDADD = \ | 116 | test_service_rps_custommap_LDADD = \ |
117 | $(top_builddir)/src/util/libgnunetutil.la | 117 | $(top_builddir)/src/lib/util/libgnunetutil.la |
118 | 118 | ||
119 | test_service_rps_sampler_elem_SOURCES = \ | 119 | test_service_rps_sampler_elem_SOURCES = \ |
120 | gnunet-service-rps_sampler_elem.h gnunet-service-rps_sampler_elem.c \ | 120 | gnunet-service-rps_sampler_elem.h gnunet-service-rps_sampler_elem.c \ |
121 | rps-test_util.h rps-test_util.c \ | 121 | rps-test_util.h rps-test_util.c \ |
122 | test_service_rps_sampler_elem.c | 122 | test_service_rps_sampler_elem.c |
123 | test_service_rps_sampler_elem_LDADD = $(top_builddir)/src/util/libgnunetutil.la | 123 | test_service_rps_sampler_elem_LDADD = $(top_builddir)/src/lib/util/libgnunetutil.la |
124 | 124 | ||
125 | #test_rps_single_req_SOURCES = $(rps_test_src) | 125 | #test_rps_single_req_SOURCES = $(rps_test_src) |
126 | #test_rps_single_req_LDADD = $(ld_rps_test_lib) | 126 | #test_rps_single_req_LDADD = $(ld_rps_test_lib) |
@@ -158,7 +158,7 @@ test_service_rps_sampler_elem_LDADD = $(top_builddir)/src/util/libgnunetutil.la | |||
158 | #gnunet_rps_profiler_LDADD = \ | 158 | #gnunet_rps_profiler_LDADD = \ |
159 | # $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 159 | # $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
160 | # libgnunetrps.la \ | 160 | # libgnunetrps.la \ |
161 | # $(top_builddir)/src/util/libgnunetutil.la \ | 161 | # $(top_builddir)/src/lib/util/libgnunetutil.la \ |
162 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ | 162 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ |
163 | # -lm | 163 | # -lm |
164 | 164 | ||
diff --git a/src/scalarproduct/Makefile.am b/src/scalarproduct/Makefile.am index 8b3b160c6..ef9f8b245 100644 --- a/src/scalarproduct/Makefile.am +++ b/src/scalarproduct/Makefile.am | |||
@@ -27,7 +27,7 @@ lib_LTLIBRARIES = \ | |||
27 | gnunet_scalarproduct_SOURCES = \ | 27 | gnunet_scalarproduct_SOURCES = \ |
28 | gnunet-scalarproduct.c | 28 | gnunet-scalarproduct.c |
29 | gnunet_scalarproduct_LDADD = \ | 29 | gnunet_scalarproduct_LDADD = \ |
30 | $(top_builddir)/src/util/libgnunetutil.la \ | 30 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
31 | libgnunetscalarproduct.la \ | 31 | libgnunetscalarproduct.la \ |
32 | $(LIBGCRYPT_LIBS) \ | 32 | $(LIBGCRYPT_LIBS) \ |
33 | -lgcrypt \ | 33 | -lgcrypt \ |
@@ -37,7 +37,7 @@ gnunet_service_scalarproduct_alice_SOURCES = \ | |||
37 | gnunet-service-scalarproduct.h \ | 37 | gnunet-service-scalarproduct.h \ |
38 | gnunet-service-scalarproduct_alice.c | 38 | gnunet-service-scalarproduct_alice.c |
39 | gnunet_service_scalarproduct_alice_LDADD = \ | 39 | gnunet_service_scalarproduct_alice_LDADD = \ |
40 | $(top_builddir)/src/util/libgnunetutil.la \ | 40 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
41 | $(top_builddir)/src/cadet/libgnunetcadet.la \ | 41 | $(top_builddir)/src/cadet/libgnunetcadet.la \ |
42 | $(top_builddir)/src/seti/libgnunetseti.la \ | 42 | $(top_builddir)/src/seti/libgnunetseti.la \ |
43 | $(LIBGCRYPT_LIBS) \ | 43 | $(LIBGCRYPT_LIBS) \ |
@@ -48,7 +48,7 @@ gnunet_service_scalarproduct_bob_SOURCES = \ | |||
48 | gnunet-service-scalarproduct.h \ | 48 | gnunet-service-scalarproduct.h \ |
49 | gnunet-service-scalarproduct_bob.c | 49 | gnunet-service-scalarproduct_bob.c |
50 | gnunet_service_scalarproduct_bob_LDADD = \ | 50 | gnunet_service_scalarproduct_bob_LDADD = \ |
51 | $(top_builddir)/src/util/libgnunetutil.la \ | 51 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
52 | $(top_builddir)/src/cadet/libgnunetcadet.la \ | 52 | $(top_builddir)/src/cadet/libgnunetcadet.la \ |
53 | $(top_builddir)/src/seti/libgnunetseti.la \ | 53 | $(top_builddir)/src/seti/libgnunetseti.la \ |
54 | $(LIBGCRYPT_LIBS) \ | 54 | $(LIBGCRYPT_LIBS) \ |
@@ -59,7 +59,7 @@ gnunet_service_scalarproduct_ecc_alice_SOURCES = \ | |||
59 | gnunet-service-scalarproduct-ecc.h \ | 59 | gnunet-service-scalarproduct-ecc.h \ |
60 | gnunet-service-scalarproduct-ecc_alice.c | 60 | gnunet-service-scalarproduct-ecc_alice.c |
61 | gnunet_service_scalarproduct_ecc_alice_LDADD = \ | 61 | gnunet_service_scalarproduct_ecc_alice_LDADD = \ |
62 | $(top_builddir)/src/util/libgnunetutil.la \ | 62 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
63 | $(top_builddir)/src/cadet/libgnunetcadet.la \ | 63 | $(top_builddir)/src/cadet/libgnunetcadet.la \ |
64 | $(top_builddir)/src/seti/libgnunetseti.la \ | 64 | $(top_builddir)/src/seti/libgnunetseti.la \ |
65 | $(LIBGCRYPT_LIBS) \ | 65 | $(LIBGCRYPT_LIBS) \ |
@@ -71,7 +71,7 @@ gnunet_service_scalarproduct_ecc_bob_SOURCES = \ | |||
71 | gnunet-service-scalarproduct-ecc.h \ | 71 | gnunet-service-scalarproduct-ecc.h \ |
72 | gnunet-service-scalarproduct-ecc_bob.c | 72 | gnunet-service-scalarproduct-ecc_bob.c |
73 | gnunet_service_scalarproduct_ecc_bob_LDADD = \ | 73 | gnunet_service_scalarproduct_ecc_bob_LDADD = \ |
74 | $(top_builddir)/src/util/libgnunetutil.la \ | 74 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
75 | $(top_builddir)/src/cadet/libgnunetcadet.la \ | 75 | $(top_builddir)/src/cadet/libgnunetcadet.la \ |
76 | $(top_builddir)/src/seti/libgnunetseti.la \ | 76 | $(top_builddir)/src/seti/libgnunetseti.la \ |
77 | $(LIBGCRYPT_LIBS) \ | 77 | $(LIBGCRYPT_LIBS) \ |
@@ -83,7 +83,7 @@ libgnunetscalarproduct_la_SOURCES = \ | |||
83 | scalarproduct_api.c \ | 83 | scalarproduct_api.c \ |
84 | scalarproduct.h | 84 | scalarproduct.h |
85 | libgnunetscalarproduct_la_LIBADD = \ | 85 | libgnunetscalarproduct_la_LIBADD = \ |
86 | $(top_builddir)/src/util/libgnunetutil.la \ | 86 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
87 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 87 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
88 | $(LIBGCRYPT_LIBS) \ | 88 | $(LIBGCRYPT_LIBS) \ |
89 | -lgcrypt \ | 89 | -lgcrypt \ |
@@ -112,5 +112,5 @@ endif | |||
112 | test_ecc_scalarproduct_SOURCES = \ | 112 | test_ecc_scalarproduct_SOURCES = \ |
113 | test_ecc_scalarproduct.c | 113 | test_ecc_scalarproduct.c |
114 | test_ecc_scalarproduct_LDADD = \ | 114 | test_ecc_scalarproduct_LDADD = \ |
115 | $(top_builddir)/src/util/libgnunetutil.la \ | 115 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
116 | -lsodium | 116 | -lsodium |
diff --git a/src/secretsharing/Makefile.am b/src/secretsharing/Makefile.am index 3a86236cd..30b3f8057 100644 --- a/src/secretsharing/Makefile.am +++ b/src/secretsharing/Makefile.am | |||
@@ -30,7 +30,7 @@ lib_LTLIBRARIES = \ | |||
30 | # libgnunetsecretsharing.la \ | 30 | # libgnunetsecretsharing.la \ |
31 | # $(top_builddir)/src/testing/libgnunettesting.la \ | 31 | # $(top_builddir)/src/testing/libgnunettesting.la \ |
32 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ | 32 | # $(top_builddir)/src/testbed/libgnunettestbed.la \ |
33 | # $(top_builddir)/src/util/libgnunetutil.la \ | 33 | # $(top_builddir)/src/lib/util/libgnunetutil.la \ |
34 | # $(GN_LIBINTL) | 34 | # $(GN_LIBINTL) |
35 | 35 | ||
36 | gnunet_service_secretsharing_SOURCES = \ | 36 | gnunet_service_secretsharing_SOURCES = \ |
@@ -39,7 +39,7 @@ gnunet_service_secretsharing_SOURCES = \ | |||
39 | secretsharing_protocol.h | 39 | secretsharing_protocol.h |
40 | gnunet_service_secretsharing_CFLAGS = $(AM_CFLAGS) | 40 | gnunet_service_secretsharing_CFLAGS = $(AM_CFLAGS) |
41 | gnunet_service_secretsharing_LDADD = \ | 41 | gnunet_service_secretsharing_LDADD = \ |
42 | $(top_builddir)/src/util/libgnunetutil.la \ | 42 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
43 | $(top_builddir)/src/consensus/libgnunetconsensus.la \ | 43 | $(top_builddir)/src/consensus/libgnunetconsensus.la \ |
44 | $(LIBGCRYPT_LIBS) \ | 44 | $(LIBGCRYPT_LIBS) \ |
45 | $(GN_LIBINTL) | 45 | $(GN_LIBINTL) |
@@ -49,7 +49,7 @@ libgnunetsecretsharing_la_SOURCES = \ | |||
49 | secretsharing_common.c \ | 49 | secretsharing_common.c \ |
50 | secretsharing.h | 50 | secretsharing.h |
51 | libgnunetsecretsharing_la_LIBADD = \ | 51 | libgnunetsecretsharing_la_LIBADD = \ |
52 | $(top_builddir)/src/util/libgnunetutil.la \ | 52 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
53 | $(LIBGCRYPT_LIBS) \ | 53 | $(LIBGCRYPT_LIBS) \ |
54 | $(LTLIBINTL) | 54 | $(LTLIBINTL) |
55 | libgnunetsecretsharing_la_LDFLAGS = \ | 55 | libgnunetsecretsharing_la_LDFLAGS = \ |
@@ -68,7 +68,7 @@ test_secretsharing_api_SOURCES = \ | |||
68 | test_secretsharing_api_LDADD = \ | 68 | test_secretsharing_api_LDADD = \ |
69 | libgnunetsecretsharing.la \ | 69 | libgnunetsecretsharing.la \ |
70 | $(top_builddir)/src/testing/libgnunettesting.la \ | 70 | $(top_builddir)/src/testing/libgnunettesting.la \ |
71 | $(top_builddir)/src/util/libgnunetutil.la | 71 | $(top_builddir)/src/lib/util/libgnunetutil.la |
72 | 72 | ||
73 | EXTRA_DIST = \ | 73 | EXTRA_DIST = \ |
74 | test_secretsharing.conf | 74 | test_secretsharing.conf |
diff --git a/src/service/Makefile.am b/src/service/Makefile.am new file mode 100644 index 000000000..d94046cde --- /dev/null +++ b/src/service/Makefile.am | |||
@@ -0,0 +1,2 @@ | |||
1 | SUBDIRS = \ | ||
2 | util | ||
diff --git a/src/service/util/.gitignore b/src/service/util/.gitignore new file mode 100644 index 000000000..9e00297f1 --- /dev/null +++ b/src/service/util/.gitignore | |||
@@ -0,0 +1,2 @@ | |||
1 | gnunet-service-resolver | ||
2 | test_resolver_api.nc | ||
diff --git a/src/service/util/Makefile.am b/src/service/util/Makefile.am new file mode 100644 index 000000000..ecd1f5e1b --- /dev/null +++ b/src/service/util/Makefile.am | |||
@@ -0,0 +1,47 @@ | |||
1 | # This Makefile.am is in the public domain | ||
2 | AM_CPPFLAGS = -I$(top_srcdir)/src/include | ||
3 | |||
4 | plugindir = $(libdir)/gnunet | ||
5 | |||
6 | libexecdir= $(pkglibdir)/libexec/ | ||
7 | |||
8 | pkgcfgdir= $(pkgdatadir)/config.d/ | ||
9 | |||
10 | if USE_COVERAGE | ||
11 | AM_CFLAGS = --coverage -O0 | ||
12 | XLIB = -lgcov | ||
13 | endif | ||
14 | |||
15 | libexec_PROGRAMS = \ | ||
16 | gnunet-service-resolver | ||
17 | |||
18 | if ENABLE_TEST_RUN | ||
19 | AM_TESTS_ENVIRONMENT=export GNUNET_PREFIX=$${GNUNET_PREFIX:-@libdir@};export PATH=$${GNUNET_PREFIX:-@prefix@}/bin:$$PATH;unset XDG_DATA_HOME;unset XDG_CONFIG_HOME; | ||
20 | TESTS = $(check_PROGRAMS) $(check_SCRIPTS) | ||
21 | endif | ||
22 | |||
23 | gnunet_service_resolver_SOURCES = \ | ||
24 | gnunet-service-resolver.c | ||
25 | gnunet_service_resolver_LDADD = \ | ||
26 | $(top_builddir)/src/lib/util/libgnunetutil.la \ | ||
27 | $(GN_LIBINTL) | ||
28 | if HAVE_GETADDRINFO_A | ||
29 | gnunet_service_resolver_LDADD += -lanl | ||
30 | endif | ||
31 | |||
32 | |||
33 | check_PROGRAMS = \ | ||
34 | test_resolver_api.nc | ||
35 | |||
36 | # Declare .nc (NO-CONCURRENCY) as a test extension so that we can impart | ||
37 | # sequential execution order for them | ||
38 | TEST_EXTENSIONS = .nc | ||
39 | test_test_client_unix.log: test_client.log | ||
40 | |||
41 | test_resolver_api_nc_SOURCES = \ | ||
42 | test_resolver_api.c | ||
43 | test_resolver_api_nc_LDADD = \ | ||
44 | $(top_builddir)/src/lib/util/libgnunetutil.la | ||
45 | |||
46 | EXTRA_DIST = \ | ||
47 | test_resolver_api_data.conf | ||
diff --git a/src/util/gnunet-service-resolver.c b/src/service/util/gnunet-service-resolver.c index 77b57c72b..8d57738ed 100644 --- a/src/util/gnunet-service-resolver.c +++ b/src/service/util/gnunet-service-resolver.c | |||
@@ -28,7 +28,7 @@ | |||
28 | #include "gnunet_util_lib.h" | 28 | #include "gnunet_util_lib.h" |
29 | #include "gnunet_protocols.h" | 29 | #include "gnunet_protocols.h" |
30 | #include "gnunet_statistics_service.h" | 30 | #include "gnunet_statistics_service.h" |
31 | #include "resolver.h" | 31 | #include "../../lib/util/resolver.h" |
32 | 32 | ||
33 | 33 | ||
34 | /** | 34 | /** |
diff --git a/src/util/test_resolver_api.c b/src/service/util/test_resolver_api.c index 5ad0c6bf3..5ad0c6bf3 100644 --- a/src/util/test_resolver_api.c +++ b/src/service/util/test_resolver_api.c | |||
diff --git a/src/util/test_resolver_api_data.conf b/src/service/util/test_resolver_api_data.conf index dd4384b80..dd4384b80 100644 --- a/src/util/test_resolver_api_data.conf +++ b/src/service/util/test_resolver_api_data.conf | |||
diff --git a/src/set/Makefile.am b/src/set/Makefile.am index a9e39a728..7433226a3 100644 --- a/src/set/Makefile.am +++ b/src/set/Makefile.am | |||
@@ -27,7 +27,7 @@ lib_LTLIBRARIES = \ | |||
27 | gnunet_set_profiler_SOURCES = \ | 27 | gnunet_set_profiler_SOURCES = \ |
28 | gnunet-set-profiler.c | 28 | gnunet-set-profiler.c |
29 | gnunet_set_profiler_LDADD = \ | 29 | gnunet_set_profiler_LDADD = \ |
30 | $(top_builddir)/src/util/libgnunetutil.la \ | 30 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
31 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 31 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
32 | libgnunetset.la \ | 32 | libgnunetset.la \ |
33 | $(top_builddir)/src/testing/libgnunettesting.la \ | 33 | $(top_builddir)/src/testing/libgnunettesting.la \ |
@@ -38,7 +38,7 @@ gnunet_set_ibf_profiler_SOURCES = \ | |||
38 | gnunet-set-ibf-profiler.c \ | 38 | gnunet-set-ibf-profiler.c \ |
39 | ibf.c | 39 | ibf.c |
40 | gnunet_set_ibf_profiler_LDADD = \ | 40 | gnunet_set_ibf_profiler_LDADD = \ |
41 | $(top_builddir)/src/util/libgnunetutil.la \ | 41 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
42 | $(GN_LIBINTL) | 42 | $(GN_LIBINTL) |
43 | 43 | ||
44 | gnunet_service_set_SOURCES = \ | 44 | gnunet_service_set_SOURCES = \ |
@@ -49,18 +49,18 @@ gnunet_service_set_SOURCES = \ | |||
49 | gnunet-service-set_union_strata_estimator.c gnunet-service-set_union_strata_estimator.h \ | 49 | gnunet-service-set_union_strata_estimator.c gnunet-service-set_union_strata_estimator.h \ |
50 | gnunet-service-set_protocol.h | 50 | gnunet-service-set_protocol.h |
51 | gnunet_service_set_LDADD = \ | 51 | gnunet_service_set_LDADD = \ |
52 | $(top_builddir)/src/util/libgnunetutil.la \ | 52 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
53 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 53 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
54 | $(top_builddir)/src/core/libgnunetcore.la \ | 54 | $(top_builddir)/src/core/libgnunetcore.la \ |
55 | $(top_builddir)/src/cadet/libgnunetcadet.la \ | 55 | $(top_builddir)/src/cadet/libgnunetcadet.la \ |
56 | $(top_builddir)/src/block/libgnunetblock.la \ | 56 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
57 | libgnunetset.la \ | 57 | libgnunetset.la \ |
58 | $(GN_LIBINTL) | 58 | $(GN_LIBINTL) |
59 | 59 | ||
60 | libgnunetset_la_SOURCES = \ | 60 | libgnunetset_la_SOURCES = \ |
61 | set_api.c set.h | 61 | set_api.c set.h |
62 | libgnunetset_la_LIBADD = \ | 62 | libgnunetset_la_LIBADD = \ |
63 | $(top_builddir)/src/util/libgnunetutil.la \ | 63 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
64 | $(LTLIBINTL) | 64 | $(LTLIBINTL) |
65 | libgnunetset_la_LDFLAGS = \ | 65 | libgnunetset_la_LDFLAGS = \ |
66 | $(GN_LIB_LDFLAGS) | 66 | $(GN_LIB_LDFLAGS) |
@@ -79,28 +79,28 @@ endif | |||
79 | test_set_api_SOURCES = \ | 79 | test_set_api_SOURCES = \ |
80 | test_set_api.c | 80 | test_set_api.c |
81 | test_set_api_LDADD = \ | 81 | test_set_api_LDADD = \ |
82 | $(top_builddir)/src/util/libgnunetutil.la \ | 82 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
83 | $(top_builddir)/src/testing/libgnunettesting.la \ | 83 | $(top_builddir)/src/testing/libgnunettesting.la \ |
84 | libgnunetset.la | 84 | libgnunetset.la |
85 | 85 | ||
86 | test_set_union_result_symmetric_SOURCES = \ | 86 | test_set_union_result_symmetric_SOURCES = \ |
87 | test_set_union_result_symmetric.c | 87 | test_set_union_result_symmetric.c |
88 | test_set_union_result_symmetric_LDADD = \ | 88 | test_set_union_result_symmetric_LDADD = \ |
89 | $(top_builddir)/src/util/libgnunetutil.la \ | 89 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
90 | $(top_builddir)/src/testing/libgnunettesting.la \ | 90 | $(top_builddir)/src/testing/libgnunettesting.la \ |
91 | libgnunetset.la | 91 | libgnunetset.la |
92 | 92 | ||
93 | test_set_intersection_result_full_SOURCES = \ | 93 | test_set_intersection_result_full_SOURCES = \ |
94 | test_set_intersection_result_full.c | 94 | test_set_intersection_result_full.c |
95 | test_set_intersection_result_full_LDADD = \ | 95 | test_set_intersection_result_full_LDADD = \ |
96 | $(top_builddir)/src/util/libgnunetutil.la \ | 96 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
97 | $(top_builddir)/src/testing/libgnunettesting.la \ | 97 | $(top_builddir)/src/testing/libgnunettesting.la \ |
98 | libgnunetset.la | 98 | libgnunetset.la |
99 | 99 | ||
100 | test_set_union_copy_SOURCES = \ | 100 | test_set_union_copy_SOURCES = \ |
101 | test_set_union_copy.c | 101 | test_set_union_copy.c |
102 | test_set_union_copy_LDADD = \ | 102 | test_set_union_copy_LDADD = \ |
103 | $(top_builddir)/src/util/libgnunetutil.la \ | 103 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
104 | $(top_builddir)/src/testing/libgnunettesting.la \ | 104 | $(top_builddir)/src/testing/libgnunettesting.la \ |
105 | libgnunetset.la | 105 | libgnunetset.la |
106 | 106 | ||
@@ -110,9 +110,9 @@ plugin_LTLIBRARIES = \ | |||
110 | libgnunet_plugin_block_set_test_la_SOURCES = \ | 110 | libgnunet_plugin_block_set_test_la_SOURCES = \ |
111 | plugin_block_set_test.c | 111 | plugin_block_set_test.c |
112 | libgnunet_plugin_block_set_test_la_LIBADD = \ | 112 | libgnunet_plugin_block_set_test_la_LIBADD = \ |
113 | $(top_builddir)/src/block/libgnunetblock.la \ | 113 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
114 | $(top_builddir)/src/block/libgnunetblockgroup.la \ | 114 | $(top_builddir)/src/lib/block/libgnunetblockgroup.la \ |
115 | $(top_builddir)/src/util/libgnunetutil.la \ | 115 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
116 | $(LTLIBINTL) | 116 | $(LTLIBINTL) |
117 | libgnunet_plugin_block_set_test_la_LDFLAGS = \ | 117 | libgnunet_plugin_block_set_test_la_LDFLAGS = \ |
118 | $(GN_PLUGIN_LDFLAGS) | 118 | $(GN_PLUGIN_LDFLAGS) |
diff --git a/src/seti/Makefile.am b/src/seti/Makefile.am index 6b0df430b..6292dce0a 100644 --- a/src/seti/Makefile.am +++ b/src/seti/Makefile.am | |||
@@ -26,7 +26,7 @@ lib_LTLIBRARIES = \ | |||
26 | gnunet_seti_profiler_SOURCES = \ | 26 | gnunet_seti_profiler_SOURCES = \ |
27 | gnunet-seti-profiler.c | 27 | gnunet-seti-profiler.c |
28 | gnunet_seti_profiler_LDADD = \ | 28 | gnunet_seti_profiler_LDADD = \ |
29 | $(top_builddir)/src/util/libgnunetutil.la \ | 29 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
30 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 30 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
31 | libgnunetseti.la \ | 31 | libgnunetseti.la \ |
32 | $(top_builddir)/src/testing/libgnunettesting.la \ | 32 | $(top_builddir)/src/testing/libgnunettesting.la \ |
@@ -37,18 +37,18 @@ gnunet_service_seti_SOURCES = \ | |||
37 | gnunet-service-seti.c \ | 37 | gnunet-service-seti.c \ |
38 | gnunet-service-seti_protocol.h | 38 | gnunet-service-seti_protocol.h |
39 | gnunet_service_seti_LDADD = \ | 39 | gnunet_service_seti_LDADD = \ |
40 | $(top_builddir)/src/util/libgnunetutil.la \ | 40 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
41 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 41 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
42 | $(top_builddir)/src/core/libgnunetcore.la \ | 42 | $(top_builddir)/src/core/libgnunetcore.la \ |
43 | $(top_builddir)/src/cadet/libgnunetcadet.la \ | 43 | $(top_builddir)/src/cadet/libgnunetcadet.la \ |
44 | $(top_builddir)/src/block/libgnunetblock.la \ | 44 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
45 | libgnunetseti.la \ | 45 | libgnunetseti.la \ |
46 | $(GN_LIBINTL) | 46 | $(GN_LIBINTL) |
47 | 47 | ||
48 | libgnunetseti_la_SOURCES = \ | 48 | libgnunetseti_la_SOURCES = \ |
49 | seti_api.c seti.h | 49 | seti_api.c seti.h |
50 | libgnunetseti_la_LIBADD = \ | 50 | libgnunetseti_la_LIBADD = \ |
51 | $(top_builddir)/src/util/libgnunetutil.la \ | 51 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
52 | $(LTLIBINTL) | 52 | $(LTLIBINTL) |
53 | libgnunetseti_la_LDFLAGS = \ | 53 | libgnunetseti_la_LDFLAGS = \ |
54 | $(GN_LIB_LDFLAGS) | 54 | $(GN_LIB_LDFLAGS) |
@@ -64,7 +64,7 @@ endif | |||
64 | test_seti_api_SOURCES = \ | 64 | test_seti_api_SOURCES = \ |
65 | test_seti_api.c | 65 | test_seti_api.c |
66 | test_seti_api_LDADD = \ | 66 | test_seti_api_LDADD = \ |
67 | $(top_builddir)/src/util/libgnunetutil.la \ | 67 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
68 | $(top_builddir)/src/testing/libgnunettesting.la \ | 68 | $(top_builddir)/src/testing/libgnunettesting.la \ |
69 | libgnunetseti.la | 69 | libgnunetseti.la |
70 | 70 | ||
@@ -74,9 +74,9 @@ plugin_LTLIBRARIES = \ | |||
74 | libgnunet_plugin_block_seti_test_la_SOURCES = \ | 74 | libgnunet_plugin_block_seti_test_la_SOURCES = \ |
75 | plugin_block_seti_test.c | 75 | plugin_block_seti_test.c |
76 | libgnunet_plugin_block_seti_test_la_LIBADD = \ | 76 | libgnunet_plugin_block_seti_test_la_LIBADD = \ |
77 | $(top_builddir)/src/block/libgnunetblock.la \ | 77 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
78 | $(top_builddir)/src/block/libgnunetblockgroup.la \ | 78 | $(top_builddir)/src/lib/block/libgnunetblockgroup.la \ |
79 | $(top_builddir)/src/util/libgnunetutil.la \ | 79 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
80 | $(LTLIBINTL) | 80 | $(LTLIBINTL) |
81 | libgnunet_plugin_block_seti_test_la_LDFLAGS = \ | 81 | libgnunet_plugin_block_seti_test_la_LDFLAGS = \ |
82 | $(GN_PLUGIN_LDFLAGS) | 82 | $(GN_PLUGIN_LDFLAGS) |
diff --git a/src/setu/Makefile.am b/src/setu/Makefile.am index 377fe82c3..32ccc7b26 100644 --- a/src/setu/Makefile.am +++ b/src/setu/Makefile.am | |||
@@ -27,7 +27,7 @@ lib_LTLIBRARIES = \ | |||
27 | gnunet_setu_profiler_SOURCES = \ | 27 | gnunet_setu_profiler_SOURCES = \ |
28 | gnunet-setu-profiler.c | 28 | gnunet-setu-profiler.c |
29 | gnunet_setu_profiler_LDADD = \ | 29 | gnunet_setu_profiler_LDADD = \ |
30 | $(top_builddir)/src/util/libgnunetutil.la \ | 30 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
31 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 31 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
32 | libgnunetsetu.la \ | 32 | libgnunetsetu.la \ |
33 | $(top_builddir)/src/testing/libgnunettesting.la \ | 33 | $(top_builddir)/src/testing/libgnunettesting.la \ |
@@ -38,7 +38,7 @@ gnunet_setu_ibf_profiler_SOURCES = \ | |||
38 | gnunet-setu-ibf-profiler.c \ | 38 | gnunet-setu-ibf-profiler.c \ |
39 | ibf.c | 39 | ibf.c |
40 | gnunet_setu_ibf_profiler_LDADD = \ | 40 | gnunet_setu_ibf_profiler_LDADD = \ |
41 | $(top_builddir)/src/util/libgnunetutil.la \ | 41 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
42 | $(GN_LIBINTL) | 42 | $(GN_LIBINTL) |
43 | 43 | ||
44 | gnunet_service_setu_SOURCES = \ | 44 | gnunet_service_setu_SOURCES = \ |
@@ -47,18 +47,18 @@ gnunet_service_setu_SOURCES = \ | |||
47 | gnunet-service-setu_strata_estimator.c gnunet-service-setu_strata_estimator.h \ | 47 | gnunet-service-setu_strata_estimator.c gnunet-service-setu_strata_estimator.h \ |
48 | gnunet-service-setu_protocol.h | 48 | gnunet-service-setu_protocol.h |
49 | gnunet_service_setu_LDADD = \ | 49 | gnunet_service_setu_LDADD = \ |
50 | $(top_builddir)/src/util/libgnunetutil.la \ | 50 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
51 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 51 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
52 | $(top_builddir)/src/core/libgnunetcore.la \ | 52 | $(top_builddir)/src/core/libgnunetcore.la \ |
53 | $(top_builddir)/src/cadet/libgnunetcadet.la \ | 53 | $(top_builddir)/src/cadet/libgnunetcadet.la \ |
54 | $(top_builddir)/src/block/libgnunetblock.la \ | 54 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
55 | libgnunetsetu.la \ | 55 | libgnunetsetu.la \ |
56 | $(GN_LIBINTL) | 56 | $(GN_LIBINTL) |
57 | 57 | ||
58 | libgnunetsetu_la_SOURCES = \ | 58 | libgnunetsetu_la_SOURCES = \ |
59 | setu_api.c setu.h | 59 | setu_api.c setu.h |
60 | libgnunetsetu_la_LIBADD = \ | 60 | libgnunetsetu_la_LIBADD = \ |
61 | $(top_builddir)/src/util/libgnunetutil.la \ | 61 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
62 | $(LTLIBINTL) | 62 | $(LTLIBINTL) |
63 | libgnunetsetu_la_LDFLAGS = \ | 63 | libgnunetsetu_la_LDFLAGS = \ |
64 | $(GN_LIB_LDFLAGS) | 64 | $(GN_LIB_LDFLAGS) |
@@ -75,7 +75,7 @@ endif | |||
75 | test_setu_api_SOURCES = \ | 75 | test_setu_api_SOURCES = \ |
76 | test_setu_api.c | 76 | test_setu_api.c |
77 | test_setu_api_LDADD = \ | 77 | test_setu_api_LDADD = \ |
78 | $(top_builddir)/src/util/libgnunetutil.la \ | 78 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
79 | $(top_builddir)/src/testing/libgnunettesting.la \ | 79 | $(top_builddir)/src/testing/libgnunettesting.la \ |
80 | libgnunetsetu.la | 80 | libgnunetsetu.la |
81 | 81 | ||
@@ -83,7 +83,7 @@ test_setu_api_LDADD = \ | |||
83 | perf_setu_api_SOURCES = \ | 83 | perf_setu_api_SOURCES = \ |
84 | perf_setu_api.c | 84 | perf_setu_api.c |
85 | perf_setu_api_LDADD = \ | 85 | perf_setu_api_LDADD = \ |
86 | $(top_builddir)/src/util/libgnunetutil.la \ | 86 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
87 | $(top_builddir)/src/testing/libgnunettesting.la \ | 87 | $(top_builddir)/src/testing/libgnunettesting.la \ |
88 | libgnunetsetu.la | 88 | libgnunetsetu.la |
89 | 89 | ||
@@ -94,9 +94,9 @@ plugin_LTLIBRARIES = \ | |||
94 | libgnunet_plugin_block_setu_test_la_SOURCES = \ | 94 | libgnunet_plugin_block_setu_test_la_SOURCES = \ |
95 | plugin_block_setu_test.c | 95 | plugin_block_setu_test.c |
96 | libgnunet_plugin_block_setu_test_la_LIBADD = \ | 96 | libgnunet_plugin_block_setu_test_la_LIBADD = \ |
97 | $(top_builddir)/src/block/libgnunetblock.la \ | 97 | $(top_builddir)/src/lib/block/libgnunetblock.la \ |
98 | $(top_builddir)/src/block/libgnunetblockgroup.la \ | 98 | $(top_builddir)/src/lib/block/libgnunetblockgroup.la \ |
99 | $(top_builddir)/src/util/libgnunetutil.la \ | 99 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
100 | $(LTLIBINTL) | 100 | $(LTLIBINTL) |
101 | libgnunet_plugin_block_setu_test_la_LDFLAGS = \ | 101 | libgnunet_plugin_block_setu_test_la_LDFLAGS = \ |
102 | $(GN_PLUGIN_LDFLAGS) | 102 | $(GN_PLUGIN_LDFLAGS) |
diff --git a/src/sq/Makefile.am b/src/sq/Makefile.am index 80911db7a..a77a380af 100644 --- a/src/sq/Makefile.am +++ b/src/sq/Makefile.am | |||
@@ -16,7 +16,7 @@ libgnunetsq_la_SOURCES = \ | |||
16 | sq_query_helper.c \ | 16 | sq_query_helper.c \ |
17 | sq_result_helper.c | 17 | sq_result_helper.c |
18 | libgnunetsq_la_LIBADD = -lsqlite3 \ | 18 | libgnunetsq_la_LIBADD = -lsqlite3 \ |
19 | $(top_builddir)/src/util/libgnunetutil.la | 19 | $(top_builddir)/src/lib/util/libgnunetutil.la |
20 | libgnunetsq_la_LDFLAGS = \ | 20 | libgnunetsq_la_LDFLAGS = \ |
21 | $(GN_LIBINTL) \ | 21 | $(GN_LIBINTL) \ |
22 | $(GN_LIB_LDFLAGS) \ | 22 | $(GN_LIB_LDFLAGS) \ |
@@ -34,5 +34,5 @@ test_sq_SOURCES = \ | |||
34 | test_sq.c | 34 | test_sq.c |
35 | test_sq_LDADD = \ | 35 | test_sq_LDADD = \ |
36 | libgnunetsq.la \ | 36 | libgnunetsq.la \ |
37 | $(top_builddir)/src/util/libgnunetutil.la \ | 37 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
38 | -lsqlite3 $(XLIB) | 38 | -lsqlite3 $(XLIB) |
diff --git a/src/statistics/Makefile.am b/src/statistics/Makefile.am index 52f382156..ed4796274 100644 --- a/src/statistics/Makefile.am +++ b/src/statistics/Makefile.am | |||
@@ -18,7 +18,7 @@ lib_LTLIBRARIES = libgnunetstatistics.la | |||
18 | libgnunetstatistics_la_SOURCES = \ | 18 | libgnunetstatistics_la_SOURCES = \ |
19 | statistics_api.c statistics.h | 19 | statistics_api.c statistics.h |
20 | libgnunetstatistics_la_LIBADD = \ | 20 | libgnunetstatistics_la_LIBADD = \ |
21 | $(top_builddir)/src/util/libgnunetutil.la \ | 21 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
22 | $(GN_LIBINTL) $(XLIB) | 22 | $(GN_LIBINTL) $(XLIB) |
23 | libgnunetstatistics_la_LDFLAGS = \ | 23 | libgnunetstatistics_la_LDFLAGS = \ |
24 | $(GN_LIB_LDFLAGS) \ | 24 | $(GN_LIB_LDFLAGS) \ |
@@ -34,14 +34,14 @@ gnunet_statistics_SOURCES = \ | |||
34 | gnunet-statistics.c | 34 | gnunet-statistics.c |
35 | gnunet_statistics_LDADD = \ | 35 | gnunet_statistics_LDADD = \ |
36 | libgnunetstatistics.la \ | 36 | libgnunetstatistics.la \ |
37 | $(top_builddir)/src/util/libgnunetutil.la \ | 37 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
38 | $(GN_LIBINTL) | 38 | $(GN_LIBINTL) |
39 | 39 | ||
40 | gnunet_service_statistics_SOURCES = \ | 40 | gnunet_service_statistics_SOURCES = \ |
41 | gnunet-service-statistics.c | 41 | gnunet-service-statistics.c |
42 | gnunet_service_statistics_LDADD = \ | 42 | gnunet_service_statistics_LDADD = \ |
43 | libgnunetstatistics.la \ | 43 | libgnunetstatistics.la \ |
44 | $(top_builddir)/src/util/libgnunetutil.la \ | 44 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
45 | $(GN_LIBINTL) | 45 | $(GN_LIBINTL) |
46 | 46 | ||
47 | check_PROGRAMS = \ | 47 | check_PROGRAMS = \ |
@@ -59,25 +59,25 @@ test_statistics_api_SOURCES = \ | |||
59 | test_statistics_api.c | 59 | test_statistics_api.c |
60 | test_statistics_api_LDADD = \ | 60 | test_statistics_api_LDADD = \ |
61 | libgnunetstatistics.la \ | 61 | libgnunetstatistics.la \ |
62 | $(top_builddir)/src/util/libgnunetutil.la | 62 | $(top_builddir)/src/lib/util/libgnunetutil.la |
63 | 63 | ||
64 | test_statistics_api_loop_SOURCES = \ | 64 | test_statistics_api_loop_SOURCES = \ |
65 | test_statistics_api_loop.c | 65 | test_statistics_api_loop.c |
66 | test_statistics_api_loop_LDADD = \ | 66 | test_statistics_api_loop_LDADD = \ |
67 | libgnunetstatistics.la \ | 67 | libgnunetstatistics.la \ |
68 | $(top_builddir)/src/util/libgnunetutil.la | 68 | $(top_builddir)/src/lib/util/libgnunetutil.la |
69 | 69 | ||
70 | test_statistics_api_watch_SOURCES = \ | 70 | test_statistics_api_watch_SOURCES = \ |
71 | test_statistics_api_watch.c | 71 | test_statistics_api_watch.c |
72 | test_statistics_api_watch_LDADD = \ | 72 | test_statistics_api_watch_LDADD = \ |
73 | libgnunetstatistics.la \ | 73 | libgnunetstatistics.la \ |
74 | $(top_builddir)/src/util/libgnunetutil.la | 74 | $(top_builddir)/src/lib/util/libgnunetutil.la |
75 | 75 | ||
76 | test_statistics_api_watch_zero_value_SOURCES = \ | 76 | test_statistics_api_watch_zero_value_SOURCES = \ |
77 | test_statistics_api_watch_zero_value.c | 77 | test_statistics_api_watch_zero_value.c |
78 | test_statistics_api_watch_zero_value_LDADD = \ | 78 | test_statistics_api_watch_zero_value_LDADD = \ |
79 | libgnunetstatistics.la \ | 79 | libgnunetstatistics.la \ |
80 | $(top_builddir)/src/util/libgnunetutil.la | 80 | $(top_builddir)/src/lib/util/libgnunetutil.la |
81 | 81 | ||
82 | if HAVE_PYTHON | 82 | if HAVE_PYTHON |
83 | check_SCRIPTS = \ | 83 | check_SCRIPTS = \ |
diff --git a/src/template/Makefile.am b/src/template/Makefile.am index 4d2e58083..8db34b330 100644 --- a/src/template/Makefile.am +++ b/src/template/Makefile.am | |||
@@ -24,13 +24,13 @@ noinst_PROGRAMS = \ | |||
24 | gnunet_template_SOURCES = \ | 24 | gnunet_template_SOURCES = \ |
25 | gnunet-template.c | 25 | gnunet-template.c |
26 | gnunet_template_LDADD = \ | 26 | gnunet_template_LDADD = \ |
27 | $(top_builddir)/src/util/libgnunetutil.la \ | 27 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
28 | $(GN_LIBINTL) | 28 | $(GN_LIBINTL) |
29 | 29 | ||
30 | gnunet_service_template_SOURCES = \ | 30 | gnunet_service_template_SOURCES = \ |
31 | gnunet-service-template.c | 31 | gnunet-service-template.c |
32 | gnunet_service_template_LDADD = \ | 32 | gnunet_service_template_LDADD = \ |
33 | $(top_builddir)/src/util/libgnunetutil.la \ | 33 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
34 | $(GN_LIBINTL) | 34 | $(GN_LIBINTL) |
35 | 35 | ||
36 | 36 | ||
@@ -45,4 +45,4 @@ endif | |||
45 | test_template_api_SOURCES = \ | 45 | test_template_api_SOURCES = \ |
46 | test_template_api.c | 46 | test_template_api.c |
47 | test_template_api_LDADD = \ | 47 | test_template_api_LDADD = \ |
48 | $(top_builddir)/src/util/libgnunetutil.la | 48 | $(top_builddir)/src/lib/util/libgnunetutil.la |
diff --git a/src/testing/Makefile.am b/src/testing/Makefile.am index c8b9cd2d1..fe7de2399 100644 --- a/src/testing/Makefile.am +++ b/src/testing/Makefile.am | |||
@@ -25,7 +25,7 @@ lib_LTLIBRARIES = \ | |||
25 | gnunet_cmds_helper_SOURCES = \ | 25 | gnunet_cmds_helper_SOURCES = \ |
26 | gnunet-cmds-helper.c | 26 | gnunet-cmds-helper.c |
27 | gnunet_cmds_helper_LDADD = $(XLIB) \ | 27 | gnunet_cmds_helper_LDADD = $(XLIB) \ |
28 | $(top_builddir)/src/util/libgnunetutil.la \ | 28 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
29 | libgnunettesting.la \ | 29 | libgnunettesting.la \ |
30 | $(LTLIBINTL) $(Z_LIBS) | 30 | $(LTLIBINTL) $(Z_LIBS) |
31 | 31 | ||
@@ -51,7 +51,7 @@ libgnunettesting_la_SOURCES = \ | |||
51 | testing_api_traits.c | 51 | testing_api_traits.c |
52 | libgnunettesting_la_LIBADD = \ | 52 | libgnunettesting_la_LIBADD = \ |
53 | $(top_builddir)/src/arm/libgnunetarm.la \ | 53 | $(top_builddir)/src/arm/libgnunetarm.la \ |
54 | $(top_builddir)/src/util/libgnunetutil.la \ | 54 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
55 | $(LTLIBINTL) | 55 | $(LTLIBINTL) |
56 | libgnunettesting_la_LDFLAGS = \ | 56 | libgnunettesting_la_LDFLAGS = \ |
57 | $(GN_LIB_LDFLAGS) \ | 57 | $(GN_LIB_LDFLAGS) \ |
@@ -67,13 +67,13 @@ gnunet_testing_SOURCES = \ | |||
67 | gnunet-testing.c | 67 | gnunet-testing.c |
68 | gnunet_testing_LDADD = \ | 68 | gnunet_testing_LDADD = \ |
69 | libgnunettesting.la \ | 69 | libgnunettesting.la \ |
70 | $(top_builddir)/src/util/libgnunetutil.la \ | 70 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
71 | $(GN_LIBINTL) | 71 | $(GN_LIBINTL) |
72 | 72 | ||
73 | list_keys_SOURCES = \ | 73 | list_keys_SOURCES = \ |
74 | list-keys.c | 74 | list-keys.c |
75 | list_keys_LDADD = \ | 75 | list_keys_LDADD = \ |
76 | $(top_builddir)/src/util/libgnunetutil.la \ | 76 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
77 | $(GN_LIBINTL) | 77 | $(GN_LIBINTL) |
78 | 78 | ||
79 | 79 | ||
@@ -97,38 +97,38 @@ test_testing_start_with_config_SOURCES = \ | |||
97 | test_testing_start_with_config.c | 97 | test_testing_start_with_config.c |
98 | test_testing_start_with_config_LDADD = \ | 98 | test_testing_start_with_config_LDADD = \ |
99 | libgnunettesting.la \ | 99 | libgnunettesting.la \ |
100 | $(top_builddir)/src/util/libgnunetutil.la \ | 100 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
101 | $(top_builddir)/src/hello/libgnunethello.la | 101 | $(top_builddir)/src/lib/hello/libgnunethello.la |
102 | 102 | ||
103 | test_testing_portreservation_SOURCES = \ | 103 | test_testing_portreservation_SOURCES = \ |
104 | test_testing_portreservation.c | 104 | test_testing_portreservation.c |
105 | test_testing_portreservation_LDADD = \ | 105 | test_testing_portreservation_LDADD = \ |
106 | libgnunettesting.la \ | 106 | libgnunettesting.la \ |
107 | $(top_builddir)/src/util/libgnunetutil.la | 107 | $(top_builddir)/src/lib/util/libgnunetutil.la |
108 | 108 | ||
109 | test_testing_peerstartup_SOURCES = \ | 109 | test_testing_peerstartup_SOURCES = \ |
110 | test_testing_peerstartup.c | 110 | test_testing_peerstartup.c |
111 | test_testing_peerstartup_LDADD = \ | 111 | test_testing_peerstartup_LDADD = \ |
112 | libgnunettesting.la \ | 112 | libgnunettesting.la \ |
113 | $(top_builddir)/src/util/libgnunetutil.la | 113 | $(top_builddir)/src/lib/util/libgnunetutil.la |
114 | 114 | ||
115 | test_testing_peerstartup2_SOURCES = \ | 115 | test_testing_peerstartup2_SOURCES = \ |
116 | test_testing_peerstartup2.c | 116 | test_testing_peerstartup2.c |
117 | test_testing_peerstartup2_LDADD = \ | 117 | test_testing_peerstartup2_LDADD = \ |
118 | libgnunettesting.la \ | 118 | libgnunettesting.la \ |
119 | $(top_builddir)/src/util/libgnunetutil.la | 119 | $(top_builddir)/src/lib/util/libgnunetutil.la |
120 | 120 | ||
121 | test_testing_servicestartup_SOURCES = \ | 121 | test_testing_servicestartup_SOURCES = \ |
122 | test_testing_servicestartup.c | 122 | test_testing_servicestartup.c |
123 | test_testing_servicestartup_LDADD = \ | 123 | test_testing_servicestartup_LDADD = \ |
124 | libgnunettesting.la \ | 124 | libgnunettesting.la \ |
125 | $(top_builddir)/src/util/libgnunetutil.la | 125 | $(top_builddir)/src/lib/util/libgnunetutil.la |
126 | 126 | ||
127 | test_testing_sharedservices_SOURCES = \ | 127 | test_testing_sharedservices_SOURCES = \ |
128 | test_testing_sharedservices.c | 128 | test_testing_sharedservices.c |
129 | test_testing_sharedservices_LDADD = \ | 129 | test_testing_sharedservices_LDADD = \ |
130 | libgnunettesting.la \ | 130 | libgnunettesting.la \ |
131 | $(top_builddir)/src/util/libgnunetutil.la | 131 | $(top_builddir)/src/lib/util/libgnunetutil.la |
132 | 132 | ||
133 | EXTRA_DIST = \ | 133 | EXTRA_DIST = \ |
134 | test_testing_defaults.conf \ | 134 | test_testing_defaults.conf \ |
diff --git a/src/topology/Makefile.am b/src/topology/Makefile.am index 6ec2ba137..c8086b74d 100644 --- a/src/topology/Makefile.am +++ b/src/topology/Makefile.am | |||
@@ -23,8 +23,8 @@ gnunet_daemon_topology_LDADD = \ | |||
23 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 23 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
24 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 24 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
25 | $(top_builddir)/src/transport/libgnunettransportapplication.la \ | 25 | $(top_builddir)/src/transport/libgnunettransportapplication.la \ |
26 | $(top_builddir)/src/hello/libgnunethello.la \ | 26 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
27 | $(top_builddir)/src/util/libgnunetutil.la \ | 27 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
28 | $(GN_LIBINTL) | 28 | $(GN_LIBINTL) |
29 | 29 | ||
30 | 30 | ||
@@ -41,7 +41,7 @@ test_gnunet_daemon_topology_SOURCES = \ | |||
41 | test_gnunet_daemon_topology_LDADD = \ | 41 | test_gnunet_daemon_topology_LDADD = \ |
42 | $(top_builddir)/src/testbed/libgnunettestbed.la \ | 42 | $(top_builddir)/src/testbed/libgnunettestbed.la \ |
43 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 43 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
44 | $(top_builddir)/src/util/libgnunetutil.la | 44 | $(top_builddir)/src/lib/util/libgnunetutil.la |
45 | 45 | ||
46 | EXTRA_DIST = \ | 46 | EXTRA_DIST = \ |
47 | test_gnunet_daemon_topology_data.conf | 47 | test_gnunet_daemon_topology_data.conf |
diff --git a/src/transport/Makefile.am b/src/transport/Makefile.am index 9815e0f01..0828f7c04 100644 --- a/src/transport/Makefile.am +++ b/src/transport/Makefile.am | |||
@@ -48,9 +48,9 @@ libgnunettransporttesting2_la_LIBADD = \ | |||
48 | libgnunettransportcore.la \ | 48 | libgnunettransportcore.la \ |
49 | $(top_builddir)/src/arm/libgnunetarm.la \ | 49 | $(top_builddir)/src/arm/libgnunetarm.la \ |
50 | $(top_builddir)/src/testing/libgnunettesting.la \ | 50 | $(top_builddir)/src/testing/libgnunettesting.la \ |
51 | $(top_builddir)/src/hello/libgnunethello.la \ | 51 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
52 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 52 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
53 | $(top_builddir)/src/util/libgnunetutil.la | 53 | $(top_builddir)/src/lib/util/libgnunetutil.la |
54 | libgnunettransporttesting2_la_LDFLAGS = \ | 54 | libgnunettransporttesting2_la_LDFLAGS = \ |
55 | $(GN_LIBINTL) \ | 55 | $(GN_LIBINTL) \ |
56 | $(GN_LIB_LDFLAGS) \ | 56 | $(GN_LIB_LDFLAGS) \ |
@@ -59,7 +59,7 @@ libgnunettransporttesting2_la_LDFLAGS = \ | |||
59 | libgnunettransportapplication_la_SOURCES = \ | 59 | libgnunettransportapplication_la_SOURCES = \ |
60 | transport_api2_application.c | 60 | transport_api2_application.c |
61 | libgnunettransportapplication_la_LIBADD = \ | 61 | libgnunettransportapplication_la_LIBADD = \ |
62 | $(top_builddir)/src/util/libgnunetutil.la \ | 62 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
63 | $(LTLIBINTL) | 63 | $(LTLIBINTL) |
64 | libgnunettransportapplication_la_LDFLAGS = \ | 64 | libgnunettransportapplication_la_LDFLAGS = \ |
65 | $(GN_LIB_LDFLAGS) \ | 65 | $(GN_LIB_LDFLAGS) \ |
@@ -69,7 +69,7 @@ libgnunettransportapplication_la_LDFLAGS = \ | |||
69 | libgnunettransportcore_la_SOURCES = \ | 69 | libgnunettransportcore_la_SOURCES = \ |
70 | transport_api2_core.c | 70 | transport_api2_core.c |
71 | libgnunettransportcore_la_LIBADD = \ | 71 | libgnunettransportcore_la_LIBADD = \ |
72 | $(top_builddir)/src/util/libgnunetutil.la \ | 72 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
73 | $(GN_LIBINTL) | 73 | $(GN_LIBINTL) |
74 | libgnunettransportcore_la_LDFLAGS = \ | 74 | libgnunettransportcore_la_LDFLAGS = \ |
75 | $(GN_LIB_LDFLAGS) \ | 75 | $(GN_LIB_LDFLAGS) \ |
@@ -78,7 +78,7 @@ libgnunettransportcore_la_LDFLAGS = \ | |||
78 | libgnunettransportcommunicator_la_SOURCES = \ | 78 | libgnunettransportcommunicator_la_SOURCES = \ |
79 | transport_api2_communication.c | 79 | transport_api2_communication.c |
80 | libgnunettransportcommunicator_la_LIBADD = \ | 80 | libgnunettransportcommunicator_la_LIBADD = \ |
81 | $(top_builddir)/src/util/libgnunetutil.la \ | 81 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
82 | $(GN_LIBINTL) | 82 | $(GN_LIBINTL) |
83 | libgnunettransportcommunicator_la_LDFLAGS = \ | 83 | libgnunettransportcommunicator_la_LDFLAGS = \ |
84 | $(GN_LIB_LDFLAGS) \ | 84 | $(GN_LIB_LDFLAGS) \ |
@@ -88,7 +88,7 @@ libgnunettransportcommunicator_la_LDFLAGS = \ | |||
88 | libgnunettransportmonitor_la_SOURCES = \ | 88 | libgnunettransportmonitor_la_SOURCES = \ |
89 | transport_api2_monitor.c | 89 | transport_api2_monitor.c |
90 | libgnunettransportmonitor_la_LIBADD = \ | 90 | libgnunettransportmonitor_la_LIBADD = \ |
91 | $(top_builddir)/src/util/libgnunetutil.la \ | 91 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
92 | $(GN_LIBINTL) | 92 | $(GN_LIBINTL) |
93 | libgnunettransportmonitor_la_LDFLAGS = \ | 93 | libgnunettransportmonitor_la_LDFLAGS = \ |
94 | $(GN_LIB_LDFLAGS) \ | 94 | $(GN_LIB_LDFLAGS) \ |
@@ -130,7 +130,7 @@ gnunet_communicator_unix_SOURCES = \ | |||
130 | gnunet_communicator_unix_LDADD = \ | 130 | gnunet_communicator_unix_LDADD = \ |
131 | libgnunettransportcommunicator.la \ | 131 | libgnunettransportcommunicator.la \ |
132 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 132 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
133 | $(top_builddir)/src/util/libgnunetutil.la | 133 | $(top_builddir)/src/lib/util/libgnunetutil.la |
134 | 134 | ||
135 | gnunet_communicator_tcp_SOURCES = \ | 135 | gnunet_communicator_tcp_SOURCES = \ |
136 | gnunet-communicator-tcp.c | 136 | gnunet-communicator-tcp.c |
@@ -139,7 +139,7 @@ gnunet_communicator_tcp_LDADD = \ | |||
139 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 139 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
140 | $(top_builddir)/src/nat/libgnunetnatnew.la \ | 140 | $(top_builddir)/src/nat/libgnunetnatnew.la \ |
141 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 141 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
142 | $(top_builddir)/src/util/libgnunetutil.la \ | 142 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
143 | $(LIBGCRYPT_LIBS) | 143 | $(LIBGCRYPT_LIBS) |
144 | 144 | ||
145 | gnunet_communicator_udp_SOURCES = \ | 145 | gnunet_communicator_udp_SOURCES = \ |
@@ -149,7 +149,7 @@ gnunet_communicator_udp_LDADD = \ | |||
149 | libgnunettransportcommunicator.la \ | 149 | libgnunettransportcommunicator.la \ |
150 | $(top_builddir)/src/nat/libgnunetnatnew.la \ | 150 | $(top_builddir)/src/nat/libgnunetnatnew.la \ |
151 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 151 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
152 | $(top_builddir)/src/util/libgnunetutil.la \ | 152 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
153 | $(LIBGCRYPT_LIBS) | 153 | $(LIBGCRYPT_LIBS) |
154 | 154 | ||
155 | if HAVE_EXPERIMENTAL | 155 | if HAVE_EXPERIMENTAL |
@@ -162,7 +162,7 @@ gnunet_communicator_quic_LDADD = \ | |||
162 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 162 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
163 | $(top_builddir)/src/nat/libgnunetnatnew.la \ | 163 | $(top_builddir)/src/nat/libgnunetnatnew.la \ |
164 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 164 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
165 | $(top_builddir)/src/util/libgnunetutil.la \ | 165 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
166 | -lquiche \ | 166 | -lquiche \ |
167 | $(LIBGCRYPT_LIBS) | 167 | $(LIBGCRYPT_LIBS) |
168 | endif | 168 | endif |
@@ -172,17 +172,17 @@ endif | |||
172 | # gnunet-transport.c | 172 | # gnunet-transport.c |
173 | #gnunet_transport_LDADD = \ | 173 | #gnunet_transport_LDADD = \ |
174 | # libgnunettransport.la \ | 174 | # libgnunettransport.la \ |
175 | # $(top_builddir)/src/hello/libgnunethello.la \ | 175 | # $(top_builddir)/src/lib/hello/libgnunethello.la \ |
176 | # $(top_builddir)/src/util/libgnunetutil.la \ | 176 | # $(top_builddir)/src/lib/util/libgnunetutil.la \ |
177 | # $(GN_LIBINTL) | 177 | # $(GN_LIBINTL) |
178 | 178 | ||
179 | gnunet_service_transport_SOURCES = \ | 179 | gnunet_service_transport_SOURCES = \ |
180 | gnunet-service-transport.c transport.h | 180 | gnunet-service-transport.c transport.h |
181 | gnunet_service_transport_LDADD = \ | 181 | gnunet_service_transport_LDADD = \ |
182 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 182 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
183 | $(top_builddir)/src/hello/libgnunethello.la \ | 183 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
184 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 184 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
185 | $(top_builddir)/src/util/libgnunetutil.la \ | 185 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
186 | $(LIBGCRYPT_LIBS) \ | 186 | $(LIBGCRYPT_LIBS) \ |
187 | $(GN_LIBINTL) | 187 | $(GN_LIBINTL) |
188 | 188 | ||
@@ -203,9 +203,9 @@ libgnunet_test_transport_plugin_cmd_nat_upnp_la_LIBADD = \ | |||
203 | $(top_builddir)/src/testing/libgnunettesting.la \ | 203 | $(top_builddir)/src/testing/libgnunettesting.la \ |
204 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 204 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
205 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 205 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
206 | $(top_builddir)/src/hello/libgnunethello.la \ | 206 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
207 | $(top_builddir)/src/arm/libgnunetarm.la \ | 207 | $(top_builddir)/src/arm/libgnunetarm.la \ |
208 | $(top_builddir)/src/util/libgnunetutil.la \ | 208 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
209 | $(LTLIBINTL) | 209 | $(LTLIBINTL) |
210 | libgnunet_test_transport_plugin_cmd_nat_upnp_la_LDFLAGS = \ | 210 | libgnunet_test_transport_plugin_cmd_nat_upnp_la_LDFLAGS = \ |
211 | $(GN_PLUGIN_LDFLAGS) | 211 | $(GN_PLUGIN_LDFLAGS) |
@@ -219,9 +219,9 @@ libgnunet_test_transport_plugin_cmd_udp_backchannel_la_LIBADD = \ | |||
219 | $(top_builddir)/src/testing/libgnunettesting.la \ | 219 | $(top_builddir)/src/testing/libgnunettesting.la \ |
220 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 220 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
221 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 221 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
222 | $(top_builddir)/src/hello/libgnunethello.la \ | 222 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
223 | $(top_builddir)/src/arm/libgnunetarm.la \ | 223 | $(top_builddir)/src/arm/libgnunetarm.la \ |
224 | $(top_builddir)/src/util/libgnunetutil.la \ | 224 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
225 | $(LTLIBINTL) | 225 | $(LTLIBINTL) |
226 | libgnunet_test_transport_plugin_cmd_udp_backchannel_la_LDFLAGS = \ | 226 | libgnunet_test_transport_plugin_cmd_udp_backchannel_la_LDFLAGS = \ |
227 | $(GN_PLUGIN_LDFLAGS) | 227 | $(GN_PLUGIN_LDFLAGS) |
@@ -235,9 +235,9 @@ libgnunet_test_transport_plugin_cmd_simple_send_la_LIBADD = \ | |||
235 | $(top_builddir)/src/testing/libgnunettesting.la \ | 235 | $(top_builddir)/src/testing/libgnunettesting.la \ |
236 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 236 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
237 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 237 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
238 | $(top_builddir)/src/hello/libgnunethello.la \ | 238 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
239 | $(top_builddir)/src/arm/libgnunetarm.la \ | 239 | $(top_builddir)/src/arm/libgnunetarm.la \ |
240 | $(top_builddir)/src/util/libgnunetutil.la \ | 240 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
241 | $(LTLIBINTL) | 241 | $(LTLIBINTL) |
242 | libgnunet_test_transport_plugin_cmd_simple_send_la_LDFLAGS = \ | 242 | libgnunet_test_transport_plugin_cmd_simple_send_la_LDFLAGS = \ |
243 | $(GN_PLUGIN_LDFLAGS) | 243 | $(GN_PLUGIN_LDFLAGS) |
@@ -251,9 +251,9 @@ libgnunet_test_transport_plugin_cmd_simple_send_performance_la_LIBADD = \ | |||
251 | $(top_builddir)/src/testing/libgnunettesting.la \ | 251 | $(top_builddir)/src/testing/libgnunettesting.la \ |
252 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 252 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
253 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 253 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
254 | $(top_builddir)/src/hello/libgnunethello.la \ | 254 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
255 | $(top_builddir)/src/arm/libgnunetarm.la \ | 255 | $(top_builddir)/src/arm/libgnunetarm.la \ |
256 | $(top_builddir)/src/util/libgnunetutil.la \ | 256 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
257 | $(LTLIBINTL) | 257 | $(LTLIBINTL) |
258 | libgnunet_test_transport_plugin_cmd_simple_send_performance_la_LDFLAGS = \ | 258 | libgnunet_test_transport_plugin_cmd_simple_send_performance_la_LDFLAGS = \ |
259 | $(GN_PLUGIN_LDFLAGS) | 259 | $(GN_PLUGIN_LDFLAGS) |
@@ -267,9 +267,9 @@ libgnunet_test_transport_plugin_cmd_simple_send_broadcast_la_LIBADD = \ | |||
267 | $(top_builddir)/src/testing/libgnunettesting.la \ | 267 | $(top_builddir)/src/testing/libgnunettesting.la \ |
268 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 268 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
269 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 269 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
270 | $(top_builddir)/src/hello/libgnunethello.la \ | 270 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
271 | $(top_builddir)/src/arm/libgnunetarm.la \ | 271 | $(top_builddir)/src/arm/libgnunetarm.la \ |
272 | $(top_builddir)/src/util/libgnunetutil.la \ | 272 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
273 | $(LTLIBINTL) | 273 | $(LTLIBINTL) |
274 | libgnunet_test_transport_plugin_cmd_simple_send_broadcast_la_LDFLAGS = \ | 274 | libgnunet_test_transport_plugin_cmd_simple_send_broadcast_la_LDFLAGS = \ |
275 | $(GN_PLUGIN_LDFLAGS) | 275 | $(GN_PLUGIN_LDFLAGS) |
@@ -283,9 +283,9 @@ libgnunet_test_transport_plugin_cmd_simple_send_dv_la_LIBADD = \ | |||
283 | $(top_builddir)/src/testing/libgnunettesting.la \ | 283 | $(top_builddir)/src/testing/libgnunettesting.la \ |
284 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ | 284 | $(top_builddir)/src/peerstore/libgnunetpeerstore.la \ |
285 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 285 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
286 | $(top_builddir)/src/hello/libgnunethello.la \ | 286 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
287 | $(top_builddir)/src/arm/libgnunetarm.la \ | 287 | $(top_builddir)/src/arm/libgnunetarm.la \ |
288 | $(top_builddir)/src/util/libgnunetutil.la \ | 288 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
289 | $(LTLIBINTL) | 289 | $(LTLIBINTL) |
290 | libgnunet_test_transport_plugin_cmd_simple_send_dv_la_LDFLAGS = \ | 290 | libgnunet_test_transport_plugin_cmd_simple_send_dv_la_LDFLAGS = \ |
291 | $(GN_PLUGIN_LDFLAGS) | 291 | $(GN_PLUGIN_LDFLAGS) |
@@ -331,8 +331,8 @@ test_transport_start_with_config_SOURCES = \ | |||
331 | test_transport_start_with_config.c | 331 | test_transport_start_with_config.c |
332 | test_transport_start_with_config_LDADD = \ | 332 | test_transport_start_with_config_LDADD = \ |
333 | $(top_builddir)/src/testing/libgnunettesting.la \ | 333 | $(top_builddir)/src/testing/libgnunettesting.la \ |
334 | $(top_builddir)/src/util/libgnunetutil.la \ | 334 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
335 | $(top_builddir)/src/hello/libgnunethello.la \ | 335 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
336 | libgnunettransportcore.la \ | 336 | libgnunettransportcore.la \ |
337 | libgnunettransporttesting2.la | 337 | libgnunettransporttesting2.la |
338 | 338 | ||
@@ -341,7 +341,7 @@ test_communicator_basic_unix_SOURCES = \ | |||
341 | test_communicator_basic_unix_LDADD = \ | 341 | test_communicator_basic_unix_LDADD = \ |
342 | libgnunettransporttesting2.la \ | 342 | libgnunettransporttesting2.la \ |
343 | $(top_builddir)/src/testing/libgnunettesting.la \ | 343 | $(top_builddir)/src/testing/libgnunettesting.la \ |
344 | $(top_builddir)/src/util/libgnunetutil.la \ | 344 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
345 | $(top_builddir)/src/statistics/libgnunetstatistics.la | 345 | $(top_builddir)/src/statistics/libgnunetstatistics.la |
346 | 346 | ||
347 | test_communicator_basic_tcp_SOURCES = \ | 347 | test_communicator_basic_tcp_SOURCES = \ |
@@ -349,7 +349,7 @@ test_communicator_basic_tcp_SOURCES = \ | |||
349 | test_communicator_basic_tcp_LDADD = \ | 349 | test_communicator_basic_tcp_LDADD = \ |
350 | libgnunettransporttesting2.la \ | 350 | libgnunettransporttesting2.la \ |
351 | $(top_builddir)/src/testing/libgnunettesting.la \ | 351 | $(top_builddir)/src/testing/libgnunettesting.la \ |
352 | $(top_builddir)/src/util/libgnunetutil.la \ | 352 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
353 | $(top_builddir)/src/statistics/libgnunetstatistics.la | 353 | $(top_builddir)/src/statistics/libgnunetstatistics.la |
354 | 354 | ||
355 | test_communicator_basic_udp_SOURCES = \ | 355 | test_communicator_basic_udp_SOURCES = \ |
@@ -357,7 +357,7 @@ test_communicator_basic_udp_SOURCES = \ | |||
357 | test_communicator_basic_udp_LDADD = \ | 357 | test_communicator_basic_udp_LDADD = \ |
358 | libgnunettransporttesting2.la \ | 358 | libgnunettransporttesting2.la \ |
359 | $(top_builddir)/src/testing/libgnunettesting.la \ | 359 | $(top_builddir)/src/testing/libgnunettesting.la \ |
360 | $(top_builddir)/src/util/libgnunetutil.la \ | 360 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
361 | $(top_builddir)/src/statistics/libgnunetstatistics.la | 361 | $(top_builddir)/src/statistics/libgnunetstatistics.la |
362 | 362 | ||
363 | test_communicator_basic_quic_SOURCES = \ | 363 | test_communicator_basic_quic_SOURCES = \ |
@@ -365,7 +365,7 @@ test_communicator_basic_quic_SOURCES = \ | |||
365 | test_communicator_basic_quic_LDADD = \ | 365 | test_communicator_basic_quic_LDADD = \ |
366 | libgnunettransporttesting2.la \ | 366 | libgnunettransporttesting2.la \ |
367 | $(top_builddir)/src/testing/libgnunettesting.la \ | 367 | $(top_builddir)/src/testing/libgnunettesting.la \ |
368 | $(top_builddir)/src/util/libgnunetutil.la \ | 368 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
369 | $(top_builddir)/src/statistics/libgnunetstatistics.la | 369 | $(top_builddir)/src/statistics/libgnunetstatistics.la |
370 | 370 | ||
371 | test_communicator_rekey_tcp_SOURCES = \ | 371 | test_communicator_rekey_tcp_SOURCES = \ |
@@ -373,7 +373,7 @@ test_communicator_rekey_tcp_SOURCES = \ | |||
373 | test_communicator_rekey_tcp_LDADD = \ | 373 | test_communicator_rekey_tcp_LDADD = \ |
374 | libgnunettransporttesting2.la \ | 374 | libgnunettransporttesting2.la \ |
375 | $(top_builddir)/src/testing/libgnunettesting.la \ | 375 | $(top_builddir)/src/testing/libgnunettesting.la \ |
376 | $(top_builddir)/src/util/libgnunetutil.la \ | 376 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
377 | $(top_builddir)/src/statistics/libgnunetstatistics.la | 377 | $(top_builddir)/src/statistics/libgnunetstatistics.la |
378 | 378 | ||
379 | test_communicator_rekey_udp_SOURCES = \ | 379 | test_communicator_rekey_udp_SOURCES = \ |
@@ -381,7 +381,7 @@ test_communicator_rekey_udp_SOURCES = \ | |||
381 | test_communicator_rekey_udp_LDADD = \ | 381 | test_communicator_rekey_udp_LDADD = \ |
382 | libgnunettransporttesting2.la \ | 382 | libgnunettransporttesting2.la \ |
383 | $(top_builddir)/src/testing/libgnunettesting.la \ | 383 | $(top_builddir)/src/testing/libgnunettesting.la \ |
384 | $(top_builddir)/src/util/libgnunetutil.la \ | 384 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
385 | $(top_builddir)/src/statistics/libgnunetstatistics.la | 385 | $(top_builddir)/src/statistics/libgnunetstatistics.la |
386 | 386 | ||
387 | test_communicator_backchannel_udp_SOURCES = \ | 387 | test_communicator_backchannel_udp_SOURCES = \ |
@@ -389,7 +389,7 @@ test_communicator_backchannel_udp_SOURCES = \ | |||
389 | test_communicator_backchannel_udp_LDADD = \ | 389 | test_communicator_backchannel_udp_LDADD = \ |
390 | libgnunettransporttesting2.la \ | 390 | libgnunettransporttesting2.la \ |
391 | $(top_builddir)/src/testing/libgnunettesting.la \ | 391 | $(top_builddir)/src/testing/libgnunettesting.la \ |
392 | $(top_builddir)/src/util/libgnunetutil.la \ | 392 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
393 | $(top_builddir)/src/statistics/libgnunetstatistics.la | 393 | $(top_builddir)/src/statistics/libgnunetstatistics.la |
394 | 394 | ||
395 | test_communicator_bidirect_tcp_SOURCES = \ | 395 | test_communicator_bidirect_tcp_SOURCES = \ |
@@ -397,14 +397,14 @@ test_communicator_bidirect_tcp_SOURCES = \ | |||
397 | test_communicator_bidirect_tcp_LDADD = \ | 397 | test_communicator_bidirect_tcp_LDADD = \ |
398 | libgnunettransporttesting2.la \ | 398 | libgnunettransporttesting2.la \ |
399 | $(top_builddir)/src/testing/libgnunettesting.la \ | 399 | $(top_builddir)/src/testing/libgnunettesting.la \ |
400 | $(top_builddir)/src/util/libgnunetutil.la \ | 400 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
401 | $(top_builddir)/src/statistics/libgnunetstatistics.la | 401 | $(top_builddir)/src/statistics/libgnunetstatistics.la |
402 | 402 | ||
403 | test_transport_api2_tcp_SOURCES = \ | 403 | test_transport_api2_tcp_SOURCES = \ |
404 | test_transport_api2.c | 404 | test_transport_api2.c |
405 | test_transport_api2_tcp_LDADD = \ | 405 | test_transport_api2_tcp_LDADD = \ |
406 | $(top_builddir)/src/hello/libgnunethello.la \ | 406 | $(top_builddir)/src/lib/hello/libgnunethello.la \ |
407 | $(top_builddir)/src/util/libgnunetutil.la \ | 407 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
408 | libgnunettransporttesting2.la | 408 | libgnunettransporttesting2.la |
409 | 409 | ||
410 | EXTRA_DIST = \ | 410 | EXTRA_DIST = \ |
diff --git a/src/vpn/Makefile.am b/src/vpn/Makefile.am index a5bbb6e22..38a7e8b3f 100644 --- a/src/vpn/Makefile.am +++ b/src/vpn/Makefile.am | |||
@@ -33,14 +33,14 @@ bin_PROGRAMS = \ | |||
33 | gnunet_helper_vpn_SOURCES = \ | 33 | gnunet_helper_vpn_SOURCES = \ |
34 | gnunet-helper-vpn.c | 34 | gnunet-helper-vpn.c |
35 | gnunet_helper_vpn_LDADD = \ | 35 | gnunet_helper_vpn_LDADD = \ |
36 | $(top_builddir)/src/util/libgnunetutil.la \ | 36 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
37 | $(GN_LIBINTL) | 37 | $(GN_LIBINTL) |
38 | 38 | ||
39 | gnunet_service_vpn_SOURCES = \ | 39 | gnunet_service_vpn_SOURCES = \ |
40 | gnunet-service-vpn.c | 40 | gnunet-service-vpn.c |
41 | gnunet_service_vpn_LDADD = \ | 41 | gnunet_service_vpn_LDADD = \ |
42 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 42 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
43 | $(top_builddir)/src/util/libgnunetutil.la \ | 43 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
44 | $(top_builddir)/src/cadet/libgnunetcadet.la \ | 44 | $(top_builddir)/src/cadet/libgnunetcadet.la \ |
45 | $(top_builddir)/src/regex/libgnunetregex.la \ | 45 | $(top_builddir)/src/regex/libgnunetregex.la \ |
46 | $(GN_LIBINTL) | 46 | $(GN_LIBINTL) |
@@ -51,13 +51,13 @@ gnunet_vpn_SOURCES = \ | |||
51 | gnunet-vpn.c | 51 | gnunet-vpn.c |
52 | gnunet_vpn_LDADD = \ | 52 | gnunet_vpn_LDADD = \ |
53 | libgnunetvpn.la \ | 53 | libgnunetvpn.la \ |
54 | $(top_builddir)/src/util/libgnunetutil.la \ | 54 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
55 | $(GN_LIBINTL) | 55 | $(GN_LIBINTL) |
56 | 56 | ||
57 | libgnunetvpn_la_SOURCES = \ | 57 | libgnunetvpn_la_SOURCES = \ |
58 | vpn_api.c vpn.h | 58 | vpn_api.c vpn.h |
59 | libgnunetvpn_la_LIBADD = \ | 59 | libgnunetvpn_la_LIBADD = \ |
60 | $(top_builddir)/src/util/libgnunetutil.la $(XLIB) | 60 | $(top_builddir)/src/lib/util/libgnunetutil.la $(XLIB) |
61 | libgnunetvpn_la_LDFLAGS = \ | 61 | libgnunetvpn_la_LDFLAGS = \ |
62 | $(GN_LIBINTL) \ | 62 | $(GN_LIBINTL) \ |
63 | $(GN_LIB_LDFLAGS) | 63 | $(GN_LIB_LDFLAGS) |
diff --git a/src/zonemaster/Makefile.am b/src/zonemaster/Makefile.am index 635c195ed..3a3b150e2 100644 --- a/src/zonemaster/Makefile.am +++ b/src/zonemaster/Makefile.am | |||
@@ -22,10 +22,10 @@ gnunet_service_zonemaster_SOURCES = \ | |||
22 | gnunet-service-zonemaster.c | 22 | gnunet-service-zonemaster.c |
23 | gnunet_service_zonemaster_LDADD = \ | 23 | gnunet_service_zonemaster_LDADD = \ |
24 | $(top_builddir)/src/dht/libgnunetdht.la \ | 24 | $(top_builddir)/src/dht/libgnunetdht.la \ |
25 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 25 | $(top_builddir)/src/lib/gnsrecord/libgnunetgnsrecord.la \ |
26 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 26 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
27 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 27 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
28 | $(top_builddir)/src/util/libgnunetutil.la \ | 28 | $(top_builddir)/src/lib/util/libgnunetutil.la \ |
29 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 29 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
30 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ | 30 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ |
31 | $(GN_LIBINTL) \ | 31 | $(GN_LIBINTL) \ |
diff --git a/src/zonemaster/gnunet-service-zonemaster.c b/src/zonemaster/gnunet-service-zonemaster.c index a4eb13004..7c763576d 100644 --- a/src/zonemaster/gnunet-service-zonemaster.c +++ b/src/zonemaster/gnunet-service-zonemaster.c | |||
@@ -146,7 +146,7 @@ struct RecordPublicationJob | |||
146 | /** | 146 | /** |
147 | * The zone key to sign the block with | 147 | * The zone key to sign the block with |
148 | */ | 148 | */ |
149 | struct GNUNET_IDENTITY_PrivateKey zone; | 149 | struct GNUNET_CRYPTO_PrivateKey zone; |
150 | 150 | ||
151 | /** | 151 | /** |
152 | * The block to sign | 152 | * The block to sign |
@@ -809,7 +809,7 @@ dht_put_continuation (void *cls) | |||
809 | * @return DHT PUT handle, NULL on error | 809 | * @return DHT PUT handle, NULL on error |
810 | */ | 810 | */ |
811 | static void | 811 | static void |
812 | dispatch_job (const struct GNUNET_IDENTITY_PrivateKey *key, | 812 | dispatch_job (const struct GNUNET_CRYPTO_PrivateKey *key, |
813 | const char *label, | 813 | const char *label, |
814 | const struct GNUNET_GNSRECORD_Data *rd, | 814 | const struct GNUNET_GNSRECORD_Data *rd, |
815 | unsigned int rd_count, | 815 | unsigned int rd_count, |
@@ -1036,7 +1036,7 @@ zone_iteration_finished (void *cls) | |||
1036 | */ | 1036 | */ |
1037 | static void | 1037 | static void |
1038 | handle_record (void *cls, | 1038 | handle_record (void *cls, |
1039 | const struct GNUNET_IDENTITY_PrivateKey *key, | 1039 | const struct GNUNET_CRYPTO_PrivateKey *key, |
1040 | const char *label, | 1040 | const char *label, |
1041 | unsigned int rd_count, | 1041 | unsigned int rd_count, |
1042 | const struct GNUNET_GNSRECORD_Data *rd, | 1042 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -1123,7 +1123,7 @@ publish_zone_dht_start (void *cls) | |||
1123 | * @param rd_public_count number of records in @a rd_public | 1123 | * @param rd_public_count number of records in @a rd_public |
1124 | */ | 1124 | */ |
1125 | static void | 1125 | static void |
1126 | dispatch_job_monitor (const struct GNUNET_IDENTITY_PrivateKey *key, | 1126 | dispatch_job_monitor (const struct GNUNET_CRYPTO_PrivateKey *key, |
1127 | const char *label, | 1127 | const char *label, |
1128 | const struct GNUNET_GNSRECORD_Data *rd, | 1128 | const struct GNUNET_GNSRECORD_Data *rd, |
1129 | unsigned int rd_count, | 1129 | unsigned int rd_count, |
@@ -1201,7 +1201,7 @@ dispatch_job_monitor (const struct GNUNET_IDENTITY_PrivateKey *key, | |||
1201 | */ | 1201 | */ |
1202 | static void | 1202 | static void |
1203 | handle_monitor_event (void *cls, | 1203 | handle_monitor_event (void *cls, |
1204 | const struct GNUNET_IDENTITY_PrivateKey *zone, | 1204 | const struct GNUNET_CRYPTO_PrivateKey *zone, |
1205 | const char *label, | 1205 | const char *label, |
1206 | unsigned int rd_count, | 1206 | unsigned int rd_count, |
1207 | const struct GNUNET_GNSRECORD_Data *rd, | 1207 | const struct GNUNET_GNSRECORD_Data *rd, |