diff options
246 files changed, 25512 insertions, 5231 deletions
diff --git a/.buildbot/firefly-x86_64-amdepyc_test_tng.sh b/.buildbot/firefly-x86_64-amdepyc_test_tng.sh index 30339d7c3..162363b5a 100755 --- a/.buildbot/firefly-x86_64-amdepyc_test_tng.sh +++ b/.buildbot/firefly-x86_64-amdepyc_test_tng.sh | |||
@@ -3,6 +3,6 @@ | |||
3 | # echo "Skipped" | 3 | # echo "Skipped" |
4 | 4 | ||
5 | pushd src/transport | 5 | pushd src/transport |
6 | make check TESTS='test_communicator_basic-tcp test_communicator_rekey-tcp test_communicator_basic-unix test_communicator_basic-udp' | 6 | make check TESTS='test_communicator_basic-tcp test_communicator_rekey-tcp test_communicator_basic-unix test_communicator_basic-udp test_communicator_backchannel-udp' |
7 | pkill --signal 9 -U buildbot gnunet | 7 | pkill --signal 9 -U buildbot gnunet |
8 | popd | 8 | popd |
diff --git a/README.1st b/README.1st index 3d000a23f..c25992351 100644 --- a/README.1st +++ b/README.1st | |||
@@ -253,4 +253,5 @@ We reserve judgement (due to lack of data) on: | |||
253 | * credential | 253 | * credential |
254 | * abe | 254 | * abe |
255 | * rest | 255 | * rest |
256 | * messenger | ||
256 | 257 | ||
diff --git a/bin/rename.sh b/bin/rename.sh index bf3c767c5..eec77e277 100755 --- a/bin/rename.sh +++ b/bin/rename.sh | |||
@@ -1,6 +1,6 @@ | |||
1 | #!/bin/sh | 1 | #!/bin/sh |
2 | # This script is in the public domain. | 2 | # This script is in the public domain. |
3 | for n in `find * -name "*.c"` `find * -name "*.h"` `find * -name "*.am"` `find * -name "*.conf"` `find * -name "*.conf.in"` | 3 | for n in `find * -name "*.c"` `find * -name "*.h"` `find * -name "*.am"` `find * -name "*.conf"` `find * -name "*.conf.in"` |
4 | do | 4 | do |
5 | cat $n | sed -e "s/$1/$2/g" > $n.new | 5 | cat $n | sed -e "s/$1/$2/g" > $n.new |
6 | mv $n.new $n || echo "Move failed: $n.new to $n" | 6 | mv $n.new $n || echo "Move failed: $n.new to $n" |
diff --git a/configure.ac b/configure.ac index 3cf7e6cb6..a9594a56c 100644 --- a/configure.ac +++ b/configure.ac | |||
@@ -1335,7 +1335,7 @@ CPPFLAGS=$SAVE_CPPFLAGS | |||
1335 | 1335 | ||
1336 | # test for postgres: | 1336 | # test for postgres: |
1337 | postgres=false | 1337 | postgres=false |
1338 | AX_LIB_POSTGRESQL([9.5], | 1338 | AX_LIB_POSTGRESQL([12.0], |
1339 | [CPPFLAGS="$CPPFLAGS $POSTGRESQL_CPPFLAGS" | 1339 | [CPPFLAGS="$CPPFLAGS $POSTGRESQL_CPPFLAGS" |
1340 | AC_CHECK_HEADERS([libpq-fe.h], | 1340 | AC_CHECK_HEADERS([libpq-fe.h], |
1341 | postgres=true) | 1341 | postgres=true) |
@@ -1817,6 +1817,16 @@ AC_MSG_RESULT($use_gcov) | |||
1817 | AM_CONDITIONAL([USE_COVERAGE], [test "x$use_gcov" = "xyes"]) | 1817 | AM_CONDITIONAL([USE_COVERAGE], [test "x$use_gcov" = "xyes"]) |
1818 | 1818 | ||
1819 | 1819 | ||
1820 | # Temporarily disable a specific piece of code until TNG is out. | ||
1821 | AC_ARG_ENABLE([transport-timing-diagnostic], | ||
1822 | [AS_HELP_STRING([--enable-transport-timing-diagnostic], | ||
1823 | [enable logging of transport (not TNG) sending times])], | ||
1824 | [enable_ttd=yes], | ||
1825 | [enable_ttd=no]) | ||
1826 | AS_IF([test "x$enable_ttd" = "xyes"], | ||
1827 | [AC_DEFINE([ENABLE_TTD], [1], [Define if transport (not TNG) should warn about sending times.])]) | ||
1828 | |||
1829 | |||
1820 | # version info | 1830 | # version info |
1821 | # TODO: git blame says this predates our switch to git. | 1831 | # TODO: git blame says this predates our switch to git. |
1822 | # git-svn should be adjusted to simply git, or | 1832 | # git-svn should be adjusted to simply git, or |
@@ -1965,6 +1975,8 @@ src/zonemaster/zonemaster.conf | |||
1965 | src/rest/Makefile | 1975 | src/rest/Makefile |
1966 | src/abe/Makefile | 1976 | src/abe/Makefile |
1967 | src/reclaim/Makefile | 1977 | src/reclaim/Makefile |
1978 | src/messenger/Makefile | ||
1979 | src/messenger/messenger.conf | ||
1968 | pkgconfig/Makefile | 1980 | pkgconfig/Makefile |
1969 | pkgconfig/gnunetarm.pc | 1981 | pkgconfig/gnunetarm.pc |
1970 | pkgconfig/gnunetats.pc | 1982 | pkgconfig/gnunetats.pc |
diff --git a/pkgconfig/gnunetmessenger.pc.in b/pkgconfig/gnunetmessenger.pc.in new file mode 100644 index 000000000..465663d0c --- /dev/null +++ b/pkgconfig/gnunetmessenger.pc.in | |||
@@ -0,0 +1,12 @@ | |||
1 | prefix=@prefix@ | ||
2 | exec_prefix=@exec_prefix@ | ||
3 | libdir=@libdir@ | ||
4 | includedir=@includedir@ | ||
5 | |||
6 | Name: GNUnet MESSENGER | ||
7 | Description: Instant messaging based on the CADET subsystem | ||
8 | URL: https://gnunet.org | ||
9 | Version: @VERSION@ | ||
10 | Requires: | ||
11 | Libs: -L${libdir} -lgnunetmessenger_common -lgnunetmessenger | ||
12 | Cflags: -I${includedir} | ||
diff --git a/po/LINGUAS b/po/LINGUAS index 0c3dbe3fa..5882d3d7e 100644 --- a/po/LINGUAS +++ b/po/LINGUAS | |||
@@ -1,2 +1,2 @@ | |||
1 | # set of available languages | 1 | # set of available languages |
2 | vi de sv es zh_CN fr it | 2 | vi de sv es zh_CN fr it sr |
diff --git a/po/POTFILES.in b/po/POTFILES.in index 36d948d93..00bdd7cbc 100644 --- a/po/POTFILES.in +++ b/po/POTFILES.in | |||
@@ -185,6 +185,7 @@ src/gnsrecord/gnsrecord_crypto.c | |||
185 | src/gnsrecord/gnsrecord_misc.c | 185 | src/gnsrecord/gnsrecord_misc.c |
186 | src/gnsrecord/gnsrecord_serialization.c | 186 | src/gnsrecord/gnsrecord_serialization.c |
187 | src/gnsrecord/gnunet-gnsrecord-tvg.c | 187 | src/gnsrecord/gnunet-gnsrecord-tvg.c |
188 | src/gnsrecord/json_gnsrecord.c | ||
188 | src/gnsrecord/plugin_gnsrecord_dns.c | 189 | src/gnsrecord/plugin_gnsrecord_dns.c |
189 | src/hello/address.c | 190 | src/hello/address.c |
190 | src/hello/gnunet-hello.c | 191 | src/hello/gnunet-hello.c |
@@ -201,9 +202,30 @@ src/identity/identity_api_suffix_lookup.c | |||
201 | src/identity/plugin_rest_identity.c | 202 | src/identity/plugin_rest_identity.c |
202 | src/json/json.c | 203 | src/json/json.c |
203 | src/json/json_generator.c | 204 | src/json/json_generator.c |
204 | src/json/json_gnsrecord.c | ||
205 | src/json/json_helper.c | 205 | src/json/json_helper.c |
206 | src/json/json_mhd.c | 206 | src/json/json_mhd.c |
207 | src/messenger/gnunet-messenger.c | ||
208 | src/messenger/gnunet-service-messenger.c | ||
209 | src/messenger/gnunet-service-messenger_basement.c | ||
210 | src/messenger/gnunet-service-messenger_contact.c | ||
211 | src/messenger/gnunet-service-messenger_handle.c | ||
212 | src/messenger/gnunet-service-messenger_list_handles.c | ||
213 | src/messenger/gnunet-service-messenger_list_messages.c | ||
214 | src/messenger/gnunet-service-messenger_message_handle.c | ||
215 | src/messenger/gnunet-service-messenger_message_kind.c | ||
216 | src/messenger/gnunet-service-messenger_message_recv.c | ||
217 | src/messenger/gnunet-service-messenger_message_send.c | ||
218 | src/messenger/gnunet-service-messenger_message_store.c | ||
219 | src/messenger/gnunet-service-messenger_room.c | ||
220 | src/messenger/gnunet-service-messenger_service.c | ||
221 | src/messenger/gnunet-service-messenger_tunnel.c | ||
222 | src/messenger/gnunet-service-messenger_util.c | ||
223 | src/messenger/messenger_api.c | ||
224 | src/messenger/messenger_api_contact.c | ||
225 | src/messenger/messenger_api_handle.c | ||
226 | src/messenger/messenger_api_list_tunnels.c | ||
227 | src/messenger/messenger_api_message.c | ||
228 | src/messenger/messenger_api_room.c | ||
207 | src/my/my.c | 229 | src/my/my.c |
208 | src/my/my_query_helper.c | 230 | src/my/my_query_helper.c |
209 | src/my/my_result_helper.c | 231 | src/my/my_result_helper.c |
@@ -523,5 +545,7 @@ src/vpn/vpn_api.c | |||
523 | src/zonemaster/gnunet-service-zonemaster.c | 545 | src/zonemaster/gnunet-service-zonemaster.c |
524 | src/zonemaster/gnunet-service-zonemaster-monitor.c | 546 | src/zonemaster/gnunet-service-zonemaster-monitor.c |
525 | src/fs/fs_api.h | 547 | src/fs/fs_api.h |
548 | src/include/gnunet_identity_service.h | ||
549 | src/include/gnunet_messenger_service.h | ||
526 | src/testbed/testbed_api.h | 550 | src/testbed/testbed_api.h |
527 | src/testbed/testbed_api_operations.h | 551 | src/testbed/testbed_api_operations.h |
@@ -10,7 +10,7 @@ msgid "" | |||
10 | msgstr "" | 10 | msgstr "" |
11 | "Project-Id-Version: gnunet 0.10.1\n" | 11 | "Project-Id-Version: gnunet 0.10.1\n" |
12 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" | 12 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" |
13 | "POT-Creation-Date: 2020-09-06 10:07+0200\n" | 13 | "POT-Creation-Date: 2020-10-13 16:12+0200\n" |
14 | "PO-Revision-Date: 2015-03-08 16:16+0100\n" | 14 | "PO-Revision-Date: 2015-03-08 16:16+0100\n" |
15 | "Last-Translator: Mario Blättermann <mario.blaettermann@gmail.com>\n" | 15 | "Last-Translator: Mario Blättermann <mario.blaettermann@gmail.com>\n" |
16 | "Language-Team: German <translation-team-de@lists.sourceforge.net>\n" | 16 | "Language-Team: German <translation-team-de@lists.sourceforge.net>\n" |
@@ -32,8 +32,8 @@ msgid "Issuer public key `%s' is not well-formed\n" | |||
32 | msgstr "" | 32 | msgstr "" |
33 | 33 | ||
34 | #: src/abd/gnunet-abd.c:560 src/abd/gnunet-service-abd.c:1747 | 34 | #: src/abd/gnunet-abd.c:560 src/abd/gnunet-service-abd.c:1747 |
35 | #: src/namestore/gnunet-namestore.c:1001 | ||
36 | #: src/namestore/gnunet-namestore-fcfsd.c:1154 | 35 | #: src/namestore/gnunet-namestore-fcfsd.c:1154 |
36 | #: src/namestore/gnunet-namestore.c:1001 | ||
37 | #, fuzzy, c-format | 37 | #, fuzzy, c-format |
38 | msgid "Failed to connect to namestore\n" | 38 | msgid "Failed to connect to namestore\n" |
39 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" | 39 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" |
@@ -499,81 +499,14 @@ msgstr "" | |||
499 | msgid "Initiating shutdown as requested by client.\n" | 499 | msgid "Initiating shutdown as requested by client.\n" |
500 | msgstr "" | 500 | msgstr "" |
501 | 501 | ||
502 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | 502 | #: src/ats-tests/ats-testing-log.c:896 |
503 | #, c-format | 503 | msgid "Stop logging\n" |
504 | msgid "" | 504 | msgstr "Protokollierung stoppen\n" |
505 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | ||
506 | "%llu\n" | ||
507 | msgstr "" | ||
508 | |||
509 | #: src/ats/gnunet-ats-solver-eval.c:3011 | ||
510 | #, c-format | ||
511 | msgid "" | ||
512 | "No outbound quota configured for network `%s', assigning default bandwidth " | ||
513 | "%llu\n" | ||
514 | msgstr "" | ||
515 | |||
516 | #: src/ats/gnunet-ats-solver-eval.c:3063 | ||
517 | #, c-format | ||
518 | msgid "" | ||
519 | "No outbound quota configure for network `%s', assigning default bandwidth " | ||
520 | "%llu\n" | ||
521 | msgstr "" | ||
522 | |||
523 | #: src/ats/gnunet-ats-solver-eval.c:3552 src/ats-tests/gnunet-solver-eval.c:997 | ||
524 | msgid "solver to use" | ||
525 | msgstr "" | ||
526 | |||
527 | #: src/ats/gnunet-ats-solver-eval.c:3557 | ||
528 | #: src/ats-tests/gnunet-solver-eval.c:1003 | ||
529 | #: src/ats-tests/gnunet-solver-eval.c:1008 | ||
530 | msgid "experiment to use" | ||
531 | msgstr "" | ||
532 | |||
533 | #: src/ats/gnunet-ats-solver-eval.c:3564 | ||
534 | msgid "print logging" | ||
535 | msgstr "" | ||
536 | |||
537 | #: src/ats/gnunet-ats-solver-eval.c:3569 | ||
538 | msgid "save logging to disk" | ||
539 | msgstr "" | ||
540 | |||
541 | #: src/ats/gnunet-ats-solver-eval.c:3574 | ||
542 | msgid "disable normalization" | ||
543 | msgstr "" | ||
544 | |||
545 | #: src/ats/gnunet-service-ats_plugins.c:326 | ||
546 | #, c-format | ||
547 | msgid "" | ||
548 | "Could not load %s quota for network `%s': `%s', assigning default bandwidth " | ||
549 | "%llu\n" | ||
550 | msgstr "" | ||
551 | |||
552 | #: src/ats/gnunet-service-ats_plugins.c:336 | ||
553 | #, c-format | ||
554 | msgid "%s quota configured for network `%s' is %llu\n" | ||
555 | msgstr "" | ||
556 | |||
557 | #: src/ats/gnunet-service-ats_plugins.c:382 | ||
558 | #, c-format | ||
559 | msgid "" | ||
560 | "No %s-quota configured for network `%s', assigning default bandwidth %llu\n" | ||
561 | msgstr "" | ||
562 | |||
563 | #: src/ats/gnunet-service-ats_plugins.c:474 | ||
564 | #, fuzzy, c-format | ||
565 | msgid "Failed to initialize solver `%s'!\n" | ||
566 | msgstr "SQLite Datenbank konnte nicht initialisiert werden.\n" | ||
567 | |||
568 | #: src/ats/plugin_ats_proportional.c:1142 | ||
569 | #, fuzzy, c-format | ||
570 | msgid "Invalid %s configuration %f \n" | ||
571 | msgstr "Konfiguration konnte nicht aus %s geladen werden\n" | ||
572 | 505 | ||
573 | #: src/ats/plugin_ats_proportional.c:1165 | 506 | #: src/ats-tests/ats-testing-log.c:952 |
574 | #, fuzzy, c-format | 507 | #, fuzzy, c-format |
575 | msgid "Invalid %s configuration %f\n" | 508 | msgid "Start logging `%s'\n" |
576 | msgstr " gconfig\tGTK Konfiguration\n" | 509 | msgstr "Collection `%s' begonnen.\n" |
577 | 510 | ||
578 | #: src/ats-tests/ats-testing.c:420 | 511 | #: src/ats-tests/ats-testing.c:420 |
579 | #, c-format | 512 | #, c-format |
@@ -585,15 +518,6 @@ msgstr "" | |||
585 | msgid "Failed to connect master peer [%u] with slave [%u]\n" | 518 | msgid "Failed to connect master peer [%u] with slave [%u]\n" |
586 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" | 519 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" |
587 | 520 | ||
588 | #: src/ats-tests/ats-testing-log.c:896 | ||
589 | msgid "Stop logging\n" | ||
590 | msgstr "Protokollierung stoppen\n" | ||
591 | |||
592 | #: src/ats-tests/ats-testing-log.c:952 | ||
593 | #, fuzzy, c-format | ||
594 | msgid "Start logging `%s'\n" | ||
595 | msgstr "Collection `%s' begonnen.\n" | ||
596 | |||
597 | #: src/ats-tests/gnunet-ats-sim.c:92 | 521 | #: src/ats-tests/gnunet-ats-sim.c:92 |
598 | #, c-format | 522 | #, c-format |
599 | msgid "" | 523 | msgid "" |
@@ -601,6 +525,16 @@ msgid "" | |||
601 | "= %u KiB/s\n" | 525 | "= %u KiB/s\n" |
602 | msgstr "" | 526 | msgstr "" |
603 | 527 | ||
528 | #: src/ats-tests/gnunet-solver-eval.c:997 src/ats/gnunet-ats-solver-eval.c:3552 | ||
529 | msgid "solver to use" | ||
530 | msgstr "" | ||
531 | |||
532 | #: src/ats-tests/gnunet-solver-eval.c:1003 | ||
533 | #: src/ats-tests/gnunet-solver-eval.c:1008 | ||
534 | #: src/ats/gnunet-ats-solver-eval.c:3557 | ||
535 | msgid "experiment to use" | ||
536 | msgstr "" | ||
537 | |||
604 | #: src/ats-tool/gnunet-ats.c:299 | 538 | #: src/ats-tool/gnunet-ats.c:299 |
605 | #, c-format | 539 | #, c-format |
606 | msgid "%u address resolutions had a timeout\n" | 540 | msgid "%u address resolutions had a timeout\n" |
@@ -718,6 +652,72 @@ msgstr "" | |||
718 | msgid "Print information about ATS state" | 652 | msgid "Print information about ATS state" |
719 | msgstr "Informationen über andere GNUnet Knoten ausgeben." | 653 | msgstr "Informationen über andere GNUnet Knoten ausgeben." |
720 | 654 | ||
655 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | ||
656 | #, c-format | ||
657 | msgid "" | ||
658 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | ||
659 | "%llu\n" | ||
660 | msgstr "" | ||
661 | |||
662 | #: src/ats/gnunet-ats-solver-eval.c:3011 | ||
663 | #, c-format | ||
664 | msgid "" | ||
665 | "No outbound quota configured for network `%s', assigning default bandwidth " | ||
666 | "%llu\n" | ||
667 | msgstr "" | ||
668 | |||
669 | #: src/ats/gnunet-ats-solver-eval.c:3063 | ||
670 | #, c-format | ||
671 | msgid "" | ||
672 | "No outbound quota configure for network `%s', assigning default bandwidth " | ||
673 | "%llu\n" | ||
674 | msgstr "" | ||
675 | |||
676 | #: src/ats/gnunet-ats-solver-eval.c:3564 | ||
677 | msgid "print logging" | ||
678 | msgstr "" | ||
679 | |||
680 | #: src/ats/gnunet-ats-solver-eval.c:3569 | ||
681 | msgid "save logging to disk" | ||
682 | msgstr "" | ||
683 | |||
684 | #: src/ats/gnunet-ats-solver-eval.c:3574 | ||
685 | msgid "disable normalization" | ||
686 | msgstr "" | ||
687 | |||
688 | #: src/ats/gnunet-service-ats_plugins.c:326 | ||
689 | #, c-format | ||
690 | msgid "" | ||
691 | "Could not load %s quota for network `%s': `%s', assigning default bandwidth " | ||
692 | "%llu\n" | ||
693 | msgstr "" | ||
694 | |||
695 | #: src/ats/gnunet-service-ats_plugins.c:336 | ||
696 | #, c-format | ||
697 | msgid "%s quota configured for network `%s' is %llu\n" | ||
698 | msgstr "" | ||
699 | |||
700 | #: src/ats/gnunet-service-ats_plugins.c:382 | ||
701 | #, c-format | ||
702 | msgid "" | ||
703 | "No %s-quota configured for network `%s', assigning default bandwidth %llu\n" | ||
704 | msgstr "" | ||
705 | |||
706 | #: src/ats/gnunet-service-ats_plugins.c:474 | ||
707 | #, fuzzy, c-format | ||
708 | msgid "Failed to initialize solver `%s'!\n" | ||
709 | msgstr "SQLite Datenbank konnte nicht initialisiert werden.\n" | ||
710 | |||
711 | #: src/ats/plugin_ats_proportional.c:1142 | ||
712 | #, fuzzy, c-format | ||
713 | msgid "Invalid %s configuration %f \n" | ||
714 | msgstr "Konfiguration konnte nicht aus %s geladen werden\n" | ||
715 | |||
716 | #: src/ats/plugin_ats_proportional.c:1165 | ||
717 | #, fuzzy, c-format | ||
718 | msgid "Invalid %s configuration %f\n" | ||
719 | msgstr " gconfig\tGTK Konfiguration\n" | ||
720 | |||
721 | #: src/auction/gnunet-auction-create.c:163 | 721 | #: src/auction/gnunet-auction-create.c:163 |
722 | msgid "description of the item to be sold" | 722 | msgid "description of the item to be sold" |
723 | msgstr "" | 723 | msgstr "" |
@@ -854,6 +854,28 @@ msgstr "Ausführlicherer Modus (empfangene Werte ausgeben)" | |||
854 | msgid "Connection to conversation service lost, trying to reconnect\n" | 854 | msgid "Connection to conversation service lost, trying to reconnect\n" |
855 | msgstr "" | 855 | msgstr "" |
856 | 856 | ||
857 | #: src/conversation/gnunet-conversation-test.c:120 | ||
858 | #, c-format | ||
859 | msgid "" | ||
860 | "\n" | ||
861 | "End of transmission. Have a GNU day.\n" | ||
862 | msgstr "" | ||
863 | |||
864 | #: src/conversation/gnunet-conversation-test.c:146 | ||
865 | #, c-format | ||
866 | msgid "" | ||
867 | "\n" | ||
868 | "We are now playing your recording back. If you can hear it, your audio " | ||
869 | "settings are working..." | ||
870 | msgstr "" | ||
871 | |||
872 | #: src/conversation/gnunet-conversation-test.c:218 | ||
873 | #, c-format | ||
874 | msgid "" | ||
875 | "We will now be recording you for %s. After that time, the recording will be " | ||
876 | "played back to you..." | ||
877 | msgstr "" | ||
878 | |||
857 | #: src/conversation/gnunet-conversation.c:264 | 879 | #: src/conversation/gnunet-conversation.c:264 |
858 | #, c-format | 880 | #, c-format |
859 | msgid "Incoming call from `%s'. Please /accept %u or /cancel %u the call.\n" | 881 | msgid "Incoming call from `%s'. Please /accept %u or /cancel %u the call.\n" |
@@ -1113,30 +1135,8 @@ msgstr "" | |||
1113 | msgid "Enables having a conversation with other GNUnet users." | 1135 | msgid "Enables having a conversation with other GNUnet users." |
1114 | msgstr "" | 1136 | msgstr "" |
1115 | 1137 | ||
1116 | #: src/conversation/gnunet-conversation-test.c:120 | ||
1117 | #, c-format | ||
1118 | msgid "" | ||
1119 | "\n" | ||
1120 | "End of transmission. Have a GNU day.\n" | ||
1121 | msgstr "" | ||
1122 | |||
1123 | #: src/conversation/gnunet-conversation-test.c:146 | ||
1124 | #, c-format | ||
1125 | msgid "" | ||
1126 | "\n" | ||
1127 | "We are now playing your recording back. If you can hear it, your audio " | ||
1128 | "settings are working..." | ||
1129 | msgstr "" | ||
1130 | |||
1131 | #: src/conversation/gnunet-conversation-test.c:218 | ||
1132 | #, c-format | ||
1133 | msgid "" | ||
1134 | "We will now be recording you for %s. After that time, the recording will be " | ||
1135 | "played back to you..." | ||
1136 | msgstr "" | ||
1137 | |||
1138 | #: src/conversation/gnunet_gst.c:664 | ||
1139 | #: src/conversation/gnunet-helper-audio-playback-gst.c:363 | 1138 | #: src/conversation/gnunet-helper-audio-playback-gst.c:363 |
1139 | #: src/conversation/gnunet_gst.c:664 | ||
1140 | #, c-format | 1140 | #, c-format |
1141 | msgid "Read error from STDIN: %d %s\n" | 1141 | msgid "Read error from STDIN: %d %s\n" |
1142 | msgstr "Fehler beim Lesen aus STDIN: %d %s\n" | 1142 | msgstr "Fehler beim Lesen aus STDIN: %d %s\n" |
@@ -1942,17 +1942,17 @@ msgstr "`%s' an `%s' schlug fehl bei %s:%d mit dem Fehler: %s\n" | |||
1942 | msgid "Mysql database running\n" | 1942 | msgid "Mysql database running\n" |
1943 | msgstr "MySQL-Datenbank läuft\n" | 1943 | msgstr "MySQL-Datenbank läuft\n" |
1944 | 1944 | ||
1945 | #: src/datastore/plugin_datastore_postgres.c:278 | 1945 | #: src/datastore/plugin_datastore_postgres.c:284 |
1946 | #: src/datastore/plugin_datastore_postgres.c:891 | 1946 | #: src/datastore/plugin_datastore_postgres.c:897 |
1947 | msgid "Postgress exec failure" | 1947 | msgid "Postgress exec failure" |
1948 | msgstr "" | 1948 | msgstr "" |
1949 | 1949 | ||
1950 | #: src/datastore/plugin_datastore_postgres.c:852 | 1950 | #: src/datastore/plugin_datastore_postgres.c:858 |
1951 | #, fuzzy | 1951 | #, fuzzy |
1952 | msgid "Failed to drop table from database.\n" | 1952 | msgid "Failed to drop table from database.\n" |
1953 | msgstr "Fehler beim Binden an UDP Port %d.\n" | 1953 | msgstr "Fehler beim Binden an UDP Port %d.\n" |
1954 | 1954 | ||
1955 | #: src/datastore/plugin_datastore_postgres.c:950 | 1955 | #: src/datastore/plugin_datastore_postgres.c:956 |
1956 | msgid "Postgres database running\n" | 1956 | msgid "Postgres database running\n" |
1957 | msgstr "PostgreSQL-Datenbank läuft\n" | 1957 | msgstr "PostgreSQL-Datenbank läuft\n" |
1958 | 1958 | ||
@@ -2059,53 +2059,6 @@ msgstr "" | |||
2059 | msgid "Prints all packets that go through the DHT." | 2059 | msgid "Prints all packets that go through the DHT." |
2060 | msgstr "" | 2060 | msgstr "" |
2061 | 2061 | ||
2062 | #: src/dht/gnunet_dht_profiler.c:922 src/testbed/gnunet-testbed-profiler.c:255 | ||
2063 | #, c-format | ||
2064 | msgid "Exiting as the number of peers is %u\n" | ||
2065 | msgstr "" | ||
2066 | |||
2067 | #: src/dht/gnunet_dht_profiler.c:955 src/rps/gnunet-rps-profiler.c:3194 | ||
2068 | #, fuzzy | ||
2069 | msgid "number of peers to start" | ||
2070 | msgstr "Anzahl an Durchläufen" | ||
2071 | |||
2072 | #: src/dht/gnunet_dht_profiler.c:961 | ||
2073 | msgid "number of PUTs to perform per peer" | ||
2074 | msgstr "" | ||
2075 | |||
2076 | #: src/dht/gnunet_dht_profiler.c:967 src/nse/gnunet-nse-profiler.c:872 | ||
2077 | #: src/testbed/gnunet-testbed-profiler.c:305 | ||
2078 | msgid "name of the file with the login information for the testbed" | ||
2079 | msgstr "" | ||
2080 | |||
2081 | #: src/dht/gnunet_dht_profiler.c:973 | ||
2082 | msgid "delay between rounds for collecting statistics (default: 30 sec)" | ||
2083 | msgstr "" | ||
2084 | |||
2085 | #: src/dht/gnunet_dht_profiler.c:979 | ||
2086 | msgid "delay to start doing PUTs (default: 1 sec)" | ||
2087 | msgstr "" | ||
2088 | |||
2089 | #: src/dht/gnunet_dht_profiler.c:985 | ||
2090 | msgid "delay to start doing GETs (default: 5 min)" | ||
2091 | msgstr "" | ||
2092 | |||
2093 | #: src/dht/gnunet_dht_profiler.c:990 | ||
2094 | msgid "replication degree for DHT PUTs" | ||
2095 | msgstr "" | ||
2096 | |||
2097 | #: src/dht/gnunet_dht_profiler.c:996 | ||
2098 | msgid "chance that a peer is selected at random for PUTs" | ||
2099 | msgstr "" | ||
2100 | |||
2101 | #: src/dht/gnunet_dht_profiler.c:1002 | ||
2102 | msgid "timeout for DHT PUT and GET requests (default: 1 min)" | ||
2103 | msgstr "" | ||
2104 | |||
2105 | #: src/dht/gnunet_dht_profiler.c:1023 | ||
2106 | msgid "Measure quality and performance of the DHT service." | ||
2107 | msgstr "" | ||
2108 | |||
2109 | #: src/dht/gnunet-dht-put.c:133 | 2062 | #: src/dht/gnunet-dht-put.c:133 |
2110 | msgid "Must provide KEY and DATA for DHT put!\n" | 2063 | msgid "Must provide KEY and DATA for DHT put!\n" |
2111 | msgstr "" | 2064 | msgstr "" |
@@ -2370,6 +2323,53 @@ msgstr "" | |||
2370 | msgid "# DHT requests combined" | 2323 | msgid "# DHT requests combined" |
2371 | msgstr "# dht Anfragen weitergeleitet" | 2324 | msgstr "# dht Anfragen weitergeleitet" |
2372 | 2325 | ||
2326 | #: src/dht/gnunet_dht_profiler.c:922 src/testbed/gnunet-testbed-profiler.c:255 | ||
2327 | #, c-format | ||
2328 | msgid "Exiting as the number of peers is %u\n" | ||
2329 | msgstr "" | ||
2330 | |||
2331 | #: src/dht/gnunet_dht_profiler.c:955 src/rps/gnunet-rps-profiler.c:3194 | ||
2332 | #, fuzzy | ||
2333 | msgid "number of peers to start" | ||
2334 | msgstr "Anzahl an Durchläufen" | ||
2335 | |||
2336 | #: src/dht/gnunet_dht_profiler.c:961 | ||
2337 | msgid "number of PUTs to perform per peer" | ||
2338 | msgstr "" | ||
2339 | |||
2340 | #: src/dht/gnunet_dht_profiler.c:967 src/nse/gnunet-nse-profiler.c:872 | ||
2341 | #: src/testbed/gnunet-testbed-profiler.c:305 | ||
2342 | msgid "name of the file with the login information for the testbed" | ||
2343 | msgstr "" | ||
2344 | |||
2345 | #: src/dht/gnunet_dht_profiler.c:973 | ||
2346 | msgid "delay between rounds for collecting statistics (default: 30 sec)" | ||
2347 | msgstr "" | ||
2348 | |||
2349 | #: src/dht/gnunet_dht_profiler.c:979 | ||
2350 | msgid "delay to start doing PUTs (default: 1 sec)" | ||
2351 | msgstr "" | ||
2352 | |||
2353 | #: src/dht/gnunet_dht_profiler.c:985 | ||
2354 | msgid "delay to start doing GETs (default: 5 min)" | ||
2355 | msgstr "" | ||
2356 | |||
2357 | #: src/dht/gnunet_dht_profiler.c:990 | ||
2358 | msgid "replication degree for DHT PUTs" | ||
2359 | msgstr "" | ||
2360 | |||
2361 | #: src/dht/gnunet_dht_profiler.c:996 | ||
2362 | msgid "chance that a peer is selected at random for PUTs" | ||
2363 | msgstr "" | ||
2364 | |||
2365 | #: src/dht/gnunet_dht_profiler.c:1002 | ||
2366 | msgid "timeout for DHT PUT and GET requests (default: 1 min)" | ||
2367 | msgstr "" | ||
2368 | |||
2369 | #: src/dht/gnunet_dht_profiler.c:1023 | ||
2370 | msgid "Measure quality and performance of the DHT service." | ||
2371 | msgstr "" | ||
2372 | |||
2373 | #: src/dht/plugin_block_dht.c:189 | 2373 | #: src/dht/plugin_block_dht.c:189 |
2374 | #, fuzzy, c-format | 2374 | #, fuzzy, c-format |
2375 | msgid "Block not of type %u\n" | 2375 | msgid "Block not of type %u\n" |
@@ -3319,15 +3319,6 @@ msgid "" | |||
3319 | "chk/...)" | 3319 | "chk/...)" |
3320 | msgstr "" | 3320 | msgstr "" |
3321 | 3321 | ||
3322 | #: src/fs/gnunet-fs.c:128 | ||
3323 | msgid "print a list of all indexed files" | ||
3324 | msgstr "" | ||
3325 | |||
3326 | #: src/fs/gnunet-fs.c:141 | ||
3327 | #, fuzzy | ||
3328 | msgid "Special file-sharing operations" | ||
3329 | msgstr "Alle Optionen anzeigen" | ||
3330 | |||
3331 | #: src/fs/gnunet-fs-profiler.c:211 | 3322 | #: src/fs/gnunet-fs-profiler.c:211 |
3332 | msgid "run the experiment with COUNT peers" | 3323 | msgid "run the experiment with COUNT peers" |
3333 | msgstr "" | 3324 | msgstr "" |
@@ -3344,6 +3335,15 @@ msgstr "" | |||
3344 | msgid "run a testbed to measure file-sharing performance" | 3335 | msgid "run a testbed to measure file-sharing performance" |
3345 | msgstr "" | 3336 | msgstr "" |
3346 | 3337 | ||
3338 | #: src/fs/gnunet-fs.c:128 | ||
3339 | msgid "print a list of all indexed files" | ||
3340 | msgstr "" | ||
3341 | |||
3342 | #: src/fs/gnunet-fs.c:141 | ||
3343 | #, fuzzy | ||
3344 | msgid "Special file-sharing operations" | ||
3345 | msgstr "Alle Optionen anzeigen" | ||
3346 | |||
3347 | #: src/fs/gnunet-publish.c:219 src/fs/gnunet-publish.c:234 | 3347 | #: src/fs/gnunet-publish.c:219 src/fs/gnunet-publish.c:234 |
3348 | #, c-format | 3348 | #, c-format |
3349 | msgid "Publishing `%s' at %llu/%llu (%s remaining)\n" | 3349 | msgid "Publishing `%s' at %llu/%llu (%s remaining)\n" |
@@ -4042,52 +4042,6 @@ msgstr "" | |||
4042 | msgid "look for GNS2DNS records instead of ANY" | 4042 | msgid "look for GNS2DNS records instead of ANY" |
4043 | msgstr "" | 4043 | msgstr "" |
4044 | 4044 | ||
4045 | #: src/gns/gnunet-gns.c:257 | ||
4046 | #, fuzzy, c-format | ||
4047 | msgid "`%s' is not a valid DNS domain name\n" | ||
4048 | msgstr "»%s« ist keine gültige IP-Adresse.\n" | ||
4049 | |||
4050 | #: src/gns/gnunet-gns.c:267 src/util/dnsparser.c:254 | ||
4051 | #, c-format | ||
4052 | msgid "Failed to convert DNS IDNA name `%s' to UTF-8: %s\n" | ||
4053 | msgstr "" | ||
4054 | |||
4055 | #: src/gns/gnunet-gns.c:281 | ||
4056 | msgid "Cannot resolve using GNS: GNUnet peer not running\n" | ||
4057 | msgstr "" | ||
4058 | |||
4059 | #: src/gns/gnunet-gns.c:305 | ||
4060 | #, c-format | ||
4061 | msgid "Invalid typename specified, assuming `ANY'\n" | ||
4062 | msgstr "" | ||
4063 | |||
4064 | #: src/gns/gnunet-gns.c:340 | ||
4065 | msgid "Lookup a record for the given name" | ||
4066 | msgstr "" | ||
4067 | |||
4068 | #: src/gns/gnunet-gns.c:346 | ||
4069 | #, fuzzy | ||
4070 | msgid "Specify the type of the record to lookup" | ||
4071 | msgstr "Die Priorität des Inhalts angeben" | ||
4072 | |||
4073 | #: src/gns/gnunet-gns.c:352 | ||
4074 | #, fuzzy | ||
4075 | msgid "Specify a timeout for the lookup" | ||
4076 | msgstr "Die Priorität des Inhalts angeben" | ||
4077 | |||
4078 | #: src/gns/gnunet-gns.c:356 | ||
4079 | msgid "No unneeded output" | ||
4080 | msgstr "" | ||
4081 | |||
4082 | #: src/gns/gnunet-gns.c:361 | ||
4083 | msgid "DNS Compatibility: Name is passed in IDNA instead of UTF-8" | ||
4084 | msgstr "" | ||
4085 | |||
4086 | #: src/gns/gnunet-gns.c:375 | ||
4087 | #, fuzzy | ||
4088 | msgid "GNUnet GNS resolver tool" | ||
4089 | msgstr "GNUnet Netzwerk Topologie tracen." | ||
4090 | |||
4091 | #: src/gns/gnunet-gns-import.c:486 | 4045 | #: src/gns/gnunet-gns-import.c:486 |
4092 | msgid "This program will import some GNS authorities into your GNS namestore." | 4046 | msgid "This program will import some GNS authorities into your GNS namestore." |
4093 | msgstr "" | 4047 | msgstr "" |
@@ -4208,6 +4162,52 @@ msgstr "" | |||
4208 | msgid "GNUnet GNS proxy" | 4162 | msgid "GNUnet GNS proxy" |
4209 | msgstr "" | 4163 | msgstr "" |
4210 | 4164 | ||
4165 | #: src/gns/gnunet-gns.c:257 | ||
4166 | #, fuzzy, c-format | ||
4167 | msgid "`%s' is not a valid DNS domain name\n" | ||
4168 | msgstr "»%s« ist keine gültige IP-Adresse.\n" | ||
4169 | |||
4170 | #: src/gns/gnunet-gns.c:267 src/util/dnsparser.c:254 | ||
4171 | #, c-format | ||
4172 | msgid "Failed to convert DNS IDNA name `%s' to UTF-8: %s\n" | ||
4173 | msgstr "" | ||
4174 | |||
4175 | #: src/gns/gnunet-gns.c:281 | ||
4176 | msgid "Cannot resolve using GNS: GNUnet peer not running\n" | ||
4177 | msgstr "" | ||
4178 | |||
4179 | #: src/gns/gnunet-gns.c:305 | ||
4180 | #, c-format | ||
4181 | msgid "Invalid typename specified, assuming `ANY'\n" | ||
4182 | msgstr "" | ||
4183 | |||
4184 | #: src/gns/gnunet-gns.c:340 | ||
4185 | msgid "Lookup a record for the given name" | ||
4186 | msgstr "" | ||
4187 | |||
4188 | #: src/gns/gnunet-gns.c:346 | ||
4189 | #, fuzzy | ||
4190 | msgid "Specify the type of the record to lookup" | ||
4191 | msgstr "Die Priorität des Inhalts angeben" | ||
4192 | |||
4193 | #: src/gns/gnunet-gns.c:352 | ||
4194 | #, fuzzy | ||
4195 | msgid "Specify a timeout for the lookup" | ||
4196 | msgstr "Die Priorität des Inhalts angeben" | ||
4197 | |||
4198 | #: src/gns/gnunet-gns.c:356 | ||
4199 | msgid "No unneeded output" | ||
4200 | msgstr "" | ||
4201 | |||
4202 | #: src/gns/gnunet-gns.c:361 | ||
4203 | msgid "DNS Compatibility: Name is passed in IDNA instead of UTF-8" | ||
4204 | msgstr "" | ||
4205 | |||
4206 | #: src/gns/gnunet-gns.c:375 | ||
4207 | #, fuzzy | ||
4208 | msgid "GNUnet GNS resolver tool" | ||
4209 | msgstr "GNUnet Netzwerk Topologie tracen." | ||
4210 | |||
4211 | #: src/gns/gnunet-service-gns.c:505 | 4211 | #: src/gns/gnunet-service-gns.c:505 |
4212 | #, fuzzy | 4212 | #, fuzzy |
4213 | msgid "Properly base32-encoded public key required" | 4213 | msgid "Properly base32-encoded public key required" |
@@ -4219,8 +4219,8 @@ msgid "Failed to connect to the namecache!\n" | |||
4219 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" | 4219 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" |
4220 | 4220 | ||
4221 | #: src/gns/gnunet-service-gns.c:560 | 4221 | #: src/gns/gnunet-service-gns.c:560 |
4222 | #: src/zonemaster/gnunet-service-zonemaster.c:887 | ||
4223 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:444 | 4222 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:444 |
4223 | #: src/zonemaster/gnunet-service-zonemaster.c:887 | ||
4224 | #, fuzzy | 4224 | #, fuzzy |
4225 | msgid "Could not connect to DHT!\n" | 4225 | msgid "Could not connect to DHT!\n" |
4226 | msgstr "Verbindung zu gnunetd konnte nicht hergestellt werden.\n" | 4226 | msgstr "Verbindung zu gnunetd konnte nicht hergestellt werden.\n" |
@@ -4722,7 +4722,7 @@ msgid "# hostlist advertisements send" | |||
4722 | msgstr "# Bekanntmachungen von anderen übertragen" | 4722 | msgstr "# Bekanntmachungen von anderen übertragen" |
4723 | 4723 | ||
4724 | #: src/hostlist/gnunet-daemon-hostlist_server.c:674 | 4724 | #: src/hostlist/gnunet-daemon-hostlist_server.c:674 |
4725 | #: src/transport/gnunet-service-transport.c:2659 | 4725 | #: src/transport/gnunet-service-transport.c:2661 |
4726 | #, fuzzy | 4726 | #, fuzzy |
4727 | msgid "Could not access PEERINFO service. Exiting.\n" | 4727 | msgid "Could not access PEERINFO service. Exiting.\n" |
4728 | msgstr "Auf die Namespace Informationen konnte nicht zugegriffen werden.\n" | 4728 | msgstr "Auf die Namespace Informationen konnte nicht zugegriffen werden.\n" |
@@ -4975,6 +4975,70 @@ msgstr "Sqlite-Datenbank läuft\n" | |||
4975 | msgid "Failed to setup database at `%s'\n" | 4975 | msgid "Failed to setup database at `%s'\n" |
4976 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" | 4976 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" |
4977 | 4977 | ||
4978 | #: src/namestore/gnunet-namestore-fcfsd.c:552 | ||
4979 | #, fuzzy, c-format | ||
4980 | msgid "Unsupported form value `%s'\n" | ||
4981 | msgstr "Kommando `%s' wird nicht unterstützt. Vorgang wird abgebrochen.\n" | ||
4982 | |||
4983 | #: src/namestore/gnunet-namestore-fcfsd.c:579 | ||
4984 | #, fuzzy, c-format | ||
4985 | msgid "Failed to create record for domain `%s': %s\n" | ||
4986 | msgstr "Fehler beim Lesen der Freunde-Liste von `%s'\n" | ||
4987 | |||
4988 | #: src/namestore/gnunet-namestore-fcfsd.c:600 | ||
4989 | msgid "Error when mapping zone to name\n" | ||
4990 | msgstr "" | ||
4991 | |||
4992 | #: src/namestore/gnunet-namestore-fcfsd.c:632 | ||
4993 | #, c-format | ||
4994 | msgid "Found existing name `%s' for the given key\n" | ||
4995 | msgstr "" | ||
4996 | |||
4997 | #: src/namestore/gnunet-namestore-fcfsd.c:694 | ||
4998 | #, c-format | ||
4999 | msgid "Found %u existing records for domain `%s'\n" | ||
5000 | msgstr "" | ||
5001 | |||
5002 | #: src/namestore/gnunet-namestore-fcfsd.c:784 | ||
5003 | #, fuzzy, c-format | ||
5004 | msgid "Failed to create page for `%s'\n" | ||
5005 | msgstr "Fehler beim Aktualisieren der Daten des Moduls `%s'\n" | ||
5006 | |||
5007 | #: src/namestore/gnunet-namestore-fcfsd.c:803 | ||
5008 | #, fuzzy, c-format | ||
5009 | msgid "Failed to setup post processor for `%s'\n" | ||
5010 | msgstr "Fehler beim Aktualisieren der Daten des Moduls `%s'\n" | ||
5011 | |||
5012 | #: src/namestore/gnunet-namestore-fcfsd.c:840 | ||
5013 | msgid "Domain name must not contain `.'\n" | ||
5014 | msgstr "" | ||
5015 | |||
5016 | #: src/namestore/gnunet-namestore-fcfsd.c:849 | ||
5017 | msgid "Domain name must not contain `+'\n" | ||
5018 | msgstr "" | ||
5019 | |||
5020 | #: src/namestore/gnunet-namestore-fcfsd.c:1084 | ||
5021 | msgid "No ego configured for `fcfsd` subsystem\n" | ||
5022 | msgstr "" | ||
5023 | |||
5024 | #: src/namestore/gnunet-namestore-fcfsd.c:1115 | ||
5025 | #, fuzzy | ||
5026 | msgid "Failed to start HTTP server\n" | ||
5027 | msgstr "Fehler beim Senden einer `%s' Anfrage an den SMTP Server.\n" | ||
5028 | |||
5029 | #: src/namestore/gnunet-namestore-fcfsd.c:1163 | ||
5030 | #, fuzzy | ||
5031 | msgid "Failed to connect to identity\n" | ||
5032 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" | ||
5033 | |||
5034 | #: src/namestore/gnunet-namestore-fcfsd.c:1190 | ||
5035 | msgid "name of the zone that is to be managed by FCFSD" | ||
5036 | msgstr "" | ||
5037 | |||
5038 | #: src/namestore/gnunet-namestore-fcfsd.c:1210 | ||
5039 | msgid "GNU Name System First Come First Serve name registration service" | ||
5040 | msgstr "" | ||
5041 | |||
4978 | #: src/namestore/gnunet-namestore.c:334 | 5042 | #: src/namestore/gnunet-namestore.c:334 |
4979 | #, c-format | 5043 | #, c-format |
4980 | msgid "Adding record failed: %s\n" | 5044 | msgid "Adding record failed: %s\n" |
@@ -5201,70 +5265,6 @@ msgstr "" | |||
5201 | msgid "name of the ego controlling the zone" | 5265 | msgid "name of the ego controlling the zone" |
5202 | msgstr "" | 5266 | msgstr "" |
5203 | 5267 | ||
5204 | #: src/namestore/gnunet-namestore-fcfsd.c:552 | ||
5205 | #, fuzzy, c-format | ||
5206 | msgid "Unsupported form value `%s'\n" | ||
5207 | msgstr "Kommando `%s' wird nicht unterstützt. Vorgang wird abgebrochen.\n" | ||
5208 | |||
5209 | #: src/namestore/gnunet-namestore-fcfsd.c:579 | ||
5210 | #, fuzzy, c-format | ||
5211 | msgid "Failed to create record for domain `%s': %s\n" | ||
5212 | msgstr "Fehler beim Lesen der Freunde-Liste von `%s'\n" | ||
5213 | |||
5214 | #: src/namestore/gnunet-namestore-fcfsd.c:600 | ||
5215 | msgid "Error when mapping zone to name\n" | ||
5216 | msgstr "" | ||
5217 | |||
5218 | #: src/namestore/gnunet-namestore-fcfsd.c:632 | ||
5219 | #, c-format | ||
5220 | msgid "Found existing name `%s' for the given key\n" | ||
5221 | msgstr "" | ||
5222 | |||
5223 | #: src/namestore/gnunet-namestore-fcfsd.c:694 | ||
5224 | #, c-format | ||
5225 | msgid "Found %u existing records for domain `%s'\n" | ||
5226 | msgstr "" | ||
5227 | |||
5228 | #: src/namestore/gnunet-namestore-fcfsd.c:784 | ||
5229 | #, fuzzy, c-format | ||
5230 | msgid "Failed to create page for `%s'\n" | ||
5231 | msgstr "Fehler beim Aktualisieren der Daten des Moduls `%s'\n" | ||
5232 | |||
5233 | #: src/namestore/gnunet-namestore-fcfsd.c:803 | ||
5234 | #, fuzzy, c-format | ||
5235 | msgid "Failed to setup post processor for `%s'\n" | ||
5236 | msgstr "Fehler beim Aktualisieren der Daten des Moduls `%s'\n" | ||
5237 | |||
5238 | #: src/namestore/gnunet-namestore-fcfsd.c:840 | ||
5239 | msgid "Domain name must not contain `.'\n" | ||
5240 | msgstr "" | ||
5241 | |||
5242 | #: src/namestore/gnunet-namestore-fcfsd.c:849 | ||
5243 | msgid "Domain name must not contain `+'\n" | ||
5244 | msgstr "" | ||
5245 | |||
5246 | #: src/namestore/gnunet-namestore-fcfsd.c:1084 | ||
5247 | msgid "No ego configured for `fcfsd` subsystem\n" | ||
5248 | msgstr "" | ||
5249 | |||
5250 | #: src/namestore/gnunet-namestore-fcfsd.c:1115 | ||
5251 | #, fuzzy | ||
5252 | msgid "Failed to start HTTP server\n" | ||
5253 | msgstr "Fehler beim Senden einer `%s' Anfrage an den SMTP Server.\n" | ||
5254 | |||
5255 | #: src/namestore/gnunet-namestore-fcfsd.c:1163 | ||
5256 | #, fuzzy | ||
5257 | msgid "Failed to connect to identity\n" | ||
5258 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" | ||
5259 | |||
5260 | #: src/namestore/gnunet-namestore-fcfsd.c:1190 | ||
5261 | msgid "name of the zone that is to be managed by FCFSD" | ||
5262 | msgstr "" | ||
5263 | |||
5264 | #: src/namestore/gnunet-namestore-fcfsd.c:1210 | ||
5265 | msgid "GNU Name System First Come First Serve name registration service" | ||
5266 | msgstr "" | ||
5267 | |||
5268 | #: src/namestore/gnunet-service-namestore.c:866 | 5268 | #: src/namestore/gnunet-service-namestore.c:866 |
5269 | #, c-format | 5269 | #, c-format |
5270 | msgid "Failed to replicate block in namecache: %s\n" | 5270 | msgid "Failed to replicate block in namecache: %s\n" |
@@ -5587,10 +5587,6 @@ msgstr "Kommando `%s' wurde nicht gefunden!\n" | |||
5587 | msgid "`upnpc' command not found\n" | 5587 | msgid "`upnpc' command not found\n" |
5588 | msgstr "Kommando `%s' wurde nicht gefunden!\n" | 5588 | msgstr "Kommando `%s' wurde nicht gefunden!\n" |
5589 | 5589 | ||
5590 | #: src/nse/gnunet-nse.c:124 | ||
5591 | msgid "Show network size estimates from NSE service." | ||
5592 | msgstr "" | ||
5593 | |||
5594 | #: src/nse/gnunet-nse-profiler.c:857 | 5590 | #: src/nse/gnunet-nse-profiler.c:857 |
5595 | msgid "limit to the number of connections to NSE services, 0 for none" | 5591 | msgid "limit to the number of connections to NSE services, 0 for none" |
5596 | msgstr "" | 5592 | msgstr "" |
@@ -5615,68 +5611,15 @@ msgstr "" | |||
5615 | msgid "Measure quality and performance of the NSE service." | 5611 | msgid "Measure quality and performance of the NSE service." |
5616 | msgstr "" | 5612 | msgstr "" |
5617 | 5613 | ||
5614 | #: src/nse/gnunet-nse.c:124 | ||
5615 | msgid "Show network size estimates from NSE service." | ||
5616 | msgstr "" | ||
5617 | |||
5618 | #: src/nse/gnunet-service-nse.c:1443 | 5618 | #: src/nse/gnunet-service-nse.c:1443 |
5619 | #: src/revocation/gnunet-service-revocation.c:834 src/util/gnunet-scrypt.c:257 | 5619 | #: src/revocation/gnunet-service-revocation.c:834 src/util/gnunet-scrypt.c:257 |
5620 | msgid "Value is too large.\n" | 5620 | msgid "Value is too large.\n" |
5621 | msgstr "" | 5621 | msgstr "" |
5622 | 5622 | ||
5623 | #: src/peerinfo/gnunet-service-peerinfo.c:175 | ||
5624 | #, fuzzy, c-format | ||
5625 | msgid "Removing expired address of transport `%s'\n" | ||
5626 | msgstr "Verfügbare(r) Transport(e): %s\n" | ||
5627 | |||
5628 | #: src/peerinfo/gnunet-service-peerinfo.c:306 | ||
5629 | #, fuzzy, c-format | ||
5630 | msgid "Failed to parse HELLO in file `%s': %s\n" | ||
5631 | msgstr "Datei wurde als `%s' gespeichert.\n" | ||
5632 | |||
5633 | #: src/peerinfo/gnunet-service-peerinfo.c:323 | ||
5634 | #: src/peerinfo/gnunet-service-peerinfo.c:348 | ||
5635 | #, fuzzy, c-format | ||
5636 | msgid "Failed to parse HELLO in file `%s'\n" | ||
5637 | msgstr "Datei wurde als `%s' gespeichert.\n" | ||
5638 | |||
5639 | #: src/peerinfo/gnunet-service-peerinfo.c:426 | ||
5640 | msgid "# peers known" | ||
5641 | msgstr "" | ||
5642 | |||
5643 | #: src/peerinfo/gnunet-service-peerinfo.c:468 | ||
5644 | #, c-format | ||
5645 | msgid "" | ||
5646 | "File `%s' in directory `%s' does not match naming convention. Removed.\n" | ||
5647 | msgstr "" | ||
5648 | "Die Datei »%s« im Verzeichnis »%s« entspricht nicht der Namenskonvention. " | ||
5649 | "Die Datei wurde entfernt.\n" | ||
5650 | |||
5651 | #: src/peerinfo/gnunet-service-peerinfo.c:624 | ||
5652 | #, fuzzy, c-format | ||
5653 | msgid "Scanning directory `%s'\n" | ||
5654 | msgstr "==> Verzeichnis `%s':\n" | ||
5655 | |||
5656 | #: src/peerinfo/gnunet-service-peerinfo.c:631 | ||
5657 | #, fuzzy, c-format | ||
5658 | msgid "Still no peers found in `%s'!\n" | ||
5659 | msgstr "Dienst `%s' konnte nicht ordentlich entladen werden!\n" | ||
5660 | |||
5661 | #: src/peerinfo/gnunet-service-peerinfo.c:1024 | ||
5662 | #, fuzzy, c-format | ||
5663 | msgid "Cleaning up directory `%s'\n" | ||
5664 | msgstr "==> Verzeichnis `%s':\n" | ||
5665 | |||
5666 | #: src/peerinfo/gnunet-service-peerinfo.c:1319 | ||
5667 | #, c-format | ||
5668 | msgid "Importing HELLOs from `%s'\n" | ||
5669 | msgstr "" | ||
5670 | |||
5671 | #: src/peerinfo/gnunet-service-peerinfo.c:1332 | ||
5672 | msgid "Skipping import of included HELLOs\n" | ||
5673 | msgstr "" | ||
5674 | |||
5675 | #: src/peerinfo/peerinfo_api.c:217 | ||
5676 | #, fuzzy | ||
5677 | msgid "Failed to receive response from `PEERINFO' service." | ||
5678 | msgstr "Fehler beim Empfangen der Antwort von gnunetd auf die `%s' Nachricht\n" | ||
5679 | |||
5680 | #: src/peerinfo-tool/gnunet-peerinfo.c:237 | 5623 | #: src/peerinfo-tool/gnunet-peerinfo.c:237 |
5681 | #, fuzzy, c-format | 5624 | #, fuzzy, c-format |
5682 | msgid "%sPeer `%s'\n" | 5625 | msgid "%sPeer `%s'\n" |
@@ -5773,6 +5716,63 @@ msgstr "Anwendung `%s' konnte nicht initialisiert werden.\n" | |||
5773 | msgid "Peerinfo REST API initialized\n" | 5716 | msgid "Peerinfo REST API initialized\n" |
5774 | msgstr " Verbindung fehlgeschlagen\n" | 5717 | msgstr " Verbindung fehlgeschlagen\n" |
5775 | 5718 | ||
5719 | #: src/peerinfo/gnunet-service-peerinfo.c:175 | ||
5720 | #, fuzzy, c-format | ||
5721 | msgid "Removing expired address of transport `%s'\n" | ||
5722 | msgstr "Verfügbare(r) Transport(e): %s\n" | ||
5723 | |||
5724 | #: src/peerinfo/gnunet-service-peerinfo.c:306 | ||
5725 | #, fuzzy, c-format | ||
5726 | msgid "Failed to parse HELLO in file `%s': %s\n" | ||
5727 | msgstr "Datei wurde als `%s' gespeichert.\n" | ||
5728 | |||
5729 | #: src/peerinfo/gnunet-service-peerinfo.c:323 | ||
5730 | #: src/peerinfo/gnunet-service-peerinfo.c:348 | ||
5731 | #, fuzzy, c-format | ||
5732 | msgid "Failed to parse HELLO in file `%s'\n" | ||
5733 | msgstr "Datei wurde als `%s' gespeichert.\n" | ||
5734 | |||
5735 | #: src/peerinfo/gnunet-service-peerinfo.c:426 | ||
5736 | msgid "# peers known" | ||
5737 | msgstr "" | ||
5738 | |||
5739 | #: src/peerinfo/gnunet-service-peerinfo.c:468 | ||
5740 | #, c-format | ||
5741 | msgid "" | ||
5742 | "File `%s' in directory `%s' does not match naming convention. Removed.\n" | ||
5743 | msgstr "" | ||
5744 | "Die Datei »%s« im Verzeichnis »%s« entspricht nicht der Namenskonvention. " | ||
5745 | "Die Datei wurde entfernt.\n" | ||
5746 | |||
5747 | #: src/peerinfo/gnunet-service-peerinfo.c:624 | ||
5748 | #, fuzzy, c-format | ||
5749 | msgid "Scanning directory `%s'\n" | ||
5750 | msgstr "==> Verzeichnis `%s':\n" | ||
5751 | |||
5752 | #: src/peerinfo/gnunet-service-peerinfo.c:631 | ||
5753 | #, fuzzy, c-format | ||
5754 | msgid "Still no peers found in `%s'!\n" | ||
5755 | msgstr "Dienst `%s' konnte nicht ordentlich entladen werden!\n" | ||
5756 | |||
5757 | #: src/peerinfo/gnunet-service-peerinfo.c:1024 | ||
5758 | #, fuzzy, c-format | ||
5759 | msgid "Cleaning up directory `%s'\n" | ||
5760 | msgstr "==> Verzeichnis `%s':\n" | ||
5761 | |||
5762 | #: src/peerinfo/gnunet-service-peerinfo.c:1319 | ||
5763 | #, c-format | ||
5764 | msgid "Importing HELLOs from `%s'\n" | ||
5765 | msgstr "" | ||
5766 | |||
5767 | #: src/peerinfo/gnunet-service-peerinfo.c:1332 | ||
5768 | msgid "Skipping import of included HELLOs\n" | ||
5769 | msgstr "" | ||
5770 | |||
5771 | #: src/peerinfo/peerinfo_api.c:217 | ||
5772 | #, fuzzy | ||
5773 | msgid "Failed to receive response from `PEERINFO' service." | ||
5774 | msgstr "Fehler beim Empfangen der Antwort von gnunetd auf die `%s' Nachricht\n" | ||
5775 | |||
5776 | #: src/peerstore/gnunet-peerstore.c:92 | 5776 | #: src/peerstore/gnunet-peerstore.c:92 |
5777 | msgid "peerstore" | 5777 | msgid "peerstore" |
5778 | msgstr "" | 5778 | msgstr "" |
@@ -6231,18 +6231,6 @@ msgstr "" | |||
6231 | msgid "Could not open revocation database file!" | 6231 | msgid "Could not open revocation database file!" |
6232 | msgstr "Knoten `%s' konnte nicht in der Routing Tabelle gefunden werden!\n" | 6232 | msgstr "Knoten `%s' konnte nicht in der Routing Tabelle gefunden werden!\n" |
6233 | 6233 | ||
6234 | #: src/rps/gnunet-rps.c:270 | ||
6235 | msgid "Seed a PeerID" | ||
6236 | msgstr "" | ||
6237 | |||
6238 | #: src/rps/gnunet-rps.c:275 | ||
6239 | msgid "Get updates of view (0 for infinite updates)" | ||
6240 | msgstr "" | ||
6241 | |||
6242 | #: src/rps/gnunet-rps.c:279 | ||
6243 | msgid "Get peers from biased stream" | ||
6244 | msgstr "" | ||
6245 | |||
6246 | #: src/rps/gnunet-rps-profiler.c:3200 | 6234 | #: src/rps/gnunet-rps-profiler.c:3200 |
6247 | msgid "duration of the profiling" | 6235 | msgid "duration of the profiling" |
6248 | msgstr "" | 6236 | msgstr "" |
@@ -6260,6 +6248,18 @@ msgstr "Anzahl an Durchläufen" | |||
6260 | msgid "Measure quality and performance of the RPS service." | 6248 | msgid "Measure quality and performance of the RPS service." |
6261 | msgstr "" | 6249 | msgstr "" |
6262 | 6250 | ||
6251 | #: src/rps/gnunet-rps.c:270 | ||
6252 | msgid "Seed a PeerID" | ||
6253 | msgstr "" | ||
6254 | |||
6255 | #: src/rps/gnunet-rps.c:275 | ||
6256 | msgid "Get updates of view (0 for infinite updates)" | ||
6257 | msgstr "" | ||
6258 | |||
6259 | #: src/rps/gnunet-rps.c:279 | ||
6260 | msgid "Get peers from biased stream" | ||
6261 | msgstr "" | ||
6262 | |||
6263 | #: src/scalarproduct/gnunet-scalarproduct.c:229 | 6263 | #: src/scalarproduct/gnunet-scalarproduct.c:229 |
6264 | #, fuzzy | 6264 | #, fuzzy |
6265 | msgid "You must specify at least one message ID to check!\n" | 6265 | msgid "You must specify at least one message ID to check!\n" |
@@ -6315,10 +6315,10 @@ msgstr "" | |||
6315 | msgid "Calculate the Vectorproduct with a GNUnet peer." | 6315 | msgid "Calculate the Vectorproduct with a GNUnet peer." |
6316 | msgstr "" | 6316 | msgstr "" |
6317 | 6317 | ||
6318 | #: src/scalarproduct/gnunet-service-scalarproduct_alice.c:1358 | ||
6319 | #: src/scalarproduct/gnunet-service-scalarproduct_bob.c:1355 | ||
6320 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_alice.c:1118 | 6318 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_alice.c:1118 |
6321 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c:1063 | 6319 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c:1063 |
6320 | #: src/scalarproduct/gnunet-service-scalarproduct_alice.c:1358 | ||
6321 | #: src/scalarproduct/gnunet-service-scalarproduct_bob.c:1355 | ||
6322 | #, fuzzy | 6322 | #, fuzzy |
6323 | msgid "Connect to CADET failed\n" | 6323 | msgid "Connect to CADET failed\n" |
6324 | msgstr " Verbindung fehlgeschlagen\n" | 6324 | msgstr " Verbindung fehlgeschlagen\n" |
@@ -6673,6 +6673,17 @@ msgstr "" | |||
6673 | msgid "%.s Unknown result code." | 6673 | msgid "%.s Unknown result code." |
6674 | msgstr "" | 6674 | msgstr "" |
6675 | 6675 | ||
6676 | #: src/testbed/gnunet-testbed-profiler.c:290 | ||
6677 | msgid "tolerate COUNT number of continious timeout failures" | ||
6678 | msgstr "" | ||
6679 | |||
6680 | #: src/testbed/gnunet-testbed-profiler.c:295 | ||
6681 | msgid "" | ||
6682 | "run profiler in non-interactive mode where upon testbed setup the profiler " | ||
6683 | "does not wait for a keystroke but continues to run until a termination " | ||
6684 | "signal is received" | ||
6685 | msgstr "" | ||
6686 | |||
6676 | #: src/testbed/gnunet_testbed_mpi_spawn.c:119 | 6687 | #: src/testbed/gnunet_testbed_mpi_spawn.c:119 |
6677 | #, fuzzy | 6688 | #, fuzzy |
6678 | msgid "Waiting for child to exit.\n" | 6689 | msgid "Waiting for child to exit.\n" |
@@ -6685,17 +6696,6 @@ msgstr "" | |||
6685 | msgid "Spawning process `%s'\n" | 6696 | msgid "Spawning process `%s'\n" |
6686 | msgstr "Ungültige Antwort auf `%s'.\n" | 6697 | msgstr "Ungültige Antwort auf `%s'.\n" |
6687 | 6698 | ||
6688 | #: src/testbed/gnunet-testbed-profiler.c:290 | ||
6689 | msgid "tolerate COUNT number of continious timeout failures" | ||
6690 | msgstr "" | ||
6691 | |||
6692 | #: src/testbed/gnunet-testbed-profiler.c:295 | ||
6693 | msgid "" | ||
6694 | "run profiler in non-interactive mode where upon testbed setup the profiler " | ||
6695 | "does not wait for a keystroke but continues to run until a termination " | ||
6696 | "signal is received" | ||
6697 | msgstr "" | ||
6698 | |||
6699 | #: src/testbed/testbed_api.c:399 | 6699 | #: src/testbed/testbed_api.c:399 |
6700 | #, fuzzy, c-format | 6700 | #, fuzzy, c-format |
6701 | msgid "Adding host %u failed with error: %s\n" | 6701 | msgid "Adding host %u failed with error: %s\n" |
@@ -6988,18 +6988,18 @@ msgstr "# HELLO-Meldungen empfangen" | |||
6988 | msgid "GNUnet topology control" | 6988 | msgid "GNUnet topology control" |
6989 | msgstr "" | 6989 | msgstr "" |
6990 | 6990 | ||
6991 | #: src/transport/gnunet-communicator-tcp.c:3189 | 6991 | #: src/transport/gnunet-communicator-tcp.c:3221 |
6992 | #: src/transport/gnunet-communicator-udp.c:2826 | 6992 | #: src/transport/gnunet-communicator-udp.c:2995 |
6993 | #: src/transport/gnunet-service-tng.c:10014 | 6993 | #: src/transport/gnunet-service-tng.c:10014 |
6994 | #: src/transport/gnunet-service-transport.c:2624 | 6994 | #: src/transport/gnunet-service-transport.c:2626 |
6995 | msgid "Transport service is lacking key configuration settings. Exiting.\n" | 6995 | msgid "Transport service is lacking key configuration settings. Exiting.\n" |
6996 | msgstr "" | 6996 | msgstr "" |
6997 | 6997 | ||
6998 | #: src/transport/gnunet-communicator-tcp.c:3494 | 6998 | #: src/transport/gnunet-communicator-tcp.c:3553 |
6999 | msgid "GNUnet TCP communicator" | 6999 | msgid "GNUnet TCP communicator" |
7000 | msgstr "" | 7000 | msgstr "" |
7001 | 7001 | ||
7002 | #: src/transport/gnunet-communicator-udp.c:2898 | 7002 | #: src/transport/gnunet-communicator-udp.c:3067 |
7003 | msgid "GNUnet UDP communicator" | 7003 | msgid "GNUnet UDP communicator" |
7004 | msgstr "" | 7004 | msgstr "" |
7005 | 7005 | ||
@@ -7024,50 +7024,50 @@ msgstr "Pfad zu »%s« kann nicht erstellt werden\n" | |||
7024 | msgid "GNUnet UNIX domain socket communicator" | 7024 | msgid "GNUnet UNIX domain socket communicator" |
7025 | msgstr "" | 7025 | msgstr "" |
7026 | 7026 | ||
7027 | #: src/transport/gnunet-service-transport_ats.c:137 | ||
7028 | msgid "# Addresses given to ATS" | ||
7029 | msgstr "" | ||
7030 | |||
7031 | #: src/transport/gnunet-service-transport.c:445 | 7027 | #: src/transport/gnunet-service-transport.c:445 |
7032 | msgid "# messages dropped due to slow client" | 7028 | msgid "# messages dropped due to slow client" |
7033 | msgstr "" | 7029 | msgstr "" |
7034 | 7030 | ||
7035 | #: src/transport/gnunet-service-transport.c:794 | 7031 | #: src/transport/gnunet-service-transport.c:796 |
7036 | msgid "# bytes payload dropped (other peer was not connected)" | 7032 | msgid "# bytes payload dropped (other peer was not connected)" |
7037 | msgstr "" | 7033 | msgstr "" |
7038 | 7034 | ||
7039 | #: src/transport/gnunet-service-transport.c:1477 | 7035 | #: src/transport/gnunet-service-transport.c:1479 |
7040 | msgid "# bytes payload discarded due to not connected peer" | 7036 | msgid "# bytes payload discarded due to not connected peer" |
7041 | msgstr "" | 7037 | msgstr "" |
7042 | 7038 | ||
7043 | #: src/transport/gnunet-service-transport.c:1622 | 7039 | #: src/transport/gnunet-service-transport.c:1624 |
7044 | msgid "# bytes total received" | 7040 | msgid "# bytes total received" |
7045 | msgstr "# Bytes insgesamt empfangen" | 7041 | msgstr "# Bytes insgesamt empfangen" |
7046 | 7042 | ||
7047 | #: src/transport/gnunet-service-transport.c:1712 | 7043 | #: src/transport/gnunet-service-transport.c:1714 |
7048 | msgid "# bytes payload received" | 7044 | msgid "# bytes payload received" |
7049 | msgstr "# Bytes Nutzdaten empfangen" | 7045 | msgstr "# Bytes Nutzdaten empfangen" |
7050 | 7046 | ||
7051 | #: src/transport/gnunet-service-transport.c:2016 | 7047 | #: src/transport/gnunet-service-transport.c:2018 |
7052 | #: src/transport/gnunet-service-transport.c:2450 | 7048 | #: src/transport/gnunet-service-transport.c:2452 |
7053 | msgid "# disconnects due to blacklist" | 7049 | msgid "# disconnects due to blacklist" |
7054 | msgstr "" | 7050 | msgstr "" |
7055 | 7051 | ||
7056 | #: src/transport/gnunet-service-transport.c:2454 | 7052 | #: src/transport/gnunet-service-transport.c:2456 |
7057 | #, fuzzy, c-format | 7053 | #, fuzzy, c-format |
7058 | msgid "Disallowing connection to peer `%s' on transport %s\n" | 7054 | msgid "Disallowing connection to peer `%s' on transport %s\n" |
7059 | msgstr "Anwendung `%s' konnte nicht initialisiert werden.\n" | 7055 | msgstr "Anwendung `%s' konnte nicht initialisiert werden.\n" |
7060 | 7056 | ||
7061 | #: src/transport/gnunet-service-transport.c:2549 | 7057 | #: src/transport/gnunet-service-transport.c:2551 |
7062 | #, c-format | 7058 | #, c-format |
7063 | msgid "Adding blacklisting entry for peer `%s'\n" | 7059 | msgid "Adding blacklisting entry for peer `%s'\n" |
7064 | msgstr "" | 7060 | msgstr "" |
7065 | 7061 | ||
7066 | #: src/transport/gnunet-service-transport.c:2558 | 7062 | #: src/transport/gnunet-service-transport.c:2560 |
7067 | #, c-format | 7063 | #, c-format |
7068 | msgid "Adding blacklisting entry for peer `%s':`%s'\n" | 7064 | msgid "Adding blacklisting entry for peer `%s':`%s'\n" |
7069 | msgstr "" | 7065 | msgstr "" |
7070 | 7066 | ||
7067 | #: src/transport/gnunet-service-transport_ats.c:137 | ||
7068 | msgid "# Addresses given to ATS" | ||
7069 | msgstr "" | ||
7070 | |||
7071 | #: src/transport/gnunet-service-transport_hello.c:195 | 7071 | #: src/transport/gnunet-service-transport_hello.c:195 |
7072 | msgid "# refreshed my HELLO" | 7072 | msgid "# refreshed my HELLO" |
7073 | msgstr "" | 7073 | msgstr "" |
@@ -7393,6 +7393,43 @@ msgstr "" | |||
7393 | msgid "# HELLOs given to peerinfo" | 7393 | msgid "# HELLOs given to peerinfo" |
7394 | msgstr "" | 7394 | msgstr "" |
7395 | 7395 | ||
7396 | #: src/transport/gnunet-transport-profiler.c:220 | ||
7397 | #, c-format | ||
7398 | msgid "%llu B in %llu ms == %.2f KB/s!\n" | ||
7399 | msgstr "" | ||
7400 | |||
7401 | #: src/transport/gnunet-transport-profiler.c:577 | ||
7402 | msgid "send data to peer" | ||
7403 | msgstr "" | ||
7404 | |||
7405 | #: src/transport/gnunet-transport-profiler.c:581 | ||
7406 | #, fuzzy | ||
7407 | msgid "receive data from peer" | ||
7408 | msgstr "# Bytes des Typs %d empfangen" | ||
7409 | |||
7410 | #: src/transport/gnunet-transport-profiler.c:586 | ||
7411 | msgid "iterations" | ||
7412 | msgstr "" | ||
7413 | |||
7414 | #: src/transport/gnunet-transport-profiler.c:591 | ||
7415 | #, fuzzy | ||
7416 | msgid "number of messages to send" | ||
7417 | msgstr "Anzahl an Durchläufen" | ||
7418 | |||
7419 | #: src/transport/gnunet-transport-profiler.c:596 | ||
7420 | msgid "message size to use" | ||
7421 | msgstr "" | ||
7422 | |||
7423 | #: src/transport/gnunet-transport-profiler.c:601 | ||
7424 | #: src/transport/gnunet-transport.c:1404 | ||
7425 | msgid "peer identity" | ||
7426 | msgstr "" | ||
7427 | |||
7428 | #: src/transport/gnunet-transport-profiler.c:614 | ||
7429 | #: src/transport/gnunet-transport.c:1426 | ||
7430 | msgid "Direct access to transport service." | ||
7431 | msgstr "Direkter Zugriff auf den Transportdienst" | ||
7432 | |||
7396 | #: src/transport/gnunet-transport.c:406 | 7433 | #: src/transport/gnunet-transport.c:406 |
7397 | #, c-format | 7434 | #, c-format |
7398 | msgid "Transmitted %llu bytes/s (%llu bytes in %s)\n" | 7435 | msgid "Transmitted %llu bytes/s (%llu bytes in %s)\n" |
@@ -7525,11 +7562,6 @@ msgstr "" | |||
7525 | msgid "do not resolve hostnames" | 7562 | msgid "do not resolve hostnames" |
7526 | msgstr "Keine Rechnernamen auflösen" | 7563 | msgstr "Keine Rechnernamen auflösen" |
7527 | 7564 | ||
7528 | #: src/transport/gnunet-transport.c:1404 | ||
7529 | #: src/transport/gnunet-transport-profiler.c:601 | ||
7530 | msgid "peer identity" | ||
7531 | msgstr "" | ||
7532 | |||
7533 | #: src/transport/gnunet-transport.c:1408 | 7565 | #: src/transport/gnunet-transport.c:1408 |
7534 | msgid "monitor plugin sessions" | 7566 | msgid "monitor plugin sessions" |
7535 | msgstr "" | 7567 | msgstr "" |
@@ -7538,38 +7570,6 @@ msgstr "" | |||
7538 | msgid "send data for benchmarking to the other peer (until CTRL-C)" | 7570 | msgid "send data for benchmarking to the other peer (until CTRL-C)" |
7539 | msgstr "" | 7571 | msgstr "" |
7540 | 7572 | ||
7541 | #: src/transport/gnunet-transport.c:1426 | ||
7542 | #: src/transport/gnunet-transport-profiler.c:614 | ||
7543 | msgid "Direct access to transport service." | ||
7544 | msgstr "Direkter Zugriff auf den Transportdienst" | ||
7545 | |||
7546 | #: src/transport/gnunet-transport-profiler.c:220 | ||
7547 | #, c-format | ||
7548 | msgid "%llu B in %llu ms == %.2f KB/s!\n" | ||
7549 | msgstr "" | ||
7550 | |||
7551 | #: src/transport/gnunet-transport-profiler.c:577 | ||
7552 | msgid "send data to peer" | ||
7553 | msgstr "" | ||
7554 | |||
7555 | #: src/transport/gnunet-transport-profiler.c:581 | ||
7556 | #, fuzzy | ||
7557 | msgid "receive data from peer" | ||
7558 | msgstr "# Bytes des Typs %d empfangen" | ||
7559 | |||
7560 | #: src/transport/gnunet-transport-profiler.c:586 | ||
7561 | msgid "iterations" | ||
7562 | msgstr "" | ||
7563 | |||
7564 | #: src/transport/gnunet-transport-profiler.c:591 | ||
7565 | #, fuzzy | ||
7566 | msgid "number of messages to send" | ||
7567 | msgstr "Anzahl an Durchläufen" | ||
7568 | |||
7569 | #: src/transport/gnunet-transport-profiler.c:596 | ||
7570 | msgid "message size to use" | ||
7571 | msgstr "" | ||
7572 | |||
7573 | #: src/transport/plugin_transport_http_client.c:1489 | 7573 | #: src/transport/plugin_transport_http_client.c:1489 |
7574 | #: src/transport/plugin_transport_http_server.c:2331 | 7574 | #: src/transport/plugin_transport_http_server.c:2331 |
7575 | #: src/transport/plugin_transport_http_server.c:3562 | 7575 | #: src/transport/plugin_transport_http_server.c:3562 |
@@ -7842,21 +7842,6 @@ msgstr "" | |||
7842 | msgid "TCP transport advertises itself as being on port %llu\n" | 7842 | msgid "TCP transport advertises itself as being on port %llu\n" |
7843 | msgstr "" | 7843 | msgstr "" |
7844 | 7844 | ||
7845 | #: src/transport/plugin_transport_udp_broadcasting.c:169 | ||
7846 | #, fuzzy | ||
7847 | msgid "# Multicast HELLO beacons received via UDP" | ||
7848 | msgstr "# Bytes empfangen über TCP" | ||
7849 | |||
7850 | #: src/transport/plugin_transport_udp_broadcasting.c:553 | ||
7851 | msgid "" | ||
7852 | "Disabling HELLO broadcasting due to friend-to-friend only configuration!\n" | ||
7853 | msgstr "" | ||
7854 | |||
7855 | #: src/transport/plugin_transport_udp_broadcasting.c:571 | ||
7856 | #, fuzzy, c-format | ||
7857 | msgid "Failed to set IPv4 broadcast option for broadcast socket on port %d\n" | ||
7858 | msgstr "Der Transportdienst auf Port %d konnte nicht gestartet werden.\n" | ||
7859 | |||
7860 | #: src/transport/plugin_transport_udp.c:3169 | 7845 | #: src/transport/plugin_transport_udp.c:3169 |
7861 | #, c-format | 7846 | #, c-format |
7862 | msgid "" | 7847 | msgid "" |
@@ -7904,6 +7889,21 @@ msgstr "»%s« ist keine gültige IP-Adresse.\n" | |||
7904 | msgid "Failed to create UDP network sockets\n" | 7889 | msgid "Failed to create UDP network sockets\n" |
7905 | msgstr "UDP-Sockets können nicht geöffnet werden\n" | 7890 | msgstr "UDP-Sockets können nicht geöffnet werden\n" |
7906 | 7891 | ||
7892 | #: src/transport/plugin_transport_udp_broadcasting.c:169 | ||
7893 | #, fuzzy | ||
7894 | msgid "# Multicast HELLO beacons received via UDP" | ||
7895 | msgstr "# Bytes empfangen über TCP" | ||
7896 | |||
7897 | #: src/transport/plugin_transport_udp_broadcasting.c:553 | ||
7898 | msgid "" | ||
7899 | "Disabling HELLO broadcasting due to friend-to-friend only configuration!\n" | ||
7900 | msgstr "" | ||
7901 | |||
7902 | #: src/transport/plugin_transport_udp_broadcasting.c:571 | ||
7903 | #, fuzzy, c-format | ||
7904 | msgid "Failed to set IPv4 broadcast option for broadcast socket on port %d\n" | ||
7905 | msgstr "Der Transportdienst auf Port %d konnte nicht gestartet werden.\n" | ||
7906 | |||
7907 | #: src/transport/plugin_transport_unix.c:1396 | 7907 | #: src/transport/plugin_transport_unix.c:1396 |
7908 | #, fuzzy, c-format | 7908 | #, fuzzy, c-format |
7909 | msgid "Cannot bind to `%s'\n" | 7909 | msgid "Cannot bind to `%s'\n" |
@@ -8085,7 +8085,7 @@ msgid "do daemonize (detach from terminal)" | |||
8085 | msgstr "" | 8085 | msgstr "" |
8086 | 8086 | ||
8087 | #: src/transport/tcp_service_legacy.c:1397 | 8087 | #: src/transport/tcp_service_legacy.c:1397 |
8088 | #: src/transport/transport-testing2.c:1116 src/util/service.c:2072 | 8088 | #: src/transport/transport-testing2.c:983 src/util/service.c:2072 |
8089 | #: src/util/service.c:2084 | 8089 | #: src/util/service.c:2084 |
8090 | #, fuzzy, c-format | 8090 | #, fuzzy, c-format |
8091 | msgid "Malformed configuration file `%s', exit ...\n" | 8091 | msgid "Malformed configuration file `%s', exit ...\n" |
@@ -8757,19 +8757,19 @@ msgid "" | |||
8757 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" | 8757 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" |
8758 | msgstr "" | 8758 | msgstr "" |
8759 | 8759 | ||
8760 | #: src/util/os_installation.c:409 | 8760 | #: src/util/os_installation.c:411 |
8761 | #, c-format | 8761 | #, c-format |
8762 | msgid "" | 8762 | msgid "" |
8763 | "Could not determine installation path for %s. Set `%s' environment " | 8763 | "Could not determine installation path for %s. Set `%s' environment " |
8764 | "variable.\n" | 8764 | "variable.\n" |
8765 | msgstr "" | 8765 | msgstr "" |
8766 | 8766 | ||
8767 | #: src/util/os_installation.c:792 | 8767 | #: src/util/os_installation.c:794 |
8768 | #, fuzzy, c-format | 8768 | #, fuzzy, c-format |
8769 | msgid "Could not find binary `%s' in PATH!\n" | 8769 | msgid "Could not find binary `%s' in PATH!\n" |
8770 | msgstr "Knoten `%s' konnte nicht in der Routing Tabelle gefunden werden!\n" | 8770 | msgstr "Knoten `%s' konnte nicht in der Routing Tabelle gefunden werden!\n" |
8771 | 8771 | ||
8772 | #: src/util/os_installation.c:825 | 8772 | #: src/util/os_installation.c:827 |
8773 | #, c-format | 8773 | #, c-format |
8774 | msgid "Binary `%s' exists, but is not SUID\n" | 8774 | msgid "Binary `%s' exists, but is not SUID\n" |
8775 | msgstr "" | 8775 | msgstr "" |
@@ -8795,17 +8795,17 @@ msgstr "`%s' fehlgeschlagen für die Bibliothek `%s'. Ort: %s:%d. Fehler: %s\n" | |||
8795 | msgid "Could not determine plugin installation path.\n" | 8795 | msgid "Could not determine plugin installation path.\n" |
8796 | msgstr "Öffentliche IP-Adresse konnte nicht ermittelt werden.\n" | 8796 | msgstr "Öffentliche IP-Adresse konnte nicht ermittelt werden.\n" |
8797 | 8797 | ||
8798 | #: src/util/program.c:262 | 8798 | #: src/util/program.c:267 |
8799 | #, fuzzy, c-format | 8799 | #, fuzzy, c-format |
8800 | msgid "Unreadable or malformed configuration file `%s', exit ...\n" | 8800 | msgid "Unreadable or malformed configuration file `%s', exit ...\n" |
8801 | msgstr "Konfigurationsdatei `%s' wurde erzeugt.\n" | 8801 | msgstr "Konfigurationsdatei `%s' wurde erzeugt.\n" |
8802 | 8802 | ||
8803 | #: src/util/program.c:279 | 8803 | #: src/util/program.c:284 |
8804 | #, fuzzy, c-format | 8804 | #, fuzzy, c-format |
8805 | msgid "Unreadable or malformed default configuration file `%s', exit ...\n" | 8805 | msgid "Unreadable or malformed default configuration file `%s', exit ...\n" |
8806 | msgstr "Konfigurationsdatei `%s' wurde erzeugt.\n" | 8806 | msgstr "Konfigurationsdatei `%s' wurde erzeugt.\n" |
8807 | 8807 | ||
8808 | #: src/util/program.c:294 | 8808 | #: src/util/program.c:299 |
8809 | #, fuzzy | 8809 | #, fuzzy |
8810 | msgid "Unreadable or malformed configuration, exit ...\n" | 8810 | msgid "Unreadable or malformed configuration, exit ...\n" |
8811 | msgstr "GNUnet Konfiguration" | 8811 | msgstr "GNUnet Konfiguration" |
@@ -8873,10 +8873,6 @@ msgstr "" | |||
8873 | msgid "Attempting to proxy service `%s' to invalid port %d or hostname.\n" | 8873 | msgid "Attempting to proxy service `%s' to invalid port %d or hostname.\n" |
8874 | msgstr "" | 8874 | msgstr "" |
8875 | 8875 | ||
8876 | #: src/util/strings.c:179 | ||
8877 | msgid "b" | ||
8878 | msgstr "b" | ||
8879 | |||
8880 | #: src/util/strings.c:503 | 8876 | #: src/util/strings.c:503 |
8881 | #, c-format | 8877 | #, c-format |
8882 | msgid "Character sets requested were `%s'->`%s'\n" | 8878 | msgid "Character sets requested were `%s'->`%s'\n" |
@@ -8886,46 +8882,6 @@ msgstr "" | |||
8886 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" | 8882 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" |
8887 | msgstr "" | 8883 | msgstr "" |
8888 | 8884 | ||
8889 | #: src/util/strings.c:706 | ||
8890 | msgid "µs" | ||
8891 | msgstr "µs" | ||
8892 | |||
8893 | #: src/util/strings.c:710 | ||
8894 | msgid "forever" | ||
8895 | msgstr "" | ||
8896 | |||
8897 | #: src/util/strings.c:712 | ||
8898 | msgid "0 ms" | ||
8899 | msgstr "0 ms" | ||
8900 | |||
8901 | #: src/util/strings.c:716 | ||
8902 | msgid "ms" | ||
8903 | msgstr "ms" | ||
8904 | |||
8905 | #: src/util/strings.c:720 | ||
8906 | msgid "s" | ||
8907 | msgstr "s" | ||
8908 | |||
8909 | #: src/util/strings.c:724 | ||
8910 | msgid "m" | ||
8911 | msgstr "m" | ||
8912 | |||
8913 | #: src/util/strings.c:728 | ||
8914 | msgid "h" | ||
8915 | msgstr "h" | ||
8916 | |||
8917 | #: src/util/strings.c:734 | ||
8918 | msgid "day" | ||
8919 | msgstr "Tag" | ||
8920 | |||
8921 | #: src/util/strings.c:736 | ||
8922 | msgid "days" | ||
8923 | msgstr "Tage" | ||
8924 | |||
8925 | #: src/util/strings.c:764 | ||
8926 | msgid "end of time" | ||
8927 | msgstr "" | ||
8928 | |||
8929 | #: src/util/strings.c:1240 | 8885 | #: src/util/strings.c:1240 |
8930 | msgid "IPv6 address did not start with `['\n" | 8886 | msgid "IPv6 address did not start with `['\n" |
8931 | msgstr "IPv6-Adresse beginnt nicht mit »[«\n" | 8887 | msgstr "IPv6-Adresse beginnt nicht mit »[«\n" |
@@ -9172,12 +9128,39 @@ msgstr "Dienst wird über UDP angeboten" | |||
9172 | msgid "Setup tunnels via VPN." | 9128 | msgid "Setup tunnels via VPN." |
9173 | msgstr "Tunnel über VPN einrichten." | 9129 | msgstr "Tunnel über VPN einrichten." |
9174 | 9130 | ||
9175 | #: src/zonemaster/gnunet-service-zonemaster.c:849 | ||
9176 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:420 | 9131 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:420 |
9132 | #: src/zonemaster/gnunet-service-zonemaster.c:849 | ||
9177 | #, fuzzy | 9133 | #, fuzzy |
9178 | msgid "Failed to connect to the namestore!\n" | 9134 | msgid "Failed to connect to the namestore!\n" |
9179 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" | 9135 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" |
9180 | 9136 | ||
9137 | #~ msgid "b" | ||
9138 | #~ msgstr "b" | ||
9139 | |||
9140 | #~ msgid "µs" | ||
9141 | #~ msgstr "µs" | ||
9142 | |||
9143 | #~ msgid "0 ms" | ||
9144 | #~ msgstr "0 ms" | ||
9145 | |||
9146 | #~ msgid "ms" | ||
9147 | #~ msgstr "ms" | ||
9148 | |||
9149 | #~ msgid "s" | ||
9150 | #~ msgstr "s" | ||
9151 | |||
9152 | #~ msgid "m" | ||
9153 | #~ msgstr "m" | ||
9154 | |||
9155 | #~ msgid "h" | ||
9156 | #~ msgstr "h" | ||
9157 | |||
9158 | #~ msgid "day" | ||
9159 | #~ msgstr "Tag" | ||
9160 | |||
9161 | #~ msgid "days" | ||
9162 | #~ msgstr "Tage" | ||
9163 | |||
9181 | #, fuzzy, c-format | 9164 | #, fuzzy, c-format |
9182 | #~ msgid "Could not acquire lock on file `%s': %s...\n" | 9165 | #~ msgid "Could not acquire lock on file `%s': %s...\n" |
9183 | #~ msgstr "PID konnte nicht in Datei `%s' geschrieben werden: %s.\n" | 9166 | #~ msgstr "PID konnte nicht in Datei `%s' geschrieben werden: %s.\n" |
@@ -8,7 +8,7 @@ msgid "" | |||
8 | msgstr "" | 8 | msgstr "" |
9 | "Project-Id-Version: gnunet 0.9.5a\n" | 9 | "Project-Id-Version: gnunet 0.9.5a\n" |
10 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" | 10 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" |
11 | "POT-Creation-Date: 2020-09-06 10:07+0200\n" | 11 | "POT-Creation-Date: 2020-10-13 16:12+0200\n" |
12 | "PO-Revision-Date: 2013-02-23 17:50+0100\n" | 12 | "PO-Revision-Date: 2013-02-23 17:50+0100\n" |
13 | "Last-Translator: Miguel Ángel Arruga Vivas <rosen644835@gmail.com>\n" | 13 | "Last-Translator: Miguel Ángel Arruga Vivas <rosen644835@gmail.com>\n" |
14 | "Language-Team: Spanish <es@li.org>\n" | 14 | "Language-Team: Spanish <es@li.org>\n" |
@@ -29,8 +29,8 @@ msgid "Issuer public key `%s' is not well-formed\n" | |||
29 | msgstr "El bloque del tipo %u está mal formado\n" | 29 | msgstr "El bloque del tipo %u está mal formado\n" |
30 | 30 | ||
31 | #: src/abd/gnunet-abd.c:560 src/abd/gnunet-service-abd.c:1747 | 31 | #: src/abd/gnunet-abd.c:560 src/abd/gnunet-service-abd.c:1747 |
32 | #: src/namestore/gnunet-namestore.c:1001 | ||
33 | #: src/namestore/gnunet-namestore-fcfsd.c:1154 | 32 | #: src/namestore/gnunet-namestore-fcfsd.c:1154 |
33 | #: src/namestore/gnunet-namestore.c:1001 | ||
34 | #, c-format | 34 | #, c-format |
35 | msgid "Failed to connect to namestore\n" | 35 | msgid "Failed to connect to namestore\n" |
36 | msgstr "Se produjo un fallo al conectar con el almacén de nombres\n" | 36 | msgstr "Se produjo un fallo al conectar con el almacén de nombres\n" |
@@ -525,94 +525,14 @@ msgstr "El servicio «%s» finalizó con estado %s/%d, se reiniciará en %llu ms | |||
525 | msgid "Initiating shutdown as requested by client.\n" | 525 | msgid "Initiating shutdown as requested by client.\n" |
526 | msgstr "Iniciando apagado bajo petición del cliente.\n" | 526 | msgstr "Iniciando apagado bajo petición del cliente.\n" |
527 | 527 | ||
528 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | 528 | #: src/ats-tests/ats-testing-log.c:896 |
529 | #, c-format | 529 | msgid "Stop logging\n" |
530 | msgid "" | ||
531 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | ||
532 | "%llu\n" | ||
533 | msgstr "" | ||
534 | "No se pudieron cargar las cuotas para la red «%s»: «%s», asignando el ancho " | ||
535 | "de banda predeterminado %llu\n" | ||
536 | |||
537 | #: src/ats/gnunet-ats-solver-eval.c:3011 | ||
538 | #, c-format | ||
539 | msgid "" | ||
540 | "No outbound quota configured for network `%s', assigning default bandwidth " | ||
541 | "%llu\n" | ||
542 | msgstr "" | ||
543 | "No hay configurada una cuota de salida para la red «%s», asignando el ancho " | ||
544 | "de banda predeterminado %llu\n" | ||
545 | |||
546 | #: src/ats/gnunet-ats-solver-eval.c:3063 | ||
547 | #, c-format | ||
548 | msgid "" | ||
549 | "No outbound quota configure for network `%s', assigning default bandwidth " | ||
550 | "%llu\n" | ||
551 | msgstr "" | ||
552 | "No hay configurada una cuota de salida para la red «%s», asignando el ancho " | ||
553 | "de banda predeterminado %llu\n" | ||
554 | |||
555 | #: src/ats/gnunet-ats-solver-eval.c:3552 src/ats-tests/gnunet-solver-eval.c:997 | ||
556 | #, fuzzy | ||
557 | msgid "solver to use" | ||
558 | msgstr "valor a establecer" | ||
559 | |||
560 | #: src/ats/gnunet-ats-solver-eval.c:3557 | ||
561 | #: src/ats-tests/gnunet-solver-eval.c:1003 | ||
562 | #: src/ats-tests/gnunet-solver-eval.c:1008 | ||
563 | msgid "experiment to use" | ||
564 | msgstr "experimento para usar" | ||
565 | |||
566 | #: src/ats/gnunet-ats-solver-eval.c:3564 | ||
567 | #, fuzzy | ||
568 | msgid "print logging" | ||
569 | msgstr "Iniciando descarga «%s».\n" | ||
570 | |||
571 | #: src/ats/gnunet-ats-solver-eval.c:3569 | ||
572 | msgid "save logging to disk" | ||
573 | msgstr "guarda protocolo al fichero en disco" | ||
574 | |||
575 | #: src/ats/gnunet-ats-solver-eval.c:3574 | ||
576 | msgid "disable normalization" | ||
577 | msgstr "deshabilita normalización" | ||
578 | |||
579 | #: src/ats/gnunet-service-ats_plugins.c:326 | ||
580 | #, fuzzy, c-format | ||
581 | msgid "" | ||
582 | "Could not load %s quota for network `%s': `%s', assigning default bandwidth " | ||
583 | "%llu\n" | ||
584 | msgstr "" | ||
585 | "No se pudieron cargar las cuotas para la red «%s»: «%s», asignando el ancho " | ||
586 | "de banda predeterminado %llu\n" | ||
587 | |||
588 | # Miguel: "Inbound" lo he traducido como entrada en todo el texto. | ||
589 | #: src/ats/gnunet-service-ats_plugins.c:336 | ||
590 | #, fuzzy, c-format | ||
591 | msgid "%s quota configured for network `%s' is %llu\n" | ||
592 | msgstr "La cuota de entrada configurada para la red «%s» es %llu\n" | ||
593 | |||
594 | #: src/ats/gnunet-service-ats_plugins.c:382 | ||
595 | #, fuzzy, c-format | ||
596 | msgid "" | ||
597 | "No %s-quota configured for network `%s', assigning default bandwidth %llu\n" | ||
598 | msgstr "" | 530 | msgstr "" |
599 | "No hay configurada una cuota de salida para la red «%s», asignando el ancho " | ||
600 | "de banda predeterminado %llu\n" | ||
601 | |||
602 | #: src/ats/gnunet-service-ats_plugins.c:474 | ||
603 | #, fuzzy, c-format | ||
604 | msgid "Failed to initialize solver `%s'!\n" | ||
605 | msgstr "¡No se puede inicializar el resolvedor!\n" | ||
606 | |||
607 | #: src/ats/plugin_ats_proportional.c:1142 | ||
608 | #, fuzzy, c-format | ||
609 | msgid "Invalid %s configuration %f \n" | ||
610 | msgstr "Se produjo un fallo al cargar la configuración de %s\n" | ||
611 | 531 | ||
612 | #: src/ats/plugin_ats_proportional.c:1165 | 532 | #: src/ats-tests/ats-testing-log.c:952 |
613 | #, fuzzy, c-format | 533 | #, fuzzy, c-format |
614 | msgid "Invalid %s configuration %f\n" | 534 | msgid "Start logging `%s'\n" |
615 | msgstr "Se produjo un fallo al cargar la configuración de %s\n" | 535 | msgstr "Iniciando descarga «%s».\n" |
616 | 536 | ||
617 | #: src/ats-tests/ats-testing.c:420 | 537 | #: src/ats-tests/ats-testing.c:420 |
618 | #, c-format | 538 | #, c-format |
@@ -624,15 +544,6 @@ msgstr "" | |||
624 | msgid "Failed to connect master peer [%u] with slave [%u]\n" | 544 | msgid "Failed to connect master peer [%u] with slave [%u]\n" |
625 | msgstr "Fallo al conectar a gnunetd.\n" | 545 | msgstr "Fallo al conectar a gnunetd.\n" |
626 | 546 | ||
627 | #: src/ats-tests/ats-testing-log.c:896 | ||
628 | msgid "Stop logging\n" | ||
629 | msgstr "" | ||
630 | |||
631 | #: src/ats-tests/ats-testing-log.c:952 | ||
632 | #, fuzzy, c-format | ||
633 | msgid "Start logging `%s'\n" | ||
634 | msgstr "Iniciando descarga «%s».\n" | ||
635 | |||
636 | #: src/ats-tests/gnunet-ats-sim.c:92 | 547 | #: src/ats-tests/gnunet-ats-sim.c:92 |
637 | #, c-format | 548 | #, c-format |
638 | msgid "" | 549 | msgid "" |
@@ -640,6 +551,17 @@ msgid "" | |||
640 | "= %u KiB/s\n" | 551 | "= %u KiB/s\n" |
641 | msgstr "" | 552 | msgstr "" |
642 | 553 | ||
554 | #: src/ats-tests/gnunet-solver-eval.c:997 src/ats/gnunet-ats-solver-eval.c:3552 | ||
555 | #, fuzzy | ||
556 | msgid "solver to use" | ||
557 | msgstr "valor a establecer" | ||
558 | |||
559 | #: src/ats-tests/gnunet-solver-eval.c:1003 | ||
560 | #: src/ats-tests/gnunet-solver-eval.c:1008 | ||
561 | #: src/ats/gnunet-ats-solver-eval.c:3557 | ||
562 | msgid "experiment to use" | ||
563 | msgstr "experimento para usar" | ||
564 | |||
643 | # Miguel: ¿Como podría traducir "resolutions" y "resolve"? | 565 | # Miguel: ¿Como podría traducir "resolutions" y "resolve"? |
644 | # Son difíciles de no calcar, puesto que no conozco como expresar | 566 | # Son difíciles de no calcar, puesto que no conozco como expresar |
645 | # el concepto de obtener una dirección a partir de un nombre | 567 | # el concepto de obtener una dirección a partir de un nombre |
@@ -774,6 +696,84 @@ msgstr "salida prolija (incluye las propiedades de direcciones del ATS)" | |||
774 | msgid "Print information about ATS state" | 696 | msgid "Print information about ATS state" |
775 | msgstr "Imprime información acerca del estado del ATS" | 697 | msgstr "Imprime información acerca del estado del ATS" |
776 | 698 | ||
699 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | ||
700 | #, c-format | ||
701 | msgid "" | ||
702 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | ||
703 | "%llu\n" | ||
704 | msgstr "" | ||
705 | "No se pudieron cargar las cuotas para la red «%s»: «%s», asignando el ancho " | ||
706 | "de banda predeterminado %llu\n" | ||
707 | |||
708 | #: src/ats/gnunet-ats-solver-eval.c:3011 | ||
709 | #, c-format | ||
710 | msgid "" | ||
711 | "No outbound quota configured for network `%s', assigning default bandwidth " | ||
712 | "%llu\n" | ||
713 | msgstr "" | ||
714 | "No hay configurada una cuota de salida para la red «%s», asignando el ancho " | ||
715 | "de banda predeterminado %llu\n" | ||
716 | |||
717 | #: src/ats/gnunet-ats-solver-eval.c:3063 | ||
718 | #, c-format | ||
719 | msgid "" | ||
720 | "No outbound quota configure for network `%s', assigning default bandwidth " | ||
721 | "%llu\n" | ||
722 | msgstr "" | ||
723 | "No hay configurada una cuota de salida para la red «%s», asignando el ancho " | ||
724 | "de banda predeterminado %llu\n" | ||
725 | |||
726 | #: src/ats/gnunet-ats-solver-eval.c:3564 | ||
727 | #, fuzzy | ||
728 | msgid "print logging" | ||
729 | msgstr "Iniciando descarga «%s».\n" | ||
730 | |||
731 | #: src/ats/gnunet-ats-solver-eval.c:3569 | ||
732 | msgid "save logging to disk" | ||
733 | msgstr "guarda protocolo al fichero en disco" | ||
734 | |||
735 | #: src/ats/gnunet-ats-solver-eval.c:3574 | ||
736 | msgid "disable normalization" | ||
737 | msgstr "deshabilita normalización" | ||
738 | |||
739 | #: src/ats/gnunet-service-ats_plugins.c:326 | ||
740 | #, fuzzy, c-format | ||
741 | msgid "" | ||
742 | "Could not load %s quota for network `%s': `%s', assigning default bandwidth " | ||
743 | "%llu\n" | ||
744 | msgstr "" | ||
745 | "No se pudieron cargar las cuotas para la red «%s»: «%s», asignando el ancho " | ||
746 | "de banda predeterminado %llu\n" | ||
747 | |||
748 | # Miguel: "Inbound" lo he traducido como entrada en todo el texto. | ||
749 | #: src/ats/gnunet-service-ats_plugins.c:336 | ||
750 | #, fuzzy, c-format | ||
751 | msgid "%s quota configured for network `%s' is %llu\n" | ||
752 | msgstr "La cuota de entrada configurada para la red «%s» es %llu\n" | ||
753 | |||
754 | #: src/ats/gnunet-service-ats_plugins.c:382 | ||
755 | #, fuzzy, c-format | ||
756 | msgid "" | ||
757 | "No %s-quota configured for network `%s', assigning default bandwidth %llu\n" | ||
758 | msgstr "" | ||
759 | "No hay configurada una cuota de salida para la red «%s», asignando el ancho " | ||
760 | "de banda predeterminado %llu\n" | ||
761 | |||
762 | #: src/ats/gnunet-service-ats_plugins.c:474 | ||
763 | #, fuzzy, c-format | ||
764 | msgid "Failed to initialize solver `%s'!\n" | ||
765 | msgstr "¡No se puede inicializar el resolvedor!\n" | ||
766 | |||
767 | #: src/ats/plugin_ats_proportional.c:1142 | ||
768 | #, fuzzy, c-format | ||
769 | msgid "Invalid %s configuration %f \n" | ||
770 | msgstr "Se produjo un fallo al cargar la configuración de %s\n" | ||
771 | |||
772 | #: src/ats/plugin_ats_proportional.c:1165 | ||
773 | #, fuzzy, c-format | ||
774 | msgid "Invalid %s configuration %f\n" | ||
775 | msgstr "Se produjo un fallo al cargar la configuración de %s\n" | ||
776 | |||
777 | #: src/auction/gnunet-auction-create.c:163 | 777 | #: src/auction/gnunet-auction-create.c:163 |
778 | msgid "description of the item to be sold" | 778 | msgid "description of the item to be sold" |
779 | msgstr "descripción del elemento que está por vender" | 779 | msgstr "descripción del elemento que está por vender" |
@@ -916,6 +916,28 @@ msgid "Connection to conversation service lost, trying to reconnect\n" | |||
916 | msgstr "" | 916 | msgstr "" |
917 | "El cliente se desconectó del servicio principal, tratando de reconectar.\n" | 917 | "El cliente se desconectó del servicio principal, tratando de reconectar.\n" |
918 | 918 | ||
919 | #: src/conversation/gnunet-conversation-test.c:120 | ||
920 | #, c-format | ||
921 | msgid "" | ||
922 | "\n" | ||
923 | "End of transmission. Have a GNU day.\n" | ||
924 | msgstr "" | ||
925 | |||
926 | #: src/conversation/gnunet-conversation-test.c:146 | ||
927 | #, c-format | ||
928 | msgid "" | ||
929 | "\n" | ||
930 | "We are now playing your recording back. If you can hear it, your audio " | ||
931 | "settings are working..." | ||
932 | msgstr "" | ||
933 | |||
934 | #: src/conversation/gnunet-conversation-test.c:218 | ||
935 | #, c-format | ||
936 | msgid "" | ||
937 | "We will now be recording you for %s. After that time, the recording will be " | ||
938 | "played back to you..." | ||
939 | msgstr "" | ||
940 | |||
919 | #: src/conversation/gnunet-conversation.c:264 | 941 | #: src/conversation/gnunet-conversation.c:264 |
920 | #, c-format | 942 | #, c-format |
921 | msgid "Incoming call from `%s'. Please /accept %u or /cancel %u the call.\n" | 943 | msgid "Incoming call from `%s'. Please /accept %u or /cancel %u the call.\n" |
@@ -1176,30 +1198,8 @@ msgstr "" | |||
1176 | msgid "Enables having a conversation with other GNUnet users." | 1198 | msgid "Enables having a conversation with other GNUnet users." |
1177 | msgstr "" | 1199 | msgstr "" |
1178 | 1200 | ||
1179 | #: src/conversation/gnunet-conversation-test.c:120 | ||
1180 | #, c-format | ||
1181 | msgid "" | ||
1182 | "\n" | ||
1183 | "End of transmission. Have a GNU day.\n" | ||
1184 | msgstr "" | ||
1185 | |||
1186 | #: src/conversation/gnunet-conversation-test.c:146 | ||
1187 | #, c-format | ||
1188 | msgid "" | ||
1189 | "\n" | ||
1190 | "We are now playing your recording back. If you can hear it, your audio " | ||
1191 | "settings are working..." | ||
1192 | msgstr "" | ||
1193 | |||
1194 | #: src/conversation/gnunet-conversation-test.c:218 | ||
1195 | #, c-format | ||
1196 | msgid "" | ||
1197 | "We will now be recording you for %s. After that time, the recording will be " | ||
1198 | "played back to you..." | ||
1199 | msgstr "" | ||
1200 | |||
1201 | #: src/conversation/gnunet_gst.c:664 | ||
1202 | #: src/conversation/gnunet-helper-audio-playback-gst.c:363 | 1201 | #: src/conversation/gnunet-helper-audio-playback-gst.c:363 |
1202 | #: src/conversation/gnunet_gst.c:664 | ||
1203 | #, c-format | 1203 | #, c-format |
1204 | msgid "Read error from STDIN: %d %s\n" | 1204 | msgid "Read error from STDIN: %d %s\n" |
1205 | msgstr "" | 1205 | msgstr "" |
@@ -2019,16 +2019,16 @@ msgstr "«%s» para «%s» falló en %s: %d con error: %s\n" | |||
2019 | msgid "Mysql database running\n" | 2019 | msgid "Mysql database running\n" |
2020 | msgstr "Base de datos Mysql ejecutándose\n" | 2020 | msgstr "Base de datos Mysql ejecutándose\n" |
2021 | 2021 | ||
2022 | #: src/datastore/plugin_datastore_postgres.c:278 | 2022 | #: src/datastore/plugin_datastore_postgres.c:284 |
2023 | #: src/datastore/plugin_datastore_postgres.c:891 | 2023 | #: src/datastore/plugin_datastore_postgres.c:897 |
2024 | msgid "Postgress exec failure" | 2024 | msgid "Postgress exec failure" |
2025 | msgstr "" | 2025 | msgstr "" |
2026 | 2026 | ||
2027 | #: src/datastore/plugin_datastore_postgres.c:852 | 2027 | #: src/datastore/plugin_datastore_postgres.c:858 |
2028 | msgid "Failed to drop table from database.\n" | 2028 | msgid "Failed to drop table from database.\n" |
2029 | msgstr "Se produjo un fallo al borrar una tabla de la base de datos.\n" | 2029 | msgstr "Se produjo un fallo al borrar una tabla de la base de datos.\n" |
2030 | 2030 | ||
2031 | #: src/datastore/plugin_datastore_postgres.c:950 | 2031 | #: src/datastore/plugin_datastore_postgres.c:956 |
2032 | msgid "Postgres database running\n" | 2032 | msgid "Postgres database running\n" |
2033 | msgstr "Base de datos Postgres ejecutándose\n" | 2033 | msgstr "Base de datos Postgres ejecutándose\n" |
2034 | 2034 | ||
@@ -2146,55 +2146,6 @@ msgstr "ser prolijo (imprime información de progreso)" | |||
2146 | msgid "Prints all packets that go through the DHT." | 2146 | msgid "Prints all packets that go through the DHT." |
2147 | msgstr "Imprime todos los paquetes que pasan por la DHT." | 2147 | msgstr "Imprime todos los paquetes que pasan por la DHT." |
2148 | 2148 | ||
2149 | #: src/dht/gnunet_dht_profiler.c:922 src/testbed/gnunet-testbed-profiler.c:255 | ||
2150 | #, fuzzy, c-format | ||
2151 | msgid "Exiting as the number of peers is %u\n" | ||
2152 | msgstr "El número máximo de conexiones es %u\n" | ||
2153 | |||
2154 | #: src/dht/gnunet_dht_profiler.c:955 src/rps/gnunet-rps-profiler.c:3194 | ||
2155 | msgid "number of peers to start" | ||
2156 | msgstr "número de pares para empezar" | ||
2157 | |||
2158 | #: src/dht/gnunet_dht_profiler.c:961 | ||
2159 | msgid "number of PUTs to perform per peer" | ||
2160 | msgstr "" | ||
2161 | |||
2162 | #: src/dht/gnunet_dht_profiler.c:967 src/nse/gnunet-nse-profiler.c:872 | ||
2163 | #: src/testbed/gnunet-testbed-profiler.c:305 | ||
2164 | msgid "name of the file with the login information for the testbed" | ||
2165 | msgstr "" | ||
2166 | "nombre del fichero con la información de acceso usada para la batería de " | ||
2167 | "pruebas" | ||
2168 | |||
2169 | #: src/dht/gnunet_dht_profiler.c:973 | ||
2170 | msgid "delay between rounds for collecting statistics (default: 30 sec)" | ||
2171 | msgstr "" | ||
2172 | |||
2173 | #: src/dht/gnunet_dht_profiler.c:979 | ||
2174 | msgid "delay to start doing PUTs (default: 1 sec)" | ||
2175 | msgstr "" | ||
2176 | |||
2177 | #: src/dht/gnunet_dht_profiler.c:985 | ||
2178 | msgid "delay to start doing GETs (default: 5 min)" | ||
2179 | msgstr "" | ||
2180 | |||
2181 | #: src/dht/gnunet_dht_profiler.c:990 | ||
2182 | msgid "replication degree for DHT PUTs" | ||
2183 | msgstr "" | ||
2184 | |||
2185 | #: src/dht/gnunet_dht_profiler.c:996 | ||
2186 | msgid "chance that a peer is selected at random for PUTs" | ||
2187 | msgstr "" | ||
2188 | |||
2189 | #: src/dht/gnunet_dht_profiler.c:1002 | ||
2190 | msgid "timeout for DHT PUT and GET requests (default: 1 min)" | ||
2191 | msgstr "" | ||
2192 | |||
2193 | #: src/dht/gnunet_dht_profiler.c:1023 | ||
2194 | #, fuzzy | ||
2195 | msgid "Measure quality and performance of the DHT service." | ||
2196 | msgstr "Medir la calidad y rendimiento del servicio NSE." | ||
2197 | |||
2198 | #: src/dht/gnunet-dht-put.c:133 | 2149 | #: src/dht/gnunet-dht-put.c:133 |
2199 | msgid "Must provide KEY and DATA for DHT put!\n" | 2150 | msgid "Must provide KEY and DATA for DHT put!\n" |
2200 | msgstr "¡Se deben proveer «KEY» y «DATA» para una subida a la DHT!\n" | 2151 | msgstr "¡Se deben proveer «KEY» y «DATA» para una subida a la DHT!\n" |
@@ -2459,6 +2410,55 @@ msgstr "# Entradas añadidas a la tabla de encaminamiento" | |||
2459 | msgid "# DHT requests combined" | 2410 | msgid "# DHT requests combined" |
2460 | msgstr "# Peticiones a la DHT combinadas" | 2411 | msgstr "# Peticiones a la DHT combinadas" |
2461 | 2412 | ||
2413 | #: src/dht/gnunet_dht_profiler.c:922 src/testbed/gnunet-testbed-profiler.c:255 | ||
2414 | #, fuzzy, c-format | ||
2415 | msgid "Exiting as the number of peers is %u\n" | ||
2416 | msgstr "El número máximo de conexiones es %u\n" | ||
2417 | |||
2418 | #: src/dht/gnunet_dht_profiler.c:955 src/rps/gnunet-rps-profiler.c:3194 | ||
2419 | msgid "number of peers to start" | ||
2420 | msgstr "número de pares para empezar" | ||
2421 | |||
2422 | #: src/dht/gnunet_dht_profiler.c:961 | ||
2423 | msgid "number of PUTs to perform per peer" | ||
2424 | msgstr "" | ||
2425 | |||
2426 | #: src/dht/gnunet_dht_profiler.c:967 src/nse/gnunet-nse-profiler.c:872 | ||
2427 | #: src/testbed/gnunet-testbed-profiler.c:305 | ||
2428 | msgid "name of the file with the login information for the testbed" | ||
2429 | msgstr "" | ||
2430 | "nombre del fichero con la información de acceso usada para la batería de " | ||
2431 | "pruebas" | ||
2432 | |||
2433 | #: src/dht/gnunet_dht_profiler.c:973 | ||
2434 | msgid "delay between rounds for collecting statistics (default: 30 sec)" | ||
2435 | msgstr "" | ||
2436 | |||
2437 | #: src/dht/gnunet_dht_profiler.c:979 | ||
2438 | msgid "delay to start doing PUTs (default: 1 sec)" | ||
2439 | msgstr "" | ||
2440 | |||
2441 | #: src/dht/gnunet_dht_profiler.c:985 | ||
2442 | msgid "delay to start doing GETs (default: 5 min)" | ||
2443 | msgstr "" | ||
2444 | |||
2445 | #: src/dht/gnunet_dht_profiler.c:990 | ||
2446 | msgid "replication degree for DHT PUTs" | ||
2447 | msgstr "" | ||
2448 | |||
2449 | #: src/dht/gnunet_dht_profiler.c:996 | ||
2450 | msgid "chance that a peer is selected at random for PUTs" | ||
2451 | msgstr "" | ||
2452 | |||
2453 | #: src/dht/gnunet_dht_profiler.c:1002 | ||
2454 | msgid "timeout for DHT PUT and GET requests (default: 1 min)" | ||
2455 | msgstr "" | ||
2456 | |||
2457 | #: src/dht/gnunet_dht_profiler.c:1023 | ||
2458 | #, fuzzy | ||
2459 | msgid "Measure quality and performance of the DHT service." | ||
2460 | msgstr "Medir la calidad y rendimiento del servicio NSE." | ||
2461 | |||
2462 | #: src/dht/plugin_block_dht.c:189 | 2462 | #: src/dht/plugin_block_dht.c:189 |
2463 | #, c-format | 2463 | #, c-format |
2464 | msgid "Block not of type %u\n" | 2464 | msgid "Block not of type %u\n" |
@@ -3442,14 +3442,6 @@ msgstr "" | |||
3442 | "Descargar ficheros de GNUnet usando una URI GNUnet CHK o LOC (gnunet://fs/" | 3442 | "Descargar ficheros de GNUnet usando una URI GNUnet CHK o LOC (gnunet://fs/" |
3443 | "chk/...)" | 3443 | "chk/...)" |
3444 | 3444 | ||
3445 | #: src/fs/gnunet-fs.c:128 | ||
3446 | msgid "print a list of all indexed files" | ||
3447 | msgstr "imprimir una lista de todos los ficheros indexados" | ||
3448 | |||
3449 | #: src/fs/gnunet-fs.c:141 | ||
3450 | msgid "Special file-sharing operations" | ||
3451 | msgstr "Operaciones especiales de compartición de ficheros" | ||
3452 | |||
3453 | #: src/fs/gnunet-fs-profiler.c:211 | 3445 | #: src/fs/gnunet-fs-profiler.c:211 |
3454 | msgid "run the experiment with COUNT peers" | 3446 | msgid "run the experiment with COUNT peers" |
3455 | msgstr "ejecuta el experimento con «COUNT» pares" | 3447 | msgstr "ejecuta el experimento con «COUNT» pares" |
@@ -3470,6 +3462,14 @@ msgstr "" | |||
3470 | "ejecuta una batería de pruebas para medir el rendimiento de la compartición " | 3462 | "ejecuta una batería de pruebas para medir el rendimiento de la compartición " |
3471 | "de ficheros" | 3463 | "de ficheros" |
3472 | 3464 | ||
3465 | #: src/fs/gnunet-fs.c:128 | ||
3466 | msgid "print a list of all indexed files" | ||
3467 | msgstr "imprimir una lista de todos los ficheros indexados" | ||
3468 | |||
3469 | #: src/fs/gnunet-fs.c:141 | ||
3470 | msgid "Special file-sharing operations" | ||
3471 | msgstr "Operaciones especiales de compartición de ficheros" | ||
3472 | |||
3473 | #: src/fs/gnunet-publish.c:219 src/fs/gnunet-publish.c:234 | 3473 | #: src/fs/gnunet-publish.c:219 src/fs/gnunet-publish.c:234 |
3474 | #, c-format | 3474 | #, c-format |
3475 | msgid "Publishing `%s' at %llu/%llu (%s remaining)\n" | 3475 | msgid "Publishing `%s' at %llu/%llu (%s remaining)\n" |
@@ -4168,53 +4168,6 @@ msgstr "¿cuánto tiempo se debe ejecutar? 0 = para siempre" | |||
4168 | msgid "look for GNS2DNS records instead of ANY" | 4168 | msgid "look for GNS2DNS records instead of ANY" |
4169 | msgstr "" | 4169 | msgstr "" |
4170 | 4170 | ||
4171 | #: src/gns/gnunet-gns.c:257 | ||
4172 | #, fuzzy, c-format | ||
4173 | msgid "`%s' is not a valid DNS domain name\n" | ||
4174 | msgstr "«%s» no es una dirección IP válida.\n" | ||
4175 | |||
4176 | #: src/gns/gnunet-gns.c:267 src/util/dnsparser.c:254 | ||
4177 | #, c-format | ||
4178 | msgid "Failed to convert DNS IDNA name `%s' to UTF-8: %s\n" | ||
4179 | msgstr "" | ||
4180 | "Se produjo un fallo al convertir el nombre en formato DNS IDNA «%s» a UTF-8: " | ||
4181 | "%s\n" | ||
4182 | |||
4183 | #: src/gns/gnunet-gns.c:281 | ||
4184 | msgid "Cannot resolve using GNS: GNUnet peer not running\n" | ||
4185 | msgstr "" | ||
4186 | |||
4187 | #: src/gns/gnunet-gns.c:305 | ||
4188 | #, c-format | ||
4189 | msgid "Invalid typename specified, assuming `ANY'\n" | ||
4190 | msgstr "" | ||
4191 | |||
4192 | #: src/gns/gnunet-gns.c:340 | ||
4193 | msgid "Lookup a record for the given name" | ||
4194 | msgstr "Buscar el registro para el nombre dado" | ||
4195 | |||
4196 | #: src/gns/gnunet-gns.c:346 | ||
4197 | msgid "Specify the type of the record to lookup" | ||
4198 | msgstr "Especificar el tipo del registro a buscar" | ||
4199 | |||
4200 | #: src/gns/gnunet-gns.c:352 | ||
4201 | #, fuzzy | ||
4202 | msgid "Specify a timeout for the lookup" | ||
4203 | msgstr "Especificar el tipo del registro a buscar" | ||
4204 | |||
4205 | #: src/gns/gnunet-gns.c:356 | ||
4206 | msgid "No unneeded output" | ||
4207 | msgstr "Sin salida innecesaria" | ||
4208 | |||
4209 | #: src/gns/gnunet-gns.c:361 | ||
4210 | msgid "DNS Compatibility: Name is passed in IDNA instead of UTF-8" | ||
4211 | msgstr "" | ||
4212 | |||
4213 | #: src/gns/gnunet-gns.c:375 | ||
4214 | #, fuzzy | ||
4215 | msgid "GNUnet GNS resolver tool" | ||
4216 | msgstr "Herramienta de acceso GNUnet GNS" | ||
4217 | |||
4218 | #: src/gns/gnunet-gns-import.c:486 | 4171 | #: src/gns/gnunet-gns-import.c:486 |
4219 | msgid "This program will import some GNS authorities into your GNS namestore." | 4172 | msgid "This program will import some GNS authorities into your GNS namestore." |
4220 | msgstr "" | 4173 | msgstr "" |
@@ -4335,6 +4288,53 @@ msgstr "" | |||
4335 | msgid "GNUnet GNS proxy" | 4288 | msgid "GNUnet GNS proxy" |
4336 | msgstr "Proxy GNUnet GNS" | 4289 | msgstr "Proxy GNUnet GNS" |
4337 | 4290 | ||
4291 | #: src/gns/gnunet-gns.c:257 | ||
4292 | #, fuzzy, c-format | ||
4293 | msgid "`%s' is not a valid DNS domain name\n" | ||
4294 | msgstr "«%s» no es una dirección IP válida.\n" | ||
4295 | |||
4296 | #: src/gns/gnunet-gns.c:267 src/util/dnsparser.c:254 | ||
4297 | #, c-format | ||
4298 | msgid "Failed to convert DNS IDNA name `%s' to UTF-8: %s\n" | ||
4299 | msgstr "" | ||
4300 | "Se produjo un fallo al convertir el nombre en formato DNS IDNA «%s» a UTF-8: " | ||
4301 | "%s\n" | ||
4302 | |||
4303 | #: src/gns/gnunet-gns.c:281 | ||
4304 | msgid "Cannot resolve using GNS: GNUnet peer not running\n" | ||
4305 | msgstr "" | ||
4306 | |||
4307 | #: src/gns/gnunet-gns.c:305 | ||
4308 | #, c-format | ||
4309 | msgid "Invalid typename specified, assuming `ANY'\n" | ||
4310 | msgstr "" | ||
4311 | |||
4312 | #: src/gns/gnunet-gns.c:340 | ||
4313 | msgid "Lookup a record for the given name" | ||
4314 | msgstr "Buscar el registro para el nombre dado" | ||
4315 | |||
4316 | #: src/gns/gnunet-gns.c:346 | ||
4317 | msgid "Specify the type of the record to lookup" | ||
4318 | msgstr "Especificar el tipo del registro a buscar" | ||
4319 | |||
4320 | #: src/gns/gnunet-gns.c:352 | ||
4321 | #, fuzzy | ||
4322 | msgid "Specify a timeout for the lookup" | ||
4323 | msgstr "Especificar el tipo del registro a buscar" | ||
4324 | |||
4325 | #: src/gns/gnunet-gns.c:356 | ||
4326 | msgid "No unneeded output" | ||
4327 | msgstr "Sin salida innecesaria" | ||
4328 | |||
4329 | #: src/gns/gnunet-gns.c:361 | ||
4330 | msgid "DNS Compatibility: Name is passed in IDNA instead of UTF-8" | ||
4331 | msgstr "" | ||
4332 | |||
4333 | #: src/gns/gnunet-gns.c:375 | ||
4334 | #, fuzzy | ||
4335 | msgid "GNUnet GNS resolver tool" | ||
4336 | msgstr "Herramienta de acceso GNUnet GNS" | ||
4337 | |||
4338 | #: src/gns/gnunet-service-gns.c:505 | 4338 | #: src/gns/gnunet-service-gns.c:505 |
4339 | #, fuzzy | 4339 | #, fuzzy |
4340 | msgid "Properly base32-encoded public key required" | 4340 | msgid "Properly base32-encoded public key required" |
@@ -4346,8 +4346,8 @@ msgid "Failed to connect to the namecache!\n" | |||
4346 | msgstr "¡Se produjo un fallo al conectar con el almacén de nombres!\n" | 4346 | msgstr "¡Se produjo un fallo al conectar con el almacén de nombres!\n" |
4347 | 4347 | ||
4348 | #: src/gns/gnunet-service-gns.c:560 | 4348 | #: src/gns/gnunet-service-gns.c:560 |
4349 | #: src/zonemaster/gnunet-service-zonemaster.c:887 | ||
4350 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:444 | 4349 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:444 |
4350 | #: src/zonemaster/gnunet-service-zonemaster.c:887 | ||
4351 | msgid "Could not connect to DHT!\n" | 4351 | msgid "Could not connect to DHT!\n" |
4352 | msgstr "¡No se pudo conectar a la DHT!\n" | 4352 | msgstr "¡No se pudo conectar a la DHT!\n" |
4353 | 4353 | ||
@@ -4877,7 +4877,7 @@ msgid "# hostlist advertisements send" | |||
4877 | msgstr "# anuncios de listas de máquinas enviados" | 4877 | msgstr "# anuncios de listas de máquinas enviados" |
4878 | 4878 | ||
4879 | #: src/hostlist/gnunet-daemon-hostlist_server.c:674 | 4879 | #: src/hostlist/gnunet-daemon-hostlist_server.c:674 |
4880 | #: src/transport/gnunet-service-transport.c:2659 | 4880 | #: src/transport/gnunet-service-transport.c:2661 |
4881 | msgid "Could not access PEERINFO service. Exiting.\n" | 4881 | msgid "Could not access PEERINFO service. Exiting.\n" |
4882 | msgstr "" | 4882 | msgstr "" |
4883 | "No se pudo acceder al servicio de información de pares (PEERINFO). " | 4883 | "No se pudo acceder al servicio de información de pares (PEERINFO). " |
@@ -5143,6 +5143,71 @@ msgstr "Base de datos sqlite ejecutándose\n" | |||
5143 | msgid "Failed to setup database at `%s'\n" | 5143 | msgid "Failed to setup database at `%s'\n" |
5144 | msgstr "Se produjo un fallo al inciar «%s» en «%s»\n" | 5144 | msgstr "Se produjo un fallo al inciar «%s» en «%s»\n" |
5145 | 5145 | ||
5146 | # form?? | ||
5147 | #: src/namestore/gnunet-namestore-fcfsd.c:552 | ||
5148 | #, c-format | ||
5149 | msgid "Unsupported form value `%s'\n" | ||
5150 | msgstr "Forma de valor no soportada «%s»\n" | ||
5151 | |||
5152 | #: src/namestore/gnunet-namestore-fcfsd.c:579 | ||
5153 | #, c-format | ||
5154 | msgid "Failed to create record for domain `%s': %s\n" | ||
5155 | msgstr "Se produjo un fallo al crear un registro para el dominio «%s»: %s\n" | ||
5156 | |||
5157 | #: src/namestore/gnunet-namestore-fcfsd.c:600 | ||
5158 | msgid "Error when mapping zone to name\n" | ||
5159 | msgstr "" | ||
5160 | |||
5161 | #: src/namestore/gnunet-namestore-fcfsd.c:632 | ||
5162 | #, c-format | ||
5163 | msgid "Found existing name `%s' for the given key\n" | ||
5164 | msgstr "Encontrado nombre «%s» para la clave dada\n" | ||
5165 | |||
5166 | #: src/namestore/gnunet-namestore-fcfsd.c:694 | ||
5167 | #, c-format | ||
5168 | msgid "Found %u existing records for domain `%s'\n" | ||
5169 | msgstr "Encontrados %u registros para el dominio «%s»\n" | ||
5170 | |||
5171 | #: src/namestore/gnunet-namestore-fcfsd.c:784 | ||
5172 | #, c-format | ||
5173 | msgid "Failed to create page for `%s'\n" | ||
5174 | msgstr "Se produjo un fallo al crear la página para «%s»\n" | ||
5175 | |||
5176 | #: src/namestore/gnunet-namestore-fcfsd.c:803 | ||
5177 | #, c-format | ||
5178 | msgid "Failed to setup post processor for `%s'\n" | ||
5179 | msgstr "Se produjo un fallo al configurar el post-procesador para «%s»\n" | ||
5180 | |||
5181 | #: src/namestore/gnunet-namestore-fcfsd.c:840 | ||
5182 | msgid "Domain name must not contain `.'\n" | ||
5183 | msgstr "El nombre de dominio no puede contener «.»\n" | ||
5184 | |||
5185 | #: src/namestore/gnunet-namestore-fcfsd.c:849 | ||
5186 | msgid "Domain name must not contain `+'\n" | ||
5187 | msgstr "El nombre de dominio no puede contener «+»\n" | ||
5188 | |||
5189 | #: src/namestore/gnunet-namestore-fcfsd.c:1084 | ||
5190 | msgid "No ego configured for `fcfsd` subsystem\n" | ||
5191 | msgstr "" | ||
5192 | |||
5193 | #: src/namestore/gnunet-namestore-fcfsd.c:1115 | ||
5194 | msgid "Failed to start HTTP server\n" | ||
5195 | msgstr "Se produjo un fallo al iniciar el servidor HTTP\n" | ||
5196 | |||
5197 | #: src/namestore/gnunet-namestore-fcfsd.c:1163 | ||
5198 | #, fuzzy | ||
5199 | msgid "Failed to connect to identity\n" | ||
5200 | msgstr "Se produjo un fallo al conectar con GNS\n" | ||
5201 | |||
5202 | #: src/namestore/gnunet-namestore-fcfsd.c:1190 | ||
5203 | msgid "name of the zone that is to be managed by FCFSD" | ||
5204 | msgstr "" | ||
5205 | |||
5206 | #: src/namestore/gnunet-namestore-fcfsd.c:1210 | ||
5207 | #, fuzzy | ||
5208 | msgid "GNU Name System First Come First Serve name registration service" | ||
5209 | msgstr "Servicio de registro GNUnet GNS primero en llegar, primero en servirse" | ||
5210 | |||
5146 | #: src/namestore/gnunet-namestore.c:334 | 5211 | #: src/namestore/gnunet-namestore.c:334 |
5147 | #, c-format | 5212 | #, c-format |
5148 | msgid "Adding record failed: %s\n" | 5213 | msgid "Adding record failed: %s\n" |
@@ -5375,71 +5440,6 @@ msgstr "" | |||
5375 | msgid "name of the ego controlling the zone" | 5440 | msgid "name of the ego controlling the zone" |
5376 | msgstr "nombre de la sección a la que acceder" | 5441 | msgstr "nombre de la sección a la que acceder" |
5377 | 5442 | ||
5378 | # form?? | ||
5379 | #: src/namestore/gnunet-namestore-fcfsd.c:552 | ||
5380 | #, c-format | ||
5381 | msgid "Unsupported form value `%s'\n" | ||
5382 | msgstr "Forma de valor no soportada «%s»\n" | ||
5383 | |||
5384 | #: src/namestore/gnunet-namestore-fcfsd.c:579 | ||
5385 | #, c-format | ||
5386 | msgid "Failed to create record for domain `%s': %s\n" | ||
5387 | msgstr "Se produjo un fallo al crear un registro para el dominio «%s»: %s\n" | ||
5388 | |||
5389 | #: src/namestore/gnunet-namestore-fcfsd.c:600 | ||
5390 | msgid "Error when mapping zone to name\n" | ||
5391 | msgstr "" | ||
5392 | |||
5393 | #: src/namestore/gnunet-namestore-fcfsd.c:632 | ||
5394 | #, c-format | ||
5395 | msgid "Found existing name `%s' for the given key\n" | ||
5396 | msgstr "Encontrado nombre «%s» para la clave dada\n" | ||
5397 | |||
5398 | #: src/namestore/gnunet-namestore-fcfsd.c:694 | ||
5399 | #, c-format | ||
5400 | msgid "Found %u existing records for domain `%s'\n" | ||
5401 | msgstr "Encontrados %u registros para el dominio «%s»\n" | ||
5402 | |||
5403 | #: src/namestore/gnunet-namestore-fcfsd.c:784 | ||
5404 | #, c-format | ||
5405 | msgid "Failed to create page for `%s'\n" | ||
5406 | msgstr "Se produjo un fallo al crear la página para «%s»\n" | ||
5407 | |||
5408 | #: src/namestore/gnunet-namestore-fcfsd.c:803 | ||
5409 | #, c-format | ||
5410 | msgid "Failed to setup post processor for `%s'\n" | ||
5411 | msgstr "Se produjo un fallo al configurar el post-procesador para «%s»\n" | ||
5412 | |||
5413 | #: src/namestore/gnunet-namestore-fcfsd.c:840 | ||
5414 | msgid "Domain name must not contain `.'\n" | ||
5415 | msgstr "El nombre de dominio no puede contener «.»\n" | ||
5416 | |||
5417 | #: src/namestore/gnunet-namestore-fcfsd.c:849 | ||
5418 | msgid "Domain name must not contain `+'\n" | ||
5419 | msgstr "El nombre de dominio no puede contener «+»\n" | ||
5420 | |||
5421 | #: src/namestore/gnunet-namestore-fcfsd.c:1084 | ||
5422 | msgid "No ego configured for `fcfsd` subsystem\n" | ||
5423 | msgstr "" | ||
5424 | |||
5425 | #: src/namestore/gnunet-namestore-fcfsd.c:1115 | ||
5426 | msgid "Failed to start HTTP server\n" | ||
5427 | msgstr "Se produjo un fallo al iniciar el servidor HTTP\n" | ||
5428 | |||
5429 | #: src/namestore/gnunet-namestore-fcfsd.c:1163 | ||
5430 | #, fuzzy | ||
5431 | msgid "Failed to connect to identity\n" | ||
5432 | msgstr "Se produjo un fallo al conectar con GNS\n" | ||
5433 | |||
5434 | #: src/namestore/gnunet-namestore-fcfsd.c:1190 | ||
5435 | msgid "name of the zone that is to be managed by FCFSD" | ||
5436 | msgstr "" | ||
5437 | |||
5438 | #: src/namestore/gnunet-namestore-fcfsd.c:1210 | ||
5439 | #, fuzzy | ||
5440 | msgid "GNU Name System First Come First Serve name registration service" | ||
5441 | msgstr "Servicio de registro GNUnet GNS primero en llegar, primero en servirse" | ||
5442 | |||
5443 | #: src/namestore/gnunet-service-namestore.c:866 | 5443 | #: src/namestore/gnunet-service-namestore.c:866 |
5444 | #, fuzzy, c-format | 5444 | #, fuzzy, c-format |
5445 | msgid "Failed to replicate block in namecache: %s\n" | 5445 | msgid "Failed to replicate block in namecache: %s\n" |
@@ -5773,11 +5773,6 @@ msgstr "comando «external-ip» no encontrado\n" | |||
5773 | msgid "`upnpc' command not found\n" | 5773 | msgid "`upnpc' command not found\n" |
5774 | msgstr "comando «upnpc» no encontrado\n" | 5774 | msgstr "comando «upnpc» no encontrado\n" |
5775 | 5775 | ||
5776 | #: src/nse/gnunet-nse.c:124 | ||
5777 | #, fuzzy | ||
5778 | msgid "Show network size estimates from NSE service." | ||
5779 | msgstr "# Estimaciones del tamaño de red recibidas" | ||
5780 | |||
5781 | #: src/nse/gnunet-nse-profiler.c:857 | 5776 | #: src/nse/gnunet-nse-profiler.c:857 |
5782 | msgid "limit to the number of connections to NSE services, 0 for none" | 5777 | msgid "limit to the number of connections to NSE services, 0 for none" |
5783 | msgstr "límite al número de conexiones a servicios NSE, 0 para ilimitadas" | 5778 | msgstr "límite al número de conexiones a servicios NSE, 0 para ilimitadas" |
@@ -5803,70 +5798,16 @@ msgstr "retraso entre rondas" | |||
5803 | msgid "Measure quality and performance of the NSE service." | 5798 | msgid "Measure quality and performance of the NSE service." |
5804 | msgstr "Medir la calidad y rendimiento del servicio NSE." | 5799 | msgstr "Medir la calidad y rendimiento del servicio NSE." |
5805 | 5800 | ||
5801 | #: src/nse/gnunet-nse.c:124 | ||
5802 | #, fuzzy | ||
5803 | msgid "Show network size estimates from NSE service." | ||
5804 | msgstr "# Estimaciones del tamaño de red recibidas" | ||
5805 | |||
5806 | #: src/nse/gnunet-service-nse.c:1443 | 5806 | #: src/nse/gnunet-service-nse.c:1443 |
5807 | #: src/revocation/gnunet-service-revocation.c:834 src/util/gnunet-scrypt.c:257 | 5807 | #: src/revocation/gnunet-service-revocation.c:834 src/util/gnunet-scrypt.c:257 |
5808 | msgid "Value is too large.\n" | 5808 | msgid "Value is too large.\n" |
5809 | msgstr "" | 5809 | msgstr "" |
5810 | 5810 | ||
5811 | #: src/peerinfo/gnunet-service-peerinfo.c:175 | ||
5812 | #, c-format | ||
5813 | msgid "Removing expired address of transport `%s'\n" | ||
5814 | msgstr "Eliminando dirección de transporte «%s»\n" | ||
5815 | |||
5816 | #: src/peerinfo/gnunet-service-peerinfo.c:306 | ||
5817 | #, fuzzy, c-format | ||
5818 | msgid "Failed to parse HELLO in file `%s': %s\n" | ||
5819 | msgstr "Se produjo un fallo al procesar «HELLO» en el fichero «%s»\n" | ||
5820 | |||
5821 | #: src/peerinfo/gnunet-service-peerinfo.c:323 | ||
5822 | #: src/peerinfo/gnunet-service-peerinfo.c:348 | ||
5823 | #, fuzzy, c-format | ||
5824 | msgid "Failed to parse HELLO in file `%s'\n" | ||
5825 | msgstr "Se produjo un fallo al procesar «HELLO» en el fichero «%s»\n" | ||
5826 | |||
5827 | #: src/peerinfo/gnunet-service-peerinfo.c:426 | ||
5828 | msgid "# peers known" | ||
5829 | msgstr "# pares conocidos" | ||
5830 | |||
5831 | #: src/peerinfo/gnunet-service-peerinfo.c:468 | ||
5832 | #, c-format | ||
5833 | msgid "" | ||
5834 | "File `%s' in directory `%s' does not match naming convention. Removed.\n" | ||
5835 | msgstr "" | ||
5836 | "El fichero «%s» en el directorio «%s» no sigue la convención de nombres. " | ||
5837 | "Eliminado.\n" | ||
5838 | |||
5839 | #: src/peerinfo/gnunet-service-peerinfo.c:624 | ||
5840 | #, fuzzy, c-format | ||
5841 | msgid "Scanning directory `%s'\n" | ||
5842 | msgstr "Escaneando directorio «%s».\n" | ||
5843 | |||
5844 | #: src/peerinfo/gnunet-service-peerinfo.c:631 | ||
5845 | #, c-format | ||
5846 | msgid "Still no peers found in `%s'!\n" | ||
5847 | msgstr "¡Aún no se han encontrado pares en «%s»!\n" | ||
5848 | |||
5849 | #: src/peerinfo/gnunet-service-peerinfo.c:1024 | ||
5850 | #, fuzzy, c-format | ||
5851 | msgid "Cleaning up directory `%s'\n" | ||
5852 | msgstr "Escaneando directorio «%s».\n" | ||
5853 | |||
5854 | #: src/peerinfo/gnunet-service-peerinfo.c:1319 | ||
5855 | #, c-format | ||
5856 | msgid "Importing HELLOs from `%s'\n" | ||
5857 | msgstr "Importando HELLO de «%s»\n" | ||
5858 | |||
5859 | #: src/peerinfo/gnunet-service-peerinfo.c:1332 | ||
5860 | msgid "Skipping import of included HELLOs\n" | ||
5861 | msgstr "" | ||
5862 | |||
5863 | # Miguel: "Failed to receive" también aquí está traducido como | ||
5864 | # "no se obtuvo respuesta" por claridad. | ||
5865 | #: src/peerinfo/peerinfo_api.c:217 | ||
5866 | msgid "Failed to receive response from `PEERINFO' service." | ||
5867 | msgstr "" | ||
5868 | "No se obtuvo respuesta del servicio de información de pares (PEERINFO)." | ||
5869 | |||
5870 | #: src/peerinfo-tool/gnunet-peerinfo.c:237 | 5811 | #: src/peerinfo-tool/gnunet-peerinfo.c:237 |
5871 | #, fuzzy, c-format | 5812 | #, fuzzy, c-format |
5872 | msgid "%sPeer `%s'\n" | 5813 | msgid "%sPeer `%s'\n" |
@@ -5962,6 +5903,65 @@ msgstr "Se produjo un fallo al cargar el módulo del transporte para «%s»\n" | |||
5962 | msgid "Peerinfo REST API initialized\n" | 5903 | msgid "Peerinfo REST API initialized\n" |
5963 | msgstr "Conexión fallida\n" | 5904 | msgstr "Conexión fallida\n" |
5964 | 5905 | ||
5906 | #: src/peerinfo/gnunet-service-peerinfo.c:175 | ||
5907 | #, c-format | ||
5908 | msgid "Removing expired address of transport `%s'\n" | ||
5909 | msgstr "Eliminando dirección de transporte «%s»\n" | ||
5910 | |||
5911 | #: src/peerinfo/gnunet-service-peerinfo.c:306 | ||
5912 | #, fuzzy, c-format | ||
5913 | msgid "Failed to parse HELLO in file `%s': %s\n" | ||
5914 | msgstr "Se produjo un fallo al procesar «HELLO» en el fichero «%s»\n" | ||
5915 | |||
5916 | #: src/peerinfo/gnunet-service-peerinfo.c:323 | ||
5917 | #: src/peerinfo/gnunet-service-peerinfo.c:348 | ||
5918 | #, fuzzy, c-format | ||
5919 | msgid "Failed to parse HELLO in file `%s'\n" | ||
5920 | msgstr "Se produjo un fallo al procesar «HELLO» en el fichero «%s»\n" | ||
5921 | |||
5922 | #: src/peerinfo/gnunet-service-peerinfo.c:426 | ||
5923 | msgid "# peers known" | ||
5924 | msgstr "# pares conocidos" | ||
5925 | |||
5926 | #: src/peerinfo/gnunet-service-peerinfo.c:468 | ||
5927 | #, c-format | ||
5928 | msgid "" | ||
5929 | "File `%s' in directory `%s' does not match naming convention. Removed.\n" | ||
5930 | msgstr "" | ||
5931 | "El fichero «%s» en el directorio «%s» no sigue la convención de nombres. " | ||
5932 | "Eliminado.\n" | ||
5933 | |||
5934 | #: src/peerinfo/gnunet-service-peerinfo.c:624 | ||
5935 | #, fuzzy, c-format | ||
5936 | msgid "Scanning directory `%s'\n" | ||
5937 | msgstr "Escaneando directorio «%s».\n" | ||
5938 | |||
5939 | #: src/peerinfo/gnunet-service-peerinfo.c:631 | ||
5940 | #, c-format | ||
5941 | msgid "Still no peers found in `%s'!\n" | ||
5942 | msgstr "¡Aún no se han encontrado pares en «%s»!\n" | ||
5943 | |||
5944 | #: src/peerinfo/gnunet-service-peerinfo.c:1024 | ||
5945 | #, fuzzy, c-format | ||
5946 | msgid "Cleaning up directory `%s'\n" | ||
5947 | msgstr "Escaneando directorio «%s».\n" | ||
5948 | |||
5949 | #: src/peerinfo/gnunet-service-peerinfo.c:1319 | ||
5950 | #, c-format | ||
5951 | msgid "Importing HELLOs from `%s'\n" | ||
5952 | msgstr "Importando HELLO de «%s»\n" | ||
5953 | |||
5954 | #: src/peerinfo/gnunet-service-peerinfo.c:1332 | ||
5955 | msgid "Skipping import of included HELLOs\n" | ||
5956 | msgstr "" | ||
5957 | |||
5958 | # Miguel: "Failed to receive" también aquí está traducido como | ||
5959 | # "no se obtuvo respuesta" por claridad. | ||
5960 | #: src/peerinfo/peerinfo_api.c:217 | ||
5961 | msgid "Failed to receive response from `PEERINFO' service." | ||
5962 | msgstr "" | ||
5963 | "No se obtuvo respuesta del servicio de información de pares (PEERINFO)." | ||
5964 | |||
5965 | #: src/peerstore/gnunet-peerstore.c:92 | 5965 | #: src/peerstore/gnunet-peerstore.c:92 |
5966 | msgid "peerstore" | 5966 | msgid "peerstore" |
5967 | msgstr "" | 5967 | msgstr "" |
@@ -6433,18 +6433,6 @@ msgstr "" | |||
6433 | msgid "Could not open revocation database file!" | 6433 | msgid "Could not open revocation database file!" |
6434 | msgstr "No se pudo conectar con el almacén de datos." | 6434 | msgstr "No se pudo conectar con el almacén de datos." |
6435 | 6435 | ||
6436 | #: src/rps/gnunet-rps.c:270 | ||
6437 | msgid "Seed a PeerID" | ||
6438 | msgstr "" | ||
6439 | |||
6440 | #: src/rps/gnunet-rps.c:275 | ||
6441 | msgid "Get updates of view (0 for infinite updates)" | ||
6442 | msgstr "" | ||
6443 | |||
6444 | #: src/rps/gnunet-rps.c:279 | ||
6445 | msgid "Get peers from biased stream" | ||
6446 | msgstr "" | ||
6447 | |||
6448 | #: src/rps/gnunet-rps-profiler.c:3200 | 6436 | #: src/rps/gnunet-rps-profiler.c:3200 |
6449 | #, fuzzy | 6437 | #, fuzzy |
6450 | msgid "duration of the profiling" | 6438 | msgid "duration of the profiling" |
@@ -6466,6 +6454,18 @@ msgstr "número de pares para empezar" | |||
6466 | msgid "Measure quality and performance of the RPS service." | 6454 | msgid "Measure quality and performance of the RPS service." |
6467 | msgstr "Medir la calidad y rendimiento del servicio NSE." | 6455 | msgstr "Medir la calidad y rendimiento del servicio NSE." |
6468 | 6456 | ||
6457 | #: src/rps/gnunet-rps.c:270 | ||
6458 | msgid "Seed a PeerID" | ||
6459 | msgstr "" | ||
6460 | |||
6461 | #: src/rps/gnunet-rps.c:275 | ||
6462 | msgid "Get updates of view (0 for infinite updates)" | ||
6463 | msgstr "" | ||
6464 | |||
6465 | #: src/rps/gnunet-rps.c:279 | ||
6466 | msgid "Get peers from biased stream" | ||
6467 | msgstr "" | ||
6468 | |||
6469 | #: src/scalarproduct/gnunet-scalarproduct.c:229 | 6469 | #: src/scalarproduct/gnunet-scalarproduct.c:229 |
6470 | #, fuzzy | 6470 | #, fuzzy |
6471 | msgid "You must specify at least one message ID to check!\n" | 6471 | msgid "You must specify at least one message ID to check!\n" |
@@ -6521,10 +6521,10 @@ msgstr "" | |||
6521 | msgid "Calculate the Vectorproduct with a GNUnet peer." | 6521 | msgid "Calculate the Vectorproduct with a GNUnet peer." |
6522 | msgstr "" | 6522 | msgstr "" |
6523 | 6523 | ||
6524 | #: src/scalarproduct/gnunet-service-scalarproduct_alice.c:1358 | ||
6525 | #: src/scalarproduct/gnunet-service-scalarproduct_bob.c:1355 | ||
6526 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_alice.c:1118 | 6524 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_alice.c:1118 |
6527 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c:1063 | 6525 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c:1063 |
6526 | #: src/scalarproduct/gnunet-service-scalarproduct_alice.c:1358 | ||
6527 | #: src/scalarproduct/gnunet-service-scalarproduct_bob.c:1355 | ||
6528 | #, fuzzy | 6528 | #, fuzzy |
6529 | msgid "Connect to CADET failed\n" | 6529 | msgid "Connect to CADET failed\n" |
6530 | msgstr "Conexión fallida (¿bug?)\n" | 6530 | msgstr "Conexión fallida (¿bug?)\n" |
@@ -6884,16 +6884,6 @@ msgstr "Petición ignorada porque el ARM se está apagando.\n" | |||
6884 | msgid "%.s Unknown result code." | 6884 | msgid "%.s Unknown result code." |
6885 | msgstr "Código de respuesta del ARM desconocido.\n" | 6885 | msgstr "Código de respuesta del ARM desconocido.\n" |
6886 | 6886 | ||
6887 | #: src/testbed/gnunet_testbed_mpi_spawn.c:119 | ||
6888 | #, fuzzy | ||
6889 | msgid "Waiting for child to exit.\n" | ||
6890 | msgstr "Esperando a los pares para conectar (%u ciclos restantes)...\n" | ||
6891 | |||
6892 | #: src/testbed/gnunet_testbed_mpi_spawn.c:242 | ||
6893 | #, fuzzy, c-format | ||
6894 | msgid "Spawning process `%s'\n" | ||
6895 | msgstr "Iniciando el proceso auxiliar (HELPER) «%s»\n" | ||
6896 | |||
6897 | #: src/testbed/gnunet-testbed-profiler.c:290 | 6887 | #: src/testbed/gnunet-testbed-profiler.c:290 |
6898 | msgid "tolerate COUNT number of continious timeout failures" | 6888 | msgid "tolerate COUNT number of continious timeout failures" |
6899 | msgstr "tolerar un número «COUNT» de continuas expiraciones de plazo" | 6889 | msgstr "tolerar un número «COUNT» de continuas expiraciones de plazo" |
@@ -6905,6 +6895,16 @@ msgid "" | |||
6905 | "signal is received" | 6895 | "signal is received" |
6906 | msgstr "" | 6896 | msgstr "" |
6907 | 6897 | ||
6898 | #: src/testbed/gnunet_testbed_mpi_spawn.c:119 | ||
6899 | #, fuzzy | ||
6900 | msgid "Waiting for child to exit.\n" | ||
6901 | msgstr "Esperando a los pares para conectar (%u ciclos restantes)...\n" | ||
6902 | |||
6903 | #: src/testbed/gnunet_testbed_mpi_spawn.c:242 | ||
6904 | #, fuzzy, c-format | ||
6905 | msgid "Spawning process `%s'\n" | ||
6906 | msgstr "Iniciando el proceso auxiliar (HELPER) «%s»\n" | ||
6907 | |||
6908 | #: src/testbed/testbed_api.c:399 | 6908 | #: src/testbed/testbed_api.c:399 |
6909 | #, c-format | 6909 | #, c-format |
6910 | msgid "Adding host %u failed with error: %s\n" | 6910 | msgid "Adding host %u failed with error: %s\n" |
@@ -7225,22 +7225,22 @@ msgstr "# mensajes «HELLO» recibidos" | |||
7225 | msgid "GNUnet topology control" | 7225 | msgid "GNUnet topology control" |
7226 | msgstr "" | 7226 | msgstr "" |
7227 | 7227 | ||
7228 | #: src/transport/gnunet-communicator-tcp.c:3189 | 7228 | #: src/transport/gnunet-communicator-tcp.c:3221 |
7229 | #: src/transport/gnunet-communicator-udp.c:2826 | 7229 | #: src/transport/gnunet-communicator-udp.c:2995 |
7230 | #: src/transport/gnunet-service-tng.c:10014 | 7230 | #: src/transport/gnunet-service-tng.c:10014 |
7231 | #: src/transport/gnunet-service-transport.c:2624 | 7231 | #: src/transport/gnunet-service-transport.c:2626 |
7232 | #, fuzzy | 7232 | #, fuzzy |
7233 | msgid "Transport service is lacking key configuration settings. Exiting.\n" | 7233 | msgid "Transport service is lacking key configuration settings. Exiting.\n" |
7234 | msgstr "" | 7234 | msgstr "" |
7235 | "El servicio de transporte carece de opciones de configuración de clave. " | 7235 | "El servicio de transporte carece de opciones de configuración de clave. " |
7236 | "Saliendo.\n" | 7236 | "Saliendo.\n" |
7237 | 7237 | ||
7238 | #: src/transport/gnunet-communicator-tcp.c:3494 | 7238 | #: src/transport/gnunet-communicator-tcp.c:3553 |
7239 | #, fuzzy | 7239 | #, fuzzy |
7240 | msgid "GNUnet TCP communicator" | 7240 | msgid "GNUnet TCP communicator" |
7241 | msgstr "Configurador Gtk de GNUnet" | 7241 | msgstr "Configurador Gtk de GNUnet" |
7242 | 7242 | ||
7243 | #: src/transport/gnunet-communicator-udp.c:2898 | 7243 | #: src/transport/gnunet-communicator-udp.c:3067 |
7244 | #, fuzzy | 7244 | #, fuzzy |
7245 | msgid "GNUnet UDP communicator" | 7245 | msgid "GNUnet UDP communicator" |
7246 | msgstr "Configurador Gtk de GNUnet" | 7246 | msgstr "Configurador Gtk de GNUnet" |
@@ -7267,51 +7267,51 @@ msgstr "Se produjo un fallo al crear la página para «%s»\n" | |||
7267 | msgid "GNUnet UNIX domain socket communicator" | 7267 | msgid "GNUnet UNIX domain socket communicator" |
7268 | msgstr "" | 7268 | msgstr "" |
7269 | 7269 | ||
7270 | #: src/transport/gnunet-service-transport_ats.c:137 | ||
7271 | msgid "# Addresses given to ATS" | ||
7272 | msgstr "" | ||
7273 | |||
7274 | #: src/transport/gnunet-service-transport.c:445 | 7270 | #: src/transport/gnunet-service-transport.c:445 |
7275 | msgid "# messages dropped due to slow client" | 7271 | msgid "# messages dropped due to slow client" |
7276 | msgstr "# mensajes omitidos debido a un cliente lento" | 7272 | msgstr "# mensajes omitidos debido a un cliente lento" |
7277 | 7273 | ||
7278 | #: src/transport/gnunet-service-transport.c:794 | 7274 | #: src/transport/gnunet-service-transport.c:796 |
7279 | msgid "# bytes payload dropped (other peer was not connected)" | 7275 | msgid "# bytes payload dropped (other peer was not connected)" |
7280 | msgstr "# bytes de «payload» omitidos (el otro par no estaba conectado)" | 7276 | msgstr "# bytes de «payload» omitidos (el otro par no estaba conectado)" |
7281 | 7277 | ||
7282 | #: src/transport/gnunet-service-transport.c:1477 | 7278 | #: src/transport/gnunet-service-transport.c:1479 |
7283 | #, fuzzy | 7279 | #, fuzzy |
7284 | msgid "# bytes payload discarded due to not connected peer" | 7280 | msgid "# bytes payload discarded due to not connected peer" |
7285 | msgstr "# bytes de «payload» descartados debido a par no conectado" | 7281 | msgstr "# bytes de «payload» descartados debido a par no conectado" |
7286 | 7282 | ||
7287 | #: src/transport/gnunet-service-transport.c:1622 | 7283 | #: src/transport/gnunet-service-transport.c:1624 |
7288 | msgid "# bytes total received" | 7284 | msgid "# bytes total received" |
7289 | msgstr "# total de bytes recibidos" | 7285 | msgstr "# total de bytes recibidos" |
7290 | 7286 | ||
7291 | #: src/transport/gnunet-service-transport.c:1712 | 7287 | #: src/transport/gnunet-service-transport.c:1714 |
7292 | msgid "# bytes payload received" | 7288 | msgid "# bytes payload received" |
7293 | msgstr "# bytes de «payload» recibidos" | 7289 | msgstr "# bytes de «payload» recibidos" |
7294 | 7290 | ||
7295 | #: src/transport/gnunet-service-transport.c:2016 | 7291 | #: src/transport/gnunet-service-transport.c:2018 |
7296 | #: src/transport/gnunet-service-transport.c:2450 | 7292 | #: src/transport/gnunet-service-transport.c:2452 |
7297 | msgid "# disconnects due to blacklist" | 7293 | msgid "# disconnects due to blacklist" |
7298 | msgstr "# desconexiones debido a la lista negra" | 7294 | msgstr "# desconexiones debido a la lista negra" |
7299 | 7295 | ||
7300 | #: src/transport/gnunet-service-transport.c:2454 | 7296 | #: src/transport/gnunet-service-transport.c:2456 |
7301 | #, fuzzy, c-format | 7297 | #, fuzzy, c-format |
7302 | msgid "Disallowing connection to peer `%s' on transport %s\n" | 7298 | msgid "Disallowing connection to peer `%s' on transport %s\n" |
7303 | msgstr "Se produjo un fallo al cargar el módulo del transporte para «%s»\n" | 7299 | msgstr "Se produjo un fallo al cargar el módulo del transporte para «%s»\n" |
7304 | 7300 | ||
7305 | #: src/transport/gnunet-service-transport.c:2549 | 7301 | #: src/transport/gnunet-service-transport.c:2551 |
7306 | #, fuzzy, c-format | 7302 | #, fuzzy, c-format |
7307 | msgid "Adding blacklisting entry for peer `%s'\n" | 7303 | msgid "Adding blacklisting entry for peer `%s'\n" |
7308 | msgstr "Añadiendo «%s» sin direcciones para el par «%s»\n" | 7304 | msgstr "Añadiendo «%s» sin direcciones para el par «%s»\n" |
7309 | 7305 | ||
7310 | #: src/transport/gnunet-service-transport.c:2558 | 7306 | #: src/transport/gnunet-service-transport.c:2560 |
7311 | #, c-format | 7307 | #, c-format |
7312 | msgid "Adding blacklisting entry for peer `%s':`%s'\n" | 7308 | msgid "Adding blacklisting entry for peer `%s':`%s'\n" |
7313 | msgstr "" | 7309 | msgstr "" |
7314 | 7310 | ||
7311 | #: src/transport/gnunet-service-transport_ats.c:137 | ||
7312 | msgid "# Addresses given to ATS" | ||
7313 | msgstr "" | ||
7314 | |||
7315 | #: src/transport/gnunet-service-transport_hello.c:195 | 7315 | #: src/transport/gnunet-service-transport_hello.c:195 |
7316 | msgid "# refreshed my HELLO" | 7316 | msgid "# refreshed my HELLO" |
7317 | msgstr "# refrescos de mi «HELLO»" | 7317 | msgstr "# refrescos de mi «HELLO»" |
@@ -7653,6 +7653,45 @@ msgstr "# revalidaciones de direcciones iniciadas" | |||
7653 | msgid "# HELLOs given to peerinfo" | 7653 | msgid "# HELLOs given to peerinfo" |
7654 | msgstr "# «HELLO» obtenidos de «peerinfo»" | 7654 | msgstr "# «HELLO» obtenidos de «peerinfo»" |
7655 | 7655 | ||
7656 | #: src/transport/gnunet-transport-profiler.c:220 | ||
7657 | #, c-format | ||
7658 | msgid "%llu B in %llu ms == %.2f KB/s!\n" | ||
7659 | msgstr "" | ||
7660 | |||
7661 | #: src/transport/gnunet-transport-profiler.c:577 | ||
7662 | msgid "send data to peer" | ||
7663 | msgstr "" | ||
7664 | |||
7665 | #: src/transport/gnunet-transport-profiler.c:581 | ||
7666 | #, fuzzy | ||
7667 | msgid "receive data from peer" | ||
7668 | msgstr "# respuestas recibidas de otros pares" | ||
7669 | |||
7670 | #: src/transport/gnunet-transport-profiler.c:586 | ||
7671 | #, fuzzy | ||
7672 | msgid "iterations" | ||
7673 | msgstr "Otras configuraciones" | ||
7674 | |||
7675 | #: src/transport/gnunet-transport-profiler.c:591 | ||
7676 | #, fuzzy | ||
7677 | msgid "number of messages to send" | ||
7678 | msgstr "número de mensajes a usar por iteración" | ||
7679 | |||
7680 | #: src/transport/gnunet-transport-profiler.c:596 | ||
7681 | #, fuzzy | ||
7682 | msgid "message size to use" | ||
7683 | msgstr "tamaño del mensaje" | ||
7684 | |||
7685 | #: src/transport/gnunet-transport-profiler.c:601 | ||
7686 | #: src/transport/gnunet-transport.c:1404 | ||
7687 | msgid "peer identity" | ||
7688 | msgstr "identidad del par" | ||
7689 | |||
7690 | #: src/transport/gnunet-transport-profiler.c:614 | ||
7691 | #: src/transport/gnunet-transport.c:1426 | ||
7692 | msgid "Direct access to transport service." | ||
7693 | msgstr "Acceso directo al servicio de transporte." | ||
7694 | |||
7656 | #: src/transport/gnunet-transport.c:406 | 7695 | #: src/transport/gnunet-transport.c:406 |
7657 | #, c-format | 7696 | #, c-format |
7658 | msgid "Transmitted %llu bytes/s (%llu bytes in %s)\n" | 7697 | msgid "Transmitted %llu bytes/s (%llu bytes in %s)\n" |
@@ -7797,11 +7836,6 @@ msgstr "" | |||
7797 | msgid "do not resolve hostnames" | 7836 | msgid "do not resolve hostnames" |
7798 | msgstr "no resolver nombres de máquinas" | 7837 | msgstr "no resolver nombres de máquinas" |
7799 | 7838 | ||
7800 | #: src/transport/gnunet-transport.c:1404 | ||
7801 | #: src/transport/gnunet-transport-profiler.c:601 | ||
7802 | msgid "peer identity" | ||
7803 | msgstr "identidad del par" | ||
7804 | |||
7805 | #: src/transport/gnunet-transport.c:1408 | 7839 | #: src/transport/gnunet-transport.c:1408 |
7806 | #, fuzzy | 7840 | #, fuzzy |
7807 | msgid "monitor plugin sessions" | 7841 | msgid "monitor plugin sessions" |
@@ -7811,40 +7845,6 @@ msgstr "# sesiones wlan pendientes" | |||
7811 | msgid "send data for benchmarking to the other peer (until CTRL-C)" | 7845 | msgid "send data for benchmarking to the other peer (until CTRL-C)" |
7812 | msgstr "enviar data para prueba a otro par (hasta CTRL-C)" | 7846 | msgstr "enviar data para prueba a otro par (hasta CTRL-C)" |
7813 | 7847 | ||
7814 | #: src/transport/gnunet-transport.c:1426 | ||
7815 | #: src/transport/gnunet-transport-profiler.c:614 | ||
7816 | msgid "Direct access to transport service." | ||
7817 | msgstr "Acceso directo al servicio de transporte." | ||
7818 | |||
7819 | #: src/transport/gnunet-transport-profiler.c:220 | ||
7820 | #, c-format | ||
7821 | msgid "%llu B in %llu ms == %.2f KB/s!\n" | ||
7822 | msgstr "" | ||
7823 | |||
7824 | #: src/transport/gnunet-transport-profiler.c:577 | ||
7825 | msgid "send data to peer" | ||
7826 | msgstr "" | ||
7827 | |||
7828 | #: src/transport/gnunet-transport-profiler.c:581 | ||
7829 | #, fuzzy | ||
7830 | msgid "receive data from peer" | ||
7831 | msgstr "# respuestas recibidas de otros pares" | ||
7832 | |||
7833 | #: src/transport/gnunet-transport-profiler.c:586 | ||
7834 | #, fuzzy | ||
7835 | msgid "iterations" | ||
7836 | msgstr "Otras configuraciones" | ||
7837 | |||
7838 | #: src/transport/gnunet-transport-profiler.c:591 | ||
7839 | #, fuzzy | ||
7840 | msgid "number of messages to send" | ||
7841 | msgstr "número de mensajes a usar por iteración" | ||
7842 | |||
7843 | #: src/transport/gnunet-transport-profiler.c:596 | ||
7844 | #, fuzzy | ||
7845 | msgid "message size to use" | ||
7846 | msgstr "tamaño del mensaje" | ||
7847 | |||
7848 | #: src/transport/plugin_transport_http_client.c:1489 | 7848 | #: src/transport/plugin_transport_http_client.c:1489 |
7849 | #: src/transport/plugin_transport_http_server.c:2331 | 7849 | #: src/transport/plugin_transport_http_server.c:2331 |
7850 | #: src/transport/plugin_transport_http_server.c:3562 | 7850 | #: src/transport/plugin_transport_http_server.c:3562 |
@@ -8129,23 +8129,6 @@ msgstr "Transporte TCP no escuchando en ningún puerto (únicamente cliente)\n" | |||
8129 | msgid "TCP transport advertises itself as being on port %llu\n" | 8129 | msgid "TCP transport advertises itself as being on port %llu\n" |
8130 | msgstr "El transporte TCP anuncia que está en el puerto %llu\n" | 8130 | msgstr "El transporte TCP anuncia que está en el puerto %llu\n" |
8131 | 8131 | ||
8132 | #: src/transport/plugin_transport_udp_broadcasting.c:169 | ||
8133 | #, fuzzy | ||
8134 | msgid "# Multicast HELLO beacons received via UDP" | ||
8135 | msgstr "# beacons HELLO multicast IPv6 recibidos vía UDP" | ||
8136 | |||
8137 | #: src/transport/plugin_transport_udp_broadcasting.c:553 | ||
8138 | msgid "" | ||
8139 | "Disabling HELLO broadcasting due to friend-to-friend only configuration!\n" | ||
8140 | msgstr "" | ||
8141 | |||
8142 | #: src/transport/plugin_transport_udp_broadcasting.c:571 | ||
8143 | #, c-format | ||
8144 | msgid "Failed to set IPv4 broadcast option for broadcast socket on port %d\n" | ||
8145 | msgstr "" | ||
8146 | "Se produjo un fallo al establecer la opción de «broadcast» IPv4 para el " | ||
8147 | "«socket» en el puerto %d\n" | ||
8148 | |||
8149 | #: src/transport/plugin_transport_udp.c:3169 | 8132 | #: src/transport/plugin_transport_udp.c:3169 |
8150 | #, c-format | 8133 | #, c-format |
8151 | msgid "" | 8134 | msgid "" |
@@ -8200,6 +8183,23 @@ msgstr "«%s» no es una dirección IP válida.\n" | |||
8200 | msgid "Failed to create UDP network sockets\n" | 8183 | msgid "Failed to create UDP network sockets\n" |
8201 | msgstr "Se produjo un fallo al crear una nueva firma" | 8184 | msgstr "Se produjo un fallo al crear una nueva firma" |
8202 | 8185 | ||
8186 | #: src/transport/plugin_transport_udp_broadcasting.c:169 | ||
8187 | #, fuzzy | ||
8188 | msgid "# Multicast HELLO beacons received via UDP" | ||
8189 | msgstr "# beacons HELLO multicast IPv6 recibidos vía UDP" | ||
8190 | |||
8191 | #: src/transport/plugin_transport_udp_broadcasting.c:553 | ||
8192 | msgid "" | ||
8193 | "Disabling HELLO broadcasting due to friend-to-friend only configuration!\n" | ||
8194 | msgstr "" | ||
8195 | |||
8196 | #: src/transport/plugin_transport_udp_broadcasting.c:571 | ||
8197 | #, c-format | ||
8198 | msgid "Failed to set IPv4 broadcast option for broadcast socket on port %d\n" | ||
8199 | msgstr "" | ||
8200 | "Se produjo un fallo al establecer la opción de «broadcast» IPv4 para el " | ||
8201 | "«socket» en el puerto %d\n" | ||
8202 | |||
8203 | #: src/transport/plugin_transport_unix.c:1396 | 8203 | #: src/transport/plugin_transport_unix.c:1396 |
8204 | #, fuzzy, c-format | 8204 | #, fuzzy, c-format |
8205 | msgid "Cannot bind to `%s'\n" | 8205 | msgid "Cannot bind to `%s'\n" |
@@ -8390,7 +8390,7 @@ msgid "do daemonize (detach from terminal)" | |||
8390 | msgstr "demonizar (desasociar del terminal)" | 8390 | msgstr "demonizar (desasociar del terminal)" |
8391 | 8391 | ||
8392 | #: src/transport/tcp_service_legacy.c:1397 | 8392 | #: src/transport/tcp_service_legacy.c:1397 |
8393 | #: src/transport/transport-testing2.c:1116 src/util/service.c:2072 | 8393 | #: src/transport/transport-testing2.c:983 src/util/service.c:2072 |
8394 | #: src/util/service.c:2084 | 8394 | #: src/util/service.c:2084 |
8395 | #, fuzzy, c-format | 8395 | #, fuzzy, c-format |
8396 | msgid "Malformed configuration file `%s', exit ...\n" | 8396 | msgid "Malformed configuration file `%s', exit ...\n" |
@@ -9072,7 +9072,7 @@ msgstr "" | |||
9072 | "¡Error lógico interno fatal, el proceso está colgado en «%s» (abortar con " | 9072 | "¡Error lógico interno fatal, el proceso está colgado en «%s» (abortar con " |
9073 | "CTRL-C)!\n" | 9073 | "CTRL-C)!\n" |
9074 | 9074 | ||
9075 | #: src/util/os_installation.c:409 | 9075 | #: src/util/os_installation.c:411 |
9076 | #, c-format | 9076 | #, c-format |
9077 | msgid "" | 9077 | msgid "" |
9078 | "Could not determine installation path for %s. Set `%s' environment " | 9078 | "Could not determine installation path for %s. Set `%s' environment " |
@@ -9081,12 +9081,12 @@ msgstr "" | |||
9081 | "No se pudo determinar la ruta de instalación de %s. Establezca la variable " | 9081 | "No se pudo determinar la ruta de instalación de %s. Establezca la variable " |
9082 | "de entorno «%s».\n" | 9082 | "de entorno «%s».\n" |
9083 | 9083 | ||
9084 | #: src/util/os_installation.c:792 | 9084 | #: src/util/os_installation.c:794 |
9085 | #, c-format | 9085 | #, c-format |
9086 | msgid "Could not find binary `%s' in PATH!\n" | 9086 | msgid "Could not find binary `%s' in PATH!\n" |
9087 | msgstr "¡No se pudo encontrar el programa llamado «%s» en PATH!\n" | 9087 | msgstr "¡No se pudo encontrar el programa llamado «%s» en PATH!\n" |
9088 | 9088 | ||
9089 | #: src/util/os_installation.c:825 | 9089 | #: src/util/os_installation.c:827 |
9090 | #, c-format | 9090 | #, c-format |
9091 | msgid "Binary `%s' exists, but is not SUID\n" | 9091 | msgid "Binary `%s' exists, but is not SUID\n" |
9092 | msgstr "" | 9092 | msgstr "" |
@@ -9110,17 +9110,17 @@ msgstr "Falló «%s» para la biblioteca «%s» con error: %s\n" | |||
9110 | msgid "Could not determine plugin installation path.\n" | 9110 | msgid "Could not determine plugin installation path.\n" |
9111 | msgstr "No se pudo determinar la ruta de instalación de los módulos.\n" | 9111 | msgstr "No se pudo determinar la ruta de instalación de los módulos.\n" |
9112 | 9112 | ||
9113 | #: src/util/program.c:262 | 9113 | #: src/util/program.c:267 |
9114 | #, fuzzy, c-format | 9114 | #, fuzzy, c-format |
9115 | msgid "Unreadable or malformed configuration file `%s', exit ...\n" | 9115 | msgid "Unreadable or malformed configuration file `%s', exit ...\n" |
9116 | msgstr "Se produjo un fallo al borrar el fichero de configuración %s\n" | 9116 | msgstr "Se produjo un fallo al borrar el fichero de configuración %s\n" |
9117 | 9117 | ||
9118 | #: src/util/program.c:279 | 9118 | #: src/util/program.c:284 |
9119 | #, fuzzy, c-format | 9119 | #, fuzzy, c-format |
9120 | msgid "Unreadable or malformed default configuration file `%s', exit ...\n" | 9120 | msgid "Unreadable or malformed default configuration file `%s', exit ...\n" |
9121 | msgstr "Se produjo un fallo al borrar el fichero de configuración %s\n" | 9121 | msgstr "Se produjo un fallo al borrar el fichero de configuración %s\n" |
9122 | 9122 | ||
9123 | #: src/util/program.c:294 | 9123 | #: src/util/program.c:299 |
9124 | #, fuzzy | 9124 | #, fuzzy |
9125 | msgid "Unreadable or malformed configuration, exit ...\n" | 9125 | msgid "Unreadable or malformed configuration, exit ...\n" |
9126 | msgstr "Se produjo un fallo al borrar el fichero de configuración %s\n" | 9126 | msgstr "Se produjo un fallo al borrar el fichero de configuración %s\n" |
@@ -9194,10 +9194,6 @@ msgstr "" | |||
9194 | msgid "Attempting to proxy service `%s' to invalid port %d or hostname.\n" | 9194 | msgid "Attempting to proxy service `%s' to invalid port %d or hostname.\n" |
9195 | msgstr "" | 9195 | msgstr "" |
9196 | 9196 | ||
9197 | #: src/util/strings.c:179 | ||
9198 | msgid "b" | ||
9199 | msgstr "b" | ||
9200 | |||
9201 | #: src/util/strings.c:503 | 9197 | #: src/util/strings.c:503 |
9202 | #, c-format | 9198 | #, c-format |
9203 | msgid "Character sets requested were `%s'->`%s'\n" | 9199 | msgid "Character sets requested were `%s'->`%s'\n" |
@@ -9209,46 +9205,6 @@ msgstr "" | |||
9209 | "Se produjo un fallo al expandir «$HOME»: variable de entorno «HOME» no " | 9205 | "Se produjo un fallo al expandir «$HOME»: variable de entorno «HOME» no " |
9210 | "establecida" | 9206 | "establecida" |
9211 | 9207 | ||
9212 | #: src/util/strings.c:706 | ||
9213 | msgid "µs" | ||
9214 | msgstr "" | ||
9215 | |||
9216 | #: src/util/strings.c:710 | ||
9217 | msgid "forever" | ||
9218 | msgstr "para siempre" | ||
9219 | |||
9220 | #: src/util/strings.c:712 | ||
9221 | msgid "0 ms" | ||
9222 | msgstr "0 ms" | ||
9223 | |||
9224 | #: src/util/strings.c:716 | ||
9225 | msgid "ms" | ||
9226 | msgstr "ms" | ||
9227 | |||
9228 | #: src/util/strings.c:720 | ||
9229 | msgid "s" | ||
9230 | msgstr "s" | ||
9231 | |||
9232 | #: src/util/strings.c:724 | ||
9233 | msgid "m" | ||
9234 | msgstr "m" | ||
9235 | |||
9236 | #: src/util/strings.c:728 | ||
9237 | msgid "h" | ||
9238 | msgstr "h" | ||
9239 | |||
9240 | #: src/util/strings.c:734 | ||
9241 | msgid "day" | ||
9242 | msgstr "día" | ||
9243 | |||
9244 | #: src/util/strings.c:736 | ||
9245 | msgid "days" | ||
9246 | msgstr "días" | ||
9247 | |||
9248 | #: src/util/strings.c:764 | ||
9249 | msgid "end of time" | ||
9250 | msgstr "fin del plazo" | ||
9251 | |||
9252 | #: src/util/strings.c:1240 | 9208 | #: src/util/strings.c:1240 |
9253 | msgid "IPv6 address did not start with `['\n" | 9209 | msgid "IPv6 address did not start with `['\n" |
9254 | msgstr "La dirección IPv6 no empezaba con «[»\n" | 9210 | msgstr "La dirección IPv6 no empezaba con «[»\n" |
@@ -9503,11 +9459,41 @@ msgstr "el servicio es ofrecido vía UDP" | |||
9503 | msgid "Setup tunnels via VPN." | 9459 | msgid "Setup tunnels via VPN." |
9504 | msgstr "Configurar túneles vía VPN." | 9460 | msgstr "Configurar túneles vía VPN." |
9505 | 9461 | ||
9506 | #: src/zonemaster/gnunet-service-zonemaster.c:849 | ||
9507 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:420 | 9462 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:420 |
9463 | #: src/zonemaster/gnunet-service-zonemaster.c:849 | ||
9508 | msgid "Failed to connect to the namestore!\n" | 9464 | msgid "Failed to connect to the namestore!\n" |
9509 | msgstr "¡Se produjo un fallo al conectar con el almacén de nombres!\n" | 9465 | msgstr "¡Se produjo un fallo al conectar con el almacén de nombres!\n" |
9510 | 9466 | ||
9467 | #~ msgid "b" | ||
9468 | #~ msgstr "b" | ||
9469 | |||
9470 | #~ msgid "forever" | ||
9471 | #~ msgstr "para siempre" | ||
9472 | |||
9473 | #~ msgid "0 ms" | ||
9474 | #~ msgstr "0 ms" | ||
9475 | |||
9476 | #~ msgid "ms" | ||
9477 | #~ msgstr "ms" | ||
9478 | |||
9479 | #~ msgid "s" | ||
9480 | #~ msgstr "s" | ||
9481 | |||
9482 | #~ msgid "m" | ||
9483 | #~ msgstr "m" | ||
9484 | |||
9485 | #~ msgid "h" | ||
9486 | #~ msgstr "h" | ||
9487 | |||
9488 | #~ msgid "day" | ||
9489 | #~ msgstr "día" | ||
9490 | |||
9491 | #~ msgid "days" | ||
9492 | #~ msgstr "días" | ||
9493 | |||
9494 | #~ msgid "end of time" | ||
9495 | #~ msgstr "fin del plazo" | ||
9496 | |||
9511 | #, c-format | 9497 | #, c-format |
9512 | #~ msgid "Metadata `%s' failed to deserialize" | 9498 | #~ msgid "Metadata `%s' failed to deserialize" |
9513 | #~ msgstr "Se produjo un fallo al deserializar los metadatos «%s»" | 9499 | #~ msgstr "Se produjo un fallo al deserializar los metadatos «%s»" |
@@ -7,7 +7,7 @@ msgid "" | |||
7 | msgstr "" | 7 | msgstr "" |
8 | "Project-Id-Version: gnunet 0.10.1\n" | 8 | "Project-Id-Version: gnunet 0.10.1\n" |
9 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" | 9 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" |
10 | "POT-Creation-Date: 2020-09-06 10:07+0200\n" | 10 | "POT-Creation-Date: 2020-10-13 16:12+0200\n" |
11 | "PO-Revision-Date: 2015-12-24 01:20+0100\n" | 11 | "PO-Revision-Date: 2015-12-24 01:20+0100\n" |
12 | "Last-Translator: Stéphane Aulery <lkppo@free.fr>\n" | 12 | "Last-Translator: Stéphane Aulery <lkppo@free.fr>\n" |
13 | "Language-Team: French <traduc@traduc.org>\n" | 13 | "Language-Team: French <traduc@traduc.org>\n" |
@@ -27,8 +27,8 @@ msgid "Issuer public key `%s' is not well-formed\n" | |||
27 | msgstr "" | 27 | msgstr "" |
28 | 28 | ||
29 | #: src/abd/gnunet-abd.c:560 src/abd/gnunet-service-abd.c:1747 | 29 | #: src/abd/gnunet-abd.c:560 src/abd/gnunet-service-abd.c:1747 |
30 | #: src/namestore/gnunet-namestore.c:1001 | ||
31 | #: src/namestore/gnunet-namestore-fcfsd.c:1154 | 30 | #: src/namestore/gnunet-namestore-fcfsd.c:1154 |
31 | #: src/namestore/gnunet-namestore.c:1001 | ||
32 | #, c-format | 32 | #, c-format |
33 | msgid "Failed to connect to namestore\n" | 33 | msgid "Failed to connect to namestore\n" |
34 | msgstr "" | 34 | msgstr "" |
@@ -491,81 +491,14 @@ msgstr "" | |||
491 | msgid "Initiating shutdown as requested by client.\n" | 491 | msgid "Initiating shutdown as requested by client.\n" |
492 | msgstr "" | 492 | msgstr "" |
493 | 493 | ||
494 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | 494 | #: src/ats-tests/ats-testing-log.c:896 |
495 | #, c-format | 495 | msgid "Stop logging\n" |
496 | msgid "" | 496 | msgstr "Arrêter la journalisation\n" |
497 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | ||
498 | "%llu\n" | ||
499 | msgstr "" | ||
500 | |||
501 | #: src/ats/gnunet-ats-solver-eval.c:3011 | ||
502 | #, c-format | ||
503 | msgid "" | ||
504 | "No outbound quota configured for network `%s', assigning default bandwidth " | ||
505 | "%llu\n" | ||
506 | msgstr "" | ||
507 | |||
508 | #: src/ats/gnunet-ats-solver-eval.c:3063 | ||
509 | #, c-format | ||
510 | msgid "" | ||
511 | "No outbound quota configure for network `%s', assigning default bandwidth " | ||
512 | "%llu\n" | ||
513 | msgstr "" | ||
514 | |||
515 | #: src/ats/gnunet-ats-solver-eval.c:3552 src/ats-tests/gnunet-solver-eval.c:997 | ||
516 | msgid "solver to use" | ||
517 | msgstr "solveur utilisé" | ||
518 | |||
519 | #: src/ats/gnunet-ats-solver-eval.c:3557 | ||
520 | #: src/ats-tests/gnunet-solver-eval.c:1003 | ||
521 | #: src/ats-tests/gnunet-solver-eval.c:1008 | ||
522 | msgid "experiment to use" | ||
523 | msgstr "" | ||
524 | |||
525 | #: src/ats/gnunet-ats-solver-eval.c:3564 | ||
526 | msgid "print logging" | ||
527 | msgstr "afficher le journal" | ||
528 | |||
529 | #: src/ats/gnunet-ats-solver-eval.c:3569 | ||
530 | msgid "save logging to disk" | ||
531 | msgstr "" | ||
532 | |||
533 | #: src/ats/gnunet-ats-solver-eval.c:3574 | ||
534 | msgid "disable normalization" | ||
535 | msgstr "" | ||
536 | |||
537 | #: src/ats/gnunet-service-ats_plugins.c:326 | ||
538 | #, c-format | ||
539 | msgid "" | ||
540 | "Could not load %s quota for network `%s': `%s', assigning default bandwidth " | ||
541 | "%llu\n" | ||
542 | msgstr "" | ||
543 | |||
544 | #: src/ats/gnunet-service-ats_plugins.c:336 | ||
545 | #, c-format | ||
546 | msgid "%s quota configured for network `%s' is %llu\n" | ||
547 | msgstr "" | ||
548 | |||
549 | #: src/ats/gnunet-service-ats_plugins.c:382 | ||
550 | #, c-format | ||
551 | msgid "" | ||
552 | "No %s-quota configured for network `%s', assigning default bandwidth %llu\n" | ||
553 | msgstr "" | ||
554 | 497 | ||
555 | #: src/ats/gnunet-service-ats_plugins.c:474 | 498 | #: src/ats-tests/ats-testing-log.c:952 |
556 | #, c-format | 499 | #, c-format |
557 | msgid "Failed to initialize solver `%s'!\n" | 500 | msgid "Start logging `%s'\n" |
558 | msgstr "" | 501 | msgstr "Démarrer la journalisation « %s »\n" |
559 | |||
560 | #: src/ats/plugin_ats_proportional.c:1142 | ||
561 | #, fuzzy, c-format | ||
562 | msgid "Invalid %s configuration %f \n" | ||
563 | msgstr "fornat invalide : « %s »\n" | ||
564 | |||
565 | #: src/ats/plugin_ats_proportional.c:1165 | ||
566 | #, fuzzy, c-format | ||
567 | msgid "Invalid %s configuration %f\n" | ||
568 | msgstr "fornat invalide : « %s »\n" | ||
569 | 502 | ||
570 | #: src/ats-tests/ats-testing.c:420 | 503 | #: src/ats-tests/ats-testing.c:420 |
571 | #, c-format | 504 | #, c-format |
@@ -577,15 +510,6 @@ msgstr "" | |||
577 | msgid "Failed to connect master peer [%u] with slave [%u]\n" | 510 | msgid "Failed to connect master peer [%u] with slave [%u]\n" |
578 | msgstr "" | 511 | msgstr "" |
579 | 512 | ||
580 | #: src/ats-tests/ats-testing-log.c:896 | ||
581 | msgid "Stop logging\n" | ||
582 | msgstr "Arrêter la journalisation\n" | ||
583 | |||
584 | #: src/ats-tests/ats-testing-log.c:952 | ||
585 | #, c-format | ||
586 | msgid "Start logging `%s'\n" | ||
587 | msgstr "Démarrer la journalisation « %s »\n" | ||
588 | |||
589 | #: src/ats-tests/gnunet-ats-sim.c:92 | 513 | #: src/ats-tests/gnunet-ats-sim.c:92 |
590 | #, c-format | 514 | #, c-format |
591 | msgid "" | 515 | msgid "" |
@@ -593,6 +517,16 @@ msgid "" | |||
593 | "= %u KiB/s\n" | 517 | "= %u KiB/s\n" |
594 | msgstr "" | 518 | msgstr "" |
595 | 519 | ||
520 | #: src/ats-tests/gnunet-solver-eval.c:997 src/ats/gnunet-ats-solver-eval.c:3552 | ||
521 | msgid "solver to use" | ||
522 | msgstr "solveur utilisé" | ||
523 | |||
524 | #: src/ats-tests/gnunet-solver-eval.c:1003 | ||
525 | #: src/ats-tests/gnunet-solver-eval.c:1008 | ||
526 | #: src/ats/gnunet-ats-solver-eval.c:3557 | ||
527 | msgid "experiment to use" | ||
528 | msgstr "" | ||
529 | |||
596 | #: src/ats-tool/gnunet-ats.c:299 | 530 | #: src/ats-tool/gnunet-ats.c:299 |
597 | #, c-format | 531 | #, c-format |
598 | msgid "%u address resolutions had a timeout\n" | 532 | msgid "%u address resolutions had a timeout\n" |
@@ -708,6 +642,72 @@ msgstr "" | |||
708 | msgid "Print information about ATS state" | 642 | msgid "Print information about ATS state" |
709 | msgstr "" | 643 | msgstr "" |
710 | 644 | ||
645 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | ||
646 | #, c-format | ||
647 | msgid "" | ||
648 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | ||
649 | "%llu\n" | ||
650 | msgstr "" | ||
651 | |||
652 | #: src/ats/gnunet-ats-solver-eval.c:3011 | ||
653 | #, c-format | ||
654 | msgid "" | ||
655 | "No outbound quota configured for network `%s', assigning default bandwidth " | ||
656 | "%llu\n" | ||
657 | msgstr "" | ||
658 | |||
659 | #: src/ats/gnunet-ats-solver-eval.c:3063 | ||
660 | #, c-format | ||
661 | msgid "" | ||
662 | "No outbound quota configure for network `%s', assigning default bandwidth " | ||
663 | "%llu\n" | ||
664 | msgstr "" | ||
665 | |||
666 | #: src/ats/gnunet-ats-solver-eval.c:3564 | ||
667 | msgid "print logging" | ||
668 | msgstr "afficher le journal" | ||
669 | |||
670 | #: src/ats/gnunet-ats-solver-eval.c:3569 | ||
671 | msgid "save logging to disk" | ||
672 | msgstr "" | ||
673 | |||
674 | #: src/ats/gnunet-ats-solver-eval.c:3574 | ||
675 | msgid "disable normalization" | ||
676 | msgstr "" | ||
677 | |||
678 | #: src/ats/gnunet-service-ats_plugins.c:326 | ||
679 | #, c-format | ||
680 | msgid "" | ||
681 | "Could not load %s quota for network `%s': `%s', assigning default bandwidth " | ||
682 | "%llu\n" | ||
683 | msgstr "" | ||
684 | |||
685 | #: src/ats/gnunet-service-ats_plugins.c:336 | ||
686 | #, c-format | ||
687 | msgid "%s quota configured for network `%s' is %llu\n" | ||
688 | msgstr "" | ||
689 | |||
690 | #: src/ats/gnunet-service-ats_plugins.c:382 | ||
691 | #, c-format | ||
692 | msgid "" | ||
693 | "No %s-quota configured for network `%s', assigning default bandwidth %llu\n" | ||
694 | msgstr "" | ||
695 | |||
696 | #: src/ats/gnunet-service-ats_plugins.c:474 | ||
697 | #, c-format | ||
698 | msgid "Failed to initialize solver `%s'!\n" | ||
699 | msgstr "" | ||
700 | |||
701 | #: src/ats/plugin_ats_proportional.c:1142 | ||
702 | #, fuzzy, c-format | ||
703 | msgid "Invalid %s configuration %f \n" | ||
704 | msgstr "fornat invalide : « %s »\n" | ||
705 | |||
706 | #: src/ats/plugin_ats_proportional.c:1165 | ||
707 | #, fuzzy, c-format | ||
708 | msgid "Invalid %s configuration %f\n" | ||
709 | msgstr "fornat invalide : « %s »\n" | ||
710 | |||
711 | #: src/auction/gnunet-auction-create.c:163 | 711 | #: src/auction/gnunet-auction-create.c:163 |
712 | msgid "description of the item to be sold" | 712 | msgid "description of the item to be sold" |
713 | msgstr "" | 713 | msgstr "" |
@@ -838,6 +838,28 @@ msgstr "" | |||
838 | msgid "Connection to conversation service lost, trying to reconnect\n" | 838 | msgid "Connection to conversation service lost, trying to reconnect\n" |
839 | msgstr "" | 839 | msgstr "" |
840 | 840 | ||
841 | #: src/conversation/gnunet-conversation-test.c:120 | ||
842 | #, c-format | ||
843 | msgid "" | ||
844 | "\n" | ||
845 | "End of transmission. Have a GNU day.\n" | ||
846 | msgstr "" | ||
847 | |||
848 | #: src/conversation/gnunet-conversation-test.c:146 | ||
849 | #, c-format | ||
850 | msgid "" | ||
851 | "\n" | ||
852 | "We are now playing your recording back. If you can hear it, your audio " | ||
853 | "settings are working..." | ||
854 | msgstr "" | ||
855 | |||
856 | #: src/conversation/gnunet-conversation-test.c:218 | ||
857 | #, c-format | ||
858 | msgid "" | ||
859 | "We will now be recording you for %s. After that time, the recording will be " | ||
860 | "played back to you..." | ||
861 | msgstr "" | ||
862 | |||
841 | #: src/conversation/gnunet-conversation.c:264 | 863 | #: src/conversation/gnunet-conversation.c:264 |
842 | #, c-format | 864 | #, c-format |
843 | msgid "Incoming call from `%s'. Please /accept %u or /cancel %u the call.\n" | 865 | msgid "Incoming call from `%s'. Please /accept %u or /cancel %u the call.\n" |
@@ -1094,30 +1116,8 @@ msgstr "" | |||
1094 | msgid "Enables having a conversation with other GNUnet users." | 1116 | msgid "Enables having a conversation with other GNUnet users." |
1095 | msgstr "" | 1117 | msgstr "" |
1096 | 1118 | ||
1097 | #: src/conversation/gnunet-conversation-test.c:120 | ||
1098 | #, c-format | ||
1099 | msgid "" | ||
1100 | "\n" | ||
1101 | "End of transmission. Have a GNU day.\n" | ||
1102 | msgstr "" | ||
1103 | |||
1104 | #: src/conversation/gnunet-conversation-test.c:146 | ||
1105 | #, c-format | ||
1106 | msgid "" | ||
1107 | "\n" | ||
1108 | "We are now playing your recording back. If you can hear it, your audio " | ||
1109 | "settings are working..." | ||
1110 | msgstr "" | ||
1111 | |||
1112 | #: src/conversation/gnunet-conversation-test.c:218 | ||
1113 | #, c-format | ||
1114 | msgid "" | ||
1115 | "We will now be recording you for %s. After that time, the recording will be " | ||
1116 | "played back to you..." | ||
1117 | msgstr "" | ||
1118 | |||
1119 | #: src/conversation/gnunet_gst.c:664 | ||
1120 | #: src/conversation/gnunet-helper-audio-playback-gst.c:363 | 1119 | #: src/conversation/gnunet-helper-audio-playback-gst.c:363 |
1120 | #: src/conversation/gnunet_gst.c:664 | ||
1121 | #, c-format | 1121 | #, c-format |
1122 | msgid "Read error from STDIN: %d %s\n" | 1122 | msgid "Read error from STDIN: %d %s\n" |
1123 | msgstr "" | 1123 | msgstr "" |
@@ -1880,16 +1880,16 @@ msgstr "" | |||
1880 | msgid "Mysql database running\n" | 1880 | msgid "Mysql database running\n" |
1881 | msgstr "" | 1881 | msgstr "" |
1882 | 1882 | ||
1883 | #: src/datastore/plugin_datastore_postgres.c:278 | 1883 | #: src/datastore/plugin_datastore_postgres.c:284 |
1884 | #: src/datastore/plugin_datastore_postgres.c:891 | 1884 | #: src/datastore/plugin_datastore_postgres.c:897 |
1885 | msgid "Postgress exec failure" | 1885 | msgid "Postgress exec failure" |
1886 | msgstr "" | 1886 | msgstr "" |
1887 | 1887 | ||
1888 | #: src/datastore/plugin_datastore_postgres.c:852 | 1888 | #: src/datastore/plugin_datastore_postgres.c:858 |
1889 | msgid "Failed to drop table from database.\n" | 1889 | msgid "Failed to drop table from database.\n" |
1890 | msgstr "" | 1890 | msgstr "" |
1891 | 1891 | ||
1892 | #: src/datastore/plugin_datastore_postgres.c:950 | 1892 | #: src/datastore/plugin_datastore_postgres.c:956 |
1893 | msgid "Postgres database running\n" | 1893 | msgid "Postgres database running\n" |
1894 | msgstr "" | 1894 | msgstr "" |
1895 | 1895 | ||
@@ -2000,53 +2000,6 @@ msgstr "" | |||
2000 | msgid "Prints all packets that go through the DHT." | 2000 | msgid "Prints all packets that go through the DHT." |
2001 | msgstr "" | 2001 | msgstr "" |
2002 | 2002 | ||
2003 | #: src/dht/gnunet_dht_profiler.c:922 src/testbed/gnunet-testbed-profiler.c:255 | ||
2004 | #, c-format | ||
2005 | msgid "Exiting as the number of peers is %u\n" | ||
2006 | msgstr "" | ||
2007 | |||
2008 | #: src/dht/gnunet_dht_profiler.c:955 src/rps/gnunet-rps-profiler.c:3194 | ||
2009 | #, fuzzy | ||
2010 | msgid "number of peers to start" | ||
2011 | msgstr "nombre de valeurs" | ||
2012 | |||
2013 | #: src/dht/gnunet_dht_profiler.c:961 | ||
2014 | msgid "number of PUTs to perform per peer" | ||
2015 | msgstr "" | ||
2016 | |||
2017 | #: src/dht/gnunet_dht_profiler.c:967 src/nse/gnunet-nse-profiler.c:872 | ||
2018 | #: src/testbed/gnunet-testbed-profiler.c:305 | ||
2019 | msgid "name of the file with the login information for the testbed" | ||
2020 | msgstr "" | ||
2021 | |||
2022 | #: src/dht/gnunet_dht_profiler.c:973 | ||
2023 | msgid "delay between rounds for collecting statistics (default: 30 sec)" | ||
2024 | msgstr "" | ||
2025 | |||
2026 | #: src/dht/gnunet_dht_profiler.c:979 | ||
2027 | msgid "delay to start doing PUTs (default: 1 sec)" | ||
2028 | msgstr "" | ||
2029 | |||
2030 | #: src/dht/gnunet_dht_profiler.c:985 | ||
2031 | msgid "delay to start doing GETs (default: 5 min)" | ||
2032 | msgstr "" | ||
2033 | |||
2034 | #: src/dht/gnunet_dht_profiler.c:990 | ||
2035 | msgid "replication degree for DHT PUTs" | ||
2036 | msgstr "" | ||
2037 | |||
2038 | #: src/dht/gnunet_dht_profiler.c:996 | ||
2039 | msgid "chance that a peer is selected at random for PUTs" | ||
2040 | msgstr "" | ||
2041 | |||
2042 | #: src/dht/gnunet_dht_profiler.c:1002 | ||
2043 | msgid "timeout for DHT PUT and GET requests (default: 1 min)" | ||
2044 | msgstr "" | ||
2045 | |||
2046 | #: src/dht/gnunet_dht_profiler.c:1023 | ||
2047 | msgid "Measure quality and performance of the DHT service." | ||
2048 | msgstr "" | ||
2049 | |||
2050 | #: src/dht/gnunet-dht-put.c:133 | 2003 | #: src/dht/gnunet-dht-put.c:133 |
2051 | msgid "Must provide KEY and DATA for DHT put!\n" | 2004 | msgid "Must provide KEY and DATA for DHT put!\n" |
2052 | msgstr "" | 2005 | msgstr "" |
@@ -2292,6 +2245,53 @@ msgstr "" | |||
2292 | msgid "# DHT requests combined" | 2245 | msgid "# DHT requests combined" |
2293 | msgstr "" | 2246 | msgstr "" |
2294 | 2247 | ||
2248 | #: src/dht/gnunet_dht_profiler.c:922 src/testbed/gnunet-testbed-profiler.c:255 | ||
2249 | #, c-format | ||
2250 | msgid "Exiting as the number of peers is %u\n" | ||
2251 | msgstr "" | ||
2252 | |||
2253 | #: src/dht/gnunet_dht_profiler.c:955 src/rps/gnunet-rps-profiler.c:3194 | ||
2254 | #, fuzzy | ||
2255 | msgid "number of peers to start" | ||
2256 | msgstr "nombre de valeurs" | ||
2257 | |||
2258 | #: src/dht/gnunet_dht_profiler.c:961 | ||
2259 | msgid "number of PUTs to perform per peer" | ||
2260 | msgstr "" | ||
2261 | |||
2262 | #: src/dht/gnunet_dht_profiler.c:967 src/nse/gnunet-nse-profiler.c:872 | ||
2263 | #: src/testbed/gnunet-testbed-profiler.c:305 | ||
2264 | msgid "name of the file with the login information for the testbed" | ||
2265 | msgstr "" | ||
2266 | |||
2267 | #: src/dht/gnunet_dht_profiler.c:973 | ||
2268 | msgid "delay between rounds for collecting statistics (default: 30 sec)" | ||
2269 | msgstr "" | ||
2270 | |||
2271 | #: src/dht/gnunet_dht_profiler.c:979 | ||
2272 | msgid "delay to start doing PUTs (default: 1 sec)" | ||
2273 | msgstr "" | ||
2274 | |||
2275 | #: src/dht/gnunet_dht_profiler.c:985 | ||
2276 | msgid "delay to start doing GETs (default: 5 min)" | ||
2277 | msgstr "" | ||
2278 | |||
2279 | #: src/dht/gnunet_dht_profiler.c:990 | ||
2280 | msgid "replication degree for DHT PUTs" | ||
2281 | msgstr "" | ||
2282 | |||
2283 | #: src/dht/gnunet_dht_profiler.c:996 | ||
2284 | msgid "chance that a peer is selected at random for PUTs" | ||
2285 | msgstr "" | ||
2286 | |||
2287 | #: src/dht/gnunet_dht_profiler.c:1002 | ||
2288 | msgid "timeout for DHT PUT and GET requests (default: 1 min)" | ||
2289 | msgstr "" | ||
2290 | |||
2291 | #: src/dht/gnunet_dht_profiler.c:1023 | ||
2292 | msgid "Measure quality and performance of the DHT service." | ||
2293 | msgstr "" | ||
2294 | |||
2295 | #: src/dht/plugin_block_dht.c:189 | 2295 | #: src/dht/plugin_block_dht.c:189 |
2296 | #, c-format | 2296 | #, c-format |
2297 | msgid "Block not of type %u\n" | 2297 | msgid "Block not of type %u\n" |
@@ -3191,14 +3191,6 @@ msgid "" | |||
3191 | "chk/...)" | 3191 | "chk/...)" |
3192 | msgstr "" | 3192 | msgstr "" |
3193 | 3193 | ||
3194 | #: src/fs/gnunet-fs.c:128 | ||
3195 | msgid "print a list of all indexed files" | ||
3196 | msgstr "" | ||
3197 | |||
3198 | #: src/fs/gnunet-fs.c:141 | ||
3199 | msgid "Special file-sharing operations" | ||
3200 | msgstr "" | ||
3201 | |||
3202 | #: src/fs/gnunet-fs-profiler.c:211 | 3194 | #: src/fs/gnunet-fs-profiler.c:211 |
3203 | msgid "run the experiment with COUNT peers" | 3195 | msgid "run the experiment with COUNT peers" |
3204 | msgstr "" | 3196 | msgstr "" |
@@ -3215,6 +3207,14 @@ msgstr "" | |||
3215 | msgid "run a testbed to measure file-sharing performance" | 3207 | msgid "run a testbed to measure file-sharing performance" |
3216 | msgstr "" | 3208 | msgstr "" |
3217 | 3209 | ||
3210 | #: src/fs/gnunet-fs.c:128 | ||
3211 | msgid "print a list of all indexed files" | ||
3212 | msgstr "" | ||
3213 | |||
3214 | #: src/fs/gnunet-fs.c:141 | ||
3215 | msgid "Special file-sharing operations" | ||
3216 | msgstr "" | ||
3217 | |||
3218 | #: src/fs/gnunet-publish.c:219 src/fs/gnunet-publish.c:234 | 3218 | #: src/fs/gnunet-publish.c:219 src/fs/gnunet-publish.c:234 |
3219 | #, c-format | 3219 | #, c-format |
3220 | msgid "Publishing `%s' at %llu/%llu (%s remaining)\n" | 3220 | msgid "Publishing `%s' at %llu/%llu (%s remaining)\n" |
@@ -3860,49 +3860,6 @@ msgstr "" | |||
3860 | msgid "look for GNS2DNS records instead of ANY" | 3860 | msgid "look for GNS2DNS records instead of ANY" |
3861 | msgstr "" | 3861 | msgstr "" |
3862 | 3862 | ||
3863 | #: src/gns/gnunet-gns.c:257 | ||
3864 | #, c-format | ||
3865 | msgid "`%s' is not a valid DNS domain name\n" | ||
3866 | msgstr "" | ||
3867 | |||
3868 | #: src/gns/gnunet-gns.c:267 src/util/dnsparser.c:254 | ||
3869 | #, c-format | ||
3870 | msgid "Failed to convert DNS IDNA name `%s' to UTF-8: %s\n" | ||
3871 | msgstr "" | ||
3872 | |||
3873 | #: src/gns/gnunet-gns.c:281 | ||
3874 | msgid "Cannot resolve using GNS: GNUnet peer not running\n" | ||
3875 | msgstr "" | ||
3876 | |||
3877 | #: src/gns/gnunet-gns.c:305 | ||
3878 | #, c-format | ||
3879 | msgid "Invalid typename specified, assuming `ANY'\n" | ||
3880 | msgstr "" | ||
3881 | |||
3882 | #: src/gns/gnunet-gns.c:340 | ||
3883 | msgid "Lookup a record for the given name" | ||
3884 | msgstr "" | ||
3885 | |||
3886 | #: src/gns/gnunet-gns.c:346 | ||
3887 | msgid "Specify the type of the record to lookup" | ||
3888 | msgstr "" | ||
3889 | |||
3890 | #: src/gns/gnunet-gns.c:352 | ||
3891 | msgid "Specify a timeout for the lookup" | ||
3892 | msgstr "" | ||
3893 | |||
3894 | #: src/gns/gnunet-gns.c:356 | ||
3895 | msgid "No unneeded output" | ||
3896 | msgstr "" | ||
3897 | |||
3898 | #: src/gns/gnunet-gns.c:361 | ||
3899 | msgid "DNS Compatibility: Name is passed in IDNA instead of UTF-8" | ||
3900 | msgstr "" | ||
3901 | |||
3902 | #: src/gns/gnunet-gns.c:375 | ||
3903 | msgid "GNUnet GNS resolver tool" | ||
3904 | msgstr "" | ||
3905 | |||
3906 | #: src/gns/gnunet-gns-import.c:486 | 3863 | #: src/gns/gnunet-gns-import.c:486 |
3907 | msgid "This program will import some GNS authorities into your GNS namestore." | 3864 | msgid "This program will import some GNS authorities into your GNS namestore." |
3908 | msgstr "" | 3865 | msgstr "" |
@@ -4022,6 +3979,49 @@ msgstr "" | |||
4022 | msgid "GNUnet GNS proxy" | 3979 | msgid "GNUnet GNS proxy" |
4023 | msgstr "" | 3980 | msgstr "" |
4024 | 3981 | ||
3982 | #: src/gns/gnunet-gns.c:257 | ||
3983 | #, c-format | ||
3984 | msgid "`%s' is not a valid DNS domain name\n" | ||
3985 | msgstr "" | ||
3986 | |||
3987 | #: src/gns/gnunet-gns.c:267 src/util/dnsparser.c:254 | ||
3988 | #, c-format | ||
3989 | msgid "Failed to convert DNS IDNA name `%s' to UTF-8: %s\n" | ||
3990 | msgstr "" | ||
3991 | |||
3992 | #: src/gns/gnunet-gns.c:281 | ||
3993 | msgid "Cannot resolve using GNS: GNUnet peer not running\n" | ||
3994 | msgstr "" | ||
3995 | |||
3996 | #: src/gns/gnunet-gns.c:305 | ||
3997 | #, c-format | ||
3998 | msgid "Invalid typename specified, assuming `ANY'\n" | ||
3999 | msgstr "" | ||
4000 | |||
4001 | #: src/gns/gnunet-gns.c:340 | ||
4002 | msgid "Lookup a record for the given name" | ||
4003 | msgstr "" | ||
4004 | |||
4005 | #: src/gns/gnunet-gns.c:346 | ||
4006 | msgid "Specify the type of the record to lookup" | ||
4007 | msgstr "" | ||
4008 | |||
4009 | #: src/gns/gnunet-gns.c:352 | ||
4010 | msgid "Specify a timeout for the lookup" | ||
4011 | msgstr "" | ||
4012 | |||
4013 | #: src/gns/gnunet-gns.c:356 | ||
4014 | msgid "No unneeded output" | ||
4015 | msgstr "" | ||
4016 | |||
4017 | #: src/gns/gnunet-gns.c:361 | ||
4018 | msgid "DNS Compatibility: Name is passed in IDNA instead of UTF-8" | ||
4019 | msgstr "" | ||
4020 | |||
4021 | #: src/gns/gnunet-gns.c:375 | ||
4022 | msgid "GNUnet GNS resolver tool" | ||
4023 | msgstr "" | ||
4024 | |||
4025 | #: src/gns/gnunet-service-gns.c:505 | 4025 | #: src/gns/gnunet-service-gns.c:505 |
4026 | msgid "Properly base32-encoded public key required" | 4026 | msgid "Properly base32-encoded public key required" |
4027 | msgstr "" | 4027 | msgstr "" |
@@ -4031,8 +4031,8 @@ msgid "Failed to connect to the namecache!\n" | |||
4031 | msgstr "" | 4031 | msgstr "" |
4032 | 4032 | ||
4033 | #: src/gns/gnunet-service-gns.c:560 | 4033 | #: src/gns/gnunet-service-gns.c:560 |
4034 | #: src/zonemaster/gnunet-service-zonemaster.c:887 | ||
4035 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:444 | 4034 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:444 |
4035 | #: src/zonemaster/gnunet-service-zonemaster.c:887 | ||
4036 | msgid "Could not connect to DHT!\n" | 4036 | msgid "Could not connect to DHT!\n" |
4037 | msgstr "" | 4037 | msgstr "" |
4038 | 4038 | ||
@@ -4518,7 +4518,7 @@ msgid "# hostlist advertisements send" | |||
4518 | msgstr "" | 4518 | msgstr "" |
4519 | 4519 | ||
4520 | #: src/hostlist/gnunet-daemon-hostlist_server.c:674 | 4520 | #: src/hostlist/gnunet-daemon-hostlist_server.c:674 |
4521 | #: src/transport/gnunet-service-transport.c:2659 | 4521 | #: src/transport/gnunet-service-transport.c:2661 |
4522 | msgid "Could not access PEERINFO service. Exiting.\n" | 4522 | msgid "Could not access PEERINFO service. Exiting.\n" |
4523 | msgstr "" | 4523 | msgstr "" |
4524 | 4524 | ||
@@ -4766,6 +4766,68 @@ msgstr "" | |||
4766 | msgid "Failed to setup database at `%s'\n" | 4766 | msgid "Failed to setup database at `%s'\n" |
4767 | msgstr "Échec du démarrage de %s\n" | 4767 | msgstr "Échec du démarrage de %s\n" |
4768 | 4768 | ||
4769 | #: src/namestore/gnunet-namestore-fcfsd.c:552 | ||
4770 | #, c-format | ||
4771 | msgid "Unsupported form value `%s'\n" | ||
4772 | msgstr "" | ||
4773 | |||
4774 | #: src/namestore/gnunet-namestore-fcfsd.c:579 | ||
4775 | #, c-format | ||
4776 | msgid "Failed to create record for domain `%s': %s\n" | ||
4777 | msgstr "" | ||
4778 | |||
4779 | #: src/namestore/gnunet-namestore-fcfsd.c:600 | ||
4780 | msgid "Error when mapping zone to name\n" | ||
4781 | msgstr "" | ||
4782 | |||
4783 | #: src/namestore/gnunet-namestore-fcfsd.c:632 | ||
4784 | #, c-format | ||
4785 | msgid "Found existing name `%s' for the given key\n" | ||
4786 | msgstr "" | ||
4787 | |||
4788 | #: src/namestore/gnunet-namestore-fcfsd.c:694 | ||
4789 | #, c-format | ||
4790 | msgid "Found %u existing records for domain `%s'\n" | ||
4791 | msgstr "" | ||
4792 | |||
4793 | #: src/namestore/gnunet-namestore-fcfsd.c:784 | ||
4794 | #, c-format | ||
4795 | msgid "Failed to create page for `%s'\n" | ||
4796 | msgstr "" | ||
4797 | |||
4798 | #: src/namestore/gnunet-namestore-fcfsd.c:803 | ||
4799 | #, c-format | ||
4800 | msgid "Failed to setup post processor for `%s'\n" | ||
4801 | msgstr "" | ||
4802 | |||
4803 | #: src/namestore/gnunet-namestore-fcfsd.c:840 | ||
4804 | msgid "Domain name must not contain `.'\n" | ||
4805 | msgstr "" | ||
4806 | |||
4807 | #: src/namestore/gnunet-namestore-fcfsd.c:849 | ||
4808 | msgid "Domain name must not contain `+'\n" | ||
4809 | msgstr "" | ||
4810 | |||
4811 | #: src/namestore/gnunet-namestore-fcfsd.c:1084 | ||
4812 | msgid "No ego configured for `fcfsd` subsystem\n" | ||
4813 | msgstr "" | ||
4814 | |||
4815 | #: src/namestore/gnunet-namestore-fcfsd.c:1115 | ||
4816 | msgid "Failed to start HTTP server\n" | ||
4817 | msgstr "" | ||
4818 | |||
4819 | #: src/namestore/gnunet-namestore-fcfsd.c:1163 | ||
4820 | msgid "Failed to connect to identity\n" | ||
4821 | msgstr "" | ||
4822 | |||
4823 | #: src/namestore/gnunet-namestore-fcfsd.c:1190 | ||
4824 | msgid "name of the zone that is to be managed by FCFSD" | ||
4825 | msgstr "" | ||
4826 | |||
4827 | #: src/namestore/gnunet-namestore-fcfsd.c:1210 | ||
4828 | msgid "GNU Name System First Come First Serve name registration service" | ||
4829 | msgstr "" | ||
4830 | |||
4769 | #: src/namestore/gnunet-namestore.c:334 | 4831 | #: src/namestore/gnunet-namestore.c:334 |
4770 | #, c-format | 4832 | #, c-format |
4771 | msgid "Adding record failed: %s\n" | 4833 | msgid "Adding record failed: %s\n" |
@@ -4992,68 +5054,6 @@ msgstr "" | |||
4992 | msgid "name of the ego controlling the zone" | 5054 | msgid "name of the ego controlling the zone" |
4993 | msgstr "" | 5055 | msgstr "" |
4994 | 5056 | ||
4995 | #: src/namestore/gnunet-namestore-fcfsd.c:552 | ||
4996 | #, c-format | ||
4997 | msgid "Unsupported form value `%s'\n" | ||
4998 | msgstr "" | ||
4999 | |||
5000 | #: src/namestore/gnunet-namestore-fcfsd.c:579 | ||
5001 | #, c-format | ||
5002 | msgid "Failed to create record for domain `%s': %s\n" | ||
5003 | msgstr "" | ||
5004 | |||
5005 | #: src/namestore/gnunet-namestore-fcfsd.c:600 | ||
5006 | msgid "Error when mapping zone to name\n" | ||
5007 | msgstr "" | ||
5008 | |||
5009 | #: src/namestore/gnunet-namestore-fcfsd.c:632 | ||
5010 | #, c-format | ||
5011 | msgid "Found existing name `%s' for the given key\n" | ||
5012 | msgstr "" | ||
5013 | |||
5014 | #: src/namestore/gnunet-namestore-fcfsd.c:694 | ||
5015 | #, c-format | ||
5016 | msgid "Found %u existing records for domain `%s'\n" | ||
5017 | msgstr "" | ||
5018 | |||
5019 | #: src/namestore/gnunet-namestore-fcfsd.c:784 | ||
5020 | #, c-format | ||
5021 | msgid "Failed to create page for `%s'\n" | ||
5022 | msgstr "" | ||
5023 | |||
5024 | #: src/namestore/gnunet-namestore-fcfsd.c:803 | ||
5025 | #, c-format | ||
5026 | msgid "Failed to setup post processor for `%s'\n" | ||
5027 | msgstr "" | ||
5028 | |||
5029 | #: src/namestore/gnunet-namestore-fcfsd.c:840 | ||
5030 | msgid "Domain name must not contain `.'\n" | ||
5031 | msgstr "" | ||
5032 | |||
5033 | #: src/namestore/gnunet-namestore-fcfsd.c:849 | ||
5034 | msgid "Domain name must not contain `+'\n" | ||
5035 | msgstr "" | ||
5036 | |||
5037 | #: src/namestore/gnunet-namestore-fcfsd.c:1084 | ||
5038 | msgid "No ego configured for `fcfsd` subsystem\n" | ||
5039 | msgstr "" | ||
5040 | |||
5041 | #: src/namestore/gnunet-namestore-fcfsd.c:1115 | ||
5042 | msgid "Failed to start HTTP server\n" | ||
5043 | msgstr "" | ||
5044 | |||
5045 | #: src/namestore/gnunet-namestore-fcfsd.c:1163 | ||
5046 | msgid "Failed to connect to identity\n" | ||
5047 | msgstr "" | ||
5048 | |||
5049 | #: src/namestore/gnunet-namestore-fcfsd.c:1190 | ||
5050 | msgid "name of the zone that is to be managed by FCFSD" | ||
5051 | msgstr "" | ||
5052 | |||
5053 | #: src/namestore/gnunet-namestore-fcfsd.c:1210 | ||
5054 | msgid "GNU Name System First Come First Serve name registration service" | ||
5055 | msgstr "" | ||
5056 | |||
5057 | #: src/namestore/gnunet-service-namestore.c:866 | 5057 | #: src/namestore/gnunet-service-namestore.c:866 |
5058 | #, c-format | 5058 | #, c-format |
5059 | msgid "Failed to replicate block in namecache: %s\n" | 5059 | msgid "Failed to replicate block in namecache: %s\n" |
@@ -5360,10 +5360,6 @@ msgstr "" | |||
5360 | msgid "`upnpc' command not found\n" | 5360 | msgid "`upnpc' command not found\n" |
5361 | msgstr "" | 5361 | msgstr "" |
5362 | 5362 | ||
5363 | #: src/nse/gnunet-nse.c:124 | ||
5364 | msgid "Show network size estimates from NSE service." | ||
5365 | msgstr "" | ||
5366 | |||
5367 | #: src/nse/gnunet-nse-profiler.c:857 | 5363 | #: src/nse/gnunet-nse-profiler.c:857 |
5368 | msgid "limit to the number of connections to NSE services, 0 for none" | 5364 | msgid "limit to the number of connections to NSE services, 0 for none" |
5369 | msgstr "" | 5365 | msgstr "" |
@@ -5388,65 +5384,15 @@ msgstr "" | |||
5388 | msgid "Measure quality and performance of the NSE service." | 5384 | msgid "Measure quality and performance of the NSE service." |
5389 | msgstr "" | 5385 | msgstr "" |
5390 | 5386 | ||
5387 | #: src/nse/gnunet-nse.c:124 | ||
5388 | msgid "Show network size estimates from NSE service." | ||
5389 | msgstr "" | ||
5390 | |||
5391 | #: src/nse/gnunet-service-nse.c:1443 | 5391 | #: src/nse/gnunet-service-nse.c:1443 |
5392 | #: src/revocation/gnunet-service-revocation.c:834 src/util/gnunet-scrypt.c:257 | 5392 | #: src/revocation/gnunet-service-revocation.c:834 src/util/gnunet-scrypt.c:257 |
5393 | msgid "Value is too large.\n" | 5393 | msgid "Value is too large.\n" |
5394 | msgstr "" | 5394 | msgstr "" |
5395 | 5395 | ||
5396 | #: src/peerinfo/gnunet-service-peerinfo.c:175 | ||
5397 | #, c-format | ||
5398 | msgid "Removing expired address of transport `%s'\n" | ||
5399 | msgstr "" | ||
5400 | |||
5401 | #: src/peerinfo/gnunet-service-peerinfo.c:306 | ||
5402 | #, c-format | ||
5403 | msgid "Failed to parse HELLO in file `%s': %s\n" | ||
5404 | msgstr "" | ||
5405 | |||
5406 | #: src/peerinfo/gnunet-service-peerinfo.c:323 | ||
5407 | #: src/peerinfo/gnunet-service-peerinfo.c:348 | ||
5408 | #, c-format | ||
5409 | msgid "Failed to parse HELLO in file `%s'\n" | ||
5410 | msgstr "" | ||
5411 | |||
5412 | #: src/peerinfo/gnunet-service-peerinfo.c:426 | ||
5413 | msgid "# peers known" | ||
5414 | msgstr "" | ||
5415 | |||
5416 | #: src/peerinfo/gnunet-service-peerinfo.c:468 | ||
5417 | #, c-format | ||
5418 | msgid "" | ||
5419 | "File `%s' in directory `%s' does not match naming convention. Removed.\n" | ||
5420 | msgstr "" | ||
5421 | |||
5422 | #: src/peerinfo/gnunet-service-peerinfo.c:624 | ||
5423 | #, c-format | ||
5424 | msgid "Scanning directory `%s'\n" | ||
5425 | msgstr "" | ||
5426 | |||
5427 | #: src/peerinfo/gnunet-service-peerinfo.c:631 | ||
5428 | #, c-format | ||
5429 | msgid "Still no peers found in `%s'!\n" | ||
5430 | msgstr "" | ||
5431 | |||
5432 | #: src/peerinfo/gnunet-service-peerinfo.c:1024 | ||
5433 | #, c-format | ||
5434 | msgid "Cleaning up directory `%s'\n" | ||
5435 | msgstr "" | ||
5436 | |||
5437 | #: src/peerinfo/gnunet-service-peerinfo.c:1319 | ||
5438 | #, c-format | ||
5439 | msgid "Importing HELLOs from `%s'\n" | ||
5440 | msgstr "" | ||
5441 | |||
5442 | #: src/peerinfo/gnunet-service-peerinfo.c:1332 | ||
5443 | msgid "Skipping import of included HELLOs\n" | ||
5444 | msgstr "" | ||
5445 | |||
5446 | #: src/peerinfo/peerinfo_api.c:217 | ||
5447 | msgid "Failed to receive response from `PEERINFO' service." | ||
5448 | msgstr "" | ||
5449 | |||
5450 | #: src/peerinfo-tool/gnunet-peerinfo.c:237 | 5396 | #: src/peerinfo-tool/gnunet-peerinfo.c:237 |
5451 | #, c-format | 5397 | #, c-format |
5452 | msgid "%sPeer `%s'\n" | 5398 | msgid "%sPeer `%s'\n" |
@@ -5541,6 +5487,60 @@ msgstr "" | |||
5541 | msgid "Peerinfo REST API initialized\n" | 5487 | msgid "Peerinfo REST API initialized\n" |
5542 | msgstr "" | 5488 | msgstr "" |
5543 | 5489 | ||
5490 | #: src/peerinfo/gnunet-service-peerinfo.c:175 | ||
5491 | #, c-format | ||
5492 | msgid "Removing expired address of transport `%s'\n" | ||
5493 | msgstr "" | ||
5494 | |||
5495 | #: src/peerinfo/gnunet-service-peerinfo.c:306 | ||
5496 | #, c-format | ||
5497 | msgid "Failed to parse HELLO in file `%s': %s\n" | ||
5498 | msgstr "" | ||
5499 | |||
5500 | #: src/peerinfo/gnunet-service-peerinfo.c:323 | ||
5501 | #: src/peerinfo/gnunet-service-peerinfo.c:348 | ||
5502 | #, c-format | ||
5503 | msgid "Failed to parse HELLO in file `%s'\n" | ||
5504 | msgstr "" | ||
5505 | |||
5506 | #: src/peerinfo/gnunet-service-peerinfo.c:426 | ||
5507 | msgid "# peers known" | ||
5508 | msgstr "" | ||
5509 | |||
5510 | #: src/peerinfo/gnunet-service-peerinfo.c:468 | ||
5511 | #, c-format | ||
5512 | msgid "" | ||
5513 | "File `%s' in directory `%s' does not match naming convention. Removed.\n" | ||
5514 | msgstr "" | ||
5515 | |||
5516 | #: src/peerinfo/gnunet-service-peerinfo.c:624 | ||
5517 | #, c-format | ||
5518 | msgid "Scanning directory `%s'\n" | ||
5519 | msgstr "" | ||
5520 | |||
5521 | #: src/peerinfo/gnunet-service-peerinfo.c:631 | ||
5522 | #, c-format | ||
5523 | msgid "Still no peers found in `%s'!\n" | ||
5524 | msgstr "" | ||
5525 | |||
5526 | #: src/peerinfo/gnunet-service-peerinfo.c:1024 | ||
5527 | #, c-format | ||
5528 | msgid "Cleaning up directory `%s'\n" | ||
5529 | msgstr "" | ||
5530 | |||
5531 | #: src/peerinfo/gnunet-service-peerinfo.c:1319 | ||
5532 | #, c-format | ||
5533 | msgid "Importing HELLOs from `%s'\n" | ||
5534 | msgstr "" | ||
5535 | |||
5536 | #: src/peerinfo/gnunet-service-peerinfo.c:1332 | ||
5537 | msgid "Skipping import of included HELLOs\n" | ||
5538 | msgstr "" | ||
5539 | |||
5540 | #: src/peerinfo/peerinfo_api.c:217 | ||
5541 | msgid "Failed to receive response from `PEERINFO' service." | ||
5542 | msgstr "" | ||
5543 | |||
5544 | #: src/peerstore/gnunet-peerstore.c:92 | 5544 | #: src/peerstore/gnunet-peerstore.c:92 |
5545 | msgid "peerstore" | 5545 | msgid "peerstore" |
5546 | msgstr "" | 5546 | msgstr "" |
@@ -5980,18 +5980,6 @@ msgstr "" | |||
5980 | msgid "Could not open revocation database file!" | 5980 | msgid "Could not open revocation database file!" |
5981 | msgstr "" | 5981 | msgstr "" |
5982 | 5982 | ||
5983 | #: src/rps/gnunet-rps.c:270 | ||
5984 | msgid "Seed a PeerID" | ||
5985 | msgstr "" | ||
5986 | |||
5987 | #: src/rps/gnunet-rps.c:275 | ||
5988 | msgid "Get updates of view (0 for infinite updates)" | ||
5989 | msgstr "" | ||
5990 | |||
5991 | #: src/rps/gnunet-rps.c:279 | ||
5992 | msgid "Get peers from biased stream" | ||
5993 | msgstr "" | ||
5994 | |||
5995 | #: src/rps/gnunet-rps-profiler.c:3200 | 5983 | #: src/rps/gnunet-rps-profiler.c:3200 |
5996 | msgid "duration of the profiling" | 5984 | msgid "duration of the profiling" |
5997 | msgstr "" | 5985 | msgstr "" |
@@ -6009,6 +5997,18 @@ msgstr "nombre de valeurs" | |||
6009 | msgid "Measure quality and performance of the RPS service." | 5997 | msgid "Measure quality and performance of the RPS service." |
6010 | msgstr "" | 5998 | msgstr "" |
6011 | 5999 | ||
6000 | #: src/rps/gnunet-rps.c:270 | ||
6001 | msgid "Seed a PeerID" | ||
6002 | msgstr "" | ||
6003 | |||
6004 | #: src/rps/gnunet-rps.c:275 | ||
6005 | msgid "Get updates of view (0 for infinite updates)" | ||
6006 | msgstr "" | ||
6007 | |||
6008 | #: src/rps/gnunet-rps.c:279 | ||
6009 | msgid "Get peers from biased stream" | ||
6010 | msgstr "" | ||
6011 | |||
6012 | #: src/scalarproduct/gnunet-scalarproduct.c:229 | 6012 | #: src/scalarproduct/gnunet-scalarproduct.c:229 |
6013 | msgid "You must specify at least one message ID to check!\n" | 6013 | msgid "You must specify at least one message ID to check!\n" |
6014 | msgstr "" | 6014 | msgstr "" |
@@ -6063,10 +6063,10 @@ msgstr "" | |||
6063 | msgid "Calculate the Vectorproduct with a GNUnet peer." | 6063 | msgid "Calculate the Vectorproduct with a GNUnet peer." |
6064 | msgstr "" | 6064 | msgstr "" |
6065 | 6065 | ||
6066 | #: src/scalarproduct/gnunet-service-scalarproduct_alice.c:1358 | ||
6067 | #: src/scalarproduct/gnunet-service-scalarproduct_bob.c:1355 | ||
6068 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_alice.c:1118 | 6066 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_alice.c:1118 |
6069 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c:1063 | 6067 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c:1063 |
6068 | #: src/scalarproduct/gnunet-service-scalarproduct_alice.c:1358 | ||
6069 | #: src/scalarproduct/gnunet-service-scalarproduct_bob.c:1355 | ||
6070 | msgid "Connect to CADET failed\n" | 6070 | msgid "Connect to CADET failed\n" |
6071 | msgstr "" | 6071 | msgstr "" |
6072 | 6072 | ||
@@ -6415,15 +6415,6 @@ msgstr "" | |||
6415 | msgid "%.s Unknown result code." | 6415 | msgid "%.s Unknown result code." |
6416 | msgstr "%.s Code d'erreur inconnu" | 6416 | msgstr "%.s Code d'erreur inconnu" |
6417 | 6417 | ||
6418 | #: src/testbed/gnunet_testbed_mpi_spawn.c:119 | ||
6419 | msgid "Waiting for child to exit.\n" | ||
6420 | msgstr "" | ||
6421 | |||
6422 | #: src/testbed/gnunet_testbed_mpi_spawn.c:242 | ||
6423 | #, c-format | ||
6424 | msgid "Spawning process `%s'\n" | ||
6425 | msgstr "" | ||
6426 | |||
6427 | #: src/testbed/gnunet-testbed-profiler.c:290 | 6418 | #: src/testbed/gnunet-testbed-profiler.c:290 |
6428 | msgid "tolerate COUNT number of continious timeout failures" | 6419 | msgid "tolerate COUNT number of continious timeout failures" |
6429 | msgstr "" | 6420 | msgstr "" |
@@ -6435,6 +6426,15 @@ msgid "" | |||
6435 | "signal is received" | 6426 | "signal is received" |
6436 | msgstr "" | 6427 | msgstr "" |
6437 | 6428 | ||
6429 | #: src/testbed/gnunet_testbed_mpi_spawn.c:119 | ||
6430 | msgid "Waiting for child to exit.\n" | ||
6431 | msgstr "" | ||
6432 | |||
6433 | #: src/testbed/gnunet_testbed_mpi_spawn.c:242 | ||
6434 | #, c-format | ||
6435 | msgid "Spawning process `%s'\n" | ||
6436 | msgstr "" | ||
6437 | |||
6438 | #: src/testbed/testbed_api.c:399 | 6438 | #: src/testbed/testbed_api.c:399 |
6439 | #, c-format | 6439 | #, c-format |
6440 | msgid "Adding host %u failed with error: %s\n" | 6440 | msgid "Adding host %u failed with error: %s\n" |
@@ -6722,18 +6722,18 @@ msgstr "" | |||
6722 | msgid "GNUnet topology control" | 6722 | msgid "GNUnet topology control" |
6723 | msgstr "" | 6723 | msgstr "" |
6724 | 6724 | ||
6725 | #: src/transport/gnunet-communicator-tcp.c:3189 | 6725 | #: src/transport/gnunet-communicator-tcp.c:3221 |
6726 | #: src/transport/gnunet-communicator-udp.c:2826 | 6726 | #: src/transport/gnunet-communicator-udp.c:2995 |
6727 | #: src/transport/gnunet-service-tng.c:10014 | 6727 | #: src/transport/gnunet-service-tng.c:10014 |
6728 | #: src/transport/gnunet-service-transport.c:2624 | 6728 | #: src/transport/gnunet-service-transport.c:2626 |
6729 | msgid "Transport service is lacking key configuration settings. Exiting.\n" | 6729 | msgid "Transport service is lacking key configuration settings. Exiting.\n" |
6730 | msgstr "" | 6730 | msgstr "" |
6731 | 6731 | ||
6732 | #: src/transport/gnunet-communicator-tcp.c:3494 | 6732 | #: src/transport/gnunet-communicator-tcp.c:3553 |
6733 | msgid "GNUnet TCP communicator" | 6733 | msgid "GNUnet TCP communicator" |
6734 | msgstr "" | 6734 | msgstr "" |
6735 | 6735 | ||
6736 | #: src/transport/gnunet-communicator-udp.c:2898 | 6736 | #: src/transport/gnunet-communicator-udp.c:3067 |
6737 | msgid "GNUnet UDP communicator" | 6737 | msgid "GNUnet UDP communicator" |
6738 | msgstr "" | 6738 | msgstr "" |
6739 | 6739 | ||
@@ -6756,50 +6756,50 @@ msgstr "" | |||
6756 | msgid "GNUnet UNIX domain socket communicator" | 6756 | msgid "GNUnet UNIX domain socket communicator" |
6757 | msgstr "" | 6757 | msgstr "" |
6758 | 6758 | ||
6759 | #: src/transport/gnunet-service-transport_ats.c:137 | ||
6760 | msgid "# Addresses given to ATS" | ||
6761 | msgstr "" | ||
6762 | |||
6763 | #: src/transport/gnunet-service-transport.c:445 | 6759 | #: src/transport/gnunet-service-transport.c:445 |
6764 | msgid "# messages dropped due to slow client" | 6760 | msgid "# messages dropped due to slow client" |
6765 | msgstr "" | 6761 | msgstr "" |
6766 | 6762 | ||
6767 | #: src/transport/gnunet-service-transport.c:794 | 6763 | #: src/transport/gnunet-service-transport.c:796 |
6768 | msgid "# bytes payload dropped (other peer was not connected)" | 6764 | msgid "# bytes payload dropped (other peer was not connected)" |
6769 | msgstr "" | 6765 | msgstr "" |
6770 | 6766 | ||
6771 | #: src/transport/gnunet-service-transport.c:1477 | 6767 | #: src/transport/gnunet-service-transport.c:1479 |
6772 | msgid "# bytes payload discarded due to not connected peer" | 6768 | msgid "# bytes payload discarded due to not connected peer" |
6773 | msgstr "" | 6769 | msgstr "" |
6774 | 6770 | ||
6775 | #: src/transport/gnunet-service-transport.c:1622 | 6771 | #: src/transport/gnunet-service-transport.c:1624 |
6776 | msgid "# bytes total received" | 6772 | msgid "# bytes total received" |
6777 | msgstr "" | 6773 | msgstr "" |
6778 | 6774 | ||
6779 | #: src/transport/gnunet-service-transport.c:1712 | 6775 | #: src/transport/gnunet-service-transport.c:1714 |
6780 | msgid "# bytes payload received" | 6776 | msgid "# bytes payload received" |
6781 | msgstr "" | 6777 | msgstr "" |
6782 | 6778 | ||
6783 | #: src/transport/gnunet-service-transport.c:2016 | 6779 | #: src/transport/gnunet-service-transport.c:2018 |
6784 | #: src/transport/gnunet-service-transport.c:2450 | 6780 | #: src/transport/gnunet-service-transport.c:2452 |
6785 | msgid "# disconnects due to blacklist" | 6781 | msgid "# disconnects due to blacklist" |
6786 | msgstr "" | 6782 | msgstr "" |
6787 | 6783 | ||
6788 | #: src/transport/gnunet-service-transport.c:2454 | 6784 | #: src/transport/gnunet-service-transport.c:2456 |
6789 | #, c-format | 6785 | #, c-format |
6790 | msgid "Disallowing connection to peer `%s' on transport %s\n" | 6786 | msgid "Disallowing connection to peer `%s' on transport %s\n" |
6791 | msgstr "" | 6787 | msgstr "" |
6792 | 6788 | ||
6793 | #: src/transport/gnunet-service-transport.c:2549 | 6789 | #: src/transport/gnunet-service-transport.c:2551 |
6794 | #, c-format | 6790 | #, c-format |
6795 | msgid "Adding blacklisting entry for peer `%s'\n" | 6791 | msgid "Adding blacklisting entry for peer `%s'\n" |
6796 | msgstr "" | 6792 | msgstr "" |
6797 | 6793 | ||
6798 | #: src/transport/gnunet-service-transport.c:2558 | 6794 | #: src/transport/gnunet-service-transport.c:2560 |
6799 | #, c-format | 6795 | #, c-format |
6800 | msgid "Adding blacklisting entry for peer `%s':`%s'\n" | 6796 | msgid "Adding blacklisting entry for peer `%s':`%s'\n" |
6801 | msgstr "" | 6797 | msgstr "" |
6802 | 6798 | ||
6799 | #: src/transport/gnunet-service-transport_ats.c:137 | ||
6800 | msgid "# Addresses given to ATS" | ||
6801 | msgstr "" | ||
6802 | |||
6803 | #: src/transport/gnunet-service-transport_hello.c:195 | 6803 | #: src/transport/gnunet-service-transport_hello.c:195 |
6804 | msgid "# refreshed my HELLO" | 6804 | msgid "# refreshed my HELLO" |
6805 | msgstr "" | 6805 | msgstr "" |
@@ -7105,6 +7105,42 @@ msgstr "" | |||
7105 | msgid "# HELLOs given to peerinfo" | 7105 | msgid "# HELLOs given to peerinfo" |
7106 | msgstr "" | 7106 | msgstr "" |
7107 | 7107 | ||
7108 | #: src/transport/gnunet-transport-profiler.c:220 | ||
7109 | #, c-format | ||
7110 | msgid "%llu B in %llu ms == %.2f KB/s!\n" | ||
7111 | msgstr "" | ||
7112 | |||
7113 | #: src/transport/gnunet-transport-profiler.c:577 | ||
7114 | msgid "send data to peer" | ||
7115 | msgstr "" | ||
7116 | |||
7117 | #: src/transport/gnunet-transport-profiler.c:581 | ||
7118 | msgid "receive data from peer" | ||
7119 | msgstr "" | ||
7120 | |||
7121 | #: src/transport/gnunet-transport-profiler.c:586 | ||
7122 | msgid "iterations" | ||
7123 | msgstr "" | ||
7124 | |||
7125 | #: src/transport/gnunet-transport-profiler.c:591 | ||
7126 | #, fuzzy | ||
7127 | msgid "number of messages to send" | ||
7128 | msgstr "nombre de valeurs" | ||
7129 | |||
7130 | #: src/transport/gnunet-transport-profiler.c:596 | ||
7131 | msgid "message size to use" | ||
7132 | msgstr "" | ||
7133 | |||
7134 | #: src/transport/gnunet-transport-profiler.c:601 | ||
7135 | #: src/transport/gnunet-transport.c:1404 | ||
7136 | msgid "peer identity" | ||
7137 | msgstr "" | ||
7138 | |||
7139 | #: src/transport/gnunet-transport-profiler.c:614 | ||
7140 | #: src/transport/gnunet-transport.c:1426 | ||
7141 | msgid "Direct access to transport service." | ||
7142 | msgstr "" | ||
7143 | |||
7108 | #: src/transport/gnunet-transport.c:406 | 7144 | #: src/transport/gnunet-transport.c:406 |
7109 | #, c-format | 7145 | #, c-format |
7110 | msgid "Transmitted %llu bytes/s (%llu bytes in %s)\n" | 7146 | msgid "Transmitted %llu bytes/s (%llu bytes in %s)\n" |
@@ -7234,11 +7270,6 @@ msgstr "" | |||
7234 | msgid "do not resolve hostnames" | 7270 | msgid "do not resolve hostnames" |
7235 | msgstr "" | 7271 | msgstr "" |
7236 | 7272 | ||
7237 | #: src/transport/gnunet-transport.c:1404 | ||
7238 | #: src/transport/gnunet-transport-profiler.c:601 | ||
7239 | msgid "peer identity" | ||
7240 | msgstr "" | ||
7241 | |||
7242 | #: src/transport/gnunet-transport.c:1408 | 7273 | #: src/transport/gnunet-transport.c:1408 |
7243 | msgid "monitor plugin sessions" | 7274 | msgid "monitor plugin sessions" |
7244 | msgstr "" | 7275 | msgstr "" |
@@ -7247,37 +7278,6 @@ msgstr "" | |||
7247 | msgid "send data for benchmarking to the other peer (until CTRL-C)" | 7278 | msgid "send data for benchmarking to the other peer (until CTRL-C)" |
7248 | msgstr "" | 7279 | msgstr "" |
7249 | 7280 | ||
7250 | #: src/transport/gnunet-transport.c:1426 | ||
7251 | #: src/transport/gnunet-transport-profiler.c:614 | ||
7252 | msgid "Direct access to transport service." | ||
7253 | msgstr "" | ||
7254 | |||
7255 | #: src/transport/gnunet-transport-profiler.c:220 | ||
7256 | #, c-format | ||
7257 | msgid "%llu B in %llu ms == %.2f KB/s!\n" | ||
7258 | msgstr "" | ||
7259 | |||
7260 | #: src/transport/gnunet-transport-profiler.c:577 | ||
7261 | msgid "send data to peer" | ||
7262 | msgstr "" | ||
7263 | |||
7264 | #: src/transport/gnunet-transport-profiler.c:581 | ||
7265 | msgid "receive data from peer" | ||
7266 | msgstr "" | ||
7267 | |||
7268 | #: src/transport/gnunet-transport-profiler.c:586 | ||
7269 | msgid "iterations" | ||
7270 | msgstr "" | ||
7271 | |||
7272 | #: src/transport/gnunet-transport-profiler.c:591 | ||
7273 | #, fuzzy | ||
7274 | msgid "number of messages to send" | ||
7275 | msgstr "nombre de valeurs" | ||
7276 | |||
7277 | #: src/transport/gnunet-transport-profiler.c:596 | ||
7278 | msgid "message size to use" | ||
7279 | msgstr "" | ||
7280 | |||
7281 | #: src/transport/plugin_transport_http_client.c:1489 | 7281 | #: src/transport/plugin_transport_http_client.c:1489 |
7282 | #: src/transport/plugin_transport_http_server.c:2331 | 7282 | #: src/transport/plugin_transport_http_server.c:2331 |
7283 | #: src/transport/plugin_transport_http_server.c:3562 | 7283 | #: src/transport/plugin_transport_http_server.c:3562 |
@@ -7543,20 +7543,6 @@ msgstr "" | |||
7543 | msgid "TCP transport advertises itself as being on port %llu\n" | 7543 | msgid "TCP transport advertises itself as being on port %llu\n" |
7544 | msgstr "" | 7544 | msgstr "" |
7545 | 7545 | ||
7546 | #: src/transport/plugin_transport_udp_broadcasting.c:169 | ||
7547 | msgid "# Multicast HELLO beacons received via UDP" | ||
7548 | msgstr "" | ||
7549 | |||
7550 | #: src/transport/plugin_transport_udp_broadcasting.c:553 | ||
7551 | msgid "" | ||
7552 | "Disabling HELLO broadcasting due to friend-to-friend only configuration!\n" | ||
7553 | msgstr "" | ||
7554 | |||
7555 | #: src/transport/plugin_transport_udp_broadcasting.c:571 | ||
7556 | #, c-format | ||
7557 | msgid "Failed to set IPv4 broadcast option for broadcast socket on port %d\n" | ||
7558 | msgstr "" | ||
7559 | |||
7560 | #: src/transport/plugin_transport_udp.c:3169 | 7546 | #: src/transport/plugin_transport_udp.c:3169 |
7561 | #, c-format | 7547 | #, c-format |
7562 | msgid "" | 7548 | msgid "" |
@@ -7603,6 +7589,20 @@ msgstr "adresse invalide" | |||
7603 | msgid "Failed to create UDP network sockets\n" | 7589 | msgid "Failed to create UDP network sockets\n" |
7604 | msgstr "" | 7590 | msgstr "" |
7605 | 7591 | ||
7592 | #: src/transport/plugin_transport_udp_broadcasting.c:169 | ||
7593 | msgid "# Multicast HELLO beacons received via UDP" | ||
7594 | msgstr "" | ||
7595 | |||
7596 | #: src/transport/plugin_transport_udp_broadcasting.c:553 | ||
7597 | msgid "" | ||
7598 | "Disabling HELLO broadcasting due to friend-to-friend only configuration!\n" | ||
7599 | msgstr "" | ||
7600 | |||
7601 | #: src/transport/plugin_transport_udp_broadcasting.c:571 | ||
7602 | #, c-format | ||
7603 | msgid "Failed to set IPv4 broadcast option for broadcast socket on port %d\n" | ||
7604 | msgstr "" | ||
7605 | |||
7606 | #: src/transport/plugin_transport_unix.c:1396 | 7606 | #: src/transport/plugin_transport_unix.c:1396 |
7607 | #, c-format | 7607 | #, c-format |
7608 | msgid "Cannot bind to `%s'\n" | 7608 | msgid "Cannot bind to `%s'\n" |
@@ -7775,7 +7775,7 @@ msgid "do daemonize (detach from terminal)" | |||
7775 | msgstr "" | 7775 | msgstr "" |
7776 | 7776 | ||
7777 | #: src/transport/tcp_service_legacy.c:1397 | 7777 | #: src/transport/tcp_service_legacy.c:1397 |
7778 | #: src/transport/transport-testing2.c:1116 src/util/service.c:2072 | 7778 | #: src/transport/transport-testing2.c:983 src/util/service.c:2072 |
7779 | #: src/util/service.c:2084 | 7779 | #: src/util/service.c:2084 |
7780 | #, c-format | 7780 | #, c-format |
7781 | msgid "Malformed configuration file `%s', exit ...\n" | 7781 | msgid "Malformed configuration file `%s', exit ...\n" |
@@ -8434,19 +8434,19 @@ msgid "" | |||
8434 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" | 8434 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" |
8435 | msgstr "" | 8435 | msgstr "" |
8436 | 8436 | ||
8437 | #: src/util/os_installation.c:409 | 8437 | #: src/util/os_installation.c:411 |
8438 | #, c-format | 8438 | #, c-format |
8439 | msgid "" | 8439 | msgid "" |
8440 | "Could not determine installation path for %s. Set `%s' environment " | 8440 | "Could not determine installation path for %s. Set `%s' environment " |
8441 | "variable.\n" | 8441 | "variable.\n" |
8442 | msgstr "" | 8442 | msgstr "" |
8443 | 8443 | ||
8444 | #: src/util/os_installation.c:792 | 8444 | #: src/util/os_installation.c:794 |
8445 | #, c-format | 8445 | #, c-format |
8446 | msgid "Could not find binary `%s' in PATH!\n" | 8446 | msgid "Could not find binary `%s' in PATH!\n" |
8447 | msgstr "" | 8447 | msgstr "" |
8448 | 8448 | ||
8449 | #: src/util/os_installation.c:825 | 8449 | #: src/util/os_installation.c:827 |
8450 | #, c-format | 8450 | #, c-format |
8451 | msgid "Binary `%s' exists, but is not SUID\n" | 8451 | msgid "Binary `%s' exists, but is not SUID\n" |
8452 | msgstr "" | 8452 | msgstr "" |
@@ -8470,17 +8470,17 @@ msgstr "" | |||
8470 | msgid "Could not determine plugin installation path.\n" | 8470 | msgid "Could not determine plugin installation path.\n" |
8471 | msgstr "" | 8471 | msgstr "" |
8472 | 8472 | ||
8473 | #: src/util/program.c:262 | 8473 | #: src/util/program.c:267 |
8474 | #, fuzzy, c-format | 8474 | #, fuzzy, c-format |
8475 | msgid "Unreadable or malformed configuration file `%s', exit ...\n" | 8475 | msgid "Unreadable or malformed configuration file `%s', exit ...\n" |
8476 | msgstr "fornat invalide : « %s »\n" | 8476 | msgstr "fornat invalide : « %s »\n" |
8477 | 8477 | ||
8478 | #: src/util/program.c:279 | 8478 | #: src/util/program.c:284 |
8479 | #, c-format | 8479 | #, c-format |
8480 | msgid "Unreadable or malformed default configuration file `%s', exit ...\n" | 8480 | msgid "Unreadable or malformed default configuration file `%s', exit ...\n" |
8481 | msgstr "" | 8481 | msgstr "" |
8482 | 8482 | ||
8483 | #: src/util/program.c:294 | 8483 | #: src/util/program.c:299 |
8484 | #, fuzzy | 8484 | #, fuzzy |
8485 | msgid "Unreadable or malformed configuration, exit ...\n" | 8485 | msgid "Unreadable or malformed configuration, exit ...\n" |
8486 | msgstr "fornat invalide : « %s »\n" | 8486 | msgstr "fornat invalide : « %s »\n" |
@@ -8545,10 +8545,6 @@ msgstr "" | |||
8545 | msgid "Attempting to proxy service `%s' to invalid port %d or hostname.\n" | 8545 | msgid "Attempting to proxy service `%s' to invalid port %d or hostname.\n" |
8546 | msgstr "" | 8546 | msgstr "" |
8547 | 8547 | ||
8548 | #: src/util/strings.c:179 | ||
8549 | msgid "b" | ||
8550 | msgstr "o" | ||
8551 | |||
8552 | #: src/util/strings.c:503 | 8548 | #: src/util/strings.c:503 |
8553 | #, c-format | 8549 | #, c-format |
8554 | msgid "Character sets requested were `%s'->`%s'\n" | 8550 | msgid "Character sets requested were `%s'->`%s'\n" |
@@ -8558,46 +8554,6 @@ msgstr "" | |||
8558 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" | 8554 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" |
8559 | msgstr "" | 8555 | msgstr "" |
8560 | 8556 | ||
8561 | #: src/util/strings.c:706 | ||
8562 | msgid "µs" | ||
8563 | msgstr "µs" | ||
8564 | |||
8565 | #: src/util/strings.c:710 | ||
8566 | msgid "forever" | ||
8567 | msgstr "perpetuel" | ||
8568 | |||
8569 | #: src/util/strings.c:712 | ||
8570 | msgid "0 ms" | ||
8571 | msgstr "0 ms" | ||
8572 | |||
8573 | #: src/util/strings.c:716 | ||
8574 | msgid "ms" | ||
8575 | msgstr "ms" | ||
8576 | |||
8577 | #: src/util/strings.c:720 | ||
8578 | msgid "s" | ||
8579 | msgstr "s" | ||
8580 | |||
8581 | #: src/util/strings.c:724 | ||
8582 | msgid "m" | ||
8583 | msgstr "m" | ||
8584 | |||
8585 | #: src/util/strings.c:728 | ||
8586 | msgid "h" | ||
8587 | msgstr "h" | ||
8588 | |||
8589 | #: src/util/strings.c:734 | ||
8590 | msgid "day" | ||
8591 | msgstr "jour" | ||
8592 | |||
8593 | #: src/util/strings.c:736 | ||
8594 | msgid "days" | ||
8595 | msgstr "jours" | ||
8596 | |||
8597 | #: src/util/strings.c:764 | ||
8598 | msgid "end of time" | ||
8599 | msgstr "fin du temps" | ||
8600 | |||
8601 | #: src/util/strings.c:1240 | 8557 | #: src/util/strings.c:1240 |
8602 | msgid "IPv6 address did not start with `['\n" | 8558 | msgid "IPv6 address did not start with `['\n" |
8603 | msgstr "" | 8559 | msgstr "" |
@@ -8834,11 +8790,44 @@ msgstr "" | |||
8834 | msgid "Setup tunnels via VPN." | 8790 | msgid "Setup tunnels via VPN." |
8835 | msgstr "Configurer des tunnels via VPN." | 8791 | msgstr "Configurer des tunnels via VPN." |
8836 | 8792 | ||
8837 | #: src/zonemaster/gnunet-service-zonemaster.c:849 | ||
8838 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:420 | 8793 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:420 |
8794 | #: src/zonemaster/gnunet-service-zonemaster.c:849 | ||
8839 | msgid "Failed to connect to the namestore!\n" | 8795 | msgid "Failed to connect to the namestore!\n" |
8840 | msgstr "" | 8796 | msgstr "" |
8841 | 8797 | ||
8798 | #~ msgid "b" | ||
8799 | #~ msgstr "o" | ||
8800 | |||
8801 | #~ msgid "µs" | ||
8802 | #~ msgstr "µs" | ||
8803 | |||
8804 | #~ msgid "forever" | ||
8805 | #~ msgstr "perpetuel" | ||
8806 | |||
8807 | #~ msgid "0 ms" | ||
8808 | #~ msgstr "0 ms" | ||
8809 | |||
8810 | #~ msgid "ms" | ||
8811 | #~ msgstr "ms" | ||
8812 | |||
8813 | #~ msgid "s" | ||
8814 | #~ msgstr "s" | ||
8815 | |||
8816 | #~ msgid "m" | ||
8817 | #~ msgstr "m" | ||
8818 | |||
8819 | #~ msgid "h" | ||
8820 | #~ msgstr "h" | ||
8821 | |||
8822 | #~ msgid "day" | ||
8823 | #~ msgstr "jour" | ||
8824 | |||
8825 | #~ msgid "days" | ||
8826 | #~ msgstr "jours" | ||
8827 | |||
8828 | #~ msgid "end of time" | ||
8829 | #~ msgstr "fin du temps" | ||
8830 | |||
8842 | #, fuzzy | 8831 | #, fuzzy |
8843 | #~ msgid "Assertion failed at %s:%d. Aborting.\n" | 8832 | #~ msgid "Assertion failed at %s:%d. Aborting.\n" |
8844 | #~ msgstr "opus_encode_float() échoué : %s. Annulation\n" | 8833 | #~ msgstr "opus_encode_float() échoué : %s. Annulation\n" |
@@ -8,7 +8,7 @@ msgid "" | |||
8 | msgstr "" | 8 | msgstr "" |
9 | "Project-Id-Version: gnunet 0.10.1\n" | 9 | "Project-Id-Version: gnunet 0.10.1\n" |
10 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" | 10 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" |
11 | "POT-Creation-Date: 2020-09-06 10:07+0200\n" | 11 | "POT-Creation-Date: 2020-10-13 16:12+0200\n" |
12 | "PO-Revision-Date: 2019-10-16 11:00+0200\n" | 12 | "PO-Revision-Date: 2019-10-16 11:00+0200\n" |
13 | "Last-Translator: Sebastiano Pistore <sebastianopistore.info@protonmail.ch>\n" | 13 | "Last-Translator: Sebastiano Pistore <sebastianopistore.info@protonmail.ch>\n" |
14 | "Language-Team: Italian <tp@lists.linux.it>\n" | 14 | "Language-Team: Italian <tp@lists.linux.it>\n" |
@@ -31,8 +31,8 @@ msgid "Issuer public key `%s' is not well-formed\n" | |||
31 | msgstr "" | 31 | msgstr "" |
32 | 32 | ||
33 | #: src/abd/gnunet-abd.c:560 src/abd/gnunet-service-abd.c:1747 | 33 | #: src/abd/gnunet-abd.c:560 src/abd/gnunet-service-abd.c:1747 |
34 | #: src/namestore/gnunet-namestore.c:1001 | ||
35 | #: src/namestore/gnunet-namestore-fcfsd.c:1154 | 34 | #: src/namestore/gnunet-namestore-fcfsd.c:1154 |
35 | #: src/namestore/gnunet-namestore.c:1001 | ||
36 | #, c-format | 36 | #, c-format |
37 | msgid "Failed to connect to namestore\n" | 37 | msgid "Failed to connect to namestore\n" |
38 | msgstr "" | 38 | msgstr "" |
@@ -492,80 +492,13 @@ msgstr "" | |||
492 | msgid "Initiating shutdown as requested by client.\n" | 492 | msgid "Initiating shutdown as requested by client.\n" |
493 | msgstr "" | 493 | msgstr "" |
494 | 494 | ||
495 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | 495 | #: src/ats-tests/ats-testing-log.c:896 |
496 | #, c-format | 496 | msgid "Stop logging\n" |
497 | msgid "" | ||
498 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | ||
499 | "%llu\n" | ||
500 | msgstr "" | ||
501 | |||
502 | #: src/ats/gnunet-ats-solver-eval.c:3011 | ||
503 | #, c-format | ||
504 | msgid "" | ||
505 | "No outbound quota configured for network `%s', assigning default bandwidth " | ||
506 | "%llu\n" | ||
507 | msgstr "" | ||
508 | |||
509 | #: src/ats/gnunet-ats-solver-eval.c:3063 | ||
510 | #, c-format | ||
511 | msgid "" | ||
512 | "No outbound quota configure for network `%s', assigning default bandwidth " | ||
513 | "%llu\n" | ||
514 | msgstr "" | ||
515 | |||
516 | #: src/ats/gnunet-ats-solver-eval.c:3552 src/ats-tests/gnunet-solver-eval.c:997 | ||
517 | msgid "solver to use" | ||
518 | msgstr "" | ||
519 | |||
520 | #: src/ats/gnunet-ats-solver-eval.c:3557 | ||
521 | #: src/ats-tests/gnunet-solver-eval.c:1003 | ||
522 | #: src/ats-tests/gnunet-solver-eval.c:1008 | ||
523 | msgid "experiment to use" | ||
524 | msgstr "" | ||
525 | |||
526 | #: src/ats/gnunet-ats-solver-eval.c:3564 | ||
527 | msgid "print logging" | ||
528 | msgstr "" | ||
529 | |||
530 | #: src/ats/gnunet-ats-solver-eval.c:3569 | ||
531 | msgid "save logging to disk" | ||
532 | msgstr "" | ||
533 | |||
534 | #: src/ats/gnunet-ats-solver-eval.c:3574 | ||
535 | msgid "disable normalization" | ||
536 | msgstr "" | ||
537 | |||
538 | #: src/ats/gnunet-service-ats_plugins.c:326 | ||
539 | #, c-format | ||
540 | msgid "" | ||
541 | "Could not load %s quota for network `%s': `%s', assigning default bandwidth " | ||
542 | "%llu\n" | ||
543 | msgstr "" | ||
544 | |||
545 | #: src/ats/gnunet-service-ats_plugins.c:336 | ||
546 | #, c-format | ||
547 | msgid "%s quota configured for network `%s' is %llu\n" | ||
548 | msgstr "" | ||
549 | |||
550 | #: src/ats/gnunet-service-ats_plugins.c:382 | ||
551 | #, c-format | ||
552 | msgid "" | ||
553 | "No %s-quota configured for network `%s', assigning default bandwidth %llu\n" | ||
554 | msgstr "" | ||
555 | |||
556 | #: src/ats/gnunet-service-ats_plugins.c:474 | ||
557 | #, c-format | ||
558 | msgid "Failed to initialize solver `%s'!\n" | ||
559 | msgstr "" | ||
560 | |||
561 | #: src/ats/plugin_ats_proportional.c:1142 | ||
562 | #, c-format | ||
563 | msgid "Invalid %s configuration %f \n" | ||
564 | msgstr "" | 497 | msgstr "" |
565 | 498 | ||
566 | #: src/ats/plugin_ats_proportional.c:1165 | 499 | #: src/ats-tests/ats-testing-log.c:952 |
567 | #, c-format | 500 | #, c-format |
568 | msgid "Invalid %s configuration %f\n" | 501 | msgid "Start logging `%s'\n" |
569 | msgstr "" | 502 | msgstr "" |
570 | 503 | ||
571 | #: src/ats-tests/ats-testing.c:420 | 504 | #: src/ats-tests/ats-testing.c:420 |
@@ -578,15 +511,6 @@ msgstr "" | |||
578 | msgid "Failed to connect master peer [%u] with slave [%u]\n" | 511 | msgid "Failed to connect master peer [%u] with slave [%u]\n" |
579 | msgstr "" | 512 | msgstr "" |
580 | 513 | ||
581 | #: src/ats-tests/ats-testing-log.c:896 | ||
582 | msgid "Stop logging\n" | ||
583 | msgstr "" | ||
584 | |||
585 | #: src/ats-tests/ats-testing-log.c:952 | ||
586 | #, c-format | ||
587 | msgid "Start logging `%s'\n" | ||
588 | msgstr "" | ||
589 | |||
590 | #: src/ats-tests/gnunet-ats-sim.c:92 | 514 | #: src/ats-tests/gnunet-ats-sim.c:92 |
591 | #, c-format | 515 | #, c-format |
592 | msgid "" | 516 | msgid "" |
@@ -594,6 +518,16 @@ msgid "" | |||
594 | "= %u KiB/s\n" | 518 | "= %u KiB/s\n" |
595 | msgstr "" | 519 | msgstr "" |
596 | 520 | ||
521 | #: src/ats-tests/gnunet-solver-eval.c:997 src/ats/gnunet-ats-solver-eval.c:3552 | ||
522 | msgid "solver to use" | ||
523 | msgstr "" | ||
524 | |||
525 | #: src/ats-tests/gnunet-solver-eval.c:1003 | ||
526 | #: src/ats-tests/gnunet-solver-eval.c:1008 | ||
527 | #: src/ats/gnunet-ats-solver-eval.c:3557 | ||
528 | msgid "experiment to use" | ||
529 | msgstr "" | ||
530 | |||
597 | #: src/ats-tool/gnunet-ats.c:299 | 531 | #: src/ats-tool/gnunet-ats.c:299 |
598 | #, c-format | 532 | #, c-format |
599 | msgid "%u address resolutions had a timeout\n" | 533 | msgid "%u address resolutions had a timeout\n" |
@@ -710,6 +644,72 @@ msgstr "" | |||
710 | msgid "Print information about ATS state" | 644 | msgid "Print information about ATS state" |
711 | msgstr "" | 645 | msgstr "" |
712 | 646 | ||
647 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | ||
648 | #, c-format | ||
649 | msgid "" | ||
650 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | ||
651 | "%llu\n" | ||
652 | msgstr "" | ||
653 | |||
654 | #: src/ats/gnunet-ats-solver-eval.c:3011 | ||
655 | #, c-format | ||
656 | msgid "" | ||
657 | "No outbound quota configured for network `%s', assigning default bandwidth " | ||
658 | "%llu\n" | ||
659 | msgstr "" | ||
660 | |||
661 | #: src/ats/gnunet-ats-solver-eval.c:3063 | ||
662 | #, c-format | ||
663 | msgid "" | ||
664 | "No outbound quota configure for network `%s', assigning default bandwidth " | ||
665 | "%llu\n" | ||
666 | msgstr "" | ||
667 | |||
668 | #: src/ats/gnunet-ats-solver-eval.c:3564 | ||
669 | msgid "print logging" | ||
670 | msgstr "" | ||
671 | |||
672 | #: src/ats/gnunet-ats-solver-eval.c:3569 | ||
673 | msgid "save logging to disk" | ||
674 | msgstr "" | ||
675 | |||
676 | #: src/ats/gnunet-ats-solver-eval.c:3574 | ||
677 | msgid "disable normalization" | ||
678 | msgstr "" | ||
679 | |||
680 | #: src/ats/gnunet-service-ats_plugins.c:326 | ||
681 | #, c-format | ||
682 | msgid "" | ||
683 | "Could not load %s quota for network `%s': `%s', assigning default bandwidth " | ||
684 | "%llu\n" | ||
685 | msgstr "" | ||
686 | |||
687 | #: src/ats/gnunet-service-ats_plugins.c:336 | ||
688 | #, c-format | ||
689 | msgid "%s quota configured for network `%s' is %llu\n" | ||
690 | msgstr "" | ||
691 | |||
692 | #: src/ats/gnunet-service-ats_plugins.c:382 | ||
693 | #, c-format | ||
694 | msgid "" | ||
695 | "No %s-quota configured for network `%s', assigning default bandwidth %llu\n" | ||
696 | msgstr "" | ||
697 | |||
698 | #: src/ats/gnunet-service-ats_plugins.c:474 | ||
699 | #, c-format | ||
700 | msgid "Failed to initialize solver `%s'!\n" | ||
701 | msgstr "" | ||
702 | |||
703 | #: src/ats/plugin_ats_proportional.c:1142 | ||
704 | #, c-format | ||
705 | msgid "Invalid %s configuration %f \n" | ||
706 | msgstr "" | ||
707 | |||
708 | #: src/ats/plugin_ats_proportional.c:1165 | ||
709 | #, c-format | ||
710 | msgid "Invalid %s configuration %f\n" | ||
711 | msgstr "" | ||
712 | |||
713 | #: src/auction/gnunet-auction-create.c:163 | 713 | #: src/auction/gnunet-auction-create.c:163 |
714 | msgid "description of the item to be sold" | 714 | msgid "description of the item to be sold" |
715 | msgstr "" | 715 | msgstr "" |
@@ -840,6 +840,28 @@ msgstr "" | |||
840 | msgid "Connection to conversation service lost, trying to reconnect\n" | 840 | msgid "Connection to conversation service lost, trying to reconnect\n" |
841 | msgstr "" | 841 | msgstr "" |
842 | 842 | ||
843 | #: src/conversation/gnunet-conversation-test.c:120 | ||
844 | #, c-format | ||
845 | msgid "" | ||
846 | "\n" | ||
847 | "End of transmission. Have a GNU day.\n" | ||
848 | msgstr "" | ||
849 | |||
850 | #: src/conversation/gnunet-conversation-test.c:146 | ||
851 | #, c-format | ||
852 | msgid "" | ||
853 | "\n" | ||
854 | "We are now playing your recording back. If you can hear it, your audio " | ||
855 | "settings are working..." | ||
856 | msgstr "" | ||
857 | |||
858 | #: src/conversation/gnunet-conversation-test.c:218 | ||
859 | #, c-format | ||
860 | msgid "" | ||
861 | "We will now be recording you for %s. After that time, the recording will be " | ||
862 | "played back to you..." | ||
863 | msgstr "" | ||
864 | |||
843 | #: src/conversation/gnunet-conversation.c:264 | 865 | #: src/conversation/gnunet-conversation.c:264 |
844 | #, c-format | 866 | #, c-format |
845 | msgid "Incoming call from `%s'. Please /accept %u or /cancel %u the call.\n" | 867 | msgid "Incoming call from `%s'. Please /accept %u or /cancel %u the call.\n" |
@@ -1096,30 +1118,8 @@ msgstr "" | |||
1096 | msgid "Enables having a conversation with other GNUnet users." | 1118 | msgid "Enables having a conversation with other GNUnet users." |
1097 | msgstr "" | 1119 | msgstr "" |
1098 | 1120 | ||
1099 | #: src/conversation/gnunet-conversation-test.c:120 | ||
1100 | #, c-format | ||
1101 | msgid "" | ||
1102 | "\n" | ||
1103 | "End of transmission. Have a GNU day.\n" | ||
1104 | msgstr "" | ||
1105 | |||
1106 | #: src/conversation/gnunet-conversation-test.c:146 | ||
1107 | #, c-format | ||
1108 | msgid "" | ||
1109 | "\n" | ||
1110 | "We are now playing your recording back. If you can hear it, your audio " | ||
1111 | "settings are working..." | ||
1112 | msgstr "" | ||
1113 | |||
1114 | #: src/conversation/gnunet-conversation-test.c:218 | ||
1115 | #, c-format | ||
1116 | msgid "" | ||
1117 | "We will now be recording you for %s. After that time, the recording will be " | ||
1118 | "played back to you..." | ||
1119 | msgstr "" | ||
1120 | |||
1121 | #: src/conversation/gnunet_gst.c:664 | ||
1122 | #: src/conversation/gnunet-helper-audio-playback-gst.c:363 | 1121 | #: src/conversation/gnunet-helper-audio-playback-gst.c:363 |
1122 | #: src/conversation/gnunet_gst.c:664 | ||
1123 | #, c-format | 1123 | #, c-format |
1124 | msgid "Read error from STDIN: %d %s\n" | 1124 | msgid "Read error from STDIN: %d %s\n" |
1125 | msgstr "" | 1125 | msgstr "" |
@@ -1891,16 +1891,16 @@ msgstr "" | |||
1891 | msgid "Mysql database running\n" | 1891 | msgid "Mysql database running\n" |
1892 | msgstr "" | 1892 | msgstr "" |
1893 | 1893 | ||
1894 | #: src/datastore/plugin_datastore_postgres.c:278 | 1894 | #: src/datastore/plugin_datastore_postgres.c:284 |
1895 | #: src/datastore/plugin_datastore_postgres.c:891 | 1895 | #: src/datastore/plugin_datastore_postgres.c:897 |
1896 | msgid "Postgress exec failure" | 1896 | msgid "Postgress exec failure" |
1897 | msgstr "" | 1897 | msgstr "" |
1898 | 1898 | ||
1899 | #: src/datastore/plugin_datastore_postgres.c:852 | 1899 | #: src/datastore/plugin_datastore_postgres.c:858 |
1900 | msgid "Failed to drop table from database.\n" | 1900 | msgid "Failed to drop table from database.\n" |
1901 | msgstr "" | 1901 | msgstr "" |
1902 | 1902 | ||
1903 | #: src/datastore/plugin_datastore_postgres.c:950 | 1903 | #: src/datastore/plugin_datastore_postgres.c:956 |
1904 | msgid "Postgres database running\n" | 1904 | msgid "Postgres database running\n" |
1905 | msgstr "" | 1905 | msgstr "" |
1906 | 1906 | ||
@@ -2007,52 +2007,6 @@ msgstr "" | |||
2007 | msgid "Prints all packets that go through the DHT." | 2007 | msgid "Prints all packets that go through the DHT." |
2008 | msgstr "" | 2008 | msgstr "" |
2009 | 2009 | ||
2010 | #: src/dht/gnunet_dht_profiler.c:922 src/testbed/gnunet-testbed-profiler.c:255 | ||
2011 | #, c-format | ||
2012 | msgid "Exiting as the number of peers is %u\n" | ||
2013 | msgstr "" | ||
2014 | |||
2015 | #: src/dht/gnunet_dht_profiler.c:955 src/rps/gnunet-rps-profiler.c:3194 | ||
2016 | msgid "number of peers to start" | ||
2017 | msgstr "" | ||
2018 | |||
2019 | #: src/dht/gnunet_dht_profiler.c:961 | ||
2020 | msgid "number of PUTs to perform per peer" | ||
2021 | msgstr "" | ||
2022 | |||
2023 | #: src/dht/gnunet_dht_profiler.c:967 src/nse/gnunet-nse-profiler.c:872 | ||
2024 | #: src/testbed/gnunet-testbed-profiler.c:305 | ||
2025 | msgid "name of the file with the login information for the testbed" | ||
2026 | msgstr "" | ||
2027 | |||
2028 | #: src/dht/gnunet_dht_profiler.c:973 | ||
2029 | msgid "delay between rounds for collecting statistics (default: 30 sec)" | ||
2030 | msgstr "" | ||
2031 | |||
2032 | #: src/dht/gnunet_dht_profiler.c:979 | ||
2033 | msgid "delay to start doing PUTs (default: 1 sec)" | ||
2034 | msgstr "" | ||
2035 | |||
2036 | #: src/dht/gnunet_dht_profiler.c:985 | ||
2037 | msgid "delay to start doing GETs (default: 5 min)" | ||
2038 | msgstr "" | ||
2039 | |||
2040 | #: src/dht/gnunet_dht_profiler.c:990 | ||
2041 | msgid "replication degree for DHT PUTs" | ||
2042 | msgstr "" | ||
2043 | |||
2044 | #: src/dht/gnunet_dht_profiler.c:996 | ||
2045 | msgid "chance that a peer is selected at random for PUTs" | ||
2046 | msgstr "" | ||
2047 | |||
2048 | #: src/dht/gnunet_dht_profiler.c:1002 | ||
2049 | msgid "timeout for DHT PUT and GET requests (default: 1 min)" | ||
2050 | msgstr "" | ||
2051 | |||
2052 | #: src/dht/gnunet_dht_profiler.c:1023 | ||
2053 | msgid "Measure quality and performance of the DHT service." | ||
2054 | msgstr "" | ||
2055 | |||
2056 | #: src/dht/gnunet-dht-put.c:133 | 2010 | #: src/dht/gnunet-dht-put.c:133 |
2057 | msgid "Must provide KEY and DATA for DHT put!\n" | 2011 | msgid "Must provide KEY and DATA for DHT put!\n" |
2058 | msgstr "" | 2012 | msgstr "" |
@@ -2298,6 +2252,52 @@ msgstr "" | |||
2298 | msgid "# DHT requests combined" | 2252 | msgid "# DHT requests combined" |
2299 | msgstr "" | 2253 | msgstr "" |
2300 | 2254 | ||
2255 | #: src/dht/gnunet_dht_profiler.c:922 src/testbed/gnunet-testbed-profiler.c:255 | ||
2256 | #, c-format | ||
2257 | msgid "Exiting as the number of peers is %u\n" | ||
2258 | msgstr "" | ||
2259 | |||
2260 | #: src/dht/gnunet_dht_profiler.c:955 src/rps/gnunet-rps-profiler.c:3194 | ||
2261 | msgid "number of peers to start" | ||
2262 | msgstr "" | ||
2263 | |||
2264 | #: src/dht/gnunet_dht_profiler.c:961 | ||
2265 | msgid "number of PUTs to perform per peer" | ||
2266 | msgstr "" | ||
2267 | |||
2268 | #: src/dht/gnunet_dht_profiler.c:967 src/nse/gnunet-nse-profiler.c:872 | ||
2269 | #: src/testbed/gnunet-testbed-profiler.c:305 | ||
2270 | msgid "name of the file with the login information for the testbed" | ||
2271 | msgstr "" | ||
2272 | |||
2273 | #: src/dht/gnunet_dht_profiler.c:973 | ||
2274 | msgid "delay between rounds for collecting statistics (default: 30 sec)" | ||
2275 | msgstr "" | ||
2276 | |||
2277 | #: src/dht/gnunet_dht_profiler.c:979 | ||
2278 | msgid "delay to start doing PUTs (default: 1 sec)" | ||
2279 | msgstr "" | ||
2280 | |||
2281 | #: src/dht/gnunet_dht_profiler.c:985 | ||
2282 | msgid "delay to start doing GETs (default: 5 min)" | ||
2283 | msgstr "" | ||
2284 | |||
2285 | #: src/dht/gnunet_dht_profiler.c:990 | ||
2286 | msgid "replication degree for DHT PUTs" | ||
2287 | msgstr "" | ||
2288 | |||
2289 | #: src/dht/gnunet_dht_profiler.c:996 | ||
2290 | msgid "chance that a peer is selected at random for PUTs" | ||
2291 | msgstr "" | ||
2292 | |||
2293 | #: src/dht/gnunet_dht_profiler.c:1002 | ||
2294 | msgid "timeout for DHT PUT and GET requests (default: 1 min)" | ||
2295 | msgstr "" | ||
2296 | |||
2297 | #: src/dht/gnunet_dht_profiler.c:1023 | ||
2298 | msgid "Measure quality and performance of the DHT service." | ||
2299 | msgstr "" | ||
2300 | |||
2301 | #: src/dht/plugin_block_dht.c:189 | 2301 | #: src/dht/plugin_block_dht.c:189 |
2302 | #, c-format | 2302 | #, c-format |
2303 | msgid "Block not of type %u\n" | 2303 | msgid "Block not of type %u\n" |
@@ -3207,14 +3207,6 @@ msgid "" | |||
3207 | "chk/...)" | 3207 | "chk/...)" |
3208 | msgstr "" | 3208 | msgstr "" |
3209 | 3209 | ||
3210 | #: src/fs/gnunet-fs.c:128 | ||
3211 | msgid "print a list of all indexed files" | ||
3212 | msgstr "" | ||
3213 | |||
3214 | #: src/fs/gnunet-fs.c:141 | ||
3215 | msgid "Special file-sharing operations" | ||
3216 | msgstr "" | ||
3217 | |||
3218 | #: src/fs/gnunet-fs-profiler.c:211 | 3210 | #: src/fs/gnunet-fs-profiler.c:211 |
3219 | msgid "run the experiment with COUNT peers" | 3211 | msgid "run the experiment with COUNT peers" |
3220 | msgstr "" | 3212 | msgstr "" |
@@ -3231,6 +3223,14 @@ msgstr "" | |||
3231 | msgid "run a testbed to measure file-sharing performance" | 3223 | msgid "run a testbed to measure file-sharing performance" |
3232 | msgstr "" | 3224 | msgstr "" |
3233 | 3225 | ||
3226 | #: src/fs/gnunet-fs.c:128 | ||
3227 | msgid "print a list of all indexed files" | ||
3228 | msgstr "" | ||
3229 | |||
3230 | #: src/fs/gnunet-fs.c:141 | ||
3231 | msgid "Special file-sharing operations" | ||
3232 | msgstr "" | ||
3233 | |||
3234 | #: src/fs/gnunet-publish.c:219 src/fs/gnunet-publish.c:234 | 3234 | #: src/fs/gnunet-publish.c:219 src/fs/gnunet-publish.c:234 |
3235 | #, c-format | 3235 | #, c-format |
3236 | msgid "Publishing `%s' at %llu/%llu (%s remaining)\n" | 3236 | msgid "Publishing `%s' at %llu/%llu (%s remaining)\n" |
@@ -3885,49 +3885,6 @@ msgstr "" | |||
3885 | msgid "look for GNS2DNS records instead of ANY" | 3885 | msgid "look for GNS2DNS records instead of ANY" |
3886 | msgstr "" | 3886 | msgstr "" |
3887 | 3887 | ||
3888 | #: src/gns/gnunet-gns.c:257 | ||
3889 | #, fuzzy, c-format | ||
3890 | msgid "`%s' is not a valid DNS domain name\n" | ||
3891 | msgstr "`%s' non è un indirizzo IP valido.\n" | ||
3892 | |||
3893 | #: src/gns/gnunet-gns.c:267 src/util/dnsparser.c:254 | ||
3894 | #, c-format | ||
3895 | msgid "Failed to convert DNS IDNA name `%s' to UTF-8: %s\n" | ||
3896 | msgstr "" | ||
3897 | |||
3898 | #: src/gns/gnunet-gns.c:281 | ||
3899 | msgid "Cannot resolve using GNS: GNUnet peer not running\n" | ||
3900 | msgstr "" | ||
3901 | |||
3902 | #: src/gns/gnunet-gns.c:305 | ||
3903 | #, c-format | ||
3904 | msgid "Invalid typename specified, assuming `ANY'\n" | ||
3905 | msgstr "" | ||
3906 | |||
3907 | #: src/gns/gnunet-gns.c:340 | ||
3908 | msgid "Lookup a record for the given name" | ||
3909 | msgstr "" | ||
3910 | |||
3911 | #: src/gns/gnunet-gns.c:346 | ||
3912 | msgid "Specify the type of the record to lookup" | ||
3913 | msgstr "" | ||
3914 | |||
3915 | #: src/gns/gnunet-gns.c:352 | ||
3916 | msgid "Specify a timeout for the lookup" | ||
3917 | msgstr "" | ||
3918 | |||
3919 | #: src/gns/gnunet-gns.c:356 | ||
3920 | msgid "No unneeded output" | ||
3921 | msgstr "" | ||
3922 | |||
3923 | #: src/gns/gnunet-gns.c:361 | ||
3924 | msgid "DNS Compatibility: Name is passed in IDNA instead of UTF-8" | ||
3925 | msgstr "" | ||
3926 | |||
3927 | #: src/gns/gnunet-gns.c:375 | ||
3928 | msgid "GNUnet GNS resolver tool" | ||
3929 | msgstr "" | ||
3930 | |||
3931 | #: src/gns/gnunet-gns-import.c:486 | 3888 | #: src/gns/gnunet-gns-import.c:486 |
3932 | msgid "This program will import some GNS authorities into your GNS namestore." | 3889 | msgid "This program will import some GNS authorities into your GNS namestore." |
3933 | msgstr "" | 3890 | msgstr "" |
@@ -4047,6 +4004,49 @@ msgstr "" | |||
4047 | msgid "GNUnet GNS proxy" | 4004 | msgid "GNUnet GNS proxy" |
4048 | msgstr "" | 4005 | msgstr "" |
4049 | 4006 | ||
4007 | #: src/gns/gnunet-gns.c:257 | ||
4008 | #, fuzzy, c-format | ||
4009 | msgid "`%s' is not a valid DNS domain name\n" | ||
4010 | msgstr "`%s' non è un indirizzo IP valido.\n" | ||
4011 | |||
4012 | #: src/gns/gnunet-gns.c:267 src/util/dnsparser.c:254 | ||
4013 | #, c-format | ||
4014 | msgid "Failed to convert DNS IDNA name `%s' to UTF-8: %s\n" | ||
4015 | msgstr "" | ||
4016 | |||
4017 | #: src/gns/gnunet-gns.c:281 | ||
4018 | msgid "Cannot resolve using GNS: GNUnet peer not running\n" | ||
4019 | msgstr "" | ||
4020 | |||
4021 | #: src/gns/gnunet-gns.c:305 | ||
4022 | #, c-format | ||
4023 | msgid "Invalid typename specified, assuming `ANY'\n" | ||
4024 | msgstr "" | ||
4025 | |||
4026 | #: src/gns/gnunet-gns.c:340 | ||
4027 | msgid "Lookup a record for the given name" | ||
4028 | msgstr "" | ||
4029 | |||
4030 | #: src/gns/gnunet-gns.c:346 | ||
4031 | msgid "Specify the type of the record to lookup" | ||
4032 | msgstr "" | ||
4033 | |||
4034 | #: src/gns/gnunet-gns.c:352 | ||
4035 | msgid "Specify a timeout for the lookup" | ||
4036 | msgstr "" | ||
4037 | |||
4038 | #: src/gns/gnunet-gns.c:356 | ||
4039 | msgid "No unneeded output" | ||
4040 | msgstr "" | ||
4041 | |||
4042 | #: src/gns/gnunet-gns.c:361 | ||
4043 | msgid "DNS Compatibility: Name is passed in IDNA instead of UTF-8" | ||
4044 | msgstr "" | ||
4045 | |||
4046 | #: src/gns/gnunet-gns.c:375 | ||
4047 | msgid "GNUnet GNS resolver tool" | ||
4048 | msgstr "" | ||
4049 | |||
4050 | #: src/gns/gnunet-service-gns.c:505 | 4050 | #: src/gns/gnunet-service-gns.c:505 |
4051 | #, fuzzy | 4051 | #, fuzzy |
4052 | msgid "Properly base32-encoded public key required" | 4052 | msgid "Properly base32-encoded public key required" |
@@ -4057,8 +4057,8 @@ msgid "Failed to connect to the namecache!\n" | |||
4057 | msgstr "" | 4057 | msgstr "" |
4058 | 4058 | ||
4059 | #: src/gns/gnunet-service-gns.c:560 | 4059 | #: src/gns/gnunet-service-gns.c:560 |
4060 | #: src/zonemaster/gnunet-service-zonemaster.c:887 | ||
4061 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:444 | 4060 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:444 |
4061 | #: src/zonemaster/gnunet-service-zonemaster.c:887 | ||
4062 | msgid "Could not connect to DHT!\n" | 4062 | msgid "Could not connect to DHT!\n" |
4063 | msgstr "" | 4063 | msgstr "" |
4064 | 4064 | ||
@@ -4544,7 +4544,7 @@ msgid "# hostlist advertisements send" | |||
4544 | msgstr "" | 4544 | msgstr "" |
4545 | 4545 | ||
4546 | #: src/hostlist/gnunet-daemon-hostlist_server.c:674 | 4546 | #: src/hostlist/gnunet-daemon-hostlist_server.c:674 |
4547 | #: src/transport/gnunet-service-transport.c:2659 | 4547 | #: src/transport/gnunet-service-transport.c:2661 |
4548 | msgid "Could not access PEERINFO service. Exiting.\n" | 4548 | msgid "Could not access PEERINFO service. Exiting.\n" |
4549 | msgstr "" | 4549 | msgstr "" |
4550 | 4550 | ||
@@ -4793,6 +4793,68 @@ msgstr "" | |||
4793 | msgid "Failed to setup database at `%s'\n" | 4793 | msgid "Failed to setup database at `%s'\n" |
4794 | msgstr "Impossibile avviare il servizio ' %s'\n" | 4794 | msgstr "Impossibile avviare il servizio ' %s'\n" |
4795 | 4795 | ||
4796 | #: src/namestore/gnunet-namestore-fcfsd.c:552 | ||
4797 | #, c-format | ||
4798 | msgid "Unsupported form value `%s'\n" | ||
4799 | msgstr "" | ||
4800 | |||
4801 | #: src/namestore/gnunet-namestore-fcfsd.c:579 | ||
4802 | #, c-format | ||
4803 | msgid "Failed to create record for domain `%s': %s\n" | ||
4804 | msgstr "" | ||
4805 | |||
4806 | #: src/namestore/gnunet-namestore-fcfsd.c:600 | ||
4807 | msgid "Error when mapping zone to name\n" | ||
4808 | msgstr "" | ||
4809 | |||
4810 | #: src/namestore/gnunet-namestore-fcfsd.c:632 | ||
4811 | #, c-format | ||
4812 | msgid "Found existing name `%s' for the given key\n" | ||
4813 | msgstr "" | ||
4814 | |||
4815 | #: src/namestore/gnunet-namestore-fcfsd.c:694 | ||
4816 | #, c-format | ||
4817 | msgid "Found %u existing records for domain `%s'\n" | ||
4818 | msgstr "" | ||
4819 | |||
4820 | #: src/namestore/gnunet-namestore-fcfsd.c:784 | ||
4821 | #, c-format | ||
4822 | msgid "Failed to create page for `%s'\n" | ||
4823 | msgstr "" | ||
4824 | |||
4825 | #: src/namestore/gnunet-namestore-fcfsd.c:803 | ||
4826 | #, c-format | ||
4827 | msgid "Failed to setup post processor for `%s'\n" | ||
4828 | msgstr "" | ||
4829 | |||
4830 | #: src/namestore/gnunet-namestore-fcfsd.c:840 | ||
4831 | msgid "Domain name must not contain `.'\n" | ||
4832 | msgstr "" | ||
4833 | |||
4834 | #: src/namestore/gnunet-namestore-fcfsd.c:849 | ||
4835 | msgid "Domain name must not contain `+'\n" | ||
4836 | msgstr "" | ||
4837 | |||
4838 | #: src/namestore/gnunet-namestore-fcfsd.c:1084 | ||
4839 | msgid "No ego configured for `fcfsd` subsystem\n" | ||
4840 | msgstr "" | ||
4841 | |||
4842 | #: src/namestore/gnunet-namestore-fcfsd.c:1115 | ||
4843 | msgid "Failed to start HTTP server\n" | ||
4844 | msgstr "Impossibile avviare il server HTTP\n" | ||
4845 | |||
4846 | #: src/namestore/gnunet-namestore-fcfsd.c:1163 | ||
4847 | msgid "Failed to connect to identity\n" | ||
4848 | msgstr "" | ||
4849 | |||
4850 | #: src/namestore/gnunet-namestore-fcfsd.c:1190 | ||
4851 | msgid "name of the zone that is to be managed by FCFSD" | ||
4852 | msgstr "" | ||
4853 | |||
4854 | #: src/namestore/gnunet-namestore-fcfsd.c:1210 | ||
4855 | msgid "GNU Name System First Come First Serve name registration service" | ||
4856 | msgstr "" | ||
4857 | |||
4796 | #: src/namestore/gnunet-namestore.c:334 | 4858 | #: src/namestore/gnunet-namestore.c:334 |
4797 | #, c-format | 4859 | #, c-format |
4798 | msgid "Adding record failed: %s\n" | 4860 | msgid "Adding record failed: %s\n" |
@@ -5019,68 +5081,6 @@ msgstr "" | |||
5019 | msgid "name of the ego controlling the zone" | 5081 | msgid "name of the ego controlling the zone" |
5020 | msgstr "" | 5082 | msgstr "" |
5021 | 5083 | ||
5022 | #: src/namestore/gnunet-namestore-fcfsd.c:552 | ||
5023 | #, c-format | ||
5024 | msgid "Unsupported form value `%s'\n" | ||
5025 | msgstr "" | ||
5026 | |||
5027 | #: src/namestore/gnunet-namestore-fcfsd.c:579 | ||
5028 | #, c-format | ||
5029 | msgid "Failed to create record for domain `%s': %s\n" | ||
5030 | msgstr "" | ||
5031 | |||
5032 | #: src/namestore/gnunet-namestore-fcfsd.c:600 | ||
5033 | msgid "Error when mapping zone to name\n" | ||
5034 | msgstr "" | ||
5035 | |||
5036 | #: src/namestore/gnunet-namestore-fcfsd.c:632 | ||
5037 | #, c-format | ||
5038 | msgid "Found existing name `%s' for the given key\n" | ||
5039 | msgstr "" | ||
5040 | |||
5041 | #: src/namestore/gnunet-namestore-fcfsd.c:694 | ||
5042 | #, c-format | ||
5043 | msgid "Found %u existing records for domain `%s'\n" | ||
5044 | msgstr "" | ||
5045 | |||
5046 | #: src/namestore/gnunet-namestore-fcfsd.c:784 | ||
5047 | #, c-format | ||
5048 | msgid "Failed to create page for `%s'\n" | ||
5049 | msgstr "" | ||
5050 | |||
5051 | #: src/namestore/gnunet-namestore-fcfsd.c:803 | ||
5052 | #, c-format | ||
5053 | msgid "Failed to setup post processor for `%s'\n" | ||
5054 | msgstr "" | ||
5055 | |||
5056 | #: src/namestore/gnunet-namestore-fcfsd.c:840 | ||
5057 | msgid "Domain name must not contain `.'\n" | ||
5058 | msgstr "" | ||
5059 | |||
5060 | #: src/namestore/gnunet-namestore-fcfsd.c:849 | ||
5061 | msgid "Domain name must not contain `+'\n" | ||
5062 | msgstr "" | ||
5063 | |||
5064 | #: src/namestore/gnunet-namestore-fcfsd.c:1084 | ||
5065 | msgid "No ego configured for `fcfsd` subsystem\n" | ||
5066 | msgstr "" | ||
5067 | |||
5068 | #: src/namestore/gnunet-namestore-fcfsd.c:1115 | ||
5069 | msgid "Failed to start HTTP server\n" | ||
5070 | msgstr "Impossibile avviare il server HTTP\n" | ||
5071 | |||
5072 | #: src/namestore/gnunet-namestore-fcfsd.c:1163 | ||
5073 | msgid "Failed to connect to identity\n" | ||
5074 | msgstr "" | ||
5075 | |||
5076 | #: src/namestore/gnunet-namestore-fcfsd.c:1190 | ||
5077 | msgid "name of the zone that is to be managed by FCFSD" | ||
5078 | msgstr "" | ||
5079 | |||
5080 | #: src/namestore/gnunet-namestore-fcfsd.c:1210 | ||
5081 | msgid "GNU Name System First Come First Serve name registration service" | ||
5082 | msgstr "" | ||
5083 | |||
5084 | #: src/namestore/gnunet-service-namestore.c:866 | 5084 | #: src/namestore/gnunet-service-namestore.c:866 |
5085 | #, c-format | 5085 | #, c-format |
5086 | msgid "Failed to replicate block in namecache: %s\n" | 5086 | msgid "Failed to replicate block in namecache: %s\n" |
@@ -5387,10 +5387,6 @@ msgstr "" | |||
5387 | msgid "`upnpc' command not found\n" | 5387 | msgid "`upnpc' command not found\n" |
5388 | msgstr "" | 5388 | msgstr "" |
5389 | 5389 | ||
5390 | #: src/nse/gnunet-nse.c:124 | ||
5391 | msgid "Show network size estimates from NSE service." | ||
5392 | msgstr "" | ||
5393 | |||
5394 | #: src/nse/gnunet-nse-profiler.c:857 | 5390 | #: src/nse/gnunet-nse-profiler.c:857 |
5395 | msgid "limit to the number of connections to NSE services, 0 for none" | 5391 | msgid "limit to the number of connections to NSE services, 0 for none" |
5396 | msgstr "" | 5392 | msgstr "" |
@@ -5415,65 +5411,15 @@ msgstr "" | |||
5415 | msgid "Measure quality and performance of the NSE service." | 5411 | msgid "Measure quality and performance of the NSE service." |
5416 | msgstr "" | 5412 | msgstr "" |
5417 | 5413 | ||
5414 | #: src/nse/gnunet-nse.c:124 | ||
5415 | msgid "Show network size estimates from NSE service." | ||
5416 | msgstr "" | ||
5417 | |||
5418 | #: src/nse/gnunet-service-nse.c:1443 | 5418 | #: src/nse/gnunet-service-nse.c:1443 |
5419 | #: src/revocation/gnunet-service-revocation.c:834 src/util/gnunet-scrypt.c:257 | 5419 | #: src/revocation/gnunet-service-revocation.c:834 src/util/gnunet-scrypt.c:257 |
5420 | msgid "Value is too large.\n" | 5420 | msgid "Value is too large.\n" |
5421 | msgstr "" | 5421 | msgstr "" |
5422 | 5422 | ||
5423 | #: src/peerinfo/gnunet-service-peerinfo.c:175 | ||
5424 | #, c-format | ||
5425 | msgid "Removing expired address of transport `%s'\n" | ||
5426 | msgstr "" | ||
5427 | |||
5428 | #: src/peerinfo/gnunet-service-peerinfo.c:306 | ||
5429 | #, c-format | ||
5430 | msgid "Failed to parse HELLO in file `%s': %s\n" | ||
5431 | msgstr "" | ||
5432 | |||
5433 | #: src/peerinfo/gnunet-service-peerinfo.c:323 | ||
5434 | #: src/peerinfo/gnunet-service-peerinfo.c:348 | ||
5435 | #, c-format | ||
5436 | msgid "Failed to parse HELLO in file `%s'\n" | ||
5437 | msgstr "" | ||
5438 | |||
5439 | #: src/peerinfo/gnunet-service-peerinfo.c:426 | ||
5440 | msgid "# peers known" | ||
5441 | msgstr "# peer conosciuti" | ||
5442 | |||
5443 | #: src/peerinfo/gnunet-service-peerinfo.c:468 | ||
5444 | #, c-format | ||
5445 | msgid "" | ||
5446 | "File `%s' in directory `%s' does not match naming convention. Removed.\n" | ||
5447 | msgstr "" | ||
5448 | |||
5449 | #: src/peerinfo/gnunet-service-peerinfo.c:624 | ||
5450 | #, c-format | ||
5451 | msgid "Scanning directory `%s'\n" | ||
5452 | msgstr "" | ||
5453 | |||
5454 | #: src/peerinfo/gnunet-service-peerinfo.c:631 | ||
5455 | #, c-format | ||
5456 | msgid "Still no peers found in `%s'!\n" | ||
5457 | msgstr "" | ||
5458 | |||
5459 | #: src/peerinfo/gnunet-service-peerinfo.c:1024 | ||
5460 | #, c-format | ||
5461 | msgid "Cleaning up directory `%s'\n" | ||
5462 | msgstr "" | ||
5463 | |||
5464 | #: src/peerinfo/gnunet-service-peerinfo.c:1319 | ||
5465 | #, c-format | ||
5466 | msgid "Importing HELLOs from `%s'\n" | ||
5467 | msgstr "" | ||
5468 | |||
5469 | #: src/peerinfo/gnunet-service-peerinfo.c:1332 | ||
5470 | msgid "Skipping import of included HELLOs\n" | ||
5471 | msgstr "" | ||
5472 | |||
5473 | #: src/peerinfo/peerinfo_api.c:217 | ||
5474 | msgid "Failed to receive response from `PEERINFO' service." | ||
5475 | msgstr "" | ||
5476 | |||
5477 | #: src/peerinfo-tool/gnunet-peerinfo.c:237 | 5423 | #: src/peerinfo-tool/gnunet-peerinfo.c:237 |
5478 | #, c-format | 5424 | #, c-format |
5479 | msgid "%sPeer `%s'\n" | 5425 | msgid "%sPeer `%s'\n" |
@@ -5568,6 +5514,60 @@ msgstr "" | |||
5568 | msgid "Peerinfo REST API initialized\n" | 5514 | msgid "Peerinfo REST API initialized\n" |
5569 | msgstr "" | 5515 | msgstr "" |
5570 | 5516 | ||
5517 | #: src/peerinfo/gnunet-service-peerinfo.c:175 | ||
5518 | #, c-format | ||
5519 | msgid "Removing expired address of transport `%s'\n" | ||
5520 | msgstr "" | ||
5521 | |||
5522 | #: src/peerinfo/gnunet-service-peerinfo.c:306 | ||
5523 | #, c-format | ||
5524 | msgid "Failed to parse HELLO in file `%s': %s\n" | ||
5525 | msgstr "" | ||
5526 | |||
5527 | #: src/peerinfo/gnunet-service-peerinfo.c:323 | ||
5528 | #: src/peerinfo/gnunet-service-peerinfo.c:348 | ||
5529 | #, c-format | ||
5530 | msgid "Failed to parse HELLO in file `%s'\n" | ||
5531 | msgstr "" | ||
5532 | |||
5533 | #: src/peerinfo/gnunet-service-peerinfo.c:426 | ||
5534 | msgid "# peers known" | ||
5535 | msgstr "# peer conosciuti" | ||
5536 | |||
5537 | #: src/peerinfo/gnunet-service-peerinfo.c:468 | ||
5538 | #, c-format | ||
5539 | msgid "" | ||
5540 | "File `%s' in directory `%s' does not match naming convention. Removed.\n" | ||
5541 | msgstr "" | ||
5542 | |||
5543 | #: src/peerinfo/gnunet-service-peerinfo.c:624 | ||
5544 | #, c-format | ||
5545 | msgid "Scanning directory `%s'\n" | ||
5546 | msgstr "" | ||
5547 | |||
5548 | #: src/peerinfo/gnunet-service-peerinfo.c:631 | ||
5549 | #, c-format | ||
5550 | msgid "Still no peers found in `%s'!\n" | ||
5551 | msgstr "" | ||
5552 | |||
5553 | #: src/peerinfo/gnunet-service-peerinfo.c:1024 | ||
5554 | #, c-format | ||
5555 | msgid "Cleaning up directory `%s'\n" | ||
5556 | msgstr "" | ||
5557 | |||
5558 | #: src/peerinfo/gnunet-service-peerinfo.c:1319 | ||
5559 | #, c-format | ||
5560 | msgid "Importing HELLOs from `%s'\n" | ||
5561 | msgstr "" | ||
5562 | |||
5563 | #: src/peerinfo/gnunet-service-peerinfo.c:1332 | ||
5564 | msgid "Skipping import of included HELLOs\n" | ||
5565 | msgstr "" | ||
5566 | |||
5567 | #: src/peerinfo/peerinfo_api.c:217 | ||
5568 | msgid "Failed to receive response from `PEERINFO' service." | ||
5569 | msgstr "" | ||
5570 | |||
5571 | #: src/peerstore/gnunet-peerstore.c:92 | 5571 | #: src/peerstore/gnunet-peerstore.c:92 |
5572 | msgid "peerstore" | 5572 | msgid "peerstore" |
5573 | msgstr "" | 5573 | msgstr "" |
@@ -6007,18 +6007,6 @@ msgstr "" | |||
6007 | msgid "Could not open revocation database file!" | 6007 | msgid "Could not open revocation database file!" |
6008 | msgstr "" | 6008 | msgstr "" |
6009 | 6009 | ||
6010 | #: src/rps/gnunet-rps.c:270 | ||
6011 | msgid "Seed a PeerID" | ||
6012 | msgstr "" | ||
6013 | |||
6014 | #: src/rps/gnunet-rps.c:275 | ||
6015 | msgid "Get updates of view (0 for infinite updates)" | ||
6016 | msgstr "" | ||
6017 | |||
6018 | #: src/rps/gnunet-rps.c:279 | ||
6019 | msgid "Get peers from biased stream" | ||
6020 | msgstr "" | ||
6021 | |||
6022 | #: src/rps/gnunet-rps-profiler.c:3200 | 6010 | #: src/rps/gnunet-rps-profiler.c:3200 |
6023 | msgid "duration of the profiling" | 6011 | msgid "duration of the profiling" |
6024 | msgstr "" | 6012 | msgstr "" |
@@ -6035,6 +6023,18 @@ msgstr "" | |||
6035 | msgid "Measure quality and performance of the RPS service." | 6023 | msgid "Measure quality and performance of the RPS service." |
6036 | msgstr "" | 6024 | msgstr "" |
6037 | 6025 | ||
6026 | #: src/rps/gnunet-rps.c:270 | ||
6027 | msgid "Seed a PeerID" | ||
6028 | msgstr "" | ||
6029 | |||
6030 | #: src/rps/gnunet-rps.c:275 | ||
6031 | msgid "Get updates of view (0 for infinite updates)" | ||
6032 | msgstr "" | ||
6033 | |||
6034 | #: src/rps/gnunet-rps.c:279 | ||
6035 | msgid "Get peers from biased stream" | ||
6036 | msgstr "" | ||
6037 | |||
6038 | #: src/scalarproduct/gnunet-scalarproduct.c:229 | 6038 | #: src/scalarproduct/gnunet-scalarproduct.c:229 |
6039 | msgid "You must specify at least one message ID to check!\n" | 6039 | msgid "You must specify at least one message ID to check!\n" |
6040 | msgstr "" | 6040 | msgstr "" |
@@ -6089,10 +6089,10 @@ msgstr "" | |||
6089 | msgid "Calculate the Vectorproduct with a GNUnet peer." | 6089 | msgid "Calculate the Vectorproduct with a GNUnet peer." |
6090 | msgstr "" | 6090 | msgstr "" |
6091 | 6091 | ||
6092 | #: src/scalarproduct/gnunet-service-scalarproduct_alice.c:1358 | ||
6093 | #: src/scalarproduct/gnunet-service-scalarproduct_bob.c:1355 | ||
6094 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_alice.c:1118 | 6092 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_alice.c:1118 |
6095 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c:1063 | 6093 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c:1063 |
6094 | #: src/scalarproduct/gnunet-service-scalarproduct_alice.c:1358 | ||
6095 | #: src/scalarproduct/gnunet-service-scalarproduct_bob.c:1355 | ||
6096 | msgid "Connect to CADET failed\n" | 6096 | msgid "Connect to CADET failed\n" |
6097 | msgstr "" | 6097 | msgstr "" |
6098 | 6098 | ||
@@ -6442,15 +6442,6 @@ msgstr "" | |||
6442 | msgid "%.s Unknown result code." | 6442 | msgid "%.s Unknown result code." |
6443 | msgstr "" | 6443 | msgstr "" |
6444 | 6444 | ||
6445 | #: src/testbed/gnunet_testbed_mpi_spawn.c:119 | ||
6446 | msgid "Waiting for child to exit.\n" | ||
6447 | msgstr "" | ||
6448 | |||
6449 | #: src/testbed/gnunet_testbed_mpi_spawn.c:242 | ||
6450 | #, c-format | ||
6451 | msgid "Spawning process `%s'\n" | ||
6452 | msgstr "" | ||
6453 | |||
6454 | #: src/testbed/gnunet-testbed-profiler.c:290 | 6445 | #: src/testbed/gnunet-testbed-profiler.c:290 |
6455 | msgid "tolerate COUNT number of continious timeout failures" | 6446 | msgid "tolerate COUNT number of continious timeout failures" |
6456 | msgstr "" | 6447 | msgstr "" |
@@ -6462,6 +6453,15 @@ msgid "" | |||
6462 | "signal is received" | 6453 | "signal is received" |
6463 | msgstr "" | 6454 | msgstr "" |
6464 | 6455 | ||
6456 | #: src/testbed/gnunet_testbed_mpi_spawn.c:119 | ||
6457 | msgid "Waiting for child to exit.\n" | ||
6458 | msgstr "" | ||
6459 | |||
6460 | #: src/testbed/gnunet_testbed_mpi_spawn.c:242 | ||
6461 | #, c-format | ||
6462 | msgid "Spawning process `%s'\n" | ||
6463 | msgstr "" | ||
6464 | |||
6465 | #: src/testbed/testbed_api.c:399 | 6465 | #: src/testbed/testbed_api.c:399 |
6466 | #, c-format | 6466 | #, c-format |
6467 | msgid "Adding host %u failed with error: %s\n" | 6467 | msgid "Adding host %u failed with error: %s\n" |
@@ -6749,18 +6749,18 @@ msgstr "" | |||
6749 | msgid "GNUnet topology control" | 6749 | msgid "GNUnet topology control" |
6750 | msgstr "" | 6750 | msgstr "" |
6751 | 6751 | ||
6752 | #: src/transport/gnunet-communicator-tcp.c:3189 | 6752 | #: src/transport/gnunet-communicator-tcp.c:3221 |
6753 | #: src/transport/gnunet-communicator-udp.c:2826 | 6753 | #: src/transport/gnunet-communicator-udp.c:2995 |
6754 | #: src/transport/gnunet-service-tng.c:10014 | 6754 | #: src/transport/gnunet-service-tng.c:10014 |
6755 | #: src/transport/gnunet-service-transport.c:2624 | 6755 | #: src/transport/gnunet-service-transport.c:2626 |
6756 | msgid "Transport service is lacking key configuration settings. Exiting.\n" | 6756 | msgid "Transport service is lacking key configuration settings. Exiting.\n" |
6757 | msgstr "" | 6757 | msgstr "" |
6758 | 6758 | ||
6759 | #: src/transport/gnunet-communicator-tcp.c:3494 | 6759 | #: src/transport/gnunet-communicator-tcp.c:3553 |
6760 | msgid "GNUnet TCP communicator" | 6760 | msgid "GNUnet TCP communicator" |
6761 | msgstr "" | 6761 | msgstr "" |
6762 | 6762 | ||
6763 | #: src/transport/gnunet-communicator-udp.c:2898 | 6763 | #: src/transport/gnunet-communicator-udp.c:3067 |
6764 | msgid "GNUnet UDP communicator" | 6764 | msgid "GNUnet UDP communicator" |
6765 | msgstr "" | 6765 | msgstr "" |
6766 | 6766 | ||
@@ -6783,50 +6783,50 @@ msgstr "" | |||
6783 | msgid "GNUnet UNIX domain socket communicator" | 6783 | msgid "GNUnet UNIX domain socket communicator" |
6784 | msgstr "" | 6784 | msgstr "" |
6785 | 6785 | ||
6786 | #: src/transport/gnunet-service-transport_ats.c:137 | ||
6787 | msgid "# Addresses given to ATS" | ||
6788 | msgstr "" | ||
6789 | |||
6790 | #: src/transport/gnunet-service-transport.c:445 | 6786 | #: src/transport/gnunet-service-transport.c:445 |
6791 | msgid "# messages dropped due to slow client" | 6787 | msgid "# messages dropped due to slow client" |
6792 | msgstr "" | 6788 | msgstr "" |
6793 | 6789 | ||
6794 | #: src/transport/gnunet-service-transport.c:794 | 6790 | #: src/transport/gnunet-service-transport.c:796 |
6795 | msgid "# bytes payload dropped (other peer was not connected)" | 6791 | msgid "# bytes payload dropped (other peer was not connected)" |
6796 | msgstr "" | 6792 | msgstr "" |
6797 | 6793 | ||
6798 | #: src/transport/gnunet-service-transport.c:1477 | 6794 | #: src/transport/gnunet-service-transport.c:1479 |
6799 | msgid "# bytes payload discarded due to not connected peer" | 6795 | msgid "# bytes payload discarded due to not connected peer" |
6800 | msgstr "" | 6796 | msgstr "" |
6801 | 6797 | ||
6802 | #: src/transport/gnunet-service-transport.c:1622 | 6798 | #: src/transport/gnunet-service-transport.c:1624 |
6803 | msgid "# bytes total received" | 6799 | msgid "# bytes total received" |
6804 | msgstr "" | 6800 | msgstr "" |
6805 | 6801 | ||
6806 | #: src/transport/gnunet-service-transport.c:1712 | 6802 | #: src/transport/gnunet-service-transport.c:1714 |
6807 | msgid "# bytes payload received" | 6803 | msgid "# bytes payload received" |
6808 | msgstr "" | 6804 | msgstr "" |
6809 | 6805 | ||
6810 | #: src/transport/gnunet-service-transport.c:2016 | 6806 | #: src/transport/gnunet-service-transport.c:2018 |
6811 | #: src/transport/gnunet-service-transport.c:2450 | 6807 | #: src/transport/gnunet-service-transport.c:2452 |
6812 | msgid "# disconnects due to blacklist" | 6808 | msgid "# disconnects due to blacklist" |
6813 | msgstr "" | 6809 | msgstr "" |
6814 | 6810 | ||
6815 | #: src/transport/gnunet-service-transport.c:2454 | 6811 | #: src/transport/gnunet-service-transport.c:2456 |
6816 | #, c-format | 6812 | #, c-format |
6817 | msgid "Disallowing connection to peer `%s' on transport %s\n" | 6813 | msgid "Disallowing connection to peer `%s' on transport %s\n" |
6818 | msgstr "" | 6814 | msgstr "" |
6819 | 6815 | ||
6820 | #: src/transport/gnunet-service-transport.c:2549 | 6816 | #: src/transport/gnunet-service-transport.c:2551 |
6821 | #, c-format | 6817 | #, c-format |
6822 | msgid "Adding blacklisting entry for peer `%s'\n" | 6818 | msgid "Adding blacklisting entry for peer `%s'\n" |
6823 | msgstr "" | 6819 | msgstr "" |
6824 | 6820 | ||
6825 | #: src/transport/gnunet-service-transport.c:2558 | 6821 | #: src/transport/gnunet-service-transport.c:2560 |
6826 | #, c-format | 6822 | #, c-format |
6827 | msgid "Adding blacklisting entry for peer `%s':`%s'\n" | 6823 | msgid "Adding blacklisting entry for peer `%s':`%s'\n" |
6828 | msgstr "" | 6824 | msgstr "" |
6829 | 6825 | ||
6826 | #: src/transport/gnunet-service-transport_ats.c:137 | ||
6827 | msgid "# Addresses given to ATS" | ||
6828 | msgstr "" | ||
6829 | |||
6830 | #: src/transport/gnunet-service-transport_hello.c:195 | 6830 | #: src/transport/gnunet-service-transport_hello.c:195 |
6831 | msgid "# refreshed my HELLO" | 6831 | msgid "# refreshed my HELLO" |
6832 | msgstr "" | 6832 | msgstr "" |
@@ -7144,6 +7144,41 @@ msgstr "" | |||
7144 | msgid "# HELLOs given to peerinfo" | 7144 | msgid "# HELLOs given to peerinfo" |
7145 | msgstr "" | 7145 | msgstr "" |
7146 | 7146 | ||
7147 | #: src/transport/gnunet-transport-profiler.c:220 | ||
7148 | #, c-format | ||
7149 | msgid "%llu B in %llu ms == %.2f KB/s!\n" | ||
7150 | msgstr "" | ||
7151 | |||
7152 | #: src/transport/gnunet-transport-profiler.c:577 | ||
7153 | msgid "send data to peer" | ||
7154 | msgstr "" | ||
7155 | |||
7156 | #: src/transport/gnunet-transport-profiler.c:581 | ||
7157 | msgid "receive data from peer" | ||
7158 | msgstr "" | ||
7159 | |||
7160 | #: src/transport/gnunet-transport-profiler.c:586 | ||
7161 | msgid "iterations" | ||
7162 | msgstr "" | ||
7163 | |||
7164 | #: src/transport/gnunet-transport-profiler.c:591 | ||
7165 | msgid "number of messages to send" | ||
7166 | msgstr "" | ||
7167 | |||
7168 | #: src/transport/gnunet-transport-profiler.c:596 | ||
7169 | msgid "message size to use" | ||
7170 | msgstr "" | ||
7171 | |||
7172 | #: src/transport/gnunet-transport-profiler.c:601 | ||
7173 | #: src/transport/gnunet-transport.c:1404 | ||
7174 | msgid "peer identity" | ||
7175 | msgstr "" | ||
7176 | |||
7177 | #: src/transport/gnunet-transport-profiler.c:614 | ||
7178 | #: src/transport/gnunet-transport.c:1426 | ||
7179 | msgid "Direct access to transport service." | ||
7180 | msgstr "" | ||
7181 | |||
7147 | #: src/transport/gnunet-transport.c:406 | 7182 | #: src/transport/gnunet-transport.c:406 |
7148 | #, c-format | 7183 | #, c-format |
7149 | msgid "Transmitted %llu bytes/s (%llu bytes in %s)\n" | 7184 | msgid "Transmitted %llu bytes/s (%llu bytes in %s)\n" |
@@ -7276,11 +7311,6 @@ msgstr "" | |||
7276 | msgid "do not resolve hostnames" | 7311 | msgid "do not resolve hostnames" |
7277 | msgstr "" | 7312 | msgstr "" |
7278 | 7313 | ||
7279 | #: src/transport/gnunet-transport.c:1404 | ||
7280 | #: src/transport/gnunet-transport-profiler.c:601 | ||
7281 | msgid "peer identity" | ||
7282 | msgstr "" | ||
7283 | |||
7284 | #: src/transport/gnunet-transport.c:1408 | 7314 | #: src/transport/gnunet-transport.c:1408 |
7285 | msgid "monitor plugin sessions" | 7315 | msgid "monitor plugin sessions" |
7286 | msgstr "" | 7316 | msgstr "" |
@@ -7289,36 +7319,6 @@ msgstr "" | |||
7289 | msgid "send data for benchmarking to the other peer (until CTRL-C)" | 7319 | msgid "send data for benchmarking to the other peer (until CTRL-C)" |
7290 | msgstr "" | 7320 | msgstr "" |
7291 | 7321 | ||
7292 | #: src/transport/gnunet-transport.c:1426 | ||
7293 | #: src/transport/gnunet-transport-profiler.c:614 | ||
7294 | msgid "Direct access to transport service." | ||
7295 | msgstr "" | ||
7296 | |||
7297 | #: src/transport/gnunet-transport-profiler.c:220 | ||
7298 | #, c-format | ||
7299 | msgid "%llu B in %llu ms == %.2f KB/s!\n" | ||
7300 | msgstr "" | ||
7301 | |||
7302 | #: src/transport/gnunet-transport-profiler.c:577 | ||
7303 | msgid "send data to peer" | ||
7304 | msgstr "" | ||
7305 | |||
7306 | #: src/transport/gnunet-transport-profiler.c:581 | ||
7307 | msgid "receive data from peer" | ||
7308 | msgstr "" | ||
7309 | |||
7310 | #: src/transport/gnunet-transport-profiler.c:586 | ||
7311 | msgid "iterations" | ||
7312 | msgstr "" | ||
7313 | |||
7314 | #: src/transport/gnunet-transport-profiler.c:591 | ||
7315 | msgid "number of messages to send" | ||
7316 | msgstr "" | ||
7317 | |||
7318 | #: src/transport/gnunet-transport-profiler.c:596 | ||
7319 | msgid "message size to use" | ||
7320 | msgstr "" | ||
7321 | |||
7322 | #: src/transport/plugin_transport_http_client.c:1489 | 7322 | #: src/transport/plugin_transport_http_client.c:1489 |
7323 | #: src/transport/plugin_transport_http_server.c:2331 | 7323 | #: src/transport/plugin_transport_http_server.c:2331 |
7324 | #: src/transport/plugin_transport_http_server.c:3562 | 7324 | #: src/transport/plugin_transport_http_server.c:3562 |
@@ -7585,21 +7585,6 @@ msgstr "" | |||
7585 | msgid "TCP transport advertises itself as being on port %llu\n" | 7585 | msgid "TCP transport advertises itself as being on port %llu\n" |
7586 | msgstr "" | 7586 | msgstr "" |
7587 | 7587 | ||
7588 | #: src/transport/plugin_transport_udp_broadcasting.c:169 | ||
7589 | #, fuzzy | ||
7590 | msgid "# Multicast HELLO beacons received via UDP" | ||
7591 | msgstr "# messaggi PONG ricevuti" | ||
7592 | |||
7593 | #: src/transport/plugin_transport_udp_broadcasting.c:553 | ||
7594 | msgid "" | ||
7595 | "Disabling HELLO broadcasting due to friend-to-friend only configuration!\n" | ||
7596 | msgstr "" | ||
7597 | |||
7598 | #: src/transport/plugin_transport_udp_broadcasting.c:571 | ||
7599 | #, c-format | ||
7600 | msgid "Failed to set IPv4 broadcast option for broadcast socket on port %d\n" | ||
7601 | msgstr "" | ||
7602 | |||
7603 | #: src/transport/plugin_transport_udp.c:3169 | 7588 | #: src/transport/plugin_transport_udp.c:3169 |
7604 | #, c-format | 7589 | #, c-format |
7605 | msgid "" | 7590 | msgid "" |
@@ -7646,6 +7631,21 @@ msgstr "deve essere un indirizzo IPv4 valido" | |||
7646 | msgid "Failed to create UDP network sockets\n" | 7631 | msgid "Failed to create UDP network sockets\n" |
7647 | msgstr "Generazione statistiche fallita\n" | 7632 | msgstr "Generazione statistiche fallita\n" |
7648 | 7633 | ||
7634 | #: src/transport/plugin_transport_udp_broadcasting.c:169 | ||
7635 | #, fuzzy | ||
7636 | msgid "# Multicast HELLO beacons received via UDP" | ||
7637 | msgstr "# messaggi PONG ricevuti" | ||
7638 | |||
7639 | #: src/transport/plugin_transport_udp_broadcasting.c:553 | ||
7640 | msgid "" | ||
7641 | "Disabling HELLO broadcasting due to friend-to-friend only configuration!\n" | ||
7642 | msgstr "" | ||
7643 | |||
7644 | #: src/transport/plugin_transport_udp_broadcasting.c:571 | ||
7645 | #, c-format | ||
7646 | msgid "Failed to set IPv4 broadcast option for broadcast socket on port %d\n" | ||
7647 | msgstr "" | ||
7648 | |||
7649 | #: src/transport/plugin_transport_unix.c:1396 | 7649 | #: src/transport/plugin_transport_unix.c:1396 |
7650 | #, fuzzy, c-format | 7650 | #, fuzzy, c-format |
7651 | msgid "Cannot bind to `%s'\n" | 7651 | msgid "Cannot bind to `%s'\n" |
@@ -7824,7 +7824,7 @@ msgid "do daemonize (detach from terminal)" | |||
7824 | msgstr "" | 7824 | msgstr "" |
7825 | 7825 | ||
7826 | #: src/transport/tcp_service_legacy.c:1397 | 7826 | #: src/transport/tcp_service_legacy.c:1397 |
7827 | #: src/transport/transport-testing2.c:1116 src/util/service.c:2072 | 7827 | #: src/transport/transport-testing2.c:983 src/util/service.c:2072 |
7828 | #: src/util/service.c:2084 | 7828 | #: src/util/service.c:2084 |
7829 | #, c-format | 7829 | #, c-format |
7830 | msgid "Malformed configuration file `%s', exit ...\n" | 7830 | msgid "Malformed configuration file `%s', exit ...\n" |
@@ -8482,19 +8482,19 @@ msgid "" | |||
8482 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" | 8482 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" |
8483 | msgstr "" | 8483 | msgstr "" |
8484 | 8484 | ||
8485 | #: src/util/os_installation.c:409 | 8485 | #: src/util/os_installation.c:411 |
8486 | #, c-format | 8486 | #, c-format |
8487 | msgid "" | 8487 | msgid "" |
8488 | "Could not determine installation path for %s. Set `%s' environment " | 8488 | "Could not determine installation path for %s. Set `%s' environment " |
8489 | "variable.\n" | 8489 | "variable.\n" |
8490 | msgstr "" | 8490 | msgstr "" |
8491 | 8491 | ||
8492 | #: src/util/os_installation.c:792 | 8492 | #: src/util/os_installation.c:794 |
8493 | #, c-format | 8493 | #, c-format |
8494 | msgid "Could not find binary `%s' in PATH!\n" | 8494 | msgid "Could not find binary `%s' in PATH!\n" |
8495 | msgstr "" | 8495 | msgstr "" |
8496 | 8496 | ||
8497 | #: src/util/os_installation.c:825 | 8497 | #: src/util/os_installation.c:827 |
8498 | #, c-format | 8498 | #, c-format |
8499 | msgid "Binary `%s' exists, but is not SUID\n" | 8499 | msgid "Binary `%s' exists, but is not SUID\n" |
8500 | msgstr "" | 8500 | msgstr "" |
@@ -8518,17 +8518,17 @@ msgstr "" | |||
8518 | msgid "Could not determine plugin installation path.\n" | 8518 | msgid "Could not determine plugin installation path.\n" |
8519 | msgstr "" | 8519 | msgstr "" |
8520 | 8520 | ||
8521 | #: src/util/program.c:262 | 8521 | #: src/util/program.c:267 |
8522 | #, c-format | 8522 | #, c-format |
8523 | msgid "Unreadable or malformed configuration file `%s', exit ...\n" | 8523 | msgid "Unreadable or malformed configuration file `%s', exit ...\n" |
8524 | msgstr "" | 8524 | msgstr "" |
8525 | 8525 | ||
8526 | #: src/util/program.c:279 | 8526 | #: src/util/program.c:284 |
8527 | #, c-format | 8527 | #, c-format |
8528 | msgid "Unreadable or malformed default configuration file `%s', exit ...\n" | 8528 | msgid "Unreadable or malformed default configuration file `%s', exit ...\n" |
8529 | msgstr "" | 8529 | msgstr "" |
8530 | 8530 | ||
8531 | #: src/util/program.c:294 | 8531 | #: src/util/program.c:299 |
8532 | msgid "Unreadable or malformed configuration, exit ...\n" | 8532 | msgid "Unreadable or malformed configuration, exit ...\n" |
8533 | msgstr "" | 8533 | msgstr "" |
8534 | 8534 | ||
@@ -8592,10 +8592,6 @@ msgstr "" | |||
8592 | msgid "Attempting to proxy service `%s' to invalid port %d or hostname.\n" | 8592 | msgid "Attempting to proxy service `%s' to invalid port %d or hostname.\n" |
8593 | msgstr "" | 8593 | msgstr "" |
8594 | 8594 | ||
8595 | #: src/util/strings.c:179 | ||
8596 | msgid "b" | ||
8597 | msgstr "" | ||
8598 | |||
8599 | #: src/util/strings.c:503 | 8595 | #: src/util/strings.c:503 |
8600 | #, c-format | 8596 | #, c-format |
8601 | msgid "Character sets requested were `%s'->`%s'\n" | 8597 | msgid "Character sets requested were `%s'->`%s'\n" |
@@ -8605,46 +8601,6 @@ msgstr "" | |||
8605 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" | 8601 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" |
8606 | msgstr "" | 8602 | msgstr "" |
8607 | 8603 | ||
8608 | #: src/util/strings.c:706 | ||
8609 | msgid "µs" | ||
8610 | msgstr "µs" | ||
8611 | |||
8612 | #: src/util/strings.c:710 | ||
8613 | msgid "forever" | ||
8614 | msgstr "per sempre" | ||
8615 | |||
8616 | #: src/util/strings.c:712 | ||
8617 | msgid "0 ms" | ||
8618 | msgstr "0 ms" | ||
8619 | |||
8620 | #: src/util/strings.c:716 | ||
8621 | msgid "ms" | ||
8622 | msgstr "ms" | ||
8623 | |||
8624 | #: src/util/strings.c:720 | ||
8625 | msgid "s" | ||
8626 | msgstr "s" | ||
8627 | |||
8628 | #: src/util/strings.c:724 | ||
8629 | msgid "m" | ||
8630 | msgstr "" | ||
8631 | |||
8632 | #: src/util/strings.c:728 | ||
8633 | msgid "h" | ||
8634 | msgstr "o" | ||
8635 | |||
8636 | #: src/util/strings.c:734 | ||
8637 | msgid "day" | ||
8638 | msgstr "giorno" | ||
8639 | |||
8640 | #: src/util/strings.c:736 | ||
8641 | msgid "days" | ||
8642 | msgstr "giorni" | ||
8643 | |||
8644 | #: src/util/strings.c:764 | ||
8645 | msgid "end of time" | ||
8646 | msgstr "" | ||
8647 | |||
8648 | #: src/util/strings.c:1240 | 8604 | #: src/util/strings.c:1240 |
8649 | msgid "IPv6 address did not start with `['\n" | 8605 | msgid "IPv6 address did not start with `['\n" |
8650 | msgstr "" | 8606 | msgstr "" |
@@ -8885,11 +8841,35 @@ msgstr "" | |||
8885 | msgid "Setup tunnels via VPN." | 8841 | msgid "Setup tunnels via VPN." |
8886 | msgstr "" | 8842 | msgstr "" |
8887 | 8843 | ||
8888 | #: src/zonemaster/gnunet-service-zonemaster.c:849 | ||
8889 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:420 | 8844 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:420 |
8845 | #: src/zonemaster/gnunet-service-zonemaster.c:849 | ||
8890 | msgid "Failed to connect to the namestore!\n" | 8846 | msgid "Failed to connect to the namestore!\n" |
8891 | msgstr "" | 8847 | msgstr "" |
8892 | 8848 | ||
8849 | #~ msgid "µs" | ||
8850 | #~ msgstr "µs" | ||
8851 | |||
8852 | #~ msgid "forever" | ||
8853 | #~ msgstr "per sempre" | ||
8854 | |||
8855 | #~ msgid "0 ms" | ||
8856 | #~ msgstr "0 ms" | ||
8857 | |||
8858 | #~ msgid "ms" | ||
8859 | #~ msgstr "ms" | ||
8860 | |||
8861 | #~ msgid "s" | ||
8862 | #~ msgstr "s" | ||
8863 | |||
8864 | #~ msgid "h" | ||
8865 | #~ msgstr "o" | ||
8866 | |||
8867 | #~ msgid "day" | ||
8868 | #~ msgstr "giorno" | ||
8869 | |||
8870 | #~ msgid "days" | ||
8871 | #~ msgstr "giorni" | ||
8872 | |||
8893 | #~ msgid "Request timed out" | 8873 | #~ msgid "Request timed out" |
8894 | #~ msgstr "Richiesta scaduta" | 8874 | #~ msgstr "Richiesta scaduta" |
8895 | 8875 | ||
diff --git a/po/sr.po b/po/sr.po new file mode 100644 index 000000000..981dc1d8e --- /dev/null +++ b/po/sr.po | |||
@@ -0,0 +1,8292 @@ | |||
1 | # Serbian translation for gnunet. | ||
2 | # Copyright © 2020 Christian Grothoff | ||
3 | # This file is distributed under the same license as the gnunet package. | ||
4 | # Мирослав Николић <miroslavnikolic@rocketmail.com>, 2020. | ||
5 | msgid "" | ||
6 | msgstr "" | ||
7 | "Project-Id-Version: gnunet-0.10.1\n" | ||
8 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" | ||
9 | "POT-Creation-Date: 2014-04-08 11:11+0200\n" | ||
10 | "PO-Revision-Date: 2020-10-23 18:39+0200\n" | ||
11 | "Last-Translator: Мирослав Николић <miroslavnikolic@rocketmail.com>\n" | ||
12 | "Language-Team: Serbian <(nothing)>\n" | ||
13 | "Language: sr\n" | ||
14 | "MIME-Version: 1.0\n" | ||
15 | "Content-Type: text/plain; charset=UTF-8\n" | ||
16 | "Content-Transfer-Encoding: 8bit\n" | ||
17 | "Plural-Forms: nplurals=3; plural=(n%10==1 && n%100!=11 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n" | ||
18 | "X-Bugs: Report translation errors to the Language-Team address.\n" | ||
19 | |||
20 | #: src/arm/arm_api.c:337 | ||
21 | msgid "Client was disconnected from arm service, trying to reconnect.\n" | ||
22 | msgstr "Клијент је ископчан са аур услуге, покушавам поново да се повежем.\n" | ||
23 | |||
24 | #: src/arm/arm_monitor_api.c:321 | ||
25 | msgid "Monitoring client was disconnected from arm service, trying to reconnect.\n" | ||
26 | msgstr "Клијент праћења је ископчан са аур услуге, покушавам поново да се повежем.\n" | ||
27 | |||
28 | #: src/arm/gnunet-arm.c:164 | ||
29 | #, c-format | ||
30 | msgid "Failed to remove configuration file %s\n" | ||
31 | msgstr "Нисам успео да уклоним датотеку подешавања „%s“\n" | ||
32 | |||
33 | #: src/arm/gnunet-arm.c:170 | ||
34 | #, c-format | ||
35 | msgid "Failed to remove servicehome directory %s\n" | ||
36 | msgstr "Нисам успео да уклоним матични директоријум услуге „%s“\n" | ||
37 | |||
38 | #: src/arm/gnunet-arm.c:216 src/testbed/gnunet-service-testbed_peers.c:1013 | ||
39 | msgid "Message was sent successfully" | ||
40 | msgstr "Порука је успешно послата" | ||
41 | |||
42 | #: src/arm/gnunet-arm.c:218 | ||
43 | msgid "Misconfiguration (can not connect to the ARM service)" | ||
44 | msgstr "Лоше подешавање (не могу да се повежем на АУР услугу)" | ||
45 | |||
46 | #: src/arm/gnunet-arm.c:220 src/testbed/gnunet-service-testbed_peers.c:1017 | ||
47 | msgid "We disconnected from ARM before we could send a request" | ||
48 | msgstr "Прекинута је веза са АУР-ом пре него ли можемо послати захтев" | ||
49 | |||
50 | #: src/arm/gnunet-arm.c:222 src/testbed/gnunet-service-testbed_peers.c:1019 | ||
51 | msgid "ARM API is busy" | ||
52 | msgstr "АУР АПИ је заузет" | ||
53 | |||
54 | #: src/arm/gnunet-arm.c:224 | ||
55 | msgid "Request does not fit into a message" | ||
56 | msgstr "Захтев не стаје у поруку" | ||
57 | |||
58 | #: src/arm/gnunet-arm.c:226 src/testbed/gnunet-service-testbed_peers.c:1023 | ||
59 | msgid "Request timed out" | ||
60 | msgstr "Истекло је време захтева" | ||
61 | |||
62 | #: src/arm/gnunet-arm.c:228 src/testbed/gnunet-service-testbed_peers.c:1025 | ||
63 | msgid "Unknown request status" | ||
64 | msgstr "Стање захтева је непознато" | ||
65 | |||
66 | #: src/arm/gnunet-arm.c:244 src/testbed/gnunet-service-testbed_peers.c:1041 | ||
67 | #, c-format | ||
68 | msgid "%s is stopped" | ||
69 | msgstr "„%s“ је заустављен" | ||
70 | |||
71 | #: src/arm/gnunet-arm.c:246 src/testbed/gnunet-service-testbed_peers.c:1043 | ||
72 | #, c-format | ||
73 | msgid "%s is starting" | ||
74 | msgstr "„%s“ се покреће" | ||
75 | |||
76 | #: src/arm/gnunet-arm.c:248 src/testbed/gnunet-service-testbed_peers.c:1045 | ||
77 | #, c-format | ||
78 | msgid "%s is stopping" | ||
79 | msgstr "„%s“ се зауставља" | ||
80 | |||
81 | #: src/arm/gnunet-arm.c:250 src/testbed/gnunet-service-testbed_peers.c:1047 | ||
82 | #, c-format | ||
83 | msgid "%s is starting already" | ||
84 | msgstr "„%s“ се већ покреће" | ||
85 | |||
86 | #: src/arm/gnunet-arm.c:252 src/testbed/gnunet-service-testbed_peers.c:1049 | ||
87 | #, c-format | ||
88 | msgid "%s is stopping already" | ||
89 | msgstr "„%s“ се већ зауставља" | ||
90 | |||
91 | #: src/arm/gnunet-arm.c:254 src/testbed/gnunet-service-testbed_peers.c:1051 | ||
92 | #, c-format | ||
93 | msgid "%s is started already" | ||
94 | msgstr "„%s“ је већ покренут" | ||
95 | |||
96 | #: src/arm/gnunet-arm.c:256 src/testbed/gnunet-service-testbed_peers.c:1053 | ||
97 | #, c-format | ||
98 | msgid "%s is stopped already" | ||
99 | msgstr "„%s“ је већ заустављен" | ||
100 | |||
101 | #: src/arm/gnunet-arm.c:258 src/testbed/gnunet-service-testbed_peers.c:1055 | ||
102 | #, c-format | ||
103 | msgid "%s service is not known to ARM" | ||
104 | msgstr "„%s“ услуга није позната АУР-у" | ||
105 | |||
106 | #: src/arm/gnunet-arm.c:260 src/testbed/gnunet-service-testbed_peers.c:1057 | ||
107 | #, c-format | ||
108 | msgid "%s service failed to start" | ||
109 | msgstr "„%s“ услуга није успела да се покрене" | ||
110 | |||
111 | #: src/arm/gnunet-arm.c:262 | ||
112 | #, c-format | ||
113 | msgid "%s service cannot be started because ARM is shutting down" | ||
114 | msgstr "„%s“ услуга се не може покренути јер се АУР гаси" | ||
115 | |||
116 | #: src/arm/gnunet-arm.c:264 src/testbed/gnunet-service-testbed_peers.c:1061 | ||
117 | #, c-format | ||
118 | msgid "%.s Unknown result code." | ||
119 | msgstr "%.s Непознат код резултата." | ||
120 | |||
121 | #: src/arm/gnunet-arm.c:297 | ||
122 | msgid "Fatal error initializing ARM API.\n" | ||
123 | msgstr "Кобна грешка покретања АУР АПИ-ја.\n" | ||
124 | |||
125 | #: src/arm/gnunet-arm.c:326 src/arm/gnunet-arm.c:335 | ||
126 | #, c-format | ||
127 | msgid "Failed to start the ARM service: %s\n" | ||
128 | msgstr "Нисам успео да покренем АУР услугу: %s\n" | ||
129 | |||
130 | #: src/arm/gnunet-arm.c:369 | ||
131 | #, c-format | ||
132 | msgid "Failed to send a stop request to the ARM service: %s\n" | ||
133 | msgstr "Нисам успео да пошаљем захтев за заустављање АУР услузи: %s\n" | ||
134 | |||
135 | #: src/arm/gnunet-arm.c:379 | ||
136 | #, c-format | ||
137 | msgid "Failed to stop the ARM service: %s\n" | ||
138 | msgstr "Нисам успео да зауставим АУР услугу: %s\n" | ||
139 | |||
140 | #: src/arm/gnunet-arm.c:421 | ||
141 | #, c-format | ||
142 | msgid "Failed to send a request to start the `%s' service: %%s\n" | ||
143 | msgstr "Нисам успео да пошаљем захтев за покретање „%s“ услузи: %%s\n" | ||
144 | |||
145 | #: src/arm/gnunet-arm.c:431 | ||
146 | #, c-format | ||
147 | msgid "Failed to start the `%s' service: %s\n" | ||
148 | msgstr "Нисам успео да покренем „%s“ услугу: %s\n" | ||
149 | |||
150 | #: src/arm/gnunet-arm.c:468 | ||
151 | #, c-format | ||
152 | msgid "Failed to send a request to kill the `%s' service: %%s\n" | ||
153 | msgstr "Нисам успео да пошаљем захтев за убијање „%s“ услуге: %%s\n" | ||
154 | |||
155 | #: src/arm/gnunet-arm.c:479 | ||
156 | #, c-format | ||
157 | msgid "Failed to kill the `%s' service: %s\n" | ||
158 | msgstr "Нисам успео да убијем „%s“ услугу: %s\n" | ||
159 | |||
160 | #: src/arm/gnunet-arm.c:517 | ||
161 | #, c-format | ||
162 | msgid "Failed to request a list of services: %s\n" | ||
163 | msgstr "Нисам успео да захтевам списак услуга: %s\n" | ||
164 | |||
165 | #: src/arm/gnunet-arm.c:525 | ||
166 | msgid "Error communicating with ARM. ARM not running?\n" | ||
167 | msgstr "Грешка у комуникацији са АУР-ом. Да ли је АУР покренут?\n" | ||
168 | |||
169 | #: src/arm/gnunet-arm.c:530 | ||
170 | msgid "Running services:\n" | ||
171 | msgstr "Покренуте услуге:\n" | ||
172 | |||
173 | #: src/arm/gnunet-arm.c:612 | ||
174 | #, c-format | ||
175 | msgid "Now only monitoring, press CTRL-C to stop.\n" | ||
176 | msgstr "Сада пратим само, притисните КТРЛ-Ц да зауставите.\n" | ||
177 | |||
178 | #: src/arm/gnunet-arm.c:643 | ||
179 | #, c-format | ||
180 | msgid "Stopped %s.\n" | ||
181 | msgstr "Заустављен%s.\n" | ||
182 | |||
183 | #: src/arm/gnunet-arm.c:646 | ||
184 | #, c-format | ||
185 | msgid "Starting %s...\n" | ||
186 | msgstr "Покрећем %s...\n" | ||
187 | |||
188 | #: src/arm/gnunet-arm.c:649 | ||
189 | #, c-format | ||
190 | msgid "Stopping %s...\n" | ||
191 | msgstr "Заустављам %s...\n" | ||
192 | |||
193 | #: src/arm/gnunet-arm.c:660 | ||
194 | #, c-format | ||
195 | msgid "Unknown status %u for service %s.\n" | ||
196 | msgstr "Непознато стање %u за услугу „%s“.\n" | ||
197 | |||
198 | #: src/arm/gnunet-arm.c:724 | ||
199 | msgid "stop all GNUnet services" | ||
200 | msgstr "зауставља све ГНУнет услуге" | ||
201 | |||
202 | #: src/arm/gnunet-arm.c:726 | ||
203 | msgid "start a particular service" | ||
204 | msgstr "покреће нарочиту услугу" | ||
205 | |||
206 | #: src/arm/gnunet-arm.c:728 | ||
207 | msgid "stop a particular service" | ||
208 | msgstr "зауставља нарочиту услугу" | ||
209 | |||
210 | #: src/arm/gnunet-arm.c:730 | ||
211 | msgid "start all GNUnet default services" | ||
212 | msgstr "покреће све основне ГНУнет услуге" | ||
213 | |||
214 | #: src/arm/gnunet-arm.c:733 | ||
215 | msgid "stop and start all GNUnet default services" | ||
216 | msgstr "зауставља и покреће све основне ГНУнет услуге" | ||
217 | |||
218 | #: src/arm/gnunet-arm.c:736 | ||
219 | msgid "delete config file and directory on exit" | ||
220 | msgstr "брише датотеку подешавања и директоријум на изласку" | ||
221 | |||
222 | #: src/arm/gnunet-arm.c:739 | ||
223 | msgid "monitor ARM activities" | ||
224 | msgstr "прати активности АУР-а" | ||
225 | |||
226 | #: src/arm/gnunet-arm.c:741 | ||
227 | msgid "don't print status messages" | ||
228 | msgstr "не исписује поруке стања" | ||
229 | |||
230 | #: src/arm/gnunet-arm.c:744 | ||
231 | msgid "timeout in MSECS milliseconds for completing current operation" | ||
232 | msgstr "време истека у МСЕК милисекундама за завршавање текуће радње" | ||
233 | |||
234 | #: src/arm/gnunet-arm.c:746 | ||
235 | msgid "list currently running services" | ||
236 | msgstr "исписује тренутно покренуте услуге" | ||
237 | |||
238 | #: src/arm/gnunet-arm.c:748 | ||
239 | msgid "don't let gnunet-service-arm inherit standard output" | ||
240 | msgstr "не да да „gnunet-service-arm“ наследи стандардни излаз" | ||
241 | |||
242 | #: src/arm/gnunet-arm.c:750 | ||
243 | msgid "don't let gnunet-service-arm inherit standard error" | ||
244 | msgstr "не да да „gnunet-service-arm“ наследи стандардну грешку" | ||
245 | |||
246 | #: src/arm/gnunet-arm.c:761 | ||
247 | msgid "Control services and the Automated Restart Manager (ARM)" | ||
248 | msgstr "Контролне услуге и Аутоматизовани Управник Рестарта (АУР)" | ||
249 | |||
250 | #: src/arm/gnunet-service-arm.c:266 | ||
251 | msgid "Could not send status result to client\n" | ||
252 | msgstr "Не могу да пошаљем резултат стања клијенту\n" | ||
253 | |||
254 | #: src/arm/gnunet-service-arm.c:302 | ||
255 | msgid "Could not send list result to client\n" | ||
256 | msgstr "Не могу да пошаљем резултат списка клијенту\n" | ||
257 | |||
258 | #: src/arm/gnunet-service-arm.c:529 | ||
259 | #, c-format | ||
260 | msgid "Failed to start service `%s'\n" | ||
261 | msgstr "Нисам успео да покренем услугу „%s“\n" | ||
262 | |||
263 | #: src/arm/gnunet-service-arm.c:540 | ||
264 | #, c-format | ||
265 | msgid "Starting service `%s'\n" | ||
266 | msgstr "Покрећем услугу „%s“\n" | ||
267 | |||
268 | #: src/arm/gnunet-service-arm.c:639 | ||
269 | #, c-format | ||
270 | msgid "Unable to create socket for service `%s': %s\n" | ||
271 | msgstr "Не могу да направим прикључницу за услугу „%s“: %s\n" | ||
272 | |||
273 | #: src/arm/gnunet-service-arm.c:661 | ||
274 | #, c-format | ||
275 | msgid "Unable to bind listening socket for service `%s' to address `%s': %s\n" | ||
276 | msgstr "Не могу да увежем прикључницу ослушкивања за услугу „%s“ на адресу „%s“: %s\n" | ||
277 | |||
278 | #: src/arm/gnunet-service-arm.c:695 | ||
279 | #, c-format | ||
280 | msgid "ARM now monitors connections to service `%s' at `%s'\n" | ||
281 | msgstr "АУР сада надгледа везе ка услузи „%s“ на „%s“\n" | ||
282 | |||
283 | #: src/arm/gnunet-service-arm.c:831 | ||
284 | #, c-format | ||
285 | msgid "Preparing to stop `%s'\n" | ||
286 | msgstr "Припремам се да зауставим „%s“\n" | ||
287 | |||
288 | #: src/arm/gnunet-service-arm.c:1100 | ||
289 | #, c-format | ||
290 | msgid "Restarting service `%s'.\n" | ||
291 | msgstr "Поново покрећем услугу „%s“.\n" | ||
292 | |||
293 | #: src/arm/gnunet-service-arm.c:1193 | ||
294 | msgid "exit" | ||
295 | msgstr "излази" | ||
296 | |||
297 | #: src/arm/gnunet-service-arm.c:1198 | ||
298 | msgid "signal" | ||
299 | msgstr "сигнал" | ||
300 | |||
301 | #: src/arm/gnunet-service-arm.c:1203 | ||
302 | msgid "unknown" | ||
303 | msgstr "непознато" | ||
304 | |||
305 | #: src/arm/gnunet-service-arm.c:1209 | ||
306 | #, c-format | ||
307 | msgid "Service `%s' took %s to terminate\n" | ||
308 | msgstr "Услуга „%s“ је узела %s да оконча\n" | ||
309 | |||
310 | #: src/arm/gnunet-service-arm.c:1231 | ||
311 | #, c-format | ||
312 | msgid "Service `%s' terminated normally, will restart at any time\n" | ||
313 | msgstr "Услуга „%s“ је окончана нормално, поново ће се покренути у било које време\n" | ||
314 | |||
315 | #: src/arm/gnunet-service-arm.c:1246 | ||
316 | #, c-format | ||
317 | msgid "Service `%s' terminated with status %s/%d, will restart in %s\n" | ||
318 | msgstr "Услуга „%s“ је окончана са стањем %s/%d, поново ће се покренути за %s\n" | ||
319 | |||
320 | #: src/arm/gnunet-service-arm.c:1500 | ||
321 | #, c-format | ||
322 | msgid "Starting default services `%s'\n" | ||
323 | msgstr "Покрећем основне услуге „%s“\n" | ||
324 | |||
325 | #: src/arm/gnunet-service-arm.c:1511 | ||
326 | #, c-format | ||
327 | msgid "Default service `%s' not configured correctly!\n" | ||
328 | msgstr "Основна услуга „%s“ није подешена исправно!\n" | ||
329 | |||
330 | #: src/arm/gnunet-service-arm.c:1524 | ||
331 | msgid "No default services configured, GNUnet will not really start right now.\n" | ||
332 | msgstr "Основне услуге нису подешене, ГНУнет се неће баш сада покренути.\n" | ||
333 | |||
334 | #: src/arm/mockup-service.c:41 | ||
335 | msgid "Initiating shutdown as requested by client.\n" | ||
336 | msgstr "Започињем гашење као што је затражио клијент.\n" | ||
337 | |||
338 | #: src/ats/ats_api_performance.c:468 | ||
339 | #, c-format | ||
340 | msgid "Received %s message\n" | ||
341 | msgstr "Примих %s поруку\n" | ||
342 | |||
343 | #: src/ats/ats_api_performance.c:511 | ||
344 | #, c-format | ||
345 | msgid "Received last message for %s \n" | ||
346 | msgstr "Примих последњу поруку за %s \n" | ||
347 | |||
348 | #: src/ats/gnunet-ats-solver-eval.c:2199 src/ats/gnunet-ats-solver-eval.c:2233 | ||
349 | #: src/ats/gnunet-service-ats_addresses.c:1980 | ||
350 | #: src/ats/gnunet-service-ats_addresses.c:2024 | ||
351 | #, c-format | ||
352 | msgid "Could not load quota for network `%s': `%s', assigning default bandwidth %llu\n" | ||
353 | msgstr "Не могу да учитам квоту за мрежу „%s“: „%s“, додељујем основни пропусни опсег %llu\n" | ||
354 | |||
355 | #: src/ats/gnunet-ats-solver-eval.c:2205 | ||
356 | #: src/ats/gnunet-service-ats_addresses.c:1987 | ||
357 | #, c-format | ||
358 | msgid "Outbound quota configure for network `%s' is %llu\n" | ||
359 | msgstr "Квота одлазности подешена за мрежу „%s“ је %llu\n" | ||
360 | |||
361 | #: src/ats/gnunet-ats-solver-eval.c:2212 | ||
362 | #: src/ats/gnunet-service-ats_addresses.c:1995 | ||
363 | #, c-format | ||
364 | msgid "No outbound quota configured for network `%s', assigning default bandwidth %llu\n" | ||
365 | msgstr "Нема подешене одлазне квоте за мрежу „%s“, додељујем основни пропусни опсег %llu\n" | ||
366 | |||
367 | #: src/ats/gnunet-ats-solver-eval.c:2239 | ||
368 | #: src/ats/gnunet-service-ats_addresses.c:2031 | ||
369 | #, c-format | ||
370 | msgid "Inbound quota configured for network `%s' is %llu\n" | ||
371 | msgstr "Квота долазности подешена за мрежу „%s“ је %llu\n" | ||
372 | |||
373 | #: src/ats/gnunet-ats-solver-eval.c:2246 | ||
374 | #: src/ats/gnunet-service-ats_addresses.c:2039 | ||
375 | #, c-format | ||
376 | msgid "No outbound quota configure for network `%s', assigning default bandwidth %llu\n" | ||
377 | msgstr "Није подешена одлазна квота за мрежу „%s“, додељујем основни пропусни опсег %llu\n" | ||
378 | |||
379 | #: src/ats/gnunet-ats-solver-eval.c:2671 | ||
380 | #: src/ats-tests/gnunet-solver-eval.c:919 | ||
381 | msgid "solver to use" | ||
382 | msgstr "решавач за коришћење" | ||
383 | |||
384 | #: src/ats/gnunet-ats-solver-eval.c:2674 src/ats/gnunet-ats-solver-eval.c:2677 | ||
385 | #: src/ats-tests/gnunet-solver-eval.c:922 | ||
386 | #: src/ats-tests/gnunet-solver-eval.c:925 | ||
387 | msgid "experiment to use" | ||
388 | msgstr "експеримент за коришћење" | ||
389 | |||
390 | #: src/ats/gnunet-ats-solver-eval.c:2680 | ||
391 | msgid "print logging" | ||
392 | msgstr "исписује дневничење" | ||
393 | |||
394 | #: src/ats/gnunet-service-ats_addresses.c:2217 | ||
395 | #, c-format | ||
396 | msgid "Initializing solver `%s '`%s'\n" | ||
397 | msgstr "Покрећем решавача „%s “„%s“\n" | ||
398 | |||
399 | #: src/ats/gnunet-service-ats_addresses.c:2220 | ||
400 | #, c-format | ||
401 | msgid "Failed to initialize solver `%s'!\n" | ||
402 | msgstr "Нисам успео да покренем решавача „%s“!\n" | ||
403 | |||
404 | #: src/ats/gnunet-service-ats_addresses.c:2243 | ||
405 | msgid "Failed to initialize solver!\n" | ||
406 | msgstr "Нисам успео да покренем решавача!\n" | ||
407 | |||
408 | #: src/ats/plugin_ats_mlp.c:892 | ||
409 | msgid "Problem size too large, cannot allocate memory!\n" | ||
410 | msgstr "Величина проблема је превелика, не могу да доделим меморију!\n" | ||
411 | |||
412 | #: src/ats/plugin_ats_mlp.c:1329 | ||
413 | #, c-format | ||
414 | msgid "Adding address for peer `%s' multiple times\n" | ||
415 | msgstr "Додајем адресу за парњака „%s“ више пута\n" | ||
416 | |||
417 | #: src/ats/plugin_ats_mlp.c:1376 | ||
418 | #, c-format | ||
419 | msgid "Updating address property `%s' for peer `%s' %p not added before\n" | ||
420 | msgstr "Освежавам својство адресе „%s“ за парњака „%s“ %p који није додат раније\n" | ||
421 | |||
422 | #: src/ats/plugin_ats_mlp.c:2122 | ||
423 | #, c-format | ||
424 | msgid "Adjusting inconsistent outbound quota configuration for network `%s', is %llu must be at least %llu\n" | ||
425 | msgstr "Поправљам недоследно подешавање одлазне квоте за мрежу „%s“, која је %llu а мора бити најмање %llu\n" | ||
426 | |||
427 | #: src/ats/plugin_ats_mlp.c:2131 | ||
428 | #, c-format | ||
429 | msgid "Adjusting inconsistent inbound quota configuration for network `%s', is %llu must be at least %llu\n" | ||
430 | msgstr "Поправљам недоследно подешавање долазне квоте за мрежу „%s“, која је %llu а мора бити најмање %llu\n" | ||
431 | |||
432 | #: src/ats/plugin_ats_mlp.c:2142 | ||
433 | #, c-format | ||
434 | msgid "Adjusting outbound quota configuration for network `%s'from %llu to %.0f\n" | ||
435 | msgstr "Поправљам недоследно подешавање одлазне квоте за мрежу „%s“ са %llu на %.0f\n" | ||
436 | |||
437 | #: src/ats/plugin_ats_mlp.c:2150 | ||
438 | #, c-format | ||
439 | msgid "Adjusting inbound quota configuration for network `%s' from %llu to %.0f\n" | ||
440 | msgstr "Поправљам недоследно подешавање долазне квоте за мрежу „%s“ са %llu на %.0f\n" | ||
441 | |||
442 | #: src/ats/plugin_ats_mlp.c:2161 | ||
443 | #, c-format | ||
444 | msgid "Using default quota configuration for network `%s' (in/out) %llu/%llu\n" | ||
445 | msgstr "Користим основно подешавање квоте за мрежу „%s“ (улаз/излаз) %llu/%llu\n" | ||
446 | |||
447 | #: src/ats/plugin_ats_proportional.c:1511 | ||
448 | #, c-format | ||
449 | msgid "Invalid network type `%u' `%s': Disconnect!\n" | ||
450 | msgstr "Неисправна врста мреже „%u“ „%s“: Прекидам везу!\n" | ||
451 | |||
452 | #: src/ats-tests/ats-testing.c:72 | ||
453 | msgid "Benchmarking done\n" | ||
454 | msgstr "Оцењивање је готово\n" | ||
455 | |||
456 | #: src/ats-tests/ats-testing.c:105 | ||
457 | #, c-format | ||
458 | msgid "Failed to connect peer 0 and %u\n" | ||
459 | msgstr "Нисам успео да повежем парњака 0 и %u\n" | ||
460 | |||
461 | #: src/ats-tests/ats-testing.c:413 | ||
462 | #, c-format | ||
463 | msgid "Connected master [%u] with slave [%u]\n" | ||
464 | msgstr "Повезан је надређени [%u] са потчињеним [%u]\n" | ||
465 | |||
466 | #: src/ats-tests/ats-testing.c:419 | ||
467 | #, c-format | ||
468 | msgid "Failed to connect master peer [%u] with slave [%u]\n" | ||
469 | msgstr "Нисам успео да повежем надређеног парњака [%u] са потчињеним [%u]\n" | ||
470 | |||
471 | #: src/ats-tests/ats-testing.c:450 | ||
472 | msgid "Connecting peers on CORE level\n" | ||
473 | msgstr "Повезујем парњаке на „CORE“ нивоу\n" | ||
474 | |||
475 | #: src/ats-tests/ats-testing.c:461 | ||
476 | #, c-format | ||
477 | msgid "Connecting master [%u] with slave [%u]\n" | ||
478 | msgstr "Повезујем надређеног [%u] са потчињеним [%u]\n" | ||
479 | |||
480 | #: src/ats-tests/ats-testing.c:470 | ||
481 | #, c-format | ||
482 | msgid "Could not connect master [%u] and slave [%u]\n" | ||
483 | msgstr "Не могу да повежем надређеног [%u] и потчињеног [%u]\n" | ||
484 | |||
485 | #: src/ats-tests/ats-testing.c:490 src/ats-tests/ats-testing.c:671 | ||
486 | msgid "Initialization failed, shutdown\n" | ||
487 | msgstr "Покретање није успело, гасим\n" | ||
488 | |||
489 | #: src/ats-tests/ats-testing-log.c:842 | ||
490 | msgid "Stop logging\n" | ||
491 | msgstr "Заустављам дневничење\n" | ||
492 | |||
493 | #: src/ats-tests/ats-testing-log.c:893 | ||
494 | #, c-format | ||
495 | msgid "Start logging `%s'\n" | ||
496 | msgstr "Започињем дневничење „%s“\n" | ||
497 | |||
498 | #: src/ats-tests/gnunet-ats-sim.c:86 | ||
499 | #, c-format | ||
500 | msgid "Master [%u]: sent: %u KiB in %u sec. = %u KiB/s, received: %u KiB in %u sec. = %u KiB/s\n" | ||
501 | msgstr "Надређени [%u]: послао: %u KiB за %u сек. = %u KiB/s, примио: %u KiB за %u сек. = %u KiB/s\n" | ||
502 | |||
503 | #: src/ats-tool/gnunet-ats.c:169 | ||
504 | #, c-format | ||
505 | msgid "%u address resolutions had a timeout\n" | ||
506 | msgstr "%u адресна разрешења имаху време истека\n" | ||
507 | |||
508 | #: src/ats-tool/gnunet-ats.c:171 | ||
509 | #, c-format | ||
510 | msgid "ATS returned results for %u addresses\n" | ||
511 | msgstr "АТС је вратио резултате за %u адресе\n" | ||
512 | |||
513 | #: src/ats-tool/gnunet-ats.c:232 | ||
514 | #, c-format | ||
515 | msgid "Peer `%s' plugin `%s', address `%s', `%s' bw out: %u Bytes/s, bw in %u Bytes/s, %s\n" | ||
516 | msgstr "Парњак „%s“ прикључак „%s“, адреса „%s“, „%s“ излазни пропусни опсег: %u Бајта/сек, улазни пропусни опсег %u Бајта/сек, %s\n" | ||
517 | |||
518 | #: src/ats-tool/gnunet-ats.c:413 | ||
519 | #, c-format | ||
520 | msgid "Quota for network `%11s' (in/out): %10s / %10s\n" | ||
521 | msgstr "Квота за мрежу „%11s“ (улаз/излаз): %10s / %10s\n" | ||
522 | |||
523 | #: src/ats-tool/gnunet-ats.c:433 src/core/gnunet-core.c:163 | ||
524 | #: src/namestore/gnunet-namestore.c:550 src/transport/gnunet-transport.c:1246 | ||
525 | #, c-format | ||
526 | msgid "Service `%s' is not running\n" | ||
527 | msgstr "Услуга „%s“ није покренута\n" | ||
528 | |||
529 | #: src/ats-tool/gnunet-ats.c:445 src/transport/gnunet-transport.c:1255 | ||
530 | #, c-format | ||
531 | msgid "Failed to parse peer identity `%s'\n" | ||
532 | msgstr "Нисам успео да обрадим идентитет парњака „%s“\n" | ||
533 | |||
534 | #: src/ats-tool/gnunet-ats.c:454 | ||
535 | #, c-format | ||
536 | msgid "Please select one operation : %s or %s or %s or %s or %s\n" | ||
537 | msgstr "Изаберите једну радњу : „%s“ или „%s“ или „%s“ или „%s“ или „%s“\n" | ||
538 | |||
539 | #: src/ats-tool/gnunet-ats.c:470 src/ats-tool/gnunet-ats.c:489 | ||
540 | #: src/ats-tool/gnunet-ats.c:506 src/ats-tool/gnunet-ats.c:543 | ||
541 | #, c-format | ||
542 | msgid "Cannot connect to ATS service, exiting...\n" | ||
543 | msgstr "Не могу да се повежем са АТС услугом, излазим...\n" | ||
544 | |||
545 | #: src/ats-tool/gnunet-ats.c:478 src/ats-tool/gnunet-ats.c:495 | ||
546 | #, c-format | ||
547 | msgid "Cannot issue request to ATS service, exiting...\n" | ||
548 | msgstr "Не могу да издам захтев АТС услузи, одлазим...\n" | ||
549 | |||
550 | #: src/ats-tool/gnunet-ats.c:515 | ||
551 | #, c-format | ||
552 | msgid "No preference type given!\n" | ||
553 | msgstr "Није дата врста својства!\n" | ||
554 | |||
555 | #: src/ats-tool/gnunet-ats.c:520 | ||
556 | #, c-format | ||
557 | msgid "No peer given!\n" | ||
558 | msgstr "Није дат парњак!\n" | ||
559 | |||
560 | #: src/ats-tool/gnunet-ats.c:536 | ||
561 | msgid "Valid type required\n" | ||
562 | msgstr "Потребна је исправна врста\n" | ||
563 | |||
564 | #: src/ats-tool/gnunet-ats.c:594 | ||
565 | msgid "get list of active addresses currently used" | ||
566 | msgstr "добавља списак активних адреса које се тренутно користе" | ||
567 | |||
568 | #: src/ats-tool/gnunet-ats.c:596 | ||
569 | msgid "get list of all active addresses" | ||
570 | msgstr "добавља списак свих активних адреса" | ||
571 | |||
572 | #: src/ats-tool/gnunet-ats.c:599 | ||
573 | msgid "do not resolve IP addresses to hostnames" | ||
574 | msgstr "не решава ИП адресе за називе домаћине" | ||
575 | |||
576 | #: src/ats-tool/gnunet-ats.c:601 | ||
577 | msgid "monitor mode" | ||
578 | msgstr "режим праћења" | ||
579 | |||
580 | #: src/ats-tool/gnunet-ats.c:603 | ||
581 | msgid "set preference for the given peer" | ||
582 | msgstr "поставља својство за датог парњака" | ||
583 | |||
584 | #: src/ats-tool/gnunet-ats.c:605 | ||
585 | msgid "print all configured quotas" | ||
586 | msgstr "исписује све подешене квоте" | ||
587 | |||
588 | #: src/ats-tool/gnunet-ats.c:607 | ||
589 | msgid "peer id" | ||
590 | msgstr "иб парњака" | ||
591 | |||
592 | #: src/ats-tool/gnunet-ats.c:610 | ||
593 | msgid "preference type to set: latency | bandwidth" | ||
594 | msgstr "врста поставке за постављање: кашњење | пропусни опсег" | ||
595 | |||
596 | #: src/ats-tool/gnunet-ats.c:612 | ||
597 | msgid "preference value" | ||
598 | msgstr "вредност својства" | ||
599 | |||
600 | #: src/ats-tool/gnunet-ats.c:615 | ||
601 | msgid "verbose output (include ATS address properties)" | ||
602 | msgstr "опширан излаз (укључује својства АТС адресе)" | ||
603 | |||
604 | #: src/ats-tool/gnunet-ats.c:622 | ||
605 | msgid "Print information about ATS state" | ||
606 | msgstr "Исписује податке о АТС стању" | ||
607 | |||
608 | #: src/consensus/gnunet-consensus-profiler.c:437 | ||
609 | #: src/secretsharing/gnunet-secretsharing-profiler.c:535 | ||
610 | msgid "number of peers in consensus" | ||
611 | msgstr "број парњака у концензусу" | ||
612 | |||
613 | #: src/consensus/gnunet-consensus-profiler.c:440 | ||
614 | msgid "how many peers receive one value?" | ||
615 | msgstr "колико парњака прима једну вредност?" | ||
616 | |||
617 | #: src/consensus/gnunet-consensus-profiler.c:443 | ||
618 | #: src/set/gnunet-set-profiler.c:286 src/set/gnunet-set-profiler.c:289 | ||
619 | #: src/set/gnunet-set-profiler.c:292 | ||
620 | msgid "number of values" | ||
621 | msgstr "број вредности" | ||
622 | |||
623 | #: src/consensus/gnunet-consensus-profiler.c:446 | ||
624 | msgid "consensus timeout" | ||
625 | msgstr "време истека концензуса" | ||
626 | |||
627 | #: src/consensus/gnunet-consensus-profiler.c:449 | ||
628 | msgid "delay until consensus starts" | ||
629 | msgstr "застој док не започне концензус" | ||
630 | |||
631 | #: src/consensus/gnunet-consensus-profiler.c:452 | ||
632 | #: src/secretsharing/gnunet-secretsharing-profiler.c:550 | ||
633 | msgid "be more verbose (print received values)" | ||
634 | msgstr "бива опширнији (исписује примљене вредности)" | ||
635 | |||
636 | #: src/conversation/conversation_api.c:557 | ||
637 | #: src/conversation/conversation_api_call.c:470 | ||
638 | msgid "Connection to conversation service lost, trying to reconnect\n" | ||
639 | msgstr "Веза са услугом конверзације је изгубљена, покушавам поново да се повежем\n" | ||
640 | |||
641 | #: src/conversation/gnunet-conversation.c:264 | ||
642 | #, c-format | ||
643 | msgid "Incoming call from `%s'. Please /accept #%u or /cancel %u the call.\n" | ||
644 | msgstr "Долазни позив од „%s“. /прихватите #%u или /откажите %u позив.\n" | ||
645 | |||
646 | #: src/conversation/gnunet-conversation.c:286 | ||
647 | #, c-format | ||
648 | msgid "Call from `%s' terminated\n" | ||
649 | msgstr "Позив од „%s“ је окончан\n" | ||
650 | |||
651 | #: src/conversation/gnunet-conversation.c:319 | ||
652 | #, c-format | ||
653 | msgid "Call from `%s' suspended by other user\n" | ||
654 | msgstr "Позив од „%s“ је обуставио други корисник\n" | ||
655 | |||
656 | #: src/conversation/gnunet-conversation.c:324 | ||
657 | #, c-format | ||
658 | msgid "Call from `%s' resumed by other user\n" | ||
659 | msgstr "Позив од „%s“ је повратио други корисник\n" | ||
660 | |||
661 | #: src/conversation/gnunet-conversation.c:342 | ||
662 | #, c-format | ||
663 | msgid "Ego `%s' no longer available, phone is now down.\n" | ||
664 | msgstr "Его „%s“ није више доступан, телефон је сада искључен.\n" | ||
665 | |||
666 | #: src/conversation/gnunet-conversation.c:356 | ||
667 | msgid "Failed to setup phone (internal error)\n" | ||
668 | msgstr "Нисам успео да подесим телефон (унутрашња грешка)\n" | ||
669 | |||
670 | #: src/conversation/gnunet-conversation.c:368 | ||
671 | #, c-format | ||
672 | msgid "Phone active on line %u. Type `/help' for a list of available commands\n" | ||
673 | msgstr "Телефон је активан на линији %u. Упишите „/help“ за списак доступних наредби\n" | ||
674 | |||
675 | #: src/conversation/gnunet-conversation.c:390 | ||
676 | #, c-format | ||
677 | msgid "Resolved address of `%s'. Now ringing other party.\n" | ||
678 | msgstr "Реших адресу за „%s“. Сада звоним на другој журци.\n" | ||
679 | |||
680 | #: src/conversation/gnunet-conversation.c:397 | ||
681 | #, c-format | ||
682 | msgid "Connection established to `%s'\n" | ||
683 | msgstr "Веза је успостављена са „%s“\n" | ||
684 | |||
685 | #: src/conversation/gnunet-conversation.c:404 | ||
686 | #, c-format | ||
687 | msgid "Failed to resolve `%s'\n" | ||
688 | msgstr "Нисам успео да решим „%s“\n" | ||
689 | |||
690 | #: src/conversation/gnunet-conversation.c:411 | ||
691 | msgid "Call terminated\n" | ||
692 | msgstr "Позив је окончан\n" | ||
693 | |||
694 | #: src/conversation/gnunet-conversation.c:417 | ||
695 | #, c-format | ||
696 | msgid "Connection to `%s' suspended (by other user)\n" | ||
697 | msgstr "Веза са „%s“ је обустављена (други корисник)\n" | ||
698 | |||
699 | #: src/conversation/gnunet-conversation.c:423 | ||
700 | #, c-format | ||
701 | msgid "Connection to `%s' resumed (by other user)\n" | ||
702 | msgstr "Веза са „%s“ је повраћена (други корисник)\n" | ||
703 | |||
704 | #: src/conversation/gnunet-conversation.c:428 | ||
705 | msgid "Error with the call, restarting it\n" | ||
706 | msgstr "Грешка са позивом, поново га покрећем\n" | ||
707 | |||
708 | #: src/conversation/gnunet-conversation.c:495 | ||
709 | #, c-format | ||
710 | msgid "Unknown command `%s'\n" | ||
711 | msgstr "Непозната наредба „%s“\n" | ||
712 | |||
713 | #: src/conversation/gnunet-conversation.c:511 | ||
714 | #: src/conversation/gnunet-conversation.c:525 | ||
715 | #, c-format | ||
716 | msgid "Ego `%s' not available\n" | ||
717 | msgstr "Его „%s“ није доступан\n" | ||
718 | |||
719 | #: src/conversation/gnunet-conversation.c:518 | ||
720 | #: src/conversation/gnunet-conversation.c:575 | ||
721 | msgid "You are calling someone else already, hang up first!\n" | ||
722 | msgstr "Већ позивате некога, спустите прво слушалицу!\n" | ||
723 | |||
724 | #: src/conversation/gnunet-conversation.c:533 | ||
725 | #: src/conversation/gnunet-conversation.c:588 | ||
726 | #, c-format | ||
727 | msgid "You are answering call from `%s', hang up or suspend that call first!\n" | ||
728 | msgstr "Одговарате на позив од „%s“, спустите слушалицу или обуставите тај позив!\n" | ||
729 | |||
730 | #: src/conversation/gnunet-conversation.c:544 | ||
731 | msgid "Call recipient missing.\n" | ||
732 | msgstr "Недостаје прималац позива.\n" | ||
733 | |||
734 | #: src/conversation/gnunet-conversation.c:599 | ||
735 | msgid "There is no incoming call to accept here!\n" | ||
736 | msgstr "Нема долазног позива овде за прихватање!\n" | ||
737 | |||
738 | #: src/conversation/gnunet-conversation.c:616 | ||
739 | #, c-format | ||
740 | msgid "There is no incoming call `%s' to accept right now!\n" | ||
741 | msgstr "Нема долазног позива „%s“ за прихватање управо сада!\n" | ||
742 | |||
743 | #: src/conversation/gnunet-conversation.c:647 | ||
744 | msgid "We currently do not have an address.\n" | ||
745 | msgstr "Тренутно немамамо адресу.\n" | ||
746 | |||
747 | #: src/conversation/gnunet-conversation.c:670 | ||
748 | #, c-format | ||
749 | msgid "We are currently trying to locate the private key for the ego `%s'.\n" | ||
750 | msgstr "Тренутно покушавамо да лоцирамо лични кључ за его „%s“.\n" | ||
751 | |||
752 | #: src/conversation/gnunet-conversation.c:675 | ||
753 | #, c-format | ||
754 | msgid "We are listening for incoming calls for ego `%s' on line %u.\n" | ||
755 | msgstr "Ослушкујемо за долазним позивима за его „%s“ на линији %u.\n" | ||
756 | |||
757 | #: src/conversation/gnunet-conversation.c:681 | ||
758 | #: src/conversation/gnunet-conversation.c:705 | ||
759 | #, c-format | ||
760 | msgid "You are having a conversation with `%s'.\n" | ||
761 | msgstr "Разговарате са „%s“.\n" | ||
762 | |||
763 | #: src/conversation/gnunet-conversation.c:686 | ||
764 | msgid "We had an internal error setting up our phone line. You can still make calls.\n" | ||
765 | msgstr "Имали смо унутрашњу грешку подешавајући нашу телефонску линију. Још увек можете обављати позиве.\n" | ||
766 | |||
767 | #: src/conversation/gnunet-conversation.c:695 | ||
768 | #, c-format | ||
769 | msgid "We are trying to find the network address to call `%s'.\n" | ||
770 | msgstr "Покушавамо да нађемо мрежну адресу за позив „%s“.\n" | ||
771 | |||
772 | #: src/conversation/gnunet-conversation.c:700 | ||
773 | #, c-format | ||
774 | msgid "We are calling `%s', his phone should be ringing.\n" | ||
775 | msgstr "Позивамо „%s“, његов телефон треба да звони.\n" | ||
776 | |||
777 | #: src/conversation/gnunet-conversation.c:719 | ||
778 | msgid "Calls waiting:\n" | ||
779 | msgstr "Чекање позива:\n" | ||
780 | |||
781 | #: src/conversation/gnunet-conversation.c:725 | ||
782 | #, c-format | ||
783 | msgid "#%u: `%s'\n" | ||
784 | msgstr "#%u: „%s“\n" | ||
785 | |||
786 | #: src/conversation/gnunet-conversation.c:753 | ||
787 | #: src/conversation/gnunet-conversation.c:768 | ||
788 | msgid "There is no call that could be suspended right now.\n" | ||
789 | msgstr "Нема позива који би могао бити обустављен управо сада.\n" | ||
790 | |||
791 | #: src/conversation/gnunet-conversation.c:801 | ||
792 | #: src/conversation/gnunet-conversation.c:817 | ||
793 | msgid "There is no call that could be resumed right now.\n" | ||
794 | msgstr "Нема позива који би могао бити повраћен управо сада.\n" | ||
795 | |||
796 | #: src/conversation/gnunet-conversation.c:824 | ||
797 | #, c-format | ||
798 | msgid "Already talking with `%s', cannot resume a call right now.\n" | ||
799 | msgstr "Већ разговарате са „%s“, не можете повратити позив управо сада.\n" | ||
800 | |||
801 | #: src/conversation/gnunet-conversation.c:833 | ||
802 | msgid "There is no incoming call to resume here!\n" | ||
803 | msgstr "Нема долазног позива овде за повраћај!\n" | ||
804 | |||
805 | #: src/conversation/gnunet-conversation.c:850 | ||
806 | #, c-format | ||
807 | msgid "There is no incoming call `%s' to resume right now!\n" | ||
808 | msgstr "Нема долазног позива „%s“ за повраћај управо сада!\n" | ||
809 | |||
810 | #: src/conversation/gnunet-conversation.c:885 | ||
811 | msgid "There is no call that could be cancelled right now.\n" | ||
812 | msgstr "Нема позива који би могао бити отказан управо сада.\n" | ||
813 | |||
814 | #: src/conversation/gnunet-conversation.c:893 | ||
815 | msgid "There is no incoming call to refuse here!\n" | ||
816 | msgstr "Нема долазног позива овде за одбијање!\n" | ||
817 | |||
818 | #: src/conversation/gnunet-conversation.c:910 | ||
819 | #, c-format | ||
820 | msgid "There is no incoming call `%s' to refuse right now!\n" | ||
821 | msgstr "Нема долазног позива „%s“ за одбијање управо сада!\n" | ||
822 | |||
823 | #: src/conversation/gnunet-conversation.c:937 | ||
824 | msgid "Use `/address' to find out which address this phone should have in GNS" | ||
825 | msgstr "Користите „/address“ да нађете коју адресу треба да има овај телефон у ГНС-у" | ||
826 | |||
827 | #: src/conversation/gnunet-conversation.c:939 | ||
828 | msgid "Use `/call USER.gnu' to call USER" | ||
829 | msgstr "Користите „/call USER.gnu“ да позовете КОРИСНИКА" | ||
830 | |||
831 | #: src/conversation/gnunet-conversation.c:941 | ||
832 | msgid "Use `/accept #NUM' to accept incoming call #NUM" | ||
833 | msgstr "Користтие „/accept #NUM“ да прихватите долазни позив #БРОЈ" | ||
834 | |||
835 | #: src/conversation/gnunet-conversation.c:943 | ||
836 | msgid "Use `/suspend' to suspend the active call" | ||
837 | msgstr "Користите „/suspend“ да обуставитеактивни позив" | ||
838 | |||
839 | #: src/conversation/gnunet-conversation.c:945 | ||
840 | msgid "Use `/resume [#NUM]' to resume a call, #NUM is needed to resume incoming calls, no argument is needed to resume the current outgoing call." | ||
841 | msgstr "Користите „/resume [#NUM]“ да наставите са позивом, #БРОЈ је потребан за повраћај долазних позива, аргумент није потребан за повраћај тренутно одлазног позива." | ||
842 | |||
843 | #: src/conversation/gnunet-conversation.c:947 | ||
844 | msgid "Use `/cancel' to reject or terminate a call" | ||
845 | msgstr "Користите „/cancel“ да одбаците или окончате позив" | ||
846 | |||
847 | #: src/conversation/gnunet-conversation.c:949 | ||
848 | msgid "Use `/status' to print status information" | ||
849 | msgstr "Користите „/status“ да испишете податке о стању" | ||
850 | |||
851 | #: src/conversation/gnunet-conversation.c:951 | ||
852 | msgid "Use `/quit' to terminate gnunet-conversation" | ||
853 | msgstr "Користите „/quit“ да окончате „gnunet-conversation“" | ||
854 | |||
855 | #: src/conversation/gnunet-conversation.c:953 | ||
856 | msgid "Use `/help command' to get help for a specific command" | ||
857 | msgstr "Користите „/help наредба“ да добијете помоћ за неку наредбу" | ||
858 | |||
859 | #: src/conversation/gnunet-conversation.c:1151 | ||
860 | #, c-format | ||
861 | msgid "Name of our ego changed to `%s'\n" | ||
862 | msgstr "Назив нашег ега је промењен у „%s“\n" | ||
863 | |||
864 | #: src/conversation/gnunet-conversation.c:1164 | ||
865 | #, c-format | ||
866 | msgid "Our ego `%s' was deleted!\n" | ||
867 | msgstr "Наш его „%s“ је обрисан!\n" | ||
868 | |||
869 | #: src/conversation/gnunet-conversation.c:1199 | ||
870 | msgid "You must specify the NAME of an ego to use\n" | ||
871 | msgstr "Морате навести НАЗИВ егоа за коришћење\n" | ||
872 | |||
873 | #: src/conversation/gnunet-conversation.c:1223 | ||
874 | msgid "Failed to start gnunet-helper-w32-console\n" | ||
875 | msgstr "Нисам успео да покренем „gnunet-helper-w32-console“\n" | ||
876 | |||
877 | #: src/conversation/gnunet-conversation.c:1249 | ||
878 | msgid "sets the NAME of the ego to use for the phone (and name resolution)" | ||
879 | msgstr "поставља НАЗИВ егоа за коришћење за телефон (и решавање назива)" | ||
880 | |||
881 | #: src/conversation/gnunet-conversation.c:1252 | ||
882 | msgid "sets the LINE to use for the phone" | ||
883 | msgstr "поставља РЕД за коришћење за телефон" | ||
884 | |||
885 | #: src/conversation/gnunet-conversation.c:1276 | ||
886 | msgid "Enables having a conversation with other GNUnet users." | ||
887 | msgstr "Укључује могућност конверзације са другим ГНУнет корисницима." | ||
888 | |||
889 | #: src/conversation/gnunet-conversation-test.c:121 | ||
890 | #, c-format | ||
891 | msgid "" | ||
892 | "\n" | ||
893 | "End of transmission. Have a GNU day.\n" | ||
894 | msgstr "" | ||
895 | "\n" | ||
896 | "Крај преноса. Нека вам је ГНУ дан.\n" | ||
897 | |||
898 | #: src/conversation/gnunet-conversation-test.c:149 | ||
899 | #, c-format | ||
900 | msgid "" | ||
901 | "\n" | ||
902 | "We are now playing your recording back. If you can hear it, your audio settings are working..." | ||
903 | msgstr "" | ||
904 | "\n" | ||
905 | "Сада пуштамо ваш снимак. Ако можете да га чујете, ваша подешавања звука су добра..." | ||
906 | |||
907 | #: src/conversation/gnunet-conversation-test.c:215 | ||
908 | #, c-format | ||
909 | msgid "We will now be recording you for %s. After that time, the recording will be played back to you..." | ||
910 | msgstr "Сада ћемо вас снимати за %s. Након тог времена, снимак ће вам бити пуштен..." | ||
911 | |||
912 | #: src/conversation/gnunet-conversation-test.c:248 | ||
913 | #: src/multicast/gnunet-multicast.c:70 src/revocation/gnunet-revocation.c:522 | ||
914 | #: src/template/gnunet-template.c:70 | ||
915 | msgid "help text" | ||
916 | msgstr "текст помоћи" | ||
917 | |||
918 | #: src/conversation/gnunet-helper-audio-playback.c:305 | ||
919 | #, c-format | ||
920 | msgid "pa_stream_write() failed: %s\n" | ||
921 | msgstr "Није успело „pa_stream_write()“: %s\n" | ||
922 | |||
923 | #: src/conversation/gnunet-helper-audio-playback.c:587 | ||
924 | msgid "gnunet-helper-audio-playback - Got signal, exiting\n" | ||
925 | msgstr "gnunet-helper-audio-playback – Добих сигнал, излазим\n" | ||
926 | |||
927 | #: src/conversation/gnunet-helper-audio-playback.c:612 | ||
928 | #: src/conversation/gnunet-helper-audio-record.c:545 | ||
929 | msgid "Connection established.\n" | ||
930 | msgstr "Веза је успостављена.\n" | ||
931 | |||
932 | #: src/conversation/gnunet-helper-audio-playback.c:617 | ||
933 | #: src/conversation/gnunet-helper-audio-record.c:550 | ||
934 | #, c-format | ||
935 | msgid "pa_stream_new() failed: %s\n" | ||
936 | msgstr "Није успело „pa_stream_new()“: %s\n" | ||
937 | |||
938 | #: src/conversation/gnunet-helper-audio-playback.c:631 | ||
939 | #, c-format | ||
940 | msgid "pa_stream_connect_playback() failed: %s\n" | ||
941 | msgstr "Није успело „pa_stream_connect_playback()“: %s\n" | ||
942 | |||
943 | #: src/conversation/gnunet-helper-audio-playback.c:644 | ||
944 | #: src/conversation/gnunet-helper-audio-record.c:576 | ||
945 | #, c-format | ||
946 | msgid "Connection failure: %s\n" | ||
947 | msgstr "Неуспешно повезивање: %s\n" | ||
948 | |||
949 | #: src/conversation/gnunet-helper-audio-playback.c:665 | ||
950 | #: src/conversation/gnunet-helper-audio-record.c:599 | ||
951 | msgid "Wrong Spec\n" | ||
952 | msgstr "Погрешна спец\n" | ||
953 | |||
954 | #: src/conversation/gnunet-helper-audio-playback.c:671 | ||
955 | #: src/conversation/gnunet-helper-audio-record.c:605 | ||
956 | msgid "pa_mainloop_new() failed.\n" | ||
957 | msgstr "Није успело „pa_mainloop_new()“.\n" | ||
958 | |||
959 | #: src/conversation/gnunet-helper-audio-playback.c:685 | ||
960 | #: src/conversation/gnunet-helper-audio-record.c:620 | ||
961 | msgid "pa_context_new() failed.\n" | ||
962 | msgstr "Није успело „pa_context_new()“.\n" | ||
963 | |||
964 | #: src/conversation/gnunet-helper-audio-playback.c:692 | ||
965 | #: src/conversation/gnunet-helper-audio-record.c:626 | ||
966 | #, c-format | ||
967 | msgid "pa_context_connect() failed: %s\n" | ||
968 | msgstr "Није успело „pa_context_connect()“: %s\n" | ||
969 | |||
970 | #: src/conversation/gnunet-helper-audio-playback.c:698 | ||
971 | #: src/conversation/gnunet-helper-audio-record.c:632 | ||
972 | msgid "pa_mainloop_run() failed.\n" | ||
973 | msgstr "Није успело „pa_mainloop_run()“.\n" | ||
974 | |||
975 | #: src/conversation/gnunet-helper-audio-playback.c:768 | ||
976 | #, c-format | ||
977 | msgid "Read error from STDIN: %s\n" | ||
978 | msgstr "Грешка читања са СТНДУЛАЗА: %s\n" | ||
979 | |||
980 | #: src/conversation/gnunet-helper-audio-playback-gst.c:325 | ||
981 | #, c-format | ||
982 | msgid "Read error from STDIN: %d %s\n" | ||
983 | msgstr "Грешка читања са СТНДУЛАЗА: %d %s\n" | ||
984 | |||
985 | #: src/conversation/gnunet-helper-audio-record.c:344 | ||
986 | #, c-format | ||
987 | msgid "opus_encode_float() failed: %s. Aborting\n" | ||
988 | msgstr "Није успело „opus_encode_float()“: %s. Прекидам\n" | ||
989 | |||
990 | #: src/conversation/gnunet-helper-audio-record.c:420 | ||
991 | #, c-format | ||
992 | msgid "pa_stream_peek() failed: %s\n" | ||
993 | msgstr "Није успело „pa_stream_peek()“: %s\n" | ||
994 | |||
995 | #: src/conversation/gnunet-helper-audio-record.c:458 | ||
996 | msgid "Got signal, exiting.\n" | ||
997 | msgstr "Добих сигнал, излазим.\n" | ||
998 | |||
999 | #: src/conversation/gnunet-helper-audio-record.c:483 | ||
1000 | msgid "Stream successfully created.\n" | ||
1001 | msgstr "Ток је успешно направљен.\n" | ||
1002 | |||
1003 | #: src/conversation/gnunet-helper-audio-record.c:488 | ||
1004 | #, c-format | ||
1005 | msgid "pa_stream_get_buffer_attr() failed: %s\n" | ||
1006 | msgstr "Није успело „pa_stream_get_buffer_attr()“: %s\n" | ||
1007 | |||
1008 | #: src/conversation/gnunet-helper-audio-record.c:496 | ||
1009 | #, c-format | ||
1010 | msgid "Buffer metrics: maxlength=%u, fragsize=%u\n" | ||
1011 | msgstr "Мере бафера: maxlength=%u, fragsize=%u\n" | ||
1012 | |||
1013 | #: src/conversation/gnunet-helper-audio-record.c:500 | ||
1014 | #, c-format | ||
1015 | msgid "Using sample spec '%s', channel map '%s'.\n" | ||
1016 | msgstr "Користим спецификацију узорка „%s“, мапа канала „%s“.\n" | ||
1017 | |||
1018 | #: src/conversation/gnunet-helper-audio-record.c:507 | ||
1019 | #, c-format | ||
1020 | msgid "Connected to device %s (%u, %ssuspended).\n" | ||
1021 | msgstr "Повезан са уређајем %s (%u, %sобустављено).\n" | ||
1022 | |||
1023 | #: src/conversation/gnunet-helper-audio-record.c:516 | ||
1024 | #, c-format | ||
1025 | msgid "Stream error: %s\n" | ||
1026 | msgstr "Грешка тока: %s\n" | ||
1027 | |||
1028 | #: src/conversation/gnunet-helper-audio-record.c:563 | ||
1029 | #, c-format | ||
1030 | msgid "pa_stream_connect_record() failed: %s\n" | ||
1031 | msgstr "Није успело „pa_stream_connect_record()“: %s\n" | ||
1032 | |||
1033 | #: src/conversation/gnunet-helper-audio-record.c:676 | ||
1034 | msgid "ogg_stream_init() failed.\n" | ||
1035 | msgstr "Није успело „ogg_stream_init()“.\n" | ||
1036 | |||
1037 | #: src/conversation/gnunet-helper-audio-record.c:721 | ||
1038 | #, c-format | ||
1039 | msgid "Failed to allocate %d bytes for second packet\n" | ||
1040 | msgstr "Нисам успео да доделим %d бајта за други пакет\n" | ||
1041 | |||
1042 | #: src/conversation/gnunet-service-conversation.c:841 | ||
1043 | msgid "Mesh audio channel not ready; audio data dropped\n" | ||
1044 | msgstr "Звучни канал меша није спреман; звучни подаци су одбачени\n" | ||
1045 | |||
1046 | #: src/conversation/gnunet-service-conversation.c:932 | ||
1047 | #, c-format | ||
1048 | msgid "No available phone for incoming call on line %u, sending HANG_UP signal\n" | ||
1049 | msgstr "Нема доступних телефона за долазни позив на линији %u, шаљем сигнал ПРЕКИД\n" | ||
1050 | |||
1051 | #: src/conversation/gnunet-service-conversation.c:1338 | ||
1052 | #, c-format | ||
1053 | msgid "Received incoming channel on port %u\n" | ||
1054 | msgstr "Примих долазни канал на прикључник %u\n" | ||
1055 | |||
1056 | #: src/conversation/microphone.c:121 | ||
1057 | msgid "Could not start record audio helper\n" | ||
1058 | msgstr "Не могу да покренем помоћника аудио снимања\n" | ||
1059 | |||
1060 | #: src/conversation/plugin_gnsrecord_conversation.c:116 | ||
1061 | #, c-format | ||
1062 | msgid "Unable to parse PHONE record `%s'\n" | ||
1063 | msgstr "Не могу да обрадим ТЕЛЕФОНСКИ снимак „%s“\n" | ||
1064 | |||
1065 | #: src/conversation/speaker.c:75 | ||
1066 | msgid "Could not start playback audio helper.\n" | ||
1067 | msgstr "Не могу да покренем помоћника аудио пуштања.\n" | ||
1068 | |||
1069 | #: src/core/core_api.c:767 | ||
1070 | msgid "Client was disconnected from core service, trying to reconnect.\n" | ||
1071 | msgstr "Клијент је ископчан са кључне услуге, покушавам поново да се повежем.\n" | ||
1072 | |||
1073 | #: src/core/gnunet-core.c:80 | ||
1074 | #, c-format | ||
1075 | msgid "Peer `%s'\n" | ||
1076 | msgstr "Парњак „%s“\n" | ||
1077 | |||
1078 | #: src/core/gnunet-core.c:110 src/core/gnunet-core.c:138 | ||
1079 | #: src/transport/gnunet-transport.c:910 src/transport/gnunet-transport.c:930 | ||
1080 | #, c-format | ||
1081 | msgid "%24s: %-17s %4s (%u connections in total)\n" | ||
1082 | msgstr "%24s: %-17s %4s (укупно повезивања: %u)\n" | ||
1083 | |||
1084 | #: src/core/gnunet-core.c:112 src/transport/gnunet-transport.c:911 | ||
1085 | msgid "Connected to" | ||
1086 | msgstr "Повезани сте са" | ||
1087 | |||
1088 | #: src/core/gnunet-core.c:140 src/transport/gnunet-transport.c:931 | ||
1089 | msgid "Disconnected from" | ||
1090 | msgstr "Прекинута је веза са" | ||
1091 | |||
1092 | #: src/core/gnunet-core.c:211 src/peerinfo-tool/gnunet-peerinfo.c:694 | ||
1093 | #, c-format | ||
1094 | msgid "Invalid command line argument `%s'\n" | ||
1095 | msgstr "Неисправан аргумент линије наредби „%s“\n" | ||
1096 | |||
1097 | #: src/core/gnunet-core.c:233 src/transport/gnunet-transport.c:1486 | ||
1098 | msgid "provide information about all current connections (continuously)" | ||
1099 | msgstr "обезбеђује податке о свим тренутним везама (непрекидно)" | ||
1100 | |||
1101 | #: src/core/gnunet-core.c:244 | ||
1102 | msgid "Print information about connected peers." | ||
1103 | msgstr "Исписује податке о повезаним парњацима." | ||
1104 | |||
1105 | #: src/core/gnunet-service-core.c:105 | ||
1106 | msgid "Core service is lacking HOSTKEY configuration setting. Exiting.\n" | ||
1107 | msgstr "Услузи језгра недостаје поставка подешавања КЉУЧА_ДОМАЋИНА. Излазим.\n" | ||
1108 | |||
1109 | #: src/core/gnunet-service-core.c:126 | ||
1110 | #, c-format | ||
1111 | msgid "Core service of `%4s' ready.\n" | ||
1112 | msgstr "Кључна услуга „%4s“ је спремна.\n" | ||
1113 | |||
1114 | #: src/core/gnunet-service-core_clients.c:370 | ||
1115 | msgid "# send requests dropped (disconnected)" | ||
1116 | msgstr "# захтеви слања су одбачени (веза је прекинута)" | ||
1117 | |||
1118 | #: src/core/gnunet-service-core_clients.c:480 | ||
1119 | msgid "# messages discarded (session disconnected)" | ||
1120 | msgstr "# поруке су одбачене (сесија је ископчана)" | ||
1121 | |||
1122 | #: src/core/gnunet-service-core_clients.c:526 | ||
1123 | #, c-format | ||
1124 | msgid "# bytes of messages of type %u received" | ||
1125 | msgstr "# бајтови порука врсте %u су примљени" | ||
1126 | |||
1127 | #: src/core/gnunet-service-core_kx.c:535 | ||
1128 | msgid "# bytes encrypted" | ||
1129 | msgstr "# бајтова шифрованих" | ||
1130 | |||
1131 | #: src/core/gnunet-service-core_kx.c:586 | ||
1132 | msgid "# bytes decrypted" | ||
1133 | msgstr "# бајтова дешифрованих" | ||
1134 | |||
1135 | #: src/core/gnunet-service-core_kx.c:673 | ||
1136 | msgid "# key exchanges initiated" | ||
1137 | msgstr "# кључ измена је покренут" | ||
1138 | |||
1139 | #: src/core/gnunet-service-core_kx.c:713 | ||
1140 | msgid "# key exchanges stopped" | ||
1141 | msgstr "# кључ измена је заустављен" | ||
1142 | |||
1143 | #: src/core/gnunet-service-core_kx.c:810 | ||
1144 | msgid "# old ephemeral keys ignored" | ||
1145 | msgstr "# стари једнократни кључеви су занемарени" | ||
1146 | |||
1147 | #: src/core/gnunet-service-core_kx.c:816 | ||
1148 | msgid "# ephemeral keys received" | ||
1149 | msgstr "# једнократни кључеви су примљени" | ||
1150 | |||
1151 | #: src/core/gnunet-service-core_kx.c:850 | ||
1152 | #, c-format | ||
1153 | msgid "Ephemeral key message from peer `%s' rejected as its validity range does not match our system time (%llu not in [%llu,%llu]).\n" | ||
1154 | msgstr "Порука једнократног кључа од парњака „%s“ је одбачена јер њен опсег исправности не одговара времену нашег система (%llu није у [%llu,%llu]).\n" | ||
1155 | |||
1156 | #: src/core/gnunet-service-core_kx.c:861 | ||
1157 | msgid "# EPHEMERAL_KEY messages received" | ||
1158 | msgstr "# поруке ЈЕДНОКРАТНОГ_КЉУЧА су примљене" | ||
1159 | |||
1160 | #: src/core/gnunet-service-core_kx.c:951 | ||
1161 | #: src/transport/gnunet-service-transport_validation.c:1016 | ||
1162 | msgid "# PING messages received" | ||
1163 | msgstr "# ПИНГ поруке су примљене" | ||
1164 | |||
1165 | #: src/core/gnunet-service-core_kx.c:959 | ||
1166 | msgid "# PING messages dropped (out of order)" | ||
1167 | msgstr "# ПИНГ поруке су одбачене (ван поретка)" | ||
1168 | |||
1169 | #: src/core/gnunet-service-core_kx.c:986 | ||
1170 | #, c-format | ||
1171 | msgid "Received PING from `%s' for different identity: I am `%s', PONG identity: `%s'\n" | ||
1172 | msgstr "Примих ПИНГ са „%s“ за другачији идентитет: Ја сам „%s“, ПОНГ идентитет: „%s“\n" | ||
1173 | |||
1174 | #: src/core/gnunet-service-core_kx.c:1003 | ||
1175 | msgid "# PONG messages created" | ||
1176 | msgstr "# ПОНГ поруке су направљене" | ||
1177 | |||
1178 | #: src/core/gnunet-service-core_kx.c:1029 | ||
1179 | msgid "# sessions terminated by timeout" | ||
1180 | msgstr "# сесије су окончане временским истеком" | ||
1181 | |||
1182 | #: src/core/gnunet-service-core_kx.c:1039 | ||
1183 | msgid "# keepalive messages sent" | ||
1184 | msgstr "# поруке држања у животу су послате" | ||
1185 | |||
1186 | #: src/core/gnunet-service-core_kx.c:1096 | ||
1187 | #: src/transport/gnunet-service-transport_validation.c:1328 | ||
1188 | msgid "# PONG messages received" | ||
1189 | msgstr "# ПОНГ поруке су примљене" | ||
1190 | |||
1191 | #: src/core/gnunet-service-core_kx.c:1102 | ||
1192 | msgid "# PONG messages dropped (connection down)" | ||
1193 | msgstr "# ПОНГ поруке су одбачене (веза је пала)" | ||
1194 | |||
1195 | #: src/core/gnunet-service-core_kx.c:1107 | ||
1196 | msgid "# PONG messages dropped (out of order)" | ||
1197 | msgstr "# ПОНГ поруке су одбачене (ван поретка)" | ||
1198 | |||
1199 | #: src/core/gnunet-service-core_kx.c:1137 | ||
1200 | msgid "# PONG messages decrypted" | ||
1201 | msgstr "# ПОНГ поруке су дешифроване" | ||
1202 | |||
1203 | #: src/core/gnunet-service-core_kx.c:1171 | ||
1204 | msgid "# session keys confirmed via PONG" | ||
1205 | msgstr "# кључеви сесије су потврђени путем ПОНГ-а" | ||
1206 | |||
1207 | #: src/core/gnunet-service-core_kx.c:1181 | ||
1208 | msgid "# timeouts prevented via PONG" | ||
1209 | msgstr "# временски истеци су спречени путем ПОНГ-а" | ||
1210 | |||
1211 | #: src/core/gnunet-service-core_kx.c:1188 | ||
1212 | msgid "# rekey operations confirmed via PONG" | ||
1213 | msgstr "# операције рекључа су потврђене путем ПОНГ-а" | ||
1214 | |||
1215 | #: src/core/gnunet-service-core_kx.c:1328 | ||
1216 | msgid "# DATA message dropped (out of order)" | ||
1217 | msgstr "# ПОДАТАКА порука је одбачена (ван поретка)" | ||
1218 | |||
1219 | #: src/core/gnunet-service-core_kx.c:1335 | ||
1220 | #, c-format | ||
1221 | msgid "Session to peer `%s' went down due to key expiration (should not happen)\n" | ||
1222 | msgstr "Сесија за парњака „%s“ је пала услед истека кључа (није требало да се деси)\n" | ||
1223 | |||
1224 | #: src/core/gnunet-service-core_kx.c:1338 | ||
1225 | msgid "# sessions terminated by key expiration" | ||
1226 | msgstr "# сесије су окончане истеком кључа" | ||
1227 | |||
1228 | #: src/core/gnunet-service-core_kx.c:1383 | ||
1229 | #: src/core/gnunet-service-core_kx.c:1408 | ||
1230 | msgid "# bytes dropped (duplicates)" | ||
1231 | msgstr "# бајтови одбачени (удвострученост)" | ||
1232 | |||
1233 | #: src/core/gnunet-service-core_kx.c:1395 | ||
1234 | msgid "# bytes dropped (out of sequence)" | ||
1235 | msgstr "# бајтови одбачени (ван низа)" | ||
1236 | |||
1237 | #: src/core/gnunet-service-core_kx.c:1437 | ||
1238 | msgid "# bytes dropped (ancient message)" | ||
1239 | msgstr "# бајтови одбачени (стара порука)" | ||
1240 | |||
1241 | #: src/core/gnunet-service-core_kx.c:1445 | ||
1242 | msgid "# bytes of payload decrypted" | ||
1243 | msgstr "# бајтови утовара су дешифровани" | ||
1244 | |||
1245 | #: src/core/gnunet-service-core_kx.c:1480 | ||
1246 | msgid "# PAYLOAD dropped (out of order)" | ||
1247 | msgstr "# УТОВАР је одбачен (ван поретка)" | ||
1248 | |||
1249 | #: src/core/gnunet-service-core_neighbours.c:168 | ||
1250 | msgid "# sessions terminated by transport disconnect" | ||
1251 | msgstr "# окончане сесије прекидом преноса" | ||
1252 | |||
1253 | #: src/core/gnunet-service-core_neighbours.c:184 | ||
1254 | #: src/core/gnunet-service-core_neighbours.c:335 | ||
1255 | msgid "# neighbour entries allocated" | ||
1256 | msgstr "# уноси суседа су додељени" | ||
1257 | |||
1258 | #: src/core/gnunet-service-core_neighbours.c:252 | ||
1259 | msgid "# encrypted bytes given to transport" | ||
1260 | msgstr "# шифровани бајтови су дати преносу" | ||
1261 | |||
1262 | #: src/core/gnunet-service-core_neighbours.c:418 | ||
1263 | #, c-format | ||
1264 | msgid "Unsupported message of type %u (%u bytes) received from peer `%s'\n" | ||
1265 | msgstr "Неподржана порука врсте %u (%u бајта) је примљена са парњака „%s“\n" | ||
1266 | |||
1267 | #: src/core/gnunet-service-core_sessions.c:216 | ||
1268 | #: src/core/gnunet-service-core_sessions.c:288 | ||
1269 | #: src/dht/gnunet-service-dht_neighbours.c:662 | ||
1270 | #: src/dht/gnunet-service-dht_neighbours.c:727 | ||
1271 | #: src/dht/gnunet-service-xdht_neighbours.c:1304 | ||
1272 | #: src/fs/gnunet-service-fs_cp.c:606 src/fs/gnunet-service-fs_cp.c:1501 | ||
1273 | #: src/topology/gnunet-daemon-topology.c:707 | ||
1274 | #: src/topology/gnunet-daemon-topology.c:808 | ||
1275 | #: src/transport/gnunet-service-transport_neighbours.c:917 | ||
1276 | #: src/transport/gnunet-service-transport_neighbours.c:1141 | ||
1277 | #: src/transport/gnunet-service-transport_neighbours.c:3142 | ||
1278 | #: src/transport/gnunet-service-transport_neighbours.c:3438 | ||
1279 | msgid "# peers connected" | ||
1280 | msgstr "# парњаци су повезани" | ||
1281 | |||
1282 | #: src/core/gnunet-service-core_sessions.c:255 | ||
1283 | msgid "# type map refreshes sent" | ||
1284 | msgstr "# освежавања мапе врсте су послата" | ||
1285 | |||
1286 | #: src/core/gnunet-service-core_sessions.c:426 | ||
1287 | msgid "# messages discarded (expired prior to transmission)" | ||
1288 | msgstr "# поруке су одбачене (истекле су пре преноса)" | ||
1289 | |||
1290 | #: src/core/gnunet-service-core_typemap.c:110 | ||
1291 | #: src/core/gnunet-service-core_typemap.c:121 | ||
1292 | msgid "# type maps received" | ||
1293 | msgstr "# мапе врсте су примљене" | ||
1294 | |||
1295 | #: src/core/gnunet-service-core_typemap.c:151 | ||
1296 | msgid "# updates to my type map" | ||
1297 | msgstr "# ажурирања за моју мапу врсте" | ||
1298 | |||
1299 | #: src/datacache/datacache.c:115 src/datacache/datacache.c:266 | ||
1300 | #: src/datastore/gnunet-service-datastore.c:838 | ||
1301 | msgid "# bytes stored" | ||
1302 | msgstr "# бајтови су смештени" | ||
1303 | |||
1304 | #: src/datacache/datacache.c:117 src/datacache/datacache.c:268 | ||
1305 | msgid "# items stored" | ||
1306 | msgstr "# ставке су смештене" | ||
1307 | |||
1308 | #: src/datacache/datacache.c:143 src/datacache/datacache.c:150 | ||
1309 | #: src/datastore/gnunet-service-datastore.c:1487 | ||
1310 | #: src/datastore/gnunet-service-datastore.c:1498 | ||
1311 | #, c-format | ||
1312 | msgid "No `%s' specified for `%s' in configuration!\n" | ||
1313 | msgstr "Није наведено „%s“ за „%s“ у подешавањима!\n" | ||
1314 | |||
1315 | #: src/datacache/datacache.c:184 | ||
1316 | #, c-format | ||
1317 | msgid "Loading `%s' datacache plugin\n" | ||
1318 | msgstr "Учитавам прикључак „%s“ оставе података\n" | ||
1319 | |||
1320 | #: src/datacache/datacache.c:192 | ||
1321 | #, c-format | ||
1322 | msgid "Failed to load datacache plugin for `%s'\n" | ||
1323 | msgstr "Нисам успео да учитам прикључак оставе података за „%s“\n" | ||
1324 | |||
1325 | #: src/datacache/datacache.c:295 | ||
1326 | msgid "# requests received" | ||
1327 | msgstr "# захтеви су примљени" | ||
1328 | |||
1329 | #: src/datacache/datacache.c:304 | ||
1330 | msgid "# requests filtered by bloom filter" | ||
1331 | msgstr "# захтеви су филтрирани блум филтером" | ||
1332 | |||
1333 | #: src/datacache/plugin_datacache_heap.c:406 | ||
1334 | msgid "Heap datacache running\n" | ||
1335 | msgstr "Остава података скупине ради\n" | ||
1336 | |||
1337 | #: src/datacache/plugin_datacache_postgres.c:392 | ||
1338 | msgid "Postgres datacache running\n" | ||
1339 | msgstr "Остава података Постгреса ради\n" | ||
1340 | |||
1341 | #: src/datacache/plugin_datacache_sqlite.c:69 | ||
1342 | #: src/datacache/plugin_datacache_sqlite.c:72 | ||
1343 | #: src/datastore/plugin_datastore_mysql.c:806 | ||
1344 | #: src/datastore/plugin_datastore_mysql.c:820 | ||
1345 | #: src/datastore/plugin_datastore_sqlite.c:57 src/mysql/mysql.c:41 | ||
1346 | #: src/mysql/mysql.c:48 src/mysql/mysql.c:522 src/mysql/mysql.c:531 | ||
1347 | #: src/mysql/mysql.c:591 src/mysql/mysql.c:607 | ||
1348 | #: src/namecache/plugin_namecache_postgres.c:52 | ||
1349 | #: src/namecache/plugin_namecache_sqlite.c:52 | ||
1350 | #: src/namestore/plugin_namestore_postgres.c:52 | ||
1351 | #: src/namestore/plugin_namestore_sqlite.c:52 | ||
1352 | #: src/testbed/generate-underlay-topology.c:47 | ||
1353 | #: src/testbed/gnunet-daemon-latency-logger.c:52 | ||
1354 | #: src/testbed/gnunet-daemon-testbed-underlay.c:55 | ||
1355 | #: src/testbed/testbed_api_hosts.c:69 src/util/crypto_ecc.c:51 | ||
1356 | #: src/util/crypto_mpi.c:39 src/include/gnunet_common.h:602 | ||
1357 | #: src/include/gnunet_common.h:611 src/scalarproduct/scalarproduct.h:50 | ||
1358 | #, c-format | ||
1359 | msgid "`%s' failed at %s:%d with error: %s\n" | ||
1360 | msgstr "„%s“ није успело на %s:%d са грешком: %s\n" | ||
1361 | |||
1362 | #: src/datacache/plugin_datacache_sqlite.c:450 | ||
1363 | msgid "Sqlite datacache running\n" | ||
1364 | msgstr "Остава података Скулајта ради\n" | ||
1365 | |||
1366 | #: src/datacache/plugin_datacache_sqlite.c:484 | ||
1367 | #: src/datastore/plugin_datastore_sqlite.c:404 | ||
1368 | #: src/namecache/plugin_namecache_sqlite.c:295 | ||
1369 | #: src/namestore/plugin_namestore_sqlite.c:327 | ||
1370 | msgid "Tried to close sqlite without finalizing all prepared statements.\n" | ||
1371 | msgstr "Покушај да затворим скулајт без довршавања свих спремљених изјава.\n" | ||
1372 | |||
1373 | #: src/datacache/plugin_datacache_sqlite.c:491 | ||
1374 | #, c-format | ||
1375 | msgid "Failed to close statement %p: %d\n" | ||
1376 | msgstr "Нисам успео да затворим тврдњу „%p“: %d\n" | ||
1377 | |||
1378 | #: src/datacache/plugin_datacache_template.c:125 | ||
1379 | msgid "Template datacache running\n" | ||
1380 | msgstr "Остава података шаблона ради\n" | ||
1381 | |||
1382 | #: src/datastore/datastore_api.c:310 | ||
1383 | msgid "Failed to transmit request to drop database.\n" | ||
1384 | msgstr "Нисам успео да пренесем захтев бази података убацивања.\n" | ||
1385 | |||
1386 | #: src/datastore/datastore_api.c:394 | ||
1387 | msgid "# queue entry timeouts" | ||
1388 | msgstr "# истекла су времена уноса реда" | ||
1389 | |||
1390 | #: src/datastore/datastore_api.c:443 | ||
1391 | msgid "# queue overflows" | ||
1392 | msgstr "# прекорачења реда" | ||
1393 | |||
1394 | #: src/datastore/datastore_api.c:471 | ||
1395 | msgid "# queue entries created" | ||
1396 | msgstr "# уноси реда су створени" | ||
1397 | |||
1398 | #: src/datastore/datastore_api.c:491 | ||
1399 | msgid "# Requests dropped from datastore queue" | ||
1400 | msgstr "# Захтеви су одбачени из реда смештаја података" | ||
1401 | |||
1402 | #: src/datastore/datastore_api.c:533 | ||
1403 | msgid "# datastore connections (re)created" | ||
1404 | msgstr "# везе смештаја података су (поново) створене" | ||
1405 | |||
1406 | #: src/datastore/datastore_api.c:616 src/scalarproduct/scalarproduct_api.c:279 | ||
1407 | msgid "# transmission request failures" | ||
1408 | msgstr "# неуспеси захтева преноса" | ||
1409 | |||
1410 | #: src/datastore/datastore_api.c:638 | ||
1411 | msgid "# bytes sent to datastore" | ||
1412 | msgstr "# бајтови су послати смештају података" | ||
1413 | |||
1414 | #: src/datastore/datastore_api.c:770 | ||
1415 | msgid "Failed to receive status response from database." | ||
1416 | msgstr "Нисам успео да примим одговор стања из базе података." | ||
1417 | |||
1418 | #: src/datastore/datastore_api.c:784 | ||
1419 | msgid "Error reading response from datastore service" | ||
1420 | msgstr "Грешка читања одговора из услуге смештаја података" | ||
1421 | |||
1422 | #: src/datastore/datastore_api.c:796 src/datastore/datastore_api.c:802 | ||
1423 | msgid "Invalid error message received from datastore service" | ||
1424 | msgstr "Неисправна порука грешке је примљена из услуге смештаја података" | ||
1425 | |||
1426 | #: src/datastore/datastore_api.c:806 | ||
1427 | msgid "# status messages received" | ||
1428 | msgstr "# поруке стања су примљене" | ||
1429 | |||
1430 | #: src/datastore/datastore_api.c:876 | ||
1431 | msgid "# PUT requests executed" | ||
1432 | msgstr "# захтеви СТАВИ су извршени" | ||
1433 | |||
1434 | #: src/datastore/datastore_api.c:944 | ||
1435 | msgid "# RESERVE requests executed" | ||
1436 | msgstr "# захтеви РЕЗЕРВИШИ су извршени" | ||
1437 | |||
1438 | #: src/datastore/datastore_api.c:1005 | ||
1439 | msgid "# RELEASE RESERVE requests executed" | ||
1440 | msgstr "# захтеви ОТПУСТИ РЕЗЕРВИШИ су извршени" | ||
1441 | |||
1442 | #: src/datastore/datastore_api.c:1065 | ||
1443 | msgid "# UPDATE requests executed" | ||
1444 | msgstr "# захтеви ОСВЕЖИ су извршени" | ||
1445 | |||
1446 | #: src/datastore/datastore_api.c:1129 | ||
1447 | msgid "# REMOVE requests executed" | ||
1448 | msgstr "# захтеви УКЛОНИ су извршени" | ||
1449 | |||
1450 | #: src/datastore/datastore_api.c:1174 | ||
1451 | msgid "Failed to receive response from database.\n" | ||
1452 | msgstr "Нисам успео да примим одговор из базе података.\n" | ||
1453 | |||
1454 | #: src/datastore/datastore_api.c:1233 | ||
1455 | msgid "# Results received" | ||
1456 | msgstr "# Резултати су примљени" | ||
1457 | |||
1458 | #: src/datastore/datastore_api.c:1300 | ||
1459 | msgid "# GET REPLICATION requests executed" | ||
1460 | msgstr "# захтеви ДОБАВИ ПРЕСЛИКАНОСТ су изршени" | ||
1461 | |||
1462 | #: src/datastore/datastore_api.c:1363 | ||
1463 | msgid "# GET ZERO ANONYMITY requests executed" | ||
1464 | msgstr "# захтеви ДОБАВИ НУЛТУ АНОНИМНОСТ су извршени" | ||
1465 | |||
1466 | #: src/datastore/datastore_api.c:1424 | ||
1467 | msgid "# GET requests executed" | ||
1468 | msgstr "# захтеви ДОБАВИ су извршени" | ||
1469 | |||
1470 | #: src/datastore/gnunet-datastore.c:114 | ||
1471 | #, c-format | ||
1472 | msgid "Failed to store item: %s, aborting\n" | ||
1473 | msgstr "Нисам успео да сместим ставку: %s, прекидам\n" | ||
1474 | |||
1475 | #: src/datastore/gnunet-datastore.c:200 | ||
1476 | #, c-format | ||
1477 | msgid "Cannot use the same configuration for source and destination\n" | ||
1478 | msgstr "Не могу да користим исто подешавање за извор и одредиште\n" | ||
1479 | |||
1480 | #: src/datastore/gnunet-datastore.c:246 | ||
1481 | msgid "specifies the configuration to use to access an alternative datastore; will merge that datastore into our current datastore" | ||
1482 | msgstr "наводи подешавање за коришћење за приступ заменском смештају података; стопиће тај смештај података у наш тренутни смештај података" | ||
1483 | |||
1484 | #: src/datastore/gnunet-datastore.c:255 | ||
1485 | msgid "Manipulate GNUnet datastore" | ||
1486 | msgstr "Манипулише ГНУнет смештајом података" | ||
1487 | |||
1488 | #: src/datastore/gnunet-service-datastore.c:351 | ||
1489 | msgid "# bytes expired" | ||
1490 | msgstr "# бајтови су истекли" | ||
1491 | |||
1492 | #: src/datastore/gnunet-service-datastore.c:425 | ||
1493 | msgid "# bytes purged (low-priority)" | ||
1494 | msgstr "# бајтови су избачени (ниска хитност)" | ||
1495 | |||
1496 | #: src/datastore/gnunet-service-datastore.c:483 | ||
1497 | #: src/gns/gnunet-gns-helper-service-w32.c:223 | ||
1498 | msgid "Transmission to client failed!\n" | ||
1499 | msgstr "Пренос до клијента није успео!\n" | ||
1500 | |||
1501 | #: src/datastore/gnunet-service-datastore.c:514 | ||
1502 | #: src/gns/gnunet-gns-helper-service-w32.c:262 | ||
1503 | msgid "Shutdown in progress, aborting transmission.\n" | ||
1504 | msgstr "Гашење је у току, прекидам пренос.\n" | ||
1505 | |||
1506 | #: src/datastore/gnunet-service-datastore.c:630 | ||
1507 | msgid "# results found" | ||
1508 | msgstr "# резултати су нађени" | ||
1509 | |||
1510 | #: src/datastore/gnunet-service-datastore.c:673 | ||
1511 | #, c-format | ||
1512 | msgid "Insufficient space (%llu bytes are available) to satisfy `%s' request for %llu bytes\n" | ||
1513 | msgstr "Недовољно простора (доступних бајтова %llu) за задовољавање „%s“ захтева за %llu бајта\n" | ||
1514 | |||
1515 | #: src/datastore/gnunet-service-datastore.c:684 | ||
1516 | #, c-format | ||
1517 | msgid "The requested amount (%llu bytes) is larger than the cache size (%llu bytes)\n" | ||
1518 | msgstr "Захтевана количина (%llu бајта) је већа од величине оставе (%llu бајта)\n" | ||
1519 | |||
1520 | #: src/datastore/gnunet-service-datastore.c:688 | ||
1521 | msgid "Insufficient space to satisfy request and requested amount is larger than cache size" | ||
1522 | msgstr "Недовољно простора за задовољавање захтева а захтевана количина је већа од величине оставе" | ||
1523 | |||
1524 | #: src/datastore/gnunet-service-datastore.c:694 | ||
1525 | msgid "Insufficient space to satisfy request" | ||
1526 | msgstr "Недовољно простора за задовољавање захтева" | ||
1527 | |||
1528 | #: src/datastore/gnunet-service-datastore.c:699 | ||
1529 | #: src/datastore/gnunet-service-datastore.c:751 | ||
1530 | #: src/datastore/gnunet-service-datastore.c:964 | ||
1531 | #: src/datastore/gnunet-service-datastore.c:1421 | ||
1532 | msgid "# reserved" | ||
1533 | msgstr "# је резервисано" | ||
1534 | |||
1535 | #: src/datastore/gnunet-service-datastore.c:764 | ||
1536 | msgid "Could not find matching reservation" | ||
1537 | msgstr "Не могу да нађем одговарајућу резервацију" | ||
1538 | |||
1539 | #: src/datastore/gnunet-service-datastore.c:850 | ||
1540 | #, c-format | ||
1541 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" | ||
1542 | msgstr "Потребна су још %llu бајта простора (%llu је дозвољено, користим %llu)\n" | ||
1543 | |||
1544 | #: src/datastore/gnunet-service-datastore.c:1010 | ||
1545 | msgid "# GET requests received" | ||
1546 | msgstr "# захтеви ДОБАВИ су примљени" | ||
1547 | |||
1548 | #: src/datastore/gnunet-service-datastore.c:1022 | ||
1549 | msgid "# requests filtered by bloomfilter" | ||
1550 | msgstr "# захтеви су филтрирани блумфилтером" | ||
1551 | |||
1552 | #: src/datastore/gnunet-service-datastore.c:1050 | ||
1553 | msgid "# UPDATE requests received" | ||
1554 | msgstr "# захтеви ОСВЕЖИ су примљени" | ||
1555 | |||
1556 | #: src/datastore/gnunet-service-datastore.c:1080 | ||
1557 | msgid "# GET REPLICATION requests received" | ||
1558 | msgstr "# захтеви ДОБАВИ ПРЕСЛИКАНОСТ су примљени" | ||
1559 | |||
1560 | #: src/datastore/gnunet-service-datastore.c:1113 | ||
1561 | msgid "# GET ZERO ANONYMITY requests received" | ||
1562 | msgstr "# захтеви ДОБАВИ НУЛТУ АНОНИМНОСТ су примљени" | ||
1563 | |||
1564 | #: src/datastore/gnunet-service-datastore.c:1138 | ||
1565 | msgid "Content not found" | ||
1566 | msgstr "Нисам нашао садржај" | ||
1567 | |||
1568 | #: src/datastore/gnunet-service-datastore.c:1146 | ||
1569 | msgid "# bytes removed (explicit request)" | ||
1570 | msgstr "# бајта је уклоњено (изричити захтев)" | ||
1571 | |||
1572 | #: src/datastore/gnunet-service-datastore.c:1178 | ||
1573 | msgid "# REMOVE requests received" | ||
1574 | msgstr "# захтеви УКЛОНИ су уклоњени" | ||
1575 | |||
1576 | #: src/datastore/gnunet-service-datastore.c:1220 | ||
1577 | #, c-format | ||
1578 | msgid "Datastore payload inaccurate (%lld < %lld). Trying to fix.\n" | ||
1579 | msgstr "Утовар смештаја података није тачан (%lld < %lld). Покушавам да поправим.\n" | ||
1580 | |||
1581 | #: src/datastore/gnunet-service-datastore.c:1281 | ||
1582 | #, c-format | ||
1583 | msgid "Loading `%s' datastore plugin\n" | ||
1584 | msgstr "Учитавам прикључак „%s“ смештаја података\n" | ||
1585 | |||
1586 | #: src/datastore/gnunet-service-datastore.c:1290 | ||
1587 | #, c-format | ||
1588 | msgid "Failed to load datastore plugin for `%s'\n" | ||
1589 | msgstr "Нисам успео да учитам прикључак смештаја података за „%s“\n" | ||
1590 | |||
1591 | #: src/datastore/gnunet-service-datastore.c:1492 | ||
1592 | #, c-format | ||
1593 | msgid "# bytes used in file-sharing datastore `%s'" | ||
1594 | msgstr "# бајтови су коришћени у смештају података дељења датотека „%s“" | ||
1595 | |||
1596 | #: src/datastore/gnunet-service-datastore.c:1503 | ||
1597 | msgid "# quota" | ||
1598 | msgstr "# квота" | ||
1599 | |||
1600 | #: src/datastore/gnunet-service-datastore.c:1505 | ||
1601 | msgid "# cache size" | ||
1602 | msgstr "# величина кеша" | ||
1603 | |||
1604 | #: src/datastore/gnunet-service-datastore.c:1518 | ||
1605 | #, c-format | ||
1606 | msgid "Could not use specified filename `%s' for bloomfilter.\n" | ||
1607 | msgstr "Не могу да користим наведени назив датотеке „%s“ за блумфилтер.\n" | ||
1608 | |||
1609 | #: src/datastore/gnunet-service-datastore.c:1536 | ||
1610 | #: src/datastore/gnunet-service-datastore.c:1552 | ||
1611 | #, c-format | ||
1612 | msgid "Failed to remove bogus bloomfilter file `%s'\n" | ||
1613 | msgstr "Нисам успео да уклоним лажну датотеку блумфилтера „%s“\n" | ||
1614 | |||
1615 | #: src/datastore/gnunet-service-datastore.c:1582 | ||
1616 | msgid "Failed to initialize bloomfilter.\n" | ||
1617 | msgstr "Нисам успео да покренем блумфилтер.\n" | ||
1618 | |||
1619 | #: src/datastore/gnunet-service-datastore.c:1611 | ||
1620 | msgid "Rebuilding bloomfilter. Please be patient.\n" | ||
1621 | msgstr "Поново градим блумфилтер. Будите стрпљиви.\n" | ||
1622 | |||
1623 | #: src/datastore/gnunet-service-datastore.c:1616 | ||
1624 | msgid "Plugin does not support get_keys function. Please fix!\n" | ||
1625 | msgstr "Прикључак не подржава функцију „get_keys“. Поправите то!\n" | ||
1626 | |||
1627 | #: src/datastore/gnunet-service-datastore.c:1619 | ||
1628 | msgid "Bloomfilter construction complete.\n" | ||
1629 | msgstr "Изградња блумфилтера је завршена.\n" | ||
1630 | |||
1631 | #: src/datastore/plugin_datastore_heap.c:820 | ||
1632 | msgid "Heap database running\n" | ||
1633 | msgstr "База података скупине ради\n" | ||
1634 | |||
1635 | #: src/datastore/plugin_datastore_mysql.c:783 | ||
1636 | #, c-format | ||
1637 | msgid "Failed to prepare statement `%s'\n" | ||
1638 | msgstr "Нисам успео да припремим стање „%s“\n" | ||
1639 | |||
1640 | #: src/datastore/plugin_datastore_mysql.c:791 | ||
1641 | #, c-format | ||
1642 | msgid "`%s' for `%s' failed at %s:%d with error: %s\n" | ||
1643 | msgstr "„%s“ за „%s“ није успело на %s:%d са грешком: %s\n" | ||
1644 | |||
1645 | #: src/datastore/plugin_datastore_mysql.c:1022 | ||
1646 | msgid "Mysql database running\n" | ||
1647 | msgstr "База података Мајскула ради\n" | ||
1648 | |||
1649 | #: src/datastore/plugin_datastore_postgres.c:824 | ||
1650 | msgid "Failed to drop table from database.\n" | ||
1651 | msgstr "Нисам успео да избацим табелу из базе података.\n" | ||
1652 | |||
1653 | #: src/datastore/plugin_datastore_postgres.c:860 | ||
1654 | #: src/namecache/plugin_namecache_postgres.c:414 | ||
1655 | #: src/namestore/plugin_namestore_postgres.c:569 | ||
1656 | msgid "Postgres database running\n" | ||
1657 | msgstr "База података Постгреса ради\n" | ||
1658 | |||
1659 | #: src/datastore/plugin_datastore_sqlite.c:57 | ||
1660 | #: src/testbed/generate-underlay-topology.c:50 | ||
1661 | #: src/testbed/gnunet-daemon-latency-logger.c:55 | ||
1662 | #: src/testbed/gnunet-daemon-testbed-underlay.c:58 | ||
1663 | #, c-format | ||
1664 | msgid "`%s' failed at %s:%u with error: %s" | ||
1665 | msgstr "„%s“ није успело на %s:%u са грешком: %s" | ||
1666 | |||
1667 | #: src/datastore/plugin_datastore_sqlite.c:255 | ||
1668 | #: src/namecache/plugin_namecache_sqlite.c:193 | ||
1669 | #: src/namestore/plugin_namestore_sqlite.c:204 | ||
1670 | #: src/psycstore/plugin_psycstore_sqlite.c:319 | ||
1671 | #, c-format | ||
1672 | msgid "Unable to initialize SQLite: %s.\n" | ||
1673 | msgstr "Не могу да покренем СКуЛајт: %s.\n" | ||
1674 | |||
1675 | #: src/datastore/plugin_datastore_sqlite.c:663 | ||
1676 | msgid "Invalid data in database. Trying to fix (by deletion).\n" | ||
1677 | msgstr "Неисправан податак у бази података. Покушавам да поправим (брисањем).\n" | ||
1678 | |||
1679 | #: src/datastore/plugin_datastore_sqlite.c:1156 | ||
1680 | msgid "sqlite version to old to determine size, assuming zero\n" | ||
1681 | msgstr "скулајт издање је престаро за одређивање величине, подразумевам нулу\n" | ||
1682 | |||
1683 | #: src/datastore/plugin_datastore_sqlite.c:1175 | ||
1684 | #, c-format | ||
1685 | msgid "Using sqlite page utilization to estimate payload (%llu pages of size %llu bytes)\n" | ||
1686 | msgstr "Користим страницу коришћења скулајта да проценим утовар (%llu странице величине %llu бајта)\n" | ||
1687 | |||
1688 | #: src/datastore/plugin_datastore_sqlite.c:1215 | ||
1689 | #: src/namecache/plugin_namecache_sqlite.c:583 | ||
1690 | #: src/namestore/plugin_namestore_sqlite.c:719 | ||
1691 | msgid "Sqlite database running\n" | ||
1692 | msgstr "База података Скулајта ради\n" | ||
1693 | |||
1694 | #: src/datastore/plugin_datastore_template.c:257 | ||
1695 | msgid "Template database running\n" | ||
1696 | msgstr "База података шаблона ради\n" | ||
1697 | |||
1698 | #: src/dht/dht_api.c:376 | ||
1699 | msgid "Failed to connect to the DHT service!\n" | ||
1700 | msgstr "Нисам успео да се повежем са „DHT“ услугом!\n" | ||
1701 | |||
1702 | #: src/dht/gnunet-dht-get.c:133 | ||
1703 | #, c-format | ||
1704 | msgid "" | ||
1705 | "Result %d, type %d:\n" | ||
1706 | "%.*s\n" | ||
1707 | msgstr "" | ||
1708 | "Резултат %d, врста %d:\n" | ||
1709 | "%.*s\n" | ||
1710 | |||
1711 | #: src/dht/gnunet-dht-get.c:159 | ||
1712 | msgid "Must provide key for DHT GET!\n" | ||
1713 | msgstr "Морате доставити кључ за ДХТ ДОБАВИ!\n" | ||
1714 | |||
1715 | #: src/dht/gnunet-dht-get.c:165 src/dht/gnunet-dht-monitor.c:225 | ||
1716 | msgid "Failed to connect to DHT service!\n" | ||
1717 | msgstr "Нисам успео да се повежем са „DHT“ услугом!\n" | ||
1718 | |||
1719 | #: src/dht/gnunet-dht-get.c:173 | ||
1720 | msgid "Issueing DHT GET with key" | ||
1721 | msgstr "Издајем ДХТ ДОБАВИ са кључем" | ||
1722 | |||
1723 | #: src/dht/gnunet-dht-get.c:189 src/dht/gnunet-dht-monitor.c:262 | ||
1724 | #: src/dht/gnunet-dht-put.c:198 | ||
1725 | msgid "the query key" | ||
1726 | msgstr "кључ упита" | ||
1727 | |||
1728 | #: src/dht/gnunet-dht-get.c:192 | ||
1729 | msgid "how many parallel requests (replicas) to create" | ||
1730 | msgstr "колико паралелних захтева (реплика) да направи" | ||
1731 | |||
1732 | #: src/dht/gnunet-dht-get.c:195 src/dht/gnunet-dht-monitor.c:265 | ||
1733 | msgid "the type of data to look for" | ||
1734 | msgstr "врста података за тражење" | ||
1735 | |||
1736 | #: src/dht/gnunet-dht-get.c:198 src/dht/gnunet-dht-put.c:210 | ||
1737 | msgid "how long to execute this query before giving up?" | ||
1738 | msgstr "колико дуго да извршава овај упит пре одустајања?" | ||
1739 | |||
1740 | #: src/dht/gnunet-dht-get.c:201 src/dht/gnunet-dht-put.c:201 | ||
1741 | msgid "use DHT's demultiplex everywhere option" | ||
1742 | msgstr "користи опцију ДХТ-а демултиплексирај свуда" | ||
1743 | |||
1744 | #: src/dht/gnunet-dht-get.c:204 src/dht/gnunet-dht-monitor.c:271 | ||
1745 | #: src/dht/gnunet-dht-put.c:213 src/fs/gnunet-auto-share.c:753 | ||
1746 | #: src/fs/gnunet-download.c:328 src/fs/gnunet-publish.c:877 | ||
1747 | #: src/fs/gnunet-search.c:301 src/fs/gnunet-unindex.c:168 | ||
1748 | #: src/nse/gnunet-nse-profiler.c:873 | ||
1749 | msgid "be verbose (print progress information)" | ||
1750 | msgstr "бива опширан (исписује податке напредовања)" | ||
1751 | |||
1752 | #: src/dht/gnunet-dht-get.c:225 | ||
1753 | msgid "Issue a GET request to the GNUnet DHT, prints results." | ||
1754 | msgstr "Издаје ДОБАВИ захтев ГНУнет ДХТ-у, исписује резултате." | ||
1755 | |||
1756 | #: src/dht/gnunet-dht-monitor.c:268 | ||
1757 | msgid "how long should the monitor command run" | ||
1758 | msgstr "колико дуго треба да ради наредба праћења" | ||
1759 | |||
1760 | #: src/dht/gnunet-dht-monitor.c:293 | ||
1761 | msgid "Prints all packets that go through the DHT." | ||
1762 | msgstr "Исписује све пакете који иду кроз „DHT“." | ||
1763 | |||
1764 | #: src/dht/gnunet-dht-put.c:118 | ||
1765 | msgid "PUT request sent with key" | ||
1766 | msgstr "СТАВИ захтев је послат са кључем" | ||
1767 | |||
1768 | #: src/dht/gnunet-dht-put.c:121 | ||
1769 | msgid "Timeout sending PUT request!\n" | ||
1770 | msgstr "Истекло је време слања СТАВИ захтева!\n" | ||
1771 | |||
1772 | #: src/dht/gnunet-dht-put.c:124 | ||
1773 | msgid "PUT request not confirmed!\n" | ||
1774 | msgstr "Захтев СТАВИ није потврђен!\n" | ||
1775 | |||
1776 | #: src/dht/gnunet-dht-put.c:153 | ||
1777 | msgid "Must provide KEY and DATA for DHT put!\n" | ||
1778 | msgstr "Морате доставити КЉУЧ и ПОДАЦИ за ДХТ стављање!\n" | ||
1779 | |||
1780 | #: src/dht/gnunet-dht-put.c:160 | ||
1781 | #, c-format | ||
1782 | msgid "Could not connect to %s service!\n" | ||
1783 | msgstr "Не могу да се повежем са „%s“ услугом!\n" | ||
1784 | |||
1785 | #: src/dht/gnunet-dht-put.c:176 | ||
1786 | #, c-format | ||
1787 | msgid "Issuing put request for `%s' with data `%s'!\n" | ||
1788 | msgstr "Издајем захтев стављања за „%s“ са подацима „%s“!\n" | ||
1789 | |||
1790 | #: src/dht/gnunet-dht-put.c:192 | ||
1791 | msgid "the data to insert under the key" | ||
1792 | msgstr "подаци за уметање под кључем" | ||
1793 | |||
1794 | #: src/dht/gnunet-dht-put.c:195 | ||
1795 | msgid "how long to store this entry in the dht (in seconds)" | ||
1796 | msgstr "колико ће дуго да држи овај унос у дхт-у (у секундама)" | ||
1797 | |||
1798 | #: src/dht/gnunet-dht-put.c:204 | ||
1799 | msgid "how many replicas to create" | ||
1800 | msgstr "број реплика за стварање" | ||
1801 | |||
1802 | #: src/dht/gnunet-dht-put.c:207 | ||
1803 | msgid "the type to insert data as" | ||
1804 | msgstr "врста за уметање података" | ||
1805 | |||
1806 | #: src/dht/gnunet-dht-put.c:236 | ||
1807 | msgid "Issue a PUT request to the GNUnet DHT insert DATA under KEY." | ||
1808 | msgstr "Издаје захтев СТАВИ у ГНУнет ДХТ уметак ПОДАТАКА под КЉУЧЕМ." | ||
1809 | |||
1810 | #: src/dht/gnunet-service-dht.c:172 src/dht/gnunet-service-xdht.c:176 | ||
1811 | msgid "Failed to connect to transport service!\n" | ||
1812 | msgstr "Нисам успео да се повежем са услугом преноса!\n" | ||
1813 | |||
1814 | #: src/dht/gnunet-service-dht_clients.c:417 | ||
1815 | #: src/dht/gnunet-service-xdht_clients.c:838 | ||
1816 | msgid "# GET requests from clients injected" | ||
1817 | msgstr "# захтеви ДОБАВИ од клијената су убризгани" | ||
1818 | |||
1819 | #: src/dht/gnunet-service-dht_clients.c:513 | ||
1820 | #: src/dht/gnunet-service-xdht_clients.c:927 | ||
1821 | msgid "# PUT requests received from clients" | ||
1822 | msgstr "# захтеви СТАВИ су примљени од клијената" | ||
1823 | |||
1824 | #: src/dht/gnunet-service-dht_clients.c:597 | ||
1825 | #: src/dht/gnunet-service-xdht_clients.c:1013 | ||
1826 | msgid "# GET requests received from clients" | ||
1827 | msgstr "# захтеви ДОБАВИ су примљени од клијената" | ||
1828 | |||
1829 | #: src/dht/gnunet-service-dht_clients.c:798 | ||
1830 | #: src/dht/gnunet-service-xdht_clients.c:1214 | ||
1831 | msgid "# GET STOP requests received from clients" | ||
1832 | msgstr "# захтеви ДОБАВИ СТОП су примљени од клијената" | ||
1833 | |||
1834 | #: src/dht/gnunet-service-dht_clients.c:1039 | ||
1835 | #: src/dht/gnunet-service-xdht_clients.c:498 | ||
1836 | msgid "# Key match, type mismatches in REPLY to CLIENT" | ||
1837 | msgstr "# Кључ се поклапа, врсте се не поклапају у ОДГОВОР КЛИЈНЕТУ" | ||
1838 | |||
1839 | #: src/dht/gnunet-service-dht_clients.c:1052 | ||
1840 | #: src/dht/gnunet-service-xdht_clients.c:511 | ||
1841 | msgid "# Duplicate REPLIES to CLIENT request dropped" | ||
1842 | msgstr "# Двоструки захтев ОДГОВОРИ КЛИЈЕНТУ је одбачен" | ||
1843 | |||
1844 | #: src/dht/gnunet-service-dht_clients.c:1089 | ||
1845 | #: src/dht/gnunet-service-xdht_clients.c:548 | ||
1846 | #, c-format | ||
1847 | msgid "Unsupported block type (%u) in request!\n" | ||
1848 | msgstr "Неподржана врста блока (%u) у захтеву!\n" | ||
1849 | |||
1850 | #: src/dht/gnunet-service-dht_clients.c:1112 | ||
1851 | #: src/dht/gnunet-service-xdht_clients.c:571 | ||
1852 | msgid "# RESULTS queued for clients" | ||
1853 | msgstr "# РЕЗУЛТАТИ су стављени у ред за клијенте" | ||
1854 | |||
1855 | #: src/dht/gnunet-service-dht_clients.c:1166 | ||
1856 | #: src/dht/gnunet-service-dht_clients.c:1209 | ||
1857 | #: src/dht/gnunet-service-xdht_clients.c:625 | ||
1858 | #: src/dht/gnunet-service-xdht_clients.c:668 | ||
1859 | msgid "# REPLIES ignored for CLIENTS (no match)" | ||
1860 | msgstr "# ОДГОВОРИ су занемарени за КЛИЈЕНТЕ (нема поклапања)" | ||
1861 | |||
1862 | #: src/dht/gnunet-service-dht_clients.c:1176 | ||
1863 | #: src/dht/gnunet-service-xdht_clients.c:635 | ||
1864 | msgid "Could not pass reply to client, message too big!\n" | ||
1865 | msgstr "Не могу да проследим одговор клијенту, порука је превелика!\n" | ||
1866 | |||
1867 | #: src/dht/gnunet-service-dht_datacache.c:68 | ||
1868 | #: src/dht/gnunet-service-xdht_datacache.c:68 | ||
1869 | #, c-format | ||
1870 | msgid "%s request received, but have no datacache!\n" | ||
1871 | msgstr "„%s“ захтев је примљен, али нема оставу података!\n" | ||
1872 | |||
1873 | #: src/dht/gnunet-service-dht_datacache.c:78 | ||
1874 | #: src/dht/gnunet-service-xdht_datacache.c:78 | ||
1875 | msgid "# ITEMS stored in datacache" | ||
1876 | msgstr "# СТАВКЕ су смештене у оставу података" | ||
1877 | |||
1878 | #: src/dht/gnunet-service-dht_datacache.c:165 | ||
1879 | #: src/dht/gnunet-service-xdht_datacache.c:165 | ||
1880 | msgid "# Good RESULTS found in datacache" | ||
1881 | msgstr "# Добри РЕЗУЛТАТИ су нађени у остави података" | ||
1882 | |||
1883 | #: src/dht/gnunet-service-dht_datacache.c:176 | ||
1884 | #: src/dht/gnunet-service-xdht_datacache.c:176 | ||
1885 | msgid "# Duplicate RESULTS found in datacache" | ||
1886 | msgstr "# Двоструки РЕЗУЛТАТИ су нађени у остави података" | ||
1887 | |||
1888 | #: src/dht/gnunet-service-dht_datacache.c:182 | ||
1889 | #: src/dht/gnunet-service-xdht_datacache.c:182 | ||
1890 | msgid "# Invalid RESULTS found in datacache" | ||
1891 | msgstr "# Неисправни РЕЗУЛТАТИ су нађени у остави података" | ||
1892 | |||
1893 | #: src/dht/gnunet-service-dht_datacache.c:188 | ||
1894 | #: src/dht/gnunet-service-xdht_datacache.c:188 | ||
1895 | msgid "# Irrelevant RESULTS found in datacache" | ||
1896 | msgstr "# Неважни РЕЗУЛТАТИ су нађени у остави података" | ||
1897 | |||
1898 | #: src/dht/gnunet-service-dht_datacache.c:200 | ||
1899 | #: src/dht/gnunet-service-xdht_datacache.c:200 | ||
1900 | msgid "# Unsupported RESULTS found in datacache" | ||
1901 | msgstr "# Неподржани РЕЗУЛТАТИ су нађени у остави података" | ||
1902 | |||
1903 | #: src/dht/gnunet-service-dht_datacache.c:203 | ||
1904 | #: src/dht/gnunet-service-xdht_datacache.c:203 | ||
1905 | #, c-format | ||
1906 | msgid "Unsupported block type (%u) in local response!\n" | ||
1907 | msgstr "Неподржана врста блока (%u) у локалном одговору!\n" | ||
1908 | |||
1909 | #: src/dht/gnunet-service-dht_datacache.c:234 | ||
1910 | #: src/dht/gnunet-service-xdht_datacache.c:234 | ||
1911 | msgid "# GET requests given to datacache" | ||
1912 | msgstr "# ДОБАВИ захтеви су дати остави података" | ||
1913 | |||
1914 | #: src/dht/gnunet-service-dht_hello.c:84 | ||
1915 | #: src/dht/gnunet-service-xdht_hello.c:82 | ||
1916 | msgid "# HELLOs obtained from peerinfo" | ||
1917 | msgstr "# „HELLO“-и су добијени из података парњака" | ||
1918 | |||
1919 | #: src/dht/gnunet-service-dht_neighbours.c:516 | ||
1920 | msgid "# Preference updates given to core" | ||
1921 | msgstr "# Ажурирања поставки су дата језгру" | ||
1922 | |||
1923 | #: src/dht/gnunet-service-dht_neighbours.c:610 | ||
1924 | msgid "# FIND PEER messages initiated" | ||
1925 | msgstr "# НАЂИ ПАРЊАКА поруке су покренуте" | ||
1926 | |||
1927 | #: src/dht/gnunet-service-dht_neighbours.c:764 | ||
1928 | msgid "# Queued messages discarded (peer disconnected)" | ||
1929 | msgstr "# Поруке из реда су одбачене (парњак је ископчан)" | ||
1930 | |||
1931 | #: src/dht/gnunet-service-dht_neighbours.c:819 | ||
1932 | #: src/dht/gnunet-service-xdht_neighbours.c:703 | ||
1933 | msgid "# Bytes transmitted to other peers" | ||
1934 | msgstr "# Бајтови су пренесени другим парњацима" | ||
1935 | |||
1936 | #: src/dht/gnunet-service-dht_neighbours.c:857 | ||
1937 | #: src/dht/gnunet-service-xdht_neighbours.c:742 | ||
1938 | msgid "# Bytes of bandwidth requested from core" | ||
1939 | msgstr "# Бајтови пропусног опсега које захтева језгро" | ||
1940 | |||
1941 | #: src/dht/gnunet-service-dht_neighbours.c:889 | ||
1942 | msgid "# requests TTL-dropped" | ||
1943 | msgstr "# захтеви ТТЛ су одбачени" | ||
1944 | |||
1945 | #: src/dht/gnunet-service-dht_neighbours.c:1093 | ||
1946 | #: src/dht/gnunet-service-dht_neighbours.c:1130 | ||
1947 | msgid "# Peers excluded from routing due to Bloomfilter" | ||
1948 | msgstr "# Парњаци су изузети из рутирања због Блумфилтера" | ||
1949 | |||
1950 | #: src/dht/gnunet-service-dht_neighbours.c:1108 | ||
1951 | #: src/dht/gnunet-service-dht_neighbours.c:1145 | ||
1952 | msgid "# Peer selection failed" | ||
1953 | msgstr "# Бирање парњака није успело" | ||
1954 | |||
1955 | #: src/dht/gnunet-service-dht_neighbours.c:1287 | ||
1956 | msgid "# PUT requests routed" | ||
1957 | msgstr "# захтеви СТАВИ су рутирани" | ||
1958 | |||
1959 | #: src/dht/gnunet-service-dht_neighbours.c:1316 | ||
1960 | msgid "# PUT messages queued for transmission" | ||
1961 | msgstr "# СТАВИ поруке су у реду за пренос" | ||
1962 | |||
1963 | #: src/dht/gnunet-service-dht_neighbours.c:1323 | ||
1964 | #: src/dht/gnunet-service-dht_neighbours.c:1440 | ||
1965 | #: src/dht/gnunet-service-dht_neighbours.c:1543 | ||
1966 | #: src/dht/gnunet-service-xdht_neighbours.c:794 | ||
1967 | #: src/dht/gnunet-service-xdht_neighbours.c:860 | ||
1968 | #: src/dht/gnunet-service-xdht_neighbours.c:919 | ||
1969 | #: src/dht/gnunet-service-xdht_neighbours.c:981 | ||
1970 | #: src/dht/gnunet-service-xdht_neighbours.c:1041 | ||
1971 | msgid "# P2P messages dropped due to full queue" | ||
1972 | msgstr "# П2П поруке су одбачене због пуног реда" | ||
1973 | |||
1974 | #: src/dht/gnunet-service-dht_neighbours.c:1405 | ||
1975 | msgid "# GET requests routed" | ||
1976 | msgstr "# захтеви ДОБАВИ су рутирани" | ||
1977 | |||
1978 | #: src/dht/gnunet-service-dht_neighbours.c:1432 | ||
1979 | msgid "# GET messages queued for transmission" | ||
1980 | msgstr "# ДОБАВИ поруке су у реду за пренос" | ||
1981 | |||
1982 | #: src/dht/gnunet-service-dht_neighbours.c:1550 | ||
1983 | msgid "# RESULT messages queued for transmission" | ||
1984 | msgstr "# РЕЗУЛТАТ поруке су у реду за пренос" | ||
1985 | |||
1986 | #: src/dht/gnunet-service-dht_neighbours.c:1636 | ||
1987 | msgid "# P2P PUT requests received" | ||
1988 | msgstr "# захтеви П2П СТАВИ су примљени" | ||
1989 | |||
1990 | #: src/dht/gnunet-service-dht_neighbours.c:1639 | ||
1991 | msgid "# P2P PUT bytes received" | ||
1992 | msgstr "# бајтови П2П СТАВИ су примљени" | ||
1993 | |||
1994 | #: src/dht/gnunet-service-dht_neighbours.c:1803 | ||
1995 | msgid "# FIND PEER requests ignored due to Bloomfilter" | ||
1996 | msgstr "# захтеви НАЂИ ПАРЊАКА су занемарени због Блумфилтера" | ||
1997 | |||
1998 | #: src/dht/gnunet-service-dht_neighbours.c:1811 | ||
1999 | msgid "# FIND PEER requests ignored due to lack of HELLO" | ||
2000 | msgstr "# захтеви НАЂИ ПАРЊАКА су занемарени због недостатка „HELLO“-а" | ||
2001 | |||
2002 | #: src/dht/gnunet-service-dht_neighbours.c:1904 | ||
2003 | msgid "# P2P GET requests received" | ||
2004 | msgstr "# захтеви П2П ДОБАВИ су примљени" | ||
2005 | |||
2006 | #: src/dht/gnunet-service-dht_neighbours.c:1907 | ||
2007 | msgid "# P2P GET bytes received" | ||
2008 | msgstr "# бајтови П2П ДОБАВИ су примљени" | ||
2009 | |||
2010 | #: src/dht/gnunet-service-dht_neighbours.c:1961 | ||
2011 | msgid "# P2P FIND PEER requests processed" | ||
2012 | msgstr "# захтеви П2П НАЂИ ПАРЊАКА су обрађени" | ||
2013 | |||
2014 | #: src/dht/gnunet-service-dht_neighbours.c:1975 | ||
2015 | msgid "# P2P GET requests ONLY routed" | ||
2016 | msgstr "# захтеви П2П ДОБАВИ су САМО рутирани" | ||
2017 | |||
2018 | #: src/dht/gnunet-service-dht_neighbours.c:2052 | ||
2019 | msgid "# P2P RESULTS received" | ||
2020 | msgstr "# П2П РЕЗУЛТАТИ су примљени" | ||
2021 | |||
2022 | #: src/dht/gnunet-service-dht_neighbours.c:2055 | ||
2023 | msgid "# P2P RESULT bytes received" | ||
2024 | msgstr "# бајтови П2П РЕЗУЛТАТ су примљени" | ||
2025 | |||
2026 | #: src/dht/gnunet-service-dht_nse.c:59 src/dht/gnunet-service-xdht_nse.c:59 | ||
2027 | msgid "# Network size estimates received" | ||
2028 | msgstr "# Процене величине мреже су примљене" | ||
2029 | |||
2030 | #: src/dht/gnunet-service-dht_routing.c:211 | ||
2031 | msgid "# Good REPLIES matched against routing table" | ||
2032 | msgstr "# Добри ОДГОВОРИ су поклопљени наспрам табеле рутирања" | ||
2033 | |||
2034 | #: src/dht/gnunet-service-dht_routing.c:220 | ||
2035 | msgid "# Duplicate REPLIES matched against routing table" | ||
2036 | msgstr "# Двоструки ОДГОВОРИ су поклопљени наспрам табеле рутирања" | ||
2037 | |||
2038 | #: src/dht/gnunet-service-dht_routing.c:226 | ||
2039 | msgid "# Invalid REPLIES matched against routing table" | ||
2040 | msgstr "# Неисправни ОДГОВОРИ су поклопљени наспрам табеле рутирања" | ||
2041 | |||
2042 | #: src/dht/gnunet-service-dht_routing.c:232 | ||
2043 | msgid "# Irrelevant REPLIES matched against routing table" | ||
2044 | msgstr "# Неважни ОДГОВОРИ су поклопљени наспрам табеле рутирања" | ||
2045 | |||
2046 | #: src/dht/gnunet-service-dht_routing.c:244 | ||
2047 | msgid "# Unsupported REPLIES matched against routing table" | ||
2048 | msgstr "# Неподржани ОДГОВОРИ су поклопљени наспрам табеле рутирања" | ||
2049 | |||
2050 | #: src/dht/gnunet-service-dht_routing.c:317 | ||
2051 | msgid "# Entries removed from routing table" | ||
2052 | msgstr "# Уноси су уклоњени из табеле рутирања" | ||
2053 | |||
2054 | #: src/dht/gnunet-service-dht_routing.c:399 | ||
2055 | msgid "# Entries added to routing table" | ||
2056 | msgstr "# Уноси су додати у табелу рутирања" | ||
2057 | |||
2058 | #: src/dht/gnunet-service-dht_routing.c:417 | ||
2059 | msgid "# DHT requests combined" | ||
2060 | msgstr "# ДХТ захтеви су комбиновани" | ||
2061 | |||
2062 | #: src/dht/gnunet-service-xdht_neighbours.c:1398 | ||
2063 | #, c-format | ||
2064 | msgid "" | ||
2065 | "\n" | ||
2066 | "SUPU %s, %s, %d,my_identity = %s" | ||
2067 | msgstr "" | ||
2068 | "\n" | ||
2069 | "SUPU %s, %s, %d,my_identity = %s" | ||
2070 | |||
2071 | #: src/dht/gnunet-service-xdht_neighbours.c:1514 | ||
2072 | #: src/dht/gnunet-service-xdht_neighbours.c:1524 | ||
2073 | #: src/dht/gnunet-service-xdht_neighbours.c:1530 | ||
2074 | #: src/dht/gnunet-service-xdht_neighbours.c:1536 | ||
2075 | #: src/dht/gnunet-service-xdht_neighbours.c:1545 | ||
2076 | #, c-format | ||
2077 | msgid "" | ||
2078 | "\n" | ||
2079 | "SUPU %s, %s, %d" | ||
2080 | msgstr "" | ||
2081 | "\n" | ||
2082 | "SUPU %s, %s, %d" | ||
2083 | |||
2084 | #: src/dht/plugin_block_dht.c:138 | ||
2085 | #, c-format | ||
2086 | msgid "Block not of type %u\n" | ||
2087 | msgstr "Блок није врсте %u\n" | ||
2088 | |||
2089 | #: src/dht/plugin_block_dht.c:145 | ||
2090 | msgid "Size mismatch for block\n" | ||
2091 | msgstr "Величин не одговара за блок\n" | ||
2092 | |||
2093 | #: src/dht/plugin_block_dht.c:155 | ||
2094 | #, c-format | ||
2095 | msgid "Block of type %u is malformed\n" | ||
2096 | msgstr "Блок врсте %u је лош\n" | ||
2097 | |||
2098 | #: src/dns/dnsparser.c:257 | ||
2099 | #, c-format | ||
2100 | msgid "Failed to convert DNS IDNA name `%s' to UTF-8: %s\n" | ||
2101 | msgstr "Нисам успео да претворим ДНС ИДНА „%s“ у УТФ-8: %s\n" | ||
2102 | |||
2103 | #: src/dns/dnsparser.c:856 | ||
2104 | #, c-format | ||
2105 | msgid "Failed to convert UTF-8 name `%s' to DNS IDNA format: %s\n" | ||
2106 | msgstr "Нисам успео да претворим УТФ-8 назив „%s“ у ДНС ИДНА формат: %s\n" | ||
2107 | |||
2108 | #: src/dns/dnsstub.c:175 | ||
2109 | #, c-format | ||
2110 | msgid "Could not bind to any port: %s\n" | ||
2111 | msgstr "Не могу да се вежем ни за један прикључник: %s\n" | ||
2112 | |||
2113 | #: src/dns/dnsstub.c:295 src/dns/dnsstub.c:383 | ||
2114 | #, c-format | ||
2115 | msgid "Failed to send DNS request to %s\n" | ||
2116 | msgstr "Нисам успео да пошаљем ДНС захтев за %s\n" | ||
2117 | |||
2118 | #: src/dns/dnsstub.c:299 | ||
2119 | #, c-format | ||
2120 | msgid "Sent DNS request to %s\n" | ||
2121 | msgstr "Послао сам ДНС захтев за %s\n" | ||
2122 | |||
2123 | #: src/dns/dnsstub.c:368 | ||
2124 | #, c-format | ||
2125 | msgid "Configured DNS exit `%s' is not working / valid.\n" | ||
2126 | msgstr "Подешени ДНС излаз „%s“ не ради / није исправан.\n" | ||
2127 | |||
2128 | #: src/dns/dnsstub.c:440 | ||
2129 | #, c-format | ||
2130 | msgid "Received DNS response that is too small (%u bytes)" | ||
2131 | msgstr "Примих ДНС одговор који је премали (%u бајта)" | ||
2132 | |||
2133 | #: src/dns/gnunet-dns-monitor.c:355 | ||
2134 | msgid "only monitor DNS queries" | ||
2135 | msgstr "само надгледа ДНС упите" | ||
2136 | |||
2137 | #: src/dns/gnunet-dns-monitor.c:358 | ||
2138 | msgid "only monitor DNS replies" | ||
2139 | msgstr "само надгледа ДНС одговоре" | ||
2140 | |||
2141 | #: src/dns/gnunet-dns-monitor.c:369 | ||
2142 | msgid "Monitor DNS queries." | ||
2143 | msgstr "Надгледа ДНС упите." | ||
2144 | |||
2145 | #: src/dns/gnunet-dns-redirector.c:236 | ||
2146 | msgid "set A records" | ||
2147 | msgstr "поставља A записе" | ||
2148 | |||
2149 | #: src/dns/gnunet-dns-redirector.c:239 | ||
2150 | msgid "set AAAA records" | ||
2151 | msgstr "поставља AAAA записе" | ||
2152 | |||
2153 | #: src/dns/gnunet-dns-redirector.c:251 | ||
2154 | msgid "Change DNS replies to point elsewhere." | ||
2155 | msgstr "Мења ДНС одговоре да показују негде другде." | ||
2156 | |||
2157 | #: src/dns/gnunet-service-dns.c:456 | ||
2158 | msgid "# DNS requests answered via TUN interface" | ||
2159 | msgstr "# на ДНС захтеве је одговорено путем ТУН сучеља" | ||
2160 | |||
2161 | #: src/dns/gnunet-service-dns.c:603 | ||
2162 | msgid "# DNS exit failed (failed to open socket)" | ||
2163 | msgstr "# ДНС излаз није успео (нисам успео да отворим прикључницу)" | ||
2164 | |||
2165 | #: src/dns/gnunet-service-dns.c:714 | ||
2166 | msgid "# External DNS response discarded (no matching request)" | ||
2167 | msgstr "# Спољни ДНС одговор је одбачен (нема одговарајућег захтева)" | ||
2168 | |||
2169 | #: src/dns/gnunet-service-dns.c:792 | ||
2170 | msgid "# Client response discarded (no matching request)" | ||
2171 | msgstr "# Одговор клијента је одбачен (нема одговарајућег захтева)" | ||
2172 | |||
2173 | #: src/dns/gnunet-service-dns.c:907 | ||
2174 | msgid "Received malformed IPv4-UDP packet on TUN interface.\n" | ||
2175 | msgstr "Примих лош ИПв4-УДП пакет на ТУН сучељу.\n" | ||
2176 | |||
2177 | #: src/dns/gnunet-service-dns.c:923 | ||
2178 | msgid "Received malformed IPv6-UDP packet on TUN interface.\n" | ||
2179 | msgstr "Примих лош ИПв6-УДП пакет на ТУН сучељу.\n" | ||
2180 | |||
2181 | #: src/dns/gnunet-service-dns.c:932 | ||
2182 | #, c-format | ||
2183 | msgid "Got non-IP packet with %u bytes and protocol %u from TUN\n" | ||
2184 | msgstr "Добих не-ИП пакет са %u бајта и протокол %u са ТУН-а\n" | ||
2185 | |||
2186 | #: src/dns/gnunet-service-dns.c:942 | ||
2187 | msgid "# Non-DNS UDP packet received via TUN interface" | ||
2188 | msgstr "# Не-ДНС УДП пакет је примљен путем ТУН сучеља" | ||
2189 | |||
2190 | #: src/dns/gnunet-service-dns.c:1009 | ||
2191 | msgid "# DNS requests received via TUN interface" | ||
2192 | msgstr "# ДНС захтеви су примљени путем ТУН сучеља" | ||
2193 | |||
2194 | #: src/dns/gnunet-service-dns.c:1049 src/exit/gnunet-daemon-exit.c:3514 | ||
2195 | #, c-format | ||
2196 | msgid "`%s' must be installed SUID, refusing to run\n" | ||
2197 | msgstr "„%s“ мора бити инсталиран СУИБ, одбијам да радим\n" | ||
2198 | |||
2199 | #: src/dns/gnunet-service-dns.c:1069 src/exit/gnunet-daemon-exit.c:3571 | ||
2200 | msgid "need a valid IPv4 or IPv6 address\n" | ||
2201 | msgstr "потребна је исправна ИПв4 или ИПв6 адреса\n" | ||
2202 | |||
2203 | #: src/dv/gnunet-dv.c:169 | ||
2204 | msgid "verbose output" | ||
2205 | msgstr "опширан излаз" | ||
2206 | |||
2207 | #: src/dv/gnunet-dv.c:178 | ||
2208 | msgid "Print information about DV state" | ||
2209 | msgstr "Исписује податке о ДВ стању" | ||
2210 | |||
2211 | #: src/exit/gnunet-daemon-exit.c:802 | ||
2212 | #, c-format | ||
2213 | msgid "Got duplicate service records for `%s:%u'\n" | ||
2214 | msgstr "Добих двоструке записе услуге за `%s:%u'\n" | ||
2215 | |||
2216 | #: src/exit/gnunet-daemon-exit.c:853 | ||
2217 | msgid "# Bytes transmitted via mesh channels" | ||
2218 | msgstr "# Бајтови су пренесени путем меш канала" | ||
2219 | |||
2220 | #: src/exit/gnunet-daemon-exit.c:970 src/exit/gnunet-daemon-exit.c:2397 | ||
2221 | #: src/exit/gnunet-daemon-exit.c:2654 src/vpn/gnunet-service-vpn.c:1407 | ||
2222 | #: src/vpn/gnunet-service-vpn.c:1797 src/vpn/gnunet-service-vpn.c:1960 | ||
2223 | msgid "# ICMPv4 packets dropped (type not allowed)" | ||
2224 | msgstr "# ICMPv4 пакети су одбачени (врста није дозвољена)" | ||
2225 | |||
2226 | #: src/exit/gnunet-daemon-exit.c:1007 src/exit/gnunet-daemon-exit.c:2456 | ||
2227 | #: src/exit/gnunet-daemon-exit.c:2713 src/vpn/gnunet-service-vpn.c:1463 | ||
2228 | #: src/vpn/gnunet-service-vpn.c:1856 src/vpn/gnunet-service-vpn.c:1993 | ||
2229 | msgid "# ICMPv6 packets dropped (type not allowed)" | ||
2230 | msgstr "# ICMPv6 пакети су одбачени (врста није дозвољена)" | ||
2231 | |||
2232 | #: src/exit/gnunet-daemon-exit.c:1047 | ||
2233 | msgid "# ICMP packets dropped (not allowed)" | ||
2234 | msgstr "# ICMP пакет је одбачен (није дозвољен)" | ||
2235 | |||
2236 | #: src/exit/gnunet-daemon-exit.c:1054 | ||
2237 | msgid "ICMP Packet dropped, have no matching connection information\n" | ||
2238 | msgstr "ICMP Пакет је одбачен, нема одговарајуће податке о вези\n" | ||
2239 | |||
2240 | #: src/exit/gnunet-daemon-exit.c:1130 | ||
2241 | msgid "UDP Packet dropped, have no matching connection information\n" | ||
2242 | msgstr "UDP Пакет је одбачен, нема одговарајуће податке о вези\n" | ||
2243 | |||
2244 | #: src/exit/gnunet-daemon-exit.c:1204 | ||
2245 | msgid "TCP Packet dropped, have no matching connection information\n" | ||
2246 | msgstr "TCP Пакет је одбачен, нема одговарајуће податке о вези\n" | ||
2247 | |||
2248 | #: src/exit/gnunet-daemon-exit.c:1256 | ||
2249 | msgid "# Packets received from TUN" | ||
2250 | msgstr "# Пакети су примљени од TUN-а" | ||
2251 | |||
2252 | #: src/exit/gnunet-daemon-exit.c:1270 | ||
2253 | msgid "# Bytes received from TUN" | ||
2254 | msgstr "# Бајтови су примљени од TUN-а" | ||
2255 | |||
2256 | #: src/exit/gnunet-daemon-exit.c:1296 | ||
2257 | msgid "IPv4 packet options received. Ignored.\n" | ||
2258 | msgstr "Опције IPv4 пакета су примљене. Занемарено.\n" | ||
2259 | |||
2260 | #: src/exit/gnunet-daemon-exit.c:1323 | ||
2261 | #, c-format | ||
2262 | msgid "IPv4 packet with unsupported next header %u received. Ignored.\n" | ||
2263 | msgstr "IPv4 пакет са неподржаним следећим заглављем %u је примљен. Занемарено.\n" | ||
2264 | |||
2265 | #: src/exit/gnunet-daemon-exit.c:1369 | ||
2266 | #, c-format | ||
2267 | msgid "IPv6 packet with unsupported next header %d received. Ignored.\n" | ||
2268 | msgstr "IPv6 пакет са неподржаним следећим заглављем %d је примљен. Занемарено.\n" | ||
2269 | |||
2270 | #: src/exit/gnunet-daemon-exit.c:1377 | ||
2271 | #, c-format | ||
2272 | msgid "Packet from unknown protocol %u received. Ignored.\n" | ||
2273 | msgstr "Пакет са непознатог протокола %u је примљен. Занемарено.\n" | ||
2274 | |||
2275 | #: src/exit/gnunet-daemon-exit.c:1759 | ||
2276 | msgid "# TCP packets sent via TUN" | ||
2277 | msgstr "# ТЦП пакети су послати путем ТУН-а" | ||
2278 | |||
2279 | #: src/exit/gnunet-daemon-exit.c:1872 | ||
2280 | msgid "# TCP service creation requests received via mesh" | ||
2281 | msgstr "# Захтеви стварања ТЦП услуге су примљени путем меша" | ||
2282 | |||
2283 | #: src/exit/gnunet-daemon-exit.c:1875 src/exit/gnunet-daemon-exit.c:1968 | ||
2284 | #: src/exit/gnunet-daemon-exit.c:2073 src/exit/gnunet-daemon-exit.c:2321 | ||
2285 | #: src/exit/gnunet-daemon-exit.c:2570 src/exit/gnunet-daemon-exit.c:2859 | ||
2286 | #: src/exit/gnunet-daemon-exit.c:2966 | ||
2287 | msgid "# Bytes received from MESH" | ||
2288 | msgstr "# Бајтови су примљени од МЕША" | ||
2289 | |||
2290 | #: src/exit/gnunet-daemon-exit.c:1909 src/exit/gnunet-daemon-exit.c:2990 | ||
2291 | #, c-format | ||
2292 | msgid "No service %s found for %s on port %d!\n" | ||
2293 | msgstr "Ниједна услуга %s није нађена %s на прикључнику %d!\n" | ||
2294 | |||
2295 | #: src/exit/gnunet-daemon-exit.c:1914 | ||
2296 | msgid "# TCP requests dropped (no such service)" | ||
2297 | msgstr "# TCP захтеви су одбачени (нема такве услуге)" | ||
2298 | |||
2299 | #: src/exit/gnunet-daemon-exit.c:1971 | ||
2300 | msgid "# TCP IP-exit creation requests received via mesh" | ||
2301 | msgstr "# Захтеви стварања ТЦП ИП-излаза су примљени путем меша" | ||
2302 | |||
2303 | #: src/exit/gnunet-daemon-exit.c:2076 | ||
2304 | msgid "# TCP data requests received via mesh" | ||
2305 | msgstr "# Захтеви ТЦП података су примљени путем меша" | ||
2306 | |||
2307 | #: src/exit/gnunet-daemon-exit.c:2090 | ||
2308 | msgid "# TCP DATA requests dropped (no session)" | ||
2309 | msgstr "# TCP DATA захтеви су одбачени (нема сесије)" | ||
2310 | |||
2311 | #: src/exit/gnunet-daemon-exit.c:2150 | ||
2312 | msgid "# ICMP packets sent via TUN" | ||
2313 | msgstr "# ICMP пакети су послати путем TUN-а" | ||
2314 | |||
2315 | #: src/exit/gnunet-daemon-exit.c:2324 | ||
2316 | msgid "# ICMP IP-exit requests received via mesh" | ||
2317 | msgstr "# Захтеви ИЦМП ИП-излаза су примљени путем меша" | ||
2318 | |||
2319 | #: src/exit/gnunet-daemon-exit.c:2573 | ||
2320 | msgid "# ICMP service requests received via mesh" | ||
2321 | msgstr "# Захтеви ИЦМП услуге су примљени путем меша" | ||
2322 | |||
2323 | #: src/exit/gnunet-daemon-exit.c:2639 src/vpn/gnunet-service-vpn.c:1397 | ||
2324 | #: src/vpn/gnunet-service-vpn.c:1954 | ||
2325 | msgid "# ICMPv4 packets dropped (impossible PT to v6)" | ||
2326 | msgstr "# ICMPv4 пакети су одбачени (немогуће PT за v6)" | ||
2327 | |||
2328 | #: src/exit/gnunet-daemon-exit.c:2698 src/vpn/gnunet-service-vpn.c:1433 | ||
2329 | #: src/vpn/gnunet-service-vpn.c:1445 src/vpn/gnunet-service-vpn.c:1844 | ||
2330 | msgid "# ICMPv6 packets dropped (impossible PT to v4)" | ||
2331 | msgstr "# ICMPv6 пакети су одбачени (немогуће PT за v4)" | ||
2332 | |||
2333 | #: src/exit/gnunet-daemon-exit.c:2748 | ||
2334 | msgid "# UDP packets sent via TUN" | ||
2335 | msgstr "# UDP пакети су послати путем TUN-а" | ||
2336 | |||
2337 | #: src/exit/gnunet-daemon-exit.c:2862 | ||
2338 | msgid "# UDP IP-exit requests received via mesh" | ||
2339 | msgstr "# Захтеви УДП ИП-излаза су примљени путем меша" | ||
2340 | |||
2341 | #: src/exit/gnunet-daemon-exit.c:2969 | ||
2342 | msgid "# UDP service requests received via mesh" | ||
2343 | msgstr "# Захтеви УДП услуге су примљени путем меша" | ||
2344 | |||
2345 | #: src/exit/gnunet-daemon-exit.c:2995 | ||
2346 | msgid "# UDP requests dropped (no such service)" | ||
2347 | msgstr "# UDP захтеви су одбачени (нема такве услуге)" | ||
2348 | |||
2349 | #: src/exit/gnunet-daemon-exit.c:3031 | ||
2350 | msgid "# Inbound MESH channels created" | ||
2351 | msgstr "# Долазни МЕШ канали су створени" | ||
2352 | |||
2353 | #: src/exit/gnunet-daemon-exit.c:3235 src/exit/gnunet-daemon-exit.c:3245 | ||
2354 | #, c-format | ||
2355 | msgid "Option `%s' for domain `%s' is not formatted correctly!\n" | ||
2356 | msgstr "Опција „%s“ за домен „%s“ није форматирана исправна!\n" | ||
2357 | |||
2358 | #: src/exit/gnunet-daemon-exit.c:3259 src/exit/gnunet-daemon-exit.c:3267 | ||
2359 | #, c-format | ||
2360 | msgid "`%s' is not a valid port number (for domain `%s')!" | ||
2361 | msgstr "„%s“ није исправан број прикључника (за домен „%s“)!" | ||
2362 | |||
2363 | #: src/exit/gnunet-daemon-exit.c:3300 | ||
2364 | #, c-format | ||
2365 | msgid "No addresses found for hostname `%s' of service `%s'!\n" | ||
2366 | msgstr "Није нађена ниједна адрееса за назив домаћина „%s“ услуге „%s“!\n" | ||
2367 | |||
2368 | #: src/exit/gnunet-daemon-exit.c:3314 src/exit/gnunet-daemon-exit.c:3326 | ||
2369 | #, c-format | ||
2370 | msgid "Service `%s' configured for IPv4, but IPv4 is disabled!\n" | ||
2371 | msgstr "Услуга „%s“ је подешена за IPv4, али IPv4 је искључено!\n" | ||
2372 | |||
2373 | #: src/exit/gnunet-daemon-exit.c:3337 | ||
2374 | #, c-format | ||
2375 | msgid "No IP addresses found for hostname `%s' of service `%s'!\n" | ||
2376 | msgstr "Није нађена ниједна ИП адрееса за назив домаћина „%s“ услуге „%s“!\n" | ||
2377 | |||
2378 | #: src/exit/gnunet-daemon-exit.c:3527 | ||
2379 | msgid "This system does not support IPv4, will disable IPv4 functions despite them being enabled in the configuration\n" | ||
2380 | msgstr "Овај систем не подржава IPv4, искључиће IPv4 функције упркос томе што су укључене у подешавањима\n" | ||
2381 | |||
2382 | #: src/exit/gnunet-daemon-exit.c:3535 | ||
2383 | msgid "This system does not support IPv6, will disable IPv6 functions despite them being enabled in the configuration\n" | ||
2384 | msgstr "Овај систем не подржава IPv6, искључиће IPv6 функције упркос томе што су укључене у подешавањима\n" | ||
2385 | |||
2386 | #: src/exit/gnunet-daemon-exit.c:3542 | ||
2387 | msgid "Cannot enable IPv4 exit but disable IPv4 on TUN interface, will use ENABLE_IPv4=YES\n" | ||
2388 | msgstr "Не могу да укључим ИПв4 излаз али искључујем ИПв4 на ТУН сучељу, користићу „ENABLE_IPv4=ДА“\n" | ||
2389 | |||
2390 | #: src/exit/gnunet-daemon-exit.c:3548 | ||
2391 | msgid "Cannot enable IPv6 exit but disable IPv6 on TUN interface, will use ENABLE_IPv6=YES\n" | ||
2392 | msgstr "Не могу да укључим ИПв6 излаз али искључујем ИПв6 на ТУН сучељу, користићу „ENABLE_IPv6=ДА“\n" | ||
2393 | |||
2394 | #: src/exit/gnunet-daemon-exit.c:3554 src/exit/gnunet-daemon-exit.c:3717 | ||
2395 | #: src/pt/gnunet-daemon-pt.c:1247 | ||
2396 | msgid "No useful service enabled. Exiting.\n" | ||
2397 | msgstr "Ниједна корисна услуга није укључена. Излазим.\n" | ||
2398 | |||
2399 | #: src/exit/gnunet-daemon-exit.c:3664 | ||
2400 | msgid "Must be a number" | ||
2401 | msgstr "Мора бити број" | ||
2402 | |||
2403 | #: src/exit/gnunet-daemon-exit.c:3813 | ||
2404 | msgid "Daemon to run to provide an IP exit node for the VPN" | ||
2405 | msgstr "Демон за покретање за обезбеђивање чвора ИП излаза за ВПН" | ||
2406 | |||
2407 | #: src/experimentation/gnunet-daemon-experimentation.c:55 | ||
2408 | msgid "Experimentation daemon shutting down ...\n" | ||
2409 | msgstr "Демон експериментисања се гаси ...\n" | ||
2410 | |||
2411 | #: src/experimentation/gnunet-daemon-experimentation.c:77 | ||
2412 | msgid "Experimentation daemon starting ...\n" | ||
2413 | msgstr "Демон експериментисања се покреће ...\n" | ||
2414 | |||
2415 | #: src/experimentation/gnunet-daemon-experimentation.c:83 | ||
2416 | msgid "Failed to create statistics!\n" | ||
2417 | msgstr "Нисам успео да направим статистику!\n" | ||
2418 | |||
2419 | #: src/experimentation/gnunet-daemon-experimentation.c:120 | ||
2420 | msgid "GNUnet experimentation daemon" | ||
2421 | msgstr "Демон експериментисања ГНУнет-а" | ||
2422 | |||
2423 | #: src/experimentation/gnunet-daemon-experimentation_experiments.c:241 | ||
2424 | #, c-format | ||
2425 | msgid "Experiment `%s': Experiment signature is invalid\n" | ||
2426 | msgstr "Експеримент „%s“: Потпис експеримента је неисправан\n" | ||
2427 | |||
2428 | #: src/experimentation/gnunet-daemon-experimentation_experiments.c:250 | ||
2429 | #, c-format | ||
2430 | msgid "Adding experiment `%s' running from `%s' to `%s' every %llu sec. for %llu sec. \n" | ||
2431 | msgstr "Додајем експеримент „%s“ који ради из „%s“ у „%s“ сваке %llu сек. за %llu сек. \n" | ||
2432 | |||
2433 | #: src/experimentation/gnunet-daemon-experimentation_experiments.c:303 | ||
2434 | #, c-format | ||
2435 | msgid "Experiment `%s': Issuer missing\n" | ||
2436 | msgstr "Експеримент „%s“: Недостаје издавач\n" | ||
2437 | |||
2438 | #: src/experimentation/gnunet-daemon-experimentation_experiments.c:312 | ||
2439 | #, c-format | ||
2440 | msgid "Experiment `%s': Issuer invalid\n" | ||
2441 | msgstr "Експеримент „%s“: Неисправан издавач\n" | ||
2442 | |||
2443 | #: src/experimentation/gnunet-daemon-experimentation_experiments.c:320 | ||
2444 | #, c-format | ||
2445 | msgid "Experiment `%s': Issuer not accepted!\n" | ||
2446 | msgstr "Експеримент „%s“: Издавач није прихваћен!\n" | ||
2447 | |||
2448 | #: src/experimentation/gnunet-daemon-experimentation_experiments.c:330 | ||
2449 | #, c-format | ||
2450 | msgid "Experiment `%s': Version missing or invalid \n" | ||
2451 | msgstr "Експеримент „%s“: Недостаје издање или је неисправно \n" | ||
2452 | |||
2453 | #: src/experimentation/gnunet-daemon-experimentation_experiments.c:339 | ||
2454 | #, c-format | ||
2455 | msgid "Experiment `%s': Required capabilities missing \n" | ||
2456 | msgstr "Експеримент „%s“: Захтеване могућности недостају \n" | ||
2457 | |||
2458 | #: src/experimentation/gnunet-daemon-experimentation_experiments.c:345 | ||
2459 | #, c-format | ||
2460 | msgid "Experiment `%s': Required capabilities invalid \n" | ||
2461 | msgstr "Експеримент „%s“: Захтеване могућности су неисправне \n" | ||
2462 | |||
2463 | #: src/experimentation/gnunet-daemon-experimentation_experiments.c:390 | ||
2464 | #, c-format | ||
2465 | msgid "Failed to parse file `%s'\n" | ||
2466 | msgstr "Нисам успео да обрадим датотеку „%s“\n" | ||
2467 | |||
2468 | #: src/experimentation/gnunet-daemon-experimentation_experiments.c:420 | ||
2469 | #: src/experimentation/gnunet-daemon-experimentation_experiments.c:452 | ||
2470 | msgid "No valid experiment issuers configured! Set value to public keys of issuers! Exiting.\n" | ||
2471 | msgstr "Нису подешени исправни издавачи експеримента! Поставите вредност на јавне кључеве издавача! Излазим.\n" | ||
2472 | |||
2473 | #: src/experimentation/gnunet-daemon-experimentation_experiments.c:435 | ||
2474 | msgid "Invalid value for public key\n" | ||
2475 | msgstr "Неисправна вредност за јавни кључ\n" | ||
2476 | |||
2477 | #: src/experimentation/gnunet-daemon-experimentation_experiments.c:473 | ||
2478 | #, c-format | ||
2479 | msgid "Cannot read experiments file `%s'\n" | ||
2480 | msgstr "Не могу да прочитам датотеку експеримената „%s“\n" | ||
2481 | |||
2482 | #: src/experimentation/gnunet-daemon-experimentation_nodes.c:221 | ||
2483 | #, c-format | ||
2484 | msgid "Cannot send message to peer `%s' for experiment `%s'\n" | ||
2485 | msgstr "Не могу да пошаљем поруку парњаку „%s“ за екперимент „%s“\n" | ||
2486 | |||
2487 | #: src/experimentation/gnunet-daemon-experimentation_nodes.c:309 | ||
2488 | #, c-format | ||
2489 | msgid "Sending experimentation request to peer %s\n" | ||
2490 | msgstr "Шаљем захтев експериментисања парњаку %s\n" | ||
2491 | |||
2492 | #: src/experimentation/gnunet-daemon-experimentation_nodes.c:453 | ||
2493 | #, c-format | ||
2494 | msgid "Added peer `%s' as active node\n" | ||
2495 | msgstr "Додат је парњак „%s“ као активан чвор\n" | ||
2496 | |||
2497 | #: src/experimentation/gnunet-daemon-experimentation_nodes.c:891 | ||
2498 | #, c-format | ||
2499 | msgid "Connected to peer %s\n" | ||
2500 | msgstr "Повезан са парњаком „%s“\n" | ||
2501 | |||
2502 | #: src/experimentation/gnunet-daemon-experimentation_nodes.c:921 | ||
2503 | #, c-format | ||
2504 | msgid "Disconnected from peer %s\n" | ||
2505 | msgstr "Прекинута је веза са парњаком „%s“\n" | ||
2506 | |||
2507 | #: src/experimentation/gnunet-daemon-experimentation_nodes.c:1104 | ||
2508 | msgid "Failed to connect to CORE service!\n" | ||
2509 | msgstr "Нисам успео да се повежем са ЈЕЗГРЕНОМ услугом!\n" | ||
2510 | |||
2511 | #: src/experimentation/gnunet-daemon-experimentation_scheduler.c:108 | ||
2512 | #, c-format | ||
2513 | msgid "Peer `%s' did not respond to request for experiment `%s'\n" | ||
2514 | msgstr "Парњак „%s“ није одговорио на захтев за експериментом „%s“\n" | ||
2515 | |||
2516 | #: src/experimentation/gnunet-daemon-experimentation_scheduler.c:143 | ||
2517 | #, c-format | ||
2518 | msgid "Starting inbound experiment `%s' with peer `%s'\n" | ||
2519 | msgstr "Покрећем експеримент долазности „%s“ са парњаком „%s“\n" | ||
2520 | |||
2521 | #: src/experimentation/gnunet-daemon-experimentation_scheduler.c:276 | ||
2522 | #, c-format | ||
2523 | msgid "Starting outbound experiment `%s' with peer `%s'\n" | ||
2524 | msgstr "Покрећем експеримент одлазности „%s“ са парњаком „%s“\n" | ||
2525 | |||
2526 | #: src/experimentation/gnunet-daemon-experimentation_scheduler.c:294 | ||
2527 | #, c-format | ||
2528 | msgid "Received %s message from peer %s for experiment `%s'\n" | ||
2529 | msgstr "Примих %s поруку са парњака %s за експеримент „%s“\n" | ||
2530 | |||
2531 | #: src/fragmentation/defragmentation.c:270 | ||
2532 | msgid "# acknowledgements sent for fragment" | ||
2533 | msgstr "# потврде су послате за делић" | ||
2534 | |||
2535 | #: src/fragmentation/defragmentation.c:456 | ||
2536 | msgid "# fragments received" | ||
2537 | msgstr "# делићи су примљени" | ||
2538 | |||
2539 | #: src/fragmentation/defragmentation.c:521 | ||
2540 | msgid "# duplicate fragments received" | ||
2541 | msgstr "# двоструки делићи су примљени" | ||
2542 | |||
2543 | #: src/fragmentation/defragmentation.c:534 | ||
2544 | msgid "# messages defragmented" | ||
2545 | msgstr "# делићи порука су уједињени" | ||
2546 | |||
2547 | #: src/fragmentation/fragmentation.c:208 | ||
2548 | msgid "# fragments transmitted" | ||
2549 | msgstr "# делићи су пренесени" | ||
2550 | |||
2551 | #: src/fragmentation/fragmentation.c:211 | ||
2552 | msgid "# fragments retransmitted" | ||
2553 | msgstr "# делићи су поново пренесени" | ||
2554 | |||
2555 | #: src/fragmentation/fragmentation.c:237 | ||
2556 | msgid "# fragments wrap arounds" | ||
2557 | msgstr "# делићи се преламају около" | ||
2558 | |||
2559 | #: src/fragmentation/fragmentation.c:281 | ||
2560 | msgid "# messages fragmented" | ||
2561 | msgstr "# поруке су расцепкане" | ||
2562 | |||
2563 | #: src/fragmentation/fragmentation.c:284 | ||
2564 | msgid "# total size of fragmented messages" | ||
2565 | msgstr "# укупна величина расцепканих порука" | ||
2566 | |||
2567 | #: src/fragmentation/fragmentation.c:405 | ||
2568 | msgid "# fragment acknowledgements received" | ||
2569 | msgstr "# потврде делића су примљене" | ||
2570 | |||
2571 | #: src/fragmentation/fragmentation.c:411 | ||
2572 | msgid "# bits removed from fragmentation ACKs" | ||
2573 | msgstr "# битови су уклоњени из АЦК-ова расцепканости" | ||
2574 | |||
2575 | #: src/fragmentation/fragmentation.c:435 | ||
2576 | msgid "# fragmentation transmissions completed" | ||
2577 | msgstr "# преноси расцепканости су завршени" | ||
2578 | |||
2579 | #: src/fs/fs_api.c:465 | ||
2580 | #, c-format | ||
2581 | msgid "Could not open file `%s': %s" | ||
2582 | msgstr "Не могу да отворим датотеку „%s“: %s" | ||
2583 | |||
2584 | #: src/fs/fs_api.c:474 | ||
2585 | #, c-format | ||
2586 | msgid "Could not read file `%s': %s" | ||
2587 | msgstr "Не могу да читам датотеку „%s“: %s" | ||
2588 | |||
2589 | #: src/fs/fs_api.c:480 | ||
2590 | #, c-format | ||
2591 | msgid "Short read reading from file `%s'!" | ||
2592 | msgstr "Кратко читање читајући из датотеке „%s“!" | ||
2593 | |||
2594 | #: src/fs/fs_api.c:1066 | ||
2595 | #, c-format | ||
2596 | msgid "Failed to resume publishing information `%s': %s\n" | ||
2597 | msgstr "Нисам успео да наставим са подацима објављивања „%s“: %s\n" | ||
2598 | |||
2599 | #: src/fs/fs_api.c:1571 | ||
2600 | #, c-format | ||
2601 | msgid "Failure while resuming publishing operation `%s': %s\n" | ||
2602 | msgstr "Неуспех приликом настављања са радњом објављивања „%s“: %s\n" | ||
2603 | |||
2604 | #: src/fs/fs_api.c:1585 | ||
2605 | #, c-format | ||
2606 | msgid "Failed to resume publishing operation `%s': %s\n" | ||
2607 | msgstr "Нисам успео да наставим са радњом објављивања „%s“: %s\n" | ||
2608 | |||
2609 | #: src/fs/fs_api.c:2242 | ||
2610 | #, c-format | ||
2611 | msgid "Failure while resuming unindexing operation `%s': %s\n" | ||
2612 | msgstr "Неуспех приликом настављања са радњом поништавања индексирања „%s“: %s\n" | ||
2613 | |||
2614 | #: src/fs/fs_api.c:2252 | ||
2615 | #, c-format | ||
2616 | msgid "Failed to resume unindexing operation `%s': %s\n" | ||
2617 | msgstr "Нисам успео да наставим са радњом поништавања индексирања „%s“: %s\n" | ||
2618 | |||
2619 | #: src/fs/fs_api.c:2378 src/fs/fs_api.c:2619 | ||
2620 | #, c-format | ||
2621 | msgid "Failed to resume sub-download `%s': %s\n" | ||
2622 | msgstr "Нисам успео да наставим са садржаним преузимањем „%s“: %s\n" | ||
2623 | |||
2624 | #: src/fs/fs_api.c:2395 | ||
2625 | #, c-format | ||
2626 | msgid "Failed to resume sub-search `%s': %s\n" | ||
2627 | msgstr "Нисам успео да наставим са садржаном претрагом „%s“: %s\n" | ||
2628 | |||
2629 | #: src/fs/fs_api.c:2409 src/fs/fs_api.c:2428 src/fs/fs_api.c:2911 | ||
2630 | #, c-format | ||
2631 | msgid "Failure while resuming search operation `%s': %s\n" | ||
2632 | msgstr "Неуспех приликом настављања са радњом претраге „%s“: %s\n" | ||
2633 | |||
2634 | #: src/fs/fs_api.c:2610 | ||
2635 | #, c-format | ||
2636 | msgid "Failed to resume sub-download `%s': could not open file `%s'\n" | ||
2637 | msgstr "Нисам успео да наставим са садржаним преузимањем „%s“: не могу да отворим датотеку „%s“\n" | ||
2638 | |||
2639 | #: src/fs/fs_api.c:2855 | ||
2640 | msgid "Could not resume running search, will resume as paused search\n" | ||
2641 | msgstr "Не могу да наставим са покренутом претрагом, наставићу као са паузираном претрагом\n" | ||
2642 | |||
2643 | #: src/fs/fs_api.c:2949 | ||
2644 | #, c-format | ||
2645 | msgid "Failure while resuming download operation `%s': %s\n" | ||
2646 | msgstr "Неуспех приликом настављања са радњом преузимања „%s“: %s\n" | ||
2647 | |||
2648 | #: src/fs/fs_directory.c:208 | ||
2649 | msgid "MAGIC mismatch. This is not a GNUnet directory.\n" | ||
2650 | msgstr "МАГИЈА не одговара. Ово није директоријум ГНУнет-а.\n" | ||
2651 | |||
2652 | #: src/fs/fs_download.c:322 | ||
2653 | msgid "Recursive downloads of directories larger than 4 GB are not supported on 32-bit systems\n" | ||
2654 | msgstr "Дубинска преузимања директоријума већих од 4 GB нису подржана на 32-битним системима\n" | ||
2655 | |||
2656 | #: src/fs/fs_download.c:342 | ||
2657 | msgid "Directory too large for system address space\n" | ||
2658 | msgstr "Директоријум је превелик за простор адресу система\n" | ||
2659 | |||
2660 | #: src/fs/fs_download.c:523 src/fs/fs_download.c:535 | ||
2661 | #, c-format | ||
2662 | msgid "Failed to open file `%s' for writing" | ||
2663 | msgstr "Нисам успео да отворим датотеку „%s“ за писање" | ||
2664 | |||
2665 | #: src/fs/fs_download.c:905 | ||
2666 | #, c-format | ||
2667 | msgid "Failed to create directory for recursive download of `%s'\n" | ||
2668 | msgstr "Нисам успео да направим директоријум за дубинско преузимање „%s“\n" | ||
2669 | |||
2670 | #: src/fs/fs_download.c:987 | ||
2671 | #, c-format | ||
2672 | msgid "Internal error or bogus download URI (expected %u bytes at depth %u and offset %llu/%llu, got %u bytes)" | ||
2673 | msgstr "Унутрашња грешка или лажна путања преузимања (очекивах %u бајта на дубини %u и померају %llu/%llu, добих %u бајта)" | ||
2674 | |||
2675 | #: src/fs/fs_download.c:1013 | ||
2676 | msgid "internal error decrypting content" | ||
2677 | msgstr "унутрашња грешка дешифровања садржаја" | ||
2678 | |||
2679 | #: src/fs/fs_download.c:1036 | ||
2680 | #, c-format | ||
2681 | msgid "Download failed: could not open file `%s': %s" | ||
2682 | msgstr "Преузимање није успело: не могу да отворим датотеку „%s“: %s" | ||
2683 | |||
2684 | #: src/fs/fs_download.c:1046 | ||
2685 | #, c-format | ||
2686 | msgid "Failed to seek to offset %llu in file `%s': %s" | ||
2687 | msgstr "Нисам успео да пређем на померај %llu у датотеци „%s“: %s" | ||
2688 | |||
2689 | #: src/fs/fs_download.c:1055 | ||
2690 | #, c-format | ||
2691 | msgid "Failed to write block of %u bytes at offset %llu in file `%s': %s" | ||
2692 | msgstr "Нисам успео да запишем блок од %u бајта на померају %llu у датотеци „%s“: %s" | ||
2693 | |||
2694 | #: src/fs/fs_download.c:1153 | ||
2695 | msgid "internal error decoding tree" | ||
2696 | msgstr "унутрашња грешка декодирања стабла" | ||
2697 | |||
2698 | #: src/fs/fs_download.c:1944 | ||
2699 | msgid "Invalid URI" | ||
2700 | msgstr "Неисправан УРИ" | ||
2701 | |||
2702 | #: src/fs/fs_getopt.c:192 | ||
2703 | #, c-format | ||
2704 | msgid "Unknown metadata type in metadata option `%s'. Using metadata type `unknown' instead.\n" | ||
2705 | msgstr "Непозната врста метаподатака у опцији метаподатака „%s“. Користим уместо тога користим врсту метаподатака `unknown'.\n" | ||
2706 | |||
2707 | #: src/fs/fs_list_indexed.c:90 | ||
2708 | #, c-format | ||
2709 | msgid "Failed to receive response for `%s' request from `%s' service.\n" | ||
2710 | msgstr "Нисам успео да примим одговор за „%s“ захтев од „%s“ услуге.\n" | ||
2711 | |||
2712 | #: src/fs/fs_list_indexed.c:113 | ||
2713 | #, c-format | ||
2714 | msgid "Failed to receive valid response for `%s' request from `%s' service.\n" | ||
2715 | msgstr "Нисам успео да примим исправан одговор за „%s“ захтев од „%s“ услуге.\n" | ||
2716 | |||
2717 | #: src/fs/fs_list_indexed.c:151 | ||
2718 | #, c-format | ||
2719 | msgid "Failed to not connect to `%s' service.\n" | ||
2720 | msgstr "Нисам успео да се не повежем са „%s“ услугом.\n" | ||
2721 | |||
2722 | #: src/fs/fs_misc.c:126 | ||
2723 | #, c-format | ||
2724 | msgid "Did not find mime type `%s' in extension list.\n" | ||
2725 | msgstr "Нисам успео да нађем миме врсту „%s“ на списку проширења.\n" | ||
2726 | |||
2727 | #: src/fs/fs_namespace.c:207 | ||
2728 | #, c-format | ||
2729 | msgid "Failed to open `%s' for writing: %s\n" | ||
2730 | msgstr "Нисам успео да отворим „%s“ ради уписа: %s\n" | ||
2731 | |||
2732 | #: src/fs/fs_namespace.c:229 | ||
2733 | #, c-format | ||
2734 | msgid "Failed to write `%s': %s\n" | ||
2735 | msgstr "Нисам успео да пишем „%s“: %s\n" | ||
2736 | |||
2737 | #: src/fs/fs_namespace.c:320 | ||
2738 | #, c-format | ||
2739 | msgid "Failed to read `%s': %s\n" | ||
2740 | msgstr "Нисам успео да прочитам „%s“: %s\n" | ||
2741 | |||
2742 | #: src/fs/fs_namespace.c:466 | ||
2743 | msgid "Failed to connect to datastore." | ||
2744 | msgstr "Нисам успео да се повежем са смештајем података." | ||
2745 | |||
2746 | #: src/fs/fs_publish.c:125 src/fs/fs_publish.c:415 | ||
2747 | #, c-format | ||
2748 | msgid "Publishing failed: %s" | ||
2749 | msgstr "Објављивање није успело: %s" | ||
2750 | |||
2751 | #: src/fs/fs_publish.c:667 src/fs/fs_publish.c:684 src/fs/fs_publish.c:723 | ||
2752 | #: src/fs/fs_publish.c:744 src/fs/fs_publish.c:768 src/fs/fs_publish.c:914 | ||
2753 | #, c-format | ||
2754 | msgid "Can not index file `%s': %s. Will try to insert instead.\n" | ||
2755 | msgstr "Не могу да индексирам датотеку „%s“: %s. Покушаћу да је уметнем.\n" | ||
2756 | |||
2757 | #: src/fs/fs_publish.c:669 | ||
2758 | msgid "timeout on index-start request to `fs' service" | ||
2759 | msgstr "истекло је време на захтев почетка индекса за „fs“ услугу" | ||
2760 | |||
2761 | #: src/fs/fs_publish.c:681 | ||
2762 | msgid "unknown error" | ||
2763 | msgstr "непозната грешка" | ||
2764 | |||
2765 | #: src/fs/fs_publish.c:725 | ||
2766 | msgid "failed to compute hash" | ||
2767 | msgstr "нисам успео да прорачунам хеш" | ||
2768 | |||
2769 | #: src/fs/fs_publish.c:745 | ||
2770 | msgid "filename too long" | ||
2771 | msgstr "назив датотеке је предуг" | ||
2772 | |||
2773 | #: src/fs/fs_publish.c:770 | ||
2774 | msgid "could not connect to `fs' service" | ||
2775 | msgstr "не могу да се повежем са „fs“ услугом" | ||
2776 | |||
2777 | #: src/fs/fs_publish.c:793 | ||
2778 | #, c-format | ||
2779 | msgid "Failed to get file identifiers for `%s'\n" | ||
2780 | msgstr "Нисам успео да добавим одреднике датотеке за „%s“\n" | ||
2781 | |||
2782 | #: src/fs/fs_publish.c:862 | ||
2783 | #, c-format | ||
2784 | msgid "Recursive upload failed at `%s': %s" | ||
2785 | msgstr "Дубински утовар није успео на „%s“: %s" | ||
2786 | |||
2787 | #: src/fs/fs_publish.c:868 | ||
2788 | #, c-format | ||
2789 | msgid "Recursive upload failed: %s" | ||
2790 | msgstr "Дубински утовар није успео: %s" | ||
2791 | |||
2792 | #: src/fs/fs_publish.c:915 | ||
2793 | msgid "needs to be an actual file" | ||
2794 | msgstr "треба да буде актуелна датотека" | ||
2795 | |||
2796 | #: src/fs/fs_publish.c:1151 | ||
2797 | #, c-format | ||
2798 | msgid "Insufficient space for publishing: %s" | ||
2799 | msgstr "Недовољно простора за објављивање: %s" | ||
2800 | |||
2801 | #: src/fs/fs_publish.c:1243 | ||
2802 | #, c-format | ||
2803 | msgid "Reserving space for %u entries and %llu bytes for publication\n" | ||
2804 | msgstr "Резервишем простор за %u уноса и %llu бајта за објављивање\n" | ||
2805 | |||
2806 | #: src/fs/fs_publish_ksk.c:219 | ||
2807 | msgid "Could not connect to datastore." | ||
2808 | msgstr "Не могу да се повежем са смештајем података." | ||
2809 | |||
2810 | #: src/fs/fs_publish_ublock.c:219 | ||
2811 | msgid "Internal error." | ||
2812 | msgstr "Унутрашња грешка." | ||
2813 | |||
2814 | #: src/fs/fs_search.c:813 | ||
2815 | #, c-format | ||
2816 | msgid "Failed to parse URI `%s': %s\n" | ||
2817 | msgstr "Нисам успео да обрадим УРИ „%s“: %s\n" | ||
2818 | |||
2819 | #: src/fs/fs_search.c:872 | ||
2820 | #, c-format | ||
2821 | msgid "Got result with unknown block type `%d', ignoring" | ||
2822 | msgstr "Добих резултат са непознатом врстом блока „%d“, занемарујем" | ||
2823 | |||
2824 | #: src/fs/fs_unindex.c:59 | ||
2825 | msgid "Failed to find given position in file" | ||
2826 | msgstr "Нисам успео да нађем дати положај у датотеци" | ||
2827 | |||
2828 | #: src/fs/fs_unindex.c:64 | ||
2829 | msgid "Failed to read file" | ||
2830 | msgstr "Нисам успео да прочитам датотеку" | ||
2831 | |||
2832 | #: src/fs/fs_unindex.c:234 | ||
2833 | msgid "Unexpected time for a response from `fs' service." | ||
2834 | msgstr "Неочекивано време за одговор са „fs“ услуге." | ||
2835 | |||
2836 | #: src/fs/fs_unindex.c:242 | ||
2837 | msgid "Timeout waiting for `fs' service." | ||
2838 | msgstr "Истекло је време чекања на „fs“ услугу." | ||
2839 | |||
2840 | #: src/fs/fs_unindex.c:250 | ||
2841 | msgid "Invalid response from `fs' service." | ||
2842 | msgstr "Неисправан одговор са „fs“ услуге." | ||
2843 | |||
2844 | #: src/fs/fs_unindex.c:291 | ||
2845 | msgid "Failed to connect to FS service for unindexing." | ||
2846 | msgstr "Нисам успео да се повежем на ФС услугу зарад поништавања индексирања." | ||
2847 | |||
2848 | #: src/fs/fs_unindex.c:347 src/fs/fs_unindex.c:359 | ||
2849 | msgid "Failed to get KSKs from directory scan." | ||
2850 | msgstr "Нисам успео да добавим KSKs из скенирања директоријума." | ||
2851 | |||
2852 | #: src/fs/fs_unindex.c:355 | ||
2853 | #, c-format | ||
2854 | msgid "Internal error scanning `%s'.\n" | ||
2855 | msgstr "Унутрашња грешка скенирања „%s“.\n" | ||
2856 | |||
2857 | #: src/fs/fs_unindex.c:414 | ||
2858 | #, c-format | ||
2859 | msgid "Failed to remove UBlock: %s\n" | ||
2860 | msgstr "Нисам успео да уклоним „UBlock“: %s\n" | ||
2861 | |||
2862 | #: src/fs/fs_unindex.c:562 src/fs/fs_unindex.c:626 | ||
2863 | msgid "Failed to connect to `datastore' service." | ||
2864 | msgstr "Нисам успео да се повежем са „datastore“ услугом." | ||
2865 | |||
2866 | #: src/fs/fs_unindex.c:639 | ||
2867 | msgid "Failed to open file for unindexing." | ||
2868 | msgstr "Нисам успео да отворим датотеку за поништавање индексирања." | ||
2869 | |||
2870 | #: src/fs/fs_unindex.c:673 | ||
2871 | msgid "Failed to compute hash of file." | ||
2872 | msgstr "Нисам успео да израчунам хеш датотеке." | ||
2873 | |||
2874 | #: src/fs/fs_uri.c:222 | ||
2875 | #, no-c-format | ||
2876 | msgid "`%' must be followed by HEX number" | ||
2877 | msgstr "„%“ мора бити праћено HEX бројем" | ||
2878 | |||
2879 | #: src/fs/fs_uri.c:281 | ||
2880 | msgid "Malformed KSK URI (must not begin or end with `+')" | ||
2881 | msgstr "Лоша KSK УРИ (не сме почињати или завршавати се са знаком +)" | ||
2882 | |||
2883 | #: src/fs/fs_uri.c:299 | ||
2884 | msgid "`++' not allowed in KSK URI" | ||
2885 | msgstr "++ није дозвољено у KSK УРИ-ју" | ||
2886 | |||
2887 | #: src/fs/fs_uri.c:306 | ||
2888 | msgid "Quotes not balanced in KSK URI" | ||
2889 | msgstr "Квоте нису уравнотежене у КСК путањи" | ||
2890 | |||
2891 | #: src/fs/fs_uri.c:376 | ||
2892 | msgid "Malformed SKS URI" | ||
2893 | msgstr "Лоша SKS УРИ" | ||
2894 | |||
2895 | #: src/fs/fs_uri.c:419 src/fs/fs_uri.c:434 | ||
2896 | msgid "Malformed CHK URI" | ||
2897 | msgstr "Лоша CHK УРИ" | ||
2898 | |||
2899 | #: src/fs/fs_uri.c:512 src/fs/fs_uri.c:580 | ||
2900 | msgid "SKS URI malformed" | ||
2901 | msgstr "SKS УРИ је лоше" | ||
2902 | |||
2903 | #: src/fs/fs_uri.c:527 src/fs/fs_uri.c:537 | ||
2904 | msgid "LOC URI malformed" | ||
2905 | msgstr "LOC УРИ је лоше" | ||
2906 | |||
2907 | #: src/fs/fs_uri.c:545 src/fs/fs_uri.c:553 | ||
2908 | msgid "LOC URI malformed (could not decode public key)" | ||
2909 | msgstr "LOC УРИ је лоше (не могу да декодирам јавни кључ)" | ||
2910 | |||
2911 | #: src/fs/fs_uri.c:559 | ||
2912 | msgid "SKS URI malformed (could not find signature)" | ||
2913 | msgstr "SKS УРИ је лоше (не могу да нашем потпис)" | ||
2914 | |||
2915 | #: src/fs/fs_uri.c:565 src/fs/fs_uri.c:574 | ||
2916 | msgid "SKS URI malformed (could not decode signature)" | ||
2917 | msgstr "SKS УРИ је лоше (не могу да декодирам потпис)" | ||
2918 | |||
2919 | #: src/fs/fs_uri.c:586 | ||
2920 | msgid "SKS URI malformed (could not parse expiration time)" | ||
2921 | msgstr "SKS УРИ је лоше (не могу да обрадим време истека)" | ||
2922 | |||
2923 | #: src/fs/fs_uri.c:598 | ||
2924 | msgid "SKS URI malformed (signature failed validation)" | ||
2925 | msgstr "SKS УРИ је лоше (потврђивање потписа није успело)" | ||
2926 | |||
2927 | #: src/fs/fs_uri.c:636 | ||
2928 | msgid "Unrecognized URI type" | ||
2929 | msgstr "Непозната УРИ врста" | ||
2930 | |||
2931 | #: src/fs/fs_uri.c:860 | ||
2932 | msgid "Lacking key configuration settings.\n" | ||
2933 | msgstr "Недостају поставке подешавања кључа.\n" | ||
2934 | |||
2935 | #: src/fs/fs_uri.c:866 | ||
2936 | #, c-format | ||
2937 | msgid "Could not access hostkey file `%s'.\n" | ||
2938 | msgstr "Не могу да приступим датотеци кључа домаћина „%s“.\n" | ||
2939 | |||
2940 | #: src/fs/fs_uri.c:1050 src/fs/fs_uri.c:1077 | ||
2941 | msgid "No keywords specified!\n" | ||
2942 | msgstr "Нису наведене речи кључа!\n" | ||
2943 | |||
2944 | #: src/fs/fs_uri.c:1083 | ||
2945 | msgid "Number of double-quotes not balanced!\n" | ||
2946 | msgstr "Број двоструких квота које нису уравнотежене!\n" | ||
2947 | |||
2948 | #: src/fs/gnunet-auto-share.c:236 | ||
2949 | #, c-format | ||
2950 | msgid "Failed to load state: %s\n" | ||
2951 | msgstr "Нисам успео да учитам стање: %s\n" | ||
2952 | |||
2953 | #: src/fs/gnunet-auto-share.c:289 src/fs/gnunet-auto-share.c:299 | ||
2954 | #: src/fs/gnunet-auto-share.c:309 | ||
2955 | #, c-format | ||
2956 | msgid "Failed to save state to file %s\n" | ||
2957 | msgstr "Нисам успео да сачувам стање у датотеку „%s“\n" | ||
2958 | |||
2959 | #: src/fs/gnunet-auto-share.c:401 | ||
2960 | #, c-format | ||
2961 | msgid "Publication of `%s' done\n" | ||
2962 | msgstr "Објављивање „%s“ је готово\n" | ||
2963 | |||
2964 | #: src/fs/gnunet-auto-share.c:488 | ||
2965 | #, c-format | ||
2966 | msgid "Publishing `%s'\n" | ||
2967 | msgstr "Објављујем „%s“\n" | ||
2968 | |||
2969 | #: src/fs/gnunet-auto-share.c:497 | ||
2970 | #, c-format | ||
2971 | msgid "Failed to run `%s'\n" | ||
2972 | msgstr "Нисам успео да покренем „%s“\n" | ||
2973 | |||
2974 | #: src/fs/gnunet-auto-share.c:686 | ||
2975 | #, c-format | ||
2976 | msgid "You must specify one and only one directory name for automatic publication.\n" | ||
2977 | msgstr "Морате навести један и само један назив директоријума за самостално објављивање.\n" | ||
2978 | |||
2979 | #: src/fs/gnunet-auto-share.c:737 src/fs/gnunet-publish.c:824 | ||
2980 | msgid "set the desired LEVEL of sender-anonymity" | ||
2981 | msgstr "поставља жељени НИВО анонимности пошиљаоца" | ||
2982 | |||
2983 | #: src/fs/gnunet-auto-share.c:741 src/fs/gnunet-publish.c:828 | ||
2984 | msgid "disable adding the creation time to the metadata of the uploaded file" | ||
2985 | msgstr "искључује додавање времена стварања метаподацима утоварене датотеке" | ||
2986 | |||
2987 | #: src/fs/gnunet-auto-share.c:744 src/fs/gnunet-publish.c:831 | ||
2988 | msgid "do not use libextractor to add keywords or metadata" | ||
2989 | msgstr "не користи „libextractor“ за додавање кључних речи или метаподатака" | ||
2990 | |||
2991 | #: src/fs/gnunet-auto-share.c:747 src/fs/gnunet-publish.c:855 | ||
2992 | msgid "specify the priority of the content" | ||
2993 | msgstr "наводи приоритет садржаја" | ||
2994 | |||
2995 | #: src/fs/gnunet-auto-share.c:750 src/fs/gnunet-publish.c:862 | ||
2996 | msgid "set the desired replication LEVEL" | ||
2997 | msgstr "поставља жељени НИВО одоговарања" | ||
2998 | |||
2999 | #: src/fs/gnunet-auto-share.c:770 | ||
3000 | msgid "Automatically publish files from a directory on GNUnet" | ||
3001 | msgstr "Самостално објављује датотеке из директоријума на ГНУнет-у" | ||
3002 | |||
3003 | #: src/fs/gnunet-daemon-fsprofiler.c:660 | ||
3004 | msgid "Daemon to use file-sharing to measure its performance." | ||
3005 | msgstr "Демон за коришћење дељења датотеке за мерење њене учинковитости." | ||
3006 | |||
3007 | #: src/fs/gnunet-directory.c:49 | ||
3008 | #, c-format | ||
3009 | msgid "\t<original file embedded in %u bytes of meta data>\n" | ||
3010 | msgstr "\t<изворна датотека угнеждена у %u бајта метаподатака>\n" | ||
3011 | |||
3012 | #: src/fs/gnunet-directory.c:94 | ||
3013 | #, c-format | ||
3014 | msgid "Directory `%s' meta data:\n" | ||
3015 | msgstr "Метаподаци директоријума „%s“:\n" | ||
3016 | |||
3017 | #: src/fs/gnunet-directory.c:97 | ||
3018 | #, c-format | ||
3019 | msgid "Directory `%s' contents:\n" | ||
3020 | msgstr "Садржај директоријума „%s“:\n" | ||
3021 | |||
3022 | #: src/fs/gnunet-directory.c:132 | ||
3023 | msgid "You must specify a filename to inspect.\n" | ||
3024 | msgstr "Морате навести назив датотеке за преглед.\n" | ||
3025 | |||
3026 | #: src/fs/gnunet-directory.c:145 | ||
3027 | #, c-format | ||
3028 | msgid "Failed to read directory `%s'\n" | ||
3029 | msgstr "Нисам успео да прочитам директоријум „%s“\n" | ||
3030 | |||
3031 | #: src/fs/gnunet-directory.c:154 | ||
3032 | #, c-format | ||
3033 | msgid "`%s' is not a GNUnet directory\n" | ||
3034 | msgstr "„%s“ није ГНУнет директоријум\n" | ||
3035 | |||
3036 | #: src/fs/gnunet-directory.c:183 | ||
3037 | msgid "Display contents of a GNUnet directory" | ||
3038 | msgstr "Приказује садржај ГНУнет директоријума" | ||
3039 | |||
3040 | #: src/fs/gnunet-download.c:137 | ||
3041 | #, c-format | ||
3042 | msgid "Starting download `%s'.\n" | ||
3043 | msgstr "Покрећем преузимање „%s“.\n" | ||
3044 | |||
3045 | #: src/fs/gnunet-download.c:147 | ||
3046 | msgid "<unknown time>" | ||
3047 | msgstr "<непознато време>" | ||
3048 | |||
3049 | #: src/fs/gnunet-download.c:157 | ||
3050 | #, c-format | ||
3051 | msgid "Downloading `%s' at %llu/%llu (%s remaining, %s/s). Block took %s to download\n" | ||
3052 | msgstr "Преузимам „%s“ при %llu/%llu (преостаје %s, %s/сек). Блоку је требало %s за преузимање\n" | ||
3053 | |||
3054 | #: src/fs/gnunet-download.c:179 | ||
3055 | #, c-format | ||
3056 | msgid "Error downloading: %s.\n" | ||
3057 | msgstr "Грешка преузимања: %s.\n" | ||
3058 | |||
3059 | #: src/fs/gnunet-download.c:194 | ||
3060 | #, c-format | ||
3061 | msgid "Downloading `%s' done (%s/s).\n" | ||
3062 | msgstr "Преузимање „%s“ је готово (%s/сек).\n" | ||
3063 | |||
3064 | #: src/fs/gnunet-download.c:209 src/fs/gnunet-publish.c:286 | ||
3065 | #: src/fs/gnunet-search.c:200 src/fs/gnunet-unindex.c:108 | ||
3066 | #, c-format | ||
3067 | msgid "Unexpected status: %d\n" | ||
3068 | msgstr "Неочекивано стање: %d\n" | ||
3069 | |||
3070 | #: src/fs/gnunet-download.c:234 | ||
3071 | msgid "You need to specify a URI argument.\n" | ||
3072 | msgstr "Треба да наведете УРИ аргумент.\n" | ||
3073 | |||
3074 | #: src/fs/gnunet-download.c:240 src/fs/gnunet-publish.c:665 | ||
3075 | #, c-format | ||
3076 | msgid "Failed to parse URI: %s\n" | ||
3077 | msgstr "Нисам успео да обрадим УРИ: %s\n" | ||
3078 | |||
3079 | #: src/fs/gnunet-download.c:247 | ||
3080 | msgid "Only CHK or LOC URIs supported.\n" | ||
3081 | msgstr "Подржани су само CHK или LOC УРИ.\n" | ||
3082 | |||
3083 | #: src/fs/gnunet-download.c:254 | ||
3084 | msgid "Target filename must be specified.\n" | ||
3085 | msgstr "Назив циљне датотеке мора бити наведен.\n" | ||
3086 | |||
3087 | #: src/fs/gnunet-download.c:268 src/fs/gnunet-publish.c:797 | ||
3088 | #: src/fs/gnunet-search.c:250 src/fs/gnunet-unindex.c:140 | ||
3089 | #, c-format | ||
3090 | msgid "Could not initialize `%s' subsystem.\n" | ||
3091 | msgstr "Не могу да покренем „%s“ субсистем.\n" | ||
3092 | |||
3093 | #: src/fs/gnunet-download.c:305 src/fs/gnunet-search.c:289 | ||
3094 | msgid "set the desired LEVEL of receiver-anonymity" | ||
3095 | msgstr "поставља жељени НИВО анонимности примаоца" | ||
3096 | |||
3097 | #: src/fs/gnunet-download.c:308 | ||
3098 | msgid "delete incomplete downloads (when aborted with CTRL-C)" | ||
3099 | msgstr "брише недовршена преузимања (када се прекине са КТРЛ-Ц)" | ||
3100 | |||
3101 | #: src/fs/gnunet-download.c:311 src/fs/gnunet-search.c:292 | ||
3102 | msgid "only search the local peer (no P2P network search)" | ||
3103 | msgstr "тражи само локалног парњака (без претраге П2П мреже)" | ||
3104 | |||
3105 | #: src/fs/gnunet-download.c:314 | ||
3106 | msgid "write the file to FILENAME" | ||
3107 | msgstr "уписује датотеку у НАЗИВ_ДАТОТЕКЕ" | ||
3108 | |||
3109 | #: src/fs/gnunet-download.c:318 | ||
3110 | msgid "set the maximum number of parallel downloads that is allowed" | ||
3111 | msgstr "поставља највећи број паралелних преузимања који је дозвољен" | ||
3112 | |||
3113 | #: src/fs/gnunet-download.c:322 | ||
3114 | msgid "set the maximum number of parallel requests for blocks that is allowed" | ||
3115 | msgstr "поставља највећи број паралелних захтева за блокове који је дозвољен" | ||
3116 | |||
3117 | #: src/fs/gnunet-download.c:325 | ||
3118 | msgid "download a GNUnet directory recursively" | ||
3119 | msgstr "преузима ГНУнет директоријум дубински" | ||
3120 | |||
3121 | #: src/fs/gnunet-download.c:339 | ||
3122 | msgid "Download files from GNUnet using a GNUnet CHK or LOC URI (gnunet://fs/chk/...)" | ||
3123 | msgstr "Преузима датотеке са ГНУнет-а користећи ГНУнет CHK или LOC УРИ (gnunet://fs/chk/...)" | ||
3124 | |||
3125 | #: src/fs/gnunet-fs.c:117 | ||
3126 | msgid "print a list of all indexed files" | ||
3127 | msgstr "исписује списак свих индексираних датотека" | ||
3128 | |||
3129 | #: src/fs/gnunet-fs.c:127 | ||
3130 | msgid "Special file-sharing operations" | ||
3131 | msgstr "Посебне радње дељења датотека" | ||
3132 | |||
3133 | #: src/fs/gnunet-fs-profiler.c:193 | ||
3134 | msgid "run the experiment with COUNT peers" | ||
3135 | msgstr "одрађује експеримент са БРОЈ парњака" | ||
3136 | |||
3137 | #: src/fs/gnunet-fs-profiler.c:196 | ||
3138 | msgid "specifies name of a file with the HOSTS the testbed should use" | ||
3139 | msgstr "наводи назив датотеке са ДОМАЋИНИМА коју пробно место треба да користи" | ||
3140 | |||
3141 | #: src/fs/gnunet-fs-profiler.c:199 | ||
3142 | msgid "automatically terminate experiment after DELAY" | ||
3143 | msgstr "самостално окончава експеримент након ЗАСТОЈА" | ||
3144 | |||
3145 | #: src/fs/gnunet-fs-profiler.c:208 | ||
3146 | msgid "run a testbed to measure file-sharing performance" | ||
3147 | msgstr "покреће пробно место за мерење учинковитости дељења датотека" | ||
3148 | |||
3149 | #: src/fs/gnunet-publish.c:231 src/fs/gnunet-publish.c:243 | ||
3150 | #, c-format | ||
3151 | msgid "Publishing `%s' at %llu/%llu (%s remaining)\n" | ||
3152 | msgstr "Објављујем „%s“ при %llu/%llu (преостаје %s)\n" | ||
3153 | |||
3154 | #: src/fs/gnunet-publish.c:250 | ||
3155 | #, c-format | ||
3156 | msgid "Error publishing: %s.\n" | ||
3157 | msgstr "Грешка објављивања: %s.\n" | ||
3158 | |||
3159 | #: src/fs/gnunet-publish.c:260 | ||
3160 | #, c-format | ||
3161 | msgid "Publishing `%s' done.\n" | ||
3162 | msgstr "Објављивање „%s“ је готово.\n" | ||
3163 | |||
3164 | #: src/fs/gnunet-publish.c:264 | ||
3165 | #, c-format | ||
3166 | msgid "URI is `%s'.\n" | ||
3167 | msgstr "УРИ је „%s“.\n" | ||
3168 | |||
3169 | #: src/fs/gnunet-publish.c:283 | ||
3170 | msgid "Cleanup after abort complete.\n" | ||
3171 | msgstr "Чисти након обављеног прекидања.\n" | ||
3172 | |||
3173 | #: src/fs/gnunet-publish.c:401 | ||
3174 | #, c-format | ||
3175 | msgid "Meta data for file `%s' (%s)\n" | ||
3176 | msgstr "Мета подаци за датотеку „%s“ (%s)\n" | ||
3177 | |||
3178 | #: src/fs/gnunet-publish.c:403 | ||
3179 | #, c-format | ||
3180 | msgid "Keywords for file `%s' (%s)\n" | ||
3181 | msgstr "Кључне речи за датотеку „%s“ (%s)\n" | ||
3182 | |||
3183 | #: src/fs/gnunet-publish.c:542 | ||
3184 | msgid "Could not publish\n" | ||
3185 | msgstr "Не могу да објавим\n" | ||
3186 | |||
3187 | #: src/fs/gnunet-publish.c:565 | ||
3188 | msgid "Could not start publishing.\n" | ||
3189 | msgstr "Не могу да покренем објављивање.\n" | ||
3190 | |||
3191 | #: src/fs/gnunet-publish.c:598 | ||
3192 | #, c-format | ||
3193 | msgid "Scanning directory `%s'.\n" | ||
3194 | msgstr "Скенирам директоријум „%s“.\n" | ||
3195 | |||
3196 | #: src/fs/gnunet-publish.c:600 | ||
3197 | #, c-format | ||
3198 | msgid "Scanning file `%s'.\n" | ||
3199 | msgstr "Скенирам датотеку „%s“.\n" | ||
3200 | |||
3201 | #: src/fs/gnunet-publish.c:605 | ||
3202 | #, c-format | ||
3203 | msgid "There was trouble processing file `%s', skipping it.\n" | ||
3204 | msgstr "Било је проблема обраде датотеке „%s“, прескачем је.\n" | ||
3205 | |||
3206 | #: src/fs/gnunet-publish.c:610 | ||
3207 | msgid "Preprocessing complete.\n" | ||
3208 | msgstr "Предодбрада је завршена.\n" | ||
3209 | |||
3210 | #: src/fs/gnunet-publish.c:614 | ||
3211 | #, c-format | ||
3212 | msgid "Extracting meta data from file `%s' complete.\n" | ||
3213 | msgstr "Извлачење мета података из датотеке „%s“ је завршено.\n" | ||
3214 | |||
3215 | #: src/fs/gnunet-publish.c:618 | ||
3216 | msgid "Meta data extraction has finished.\n" | ||
3217 | msgstr "Извлачење мета података је завршено.\n" | ||
3218 | |||
3219 | #: src/fs/gnunet-publish.c:625 | ||
3220 | msgid "Internal error scanning directory.\n" | ||
3221 | msgstr "Унутрашња грешка скенирања директоријума.\n" | ||
3222 | |||
3223 | #: src/fs/gnunet-publish.c:656 | ||
3224 | #, c-format | ||
3225 | msgid "Selected pseudonym `%s' unknown\n" | ||
3226 | msgstr "Изабрани псеудоним „%s“ је непознат\n" | ||
3227 | |||
3228 | #: src/fs/gnunet-publish.c:682 | ||
3229 | #, c-format | ||
3230 | msgid "Failed to access `%s': %s\n" | ||
3231 | msgstr "Нисам успео да приступим „%s“: %s\n" | ||
3232 | |||
3233 | #: src/fs/gnunet-publish.c:695 | ||
3234 | msgid "Failed to start meta directory scanner. Is gnunet-helper-publish-fs installed?\n" | ||
3235 | msgstr "Нисам успео да покренем скенер мета директоријума. Да ли је инсталиран „gnunet-helper-publish-fs“?\n" | ||
3236 | |||
3237 | #: src/fs/gnunet-publish.c:747 | ||
3238 | #, c-format | ||
3239 | msgid "Cannot extract metadata from a URI!\n" | ||
3240 | msgstr "Не могу да извучем метаподатке из УРИ-ја!\n" | ||
3241 | |||
3242 | #: src/fs/gnunet-publish.c:754 | ||
3243 | #, c-format | ||
3244 | msgid "You must specify one and only one filename for insertion.\n" | ||
3245 | msgstr "Морате навести један и само један назив датотеке за уметање.\n" | ||
3246 | |||
3247 | #: src/fs/gnunet-publish.c:760 | ||
3248 | #, c-format | ||
3249 | msgid "You must NOT specify an URI and a filename.\n" | ||
3250 | msgstr "НЕ можете навести УРИ и назив датотеке.\n" | ||
3251 | |||
3252 | #: src/fs/gnunet-publish.c:768 src/vpn/gnunet-vpn.c:209 | ||
3253 | #, c-format | ||
3254 | msgid "Option `%s' is required when using option `%s'.\n" | ||
3255 | msgstr "Опција „%s“ се захтева приликом коришћења опције „%s“.\n" | ||
3256 | |||
3257 | #: src/fs/gnunet-publish.c:778 src/fs/gnunet-publish.c:785 | ||
3258 | #: src/transport/gnunet-transport.c:1284 src/transport/gnunet-transport.c:1314 | ||
3259 | #: src/transport/gnunet-transport.c:1344 | ||
3260 | #, c-format | ||
3261 | msgid "Option `%s' makes no sense without option `%s'.\n" | ||
3262 | msgstr "Опција „%s“ нема смисла без опције „%s“.\n" | ||
3263 | |||
3264 | #: src/fs/gnunet-publish.c:835 | ||
3265 | msgid "print list of extracted keywords that would be used, but do not perform upload" | ||
3266 | msgstr "исписује списак извучених кључних речи које ће се користити, али не обавља утовар" | ||
3267 | |||
3268 | #: src/fs/gnunet-publish.c:839 | ||
3269 | msgid "add an additional keyword for the top-level file or directory (this option can be specified multiple times)" | ||
3270 | msgstr "додаје додатну кључну реч за датотеку највишег нивоа или директоријум (ова опција се може навести више пута)" | ||
3271 | |||
3272 | #: src/fs/gnunet-publish.c:843 | ||
3273 | msgid "set the meta-data for the given TYPE to the given VALUE" | ||
3274 | msgstr "поставља мета-податке за дату ВРСТУ за дату ВРЕДНОСТ" | ||
3275 | |||
3276 | #: src/fs/gnunet-publish.c:846 | ||
3277 | msgid "do not index, perform full insertion (stores entire file in encrypted form in GNUnet database)" | ||
3278 | msgstr "не индексира, обавља пуно уметање (смешта читаву датотеку у шифрованом облику у ГНУнет базу података)" | ||
3279 | |||
3280 | #: src/fs/gnunet-publish.c:851 | ||
3281 | msgid "specify ID of an updated version to be published in the future (for namespace insertions only)" | ||
3282 | msgstr "наводи ИБ ажурираног издања које ће бити објављено у будућности (само за уметања називног простора)" | ||
3283 | |||
3284 | #: src/fs/gnunet-publish.c:859 | ||
3285 | msgid "publish the files under the pseudonym NAME (place file into namespace)" | ||
3286 | msgstr "објављује датотеке под псеудонимом НАЗИВ (ставља датотеку у називни простор)" | ||
3287 | |||
3288 | #: src/fs/gnunet-publish.c:865 | ||
3289 | msgid "only simulate the process but do not do any actual publishing (useful to compute URIs)" | ||
3290 | msgstr "само опонаша процес али не чини никакво актуелно објављивање (корисно за прорачун УРИ-ја)" | ||
3291 | |||
3292 | #: src/fs/gnunet-publish.c:869 | ||
3293 | msgid "set the ID of this version of the publication (for namespace insertions only)" | ||
3294 | msgstr "поставља ИБ овог издања објављивања (само за уметања називног простора)" | ||
3295 | |||
3296 | #: src/fs/gnunet-publish.c:873 | ||
3297 | msgid "URI to be published (can be used instead of passing a file to add keywords to the file with the respective URI)" | ||
3298 | msgstr "УРИ који ће бити објављен (може се користити уместо прослеђивања датотеке за додавање кључних речи датотеци са одговарајућим УРИ-јем)" | ||
3299 | |||
3300 | #: src/fs/gnunet-publish.c:889 | ||
3301 | msgid "Publish a file or directory on GNUnet" | ||
3302 | msgstr "Објављује датотеку или директоријум на ГНУнет-у" | ||
3303 | |||
3304 | #: src/fs/gnunet-search.c:114 | ||
3305 | #, c-format | ||
3306 | msgid "Failed to write directory with search results to `%s'\n" | ||
3307 | msgstr "Нисам успео да пишем директоријум са резултатима претраге за „%s“\n" | ||
3308 | |||
3309 | #: src/fs/gnunet-search.c:191 | ||
3310 | #, c-format | ||
3311 | msgid "Error searching: %s.\n" | ||
3312 | msgstr "Грешка претраге: %s.\n" | ||
3313 | |||
3314 | #: src/fs/gnunet-search.c:240 | ||
3315 | msgid "Could not create keyword URI from arguments.\n" | ||
3316 | msgstr "Не могу да створим УРИ кључне речи из аргумената.\n" | ||
3317 | |||
3318 | #: src/fs/gnunet-search.c:264 | ||
3319 | msgid "Could not start searching.\n" | ||
3320 | msgstr "Не могу да покренем претрагу.\n" | ||
3321 | |||
3322 | #: src/fs/gnunet-search.c:295 | ||
3323 | msgid "write search results to file starting with PREFIX" | ||
3324 | msgstr "пише резултате претраге у датотеку која почиње са ПРЕФИКСОМ" | ||
3325 | |||
3326 | #: src/fs/gnunet-search.c:298 | ||
3327 | msgid "automatically terminate search after DELAY" | ||
3328 | msgstr "самостално окончава претрагу након ЗАСТОЈА" | ||
3329 | |||
3330 | #: src/fs/gnunet-search.c:305 | ||
3331 | msgid "automatically terminate search after VALUE results are found" | ||
3332 | msgstr "самостално окончава претрагу након што су пронађени резултати ВРЕДНОСТ" | ||
3333 | |||
3334 | #: src/fs/gnunet-search.c:316 | ||
3335 | msgid "Search GNUnet for files that were published on GNUnet" | ||
3336 | msgstr "Претражује ГНУнет за датотекама које су објављене на ГНУнет-у" | ||
3337 | |||
3338 | #: src/fs/gnunet-service-fs.c:271 | ||
3339 | msgid "# running average P2P latency (ms)" | ||
3340 | msgstr "# радно просечно П2П кашњење (ms)" | ||
3341 | |||
3342 | #: src/fs/gnunet-service-fs.c:326 src/fs/gnunet-service-fs.c:539 | ||
3343 | msgid "# Loopback routes suppressed" | ||
3344 | msgstr "# Руте петље су потиснуте" | ||
3345 | |||
3346 | #: src/fs/gnunet-service-fs.c:639 src/hostlist/gnunet-daemon-hostlist.c:288 | ||
3347 | #: src/topology/gnunet-daemon-topology.c:1254 | ||
3348 | #: src/topology/gnunet-daemon-topology.c:1261 | ||
3349 | #, c-format | ||
3350 | msgid "Failed to connect to `%s' service.\n" | ||
3351 | msgstr "Нисам успео да се повежем са „%s“ услугом.\n" | ||
3352 | |||
3353 | #: src/fs/gnunet-service-fs_cp.c:682 | ||
3354 | msgid "# migration stop messages received" | ||
3355 | msgstr "# поруке заустављања миграције су примљене" | ||
3356 | |||
3357 | #: src/fs/gnunet-service-fs_cp.c:686 | ||
3358 | #, c-format | ||
3359 | msgid "Migration of content to peer `%s' blocked for %s\n" | ||
3360 | msgstr "Премештање садржаја за парњака „%s“ је блокирано за %s\n" | ||
3361 | |||
3362 | #: src/fs/gnunet-service-fs_cp.c:721 | ||
3363 | msgid "# replies transmitted to other peers" | ||
3364 | msgstr "# одговори су пренесени другим парњацима" | ||
3365 | |||
3366 | #: src/fs/gnunet-service-fs_cp.c:727 | ||
3367 | msgid "# replies dropped" | ||
3368 | msgstr "# одговори су одбачени" | ||
3369 | |||
3370 | #: src/fs/gnunet-service-fs_cp.c:752 src/fs/gnunet-service-fs_cp.c:1301 | ||
3371 | msgid "# P2P searches active" | ||
3372 | msgstr "# П2П претраге су активне" | ||
3373 | |||
3374 | #: src/fs/gnunet-service-fs_cp.c:845 | ||
3375 | msgid "# artificial delays introduced (ms)" | ||
3376 | msgstr "# вештачка кашњења су уведена (ms)" | ||
3377 | |||
3378 | #: src/fs/gnunet-service-fs_cp.c:898 | ||
3379 | msgid "# replies dropped due to type mismatch" | ||
3380 | msgstr "# одговори су одбачени услед непоклапања врсте" | ||
3381 | |||
3382 | #: src/fs/gnunet-service-fs_cp.c:906 | ||
3383 | msgid "# replies received for other peers" | ||
3384 | msgstr "# одговори су примљени за друге парњаке" | ||
3385 | |||
3386 | #: src/fs/gnunet-service-fs_cp.c:920 | ||
3387 | msgid "# replies dropped due to insufficient cover traffic" | ||
3388 | msgstr "# одговори су одбачени услед недовољног покривног саобраћаја" | ||
3389 | |||
3390 | #: src/fs/gnunet-service-fs_cp.c:958 | ||
3391 | msgid "# P2P searches destroyed due to ultimate reply" | ||
3392 | msgstr "# П2П претраге су уништене због крајњег одговора" | ||
3393 | |||
3394 | #: src/fs/gnunet-service-fs_cp.c:1026 | ||
3395 | msgid "# requests done for free (low load)" | ||
3396 | msgstr "# захтева је готово за џабе (слабо учитавање)" | ||
3397 | |||
3398 | #: src/fs/gnunet-service-fs_cp.c:1051 | ||
3399 | msgid "# request dropped, priority insufficient" | ||
3400 | msgstr "# захтева је одбачено, недовољно хитности" | ||
3401 | |||
3402 | #: src/fs/gnunet-service-fs_cp.c:1061 | ||
3403 | msgid "# requests done for a price (normal load)" | ||
3404 | msgstr "# захтева је готово за цену (нормално учитавање)" | ||
3405 | |||
3406 | #: src/fs/gnunet-service-fs_cp.c:1139 | ||
3407 | msgid "# GET requests received (from other peers)" | ||
3408 | msgstr "# „GET“ захтеви су примљени (од других парњака)" | ||
3409 | |||
3410 | #: src/fs/gnunet-service-fs_cp.c:1173 | ||
3411 | msgid "# requests dropped due to initiator not being connected" | ||
3412 | msgstr "# захтеви су одбачени јер покретач није повезан" | ||
3413 | |||
3414 | #: src/fs/gnunet-service-fs_cp.c:1195 | ||
3415 | msgid "# requests dropped due to missing reverse route" | ||
3416 | msgstr "# захтеви су одбачени јер недостаје повратна рута" | ||
3417 | |||
3418 | #: src/fs/gnunet-service-fs_cp.c:1246 | ||
3419 | msgid "# requests dropped due TTL underflow" | ||
3420 | msgstr "# захтеви су одбачени услед ниског ТТЛ тока" | ||
3421 | |||
3422 | #: src/fs/gnunet-service-fs_cp.c:1270 | ||
3423 | msgid "# requests dropped due to higher-TTL request" | ||
3424 | msgstr "# захтеви су одбачени услед вишег-ТТЛ захтева" | ||
3425 | |||
3426 | #: src/fs/gnunet-service-fs_cp.c:1299 | ||
3427 | msgid "# P2P query messages received and processed" | ||
3428 | msgstr "# поруке П2П упита су примљене и обрађене" | ||
3429 | |||
3430 | #: src/fs/gnunet-service-fs_cp.c:1670 | ||
3431 | msgid "# migration stop messages sent" | ||
3432 | msgstr "# поруке зауставља миграције су послате" | ||
3433 | |||
3434 | #: src/fs/gnunet-service-fs_indexing.c:130 | ||
3435 | #: src/fs/gnunet-service-fs_indexing.c:181 | ||
3436 | #, c-format | ||
3437 | msgid "Could not open `%s'.\n" | ||
3438 | msgstr "Не могу да отворим „%s“.\n" | ||
3439 | |||
3440 | #: src/fs/gnunet-service-fs_indexing.c:142 | ||
3441 | #, c-format | ||
3442 | msgid "Error writing `%s'.\n" | ||
3443 | msgstr "Грешка писања „%s“.\n" | ||
3444 | |||
3445 | #: src/fs/gnunet-service-fs_indexing.c:237 | ||
3446 | #, c-format | ||
3447 | msgid "Index request received for file `%s' is already indexed as `%s'. Permitting anyway.\n" | ||
3448 | msgstr "Примљени захтев индексирања за датотеку „%s“ је већ индексиран „%s“. Ипак одобравам.\n" | ||
3449 | |||
3450 | #: src/fs/gnunet-service-fs_indexing.c:275 | ||
3451 | #, c-format | ||
3452 | msgid "Hash mismatch trying to index file `%s' which has hash `%s'\n" | ||
3453 | msgstr "Неодговарајући хеш приликом покушаја индексирања датотеке „%s“ која има хеш „%s“\n" | ||
3454 | |||
3455 | #: src/fs/gnunet-service-fs_indexing.c:477 | ||
3456 | #, c-format | ||
3457 | msgid "Failed to delete bogus block: %s\n" | ||
3458 | msgstr "Нисам успео да обришем лажни блок: %s\n" | ||
3459 | |||
3460 | #: src/fs/gnunet-service-fs_indexing.c:542 | ||
3461 | msgid "# index blocks removed: original file inaccessible" | ||
3462 | msgstr "# блокови индекси су уклоњени: изворна датотека је неприступачна" | ||
3463 | |||
3464 | #: src/fs/gnunet-service-fs_indexing.c:557 | ||
3465 | #, c-format | ||
3466 | msgid "Could not access indexed file `%s' (%s) at offset %llu: %s\n" | ||
3467 | msgstr "Не могу да приступим индексираној датотеци „%s“ (%s) на померају %llu: %s\n" | ||
3468 | |||
3469 | #: src/fs/gnunet-service-fs_indexing.c:559 | ||
3470 | msgid "not indexed" | ||
3471 | msgstr "није индексирано" | ||
3472 | |||
3473 | #: src/fs/gnunet-service-fs_indexing.c:574 | ||
3474 | #, c-format | ||
3475 | msgid "Indexed file `%s' changed at offset %llu\n" | ||
3476 | msgstr "Индексирана датотека „%s“ је измењена на померају %llu\n" | ||
3477 | |||
3478 | #: src/fs/gnunet-service-fs_lc.c:202 src/fs/gnunet-service-fs_lc.c:368 | ||
3479 | msgid "# client searches active" | ||
3480 | msgstr "# претраге клијента су активне" | ||
3481 | |||
3482 | #: src/fs/gnunet-service-fs_lc.c:256 | ||
3483 | msgid "# replies received for local clients" | ||
3484 | msgstr "# одговори су примљени за локалне клијенте" | ||
3485 | |||
3486 | #: src/fs/gnunet-service-fs_lc.c:327 | ||
3487 | msgid "# client searches received" | ||
3488 | msgstr "# претраге клијента су примљене" | ||
3489 | |||
3490 | #: src/fs/gnunet-service-fs_lc.c:362 | ||
3491 | msgid "# client searches updated (merged content seen list)" | ||
3492 | msgstr "# претраге клијента су освежене (стопљени садржај виђеног списка)" | ||
3493 | |||
3494 | #: src/fs/gnunet-service-fs_mesh_client.c:484 | ||
3495 | msgid "# replies received via mesh" | ||
3496 | msgstr "# одговори су примљени путем меша" | ||
3497 | |||
3498 | #: src/fs/gnunet-service-fs_mesh_client.c:498 | ||
3499 | msgid "# replies received via mesh dropped" | ||
3500 | msgstr "# одговори су примљени путем одбаченог меша" | ||
3501 | |||
3502 | #: src/fs/gnunet-service-fs_mesh_server.c:260 | ||
3503 | msgid "# Blocks transferred via mesh" | ||
3504 | msgstr "# Блокови су пренесени путем меша" | ||
3505 | |||
3506 | #: src/fs/gnunet-service-fs_mesh_server.c:352 | ||
3507 | msgid "# queries received via mesh not answered" | ||
3508 | msgstr "# упити су примљени путем неодговореног меша" | ||
3509 | |||
3510 | #: src/fs/gnunet-service-fs_mesh_server.c:432 | ||
3511 | msgid "# queries received via mesh" | ||
3512 | msgstr "# упути су примљени путем меша" | ||
3513 | |||
3514 | #: src/fs/gnunet-service-fs_mesh_server.c:476 | ||
3515 | msgid "# mesh client connections rejected" | ||
3516 | msgstr "# везе меш клијента су одбијене" | ||
3517 | |||
3518 | #: src/fs/gnunet-service-fs_mesh_server.c:482 | ||
3519 | #: src/fs/gnunet-service-fs_mesh_server.c:522 | ||
3520 | msgid "# mesh connections active" | ||
3521 | msgstr "# меш везе су радне" | ||
3522 | |||
3523 | #: src/fs/gnunet-service-fs_pe.c:269 | ||
3524 | msgid "# average retransmission delay (ms)" | ||
3525 | msgstr "# просечан застој поновног преноса (ms)" | ||
3526 | |||
3527 | #: src/fs/gnunet-service-fs_pe.c:400 | ||
3528 | msgid "# transmission failed (core has no bandwidth)" | ||
3529 | msgstr "# пренос није успео (језгро нема пропусни опсег)" | ||
3530 | |||
3531 | #: src/fs/gnunet-service-fs_pe.c:433 | ||
3532 | msgid "# query messages sent to other peers" | ||
3533 | msgstr "# поруке упита су послате другим парњацима" | ||
3534 | |||
3535 | #: src/fs/gnunet-service-fs_pe.c:484 | ||
3536 | msgid "# delay heap timeout (ms)" | ||
3537 | msgstr "# истекло је време застоја скупине (ms)" | ||
3538 | |||
3539 | #: src/fs/gnunet-service-fs_pe.c:492 | ||
3540 | msgid "# query plans executed" | ||
3541 | msgstr "# план упита је извршен" | ||
3542 | |||
3543 | #: src/fs/gnunet-service-fs_pe.c:552 | ||
3544 | msgid "# requests merged" | ||
3545 | msgstr "# захтеви су стопљени" | ||
3546 | |||
3547 | #: src/fs/gnunet-service-fs_pe.c:560 | ||
3548 | msgid "# requests refreshed" | ||
3549 | msgstr "# захтеви су освежени" | ||
3550 | |||
3551 | #: src/fs/gnunet-service-fs_pe.c:616 src/fs/gnunet-service-fs_pe.c:700 | ||
3552 | #: src/fs/gnunet-service-fs_pe.c:771 | ||
3553 | msgid "# query plan entries" | ||
3554 | msgstr "# пропитује обичне уносе" | ||
3555 | |||
3556 | #: src/fs/gnunet-service-fs_pr.c:311 | ||
3557 | msgid "# Pending requests created" | ||
3558 | msgstr "# Захтеви на чекању су створени" | ||
3559 | |||
3560 | #: src/fs/gnunet-service-fs_pr.c:394 src/fs/gnunet-service-fs_pr.c:645 | ||
3561 | msgid "# Pending requests active" | ||
3562 | msgstr "# Захтеви на чекању су активни" | ||
3563 | |||
3564 | #: src/fs/gnunet-service-fs_pr.c:814 | ||
3565 | msgid "# replies received and matched" | ||
3566 | msgstr "# одговори су примљени и подударени" | ||
3567 | |||
3568 | #: src/fs/gnunet-service-fs_pr.c:844 | ||
3569 | msgid "# duplicate replies discarded (bloomfilter)" | ||
3570 | msgstr "# двоструки одговори су одбачени (bloomfilter)" | ||
3571 | |||
3572 | #: src/fs/gnunet-service-fs_pr.c:853 | ||
3573 | msgid "# irrelevant replies discarded" | ||
3574 | msgstr "# небитни одговори су одбачени" | ||
3575 | |||
3576 | #: src/fs/gnunet-service-fs_pr.c:867 | ||
3577 | #, c-format | ||
3578 | msgid "Unsupported block type %u\n" | ||
3579 | msgstr "Неподржана врста блока %u\n" | ||
3580 | |||
3581 | #: src/fs/gnunet-service-fs_pr.c:880 | ||
3582 | msgid "# results found locally" | ||
3583 | msgstr "# резултати су пронађени локално" | ||
3584 | |||
3585 | #: src/fs/gnunet-service-fs_pr.c:1001 | ||
3586 | msgid "# Datastore `PUT' failures" | ||
3587 | msgstr "# Неуспеси „СТАВИ“ смештаја података" | ||
3588 | |||
3589 | #: src/fs/gnunet-service-fs_pr.c:1029 | ||
3590 | msgid "# storage requests dropped due to high load" | ||
3591 | msgstr "# захтеви смештаја су одбачени услед високог утовара" | ||
3592 | |||
3593 | #: src/fs/gnunet-service-fs_pr.c:1064 | ||
3594 | msgid "# Replies received from DHT" | ||
3595 | msgstr "# Одговори су примљени од DHT-а" | ||
3596 | |||
3597 | #: src/fs/gnunet-service-fs_pr.c:1192 | ||
3598 | msgid "# Replies received from MESH" | ||
3599 | msgstr "# Одговори су примљени од MESH-а" | ||
3600 | |||
3601 | #: src/fs/gnunet-service-fs_pr.c:1244 | ||
3602 | #, c-format | ||
3603 | msgid "Datastore lookup already took %s!\n" | ||
3604 | msgstr "Претрага смештаја података је већ узела „%s“!\n" | ||
3605 | |||
3606 | #: src/fs/gnunet-service-fs_pr.c:1264 | ||
3607 | #, c-format | ||
3608 | msgid "On-demand lookup already took %s!\n" | ||
3609 | msgstr "Претрага на-захтев је већ узела „%s“!\n" | ||
3610 | |||
3611 | #: src/fs/gnunet-service-fs_pr.c:1311 | ||
3612 | msgid "# Datastore lookups concluded (no results)" | ||
3613 | msgstr "# Претраге смештаја података су закључене (нема резултата)" | ||
3614 | |||
3615 | #: src/fs/gnunet-service-fs_pr.c:1326 | ||
3616 | msgid "# Datastore lookups concluded (seen all)" | ||
3617 | msgstr "# Претраге смештаја података су закључене (видех све)" | ||
3618 | |||
3619 | #: src/fs/gnunet-service-fs_pr.c:1335 | ||
3620 | msgid "# Datastore lookups aborted (more than MAX_RESULTS)" | ||
3621 | msgstr "# Претраге смештаја података су прекинуте (више од „MAX_RESULTS“)" | ||
3622 | |||
3623 | #: src/fs/gnunet-service-fs_pr.c:1350 | ||
3624 | msgid "# requested DBLOCK or IBLOCK not found" | ||
3625 | msgstr "# захтевани DBLOCK или IBLOCK нису нађени" | ||
3626 | |||
3627 | #: src/fs/gnunet-service-fs_pr.c:1364 | ||
3628 | msgid "# on-demand blocks matched requests" | ||
3629 | msgstr "# блокови на-захтев одговарају захтевима" | ||
3630 | |||
3631 | #: src/fs/gnunet-service-fs_pr.c:1377 | ||
3632 | msgid "# on-demand lookups performed successfully" | ||
3633 | msgstr "# претраге на-захтев су обављене успешно" | ||
3634 | |||
3635 | #: src/fs/gnunet-service-fs_pr.c:1382 | ||
3636 | msgid "# on-demand lookups failed" | ||
3637 | msgstr "# претраге на-захтев нису успеле" | ||
3638 | |||
3639 | #: src/fs/gnunet-service-fs_pr.c:1409 src/fs/gnunet-service-fs_pr.c:1449 | ||
3640 | #: src/fs/gnunet-service-fs_pr.c:1590 | ||
3641 | msgid "# Datastore lookups concluded (error queueing)" | ||
3642 | msgstr "# Претраге смештаја података су закључене (грешка стављања у ред)" | ||
3643 | |||
3644 | #: src/fs/gnunet-service-fs_pr.c:1467 | ||
3645 | msgid "# Datastore lookups concluded (found last result)" | ||
3646 | msgstr "# Претраге смештаја података су закључене (нађох последњи резултат)" | ||
3647 | |||
3648 | #: src/fs/gnunet-service-fs_pr.c:1478 | ||
3649 | msgid "# Datastore lookups concluded (load too high)" | ||
3650 | msgstr "# Претраге смештаја података су закључене (утовар је превелик)" | ||
3651 | |||
3652 | #: src/fs/gnunet-service-fs_pr.c:1566 | ||
3653 | msgid "# Datastore lookups initiated" | ||
3654 | msgstr "# Претраге смештаја података су покренуте" | ||
3655 | |||
3656 | #: src/fs/gnunet-service-fs_pr.c:1651 | ||
3657 | msgid "# GAP PUT messages received" | ||
3658 | msgstr "# поруке ЈАЗ СТАВИ су примљене" | ||
3659 | |||
3660 | #: src/fs/gnunet-service-fs_push.c:631 | ||
3661 | msgid "time required, content pushing disabled" | ||
3662 | msgstr "време је затражено, гурање садржаја је искључено" | ||
3663 | |||
3664 | #: src/fs/gnunet-unindex.c:89 | ||
3665 | #, c-format | ||
3666 | msgid "Unindexing at %llu/%llu (%s remaining)\n" | ||
3667 | msgstr "Поништавам индексирање при %llu/%llu (преостаје %s)\n" | ||
3668 | |||
3669 | #: src/fs/gnunet-unindex.c:95 | ||
3670 | #, c-format | ||
3671 | msgid "Error unindexing: %s.\n" | ||
3672 | msgstr "Грешка поништавања индексирања: %s.\n" | ||
3673 | |||
3674 | #: src/fs/gnunet-unindex.c:100 | ||
3675 | msgid "Unindexing done.\n" | ||
3676 | msgstr "Поништавање индексирања је готово.\n" | ||
3677 | |||
3678 | #: src/fs/gnunet-unindex.c:130 | ||
3679 | #, c-format | ||
3680 | msgid "You must specify one and only one filename for unindexing.\n" | ||
3681 | msgstr "Морате навести један и само један назив датотеке за поништавање индексирања.\n" | ||
3682 | |||
3683 | #: src/fs/gnunet-unindex.c:147 | ||
3684 | msgid "Could not start unindex operation.\n" | ||
3685 | msgstr "Не могу да започнем радњу поништавања индексирања.\n" | ||
3686 | |||
3687 | #: src/fs/gnunet-unindex.c:179 | ||
3688 | msgid "Unindex a file that was previously indexed with gnunet-publish." | ||
3689 | msgstr "Поништава индексирање датотеке која је претходно била индексирана са „gnunet-publish“." | ||
3690 | |||
3691 | #: src/gns/gns_api.c:393 | ||
3692 | msgid "Failed to deserialize lookup reply from GNS service!\n" | ||
3693 | msgstr "Нисам успео да десеријализујем одговор претраге са ГНС услуге!\n" | ||
3694 | |||
3695 | #: src/gns/gnunet-bcd.c:123 | ||
3696 | #, c-format | ||
3697 | msgid "Refusing `%s' request to HTTP server\n" | ||
3698 | msgstr "Одбијам „%s“ захтев за ХТТП сервер\n" | ||
3699 | |||
3700 | #: src/gns/gnunet-bcd.c:355 src/hostlist/hostlist-server.c:567 | ||
3701 | #, c-format | ||
3702 | msgid "Invalid port number %llu. Exiting.\n" | ||
3703 | msgstr "Неисправан број прикључника %llu. Излазим.\n" | ||
3704 | |||
3705 | #: src/gns/gnunet-bcd.c:360 | ||
3706 | #, c-format | ||
3707 | msgid "Businesscard HTTP server starts on %llu\n" | ||
3708 | msgstr "ХТТП сервер пословне картице почиње на %llu\n" | ||
3709 | |||
3710 | #: src/gns/gnunet-bcd.c:374 | ||
3711 | #, c-format | ||
3712 | msgid "Could not start businesscard HTTP server on port %u\n" | ||
3713 | msgstr "Не могу да покренем ХТТП сервер пословне картице на прикључнику %u\n" | ||
3714 | |||
3715 | #: src/gns/gnunet-bcd.c:519 | ||
3716 | msgid "Run HTTP serve on port PORT (default is 8888)" | ||
3717 | msgstr "Покрећем ХТТП сервер на прикључнику ПРИКЉУЧНИК (основно је 8888)" | ||
3718 | |||
3719 | #: src/gns/gnunet-bcd.c:531 | ||
3720 | msgid "GNUnet HTTP server to create business cards" | ||
3721 | msgstr "ГНУнет ХТТП сервер за стварање бизнис картица" | ||
3722 | |||
3723 | #: src/gns/gnunet-dns2gns.c:228 | ||
3724 | msgid "Failed to pack DNS response into UDP packet!\n" | ||
3725 | msgstr "Нисам успео да упакујем ДНС одговор у УДП пакет!\n" | ||
3726 | |||
3727 | #: src/gns/gnunet-dns2gns.c:400 | ||
3728 | #, c-format | ||
3729 | msgid "Cannot parse DNS request from %s\n" | ||
3730 | msgstr "Не могу да обрадим ДНС захтев од „%s“\n" | ||
3731 | |||
3732 | #: src/gns/gnunet-dns2gns.c:416 | ||
3733 | #, c-format | ||
3734 | msgid "Received malformed DNS request from %s\n" | ||
3735 | msgstr "Примих лош ДНС захтев од „%s“\n" | ||
3736 | |||
3737 | #: src/gns/gnunet-dns2gns.c:424 | ||
3738 | #, c-format | ||
3739 | msgid "Received unsupported DNS request from %s\n" | ||
3740 | msgstr "Примих неподржан ДНС захтев од „%s“\n" | ||
3741 | |||
3742 | #: src/gns/gnunet-dns2gns.c:701 | ||
3743 | msgid "No ego configured for `dns2gns` subsystem\n" | ||
3744 | msgstr "Није подешен его за „dns2gns“ подсистем\n" | ||
3745 | |||
3746 | #: src/gns/gnunet-dns2gns.c:727 | ||
3747 | msgid "No DNS server specified!\n" | ||
3748 | msgstr "Није наведен ДНС сервер!\n" | ||
3749 | |||
3750 | #: src/gns/gnunet-dns2gns.c:749 | ||
3751 | msgid "No valid GNS zone specified!\n" | ||
3752 | msgstr "Није наведена исправна ГНС зона!\n" | ||
3753 | |||
3754 | #: src/gns/gnunet-dns2gns.c:770 | ||
3755 | msgid "IP of recursive DNS resolver to use (required)" | ||
3756 | msgstr "ИП дубинског ДНС решавача за коришћење (потребно)" | ||
3757 | |||
3758 | #: src/gns/gnunet-dns2gns.c:773 | ||
3759 | msgid "Authoritative FCFS suffix to use (optional); default: fcfs.zkey.eu" | ||
3760 | msgstr "Ауторитативни ФЦФС суфикс за коришћење (изборно); основно: fcfs.zkey.eu" | ||
3761 | |||
3762 | #: src/gns/gnunet-dns2gns.c:776 | ||
3763 | msgid "Authoritative DNS suffix to use (optional); default: zkey.eu" | ||
3764 | msgstr "Ауторитативни ДНС суфикс за коришћење (изборно); основно: zkey.eu" | ||
3765 | |||
3766 | #: src/gns/gnunet-dns2gns.c:779 | ||
3767 | msgid "UDP port to listen on for inbound DNS requests; default: 53" | ||
3768 | msgstr "УДП прикључник на коме ће ослушкивати за долазним ДНС захтевима; основно: 53" | ||
3769 | |||
3770 | #: src/gns/gnunet-dns2gns.c:782 | ||
3771 | msgid "Public key of the GNS zone to use (overrides default)" | ||
3772 | msgstr "Јавни кључ ГНС зоне за коришћење (преписује основно)" | ||
3773 | |||
3774 | #: src/gns/gnunet-dns2gns.c:795 | ||
3775 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" | ||
3776 | msgstr "Посредник ДНС-до-ГНС ГНУнет-а (ДНС сервер)" | ||
3777 | |||
3778 | #: src/gns/gnunet-gns.c:227 | ||
3779 | #, c-format | ||
3780 | msgid "Please specify name to lookup!\n" | ||
3781 | msgstr "Наведите назив за тражење!\n" | ||
3782 | |||
3783 | #: src/gns/gnunet-gns.c:308 | ||
3784 | #, c-format | ||
3785 | msgid "Ego for `%s' not found, cannot perform lookup.\n" | ||
3786 | msgstr "Нисам нашао его за „%s“, не могу да обавим претрагу.\n" | ||
3787 | |||
3788 | #: src/gns/gnunet-gns.c:347 src/gns/gnunet-gns-helper-service-w32.c:798 | ||
3789 | #, c-format | ||
3790 | msgid "Ego for `gns-master' not found, cannot perform lookup. Did you run gnunet-gns-import.sh?\n" | ||
3791 | msgstr "Нисам нашао его за „gns-master“, не могу да обавим претрагу. Да ли сте покренули „gnunet-gns-import.sh“?\n" | ||
3792 | |||
3793 | #: src/gns/gnunet-gns.c:386 src/gns/gnunet-gns-helper-service-w32.c:828 | ||
3794 | #, c-format | ||
3795 | msgid "Failed to connect to GNS\n" | ||
3796 | msgstr "Нисам успео да се повежем са ГНС-ом\n" | ||
3797 | |||
3798 | #: src/gns/gnunet-gns.c:399 | ||
3799 | #, c-format | ||
3800 | msgid "Public key `%s' is not well-formed\n" | ||
3801 | msgstr "Јавни кључ „%s“ није добро оформљен\n" | ||
3802 | |||
3803 | #: src/gns/gnunet-gns.c:449 | ||
3804 | msgid "Lookup a record for the given name" | ||
3805 | msgstr "Претражује запис за датим називом" | ||
3806 | |||
3807 | #: src/gns/gnunet-gns.c:452 | ||
3808 | msgid "Specify the type of the record to lookup" | ||
3809 | msgstr "Наводи врсту записа за претраживање" | ||
3810 | |||
3811 | #: src/gns/gnunet-gns.c:455 | ||
3812 | msgid "Specify timeout for the lookup" | ||
3813 | msgstr "Наводи време истека за претраживање" | ||
3814 | |||
3815 | #: src/gns/gnunet-gns.c:458 | ||
3816 | msgid "No unneeded output" | ||
3817 | msgstr "Нема непотребног излаза" | ||
3818 | |||
3819 | #: src/gns/gnunet-gns.c:461 | ||
3820 | msgid "Specify the public key of the zone to lookup the record in" | ||
3821 | msgstr "Наводи јавни кључ зоне у којој ће се тражити запис" | ||
3822 | |||
3823 | #: src/gns/gnunet-gns.c:464 | ||
3824 | msgid "Specify the name of the ego of the zone to lookup the record in" | ||
3825 | msgstr "Наводи назив егоа зоне у којој ће се тражити запис" | ||
3826 | |||
3827 | #: src/gns/gnunet-gns.c:478 | ||
3828 | msgid "GNUnet GNS resolver tool" | ||
3829 | msgstr "Алат ГНУнет ГНС решавача" | ||
3830 | |||
3831 | #: src/gns/gnunet-gns-helper-service-w32.c:768 | ||
3832 | #, c-format | ||
3833 | msgid "Ego for `gns-short' not found. This is not really fatal, but i'll pretend that it is and refuse to perform a lookup. Did you run gnunet-gns-import.sh?\n" | ||
3834 | msgstr "Нисам нашао „gns-short“. То и није баш кобно, али ћу се ја претварати да јесте и одбићу да обавим претраживање. Да ли сте покренули „gnunet-gns-import.sh“?\n" | ||
3835 | |||
3836 | #: src/gns/gnunet-gns-helper-service-w32.c:838 | ||
3837 | #, c-format | ||
3838 | msgid "Failed to connect to identity service\n" | ||
3839 | msgstr "Нисам успео да се повежем са услугом идентитета\n" | ||
3840 | |||
3841 | #: src/gns/gnunet-gns-import.c:479 | ||
3842 | msgid "This program will import some GNS authorities into your GNS namestore." | ||
3843 | msgstr "Овај програм ће увести неке ГНС ауторитете у ваш ГНС смештај назива." | ||
3844 | |||
3845 | #: src/gns/gnunet-gns-proxy.c:105 src/hostlist/hostlist-client.c:469 | ||
3846 | #: src/hostlist/hostlist-client.c:683 src/hostlist/hostlist-client.c:689 | ||
3847 | #: src/hostlist/hostlist-client.c:741 src/hostlist/hostlist-client.c:750 | ||
3848 | #: src/hostlist/hostlist-client.c:871 src/hostlist/hostlist-client.c:963 | ||
3849 | #: src/hostlist/hostlist-client.c:968 | ||
3850 | #: src/transport/plugin_transport_http_client.c:1062 | ||
3851 | #: src/transport/plugin_transport_http_client.c:1077 | ||
3852 | #, c-format | ||
3853 | msgid "%s failed at %s:%d: `%s'\n" | ||
3854 | msgstr "„%s“ није успело на %s:%d: „%s“\n" | ||
3855 | |||
3856 | #: src/gns/gnunet-gns-proxy.c:833 | ||
3857 | #, c-format | ||
3858 | msgid "Unsupported CURL SSL backend %d\n" | ||
3859 | msgstr "Неподржан CURL SSL позадинац %d\n" | ||
3860 | |||
3861 | #: src/gns/gnunet-gns-proxy.c:856 | ||
3862 | #, c-format | ||
3863 | msgid "Failed to fetch CN from cert: %s\n" | ||
3864 | msgstr "Нисам успео да довучем ЦН из уверења: %s\n" | ||
3865 | |||
3866 | #: src/gns/gnunet-gns-proxy.c:879 | ||
3867 | #, c-format | ||
3868 | msgid "Failed to initialize DANE: %s\n" | ||
3869 | msgstr "Нисам успео да покренем ДАНЕ: %s\n" | ||
3870 | |||
3871 | #: src/gns/gnunet-gns-proxy.c:892 | ||
3872 | #, c-format | ||
3873 | msgid "Failed to parse DANE record: %s\n" | ||
3874 | msgstr "Нисам успео да обрадим ДАНЕ запис: %s\n" | ||
3875 | |||
3876 | #: src/gns/gnunet-gns-proxy.c:907 | ||
3877 | #, c-format | ||
3878 | msgid "Failed to verify TLS connection using DANE: %s\n" | ||
3879 | msgstr "Нисам успео да потврдим ТЛС везу користећи ДАНЕ: %s\n" | ||
3880 | |||
3881 | #: src/gns/gnunet-gns-proxy.c:917 | ||
3882 | #, c-format | ||
3883 | msgid "Failed DANE verification failed with GnuTLS verify status code: %u\n" | ||
3884 | msgstr "Неуспела ДАНЕ провера није успела са кодом стања ГнуТЛС провере: %u\n" | ||
3885 | |||
3886 | #: src/gns/gnunet-gns-proxy.c:941 | ||
3887 | #, c-format | ||
3888 | msgid "SSL certificate subject name (%s) does not match `%s'\n" | ||
3889 | msgstr "Назив субјекта ССЛ уверења (%s) не одговара „%s“\n" | ||
3890 | |||
3891 | #: src/gns/gnunet-gns-proxy.c:1086 | ||
3892 | #, c-format | ||
3893 | msgid "Cookie domain `%s' supplied by server is invalid\n" | ||
3894 | msgstr "Домен колачића „%s“ које је доставио сервер је неисправан\n" | ||
3895 | |||
3896 | #: src/gns/gnunet-gns-proxy.c:1602 | ||
3897 | #, c-format | ||
3898 | msgid "Unsupported HTTP method `%s'\n" | ||
3899 | msgstr "Неподржан ХТТП метод „%s“\n" | ||
3900 | |||
3901 | #: src/gns/gnunet-gns-proxy.c:1973 | ||
3902 | #, c-format | ||
3903 | msgid "Unable to import private key from file `%s'\n" | ||
3904 | msgstr "Не могу да увезем приватни кључ из датотеке „%s“\n" | ||
3905 | |||
3906 | #: src/gns/gnunet-gns-proxy.c:2003 | ||
3907 | #, c-format | ||
3908 | msgid "Unable to import certificate %s\n" | ||
3909 | msgstr "Не могу да увезем уверење „%s“\n" | ||
3910 | |||
3911 | #: src/gns/gnunet-gns-proxy.c:2177 | ||
3912 | #, c-format | ||
3913 | msgid "Failed to start HTTPS server for `%s'\n" | ||
3914 | msgstr "Нисам успео да покренем ХТТПС сервер за „%s“\n" | ||
3915 | |||
3916 | #: src/gns/gnunet-gns-proxy.c:2196 | ||
3917 | msgid "Failed to pass client to MHD\n" | ||
3918 | msgstr "Нисам успео да проследим клијента МХД-у\n" | ||
3919 | |||
3920 | #: src/gns/gnunet-gns-proxy.c:2504 | ||
3921 | #, c-format | ||
3922 | msgid "Unsupported socks version %d\n" | ||
3923 | msgstr "Неподржано издање прикључнице %d\n" | ||
3924 | |||
3925 | #: src/gns/gnunet-gns-proxy.c:2533 | ||
3926 | #, c-format | ||
3927 | msgid "Unsupported socks command %d\n" | ||
3928 | msgstr "Неподржана наредба прикључнице %d\n" | ||
3929 | |||
3930 | #: src/gns/gnunet-gns-proxy.c:2551 src/gns/gnunet-gns-proxy.c:2580 | ||
3931 | msgid "SSL connection to plain IPv4 address requested\n" | ||
3932 | msgstr "ССЛ веза за обичну ИПв4 адресу је захтевана\n" | ||
3933 | |||
3934 | #: src/gns/gnunet-gns-proxy.c:2631 | ||
3935 | #, c-format | ||
3936 | msgid "Unsupported socks address type %d\n" | ||
3937 | msgstr "Неподржана врста адресе прикључнице %d\n" | ||
3938 | |||
3939 | #: src/gns/gnunet-gns-proxy.c:2970 | ||
3940 | msgid "No ego configured for `shorten-zone`\n" | ||
3941 | msgstr "Его није подешен за „shorten-zone“\n" | ||
3942 | |||
3943 | #: src/gns/gnunet-gns-proxy.c:3010 | ||
3944 | #, c-format | ||
3945 | msgid "No ego configured for `%s`\n" | ||
3946 | msgstr "Није подешен его за `%s`\n" | ||
3947 | |||
3948 | #: src/gns/gnunet-gns-proxy.c:3072 | ||
3949 | #, c-format | ||
3950 | msgid "Failed to load SSL/TLS key and certificate from `%s'\n" | ||
3951 | msgstr "Нисам успео да учитам ССЛ/ТЛС кључ и уверење из „%s“\n" | ||
3952 | |||
3953 | #: src/gns/gnunet-gns-proxy.c:3113 | ||
3954 | msgid "listen on specified port (default: 7777)" | ||
3955 | msgstr "ослушкиван на наведеном прикључнику (основно: 7777)" | ||
3956 | |||
3957 | #: src/gns/gnunet-gns-proxy.c:3116 | ||
3958 | msgid "pem file to use as CA" | ||
3959 | msgstr "пем датотека за коришћење као издавач уверења" | ||
3960 | |||
3961 | #: src/gns/gnunet-gns-proxy.c:3135 | ||
3962 | msgid "GNUnet GNS proxy" | ||
3963 | msgstr "ГНУнет ГНС посредник" | ||
3964 | |||
3965 | #: src/gns/gnunet-service-gns.c:862 | ||
3966 | msgid "Failed to connect to the namestore!\n" | ||
3967 | msgstr "Нисам успео да се повежем са смештајем назива!\n" | ||
3968 | |||
3969 | #: src/gns/gnunet-service-gns.c:870 | ||
3970 | msgid "Failed to connect to the namecache!\n" | ||
3971 | msgstr "Нисам успео да се повежем са оставом назива!\n" | ||
3972 | |||
3973 | #: src/gns/gnunet-service-gns.c:903 | ||
3974 | msgid "Could not connect to DHT!\n" | ||
3975 | msgstr "Не могу да се повежем на ДХТ!\n" | ||
3976 | |||
3977 | #: src/gns/gnunet-service-gns.c:919 | ||
3978 | msgid "valid public key required" | ||
3979 | msgstr "исправан јавни кључ се захтева" | ||
3980 | |||
3981 | #: src/gns/gnunet-service-gns_interceptor.c:263 | ||
3982 | msgid "Error converting GNS response to DNS response!\n" | ||
3983 | msgstr "Грешка претварања ГНС одговора у ДНС одговор!\n" | ||
3984 | |||
3985 | #: src/gns/gnunet-service-gns_interceptor.c:369 | ||
3986 | msgid "Failed to connect to the DNS service!\n" | ||
3987 | msgstr "Нисам успео да се повежем са ДНС услугом!\n" | ||
3988 | |||
3989 | #: src/gns/gnunet-service-gns_resolver.c:816 | ||
3990 | msgid "Failed to parse DNS response\n" | ||
3991 | msgstr "Нисам успео да обрадим ДНС одговор\n" | ||
3992 | |||
3993 | #: src/gns/gnunet-service-gns_resolver.c:958 | ||
3994 | #, c-format | ||
3995 | msgid "Skipping record of unsupported type %d\n" | ||
3996 | msgstr "Прескачем запис неподржане врсте %d\n" | ||
3997 | |||
3998 | #: src/gns/gnunet-service-gns_resolver.c:1317 | ||
3999 | #, c-format | ||
4000 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" | ||
4001 | msgstr "ГНС претраживање је резултирало ДНС називом који је предуг („%s“)\n" | ||
4002 | |||
4003 | #: src/gns/gnunet-service-gns_resolver.c:1817 | ||
4004 | msgid "GNS lookup recursion failed (no delegation record found)\n" | ||
4005 | msgstr "Дубачење ГНС претраге није успело (нисам нашао запис изасланства)\n" | ||
4006 | |||
4007 | #: src/gns/gnunet-service-gns_resolver.c:1841 | ||
4008 | #, c-format | ||
4009 | msgid "Failed to cache GNS resolution: %s\n" | ||
4010 | msgstr "Нисам успео да сместим у оставу ГНС резолуцију: %s\n" | ||
4011 | |||
4012 | #: src/gns/gnunet-service-gns_resolver.c:2123 | ||
4013 | #, c-format | ||
4014 | msgid "Zone %s was revoked, resolution fails\n" | ||
4015 | msgstr "Зона %s је опозвана, резолуција није успела\n" | ||
4016 | |||
4017 | #: src/gns/gnunet-service-gns_resolver.c:2272 | ||
4018 | #, c-format | ||
4019 | msgid "Hostname `%s' is not well-formed, resolution fails\n" | ||
4020 | msgstr "Назив домаћина „%s“ није лепо оформљен, резолуција није успела\n" | ||
4021 | |||
4022 | #: src/gns/plugin_gnsrecord_gns.c:151 | ||
4023 | #, c-format | ||
4024 | msgid "Unable to parse PKEY record `%s'\n" | ||
4025 | msgstr "Не могу да обрадим „PKEY“ запис „%s“\n" | ||
4026 | |||
4027 | #: src/gns/plugin_gnsrecord_gns.c:180 | ||
4028 | #, c-format | ||
4029 | msgid "Unable to parse GNS2DNS record `%s'\n" | ||
4030 | msgstr "Не могу да обрадим „GNS2DNS“ запис „%s“\n" | ||
4031 | |||
4032 | #: src/gns/plugin_gnsrecord_gns.c:201 | ||
4033 | #, c-format | ||
4034 | msgid "Failed to serialize GNS2DNS record with value `%s'\n" | ||
4035 | msgstr "Нисам успео да серијализујем ГНС2ДНС запис са вредношћу „%s“\n" | ||
4036 | |||
4037 | #: src/gns/plugin_gnsrecord_gns.c:217 | ||
4038 | #, c-format | ||
4039 | msgid "Unable to parse VPN record string `%s'\n" | ||
4040 | msgstr "Не могу да обрадим ниску ВПН записа „%s“\n" | ||
4041 | |||
4042 | #: src/gnsrecord/plugin_gnsrecord_dns.c:293 | ||
4043 | #, c-format | ||
4044 | msgid "Unable to parse IPv4 address `%s'\n" | ||
4045 | msgstr "Не могу да обрадим ИПв4 адресу „%s“\n" | ||
4046 | |||
4047 | #: src/gnsrecord/plugin_gnsrecord_dns.c:314 | ||
4048 | #, c-format | ||
4049 | msgid "Failed to serialize NS record with value `%s'\n" | ||
4050 | msgstr "Нисам успео да серијализујем НС запис са вредношћу „%s“\n" | ||
4051 | |||
4052 | #: src/gnsrecord/plugin_gnsrecord_dns.c:336 | ||
4053 | #, c-format | ||
4054 | msgid "Failed to serialize CNAME record with value `%s'\n" | ||
4055 | msgstr "Нисам успео да серијализујем ЦНАЗИВ запис са вредношћу „%s“\n" | ||
4056 | |||
4057 | #: src/gnsrecord/plugin_gnsrecord_dns.c:420 | ||
4058 | #, c-format | ||
4059 | msgid "Failed to serialize CERT record with %u bytes\n" | ||
4060 | msgstr "Нисам успео да серијализујем УВЕР запис са %u бајта\n" | ||
4061 | |||
4062 | #: src/gnsrecord/plugin_gnsrecord_dns.c:452 | ||
4063 | #, c-format | ||
4064 | msgid "Unable to parse SOA record `%s'\n" | ||
4065 | msgstr "Не могу да обрадим „SOA“ запис „%s“\n" | ||
4066 | |||
4067 | #: src/gnsrecord/plugin_gnsrecord_dns.c:471 | ||
4068 | #, c-format | ||
4069 | msgid "Failed to serialize SOA record with mname `%s' and rname `%s'\n" | ||
4070 | msgstr "Нисам успео да серијализујем СОА запис са називом „%s“ и р-називом „%s“\n" | ||
4071 | |||
4072 | #: src/gnsrecord/plugin_gnsrecord_dns.c:494 | ||
4073 | #, c-format | ||
4074 | msgid "Failed to serialize PTR record with value `%s'\n" | ||
4075 | msgstr "Нисам успео да серијализујем ПТР запис са вредношћу „%s“\n" | ||
4076 | |||
4077 | #: src/gnsrecord/plugin_gnsrecord_dns.c:514 | ||
4078 | #, c-format | ||
4079 | msgid "Unable to parse MX record `%s'\n" | ||
4080 | msgstr "Не могу да обрадим „MX“ запис „%s“\n" | ||
4081 | |||
4082 | #: src/gnsrecord/plugin_gnsrecord_dns.c:529 | ||
4083 | #, c-format | ||
4084 | msgid "Failed to serialize MX record with hostname `%s'\n" | ||
4085 | msgstr "Нисам успео да серијализујем МИкс запис са називом домаћина „%s“\n" | ||
4086 | |||
4087 | #: src/gnsrecord/plugin_gnsrecord_dns.c:549 | ||
4088 | #, c-format | ||
4089 | msgid "Unable to parse IPv6 address `%s'\n" | ||
4090 | msgstr "Не могу да обрадим ИПв6 адресу „%s“\n" | ||
4091 | |||
4092 | #: src/gnsrecord/plugin_gnsrecord_dns.c:567 | ||
4093 | #, c-format | ||
4094 | msgid "Unable to parse TLSA record string `%s'\n" | ||
4095 | msgstr "Не могу да обрадим ниску ТЛСА записа „%s“\n" | ||
4096 | |||
4097 | #: src/hello/gnunet-hello.c:123 | ||
4098 | msgid "Call with name of HELLO file to modify.\n" | ||
4099 | msgstr "Позив са називом датотеке „HELLO“ за мењање.\n" | ||
4100 | |||
4101 | #: src/hello/gnunet-hello.c:129 | ||
4102 | #, c-format | ||
4103 | msgid "Error accessing file `%s': %s\n" | ||
4104 | msgstr "Грешка приступа датотеци „%s“: %s\n" | ||
4105 | |||
4106 | #: src/hello/gnunet-hello.c:137 | ||
4107 | #, c-format | ||
4108 | msgid "File `%s' is too big to be a HELLO\n" | ||
4109 | msgstr "Датотека „%s“ је превелика да би била „HELLO“\n" | ||
4110 | |||
4111 | #: src/hello/gnunet-hello.c:144 | ||
4112 | #, c-format | ||
4113 | msgid "File `%s' is too small to be a HELLO\n" | ||
4114 | msgstr "Датотека „%s“ је премала да би била „HELLO“\n" | ||
4115 | |||
4116 | #: src/hello/gnunet-hello.c:154 src/hello/gnunet-hello.c:183 | ||
4117 | #, c-format | ||
4118 | msgid "Error opening file `%s': %s\n" | ||
4119 | msgstr "Грешка отварања датотеке „%s“: %s\n" | ||
4120 | |||
4121 | #: src/hello/gnunet-hello.c:170 | ||
4122 | #, c-format | ||
4123 | msgid "Did not find well-formed HELLO in file `%s'\n" | ||
4124 | msgstr "Нисам нашао лепо формирано „HELLO“ у датотеци „%s“\n" | ||
4125 | |||
4126 | #: src/hello/gnunet-hello.c:195 | ||
4127 | #, c-format | ||
4128 | msgid "Error writing HELLO to file `%s': %s\n" | ||
4129 | msgstr "Грешка писања „HELLO“-а у датотеку „%s“: %s\n" | ||
4130 | |||
4131 | #: src/hello/gnunet-hello.c:203 | ||
4132 | #, c-format | ||
4133 | msgid "Modified %u addresses \n" | ||
4134 | msgstr "Измењених адреса — %u \n" | ||
4135 | |||
4136 | #: src/hello/hello.c:944 | ||
4137 | msgid "Failed to parse HELLO message: missing expiration time\n" | ||
4138 | msgstr "Нисам успео да обрадим „HELLO“ поруку: недостаје време истека\n" | ||
4139 | |||
4140 | #: src/hello/hello.c:953 | ||
4141 | msgid "Failed to parse HELLO message: invalid expiration time\n" | ||
4142 | msgstr "Нисам успео да обрадим „HELLO“ поруку: неисправно време истека\n" | ||
4143 | |||
4144 | #: src/hello/hello.c:963 | ||
4145 | msgid "Failed to parse HELLO message: malformed\n" | ||
4146 | msgstr "Нисам успео да обрадим „HELLO“ поруку: лоша\n" | ||
4147 | |||
4148 | #: src/hello/hello.c:973 | ||
4149 | msgid "Failed to parse HELLO message: missing transport plugin\n" | ||
4150 | msgstr "Нисам успео да обрадим „HELLO“ поруку: недостаје прикључак преноса\n" | ||
4151 | |||
4152 | #: src/hello/hello.c:990 | ||
4153 | #, c-format | ||
4154 | msgid "Plugin `%s' not found\n" | ||
4155 | msgstr "Нисам нашао прикључак „%s“\n" | ||
4156 | |||
4157 | #: src/hello/hello.c:999 | ||
4158 | #, c-format | ||
4159 | msgid "Plugin `%s' does not support URIs yet\n" | ||
4160 | msgstr "Прикључак „%s“ још не подржава УРИ-је\n" | ||
4161 | |||
4162 | #: src/hello/hello.c:1018 | ||
4163 | #, c-format | ||
4164 | msgid "Failed to parse `%s' as an address for plugin `%s'\n" | ||
4165 | msgstr "Нисам успео да обрадим „%s“ као адресу за прикључак „%s“\n" | ||
4166 | |||
4167 | #: src/hostlist/gnunet-daemon-hostlist.c:259 | ||
4168 | msgid "None of the functions for the hostlist daemon were enabled. I have no reason to run!\n" | ||
4169 | msgstr "Ниједна од функција за демона списка домаћина није укључена. Немам разлога да радим било шта!\n" | ||
4170 | |||
4171 | #: src/hostlist/gnunet-daemon-hostlist.c:308 | ||
4172 | msgid "advertise our hostlist to other peers" | ||
4173 | msgstr "рекламира наш списак домаћина другим парњацима" | ||
4174 | |||
4175 | #: src/hostlist/gnunet-daemon-hostlist.c:313 | ||
4176 | msgid "bootstrap using hostlists (it is highly recommended that you always use this option)" | ||
4177 | msgstr "почетно подизање помоћу спискова домаћина (врло се препоручује да увек користите ову опцију)" | ||
4178 | |||
4179 | #: src/hostlist/gnunet-daemon-hostlist.c:316 | ||
4180 | msgid "enable learning about hostlist servers from other peers" | ||
4181 | msgstr "укључује учење о серверима списка домаћина са других парњака" | ||
4182 | |||
4183 | #: src/hostlist/gnunet-daemon-hostlist.c:320 | ||
4184 | msgid "provide a hostlist server" | ||
4185 | msgstr "обезбеђује сервер списка домаћина" | ||
4186 | |||
4187 | #: src/hostlist/gnunet-daemon-hostlist.c:335 | ||
4188 | msgid "GNUnet hostlist server and client" | ||
4189 | msgstr "Сервер и клијент списка домаћина ГНУнет-а" | ||
4190 | |||
4191 | #: src/hostlist/hostlist-client.c:288 | ||
4192 | msgid "# bytes downloaded from hostlist servers" | ||
4193 | msgstr "# бајтови су преузети са сервера списка домаћина" | ||
4194 | |||
4195 | #: src/hostlist/hostlist-client.c:309 src/hostlist/hostlist-client.c:339 | ||
4196 | msgid "# invalid HELLOs downloaded from hostlist servers" | ||
4197 | msgstr "# неисправни „HELLO“-и су преузети са сервера списка домаћина" | ||
4198 | |||
4199 | #: src/hostlist/hostlist-client.c:312 src/hostlist/hostlist-client.c:342 | ||
4200 | #, c-format | ||
4201 | msgid "Invalid `%s' message received from hostlist at `%s'\n" | ||
4202 | msgstr "Неисправна „%s“ порука је примљена са списка домаћина на „%s“\n" | ||
4203 | |||
4204 | #: src/hostlist/hostlist-client.c:330 | ||
4205 | msgid "# valid HELLOs downloaded from hostlist servers" | ||
4206 | msgstr "# исправни „HELLO“-и су преузети са сервера списка домаћина" | ||
4207 | |||
4208 | #: src/hostlist/hostlist-client.c:592 src/hostlist/hostlist-client.c:1333 | ||
4209 | msgid "# advertised hostlist URIs" | ||
4210 | msgstr "# рекламиране путање списка домаћина" | ||
4211 | |||
4212 | #: src/hostlist/hostlist-client.c:622 | ||
4213 | #, c-format | ||
4214 | msgid "# advertised URI `%s' downloaded" | ||
4215 | msgstr "# рекламирана путања „%s“ је преузета" | ||
4216 | |||
4217 | #: src/hostlist/hostlist-client.c:664 | ||
4218 | #, c-format | ||
4219 | msgid "Advertised hostlist with URI `%s' could not be downloaded. Advertised URI gets dismissed.\n" | ||
4220 | msgstr "Рекламирани списак домаћина са путањом „%s“ се не може преузети. Рекламирана путања је одбачена.\n" | ||
4221 | |||
4222 | #: src/hostlist/hostlist-client.c:802 | ||
4223 | #, c-format | ||
4224 | msgid "Timeout trying to download hostlist from `%s'\n" | ||
4225 | msgstr "Време је истекло у покушају преузимања списка домаћина са „%s“\n" | ||
4226 | |||
4227 | #: src/hostlist/hostlist-client.c:816 | ||
4228 | #, c-format | ||
4229 | msgid "Download limit of %u bytes exceeded, stopping download\n" | ||
4230 | msgstr "Ограничење преузимања од %u бајта је премашено, заустављам преузимање\n" | ||
4231 | |||
4232 | #: src/hostlist/hostlist-client.c:836 | ||
4233 | #, c-format | ||
4234 | msgid "Download of hostlist from `%s' failed: `%s'\n" | ||
4235 | msgstr "Преузимање списка доамаћина са „%s“ није успело: „%s“\n" | ||
4236 | |||
4237 | #: src/hostlist/hostlist-client.c:842 | ||
4238 | #, c-format | ||
4239 | msgid "Download of hostlist `%s' completed.\n" | ||
4240 | msgstr "Преузимање списка домаћина „%s“ је завршено.\n" | ||
4241 | |||
4242 | #: src/hostlist/hostlist-client.c:850 | ||
4243 | #, c-format | ||
4244 | msgid "Adding successfully tested hostlist `%s' datastore.\n" | ||
4245 | msgstr "Додаје успешно тестирани смештај података „%s“ списка домаћина.\n" | ||
4246 | |||
4247 | #: src/hostlist/hostlist-client.c:903 | ||
4248 | #, c-format | ||
4249 | msgid "Bootstrapping using hostlist at `%s'.\n" | ||
4250 | msgstr "Вршим почетно подизање помоћу списка домаћина на „%s“.\n" | ||
4251 | |||
4252 | #: src/hostlist/hostlist-client.c:911 | ||
4253 | msgid "# hostlist downloads initiated" | ||
4254 | msgstr "# преузимања списка домаћина су започета" | ||
4255 | |||
4256 | #: src/hostlist/hostlist-client.c:1040 src/hostlist/hostlist-client.c:1506 | ||
4257 | msgid "# milliseconds between hostlist downloads" | ||
4258 | msgstr "# милисекунди између преузимања списка домаћина" | ||
4259 | |||
4260 | #: src/hostlist/hostlist-client.c:1049 | ||
4261 | #, c-format | ||
4262 | msgid "Have %u/%u connections. Will consider downloading hostlist in %s\n" | ||
4263 | msgstr "Имам %u/%u везе. Размотрићу преузимање списка домаћина за %s\n" | ||
4264 | |||
4265 | #: src/hostlist/hostlist-client.c:1109 src/hostlist/hostlist-client.c:1125 | ||
4266 | msgid "# active connections" | ||
4267 | msgstr "# активних веза" | ||
4268 | |||
4269 | #: src/hostlist/hostlist-client.c:1280 | ||
4270 | #, c-format | ||
4271 | msgid "Loading saved hostlist entries from file `%s' \n" | ||
4272 | msgstr "Учитавам сачуване уносе списка домаћина из датотеке „%s“ \n" | ||
4273 | |||
4274 | #: src/hostlist/hostlist-client.c:1285 | ||
4275 | #, c-format | ||
4276 | msgid "Hostlist file `%s' does not exist\n" | ||
4277 | msgstr "Датотека списка домаћина „%s“ не постоји\n" | ||
4278 | |||
4279 | #: src/hostlist/hostlist-client.c:1296 | ||
4280 | #, c-format | ||
4281 | msgid "Could not open file `%s' for reading to load hostlists: %s\n" | ||
4282 | msgstr "Не могу да отворим датотеку „%s“ за читање да утоварим спискове домаћина: %s\n" | ||
4283 | |||
4284 | #: src/hostlist/hostlist-client.c:1329 | ||
4285 | #, c-format | ||
4286 | msgid "%u hostlist URIs loaded from file\n" | ||
4287 | msgstr "УРИ-и %u списка домаћина су учитани из датотеке\n" | ||
4288 | |||
4289 | #: src/hostlist/hostlist-client.c:1331 | ||
4290 | msgid "# hostlist URIs read from file" | ||
4291 | msgstr "# УРИ-и списка домаћина су учитани из датотеке" | ||
4292 | |||
4293 | #: src/hostlist/hostlist-client.c:1376 | ||
4294 | #, c-format | ||
4295 | msgid "Could not open file `%s' for writing to save hostlists: %s\n" | ||
4296 | msgstr "Не могу да отворим датотеку „%s“ за писање да сачувам спискове домаћина: %s\n" | ||
4297 | |||
4298 | #: src/hostlist/hostlist-client.c:1381 | ||
4299 | #, c-format | ||
4300 | msgid "Writing %u hostlist URIs to `%s'\n" | ||
4301 | msgstr "Уписујем УРИ-је %u списка домаћина у „%s“\n" | ||
4302 | |||
4303 | #: src/hostlist/hostlist-client.c:1405 src/hostlist/hostlist-client.c:1422 | ||
4304 | #, c-format | ||
4305 | msgid "Error writing hostlist URIs to file `%s'\n" | ||
4306 | msgstr "Грешка писања УРИ-а списка домаћина у датотеку „%s“\n" | ||
4307 | |||
4308 | #: src/hostlist/hostlist-client.c:1417 | ||
4309 | msgid "# hostlist URIs written to file" | ||
4310 | msgstr "# УРИ-и списка домаћина су записани у датотеку" | ||
4311 | |||
4312 | #: src/hostlist/hostlist-client.c:1471 | ||
4313 | msgid "Learning is enabled on this peer\n" | ||
4314 | msgstr "Учење је укључено на овом парњаку\n" | ||
4315 | |||
4316 | #: src/hostlist/hostlist-client.c:1483 | ||
4317 | msgid "Learning is not enabled on this peer\n" | ||
4318 | msgstr "Учење није укључено на овом парњаку\n" | ||
4319 | |||
4320 | #: src/hostlist/hostlist-client.c:1495 | ||
4321 | #, c-format | ||
4322 | msgid "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" | ||
4323 | msgstr "Како учење није укључено на овом парњаку, датотека списка домаћина „%s“ је уклоњена\n" | ||
4324 | |||
4325 | #: src/hostlist/hostlist-client.c:1499 | ||
4326 | #, c-format | ||
4327 | msgid "Hostlist file `%s' could not be removed\n" | ||
4328 | msgstr "Датотека списка домаћина „%s“ не може бити уклоњена\n" | ||
4329 | |||
4330 | #: src/hostlist/hostlist-server.c:137 | ||
4331 | msgid "bytes in hostlist" | ||
4332 | msgstr "бајтова у списку домаћина" | ||
4333 | |||
4334 | #: src/hostlist/hostlist-server.c:161 | ||
4335 | msgid "expired addresses encountered" | ||
4336 | msgstr "наиђох на истекле адресе" | ||
4337 | |||
4338 | #: src/hostlist/hostlist-server.c:189 src/hostlist/hostlist-server.c:425 | ||
4339 | #: src/peerinfo-tool/gnunet-peerinfo.c:350 | ||
4340 | #: src/peerinfo-tool/gnunet-peerinfo.c:419 | ||
4341 | #: src/peerinfo-tool/gnunet-peerinfo.c:490 | ||
4342 | #: src/topology/gnunet-daemon-topology.c:925 | ||
4343 | #, c-format | ||
4344 | msgid "Error in communication with PEERINFO service: %s\n" | ||
4345 | msgstr "Грешка у комуникацији са услугом ПОДАЦИ_ПАРЊАКА: %s\n" | ||
4346 | |||
4347 | #: src/hostlist/hostlist-server.c:210 | ||
4348 | msgid "HELLOs without addresses encountered (ignored)" | ||
4349 | msgstr "наиђох на „HELLO“-е без адреса (занемарено)" | ||
4350 | |||
4351 | #: src/hostlist/hostlist-server.c:224 | ||
4352 | msgid "bytes not included in hostlist (size limit)" | ||
4353 | msgstr "бајтови нису укључени на списак домаћина (ограничење величине)" | ||
4354 | |||
4355 | #: src/hostlist/hostlist-server.c:268 | ||
4356 | #, c-format | ||
4357 | msgid "Refusing `%s' request to hostlist server\n" | ||
4358 | msgstr "Одбијам „%s“ захтев за сервер списка домаћина\n" | ||
4359 | |||
4360 | #: src/hostlist/hostlist-server.c:271 | ||
4361 | msgid "hostlist requests refused (not HTTP GET)" | ||
4362 | msgstr "захтеви списка домаћина су одбијени (нису „HTTP GET“)" | ||
4363 | |||
4364 | #: src/hostlist/hostlist-server.c:284 | ||
4365 | #, c-format | ||
4366 | msgid "Refusing `%s' request with %llu bytes of upload data\n" | ||
4367 | msgstr "Одбијам „%s“ захтев са %llu бајта података утовара\n" | ||
4368 | |||
4369 | #: src/hostlist/hostlist-server.c:288 | ||
4370 | msgid "hostlist requests refused (upload data)" | ||
4371 | msgstr "захтеви списка домаћина су одбијени (подаци утовара)" | ||
4372 | |||
4373 | #: src/hostlist/hostlist-server.c:296 | ||
4374 | msgid "Could not handle hostlist request since I do not have a response yet\n" | ||
4375 | msgstr "Не могу да радим са захтевом списка домаћина јер још немам одговор\n" | ||
4376 | |||
4377 | #: src/hostlist/hostlist-server.c:299 | ||
4378 | msgid "hostlist requests refused (not ready)" | ||
4379 | msgstr "захтеви списка домаћина су одбијени (нису спремни)" | ||
4380 | |||
4381 | #: src/hostlist/hostlist-server.c:303 | ||
4382 | msgid "Received request for our hostlist\n" | ||
4383 | msgstr "Примих захтев за наш списак домаћина\n" | ||
4384 | |||
4385 | #: src/hostlist/hostlist-server.c:304 | ||
4386 | msgid "hostlist requests processed" | ||
4387 | msgstr "захтеви списка домаћина су обрађени" | ||
4388 | |||
4389 | #: src/hostlist/hostlist-server.c:346 | ||
4390 | msgid "# hostlist advertisements send" | ||
4391 | msgstr "# рекламе списка домаћина су послате" | ||
4392 | |||
4393 | #: src/hostlist/hostlist-server.c:390 | ||
4394 | msgid "Advertisement message could not be queued by core\n" | ||
4395 | msgstr "Поруку оглашавања језгро не може да стави у ред\n" | ||
4396 | |||
4397 | #: src/hostlist/hostlist-server.c:557 src/peerinfo-tool/gnunet-peerinfo.c:639 | ||
4398 | #: src/transport/gnunet-service-transport.c:1114 | ||
4399 | msgid "Could not access PEERINFO service. Exiting.\n" | ||
4400 | msgstr "Не могу да приступим услузи ИНФО_ПАРЊАКА. Излазим.\n" | ||
4401 | |||
4402 | #: src/hostlist/hostlist-server.c:576 | ||
4403 | #, c-format | ||
4404 | msgid "Hostlist service starts on %s:%llu\n" | ||
4405 | msgstr "Услуга списка домаћина почиње на %s:%llu\n" | ||
4406 | |||
4407 | #: src/hostlist/hostlist-server.c:590 | ||
4408 | #, c-format | ||
4409 | msgid "Address to obtain hostlist: `%s'\n" | ||
4410 | msgstr "Адреса за добијање списка домаћина: „%s“\n" | ||
4411 | |||
4412 | #: src/hostlist/hostlist-server.c:630 | ||
4413 | #, c-format | ||
4414 | msgid "`%s' is not a valid IP address! Ignoring BINDTOIP.\n" | ||
4415 | msgstr "„%s“ није исправна ИП адреса! Занемарујем „BINDTOIP“.\n" | ||
4416 | |||
4417 | #: src/hostlist/hostlist-server.c:673 | ||
4418 | #, c-format | ||
4419 | msgid "Could not start hostlist HTTP server on port %u\n" | ||
4420 | msgstr "Не могу да покренем ХТТП сервер списка домаћина на прикључнику %u\n" | ||
4421 | |||
4422 | #: src/identity/gnunet-identity.c:165 | ||
4423 | #, c-format | ||
4424 | msgid "Failed to create ego: %s\n" | ||
4425 | msgstr "Нисам успео да направим его: %s\n" | ||
4426 | |||
4427 | #: src/identity/gnunet-identity.c:184 | ||
4428 | #, c-format | ||
4429 | msgid "Failed to set default ego: %s\n" | ||
4430 | msgstr "Нисам успео да поставим основни его: %s\n" | ||
4431 | |||
4432 | #: src/identity/gnunet-identity.c:327 | ||
4433 | msgid "create ego NAME" | ||
4434 | msgstr "ствара НАЗИВ ега" | ||
4435 | |||
4436 | #: src/identity/gnunet-identity.c:330 | ||
4437 | msgid "delete ego NAME " | ||
4438 | msgstr "брише НАЗИВ ега " | ||
4439 | |||
4440 | # | ||
4441 | # File: util/dialtest.c++, line: 134 | ||
4442 | #: src/identity/gnunet-identity.c:333 | ||
4443 | msgid "display all egos" | ||
4444 | msgstr "приказује све егое" | ||
4445 | |||
4446 | #: src/identity/gnunet-identity.c:336 | ||
4447 | msgid "set default identity to EGO for a subsystem SUBSYSTEM (use together with -s)" | ||
4448 | msgstr "поставља основни идентитет на ЕГО за подсистем ПОДСИСТЕМ (користите заједно са -s)" | ||
4449 | |||
4450 | #: src/identity/gnunet-identity.c:339 | ||
4451 | msgid "run in monitor mode egos" | ||
4452 | msgstr "ради у режиму праћења егоа" | ||
4453 | |||
4454 | #: src/identity/gnunet-identity.c:342 | ||
4455 | msgid "set default identity to EGO for a subsystem SUBSYSTEM (use together with -e)" | ||
4456 | msgstr "поставља основни идентитет на ЕГО за подсистем ПОДСИСТЕМ (користите заједно са -e)" | ||
4457 | |||
4458 | #: src/identity/gnunet-identity.c:351 | ||
4459 | msgid "Maintain egos" | ||
4460 | msgstr "Одржава егое" | ||
4461 | |||
4462 | #: src/identity/gnunet-service-identity.c:338 | ||
4463 | msgid "no default known" | ||
4464 | msgstr "основнст није позната" | ||
4465 | |||
4466 | #: src/identity/gnunet-service-identity.c:362 | ||
4467 | msgid "default configured, but ego unknown (internal error)" | ||
4468 | msgstr "основни је подешен, али его није познат (унутрашња грешка)" | ||
4469 | |||
4470 | #: src/identity/gnunet-service-identity.c:439 | ||
4471 | #: src/identity/gnunet-service-identity.c:670 | ||
4472 | #: src/identity/gnunet-service-identity.c:778 | ||
4473 | #, c-format | ||
4474 | msgid "Failed to write subsystem default identifier map to `%s'.\n" | ||
4475 | msgstr "Нисам успео да запишем основну мапу одредника подсистема у „%s“.\n" | ||
4476 | |||
4477 | #: src/identity/gnunet-service-identity.c:446 | ||
4478 | msgid "Unknown ego specified for service (internal error)" | ||
4479 | msgstr "Непознат его је наведен за услугу (унутрашња грешка)" | ||
4480 | |||
4481 | #: src/identity/gnunet-service-identity.c:516 | ||
4482 | msgid "identifier already in use for another ego" | ||
4483 | msgstr "одредник се већ користи за други его" | ||
4484 | |||
4485 | #: src/identity/gnunet-service-identity.c:647 | ||
4486 | msgid "target name already exists" | ||
4487 | msgstr "назив мете већ постоји" | ||
4488 | |||
4489 | #: src/identity/gnunet-service-identity.c:686 | ||
4490 | #: src/identity/gnunet-service-identity.c:795 | ||
4491 | msgid "no matching ego found" | ||
4492 | msgstr "нисам нашао одговарајући его" | ||
4493 | |||
4494 | #: src/identity/gnunet-service-identity.c:829 | ||
4495 | #, c-format | ||
4496 | msgid "Failed to parse ego information in `%s'\n" | ||
4497 | msgstr "Нисам успео да обрадим податке егоа у „%s“\n" | ||
4498 | |||
4499 | #: src/identity/gnunet-service-identity.c:902 | ||
4500 | #, c-format | ||
4501 | msgid "Failed to parse subsystem identity configuration file `%s'\n" | ||
4502 | msgstr "Нисам успео да обрадим датотеку подешавања идентитета субсистема „%s“\n" | ||
4503 | |||
4504 | #: src/identity/gnunet-service-identity.c:914 | ||
4505 | #, c-format | ||
4506 | msgid "Failed to create directory `%s' for storing egos\n" | ||
4507 | msgstr "Нисам успео да направим директоријум „%s“ за смештајне егое\n" | ||
4508 | |||
4509 | #: src/mesh/gnunet-mesh.c:357 | ||
4510 | #, c-format | ||
4511 | msgid "Invalid target `%s'\n" | ||
4512 | msgstr "Неисправна мета „%s“\n" | ||
4513 | |||
4514 | #: src/mesh/gnunet-mesh.c:607 | ||
4515 | #, c-format | ||
4516 | msgid "Invalid peer ID `%s'\n" | ||
4517 | msgstr "Неисправан ИБ парњака „%s“\n" | ||
4518 | |||
4519 | #: src/mesh/gnunet-mesh.c:650 | ||
4520 | #, c-format | ||
4521 | msgid "Invalid tunnel owner `%s'\n" | ||
4522 | msgstr "Неисправан власник тунела „%s“\n" | ||
4523 | |||
4524 | #: src/mesh/gnunet-mesh.c:716 | ||
4525 | msgid "You must NOT give a TARGETwhen using 'request all' options\n" | ||
4526 | msgstr "НЕ можете дати МЕТУ када користите опције „request all“\n" | ||
4527 | |||
4528 | #: src/mesh/gnunet-mesh.c:807 | ||
4529 | msgid "provide information about a particular connection" | ||
4530 | msgstr "обезбеђује податке о нарочитој вези" | ||
4531 | |||
4532 | #: src/mesh/gnunet-mesh.c:810 | ||
4533 | msgid "activate echo mode" | ||
4534 | msgstr "покреће режим ехоа" | ||
4535 | |||
4536 | #: src/mesh/gnunet-mesh.c:816 | ||
4537 | msgid "port to listen to (default; 0)" | ||
4538 | msgstr "прикључник за ослушкивање (основно; 0)" | ||
4539 | |||
4540 | #: src/mesh/gnunet-mesh.c:819 src/mesh/gnunet-mesh.c:822 | ||
4541 | msgid "provide information about all peers" | ||
4542 | msgstr "обезбеђује податке о свим парњацима" | ||
4543 | |||
4544 | #: src/mesh/gnunet-mesh.c:825 | ||
4545 | msgid "provide information about a particular tunnel" | ||
4546 | msgstr "обезбеђује податке о нарочитом тунелу" | ||
4547 | |||
4548 | #: src/mesh/gnunet-mesh.c:828 | ||
4549 | msgid "provide information about all tunnels" | ||
4550 | msgstr "обезбеђује податке о свим тунелима" | ||
4551 | |||
4552 | #: src/mesh/gnunet-service-mesh_peer.c:390 | ||
4553 | msgid "Wrong CORE service\n" | ||
4554 | msgstr "Погрешна ЈЕЗГРЕНА услуга\n" | ||
4555 | |||
4556 | #: src/mysql/mysql.c:174 | ||
4557 | #, c-format | ||
4558 | msgid "Trying to use file `%s' for MySQL configuration.\n" | ||
4559 | msgstr "Покушавам да користим датотеку „%s“ за МајСКуЛ подешавање.\n" | ||
4560 | |||
4561 | #: src/mysql/mysql.c:181 | ||
4562 | #, c-format | ||
4563 | msgid "Could not access file `%s': %s\n" | ||
4564 | msgstr "Не могу да приступим датотеци „%s“: %s\n" | ||
4565 | |||
4566 | #: src/namecache/gnunet-namecache.c:109 | ||
4567 | #, c-format | ||
4568 | msgid "No records found for `%s'" | ||
4569 | msgstr "Нисам нашао записе за „%s“" | ||
4570 | |||
4571 | #: src/namecache/gnunet-namecache.c:124 src/namestore/gnunet-namestore.c:397 | ||
4572 | #, c-format | ||
4573 | msgid "\tCorrupt or unsupported record of type %u\n" | ||
4574 | msgstr "\tОштећен или неподржан запис врсте %u\n" | ||
4575 | |||
4576 | #: src/namecache/gnunet-namecache.c:185 | ||
4577 | #, c-format | ||
4578 | msgid "You must specify which zone should be accessed\n" | ||
4579 | msgstr "Морате навести којој зони се треба приступити\n" | ||
4580 | |||
4581 | #: src/namecache/gnunet-namecache.c:195 src/namestore/gnunet-namestore.c:695 | ||
4582 | #, c-format | ||
4583 | msgid "Invalid public key for reverse lookup `%s'\n" | ||
4584 | msgstr "Неисправан јавни кључ за обратну претрагу „%s“\n" | ||
4585 | |||
4586 | #: src/namecache/gnunet-namecache.c:203 | ||
4587 | #, c-format | ||
4588 | msgid "You must specify a name\n" | ||
4589 | msgstr "Морате навести назив\n" | ||
4590 | |||
4591 | #: src/namecache/gnunet-namecache.c:234 src/namestore/gnunet-namestore.c:931 | ||
4592 | msgid "name of the record to add/delete/display" | ||
4593 | msgstr "назив записа за додавање/брисање/приказ" | ||
4594 | |||
4595 | #: src/namecache/gnunet-namecache.c:237 | ||
4596 | msgid "spezifies the public key of the zone to look in" | ||
4597 | msgstr "наводи јавни кључ зоне за претраживање" | ||
4598 | |||
4599 | #: src/namecache/gnunet-namecache.c:248 src/namestore/gnunet-namestore.c:963 | ||
4600 | msgid "GNUnet zone manipulation tool" | ||
4601 | msgstr "Алат манипуслисања ГНУнет зоном" | ||
4602 | |||
4603 | #: src/namecache/namecache_api.c:276 | ||
4604 | msgid "Namecache failed to cache block" | ||
4605 | msgstr "Остава назива није успела да смести у оставу блок" | ||
4606 | |||
4607 | #: src/namecache/plugin_namecache_postgres.c:89 | ||
4608 | #: src/namestore/plugin_namestore_postgres.c:96 | ||
4609 | msgid "Failed to create indices\n" | ||
4610 | msgstr "Нисам успео да направим индексе\n" | ||
4611 | |||
4612 | #: src/namestore/gnunet-namestore.c:303 | ||
4613 | #, c-format | ||
4614 | msgid "Adding record failed: %s\n" | ||
4615 | msgstr "Додавање записа није успело: %s\n" | ||
4616 | |||
4617 | #: src/namestore/gnunet-namestore.c:332 | ||
4618 | #, c-format | ||
4619 | msgid "Deleting record failed, record does not exist%s%s\n" | ||
4620 | msgstr "Брисање записа није успело, запис не постоји%s%s\n" | ||
4621 | |||
4622 | #: src/namestore/gnunet-namestore.c:339 | ||
4623 | #, c-format | ||
4624 | msgid "Deleting record failed%s%s\n" | ||
4625 | msgstr "Брисање записа није успело%s%s\n" | ||
4626 | |||
4627 | #: src/namestore/gnunet-namestore.c:558 | ||
4628 | #, c-format | ||
4629 | msgid "No options given\n" | ||
4630 | msgstr "Нису дате опције\n" | ||
4631 | |||
4632 | #: src/namestore/gnunet-namestore.c:569 | ||
4633 | #: src/namestore/gnunet-namestore-fcfsd.c:970 | ||
4634 | msgid "Failed to connect to namestore\n" | ||
4635 | msgstr "Нисам успео да се повежем са смештајем назива\n" | ||
4636 | |||
4637 | #: src/namestore/gnunet-namestore.c:577 src/namestore/gnunet-namestore.c:586 | ||
4638 | #: src/namestore/gnunet-namestore.c:603 src/namestore/gnunet-namestore.c:625 | ||
4639 | #: src/namestore/gnunet-namestore.c:665 | ||
4640 | #, c-format | ||
4641 | msgid "Missing option `%s' for operation `%s'\n" | ||
4642 | msgstr "Недостаје опција „%s“ за радњу „%s“\n" | ||
4643 | |||
4644 | #: src/namestore/gnunet-namestore.c:578 src/namestore/gnunet-namestore.c:587 | ||
4645 | #: src/namestore/gnunet-namestore.c:604 src/namestore/gnunet-namestore.c:626 | ||
4646 | msgid "add" | ||
4647 | msgstr "додај" | ||
4648 | |||
4649 | #: src/namestore/gnunet-namestore.c:595 | ||
4650 | #, c-format | ||
4651 | msgid "Unsupported type `%s'\n" | ||
4652 | msgstr "Неподржана врста „%s“\n" | ||
4653 | |||
4654 | #: src/namestore/gnunet-namestore.c:615 | ||
4655 | #, c-format | ||
4656 | msgid "Value `%s' invalid for record type `%s'\n" | ||
4657 | msgstr "Вредност „%s“ је неисправна за врсту записа „%s“\n" | ||
4658 | |||
4659 | #: src/namestore/gnunet-namestore.c:651 | ||
4660 | #, c-format | ||
4661 | msgid "Invalid time format `%s'\n" | ||
4662 | msgstr "Неисправан формат времена „%s“\n" | ||
4663 | |||
4664 | #: src/namestore/gnunet-namestore.c:666 | ||
4665 | msgid "del" | ||
4666 | msgstr "обриши" | ||
4667 | |||
4668 | #: src/namestore/gnunet-namestore.c:715 | ||
4669 | #: src/peerinfo-tool/gnunet-peerinfo.c:723 | ||
4670 | #, c-format | ||
4671 | msgid "Invalid URI `%s'\n" | ||
4672 | msgstr "Неисправан УРИ „%s“\n" | ||
4673 | |||
4674 | #: src/namestore/gnunet-namestore.c:750 | ||
4675 | #, c-format | ||
4676 | msgid "Invalid nick `%s'\n" | ||
4677 | msgstr "Неисправан надимак „%s“\n" | ||
4678 | |||
4679 | #: src/namestore/gnunet-namestore.c:790 | ||
4680 | #, c-format | ||
4681 | msgid "Ego `%s' not known to identity service\n" | ||
4682 | msgstr "Его „%s“ није познат услузи идентитета\n" | ||
4683 | |||
4684 | #: src/namestore/gnunet-namestore.c:817 | ||
4685 | #, c-format | ||
4686 | msgid "No default ego configured in identity service\n" | ||
4687 | msgstr "Није подешен основни его у услузи идентитета\n" | ||
4688 | |||
4689 | #: src/namestore/gnunet-namestore.c:853 | ||
4690 | #, c-format | ||
4691 | msgid "Identity service is not running\n" | ||
4692 | msgstr "Услуга идентитета није покренута\n" | ||
4693 | |||
4694 | #: src/namestore/gnunet-namestore.c:865 | ||
4695 | #, c-format | ||
4696 | msgid "Cannot connect to identity service\n" | ||
4697 | msgstr "Не могу да се повежем са услугом идентитета\n" | ||
4698 | |||
4699 | #: src/namestore/gnunet-namestore.c:913 | ||
4700 | msgid "add record" | ||
4701 | msgstr "додаје запис" | ||
4702 | |||
4703 | #: src/namestore/gnunet-namestore.c:916 | ||
4704 | msgid "delete record" | ||
4705 | msgstr "брише запис" | ||
4706 | |||
4707 | #: src/namestore/gnunet-namestore.c:919 | ||
4708 | msgid "display records" | ||
4709 | msgstr "приказује записе" | ||
4710 | |||
4711 | #: src/namestore/gnunet-namestore.c:922 | ||
4712 | msgid "expiration time for record to use (for adding only), \"never\" is possible" | ||
4713 | msgstr "време истека записа за коришћење (само за додавање), „never“ је могуће" | ||
4714 | |||
4715 | #: src/namestore/gnunet-namestore.c:925 | ||
4716 | msgid "set the desired nick name for the zone" | ||
4717 | msgstr "поставља жељени назив надимка за зону" | ||
4718 | |||
4719 | #: src/namestore/gnunet-namestore.c:928 | ||
4720 | msgid "monitor changes in the namestore" | ||
4721 | msgstr "прати измене у смештају назива" | ||
4722 | |||
4723 | #: src/namestore/gnunet-namestore.c:934 | ||
4724 | msgid "determine our name for the given PKEY" | ||
4725 | msgstr "одређује наш назив за дати „PKEY“" | ||
4726 | |||
4727 | #: src/namestore/gnunet-namestore.c:937 | ||
4728 | msgid "type of the record to add/delete/display" | ||
4729 | msgstr "врста записа за додавање/брисање/приказ" | ||
4730 | |||
4731 | #: src/namestore/gnunet-namestore.c:940 | ||
4732 | msgid "URI to import into our zone" | ||
4733 | msgstr "УРИ за увоз у нашу зону" | ||
4734 | |||
4735 | #: src/namestore/gnunet-namestore.c:943 | ||
4736 | msgid "value of the record to add/delete" | ||
4737 | msgstr "вредност записа за додавање/брисање" | ||
4738 | |||
4739 | #: src/namestore/gnunet-namestore.c:946 | ||
4740 | msgid "create or list public record" | ||
4741 | msgstr "ствара или исписује јавни запис" | ||
4742 | |||
4743 | #: src/namestore/gnunet-namestore.c:949 | ||
4744 | msgid "create shadow record (only valid if all other records of the same type have expired" | ||
4745 | msgstr "прави сеновити запис (важи само ако су сви остали записи исте врсте истекли" | ||
4746 | |||
4747 | #: src/namestore/gnunet-namestore.c:952 | ||
4748 | msgid "name of the ego controlling the zone" | ||
4749 | msgstr "назив егоа који контролише зону" | ||
4750 | |||
4751 | #: src/namestore/gnunet-namestore-fcfsd.c:464 | ||
4752 | #, c-format | ||
4753 | msgid "Unsupported form value `%s'\n" | ||
4754 | msgstr "Неподржана вредност облика „%s“\n" | ||
4755 | |||
4756 | #: src/namestore/gnunet-namestore-fcfsd.c:491 | ||
4757 | #, c-format | ||
4758 | msgid "Failed to create record for domain `%s': %s\n" | ||
4759 | msgstr "Нисам успео да направим запис за домен „%s“: %s\n" | ||
4760 | |||
4761 | #: src/namestore/gnunet-namestore-fcfsd.c:525 | ||
4762 | #, c-format | ||
4763 | msgid "Found existing name `%s' for the given key\n" | ||
4764 | msgstr "Нађох постојећи назив „%s“ за дати кључ\n" | ||
4765 | |||
4766 | #: src/namestore/gnunet-namestore-fcfsd.c:534 | ||
4767 | msgid "Error when mapping zone to name\n" | ||
4768 | msgstr "Грешка приликом мапирања зоне у назив\n" | ||
4769 | |||
4770 | #: src/namestore/gnunet-namestore-fcfsd.c:596 | ||
4771 | #, c-format | ||
4772 | msgid "Found %u existing records for domain `%s'\n" | ||
4773 | msgstr "Нађох %u постојећа записа за домен „%s“\n" | ||
4774 | |||
4775 | #: src/namestore/gnunet-namestore-fcfsd.c:652 | ||
4776 | #, c-format | ||
4777 | msgid "Failed to create page for `%s'\n" | ||
4778 | msgstr "Нисам успео да направим страницу за „%s“\n" | ||
4779 | |||
4780 | #: src/namestore/gnunet-namestore-fcfsd.c:668 | ||
4781 | #, c-format | ||
4782 | msgid "Failed to setup post processor for `%s'\n" | ||
4783 | msgstr "Нисам успео да поставим постпроцесор за „%s“\n" | ||
4784 | |||
4785 | #: src/namestore/gnunet-namestore-fcfsd.c:704 | ||
4786 | msgid "Domain name must not contain `.'\n" | ||
4787 | msgstr "Назив домена не сме да садржи „.“\n" | ||
4788 | |||
4789 | #: src/namestore/gnunet-namestore-fcfsd.c:712 | ||
4790 | msgid "Domain name must not contain `+'\n" | ||
4791 | msgstr "Назив домена не сме да садржи „+“\n" | ||
4792 | |||
4793 | #: src/namestore/gnunet-namestore-fcfsd.c:910 | ||
4794 | msgid "No ego configured for `fcfsd` subsystem\n" | ||
4795 | msgstr "Није подешен его за „fcfsd“ подсистем\n" | ||
4796 | |||
4797 | #: src/namestore/gnunet-namestore-fcfsd.c:936 | ||
4798 | msgid "Failed to start HTTP server\n" | ||
4799 | msgstr "Нисам успео да покренем ХТТП сервер\n" | ||
4800 | |||
4801 | #: src/namestore/gnunet-namestore-fcfsd.c:978 | ||
4802 | msgid "Failed to connect to identity\n" | ||
4803 | msgstr "Нисам успео да се повежем са идентитетом\n" | ||
4804 | |||
4805 | #: src/namestore/gnunet-namestore-fcfsd.c:1011 | ||
4806 | msgid "GNU Name System First Come First Serve name registration service" | ||
4807 | msgstr "Услуга регистрације назива Први Стиже Први Служи ГНУ Система Назива" | ||
4808 | |||
4809 | #: src/namestore/gnunet-service-namestore.c:655 | ||
4810 | #, c-format | ||
4811 | msgid "Failed to replicate block in namecache: %s\n" | ||
4812 | msgstr "Нисам успео да реплицирам блок у остави назива: %s\n" | ||
4813 | |||
4814 | #: src/namestore/namestore_api.c:275 | ||
4815 | msgid "Namestore failed to store record\n" | ||
4816 | msgstr "Смештај назива није успео да смести запис\n" | ||
4817 | |||
4818 | #: src/nat/gnunet-nat-server.c:279 | ||
4819 | #, c-format | ||
4820 | msgid "Please pass valid port number as the first argument! (got `%s')\n" | ||
4821 | msgstr "Проследите исправан број прикључника као први аргумент! (добих „%s“)\n" | ||
4822 | |||
4823 | #: src/nat/gnunet-nat-server.c:321 | ||
4824 | msgid "GNUnet NAT traversal test helper daemon" | ||
4825 | msgstr "Демон помоћника теста ГНУнет НАТ попречника" | ||
4826 | |||
4827 | #: src/nat/nat_auto.c:170 | ||
4828 | msgid "NAT traversal with ICMP Server timed out.\n" | ||
4829 | msgstr "Истекло је време НАТ попречника са ИЦМП сервером.\n" | ||
4830 | |||
4831 | #: src/nat/nat_auto.c:203 | ||
4832 | msgid "NAT traversal with ICMP Server succeeded.\n" | ||
4833 | msgstr "НАТ попречник са ИЦМП сервером је успео.\n" | ||
4834 | |||
4835 | #: src/nat/nat_auto.c:204 | ||
4836 | msgid "NAT traversal with ICMP Server failed.\n" | ||
4837 | msgstr "НАТ попречник са ИЦМП сервером није успео.\n" | ||
4838 | |||
4839 | #: src/nat/nat_auto.c:225 | ||
4840 | msgid "Testing connection reversal with ICMP server.\n" | ||
4841 | msgstr "Тестира обратност везе са ИЦМП сервером.\n" | ||
4842 | |||
4843 | #: src/nat/nat_auto.c:274 | ||
4844 | #, c-format | ||
4845 | msgid "Detected external IP `%s'\n" | ||
4846 | msgstr "Откривен је спољни ИП „%s“\n" | ||
4847 | |||
4848 | #: src/nat/nat_auto.c:344 | ||
4849 | msgid "This system has a global IPv6 address, setting IPv6 to supported.\n" | ||
4850 | msgstr "Овај систем има општу ИПв6 адресу, постављам ИПв6 на подржану.\n" | ||
4851 | |||
4852 | #: src/nat/nat_auto.c:360 | ||
4853 | #, c-format | ||
4854 | msgid "Detected internal network address `%s'.\n" | ||
4855 | msgstr "Откривена је унутрашња адреса мреже „%s“.\n" | ||
4856 | |||
4857 | #: src/nat/nat_auto.c:413 | ||
4858 | msgid "upnpc found, enabling its use\n" | ||
4859 | msgstr "нађох „upnpc“, омогућујем њено коришћење\n" | ||
4860 | |||
4861 | #: src/nat/nat_auto.c:414 | ||
4862 | msgid "upnpc not found\n" | ||
4863 | msgstr "нисам нашао „upnpc“\n" | ||
4864 | |||
4865 | #: src/nat/nat_auto.c:447 | ||
4866 | msgid "gnunet-helper-nat-server found, testing it\n" | ||
4867 | msgstr "нађох „gnunet-helper-nat-server“, тестирам је\n" | ||
4868 | |||
4869 | #: src/nat/nat_auto.c:448 | ||
4870 | msgid "No working gnunet-helper-nat-server found\n" | ||
4871 | msgstr "Нисам нашао радну „gnunet-helper-nat-server“\n" | ||
4872 | |||
4873 | #: src/nat/nat_auto.c:482 | ||
4874 | msgid "gnunet-helper-nat-client found, enabling it\n" | ||
4875 | msgstr "нађох „gnunet-helper-nat-client“, омогућавам је\n" | ||
4876 | |||
4877 | #: src/nat/nat_auto.c:483 | ||
4878 | msgid "gnunet-helper-nat-client not found or behind NAT, disabling it\n" | ||
4879 | msgstr "нисам нашао „gnunet-helper-nat-client“ или иза НАТ-а, искључујем је\n" | ||
4880 | |||
4881 | #: src/nat/nat.c:867 | ||
4882 | #, c-format | ||
4883 | msgid "gnunet-helper-nat-server generated malformed address `%s'\n" | ||
4884 | msgstr "„gnunet-helper-nat-server“ је створила лошу адресу „%s“\n" | ||
4885 | |||
4886 | #: src/nat/nat.c:917 | ||
4887 | #, c-format | ||
4888 | msgid "Failed to start %s\n" | ||
4889 | msgstr "Нисам успео да покренем „%s“\n" | ||
4890 | |||
4891 | #: src/nat/nat.c:1205 | ||
4892 | msgid "malformed" | ||
4893 | msgstr "лоше" | ||
4894 | |||
4895 | #: src/nat/nat.c:1276 src/nat/nat.c:1288 | ||
4896 | #, c-format | ||
4897 | msgid "Configuration requires `%s', but binary is not installed properly (SUID bit not set). Option disabled.\n" | ||
4898 | msgstr "Подешавање захтева „%s“, али бинарно није исправно инсталирано („SUID“ бит није постављен). Опција је искључена.\n" | ||
4899 | |||
4900 | #: src/nat/nat.c:1426 | ||
4901 | msgid "Internal IP address not known, cannot use ICMP NAT traversal method\n" | ||
4902 | msgstr "Унутрашња ИП адреса није позната, не могу користити методу ИЦМП НАТ попречника\n" | ||
4903 | |||
4904 | #: src/nat/nat.c:1442 | ||
4905 | #, c-format | ||
4906 | msgid "Running gnunet-helper-nat-client %s %s %u\n" | ||
4907 | msgstr "Извршавам „gnunet-helper-nat-client“ %s %s %u\n" | ||
4908 | |||
4909 | #: src/nat/nat_mini.c:155 | ||
4910 | msgid "no valid address was returned by `external-ip'" | ||
4911 | msgstr "ниједна исправна адреса није враћена „external-ip“-ом" | ||
4912 | |||
4913 | #: src/nat/nat_mini.c:175 | ||
4914 | msgid "`external-ip' command not found" | ||
4915 | msgstr "нисам нашао наредбу „external-ip“" | ||
4916 | |||
4917 | #: src/nat/nat_mini.c:201 | ||
4918 | msgid "`external-ip' command not found\n" | ||
4919 | msgstr "нисам нашао наредбу „external-ip“\n" | ||
4920 | |||
4921 | #: src/nat/nat_mini.c:366 | ||
4922 | msgid "Failed to run `upnpc` command" | ||
4923 | msgstr "Нисам успео да покренем наредбу „upnpc“" | ||
4924 | |||
4925 | #: src/nat/nat_mini.c:512 | ||
4926 | msgid "`upnpc' command took too long, process killed" | ||
4927 | msgstr "„upnpc“ наредби треба превише времена, процес је убијен" | ||
4928 | |||
4929 | #: src/nat/nat_mini.c:540 | ||
4930 | msgid "`upnpc' command failed to establish port mapping" | ||
4931 | msgstr "„upnpc“ наредба није успела да успостави мапирање прикључника" | ||
4932 | |||
4933 | #: src/nat/nat_mini.c:604 | ||
4934 | msgid "`upnpc' command not found\n" | ||
4935 | msgstr "нисам нашао „upnpc“ наредбу\n" | ||
4936 | |||
4937 | #: src/nat/nat_mini.c:608 | ||
4938 | msgid "`upnpc` command not found" | ||
4939 | msgstr "нисам нашао „upnpc“ наредбу" | ||
4940 | |||
4941 | #: src/nat/nat_test.c:351 | ||
4942 | msgid "Failed to connect to `gnunet-nat-server'\n" | ||
4943 | msgstr "Нисам успео да се повежем на „gnunet-nat-server“\n" | ||
4944 | |||
4945 | #: src/nat/nat_test.c:423 | ||
4946 | #, c-format | ||
4947 | msgid "Failed to create listen socket bound to `%s' for NAT test: %s\n" | ||
4948 | msgstr "Нисам успео да направим свезу прикључнице ослушкивања ка „%s“ за НАТ тест: %s\n" | ||
4949 | |||
4950 | #: src/nse/gnunet-nse.c:117 | ||
4951 | msgid "NSE service is not running\n" | ||
4952 | msgstr "НСЕ услуга није покренута\n" | ||
4953 | |||
4954 | #: src/nse/gnunet-nse.c:122 | ||
4955 | msgid "Error while checking if NSE service is running or not\n" | ||
4956 | msgstr "Грешка приликом проверавања да ли НСЕ услуга ради или не\n" | ||
4957 | |||
4958 | #: src/nse/gnunet-nse.c:168 | ||
4959 | msgid "Show network size estimates from NSE service." | ||
4960 | msgstr "Показује процене величине мреже из НСЕ услуге." | ||
4961 | |||
4962 | #: src/nse/gnunet-nse-profiler.c:858 | ||
4963 | msgid "limit to the number of connections to NSE services, 0 for none" | ||
4964 | msgstr "ограничење броја веза на НСЕ услуге, 0 за ништа" | ||
4965 | |||
4966 | #: src/nse/gnunet-nse-profiler.c:861 | ||
4967 | msgid "name of the file for writing connection information and statistics" | ||
4968 | msgstr "назив датотеке за записивање података везе и статистику" | ||
4969 | |||
4970 | #: src/nse/gnunet-nse-profiler.c:864 src/testbed/gnunet-testbed-profiler.c:306 | ||
4971 | msgid "name of the file with the login information for the testbed" | ||
4972 | msgstr "назив датотеке са подацима пријављивања за пробно место" | ||
4973 | |||
4974 | #: src/nse/gnunet-nse-profiler.c:867 | ||
4975 | msgid "name of the file for writing the main results" | ||
4976 | msgstr "назив датотеке за записивање главних резултата" | ||
4977 | |||
4978 | #: src/nse/gnunet-nse-profiler.c:870 | ||
4979 | msgid "Number of peers to run in each round, separated by commas" | ||
4980 | msgstr "Број парњака за покретање у свакој рунди, раздвојени зарезима" | ||
4981 | |||
4982 | #: src/nse/gnunet-nse-profiler.c:876 | ||
4983 | msgid "delay between rounds" | ||
4984 | msgstr "застој између рунди" | ||
4985 | |||
4986 | #: src/nse/gnunet-nse-profiler.c:885 | ||
4987 | msgid "Measure quality and performance of the NSE service." | ||
4988 | msgstr "Мери квалитет и учинковитост НСЕ услуге." | ||
4989 | |||
4990 | #: src/nse/gnunet-service-nse.c:1517 | ||
4991 | #: src/revocation/gnunet-service-revocation.c:789 src/util/gnunet-scrypt.c:248 | ||
4992 | msgid "Value is too large.\n" | ||
4993 | msgstr "Вредност је превелика.\n" | ||
4994 | |||
4995 | #: src/peerinfo/gnunet-service-peerinfo.c:215 | ||
4996 | #, c-format | ||
4997 | msgid "Removing expired address of transport `%s'\n" | ||
4998 | msgstr "Уклањам истеклу адресу преноса „%s“\n" | ||
4999 | |||
5000 | #: src/peerinfo/gnunet-service-peerinfo.c:352 | ||
5001 | #, c-format | ||
5002 | msgid "Failed to parse HELLO in file `%s': %s\n" | ||
5003 | msgstr "Нисам успео да обрадим „HELLO“ у датотеци „%s“: %s\n" | ||
5004 | |||
5005 | #: src/peerinfo/gnunet-service-peerinfo.c:371 | ||
5006 | #: src/peerinfo/gnunet-service-peerinfo.c:388 | ||
5007 | #, c-format | ||
5008 | msgid "Failed to parse HELLO in file `%s'\n" | ||
5009 | msgstr "Нисам успео да обрадим „HELLO“ у датотеци „%s“\n" | ||
5010 | |||
5011 | #: src/peerinfo/gnunet-service-peerinfo.c:466 | ||
5012 | msgid "# peers known" | ||
5013 | msgstr "# парњака је познато" | ||
5014 | |||
5015 | #: src/peerinfo/gnunet-service-peerinfo.c:503 | ||
5016 | #, c-format | ||
5017 | msgid "File `%s' in directory `%s' does not match naming convention. Removed.\n" | ||
5018 | msgstr "Датотека „%s“ у директоријуму „%s“ не одговара договору именовања. Уклоњена је.\n" | ||
5019 | |||
5020 | #: src/peerinfo/gnunet-service-peerinfo.c:653 | ||
5021 | #, c-format | ||
5022 | msgid "Scanning directory `%s'\n" | ||
5023 | msgstr "Скенирам директоријум „%s“\n" | ||
5024 | |||
5025 | #: src/peerinfo/gnunet-service-peerinfo.c:658 | ||
5026 | #, c-format | ||
5027 | msgid "Still no peers found in `%s'!\n" | ||
5028 | msgstr "Још увек нисам нашао парњаке у „%s“!\n" | ||
5029 | |||
5030 | #: src/peerinfo/gnunet-service-peerinfo.c:994 | ||
5031 | #, c-format | ||
5032 | msgid "Cleaning up directory `%s'\n" | ||
5033 | msgstr "Чистим директоријум „%s“\n" | ||
5034 | |||
5035 | #: src/peerinfo/gnunet-service-peerinfo.c:1287 | ||
5036 | #, c-format | ||
5037 | msgid "Importing HELLOs from `%s'\n" | ||
5038 | msgstr "Увозим „HELLO“-е из „%s“\n" | ||
5039 | |||
5040 | #: src/peerinfo/gnunet-service-peerinfo.c:1298 | ||
5041 | msgid "Skipping import of included HELLOs\n" | ||
5042 | msgstr "Прескачем увоз укључених „HELLO“-а\n" | ||
5043 | |||
5044 | #: src/peerinfo/peerinfo_api.c:236 | ||
5045 | msgid "aborted due to explicit disconnect request" | ||
5046 | msgstr "прекинуто услед изричитог захтева прекида везе" | ||
5047 | |||
5048 | #: src/peerinfo/peerinfo_api.c:356 | ||
5049 | msgid "failed to transmit request (service down?)" | ||
5050 | msgstr "нисам успео да пренесем захтев (услуга је пала?)" | ||
5051 | |||
5052 | #: src/peerinfo/peerinfo_api.c:506 | ||
5053 | msgid "Failed to receive response from `PEERINFO' service." | ||
5054 | msgstr "Нисам успео да примим одговор са услуге „PEERINFO“." | ||
5055 | |||
5056 | #: src/peerinfo/peerinfo_api.c:547 src/peerinfo/peerinfo_api.c:566 | ||
5057 | #: src/peerinfo/peerinfo_api.c:581 src/peerinfo/peerinfo_api.c:592 | ||
5058 | #: src/peerinfo/peerinfo_api.c:603 | ||
5059 | msgid "Received invalid message from `PEERINFO' service." | ||
5060 | msgstr "Примих неисправну поруку са услуге „PEERINFO“." | ||
5061 | |||
5062 | #: src/peerinfo/peerinfo_api.c:678 | ||
5063 | msgid "Timeout transmitting iteration request to `PEERINFO' service." | ||
5064 | msgstr "Истекло је време преношења захтева понављања ка услузи „ПОДАЦИ_ПАРЊАКА“." | ||
5065 | |||
5066 | #: src/peerinfo/peerinfo_api_notify.c:268 | ||
5067 | #, c-format | ||
5068 | msgid "Could not connect to `%s' service.\n" | ||
5069 | msgstr "Не могу да се повежем са „%s“ услугом.\n" | ||
5070 | |||
5071 | #: src/peerinfo-tool/gnunet-peerinfo.c:232 | ||
5072 | #, c-format | ||
5073 | msgid "%sPeer `%s'\n" | ||
5074 | msgstr "%sПарњак „%s“\n" | ||
5075 | |||
5076 | #: src/peerinfo-tool/gnunet-peerinfo.c:239 | ||
5077 | #, c-format | ||
5078 | msgid "\tExpires: %s \t %s\n" | ||
5079 | msgstr "\tИстиче: %s \t %s\n" | ||
5080 | |||
5081 | #: src/peerinfo-tool/gnunet-peerinfo.c:428 | ||
5082 | #, c-format | ||
5083 | msgid "Failure: Did not receive %s\n" | ||
5084 | msgstr "Неуспех: Нисам примио „%s“\n" | ||
5085 | |||
5086 | #: src/peerinfo-tool/gnunet-peerinfo.c:436 | ||
5087 | #, c-format | ||
5088 | msgid "Failure: Received invalid %s\n" | ||
5089 | msgstr "Неуспех: Примих неисправно „%s“\n" | ||
5090 | |||
5091 | #: src/peerinfo-tool/gnunet-peerinfo.c:445 | ||
5092 | #, c-format | ||
5093 | msgid "Failed to write HELLO with %u bytes to file `%s'\n" | ||
5094 | msgstr "Нисам успео да упишем „HELLO“ са %u бајта у датотеку „%s“\n" | ||
5095 | |||
5096 | #: src/peerinfo-tool/gnunet-peerinfo.c:458 | ||
5097 | #, c-format | ||
5098 | msgid "Wrote %s HELLO containing %u addresses with %u bytes to file `%s'\n" | ||
5099 | msgstr "Записах „%s HELLO“ које садржи %u адресе са %u бајта у датотеку „%s“\n" | ||
5100 | |||
5101 | #: src/peerinfo-tool/gnunet-peerinfo.c:522 | ||
5102 | #, c-format | ||
5103 | msgid "Failure adding HELLO: %s\n" | ||
5104 | msgstr "Неуспех додавања „HELLO“-а: %s\n" | ||
5105 | |||
5106 | #: src/peerinfo-tool/gnunet-peerinfo.c:633 | ||
5107 | #, c-format | ||
5108 | msgid "Service `%s' is not running, please start GNUnet\n" | ||
5109 | msgstr "Услуга „%s“ није покренута, покрените ГНУнет\n" | ||
5110 | |||
5111 | #: src/peerinfo-tool/gnunet-peerinfo.c:654 src/util/gnunet-scrypt.c:224 | ||
5112 | #, c-format | ||
5113 | msgid "Loading hostkey from `%s' failed.\n" | ||
5114 | msgstr "Учитавање кључа домаћина из „%s“ није успело.\n" | ||
5115 | |||
5116 | #: src/peerinfo-tool/gnunet-peerinfo.c:745 | ||
5117 | #, c-format | ||
5118 | msgid "I am peer `%s'.\n" | ||
5119 | msgstr "Ја сам парњак „%s“.\n" | ||
5120 | |||
5121 | #: src/peerinfo-tool/gnunet-peerinfo.c:789 | ||
5122 | msgid "don't resolve host names" | ||
5123 | msgstr "не разрешава називе домаћина" | ||
5124 | |||
5125 | #: src/peerinfo-tool/gnunet-peerinfo.c:792 | ||
5126 | msgid "output only the identity strings" | ||
5127 | msgstr "исписује само ниске идентитета" | ||
5128 | |||
5129 | #: src/peerinfo-tool/gnunet-peerinfo.c:795 | ||
5130 | msgid "include friend-only information" | ||
5131 | msgstr "укључује податке само-пријатељ" | ||
5132 | |||
5133 | #: src/peerinfo-tool/gnunet-peerinfo.c:798 | ||
5134 | msgid "output our own identity only" | ||
5135 | msgstr "исписује само наш лични идентитет" | ||
5136 | |||
5137 | #: src/peerinfo-tool/gnunet-peerinfo.c:801 | ||
5138 | msgid "list all known peers" | ||
5139 | msgstr "исписује све познате парњаке" | ||
5140 | |||
5141 | #: src/peerinfo-tool/gnunet-peerinfo.c:804 | ||
5142 | msgid "dump hello to file" | ||
5143 | msgstr "шаље „hello“ у датотеку" | ||
5144 | |||
5145 | #: src/peerinfo-tool/gnunet-peerinfo.c:807 | ||
5146 | msgid "also output HELLO uri(s)" | ||
5147 | msgstr "такође исписује „HELLO“ ури-је" | ||
5148 | |||
5149 | #: src/peerinfo-tool/gnunet-peerinfo.c:810 | ||
5150 | msgid "add given HELLO uri to the database" | ||
5151 | msgstr "додаје дату „HELLO“ путању у базу података" | ||
5152 | |||
5153 | #: src/peerinfo-tool/gnunet-peerinfo.c:821 | ||
5154 | msgid "Print information about peers." | ||
5155 | msgstr "Исписује податке о парњацима." | ||
5156 | |||
5157 | #: src/peerinfo-tool/gnunet-peerinfo_plugins.c:105 | ||
5158 | #: src/transport/gnunet-service-transport_plugins.c:128 | ||
5159 | #, c-format | ||
5160 | msgid "Starting transport plugins `%s'\n" | ||
5161 | msgstr "Покрећем прикључке преноса „%s“\n" | ||
5162 | |||
5163 | #: src/peerinfo-tool/gnunet-peerinfo_plugins.c:109 | ||
5164 | #: src/transport/gnunet-service-transport_plugins.c:133 | ||
5165 | #, c-format | ||
5166 | msgid "Loading `%s' transport plugin\n" | ||
5167 | msgstr "Учитавам „%s“ прикључак преноса\n" | ||
5168 | |||
5169 | #: src/peerinfo-tool/gnunet-peerinfo_plugins.c:129 | ||
5170 | #: src/transport/gnunet-service-transport_plugins.c:165 | ||
5171 | #, c-format | ||
5172 | msgid "Failed to load transport plugin for `%s'\n" | ||
5173 | msgstr "Нисам успео да учитам прикључак преноса за „%s“\n" | ||
5174 | |||
5175 | #: src/postgres/postgres.c:59 | ||
5176 | #, c-format | ||
5177 | msgid "`%s:%s' failed at %s:%d with error: %s" | ||
5178 | msgstr "`%s:%s' није успело на %s:%d са грешком: %s" | ||
5179 | |||
5180 | #: src/postgres/postgres.c:148 | ||
5181 | #, c-format | ||
5182 | msgid "Unable to initialize Postgres: %s" | ||
5183 | msgstr "Не могу да покренем Постгрес: %s" | ||
5184 | |||
5185 | #: src/psycstore/gnunet-service-psycstore.c:200 | ||
5186 | msgid "Failed to store membership information!\n" | ||
5187 | msgstr "Нисам успео да сместим податке о чланству!\n" | ||
5188 | |||
5189 | #: src/psycstore/gnunet-service-psycstore.c:224 | ||
5190 | msgid "Failed to test membership!\n" | ||
5191 | msgstr "Нисам успео да тестирам чланство!\n" | ||
5192 | |||
5193 | #: src/psycstore/gnunet-service-psycstore.c:246 | ||
5194 | msgid "Failed to store fragment!\n" | ||
5195 | msgstr "Нисам успео да сместим делић!\n" | ||
5196 | |||
5197 | #: src/psycstore/gnunet-service-psycstore.c:272 | ||
5198 | msgid "Failed to get fragment!\n" | ||
5199 | msgstr "Нисам успео да добавим делић!\n" | ||
5200 | |||
5201 | #: src/psycstore/gnunet-service-psycstore.c:299 | ||
5202 | msgid "Failed to get message!\n" | ||
5203 | msgstr "Нисам успео да добавим поруку!\n" | ||
5204 | |||
5205 | #: src/psycstore/gnunet-service-psycstore.c:328 | ||
5206 | msgid "Failed to get message fragment!\n" | ||
5207 | msgstr "Нисам успео да добавим делић поруке!\n" | ||
5208 | |||
5209 | #: src/psycstore/gnunet-service-psycstore.c:356 | ||
5210 | msgid "Failed to get master counters!\n" | ||
5211 | msgstr "Нисам успео да добавим главне бројаче!\n" | ||
5212 | |||
5213 | #: src/psycstore/gnunet-service-psycstore.c:392 | ||
5214 | #: src/psycstore/gnunet-service-psycstore.c:465 | ||
5215 | msgid "Tried to set invalid state variable name!\n" | ||
5216 | msgstr "Покушах да поставим назив променљиве неисправног стања!\n" | ||
5217 | |||
5218 | #: src/psycstore/gnunet-service-psycstore.c:408 | ||
5219 | msgid "Failed to begin modifying state!\n" | ||
5220 | msgstr "Нисам успео да започнем стање измене!\n" | ||
5221 | |||
5222 | #: src/psycstore/gnunet-service-psycstore.c:431 | ||
5223 | #, c-format | ||
5224 | msgid "Unknown operator: %c\n" | ||
5225 | msgstr "Непознат оператор: %c\n" | ||
5226 | |||
5227 | #: src/psycstore/gnunet-service-psycstore.c:441 | ||
5228 | msgid "Failed to end modifying state!\n" | ||
5229 | msgstr "Нисам успео да завршим стање измене!\n" | ||
5230 | |||
5231 | #: src/psycstore/gnunet-service-psycstore.c:479 | ||
5232 | msgid "Failed to begin synchronizing state!\n" | ||
5233 | msgstr "Нисам успео да започнем стање усклађивања!\n" | ||
5234 | |||
5235 | #: src/psycstore/gnunet-service-psycstore.c:495 | ||
5236 | msgid "Failed to end synchronizing state!\n" | ||
5237 | msgstr "Нисам успео да завршим стање усклађивања!\n" | ||
5238 | |||
5239 | #: src/psycstore/gnunet-service-psycstore.c:515 | ||
5240 | #: src/psycstore/gnunet-service-psycstore.c:534 | ||
5241 | msgid "Failed to reset state!\n" | ||
5242 | msgstr "Нисам успео да повратим стање!\n" | ||
5243 | |||
5244 | #: src/psycstore/gnunet-service-psycstore.c:557 | ||
5245 | #: src/psycstore/gnunet-service-psycstore.c:608 | ||
5246 | msgid "Tried to get invalid state variable name!\n" | ||
5247 | msgstr "Покушах да добавим назив променљиве неисправног стања!\n" | ||
5248 | |||
5249 | #: src/psycstore/gnunet-service-psycstore.c:584 | ||
5250 | #: src/psycstore/gnunet-service-psycstore.c:623 | ||
5251 | msgid "Failed to get state variable!\n" | ||
5252 | msgstr "Нисам успео да добавим променљиву стања!\n" | ||
5253 | |||
5254 | #: src/psycstore/plugin_psycstore_sqlite.c:60 | ||
5255 | #, c-format | ||
5256 | msgid "`%s' failed at %s:%d with error: %s (%d)\n" | ||
5257 | msgstr "„%s“ није успело на %s:%d са грешком: %s (%d)\n" | ||
5258 | |||
5259 | #: src/psycstore/plugin_psycstore_sqlite.c:253 | ||
5260 | #, c-format | ||
5261 | msgid "" | ||
5262 | "Error preparing SQL query: %s\n" | ||
5263 | " %s\n" | ||
5264 | msgstr "" | ||
5265 | "Грешка припремања СКуЛ упита: %s\n" | ||
5266 | " %s\n" | ||
5267 | |||
5268 | #: src/psycstore/plugin_psycstore_sqlite.c:276 | ||
5269 | #, c-format | ||
5270 | msgid "" | ||
5271 | "Error executing SQL query: %s\n" | ||
5272 | " %s\n" | ||
5273 | msgstr "" | ||
5274 | "Грешка извршавања СКуЛ упита: %s\n" | ||
5275 | " %s\n" | ||
5276 | |||
5277 | #: src/psycstore/plugin_psycstore_sqlite.c:1796 | ||
5278 | msgid "SQLite database running\n" | ||
5279 | msgstr "База података СКуЛајта ради\n" | ||
5280 | |||
5281 | #: src/pt/gnunet-daemon-pt.c:482 | ||
5282 | msgid "Failed to pack DNS request. Dropping.\n" | ||
5283 | msgstr "Нисам успео да упакујем ДНС захтев. Одбацујем.\n" | ||
5284 | |||
5285 | #: src/pt/gnunet-daemon-pt.c:488 | ||
5286 | msgid "# DNS requests mapped to VPN" | ||
5287 | msgstr "# ДНС захтеви су мапирани у ВПН" | ||
5288 | |||
5289 | #: src/pt/gnunet-daemon-pt.c:541 | ||
5290 | msgid "# DNS records modified" | ||
5291 | msgstr "# ДНС записи су измењени" | ||
5292 | |||
5293 | #: src/pt/gnunet-daemon-pt.c:717 | ||
5294 | msgid "# DNS replies intercepted" | ||
5295 | msgstr "# ДНС одговори су пресретени" | ||
5296 | |||
5297 | #: src/pt/gnunet-daemon-pt.c:723 | ||
5298 | msgid "Failed to parse DNS request. Dropping.\n" | ||
5299 | msgstr "Нисам успео да обрадим ДНС захтев. Одбацујем.\n" | ||
5300 | |||
5301 | #: src/pt/gnunet-daemon-pt.c:826 | ||
5302 | msgid "# DNS requests dropped (timeout)" | ||
5303 | msgstr "# ДНС захтеви су одбачени (истекло је време)" | ||
5304 | |||
5305 | #: src/pt/gnunet-daemon-pt.c:883 | ||
5306 | msgid "# DNS requests intercepted" | ||
5307 | msgstr "# ДНС захтеви су пресретени" | ||
5308 | |||
5309 | #: src/pt/gnunet-daemon-pt.c:888 | ||
5310 | msgid "# DNS requests dropped (DNS mesh channel down)" | ||
5311 | msgstr "# ДНС захтеви су одбачени (ДНС меш канал је пао)" | ||
5312 | |||
5313 | #: src/pt/gnunet-daemon-pt.c:896 | ||
5314 | msgid "# DNS requests dropped (malformed)" | ||
5315 | msgstr "# ДНС захтеви су одбачени (лоши су)" | ||
5316 | |||
5317 | #: src/pt/gnunet-daemon-pt.c:969 | ||
5318 | msgid "# DNS replies received" | ||
5319 | msgstr "# ДНС одговори су примљени" | ||
5320 | |||
5321 | #: src/pt/gnunet-daemon-pt.c:985 | ||
5322 | msgid "# DNS replies dropped (too late?)" | ||
5323 | msgstr "# ДНС одговори су одбачени (прекасно је?)" | ||
5324 | |||
5325 | #: src/pt/gnunet-daemon-pt.c:1261 src/pt/gnunet-daemon-pt.c:1270 | ||
5326 | #: src/pt/gnunet-daemon-pt.c:1290 src/pt/gnunet-daemon-pt.c:1301 | ||
5327 | #: src/pt/gnunet-daemon-pt.c:1310 | ||
5328 | #, c-format | ||
5329 | msgid "Failed to connect to %s service. Exiting.\n" | ||
5330 | msgstr "Нисам успео да се повежем са „%s“ услугом. Излазим.\n" | ||
5331 | |||
5332 | #: src/pt/gnunet-daemon-pt.c:1347 | ||
5333 | msgid "Daemon to run to perform IP protocol translation to GNUnet" | ||
5334 | msgstr "Демон за покретање за обављање превода ИП протокола у ГНУнет" | ||
5335 | |||
5336 | #: src/regex/gnunet-daemon-regexprofiler.c:270 | ||
5337 | #: src/regex/gnunet-regex-simulation-profiler.c:659 | ||
5338 | #, c-format | ||
5339 | msgid "%s service is lacking key configuration settings (%s). Exiting.\n" | ||
5340 | msgstr "„%s“ услузи недостају поставке подешавања кључа (%s). Излазим.\n" | ||
5341 | |||
5342 | #: src/regex/gnunet-daemon-regexprofiler.c:380 | ||
5343 | msgid "Daemon to announce regular expressions for the peer using mesh." | ||
5344 | msgstr "Демон за најаву регуларних израза за парњака који користи меш." | ||
5345 | |||
5346 | #: src/regex/gnunet-regex-profiler.c:1288 | ||
5347 | msgid "No configuration file given. Exiting\n" | ||
5348 | msgstr "Није дата датотека подешавања. Излазим\n" | ||
5349 | |||
5350 | #: src/regex/gnunet-regex-profiler.c:1299 | ||
5351 | msgid "Configuration option \"regex_prefix\" missing. Exiting\n" | ||
5352 | msgstr "Недостаје опција подешавања „regex_prefix“. Излазим\n" | ||
5353 | |||
5354 | #: src/regex/gnunet-regex-profiler.c:1328 | ||
5355 | #: src/regex/gnunet-regex-simulation-profiler.c:622 | ||
5356 | #, c-format | ||
5357 | msgid "No policy directory specified on command line. Exiting.\n" | ||
5358 | msgstr "На линији наредби није наведен директоријум политике. Излазим.\n" | ||
5359 | |||
5360 | #: src/regex/gnunet-regex-profiler.c:1334 | ||
5361 | #: src/regex/gnunet-regex-simulation-profiler.c:629 | ||
5362 | #, c-format | ||
5363 | msgid "Specified policies directory does not exist. Exiting.\n" | ||
5364 | msgstr "Наведени директоријум политике не постоји. Излазим.\n" | ||
5365 | |||
5366 | #: src/regex/gnunet-regex-profiler.c:1341 | ||
5367 | #, c-format | ||
5368 | msgid "No files found in `%s'\n" | ||
5369 | msgstr "Нисам нашао датотеке у „%s“\n" | ||
5370 | |||
5371 | #: src/regex/gnunet-regex-profiler.c:1350 | ||
5372 | msgid "No search strings file given. Exiting.\n" | ||
5373 | msgstr "Није дата датотека ниски претраге. Излазим.\n" | ||
5374 | |||
5375 | #: src/regex/gnunet-regex-profiler.c:1370 | ||
5376 | msgid "Error loading search strings. Exiting.\n" | ||
5377 | msgstr "Грешка учитавања ниски претраге. Излазим.\n" | ||
5378 | |||
5379 | #: src/regex/gnunet-regex-profiler.c:1455 | ||
5380 | msgid "name of the file for writing statistics" | ||
5381 | msgstr "назив датотеке за записивање статистике" | ||
5382 | |||
5383 | #: src/regex/gnunet-regex-profiler.c:1458 | ||
5384 | msgid "wait TIMEOUT before ending the experiment" | ||
5385 | msgstr "чека ВРЕМЕ_ИСТЕКА пре завршавања експеримента" | ||
5386 | |||
5387 | #: src/regex/gnunet-regex-profiler.c:1461 | ||
5388 | msgid "directory with policy files" | ||
5389 | msgstr "директоријум са датотекама политике" | ||
5390 | |||
5391 | #: src/regex/gnunet-regex-profiler.c:1464 | ||
5392 | msgid "name of file with input strings" | ||
5393 | msgstr "назив датотеке са улазним нискама" | ||
5394 | |||
5395 | #: src/regex/gnunet-regex-profiler.c:1467 | ||
5396 | msgid "name of file with hosts' names" | ||
5397 | msgstr "назив датотеке са називима домаћина" | ||
5398 | |||
5399 | #: src/regex/gnunet-regex-profiler.c:1479 | ||
5400 | msgid "Profiler for regex" | ||
5401 | msgstr "Профилатор за регуларни израз" | ||
5402 | |||
5403 | #: src/regex/gnunet-regex-simulation-profiler.c:689 | ||
5404 | msgid "name of the table to write DFAs" | ||
5405 | msgstr "назив табеле за уписивање ДФА-са" | ||
5406 | |||
5407 | #: src/regex/gnunet-regex-simulation-profiler.c:692 | ||
5408 | msgid "maximum path compression length" | ||
5409 | msgstr "највећа дужина сажимања путање" | ||
5410 | |||
5411 | #: src/regex/gnunet-regex-simulation-profiler.c:705 | ||
5412 | msgid "Profiler for regex library" | ||
5413 | msgstr "Профилатор за библиотеку регуларног израза" | ||
5414 | |||
5415 | #: src/regex/regex_api.c:131 | ||
5416 | #, c-format | ||
5417 | msgid "Regex `%s' is too long!\n" | ||
5418 | msgstr "Регуларни израз „%s“ је превелик!\n" | ||
5419 | |||
5420 | #: src/revocation/gnunet-revocation.c:126 | ||
5421 | #, c-format | ||
5422 | msgid "Key `%s' is valid\n" | ||
5423 | msgstr "Кључ „%s“ је исправан\n" | ||
5424 | |||
5425 | #: src/revocation/gnunet-revocation.c:131 | ||
5426 | #, c-format | ||
5427 | msgid "Key `%s' has been revoked\n" | ||
5428 | msgstr "Тастер „%s“ је опозван\n" | ||
5429 | |||
5430 | #: src/revocation/gnunet-revocation.c:137 | ||
5431 | msgid "Internal error\n" | ||
5432 | msgstr "Унутрашња грешка\n" | ||
5433 | |||
5434 | #: src/revocation/gnunet-revocation.c:163 | ||
5435 | #, c-format | ||
5436 | msgid "Key for ego `%s' is still valid, revocation failed (!)\n" | ||
5437 | msgstr "Кључ за его „%s“ још увек важи, опозивање није успело (!)\n" | ||
5438 | |||
5439 | #: src/revocation/gnunet-revocation.c:168 | ||
5440 | msgid "Revocation failed (!)\n" | ||
5441 | msgstr "Опозивање није успело (!)\n" | ||
5442 | |||
5443 | #: src/revocation/gnunet-revocation.c:173 | ||
5444 | #, c-format | ||
5445 | msgid "Key for ego `%s' has been successfully revoked\n" | ||
5446 | msgstr "Кључ за его „%s“ је успешно опозван\n" | ||
5447 | |||
5448 | #: src/revocation/gnunet-revocation.c:178 | ||
5449 | msgid "Revocation successful.\n" | ||
5450 | msgstr "Опозивање је успело.\n" | ||
5451 | |||
5452 | #: src/revocation/gnunet-revocation.c:183 | ||
5453 | msgid "Internal error, key revocation might have failed\n" | ||
5454 | msgstr "Унутрашња грешка, опозив кључа можда није успео\n" | ||
5455 | |||
5456 | #: src/revocation/gnunet-revocation.c:294 | ||
5457 | #, c-format | ||
5458 | msgid "Revocation certificate for `%s' stored in `%s'\n" | ||
5459 | msgstr "Уверење опозива за „%s“ је смештено у „%s“\n" | ||
5460 | |||
5461 | #: src/revocation/gnunet-revocation.c:324 | ||
5462 | #, c-format | ||
5463 | msgid "Ego `%s' not found.\n" | ||
5464 | msgstr "Нисам нашао его „%s“.\n" | ||
5465 | |||
5466 | #: src/revocation/gnunet-revocation.c:345 | ||
5467 | #, c-format | ||
5468 | msgid "Error: revocation certificate in `%s' is not for `%s'\n" | ||
5469 | msgstr "Грешка: уверење опозива у „%s“ није за „%s“\n" | ||
5470 | |||
5471 | #: src/revocation/gnunet-revocation.c:365 | ||
5472 | msgid "Revocation certificate ready\n" | ||
5473 | msgstr "Уверење опозива је спремно\n" | ||
5474 | |||
5475 | #: src/revocation/gnunet-revocation.c:375 | ||
5476 | msgid "Revocation certificate not ready, calculating proof of work\n" | ||
5477 | msgstr "Уверење опозива није спремно, израчунавам доказ о раду\n" | ||
5478 | |||
5479 | #: src/revocation/gnunet-revocation.c:407 | ||
5480 | #, c-format | ||
5481 | msgid "Public key `%s' malformed\n" | ||
5482 | msgstr "Јавни кључ „%s“ је лош\n" | ||
5483 | |||
5484 | #: src/revocation/gnunet-revocation.c:421 | ||
5485 | msgid "Testing and revoking at the same time is not allowed, only executing test.\n" | ||
5486 | msgstr "Тестирање и опозивање у исто време није дозвољено, само тестирање извршавам.\n" | ||
5487 | |||
5488 | #: src/revocation/gnunet-revocation.c:441 | ||
5489 | msgid "No filename to store revocation certificate given.\n" | ||
5490 | msgstr "Није дат назив датотеке за смештање уверења опозива.\n" | ||
5491 | |||
5492 | #: src/revocation/gnunet-revocation.c:463 | ||
5493 | #, c-format | ||
5494 | msgid "Failed to read revocation certificate from `%s'\n" | ||
5495 | msgstr "Нисам успео да прочитам уверење опозива из „%s“\n" | ||
5496 | |||
5497 | #: src/revocation/gnunet-revocation.c:488 | ||
5498 | msgid "No action specified. Nothing to do.\n" | ||
5499 | msgstr "Није наведена ниједна радња. Немам шта да радим.\n" | ||
5500 | |||
5501 | #: src/revocation/gnunet-revocation.c:504 | ||
5502 | msgid "use NAME for the name of the revocation file" | ||
5503 | msgstr "користи НАЗИВ за назив датотеке опозивања" | ||
5504 | |||
5505 | #: src/revocation/gnunet-revocation.c:507 | ||
5506 | msgid "revoke the private key associated for the the private key associated with the ego NAME " | ||
5507 | msgstr "опозива лични кључ придружен личном кључу са его НАЗИВОМ " | ||
5508 | |||
5509 | #: src/revocation/gnunet-revocation.c:510 | ||
5510 | msgid "actually perform revocation, otherwise we just do the precomputation" | ||
5511 | msgstr "заправо обавља опозив, у супротном само радимо предизрачунавање" | ||
5512 | |||
5513 | #: src/revocation/gnunet-revocation.c:513 | ||
5514 | msgid "test if the public key KEY has been revoked" | ||
5515 | msgstr "тестира да ли је јавни кључ КЉУЧ опозван" | ||
5516 | |||
5517 | #: src/revocation/gnunet-service-revocation.c:272 | ||
5518 | msgid "Duplicate revocation received from peer. Ignored.\n" | ||
5519 | msgstr "Двоструки опзив је примљен од парњака. Занемарено.\n" | ||
5520 | |||
5521 | #: src/revocation/gnunet-service-revocation.c:434 | ||
5522 | #, c-format | ||
5523 | msgid "Error computing revocation set union with %s\n" | ||
5524 | msgstr "Грешка прорачуна уније скупа опозивања са %s\n" | ||
5525 | |||
5526 | #: src/revocation/gnunet-service-revocation.c:486 | ||
5527 | msgid "SET service crashed, terminating revocation service\n" | ||
5528 | msgstr "Услуга ПОСТАВИ се урушила, окончавам услугу опозивања\n" | ||
5529 | |||
5530 | #: src/revocation/gnunet-service-revocation.c:812 | ||
5531 | msgid "Could not open revocation database file!" | ||
5532 | msgstr "Не могу да отворим датотеку базе података опозивања!" | ||
5533 | |||
5534 | #: src/scalarproduct/gnunet-scalarproduct.c:225 | ||
5535 | msgid "You must specify at least one message ID to check!\n" | ||
5536 | msgstr "Морате навести бар један ИБ поруке за проверу!\n" | ||
5537 | |||
5538 | #: src/scalarproduct/gnunet-scalarproduct.c:232 | ||
5539 | msgid "This program needs a session identifier for comparing vectors.\n" | ||
5540 | msgstr "Овом програму је потребан одредник сесије за поређење вектора.\n" | ||
5541 | |||
5542 | #: src/scalarproduct/gnunet-scalarproduct.c:239 | ||
5543 | msgid "Please give a session key for --input_key!\n" | ||
5544 | msgstr "Дајте кључ сесије за „--input_key“!\n" | ||
5545 | |||
5546 | #: src/scalarproduct/gnunet-scalarproduct.c:251 | ||
5547 | #, c-format | ||
5548 | msgid "Tried to set initiator mode, as peer ID was given. However, `%s' is not a valid peer identifier.\n" | ||
5549 | msgstr "Покушах да поставим режим покретача, јер је ИБ парњака био дат. Било како било, „%s“ није добар одредник парњака.\n" | ||
5550 | |||
5551 | #: src/scalarproduct/gnunet-scalarproduct.c:278 | ||
5552 | #: src/scalarproduct/gnunet-scalarproduct.c:314 | ||
5553 | #, c-format | ||
5554 | msgid "Could not convert `%s' to int32_t.\n" | ||
5555 | msgstr "Не могу да претворим „%s“ у „int32_t“.\n" | ||
5556 | |||
5557 | #: src/scalarproduct/gnunet-scalarproduct.c:286 | ||
5558 | msgid "Need elements to compute the vectorproduct, got none.\n" | ||
5559 | msgstr "Потребни су елементи за израчунавање производа вектора, нисам добио ниједан.\n" | ||
5560 | |||
5561 | #: src/scalarproduct/gnunet-scalarproduct.c:346 | ||
5562 | #, c-format | ||
5563 | msgid "Could not convert `%s' to integer.\n" | ||
5564 | msgstr "Не могу да претворим „%s“ у цео број.\n" | ||
5565 | |||
5566 | #: src/scalarproduct/gnunet-scalarproduct.c:407 | ||
5567 | msgid "A comma separated list of elements to compare as vector with our remote peer." | ||
5568 | msgstr "Зарезом раздвојен списак елемената за поређење као вектора са нашим удаљеним парњаком." | ||
5569 | |||
5570 | #: src/scalarproduct/gnunet-scalarproduct.c:410 | ||
5571 | msgid "A comma separated mask to select which elements should actually be compared." | ||
5572 | msgstr "Зарезом раздвојена маска за бирање који елементи заправо требају бити поређени." | ||
5573 | |||
5574 | #: src/scalarproduct/gnunet-scalarproduct.c:413 | ||
5575 | msgid "[Optional] peer to calculate our scalarproduct with. If this parameter is not given, the service will wait for a remote peer to compute the request." | ||
5576 | msgstr "[Изборни] парњак са којим израчунавамо наш скаларни производ. Ако тај параметар није дат, услуга ће чекати да удаљени парњак прорачуна захтев." | ||
5577 | |||
5578 | #: src/scalarproduct/gnunet-scalarproduct.c:416 | ||
5579 | msgid "Transaction ID shared with peer." | ||
5580 | msgstr "ИБ преноса дељеног са парњаком." | ||
5581 | |||
5582 | #: src/scalarproduct/gnunet-scalarproduct.c:425 | ||
5583 | msgid "Calculate the Vectorproduct with a GNUnet peer." | ||
5584 | msgstr "Израчунава Производ вектора са ГНУнет парњаком." | ||
5585 | |||
5586 | #: src/scalarproduct/gnunet-service-scalarproduct.c:541 | ||
5587 | #, c-format | ||
5588 | msgid "Client (%p) disconnected from us.\n" | ||
5589 | msgstr "Прекинута је веза клијента (%p) са нама.\n" | ||
5590 | |||
5591 | #: src/scalarproduct/gnunet-service-scalarproduct.c:613 | ||
5592 | #: src/scalarproduct/gnunet-service-scalarproduct.c:702 | ||
5593 | #, c-format | ||
5594 | msgid "Could not send message to client (%p)!\n" | ||
5595 | msgstr "Не могу да пошаљем поруку клијенту (%p)!\n" | ||
5596 | |||
5597 | #: src/scalarproduct/gnunet-service-scalarproduct.c:619 | ||
5598 | #, c-format | ||
5599 | msgid "Sending session-end notification to client (%p) for session %s\n" | ||
5600 | msgstr "Шаљем обавештење о крају сесије клијенту (%p) за сесију %s\n" | ||
5601 | |||
5602 | #: src/scalarproduct/gnunet-service-scalarproduct.c:712 | ||
5603 | #, c-format | ||
5604 | msgid "Sent result to client (%p), this session (%s) has ended!\n" | ||
5605 | msgstr "Резултати су послати клијенту (%p), ова сесија (%s) је завршена!\n" | ||
5606 | |||
5607 | #: src/scalarproduct/gnunet-service-scalarproduct.c:766 | ||
5608 | #: src/scalarproduct/gnunet-service-scalarproduct.c:855 | ||
5609 | msgid "Could not send service-response message via mesh!)\n" | ||
5610 | msgstr "Не могу да пошаљем поруку одговора услуге путем меша!)\n" | ||
5611 | |||
5612 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1028 | ||
5613 | #, c-format | ||
5614 | msgid "Failed to communicate with `%s', scalar product calculation aborted.\n" | ||
5615 | msgstr "Нисам успео да разговарам са „%s“, прорачун скаларног производа је прекинут.\n" | ||
5616 | |||
5617 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1099 | ||
5618 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1208 | ||
5619 | msgid "Transmitting service request.\n" | ||
5620 | msgstr "Одашиљем захтев услуге.\n" | ||
5621 | |||
5622 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1108 | ||
5623 | msgid "Could not send service-request multipart message to channel!\n" | ||
5624 | msgstr "Не могу да пошаљем вишеделовну поруку захтева услуге каналу!\n" | ||
5625 | |||
5626 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1147 | ||
5627 | #, c-format | ||
5628 | msgid "Successfully created new channel to peer (%s)!\n" | ||
5629 | msgstr "Успешно је створен нови канал за парњака (%s)!\n" | ||
5630 | |||
5631 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1217 | ||
5632 | msgid "Could not send message to channel!\n" | ||
5633 | msgstr "Не могу да пошаљем поруку на канал!\n" | ||
5634 | |||
5635 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1274 | ||
5636 | msgid "Too short message received from client!\n" | ||
5637 | msgstr "Прекратка порука је примљена од клијента!\n" | ||
5638 | |||
5639 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1287 | ||
5640 | msgid "Invalid message received from client, session information incorrect!\n" | ||
5641 | msgstr "Неисправна порука је примљена са клијента, подаци о сесији су нетачни!\n" | ||
5642 | |||
5643 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1298 | ||
5644 | #, c-format | ||
5645 | msgid "Duplicate session information received, cannot create new session with key `%s'\n" | ||
5646 | msgstr "Двоструки подаци сесије су примљени, не могу да направим нову сесију са кључем „%s“\n" | ||
5647 | |||
5648 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1318 | ||
5649 | #, c-format | ||
5650 | msgid "Got client-request-session with key %s, preparing channel to remote service.\n" | ||
5651 | msgstr "Добих сесију захтева клијента са кључем %s, припремам канал за удљену услугу.\n" | ||
5652 | |||
5653 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1354 | ||
5654 | #, c-format | ||
5655 | msgid "Creating new channel for session with key %s.\n" | ||
5656 | msgstr "Стварам нови канал за сесију са кључем „%s“.\n" | ||
5657 | |||
5658 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1399 | ||
5659 | #, c-format | ||
5660 | msgid "Got client-responder-session with key %s and a matching service-request-session set, processing.\n" | ||
5661 | msgstr "Добих сесију одговарача клијента са кључем %s и одговарајући скуп сесије захтева услуге, обрађујем.\n" | ||
5662 | |||
5663 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1409 | ||
5664 | #, c-format | ||
5665 | msgid "Got client-responder-session with key %s but NO matching service-request-session set, queuing element for later use.\n" | ||
5666 | msgstr "Добих сесију одговарача клијента са кључем %s али НЕ и одговарајући скуп сесије захтева услуге, стављам елемент у ред за касније коришћење.\n" | ||
5667 | |||
5668 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1439 | ||
5669 | #, c-format | ||
5670 | msgid "New incoming channel from peer %s.\n" | ||
5671 | msgstr "Нови долазни канал са парњака „%s“.\n" | ||
5672 | |||
5673 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1471 | ||
5674 | #, c-format | ||
5675 | msgid "Peer disconnected, terminating session %s with peer (%s)\n" | ||
5676 | msgstr "Веза са парњаком је прекинута, окончавам сесију %s са парњаком (%s)\n" | ||
5677 | |||
5678 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1672 | ||
5679 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1814 | ||
5680 | #, c-format | ||
5681 | msgid "Got session with key %s and a matching element set, processing.\n" | ||
5682 | msgstr "Добих сесију са кључем „%s“ и одговарајући скуп елемената, обрађујем.\n" | ||
5683 | |||
5684 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1681 | ||
5685 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1821 | ||
5686 | #, c-format | ||
5687 | msgid "Got session with key %s without a matching element set, queueing.\n" | ||
5688 | msgstr "Добих сесију са кључем „%s“ без одговарајућег скупа елемената, стављам у ред.\n" | ||
5689 | |||
5690 | #: src/scalarproduct/gnunet-service-scalarproduct.c:1771 | ||
5691 | #, c-format | ||
5692 | msgid "Got message with duplicate session key (`%s'), ignoring service request.\n" | ||
5693 | msgstr "Добих поруку са двоструким кључем сесије („%s“), занемарујем захтев сесије.\n" | ||
5694 | |||
5695 | #: src/scalarproduct/gnunet-service-scalarproduct.c:2014 | ||
5696 | msgid "Shutting down, initiating cleanup.\n" | ||
5697 | msgstr "Гасим, покрећем чишћење.\n" | ||
5698 | |||
5699 | #: src/scalarproduct/gnunet-service-scalarproduct.c:2100 | ||
5700 | msgid "Connect to MESH failed\n" | ||
5701 | msgstr "Повезивање са МЕШОМ није успело\n" | ||
5702 | |||
5703 | #: src/scalarproduct/gnunet-service-scalarproduct.c:2104 | ||
5704 | msgid "Mesh initialized\n" | ||
5705 | msgstr "Меш је покренут\n" | ||
5706 | |||
5707 | #: src/scalarproduct/scalarproduct_api.c:246 | ||
5708 | msgid "# SUC responder result messages received" | ||
5709 | msgstr "# примљене су поруке резултата „SUC“ одговарача" | ||
5710 | |||
5711 | #: src/scalarproduct/scalarproduct_api.c:300 | ||
5712 | msgid "# bytes sent to scalarproduct" | ||
5713 | msgstr "# бајтови су послати скаларном производу" | ||
5714 | |||
5715 | #: src/scalarproduct/scalarproduct_api.c:345 | ||
5716 | #: src/scalarproduct/scalarproduct_api.c:440 | ||
5717 | msgid "Failed to connect to the scalarproduct service\n" | ||
5718 | msgstr "Нисам успео да се повежем са услугом скаларног производа\n" | ||
5719 | |||
5720 | #: src/scalarproduct/scalarproduct_api.c:353 | ||
5721 | #: src/scalarproduct/scalarproduct_api.c:448 | ||
5722 | msgid "Failed to send a message to the statistics service\n" | ||
5723 | msgstr "Нисам успео да пошаљем поруку услузи статистике\n" | ||
5724 | |||
5725 | #: src/scalarproduct/scalarproduct_api.c:387 | ||
5726 | #: src/scalarproduct/scalarproduct_api.c:485 | ||
5727 | msgid "Failed to send a message to the scalarproduct service\n" | ||
5728 | msgstr "Нисам успео да пошаљем поруку услузи скаларног производа\n" | ||
5729 | |||
5730 | #: src/secretsharing/gnunet-secretsharing-profiler.c:538 | ||
5731 | msgid "dkg start delay" | ||
5732 | msgstr "застој „dkg“ почетка" | ||
5733 | |||
5734 | #: src/secretsharing/gnunet-secretsharing-profiler.c:541 | ||
5735 | msgid "dkg timeout" | ||
5736 | msgstr "време истека „dkg“-а" | ||
5737 | |||
5738 | #: src/secretsharing/gnunet-secretsharing-profiler.c:544 | ||
5739 | msgid "threshold" | ||
5740 | msgstr "осетљивост" | ||
5741 | |||
5742 | #: src/secretsharing/gnunet-secretsharing-profiler.c:547 | ||
5743 | msgid "also profile decryption" | ||
5744 | msgstr "такође опис профила" | ||
5745 | |||
5746 | #: src/set/gnunet-service-set.c:1431 | ||
5747 | msgid "Could not connect to mesh service\n" | ||
5748 | msgstr "Не могу да се повежем са меш услугом\n" | ||
5749 | |||
5750 | #: src/set/gnunet-set-ibf-profiler.c:221 | ||
5751 | msgid "number of element in set A-B" | ||
5752 | msgstr "број елемената у скупу A-B" | ||
5753 | |||
5754 | #: src/set/gnunet-set-ibf-profiler.c:224 | ||
5755 | msgid "number of element in set B-A" | ||
5756 | msgstr "број елемената у скупу B-A" | ||
5757 | |||
5758 | #: src/set/gnunet-set-ibf-profiler.c:227 | ||
5759 | msgid "number of common elements in A and B" | ||
5760 | msgstr "број заједничких елемената у A и B" | ||
5761 | |||
5762 | #: src/set/gnunet-set-ibf-profiler.c:230 | ||
5763 | msgid "hash num" | ||
5764 | msgstr "хеш број" | ||
5765 | |||
5766 | #: src/set/gnunet-set-ibf-profiler.c:233 | ||
5767 | msgid "ibf size" | ||
5768 | msgstr "„ibf“ величина" | ||
5769 | |||
5770 | #: src/set/gnunet-set-profiler.c:295 | ||
5771 | msgid "oeration to execute" | ||
5772 | msgstr "операција за извршавање" | ||
5773 | |||
5774 | #: src/statistics/gnunet-service-statistics.c:280 | ||
5775 | #, c-format | ||
5776 | msgid "Loading %llu bytes of statistics from `%s'\n" | ||
5777 | msgstr "Учитавам %llu бајта статистике из „%s“\n" | ||
5778 | |||
5779 | #: src/statistics/gnunet-service-statistics.c:346 | ||
5780 | #, c-format | ||
5781 | msgid "Wrote %llu bytes of statistics to `%s'\n" | ||
5782 | msgstr "Записујем %llu бајта статистике у „%s“\n" | ||
5783 | |||
5784 | #: src/statistics/gnunet-statistics.c:140 | ||
5785 | msgid "Failed to obtain statistics.\n" | ||
5786 | msgstr "Нисам успео да добијем статистику.\n" | ||
5787 | |||
5788 | #: src/statistics/gnunet-statistics.c:142 | ||
5789 | #, c-format | ||
5790 | msgid "Failed to obtain statistics from host `%s:%llu'\n" | ||
5791 | msgstr "Нисам успео да добијем статистику од домаћина „%s:%llu“\n" | ||
5792 | |||
5793 | #: src/statistics/gnunet-statistics.c:189 | ||
5794 | msgid "Missing argument: subsystem \n" | ||
5795 | msgstr "Недостаје аргумент: подсистем \n" | ||
5796 | |||
5797 | #: src/statistics/gnunet-statistics.c:195 | ||
5798 | msgid "Missing argument: name\n" | ||
5799 | msgstr "Недостаје аргумент: назив\n" | ||
5800 | |||
5801 | #: src/statistics/gnunet-statistics.c:226 | ||
5802 | #, c-format | ||
5803 | msgid "No subsystem or name given\n" | ||
5804 | msgstr "Није дат подсистем или назив\n" | ||
5805 | |||
5806 | #: src/statistics/gnunet-statistics.c:234 | ||
5807 | #, c-format | ||
5808 | msgid "Failed to initialize watch routine\n" | ||
5809 | msgstr "Нисам успео да покренем рутину гледања\n" | ||
5810 | |||
5811 | #: src/statistics/gnunet-statistics.c:261 | ||
5812 | #, c-format | ||
5813 | msgid "Trying to connect to remote host, but service `%s' is not running\n" | ||
5814 | msgstr "Покушавам да се повежем са удаљеним домаћином, али услуга „%s“ није покренута\n" | ||
5815 | |||
5816 | #: src/statistics/gnunet-statistics.c:269 | ||
5817 | #, c-format | ||
5818 | msgid "A port is required to connect to host `%s'\n" | ||
5819 | msgstr "Потребан је прикључник за повезивање са домаћином „%s“\n" | ||
5820 | |||
5821 | #: src/statistics/gnunet-statistics.c:276 | ||
5822 | #, c-format | ||
5823 | msgid "A port has to be between 1 and 65535 to connect to host `%s'\n" | ||
5824 | msgstr "Прикључник треба бити између 1 и 65535 за повезивање са домаћином „%s“\n" | ||
5825 | |||
5826 | #: src/statistics/gnunet-statistics.c:308 | ||
5827 | #, c-format | ||
5828 | msgid "Invalid argument `%s'\n" | ||
5829 | msgstr "Неисправан аргумент „%s“\n" | ||
5830 | |||
5831 | #: src/statistics/gnunet-statistics.c:334 | ||
5832 | msgid "limit output to statistics for the given NAME" | ||
5833 | msgstr "ограничава излаз на статистику за дати НАЗИВ" | ||
5834 | |||
5835 | #: src/statistics/gnunet-statistics.c:337 | ||
5836 | msgid "make the value being set persistent" | ||
5837 | msgstr "чини да вредност бива постављена трајном" | ||
5838 | |||
5839 | #: src/statistics/gnunet-statistics.c:340 | ||
5840 | msgid "limit output to the given SUBSYSTEM" | ||
5841 | msgstr "ограничава излаз на дати ПОДСИСТЕМ" | ||
5842 | |||
5843 | #: src/statistics/gnunet-statistics.c:343 | ||
5844 | msgid "just print the statistics value" | ||
5845 | msgstr "само исписује вредност статистике" | ||
5846 | |||
5847 | #: src/statistics/gnunet-statistics.c:346 | ||
5848 | msgid "watch value continuously" | ||
5849 | msgstr "гледа вредност непрекидно" | ||
5850 | |||
5851 | #: src/statistics/gnunet-statistics.c:349 | ||
5852 | msgid "connect to remote host" | ||
5853 | msgstr "повезује се са удаљеним домаћином" | ||
5854 | |||
5855 | #: src/statistics/gnunet-statistics.c:352 | ||
5856 | msgid "port for remote host" | ||
5857 | msgstr "прикључник за удаљеног домаћина" | ||
5858 | |||
5859 | #: src/statistics/gnunet-statistics.c:364 | ||
5860 | msgid "Print statistics about GNUnet operations." | ||
5861 | msgstr "Исписује статистику о ГНУнет радњама." | ||
5862 | |||
5863 | #: src/statistics/statistics_api.c:519 | ||
5864 | msgid "Could not save some persistent statistics\n" | ||
5865 | msgstr "Не могу да сачувам нешто од трајне статистике\n" | ||
5866 | |||
5867 | #: src/statistics/statistics_api.c:1090 | ||
5868 | msgid "Failed to receive acknowledgement from statistics service, some statistics might have been lost!\n" | ||
5869 | msgstr "Нисам успео да примим потврду од услуге статистике, неке статистике могу бити изгубљене!\n" | ||
5870 | |||
5871 | #: src/testbed/generate-underlay-topology.c:223 | ||
5872 | msgid "Need atleast 2 arguments\n" | ||
5873 | msgstr "Потребна су најмање 2 аргумента\n" | ||
5874 | |||
5875 | #: src/testbed/generate-underlay-topology.c:228 | ||
5876 | msgid "Database filename missing\n" | ||
5877 | msgstr "Недостаје назив датотеке базе података\n" | ||
5878 | |||
5879 | #: src/testbed/generate-underlay-topology.c:235 | ||
5880 | msgid "Topology string missing\n" | ||
5881 | msgstr "Ниска размештаја недостаје\n" | ||
5882 | |||
5883 | #: src/testbed/generate-underlay-topology.c:240 | ||
5884 | #, c-format | ||
5885 | msgid "Invalid topology: %s\n" | ||
5886 | msgstr "Неисправан размештај: %s\n" | ||
5887 | |||
5888 | #: src/testbed/generate-underlay-topology.c:252 | ||
5889 | #, c-format | ||
5890 | msgid "An argument is missing for given topology `%s'\n" | ||
5891 | msgstr "Недостаје аргумент за дати размештај „%s“\n" | ||
5892 | |||
5893 | #: src/testbed/generate-underlay-topology.c:258 | ||
5894 | #, c-format | ||
5895 | msgid "Invalid argument `%s' given as topology argument\n" | ||
5896 | msgstr "Неисправан аргумент „%s“ је дат као аргумент размештаја\n" | ||
5897 | |||
5898 | #: src/testbed/generate-underlay-topology.c:266 | ||
5899 | #, c-format | ||
5900 | msgid "Filename argument missing for topology `%s'\n" | ||
5901 | msgstr "Аргумент назива датотеке недостаје за размештај „%s“\n" | ||
5902 | |||
5903 | #: src/testbed/generate-underlay-topology.c:280 | ||
5904 | #, c-format | ||
5905 | msgid "Second argument for topology `%s' is missing\n" | ||
5906 | msgstr "Други аргумент за размештај „%s“ недостаје\n" | ||
5907 | |||
5908 | #: src/testbed/generate-underlay-topology.c:286 | ||
5909 | #, c-format | ||
5910 | msgid "Invalid argument `%s'; expecting unsigned int\n" | ||
5911 | msgstr "Неисправан аргумент „%s“; очекујем цео број без знака\n" | ||
5912 | |||
5913 | #: src/testbed/generate-underlay-topology.c:335 | ||
5914 | #: src/testbed/gnunet-testbed-profiler.c:293 | ||
5915 | msgid "create COUNT number of peers" | ||
5916 | msgstr "ствара УКУПНОСТ број парњака" | ||
5917 | |||
5918 | #: src/testbed/generate-underlay-topology.c:344 | ||
5919 | msgid "" | ||
5920 | "Generates SQLite3 database representing a given underlay topology.\n" | ||
5921 | "Usage: gnunet-underlay-topology [OPTIONS] db-filename TOPO [TOPOOPTS]\n" | ||
5922 | "The following options are available for TOPO followed by TOPOOPTS if applicable:\n" | ||
5923 | "\t LINE\n" | ||
5924 | "\t RING\n" | ||
5925 | "\t RANDOM <num_rnd_links>\n" | ||
5926 | "\t SMALL_WORLD <num_rnd_links>\n" | ||
5927 | "\t SMALL_WORLD_RING <num_rnd_links>\n" | ||
5928 | "\t CLIQUE\n" | ||
5929 | "\t 2D_TORUS\n" | ||
5930 | "\t SCALE_FREE <cap> <m>\n" | ||
5931 | "\t FROM_FILE <filename>\n" | ||
5932 | "TOPOOPTS:\n" | ||
5933 | "\t num_rnd_links: The number of random links\n" | ||
5934 | "\t cap: the maximum number of links a node can have\n" | ||
5935 | "\t m: the number of links a node should have while joining the network\n" | ||
5936 | "\t filename: the path of the file which contains topology information\n" | ||
5937 | "NOTE: the format of the above file is descibed here: https://www.gnunet.org/content/topology-file-format\n" | ||
5938 | msgstr "" | ||
5939 | "Ствара СКуЛајт3 базу података која представља дати основни размештај.\n" | ||
5940 | "Коришћење: gnunet-underlay-topology [ОПЦИЈЕ] db-filename TOPO [ТОПООПЦИЈЕ]\n" | ||
5941 | "Следеће опције су доступне за „TOPO“ за којима следе ТОПООПЦИЈЕ ако су примењиве:\n" | ||
5942 | "\t LINE\n" | ||
5943 | "\t RING\n" | ||
5944 | "\t RANDOM <num_rnd_links>\n" | ||
5945 | "\t SMALL_WORLD <num_rnd_links>\n" | ||
5946 | "\t SMALL_WORLD_RING <num_rnd_links>\n" | ||
5947 | "\t CLIQUE\n" | ||
5948 | "\t 2D_TORUS\n" | ||
5949 | "\t SCALE_FREE <cap> <m>\n" | ||
5950 | "\t FROM_FILE <filename>\n" | ||
5951 | "TOPOOPTS:\n" | ||
5952 | "\t num_rnd_links: Број насумичних веза\n" | ||
5953 | "\t cap: највећи број веза које чвор може да има\n" | ||
5954 | "\t m: број веза које чвор треба да има приликом придруживања мрежи\n" | ||
5955 | "\t filename: путања датотеке која садржи податке о размештају\n" | ||
5956 | "НАПОМЕНА: формат горе поменуте датотеке је описан овде: https://www.gnunet.org/content/topology-file-format\n" | ||
5957 | |||
5958 | #: src/testbed/gnunet-daemon-latency-logger.c:325 | ||
5959 | msgid "Daemon to log latency values of connections to neighbours" | ||
5960 | msgstr "Демон за дневничење вредности кашњења веза са суседима" | ||
5961 | |||
5962 | #: src/testbed/gnunet-daemon-testbed-blacklist.c:264 | ||
5963 | msgid "Daemon to restrict incoming transport layer connections during testbed deployments" | ||
5964 | msgstr "Демон за ограничење долазних веза слоја преноса за време примене пробног места" | ||
5965 | |||
5966 | #: src/testbed/gnunet-daemon-testbed-underlay.c:235 src/testing/list-keys.c:50 | ||
5967 | #: src/testing/testing.c:293 src/util/gnunet-ecc.c:217 | ||
5968 | #, c-format | ||
5969 | msgid "Incorrect hostkey file format: %s\n" | ||
5970 | msgstr "Нетачан формат датотеке кључа домаћина: %s\n" | ||
5971 | |||
5972 | #: src/testbed/gnunet-daemon-testbed-underlay.c:474 | ||
5973 | msgid "Daemon to restrict underlay network in testbed deployments" | ||
5974 | msgstr "Демон за ограничење основне мреже у применама пробног места" | ||
5975 | |||
5976 | #: src/testbed/gnunet-service-testbed_cpustatus.c:730 | ||
5977 | #, c-format | ||
5978 | msgid "Cannot open %s for writing load statistics. Not logging load statistics\n" | ||
5979 | msgstr "Не могу да отворим „%s“ за писање статистике учитавања. Не записујем у дневник статистику учитавања\n" | ||
5980 | |||
5981 | #: src/testbed/gnunet-service-testbed_peers.c:1015 | ||
5982 | msgid "Misconfiguration (can't connect to the ARM service)" | ||
5983 | msgstr "Лоше подешавање (не могу да се повежем на АУР услугу)" | ||
5984 | |||
5985 | #: src/testbed/gnunet-service-testbed_peers.c:1021 | ||
5986 | msgid "Request doesn't fit into a message" | ||
5987 | msgstr "Захтев не стаје у поруку" | ||
5988 | |||
5989 | #: src/testbed/gnunet-service-testbed_peers.c:1059 | ||
5990 | #, c-format | ||
5991 | msgid "%s service can't be started because ARM is shutting down" | ||
5992 | msgstr "„%s“ услуга се не може покренути јер се АУР гаси" | ||
5993 | |||
5994 | #: src/testbed/gnunet_testbed_mpi_spawn.c:125 | ||
5995 | msgid "Waiting for child to exit.\n" | ||
5996 | msgstr "Чекам на пород да изађе.\n" | ||
5997 | |||
5998 | #: src/testbed/gnunet_testbed_mpi_spawn.c:247 | ||
5999 | #, c-format | ||
6000 | msgid "Spawning process `%s'\n" | ||
6001 | msgstr "Умножавам процес „%s“\n" | ||
6002 | |||
6003 | #: src/testbed/gnunet-testbed-profiler.c:267 | ||
6004 | #, c-format | ||
6005 | msgid "Exiting as the number of peers is %u\n" | ||
6006 | msgstr "Излазим јер је број парњака %u\n" | ||
6007 | |||
6008 | #: src/testbed/gnunet-testbed-profiler.c:296 | ||
6009 | msgid "tolerate COUNT number of continious timeout failures" | ||
6010 | msgstr "толерише УКУПНО број непрекидних неуспеха истека времена" | ||
6011 | |||
6012 | #: src/testbed/gnunet-testbed-profiler.c:299 | ||
6013 | msgid "run profiler in non-interactive mode where upon testbed setup the profiler does not wait for a keystroke but continues to run until a termination signal is received" | ||
6014 | msgstr "покреће профајлера у не-дејственом режиму у коме над поставком пробног места профајлер не чека на притисак тастера већ наставља да ради све док се не прими сигнал окончања" | ||
6015 | |||
6016 | #: src/testbed/testbed_api_hosts.c:415 | ||
6017 | #, c-format | ||
6018 | msgid "Hosts file %s not found\n" | ||
6019 | msgstr "Нисам нашао датотеку домаћина „%s“\n" | ||
6020 | |||
6021 | #: src/testbed/testbed_api_hosts.c:423 | ||
6022 | #, c-format | ||
6023 | msgid "Hosts file %s has no data\n" | ||
6024 | msgstr "Датотека домаћина „%s“ нема података\n" | ||
6025 | |||
6026 | #: src/testbed/testbed_api_hosts.c:430 | ||
6027 | #, c-format | ||
6028 | msgid "Hosts file %s cannot be read\n" | ||
6029 | msgstr "Не могу да прочитам датотеку домаћина „%s“\n" | ||
6030 | |||
6031 | #: src/testbed/testbed_api_hosts.c:570 | ||
6032 | #, c-format | ||
6033 | msgid "The function %s is only available when compiled with (--with-ll)\n" | ||
6034 | msgstr "Функција „%s“ је доступна само када је преведена са (--with-ll)\n" | ||
6035 | |||
6036 | #: src/testbed/testbed_api_hosts.c:1586 | ||
6037 | #, c-format | ||
6038 | msgid "Adding host %u failed with error: %s\n" | ||
6039 | msgstr "Додавање домаћина %u није успело са грешком: %s\n" | ||
6040 | |||
6041 | #: src/testbed/testbed_api_testbed.c:819 | ||
6042 | msgid "Linking controllers failed. Exiting" | ||
6043 | msgstr "Повезивање контролера није успело. Излазим" | ||
6044 | |||
6045 | #: src/testbed/testbed_api_testbed.c:988 | ||
6046 | #, c-format | ||
6047 | msgid "Host registration failed for a host. Error: %s\n" | ||
6048 | msgstr "Регистрација домаћина није успела за домаћина. Грешка: %s\n" | ||
6049 | |||
6050 | #: src/testbed/testbed_api_testbed.c:1054 | ||
6051 | msgid "Controller crash detected. Shutting down.\n" | ||
6052 | msgstr "Урушавање контролера је откривено. Гасим се.\n" | ||
6053 | |||
6054 | #: src/testbed/testbed_api_testbed.c:1143 | ||
6055 | #, c-format | ||
6056 | msgid "Host %s cannot start testbed\n" | ||
6057 | msgstr "Домаћин „%s“ не може да покрене пробно место\n" | ||
6058 | |||
6059 | #: src/testbed/testbed_api_testbed.c:1147 | ||
6060 | msgid "Testbed cannot be started on localhost\n" | ||
6061 | msgstr "Пробно место се не може покренути на локалном домаћину\n" | ||
6062 | |||
6063 | #: src/testbed/testbed_api_testbed.c:1185 | ||
6064 | msgid "Cannot start the master controller" | ||
6065 | msgstr "Не могу да покренем главног контролора" | ||
6066 | |||
6067 | #: src/testbed/testbed_api_testbed.c:1203 | ||
6068 | msgid "Shutting down testbed due to timeout while setup.\n" | ||
6069 | msgstr "Гасим пробно место због истека времена приликом подешавања.\n" | ||
6070 | |||
6071 | #: src/testbed/testbed_api_testbed.c:1263 | ||
6072 | msgid "No hosts loaded from LoadLeveler. Need at least one host\n" | ||
6073 | msgstr "Ниједан домаћин није учитан из „LoadLeveler“-а. Потребан је барем један домаћин\n" | ||
6074 | |||
6075 | #: src/testbed/testbed_api_testbed.c:1275 | ||
6076 | msgid "No hosts loaded. Need at least one host\n" | ||
6077 | msgstr "Ниједан домаћин није учитан. Потребан је барем један домаћин\n" | ||
6078 | |||
6079 | #: src/testbed/testbed_api_testbed.c:1299 | ||
6080 | msgid "Specified topology must be supported by testbed" | ||
6081 | msgstr "Наведени размештај мора бити подржан пробним местом" | ||
6082 | |||
6083 | #: src/testbed/testbed_api_testbed.c:1349 | ||
6084 | #, c-format | ||
6085 | msgid "Maximum number of edges a peer can have in a scale free topology cannot be more than %u. Given `%s = %llu'" | ||
6086 | msgstr "Највећи број ивица које парњак може имати у слободном размештају лествице не може бити већи од %u. Дато је „%s = %llu“" | ||
6087 | |||
6088 | #: src/testbed/testbed_api_testbed.c:1365 | ||
6089 | #, c-format | ||
6090 | msgid "The number of edges that can established when adding a new node to scale free topology cannot be more than %u. Given `%s = %llu'" | ||
6091 | msgstr "Број ивица које се могу успоставити приликом додавања новог чвора у слободном размештају лествице не може бити већи од %u. Дато је „%s = %llu“" | ||
6092 | |||
6093 | #: src/testbed/testbed_api_topology.c:960 | ||
6094 | #, c-format | ||
6095 | msgid "Topology file %s not found\n" | ||
6096 | msgstr "Нисам нашао датотеку размештаја „%s“\n" | ||
6097 | |||
6098 | #: src/testbed/testbed_api_topology.c:966 | ||
6099 | #, c-format | ||
6100 | msgid "Topology file %s has no data\n" | ||
6101 | msgstr "Датотека размештаја „%s“ нема података\n" | ||
6102 | |||
6103 | #: src/testbed/testbed_api_topology.c:973 | ||
6104 | #, c-format | ||
6105 | msgid "Topology file %s cannot be read\n" | ||
6106 | msgstr "Не могу да прочитам датотеку размештаја „%s“\n" | ||
6107 | |||
6108 | #: src/testbed/testbed_api_topology.c:995 | ||
6109 | #, c-format | ||
6110 | msgid "Failed to read peer index from toology file: %s" | ||
6111 | msgstr "Нисам успео да прочитам индекс парњака из датотеке размештаја: %s" | ||
6112 | |||
6113 | #: src/testbed/testbed_api_topology.c:1004 | ||
6114 | #: src/testbed/testbed_api_topology.c:1028 | ||
6115 | #, c-format | ||
6116 | msgid "Value in given topology file: %s out of range\n" | ||
6117 | msgstr "Вредност у датој датотеци размештаја: „%s“ је ван опсега\n" | ||
6118 | |||
6119 | #: src/testbed/testbed_api_topology.c:1010 | ||
6120 | #: src/testbed/testbed_api_topology.c:1034 | ||
6121 | #, c-format | ||
6122 | msgid "Failed to read peer index from topology file: %s" | ||
6123 | msgstr "Нисам успео да прочитам индекс парњака из датотеке размештаја: %s" | ||
6124 | |||
6125 | #: src/testbed/testbed_api_topology.c:1016 | ||
6126 | #: src/testbed/testbed_api_topology.c:1040 | ||
6127 | msgid "Topology file needs more peers than given ones\n" | ||
6128 | msgstr "Датотеци размештаја је потребно више парњака од једног датог\n" | ||
6129 | |||
6130 | #: src/testbed/testbed_api_topology.c:1074 | ||
6131 | #, c-format | ||
6132 | msgid "Ignoring to connect peer %u to peer %u\n" | ||
6133 | msgstr "Занемарујем да повежем парњака %u са парњаком %u\n" | ||
6134 | |||
6135 | #: src/testing/gnunet-testing.c:173 | ||
6136 | #, c-format | ||
6137 | msgid "Could not extract hostkey %u (offset too large?)\n" | ||
6138 | msgstr "Не могу да извучем кључ домаћина %u (померај је превелик?)\n" | ||
6139 | |||
6140 | #: src/testing/gnunet-testing.c:258 | ||
6141 | #, c-format | ||
6142 | msgid "Unknown command, use 'q' to quit or 'r' to restart peer\n" | ||
6143 | msgstr "Непозната наредба, користите „q“ да прекинете или „r“ да поново покренете парњака\n" | ||
6144 | |||
6145 | #: src/testing/gnunet-testing.c:355 | ||
6146 | msgid "create unique configuration files" | ||
6147 | msgstr "ствара јединствене датотеке подешавања" | ||
6148 | |||
6149 | #: src/testing/gnunet-testing.c:357 | ||
6150 | msgid "extract hostkey file from pre-computed hostkey list" | ||
6151 | msgstr "извлачи датотеку кључа доамћина из унапред прорачунатог списка кључа домаћина" | ||
6152 | |||
6153 | #: src/testing/gnunet-testing.c:359 | ||
6154 | msgid "number of unique configuration files to create, or number of the hostkey to extract" | ||
6155 | msgstr "број јединствених датотека подешавања за стварање, или број кључа домаћина за извлачење" | ||
6156 | |||
6157 | #: src/testing/gnunet-testing.c:361 | ||
6158 | msgid "configuration template" | ||
6159 | msgstr "шаблон подешавања" | ||
6160 | |||
6161 | #: src/testing/gnunet-testing.c:363 | ||
6162 | msgid "run the given service, wait on stdin for 'r' (restart) or 'q' (quit)" | ||
6163 | msgstr "покреће дату услугу, чека на стандардном улазу за „r“ (поновно покретање) или „q“ (излази)" | ||
6164 | |||
6165 | #: src/testing/gnunet-testing.c:376 | ||
6166 | msgid "Command line tool to access the testing library" | ||
6167 | msgstr "Алат линије наредби за приезуп библиотеци тестирања" | ||
6168 | |||
6169 | #: src/testing/list-keys.c:90 | ||
6170 | msgid "list COUNT number of keys" | ||
6171 | msgstr "исписује УКУПНОСТ број парњака" | ||
6172 | |||
6173 | #: src/testing/list-keys.c:93 | ||
6174 | msgid "skip COUNT number of keys in the beginning" | ||
6175 | msgstr "прескаче УКУПНОСТ број кључева на почетку" | ||
6176 | |||
6177 | #: src/testing/testing.c:277 | ||
6178 | #, c-format | ||
6179 | msgid "Hostkeys file not found: %s\n" | ||
6180 | msgstr "Нисам нашао датотеку кључева домаћина: %s\n" | ||
6181 | |||
6182 | #: src/testing/testing.c:718 | ||
6183 | #, c-format | ||
6184 | msgid "Key number %u does not exist\n" | ||
6185 | msgstr "Број кључа %u не постоји\n" | ||
6186 | |||
6187 | #: src/testing/testing.c:1157 | ||
6188 | #, c-format | ||
6189 | msgid "You attempted to create a testbed with more than %u hosts. Please precompute more hostkeys first.\n" | ||
6190 | msgstr "Покушали сте да направите пробно место са више од %u домаћина. Прво пре свега израчунајте више кључева домаћина.\n" | ||
6191 | |||
6192 | #: src/testing/testing.c:1166 | ||
6193 | #, c-format | ||
6194 | msgid "Failed to initialize hostkey for peer %u\n" | ||
6195 | msgstr "Нисам успео да покренем кључ домаћина за парњака %u\n" | ||
6196 | |||
6197 | #: src/testing/testing.c:1176 | ||
6198 | msgid "PRIVATE_KEY option in PEER section missing in configuration\n" | ||
6199 | msgstr "опција „PRIVATE_KEY“ у одељку „PEER“ недостаје у подешавањима\n" | ||
6200 | |||
6201 | #: src/testing/testing.c:1189 | ||
6202 | msgid "Failed to create configuration for peer (not enough free ports?)\n" | ||
6203 | msgstr "Нисам успео да направим подешавање за парњака (нема довољно слободних прикључника?)\n" | ||
6204 | |||
6205 | #: src/testing/testing.c:1203 | ||
6206 | #, c-format | ||
6207 | msgid "Cannot open hostkey file `%s': %s\n" | ||
6208 | msgstr "Не могу да отворим датотеку кључа домаћина „%s“: %s\n" | ||
6209 | |||
6210 | #: src/testing/testing.c:1215 | ||
6211 | #, c-format | ||
6212 | msgid "Failed to write hostkey file for peer %u: %s\n" | ||
6213 | msgstr "Нисам успео да запишем датотеку кључа домаћина за парњака %u: %s\n" | ||
6214 | |||
6215 | #: src/testing/testing.c:1240 | ||
6216 | #, c-format | ||
6217 | msgid "Failed to write configuration file `%s' for peer %u: %s\n" | ||
6218 | msgstr "Нисам успео да запишем датотеку подешавања „%s“ за парњака %u: %s\n" | ||
6219 | |||
6220 | #: src/testing/testing.c:1342 | ||
6221 | #, c-format | ||
6222 | msgid "Failed to start `%s': %s\n" | ||
6223 | msgstr "Нисам успео да покренем „%s“: %s\n" | ||
6224 | |||
6225 | #: src/testing/testing.c:1706 | ||
6226 | #, c-format | ||
6227 | msgid "Failed to load configuration from %s\n" | ||
6228 | msgstr "Нисам успео да учитам подешавање за „%s“\n" | ||
6229 | |||
6230 | #: src/topology/friends.c:100 | ||
6231 | #, c-format | ||
6232 | msgid "Syntax error in FRIENDS file at offset %llu, skipping bytes `%.*s'.\n" | ||
6233 | msgstr "Грешка синтаксе у датотеци „FRIENDS“ на померају %llu, прескачем бајтове „%.*s“.\n" | ||
6234 | |||
6235 | #: src/topology/friends.c:154 | ||
6236 | #, c-format | ||
6237 | msgid "Directory for file `%s' does not seem to be writable.\n" | ||
6238 | msgstr "Директоријум за датотеку „%s“ не изгледа да је уписив.\n" | ||
6239 | |||
6240 | #: src/topology/gnunet-daemon-topology.c:255 | ||
6241 | msgid "# peers blacklisted" | ||
6242 | msgstr "# парњаци су стављени на списак забрана" | ||
6243 | |||
6244 | #: src/topology/gnunet-daemon-topology.c:388 | ||
6245 | msgid "# connect requests issued to transport" | ||
6246 | msgstr "# захтеви везе су издати преносу" | ||
6247 | |||
6248 | #: src/topology/gnunet-daemon-topology.c:728 | ||
6249 | #: src/topology/gnunet-daemon-topology.c:813 | ||
6250 | msgid "# friends connected" | ||
6251 | msgstr "# пријатељи су повезани" | ||
6252 | |||
6253 | #: src/topology/gnunet-daemon-topology.c:993 | ||
6254 | msgid "Failed to connect to core service, can not manage topology!\n" | ||
6255 | msgstr "Нисам успео да се повежем са услугом језгра, не могу да радим размештајем!\n" | ||
6256 | |||
6257 | #: src/topology/gnunet-daemon-topology.c:1022 | ||
6258 | #, c-format | ||
6259 | msgid "Found myself `%s' in friend list (useless, ignored)\n" | ||
6260 | msgstr "Нађох себе „%s“ на списку пријатеља (некорисно, занемарујем)\n" | ||
6261 | |||
6262 | #: src/topology/gnunet-daemon-topology.c:1029 | ||
6263 | #, c-format | ||
6264 | msgid "Found friend `%s' in configuration\n" | ||
6265 | msgstr "Нађох пријатеља „%s“ у подешавањима\n" | ||
6266 | |||
6267 | #: src/topology/gnunet-daemon-topology.c:1050 | ||
6268 | msgid "Encountered errors parsing friends list!\n" | ||
6269 | msgstr "Наиђох на грешке током обраде списка пријатеља!\n" | ||
6270 | |||
6271 | #: src/topology/gnunet-daemon-topology.c:1052 | ||
6272 | msgid "# friends in configuration" | ||
6273 | msgstr "# пријатељи у подешавањима" | ||
6274 | |||
6275 | #: src/topology/gnunet-daemon-topology.c:1057 | ||
6276 | msgid "Fewer friends specified than required by minimum friend count. Will only connect to friends.\n" | ||
6277 | msgstr "Наведено је мање пријатеља него што се захтева најмањим бројем пријатеља. Повезаћу се само са пријатељима.\n" | ||
6278 | |||
6279 | #: src/topology/gnunet-daemon-topology.c:1063 | ||
6280 | msgid "More friendly connections required than target total number of connections.\n" | ||
6281 | msgstr "Захтевано је више пријатељских веза него циљни укупан број веза.\n" | ||
6282 | |||
6283 | #: src/topology/gnunet-daemon-topology.c:1094 | ||
6284 | msgid "# HELLO messages received" | ||
6285 | msgstr "# „HELLO“ поруке су примљене" | ||
6286 | |||
6287 | #: src/topology/gnunet-daemon-topology.c:1151 | ||
6288 | msgid "# HELLO messages gossipped" | ||
6289 | msgstr "# „HELLO“ поруке су наклопљене" | ||
6290 | |||
6291 | #: src/topology/gnunet-daemon-topology.c:1290 | ||
6292 | msgid "GNUnet topology control (maintaining P2P mesh and F2F constraints)" | ||
6293 | msgstr "Контрола ГНУнет размештаја (задржавајући П2П меш и Ф2Ф ограничења)" | ||
6294 | |||
6295 | #: src/transport/gnunet-service-transport_blacklist.c:271 | ||
6296 | #, c-format | ||
6297 | msgid "Adding blacklisting entry for peer `%s'\n" | ||
6298 | msgstr "Додајем унос списка забрана за парњака „%s“\n" | ||
6299 | |||
6300 | #: src/transport/gnunet-service-transport_blacklist.c:279 | ||
6301 | #, c-format | ||
6302 | msgid "Adding blacklisting entry for peer `%s':`%s'\n" | ||
6303 | msgstr "Додајем унос списка забрана за парњака „%s“:„%s“\n" | ||
6304 | |||
6305 | #: src/transport/gnunet-service-transport_blacklist.c:464 | ||
6306 | #: src/transport/gnunet-service-transport_blacklist.c:745 | ||
6307 | msgid "# disconnects due to blacklist" | ||
6308 | msgstr "# прекиди везе због списка забрана" | ||
6309 | |||
6310 | #: src/transport/gnunet-service-transport.c:220 | ||
6311 | msgid "# bytes payload discarded due to not connected peer" | ||
6312 | msgstr "# бајтови утовара су одбачени због не повезаног парњака" | ||
6313 | |||
6314 | #: src/transport/gnunet-service-transport.c:424 | ||
6315 | msgid "# bytes total received" | ||
6316 | msgstr "# укупно бајтова је примљено" | ||
6317 | |||
6318 | #: src/transport/gnunet-service-transport.c:515 | ||
6319 | msgid "# bytes payload received" | ||
6320 | msgstr "# бајтови утовара су примљени" | ||
6321 | |||
6322 | #: src/transport/gnunet-service-transport.c:686 | ||
6323 | #, c-format | ||
6324 | msgid "Could not obtain a valid network for `%s' %s (%s)\n" | ||
6325 | msgstr "Не могу да добијем исправну везу за „%s“ %s (%s)\n" | ||
6326 | |||
6327 | #: src/transport/gnunet-service-transport.c:733 | ||
6328 | #, c-format | ||
6329 | msgid "Address or session unknown: failed to update properties for peer `%s' plugin `%s' address `%s' session %p\n" | ||
6330 | msgstr "Адреса или сесија је непозната: нисам успео да својства за парњака „%s“ прикључак „%s“ адресу „%s“ сесију %p\n" | ||
6331 | |||
6332 | #: src/transport/gnunet-service-transport.c:1084 | ||
6333 | msgid "Transport service is lacking key configuration settings. Exiting.\n" | ||
6334 | msgstr "Услузи преноса недостају поставке подешавања кључа. Излазим.\n" | ||
6335 | |||
6336 | #: src/transport/gnunet-service-transport_clients.c:432 | ||
6337 | #, c-format | ||
6338 | msgid "Dropping message of type %u and size %u, have %u/%u messages pending\n" | ||
6339 | msgstr "Одбацујем поруку врсте %u и величине %u, има %u/%u порука на чекању\n" | ||
6340 | |||
6341 | #: src/transport/gnunet-service-transport_clients.c:439 | ||
6342 | msgid "# messages dropped due to slow client" | ||
6343 | msgstr "# поруке су одбачене услед спорог клијента" | ||
6344 | |||
6345 | #: src/transport/gnunet-service-transport_clients.c:596 | ||
6346 | #, c-format | ||
6347 | msgid "Rejecting control connection from peer `%s', which is not me!\n" | ||
6348 | msgstr "Одбацујем контролну везу од парњака „%s“, а то нисам ја!\n" | ||
6349 | |||
6350 | #: src/transport/gnunet-service-transport_clients.c:737 | ||
6351 | msgid "# bytes payload dropped (other peer was not connected)" | ||
6352 | msgstr "# утовар бајтова је одбачен (други парњак није повезан)" | ||
6353 | |||
6354 | #: src/transport/gnunet-service-transport_clients.c:770 | ||
6355 | #, c-format | ||
6356 | msgid "Blacklist refuses connection attempt to peer `%s'\n" | ||
6357 | msgstr "Списак забрана одбацује покушај повезивања са парњаком „%s“\n" | ||
6358 | |||
6359 | #: src/transport/gnunet-service-transport_clients.c:776 | ||
6360 | #, c-format | ||
6361 | msgid "Blacklist allows connection attempt to peer `%s'\n" | ||
6362 | msgstr "Списак забрана дозвољава покушај повезивања са парњаком „%s“\n" | ||
6363 | |||
6364 | #: src/transport/gnunet-service-transport_clients.c:801 | ||
6365 | msgid "# REQUEST CONNECT messages received" | ||
6366 | msgstr "# ЗАХТЕВАЈ ПОВЕЖИ_СЕ поруке су примљене" | ||
6367 | |||
6368 | #: src/transport/gnunet-service-transport_clients.c:815 | ||
6369 | #, c-format | ||
6370 | msgid "Received a request connect message for peer `%s'\n" | ||
6371 | msgstr "Примих поруку захтева повезивања за парњака „%s“\n" | ||
6372 | |||
6373 | #: src/transport/gnunet-service-transport_clients.c:826 | ||
6374 | msgid "# REQUEST DISCONNECT messages received" | ||
6375 | msgstr "# ЗАХТЕВАЈ ПРЕКИНИ_ВЕЗУ поруке су примљене" | ||
6376 | |||
6377 | #: src/transport/gnunet-service-transport_clients.c:840 | ||
6378 | #, c-format | ||
6379 | msgid "Received a request disconnect message for peer `%s'\n" | ||
6380 | msgstr "Примих поруку захтева прекида везе за парњака „%s“\n" | ||
6381 | |||
6382 | #: src/transport/gnunet-service-transport_hello.c:181 | ||
6383 | msgid "# refreshed my HELLO" | ||
6384 | msgstr "# освежих мој „HELLO“" | ||
6385 | |||
6386 | #: src/transport/gnunet-service-transport_neighbours.c:1095 | ||
6387 | msgid "# DISCONNECT messages sent" | ||
6388 | msgstr "# ПРЕКИНИ_ВЕЗУ поруке су послате" | ||
6389 | |||
6390 | #: src/transport/gnunet-service-transport_neighbours.c:1220 | ||
6391 | #: src/transport/gnunet-service-transport_neighbours.c:1629 | ||
6392 | msgid "# bytes in message queue for other peers" | ||
6393 | msgstr "# бајтови у реду поруке за друге парњаке" | ||
6394 | |||
6395 | #: src/transport/gnunet-service-transport_neighbours.c:1225 | ||
6396 | msgid "# messages transmitted to other peers" | ||
6397 | msgstr "# поруке су пренесене другим парњацима" | ||
6398 | |||
6399 | #: src/transport/gnunet-service-transport_neighbours.c:1230 | ||
6400 | msgid "# transmission failures for messages to other peers" | ||
6401 | msgstr "# неуспеси преноса за поруке ка другим парњацима" | ||
6402 | |||
6403 | #: src/transport/gnunet-service-transport_neighbours.c:1287 | ||
6404 | msgid "# messages timed out while in transport queue" | ||
6405 | msgstr "# истекло је време порукама док су у реду преноса" | ||
6406 | |||
6407 | #: src/transport/gnunet-service-transport_neighbours.c:1343 | ||
6408 | msgid "# keepalives sent" | ||
6409 | msgstr "# одржавања у раду су послата" | ||
6410 | |||
6411 | #: src/transport/gnunet-service-transport_neighbours.c:1376 | ||
6412 | msgid "# KEEPALIVE messages discarded (peer unknown)" | ||
6413 | msgstr "# ОДРЖИ_У_РАДУ поруке су одбачене (парњак није познат)" | ||
6414 | |||
6415 | #: src/transport/gnunet-service-transport_neighbours.c:1384 | ||
6416 | msgid "# KEEPALIVE messages discarded (no session)" | ||
6417 | msgstr "# ОДРЖИ_У_РАДУ поруке су одбачене (нема сесије)" | ||
6418 | |||
6419 | #: src/transport/gnunet-service-transport_neighbours.c:1431 | ||
6420 | msgid "# KEEPALIVE_RESPONSE messages discarded (not connected)" | ||
6421 | msgstr "# ОДГОВОР_ОДРЖИ_У_РАДУ поруке су одбачене (нисам повезан)" | ||
6422 | |||
6423 | #: src/transport/gnunet-service-transport_neighbours.c:1440 | ||
6424 | msgid "# KEEPALIVE_RESPONSE messages discarded (not expected)" | ||
6425 | msgstr "# ОДГОВОР_ОДРЖИ_У_РАДУ поруке су одбачене (није очекиван)" | ||
6426 | |||
6427 | #: src/transport/gnunet-service-transport_neighbours.c:1448 | ||
6428 | msgid "# KEEPALIVE_RESPONSE messages discarded (address changed)" | ||
6429 | msgstr "# ОДГОВОР_ОДРЖИ_У_РАДУ поруке су одбачене (адреса је измењена)" | ||
6430 | |||
6431 | #: src/transport/gnunet-service-transport_neighbours.c:1456 | ||
6432 | msgid "# KEEPALIVE_RESPONSE messages discarded (wrong nonce)" | ||
6433 | msgstr "# ОДГОВОР_ОДРЖИ_У_РАДУ поруке су одбачене (погрешна тренутност)" | ||
6434 | |||
6435 | #: src/transport/gnunet-service-transport_neighbours.c:1534 | ||
6436 | msgid "# messages discarded due to lack of neighbour record" | ||
6437 | msgstr "# поруке су одбачене услед недостатка записа суседа" | ||
6438 | |||
6439 | #: src/transport/gnunet-service-transport_neighbours.c:1568 | ||
6440 | msgid "# bandwidth quota violations by other peers" | ||
6441 | msgstr "# повређивање квоте пропусног опсега од стране других парњака" | ||
6442 | |||
6443 | #: src/transport/gnunet-service-transport_neighbours.c:1584 | ||
6444 | msgid "# ms throttling suggested" | ||
6445 | msgstr "# ms пригушење се саветује" | ||
6446 | |||
6447 | #: src/transport/gnunet-service-transport_neighbours.c:1678 | ||
6448 | #, c-format | ||
6449 | msgid "Failed to send CONNECT message to peer `%s' using address `%s' session %p\n" | ||
6450 | msgstr "Нисам успео да пошаљем поруку ПОВЕЖИ_СЕ парњаку „%s“ користећи адресу „%s“ сесије %p\n" | ||
6451 | |||
6452 | #: src/transport/gnunet-service-transport_neighbours.c:1705 | ||
6453 | msgid "# Failed attempts to switch addresses (failed to send CONNECT CONT)" | ||
6454 | msgstr "# Нису успели покушаји за пребацивање адреса (нисам успео да пошаљем УКУПНО ПОВЕЖИ_СЕ)" | ||
6455 | |||
6456 | #: src/transport/gnunet-service-transport_neighbours.c:1751 | ||
6457 | msgid "# SESSION_CONNECT messages sent" | ||
6458 | msgstr "# ПОВЕЗИВАЊЕ_СЕСИЈЕ поруке су послате" | ||
6459 | |||
6460 | #: src/transport/gnunet-service-transport_neighbours.c:1767 | ||
6461 | #, c-format | ||
6462 | msgid "Failed to transmit CONNECT message via plugin to %s\n" | ||
6463 | msgstr "Нисам успео да пренесем поруку ПОВЕЖИ_СЕ путем прикључка ка „%s“\n" | ||
6464 | |||
6465 | #: src/transport/gnunet-service-transport_neighbours.c:1794 | ||
6466 | msgid "# Failed attempts to switch addresses (failed to send CONNECT)" | ||
6467 | msgstr "# Нису успели покушаји за пребацивање адреса (нисам успео да пошаљем ПОВЕЖИ_СЕ)" | ||
6468 | |||
6469 | #: src/transport/gnunet-service-transport_neighbours.c:1844 | ||
6470 | #, c-format | ||
6471 | msgid "Failed to send CONNECT_ACK message to peer `%s' using address `%s' session %p\n" | ||
6472 | msgstr "Нисам успео да пошаљем поруку ПОВЕЖИ_АЦК парњаку „%s“ користећи адресу „%s“ сесије %p\n" | ||
6473 | |||
6474 | #: src/transport/gnunet-service-transport_neighbours.c:1899 | ||
6475 | msgid "# CONNECT_ACK messages sent" | ||
6476 | msgstr "# ПОВЕЖИ_АЦК поруке су послате" | ||
6477 | |||
6478 | #: src/transport/gnunet-service-transport_neighbours.c:1914 | ||
6479 | #, c-format | ||
6480 | msgid "Failed to transmit CONNECT_ACK message via plugin to %s\n" | ||
6481 | msgstr "Нисам успео да пренесем поруку ПОВЕЖИ_АЦК путем прикључка ка „%s“\n" | ||
6482 | |||
6483 | #: src/transport/gnunet-service-transport_neighbours.c:2192 | ||
6484 | #, c-format | ||
6485 | msgid "Blacklisting disapproved to connect to peer `%s'\n" | ||
6486 | msgstr "Списак забрана није одобрио повезивање са парњаком „%s“\n" | ||
6487 | |||
6488 | #: src/transport/gnunet-service-transport_neighbours.c:2312 | ||
6489 | msgid "# CONNECT messages received" | ||
6490 | msgstr "# ПОВЕЖИ_СЕ поруке су примљене" | ||
6491 | |||
6492 | #: src/transport/gnunet-service-transport_neighbours.c:2317 | ||
6493 | #, c-format | ||
6494 | msgid "CONNECT request from peer `%s' ignored due impending shutdown\n" | ||
6495 | msgstr "ПОВЕЖИ_СЕ захтев са парњака „%s“ је занемарен због неминовног гашења\n" | ||
6496 | |||
6497 | #: src/transport/gnunet-service-transport_neighbours.c:2590 | ||
6498 | msgid "# Attempts to switch addresses" | ||
6499 | msgstr "# Покушаји за пребацивање адреса" | ||
6500 | |||
6501 | #: src/transport/gnunet-service-transport_neighbours.c:3012 | ||
6502 | msgid "# Failed attempts to switch addresses (no response)" | ||
6503 | msgstr "# Нису успели покушаји за пребацивање адреса (нема одговора)" | ||
6504 | |||
6505 | #: src/transport/gnunet-service-transport_neighbours.c:3107 | ||
6506 | msgid "# CONNECT_ACK messages received" | ||
6507 | msgstr "# ПОВЕЖИ_АЦК поруке су примљене" | ||
6508 | |||
6509 | #: src/transport/gnunet-service-transport_neighbours.c:3115 | ||
6510 | msgid "# unexpected CONNECT_ACK messages (no peer)" | ||
6511 | msgstr "# неочекиване ПОВЕЖИ_АЦК поруке (нема парњака)" | ||
6512 | |||
6513 | #: src/transport/gnunet-service-transport_neighbours.c:3129 | ||
6514 | #: src/transport/gnunet-service-transport_neighbours.c:3164 | ||
6515 | msgid "# unexpected CONNECT_ACK messages (not ready)" | ||
6516 | msgstr "# неочекиване ПОВЕЖИ_АЦК поруке (нису спремне)" | ||
6517 | |||
6518 | #: src/transport/gnunet-service-transport_neighbours.c:3176 | ||
6519 | msgid "# unexpected CONNECT_ACK messages (waiting on ATS)" | ||
6520 | msgstr "# неочекиване ПОВЕЖИ_АЦК поруке (чекам на АТС)" | ||
6521 | |||
6522 | #: src/transport/gnunet-service-transport_neighbours.c:3200 | ||
6523 | msgid "# Successful attempts to switch addresses" | ||
6524 | msgstr "# Покушаји за пребацивање адреса су успели" | ||
6525 | |||
6526 | #: src/transport/gnunet-service-transport_neighbours.c:3208 | ||
6527 | msgid "# unexpected CONNECT_ACK messages (disconnecting)" | ||
6528 | msgstr "# неочекиване ПОВЕЖИ_АЦК поруке (прекидам везу)" | ||
6529 | |||
6530 | #: src/transport/gnunet-service-transport_neighbours.c:3396 | ||
6531 | msgid "# SESSION_ACK messages received" | ||
6532 | msgstr "# поруке СЕСИЈА_АЦК су примљене" | ||
6533 | |||
6534 | #: src/transport/gnunet-service-transport_neighbours.c:3424 | ||
6535 | msgid "# unexpected SESSION_ACK messages" | ||
6536 | msgstr "# неочекиване СЕСИЈА_АЦК поруке" | ||
6537 | |||
6538 | #: src/transport/gnunet-service-transport_neighbours.c:3490 | ||
6539 | msgid "# SET QUOTA messages ignored (no such peer)" | ||
6540 | msgstr "# ПОСТАВИ КВОТУ поруке су занемарене (нема таквог парњака)" | ||
6541 | |||
6542 | #: src/transport/gnunet-service-transport_neighbours.c:3505 | ||
6543 | msgid "# disconnects due to quota of 0" | ||
6544 | msgstr "# прекиди везе због квоте 0" | ||
6545 | |||
6546 | #: src/transport/gnunet-service-transport_neighbours.c:3545 | ||
6547 | msgid "# disconnect messages ignored (malformed)" | ||
6548 | msgstr "# поруке прекида везе су занемарене(лоше су)" | ||
6549 | |||
6550 | #: src/transport/gnunet-service-transport_neighbours.c:3551 | ||
6551 | msgid "# DISCONNECT messages received" | ||
6552 | msgstr "# ПРЕКИНИ_ВЕЗУ поруке су примљене" | ||
6553 | |||
6554 | #: src/transport/gnunet-service-transport_neighbours.c:3560 | ||
6555 | msgid "# disconnect messages ignored (timestamp)" | ||
6556 | msgstr "# поруке прекида везе су занемарене(временска ознака)" | ||
6557 | |||
6558 | #: src/transport/gnunet-service-transport_neighbours.c:3687 | ||
6559 | msgid "# disconnected from peer upon explicit request" | ||
6560 | msgstr "# прекинута је веза са парњаком услед изричитог захтева" | ||
6561 | |||
6562 | #: src/transport/gnunet-service-transport_plugins.c:120 | ||
6563 | msgid "Transport service is lacking NEIGHBOUR_LIMIT option.\n" | ||
6564 | msgstr "Услузи преноса недостаје опција ОГРАНИЧЕЊЕ_СУСЕДА.\n" | ||
6565 | |||
6566 | #: src/transport/gnunet-service-transport_plugins.c:178 | ||
6567 | #: src/transport/gnunet-service-transport_plugins.c:186 | ||
6568 | #: src/transport/gnunet-service-transport_plugins.c:194 | ||
6569 | #: src/transport/gnunet-service-transport_plugins.c:202 | ||
6570 | #: src/transport/gnunet-service-transport_plugins.c:210 | ||
6571 | #: src/transport/gnunet-service-transport_plugins.c:218 | ||
6572 | #: src/transport/gnunet-service-transport_plugins.c:226 | ||
6573 | #: src/transport/gnunet-service-transport_plugins.c:234 | ||
6574 | #: src/transport/gnunet-service-transport_plugins.c:242 | ||
6575 | #: src/transport/gnunet-service-transport_plugins.c:250 | ||
6576 | #: src/transport/gnunet-service-transport_plugins.c:258 | ||
6577 | #, c-format | ||
6578 | msgid "Missing function `%s' in transport plugin for `%s'\n" | ||
6579 | msgstr "Недостаје функција „%s“ у прикључку преноса за „%s“\n" | ||
6580 | |||
6581 | #: src/transport/gnunet-service-transport_plugins.c:265 | ||
6582 | #, c-format | ||
6583 | msgid "Did not load plugin `%s' due to missing functions\n" | ||
6584 | msgstr "Не учитавам прикључак „%s“ услед недостајућих функција\n" | ||
6585 | |||
6586 | #: src/transport/gnunet-service-transport_validation.c:488 | ||
6587 | msgid "# address records discarded" | ||
6588 | msgstr "# записи адресе су одбачени" | ||
6589 | |||
6590 | #: src/transport/gnunet-service-transport_validation.c:558 | ||
6591 | #, c-format | ||
6592 | msgid "Not transmitting `%s' with `%s', message too big (%u bytes!). This should not happen.\n" | ||
6593 | msgstr "Не преносим „%s“ са „%s“, порука је превелика (%u бајта!). Ово није требало да се деси.\n" | ||
6594 | |||
6595 | #: src/transport/gnunet-service-transport_validation.c:616 | ||
6596 | msgid "# PING without HELLO messages sent" | ||
6597 | msgstr "# ПИНГ без „HELLO“ порука је послат" | ||
6598 | |||
6599 | #: src/transport/gnunet-service-transport_validation.c:722 | ||
6600 | msgid "# address revalidations started" | ||
6601 | msgstr "# поновно потврђивање адресе је започето" | ||
6602 | |||
6603 | #: src/transport/gnunet-service-transport_validation.c:1011 | ||
6604 | msgid "# PING message for different peer received" | ||
6605 | msgstr "# ПИНГ порука за различитог парњака је примљена" | ||
6606 | |||
6607 | #: src/transport/gnunet-service-transport_validation.c:1062 | ||
6608 | #, c-format | ||
6609 | msgid "Plugin `%s' not available, cannot confirm having this address\n" | ||
6610 | msgstr "Прикључак „%s“ није доступан, не могу да потврдим имајући ову адресу\n" | ||
6611 | |||
6612 | #: src/transport/gnunet-service-transport_validation.c:1072 | ||
6613 | msgid "# failed address checks during validation" | ||
6614 | msgstr "# неуспешне провере адресе за време потврђивања" | ||
6615 | |||
6616 | #: src/transport/gnunet-service-transport_validation.c:1075 | ||
6617 | #, c-format | ||
6618 | msgid "Address `%s' is not one of my addresses, not confirming PING\n" | ||
6619 | msgstr "Адреса „%s“ није једна од мојих адреса, не потврђујем ПИНГ\n" | ||
6620 | |||
6621 | #: src/transport/gnunet-service-transport_validation.c:1083 | ||
6622 | msgid "# successful address checks during validation" | ||
6623 | msgstr "# успешне провере адресе за време потврђивања" | ||
6624 | |||
6625 | #: src/transport/gnunet-service-transport_validation.c:1095 | ||
6626 | #, c-format | ||
6627 | msgid "Not confirming PING from peer `%s' with address `%s' since I cannot confirm having this address.\n" | ||
6628 | msgstr "Не потврђујем ПИНГ од парњака „%s“ са адресом „%s“ јер не могу да потврдим да имам ту адресу.\n" | ||
6629 | |||
6630 | #: src/transport/gnunet-service-transport_validation.c:1103 | ||
6631 | #, c-format | ||
6632 | msgid "Received a PING message with validation bug from `%s'\n" | ||
6633 | msgstr "Примих ПИНГ поруку са грешком потврђивања са „%s“\n" | ||
6634 | |||
6635 | #: src/transport/gnunet-service-transport_validation.c:1157 | ||
6636 | #, c-format | ||
6637 | msgid "Failed to create PONG signature for peer `%s'\n" | ||
6638 | msgstr "Нисам успео да направим ПОНГ потпис за парњака „%s“\n" | ||
6639 | |||
6640 | #: src/transport/gnunet-service-transport_validation.c:1206 | ||
6641 | msgid "# PONGs unicast via reliable transport" | ||
6642 | msgstr "# једноодредишни пренос ПОНГ-ова путем поузданог преноса" | ||
6643 | |||
6644 | #: src/transport/gnunet-service-transport_validation.c:1215 | ||
6645 | msgid "# PONGs multicast to all available addresses" | ||
6646 | msgstr "# вишеодредишни пренос ПОНГ-ова ка свим доступним адресама" | ||
6647 | |||
6648 | #: src/transport/gnunet-service-transport_validation.c:1356 | ||
6649 | msgid "# PONGs dropped, no matching pending validation" | ||
6650 | msgstr "# ПОНГ-ови су одбачени, нема одговарајућих потврђивања на чекању" | ||
6651 | |||
6652 | #: src/transport/gnunet-service-transport_validation.c:1371 | ||
6653 | msgid "# PONGs dropped, signature expired" | ||
6654 | msgstr "# ПОНГ-ови су одбачени, потпис је истекао" | ||
6655 | |||
6656 | #: src/transport/gnunet-service-transport_validation.c:1493 | ||
6657 | #, c-format | ||
6658 | msgid "Validation received new %s message for peer `%s' with size %u\n" | ||
6659 | msgstr "Потврђивање је примило нову „%s“ поруку за парњака „%s“ са величином %u\n" | ||
6660 | |||
6661 | #: src/transport/gnunet-service-transport_validation.c:1500 | ||
6662 | #, c-format | ||
6663 | msgid "Adding `%s' without addresses for peer `%s'\n" | ||
6664 | msgstr "Додајем „%s“ без адреса за парњака „%s“\n" | ||
6665 | |||
6666 | #: src/transport/gnunet-transport.c:367 | ||
6667 | #, c-format | ||
6668 | msgid "Transmitted %llu bytes/s (%llu bytes in %s)\n" | ||
6669 | msgstr "Пренесох %llu бајта/сек (%llu бајта за %s)\n" | ||
6670 | |||
6671 | #: src/transport/gnunet-transport.c:375 | ||
6672 | #, c-format | ||
6673 | msgid "Received %llu bytes/s (%llu bytes in %s)\n" | ||
6674 | msgstr "Примих %llu бајта/сек (%llu бајта за %s)\n" | ||
6675 | |||
6676 | #: src/transport/gnunet-transport.c:415 | ||
6677 | #, c-format | ||
6678 | msgid "Failed to connect to `%s'\n" | ||
6679 | msgstr "Нисам успео да се повежем на „%s“\n" | ||
6680 | |||
6681 | #: src/transport/gnunet-transport.c:428 | ||
6682 | #, c-format | ||
6683 | msgid "Failed to resolve address for peer `%s'\n" | ||
6684 | msgstr "Нисам успео да решим адресу за парњака „%s“\n" | ||
6685 | |||
6686 | #: src/transport/gnunet-transport.c:438 | ||
6687 | msgid "Failed to list connections, timeout occured\n" | ||
6688 | msgstr "Нисам успео да испишем везе, дошло је до истека времена\n" | ||
6689 | |||
6690 | #: src/transport/gnunet-transport.c:559 | ||
6691 | #, c-format | ||
6692 | msgid "" | ||
6693 | "Peer `%s' %s %s\n" | ||
6694 | "\t%s%s\n" | ||
6695 | "\t%s%s\n" | ||
6696 | "\t%s%s\n" | ||
6697 | msgstr "" | ||
6698 | "Парњак „%s“ %s %s\n" | ||
6699 | "\t%s%s\n" | ||
6700 | "\t%s%s\n" | ||
6701 | "\t%s%s\n" | ||
6702 | |||
6703 | #: src/transport/gnunet-transport.c:586 | ||
6704 | #, c-format | ||
6705 | msgid "Peer `%s' %s `%s' \n" | ||
6706 | msgstr "Парњак „%s“ %s „%s“ \n" | ||
6707 | |||
6708 | #: src/transport/gnunet-transport.c:712 | ||
6709 | msgid "No transport plugins configured, peer will never communicate\n" | ||
6710 | msgstr "Нису подешени прикључци преноса, парњак неће никада комуницирати\n" | ||
6711 | |||
6712 | #: src/transport/gnunet-transport.c:726 | ||
6713 | #, c-format | ||
6714 | msgid "No port configured for plugin `%s', cannot test it\n" | ||
6715 | msgstr "Није подешен прикључник за прикључак „%s“, не могу да га тестирам\n" | ||
6716 | |||
6717 | #: src/transport/gnunet-transport.c:789 | ||
6718 | #, c-format | ||
6719 | msgid "Transmitting %u bytes to %s\n" | ||
6720 | msgstr "Преносим %u бајта ка %s\n" | ||
6721 | |||
6722 | #: src/transport/gnunet-transport.c:810 | ||
6723 | #, c-format | ||
6724 | msgid "Successfully connected to `%s'\n" | ||
6725 | msgstr "Успешно је успостављена веза са „%s“\n" | ||
6726 | |||
6727 | #: src/transport/gnunet-transport.c:834 | ||
6728 | #, c-format | ||
6729 | msgid "Successfully connected to `%s', starting to send benchmark data in %u Kb blocks\n" | ||
6730 | msgstr "Успешно смо повезани са „%s“, почињем да шаљем податке оцењивања у блоковима од %u Kb\n" | ||
6731 | |||
6732 | #: src/transport/gnunet-transport.c:865 | ||
6733 | #, c-format | ||
6734 | msgid "Successfully disconnected from `%s'\n" | ||
6735 | msgstr "Успешно је прекинута веза са „%s“\n" | ||
6736 | |||
6737 | #: src/transport/gnunet-transport.c:888 | ||
6738 | #, c-format | ||
6739 | msgid "Disconnected from peer `%s' while benchmarking\n" | ||
6740 | msgstr "Прекинута је веза са парњаком „%s“ за време оцењивања\n" | ||
6741 | |||
6742 | #: src/transport/gnunet-transport.c:950 | ||
6743 | #, c-format | ||
6744 | msgid "Received %u bytes from %s\n" | ||
6745 | msgstr "Примих %u бајта од „%s“\n" | ||
6746 | |||
6747 | #: src/transport/gnunet-transport.c:975 | ||
6748 | #, c-format | ||
6749 | msgid "Peer `%s': %s %s in state `%s' until %s\n" | ||
6750 | msgstr "Парњак „%s“: %s %s у стању „%s“ све до %s\n" | ||
6751 | |||
6752 | #: src/transport/gnunet-transport.c:986 | ||
6753 | #, c-format | ||
6754 | msgid "Peer `%s': %s %s\n" | ||
6755 | msgstr "Парњак „%s“: %s %s\n" | ||
6756 | |||
6757 | #: src/transport/gnunet-transport.c:1197 src/transport/gnunet-transport.c:1222 | ||
6758 | msgid "Failed to send connect request to transport service\n" | ||
6759 | msgstr "Нисам успео да пошаљем захтев за повезивање са услугом преноса\n" | ||
6760 | |||
6761 | #: src/transport/gnunet-transport.c:1266 | ||
6762 | #, c-format | ||
6763 | msgid "Multiple operations given. Please choose only one operation: %s, %s, %s, %s, %s, %s\n" | ||
6764 | msgstr "Дато је више радњи. Изаберите само једну од: %s, %s, %s, %s, %s, %s\n" | ||
6765 | |||
6766 | #: src/transport/gnunet-transport.c:1274 | ||
6767 | #, c-format | ||
6768 | msgid "No operation given. Please choose one operation: %s, %s, %s, %s, %s, %s\n" | ||
6769 | msgstr "Није дата радња. Изаберите једну од: %s, %s, %s, %s, %s, %s\n" | ||
6770 | |||
6771 | #: src/transport/gnunet-transport.c:1293 src/transport/gnunet-transport.c:1323 | ||
6772 | #: src/transport/gnunet-transport.c:1353 src/transport/gnunet-transport.c:1376 | ||
6773 | #: src/transport/gnunet-transport.c:1419 | ||
6774 | msgid "Failed to connect to transport service\n" | ||
6775 | msgstr "Нисам успео да се повежем са услугом преноса\n" | ||
6776 | |||
6777 | #: src/transport/gnunet-transport.c:1302 src/transport/gnunet-transport.c:1332 | ||
6778 | #: src/transport/gnunet-transport.c:1362 | ||
6779 | msgid "Failed to send request to transport service\n" | ||
6780 | msgstr "Нисам успео да пошаљем захтев услузи преноса\n" | ||
6781 | |||
6782 | #: src/transport/gnunet-transport.c:1381 | ||
6783 | msgid "Starting to receive benchmark data\n" | ||
6784 | msgstr "Почињем да примам податке оцењивања\n" | ||
6785 | |||
6786 | #: src/transport/gnunet-transport.c:1465 | ||
6787 | msgid "print information for all peers (instead of only connected peers )" | ||
6788 | msgstr "исписује податке за све парњаке (уместо само о повезаним парњацима )" | ||
6789 | |||
6790 | #: src/transport/gnunet-transport.c:1468 | ||
6791 | msgid "measure how fast we are receiving data from all peers (until CTRL-C)" | ||
6792 | msgstr "мери колико брзо примамо податке са свих парњака (све до КТРЛ-Ц)" | ||
6793 | |||
6794 | #: src/transport/gnunet-transport.c:1471 | ||
6795 | msgid "connect to a peer" | ||
6796 | msgstr "повезује се са парњаком" | ||
6797 | |||
6798 | #: src/transport/gnunet-transport.c:1474 | ||
6799 | msgid "disconnect to a peer" | ||
6800 | msgstr "прекида везу са парњаком" | ||
6801 | |||
6802 | #: src/transport/gnunet-transport.c:1477 | ||
6803 | msgid "print information for all pending validations " | ||
6804 | msgstr "исписује податке за сва потврђивања на чекању " | ||
6805 | |||
6806 | #: src/transport/gnunet-transport.c:1480 | ||
6807 | msgid "print information for all pending validations continously" | ||
6808 | msgstr "непрекидно исписује податке за сва потврђивања на чекању" | ||
6809 | |||
6810 | #: src/transport/gnunet-transport.c:1483 | ||
6811 | msgid "provide information about all current connections (once)" | ||
6812 | msgstr "обезбеђује податке о свим тренутним везама (једном)" | ||
6813 | |||
6814 | #: src/transport/gnunet-transport.c:1489 | ||
6815 | msgid "provide information about all connects and disconnect events (continuously)" | ||
6816 | msgstr "обезбеђује податке о свим догађајима повезивања и прекида везе (непрекидно)" | ||
6817 | |||
6818 | #: src/transport/gnunet-transport.c:1491 | ||
6819 | msgid "do not resolve hostnames" | ||
6820 | msgstr "не разрешава називе домаћина" | ||
6821 | |||
6822 | #: src/transport/gnunet-transport.c:1493 | ||
6823 | msgid "peer identity" | ||
6824 | msgstr "идентитет парњака" | ||
6825 | |||
6826 | #: src/transport/gnunet-transport.c:1495 | ||
6827 | msgid "send data for benchmarking to the other peer (until CTRL-C)" | ||
6828 | msgstr "шаље податке за оцењивање другим парњацима (све до КТРЛ-Ц)" | ||
6829 | |||
6830 | #: src/transport/gnunet-transport.c:1498 | ||
6831 | msgid "test transport configuration (involves external server)" | ||
6832 | msgstr "тестира подешавање транспорта (призива спољни сервер)" | ||
6833 | |||
6834 | #: src/transport/gnunet-transport.c:1507 | ||
6835 | msgid "Direct access to transport service." | ||
6836 | msgstr "Непосредан приступ услузи преноса." | ||
6837 | |||
6838 | #: src/transport/plugin_transport_bluetooth.c:621 | ||
6839 | msgid "# Bluetooth ACKs sent" | ||
6840 | msgstr "# АЦК-ови блутута су послати" | ||
6841 | |||
6842 | #: src/transport/plugin_transport_bluetooth.c:640 | ||
6843 | msgid "# Bluetooth messages defragmented" | ||
6844 | msgstr "# делићи Блутут порука су уједињени" | ||
6845 | |||
6846 | #: src/transport/plugin_transport_bluetooth.c:686 | ||
6847 | #: src/transport/plugin_transport_bluetooth.c:737 | ||
6848 | #: src/transport/plugin_transport_bluetooth.c:1942 | ||
6849 | msgid "# Bluetooth sessions allocated" | ||
6850 | msgstr "# Блутут сесије су додељене" | ||
6851 | |||
6852 | #: src/transport/plugin_transport_bluetooth.c:837 | ||
6853 | msgid "# Bluetooth message fragments sent" | ||
6854 | msgstr "# Делићи блутут поруке су послати" | ||
6855 | |||
6856 | #: src/transport/plugin_transport_bluetooth.c:861 | ||
6857 | msgid "# Bluetooth messages pending (with fragmentation)" | ||
6858 | msgstr "# Поруке блутута су на чекању (са расцепканошћу)" | ||
6859 | |||
6860 | #: src/transport/plugin_transport_bluetooth.c:969 | ||
6861 | #: src/transport/plugin_transport_bluetooth.c:1054 | ||
6862 | #: src/transport/plugin_transport_bluetooth.c:1944 | ||
6863 | msgid "# Bluetooth MAC endpoints allocated" | ||
6864 | msgstr "# Крајње тачке Блутут МАЦ-а су додељене" | ||
6865 | |||
6866 | #: src/transport/plugin_transport_bluetooth.c:1307 | ||
6867 | msgid "# HELLO messages received via Bluetooth" | ||
6868 | msgstr "# „HELLO“ поруке су примљене путем блутута" | ||
6869 | |||
6870 | #: src/transport/plugin_transport_bluetooth.c:1331 | ||
6871 | msgid "# fragments received via Bluetooth" | ||
6872 | msgstr "# делићи су примљени путем Блутута" | ||
6873 | |||
6874 | #: src/transport/plugin_transport_bluetooth.c:1341 | ||
6875 | msgid "# ACKs received via Bluetooth" | ||
6876 | msgstr "# АЦК-ови су примљени путем блутута" | ||
6877 | |||
6878 | #: src/transport/plugin_transport_bluetooth.c:1401 | ||
6879 | msgid "# Bluetooth DATA messages discarded due to CRC32 error" | ||
6880 | msgstr "# Поруке ПОДАТАКА блутута су одбачене услед „CRC32“ грешке" | ||
6881 | |||
6882 | #: src/transport/plugin_transport_bluetooth.c:1512 | ||
6883 | msgid "# DATA messages received via Bluetooth" | ||
6884 | msgstr "# поруке ПОДАТАКА су примљене путем блутута" | ||
6885 | |||
6886 | #: src/transport/plugin_transport_bluetooth.c:1547 | ||
6887 | msgid "# Bluetooth DATA messages processed" | ||
6888 | msgstr "# Поруке Блутут ПОДАТАКА су обрађене" | ||
6889 | |||
6890 | #: src/transport/plugin_transport_bluetooth.c:1610 | ||
6891 | msgid "# HELLO beacons sent via Bluetooth" | ||
6892 | msgstr "# „HELLO“ ознаке су послате путем Блутута" | ||
6893 | |||
6894 | #: src/transport/plugin_transport_bluetooth.c:1723 | ||
6895 | msgid "Bluetooth address with invalid size encountered\n" | ||
6896 | msgstr "Наишли смо на адресу блутута са неисправном величином\n" | ||
6897 | |||
6898 | #: src/transport/plugin_transport_bluetooth.c:1923 | ||
6899 | #, c-format | ||
6900 | msgid "Helper binary `%s' not SUID, cannot run bluetooth transport\n" | ||
6901 | msgstr "Извршна помоћника „%s“ није СУИБ, не могу да покренем блутут пренос\n" | ||
6902 | |||
6903 | #: src/transport/plugin_transport_http_client.c:1622 | ||
6904 | #, c-format | ||
6905 | msgid "Could not initialize curl multi handle, failed to start %s plugin!\n" | ||
6906 | msgstr "Не могу да покренем мулти ручку „curl“-а, нисам успео да покренем „%s“ прикључак!\n" | ||
6907 | |||
6908 | #: src/transport/plugin_transport_http_client.c:1697 | ||
6909 | #: src/transport/plugin_transport_http_server.c:3007 | ||
6910 | #, c-format | ||
6911 | msgid "Shutting down plugin `%s'\n" | ||
6912 | msgstr "Гасим прикључак „%s“\n" | ||
6913 | |||
6914 | #: src/transport/plugin_transport_http_client.c:1722 | ||
6915 | #: src/transport/plugin_transport_http_server.c:3063 | ||
6916 | #, c-format | ||
6917 | msgid "Shutdown for plugin `%s' complete\n" | ||
6918 | msgstr "Гашење за прикључак „%s“ је завршено\n" | ||
6919 | |||
6920 | #: src/transport/plugin_transport_http_client.c:1750 | ||
6921 | #: src/transport/plugin_transport_http_server.c:2907 | ||
6922 | #, c-format | ||
6923 | msgid "Maximum number of connections is %u\n" | ||
6924 | msgstr "Највећи број веза је %u\n" | ||
6925 | |||
6926 | #: src/transport/plugin_transport_http_server.c:1402 | ||
6927 | #, c-format | ||
6928 | msgid "Access from connection %p (%u of %u) for `%s' `%s' url `%s' with upload data size %u\n" | ||
6929 | msgstr "Приступ из везе %p (%u од %u) за „%s“ „%s“ адреса „%s“ са величином података утовара %u\n" | ||
6930 | |||
6931 | #: src/transport/plugin_transport_http_server.c:1663 | ||
6932 | #, c-format | ||
6933 | msgid "Accepting connection (%u of %u) from `%s'\n" | ||
6934 | msgstr "Прихватам везу (%u од %u) са „%s“\n" | ||
6935 | |||
6936 | #: src/transport/plugin_transport_http_server.c:1671 | ||
6937 | #, c-format | ||
6938 | msgid "Server reached maximum number connections (%u), rejecting new connection\n" | ||
6939 | msgstr "Сервер је достигао највећи број веза (%u), одбацује нове везе\n" | ||
6940 | |||
6941 | #: src/transport/plugin_transport_http_server.c:1958 | ||
6942 | msgid "Could not create a new TLS certificate, program `gnunet-transport-certificate-creation' could not be started!\n" | ||
6943 | msgstr "Не могу да направим ново ТЛС уверење, програм „gnunet-transport-certificate-creation“ се не може покренути!\n" | ||
6944 | |||
6945 | #: src/transport/plugin_transport_http_server.c:1982 | ||
6946 | #, c-format | ||
6947 | msgid "No usable TLS certificate found and creating one at `%s/%s' failed!\n" | ||
6948 | msgstr "Нисам нашао употребљиво ТЛС уверење а његово стварање на „%s/%s“ није успело!\n" | ||
6949 | |||
6950 | #: src/transport/plugin_transport_http_server.c:2405 | ||
6951 | msgid "Require valid port number for service in configuration!\n" | ||
6952 | msgstr "Захтева исправан број прикључника за услугу у подешавањима!\n" | ||
6953 | |||
6954 | #: src/transport/plugin_transport_http_server.c:2437 src/util/service.c:698 | ||
6955 | #, c-format | ||
6956 | msgid "Failed to resolve `%s': %s\n" | ||
6957 | msgstr "Нисам успео да решим „%s“: %s\n" | ||
6958 | |||
6959 | #: src/transport/plugin_transport_http_server.c:2454 src/util/service.c:715 | ||
6960 | #, c-format | ||
6961 | msgid "Failed to find %saddress for `%s'.\n" | ||
6962 | msgstr "Нисам успео да нађем %s адресу за „%s“.\n" | ||
6963 | |||
6964 | #: src/transport/plugin_transport_http_server.c:2565 | ||
6965 | #, c-format | ||
6966 | msgid "Found %u addresses to report to NAT service\n" | ||
6967 | msgstr "Нађох %u адрес за извештавање НАТ услузи\n" | ||
6968 | |||
6969 | #: src/transport/plugin_transport_http_server.c:2637 | ||
6970 | msgid "Disabling IPv6 since it is not supported on this system!\n" | ||
6971 | msgstr "Искључујем ИПв6 јер није подржано на овом систему!\n" | ||
6972 | |||
6973 | #: src/transport/plugin_transport_http_server.c:2730 | ||
6974 | #, c-format | ||
6975 | msgid "IPv4 support is %s\n" | ||
6976 | msgstr "ИПв4 подршка је %s\n" | ||
6977 | |||
6978 | #: src/transport/plugin_transport_http_server.c:2744 | ||
6979 | #, c-format | ||
6980 | msgid "IPv6 support is %s\n" | ||
6981 | msgstr "ИПв6 подршка је %s\n" | ||
6982 | |||
6983 | #: src/transport/plugin_transport_http_server.c:2751 | ||
6984 | msgid "Neither IPv4 nor IPv6 are enabled! Fix in configuration\n" | ||
6985 | msgstr "Ни ИПв4 ни ИПв6 није укључено! Исправите у подешавању\n" | ||
6986 | |||
6987 | #: src/transport/plugin_transport_http_server.c:2762 | ||
6988 | msgid "Port is required! Fix in configuration\n" | ||
6989 | msgstr "Прикључник је потребан! Исправите у подешавању\n" | ||
6990 | |||
6991 | #: src/transport/plugin_transport_http_server.c:2769 | ||
6992 | #, c-format | ||
6993 | msgid "Using port %u\n" | ||
6994 | msgstr "Користим прикључник %u\n" | ||
6995 | |||
6996 | #: src/transport/plugin_transport_http_server.c:2784 | ||
6997 | #, c-format | ||
6998 | msgid "Specific IPv4 address `%s' in configuration file is invalid!\n" | ||
6999 | msgstr "Специфична ИПв4 адреса „%s“ у датотеци подешавања је неисправна!\n" | ||
7000 | |||
7001 | #: src/transport/plugin_transport_http_server.c:2794 | ||
7002 | #, c-format | ||
7003 | msgid "Binding to IPv4 address %s\n" | ||
7004 | msgstr "Свезујем за ИПв4 адресу %s\n" | ||
7005 | |||
7006 | #: src/transport/plugin_transport_http_server.c:2815 | ||
7007 | #, c-format | ||
7008 | msgid "Specific IPv6 address `%s' in configuration file is invalid!\n" | ||
7009 | msgstr "Специфична ИПв6 адреса „%s“ у датотеци подешавања је неисправна!\n" | ||
7010 | |||
7011 | #: src/transport/plugin_transport_http_server.c:2825 | ||
7012 | #, c-format | ||
7013 | msgid "Binding to IPv6 address %s\n" | ||
7014 | msgstr "Свезујем за ИПв6 адресу %s\n" | ||
7015 | |||
7016 | #: src/transport/plugin_transport_http_server.c:2877 | ||
7017 | #, c-format | ||
7018 | msgid "Using external hostname `%s'\n" | ||
7019 | msgstr "Користим спољни назив домаћина „%s“\n" | ||
7020 | |||
7021 | #: src/transport/plugin_transport_http_server.c:2893 | ||
7022 | #, c-format | ||
7023 | msgid "Notifying transport only about hostname `%s'\n" | ||
7024 | msgstr "Обавештавам пренос само о називу домаћина „%s“\n" | ||
7025 | |||
7026 | #: src/transport/plugin_transport_smtp.c:223 | ||
7027 | #, c-format | ||
7028 | msgid "Received malformed message via %s. Ignored.\n" | ||
7029 | msgstr "Примих лошу поруку путем „%s“. Занемарујем.\n" | ||
7030 | |||
7031 | #: src/transport/plugin_transport_smtp.c:310 | ||
7032 | msgid "SMTP filter string to invalid, lacks ': '\n" | ||
7033 | msgstr "Ниска СМТП филтера је превише неисправна, недостаје „: “\n" | ||
7034 | |||
7035 | #: src/transport/plugin_transport_smtp.c:319 | ||
7036 | #, c-format | ||
7037 | msgid "SMTP filter string to long, capped to `%s'\n" | ||
7038 | msgstr "Ниска СМТП филтера је предуга, скраћена је на „%s“\n" | ||
7039 | |||
7040 | #: src/transport/plugin_transport_smtp.c:414 | ||
7041 | #: src/transport/plugin_transport_smtp.c:424 | ||
7042 | #: src/transport/plugin_transport_smtp.c:437 | ||
7043 | #: src/transport/plugin_transport_smtp.c:456 | ||
7044 | #: src/transport/plugin_transport_smtp.c:479 | ||
7045 | #: src/transport/plugin_transport_smtp.c:487 | ||
7046 | #: src/transport/plugin_transport_smtp.c:500 | ||
7047 | #: src/transport/plugin_transport_smtp.c:511 | ||
7048 | #, c-format | ||
7049 | msgid "SMTP: `%s' failed: %s.\n" | ||
7050 | msgstr "СМТП: „%s“ није успело: %s.\n" | ||
7051 | |||
7052 | #: src/transport/plugin_transport_smtp.c:652 | ||
7053 | msgid "No email-address specified, can not start SMTP transport.\n" | ||
7054 | msgstr "Није наведена адреса е-поште, не могу да почнем СМТП пренос.\n" | ||
7055 | |||
7056 | #: src/transport/plugin_transport_smtp.c:664 | ||
7057 | msgid "# bytes received via SMTP" | ||
7058 | msgstr "# бајтови су примљени путем СМТП-а" | ||
7059 | |||
7060 | #: src/transport/plugin_transport_smtp.c:665 | ||
7061 | msgid "# bytes sent via SMTP" | ||
7062 | msgstr "# бајтови су послати путем СМТП-а" | ||
7063 | |||
7064 | #: src/transport/plugin_transport_smtp.c:667 | ||
7065 | msgid "# bytes dropped by SMTP (outgoing)" | ||
7066 | msgstr "# бајтови су одбачени СМТП-ом (одлазни)" | ||
7067 | |||
7068 | #: src/transport/plugin_transport_tcp.c:555 | ||
7069 | #, c-format | ||
7070 | msgid "Unexpected address length: %u bytes\n" | ||
7071 | msgstr "Неочекивана дужина адресе: %u бајта\n" | ||
7072 | |||
7073 | #: src/transport/plugin_transport_tcp.c:762 | ||
7074 | #: src/transport/plugin_transport_tcp.c:928 | ||
7075 | #: src/transport/plugin_transport_tcp.c:2005 | ||
7076 | #: src/transport/plugin_transport_tcp.c:2558 | ||
7077 | msgid "# TCP sessions active" | ||
7078 | msgstr "# ТЦП сесије су активне" | ||
7079 | |||
7080 | #: src/transport/plugin_transport_tcp.c:795 | ||
7081 | #: src/transport/plugin_transport_tcp.c:921 | ||
7082 | #: src/transport/plugin_transport_tcp.c:1009 | ||
7083 | #: src/transport/plugin_transport_tcp.c:1056 | ||
7084 | #: src/transport/plugin_transport_tcp.c:1219 | ||
7085 | #: src/transport/plugin_transport_tcp.c:1237 | ||
7086 | msgid "# bytes currently in TCP buffers" | ||
7087 | msgstr "# бајтова тренутно у ТЦП међумеморијама" | ||
7088 | |||
7089 | #: src/transport/plugin_transport_tcp.c:798 | ||
7090 | msgid "# bytes discarded by TCP (disconnect)" | ||
7091 | msgstr "# бајтови су одбачени ТЦП-ом (прекид везе)" | ||
7092 | |||
7093 | #: src/transport/plugin_transport_tcp.c:1012 | ||
7094 | msgid "# bytes discarded by TCP (timeout)" | ||
7095 | msgstr "# бајтови су одбачени ТЦП-ом (истекло време)" | ||
7096 | |||
7097 | #: src/transport/plugin_transport_tcp.c:1059 | ||
7098 | msgid "# bytes transmitted via TCP" | ||
7099 | msgstr "# бајтови су пренесени путем ТЦП-а" | ||
7100 | |||
7101 | #: src/transport/plugin_transport_tcp.c:1193 | ||
7102 | #, c-format | ||
7103 | msgid "Trying to send with invalid session %p\n" | ||
7104 | msgstr "Покушавам да пошаљем са неисправном сесијом %p\n" | ||
7105 | |||
7106 | #: src/transport/plugin_transport_tcp.c:1462 | ||
7107 | msgid "# requests to create session with invalid address" | ||
7108 | msgstr "# захтева за стварање сесије са неисправном адресом" | ||
7109 | |||
7110 | #: src/transport/plugin_transport_tcp.c:1567 | ||
7111 | msgid "# transport-service disconnect requests for TCP" | ||
7112 | msgstr "# захтеви прекида везе услуге преноса за ТЦП" | ||
7113 | |||
7114 | #: src/transport/plugin_transport_tcp.c:2055 | ||
7115 | msgid "# TCP WELCOME messages received" | ||
7116 | msgstr "# поруке ТЦП ДОБРОДОШЛИЦЕ су примљене" | ||
7117 | |||
7118 | #: src/transport/plugin_transport_tcp.c:2215 | ||
7119 | msgid "# bytes received via TCP" | ||
7120 | msgstr "# бајта је примљено путем ТЦП-а" | ||
7121 | |||
7122 | #: src/transport/plugin_transport_tcp.c:2279 | ||
7123 | msgid "# network-level TCP disconnect events" | ||
7124 | msgstr "# догађаји ТЦП мрежног нивоа прекидања везе" | ||
7125 | |||
7126 | #: src/transport/plugin_transport_tcp.c:2437 src/util/service.c:582 | ||
7127 | #: src/util/service.c:588 | ||
7128 | #, c-format | ||
7129 | msgid "Require valid port number for service `%s' in configuration!\n" | ||
7130 | msgstr "Захтева исправан број прикључника за услугу „%s“ у подешавањима!\n" | ||
7131 | |||
7132 | #: src/transport/plugin_transport_tcp.c:2451 | ||
7133 | msgid "Failed to start service.\n" | ||
7134 | msgstr "Нисам успео да покренем услугу.\n" | ||
7135 | |||
7136 | #: src/transport/plugin_transport_tcp.c:2547 | ||
7137 | #, c-format | ||
7138 | msgid "TCP transport listening on port %llu\n" | ||
7139 | msgstr "ТЦП пренос ослушкује на прикључнику %llu\n" | ||
7140 | |||
7141 | #: src/transport/plugin_transport_tcp.c:2551 | ||
7142 | msgid "TCP transport not listening on any port (client only)\n" | ||
7143 | msgstr "ТЦП пренос не ослушкује ни на једном прикључнику (само клијент)\n" | ||
7144 | |||
7145 | #: src/transport/plugin_transport_tcp.c:2554 | ||
7146 | #, c-format | ||
7147 | msgid "TCP transport advertises itself as being on port %llu\n" | ||
7148 | msgstr "ТЦП пренос упозорава себе да је на прикључнику %llu\n" | ||
7149 | |||
7150 | #: src/transport/plugin_transport_udp_broadcasting.c:167 | ||
7151 | msgid "# IPv6 multicast HELLO beacons received via udp" | ||
7152 | msgstr "# ИПв6 вишеодредишне „HELLO“ ознаке су примљене путем удп-а" | ||
7153 | |||
7154 | #: src/transport/plugin_transport_udp_broadcasting.c:210 | ||
7155 | msgid "# IPv4 broadcast HELLO beacons received via udp" | ||
7156 | msgstr "# ИПв4 свеодредишне „HELLO“ ознаке су примљене путем удп-а" | ||
7157 | |||
7158 | #: src/transport/plugin_transport_udp_broadcasting.c:603 | ||
7159 | msgid "Disabling HELLO broadcasting due to friend-to-friend only configuration!\n" | ||
7160 | msgstr "Искључујем „HELLO“ емитовање због подешавања само пријатељ пријатељу!\n" | ||
7161 | |||
7162 | #: src/transport/plugin_transport_udp_broadcasting.c:626 | ||
7163 | #, c-format | ||
7164 | msgid "Failed to set IPv4 broadcast option for broadcast socket on port %d\n" | ||
7165 | msgstr "Нисам успео да поставим опцију ИПв4 емитовања за прикључницу емитовања на прикључнику %d\n" | ||
7166 | |||
7167 | #: src/transport/plugin_transport_udp.c:1513 | ||
7168 | #, c-format | ||
7169 | msgid "Trying to create session for address of unexpected length %u (should be %u or %u)\n" | ||
7170 | msgstr "Покушавам да направим сесију за адресу неочекиване дужине %u (треба бити %u или %u)\n" | ||
7171 | |||
7172 | #: src/transport/plugin_transport_udp.c:2602 | ||
7173 | #, c-format | ||
7174 | msgid "UDP could not transmit message to `%s': Network seems down, please check your network configuration\n" | ||
7175 | msgstr "УДП не може да пренесе поруку до „%s“: Изгледа да је мрежа пала, проверите ваша мрежна подешавања\n" | ||
7176 | |||
7177 | #: src/transport/plugin_transport_udp.c:2616 | ||
7178 | msgid "UDP could not transmit IPv6 message! Please check your network configuration and disable IPv6 if your connection does not have a global IPv6 address\n" | ||
7179 | msgstr "УДП не може да пренесе ИПв6 поруку! Проверите мрежна подешавања и искључите ИПв6 ако ваша веза нема општу Ипв6 адресу\n" | ||
7180 | |||
7181 | #: src/transport/plugin_transport_udp.c:2961 | ||
7182 | msgid "Failed to open UDP sockets\n" | ||
7183 | msgstr "Нисам успео да отворим УДП прикључницу\n" | ||
7184 | |||
7185 | #: src/transport/plugin_transport_udp.c:3056 | ||
7186 | #, c-format | ||
7187 | msgid "Given `%s' option is out of range: %llu > %u\n" | ||
7188 | msgstr "Дата „%s“ опција је ван опсега: %llu > %u\n" | ||
7189 | |||
7190 | #: src/transport/plugin_transport_udp.c:3097 | ||
7191 | #, c-format | ||
7192 | msgid "Invalid IPv6 address: `%s'\n" | ||
7193 | msgstr "Неисправна ИПв6 адреса: „%s“\n" | ||
7194 | |||
7195 | #: src/transport/plugin_transport_udp.c:3168 | ||
7196 | msgid "Failed to create network sockets, plugin failed\n" | ||
7197 | msgstr "Нисам успео да направим прикључнице мреже, прикључак није успео\n" | ||
7198 | |||
7199 | #: src/transport/plugin_transport_unix.c:1321 | ||
7200 | #, c-format | ||
7201 | msgid "Cannot create path to `%s'\n" | ||
7202 | msgstr "Не могу да направим путању до „%s“\n" | ||
7203 | |||
7204 | #: src/transport/plugin_transport_unix.c:1652 | ||
7205 | msgid "No UNIXPATH given in configuration!\n" | ||
7206 | msgstr "Није дата ЈУНИКС_ПУТАЊА у подешавањима!\n" | ||
7207 | |||
7208 | #: src/transport/plugin_transport_unix.c:1688 | ||
7209 | msgid "Failed to open UNIX listen socket\n" | ||
7210 | msgstr "Нисам успео да отворим ЈУНИКС прикључницу ослушкивања\n" | ||
7211 | |||
7212 | #: src/transport/plugin_transport_wlan.c:620 | ||
7213 | msgid "# WLAN ACKs sent" | ||
7214 | msgstr "# „WLAN“ АЦК-ови су послати" | ||
7215 | |||
7216 | #: src/transport/plugin_transport_wlan.c:639 | ||
7217 | msgid "# WLAN messages defragmented" | ||
7218 | msgstr "# делићи „WLAN“ порука су уједињени" | ||
7219 | |||
7220 | #: src/transport/plugin_transport_wlan.c:688 | ||
7221 | #: src/transport/plugin_transport_wlan.c:772 | ||
7222 | #: src/transport/plugin_transport_wlan.c:1948 | ||
7223 | msgid "# WLAN sessions allocated" | ||
7224 | msgstr "# „WLAN“ сесије су додељене" | ||
7225 | |||
7226 | #: src/transport/plugin_transport_wlan.c:876 | ||
7227 | msgid "# WLAN message fragments sent" | ||
7228 | msgstr "# делићи „WLAN“ поруке су послати" | ||
7229 | |||
7230 | #: src/transport/plugin_transport_wlan.c:900 | ||
7231 | msgid "# WLAN messages pending (with fragmentation)" | ||
7232 | msgstr "# Поруке „WLAN“-а су на чекању (са расцепканошћу)" | ||
7233 | |||
7234 | #: src/transport/plugin_transport_wlan.c:1008 | ||
7235 | #: src/transport/plugin_transport_wlan.c:1098 | ||
7236 | #: src/transport/plugin_transport_wlan.c:1950 | ||
7237 | msgid "# WLAN MAC endpoints allocated" | ||
7238 | msgstr "# Крајње тачке „WLAN“ МАЦ-а су додељене" | ||
7239 | |||
7240 | #: src/transport/plugin_transport_wlan.c:1302 | ||
7241 | msgid "# HELLO messages received via WLAN" | ||
7242 | msgstr "# „HELLO“ поруке су примљене путем „WLAN“-а" | ||
7243 | |||
7244 | #: src/transport/plugin_transport_wlan.c:1326 | ||
7245 | msgid "# fragments received via WLAN" | ||
7246 | msgstr "# делићи су примљени путем „WLAN“-а" | ||
7247 | |||
7248 | #: src/transport/plugin_transport_wlan.c:1336 | ||
7249 | msgid "# ACKs received via WLAN" | ||
7250 | msgstr "# АЦК-ови су примљени путем „WLAN“-а" | ||
7251 | |||
7252 | #: src/transport/plugin_transport_wlan.c:1396 | ||
7253 | msgid "# WLAN DATA messages discarded due to CRC32 error" | ||
7254 | msgstr "# Поруке ПОДАТАКА „WLAN“ су одбачене услед „CRC32“ грешке" | ||
7255 | |||
7256 | #: src/transport/plugin_transport_wlan.c:1518 | ||
7257 | msgid "# DATA messages received via WLAN" | ||
7258 | msgstr "# поруке ПОДАТАКА су примљене путем „WLAN“-а" | ||
7259 | |||
7260 | #: src/transport/plugin_transport_wlan.c:1553 | ||
7261 | msgid "# WLAN DATA messages processed" | ||
7262 | msgstr "# Поруке „WLAN“ ПОДАТАКА су обрађене" | ||
7263 | |||
7264 | #: src/transport/plugin_transport_wlan.c:1616 | ||
7265 | msgid "# HELLO beacons sent via WLAN" | ||
7266 | msgstr "# „HELLO“ ознаке су послате путем „WLAN“—а" | ||
7267 | |||
7268 | #: src/transport/plugin_transport_wlan.c:1729 | ||
7269 | msgid "WLAN address with invalid size encountered\n" | ||
7270 | msgstr "Наишли смо на адресу „WLAN“ са неисправном величином\n" | ||
7271 | |||
7272 | #: src/transport/plugin_transport_wlan.c:1929 | ||
7273 | #, c-format | ||
7274 | msgid "Helper binary `%s' not SUID, cannot run WLAN transport\n" | ||
7275 | msgstr "Извршна помоћника „%s“ није СУИБ, не могу да покренем „WLAN“ пренос\n" | ||
7276 | |||
7277 | #: src/transport/transport_api.c:739 | ||
7278 | #, c-format | ||
7279 | msgid "Received unexpected message of type %u in %s:%u\n" | ||
7280 | msgstr "Примих неочекивану поруку врсте %u у %s:%u\n" | ||
7281 | |||
7282 | #: src/transport/transport-testing.c:584 | ||
7283 | msgid "Failed to initialize testing library!\n" | ||
7284 | msgstr "Нисам успео да покренем библиотеку тестирања!\n" | ||
7285 | |||
7286 | #: src/tun/regex.c:129 | ||
7287 | #, c-format | ||
7288 | msgid "Bad mask: %d\n" | ||
7289 | msgstr "Лоша маска: %d\n" | ||
7290 | |||
7291 | #: src/util/bio.c:170 src/util/bio.c:178 | ||
7292 | #, c-format | ||
7293 | msgid "Error reading `%s': %s" | ||
7294 | msgstr "Грешка при читању „%s“: %s" | ||
7295 | |||
7296 | #: src/util/bio.c:180 | ||
7297 | msgid "End of file" | ||
7298 | msgstr "Крај датотеке" | ||
7299 | |||
7300 | #: src/util/bio.c:237 | ||
7301 | #, c-format | ||
7302 | msgid "Error reading length of string `%s'" | ||
7303 | msgstr "Грешка читања дужине ниске „%s“" | ||
7304 | |||
7305 | #: src/util/bio.c:247 | ||
7306 | #, c-format | ||
7307 | msgid "String `%s' longer than allowed (%u > %u)" | ||
7308 | msgstr "Ниска „%s“ је дужа од дозвољеног (%u > %u)" | ||
7309 | |||
7310 | #: src/util/bio.c:293 | ||
7311 | #, c-format | ||
7312 | msgid "Serialized metadata `%s' larger than allowed (%u>%u)" | ||
7313 | msgstr "Серијализовани метаподаци „%s“ су већи од дозвољеног (%u>%u)" | ||
7314 | |||
7315 | #: src/util/bio.c:307 | ||
7316 | #, c-format | ||
7317 | msgid "Metadata `%s' failed to deserialize" | ||
7318 | msgstr "Метаподаци „%s“ нису успели да се десеријализују" | ||
7319 | |||
7320 | #: src/util/client.c:261 src/util/client.c:858 src/util/service.c:619 | ||
7321 | #, c-format | ||
7322 | msgid "UNIXPATH `%s' too long, maximum length is %llu\n" | ||
7323 | msgstr "ЈУНИКС_ПУТАЊА „%s“ је предуга, највећа дужина је %llu\n" | ||
7324 | |||
7325 | #: src/util/client.c:265 src/util/client.c:863 src/util/service.c:623 | ||
7326 | #, c-format | ||
7327 | msgid "Using `%s' instead\n" | ||
7328 | msgstr "Користим зато „%s“\n" | ||
7329 | |||
7330 | #: src/util/client.c:360 | ||
7331 | #, c-format | ||
7332 | msgid "Could not determine valid hostname and port for service `%s' from configuration.\n" | ||
7333 | msgstr "Не могу да одредим исправан назив доамћина и прикључник за услугу „%s“ из подешавања.\n" | ||
7334 | |||
7335 | #: src/util/client.c:368 | ||
7336 | #, c-format | ||
7337 | msgid "Need a non-empty hostname for service `%s'.\n" | ||
7338 | msgstr "Потребан је не-празан назив домаћина за услугу „%s“.\n" | ||
7339 | |||
7340 | #: src/util/client.c:1008 | ||
7341 | #, c-format | ||
7342 | msgid "Could not connect to service `%s', configuration broken.\n" | ||
7343 | msgstr "Не могу да се повежем на услугу „%s“, подешавање је оштећено.\n" | ||
7344 | |||
7345 | #: src/util/client.c:1020 | ||
7346 | #, c-format | ||
7347 | msgid "Failure to transmit request to service `%s'\n" | ||
7348 | msgstr "Нисам успео да пренесем захтев услузи „%s“\n" | ||
7349 | |||
7350 | #: src/util/client.c:1303 | ||
7351 | msgid "Could not submit request, not expecting to receive a response.\n" | ||
7352 | msgstr "Не могу да предам захтев, не очекујем да примим одговор.\n" | ||
7353 | |||
7354 | #: src/util/common_logging.c:254 src/util/common_logging.c:1039 | ||
7355 | msgid "DEBUG" | ||
7356 | msgstr "ПРОЧИШЋАВАЊЕ" | ||
7357 | |||
7358 | #: src/util/common_logging.c:256 src/util/common_logging.c:1037 | ||
7359 | msgid "INFO" | ||
7360 | msgstr "ПОДАЦИ" | ||
7361 | |||
7362 | #: src/util/common_logging.c:258 src/util/common_logging.c:1035 | ||
7363 | msgid "WARNING" | ||
7364 | msgstr "УПОЗОРЕЊЕ" | ||
7365 | |||
7366 | #: src/util/common_logging.c:260 src/util/common_logging.c:1033 | ||
7367 | msgid "ERROR" | ||
7368 | msgstr "ГРЕШКА" | ||
7369 | |||
7370 | #: src/util/common_logging.c:262 src/util/common_logging.c:1041 | ||
7371 | msgid "NONE" | ||
7372 | msgstr "НИШТА" | ||
7373 | |||
7374 | #: src/util/common_logging.c:391 | ||
7375 | #, c-format | ||
7376 | msgid "Failed to create or access directory for log file `%s'\n" | ||
7377 | msgstr "Нисам успео да направим или да приступим директоријуму да забележим датотеку „%s“\n" | ||
7378 | |||
7379 | #: src/util/common_logging.c:817 | ||
7380 | #, c-format | ||
7381 | msgid "Message `%.*s' repeated %u times in the last %s\n" | ||
7382 | msgstr "Порука „%.*s“ је поновљена %u пута у прошлости %s\n" | ||
7383 | |||
7384 | #: src/util/common_logging.c:1042 | ||
7385 | msgid "INVALID" | ||
7386 | msgstr "НЕИСПРАВНО" | ||
7387 | |||
7388 | #: src/util/common_logging.c:1157 | ||
7389 | msgid "unknown address" | ||
7390 | msgstr "непозната адреса" | ||
7391 | |||
7392 | #: src/util/common_logging.c:1196 | ||
7393 | msgid "invalid address" | ||
7394 | msgstr "неисправна адреса" | ||
7395 | |||
7396 | #: src/util/common_logging.c:1214 | ||
7397 | #, c-format | ||
7398 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" | ||
7399 | msgstr "Подешавање није успело да наведе опцију „%s“ у одељку „%s“!\n" | ||
7400 | |||
7401 | #: src/util/common_logging.c:1235 | ||
7402 | #, c-format | ||
7403 | msgid "Configuration specifies invalid value for option `%s' in section `%s': %s\n" | ||
7404 | msgstr "Подешавање наводи неисправну вредност за опцију „%s“ у одељку „%s“: %s\n" | ||
7405 | |||
7406 | #: src/util/configuration.c:288 | ||
7407 | #, c-format | ||
7408 | msgid "Syntax error while deserializing in line %u\n" | ||
7409 | msgstr "Грешка синтаксе приликом десеријализације у реду %u\n" | ||
7410 | |||
7411 | #: src/util/configuration.c:996 | ||
7412 | #, c-format | ||
7413 | msgid "Configuration value '%s' for '%s' in section '%s' is not in set of legal choices\n" | ||
7414 | msgstr "Вредност подешавања '%s' за '%s' у одељку '%s' није ус купу исправних избора\n" | ||
7415 | |||
7416 | #: src/util/configuration.c:1066 | ||
7417 | #, c-format | ||
7418 | msgid "Recursive expansion suspected, aborting $-expansion for term `%s'\n" | ||
7419 | msgstr "Сумња се на дубинско ширење, прекидам $-ширење за термин „%s“\n" | ||
7420 | |||
7421 | #: src/util/configuration.c:1098 | ||
7422 | #, c-format | ||
7423 | msgid "Missing closing `%s' in option `%s'\n" | ||
7424 | msgstr "Недостаје затварење „%s“ у опцији „%s“\n" | ||
7425 | |||
7426 | #: src/util/configuration.c:1172 | ||
7427 | #, c-format | ||
7428 | msgid "Failed to expand `%s' in `%s' as it is neither found in [PATHS] nor defined as an environmental variable\n" | ||
7429 | msgstr "Нисам успео да раширим „%s“ у „%s“ јер нисам нашао у [ПУТАЊАМА] нити је дефинисано као променљива окружења\n" | ||
7430 | |||
7431 | #: src/util/connection.c:423 | ||
7432 | #, c-format | ||
7433 | msgid "Access denied to `%s'\n" | ||
7434 | msgstr "Приступ је збрањен за „%s“\n" | ||
7435 | |||
7436 | #: src/util/connection.c:438 | ||
7437 | #, c-format | ||
7438 | msgid "Accepting connection from `%s': %p\n" | ||
7439 | msgstr "Прихватам везу са „%s“: %p\n" | ||
7440 | |||
7441 | #: src/util/connection.c:553 | ||
7442 | #, c-format | ||
7443 | msgid "Failed to establish TCP connection to `%s:%u', no further addresses to try.\n" | ||
7444 | msgstr "Нисам успео да успоставим ТЦП везу са `%s:%u', нема будућих адреса за покушавање.\n" | ||
7445 | |||
7446 | #: src/util/connection.c:751 src/util/connection.c:919 | ||
7447 | #, c-format | ||
7448 | msgid "Trying to connect to `%s' (%p)\n" | ||
7449 | msgstr "Покушавам да се повежем на „%s“ (%p)\n" | ||
7450 | |||
7451 | #: src/util/connection.c:910 | ||
7452 | #, c-format | ||
7453 | msgid "Attempt to connect to `%s' failed\n" | ||
7454 | msgstr "Покушај повезивања са „%s“ није успео\n" | ||
7455 | |||
7456 | #: src/util/container_bloomfilter.c:531 | ||
7457 | #, c-format | ||
7458 | msgid "Size of file on disk is incorrect for this Bloom filter (want %llu, have %llu)\n" | ||
7459 | msgstr "Величина датотеке на диску није тачна за овај Блум филтер (желим %llu, имам %llu)\n" | ||
7460 | |||
7461 | #: src/util/crypto_ecc.c:702 src/util/crypto_ecc.c:740 | ||
7462 | #: src/util/crypto_ecc.c:858 src/util/crypto_ecc.c:896 | ||
7463 | #, c-format | ||
7464 | msgid "Could not acquire lock on file `%s': %s...\n" | ||
7465 | msgstr "Не могу да остварим закључавање на датотеци „%s“: %s...\n" | ||
7466 | |||
7467 | #: src/util/crypto_ecc.c:707 src/util/crypto_ecc.c:863 | ||
7468 | msgid "Creating a new private key. This may take a while.\n" | ||
7469 | msgstr "Стварам нови лични кључ. Ово може потрајати.\n" | ||
7470 | |||
7471 | #: src/util/crypto_ecc.c:744 src/util/crypto_ecc.c:900 | ||
7472 | msgid "This may be ok if someone is currently generating a private key.\n" | ||
7473 | msgstr "Ово може бити у реду ако неко тренутно ствара лични кључ.\n" | ||
7474 | |||
7475 | #: src/util/crypto_ecc.c:774 src/util/crypto_ecc.c:930 | ||
7476 | #, c-format | ||
7477 | msgid "When trying to read key file `%s' I found %u bytes but I need at least %u.\n" | ||
7478 | msgstr "Приликом покушаја читања датотеке кључа „%s“ нађох %u бајта али ми треба барем %u.\n" | ||
7479 | |||
7480 | #: src/util/crypto_ecc.c:778 src/util/crypto_ecc.c:934 | ||
7481 | msgid "This may be ok if someone is currently generating a key.\n" | ||
7482 | msgstr "Ово може бити у реду ако неко тренутно ствара кључ.\n" | ||
7483 | |||
7484 | #: src/util/crypto_ecc.c:1016 | ||
7485 | msgid "Could not load peer's private key\n" | ||
7486 | msgstr "Не могу да учитам лични кључ парњака\n" | ||
7487 | |||
7488 | #: src/util/crypto_ecc.c:1120 | ||
7489 | #, c-format | ||
7490 | msgid "ECC signing failed at %s:%d: %s\n" | ||
7491 | msgstr "„ECC“ потписивање није успело на %s:%d: %s\n" | ||
7492 | |||
7493 | #: src/util/crypto_ecc.c:1170 | ||
7494 | #, c-format | ||
7495 | msgid "EdDSA signing failed at %s:%d: %s\n" | ||
7496 | msgstr "„EdDSA“ потписивање није успело на %s:%d: %s\n" | ||
7497 | |||
7498 | #: src/util/crypto_ecc.c:1244 | ||
7499 | #, c-format | ||
7500 | msgid "ECDSA signature verification failed at %s:%d: %s\n" | ||
7501 | msgstr "Провера „ECDSA“ потписа није успела на %s:%d: %s\n" | ||
7502 | |||
7503 | #: src/util/crypto_ecc.c:1301 | ||
7504 | #, c-format | ||
7505 | msgid "EdDSA signature verification failed at %s:%d: %s\n" | ||
7506 | msgstr "Провера „EdDSA“ потписа није успела на %s:%d: %s\n" | ||
7507 | |||
7508 | #: src/util/crypto_random.c:284 | ||
7509 | #, c-format | ||
7510 | msgid "libgcrypt has not the expected version (version %s is required).\n" | ||
7511 | msgstr "„libgcrypt“ није очекиваног издања (издање %s је потребно).\n" | ||
7512 | |||
7513 | #: src/util/disk.c:1184 | ||
7514 | #, c-format | ||
7515 | msgid "Expected `%s' to be a directory!\n" | ||
7516 | msgstr "Очекивах да „%s“ буде директоријум!\n" | ||
7517 | |||
7518 | #: src/util/disk.c:1546 src/util/service.c:1318 | ||
7519 | #, c-format | ||
7520 | msgid "Cannot obtain information about user `%s': %s\n" | ||
7521 | msgstr "Не могу да добијем податке о кориснику „%s“: %s\n" | ||
7522 | |||
7523 | #: src/util/getopt.c:568 | ||
7524 | #, c-format | ||
7525 | msgid "%s: option `%s' is ambiguous\n" | ||
7526 | msgstr "%s: опција „%s“ је нејасна\n" | ||
7527 | |||
7528 | #: src/util/getopt.c:592 | ||
7529 | #, c-format | ||
7530 | msgid "%s: option `--%s' does not allow an argument\n" | ||
7531 | msgstr "%s: опција „--%s“ не дозвољава аргумент\n" | ||
7532 | |||
7533 | #: src/util/getopt.c:597 | ||
7534 | #, c-format | ||
7535 | msgid "%s: option `%c%s' does not allow an argument\n" | ||
7536 | msgstr "%s: опција „%c%s“ не дозвољава аргумент\n" | ||
7537 | |||
7538 | #: src/util/getopt.c:614 src/util/getopt.c:781 | ||
7539 | #, c-format | ||
7540 | msgid "%s: option `%s' requires an argument\n" | ||
7541 | msgstr "%s: опција „%s“ захтева аргумент\n" | ||
7542 | |||
7543 | #: src/util/getopt.c:643 | ||
7544 | #, c-format | ||
7545 | msgid "%s: unrecognized option `--%s'\n" | ||
7546 | msgstr "%s: непрепозната опција „--%s“\n" | ||
7547 | |||
7548 | #: src/util/getopt.c:647 | ||
7549 | #, c-format | ||
7550 | msgid "%s: unrecognized option `%c%s'\n" | ||
7551 | msgstr "%s: непрепозната опција „%c%s“\n" | ||
7552 | |||
7553 | #: src/util/getopt.c:672 | ||
7554 | #, c-format | ||
7555 | msgid "%s: illegal option -- %c\n" | ||
7556 | msgstr "%s: недозвољена опција —— %c\n" | ||
7557 | |||
7558 | #: src/util/getopt.c:674 | ||
7559 | #, c-format | ||
7560 | msgid "%s: invalid option -- %c\n" | ||
7561 | msgstr "%s: неисправна опција —— %c\n" | ||
7562 | |||
7563 | #: src/util/getopt.c:702 src/util/getopt.c:829 | ||
7564 | #, c-format | ||
7565 | msgid "%s: option requires an argument -- %c\n" | ||
7566 | msgstr "%s: опција захтева аргумент —— %c\n" | ||
7567 | |||
7568 | #: src/util/getopt.c:750 | ||
7569 | #, c-format | ||
7570 | msgid "%s: option `-W %s' is ambiguous\n" | ||
7571 | msgstr "%s: опција „-W %s“ је нејасна\n" | ||
7572 | |||
7573 | #: src/util/getopt.c:768 | ||
7574 | #, c-format | ||
7575 | msgid "%s: option `-W %s' does not allow an argument\n" | ||
7576 | msgstr "%s: опција „-W %s“ не дозвољава аргумент\n" | ||
7577 | |||
7578 | #: src/util/getopt.c:933 | ||
7579 | #, c-format | ||
7580 | msgid "Use %s to get a list of options.\n" | ||
7581 | msgstr "Употребите „%s“ да добавите списак опција.\n" | ||
7582 | |||
7583 | #: src/util/getopt_helpers.c:84 | ||
7584 | #, c-format | ||
7585 | msgid "Arguments mandatory for long options are also mandatory for short options.\n" | ||
7586 | msgstr "Аргументи обавезни за дуге опције су такође обавезни за кратке опције.\n" | ||
7587 | |||
7588 | #: src/util/getopt_helpers.c:268 src/util/getopt_helpers.c:326 | ||
7589 | #, c-format | ||
7590 | msgid "You must pass a number to the `%s' option.\n" | ||
7591 | msgstr "Морате да проследите број опцији „%s“.\n" | ||
7592 | |||
7593 | #: src/util/getopt_helpers.c:298 | ||
7594 | #, c-format | ||
7595 | msgid "You must pass relative time to the `%s' option.\n" | ||
7596 | msgstr "Морате да проследите релативно време опцији „%s“.\n" | ||
7597 | |||
7598 | #: src/util/gnunet-config.c:90 | ||
7599 | #, c-format | ||
7600 | msgid "--section argument is required\n" | ||
7601 | msgstr "аргумент „--section“ је потребан\n" | ||
7602 | |||
7603 | #: src/util/gnunet-config.c:133 | ||
7604 | #, c-format | ||
7605 | msgid "--option argument required to set value\n" | ||
7606 | msgstr "аргумент „--option“ је потребан за постављање вредности\n" | ||
7607 | |||
7608 | #: src/util/gnunet-config.c:160 | ||
7609 | msgid "obtain option of value as a filename (with $-expansion)" | ||
7610 | msgstr "добија опцију вредности као назив датотеке (са $-ширењем)" | ||
7611 | |||
7612 | #: src/util/gnunet-config.c:163 | ||
7613 | msgid "name of the section to access" | ||
7614 | msgstr "назив одељка за приступање" | ||
7615 | |||
7616 | #: src/util/gnunet-config.c:166 | ||
7617 | msgid "name of the option to access" | ||
7618 | msgstr "назив опције за приступање" | ||
7619 | |||
7620 | #: src/util/gnunet-config.c:169 | ||
7621 | msgid "value to set" | ||
7622 | msgstr "вредност за постављање" | ||
7623 | |||
7624 | #: src/util/gnunet-config.c:178 | ||
7625 | msgid "Manipulate GNUnet configuration files" | ||
7626 | msgstr "Управља ГНУнет датотекама подешавања" | ||
7627 | |||
7628 | #: src/util/gnunet-ecc.c:75 | ||
7629 | #, c-format | ||
7630 | msgid "Failed to open `%s': %s\n" | ||
7631 | msgstr "Нисам успео да отворим „%s“: %s\n" | ||
7632 | |||
7633 | #: src/util/gnunet-ecc.c:81 | ||
7634 | #, c-format | ||
7635 | msgid "Generating %u keys, please wait" | ||
7636 | msgstr "Стварам %u кључа, сачекајте" | ||
7637 | |||
7638 | #: src/util/gnunet-ecc.c:97 | ||
7639 | #, c-format | ||
7640 | msgid "" | ||
7641 | "\n" | ||
7642 | "Failed to write to `%s': %s\n" | ||
7643 | msgstr "" | ||
7644 | "\n" | ||
7645 | "Нисам успео да пишем у „%s“: %s\n" | ||
7646 | |||
7647 | #: src/util/gnunet-ecc.c:107 | ||
7648 | #, c-format | ||
7649 | msgid "" | ||
7650 | "\n" | ||
7651 | "Finished!\n" | ||
7652 | msgstr "" | ||
7653 | "\n" | ||
7654 | "Завршено!\n" | ||
7655 | |||
7656 | #: src/util/gnunet-ecc.c:110 | ||
7657 | #, c-format | ||
7658 | msgid "" | ||
7659 | "\n" | ||
7660 | "Error, %u keys not generated\n" | ||
7661 | msgstr "" | ||
7662 | "\n" | ||
7663 | "Грешка, %u кључа нису створена\n" | ||
7664 | |||
7665 | #: src/util/gnunet-ecc.c:199 | ||
7666 | #, c-format | ||
7667 | msgid "Hostkeys file `%s' not found\n" | ||
7668 | msgstr "Нисам нашао датотеку кључа домаћина „%s“\n" | ||
7669 | |||
7670 | #: src/util/gnunet-ecc.c:210 | ||
7671 | #, c-format | ||
7672 | msgid "Hostkeys file `%s' is empty\n" | ||
7673 | msgstr "Датотека кључа домаћина „%s“ је празна\n" | ||
7674 | |||
7675 | #: src/util/gnunet-ecc.c:232 | ||
7676 | #, c-format | ||
7677 | msgid "Could not read hostkey file: %s\n" | ||
7678 | msgstr "Не могу да прочитам датотеку кључа домаћина: %s\n" | ||
7679 | |||
7680 | #: src/util/gnunet-ecc.c:283 | ||
7681 | msgid "No hostkey file specified on command line\n" | ||
7682 | msgstr "Није наведена датотека кључа домаћина на линији наредби\n" | ||
7683 | |||
7684 | #: src/util/gnunet-ecc.c:349 | ||
7685 | msgid "list keys included in a file (for testing)" | ||
7686 | msgstr "исписује кључеве укључене у датотеци (за тестирање)" | ||
7687 | |||
7688 | #: src/util/gnunet-ecc.c:352 | ||
7689 | msgid "number of keys to list included in a file (for testing)" | ||
7690 | msgstr "број кључева за испис укључених у датотеци (за тестирање)" | ||
7691 | |||
7692 | #: src/util/gnunet-ecc.c:355 | ||
7693 | msgid "create COUNT public-private key pairs (for testing)" | ||
7694 | msgstr "ствара БРОЈ пара јавног-личног кључа (за тестирање)" | ||
7695 | |||
7696 | #: src/util/gnunet-ecc.c:358 | ||
7697 | msgid "print the public key in ASCII format" | ||
7698 | msgstr "исписује јавни кључ у АСКРИ формату" | ||
7699 | |||
7700 | #: src/util/gnunet-ecc.c:361 | ||
7701 | msgid "print the hash of the public key in ASCII format" | ||
7702 | msgstr "исписује хеш јавног кључа у АСКРИ формату" | ||
7703 | |||
7704 | #: src/util/gnunet-ecc.c:364 | ||
7705 | msgid "print examples of ECC operations (used for compatibility testing)" | ||
7706 | msgstr "исписује примере ЕЦЦ операција (користи се за тестирање сагласности)" | ||
7707 | |||
7708 | #: src/util/gnunet-ecc.c:375 | ||
7709 | msgid "Manipulate GNUnet private ECC key files" | ||
7710 | msgstr "Управља ГНУнет датотекама личног ЕЦЦ кључа" | ||
7711 | |||
7712 | #: src/util/gnunet-resolver.c:149 | ||
7713 | msgid "perform a reverse lookup" | ||
7714 | msgstr "обавља повратну претрагу" | ||
7715 | |||
7716 | #: src/util/gnunet-resolver.c:160 | ||
7717 | msgid "Use build-in GNUnet stub resolver" | ||
7718 | msgstr "Користи уграђеног заменског решавача ГНУнет-а" | ||
7719 | |||
7720 | #: src/util/gnunet-scrypt.c:279 | ||
7721 | msgid "number of bits to require for the proof of work" | ||
7722 | msgstr "број битова за тражење доказивања о раду" | ||
7723 | |||
7724 | #: src/util/gnunet-scrypt.c:282 | ||
7725 | msgid "file with private key, otherwise default is used" | ||
7726 | msgstr "датотека са личним кључем, у супротном користи се основна" | ||
7727 | |||
7728 | #: src/util/gnunet-scrypt.c:285 | ||
7729 | msgid "file with proof of work, otherwise default is used" | ||
7730 | msgstr "датотека са доказом о раду, у супротном користи се основна" | ||
7731 | |||
7732 | #: src/util/gnunet-scrypt.c:288 | ||
7733 | msgid "time to wait between calculations" | ||
7734 | msgstr "време за чекање између прорачуна" | ||
7735 | |||
7736 | #: src/util/gnunet-scrypt.c:299 | ||
7737 | msgid "Manipulate GNUnet proof of work files" | ||
7738 | msgstr "Управља ГНУнет датотекама доказа о раду" | ||
7739 | |||
7740 | #: src/util/gnunet-service-resolver.c:299 | ||
7741 | #, c-format | ||
7742 | msgid "Could not resolve `%s' (%s): %s\n" | ||
7743 | msgstr "Не могу да решим „%s“ (%s): %s\n" | ||
7744 | |||
7745 | #: src/util/gnunet-service-resolver.c:371 | ||
7746 | #: src/util/gnunet-service-resolver.c:412 | ||
7747 | #, c-format | ||
7748 | msgid "Could not find IP of host `%s': %s\n" | ||
7749 | msgstr "Не могу да нађем ИП домаћина „%s“: %s\n" | ||
7750 | |||
7751 | #: src/util/gnunet-uri.c:84 | ||
7752 | #, c-format | ||
7753 | msgid "No URI specified on command line\n" | ||
7754 | msgstr "Није наведена путања на линији наредби\n" | ||
7755 | |||
7756 | #: src/util/gnunet-uri.c:89 | ||
7757 | #, c-format | ||
7758 | msgid "Invalid URI: does not start with `%s'\n" | ||
7759 | msgstr "Неисправна путања: не почиње са „%s“\n" | ||
7760 | |||
7761 | #: src/util/gnunet-uri.c:96 | ||
7762 | #, c-format | ||
7763 | msgid "Invalid URI: fails to specify subsystem\n" | ||
7764 | msgstr "Неисправна путања: није успело навођење подсистема\n" | ||
7765 | |||
7766 | #: src/util/gnunet-uri.c:106 | ||
7767 | #, c-format | ||
7768 | msgid "No handler known for subsystem `%s'\n" | ||
7769 | msgstr "Није познат руковалац за подсистем „%s“\n" | ||
7770 | |||
7771 | #: src/util/gnunet-uri.c:168 | ||
7772 | msgid "Perform default-actions for GNUnet URIs" | ||
7773 | msgstr "Обавља основне радње за путање ГНУнет-а" | ||
7774 | |||
7775 | #: src/util/helper.c:338 | ||
7776 | #, c-format | ||
7777 | msgid "Error reading from `%s': %s\n" | ||
7778 | msgstr "Грешка читања из „%s“: %s\n" | ||
7779 | |||
7780 | #: src/util/helper.c:383 | ||
7781 | #, c-format | ||
7782 | msgid "Failed to parse inbound message from helper `%s'\n" | ||
7783 | msgstr "Нисам успео да обрадим долазну поруку са помоћника „%s“\n" | ||
7784 | |||
7785 | #: src/util/helper.c:609 | ||
7786 | #, c-format | ||
7787 | msgid "Error writing to `%s': %s\n" | ||
7788 | msgstr "Грешка писања у „%s“: %s\n" | ||
7789 | |||
7790 | #: src/util/network.c:134 | ||
7791 | #, c-format | ||
7792 | msgid "Unable to shorten unix path `%s' while keeping name unique\n" | ||
7793 | msgstr "Не могу да скратим јуникс путању „%s“ док задржавам назив јединственим\n" | ||
7794 | |||
7795 | #: src/util/network.c:1355 src/util/network.c:1480 | ||
7796 | #, c-format | ||
7797 | msgid "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" | ||
7798 | msgstr "Кобна унутрашња логичка грешка, процес се заплео у „%s“ (прекините са КТРЛ-Ц)!\n" | ||
7799 | |||
7800 | #: src/util/os_installation.c:421 | ||
7801 | #, c-format | ||
7802 | msgid "Could not determine installation path for %s. Set `%s' environment variable.\n" | ||
7803 | msgstr "Не могу да одредим путању инсталирања за „%s“. Поставите „%s“ променљиву окружења.\n" | ||
7804 | |||
7805 | #: src/util/os_installation.c:766 | ||
7806 | #, c-format | ||
7807 | msgid "Could not find binary `%s' in PATH!\n" | ||
7808 | msgstr "Не могу да нађем извршну „%s“ у ПУТАЊИ!\n" | ||
7809 | |||
7810 | #: src/util/os_installation.c:826 | ||
7811 | #, c-format | ||
7812 | msgid "CreateProcess failed for binary %s (%d).\n" | ||
7813 | msgstr "„CreateProcess“ није успело за извршну „%s“ (%d).\n" | ||
7814 | |||
7815 | #: src/util/os_installation.c:836 | ||
7816 | #, c-format | ||
7817 | msgid "GetExitCodeProcess failed for binary %s (%d).\n" | ||
7818 | msgstr "„GetExitCodeProcess“ није успело за извршну „%s“ (%d).\n" | ||
7819 | |||
7820 | #: src/util/plugin.c:87 | ||
7821 | #, c-format | ||
7822 | msgid "Initialization of plugin mechanism failed: %s!\n" | ||
7823 | msgstr "Покретање механизма прикључка није успело: %s!\n" | ||
7824 | |||
7825 | #: src/util/plugin.c:148 | ||
7826 | #, c-format | ||
7827 | msgid "`%s' failed to resolve method '%s' with error: %s\n" | ||
7828 | msgstr "„%s“ није успело да реши метод '%s' са грешком: %s\n" | ||
7829 | |||
7830 | #: src/util/plugin.c:223 | ||
7831 | #, c-format | ||
7832 | msgid "`%s' failed for library `%s' with error: %s\n" | ||
7833 | msgstr "„%s“ није успело за библиотеку '%s' са грешком: %s\n" | ||
7834 | |||
7835 | #: src/util/plugin.c:382 | ||
7836 | msgid "Could not determine plugin installation path.\n" | ||
7837 | msgstr "Не могу да одредим путању инсталирања прикључка.\n" | ||
7838 | |||
7839 | #: src/util/program.c:246 src/util/service.c:1452 | ||
7840 | #, c-format | ||
7841 | msgid "Malformed configuration file `%s', exit ...\n" | ||
7842 | msgstr "Лоша датотека подешавања „%s“, излазим ...\n" | ||
7843 | |||
7844 | #: src/util/program.c:258 src/util/service.c:1467 | ||
7845 | #, c-format | ||
7846 | msgid "Could not access configuration file `%s'\n" | ||
7847 | msgstr "Не могу да приступим датотеци подешавања „%s“\n" | ||
7848 | |||
7849 | #: src/util/program.c:263 src/util/service.c:1462 | ||
7850 | msgid "Malformed configuration, exit ...\n" | ||
7851 | msgstr "Лоше подешавање, излазим ...\n" | ||
7852 | |||
7853 | #: src/util/resolver_api.c:198 | ||
7854 | #, c-format | ||
7855 | msgid "Must specify `%s' for `%s' in configuration!\n" | ||
7856 | msgstr "Морате навести „%s“ за „%s“ у подешавањима!\n" | ||
7857 | |||
7858 | #: src/util/resolver_api.c:216 | ||
7859 | #, c-format | ||
7860 | msgid "Must specify `%s' or numeric IP address for `%s' of `%s' in configuration!\n" | ||
7861 | msgstr "Морате навести „%s“ или бројевну ИП адресу за „%s“ од „%s“ у подешавањима!\n" | ||
7862 | |||
7863 | #: src/util/resolver_api.c:348 | ||
7864 | #, c-format | ||
7865 | msgid "Timeout trying to resolve IP address `%s'.\n" | ||
7866 | msgstr "Истекло је време при покушају решавања ИП адресе „%s“.\n" | ||
7867 | |||
7868 | #: src/util/resolver_api.c:352 | ||
7869 | #, c-format | ||
7870 | msgid "Timeout trying to resolve hostname `%s'.\n" | ||
7871 | msgstr "Истекло је време при покушају решавања назива домаћина „%s“.\n" | ||
7872 | |||
7873 | #: src/util/resolver_api.c:908 | ||
7874 | #, c-format | ||
7875 | msgid "Could not resolve our FQDN : %s\n" | ||
7876 | msgstr "Не могу да решим наш „FQDN“ : %s\n" | ||
7877 | |||
7878 | #: src/util/scheduler.c:813 | ||
7879 | msgid "Looks like we're busy waiting...\n" | ||
7880 | msgstr "Изгледа да смо заузети чекајући...\n" | ||
7881 | |||
7882 | #: src/util/scheduler.c:948 | ||
7883 | #, c-format | ||
7884 | msgid "Attempt to cancel dead task %llu!\n" | ||
7885 | msgstr "Покушах да обришем неактиван задатак %llu!\n" | ||
7886 | |||
7887 | #: src/util/server.c:484 | ||
7888 | #, c-format | ||
7889 | msgid "`%s' failed for port %d (%s).\n" | ||
7890 | msgstr "„%s“ није успело за прикључник %d (%s).\n" | ||
7891 | |||
7892 | #: src/util/server.c:493 | ||
7893 | #, c-format | ||
7894 | msgid "`%s' failed for port %d (%s): address already in use\n" | ||
7895 | msgstr "„%s“ није успело за прикључник %d (%s): адреса је већ у употреби\n" | ||
7896 | |||
7897 | #: src/util/server.c:499 | ||
7898 | #, c-format | ||
7899 | msgid "`%s' failed for `%s': address already in use\n" | ||
7900 | msgstr "„%s“ није успело за „%s“: адреса је већ у употреби\n" | ||
7901 | |||
7902 | #: src/util/server.c:892 | ||
7903 | #, c-format | ||
7904 | msgid "Processing code for message of type %u did not call `GNUNET_SERVER_receive_done' after %s\n" | ||
7905 | msgstr "Обрађивачки код за поруку врсте %u није позвао „GNUNET_SERVER_receive_done“ након „%s“\n" | ||
7906 | |||
7907 | #: src/util/service.c:347 | ||
7908 | #, c-format | ||
7909 | msgid "Unknown address family %d\n" | ||
7910 | msgstr "Непозната породица адресе „%d“\n" | ||
7911 | |||
7912 | #: src/util/service.c:354 | ||
7913 | #, c-format | ||
7914 | msgid "Access from `%s' denied to service `%s'\n" | ||
7915 | msgstr "Приступ из „%s“ је забрањен за услугу „%s“\n" | ||
7916 | |||
7917 | #: src/util/service.c:409 | ||
7918 | #, c-format | ||
7919 | msgid "Could not parse IPv4 network specification `%s' for `%s:%s'\n" | ||
7920 | msgstr "Не могу да обрадим спецификацију ИПв4 мреже „%s“ за `%s:%s'\n" | ||
7921 | |||
7922 | #: src/util/service.c:446 | ||
7923 | #, c-format | ||
7924 | msgid "Could not parse IPv6 network specification `%s' for `%s:%s'\n" | ||
7925 | msgstr "Не могу да обрадим спецификацију ИПв6 мреже „%s“ за `%s:%s'\n" | ||
7926 | |||
7927 | #: src/util/service.c:563 | ||
7928 | #, c-format | ||
7929 | msgid "Disabling IPv6 support for service `%s', failed to create IPv6 socket: %s\n" | ||
7930 | msgstr "Искључујем ИПв6 подршку за услугу „%s“, нисм успео да направим ИПв6 прикључницу: %s\n" | ||
7931 | |||
7932 | #: src/util/service.c:653 | ||
7933 | #, c-format | ||
7934 | msgid "Disabling UNIX domain socket support for service `%s', failed to create UNIX domain socket: %s\n" | ||
7935 | msgstr "Искључујем подршку прикључнице ЈУНИКС домена за услугу „%s“, нисм успео да направим прикључницу ЈУНИКС домена: %s\n" | ||
7936 | |||
7937 | #: src/util/service.c:669 | ||
7938 | #, c-format | ||
7939 | msgid "Have neither PORT nor UNIXPATH for service `%s', but one is required\n" | ||
7940 | msgstr "Немам ни ПРИКЉУЧНИК ни ЈУНИКС_ПУТАЊУ за услугу „%s“, али је једно потребно\n" | ||
7941 | |||
7942 | #: src/util/service.c:903 | ||
7943 | msgid "Could not access a pre-bound socket, will try to bind myself\n" | ||
7944 | msgstr "Не могу да приступим унапред свезаној прикључници, покушаћу да свежем себе самог\n" | ||
7945 | |||
7946 | #: src/util/service.c:952 src/util/service.c:970 | ||
7947 | #, c-format | ||
7948 | msgid "Specified value for `%s' of service `%s' is invalid\n" | ||
7949 | msgstr "Наведена вредност за „%s“ услуге „%s“ је неисправна\n" | ||
7950 | |||
7951 | #: src/util/service.c:995 | ||
7952 | #, c-format | ||
7953 | msgid "Could not access pre-bound socket %u, will try to bind myself\n" | ||
7954 | msgstr "Не могу да приступим унапред свезаној прикључници %u, покушаћу да свежем себе самог\n" | ||
7955 | |||
7956 | #: src/util/service.c:1165 | ||
7957 | #, c-format | ||
7958 | msgid "Failed to start `%s' at `%s'\n" | ||
7959 | msgstr "Нисам успео да покренем „%s“ на „%s“\n" | ||
7960 | |||
7961 | #: src/util/service.c:1207 | ||
7962 | #, c-format | ||
7963 | msgid "Service `%s' runs at %s\n" | ||
7964 | msgstr "Услуга „%s“ ради на „%s“\n" | ||
7965 | |||
7966 | #: src/util/service.c:1256 | ||
7967 | msgid "Service process failed to initialize\n" | ||
7968 | msgstr "Процес услуге није успео да се покрене\n" | ||
7969 | |||
7970 | #: src/util/service.c:1260 | ||
7971 | msgid "Service process could not initialize server function\n" | ||
7972 | msgstr "Процес услуге не може да покрене функцију сервера\n" | ||
7973 | |||
7974 | #: src/util/service.c:1264 | ||
7975 | msgid "Service process failed to report status\n" | ||
7976 | msgstr "Процес услуге није успео да извести о стању\n" | ||
7977 | |||
7978 | #: src/util/service.c:1319 | ||
7979 | msgid "No such user" | ||
7980 | msgstr "Нема таквог корисника" | ||
7981 | |||
7982 | #: src/util/service.c:1332 | ||
7983 | #, c-format | ||
7984 | msgid "Cannot change user/group to `%s': %s\n" | ||
7985 | msgstr "Не могу да променим власника/групу на „%s“: %s\n" | ||
7986 | |||
7987 | #: src/util/service.c:1402 | ||
7988 | msgid "do daemonize (detach from terminal)" | ||
7989 | msgstr "ради демонизацију (откачиње од терминала)" | ||
7990 | |||
7991 | #: src/util/signal.c:89 | ||
7992 | #, c-format | ||
7993 | msgid "signal (%d, %p) returned %d.\n" | ||
7994 | msgstr "сигнал (%d, %p) је дао %d.\n" | ||
7995 | |||
7996 | #: src/util/strings.c:145 | ||
7997 | msgid "b" | ||
7998 | msgstr "b" | ||
7999 | |||
8000 | #: src/util/strings.c:433 | ||
8001 | #, c-format | ||
8002 | msgid "Character sets requested were `%s'->`%s'\n" | ||
8003 | msgstr "Скупови знакова се захтевају где је „%s“–>„%s“\n" | ||
8004 | |||
8005 | #: src/util/strings.c:561 | ||
8006 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" | ||
8007 | msgstr "Нисам успео да раширим „$HOME“: променљива окружења „HOME“ није постављена" | ||
8008 | |||
8009 | #: src/util/strings.c:658 | ||
8010 | msgid "µs" | ||
8011 | msgstr "µs" | ||
8012 | |||
8013 | #: src/util/strings.c:662 | ||
8014 | msgid "forever" | ||
8015 | msgstr "заувек" | ||
8016 | |||
8017 | #: src/util/strings.c:664 | ||
8018 | msgid "0 ms" | ||
8019 | msgstr "0 ms" | ||
8020 | |||
8021 | #: src/util/strings.c:670 | ||
8022 | msgid "ms" | ||
8023 | msgstr "ms" | ||
8024 | |||
8025 | #: src/util/strings.c:676 | ||
8026 | msgid "s" | ||
8027 | msgstr "s" | ||
8028 | |||
8029 | #: src/util/strings.c:682 | ||
8030 | msgid "m" | ||
8031 | msgstr "m" | ||
8032 | |||
8033 | #: src/util/strings.c:688 | ||
8034 | msgid "h" | ||
8035 | msgstr "h" | ||
8036 | |||
8037 | #: src/util/strings.c:695 | ||
8038 | msgid "day" | ||
8039 | msgstr "дан" | ||
8040 | |||
8041 | #: src/util/strings.c:697 | ||
8042 | msgid "days" | ||
8043 | msgstr "дана" | ||
8044 | |||
8045 | #: src/util/strings.c:726 | ||
8046 | msgid "end of time" | ||
8047 | msgstr "крај времена" | ||
8048 | |||
8049 | #: src/util/strings.c:1159 | ||
8050 | msgid "IPv6 address did not start with `['\n" | ||
8051 | msgstr "ИПв6 адреса не почиње са [\n" | ||
8052 | |||
8053 | #: src/util/strings.c:1167 | ||
8054 | msgid "IPv6 address did contain ':' to separate port number\n" | ||
8055 | msgstr "ИПв6 адреса садржи : за раздвајање броја прикључника\n" | ||
8056 | |||
8057 | #: src/util/strings.c:1173 | ||
8058 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" | ||
8059 | msgstr "ИПв6 адреса садржи ] пре : за раздвајање броја прикључника\n" | ||
8060 | |||
8061 | #: src/util/strings.c:1180 | ||
8062 | msgid "IPv6 address did contain a valid port number after the last ':'\n" | ||
8063 | msgstr "ИПв6 адреса садржи исправан број прикључника након последње „:“\n" | ||
8064 | |||
8065 | #: src/util/strings.c:1189 | ||
8066 | #, c-format | ||
8067 | msgid "Invalid IPv6 address `%s': %s\n" | ||
8068 | msgstr "Неисправна ИПв6 адреса „%s“: %s\n" | ||
8069 | |||
8070 | #: src/util/strings.c:1395 src/util/strings.c:1411 | ||
8071 | msgid "Port not in range\n" | ||
8072 | msgstr "Прикључник није у опсегу\n" | ||
8073 | |||
8074 | #: src/util/strings.c:1420 | ||
8075 | #, c-format | ||
8076 | msgid "Malformed port policy `%s'\n" | ||
8077 | msgstr "Лоша политика прикључника „%s“\n" | ||
8078 | |||
8079 | #: src/util/strings.c:1503 src/util/strings.c:1534 src/util/strings.c:1582 | ||
8080 | #: src/util/strings.c:1603 | ||
8081 | #, c-format | ||
8082 | msgid "Invalid format for IP: `%s'\n" | ||
8083 | msgstr "Неисправан формат за ИП: „%s“\n" | ||
8084 | |||
8085 | #: src/util/strings.c:1560 | ||
8086 | #, c-format | ||
8087 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." | ||
8088 | msgstr "Неисправна напомена мреже („/%d“ није исправно у ИПв4 ЦИДР-у)." | ||
8089 | |||
8090 | #: src/util/strings.c:1612 | ||
8091 | #, c-format | ||
8092 | msgid "Invalid format: `%s'\n" | ||
8093 | msgstr "Неисправан формат: „%s“\n" | ||
8094 | |||
8095 | #: src/util/strings.c:1664 | ||
8096 | #, c-format | ||
8097 | msgid "Invalid network notation (does not end with ';': `%s')\n" | ||
8098 | msgstr "Неисправна напомена мреже (не завршава се са „;“: „%s“)\n" | ||
8099 | |||
8100 | #: src/util/strings.c:1714 | ||
8101 | #, c-format | ||
8102 | msgid "Wrong format `%s' for netmask\n" | ||
8103 | msgstr "Погрешан формат „%s“ за мрежну маску\n" | ||
8104 | |||
8105 | #: src/util/strings.c:1745 | ||
8106 | #, c-format | ||
8107 | msgid "Wrong format `%s' for network\n" | ||
8108 | msgstr "Погрешан формат „%s“ за мрежу\n" | ||
8109 | |||
8110 | #: src/vpn/gnunet-service-vpn.c:550 src/vpn/gnunet-service-vpn.c:1086 | ||
8111 | msgid "# Active channels" | ||
8112 | msgstr "# Активни канали" | ||
8113 | |||
8114 | #: src/vpn/gnunet-service-vpn.c:642 | ||
8115 | msgid "# Bytes given to mesh for transmission" | ||
8116 | msgstr "# Бајтови су дати мешу за преношење" | ||
8117 | |||
8118 | #: src/vpn/gnunet-service-vpn.c:680 | ||
8119 | msgid "# Bytes dropped in mesh queue (overflow)" | ||
8120 | msgstr "# Бајтови су одбачени у реду меша (прекорачење)" | ||
8121 | |||
8122 | #: src/vpn/gnunet-service-vpn.c:753 | ||
8123 | msgid "# Mesh channels created" | ||
8124 | msgstr "# Меш канали су направљени" | ||
8125 | |||
8126 | #: src/vpn/gnunet-service-vpn.c:784 | ||
8127 | msgid "Failed to setup mesh channel!\n" | ||
8128 | msgstr "Нисам успео да поставим меш канал!\n" | ||
8129 | |||
8130 | #: src/vpn/gnunet-service-vpn.c:978 | ||
8131 | #, c-format | ||
8132 | msgid "Protocol %u not supported, dropping\n" | ||
8133 | msgstr "Протокол %u није подржан, одбацујем\n" | ||
8134 | |||
8135 | #: src/vpn/gnunet-service-vpn.c:1305 | ||
8136 | msgid "# ICMPv4 packets dropped (not allowed)" | ||
8137 | msgstr "# ICMPv4 пакети су одбачени (нису дозвољени)" | ||
8138 | |||
8139 | #: src/vpn/gnunet-service-vpn.c:1326 | ||
8140 | msgid "# ICMPv6 packets dropped (not allowed)" | ||
8141 | msgstr "# ICMPv6 пакети су одбачени (нису дозвољени)" | ||
8142 | |||
8143 | #: src/vpn/gnunet-service-vpn.c:1531 | ||
8144 | msgid "# Packets received from TUN interface" | ||
8145 | msgstr "# Пакети су примљени са ТУН сучеља" | ||
8146 | |||
8147 | #: src/vpn/gnunet-service-vpn.c:1564 src/vpn/gnunet-service-vpn.c:1600 | ||
8148 | #, c-format | ||
8149 | msgid "Packet received for unmapped destination `%s' (dropping it)\n" | ||
8150 | msgstr "Пакет је примљен за одмапирано одредиште „%s“ (одбацујем га)\n" | ||
8151 | |||
8152 | #: src/vpn/gnunet-service-vpn.c:1610 | ||
8153 | msgid "Received IPv4 packet with options (dropping it)\n" | ||
8154 | msgstr "Примљен је ИПв4 пакет са опцијама (одбацујем га)\n" | ||
8155 | |||
8156 | #: src/vpn/gnunet-service-vpn.c:1624 | ||
8157 | #, c-format | ||
8158 | msgid "Received packet of unknown protocol %d from TUN (dropping it)\n" | ||
8159 | msgstr "Примљен је пакет непознатог протокола %d са ТУН-а (одбацујем га)\n" | ||
8160 | |||
8161 | #: src/vpn/gnunet-service-vpn.c:1706 | ||
8162 | msgid "# ICMP packets received from mesh" | ||
8163 | msgstr "# ИЦМП пакети су примљени од меша" | ||
8164 | |||
8165 | #: src/vpn/gnunet-service-vpn.c:2045 | ||
8166 | msgid "# UDP packets received from mesh" | ||
8167 | msgstr "# УДП пакети су примљени од меша" | ||
8168 | |||
8169 | #: src/vpn/gnunet-service-vpn.c:2200 | ||
8170 | msgid "# TCP packets received from mesh" | ||
8171 | msgstr "# ТЦП пакети су примљени од меша" | ||
8172 | |||
8173 | #: src/vpn/gnunet-service-vpn.c:2351 | ||
8174 | msgid "Failed to find unallocated IPv4 address in VPN's range\n" | ||
8175 | msgstr "Нисам успео да нађем недодељену ИПв4 адресу у опсегу ВПН-а\n" | ||
8176 | |||
8177 | #: src/vpn/gnunet-service-vpn.c:2406 | ||
8178 | msgid "Failed to find unallocated IPv6 address in VPN's range\n" | ||
8179 | msgstr "Нисам успео да нађем недодељену ИПв6 адресу у опсегу ВПН-а\n" | ||
8180 | |||
8181 | #: src/vpn/gnunet-service-vpn.c:2447 src/vpn/gnunet-service-vpn.c:2663 | ||
8182 | msgid "# Active destinations" | ||
8183 | msgstr "# Активна одредишта" | ||
8184 | |||
8185 | #: src/vpn/gnunet-service-vpn.c:2715 | ||
8186 | msgid "Failed to allocate IP address for new destination\n" | ||
8187 | msgstr "Нисам успео да доделим ИП адресу за ново одредиште\n" | ||
8188 | |||
8189 | #: src/vpn/gnunet-service-vpn.c:2982 | ||
8190 | msgid "Must specify valid IPv6 address" | ||
8191 | msgstr "Морате навести исправну ИПв6 адресу" | ||
8192 | |||
8193 | #: src/vpn/gnunet-service-vpn.c:3006 | ||
8194 | msgid "Must specify valid IPv6 mask" | ||
8195 | msgstr "Морате навести исправну ИПв6 маску" | ||
8196 | |||
8197 | #: src/vpn/gnunet-service-vpn.c:3014 | ||
8198 | msgid "IPv6 support disabled as this system does not support IPv6\n" | ||
8199 | msgstr "ИПв6 подршка је искључена јер овај систем не подржава ИПв6\n" | ||
8200 | |||
8201 | #: src/vpn/gnunet-service-vpn.c:3027 | ||
8202 | msgid "Must specify valid IPv4 address" | ||
8203 | msgstr "Морате навести исправну ИПв4 адресу" | ||
8204 | |||
8205 | #: src/vpn/gnunet-service-vpn.c:3040 | ||
8206 | msgid "Must specify valid IPv4 mask" | ||
8207 | msgstr "Морате навести исправну ИПв4 маску" | ||
8208 | |||
8209 | #: src/vpn/gnunet-service-vpn.c:3050 | ||
8210 | msgid "IPv4 support disabled as this system does not support IPv4\n" | ||
8211 | msgstr "ИПв4 подршка је искључена јер овај систем не подржава ИПв4\n" | ||
8212 | |||
8213 | #: src/vpn/gnunet-vpn.c:147 | ||
8214 | msgid "Error creating tunnel\n" | ||
8215 | msgstr "Грешка стварања тунела\n" | ||
8216 | |||
8217 | #: src/vpn/gnunet-vpn.c:190 src/vpn/gnunet-vpn.c:221 | ||
8218 | #, c-format | ||
8219 | msgid "Option `%s' makes no sense with option `%s'.\n" | ||
8220 | msgstr "Опција „%s“ нема смисла са опцијом „%s“.\n" | ||
8221 | |||
8222 | #: src/vpn/gnunet-vpn.c:203 | ||
8223 | #, c-format | ||
8224 | msgid "Option `%s' or `%s' is required.\n" | ||
8225 | msgstr "Опција „%s“ или „%s“ је потребна.\n" | ||
8226 | |||
8227 | #: src/vpn/gnunet-vpn.c:215 | ||
8228 | #, c-format | ||
8229 | msgid "Option `%s' or `%s' is required when using option `%s'.\n" | ||
8230 | msgstr "Опција „%s“ или „%s“ се захтева приликом коришћења опције „%s“.\n" | ||
8231 | |||
8232 | #: src/vpn/gnunet-vpn.c:235 | ||
8233 | #, c-format | ||
8234 | msgid "`%s' is not a valid peer identifier.\n" | ||
8235 | msgstr "„%s“ није исправан одредник парњака.\n" | ||
8236 | |||
8237 | #: src/vpn/gnunet-vpn.c:255 | ||
8238 | #, c-format | ||
8239 | msgid "`%s' is not a valid IP address.\n" | ||
8240 | msgstr "„%s“ није исправна ИП адреса.\n" | ||
8241 | |||
8242 | #: src/vpn/gnunet-vpn.c:290 | ||
8243 | msgid "request that result should be an IPv4 address" | ||
8244 | msgstr "захтева да резултат треба да буде ИПв4 адреса" | ||
8245 | |||
8246 | #: src/vpn/gnunet-vpn.c:293 | ||
8247 | msgid "request that result should be an IPv6 address" | ||
8248 | msgstr "захтева да резултат треба да буде ИПв6 адреса" | ||
8249 | |||
8250 | #: src/vpn/gnunet-vpn.c:296 | ||
8251 | msgid "how long should the mapping be valid for new tunnels?" | ||
8252 | msgstr "колико дуго мапирање треба бити важеће за нове тунеле?" | ||
8253 | |||
8254 | #: src/vpn/gnunet-vpn.c:299 | ||
8255 | msgid "destination IP for the tunnel" | ||
8256 | msgstr "ИП одредишта за тунел" | ||
8257 | |||
8258 | #: src/vpn/gnunet-vpn.c:302 | ||
8259 | msgid "peer offering the service we would like to access" | ||
8260 | msgstr "парњак који нуди услугу којој желимо да приступимо" | ||
8261 | |||
8262 | #: src/vpn/gnunet-vpn.c:305 | ||
8263 | msgid "name of the service we would like to access" | ||
8264 | msgstr "назив услуге којој желимо да приступимо" | ||
8265 | |||
8266 | #: src/vpn/gnunet-vpn.c:308 | ||
8267 | msgid "service is offered via TCP" | ||
8268 | msgstr "услуга се нуди путем ТЦП-а" | ||
8269 | |||
8270 | #: src/vpn/gnunet-vpn.c:311 | ||
8271 | msgid "service is offered via UDP" | ||
8272 | msgstr "услуга се нуди путем УДП-ом" | ||
8273 | |||
8274 | #: src/vpn/gnunet-vpn.c:323 | ||
8275 | msgid "Setup tunnels via VPN." | ||
8276 | msgstr "Поставља тунеле путем ВПН-а." | ||
8277 | |||
8278 | #: src/include/gnunet_common.h:566 src/include/gnunet_common.h:573 | ||
8279 | #: src/include/gnunet_common.h:581 | ||
8280 | #, c-format | ||
8281 | msgid "Assertion failed at %s:%d.\n" | ||
8282 | msgstr "Потврђивање није успело на %s:%d.\n" | ||
8283 | |||
8284 | #: src/include/gnunet_common.h:593 | ||
8285 | #, c-format | ||
8286 | msgid "External protocol violation detected at %s:%d.\n" | ||
8287 | msgstr "Повреда спољног протокола је откривена на %s:%d.\n" | ||
8288 | |||
8289 | #: src/include/gnunet_common.h:620 src/include/gnunet_common.h:629 | ||
8290 | #, c-format | ||
8291 | msgid "`%s' failed on file `%s' at %s:%d with error: %s\n" | ||
8292 | msgstr "„%s“ није успело на датотеци „%s“ на %s:%d са грешком: %s\n" | ||
@@ -7,7 +7,7 @@ msgid "" | |||
7 | msgstr "" | 7 | msgstr "" |
8 | "Project-Id-Version: GNUnet 0.7.0b\n" | 8 | "Project-Id-Version: GNUnet 0.7.0b\n" |
9 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" | 9 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" |
10 | "POT-Creation-Date: 2020-09-06 10:07+0200\n" | 10 | "POT-Creation-Date: 2020-10-13 16:12+0200\n" |
11 | "PO-Revision-Date: 2006-01-21 17:16+0100\n" | 11 | "PO-Revision-Date: 2006-01-21 17:16+0100\n" |
12 | "Last-Translator: Daniel Nylander <po@danielnylander.se>\n" | 12 | "Last-Translator: Daniel Nylander <po@danielnylander.se>\n" |
13 | "Language-Team: Swedish <tp-sv@listor.tp-sv.se>\n" | 13 | "Language-Team: Swedish <tp-sv@listor.tp-sv.se>\n" |
@@ -27,8 +27,8 @@ msgid "Issuer public key `%s' is not well-formed\n" | |||
27 | msgstr "Ogiltigt argument: \"%s\"\n" | 27 | msgstr "Ogiltigt argument: \"%s\"\n" |
28 | 28 | ||
29 | #: src/abd/gnunet-abd.c:560 src/abd/gnunet-service-abd.c:1747 | 29 | #: src/abd/gnunet-abd.c:560 src/abd/gnunet-service-abd.c:1747 |
30 | #: src/namestore/gnunet-namestore.c:1001 | ||
31 | #: src/namestore/gnunet-namestore-fcfsd.c:1154 | 30 | #: src/namestore/gnunet-namestore-fcfsd.c:1154 |
31 | #: src/namestore/gnunet-namestore.c:1001 | ||
32 | #, fuzzy, c-format | 32 | #, fuzzy, c-format |
33 | msgid "Failed to connect to namestore\n" | 33 | msgid "Failed to connect to namestore\n" |
34 | msgstr "Misslyckades att ansluta till gnunetd.\n" | 34 | msgstr "Misslyckades att ansluta till gnunetd.\n" |
@@ -502,82 +502,14 @@ msgstr "" | |||
502 | msgid "Initiating shutdown as requested by client.\n" | 502 | msgid "Initiating shutdown as requested by client.\n" |
503 | msgstr "" | 503 | msgstr "" |
504 | 504 | ||
505 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | 505 | #: src/ats-tests/ats-testing-log.c:896 |
506 | #, c-format | 506 | msgid "Stop logging\n" |
507 | msgid "" | ||
508 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | ||
509 | "%llu\n" | ||
510 | msgstr "" | ||
511 | |||
512 | #: src/ats/gnunet-ats-solver-eval.c:3011 | ||
513 | #, c-format | ||
514 | msgid "" | ||
515 | "No outbound quota configured for network `%s', assigning default bandwidth " | ||
516 | "%llu\n" | ||
517 | msgstr "" | ||
518 | |||
519 | #: src/ats/gnunet-ats-solver-eval.c:3063 | ||
520 | #, c-format | ||
521 | msgid "" | ||
522 | "No outbound quota configure for network `%s', assigning default bandwidth " | ||
523 | "%llu\n" | ||
524 | msgstr "" | ||
525 | |||
526 | #: src/ats/gnunet-ats-solver-eval.c:3552 src/ats-tests/gnunet-solver-eval.c:997 | ||
527 | msgid "solver to use" | ||
528 | msgstr "" | ||
529 | |||
530 | #: src/ats/gnunet-ats-solver-eval.c:3557 | ||
531 | #: src/ats-tests/gnunet-solver-eval.c:1003 | ||
532 | #: src/ats-tests/gnunet-solver-eval.c:1008 | ||
533 | msgid "experiment to use" | ||
534 | msgstr "" | ||
535 | |||
536 | #: src/ats/gnunet-ats-solver-eval.c:3564 | ||
537 | #, fuzzy | ||
538 | msgid "print logging" | ||
539 | msgstr "Startade samling \"%s\".\n" | ||
540 | |||
541 | #: src/ats/gnunet-ats-solver-eval.c:3569 | ||
542 | msgid "save logging to disk" | ||
543 | msgstr "" | ||
544 | |||
545 | #: src/ats/gnunet-ats-solver-eval.c:3574 | ||
546 | msgid "disable normalization" | ||
547 | msgstr "" | ||
548 | |||
549 | #: src/ats/gnunet-service-ats_plugins.c:326 | ||
550 | #, c-format | ||
551 | msgid "" | ||
552 | "Could not load %s quota for network `%s': `%s', assigning default bandwidth " | ||
553 | "%llu\n" | ||
554 | msgstr "" | ||
555 | |||
556 | #: src/ats/gnunet-service-ats_plugins.c:336 | ||
557 | #, c-format | ||
558 | msgid "%s quota configured for network `%s' is %llu\n" | ||
559 | msgstr "" | ||
560 | |||
561 | #: src/ats/gnunet-service-ats_plugins.c:382 | ||
562 | #, c-format | ||
563 | msgid "" | ||
564 | "No %s-quota configured for network `%s', assigning default bandwidth %llu\n" | ||
565 | msgstr "" | 507 | msgstr "" |
566 | 508 | ||
567 | #: src/ats/gnunet-service-ats_plugins.c:474 | 509 | #: src/ats-tests/ats-testing-log.c:952 |
568 | #, fuzzy, c-format | ||
569 | msgid "Failed to initialize solver `%s'!\n" | ||
570 | msgstr "Kunde inte initiera SQLite.\n" | ||
571 | |||
572 | #: src/ats/plugin_ats_proportional.c:1142 | ||
573 | #, fuzzy, c-format | ||
574 | msgid "Invalid %s configuration %f \n" | ||
575 | msgstr "Kunde inte spara konfigurationsfil \"%s\":" | ||
576 | |||
577 | #: src/ats/plugin_ats_proportional.c:1165 | ||
578 | #, fuzzy, c-format | 510 | #, fuzzy, c-format |
579 | msgid "Invalid %s configuration %f\n" | 511 | msgid "Start logging `%s'\n" |
580 | msgstr "Kunde inte spara konfigurationsfil \"%s\":" | 512 | msgstr "Startade samling \"%s\".\n" |
581 | 513 | ||
582 | #: src/ats-tests/ats-testing.c:420 | 514 | #: src/ats-tests/ats-testing.c:420 |
583 | #, c-format | 515 | #, c-format |
@@ -589,15 +521,6 @@ msgstr "" | |||
589 | msgid "Failed to connect master peer [%u] with slave [%u]\n" | 521 | msgid "Failed to connect master peer [%u] with slave [%u]\n" |
590 | msgstr "Misslyckades att ansluta till gnunetd.\n" | 522 | msgstr "Misslyckades att ansluta till gnunetd.\n" |
591 | 523 | ||
592 | #: src/ats-tests/ats-testing-log.c:896 | ||
593 | msgid "Stop logging\n" | ||
594 | msgstr "" | ||
595 | |||
596 | #: src/ats-tests/ats-testing-log.c:952 | ||
597 | #, fuzzy, c-format | ||
598 | msgid "Start logging `%s'\n" | ||
599 | msgstr "Startade samling \"%s\".\n" | ||
600 | |||
601 | #: src/ats-tests/gnunet-ats-sim.c:92 | 524 | #: src/ats-tests/gnunet-ats-sim.c:92 |
602 | #, c-format | 525 | #, c-format |
603 | msgid "" | 526 | msgid "" |
@@ -605,6 +528,16 @@ msgid "" | |||
605 | "= %u KiB/s\n" | 528 | "= %u KiB/s\n" |
606 | msgstr "" | 529 | msgstr "" |
607 | 530 | ||
531 | #: src/ats-tests/gnunet-solver-eval.c:997 src/ats/gnunet-ats-solver-eval.c:3552 | ||
532 | msgid "solver to use" | ||
533 | msgstr "" | ||
534 | |||
535 | #: src/ats-tests/gnunet-solver-eval.c:1003 | ||
536 | #: src/ats-tests/gnunet-solver-eval.c:1008 | ||
537 | #: src/ats/gnunet-ats-solver-eval.c:3557 | ||
538 | msgid "experiment to use" | ||
539 | msgstr "" | ||
540 | |||
608 | #: src/ats-tool/gnunet-ats.c:299 | 541 | #: src/ats-tool/gnunet-ats.c:299 |
609 | #, c-format | 542 | #, c-format |
610 | msgid "%u address resolutions had a timeout\n" | 543 | msgid "%u address resolutions had a timeout\n" |
@@ -726,6 +659,73 @@ msgstr "" | |||
726 | msgid "Print information about ATS state" | 659 | msgid "Print information about ATS state" |
727 | msgstr "Skriv ut information om GNUnets motparter." | 660 | msgstr "Skriv ut information om GNUnets motparter." |
728 | 661 | ||
662 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | ||
663 | #, c-format | ||
664 | msgid "" | ||
665 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | ||
666 | "%llu\n" | ||
667 | msgstr "" | ||
668 | |||
669 | #: src/ats/gnunet-ats-solver-eval.c:3011 | ||
670 | #, c-format | ||
671 | msgid "" | ||
672 | "No outbound quota configured for network `%s', assigning default bandwidth " | ||
673 | "%llu\n" | ||
674 | msgstr "" | ||
675 | |||
676 | #: src/ats/gnunet-ats-solver-eval.c:3063 | ||
677 | #, c-format | ||
678 | msgid "" | ||
679 | "No outbound quota configure for network `%s', assigning default bandwidth " | ||
680 | "%llu\n" | ||
681 | msgstr "" | ||
682 | |||
683 | #: src/ats/gnunet-ats-solver-eval.c:3564 | ||
684 | #, fuzzy | ||
685 | msgid "print logging" | ||
686 | msgstr "Startade samling \"%s\".\n" | ||
687 | |||
688 | #: src/ats/gnunet-ats-solver-eval.c:3569 | ||
689 | msgid "save logging to disk" | ||
690 | msgstr "" | ||
691 | |||
692 | #: src/ats/gnunet-ats-solver-eval.c:3574 | ||
693 | msgid "disable normalization" | ||
694 | msgstr "" | ||
695 | |||
696 | #: src/ats/gnunet-service-ats_plugins.c:326 | ||
697 | #, c-format | ||
698 | msgid "" | ||
699 | "Could not load %s quota for network `%s': `%s', assigning default bandwidth " | ||
700 | "%llu\n" | ||
701 | msgstr "" | ||
702 | |||
703 | #: src/ats/gnunet-service-ats_plugins.c:336 | ||
704 | #, c-format | ||
705 | msgid "%s quota configured for network `%s' is %llu\n" | ||
706 | msgstr "" | ||
707 | |||
708 | #: src/ats/gnunet-service-ats_plugins.c:382 | ||
709 | #, c-format | ||
710 | msgid "" | ||
711 | "No %s-quota configured for network `%s', assigning default bandwidth %llu\n" | ||
712 | msgstr "" | ||
713 | |||
714 | #: src/ats/gnunet-service-ats_plugins.c:474 | ||
715 | #, fuzzy, c-format | ||
716 | msgid "Failed to initialize solver `%s'!\n" | ||
717 | msgstr "Kunde inte initiera SQLite.\n" | ||
718 | |||
719 | #: src/ats/plugin_ats_proportional.c:1142 | ||
720 | #, fuzzy, c-format | ||
721 | msgid "Invalid %s configuration %f \n" | ||
722 | msgstr "Kunde inte spara konfigurationsfil \"%s\":" | ||
723 | |||
724 | #: src/ats/plugin_ats_proportional.c:1165 | ||
725 | #, fuzzy, c-format | ||
726 | msgid "Invalid %s configuration %f\n" | ||
727 | msgstr "Kunde inte spara konfigurationsfil \"%s\":" | ||
728 | |||
729 | #: src/auction/gnunet-auction-create.c:163 | 729 | #: src/auction/gnunet-auction-create.c:163 |
730 | msgid "description of the item to be sold" | 730 | msgid "description of the item to be sold" |
731 | msgstr "" | 731 | msgstr "" |
@@ -865,6 +865,28 @@ msgstr "" | |||
865 | msgid "Connection to conversation service lost, trying to reconnect\n" | 865 | msgid "Connection to conversation service lost, trying to reconnect\n" |
866 | msgstr "" | 866 | msgstr "" |
867 | 867 | ||
868 | #: src/conversation/gnunet-conversation-test.c:120 | ||
869 | #, c-format | ||
870 | msgid "" | ||
871 | "\n" | ||
872 | "End of transmission. Have a GNU day.\n" | ||
873 | msgstr "" | ||
874 | |||
875 | #: src/conversation/gnunet-conversation-test.c:146 | ||
876 | #, c-format | ||
877 | msgid "" | ||
878 | "\n" | ||
879 | "We are now playing your recording back. If you can hear it, your audio " | ||
880 | "settings are working..." | ||
881 | msgstr "" | ||
882 | |||
883 | #: src/conversation/gnunet-conversation-test.c:218 | ||
884 | #, c-format | ||
885 | msgid "" | ||
886 | "We will now be recording you for %s. After that time, the recording will be " | ||
887 | "played back to you..." | ||
888 | msgstr "" | ||
889 | |||
868 | #: src/conversation/gnunet-conversation.c:264 | 890 | #: src/conversation/gnunet-conversation.c:264 |
869 | #, c-format | 891 | #, c-format |
870 | msgid "Incoming call from `%s'. Please /accept %u or /cancel %u the call.\n" | 892 | msgid "Incoming call from `%s'. Please /accept %u or /cancel %u the call.\n" |
@@ -1124,30 +1146,8 @@ msgstr "" | |||
1124 | msgid "Enables having a conversation with other GNUnet users." | 1146 | msgid "Enables having a conversation with other GNUnet users." |
1125 | msgstr "" | 1147 | msgstr "" |
1126 | 1148 | ||
1127 | #: src/conversation/gnunet-conversation-test.c:120 | ||
1128 | #, c-format | ||
1129 | msgid "" | ||
1130 | "\n" | ||
1131 | "End of transmission. Have a GNU day.\n" | ||
1132 | msgstr "" | ||
1133 | |||
1134 | #: src/conversation/gnunet-conversation-test.c:146 | ||
1135 | #, c-format | ||
1136 | msgid "" | ||
1137 | "\n" | ||
1138 | "We are now playing your recording back. If you can hear it, your audio " | ||
1139 | "settings are working..." | ||
1140 | msgstr "" | ||
1141 | |||
1142 | #: src/conversation/gnunet-conversation-test.c:218 | ||
1143 | #, c-format | ||
1144 | msgid "" | ||
1145 | "We will now be recording you for %s. After that time, the recording will be " | ||
1146 | "played back to you..." | ||
1147 | msgstr "" | ||
1148 | |||
1149 | #: src/conversation/gnunet_gst.c:664 | ||
1150 | #: src/conversation/gnunet-helper-audio-playback-gst.c:363 | 1149 | #: src/conversation/gnunet-helper-audio-playback-gst.c:363 |
1150 | #: src/conversation/gnunet_gst.c:664 | ||
1151 | #, c-format | 1151 | #, c-format |
1152 | msgid "Read error from STDIN: %d %s\n" | 1152 | msgid "Read error from STDIN: %d %s\n" |
1153 | msgstr "" | 1153 | msgstr "" |
@@ -1975,17 +1975,17 @@ msgstr "\"%s\" till \"%s\" misslyckades vid %s:%d med fel: %s\n" | |||
1975 | msgid "Mysql database running\n" | 1975 | msgid "Mysql database running\n" |
1976 | msgstr "" | 1976 | msgstr "" |
1977 | 1977 | ||
1978 | #: src/datastore/plugin_datastore_postgres.c:278 | 1978 | #: src/datastore/plugin_datastore_postgres.c:284 |
1979 | #: src/datastore/plugin_datastore_postgres.c:891 | 1979 | #: src/datastore/plugin_datastore_postgres.c:897 |
1980 | msgid "Postgress exec failure" | 1980 | msgid "Postgress exec failure" |
1981 | msgstr "" | 1981 | msgstr "" |
1982 | 1982 | ||
1983 | #: src/datastore/plugin_datastore_postgres.c:852 | 1983 | #: src/datastore/plugin_datastore_postgres.c:858 |
1984 | #, fuzzy | 1984 | #, fuzzy |
1985 | msgid "Failed to drop table from database.\n" | 1985 | msgid "Failed to drop table from database.\n" |
1986 | msgstr "Misslyckades att ta emot svar till \"%s\" meddelande från gnunetd\n" | 1986 | msgstr "Misslyckades att ta emot svar till \"%s\" meddelande från gnunetd\n" |
1987 | 1987 | ||
1988 | #: src/datastore/plugin_datastore_postgres.c:950 | 1988 | #: src/datastore/plugin_datastore_postgres.c:956 |
1989 | msgid "Postgres database running\n" | 1989 | msgid "Postgres database running\n" |
1990 | msgstr "" | 1990 | msgstr "" |
1991 | 1991 | ||
@@ -2093,54 +2093,6 @@ msgstr "" | |||
2093 | msgid "Prints all packets that go through the DHT." | 2093 | msgid "Prints all packets that go through the DHT." |
2094 | msgstr "" | 2094 | msgstr "" |
2095 | 2095 | ||
2096 | #: src/dht/gnunet_dht_profiler.c:922 src/testbed/gnunet-testbed-profiler.c:255 | ||
2097 | #, fuzzy, c-format | ||
2098 | msgid "Exiting as the number of peers is %u\n" | ||
2099 | msgstr "Maximalt antal chattklienter uppnått.\n" | ||
2100 | |||
2101 | #: src/dht/gnunet_dht_profiler.c:955 src/rps/gnunet-rps-profiler.c:3194 | ||
2102 | #, fuzzy | ||
2103 | msgid "number of peers to start" | ||
2104 | msgstr "antal iterationer" | ||
2105 | |||
2106 | #: src/dht/gnunet_dht_profiler.c:961 | ||
2107 | msgid "number of PUTs to perform per peer" | ||
2108 | msgstr "" | ||
2109 | |||
2110 | #: src/dht/gnunet_dht_profiler.c:967 src/nse/gnunet-nse-profiler.c:872 | ||
2111 | #: src/testbed/gnunet-testbed-profiler.c:305 | ||
2112 | msgid "name of the file with the login information for the testbed" | ||
2113 | msgstr "" | ||
2114 | |||
2115 | #: src/dht/gnunet_dht_profiler.c:973 | ||
2116 | msgid "delay between rounds for collecting statistics (default: 30 sec)" | ||
2117 | msgstr "" | ||
2118 | |||
2119 | #: src/dht/gnunet_dht_profiler.c:979 | ||
2120 | msgid "delay to start doing PUTs (default: 1 sec)" | ||
2121 | msgstr "" | ||
2122 | |||
2123 | #: src/dht/gnunet_dht_profiler.c:985 | ||
2124 | msgid "delay to start doing GETs (default: 5 min)" | ||
2125 | msgstr "" | ||
2126 | |||
2127 | #: src/dht/gnunet_dht_profiler.c:990 | ||
2128 | msgid "replication degree for DHT PUTs" | ||
2129 | msgstr "" | ||
2130 | |||
2131 | #: src/dht/gnunet_dht_profiler.c:996 | ||
2132 | msgid "chance that a peer is selected at random for PUTs" | ||
2133 | msgstr "" | ||
2134 | |||
2135 | #: src/dht/gnunet_dht_profiler.c:1002 | ||
2136 | msgid "timeout for DHT PUT and GET requests (default: 1 min)" | ||
2137 | msgstr "" | ||
2138 | |||
2139 | #: src/dht/gnunet_dht_profiler.c:1023 | ||
2140 | #, fuzzy | ||
2141 | msgid "Measure quality and performance of the DHT service." | ||
2142 | msgstr "Kan inte tillgå tjänsten" | ||
2143 | |||
2144 | #: src/dht/gnunet-dht-put.c:133 | 2096 | #: src/dht/gnunet-dht-put.c:133 |
2145 | msgid "Must provide KEY and DATA for DHT put!\n" | 2097 | msgid "Must provide KEY and DATA for DHT put!\n" |
2146 | msgstr "" | 2098 | msgstr "" |
@@ -2411,6 +2363,54 @@ msgstr "" | |||
2411 | msgid "# DHT requests combined" | 2363 | msgid "# DHT requests combined" |
2412 | msgstr "# byte mottogs via TCP" | 2364 | msgstr "# byte mottogs via TCP" |
2413 | 2365 | ||
2366 | #: src/dht/gnunet_dht_profiler.c:922 src/testbed/gnunet-testbed-profiler.c:255 | ||
2367 | #, fuzzy, c-format | ||
2368 | msgid "Exiting as the number of peers is %u\n" | ||
2369 | msgstr "Maximalt antal chattklienter uppnått.\n" | ||
2370 | |||
2371 | #: src/dht/gnunet_dht_profiler.c:955 src/rps/gnunet-rps-profiler.c:3194 | ||
2372 | #, fuzzy | ||
2373 | msgid "number of peers to start" | ||
2374 | msgstr "antal iterationer" | ||
2375 | |||
2376 | #: src/dht/gnunet_dht_profiler.c:961 | ||
2377 | msgid "number of PUTs to perform per peer" | ||
2378 | msgstr "" | ||
2379 | |||
2380 | #: src/dht/gnunet_dht_profiler.c:967 src/nse/gnunet-nse-profiler.c:872 | ||
2381 | #: src/testbed/gnunet-testbed-profiler.c:305 | ||
2382 | msgid "name of the file with the login information for the testbed" | ||
2383 | msgstr "" | ||
2384 | |||
2385 | #: src/dht/gnunet_dht_profiler.c:973 | ||
2386 | msgid "delay between rounds for collecting statistics (default: 30 sec)" | ||
2387 | msgstr "" | ||
2388 | |||
2389 | #: src/dht/gnunet_dht_profiler.c:979 | ||
2390 | msgid "delay to start doing PUTs (default: 1 sec)" | ||
2391 | msgstr "" | ||
2392 | |||
2393 | #: src/dht/gnunet_dht_profiler.c:985 | ||
2394 | msgid "delay to start doing GETs (default: 5 min)" | ||
2395 | msgstr "" | ||
2396 | |||
2397 | #: src/dht/gnunet_dht_profiler.c:990 | ||
2398 | msgid "replication degree for DHT PUTs" | ||
2399 | msgstr "" | ||
2400 | |||
2401 | #: src/dht/gnunet_dht_profiler.c:996 | ||
2402 | msgid "chance that a peer is selected at random for PUTs" | ||
2403 | msgstr "" | ||
2404 | |||
2405 | #: src/dht/gnunet_dht_profiler.c:1002 | ||
2406 | msgid "timeout for DHT PUT and GET requests (default: 1 min)" | ||
2407 | msgstr "" | ||
2408 | |||
2409 | #: src/dht/gnunet_dht_profiler.c:1023 | ||
2410 | #, fuzzy | ||
2411 | msgid "Measure quality and performance of the DHT service." | ||
2412 | msgstr "Kan inte tillgå tjänsten" | ||
2413 | |||
2414 | #: src/dht/plugin_block_dht.c:189 | 2414 | #: src/dht/plugin_block_dht.c:189 |
2415 | #, fuzzy, c-format | 2415 | #, fuzzy, c-format |
2416 | msgid "Block not of type %u\n" | 2416 | msgid "Block not of type %u\n" |
@@ -3362,15 +3362,6 @@ msgid "" | |||
3362 | "chk/...)" | 3362 | "chk/...)" |
3363 | msgstr "" | 3363 | msgstr "" |
3364 | 3364 | ||
3365 | #: src/fs/gnunet-fs.c:128 | ||
3366 | msgid "print a list of all indexed files" | ||
3367 | msgstr "" | ||
3368 | |||
3369 | #: src/fs/gnunet-fs.c:141 | ||
3370 | #, fuzzy | ||
3371 | msgid "Special file-sharing operations" | ||
3372 | msgstr "Visa alla alternativ" | ||
3373 | |||
3374 | #: src/fs/gnunet-fs-profiler.c:211 | 3365 | #: src/fs/gnunet-fs-profiler.c:211 |
3375 | msgid "run the experiment with COUNT peers" | 3366 | msgid "run the experiment with COUNT peers" |
3376 | msgstr "" | 3367 | msgstr "" |
@@ -3387,6 +3378,15 @@ msgstr "" | |||
3387 | msgid "run a testbed to measure file-sharing performance" | 3378 | msgid "run a testbed to measure file-sharing performance" |
3388 | msgstr "" | 3379 | msgstr "" |
3389 | 3380 | ||
3381 | #: src/fs/gnunet-fs.c:128 | ||
3382 | msgid "print a list of all indexed files" | ||
3383 | msgstr "" | ||
3384 | |||
3385 | #: src/fs/gnunet-fs.c:141 | ||
3386 | #, fuzzy | ||
3387 | msgid "Special file-sharing operations" | ||
3388 | msgstr "Visa alla alternativ" | ||
3389 | |||
3390 | #: src/fs/gnunet-publish.c:219 src/fs/gnunet-publish.c:234 | 3390 | #: src/fs/gnunet-publish.c:219 src/fs/gnunet-publish.c:234 |
3391 | #, c-format | 3391 | #, c-format |
3392 | msgid "Publishing `%s' at %llu/%llu (%s remaining)\n" | 3392 | msgid "Publishing `%s' at %llu/%llu (%s remaining)\n" |
@@ -4073,52 +4073,6 @@ msgstr "" | |||
4073 | msgid "look for GNS2DNS records instead of ANY" | 4073 | msgid "look for GNS2DNS records instead of ANY" |
4074 | msgstr "" | 4074 | msgstr "" |
4075 | 4075 | ||
4076 | #: src/gns/gnunet-gns.c:257 | ||
4077 | #, fuzzy, c-format | ||
4078 | msgid "`%s' is not a valid DNS domain name\n" | ||
4079 | msgstr "\"%s\" är inte tillgänglig." | ||
4080 | |||
4081 | #: src/gns/gnunet-gns.c:267 src/util/dnsparser.c:254 | ||
4082 | #, fuzzy, c-format | ||
4083 | msgid "Failed to convert DNS IDNA name `%s' to UTF-8: %s\n" | ||
4084 | msgstr "Misslyckades att leverera \"%s\" meddelande.\n" | ||
4085 | |||
4086 | #: src/gns/gnunet-gns.c:281 | ||
4087 | msgid "Cannot resolve using GNS: GNUnet peer not running\n" | ||
4088 | msgstr "" | ||
4089 | |||
4090 | #: src/gns/gnunet-gns.c:305 | ||
4091 | #, c-format | ||
4092 | msgid "Invalid typename specified, assuming `ANY'\n" | ||
4093 | msgstr "" | ||
4094 | |||
4095 | #: src/gns/gnunet-gns.c:340 | ||
4096 | msgid "Lookup a record for the given name" | ||
4097 | msgstr "" | ||
4098 | |||
4099 | #: src/gns/gnunet-gns.c:346 | ||
4100 | #, fuzzy | ||
4101 | msgid "Specify the type of the record to lookup" | ||
4102 | msgstr "ange prioritet för innehållet" | ||
4103 | |||
4104 | #: src/gns/gnunet-gns.c:352 | ||
4105 | #, fuzzy | ||
4106 | msgid "Specify a timeout for the lookup" | ||
4107 | msgstr "ange prioritet för innehållet" | ||
4108 | |||
4109 | #: src/gns/gnunet-gns.c:356 | ||
4110 | msgid "No unneeded output" | ||
4111 | msgstr "" | ||
4112 | |||
4113 | #: src/gns/gnunet-gns.c:361 | ||
4114 | msgid "DNS Compatibility: Name is passed in IDNA instead of UTF-8" | ||
4115 | msgstr "" | ||
4116 | |||
4117 | #: src/gns/gnunet-gns.c:375 | ||
4118 | #, fuzzy | ||
4119 | msgid "GNUnet GNS resolver tool" | ||
4120 | msgstr "Spåra GNUnets nätverkstopologi." | ||
4121 | |||
4122 | #: src/gns/gnunet-gns-import.c:486 | 4076 | #: src/gns/gnunet-gns-import.c:486 |
4123 | msgid "This program will import some GNS authorities into your GNS namestore." | 4077 | msgid "This program will import some GNS authorities into your GNS namestore." |
4124 | msgstr "" | 4078 | msgstr "" |
@@ -4239,6 +4193,52 @@ msgstr "" | |||
4239 | msgid "GNUnet GNS proxy" | 4193 | msgid "GNUnet GNS proxy" |
4240 | msgstr "" | 4194 | msgstr "" |
4241 | 4195 | ||
4196 | #: src/gns/gnunet-gns.c:257 | ||
4197 | #, fuzzy, c-format | ||
4198 | msgid "`%s' is not a valid DNS domain name\n" | ||
4199 | msgstr "\"%s\" är inte tillgänglig." | ||
4200 | |||
4201 | #: src/gns/gnunet-gns.c:267 src/util/dnsparser.c:254 | ||
4202 | #, fuzzy, c-format | ||
4203 | msgid "Failed to convert DNS IDNA name `%s' to UTF-8: %s\n" | ||
4204 | msgstr "Misslyckades att leverera \"%s\" meddelande.\n" | ||
4205 | |||
4206 | #: src/gns/gnunet-gns.c:281 | ||
4207 | msgid "Cannot resolve using GNS: GNUnet peer not running\n" | ||
4208 | msgstr "" | ||
4209 | |||
4210 | #: src/gns/gnunet-gns.c:305 | ||
4211 | #, c-format | ||
4212 | msgid "Invalid typename specified, assuming `ANY'\n" | ||
4213 | msgstr "" | ||
4214 | |||
4215 | #: src/gns/gnunet-gns.c:340 | ||
4216 | msgid "Lookup a record for the given name" | ||
4217 | msgstr "" | ||
4218 | |||
4219 | #: src/gns/gnunet-gns.c:346 | ||
4220 | #, fuzzy | ||
4221 | msgid "Specify the type of the record to lookup" | ||
4222 | msgstr "ange prioritet för innehållet" | ||
4223 | |||
4224 | #: src/gns/gnunet-gns.c:352 | ||
4225 | #, fuzzy | ||
4226 | msgid "Specify a timeout for the lookup" | ||
4227 | msgstr "ange prioritet för innehållet" | ||
4228 | |||
4229 | #: src/gns/gnunet-gns.c:356 | ||
4230 | msgid "No unneeded output" | ||
4231 | msgstr "" | ||
4232 | |||
4233 | #: src/gns/gnunet-gns.c:361 | ||
4234 | msgid "DNS Compatibility: Name is passed in IDNA instead of UTF-8" | ||
4235 | msgstr "" | ||
4236 | |||
4237 | #: src/gns/gnunet-gns.c:375 | ||
4238 | #, fuzzy | ||
4239 | msgid "GNUnet GNS resolver tool" | ||
4240 | msgstr "Spåra GNUnets nätverkstopologi." | ||
4241 | |||
4242 | #: src/gns/gnunet-service-gns.c:505 | 4242 | #: src/gns/gnunet-service-gns.c:505 |
4243 | #, fuzzy | 4243 | #, fuzzy |
4244 | msgid "Properly base32-encoded public key required" | 4244 | msgid "Properly base32-encoded public key required" |
@@ -4250,8 +4250,8 @@ msgid "Failed to connect to the namecache!\n" | |||
4250 | msgstr "Misslyckades att ansluta till gnunetd.\n" | 4250 | msgstr "Misslyckades att ansluta till gnunetd.\n" |
4251 | 4251 | ||
4252 | #: src/gns/gnunet-service-gns.c:560 | 4252 | #: src/gns/gnunet-service-gns.c:560 |
4253 | #: src/zonemaster/gnunet-service-zonemaster.c:887 | ||
4254 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:444 | 4253 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:444 |
4254 | #: src/zonemaster/gnunet-service-zonemaster.c:887 | ||
4255 | #, fuzzy | 4255 | #, fuzzy |
4256 | msgid "Could not connect to DHT!\n" | 4256 | msgid "Could not connect to DHT!\n" |
4257 | msgstr "Kunde inte ansluta till gnunetd.\n" | 4257 | msgstr "Kunde inte ansluta till gnunetd.\n" |
@@ -4749,7 +4749,7 @@ msgid "# hostlist advertisements send" | |||
4749 | msgstr "" | 4749 | msgstr "" |
4750 | 4750 | ||
4751 | #: src/hostlist/gnunet-daemon-hostlist_server.c:674 | 4751 | #: src/hostlist/gnunet-daemon-hostlist_server.c:674 |
4752 | #: src/transport/gnunet-service-transport.c:2659 | 4752 | #: src/transport/gnunet-service-transport.c:2661 |
4753 | #, fuzzy | 4753 | #, fuzzy |
4754 | msgid "Could not access PEERINFO service. Exiting.\n" | 4754 | msgid "Could not access PEERINFO service. Exiting.\n" |
4755 | msgstr "Kunde inte komma åt namnrymdsinformation.\n" | 4755 | msgstr "Kunde inte komma åt namnrymdsinformation.\n" |
@@ -5003,6 +5003,70 @@ msgstr "" | |||
5003 | msgid "Failed to setup database at `%s'\n" | 5003 | msgid "Failed to setup database at `%s'\n" |
5004 | msgstr "Fel vid %s:%d.\n" | 5004 | msgstr "Fel vid %s:%d.\n" |
5005 | 5005 | ||
5006 | #: src/namestore/gnunet-namestore-fcfsd.c:552 | ||
5007 | #, fuzzy, c-format | ||
5008 | msgid "Unsupported form value `%s'\n" | ||
5009 | msgstr "Kommando \"%s\" stöds ej. Avbryter.\n" | ||
5010 | |||
5011 | #: src/namestore/gnunet-namestore-fcfsd.c:579 | ||
5012 | #, fuzzy, c-format | ||
5013 | msgid "Failed to create record for domain `%s': %s\n" | ||
5014 | msgstr "Kunde inte tolka konfigurationsfil \"%s\".\n" | ||
5015 | |||
5016 | #: src/namestore/gnunet-namestore-fcfsd.c:600 | ||
5017 | msgid "Error when mapping zone to name\n" | ||
5018 | msgstr "" | ||
5019 | |||
5020 | #: src/namestore/gnunet-namestore-fcfsd.c:632 | ||
5021 | #, c-format | ||
5022 | msgid "Found existing name `%s' for the given key\n" | ||
5023 | msgstr "" | ||
5024 | |||
5025 | #: src/namestore/gnunet-namestore-fcfsd.c:694 | ||
5026 | #, c-format | ||
5027 | msgid "Found %u existing records for domain `%s'\n" | ||
5028 | msgstr "" | ||
5029 | |||
5030 | #: src/namestore/gnunet-namestore-fcfsd.c:784 | ||
5031 | #, fuzzy, c-format | ||
5032 | msgid "Failed to create page for `%s'\n" | ||
5033 | msgstr "Kunde inte skapa namnrymd \"%s\" (existerar?).\n" | ||
5034 | |||
5035 | #: src/namestore/gnunet-namestore-fcfsd.c:803 | ||
5036 | #, fuzzy, c-format | ||
5037 | msgid "Failed to setup post processor for `%s'\n" | ||
5038 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | ||
5039 | |||
5040 | #: src/namestore/gnunet-namestore-fcfsd.c:840 | ||
5041 | msgid "Domain name must not contain `.'\n" | ||
5042 | msgstr "" | ||
5043 | |||
5044 | #: src/namestore/gnunet-namestore-fcfsd.c:849 | ||
5045 | msgid "Domain name must not contain `+'\n" | ||
5046 | msgstr "" | ||
5047 | |||
5048 | #: src/namestore/gnunet-namestore-fcfsd.c:1084 | ||
5049 | msgid "No ego configured for `fcfsd` subsystem\n" | ||
5050 | msgstr "" | ||
5051 | |||
5052 | #: src/namestore/gnunet-namestore-fcfsd.c:1115 | ||
5053 | #, fuzzy | ||
5054 | msgid "Failed to start HTTP server\n" | ||
5055 | msgstr "Misslyckades att starta samling.\n" | ||
5056 | |||
5057 | #: src/namestore/gnunet-namestore-fcfsd.c:1163 | ||
5058 | #, fuzzy | ||
5059 | msgid "Failed to connect to identity\n" | ||
5060 | msgstr "Misslyckades att ansluta till gnunetd.\n" | ||
5061 | |||
5062 | #: src/namestore/gnunet-namestore-fcfsd.c:1190 | ||
5063 | msgid "name of the zone that is to be managed by FCFSD" | ||
5064 | msgstr "" | ||
5065 | |||
5066 | #: src/namestore/gnunet-namestore-fcfsd.c:1210 | ||
5067 | msgid "GNU Name System First Come First Serve name registration service" | ||
5068 | msgstr "" | ||
5069 | |||
5006 | #: src/namestore/gnunet-namestore.c:334 | 5070 | #: src/namestore/gnunet-namestore.c:334 |
5007 | #, fuzzy, c-format | 5071 | #, fuzzy, c-format |
5008 | msgid "Adding record failed: %s\n" | 5072 | msgid "Adding record failed: %s\n" |
@@ -5239,70 +5303,6 @@ msgstr "" | |||
5239 | msgid "name of the ego controlling the zone" | 5303 | msgid "name of the ego controlling the zone" |
5240 | msgstr "Visa värde av alternativet" | 5304 | msgstr "Visa värde av alternativet" |
5241 | 5305 | ||
5242 | #: src/namestore/gnunet-namestore-fcfsd.c:552 | ||
5243 | #, fuzzy, c-format | ||
5244 | msgid "Unsupported form value `%s'\n" | ||
5245 | msgstr "Kommando \"%s\" stöds ej. Avbryter.\n" | ||
5246 | |||
5247 | #: src/namestore/gnunet-namestore-fcfsd.c:579 | ||
5248 | #, fuzzy, c-format | ||
5249 | msgid "Failed to create record for domain `%s': %s\n" | ||
5250 | msgstr "Kunde inte tolka konfigurationsfil \"%s\".\n" | ||
5251 | |||
5252 | #: src/namestore/gnunet-namestore-fcfsd.c:600 | ||
5253 | msgid "Error when mapping zone to name\n" | ||
5254 | msgstr "" | ||
5255 | |||
5256 | #: src/namestore/gnunet-namestore-fcfsd.c:632 | ||
5257 | #, c-format | ||
5258 | msgid "Found existing name `%s' for the given key\n" | ||
5259 | msgstr "" | ||
5260 | |||
5261 | #: src/namestore/gnunet-namestore-fcfsd.c:694 | ||
5262 | #, c-format | ||
5263 | msgid "Found %u existing records for domain `%s'\n" | ||
5264 | msgstr "" | ||
5265 | |||
5266 | #: src/namestore/gnunet-namestore-fcfsd.c:784 | ||
5267 | #, fuzzy, c-format | ||
5268 | msgid "Failed to create page for `%s'\n" | ||
5269 | msgstr "Kunde inte skapa namnrymd \"%s\" (existerar?).\n" | ||
5270 | |||
5271 | #: src/namestore/gnunet-namestore-fcfsd.c:803 | ||
5272 | #, fuzzy, c-format | ||
5273 | msgid "Failed to setup post processor for `%s'\n" | ||
5274 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | ||
5275 | |||
5276 | #: src/namestore/gnunet-namestore-fcfsd.c:840 | ||
5277 | msgid "Domain name must not contain `.'\n" | ||
5278 | msgstr "" | ||
5279 | |||
5280 | #: src/namestore/gnunet-namestore-fcfsd.c:849 | ||
5281 | msgid "Domain name must not contain `+'\n" | ||
5282 | msgstr "" | ||
5283 | |||
5284 | #: src/namestore/gnunet-namestore-fcfsd.c:1084 | ||
5285 | msgid "No ego configured for `fcfsd` subsystem\n" | ||
5286 | msgstr "" | ||
5287 | |||
5288 | #: src/namestore/gnunet-namestore-fcfsd.c:1115 | ||
5289 | #, fuzzy | ||
5290 | msgid "Failed to start HTTP server\n" | ||
5291 | msgstr "Misslyckades att starta samling.\n" | ||
5292 | |||
5293 | #: src/namestore/gnunet-namestore-fcfsd.c:1163 | ||
5294 | #, fuzzy | ||
5295 | msgid "Failed to connect to identity\n" | ||
5296 | msgstr "Misslyckades att ansluta till gnunetd.\n" | ||
5297 | |||
5298 | #: src/namestore/gnunet-namestore-fcfsd.c:1190 | ||
5299 | msgid "name of the zone that is to be managed by FCFSD" | ||
5300 | msgstr "" | ||
5301 | |||
5302 | #: src/namestore/gnunet-namestore-fcfsd.c:1210 | ||
5303 | msgid "GNU Name System First Come First Serve name registration service" | ||
5304 | msgstr "" | ||
5305 | |||
5306 | #: src/namestore/gnunet-service-namestore.c:866 | 5306 | #: src/namestore/gnunet-service-namestore.c:866 |
5307 | #, fuzzy, c-format | 5307 | #, fuzzy, c-format |
5308 | msgid "Failed to replicate block in namecache: %s\n" | 5308 | msgid "Failed to replicate block in namecache: %s\n" |
@@ -5625,11 +5625,6 @@ msgstr "" | |||
5625 | msgid "`upnpc' command not found\n" | 5625 | msgid "`upnpc' command not found\n" |
5626 | msgstr "" | 5626 | msgstr "" |
5627 | 5627 | ||
5628 | #: src/nse/gnunet-nse.c:124 | ||
5629 | #, fuzzy | ||
5630 | msgid "Show network size estimates from NSE service." | ||
5631 | msgstr "# byte mottogs via TCP" | ||
5632 | |||
5633 | #: src/nse/gnunet-nse-profiler.c:857 | 5628 | #: src/nse/gnunet-nse-profiler.c:857 |
5634 | #, fuzzy | 5629 | #, fuzzy |
5635 | msgid "limit to the number of connections to NSE services, 0 for none" | 5630 | msgid "limit to the number of connections to NSE services, 0 for none" |
@@ -5656,66 +5651,16 @@ msgstr "" | |||
5656 | msgid "Measure quality and performance of the NSE service." | 5651 | msgid "Measure quality and performance of the NSE service." |
5657 | msgstr "Kan inte tillgå tjänsten" | 5652 | msgstr "Kan inte tillgå tjänsten" |
5658 | 5653 | ||
5654 | #: src/nse/gnunet-nse.c:124 | ||
5655 | #, fuzzy | ||
5656 | msgid "Show network size estimates from NSE service." | ||
5657 | msgstr "# byte mottogs via TCP" | ||
5658 | |||
5659 | #: src/nse/gnunet-service-nse.c:1443 | 5659 | #: src/nse/gnunet-service-nse.c:1443 |
5660 | #: src/revocation/gnunet-service-revocation.c:834 src/util/gnunet-scrypt.c:257 | 5660 | #: src/revocation/gnunet-service-revocation.c:834 src/util/gnunet-scrypt.c:257 |
5661 | msgid "Value is too large.\n" | 5661 | msgid "Value is too large.\n" |
5662 | msgstr "" | 5662 | msgstr "" |
5663 | 5663 | ||
5664 | #: src/peerinfo/gnunet-service-peerinfo.c:175 | ||
5665 | #, fuzzy, c-format | ||
5666 | msgid "Removing expired address of transport `%s'\n" | ||
5667 | msgstr "Tillgängliga transport(er): %s\n" | ||
5668 | |||
5669 | #: src/peerinfo/gnunet-service-peerinfo.c:306 | ||
5670 | #, fuzzy, c-format | ||
5671 | msgid "Failed to parse HELLO in file `%s': %s\n" | ||
5672 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | ||
5673 | |||
5674 | #: src/peerinfo/gnunet-service-peerinfo.c:323 | ||
5675 | #: src/peerinfo/gnunet-service-peerinfo.c:348 | ||
5676 | #, fuzzy, c-format | ||
5677 | msgid "Failed to parse HELLO in file `%s'\n" | ||
5678 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | ||
5679 | |||
5680 | #: src/peerinfo/gnunet-service-peerinfo.c:426 | ||
5681 | msgid "# peers known" | ||
5682 | msgstr "" | ||
5683 | |||
5684 | #: src/peerinfo/gnunet-service-peerinfo.c:468 | ||
5685 | #, c-format | ||
5686 | msgid "" | ||
5687 | "File `%s' in directory `%s' does not match naming convention. Removed.\n" | ||
5688 | msgstr "" | ||
5689 | |||
5690 | #: src/peerinfo/gnunet-service-peerinfo.c:624 | ||
5691 | #, fuzzy, c-format | ||
5692 | msgid "Scanning directory `%s'\n" | ||
5693 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | ||
5694 | |||
5695 | #: src/peerinfo/gnunet-service-peerinfo.c:631 | ||
5696 | #, c-format | ||
5697 | msgid "Still no peers found in `%s'!\n" | ||
5698 | msgstr "" | ||
5699 | |||
5700 | #: src/peerinfo/gnunet-service-peerinfo.c:1024 | ||
5701 | #, fuzzy, c-format | ||
5702 | msgid "Cleaning up directory `%s'\n" | ||
5703 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | ||
5704 | |||
5705 | #: src/peerinfo/gnunet-service-peerinfo.c:1319 | ||
5706 | #, c-format | ||
5707 | msgid "Importing HELLOs from `%s'\n" | ||
5708 | msgstr "" | ||
5709 | |||
5710 | #: src/peerinfo/gnunet-service-peerinfo.c:1332 | ||
5711 | msgid "Skipping import of included HELLOs\n" | ||
5712 | msgstr "" | ||
5713 | |||
5714 | #: src/peerinfo/peerinfo_api.c:217 | ||
5715 | #, fuzzy | ||
5716 | msgid "Failed to receive response from `PEERINFO' service." | ||
5717 | msgstr "Misslyckades att ta emot svar till \"%s\" meddelande från gnunetd\n" | ||
5718 | |||
5719 | #: src/peerinfo-tool/gnunet-peerinfo.c:237 | 5664 | #: src/peerinfo-tool/gnunet-peerinfo.c:237 |
5720 | #, fuzzy, c-format | 5665 | #, fuzzy, c-format |
5721 | msgid "%sPeer `%s'\n" | 5666 | msgid "%sPeer `%s'\n" |
@@ -5812,6 +5757,61 @@ msgstr "Kunde inte slå upp \"%s\": %s\n" | |||
5812 | msgid "Peerinfo REST API initialized\n" | 5757 | msgid "Peerinfo REST API initialized\n" |
5813 | msgstr " Anslutning misslyckades\n" | 5758 | msgstr " Anslutning misslyckades\n" |
5814 | 5759 | ||
5760 | #: src/peerinfo/gnunet-service-peerinfo.c:175 | ||
5761 | #, fuzzy, c-format | ||
5762 | msgid "Removing expired address of transport `%s'\n" | ||
5763 | msgstr "Tillgängliga transport(er): %s\n" | ||
5764 | |||
5765 | #: src/peerinfo/gnunet-service-peerinfo.c:306 | ||
5766 | #, fuzzy, c-format | ||
5767 | msgid "Failed to parse HELLO in file `%s': %s\n" | ||
5768 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | ||
5769 | |||
5770 | #: src/peerinfo/gnunet-service-peerinfo.c:323 | ||
5771 | #: src/peerinfo/gnunet-service-peerinfo.c:348 | ||
5772 | #, fuzzy, c-format | ||
5773 | msgid "Failed to parse HELLO in file `%s'\n" | ||
5774 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | ||
5775 | |||
5776 | #: src/peerinfo/gnunet-service-peerinfo.c:426 | ||
5777 | msgid "# peers known" | ||
5778 | msgstr "" | ||
5779 | |||
5780 | #: src/peerinfo/gnunet-service-peerinfo.c:468 | ||
5781 | #, c-format | ||
5782 | msgid "" | ||
5783 | "File `%s' in directory `%s' does not match naming convention. Removed.\n" | ||
5784 | msgstr "" | ||
5785 | |||
5786 | #: src/peerinfo/gnunet-service-peerinfo.c:624 | ||
5787 | #, fuzzy, c-format | ||
5788 | msgid "Scanning directory `%s'\n" | ||
5789 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | ||
5790 | |||
5791 | #: src/peerinfo/gnunet-service-peerinfo.c:631 | ||
5792 | #, c-format | ||
5793 | msgid "Still no peers found in `%s'!\n" | ||
5794 | msgstr "" | ||
5795 | |||
5796 | #: src/peerinfo/gnunet-service-peerinfo.c:1024 | ||
5797 | #, fuzzy, c-format | ||
5798 | msgid "Cleaning up directory `%s'\n" | ||
5799 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | ||
5800 | |||
5801 | #: src/peerinfo/gnunet-service-peerinfo.c:1319 | ||
5802 | #, c-format | ||
5803 | msgid "Importing HELLOs from `%s'\n" | ||
5804 | msgstr "" | ||
5805 | |||
5806 | #: src/peerinfo/gnunet-service-peerinfo.c:1332 | ||
5807 | msgid "Skipping import of included HELLOs\n" | ||
5808 | msgstr "" | ||
5809 | |||
5810 | #: src/peerinfo/peerinfo_api.c:217 | ||
5811 | #, fuzzy | ||
5812 | msgid "Failed to receive response from `PEERINFO' service." | ||
5813 | msgstr "Misslyckades att ta emot svar till \"%s\" meddelande från gnunetd\n" | ||
5814 | |||
5815 | #: src/peerstore/gnunet-peerstore.c:92 | 5815 | #: src/peerstore/gnunet-peerstore.c:92 |
5816 | msgid "peerstore" | 5816 | msgid "peerstore" |
5817 | msgstr "" | 5817 | msgstr "" |
@@ -6283,18 +6283,6 @@ msgstr "" | |||
6283 | msgid "Could not open revocation database file!" | 6283 | msgid "Could not open revocation database file!" |
6284 | msgstr "Kunde inte ansluta till gnunetd.\n" | 6284 | msgstr "Kunde inte ansluta till gnunetd.\n" |
6285 | 6285 | ||
6286 | #: src/rps/gnunet-rps.c:270 | ||
6287 | msgid "Seed a PeerID" | ||
6288 | msgstr "" | ||
6289 | |||
6290 | #: src/rps/gnunet-rps.c:275 | ||
6291 | msgid "Get updates of view (0 for infinite updates)" | ||
6292 | msgstr "" | ||
6293 | |||
6294 | #: src/rps/gnunet-rps.c:279 | ||
6295 | msgid "Get peers from biased stream" | ||
6296 | msgstr "" | ||
6297 | |||
6298 | #: src/rps/gnunet-rps-profiler.c:3200 | 6286 | #: src/rps/gnunet-rps-profiler.c:3200 |
6299 | msgid "duration of the profiling" | 6287 | msgid "duration of the profiling" |
6300 | msgstr "" | 6288 | msgstr "" |
@@ -6314,6 +6302,18 @@ msgstr "antal iterationer" | |||
6314 | msgid "Measure quality and performance of the RPS service." | 6302 | msgid "Measure quality and performance of the RPS service." |
6315 | msgstr "Kan inte tillgå tjänsten" | 6303 | msgstr "Kan inte tillgå tjänsten" |
6316 | 6304 | ||
6305 | #: src/rps/gnunet-rps.c:270 | ||
6306 | msgid "Seed a PeerID" | ||
6307 | msgstr "" | ||
6308 | |||
6309 | #: src/rps/gnunet-rps.c:275 | ||
6310 | msgid "Get updates of view (0 for infinite updates)" | ||
6311 | msgstr "" | ||
6312 | |||
6313 | #: src/rps/gnunet-rps.c:279 | ||
6314 | msgid "Get peers from biased stream" | ||
6315 | msgstr "" | ||
6316 | |||
6317 | #: src/scalarproduct/gnunet-scalarproduct.c:229 | 6317 | #: src/scalarproduct/gnunet-scalarproduct.c:229 |
6318 | #, fuzzy | 6318 | #, fuzzy |
6319 | msgid "You must specify at least one message ID to check!\n" | 6319 | msgid "You must specify at least one message ID to check!\n" |
@@ -6369,10 +6369,10 @@ msgstr "" | |||
6369 | msgid "Calculate the Vectorproduct with a GNUnet peer." | 6369 | msgid "Calculate the Vectorproduct with a GNUnet peer." |
6370 | msgstr "" | 6370 | msgstr "" |
6371 | 6371 | ||
6372 | #: src/scalarproduct/gnunet-service-scalarproduct_alice.c:1358 | ||
6373 | #: src/scalarproduct/gnunet-service-scalarproduct_bob.c:1355 | ||
6374 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_alice.c:1118 | 6372 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_alice.c:1118 |
6375 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c:1063 | 6373 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c:1063 |
6374 | #: src/scalarproduct/gnunet-service-scalarproduct_alice.c:1358 | ||
6375 | #: src/scalarproduct/gnunet-service-scalarproduct_bob.c:1355 | ||
6376 | #, fuzzy | 6376 | #, fuzzy |
6377 | msgid "Connect to CADET failed\n" | 6377 | msgid "Connect to CADET failed\n" |
6378 | msgstr " Anslutning misslyckades (fel?)\n" | 6378 | msgstr " Anslutning misslyckades (fel?)\n" |
@@ -6727,16 +6727,6 @@ msgstr "" | |||
6727 | msgid "%.s Unknown result code." | 6727 | msgid "%.s Unknown result code." |
6728 | msgstr "" | 6728 | msgstr "" |
6729 | 6729 | ||
6730 | #: src/testbed/gnunet_testbed_mpi_spawn.c:119 | ||
6731 | #, fuzzy | ||
6732 | msgid "Waiting for child to exit.\n" | ||
6733 | msgstr "Väntar på att motparter ska ansluta (%u iterationer kvar)...\n" | ||
6734 | |||
6735 | #: src/testbed/gnunet_testbed_mpi_spawn.c:242 | ||
6736 | #, fuzzy, c-format | ||
6737 | msgid "Spawning process `%s'\n" | ||
6738 | msgstr "Startade samling \"%s\".\n" | ||
6739 | |||
6740 | #: src/testbed/gnunet-testbed-profiler.c:290 | 6730 | #: src/testbed/gnunet-testbed-profiler.c:290 |
6741 | msgid "tolerate COUNT number of continious timeout failures" | 6731 | msgid "tolerate COUNT number of continious timeout failures" |
6742 | msgstr "" | 6732 | msgstr "" |
@@ -6748,6 +6738,16 @@ msgid "" | |||
6748 | "signal is received" | 6738 | "signal is received" |
6749 | msgstr "" | 6739 | msgstr "" |
6750 | 6740 | ||
6741 | #: src/testbed/gnunet_testbed_mpi_spawn.c:119 | ||
6742 | #, fuzzy | ||
6743 | msgid "Waiting for child to exit.\n" | ||
6744 | msgstr "Väntar på att motparter ska ansluta (%u iterationer kvar)...\n" | ||
6745 | |||
6746 | #: src/testbed/gnunet_testbed_mpi_spawn.c:242 | ||
6747 | #, fuzzy, c-format | ||
6748 | msgid "Spawning process `%s'\n" | ||
6749 | msgstr "Startade samling \"%s\".\n" | ||
6750 | |||
6751 | #: src/testbed/testbed_api.c:399 | 6751 | #: src/testbed/testbed_api.c:399 |
6752 | #, fuzzy, c-format | 6752 | #, fuzzy, c-format |
6753 | msgid "Adding host %u failed with error: %s\n" | 6753 | msgid "Adding host %u failed with error: %s\n" |
@@ -7044,19 +7044,19 @@ msgstr "# krypterade PONG-meddelanden mottagna" | |||
7044 | msgid "GNUnet topology control" | 7044 | msgid "GNUnet topology control" |
7045 | msgstr "" | 7045 | msgstr "" |
7046 | 7046 | ||
7047 | #: src/transport/gnunet-communicator-tcp.c:3189 | 7047 | #: src/transport/gnunet-communicator-tcp.c:3221 |
7048 | #: src/transport/gnunet-communicator-udp.c:2826 | 7048 | #: src/transport/gnunet-communicator-udp.c:2995 |
7049 | #: src/transport/gnunet-service-tng.c:10014 | 7049 | #: src/transport/gnunet-service-tng.c:10014 |
7050 | #: src/transport/gnunet-service-transport.c:2624 | 7050 | #: src/transport/gnunet-service-transport.c:2626 |
7051 | #, fuzzy | 7051 | #, fuzzy |
7052 | msgid "Transport service is lacking key configuration settings. Exiting.\n" | 7052 | msgid "Transport service is lacking key configuration settings. Exiting.\n" |
7053 | msgstr "GNUnet-konfiguration" | 7053 | msgstr "GNUnet-konfiguration" |
7054 | 7054 | ||
7055 | #: src/transport/gnunet-communicator-tcp.c:3494 | 7055 | #: src/transport/gnunet-communicator-tcp.c:3553 |
7056 | msgid "GNUnet TCP communicator" | 7056 | msgid "GNUnet TCP communicator" |
7057 | msgstr "" | 7057 | msgstr "" |
7058 | 7058 | ||
7059 | #: src/transport/gnunet-communicator-udp.c:2898 | 7059 | #: src/transport/gnunet-communicator-udp.c:3067 |
7060 | msgid "GNUnet UDP communicator" | 7060 | msgid "GNUnet UDP communicator" |
7061 | msgstr "" | 7061 | msgstr "" |
7062 | 7062 | ||
@@ -7081,53 +7081,53 @@ msgstr "Kunde inte skapa namnrymd \"%s\" (existerar?).\n" | |||
7081 | msgid "GNUnet UNIX domain socket communicator" | 7081 | msgid "GNUnet UNIX domain socket communicator" |
7082 | msgstr "" | 7082 | msgstr "" |
7083 | 7083 | ||
7084 | #: src/transport/gnunet-service-transport_ats.c:137 | ||
7085 | msgid "# Addresses given to ATS" | ||
7086 | msgstr "" | ||
7087 | |||
7088 | #: src/transport/gnunet-service-transport.c:445 | 7084 | #: src/transport/gnunet-service-transport.c:445 |
7089 | msgid "# messages dropped due to slow client" | 7085 | msgid "# messages dropped due to slow client" |
7090 | msgstr "" | 7086 | msgstr "" |
7091 | 7087 | ||
7092 | #: src/transport/gnunet-service-transport.c:794 | 7088 | #: src/transport/gnunet-service-transport.c:796 |
7093 | msgid "# bytes payload dropped (other peer was not connected)" | 7089 | msgid "# bytes payload dropped (other peer was not connected)" |
7094 | msgstr "" | 7090 | msgstr "" |
7095 | 7091 | ||
7096 | #: src/transport/gnunet-service-transport.c:1477 | 7092 | #: src/transport/gnunet-service-transport.c:1479 |
7097 | #, fuzzy | 7093 | #, fuzzy |
7098 | msgid "# bytes payload discarded due to not connected peer" | 7094 | msgid "# bytes payload discarded due to not connected peer" |
7099 | msgstr "Nätverksannonsering avstängd i konfigurationen!\n" | 7095 | msgstr "Nätverksannonsering avstängd i konfigurationen!\n" |
7100 | 7096 | ||
7101 | #: src/transport/gnunet-service-transport.c:1622 | 7097 | #: src/transport/gnunet-service-transport.c:1624 |
7102 | #, fuzzy | 7098 | #, fuzzy |
7103 | msgid "# bytes total received" | 7099 | msgid "# bytes total received" |
7104 | msgstr "# byte krypterade" | 7100 | msgstr "# byte krypterade" |
7105 | 7101 | ||
7106 | #: src/transport/gnunet-service-transport.c:1712 | 7102 | #: src/transport/gnunet-service-transport.c:1714 |
7107 | #, fuzzy | 7103 | #, fuzzy |
7108 | msgid "# bytes payload received" | 7104 | msgid "# bytes payload received" |
7109 | msgstr "# byte dekrypterade" | 7105 | msgstr "# byte dekrypterade" |
7110 | 7106 | ||
7111 | #: src/transport/gnunet-service-transport.c:2016 | 7107 | #: src/transport/gnunet-service-transport.c:2018 |
7112 | #: src/transport/gnunet-service-transport.c:2450 | 7108 | #: src/transport/gnunet-service-transport.c:2452 |
7113 | msgid "# disconnects due to blacklist" | 7109 | msgid "# disconnects due to blacklist" |
7114 | msgstr "" | 7110 | msgstr "" |
7115 | 7111 | ||
7116 | #: src/transport/gnunet-service-transport.c:2454 | 7112 | #: src/transport/gnunet-service-transport.c:2456 |
7117 | #, fuzzy, c-format | 7113 | #, fuzzy, c-format |
7118 | msgid "Disallowing connection to peer `%s' on transport %s\n" | 7114 | msgid "Disallowing connection to peer `%s' on transport %s\n" |
7119 | msgstr "Kunde inte slå upp \"%s\": %s\n" | 7115 | msgstr "Kunde inte slå upp \"%s\": %s\n" |
7120 | 7116 | ||
7121 | #: src/transport/gnunet-service-transport.c:2549 | 7117 | #: src/transport/gnunet-service-transport.c:2551 |
7122 | #, fuzzy, c-format | 7118 | #, fuzzy, c-format |
7123 | msgid "Adding blacklisting entry for peer `%s'\n" | 7119 | msgid "Adding blacklisting entry for peer `%s'\n" |
7124 | msgstr "Motpart \"%s\" med pålitlighet %8u och adress \"%s\"\n" | 7120 | msgstr "Motpart \"%s\" med pålitlighet %8u och adress \"%s\"\n" |
7125 | 7121 | ||
7126 | #: src/transport/gnunet-service-transport.c:2558 | 7122 | #: src/transport/gnunet-service-transport.c:2560 |
7127 | #, c-format | 7123 | #, c-format |
7128 | msgid "Adding blacklisting entry for peer `%s':`%s'\n" | 7124 | msgid "Adding blacklisting entry for peer `%s':`%s'\n" |
7129 | msgstr "" | 7125 | msgstr "" |
7130 | 7126 | ||
7127 | #: src/transport/gnunet-service-transport_ats.c:137 | ||
7128 | msgid "# Addresses given to ATS" | ||
7129 | msgstr "" | ||
7130 | |||
7131 | #: src/transport/gnunet-service-transport_hello.c:195 | 7131 | #: src/transport/gnunet-service-transport_hello.c:195 |
7132 | msgid "# refreshed my HELLO" | 7132 | msgid "# refreshed my HELLO" |
7133 | msgstr "" | 7133 | msgstr "" |
@@ -7464,6 +7464,46 @@ msgstr "" | |||
7464 | msgid "# HELLOs given to peerinfo" | 7464 | msgid "# HELLOs given to peerinfo" |
7465 | msgstr "Meddelande mottaget från klient är ogiltig.\n" | 7465 | msgstr "Meddelande mottaget från klient är ogiltig.\n" |
7466 | 7466 | ||
7467 | #: src/transport/gnunet-transport-profiler.c:220 | ||
7468 | #, c-format | ||
7469 | msgid "%llu B in %llu ms == %.2f KB/s!\n" | ||
7470 | msgstr "" | ||
7471 | |||
7472 | #: src/transport/gnunet-transport-profiler.c:577 | ||
7473 | msgid "send data to peer" | ||
7474 | msgstr "" | ||
7475 | |||
7476 | #: src/transport/gnunet-transport-profiler.c:581 | ||
7477 | #, fuzzy | ||
7478 | msgid "receive data from peer" | ||
7479 | msgstr "# byte mottagna av typen %d" | ||
7480 | |||
7481 | #: src/transport/gnunet-transport-profiler.c:586 | ||
7482 | #, fuzzy | ||
7483 | msgid "iterations" | ||
7484 | msgstr "Visa alla alternativ" | ||
7485 | |||
7486 | #: src/transport/gnunet-transport-profiler.c:591 | ||
7487 | #, fuzzy | ||
7488 | msgid "number of messages to send" | ||
7489 | msgstr "antal meddelanden att använda per iteration" | ||
7490 | |||
7491 | #: src/transport/gnunet-transport-profiler.c:596 | ||
7492 | #, fuzzy | ||
7493 | msgid "message size to use" | ||
7494 | msgstr "meddelandestorlek" | ||
7495 | |||
7496 | #: src/transport/gnunet-transport-profiler.c:601 | ||
7497 | #: src/transport/gnunet-transport.c:1404 | ||
7498 | msgid "peer identity" | ||
7499 | msgstr "" | ||
7500 | |||
7501 | #: src/transport/gnunet-transport-profiler.c:614 | ||
7502 | #: src/transport/gnunet-transport.c:1426 | ||
7503 | #, fuzzy | ||
7504 | msgid "Direct access to transport service." | ||
7505 | msgstr "Misslyckades att ansluta till gnunetd.\n" | ||
7506 | |||
7467 | #: src/transport/gnunet-transport.c:406 | 7507 | #: src/transport/gnunet-transport.c:406 |
7468 | #, fuzzy, c-format | 7508 | #, fuzzy, c-format |
7469 | msgid "Transmitted %llu bytes/s (%llu bytes in %s)\n" | 7509 | msgid "Transmitted %llu bytes/s (%llu bytes in %s)\n" |
@@ -7603,11 +7643,6 @@ msgstr "Skriv ut information om GNUnets motparter." | |||
7603 | msgid "do not resolve hostnames" | 7643 | msgid "do not resolve hostnames" |
7604 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | 7644 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" |
7605 | 7645 | ||
7606 | #: src/transport/gnunet-transport.c:1404 | ||
7607 | #: src/transport/gnunet-transport-profiler.c:601 | ||
7608 | msgid "peer identity" | ||
7609 | msgstr "" | ||
7610 | |||
7611 | #: src/transport/gnunet-transport.c:1408 | 7646 | #: src/transport/gnunet-transport.c:1408 |
7612 | msgid "monitor plugin sessions" | 7647 | msgid "monitor plugin sessions" |
7613 | msgstr "" | 7648 | msgstr "" |
@@ -7616,41 +7651,6 @@ msgstr "" | |||
7616 | msgid "send data for benchmarking to the other peer (until CTRL-C)" | 7651 | msgid "send data for benchmarking to the other peer (until CTRL-C)" |
7617 | msgstr "" | 7652 | msgstr "" |
7618 | 7653 | ||
7619 | #: src/transport/gnunet-transport.c:1426 | ||
7620 | #: src/transport/gnunet-transport-profiler.c:614 | ||
7621 | #, fuzzy | ||
7622 | msgid "Direct access to transport service." | ||
7623 | msgstr "Misslyckades att ansluta till gnunetd.\n" | ||
7624 | |||
7625 | #: src/transport/gnunet-transport-profiler.c:220 | ||
7626 | #, c-format | ||
7627 | msgid "%llu B in %llu ms == %.2f KB/s!\n" | ||
7628 | msgstr "" | ||
7629 | |||
7630 | #: src/transport/gnunet-transport-profiler.c:577 | ||
7631 | msgid "send data to peer" | ||
7632 | msgstr "" | ||
7633 | |||
7634 | #: src/transport/gnunet-transport-profiler.c:581 | ||
7635 | #, fuzzy | ||
7636 | msgid "receive data from peer" | ||
7637 | msgstr "# byte mottagna av typen %d" | ||
7638 | |||
7639 | #: src/transport/gnunet-transport-profiler.c:586 | ||
7640 | #, fuzzy | ||
7641 | msgid "iterations" | ||
7642 | msgstr "Visa alla alternativ" | ||
7643 | |||
7644 | #: src/transport/gnunet-transport-profiler.c:591 | ||
7645 | #, fuzzy | ||
7646 | msgid "number of messages to send" | ||
7647 | msgstr "antal meddelanden att använda per iteration" | ||
7648 | |||
7649 | #: src/transport/gnunet-transport-profiler.c:596 | ||
7650 | #, fuzzy | ||
7651 | msgid "message size to use" | ||
7652 | msgstr "meddelandestorlek" | ||
7653 | |||
7654 | #: src/transport/plugin_transport_http_client.c:1489 | 7654 | #: src/transport/plugin_transport_http_client.c:1489 |
7655 | #: src/transport/plugin_transport_http_server.c:2331 | 7655 | #: src/transport/plugin_transport_http_server.c:2331 |
7656 | #: src/transport/plugin_transport_http_server.c:3562 | 7656 | #: src/transport/plugin_transport_http_server.c:3562 |
@@ -7938,21 +7938,6 @@ msgstr "" | |||
7938 | msgid "TCP transport advertises itself as being on port %llu\n" | 7938 | msgid "TCP transport advertises itself as being on port %llu\n" |
7939 | msgstr "" | 7939 | msgstr "" |
7940 | 7940 | ||
7941 | #: src/transport/plugin_transport_udp_broadcasting.c:169 | ||
7942 | #, fuzzy | ||
7943 | msgid "# Multicast HELLO beacons received via UDP" | ||
7944 | msgstr "# krypterade PONG-meddelanden mottagna" | ||
7945 | |||
7946 | #: src/transport/plugin_transport_udp_broadcasting.c:553 | ||
7947 | msgid "" | ||
7948 | "Disabling HELLO broadcasting due to friend-to-friend only configuration!\n" | ||
7949 | msgstr "" | ||
7950 | |||
7951 | #: src/transport/plugin_transport_udp_broadcasting.c:571 | ||
7952 | #, c-format | ||
7953 | msgid "Failed to set IPv4 broadcast option for broadcast socket on port %d\n" | ||
7954 | msgstr "" | ||
7955 | |||
7956 | #: src/transport/plugin_transport_udp.c:3169 | 7941 | #: src/transport/plugin_transport_udp.c:3169 |
7957 | #, c-format | 7942 | #, c-format |
7958 | msgid "" | 7943 | msgid "" |
@@ -8001,6 +7986,21 @@ msgstr "\"%s\" är inte tillgänglig." | |||
8001 | msgid "Failed to create UDP network sockets\n" | 7986 | msgid "Failed to create UDP network sockets\n" |
8002 | msgstr "Kunde inte skapa namnrymd \"%s\" (existerar?).\n" | 7987 | msgstr "Kunde inte skapa namnrymd \"%s\" (existerar?).\n" |
8003 | 7988 | ||
7989 | #: src/transport/plugin_transport_udp_broadcasting.c:169 | ||
7990 | #, fuzzy | ||
7991 | msgid "# Multicast HELLO beacons received via UDP" | ||
7992 | msgstr "# krypterade PONG-meddelanden mottagna" | ||
7993 | |||
7994 | #: src/transport/plugin_transport_udp_broadcasting.c:553 | ||
7995 | msgid "" | ||
7996 | "Disabling HELLO broadcasting due to friend-to-friend only configuration!\n" | ||
7997 | msgstr "" | ||
7998 | |||
7999 | #: src/transport/plugin_transport_udp_broadcasting.c:571 | ||
8000 | #, c-format | ||
8001 | msgid "Failed to set IPv4 broadcast option for broadcast socket on port %d\n" | ||
8002 | msgstr "" | ||
8003 | |||
8004 | #: src/transport/plugin_transport_unix.c:1396 | 8004 | #: src/transport/plugin_transport_unix.c:1396 |
8005 | #, fuzzy, c-format | 8005 | #, fuzzy, c-format |
8006 | msgid "Cannot bind to `%s'\n" | 8006 | msgid "Cannot bind to `%s'\n" |
@@ -8184,7 +8184,7 @@ msgid "do daemonize (detach from terminal)" | |||
8184 | msgstr "" | 8184 | msgstr "" |
8185 | 8185 | ||
8186 | #: src/transport/tcp_service_legacy.c:1397 | 8186 | #: src/transport/tcp_service_legacy.c:1397 |
8187 | #: src/transport/transport-testing2.c:1116 src/util/service.c:2072 | 8187 | #: src/transport/transport-testing2.c:983 src/util/service.c:2072 |
8188 | #: src/util/service.c:2084 | 8188 | #: src/util/service.c:2084 |
8189 | #, fuzzy, c-format | 8189 | #, fuzzy, c-format |
8190 | msgid "Malformed configuration file `%s', exit ...\n" | 8190 | msgid "Malformed configuration file `%s', exit ...\n" |
@@ -8852,19 +8852,19 @@ msgid "" | |||
8852 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" | 8852 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" |
8853 | msgstr "" | 8853 | msgstr "" |
8854 | 8854 | ||
8855 | #: src/util/os_installation.c:409 | 8855 | #: src/util/os_installation.c:411 |
8856 | #, c-format | 8856 | #, c-format |
8857 | msgid "" | 8857 | msgid "" |
8858 | "Could not determine installation path for %s. Set `%s' environment " | 8858 | "Could not determine installation path for %s. Set `%s' environment " |
8859 | "variable.\n" | 8859 | "variable.\n" |
8860 | msgstr "" | 8860 | msgstr "" |
8861 | 8861 | ||
8862 | #: src/util/os_installation.c:792 | 8862 | #: src/util/os_installation.c:794 |
8863 | #, fuzzy, c-format | 8863 | #, fuzzy, c-format |
8864 | msgid "Could not find binary `%s' in PATH!\n" | 8864 | msgid "Could not find binary `%s' in PATH!\n" |
8865 | msgstr "Kunde inte hitta motpart \"%s\" i routingtabell!\n" | 8865 | msgstr "Kunde inte hitta motpart \"%s\" i routingtabell!\n" |
8866 | 8866 | ||
8867 | #: src/util/os_installation.c:825 | 8867 | #: src/util/os_installation.c:827 |
8868 | #, c-format | 8868 | #, c-format |
8869 | msgid "Binary `%s' exists, but is not SUID\n" | 8869 | msgid "Binary `%s' exists, but is not SUID\n" |
8870 | msgstr "" | 8870 | msgstr "" |
@@ -8889,17 +8889,17 @@ msgstr "\"%s\" misslyckades vid %s:%d med fel: %s\n" | |||
8889 | msgid "Could not determine plugin installation path.\n" | 8889 | msgid "Could not determine plugin installation path.\n" |
8890 | msgstr "Kunde inte fastställa min publika IPv6-adress.\n" | 8890 | msgstr "Kunde inte fastställa min publika IPv6-adress.\n" |
8891 | 8891 | ||
8892 | #: src/util/program.c:262 | 8892 | #: src/util/program.c:267 |
8893 | #, fuzzy, c-format | 8893 | #, fuzzy, c-format |
8894 | msgid "Unreadable or malformed configuration file `%s', exit ...\n" | 8894 | msgid "Unreadable or malformed configuration file `%s', exit ...\n" |
8895 | msgstr "Kunde inte spara konfigurationsfil \"%s\":" | 8895 | msgstr "Kunde inte spara konfigurationsfil \"%s\":" |
8896 | 8896 | ||
8897 | #: src/util/program.c:279 | 8897 | #: src/util/program.c:284 |
8898 | #, fuzzy, c-format | 8898 | #, fuzzy, c-format |
8899 | msgid "Unreadable or malformed default configuration file `%s', exit ...\n" | 8899 | msgid "Unreadable or malformed default configuration file `%s', exit ...\n" |
8900 | msgstr "Kunde inte spara konfigurationsfil \"%s\":" | 8900 | msgstr "Kunde inte spara konfigurationsfil \"%s\":" |
8901 | 8901 | ||
8902 | #: src/util/program.c:294 | 8902 | #: src/util/program.c:299 |
8903 | #, fuzzy | 8903 | #, fuzzy |
8904 | msgid "Unreadable or malformed configuration, exit ...\n" | 8904 | msgid "Unreadable or malformed configuration, exit ...\n" |
8905 | msgstr "Kunde inte spara konfigurationsfil \"%s\":" | 8905 | msgstr "Kunde inte spara konfigurationsfil \"%s\":" |
@@ -8966,10 +8966,6 @@ msgstr "" | |||
8966 | msgid "Attempting to proxy service `%s' to invalid port %d or hostname.\n" | 8966 | msgid "Attempting to proxy service `%s' to invalid port %d or hostname.\n" |
8967 | msgstr "" | 8967 | msgstr "" |
8968 | 8968 | ||
8969 | #: src/util/strings.c:179 | ||
8970 | msgid "b" | ||
8971 | msgstr "b" | ||
8972 | |||
8973 | #: src/util/strings.c:503 | 8969 | #: src/util/strings.c:503 |
8974 | #, c-format | 8970 | #, c-format |
8975 | msgid "Character sets requested were `%s'->`%s'\n" | 8971 | msgid "Character sets requested were `%s'->`%s'\n" |
@@ -8979,48 +8975,6 @@ msgstr "" | |||
8979 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" | 8975 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" |
8980 | msgstr "" | 8976 | msgstr "" |
8981 | 8977 | ||
8982 | #: src/util/strings.c:706 | ||
8983 | msgid "µs" | ||
8984 | msgstr "" | ||
8985 | |||
8986 | #: src/util/strings.c:710 | ||
8987 | msgid "forever" | ||
8988 | msgstr "" | ||
8989 | |||
8990 | #: src/util/strings.c:712 | ||
8991 | msgid "0 ms" | ||
8992 | msgstr "" | ||
8993 | |||
8994 | #: src/util/strings.c:716 | ||
8995 | msgid "ms" | ||
8996 | msgstr "ms" | ||
8997 | |||
8998 | #: src/util/strings.c:720 | ||
8999 | msgid "s" | ||
9000 | msgstr "s" | ||
9001 | |||
9002 | #: src/util/strings.c:724 | ||
9003 | msgid "m" | ||
9004 | msgstr "m" | ||
9005 | |||
9006 | #: src/util/strings.c:728 | ||
9007 | msgid "h" | ||
9008 | msgstr "h" | ||
9009 | |||
9010 | #: src/util/strings.c:734 | ||
9011 | #, fuzzy | ||
9012 | msgid "day" | ||
9013 | msgstr " dagar" | ||
9014 | |||
9015 | #: src/util/strings.c:736 | ||
9016 | #, fuzzy | ||
9017 | msgid "days" | ||
9018 | msgstr " dagar" | ||
9019 | |||
9020 | #: src/util/strings.c:764 | ||
9021 | msgid "end of time" | ||
9022 | msgstr "" | ||
9023 | |||
9024 | #: src/util/strings.c:1240 | 8978 | #: src/util/strings.c:1240 |
9025 | msgid "IPv6 address did not start with `['\n" | 8979 | msgid "IPv6 address did not start with `['\n" |
9026 | msgstr "" | 8980 | msgstr "" |
@@ -9271,12 +9225,35 @@ msgstr "# byte mottagna via UDP" | |||
9271 | msgid "Setup tunnels via VPN." | 9225 | msgid "Setup tunnels via VPN." |
9272 | msgstr "" | 9226 | msgstr "" |
9273 | 9227 | ||
9274 | #: src/zonemaster/gnunet-service-zonemaster.c:849 | ||
9275 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:420 | 9228 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:420 |
9229 | #: src/zonemaster/gnunet-service-zonemaster.c:849 | ||
9276 | #, fuzzy | 9230 | #, fuzzy |
9277 | msgid "Failed to connect to the namestore!\n" | 9231 | msgid "Failed to connect to the namestore!\n" |
9278 | msgstr "Misslyckades att ansluta till gnunetd.\n" | 9232 | msgstr "Misslyckades att ansluta till gnunetd.\n" |
9279 | 9233 | ||
9234 | #~ msgid "b" | ||
9235 | #~ msgstr "b" | ||
9236 | |||
9237 | #~ msgid "ms" | ||
9238 | #~ msgstr "ms" | ||
9239 | |||
9240 | #~ msgid "s" | ||
9241 | #~ msgstr "s" | ||
9242 | |||
9243 | #~ msgid "m" | ||
9244 | #~ msgstr "m" | ||
9245 | |||
9246 | #~ msgid "h" | ||
9247 | #~ msgstr "h" | ||
9248 | |||
9249 | #, fuzzy | ||
9250 | #~ msgid "day" | ||
9251 | #~ msgstr " dagar" | ||
9252 | |||
9253 | #, fuzzy | ||
9254 | #~ msgid "days" | ||
9255 | #~ msgstr " dagar" | ||
9256 | |||
9280 | #, fuzzy, c-format | 9257 | #, fuzzy, c-format |
9281 | #~ msgid "Could not acquire lock on file `%s': %s...\n" | 9258 | #~ msgid "Could not acquire lock on file `%s': %s...\n" |
9282 | #~ msgstr "Kunde inte slå upp \"%s\": %s\n" | 9259 | #~ msgstr "Kunde inte slå upp \"%s\": %s\n" |
@@ -8,7 +8,7 @@ msgid "" | |||
8 | msgstr "" | 8 | msgstr "" |
9 | "Project-Id-Version: gnunet 0.8.0a\n" | 9 | "Project-Id-Version: gnunet 0.8.0a\n" |
10 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" | 10 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" |
11 | "POT-Creation-Date: 2020-09-06 10:07+0200\n" | 11 | "POT-Creation-Date: 2020-10-13 16:12+0200\n" |
12 | "PO-Revision-Date: 2008-09-10 22:05+0930\n" | 12 | "PO-Revision-Date: 2008-09-10 22:05+0930\n" |
13 | "Last-Translator: Clytie Siddall <clytie@riverland.net.au>\n" | 13 | "Last-Translator: Clytie Siddall <clytie@riverland.net.au>\n" |
14 | "Language-Team: Vietnamese <vi-VN@googlegroups.com>\n" | 14 | "Language-Team: Vietnamese <vi-VN@googlegroups.com>\n" |
@@ -30,8 +30,8 @@ msgid "Issuer public key `%s' is not well-formed\n" | |||
30 | msgstr "Đối số không hợp lệ cho « %s ».\n" | 30 | msgstr "Đối số không hợp lệ cho « %s ».\n" |
31 | 31 | ||
32 | #: src/abd/gnunet-abd.c:560 src/abd/gnunet-service-abd.c:1747 | 32 | #: src/abd/gnunet-abd.c:560 src/abd/gnunet-service-abd.c:1747 |
33 | #: src/namestore/gnunet-namestore.c:1001 | ||
34 | #: src/namestore/gnunet-namestore-fcfsd.c:1154 | 33 | #: src/namestore/gnunet-namestore-fcfsd.c:1154 |
34 | #: src/namestore/gnunet-namestore.c:1001 | ||
35 | #, fuzzy, c-format | 35 | #, fuzzy, c-format |
36 | msgid "Failed to connect to namestore\n" | 36 | msgid "Failed to connect to namestore\n" |
37 | msgstr "Không kết nối được đến trình nền gnunetd." | 37 | msgstr "Không kết nối được đến trình nền gnunetd." |
@@ -509,82 +509,15 @@ msgstr "" | |||
509 | msgid "Initiating shutdown as requested by client.\n" | 509 | msgid "Initiating shutdown as requested by client.\n" |
510 | msgstr "" | 510 | msgstr "" |
511 | 511 | ||
512 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | 512 | #: src/ats-tests/ats-testing-log.c:896 |
513 | #, c-format | ||
514 | msgid "" | ||
515 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | ||
516 | "%llu\n" | ||
517 | msgstr "" | ||
518 | |||
519 | #: src/ats/gnunet-ats-solver-eval.c:3011 | ||
520 | #, c-format | ||
521 | msgid "" | ||
522 | "No outbound quota configured for network `%s', assigning default bandwidth " | ||
523 | "%llu\n" | ||
524 | msgstr "" | ||
525 | |||
526 | #: src/ats/gnunet-ats-solver-eval.c:3063 | ||
527 | #, c-format | ||
528 | msgid "" | ||
529 | "No outbound quota configure for network `%s', assigning default bandwidth " | ||
530 | "%llu\n" | ||
531 | msgstr "" | ||
532 | |||
533 | #: src/ats/gnunet-ats-solver-eval.c:3552 src/ats-tests/gnunet-solver-eval.c:997 | ||
534 | msgid "solver to use" | ||
535 | msgstr "" | ||
536 | |||
537 | #: src/ats/gnunet-ats-solver-eval.c:3557 | ||
538 | #: src/ats-tests/gnunet-solver-eval.c:1003 | ||
539 | #: src/ats-tests/gnunet-solver-eval.c:1008 | ||
540 | msgid "experiment to use" | ||
541 | msgstr "" | ||
542 | |||
543 | #: src/ats/gnunet-ats-solver-eval.c:3564 | ||
544 | #, fuzzy | 513 | #, fuzzy |
545 | msgid "print logging" | 514 | msgid "Stop logging\n" |
546 | msgstr "Theo dõi" | 515 | msgstr "Theo dõi" |
547 | 516 | ||
548 | #: src/ats/gnunet-ats-solver-eval.c:3569 | 517 | #: src/ats-tests/ats-testing-log.c:952 |
549 | msgid "save logging to disk" | ||
550 | msgstr "" | ||
551 | |||
552 | #: src/ats/gnunet-ats-solver-eval.c:3574 | ||
553 | msgid "disable normalization" | ||
554 | msgstr "" | ||
555 | |||
556 | #: src/ats/gnunet-service-ats_plugins.c:326 | ||
557 | #, c-format | ||
558 | msgid "" | ||
559 | "Could not load %s quota for network `%s': `%s', assigning default bandwidth " | ||
560 | "%llu\n" | ||
561 | msgstr "" | ||
562 | |||
563 | #: src/ats/gnunet-service-ats_plugins.c:336 | ||
564 | #, c-format | ||
565 | msgid "%s quota configured for network `%s' is %llu\n" | ||
566 | msgstr "" | ||
567 | |||
568 | #: src/ats/gnunet-service-ats_plugins.c:382 | ||
569 | #, c-format | ||
570 | msgid "" | ||
571 | "No %s-quota configured for network `%s', assigning default bandwidth %llu\n" | ||
572 | msgstr "" | ||
573 | |||
574 | #: src/ats/gnunet-service-ats_plugins.c:474 | ||
575 | #, fuzzy, c-format | ||
576 | msgid "Failed to initialize solver `%s'!\n" | ||
577 | msgstr "Không thể sơ khởi SQLite: %s.\n" | ||
578 | |||
579 | #: src/ats/plugin_ats_proportional.c:1142 | ||
580 | #, fuzzy, c-format | ||
581 | msgid "Invalid %s configuration %f \n" | ||
582 | msgstr "Không thể lưu tập tin cấu hình « %s »:" | ||
583 | |||
584 | #: src/ats/plugin_ats_proportional.c:1165 | ||
585 | #, fuzzy, c-format | 518 | #, fuzzy, c-format |
586 | msgid "Invalid %s configuration %f\n" | 519 | msgid "Start logging `%s'\n" |
587 | msgstr "Không th lưu tp tin cu hnh « %s »:" | 520 | msgstr "Đang bt đu ti về « %s »\n" |
588 | 521 | ||
589 | #: src/ats-tests/ats-testing.c:420 | 522 | #: src/ats-tests/ats-testing.c:420 |
590 | #, c-format | 523 | #, c-format |
@@ -596,16 +529,6 @@ msgstr "" | |||
596 | msgid "Failed to connect master peer [%u] with slave [%u]\n" | 529 | msgid "Failed to connect master peer [%u] with slave [%u]\n" |
597 | msgstr "Lỗi kết nối đến gnunetd.\n" | 530 | msgstr "Lỗi kết nối đến gnunetd.\n" |
598 | 531 | ||
599 | #: src/ats-tests/ats-testing-log.c:896 | ||
600 | #, fuzzy | ||
601 | msgid "Stop logging\n" | ||
602 | msgstr "Theo dõi" | ||
603 | |||
604 | #: src/ats-tests/ats-testing-log.c:952 | ||
605 | #, fuzzy, c-format | ||
606 | msgid "Start logging `%s'\n" | ||
607 | msgstr "Đang bắt đầu tài về « %s »\n" | ||
608 | |||
609 | #: src/ats-tests/gnunet-ats-sim.c:92 | 532 | #: src/ats-tests/gnunet-ats-sim.c:92 |
610 | #, c-format | 533 | #, c-format |
611 | msgid "" | 534 | msgid "" |
@@ -613,6 +536,16 @@ msgid "" | |||
613 | "= %u KiB/s\n" | 536 | "= %u KiB/s\n" |
614 | msgstr "" | 537 | msgstr "" |
615 | 538 | ||
539 | #: src/ats-tests/gnunet-solver-eval.c:997 src/ats/gnunet-ats-solver-eval.c:3552 | ||
540 | msgid "solver to use" | ||
541 | msgstr "" | ||
542 | |||
543 | #: src/ats-tests/gnunet-solver-eval.c:1003 | ||
544 | #: src/ats-tests/gnunet-solver-eval.c:1008 | ||
545 | #: src/ats/gnunet-ats-solver-eval.c:3557 | ||
546 | msgid "experiment to use" | ||
547 | msgstr "" | ||
548 | |||
616 | #: src/ats-tool/gnunet-ats.c:299 | 549 | #: src/ats-tool/gnunet-ats.c:299 |
617 | #, c-format | 550 | #, c-format |
618 | msgid "%u address resolutions had a timeout\n" | 551 | msgid "%u address resolutions had a timeout\n" |
@@ -735,6 +668,73 @@ msgstr "" | |||
735 | msgid "Print information about ATS state" | 668 | msgid "Print information about ATS state" |
736 | msgstr "In ra thông tin về các đồng đẳng GNUnet." | 669 | msgstr "In ra thông tin về các đồng đẳng GNUnet." |
737 | 670 | ||
671 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | ||
672 | #, c-format | ||
673 | msgid "" | ||
674 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | ||
675 | "%llu\n" | ||
676 | msgstr "" | ||
677 | |||
678 | #: src/ats/gnunet-ats-solver-eval.c:3011 | ||
679 | #, c-format | ||
680 | msgid "" | ||
681 | "No outbound quota configured for network `%s', assigning default bandwidth " | ||
682 | "%llu\n" | ||
683 | msgstr "" | ||
684 | |||
685 | #: src/ats/gnunet-ats-solver-eval.c:3063 | ||
686 | #, c-format | ||
687 | msgid "" | ||
688 | "No outbound quota configure for network `%s', assigning default bandwidth " | ||
689 | "%llu\n" | ||
690 | msgstr "" | ||
691 | |||
692 | #: src/ats/gnunet-ats-solver-eval.c:3564 | ||
693 | #, fuzzy | ||
694 | msgid "print logging" | ||
695 | msgstr "Theo dõi" | ||
696 | |||
697 | #: src/ats/gnunet-ats-solver-eval.c:3569 | ||
698 | msgid "save logging to disk" | ||
699 | msgstr "" | ||
700 | |||
701 | #: src/ats/gnunet-ats-solver-eval.c:3574 | ||
702 | msgid "disable normalization" | ||
703 | msgstr "" | ||
704 | |||
705 | #: src/ats/gnunet-service-ats_plugins.c:326 | ||
706 | #, c-format | ||
707 | msgid "" | ||
708 | "Could not load %s quota for network `%s': `%s', assigning default bandwidth " | ||
709 | "%llu\n" | ||
710 | msgstr "" | ||
711 | |||
712 | #: src/ats/gnunet-service-ats_plugins.c:336 | ||
713 | #, c-format | ||
714 | msgid "%s quota configured for network `%s' is %llu\n" | ||
715 | msgstr "" | ||
716 | |||
717 | #: src/ats/gnunet-service-ats_plugins.c:382 | ||
718 | #, c-format | ||
719 | msgid "" | ||
720 | "No %s-quota configured for network `%s', assigning default bandwidth %llu\n" | ||
721 | msgstr "" | ||
722 | |||
723 | #: src/ats/gnunet-service-ats_plugins.c:474 | ||
724 | #, fuzzy, c-format | ||
725 | msgid "Failed to initialize solver `%s'!\n" | ||
726 | msgstr "Không thể sơ khởi SQLite: %s.\n" | ||
727 | |||
728 | #: src/ats/plugin_ats_proportional.c:1142 | ||
729 | #, fuzzy, c-format | ||
730 | msgid "Invalid %s configuration %f \n" | ||
731 | msgstr "Không thể lưu tập tin cấu hình « %s »:" | ||
732 | |||
733 | #: src/ats/plugin_ats_proportional.c:1165 | ||
734 | #, fuzzy, c-format | ||
735 | msgid "Invalid %s configuration %f\n" | ||
736 | msgstr "Không thể lưu tập tin cấu hình « %s »:" | ||
737 | |||
738 | #: src/auction/gnunet-auction-create.c:163 | 738 | #: src/auction/gnunet-auction-create.c:163 |
739 | msgid "description of the item to be sold" | 739 | msgid "description of the item to be sold" |
740 | msgstr "" | 740 | msgstr "" |
@@ -874,6 +874,28 @@ msgstr "" | |||
874 | msgid "Connection to conversation service lost, trying to reconnect\n" | 874 | msgid "Connection to conversation service lost, trying to reconnect\n" |
875 | msgstr "" | 875 | msgstr "" |
876 | 876 | ||
877 | #: src/conversation/gnunet-conversation-test.c:120 | ||
878 | #, c-format | ||
879 | msgid "" | ||
880 | "\n" | ||
881 | "End of transmission. Have a GNU day.\n" | ||
882 | msgstr "" | ||
883 | |||
884 | #: src/conversation/gnunet-conversation-test.c:146 | ||
885 | #, c-format | ||
886 | msgid "" | ||
887 | "\n" | ||
888 | "We are now playing your recording back. If you can hear it, your audio " | ||
889 | "settings are working..." | ||
890 | msgstr "" | ||
891 | |||
892 | #: src/conversation/gnunet-conversation-test.c:218 | ||
893 | #, c-format | ||
894 | msgid "" | ||
895 | "We will now be recording you for %s. After that time, the recording will be " | ||
896 | "played back to you..." | ||
897 | msgstr "" | ||
898 | |||
877 | #: src/conversation/gnunet-conversation.c:264 | 899 | #: src/conversation/gnunet-conversation.c:264 |
878 | #, c-format | 900 | #, c-format |
879 | msgid "Incoming call from `%s'. Please /accept %u or /cancel %u the call.\n" | 901 | msgid "Incoming call from `%s'. Please /accept %u or /cancel %u the call.\n" |
@@ -1133,30 +1155,8 @@ msgstr "" | |||
1133 | msgid "Enables having a conversation with other GNUnet users." | 1155 | msgid "Enables having a conversation with other GNUnet users." |
1134 | msgstr "" | 1156 | msgstr "" |
1135 | 1157 | ||
1136 | #: src/conversation/gnunet-conversation-test.c:120 | ||
1137 | #, c-format | ||
1138 | msgid "" | ||
1139 | "\n" | ||
1140 | "End of transmission. Have a GNU day.\n" | ||
1141 | msgstr "" | ||
1142 | |||
1143 | #: src/conversation/gnunet-conversation-test.c:146 | ||
1144 | #, c-format | ||
1145 | msgid "" | ||
1146 | "\n" | ||
1147 | "We are now playing your recording back. If you can hear it, your audio " | ||
1148 | "settings are working..." | ||
1149 | msgstr "" | ||
1150 | |||
1151 | #: src/conversation/gnunet-conversation-test.c:218 | ||
1152 | #, c-format | ||
1153 | msgid "" | ||
1154 | "We will now be recording you for %s. After that time, the recording will be " | ||
1155 | "played back to you..." | ||
1156 | msgstr "" | ||
1157 | |||
1158 | #: src/conversation/gnunet_gst.c:664 | ||
1159 | #: src/conversation/gnunet-helper-audio-playback-gst.c:363 | 1158 | #: src/conversation/gnunet-helper-audio-playback-gst.c:363 |
1159 | #: src/conversation/gnunet_gst.c:664 | ||
1160 | #, c-format | 1160 | #, c-format |
1161 | msgid "Read error from STDIN: %d %s\n" | 1161 | msgid "Read error from STDIN: %d %s\n" |
1162 | msgstr "" | 1162 | msgstr "" |
@@ -1994,19 +1994,19 @@ msgstr "« %s » bị lỗi tại %s:%d với lỗi: %s\n" | |||
1994 | msgid "Mysql database running\n" | 1994 | msgid "Mysql database running\n" |
1995 | msgstr "" | 1995 | msgstr "" |
1996 | 1996 | ||
1997 | #: src/datastore/plugin_datastore_postgres.c:278 | 1997 | #: src/datastore/plugin_datastore_postgres.c:284 |
1998 | #: src/datastore/plugin_datastore_postgres.c:891 | 1998 | #: src/datastore/plugin_datastore_postgres.c:897 |
1999 | msgid "Postgress exec failure" | 1999 | msgid "Postgress exec failure" |
2000 | msgstr "" | 2000 | msgstr "" |
2001 | 2001 | ||
2002 | #: src/datastore/plugin_datastore_postgres.c:852 | 2002 | #: src/datastore/plugin_datastore_postgres.c:858 |
2003 | #, fuzzy | 2003 | #, fuzzy |
2004 | msgid "Failed to drop table from database.\n" | 2004 | msgid "Failed to drop table from database.\n" |
2005 | msgstr "" | 2005 | msgstr "" |
2006 | "\n" | 2006 | "\n" |
2007 | "Không nhận được đáp ứng từ gnunetd.\n" | 2007 | "Không nhận được đáp ứng từ gnunetd.\n" |
2008 | 2008 | ||
2009 | #: src/datastore/plugin_datastore_postgres.c:950 | 2009 | #: src/datastore/plugin_datastore_postgres.c:956 |
2010 | msgid "Postgres database running\n" | 2010 | msgid "Postgres database running\n" |
2011 | msgstr "" | 2011 | msgstr "" |
2012 | 2012 | ||
@@ -2115,54 +2115,6 @@ msgstr "" | |||
2115 | msgid "Prints all packets that go through the DHT." | 2115 | msgid "Prints all packets that go through the DHT." |
2116 | msgstr "" | 2116 | msgstr "" |
2117 | 2117 | ||
2118 | #: src/dht/gnunet_dht_profiler.c:922 src/testbed/gnunet-testbed-profiler.c:255 | ||
2119 | #, fuzzy, c-format | ||
2120 | msgid "Exiting as the number of peers is %u\n" | ||
2121 | msgstr "tăng sổ tối đa các kết nối TCP/IP" | ||
2122 | |||
2123 | #: src/dht/gnunet_dht_profiler.c:955 src/rps/gnunet-rps-profiler.c:3194 | ||
2124 | #, fuzzy | ||
2125 | msgid "number of peers to start" | ||
2126 | msgstr "số lần lặp lại" | ||
2127 | |||
2128 | #: src/dht/gnunet_dht_profiler.c:961 | ||
2129 | msgid "number of PUTs to perform per peer" | ||
2130 | msgstr "" | ||
2131 | |||
2132 | #: src/dht/gnunet_dht_profiler.c:967 src/nse/gnunet-nse-profiler.c:872 | ||
2133 | #: src/testbed/gnunet-testbed-profiler.c:305 | ||
2134 | msgid "name of the file with the login information for the testbed" | ||
2135 | msgstr "" | ||
2136 | |||
2137 | #: src/dht/gnunet_dht_profiler.c:973 | ||
2138 | msgid "delay between rounds for collecting statistics (default: 30 sec)" | ||
2139 | msgstr "" | ||
2140 | |||
2141 | #: src/dht/gnunet_dht_profiler.c:979 | ||
2142 | msgid "delay to start doing PUTs (default: 1 sec)" | ||
2143 | msgstr "" | ||
2144 | |||
2145 | #: src/dht/gnunet_dht_profiler.c:985 | ||
2146 | msgid "delay to start doing GETs (default: 5 min)" | ||
2147 | msgstr "" | ||
2148 | |||
2149 | #: src/dht/gnunet_dht_profiler.c:990 | ||
2150 | msgid "replication degree for DHT PUTs" | ||
2151 | msgstr "" | ||
2152 | |||
2153 | #: src/dht/gnunet_dht_profiler.c:996 | ||
2154 | msgid "chance that a peer is selected at random for PUTs" | ||
2155 | msgstr "" | ||
2156 | |||
2157 | #: src/dht/gnunet_dht_profiler.c:1002 | ||
2158 | msgid "timeout for DHT PUT and GET requests (default: 1 min)" | ||
2159 | msgstr "" | ||
2160 | |||
2161 | #: src/dht/gnunet_dht_profiler.c:1023 | ||
2162 | #, fuzzy | ||
2163 | msgid "Measure quality and performance of the DHT service." | ||
2164 | msgstr "Không thể truy cập đến dịch vụ" | ||
2165 | |||
2166 | #: src/dht/gnunet-dht-put.c:133 | 2118 | #: src/dht/gnunet-dht-put.c:133 |
2167 | msgid "Must provide KEY and DATA for DHT put!\n" | 2119 | msgid "Must provide KEY and DATA for DHT put!\n" |
2168 | msgstr "" | 2120 | msgstr "" |
@@ -2434,6 +2386,54 @@ msgstr "" | |||
2434 | msgid "# DHT requests combined" | 2386 | msgid "# DHT requests combined" |
2435 | msgstr "# các yêu cầu get (lấy) dht được nhận" | 2387 | msgstr "# các yêu cầu get (lấy) dht được nhận" |
2436 | 2388 | ||
2389 | #: src/dht/gnunet_dht_profiler.c:922 src/testbed/gnunet-testbed-profiler.c:255 | ||
2390 | #, fuzzy, c-format | ||
2391 | msgid "Exiting as the number of peers is %u\n" | ||
2392 | msgstr "tăng sổ tối đa các kết nối TCP/IP" | ||
2393 | |||
2394 | #: src/dht/gnunet_dht_profiler.c:955 src/rps/gnunet-rps-profiler.c:3194 | ||
2395 | #, fuzzy | ||
2396 | msgid "number of peers to start" | ||
2397 | msgstr "số lần lặp lại" | ||
2398 | |||
2399 | #: src/dht/gnunet_dht_profiler.c:961 | ||
2400 | msgid "number of PUTs to perform per peer" | ||
2401 | msgstr "" | ||
2402 | |||
2403 | #: src/dht/gnunet_dht_profiler.c:967 src/nse/gnunet-nse-profiler.c:872 | ||
2404 | #: src/testbed/gnunet-testbed-profiler.c:305 | ||
2405 | msgid "name of the file with the login information for the testbed" | ||
2406 | msgstr "" | ||
2407 | |||
2408 | #: src/dht/gnunet_dht_profiler.c:973 | ||
2409 | msgid "delay between rounds for collecting statistics (default: 30 sec)" | ||
2410 | msgstr "" | ||
2411 | |||
2412 | #: src/dht/gnunet_dht_profiler.c:979 | ||
2413 | msgid "delay to start doing PUTs (default: 1 sec)" | ||
2414 | msgstr "" | ||
2415 | |||
2416 | #: src/dht/gnunet_dht_profiler.c:985 | ||
2417 | msgid "delay to start doing GETs (default: 5 min)" | ||
2418 | msgstr "" | ||
2419 | |||
2420 | #: src/dht/gnunet_dht_profiler.c:990 | ||
2421 | msgid "replication degree for DHT PUTs" | ||
2422 | msgstr "" | ||
2423 | |||
2424 | #: src/dht/gnunet_dht_profiler.c:996 | ||
2425 | msgid "chance that a peer is selected at random for PUTs" | ||
2426 | msgstr "" | ||
2427 | |||
2428 | #: src/dht/gnunet_dht_profiler.c:1002 | ||
2429 | msgid "timeout for DHT PUT and GET requests (default: 1 min)" | ||
2430 | msgstr "" | ||
2431 | |||
2432 | #: src/dht/gnunet_dht_profiler.c:1023 | ||
2433 | #, fuzzy | ||
2434 | msgid "Measure quality and performance of the DHT service." | ||
2435 | msgstr "Không thể truy cập đến dịch vụ" | ||
2436 | |||
2437 | #: src/dht/plugin_block_dht.c:189 | 2437 | #: src/dht/plugin_block_dht.c:189 |
2438 | #, fuzzy, c-format | 2438 | #, fuzzy, c-format |
2439 | msgid "Block not of type %u\n" | 2439 | msgid "Block not of type %u\n" |
@@ -3385,15 +3385,6 @@ msgid "" | |||
3385 | "chk/...)" | 3385 | "chk/...)" |
3386 | msgstr "" | 3386 | msgstr "" |
3387 | 3387 | ||
3388 | #: src/fs/gnunet-fs.c:128 | ||
3389 | msgid "print a list of all indexed files" | ||
3390 | msgstr "" | ||
3391 | |||
3392 | #: src/fs/gnunet-fs.c:141 | ||
3393 | #, fuzzy | ||
3394 | msgid "Special file-sharing operations" | ||
3395 | msgstr "Tùy chọn chia sẻ tập tin" | ||
3396 | |||
3397 | #: src/fs/gnunet-fs-profiler.c:211 | 3388 | #: src/fs/gnunet-fs-profiler.c:211 |
3398 | msgid "run the experiment with COUNT peers" | 3389 | msgid "run the experiment with COUNT peers" |
3399 | msgstr "" | 3390 | msgstr "" |
@@ -3410,6 +3401,15 @@ msgstr "" | |||
3410 | msgid "run a testbed to measure file-sharing performance" | 3401 | msgid "run a testbed to measure file-sharing performance" |
3411 | msgstr "" | 3402 | msgstr "" |
3412 | 3403 | ||
3404 | #: src/fs/gnunet-fs.c:128 | ||
3405 | msgid "print a list of all indexed files" | ||
3406 | msgstr "" | ||
3407 | |||
3408 | #: src/fs/gnunet-fs.c:141 | ||
3409 | #, fuzzy | ||
3410 | msgid "Special file-sharing operations" | ||
3411 | msgstr "Tùy chọn chia sẻ tập tin" | ||
3412 | |||
3413 | #: src/fs/gnunet-publish.c:219 src/fs/gnunet-publish.c:234 | 3413 | #: src/fs/gnunet-publish.c:219 src/fs/gnunet-publish.c:234 |
3414 | #, c-format | 3414 | #, c-format |
3415 | msgid "Publishing `%s' at %llu/%llu (%s remaining)\n" | 3415 | msgid "Publishing `%s' at %llu/%llu (%s remaining)\n" |
@@ -4120,52 +4120,6 @@ msgstr "" | |||
4120 | msgid "look for GNS2DNS records instead of ANY" | 4120 | msgid "look for GNS2DNS records instead of ANY" |
4121 | msgstr "" | 4121 | msgstr "" |
4122 | 4122 | ||
4123 | #: src/gns/gnunet-gns.c:257 | ||
4124 | #, fuzzy, c-format | ||
4125 | msgid "`%s' is not a valid DNS domain name\n" | ||
4126 | msgstr "« %s » không sẵn sàng.\n" | ||
4127 | |||
4128 | #: src/gns/gnunet-gns.c:267 src/util/dnsparser.c:254 | ||
4129 | #, fuzzy, c-format | ||
4130 | msgid "Failed to convert DNS IDNA name `%s' to UTF-8: %s\n" | ||
4131 | msgstr "Lỗi mở tập tin ghi sự kiện « %s »: %s\n" | ||
4132 | |||
4133 | #: src/gns/gnunet-gns.c:281 | ||
4134 | msgid "Cannot resolve using GNS: GNUnet peer not running\n" | ||
4135 | msgstr "" | ||
4136 | |||
4137 | #: src/gns/gnunet-gns.c:305 | ||
4138 | #, c-format | ||
4139 | msgid "Invalid typename specified, assuming `ANY'\n" | ||
4140 | msgstr "" | ||
4141 | |||
4142 | #: src/gns/gnunet-gns.c:340 | ||
4143 | msgid "Lookup a record for the given name" | ||
4144 | msgstr "" | ||
4145 | |||
4146 | #: src/gns/gnunet-gns.c:346 | ||
4147 | #, fuzzy | ||
4148 | msgid "Specify the type of the record to lookup" | ||
4149 | msgstr "xác định mức ưu tiên của nội dung" | ||
4150 | |||
4151 | #: src/gns/gnunet-gns.c:352 | ||
4152 | #, fuzzy | ||
4153 | msgid "Specify a timeout for the lookup" | ||
4154 | msgstr "xác định mức ưu tiên của nội dung" | ||
4155 | |||
4156 | #: src/gns/gnunet-gns.c:356 | ||
4157 | msgid "No unneeded output" | ||
4158 | msgstr "" | ||
4159 | |||
4160 | #: src/gns/gnunet-gns.c:361 | ||
4161 | msgid "DNS Compatibility: Name is passed in IDNA instead of UTF-8" | ||
4162 | msgstr "" | ||
4163 | |||
4164 | #: src/gns/gnunet-gns.c:375 | ||
4165 | #, fuzzy | ||
4166 | msgid "GNUnet GNS resolver tool" | ||
4167 | msgstr "Bản ghi lỗi GNUnet" | ||
4168 | |||
4169 | #: src/gns/gnunet-gns-import.c:486 | 4123 | #: src/gns/gnunet-gns-import.c:486 |
4170 | msgid "This program will import some GNS authorities into your GNS namestore." | 4124 | msgid "This program will import some GNS authorities into your GNS namestore." |
4171 | msgstr "" | 4125 | msgstr "" |
@@ -4286,6 +4240,52 @@ msgstr "" | |||
4286 | msgid "GNUnet GNS proxy" | 4240 | msgid "GNUnet GNS proxy" |
4287 | msgstr "" | 4241 | msgstr "" |
4288 | 4242 | ||
4243 | #: src/gns/gnunet-gns.c:257 | ||
4244 | #, fuzzy, c-format | ||
4245 | msgid "`%s' is not a valid DNS domain name\n" | ||
4246 | msgstr "« %s » không sẵn sàng.\n" | ||
4247 | |||
4248 | #: src/gns/gnunet-gns.c:267 src/util/dnsparser.c:254 | ||
4249 | #, fuzzy, c-format | ||
4250 | msgid "Failed to convert DNS IDNA name `%s' to UTF-8: %s\n" | ||
4251 | msgstr "Lỗi mở tập tin ghi sự kiện « %s »: %s\n" | ||
4252 | |||
4253 | #: src/gns/gnunet-gns.c:281 | ||
4254 | msgid "Cannot resolve using GNS: GNUnet peer not running\n" | ||
4255 | msgstr "" | ||
4256 | |||
4257 | #: src/gns/gnunet-gns.c:305 | ||
4258 | #, c-format | ||
4259 | msgid "Invalid typename specified, assuming `ANY'\n" | ||
4260 | msgstr "" | ||
4261 | |||
4262 | #: src/gns/gnunet-gns.c:340 | ||
4263 | msgid "Lookup a record for the given name" | ||
4264 | msgstr "" | ||
4265 | |||
4266 | #: src/gns/gnunet-gns.c:346 | ||
4267 | #, fuzzy | ||
4268 | msgid "Specify the type of the record to lookup" | ||
4269 | msgstr "xác định mức ưu tiên của nội dung" | ||
4270 | |||
4271 | #: src/gns/gnunet-gns.c:352 | ||
4272 | #, fuzzy | ||
4273 | msgid "Specify a timeout for the lookup" | ||
4274 | msgstr "xác định mức ưu tiên của nội dung" | ||
4275 | |||
4276 | #: src/gns/gnunet-gns.c:356 | ||
4277 | msgid "No unneeded output" | ||
4278 | msgstr "" | ||
4279 | |||
4280 | #: src/gns/gnunet-gns.c:361 | ||
4281 | msgid "DNS Compatibility: Name is passed in IDNA instead of UTF-8" | ||
4282 | msgstr "" | ||
4283 | |||
4284 | #: src/gns/gnunet-gns.c:375 | ||
4285 | #, fuzzy | ||
4286 | msgid "GNUnet GNS resolver tool" | ||
4287 | msgstr "Bản ghi lỗi GNUnet" | ||
4288 | |||
4289 | #: src/gns/gnunet-service-gns.c:505 | 4289 | #: src/gns/gnunet-service-gns.c:505 |
4290 | #, fuzzy | 4290 | #, fuzzy |
4291 | msgid "Properly base32-encoded public key required" | 4291 | msgid "Properly base32-encoded public key required" |
@@ -4297,8 +4297,8 @@ msgid "Failed to connect to the namecache!\n" | |||
4297 | msgstr "Không kết nối được đến trình nền gnunetd." | 4297 | msgstr "Không kết nối được đến trình nền gnunetd." |
4298 | 4298 | ||
4299 | #: src/gns/gnunet-service-gns.c:560 | 4299 | #: src/gns/gnunet-service-gns.c:560 |
4300 | #: src/zonemaster/gnunet-service-zonemaster.c:887 | ||
4301 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:444 | 4300 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:444 |
4301 | #: src/zonemaster/gnunet-service-zonemaster.c:887 | ||
4302 | #, fuzzy | 4302 | #, fuzzy |
4303 | msgid "Could not connect to DHT!\n" | 4303 | msgid "Could not connect to DHT!\n" |
4304 | msgstr "Không thể kết nối tới %s:%u: %s\n" | 4304 | msgstr "Không thể kết nối tới %s:%u: %s\n" |
@@ -4809,7 +4809,7 @@ msgid "# hostlist advertisements send" | |||
4809 | msgstr "# Các quảng cáo ngoại được chuyển tiếp" | 4809 | msgstr "# Các quảng cáo ngoại được chuyển tiếp" |
4810 | 4810 | ||
4811 | #: src/hostlist/gnunet-daemon-hostlist_server.c:674 | 4811 | #: src/hostlist/gnunet-daemon-hostlist_server.c:674 |
4812 | #: src/transport/gnunet-service-transport.c:2659 | 4812 | #: src/transport/gnunet-service-transport.c:2661 |
4813 | #, fuzzy | 4813 | #, fuzzy |
4814 | msgid "Could not access PEERINFO service. Exiting.\n" | 4814 | msgid "Could not access PEERINFO service. Exiting.\n" |
4815 | msgstr "Không thể truy cập đến thông tin về không gian tên.\n" | 4815 | msgstr "Không thể truy cập đến thông tin về không gian tên.\n" |
@@ -5065,6 +5065,70 @@ msgstr "kho dữ liệu sqlite" | |||
5065 | msgid "Failed to setup database at `%s'\n" | 5065 | msgid "Failed to setup database at `%s'\n" |
5066 | msgstr "Lỗi chạy %s: %s %d\n" | 5066 | msgstr "Lỗi chạy %s: %s %d\n" |
5067 | 5067 | ||
5068 | #: src/namestore/gnunet-namestore-fcfsd.c:552 | ||
5069 | #, fuzzy, c-format | ||
5070 | msgid "Unsupported form value `%s'\n" | ||
5071 | msgstr "Lệnh không được hỗ trợ « %s ». Đang hủy bỏ.\n" | ||
5072 | |||
5073 | #: src/namestore/gnunet-namestore-fcfsd.c:579 | ||
5074 | #, fuzzy, c-format | ||
5075 | msgid "Failed to create record for domain `%s': %s\n" | ||
5076 | msgstr "Không thể truy cập đến tập tin gnunet-directory « %s »\n" | ||
5077 | |||
5078 | #: src/namestore/gnunet-namestore-fcfsd.c:600 | ||
5079 | msgid "Error when mapping zone to name\n" | ||
5080 | msgstr "" | ||
5081 | |||
5082 | #: src/namestore/gnunet-namestore-fcfsd.c:632 | ||
5083 | #, c-format | ||
5084 | msgid "Found existing name `%s' for the given key\n" | ||
5085 | msgstr "" | ||
5086 | |||
5087 | #: src/namestore/gnunet-namestore-fcfsd.c:694 | ||
5088 | #, c-format | ||
5089 | msgid "Found %u existing records for domain `%s'\n" | ||
5090 | msgstr "" | ||
5091 | |||
5092 | #: src/namestore/gnunet-namestore-fcfsd.c:784 | ||
5093 | #, fuzzy, c-format | ||
5094 | msgid "Failed to create page for `%s'\n" | ||
5095 | msgstr "Không thể tạo miền tên.\n" | ||
5096 | |||
5097 | #: src/namestore/gnunet-namestore-fcfsd.c:803 | ||
5098 | #, fuzzy, c-format | ||
5099 | msgid "Failed to setup post processor for `%s'\n" | ||
5100 | msgstr "Lỗi cập nhật dữ liệu cho mô-đun « %s »\n" | ||
5101 | |||
5102 | #: src/namestore/gnunet-namestore-fcfsd.c:840 | ||
5103 | msgid "Domain name must not contain `.'\n" | ||
5104 | msgstr "" | ||
5105 | |||
5106 | #: src/namestore/gnunet-namestore-fcfsd.c:849 | ||
5107 | msgid "Domain name must not contain `+'\n" | ||
5108 | msgstr "" | ||
5109 | |||
5110 | #: src/namestore/gnunet-namestore-fcfsd.c:1084 | ||
5111 | msgid "No ego configured for `fcfsd` subsystem\n" | ||
5112 | msgstr "" | ||
5113 | |||
5114 | #: src/namestore/gnunet-namestore-fcfsd.c:1115 | ||
5115 | #, fuzzy | ||
5116 | msgid "Failed to start HTTP server\n" | ||
5117 | msgstr "Lỗi bắt đầu thu thập.\n" | ||
5118 | |||
5119 | #: src/namestore/gnunet-namestore-fcfsd.c:1163 | ||
5120 | #, fuzzy | ||
5121 | msgid "Failed to connect to identity\n" | ||
5122 | msgstr "Lỗi kết nối đến gnunetd.\n" | ||
5123 | |||
5124 | #: src/namestore/gnunet-namestore-fcfsd.c:1190 | ||
5125 | msgid "name of the zone that is to be managed by FCFSD" | ||
5126 | msgstr "" | ||
5127 | |||
5128 | #: src/namestore/gnunet-namestore-fcfsd.c:1210 | ||
5129 | msgid "GNU Name System First Come First Serve name registration service" | ||
5130 | msgstr "" | ||
5131 | |||
5068 | #: src/namestore/gnunet-namestore.c:334 | 5132 | #: src/namestore/gnunet-namestore.c:334 |
5069 | #, fuzzy, c-format | 5133 | #, fuzzy, c-format |
5070 | msgid "Adding record failed: %s\n" | 5134 | msgid "Adding record failed: %s\n" |
@@ -5294,70 +5358,6 @@ msgstr "" | |||
5294 | msgid "name of the ego controlling the zone" | 5358 | msgid "name of the ego controlling the zone" |
5295 | msgstr "" | 5359 | msgstr "" |
5296 | 5360 | ||
5297 | #: src/namestore/gnunet-namestore-fcfsd.c:552 | ||
5298 | #, fuzzy, c-format | ||
5299 | msgid "Unsupported form value `%s'\n" | ||
5300 | msgstr "Lệnh không được hỗ trợ « %s ». Đang hủy bỏ.\n" | ||
5301 | |||
5302 | #: src/namestore/gnunet-namestore-fcfsd.c:579 | ||
5303 | #, fuzzy, c-format | ||
5304 | msgid "Failed to create record for domain `%s': %s\n" | ||
5305 | msgstr "Không thể truy cập đến tập tin gnunet-directory « %s »\n" | ||
5306 | |||
5307 | #: src/namestore/gnunet-namestore-fcfsd.c:600 | ||
5308 | msgid "Error when mapping zone to name\n" | ||
5309 | msgstr "" | ||
5310 | |||
5311 | #: src/namestore/gnunet-namestore-fcfsd.c:632 | ||
5312 | #, c-format | ||
5313 | msgid "Found existing name `%s' for the given key\n" | ||
5314 | msgstr "" | ||
5315 | |||
5316 | #: src/namestore/gnunet-namestore-fcfsd.c:694 | ||
5317 | #, c-format | ||
5318 | msgid "Found %u existing records for domain `%s'\n" | ||
5319 | msgstr "" | ||
5320 | |||
5321 | #: src/namestore/gnunet-namestore-fcfsd.c:784 | ||
5322 | #, fuzzy, c-format | ||
5323 | msgid "Failed to create page for `%s'\n" | ||
5324 | msgstr "Không thể tạo miền tên.\n" | ||
5325 | |||
5326 | #: src/namestore/gnunet-namestore-fcfsd.c:803 | ||
5327 | #, fuzzy, c-format | ||
5328 | msgid "Failed to setup post processor for `%s'\n" | ||
5329 | msgstr "Lỗi cập nhật dữ liệu cho mô-đun « %s »\n" | ||
5330 | |||
5331 | #: src/namestore/gnunet-namestore-fcfsd.c:840 | ||
5332 | msgid "Domain name must not contain `.'\n" | ||
5333 | msgstr "" | ||
5334 | |||
5335 | #: src/namestore/gnunet-namestore-fcfsd.c:849 | ||
5336 | msgid "Domain name must not contain `+'\n" | ||
5337 | msgstr "" | ||
5338 | |||
5339 | #: src/namestore/gnunet-namestore-fcfsd.c:1084 | ||
5340 | msgid "No ego configured for `fcfsd` subsystem\n" | ||
5341 | msgstr "" | ||
5342 | |||
5343 | #: src/namestore/gnunet-namestore-fcfsd.c:1115 | ||
5344 | #, fuzzy | ||
5345 | msgid "Failed to start HTTP server\n" | ||
5346 | msgstr "Lỗi bắt đầu thu thập.\n" | ||
5347 | |||
5348 | #: src/namestore/gnunet-namestore-fcfsd.c:1163 | ||
5349 | #, fuzzy | ||
5350 | msgid "Failed to connect to identity\n" | ||
5351 | msgstr "Lỗi kết nối đến gnunetd.\n" | ||
5352 | |||
5353 | #: src/namestore/gnunet-namestore-fcfsd.c:1190 | ||
5354 | msgid "name of the zone that is to be managed by FCFSD" | ||
5355 | msgstr "" | ||
5356 | |||
5357 | #: src/namestore/gnunet-namestore-fcfsd.c:1210 | ||
5358 | msgid "GNU Name System First Come First Serve name registration service" | ||
5359 | msgstr "" | ||
5360 | |||
5361 | #: src/namestore/gnunet-service-namestore.c:866 | 5361 | #: src/namestore/gnunet-service-namestore.c:866 |
5362 | #, fuzzy, c-format | 5362 | #, fuzzy, c-format |
5363 | msgid "Failed to replicate block in namecache: %s\n" | 5363 | msgid "Failed to replicate block in namecache: %s\n" |
@@ -5677,11 +5677,6 @@ msgstr "" | |||
5677 | msgid "`upnpc' command not found\n" | 5677 | msgid "`upnpc' command not found\n" |
5678 | msgstr "" | 5678 | msgstr "" |
5679 | 5679 | ||
5680 | #: src/nse/gnunet-nse.c:124 | ||
5681 | #, fuzzy | ||
5682 | msgid "Show network size estimates from NSE service." | ||
5683 | msgstr "# các yêu cầu get (lấy) dht được nhận" | ||
5684 | |||
5685 | #: src/nse/gnunet-nse-profiler.c:857 | 5680 | #: src/nse/gnunet-nse-profiler.c:857 |
5686 | #, fuzzy | 5681 | #, fuzzy |
5687 | msgid "limit to the number of connections to NSE services, 0 for none" | 5682 | msgid "limit to the number of connections to NSE services, 0 for none" |
@@ -5708,71 +5703,17 @@ msgstr "" | |||
5708 | msgid "Measure quality and performance of the NSE service." | 5703 | msgid "Measure quality and performance of the NSE service." |
5709 | msgstr "Không thể truy cập đến dịch vụ" | 5704 | msgstr "Không thể truy cập đến dịch vụ" |
5710 | 5705 | ||
5706 | #: src/nse/gnunet-nse.c:124 | ||
5707 | #, fuzzy | ||
5708 | msgid "Show network size estimates from NSE service." | ||
5709 | msgstr "# các yêu cầu get (lấy) dht được nhận" | ||
5710 | |||
5711 | #: src/nse/gnunet-service-nse.c:1443 | 5711 | #: src/nse/gnunet-service-nse.c:1443 |
5712 | #: src/revocation/gnunet-service-revocation.c:834 src/util/gnunet-scrypt.c:257 | 5712 | #: src/revocation/gnunet-service-revocation.c:834 src/util/gnunet-scrypt.c:257 |
5713 | #, fuzzy | 5713 | #, fuzzy |
5714 | msgid "Value is too large.\n" | 5714 | msgid "Value is too large.\n" |
5715 | msgstr "Giá trị không nằm trong phạm vi được phép." | 5715 | msgstr "Giá trị không nằm trong phạm vi được phép." |
5716 | 5716 | ||
5717 | #: src/peerinfo/gnunet-service-peerinfo.c:175 | ||
5718 | #, fuzzy, c-format | ||
5719 | msgid "Removing expired address of transport `%s'\n" | ||
5720 | msgstr "Đã nạp truyền tải « %s »\n" | ||
5721 | |||
5722 | #: src/peerinfo/gnunet-service-peerinfo.c:306 | ||
5723 | #, fuzzy, c-format | ||
5724 | msgid "Failed to parse HELLO in file `%s': %s\n" | ||
5725 | msgstr "Lỗi đọc danh sách bạn bè từ « %s »\n" | ||
5726 | |||
5727 | #: src/peerinfo/gnunet-service-peerinfo.c:323 | ||
5728 | #: src/peerinfo/gnunet-service-peerinfo.c:348 | ||
5729 | #, fuzzy, c-format | ||
5730 | msgid "Failed to parse HELLO in file `%s'\n" | ||
5731 | msgstr "Lỗi đọc danh sách bạn bè từ « %s »\n" | ||
5732 | |||
5733 | #: src/peerinfo/gnunet-service-peerinfo.c:426 | ||
5734 | msgid "# peers known" | ||
5735 | msgstr "" | ||
5736 | |||
5737 | #: src/peerinfo/gnunet-service-peerinfo.c:468 | ||
5738 | #, c-format | ||
5739 | msgid "" | ||
5740 | "File `%s' in directory `%s' does not match naming convention. Removed.\n" | ||
5741 | msgstr "" | ||
5742 | "Tập tin « %s » trong thư mục « %s » không tùy theo quy ước đặt tên. Bị gỡ " | ||
5743 | "bỏ.\n" | ||
5744 | |||
5745 | #: src/peerinfo/gnunet-service-peerinfo.c:624 | ||
5746 | #, fuzzy, c-format | ||
5747 | msgid "Scanning directory `%s'\n" | ||
5748 | msgstr "Lỗi đọc danh sách bạn bè từ « %s »\n" | ||
5749 | |||
5750 | #: src/peerinfo/gnunet-service-peerinfo.c:631 | ||
5751 | #, c-format | ||
5752 | msgid "Still no peers found in `%s'!\n" | ||
5753 | msgstr "Vẫn còn không tìm thấy đồng đẳng trong « %s ».\n" | ||
5754 | |||
5755 | #: src/peerinfo/gnunet-service-peerinfo.c:1024 | ||
5756 | #, fuzzy, c-format | ||
5757 | msgid "Cleaning up directory `%s'\n" | ||
5758 | msgstr "Lỗi đọc danh sách bạn bè từ « %s »\n" | ||
5759 | |||
5760 | #: src/peerinfo/gnunet-service-peerinfo.c:1319 | ||
5761 | #, c-format | ||
5762 | msgid "Importing HELLOs from `%s'\n" | ||
5763 | msgstr "" | ||
5764 | |||
5765 | #: src/peerinfo/gnunet-service-peerinfo.c:1332 | ||
5766 | msgid "Skipping import of included HELLOs\n" | ||
5767 | msgstr "" | ||
5768 | |||
5769 | #: src/peerinfo/peerinfo_api.c:217 | ||
5770 | #, fuzzy | ||
5771 | msgid "Failed to receive response from `PEERINFO' service." | ||
5772 | msgstr "" | ||
5773 | "\n" | ||
5774 | "Không nhận được đáp ứng từ gnunetd.\n" | ||
5775 | |||
5776 | #: src/peerinfo-tool/gnunet-peerinfo.c:237 | 5717 | #: src/peerinfo-tool/gnunet-peerinfo.c:237 |
5777 | #, fuzzy, c-format | 5718 | #, fuzzy, c-format |
5778 | msgid "%sPeer `%s'\n" | 5719 | msgid "%sPeer `%s'\n" |
@@ -5870,6 +5811,65 @@ msgstr "Không thể nạp phần bổ sung truyền tải « %s »\n" | |||
5870 | msgid "Peerinfo REST API initialized\n" | 5811 | msgid "Peerinfo REST API initialized\n" |
5871 | msgstr "Lỗi sơ khởi lõi.\n" | 5812 | msgstr "Lỗi sơ khởi lõi.\n" |
5872 | 5813 | ||
5814 | #: src/peerinfo/gnunet-service-peerinfo.c:175 | ||
5815 | #, fuzzy, c-format | ||
5816 | msgid "Removing expired address of transport `%s'\n" | ||
5817 | msgstr "Đã nạp truyền tải « %s »\n" | ||
5818 | |||
5819 | #: src/peerinfo/gnunet-service-peerinfo.c:306 | ||
5820 | #, fuzzy, c-format | ||
5821 | msgid "Failed to parse HELLO in file `%s': %s\n" | ||
5822 | msgstr "Lỗi đọc danh sách bạn bè từ « %s »\n" | ||
5823 | |||
5824 | #: src/peerinfo/gnunet-service-peerinfo.c:323 | ||
5825 | #: src/peerinfo/gnunet-service-peerinfo.c:348 | ||
5826 | #, fuzzy, c-format | ||
5827 | msgid "Failed to parse HELLO in file `%s'\n" | ||
5828 | msgstr "Lỗi đọc danh sách bạn bè từ « %s »\n" | ||
5829 | |||
5830 | #: src/peerinfo/gnunet-service-peerinfo.c:426 | ||
5831 | msgid "# peers known" | ||
5832 | msgstr "" | ||
5833 | |||
5834 | #: src/peerinfo/gnunet-service-peerinfo.c:468 | ||
5835 | #, c-format | ||
5836 | msgid "" | ||
5837 | "File `%s' in directory `%s' does not match naming convention. Removed.\n" | ||
5838 | msgstr "" | ||
5839 | "Tập tin « %s » trong thư mục « %s » không tùy theo quy ước đặt tên. Bị gỡ " | ||
5840 | "bỏ.\n" | ||
5841 | |||
5842 | #: src/peerinfo/gnunet-service-peerinfo.c:624 | ||
5843 | #, fuzzy, c-format | ||
5844 | msgid "Scanning directory `%s'\n" | ||
5845 | msgstr "Lỗi đọc danh sách bạn bè từ « %s »\n" | ||
5846 | |||
5847 | #: src/peerinfo/gnunet-service-peerinfo.c:631 | ||
5848 | #, c-format | ||
5849 | msgid "Still no peers found in `%s'!\n" | ||
5850 | msgstr "Vẫn còn không tìm thấy đồng đẳng trong « %s ».\n" | ||
5851 | |||
5852 | #: src/peerinfo/gnunet-service-peerinfo.c:1024 | ||
5853 | #, fuzzy, c-format | ||
5854 | msgid "Cleaning up directory `%s'\n" | ||
5855 | msgstr "Lỗi đọc danh sách bạn bè từ « %s »\n" | ||
5856 | |||
5857 | #: src/peerinfo/gnunet-service-peerinfo.c:1319 | ||
5858 | #, c-format | ||
5859 | msgid "Importing HELLOs from `%s'\n" | ||
5860 | msgstr "" | ||
5861 | |||
5862 | #: src/peerinfo/gnunet-service-peerinfo.c:1332 | ||
5863 | msgid "Skipping import of included HELLOs\n" | ||
5864 | msgstr "" | ||
5865 | |||
5866 | #: src/peerinfo/peerinfo_api.c:217 | ||
5867 | #, fuzzy | ||
5868 | msgid "Failed to receive response from `PEERINFO' service." | ||
5869 | msgstr "" | ||
5870 | "\n" | ||
5871 | "Không nhận được đáp ứng từ gnunetd.\n" | ||
5872 | |||
5873 | #: src/peerstore/gnunet-peerstore.c:92 | 5873 | #: src/peerstore/gnunet-peerstore.c:92 |
5874 | msgid "peerstore" | 5874 | msgid "peerstore" |
5875 | msgstr "" | 5875 | msgstr "" |
@@ -6339,18 +6339,6 @@ msgstr "" | |||
6339 | msgid "Could not open revocation database file!" | 6339 | msgid "Could not open revocation database file!" |
6340 | msgstr "« %s »: Không thể kết nối.\n" | 6340 | msgstr "« %s »: Không thể kết nối.\n" |
6341 | 6341 | ||
6342 | #: src/rps/gnunet-rps.c:270 | ||
6343 | msgid "Seed a PeerID" | ||
6344 | msgstr "" | ||
6345 | |||
6346 | #: src/rps/gnunet-rps.c:275 | ||
6347 | msgid "Get updates of view (0 for infinite updates)" | ||
6348 | msgstr "" | ||
6349 | |||
6350 | #: src/rps/gnunet-rps.c:279 | ||
6351 | msgid "Get peers from biased stream" | ||
6352 | msgstr "" | ||
6353 | |||
6354 | #: src/rps/gnunet-rps-profiler.c:3200 | 6342 | #: src/rps/gnunet-rps-profiler.c:3200 |
6355 | msgid "duration of the profiling" | 6343 | msgid "duration of the profiling" |
6356 | msgstr "" | 6344 | msgstr "" |
@@ -6370,6 +6358,18 @@ msgstr "số lần lặp lại" | |||
6370 | msgid "Measure quality and performance of the RPS service." | 6358 | msgid "Measure quality and performance of the RPS service." |
6371 | msgstr "Không thể truy cập đến dịch vụ" | 6359 | msgstr "Không thể truy cập đến dịch vụ" |
6372 | 6360 | ||
6361 | #: src/rps/gnunet-rps.c:270 | ||
6362 | msgid "Seed a PeerID" | ||
6363 | msgstr "" | ||
6364 | |||
6365 | #: src/rps/gnunet-rps.c:275 | ||
6366 | msgid "Get updates of view (0 for infinite updates)" | ||
6367 | msgstr "" | ||
6368 | |||
6369 | #: src/rps/gnunet-rps.c:279 | ||
6370 | msgid "Get peers from biased stream" | ||
6371 | msgstr "" | ||
6372 | |||
6373 | #: src/scalarproduct/gnunet-scalarproduct.c:229 | 6373 | #: src/scalarproduct/gnunet-scalarproduct.c:229 |
6374 | #, fuzzy | 6374 | #, fuzzy |
6375 | msgid "You must specify at least one message ID to check!\n" | 6375 | msgid "You must specify at least one message ID to check!\n" |
@@ -6425,10 +6425,10 @@ msgstr "" | |||
6425 | msgid "Calculate the Vectorproduct with a GNUnet peer." | 6425 | msgid "Calculate the Vectorproduct with a GNUnet peer." |
6426 | msgstr "" | 6426 | msgstr "" |
6427 | 6427 | ||
6428 | #: src/scalarproduct/gnunet-service-scalarproduct_alice.c:1358 | ||
6429 | #: src/scalarproduct/gnunet-service-scalarproduct_bob.c:1355 | ||
6430 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_alice.c:1118 | 6428 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_alice.c:1118 |
6431 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c:1063 | 6429 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c:1063 |
6430 | #: src/scalarproduct/gnunet-service-scalarproduct_alice.c:1358 | ||
6431 | #: src/scalarproduct/gnunet-service-scalarproduct_bob.c:1355 | ||
6432 | #, fuzzy | 6432 | #, fuzzy |
6433 | msgid "Connect to CADET failed\n" | 6433 | msgid "Connect to CADET failed\n" |
6434 | msgstr " Không kết nối được (lỗi ?)\n" | 6434 | msgstr " Không kết nối được (lỗi ?)\n" |
@@ -6783,16 +6783,6 @@ msgstr "« %s » đang tắt.\n" | |||
6783 | msgid "%.s Unknown result code." | 6783 | msgid "%.s Unknown result code." |
6784 | msgstr "" | 6784 | msgstr "" |
6785 | 6785 | ||
6786 | #: src/testbed/gnunet_testbed_mpi_spawn.c:119 | ||
6787 | #, fuzzy | ||
6788 | msgid "Waiting for child to exit.\n" | ||
6789 | msgstr "Đang đợi các đồng đẳng kết nối" | ||
6790 | |||
6791 | #: src/testbed/gnunet_testbed_mpi_spawn.c:242 | ||
6792 | #, fuzzy, c-format | ||
6793 | msgid "Spawning process `%s'\n" | ||
6794 | msgstr "Đang bắt đầu tài về « %s »\n" | ||
6795 | |||
6796 | #: src/testbed/gnunet-testbed-profiler.c:290 | 6786 | #: src/testbed/gnunet-testbed-profiler.c:290 |
6797 | msgid "tolerate COUNT number of continious timeout failures" | 6787 | msgid "tolerate COUNT number of continious timeout failures" |
6798 | msgstr "" | 6788 | msgstr "" |
@@ -6804,6 +6794,16 @@ msgid "" | |||
6804 | "signal is received" | 6794 | "signal is received" |
6805 | msgstr "" | 6795 | msgstr "" |
6806 | 6796 | ||
6797 | #: src/testbed/gnunet_testbed_mpi_spawn.c:119 | ||
6798 | #, fuzzy | ||
6799 | msgid "Waiting for child to exit.\n" | ||
6800 | msgstr "Đang đợi các đồng đẳng kết nối" | ||
6801 | |||
6802 | #: src/testbed/gnunet_testbed_mpi_spawn.c:242 | ||
6803 | #, fuzzy, c-format | ||
6804 | msgid "Spawning process `%s'\n" | ||
6805 | msgstr "Đang bắt đầu tài về « %s »\n" | ||
6806 | |||
6807 | #: src/testbed/testbed_api.c:399 | 6807 | #: src/testbed/testbed_api.c:399 |
6808 | #, fuzzy, c-format | 6808 | #, fuzzy, c-format |
6809 | msgid "Adding host %u failed with error: %s\n" | 6809 | msgid "Adding host %u failed with error: %s\n" |
@@ -7106,19 +7106,19 @@ msgstr "# các thông báo PONG đã mật mã được nhận" | |||
7106 | msgid "GNUnet topology control" | 7106 | msgid "GNUnet topology control" |
7107 | msgstr "" | 7107 | msgstr "" |
7108 | 7108 | ||
7109 | #: src/transport/gnunet-communicator-tcp.c:3189 | 7109 | #: src/transport/gnunet-communicator-tcp.c:3221 |
7110 | #: src/transport/gnunet-communicator-udp.c:2826 | 7110 | #: src/transport/gnunet-communicator-udp.c:2995 |
7111 | #: src/transport/gnunet-service-tng.c:10014 | 7111 | #: src/transport/gnunet-service-tng.c:10014 |
7112 | #: src/transport/gnunet-service-transport.c:2624 | 7112 | #: src/transport/gnunet-service-transport.c:2626 |
7113 | #, fuzzy | 7113 | #, fuzzy |
7114 | msgid "Transport service is lacking key configuration settings. Exiting.\n" | 7114 | msgid "Transport service is lacking key configuration settings. Exiting.\n" |
7115 | msgstr "Lưu cấu hình ngay bây giờ không?" | 7115 | msgstr "Lưu cấu hình ngay bây giờ không?" |
7116 | 7116 | ||
7117 | #: src/transport/gnunet-communicator-tcp.c:3494 | 7117 | #: src/transport/gnunet-communicator-tcp.c:3553 |
7118 | msgid "GNUnet TCP communicator" | 7118 | msgid "GNUnet TCP communicator" |
7119 | msgstr "" | 7119 | msgstr "" |
7120 | 7120 | ||
7121 | #: src/transport/gnunet-communicator-udp.c:2898 | 7121 | #: src/transport/gnunet-communicator-udp.c:3067 |
7122 | msgid "GNUnet UDP communicator" | 7122 | msgid "GNUnet UDP communicator" |
7123 | msgstr "" | 7123 | msgstr "" |
7124 | 7124 | ||
@@ -7143,54 +7143,54 @@ msgstr "Không thể tạo miền tên.\n" | |||
7143 | msgid "GNUnet UNIX domain socket communicator" | 7143 | msgid "GNUnet UNIX domain socket communicator" |
7144 | msgstr "" | 7144 | msgstr "" |
7145 | 7145 | ||
7146 | #: src/transport/gnunet-service-transport_ats.c:137 | ||
7147 | msgid "# Addresses given to ATS" | ||
7148 | msgstr "" | ||
7149 | |||
7150 | #: src/transport/gnunet-service-transport.c:445 | 7146 | #: src/transport/gnunet-service-transport.c:445 |
7151 | #, fuzzy | 7147 | #, fuzzy |
7152 | msgid "# messages dropped due to slow client" | 7148 | msgid "# messages dropped due to slow client" |
7153 | msgstr "# các yêu cầu lỗ hổng bị bỏ do trọng tải" | 7149 | msgstr "# các yêu cầu lỗ hổng bị bỏ do trọng tải" |
7154 | 7150 | ||
7155 | #: src/transport/gnunet-service-transport.c:794 | 7151 | #: src/transport/gnunet-service-transport.c:796 |
7156 | msgid "# bytes payload dropped (other peer was not connected)" | 7152 | msgid "# bytes payload dropped (other peer was not connected)" |
7157 | msgstr "" | 7153 | msgstr "" |
7158 | 7154 | ||
7159 | #: src/transport/gnunet-service-transport.c:1477 | 7155 | #: src/transport/gnunet-service-transport.c:1479 |
7160 | #, fuzzy | 7156 | #, fuzzy |
7161 | msgid "# bytes payload discarded due to not connected peer" | 7157 | msgid "# bytes payload discarded due to not connected peer" |
7162 | msgstr "# Các quảng cáo đồng đẳng bị hủy do trọng tải" | 7158 | msgstr "# Các quảng cáo đồng đẳng bị hủy do trọng tải" |
7163 | 7159 | ||
7164 | #: src/transport/gnunet-service-transport.c:1622 | 7160 | #: src/transport/gnunet-service-transport.c:1624 |
7165 | #, fuzzy | 7161 | #, fuzzy |
7166 | msgid "# bytes total received" | 7162 | msgid "# bytes total received" |
7167 | msgstr "# tổng số nội dung lỗ hổng được nhận" | 7163 | msgstr "# tổng số nội dung lỗ hổng được nhận" |
7168 | 7164 | ||
7169 | #: src/transport/gnunet-service-transport.c:1712 | 7165 | #: src/transport/gnunet-service-transport.c:1714 |
7170 | #, fuzzy | 7166 | #, fuzzy |
7171 | msgid "# bytes payload received" | 7167 | msgid "# bytes payload received" |
7172 | msgstr "# các byte đã giải mã" | 7168 | msgstr "# các byte đã giải mã" |
7173 | 7169 | ||
7174 | #: src/transport/gnunet-service-transport.c:2016 | 7170 | #: src/transport/gnunet-service-transport.c:2018 |
7175 | #: src/transport/gnunet-service-transport.c:2450 | 7171 | #: src/transport/gnunet-service-transport.c:2452 |
7176 | msgid "# disconnects due to blacklist" | 7172 | msgid "# disconnects due to blacklist" |
7177 | msgstr "" | 7173 | msgstr "" |
7178 | 7174 | ||
7179 | #: src/transport/gnunet-service-transport.c:2454 | 7175 | #: src/transport/gnunet-service-transport.c:2456 |
7180 | #, fuzzy, c-format | 7176 | #, fuzzy, c-format |
7181 | msgid "Disallowing connection to peer `%s' on transport %s\n" | 7177 | msgid "Disallowing connection to peer `%s' on transport %s\n" |
7182 | msgstr "Không thể nạp phần bổ sung truyền tải « %s »\n" | 7178 | msgstr "Không thể nạp phần bổ sung truyền tải « %s »\n" |
7183 | 7179 | ||
7184 | #: src/transport/gnunet-service-transport.c:2549 | 7180 | #: src/transport/gnunet-service-transport.c:2551 |
7185 | #, fuzzy, c-format | 7181 | #, fuzzy, c-format |
7186 | msgid "Adding blacklisting entry for peer `%s'\n" | 7182 | msgid "Adding blacklisting entry for peer `%s'\n" |
7187 | msgstr "Không thể lấy địa chỉ của đồng đẳng « %s ».\n" | 7183 | msgstr "Không thể lấy địa chỉ của đồng đẳng « %s ».\n" |
7188 | 7184 | ||
7189 | #: src/transport/gnunet-service-transport.c:2558 | 7185 | #: src/transport/gnunet-service-transport.c:2560 |
7190 | #, c-format | 7186 | #, c-format |
7191 | msgid "Adding blacklisting entry for peer `%s':`%s'\n" | 7187 | msgid "Adding blacklisting entry for peer `%s':`%s'\n" |
7192 | msgstr "" | 7188 | msgstr "" |
7193 | 7189 | ||
7190 | #: src/transport/gnunet-service-transport_ats.c:137 | ||
7191 | msgid "# Addresses given to ATS" | ||
7192 | msgstr "" | ||
7193 | |||
7194 | #: src/transport/gnunet-service-transport_hello.c:195 | 7194 | #: src/transport/gnunet-service-transport_hello.c:195 |
7195 | msgid "# refreshed my HELLO" | 7195 | msgid "# refreshed my HELLO" |
7196 | msgstr "" | 7196 | msgstr "" |
@@ -7530,6 +7530,46 @@ msgstr "" | |||
7530 | msgid "# HELLOs given to peerinfo" | 7530 | msgid "# HELLOs given to peerinfo" |
7531 | msgstr "Nhận được thông báo « %s » sai từ đồng đẳng « %s ».\n" | 7531 | msgstr "Nhận được thông báo « %s » sai từ đồng đẳng « %s ».\n" |
7532 | 7532 | ||
7533 | #: src/transport/gnunet-transport-profiler.c:220 | ||
7534 | #, c-format | ||
7535 | msgid "%llu B in %llu ms == %.2f KB/s!\n" | ||
7536 | msgstr "" | ||
7537 | |||
7538 | #: src/transport/gnunet-transport-profiler.c:577 | ||
7539 | msgid "send data to peer" | ||
7540 | msgstr "" | ||
7541 | |||
7542 | #: src/transport/gnunet-transport-profiler.c:581 | ||
7543 | #, fuzzy | ||
7544 | msgid "receive data from peer" | ||
7545 | msgstr "Yêu cầu cấp %d từ đồng đẳng %d\n" | ||
7546 | |||
7547 | #: src/transport/gnunet-transport-profiler.c:586 | ||
7548 | #, fuzzy | ||
7549 | msgid "iterations" | ||
7550 | msgstr "Tùy chọn chung" | ||
7551 | |||
7552 | #: src/transport/gnunet-transport-profiler.c:591 | ||
7553 | #, fuzzy | ||
7554 | msgid "number of messages to send" | ||
7555 | msgstr "số tin nhắn cần dùng mỗi lần lặp" | ||
7556 | |||
7557 | #: src/transport/gnunet-transport-profiler.c:596 | ||
7558 | #, fuzzy | ||
7559 | msgid "message size to use" | ||
7560 | msgstr "kích cỡ tin nhắn" | ||
7561 | |||
7562 | #: src/transport/gnunet-transport-profiler.c:601 | ||
7563 | #: src/transport/gnunet-transport.c:1404 | ||
7564 | msgid "peer identity" | ||
7565 | msgstr "" | ||
7566 | |||
7567 | #: src/transport/gnunet-transport-profiler.c:614 | ||
7568 | #: src/transport/gnunet-transport.c:1426 | ||
7569 | #, fuzzy | ||
7570 | msgid "Direct access to transport service." | ||
7571 | msgstr "Lỗi kết nối đến gnunetd.\n" | ||
7572 | |||
7533 | #: src/transport/gnunet-transport.c:406 | 7573 | #: src/transport/gnunet-transport.c:406 |
7534 | #, fuzzy, c-format | 7574 | #, fuzzy, c-format |
7535 | msgid "Transmitted %llu bytes/s (%llu bytes in %s)\n" | 7575 | msgid "Transmitted %llu bytes/s (%llu bytes in %s)\n" |
@@ -7669,11 +7709,6 @@ msgstr "In ra thông tin về các đồng đẳng GNUnet." | |||
7669 | msgid "do not resolve hostnames" | 7709 | msgid "do not resolve hostnames" |
7670 | msgstr "không quyết định các tên máy" | 7710 | msgstr "không quyết định các tên máy" |
7671 | 7711 | ||
7672 | #: src/transport/gnunet-transport.c:1404 | ||
7673 | #: src/transport/gnunet-transport-profiler.c:601 | ||
7674 | msgid "peer identity" | ||
7675 | msgstr "" | ||
7676 | |||
7677 | #: src/transport/gnunet-transport.c:1408 | 7712 | #: src/transport/gnunet-transport.c:1408 |
7678 | msgid "monitor plugin sessions" | 7713 | msgid "monitor plugin sessions" |
7679 | msgstr "" | 7714 | msgstr "" |
@@ -7682,41 +7717,6 @@ msgstr "" | |||
7682 | msgid "send data for benchmarking to the other peer (until CTRL-C)" | 7717 | msgid "send data for benchmarking to the other peer (until CTRL-C)" |
7683 | msgstr "" | 7718 | msgstr "" |
7684 | 7719 | ||
7685 | #: src/transport/gnunet-transport.c:1426 | ||
7686 | #: src/transport/gnunet-transport-profiler.c:614 | ||
7687 | #, fuzzy | ||
7688 | msgid "Direct access to transport service." | ||
7689 | msgstr "Lỗi kết nối đến gnunetd.\n" | ||
7690 | |||
7691 | #: src/transport/gnunet-transport-profiler.c:220 | ||
7692 | #, c-format | ||
7693 | msgid "%llu B in %llu ms == %.2f KB/s!\n" | ||
7694 | msgstr "" | ||
7695 | |||
7696 | #: src/transport/gnunet-transport-profiler.c:577 | ||
7697 | msgid "send data to peer" | ||
7698 | msgstr "" | ||
7699 | |||
7700 | #: src/transport/gnunet-transport-profiler.c:581 | ||
7701 | #, fuzzy | ||
7702 | msgid "receive data from peer" | ||
7703 | msgstr "Yêu cầu cấp %d từ đồng đẳng %d\n" | ||
7704 | |||
7705 | #: src/transport/gnunet-transport-profiler.c:586 | ||
7706 | #, fuzzy | ||
7707 | msgid "iterations" | ||
7708 | msgstr "Tùy chọn chung" | ||
7709 | |||
7710 | #: src/transport/gnunet-transport-profiler.c:591 | ||
7711 | #, fuzzy | ||
7712 | msgid "number of messages to send" | ||
7713 | msgstr "số tin nhắn cần dùng mỗi lần lặp" | ||
7714 | |||
7715 | #: src/transport/gnunet-transport-profiler.c:596 | ||
7716 | #, fuzzy | ||
7717 | msgid "message size to use" | ||
7718 | msgstr "kích cỡ tin nhắn" | ||
7719 | |||
7720 | #: src/transport/plugin_transport_http_client.c:1489 | 7720 | #: src/transport/plugin_transport_http_client.c:1489 |
7721 | #: src/transport/plugin_transport_http_server.c:2331 | 7721 | #: src/transport/plugin_transport_http_server.c:2331 |
7722 | #: src/transport/plugin_transport_http_server.c:3562 | 7722 | #: src/transport/plugin_transport_http_server.c:3562 |
@@ -7995,21 +7995,6 @@ msgstr "" | |||
7995 | msgid "TCP transport advertises itself as being on port %llu\n" | 7995 | msgid "TCP transport advertises itself as being on port %llu\n" |
7996 | msgstr "" | 7996 | msgstr "" |
7997 | 7997 | ||
7998 | #: src/transport/plugin_transport_udp_broadcasting.c:169 | ||
7999 | #, fuzzy | ||
8000 | msgid "# Multicast HELLO beacons received via UDP" | ||
8001 | msgstr "# các thông báo PONG đã mật mã được nhận" | ||
8002 | |||
8003 | #: src/transport/plugin_transport_udp_broadcasting.c:553 | ||
8004 | msgid "" | ||
8005 | "Disabling HELLO broadcasting due to friend-to-friend only configuration!\n" | ||
8006 | msgstr "" | ||
8007 | |||
8008 | #: src/transport/plugin_transport_udp_broadcasting.c:571 | ||
8009 | #, c-format | ||
8010 | msgid "Failed to set IPv4 broadcast option for broadcast socket on port %d\n" | ||
8011 | msgstr "" | ||
8012 | |||
8013 | #: src/transport/plugin_transport_udp.c:3169 | 7998 | #: src/transport/plugin_transport_udp.c:3169 |
8014 | #, c-format | 7999 | #, c-format |
8015 | msgid "" | 8000 | msgid "" |
@@ -8058,6 +8043,21 @@ msgstr "« %s » không sẵn sàng.\n" | |||
8058 | msgid "Failed to create UDP network sockets\n" | 8043 | msgid "Failed to create UDP network sockets\n" |
8059 | msgstr "Không thể tạo miền tên.\n" | 8044 | msgstr "Không thể tạo miền tên.\n" |
8060 | 8045 | ||
8046 | #: src/transport/plugin_transport_udp_broadcasting.c:169 | ||
8047 | #, fuzzy | ||
8048 | msgid "# Multicast HELLO beacons received via UDP" | ||
8049 | msgstr "# các thông báo PONG đã mật mã được nhận" | ||
8050 | |||
8051 | #: src/transport/plugin_transport_udp_broadcasting.c:553 | ||
8052 | msgid "" | ||
8053 | "Disabling HELLO broadcasting due to friend-to-friend only configuration!\n" | ||
8054 | msgstr "" | ||
8055 | |||
8056 | #: src/transport/plugin_transport_udp_broadcasting.c:571 | ||
8057 | #, c-format | ||
8058 | msgid "Failed to set IPv4 broadcast option for broadcast socket on port %d\n" | ||
8059 | msgstr "" | ||
8060 | |||
8061 | #: src/transport/plugin_transport_unix.c:1396 | 8061 | #: src/transport/plugin_transport_unix.c:1396 |
8062 | #, fuzzy, c-format | 8062 | #, fuzzy, c-format |
8063 | msgid "Cannot bind to `%s'\n" | 8063 | msgid "Cannot bind to `%s'\n" |
@@ -8240,7 +8240,7 @@ msgid "do daemonize (detach from terminal)" | |||
8240 | msgstr "" | 8240 | msgstr "" |
8241 | 8241 | ||
8242 | #: src/transport/tcp_service_legacy.c:1397 | 8242 | #: src/transport/tcp_service_legacy.c:1397 |
8243 | #: src/transport/transport-testing2.c:1116 src/util/service.c:2072 | 8243 | #: src/transport/transport-testing2.c:983 src/util/service.c:2072 |
8244 | #: src/util/service.c:2084 | 8244 | #: src/util/service.c:2084 |
8245 | #, fuzzy, c-format | 8245 | #, fuzzy, c-format |
8246 | msgid "Malformed configuration file `%s', exit ...\n" | 8246 | msgid "Malformed configuration file `%s', exit ...\n" |
@@ -8912,19 +8912,19 @@ msgid "" | |||
8912 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" | 8912 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" |
8913 | msgstr "" | 8913 | msgstr "" |
8914 | 8914 | ||
8915 | #: src/util/os_installation.c:409 | 8915 | #: src/util/os_installation.c:411 |
8916 | #, c-format | 8916 | #, c-format |
8917 | msgid "" | 8917 | msgid "" |
8918 | "Could not determine installation path for %s. Set `%s' environment " | 8918 | "Could not determine installation path for %s. Set `%s' environment " |
8919 | "variable.\n" | 8919 | "variable.\n" |
8920 | msgstr "" | 8920 | msgstr "" |
8921 | 8921 | ||
8922 | #: src/util/os_installation.c:792 | 8922 | #: src/util/os_installation.c:794 |
8923 | #, fuzzy, c-format | 8923 | #, fuzzy, c-format |
8924 | msgid "Could not find binary `%s' in PATH!\n" | 8924 | msgid "Could not find binary `%s' in PATH!\n" |
8925 | msgstr "Không thể đọc danh sách bạn bè « %s »\n" | 8925 | msgstr "Không thể đọc danh sách bạn bè « %s »\n" |
8926 | 8926 | ||
8927 | #: src/util/os_installation.c:825 | 8927 | #: src/util/os_installation.c:827 |
8928 | #, c-format | 8928 | #, c-format |
8929 | msgid "Binary `%s' exists, but is not SUID\n" | 8929 | msgid "Binary `%s' exists, but is not SUID\n" |
8930 | msgstr "" | 8930 | msgstr "" |
@@ -8949,17 +8949,17 @@ msgstr "« %s » thất bại cho thư viện « %s » với lỗi: %s\n" | |||
8949 | msgid "Could not determine plugin installation path.\n" | 8949 | msgid "Could not determine plugin installation path.\n" |
8950 | msgstr "Không thể truy cập đến thông tin về không gian tên.\n" | 8950 | msgstr "Không thể truy cập đến thông tin về không gian tên.\n" |
8951 | 8951 | ||
8952 | #: src/util/program.c:262 | 8952 | #: src/util/program.c:267 |
8953 | #, fuzzy, c-format | 8953 | #, fuzzy, c-format |
8954 | msgid "Unreadable or malformed configuration file `%s', exit ...\n" | 8954 | msgid "Unreadable or malformed configuration file `%s', exit ...\n" |
8955 | msgstr "Không thể lưu tập tin cấu hình « %s »:" | 8955 | msgstr "Không thể lưu tập tin cấu hình « %s »:" |
8956 | 8956 | ||
8957 | #: src/util/program.c:279 | 8957 | #: src/util/program.c:284 |
8958 | #, fuzzy, c-format | 8958 | #, fuzzy, c-format |
8959 | msgid "Unreadable or malformed default configuration file `%s', exit ...\n" | 8959 | msgid "Unreadable or malformed default configuration file `%s', exit ...\n" |
8960 | msgstr "Không thể lưu tập tin cấu hình « %s »:" | 8960 | msgstr "Không thể lưu tập tin cấu hình « %s »:" |
8961 | 8961 | ||
8962 | #: src/util/program.c:294 | 8962 | #: src/util/program.c:299 |
8963 | #, fuzzy | 8963 | #, fuzzy |
8964 | msgid "Unreadable or malformed configuration, exit ...\n" | 8964 | msgid "Unreadable or malformed configuration, exit ...\n" |
8965 | msgstr "Không thể lưu tập tin cấu hình « %s »:" | 8965 | msgstr "Không thể lưu tập tin cấu hình « %s »:" |
@@ -9024,10 +9024,6 @@ msgstr "" | |||
9024 | msgid "Attempting to proxy service `%s' to invalid port %d or hostname.\n" | 9024 | msgid "Attempting to proxy service `%s' to invalid port %d or hostname.\n" |
9025 | msgstr "" | 9025 | msgstr "" |
9026 | 9026 | ||
9027 | #: src/util/strings.c:179 | ||
9028 | msgid "b" | ||
9029 | msgstr "b" | ||
9030 | |||
9031 | #: src/util/strings.c:503 | 9027 | #: src/util/strings.c:503 |
9032 | #, c-format | 9028 | #, c-format |
9033 | msgid "Character sets requested were `%s'->`%s'\n" | 9029 | msgid "Character sets requested were `%s'->`%s'\n" |
@@ -9038,48 +9034,6 @@ msgid "Failed to expand `$HOME': environment variable `HOME' not set" | |||
9038 | msgstr "" | 9034 | msgstr "" |
9039 | "Lỗi mở rộng biến môi trường « $HOME »: chưa đặt biến môi trường « HOME »" | 9035 | "Lỗi mở rộng biến môi trường « $HOME »: chưa đặt biến môi trường « HOME »" |
9040 | 9036 | ||
9041 | #: src/util/strings.c:706 | ||
9042 | msgid "µs" | ||
9043 | msgstr "" | ||
9044 | |||
9045 | #: src/util/strings.c:710 | ||
9046 | msgid "forever" | ||
9047 | msgstr "" | ||
9048 | |||
9049 | #: src/util/strings.c:712 | ||
9050 | msgid "0 ms" | ||
9051 | msgstr "" | ||
9052 | |||
9053 | #: src/util/strings.c:716 | ||
9054 | msgid "ms" | ||
9055 | msgstr "mg" | ||
9056 | |||
9057 | #: src/util/strings.c:720 | ||
9058 | msgid "s" | ||
9059 | msgstr "g" | ||
9060 | |||
9061 | #: src/util/strings.c:724 | ||
9062 | msgid "m" | ||
9063 | msgstr "p" | ||
9064 | |||
9065 | #: src/util/strings.c:728 | ||
9066 | msgid "h" | ||
9067 | msgstr "g" | ||
9068 | |||
9069 | #: src/util/strings.c:734 | ||
9070 | #, fuzzy | ||
9071 | msgid "day" | ||
9072 | msgstr " ngày" | ||
9073 | |||
9074 | #: src/util/strings.c:736 | ||
9075 | #, fuzzy | ||
9076 | msgid "days" | ||
9077 | msgstr " ngày" | ||
9078 | |||
9079 | #: src/util/strings.c:764 | ||
9080 | msgid "end of time" | ||
9081 | msgstr "" | ||
9082 | |||
9083 | #: src/util/strings.c:1240 | 9037 | #: src/util/strings.c:1240 |
9084 | msgid "IPv6 address did not start with `['\n" | 9038 | msgid "IPv6 address did not start with `['\n" |
9085 | msgstr "" | 9039 | msgstr "" |
@@ -9330,12 +9284,35 @@ msgstr "# các byte đã nhận qua UDP" | |||
9330 | msgid "Setup tunnels via VPN." | 9284 | msgid "Setup tunnels via VPN." |
9331 | msgstr "" | 9285 | msgstr "" |
9332 | 9286 | ||
9333 | #: src/zonemaster/gnunet-service-zonemaster.c:849 | ||
9334 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:420 | 9287 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:420 |
9288 | #: src/zonemaster/gnunet-service-zonemaster.c:849 | ||
9335 | #, fuzzy | 9289 | #, fuzzy |
9336 | msgid "Failed to connect to the namestore!\n" | 9290 | msgid "Failed to connect to the namestore!\n" |
9337 | msgstr "Không kết nối được đến trình nền gnunetd." | 9291 | msgstr "Không kết nối được đến trình nền gnunetd." |
9338 | 9292 | ||
9293 | #~ msgid "b" | ||
9294 | #~ msgstr "b" | ||
9295 | |||
9296 | #~ msgid "ms" | ||
9297 | #~ msgstr "mg" | ||
9298 | |||
9299 | #~ msgid "s" | ||
9300 | #~ msgstr "g" | ||
9301 | |||
9302 | #~ msgid "m" | ||
9303 | #~ msgstr "p" | ||
9304 | |||
9305 | #~ msgid "h" | ||
9306 | #~ msgstr "g" | ||
9307 | |||
9308 | #, fuzzy | ||
9309 | #~ msgid "day" | ||
9310 | #~ msgstr " ngày" | ||
9311 | |||
9312 | #, fuzzy | ||
9313 | #~ msgid "days" | ||
9314 | #~ msgstr " ngày" | ||
9315 | |||
9339 | #, fuzzy, c-format | 9316 | #, fuzzy, c-format |
9340 | #~ msgid "Could not acquire lock on file `%s': %s...\n" | 9317 | #~ msgid "Could not acquire lock on file `%s': %s...\n" |
9341 | #~ msgstr "Lỗi mở tập tin theo dõi « %s »: %s\n" | 9318 | #~ msgstr "Lỗi mở tập tin theo dõi « %s »: %s\n" |
diff --git a/po/zh_CN.po b/po/zh_CN.po index dec62e27f..a5376561d 100644 --- a/po/zh_CN.po +++ b/po/zh_CN.po | |||
@@ -7,7 +7,7 @@ msgid "" | |||
7 | msgstr "" | 7 | msgstr "" |
8 | "Project-Id-Version: gnunet-0.8.1\n" | 8 | "Project-Id-Version: gnunet-0.8.1\n" |
9 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" | 9 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" |
10 | "POT-Creation-Date: 2020-09-06 10:07+0200\n" | 10 | "POT-Creation-Date: 2020-10-13 16:12+0200\n" |
11 | "PO-Revision-Date: 2011-07-09 12:12+0800\n" | 11 | "PO-Revision-Date: 2011-07-09 12:12+0800\n" |
12 | "Last-Translator: Wylmer Wang <wantinghard@gmail.com>\n" | 12 | "Last-Translator: Wylmer Wang <wantinghard@gmail.com>\n" |
13 | "Language-Team: Chinese (simplified) <i18n-zh@googlegroups.com>\n" | 13 | "Language-Team: Chinese (simplified) <i18n-zh@googlegroups.com>\n" |
@@ -27,8 +27,8 @@ msgid "Issuer public key `%s' is not well-formed\n" | |||
27 | msgstr "“%s”的参数无效。\n" | 27 | msgstr "“%s”的参数无效。\n" |
28 | 28 | ||
29 | #: src/abd/gnunet-abd.c:560 src/abd/gnunet-service-abd.c:1747 | 29 | #: src/abd/gnunet-abd.c:560 src/abd/gnunet-service-abd.c:1747 |
30 | #: src/namestore/gnunet-namestore.c:1001 | ||
31 | #: src/namestore/gnunet-namestore-fcfsd.c:1154 | 30 | #: src/namestore/gnunet-namestore-fcfsd.c:1154 |
31 | #: src/namestore/gnunet-namestore.c:1001 | ||
32 | #, fuzzy, c-format | 32 | #, fuzzy, c-format |
33 | msgid "Failed to connect to namestore\n" | 33 | msgid "Failed to connect to namestore\n" |
34 | msgstr "初始化“%s”服务失败。\n" | 34 | msgstr "初始化“%s”服务失败。\n" |
@@ -494,82 +494,14 @@ msgstr "" | |||
494 | msgid "Initiating shutdown as requested by client.\n" | 494 | msgid "Initiating shutdown as requested by client.\n" |
495 | msgstr "" | 495 | msgstr "" |
496 | 496 | ||
497 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | 497 | #: src/ats-tests/ats-testing-log.c:896 |
498 | #, c-format | 498 | msgid "Stop logging\n" |
499 | msgid "" | ||
500 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | ||
501 | "%llu\n" | ||
502 | msgstr "" | ||
503 | |||
504 | #: src/ats/gnunet-ats-solver-eval.c:3011 | ||
505 | #, c-format | ||
506 | msgid "" | ||
507 | "No outbound quota configured for network `%s', assigning default bandwidth " | ||
508 | "%llu\n" | ||
509 | msgstr "" | ||
510 | |||
511 | #: src/ats/gnunet-ats-solver-eval.c:3063 | ||
512 | #, c-format | ||
513 | msgid "" | ||
514 | "No outbound quota configure for network `%s', assigning default bandwidth " | ||
515 | "%llu\n" | ||
516 | msgstr "" | ||
517 | |||
518 | #: src/ats/gnunet-ats-solver-eval.c:3552 src/ats-tests/gnunet-solver-eval.c:997 | ||
519 | msgid "solver to use" | ||
520 | msgstr "" | ||
521 | |||
522 | #: src/ats/gnunet-ats-solver-eval.c:3557 | ||
523 | #: src/ats-tests/gnunet-solver-eval.c:1003 | ||
524 | #: src/ats-tests/gnunet-solver-eval.c:1008 | ||
525 | msgid "experiment to use" | ||
526 | msgstr "" | ||
527 | |||
528 | #: src/ats/gnunet-ats-solver-eval.c:3564 | ||
529 | #, fuzzy | ||
530 | msgid "print logging" | ||
531 | msgstr "未知的命令“%s”。\n" | ||
532 | |||
533 | #: src/ats/gnunet-ats-solver-eval.c:3569 | ||
534 | msgid "save logging to disk" | ||
535 | msgstr "" | ||
536 | |||
537 | #: src/ats/gnunet-ats-solver-eval.c:3574 | ||
538 | msgid "disable normalization" | ||
539 | msgstr "" | ||
540 | |||
541 | #: src/ats/gnunet-service-ats_plugins.c:326 | ||
542 | #, c-format | ||
543 | msgid "" | ||
544 | "Could not load %s quota for network `%s': `%s', assigning default bandwidth " | ||
545 | "%llu\n" | ||
546 | msgstr "" | ||
547 | |||
548 | #: src/ats/gnunet-service-ats_plugins.c:336 | ||
549 | #, c-format | ||
550 | msgid "%s quota configured for network `%s' is %llu\n" | ||
551 | msgstr "" | ||
552 | |||
553 | #: src/ats/gnunet-service-ats_plugins.c:382 | ||
554 | #, c-format | ||
555 | msgid "" | ||
556 | "No %s-quota configured for network `%s', assigning default bandwidth %llu\n" | ||
557 | msgstr "" | 499 | msgstr "" |
558 | 500 | ||
559 | #: src/ats/gnunet-service-ats_plugins.c:474 | 501 | #: src/ats-tests/ats-testing-log.c:952 |
560 | #, fuzzy, c-format | ||
561 | msgid "Failed to initialize solver `%s'!\n" | ||
562 | msgstr "无法初始化 SQLite:%s。\n" | ||
563 | |||
564 | #: src/ats/plugin_ats_proportional.c:1142 | ||
565 | #, fuzzy, c-format | ||
566 | msgid "Invalid %s configuration %f \n" | ||
567 | msgstr "解析配置文件“%s”失败\n" | ||
568 | |||
569 | #: src/ats/plugin_ats_proportional.c:1165 | ||
570 | #, fuzzy, c-format | 502 | #, fuzzy, c-format |
571 | msgid "Invalid %s configuration %f\n" | 503 | msgid "Start logging `%s'\n" |
572 | msgstr "解配文“%s”失败\n" | 504 | msgstr "的“%s”。\n" |
573 | 505 | ||
574 | #: src/ats-tests/ats-testing.c:420 | 506 | #: src/ats-tests/ats-testing.c:420 |
575 | #, c-format | 507 | #, c-format |
@@ -581,15 +513,6 @@ msgstr "" | |||
581 | msgid "Failed to connect master peer [%u] with slave [%u]\n" | 513 | msgid "Failed to connect master peer [%u] with slave [%u]\n" |
582 | msgstr "初始化“%s”服务失败。\n" | 514 | msgstr "初始化“%s”服务失败。\n" |
583 | 515 | ||
584 | #: src/ats-tests/ats-testing-log.c:896 | ||
585 | msgid "Stop logging\n" | ||
586 | msgstr "" | ||
587 | |||
588 | #: src/ats-tests/ats-testing-log.c:952 | ||
589 | #, fuzzy, c-format | ||
590 | msgid "Start logging `%s'\n" | ||
591 | msgstr "未知的命令“%s”。\n" | ||
592 | |||
593 | #: src/ats-tests/gnunet-ats-sim.c:92 | 516 | #: src/ats-tests/gnunet-ats-sim.c:92 |
594 | #, c-format | 517 | #, c-format |
595 | msgid "" | 518 | msgid "" |
@@ -597,6 +520,16 @@ msgid "" | |||
597 | "= %u KiB/s\n" | 520 | "= %u KiB/s\n" |
598 | msgstr "" | 521 | msgstr "" |
599 | 522 | ||
523 | #: src/ats-tests/gnunet-solver-eval.c:997 src/ats/gnunet-ats-solver-eval.c:3552 | ||
524 | msgid "solver to use" | ||
525 | msgstr "" | ||
526 | |||
527 | #: src/ats-tests/gnunet-solver-eval.c:1003 | ||
528 | #: src/ats-tests/gnunet-solver-eval.c:1008 | ||
529 | #: src/ats/gnunet-ats-solver-eval.c:3557 | ||
530 | msgid "experiment to use" | ||
531 | msgstr "" | ||
532 | |||
600 | #: src/ats-tool/gnunet-ats.c:299 | 533 | #: src/ats-tool/gnunet-ats.c:299 |
601 | #, c-format | 534 | #, c-format |
602 | msgid "%u address resolutions had a timeout\n" | 535 | msgid "%u address resolutions had a timeout\n" |
@@ -718,6 +651,73 @@ msgstr "" | |||
718 | msgid "Print information about ATS state" | 651 | msgid "Print information about ATS state" |
719 | msgstr "无法获取有关用户“%s”的信息:%s\n" | 652 | msgstr "无法获取有关用户“%s”的信息:%s\n" |
720 | 653 | ||
654 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | ||
655 | #, c-format | ||
656 | msgid "" | ||
657 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | ||
658 | "%llu\n" | ||
659 | msgstr "" | ||
660 | |||
661 | #: src/ats/gnunet-ats-solver-eval.c:3011 | ||
662 | #, c-format | ||
663 | msgid "" | ||
664 | "No outbound quota configured for network `%s', assigning default bandwidth " | ||
665 | "%llu\n" | ||
666 | msgstr "" | ||
667 | |||
668 | #: src/ats/gnunet-ats-solver-eval.c:3063 | ||
669 | #, c-format | ||
670 | msgid "" | ||
671 | "No outbound quota configure for network `%s', assigning default bandwidth " | ||
672 | "%llu\n" | ||
673 | msgstr "" | ||
674 | |||
675 | #: src/ats/gnunet-ats-solver-eval.c:3564 | ||
676 | #, fuzzy | ||
677 | msgid "print logging" | ||
678 | msgstr "未知的命令“%s”。\n" | ||
679 | |||
680 | #: src/ats/gnunet-ats-solver-eval.c:3569 | ||
681 | msgid "save logging to disk" | ||
682 | msgstr "" | ||
683 | |||
684 | #: src/ats/gnunet-ats-solver-eval.c:3574 | ||
685 | msgid "disable normalization" | ||
686 | msgstr "" | ||
687 | |||
688 | #: src/ats/gnunet-service-ats_plugins.c:326 | ||
689 | #, c-format | ||
690 | msgid "" | ||
691 | "Could not load %s quota for network `%s': `%s', assigning default bandwidth " | ||
692 | "%llu\n" | ||
693 | msgstr "" | ||
694 | |||
695 | #: src/ats/gnunet-service-ats_plugins.c:336 | ||
696 | #, c-format | ||
697 | msgid "%s quota configured for network `%s' is %llu\n" | ||
698 | msgstr "" | ||
699 | |||
700 | #: src/ats/gnunet-service-ats_plugins.c:382 | ||
701 | #, c-format | ||
702 | msgid "" | ||
703 | "No %s-quota configured for network `%s', assigning default bandwidth %llu\n" | ||
704 | msgstr "" | ||
705 | |||
706 | #: src/ats/gnunet-service-ats_plugins.c:474 | ||
707 | #, fuzzy, c-format | ||
708 | msgid "Failed to initialize solver `%s'!\n" | ||
709 | msgstr "无法初始化 SQLite:%s。\n" | ||
710 | |||
711 | #: src/ats/plugin_ats_proportional.c:1142 | ||
712 | #, fuzzy, c-format | ||
713 | msgid "Invalid %s configuration %f \n" | ||
714 | msgstr "解析配置文件“%s”失败\n" | ||
715 | |||
716 | #: src/ats/plugin_ats_proportional.c:1165 | ||
717 | #, fuzzy, c-format | ||
718 | msgid "Invalid %s configuration %f\n" | ||
719 | msgstr "解析配置文件“%s”失败\n" | ||
720 | |||
721 | #: src/auction/gnunet-auction-create.c:163 | 721 | #: src/auction/gnunet-auction-create.c:163 |
722 | msgid "description of the item to be sold" | 722 | msgid "description of the item to be sold" |
723 | msgstr "" | 723 | msgstr "" |
@@ -854,6 +854,28 @@ msgstr "" | |||
854 | msgid "Connection to conversation service lost, trying to reconnect\n" | 854 | msgid "Connection to conversation service lost, trying to reconnect\n" |
855 | msgstr "" | 855 | msgstr "" |
856 | 856 | ||
857 | #: src/conversation/gnunet-conversation-test.c:120 | ||
858 | #, c-format | ||
859 | msgid "" | ||
860 | "\n" | ||
861 | "End of transmission. Have a GNU day.\n" | ||
862 | msgstr "" | ||
863 | |||
864 | #: src/conversation/gnunet-conversation-test.c:146 | ||
865 | #, c-format | ||
866 | msgid "" | ||
867 | "\n" | ||
868 | "We are now playing your recording back. If you can hear it, your audio " | ||
869 | "settings are working..." | ||
870 | msgstr "" | ||
871 | |||
872 | #: src/conversation/gnunet-conversation-test.c:218 | ||
873 | #, c-format | ||
874 | msgid "" | ||
875 | "We will now be recording you for %s. After that time, the recording will be " | ||
876 | "played back to you..." | ||
877 | msgstr "" | ||
878 | |||
857 | #: src/conversation/gnunet-conversation.c:264 | 879 | #: src/conversation/gnunet-conversation.c:264 |
858 | #, c-format | 880 | #, c-format |
859 | msgid "Incoming call from `%s'. Please /accept %u or /cancel %u the call.\n" | 881 | msgid "Incoming call from `%s'. Please /accept %u or /cancel %u the call.\n" |
@@ -1112,30 +1134,8 @@ msgstr "" | |||
1112 | msgid "Enables having a conversation with other GNUnet users." | 1134 | msgid "Enables having a conversation with other GNUnet users." |
1113 | msgstr "" | 1135 | msgstr "" |
1114 | 1136 | ||
1115 | #: src/conversation/gnunet-conversation-test.c:120 | ||
1116 | #, c-format | ||
1117 | msgid "" | ||
1118 | "\n" | ||
1119 | "End of transmission. Have a GNU day.\n" | ||
1120 | msgstr "" | ||
1121 | |||
1122 | #: src/conversation/gnunet-conversation-test.c:146 | ||
1123 | #, c-format | ||
1124 | msgid "" | ||
1125 | "\n" | ||
1126 | "We are now playing your recording back. If you can hear it, your audio " | ||
1127 | "settings are working..." | ||
1128 | msgstr "" | ||
1129 | |||
1130 | #: src/conversation/gnunet-conversation-test.c:218 | ||
1131 | #, c-format | ||
1132 | msgid "" | ||
1133 | "We will now be recording you for %s. After that time, the recording will be " | ||
1134 | "played back to you..." | ||
1135 | msgstr "" | ||
1136 | |||
1137 | #: src/conversation/gnunet_gst.c:664 | ||
1138 | #: src/conversation/gnunet-helper-audio-playback-gst.c:363 | 1137 | #: src/conversation/gnunet-helper-audio-playback-gst.c:363 |
1138 | #: src/conversation/gnunet_gst.c:664 | ||
1139 | #, c-format | 1139 | #, c-format |
1140 | msgid "Read error from STDIN: %d %s\n" | 1140 | msgid "Read error from STDIN: %d %s\n" |
1141 | msgstr "" | 1141 | msgstr "" |
@@ -1917,17 +1917,17 @@ msgstr "“%s”于 %s:%d 处失败,错误为:%s\n" | |||
1917 | msgid "Mysql database running\n" | 1917 | msgid "Mysql database running\n" |
1918 | msgstr "" | 1918 | msgstr "" |
1919 | 1919 | ||
1920 | #: src/datastore/plugin_datastore_postgres.c:278 | 1920 | #: src/datastore/plugin_datastore_postgres.c:284 |
1921 | #: src/datastore/plugin_datastore_postgres.c:891 | 1921 | #: src/datastore/plugin_datastore_postgres.c:897 |
1922 | msgid "Postgress exec failure" | 1922 | msgid "Postgress exec failure" |
1923 | msgstr "" | 1923 | msgstr "" |
1924 | 1924 | ||
1925 | #: src/datastore/plugin_datastore_postgres.c:852 | 1925 | #: src/datastore/plugin_datastore_postgres.c:858 |
1926 | #, fuzzy | 1926 | #, fuzzy |
1927 | msgid "Failed to drop table from database.\n" | 1927 | msgid "Failed to drop table from database.\n" |
1928 | msgstr "发送消息失败。\n" | 1928 | msgstr "发送消息失败。\n" |
1929 | 1929 | ||
1930 | #: src/datastore/plugin_datastore_postgres.c:950 | 1930 | #: src/datastore/plugin_datastore_postgres.c:956 |
1931 | msgid "Postgres database running\n" | 1931 | msgid "Postgres database running\n" |
1932 | msgstr "" | 1932 | msgstr "" |
1933 | 1933 | ||
@@ -2036,54 +2036,6 @@ msgstr "" | |||
2036 | msgid "Prints all packets that go through the DHT." | 2036 | msgid "Prints all packets that go through the DHT." |
2037 | msgstr "" | 2037 | msgstr "" |
2038 | 2038 | ||
2039 | #: src/dht/gnunet_dht_profiler.c:922 src/testbed/gnunet-testbed-profiler.c:255 | ||
2040 | #, fuzzy, c-format | ||
2041 | msgid "Exiting as the number of peers is %u\n" | ||
2042 | msgstr "增加 TCP/IP 的最大连接数" | ||
2043 | |||
2044 | #: src/dht/gnunet_dht_profiler.c:955 src/rps/gnunet-rps-profiler.c:3194 | ||
2045 | #, fuzzy | ||
2046 | msgid "number of peers to start" | ||
2047 | msgstr "迭代次数" | ||
2048 | |||
2049 | #: src/dht/gnunet_dht_profiler.c:961 | ||
2050 | msgid "number of PUTs to perform per peer" | ||
2051 | msgstr "" | ||
2052 | |||
2053 | #: src/dht/gnunet_dht_profiler.c:967 src/nse/gnunet-nse-profiler.c:872 | ||
2054 | #: src/testbed/gnunet-testbed-profiler.c:305 | ||
2055 | msgid "name of the file with the login information for the testbed" | ||
2056 | msgstr "" | ||
2057 | |||
2058 | #: src/dht/gnunet_dht_profiler.c:973 | ||
2059 | msgid "delay between rounds for collecting statistics (default: 30 sec)" | ||
2060 | msgstr "" | ||
2061 | |||
2062 | #: src/dht/gnunet_dht_profiler.c:979 | ||
2063 | msgid "delay to start doing PUTs (default: 1 sec)" | ||
2064 | msgstr "" | ||
2065 | |||
2066 | #: src/dht/gnunet_dht_profiler.c:985 | ||
2067 | msgid "delay to start doing GETs (default: 5 min)" | ||
2068 | msgstr "" | ||
2069 | |||
2070 | #: src/dht/gnunet_dht_profiler.c:990 | ||
2071 | msgid "replication degree for DHT PUTs" | ||
2072 | msgstr "" | ||
2073 | |||
2074 | #: src/dht/gnunet_dht_profiler.c:996 | ||
2075 | msgid "chance that a peer is selected at random for PUTs" | ||
2076 | msgstr "" | ||
2077 | |||
2078 | #: src/dht/gnunet_dht_profiler.c:1002 | ||
2079 | msgid "timeout for DHT PUT and GET requests (default: 1 min)" | ||
2080 | msgstr "" | ||
2081 | |||
2082 | #: src/dht/gnunet_dht_profiler.c:1023 | ||
2083 | #, fuzzy | ||
2084 | msgid "Measure quality and performance of the DHT service." | ||
2085 | msgstr "无法访问该服务" | ||
2086 | |||
2087 | #: src/dht/gnunet-dht-put.c:133 | 2039 | #: src/dht/gnunet-dht-put.c:133 |
2088 | msgid "Must provide KEY and DATA for DHT put!\n" | 2040 | msgid "Must provide KEY and DATA for DHT put!\n" |
2089 | msgstr "" | 2041 | msgstr "" |
@@ -2329,6 +2281,54 @@ msgstr "" | |||
2329 | msgid "# DHT requests combined" | 2281 | msgid "# DHT requests combined" |
2330 | msgstr "" | 2282 | msgstr "" |
2331 | 2283 | ||
2284 | #: src/dht/gnunet_dht_profiler.c:922 src/testbed/gnunet-testbed-profiler.c:255 | ||
2285 | #, fuzzy, c-format | ||
2286 | msgid "Exiting as the number of peers is %u\n" | ||
2287 | msgstr "增加 TCP/IP 的最大连接数" | ||
2288 | |||
2289 | #: src/dht/gnunet_dht_profiler.c:955 src/rps/gnunet-rps-profiler.c:3194 | ||
2290 | #, fuzzy | ||
2291 | msgid "number of peers to start" | ||
2292 | msgstr "迭代次数" | ||
2293 | |||
2294 | #: src/dht/gnunet_dht_profiler.c:961 | ||
2295 | msgid "number of PUTs to perform per peer" | ||
2296 | msgstr "" | ||
2297 | |||
2298 | #: src/dht/gnunet_dht_profiler.c:967 src/nse/gnunet-nse-profiler.c:872 | ||
2299 | #: src/testbed/gnunet-testbed-profiler.c:305 | ||
2300 | msgid "name of the file with the login information for the testbed" | ||
2301 | msgstr "" | ||
2302 | |||
2303 | #: src/dht/gnunet_dht_profiler.c:973 | ||
2304 | msgid "delay between rounds for collecting statistics (default: 30 sec)" | ||
2305 | msgstr "" | ||
2306 | |||
2307 | #: src/dht/gnunet_dht_profiler.c:979 | ||
2308 | msgid "delay to start doing PUTs (default: 1 sec)" | ||
2309 | msgstr "" | ||
2310 | |||
2311 | #: src/dht/gnunet_dht_profiler.c:985 | ||
2312 | msgid "delay to start doing GETs (default: 5 min)" | ||
2313 | msgstr "" | ||
2314 | |||
2315 | #: src/dht/gnunet_dht_profiler.c:990 | ||
2316 | msgid "replication degree for DHT PUTs" | ||
2317 | msgstr "" | ||
2318 | |||
2319 | #: src/dht/gnunet_dht_profiler.c:996 | ||
2320 | msgid "chance that a peer is selected at random for PUTs" | ||
2321 | msgstr "" | ||
2322 | |||
2323 | #: src/dht/gnunet_dht_profiler.c:1002 | ||
2324 | msgid "timeout for DHT PUT and GET requests (default: 1 min)" | ||
2325 | msgstr "" | ||
2326 | |||
2327 | #: src/dht/gnunet_dht_profiler.c:1023 | ||
2328 | #, fuzzy | ||
2329 | msgid "Measure quality and performance of the DHT service." | ||
2330 | msgstr "无法访问该服务" | ||
2331 | |||
2332 | #: src/dht/plugin_block_dht.c:189 | 2332 | #: src/dht/plugin_block_dht.c:189 |
2333 | #, c-format | 2333 | #, c-format |
2334 | msgid "Block not of type %u\n" | 2334 | msgid "Block not of type %u\n" |
@@ -3248,14 +3248,6 @@ msgid "" | |||
3248 | "chk/...)" | 3248 | "chk/...)" |
3249 | msgstr "" | 3249 | msgstr "" |
3250 | 3250 | ||
3251 | #: src/fs/gnunet-fs.c:128 | ||
3252 | msgid "print a list of all indexed files" | ||
3253 | msgstr "" | ||
3254 | |||
3255 | #: src/fs/gnunet-fs.c:141 | ||
3256 | msgid "Special file-sharing operations" | ||
3257 | msgstr "" | ||
3258 | |||
3259 | #: src/fs/gnunet-fs-profiler.c:211 | 3251 | #: src/fs/gnunet-fs-profiler.c:211 |
3260 | msgid "run the experiment with COUNT peers" | 3252 | msgid "run the experiment with COUNT peers" |
3261 | msgstr "" | 3253 | msgstr "" |
@@ -3272,6 +3264,14 @@ msgstr "" | |||
3272 | msgid "run a testbed to measure file-sharing performance" | 3264 | msgid "run a testbed to measure file-sharing performance" |
3273 | msgstr "" | 3265 | msgstr "" |
3274 | 3266 | ||
3267 | #: src/fs/gnunet-fs.c:128 | ||
3268 | msgid "print a list of all indexed files" | ||
3269 | msgstr "" | ||
3270 | |||
3271 | #: src/fs/gnunet-fs.c:141 | ||
3272 | msgid "Special file-sharing operations" | ||
3273 | msgstr "" | ||
3274 | |||
3275 | #: src/fs/gnunet-publish.c:219 src/fs/gnunet-publish.c:234 | 3275 | #: src/fs/gnunet-publish.c:219 src/fs/gnunet-publish.c:234 |
3276 | #, c-format | 3276 | #, c-format |
3277 | msgid "Publishing `%s' at %llu/%llu (%s remaining)\n" | 3277 | msgid "Publishing `%s' at %llu/%llu (%s remaining)\n" |
@@ -3926,50 +3926,6 @@ msgstr "" | |||
3926 | msgid "look for GNS2DNS records instead of ANY" | 3926 | msgid "look for GNS2DNS records instead of ANY" |
3927 | msgstr "" | 3927 | msgstr "" |
3928 | 3928 | ||
3929 | #: src/gns/gnunet-gns.c:257 | ||
3930 | #, fuzzy, c-format | ||
3931 | msgid "`%s' is not a valid DNS domain name\n" | ||
3932 | msgstr "“%s”不可用。\n" | ||
3933 | |||
3934 | #: src/gns/gnunet-gns.c:267 src/util/dnsparser.c:254 | ||
3935 | #, fuzzy, c-format | ||
3936 | msgid "Failed to convert DNS IDNA name `%s' to UTF-8: %s\n" | ||
3937 | msgstr "打开日志文件“%s”失败:%s\n" | ||
3938 | |||
3939 | #: src/gns/gnunet-gns.c:281 | ||
3940 | msgid "Cannot resolve using GNS: GNUnet peer not running\n" | ||
3941 | msgstr "" | ||
3942 | |||
3943 | #: src/gns/gnunet-gns.c:305 | ||
3944 | #, c-format | ||
3945 | msgid "Invalid typename specified, assuming `ANY'\n" | ||
3946 | msgstr "" | ||
3947 | |||
3948 | #: src/gns/gnunet-gns.c:340 | ||
3949 | msgid "Lookup a record for the given name" | ||
3950 | msgstr "" | ||
3951 | |||
3952 | #: src/gns/gnunet-gns.c:346 | ||
3953 | msgid "Specify the type of the record to lookup" | ||
3954 | msgstr "" | ||
3955 | |||
3956 | #: src/gns/gnunet-gns.c:352 | ||
3957 | msgid "Specify a timeout for the lookup" | ||
3958 | msgstr "" | ||
3959 | |||
3960 | #: src/gns/gnunet-gns.c:356 | ||
3961 | msgid "No unneeded output" | ||
3962 | msgstr "" | ||
3963 | |||
3964 | #: src/gns/gnunet-gns.c:361 | ||
3965 | msgid "DNS Compatibility: Name is passed in IDNA instead of UTF-8" | ||
3966 | msgstr "" | ||
3967 | |||
3968 | #: src/gns/gnunet-gns.c:375 | ||
3969 | #, fuzzy | ||
3970 | msgid "GNUnet GNS resolver tool" | ||
3971 | msgstr "GNUnet 错误日志" | ||
3972 | |||
3973 | #: src/gns/gnunet-gns-import.c:486 | 3929 | #: src/gns/gnunet-gns-import.c:486 |
3974 | msgid "This program will import some GNS authorities into your GNS namestore." | 3930 | msgid "This program will import some GNS authorities into your GNS namestore." |
3975 | msgstr "" | 3931 | msgstr "" |
@@ -4090,6 +4046,50 @@ msgstr "" | |||
4090 | msgid "GNUnet GNS proxy" | 4046 | msgid "GNUnet GNS proxy" |
4091 | msgstr "" | 4047 | msgstr "" |
4092 | 4048 | ||
4049 | #: src/gns/gnunet-gns.c:257 | ||
4050 | #, fuzzy, c-format | ||
4051 | msgid "`%s' is not a valid DNS domain name\n" | ||
4052 | msgstr "“%s”不可用。\n" | ||
4053 | |||
4054 | #: src/gns/gnunet-gns.c:267 src/util/dnsparser.c:254 | ||
4055 | #, fuzzy, c-format | ||
4056 | msgid "Failed to convert DNS IDNA name `%s' to UTF-8: %s\n" | ||
4057 | msgstr "打开日志文件“%s”失败:%s\n" | ||
4058 | |||
4059 | #: src/gns/gnunet-gns.c:281 | ||
4060 | msgid "Cannot resolve using GNS: GNUnet peer not running\n" | ||
4061 | msgstr "" | ||
4062 | |||
4063 | #: src/gns/gnunet-gns.c:305 | ||
4064 | #, c-format | ||
4065 | msgid "Invalid typename specified, assuming `ANY'\n" | ||
4066 | msgstr "" | ||
4067 | |||
4068 | #: src/gns/gnunet-gns.c:340 | ||
4069 | msgid "Lookup a record for the given name" | ||
4070 | msgstr "" | ||
4071 | |||
4072 | #: src/gns/gnunet-gns.c:346 | ||
4073 | msgid "Specify the type of the record to lookup" | ||
4074 | msgstr "" | ||
4075 | |||
4076 | #: src/gns/gnunet-gns.c:352 | ||
4077 | msgid "Specify a timeout for the lookup" | ||
4078 | msgstr "" | ||
4079 | |||
4080 | #: src/gns/gnunet-gns.c:356 | ||
4081 | msgid "No unneeded output" | ||
4082 | msgstr "" | ||
4083 | |||
4084 | #: src/gns/gnunet-gns.c:361 | ||
4085 | msgid "DNS Compatibility: Name is passed in IDNA instead of UTF-8" | ||
4086 | msgstr "" | ||
4087 | |||
4088 | #: src/gns/gnunet-gns.c:375 | ||
4089 | #, fuzzy | ||
4090 | msgid "GNUnet GNS resolver tool" | ||
4091 | msgstr "GNUnet 错误日志" | ||
4092 | |||
4093 | #: src/gns/gnunet-service-gns.c:505 | 4093 | #: src/gns/gnunet-service-gns.c:505 |
4094 | #, fuzzy | 4094 | #, fuzzy |
4095 | msgid "Properly base32-encoded public key required" | 4095 | msgid "Properly base32-encoded public key required" |
@@ -4101,8 +4101,8 @@ msgid "Failed to connect to the namecache!\n" | |||
4101 | msgstr "初始化“%s”服务失败。\n" | 4101 | msgstr "初始化“%s”服务失败。\n" |
4102 | 4102 | ||
4103 | #: src/gns/gnunet-service-gns.c:560 | 4103 | #: src/gns/gnunet-service-gns.c:560 |
4104 | #: src/zonemaster/gnunet-service-zonemaster.c:887 | ||
4105 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:444 | 4104 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:444 |
4105 | #: src/zonemaster/gnunet-service-zonemaster.c:887 | ||
4106 | #, fuzzy | 4106 | #, fuzzy |
4107 | msgid "Could not connect to DHT!\n" | 4107 | msgid "Could not connect to DHT!\n" |
4108 | msgstr "无法连接到 %s:%u:%s\n" | 4108 | msgstr "无法连接到 %s:%u:%s\n" |
@@ -4594,7 +4594,7 @@ msgid "# hostlist advertisements send" | |||
4594 | msgstr "" | 4594 | msgstr "" |
4595 | 4595 | ||
4596 | #: src/hostlist/gnunet-daemon-hostlist_server.c:674 | 4596 | #: src/hostlist/gnunet-daemon-hostlist_server.c:674 |
4597 | #: src/transport/gnunet-service-transport.c:2659 | 4597 | #: src/transport/gnunet-service-transport.c:2661 |
4598 | msgid "Could not access PEERINFO service. Exiting.\n" | 4598 | msgid "Could not access PEERINFO service. Exiting.\n" |
4599 | msgstr "" | 4599 | msgstr "" |
4600 | 4600 | ||
@@ -4847,6 +4847,70 @@ msgstr "sqlite 数据仓库" | |||
4847 | msgid "Failed to setup database at `%s'\n" | 4847 | msgid "Failed to setup database at `%s'\n" |
4848 | msgstr "运行 %s失败:%s %d\n" | 4848 | msgstr "运行 %s失败:%s %d\n" |
4849 | 4849 | ||
4850 | #: src/namestore/gnunet-namestore-fcfsd.c:552 | ||
4851 | #, fuzzy, c-format | ||
4852 | msgid "Unsupported form value `%s'\n" | ||
4853 | msgstr "未知的命令“%s”。\n" | ||
4854 | |||
4855 | #: src/namestore/gnunet-namestore-fcfsd.c:579 | ||
4856 | #, fuzzy, c-format | ||
4857 | msgid "Failed to create record for domain `%s': %s\n" | ||
4858 | msgstr "解析配置文件“%s”失败\n" | ||
4859 | |||
4860 | #: src/namestore/gnunet-namestore-fcfsd.c:600 | ||
4861 | msgid "Error when mapping zone to name\n" | ||
4862 | msgstr "" | ||
4863 | |||
4864 | #: src/namestore/gnunet-namestore-fcfsd.c:632 | ||
4865 | #, c-format | ||
4866 | msgid "Found existing name `%s' for the given key\n" | ||
4867 | msgstr "" | ||
4868 | |||
4869 | #: src/namestore/gnunet-namestore-fcfsd.c:694 | ||
4870 | #, c-format | ||
4871 | msgid "Found %u existing records for domain `%s'\n" | ||
4872 | msgstr "" | ||
4873 | |||
4874 | #: src/namestore/gnunet-namestore-fcfsd.c:784 | ||
4875 | #, fuzzy, c-format | ||
4876 | msgid "Failed to create page for `%s'\n" | ||
4877 | msgstr "发送消息失败。\n" | ||
4878 | |||
4879 | #: src/namestore/gnunet-namestore-fcfsd.c:803 | ||
4880 | #, fuzzy, c-format | ||
4881 | msgid "Failed to setup post processor for `%s'\n" | ||
4882 | msgstr "解析配置文件“%s”失败\n" | ||
4883 | |||
4884 | #: src/namestore/gnunet-namestore-fcfsd.c:840 | ||
4885 | msgid "Domain name must not contain `.'\n" | ||
4886 | msgstr "" | ||
4887 | |||
4888 | #: src/namestore/gnunet-namestore-fcfsd.c:849 | ||
4889 | msgid "Domain name must not contain `+'\n" | ||
4890 | msgstr "" | ||
4891 | |||
4892 | #: src/namestore/gnunet-namestore-fcfsd.c:1084 | ||
4893 | msgid "No ego configured for `fcfsd` subsystem\n" | ||
4894 | msgstr "" | ||
4895 | |||
4896 | #: src/namestore/gnunet-namestore-fcfsd.c:1115 | ||
4897 | #, fuzzy | ||
4898 | msgid "Failed to start HTTP server\n" | ||
4899 | msgstr "初始化“%s”服务失败。\n" | ||
4900 | |||
4901 | #: src/namestore/gnunet-namestore-fcfsd.c:1163 | ||
4902 | #, fuzzy | ||
4903 | msgid "Failed to connect to identity\n" | ||
4904 | msgstr "初始化“%s”服务失败。\n" | ||
4905 | |||
4906 | #: src/namestore/gnunet-namestore-fcfsd.c:1190 | ||
4907 | msgid "name of the zone that is to be managed by FCFSD" | ||
4908 | msgstr "" | ||
4909 | |||
4910 | #: src/namestore/gnunet-namestore-fcfsd.c:1210 | ||
4911 | msgid "GNU Name System First Come First Serve name registration service" | ||
4912 | msgstr "" | ||
4913 | |||
4850 | #: src/namestore/gnunet-namestore.c:334 | 4914 | #: src/namestore/gnunet-namestore.c:334 |
4851 | #, c-format | 4915 | #, c-format |
4852 | msgid "Adding record failed: %s\n" | 4916 | msgid "Adding record failed: %s\n" |
@@ -5076,70 +5140,6 @@ msgstr "" | |||
5076 | msgid "name of the ego controlling the zone" | 5140 | msgid "name of the ego controlling the zone" |
5077 | msgstr "" | 5141 | msgstr "" |
5078 | 5142 | ||
5079 | #: src/namestore/gnunet-namestore-fcfsd.c:552 | ||
5080 | #, fuzzy, c-format | ||
5081 | msgid "Unsupported form value `%s'\n" | ||
5082 | msgstr "未知的命令“%s”。\n" | ||
5083 | |||
5084 | #: src/namestore/gnunet-namestore-fcfsd.c:579 | ||
5085 | #, fuzzy, c-format | ||
5086 | msgid "Failed to create record for domain `%s': %s\n" | ||
5087 | msgstr "解析配置文件“%s”失败\n" | ||
5088 | |||
5089 | #: src/namestore/gnunet-namestore-fcfsd.c:600 | ||
5090 | msgid "Error when mapping zone to name\n" | ||
5091 | msgstr "" | ||
5092 | |||
5093 | #: src/namestore/gnunet-namestore-fcfsd.c:632 | ||
5094 | #, c-format | ||
5095 | msgid "Found existing name `%s' for the given key\n" | ||
5096 | msgstr "" | ||
5097 | |||
5098 | #: src/namestore/gnunet-namestore-fcfsd.c:694 | ||
5099 | #, c-format | ||
5100 | msgid "Found %u existing records for domain `%s'\n" | ||
5101 | msgstr "" | ||
5102 | |||
5103 | #: src/namestore/gnunet-namestore-fcfsd.c:784 | ||
5104 | #, fuzzy, c-format | ||
5105 | msgid "Failed to create page for `%s'\n" | ||
5106 | msgstr "发送消息失败。\n" | ||
5107 | |||
5108 | #: src/namestore/gnunet-namestore-fcfsd.c:803 | ||
5109 | #, fuzzy, c-format | ||
5110 | msgid "Failed to setup post processor for `%s'\n" | ||
5111 | msgstr "解析配置文件“%s”失败\n" | ||
5112 | |||
5113 | #: src/namestore/gnunet-namestore-fcfsd.c:840 | ||
5114 | msgid "Domain name must not contain `.'\n" | ||
5115 | msgstr "" | ||
5116 | |||
5117 | #: src/namestore/gnunet-namestore-fcfsd.c:849 | ||
5118 | msgid "Domain name must not contain `+'\n" | ||
5119 | msgstr "" | ||
5120 | |||
5121 | #: src/namestore/gnunet-namestore-fcfsd.c:1084 | ||
5122 | msgid "No ego configured for `fcfsd` subsystem\n" | ||
5123 | msgstr "" | ||
5124 | |||
5125 | #: src/namestore/gnunet-namestore-fcfsd.c:1115 | ||
5126 | #, fuzzy | ||
5127 | msgid "Failed to start HTTP server\n" | ||
5128 | msgstr "初始化“%s”服务失败。\n" | ||
5129 | |||
5130 | #: src/namestore/gnunet-namestore-fcfsd.c:1163 | ||
5131 | #, fuzzy | ||
5132 | msgid "Failed to connect to identity\n" | ||
5133 | msgstr "初始化“%s”服务失败。\n" | ||
5134 | |||
5135 | #: src/namestore/gnunet-namestore-fcfsd.c:1190 | ||
5136 | msgid "name of the zone that is to be managed by FCFSD" | ||
5137 | msgstr "" | ||
5138 | |||
5139 | #: src/namestore/gnunet-namestore-fcfsd.c:1210 | ||
5140 | msgid "GNU Name System First Come First Serve name registration service" | ||
5141 | msgstr "" | ||
5142 | |||
5143 | #: src/namestore/gnunet-service-namestore.c:866 | 5143 | #: src/namestore/gnunet-service-namestore.c:866 |
5144 | #, fuzzy, c-format | 5144 | #, fuzzy, c-format |
5145 | msgid "Failed to replicate block in namecache: %s\n" | 5145 | msgid "Failed to replicate block in namecache: %s\n" |
@@ -5455,10 +5455,6 @@ msgstr "" | |||
5455 | msgid "`upnpc' command not found\n" | 5455 | msgid "`upnpc' command not found\n" |
5456 | msgstr "" | 5456 | msgstr "" |
5457 | 5457 | ||
5458 | #: src/nse/gnunet-nse.c:124 | ||
5459 | msgid "Show network size estimates from NSE service." | ||
5460 | msgstr "" | ||
5461 | |||
5462 | #: src/nse/gnunet-nse-profiler.c:857 | 5458 | #: src/nse/gnunet-nse-profiler.c:857 |
5463 | msgid "limit to the number of connections to NSE services, 0 for none" | 5459 | msgid "limit to the number of connections to NSE services, 0 for none" |
5464 | msgstr "" | 5460 | msgstr "" |
@@ -5484,66 +5480,16 @@ msgstr "" | |||
5484 | msgid "Measure quality and performance of the NSE service." | 5480 | msgid "Measure quality and performance of the NSE service." |
5485 | msgstr "无法访问该服务" | 5481 | msgstr "无法访问该服务" |
5486 | 5482 | ||
5483 | #: src/nse/gnunet-nse.c:124 | ||
5484 | msgid "Show network size estimates from NSE service." | ||
5485 | msgstr "" | ||
5486 | |||
5487 | #: src/nse/gnunet-service-nse.c:1443 | 5487 | #: src/nse/gnunet-service-nse.c:1443 |
5488 | #: src/revocation/gnunet-service-revocation.c:834 src/util/gnunet-scrypt.c:257 | 5488 | #: src/revocation/gnunet-service-revocation.c:834 src/util/gnunet-scrypt.c:257 |
5489 | #, fuzzy | 5489 | #, fuzzy |
5490 | msgid "Value is too large.\n" | 5490 | msgid "Value is too large.\n" |
5491 | msgstr "值不在合法范围内。" | 5491 | msgstr "值不在合法范围内。" |
5492 | 5492 | ||
5493 | #: src/peerinfo/gnunet-service-peerinfo.c:175 | ||
5494 | #, c-format | ||
5495 | msgid "Removing expired address of transport `%s'\n" | ||
5496 | msgstr "" | ||
5497 | |||
5498 | #: src/peerinfo/gnunet-service-peerinfo.c:306 | ||
5499 | #, fuzzy, c-format | ||
5500 | msgid "Failed to parse HELLO in file `%s': %s\n" | ||
5501 | msgstr "解析配置文件“%s”失败\n" | ||
5502 | |||
5503 | #: src/peerinfo/gnunet-service-peerinfo.c:323 | ||
5504 | #: src/peerinfo/gnunet-service-peerinfo.c:348 | ||
5505 | #, fuzzy, c-format | ||
5506 | msgid "Failed to parse HELLO in file `%s'\n" | ||
5507 | msgstr "解析配置文件“%s”失败\n" | ||
5508 | |||
5509 | #: src/peerinfo/gnunet-service-peerinfo.c:426 | ||
5510 | msgid "# peers known" | ||
5511 | msgstr "" | ||
5512 | |||
5513 | #: src/peerinfo/gnunet-service-peerinfo.c:468 | ||
5514 | #, c-format | ||
5515 | msgid "" | ||
5516 | "File `%s' in directory `%s' does not match naming convention. Removed.\n" | ||
5517 | msgstr "" | ||
5518 | |||
5519 | #: src/peerinfo/gnunet-service-peerinfo.c:624 | ||
5520 | #, fuzzy, c-format | ||
5521 | msgid "Scanning directory `%s'\n" | ||
5522 | msgstr "解析配置文件“%s”失败\n" | ||
5523 | |||
5524 | #: src/peerinfo/gnunet-service-peerinfo.c:631 | ||
5525 | #, c-format | ||
5526 | msgid "Still no peers found in `%s'!\n" | ||
5527 | msgstr "" | ||
5528 | |||
5529 | #: src/peerinfo/gnunet-service-peerinfo.c:1024 | ||
5530 | #, fuzzy, c-format | ||
5531 | msgid "Cleaning up directory `%s'\n" | ||
5532 | msgstr "解析配置文件“%s”失败\n" | ||
5533 | |||
5534 | #: src/peerinfo/gnunet-service-peerinfo.c:1319 | ||
5535 | #, c-format | ||
5536 | msgid "Importing HELLOs from `%s'\n" | ||
5537 | msgstr "" | ||
5538 | |||
5539 | #: src/peerinfo/gnunet-service-peerinfo.c:1332 | ||
5540 | msgid "Skipping import of included HELLOs\n" | ||
5541 | msgstr "" | ||
5542 | |||
5543 | #: src/peerinfo/peerinfo_api.c:217 | ||
5544 | msgid "Failed to receive response from `PEERINFO' service." | ||
5545 | msgstr "" | ||
5546 | |||
5547 | #: src/peerinfo-tool/gnunet-peerinfo.c:237 | 5493 | #: src/peerinfo-tool/gnunet-peerinfo.c:237 |
5548 | #, fuzzy, c-format | 5494 | #, fuzzy, c-format |
5549 | msgid "%sPeer `%s'\n" | 5495 | msgid "%sPeer `%s'\n" |
@@ -5640,6 +5586,60 @@ msgstr "解析配置文件“%s”失败\n" | |||
5640 | msgid "Peerinfo REST API initialized\n" | 5586 | msgid "Peerinfo REST API initialized\n" |
5641 | msgstr "" | 5587 | msgstr "" |
5642 | 5588 | ||
5589 | #: src/peerinfo/gnunet-service-peerinfo.c:175 | ||
5590 | #, c-format | ||
5591 | msgid "Removing expired address of transport `%s'\n" | ||
5592 | msgstr "" | ||
5593 | |||
5594 | #: src/peerinfo/gnunet-service-peerinfo.c:306 | ||
5595 | #, fuzzy, c-format | ||
5596 | msgid "Failed to parse HELLO in file `%s': %s\n" | ||
5597 | msgstr "解析配置文件“%s”失败\n" | ||
5598 | |||
5599 | #: src/peerinfo/gnunet-service-peerinfo.c:323 | ||
5600 | #: src/peerinfo/gnunet-service-peerinfo.c:348 | ||
5601 | #, fuzzy, c-format | ||
5602 | msgid "Failed to parse HELLO in file `%s'\n" | ||
5603 | msgstr "解析配置文件“%s”失败\n" | ||
5604 | |||
5605 | #: src/peerinfo/gnunet-service-peerinfo.c:426 | ||
5606 | msgid "# peers known" | ||
5607 | msgstr "" | ||
5608 | |||
5609 | #: src/peerinfo/gnunet-service-peerinfo.c:468 | ||
5610 | #, c-format | ||
5611 | msgid "" | ||
5612 | "File `%s' in directory `%s' does not match naming convention. Removed.\n" | ||
5613 | msgstr "" | ||
5614 | |||
5615 | #: src/peerinfo/gnunet-service-peerinfo.c:624 | ||
5616 | #, fuzzy, c-format | ||
5617 | msgid "Scanning directory `%s'\n" | ||
5618 | msgstr "解析配置文件“%s”失败\n" | ||
5619 | |||
5620 | #: src/peerinfo/gnunet-service-peerinfo.c:631 | ||
5621 | #, c-format | ||
5622 | msgid "Still no peers found in `%s'!\n" | ||
5623 | msgstr "" | ||
5624 | |||
5625 | #: src/peerinfo/gnunet-service-peerinfo.c:1024 | ||
5626 | #, fuzzy, c-format | ||
5627 | msgid "Cleaning up directory `%s'\n" | ||
5628 | msgstr "解析配置文件“%s”失败\n" | ||
5629 | |||
5630 | #: src/peerinfo/gnunet-service-peerinfo.c:1319 | ||
5631 | #, c-format | ||
5632 | msgid "Importing HELLOs from `%s'\n" | ||
5633 | msgstr "" | ||
5634 | |||
5635 | #: src/peerinfo/gnunet-service-peerinfo.c:1332 | ||
5636 | msgid "Skipping import of included HELLOs\n" | ||
5637 | msgstr "" | ||
5638 | |||
5639 | #: src/peerinfo/peerinfo_api.c:217 | ||
5640 | msgid "Failed to receive response from `PEERINFO' service." | ||
5641 | msgstr "" | ||
5642 | |||
5643 | #: src/peerstore/gnunet-peerstore.c:92 | 5643 | #: src/peerstore/gnunet-peerstore.c:92 |
5644 | msgid "peerstore" | 5644 | msgid "peerstore" |
5645 | msgstr "" | 5645 | msgstr "" |
@@ -6094,18 +6094,6 @@ msgstr "" | |||
6094 | msgid "Could not open revocation database file!" | 6094 | msgid "Could not open revocation database file!" |
6095 | msgstr "无法连接到 %s:%u:%s\n" | 6095 | msgstr "无法连接到 %s:%u:%s\n" |
6096 | 6096 | ||
6097 | #: src/rps/gnunet-rps.c:270 | ||
6098 | msgid "Seed a PeerID" | ||
6099 | msgstr "" | ||
6100 | |||
6101 | #: src/rps/gnunet-rps.c:275 | ||
6102 | msgid "Get updates of view (0 for infinite updates)" | ||
6103 | msgstr "" | ||
6104 | |||
6105 | #: src/rps/gnunet-rps.c:279 | ||
6106 | msgid "Get peers from biased stream" | ||
6107 | msgstr "" | ||
6108 | |||
6109 | #: src/rps/gnunet-rps-profiler.c:3200 | 6097 | #: src/rps/gnunet-rps-profiler.c:3200 |
6110 | msgid "duration of the profiling" | 6098 | msgid "duration of the profiling" |
6111 | msgstr "" | 6099 | msgstr "" |
@@ -6124,6 +6112,18 @@ msgstr "迭代次数" | |||
6124 | msgid "Measure quality and performance of the RPS service." | 6112 | msgid "Measure quality and performance of the RPS service." |
6125 | msgstr "无法访问该服务" | 6113 | msgstr "无法访问该服务" |
6126 | 6114 | ||
6115 | #: src/rps/gnunet-rps.c:270 | ||
6116 | msgid "Seed a PeerID" | ||
6117 | msgstr "" | ||
6118 | |||
6119 | #: src/rps/gnunet-rps.c:275 | ||
6120 | msgid "Get updates of view (0 for infinite updates)" | ||
6121 | msgstr "" | ||
6122 | |||
6123 | #: src/rps/gnunet-rps.c:279 | ||
6124 | msgid "Get peers from biased stream" | ||
6125 | msgstr "" | ||
6126 | |||
6127 | #: src/scalarproduct/gnunet-scalarproduct.c:229 | 6127 | #: src/scalarproduct/gnunet-scalarproduct.c:229 |
6128 | #, fuzzy | 6128 | #, fuzzy |
6129 | msgid "You must specify at least one message ID to check!\n" | 6129 | msgid "You must specify at least one message ID to check!\n" |
@@ -6179,10 +6179,10 @@ msgstr "" | |||
6179 | msgid "Calculate the Vectorproduct with a GNUnet peer." | 6179 | msgid "Calculate the Vectorproduct with a GNUnet peer." |
6180 | msgstr "" | 6180 | msgstr "" |
6181 | 6181 | ||
6182 | #: src/scalarproduct/gnunet-service-scalarproduct_alice.c:1358 | ||
6183 | #: src/scalarproduct/gnunet-service-scalarproduct_bob.c:1355 | ||
6184 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_alice.c:1118 | 6182 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_alice.c:1118 |
6185 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c:1063 | 6183 | #: src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c:1063 |
6184 | #: src/scalarproduct/gnunet-service-scalarproduct_alice.c:1358 | ||
6185 | #: src/scalarproduct/gnunet-service-scalarproduct_bob.c:1355 | ||
6186 | #, fuzzy | 6186 | #, fuzzy |
6187 | msgid "Connect to CADET failed\n" | 6187 | msgid "Connect to CADET failed\n" |
6188 | msgstr "“%s”已连接到“%s”。\n" | 6188 | msgstr "“%s”已连接到“%s”。\n" |
@@ -6537,15 +6537,6 @@ msgstr "" | |||
6537 | msgid "%.s Unknown result code." | 6537 | msgid "%.s Unknown result code." |
6538 | msgstr "" | 6538 | msgstr "" |
6539 | 6539 | ||
6540 | #: src/testbed/gnunet_testbed_mpi_spawn.c:119 | ||
6541 | msgid "Waiting for child to exit.\n" | ||
6542 | msgstr "" | ||
6543 | |||
6544 | #: src/testbed/gnunet_testbed_mpi_spawn.c:242 | ||
6545 | #, fuzzy, c-format | ||
6546 | msgid "Spawning process `%s'\n" | ||
6547 | msgstr "卸载 GNUnet 服务" | ||
6548 | |||
6549 | #: src/testbed/gnunet-testbed-profiler.c:290 | 6540 | #: src/testbed/gnunet-testbed-profiler.c:290 |
6550 | msgid "tolerate COUNT number of continious timeout failures" | 6541 | msgid "tolerate COUNT number of continious timeout failures" |
6551 | msgstr "" | 6542 | msgstr "" |
@@ -6557,6 +6548,15 @@ msgid "" | |||
6557 | "signal is received" | 6548 | "signal is received" |
6558 | msgstr "" | 6549 | msgstr "" |
6559 | 6550 | ||
6551 | #: src/testbed/gnunet_testbed_mpi_spawn.c:119 | ||
6552 | msgid "Waiting for child to exit.\n" | ||
6553 | msgstr "" | ||
6554 | |||
6555 | #: src/testbed/gnunet_testbed_mpi_spawn.c:242 | ||
6556 | #, fuzzy, c-format | ||
6557 | msgid "Spawning process `%s'\n" | ||
6558 | msgstr "卸载 GNUnet 服务" | ||
6559 | |||
6560 | #: src/testbed/testbed_api.c:399 | 6560 | #: src/testbed/testbed_api.c:399 |
6561 | #, fuzzy, c-format | 6561 | #, fuzzy, c-format |
6562 | msgid "Adding host %u failed with error: %s\n" | 6562 | msgid "Adding host %u failed with error: %s\n" |
@@ -6853,19 +6853,19 @@ msgstr "" | |||
6853 | msgid "GNUnet topology control" | 6853 | msgid "GNUnet topology control" |
6854 | msgstr "" | 6854 | msgstr "" |
6855 | 6855 | ||
6856 | #: src/transport/gnunet-communicator-tcp.c:3189 | 6856 | #: src/transport/gnunet-communicator-tcp.c:3221 |
6857 | #: src/transport/gnunet-communicator-udp.c:2826 | 6857 | #: src/transport/gnunet-communicator-udp.c:2995 |
6858 | #: src/transport/gnunet-service-tng.c:10014 | 6858 | #: src/transport/gnunet-service-tng.c:10014 |
6859 | #: src/transport/gnunet-service-transport.c:2624 | 6859 | #: src/transport/gnunet-service-transport.c:2626 |
6860 | #, fuzzy | 6860 | #, fuzzy |
6861 | msgid "Transport service is lacking key configuration settings. Exiting.\n" | 6861 | msgid "Transport service is lacking key configuration settings. Exiting.\n" |
6862 | msgstr "立即保存配置?" | 6862 | msgstr "立即保存配置?" |
6863 | 6863 | ||
6864 | #: src/transport/gnunet-communicator-tcp.c:3494 | 6864 | #: src/transport/gnunet-communicator-tcp.c:3553 |
6865 | msgid "GNUnet TCP communicator" | 6865 | msgid "GNUnet TCP communicator" |
6866 | msgstr "" | 6866 | msgstr "" |
6867 | 6867 | ||
6868 | #: src/transport/gnunet-communicator-udp.c:2898 | 6868 | #: src/transport/gnunet-communicator-udp.c:3067 |
6869 | msgid "GNUnet UDP communicator" | 6869 | msgid "GNUnet UDP communicator" |
6870 | msgstr "" | 6870 | msgstr "" |
6871 | 6871 | ||
@@ -6890,50 +6890,50 @@ msgstr "发送消息失败。\n" | |||
6890 | msgid "GNUnet UNIX domain socket communicator" | 6890 | msgid "GNUnet UNIX domain socket communicator" |
6891 | msgstr "" | 6891 | msgstr "" |
6892 | 6892 | ||
6893 | #: src/transport/gnunet-service-transport_ats.c:137 | ||
6894 | msgid "# Addresses given to ATS" | ||
6895 | msgstr "" | ||
6896 | |||
6897 | #: src/transport/gnunet-service-transport.c:445 | 6893 | #: src/transport/gnunet-service-transport.c:445 |
6898 | msgid "# messages dropped due to slow client" | 6894 | msgid "# messages dropped due to slow client" |
6899 | msgstr "" | 6895 | msgstr "" |
6900 | 6896 | ||
6901 | #: src/transport/gnunet-service-transport.c:794 | 6897 | #: src/transport/gnunet-service-transport.c:796 |
6902 | msgid "# bytes payload dropped (other peer was not connected)" | 6898 | msgid "# bytes payload dropped (other peer was not connected)" |
6903 | msgstr "" | 6899 | msgstr "" |
6904 | 6900 | ||
6905 | #: src/transport/gnunet-service-transport.c:1477 | 6901 | #: src/transport/gnunet-service-transport.c:1479 |
6906 | msgid "# bytes payload discarded due to not connected peer" | 6902 | msgid "# bytes payload discarded due to not connected peer" |
6907 | msgstr "" | 6903 | msgstr "" |
6908 | 6904 | ||
6909 | #: src/transport/gnunet-service-transport.c:1622 | 6905 | #: src/transport/gnunet-service-transport.c:1624 |
6910 | msgid "# bytes total received" | 6906 | msgid "# bytes total received" |
6911 | msgstr "" | 6907 | msgstr "" |
6912 | 6908 | ||
6913 | #: src/transport/gnunet-service-transport.c:1712 | 6909 | #: src/transport/gnunet-service-transport.c:1714 |
6914 | msgid "# bytes payload received" | 6910 | msgid "# bytes payload received" |
6915 | msgstr "" | 6911 | msgstr "" |
6916 | 6912 | ||
6917 | #: src/transport/gnunet-service-transport.c:2016 | 6913 | #: src/transport/gnunet-service-transport.c:2018 |
6918 | #: src/transport/gnunet-service-transport.c:2450 | 6914 | #: src/transport/gnunet-service-transport.c:2452 |
6919 | msgid "# disconnects due to blacklist" | 6915 | msgid "# disconnects due to blacklist" |
6920 | msgstr "" | 6916 | msgstr "" |
6921 | 6917 | ||
6922 | #: src/transport/gnunet-service-transport.c:2454 | 6918 | #: src/transport/gnunet-service-transport.c:2456 |
6923 | #, fuzzy, c-format | 6919 | #, fuzzy, c-format |
6924 | msgid "Disallowing connection to peer `%s' on transport %s\n" | 6920 | msgid "Disallowing connection to peer `%s' on transport %s\n" |
6925 | msgstr "解析配置文件“%s”失败\n" | 6921 | msgstr "解析配置文件“%s”失败\n" |
6926 | 6922 | ||
6927 | #: src/transport/gnunet-service-transport.c:2549 | 6923 | #: src/transport/gnunet-service-transport.c:2551 |
6928 | #, fuzzy, c-format | 6924 | #, fuzzy, c-format |
6929 | msgid "Adding blacklisting entry for peer `%s'\n" | 6925 | msgid "Adding blacklisting entry for peer `%s'\n" |
6930 | msgstr "卸载 GNUnet 服务" | 6926 | msgstr "卸载 GNUnet 服务" |
6931 | 6927 | ||
6932 | #: src/transport/gnunet-service-transport.c:2558 | 6928 | #: src/transport/gnunet-service-transport.c:2560 |
6933 | #, c-format | 6929 | #, c-format |
6934 | msgid "Adding blacklisting entry for peer `%s':`%s'\n" | 6930 | msgid "Adding blacklisting entry for peer `%s':`%s'\n" |
6935 | msgstr "" | 6931 | msgstr "" |
6936 | 6932 | ||
6933 | #: src/transport/gnunet-service-transport_ats.c:137 | ||
6934 | msgid "# Addresses given to ATS" | ||
6935 | msgstr "" | ||
6936 | |||
6937 | #: src/transport/gnunet-service-transport_hello.c:195 | 6937 | #: src/transport/gnunet-service-transport_hello.c:195 |
6938 | msgid "# refreshed my HELLO" | 6938 | msgid "# refreshed my HELLO" |
6939 | msgstr "" | 6939 | msgstr "" |
@@ -7242,6 +7242,44 @@ msgstr "" | |||
7242 | msgid "# HELLOs given to peerinfo" | 7242 | msgid "# HELLOs given to peerinfo" |
7243 | msgstr "" | 7243 | msgstr "" |
7244 | 7244 | ||
7245 | #: src/transport/gnunet-transport-profiler.c:220 | ||
7246 | #, c-format | ||
7247 | msgid "%llu B in %llu ms == %.2f KB/s!\n" | ||
7248 | msgstr "" | ||
7249 | |||
7250 | #: src/transport/gnunet-transport-profiler.c:577 | ||
7251 | msgid "send data to peer" | ||
7252 | msgstr "" | ||
7253 | |||
7254 | #: src/transport/gnunet-transport-profiler.c:581 | ||
7255 | msgid "receive data from peer" | ||
7256 | msgstr "" | ||
7257 | |||
7258 | #: src/transport/gnunet-transport-profiler.c:586 | ||
7259 | msgid "iterations" | ||
7260 | msgstr "" | ||
7261 | |||
7262 | #: src/transport/gnunet-transport-profiler.c:591 | ||
7263 | #, fuzzy | ||
7264 | msgid "number of messages to send" | ||
7265 | msgstr "每次迭代所使用的消息数量" | ||
7266 | |||
7267 | #: src/transport/gnunet-transport-profiler.c:596 | ||
7268 | #, fuzzy | ||
7269 | msgid "message size to use" | ||
7270 | msgstr "消息尺寸" | ||
7271 | |||
7272 | #: src/transport/gnunet-transport-profiler.c:601 | ||
7273 | #: src/transport/gnunet-transport.c:1404 | ||
7274 | msgid "peer identity" | ||
7275 | msgstr "" | ||
7276 | |||
7277 | #: src/transport/gnunet-transport-profiler.c:614 | ||
7278 | #: src/transport/gnunet-transport.c:1426 | ||
7279 | #, fuzzy | ||
7280 | msgid "Direct access to transport service." | ||
7281 | msgstr "初始化“%s”服务失败。\n" | ||
7282 | |||
7245 | #: src/transport/gnunet-transport.c:406 | 7283 | #: src/transport/gnunet-transport.c:406 |
7246 | #, c-format | 7284 | #, c-format |
7247 | msgid "Transmitted %llu bytes/s (%llu bytes in %s)\n" | 7285 | msgid "Transmitted %llu bytes/s (%llu bytes in %s)\n" |
@@ -7378,11 +7416,6 @@ msgstr "" | |||
7378 | msgid "do not resolve hostnames" | 7416 | msgid "do not resolve hostnames" |
7379 | msgstr "" | 7417 | msgstr "" |
7380 | 7418 | ||
7381 | #: src/transport/gnunet-transport.c:1404 | ||
7382 | #: src/transport/gnunet-transport-profiler.c:601 | ||
7383 | msgid "peer identity" | ||
7384 | msgstr "" | ||
7385 | |||
7386 | #: src/transport/gnunet-transport.c:1408 | 7419 | #: src/transport/gnunet-transport.c:1408 |
7387 | msgid "monitor plugin sessions" | 7420 | msgid "monitor plugin sessions" |
7388 | msgstr "" | 7421 | msgstr "" |
@@ -7391,39 +7424,6 @@ msgstr "" | |||
7391 | msgid "send data for benchmarking to the other peer (until CTRL-C)" | 7424 | msgid "send data for benchmarking to the other peer (until CTRL-C)" |
7392 | msgstr "" | 7425 | msgstr "" |
7393 | 7426 | ||
7394 | #: src/transport/gnunet-transport.c:1426 | ||
7395 | #: src/transport/gnunet-transport-profiler.c:614 | ||
7396 | #, fuzzy | ||
7397 | msgid "Direct access to transport service." | ||
7398 | msgstr "初始化“%s”服务失败。\n" | ||
7399 | |||
7400 | #: src/transport/gnunet-transport-profiler.c:220 | ||
7401 | #, c-format | ||
7402 | msgid "%llu B in %llu ms == %.2f KB/s!\n" | ||
7403 | msgstr "" | ||
7404 | |||
7405 | #: src/transport/gnunet-transport-profiler.c:577 | ||
7406 | msgid "send data to peer" | ||
7407 | msgstr "" | ||
7408 | |||
7409 | #: src/transport/gnunet-transport-profiler.c:581 | ||
7410 | msgid "receive data from peer" | ||
7411 | msgstr "" | ||
7412 | |||
7413 | #: src/transport/gnunet-transport-profiler.c:586 | ||
7414 | msgid "iterations" | ||
7415 | msgstr "" | ||
7416 | |||
7417 | #: src/transport/gnunet-transport-profiler.c:591 | ||
7418 | #, fuzzy | ||
7419 | msgid "number of messages to send" | ||
7420 | msgstr "每次迭代所使用的消息数量" | ||
7421 | |||
7422 | #: src/transport/gnunet-transport-profiler.c:596 | ||
7423 | #, fuzzy | ||
7424 | msgid "message size to use" | ||
7425 | msgstr "消息尺寸" | ||
7426 | |||
7427 | #: src/transport/plugin_transport_http_client.c:1489 | 7427 | #: src/transport/plugin_transport_http_client.c:1489 |
7428 | #: src/transport/plugin_transport_http_server.c:2331 | 7428 | #: src/transport/plugin_transport_http_server.c:2331 |
7429 | #: src/transport/plugin_transport_http_server.c:3562 | 7429 | #: src/transport/plugin_transport_http_server.c:3562 |
@@ -7700,20 +7700,6 @@ msgstr "" | |||
7700 | msgid "TCP transport advertises itself as being on port %llu\n" | 7700 | msgid "TCP transport advertises itself as being on port %llu\n" |
7701 | msgstr "" | 7701 | msgstr "" |
7702 | 7702 | ||
7703 | #: src/transport/plugin_transport_udp_broadcasting.c:169 | ||
7704 | msgid "# Multicast HELLO beacons received via UDP" | ||
7705 | msgstr "" | ||
7706 | |||
7707 | #: src/transport/plugin_transport_udp_broadcasting.c:553 | ||
7708 | msgid "" | ||
7709 | "Disabling HELLO broadcasting due to friend-to-friend only configuration!\n" | ||
7710 | msgstr "" | ||
7711 | |||
7712 | #: src/transport/plugin_transport_udp_broadcasting.c:571 | ||
7713 | #, c-format | ||
7714 | msgid "Failed to set IPv4 broadcast option for broadcast socket on port %d\n" | ||
7715 | msgstr "" | ||
7716 | |||
7717 | #: src/transport/plugin_transport_udp.c:3169 | 7703 | #: src/transport/plugin_transport_udp.c:3169 |
7718 | #, c-format | 7704 | #, c-format |
7719 | msgid "" | 7705 | msgid "" |
@@ -7762,6 +7748,20 @@ msgstr "“%s”不可用。\n" | |||
7762 | msgid "Failed to create UDP network sockets\n" | 7748 | msgid "Failed to create UDP network sockets\n" |
7763 | msgstr "发送消息失败。\n" | 7749 | msgstr "发送消息失败。\n" |
7764 | 7750 | ||
7751 | #: src/transport/plugin_transport_udp_broadcasting.c:169 | ||
7752 | msgid "# Multicast HELLO beacons received via UDP" | ||
7753 | msgstr "" | ||
7754 | |||
7755 | #: src/transport/plugin_transport_udp_broadcasting.c:553 | ||
7756 | msgid "" | ||
7757 | "Disabling HELLO broadcasting due to friend-to-friend only configuration!\n" | ||
7758 | msgstr "" | ||
7759 | |||
7760 | #: src/transport/plugin_transport_udp_broadcasting.c:571 | ||
7761 | #, c-format | ||
7762 | msgid "Failed to set IPv4 broadcast option for broadcast socket on port %d\n" | ||
7763 | msgstr "" | ||
7764 | |||
7765 | #: src/transport/plugin_transport_unix.c:1396 | 7765 | #: src/transport/plugin_transport_unix.c:1396 |
7766 | #, fuzzy, c-format | 7766 | #, fuzzy, c-format |
7767 | msgid "Cannot bind to `%s'\n" | 7767 | msgid "Cannot bind to `%s'\n" |
@@ -7934,7 +7934,7 @@ msgid "do daemonize (detach from terminal)" | |||
7934 | msgstr "" | 7934 | msgstr "" |
7935 | 7935 | ||
7936 | #: src/transport/tcp_service_legacy.c:1397 | 7936 | #: src/transport/tcp_service_legacy.c:1397 |
7937 | #: src/transport/transport-testing2.c:1116 src/util/service.c:2072 | 7937 | #: src/transport/transport-testing2.c:983 src/util/service.c:2072 |
7938 | #: src/util/service.c:2084 | 7938 | #: src/util/service.c:2084 |
7939 | #, fuzzy, c-format | 7939 | #, fuzzy, c-format |
7940 | msgid "Malformed configuration file `%s', exit ...\n" | 7940 | msgid "Malformed configuration file `%s', exit ...\n" |
@@ -8598,19 +8598,19 @@ msgid "" | |||
8598 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" | 8598 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" |
8599 | msgstr "" | 8599 | msgstr "" |
8600 | 8600 | ||
8601 | #: src/util/os_installation.c:409 | 8601 | #: src/util/os_installation.c:411 |
8602 | #, fuzzy, c-format | 8602 | #, fuzzy, c-format |
8603 | msgid "" | 8603 | msgid "" |
8604 | "Could not determine installation path for %s. Set `%s' environment " | 8604 | "Could not determine installation path for %s. Set `%s' environment " |
8605 | "variable.\n" | 8605 | "variable.\n" |
8606 | msgstr "无法确定安装路径。请尝试设置“%s”\n" | 8606 | msgstr "无法确定安装路径。请尝试设置“%s”\n" |
8607 | 8607 | ||
8608 | #: src/util/os_installation.c:792 | 8608 | #: src/util/os_installation.c:794 |
8609 | #, fuzzy, c-format | 8609 | #, fuzzy, c-format |
8610 | msgid "Could not find binary `%s' in PATH!\n" | 8610 | msgid "Could not find binary `%s' in PATH!\n" |
8611 | msgstr "找不到主机“%s”的 IP:%s\n" | 8611 | msgstr "找不到主机“%s”的 IP:%s\n" |
8612 | 8612 | ||
8613 | #: src/util/os_installation.c:825 | 8613 | #: src/util/os_installation.c:827 |
8614 | #, c-format | 8614 | #, c-format |
8615 | msgid "Binary `%s' exists, but is not SUID\n" | 8615 | msgid "Binary `%s' exists, but is not SUID\n" |
8616 | msgstr "" | 8616 | msgstr "" |
@@ -8635,17 +8635,17 @@ msgstr "" | |||
8635 | msgid "Could not determine plugin installation path.\n" | 8635 | msgid "Could not determine plugin installation path.\n" |
8636 | msgstr "无法确定用户界面定义文件。" | 8636 | msgstr "无法确定用户界面定义文件。" |
8637 | 8637 | ||
8638 | #: src/util/program.c:262 | 8638 | #: src/util/program.c:267 |
8639 | #, fuzzy, c-format | 8639 | #, fuzzy, c-format |
8640 | msgid "Unreadable or malformed configuration file `%s', exit ...\n" | 8640 | msgid "Unreadable or malformed configuration file `%s', exit ...\n" |
8641 | msgstr "解析配置文件“%s”失败\n" | 8641 | msgstr "解析配置文件“%s”失败\n" |
8642 | 8642 | ||
8643 | #: src/util/program.c:279 | 8643 | #: src/util/program.c:284 |
8644 | #, fuzzy, c-format | 8644 | #, fuzzy, c-format |
8645 | msgid "Unreadable or malformed default configuration file `%s', exit ...\n" | 8645 | msgid "Unreadable or malformed default configuration file `%s', exit ...\n" |
8646 | msgstr "解析配置文件“%s”失败\n" | 8646 | msgstr "解析配置文件“%s”失败\n" |
8647 | 8647 | ||
8648 | #: src/util/program.c:294 | 8648 | #: src/util/program.c:299 |
8649 | #, fuzzy | 8649 | #, fuzzy |
8650 | msgid "Unreadable or malformed configuration, exit ...\n" | 8650 | msgid "Unreadable or malformed configuration, exit ...\n" |
8651 | msgstr "解析配置文件“%s”失败\n" | 8651 | msgstr "解析配置文件“%s”失败\n" |
@@ -8710,10 +8710,6 @@ msgstr "" | |||
8710 | msgid "Attempting to proxy service `%s' to invalid port %d or hostname.\n" | 8710 | msgid "Attempting to proxy service `%s' to invalid port %d or hostname.\n" |
8711 | msgstr "" | 8711 | msgstr "" |
8712 | 8712 | ||
8713 | #: src/util/strings.c:179 | ||
8714 | msgid "b" | ||
8715 | msgstr "b" | ||
8716 | |||
8717 | #: src/util/strings.c:503 | 8713 | #: src/util/strings.c:503 |
8718 | #, c-format | 8714 | #, c-format |
8719 | msgid "Character sets requested were `%s'->`%s'\n" | 8715 | msgid "Character sets requested were `%s'->`%s'\n" |
@@ -8723,48 +8719,6 @@ msgstr "" | |||
8723 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" | 8719 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" |
8724 | msgstr "扩展“$HOME”失败:没有设置环境变量“HOME”" | 8720 | msgstr "扩展“$HOME”失败:没有设置环境变量“HOME”" |
8725 | 8721 | ||
8726 | #: src/util/strings.c:706 | ||
8727 | msgid "µs" | ||
8728 | msgstr "" | ||
8729 | |||
8730 | #: src/util/strings.c:710 | ||
8731 | msgid "forever" | ||
8732 | msgstr "" | ||
8733 | |||
8734 | #: src/util/strings.c:712 | ||
8735 | msgid "0 ms" | ||
8736 | msgstr "" | ||
8737 | |||
8738 | #: src/util/strings.c:716 | ||
8739 | msgid "ms" | ||
8740 | msgstr "毫秒" | ||
8741 | |||
8742 | #: src/util/strings.c:720 | ||
8743 | msgid "s" | ||
8744 | msgstr "秒" | ||
8745 | |||
8746 | #: src/util/strings.c:724 | ||
8747 | msgid "m" | ||
8748 | msgstr "分" | ||
8749 | |||
8750 | #: src/util/strings.c:728 | ||
8751 | msgid "h" | ||
8752 | msgstr "时" | ||
8753 | |||
8754 | #: src/util/strings.c:734 | ||
8755 | #, fuzzy | ||
8756 | msgid "day" | ||
8757 | msgstr " 天" | ||
8758 | |||
8759 | #: src/util/strings.c:736 | ||
8760 | #, fuzzy | ||
8761 | msgid "days" | ||
8762 | msgstr " 天" | ||
8763 | |||
8764 | #: src/util/strings.c:764 | ||
8765 | msgid "end of time" | ||
8766 | msgstr "" | ||
8767 | |||
8768 | #: src/util/strings.c:1240 | 8722 | #: src/util/strings.c:1240 |
8769 | msgid "IPv6 address did not start with `['\n" | 8723 | msgid "IPv6 address did not start with `['\n" |
8770 | msgstr "" | 8724 | msgstr "" |
@@ -9007,12 +8961,35 @@ msgstr "" | |||
9007 | msgid "Setup tunnels via VPN." | 8961 | msgid "Setup tunnels via VPN." |
9008 | msgstr "" | 8962 | msgstr "" |
9009 | 8963 | ||
9010 | #: src/zonemaster/gnunet-service-zonemaster.c:849 | ||
9011 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:420 | 8964 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:420 |
8965 | #: src/zonemaster/gnunet-service-zonemaster.c:849 | ||
9012 | #, fuzzy | 8966 | #, fuzzy |
9013 | msgid "Failed to connect to the namestore!\n" | 8967 | msgid "Failed to connect to the namestore!\n" |
9014 | msgstr "初始化“%s”服务失败。\n" | 8968 | msgstr "初始化“%s”服务失败。\n" |
9015 | 8969 | ||
8970 | #~ msgid "b" | ||
8971 | #~ msgstr "b" | ||
8972 | |||
8973 | #~ msgid "ms" | ||
8974 | #~ msgstr "毫秒" | ||
8975 | |||
8976 | #~ msgid "s" | ||
8977 | #~ msgstr "秒" | ||
8978 | |||
8979 | #~ msgid "m" | ||
8980 | #~ msgstr "分" | ||
8981 | |||
8982 | #~ msgid "h" | ||
8983 | #~ msgstr "时" | ||
8984 | |||
8985 | #, fuzzy | ||
8986 | #~ msgid "day" | ||
8987 | #~ msgstr " 天" | ||
8988 | |||
8989 | #, fuzzy | ||
8990 | #~ msgid "days" | ||
8991 | #~ msgstr " 天" | ||
8992 | |||
9016 | #, fuzzy, c-format | 8993 | #, fuzzy, c-format |
9017 | #~ msgid "Could not acquire lock on file `%s': %s...\n" | 8994 | #~ msgid "Could not acquire lock on file `%s': %s...\n" |
9018 | #~ msgstr "无法解析“%s”(%s):%s\n" | 8995 | #~ msgstr "无法解析“%s”(%s):%s\n" |
diff --git a/src/Makefile.am b/src/Makefile.am index 234a63389..c04d730be 100644 --- a/src/Makefile.am +++ b/src/Makefile.am | |||
@@ -12,7 +12,8 @@ endif | |||
12 | if HAVE_EXPERIMENTAL | 12 | if HAVE_EXPERIMENTAL |
13 | EXP_DIR = \ | 13 | EXP_DIR = \ |
14 | rps \ | 14 | rps \ |
15 | abd | 15 | #abd FTBFS |
16 | messenger | ||
16 | if HAVE_ABE | 17 | if HAVE_ABE |
17 | EXP_DIR += \ | 18 | EXP_DIR += \ |
18 | abe | 19 | abe |
@@ -51,7 +52,6 @@ SUBDIRS = \ | |||
51 | include $(INTLEMU_SUBDIRS) \ | 52 | include $(INTLEMU_SUBDIRS) \ |
52 | util \ | 53 | util \ |
53 | nt \ | 54 | nt \ |
54 | gnsrecord \ | ||
55 | hello \ | 55 | hello \ |
56 | block \ | 56 | block \ |
57 | statistics \ | 57 | statistics \ |
@@ -74,7 +74,6 @@ SUBDIRS = \ | |||
74 | fragmentation \ | 74 | fragmentation \ |
75 | transport \ | 75 | transport \ |
76 | ats-tool \ | 76 | ats-tool \ |
77 | peerinfo-tool \ | ||
78 | core \ | 77 | core \ |
79 | $(TESTBED) \ | 78 | $(TESTBED) \ |
80 | $(ATS_TESTS) \ | 79 | $(ATS_TESTS) \ |
@@ -85,8 +84,10 @@ SUBDIRS = \ | |||
85 | regex \ | 84 | regex \ |
86 | dns \ | 85 | dns \ |
87 | identity \ | 86 | identity \ |
87 | gnsrecord \ | ||
88 | namecache \ | 88 | namecache \ |
89 | namestore \ | 89 | namestore \ |
90 | peerinfo-tool \ | ||
90 | cadet \ | 91 | cadet \ |
91 | set \ | 92 | set \ |
92 | seti \ | 93 | seti \ |
diff --git a/src/ats-tests/ats-testing-log.c b/src/ats-tests/ats-testing-log.c index 38094a438..955401dd8 100644 --- a/src/ats-tests/ats-testing-log.c +++ b/src/ats-tests/ats-testing-log.c | |||
@@ -575,7 +575,7 @@ GNUNET_ATS_TEST_logging_write_to_file (struct LoggingHandle *l, | |||
575 | 575 | ||
576 | /* Assembling slave string */ | 576 | /* Assembling slave string */ |
577 | GNUNET_asprintf (&data, | 577 | GNUNET_asprintf (&data, |
578 | "%llu;%llu;%u;%u;%u;%u;%u;%u;%.3f;%u;%u;%u;%u;%u;%u;%u;%.3f;%.3f\n", | 578 | "%llu;%llu;%u;%u;%u;%u;%u;%u;%.3f;%u;%u;%llu;%u;%u;%u;%u;%.3f;%.3f\n", |
579 | (long long unsigned | 579 | (long long unsigned |
580 | int) cur_lt->timestamp.abs_value_us, | 580 | int) cur_lt->timestamp.abs_value_us, |
581 | (long long unsigned | 581 | (long long unsigned |
@@ -593,7 +593,7 @@ GNUNET_ATS_TEST_logging_write_to_file (struct LoggingHandle *l, | |||
593 | (double) plt->app_rtt / 1000, | 593 | (double) plt->app_rtt / 1000, |
594 | plt->bandwidth_in, | 594 | plt->bandwidth_in, |
595 | plt->bandwidth_out, | 595 | plt->bandwidth_out, |
596 | plt->ats_delay, | 596 | plt->ats_delay.rel_value_us, |
597 | plt->ats_distance, | 597 | plt->ats_distance, |
598 | plt->ats_network_type, | 598 | plt->ats_network_type, |
599 | plt->ats_utilization_out, | 599 | plt->ats_utilization_out, |
diff --git a/src/cadet/gnunet-service-cadet_channel.c b/src/cadet/gnunet-service-cadet_channel.c index dab53b8c4..ae6d21452 100644 --- a/src/cadet/gnunet-service-cadet_channel.c +++ b/src/cadet/gnunet-service-cadet_channel.c | |||
@@ -442,7 +442,7 @@ GCCH_2s (const struct CadetChannel *ch) | |||
442 | ? "loopback" | 442 | ? "loopback" |
443 | : GNUNET_i2s (GCP_get_id (GCT_get_destination (ch->t))), | 443 | : GNUNET_i2s (GCP_get_id (GCT_get_destination (ch->t))), |
444 | GNUNET_h2s (&ch->port), | 444 | GNUNET_h2s (&ch->port), |
445 | ch->ctn, | 445 | ch->ctn.cn, |
446 | (NULL == ch->owner) | 446 | (NULL == ch->owner) |
447 | ? 0 | 447 | ? 0 |
448 | : ntohl (ch->owner->ccn.channel_of_client), | 448 | : ntohl (ch->owner->ccn.channel_of_client), |
@@ -1899,10 +1899,10 @@ GCCH_handle_local_data (struct CadetChannel *ch, | |||
1899 | GNUNET_memcpy (&crm->data_message[1], buf, buf_len); | 1899 | GNUNET_memcpy (&crm->data_message[1], buf, buf_len); |
1900 | GNUNET_CONTAINER_DLL_insert_tail (ch->head_sent, ch->tail_sent, crm); | 1900 | GNUNET_CONTAINER_DLL_insert_tail (ch->head_sent, ch->tail_sent, crm); |
1901 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1901 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1902 | "Sending message %u from local client to %s with %u bytes\n", | 1902 | "Sending message %u from local client to %s with %lu bytes\n", |
1903 | ntohl (crm->data_message->mid.mid), | 1903 | ntohl (crm->data_message->mid.mid), |
1904 | GCCH_2s (ch), | 1904 | GCCH_2s (ch), |
1905 | buf_len); | 1905 | (unsigned long) buf_len); |
1906 | if (NULL != ch->retry_data_task) | 1906 | if (NULL != ch->retry_data_task) |
1907 | { | 1907 | { |
1908 | GNUNET_SCHEDULER_cancel (ch->retry_data_task); | 1908 | GNUNET_SCHEDULER_cancel (ch->retry_data_task); |
@@ -2044,7 +2044,7 @@ GCCH_debug (struct CadetChannel *ch, enum GNUNET_ErrorType level) | |||
2044 | LOG2 (level, "CHN *** DEBUG NULL CHANNEL ***\n"); | 2044 | LOG2 (level, "CHN *** DEBUG NULL CHANNEL ***\n"); |
2045 | return; | 2045 | return; |
2046 | } | 2046 | } |
2047 | LOG2 (level, "CHN %s:%X (%p)\n", GCT_2s (ch->t), ch->ctn, ch); | 2047 | LOG2 (level, "CHN %s:%X (%p)\n", GCT_2s (ch->t), ch->ctn.cn, ch); |
2048 | if (NULL != ch->owner) | 2048 | if (NULL != ch->owner) |
2049 | { | 2049 | { |
2050 | LOG2 (level, | 2050 | LOG2 (level, |
@@ -2062,7 +2062,7 @@ GCCH_debug (struct CadetChannel *ch, enum GNUNET_ErrorType level) | |||
2062 | ntohl (ch->dest->ccn.channel_of_client)); | 2062 | ntohl (ch->dest->ccn.channel_of_client)); |
2063 | } | 2063 | } |
2064 | LOG2 (level, | 2064 | LOG2 (level, |
2065 | "CHN Message IDs recv: %d (%LLX), send: %d\n", | 2065 | "CHN Message IDs recv: %d (%llX), send: %d\n", |
2066 | ntohl (ch->mid_recv.mid), | 2066 | ntohl (ch->mid_recv.mid), |
2067 | (unsigned long long) ch->mid_futures, | 2067 | (unsigned long long) ch->mid_futures, |
2068 | ntohl (ch->mid_send.mid)); | 2068 | ntohl (ch->mid_send.mid)); |
diff --git a/src/cadet/gnunet-service-cadet_core.c b/src/cadet/gnunet-service-cadet_core.c index 9a83fa31d..95a5d3f63 100644 --- a/src/cadet/gnunet-service-cadet_core.c +++ b/src/cadet/gnunet-service-cadet_core.c | |||
@@ -296,7 +296,7 @@ discard_all_from_rung_tail () | |||
296 | while (NULL != (dir = tail->rd_head)) | 296 | while (NULL != (dir = tail->rd_head)) |
297 | { | 297 | { |
298 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 298 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
299 | "Queue full due new message %s on connection %s, dropping old message\n", | 299 | "Queue full due new message on connection %s, dropping old message\n", |
300 | GNUNET_sh2s (&dir->my_route->cid.connection_of_tunnel)); | 300 | GNUNET_sh2s (&dir->my_route->cid.connection_of_tunnel)); |
301 | GNUNET_STATISTICS_update (stats, | 301 | GNUNET_STATISTICS_update (stats, |
302 | "# messages dropped due to full buffer", | 302 | "# messages dropped due to full buffer", |
@@ -408,7 +408,7 @@ route_message (struct CadetPeer *prev, | |||
408 | { | 408 | { |
409 | /* We are in the highest rung, drop our own! */ | 409 | /* We are in the highest rung, drop our own! */ |
410 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 410 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
411 | "Queue full due new message %s on connection %s, dropping old message\n", | 411 | "Queue full due new message on connection %s, dropping old message\n", |
412 | GNUNET_sh2s (&dir->my_route->cid.connection_of_tunnel)); | 412 | GNUNET_sh2s (&dir->my_route->cid.connection_of_tunnel)); |
413 | GNUNET_STATISTICS_update (stats, | 413 | GNUNET_STATISTICS_update (stats, |
414 | "# messages dropped due to full buffer", | 414 | "# messages dropped due to full buffer", |
diff --git a/src/cadet/gnunet-service-cadet_dht.c b/src/cadet/gnunet-service-cadet_dht.c index 4e8ccbb08..e1bbeb2c3 100644 --- a/src/cadet/gnunet-service-cadet_dht.c +++ b/src/cadet/gnunet-service-cadet_dht.c | |||
@@ -195,8 +195,8 @@ announce_id (void *cls) | |||
195 | &my_full_id, | 195 | &my_full_id, |
196 | sizeof(my_full_id)); | 196 | sizeof(my_full_id)); |
197 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 197 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
198 | "Announcing my HELLO (%u bytes) in the DHT\n", | 198 | "Announcing my HELLO (%lu bytes) in the DHT\n", |
199 | size); | 199 | (unsigned long) size); |
200 | GNUNET_DHT_put (dht_handle, /* DHT handle */ | 200 | GNUNET_DHT_put (dht_handle, /* DHT handle */ |
201 | &phash, /* Key to use */ | 201 | &phash, /* Key to use */ |
202 | dht_replication_level, /* Replication level */ | 202 | dht_replication_level, /* Replication level */ |
diff --git a/src/cadet/gnunet-service-cadet_tunnels.c b/src/cadet/gnunet-service-cadet_tunnels.c index 2ca46b5aa..78bc54a5c 100644 --- a/src/cadet/gnunet-service-cadet_tunnels.c +++ b/src/cadet/gnunet-service-cadet_tunnels.c | |||
@@ -2431,7 +2431,7 @@ connection_ready_cb (void *cls, | |||
2431 | { | 2431 | { |
2432 | case CADET_TUNNEL_KEY_UNINITIALIZED: | 2432 | case CADET_TUNNEL_KEY_UNINITIALIZED: |
2433 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 2433 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
2434 | "Do not begin KX for %s if WE have no channels waiting. Retrying after %d\n", | 2434 | "Do not begin KX for %s if WE have no channels waiting. Retrying after %llu\n", |
2435 | GCT_2s (t), | 2435 | GCT_2s (t), |
2436 | GNUNET_TIME_absolute_get_remaining (t->next_kx_attempt).rel_value_us); | 2436 | GNUNET_TIME_absolute_get_remaining (t->next_kx_attempt).rel_value_us); |
2437 | /* Do not begin KX if WE have no channels waiting! */ | 2437 | /* Do not begin KX if WE have no channels waiting! */ |
diff --git a/src/consensus/consensus_api.c b/src/consensus/consensus_api.c index 06b4c88ef..b4a9e5d39 100644 --- a/src/consensus/consensus_api.c +++ b/src/consensus/consensus_api.c | |||
@@ -280,7 +280,7 @@ GNUNET_CONSENSUS_insert (struct GNUNET_CONSENSUS_Handle *consensus, | |||
280 | struct GNUNET_MQ_Envelope *ev; | 280 | struct GNUNET_MQ_Envelope *ev; |
281 | struct InsertDoneInfo *i; | 281 | struct InsertDoneInfo *i; |
282 | 282 | ||
283 | LOG (GNUNET_ERROR_TYPE_DEBUG, "inserting, size=%llu\n", element->size); | 283 | LOG (GNUNET_ERROR_TYPE_DEBUG, "inserting, size=%u\n", element->size); |
284 | 284 | ||
285 | ev = GNUNET_MQ_msg_extra (element_msg, element->size, | 285 | ev = GNUNET_MQ_msg_extra (element_msg, element->size, |
286 | GNUNET_MESSAGE_TYPE_CONSENSUS_CLIENT_INSERT); | 286 | GNUNET_MESSAGE_TYPE_CONSENSUS_CLIENT_INSERT); |
diff --git a/src/conversation/Makefile.am b/src/conversation/Makefile.am index 7645b7973..0f99a6526 100644 --- a/src/conversation/Makefile.am +++ b/src/conversation/Makefile.am | |||
@@ -185,6 +185,7 @@ gnunet_service_conversation_LDADD = \ | |||
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/util/libgnunetutil.la \ |
188 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
188 | $(INTLLIBS) | 189 | $(INTLLIBS) |
189 | #gnunet_service_conversation_LDFLAGS = \ | 190 | #gnunet_service_conversation_LDFLAGS = \ |
190 | # | 191 | # |
diff --git a/src/conversation/conversation.h b/src/conversation/conversation.h index ed614ab1b..d244f5163 100644 --- a/src/conversation/conversation.h +++ b/src/conversation/conversation.h | |||
@@ -27,6 +27,8 @@ | |||
27 | #ifndef CONVERSATION_H | 27 | #ifndef CONVERSATION_H |
28 | #define CONVERSATION_H | 28 | #define CONVERSATION_H |
29 | 29 | ||
30 | #include "gnunet_identity_service.h" | ||
31 | |||
30 | #ifdef __cplusplus | 32 | #ifdef __cplusplus |
31 | extern "C" | 33 | extern "C" |
32 | { | 34 | { |
@@ -105,7 +107,7 @@ struct ClientPhoneRingMessage | |||
105 | /** | 107 | /** |
106 | * Who is calling us? | 108 | * Who is calling us? |
107 | */ | 109 | */ |
108 | struct GNUNET_CRYPTO_EcdsaPublicKey caller_id; | 110 | struct GNUNET_IDENTITY_PublicKey caller_id; |
109 | }; | 111 | }; |
110 | 112 | ||
111 | 113 | ||
@@ -230,7 +232,7 @@ struct ClientCallMessage | |||
230 | /** | 232 | /** |
231 | * Identity of the caller. | 233 | * Identity of the caller. |
232 | */ | 234 | */ |
233 | struct GNUNET_CRYPTO_EcdsaPrivateKey caller_id; | 235 | struct GNUNET_IDENTITY_PrivateKey caller_id; |
234 | }; | 236 | }; |
235 | 237 | ||
236 | 238 | ||
@@ -301,7 +303,7 @@ struct CadetPhoneRingMessage | |||
301 | /** | 303 | /** |
302 | * Who is calling us? (also who is signing). | 304 | * Who is calling us? (also who is signing). |
303 | */ | 305 | */ |
304 | struct GNUNET_CRYPTO_EcdsaPublicKey caller_id; | 306 | struct GNUNET_IDENTITY_PublicKey caller_id; |
305 | 307 | ||
306 | /** | 308 | /** |
307 | * When does the signature expire? | 309 | * When does the signature expire? |
@@ -311,7 +313,7 @@ struct CadetPhoneRingMessage | |||
311 | /** | 313 | /** |
312 | * Signature over a `struct CadetPhoneRingInfoPS` | 314 | * Signature over a `struct CadetPhoneRingInfoPS` |
313 | */ | 315 | */ |
314 | struct GNUNET_CRYPTO_EcdsaSignature signature; | 316 | struct GNUNET_IDENTITY_Signature signature; |
315 | }; | 317 | }; |
316 | 318 | ||
317 | 319 | ||
diff --git a/src/conversation/conversation_api.c b/src/conversation/conversation_api.c index daf51042a..88fe8f11c 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_CRYPTO_EcdsaPublicKey caller_id; | 108 | struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey my_zone; | 195 | struct GNUNET_IDENTITY_PrivateKey my_zone; |
196 | 196 | ||
197 | /** | 197 | /** |
198 | * State machine for the phone. | 198 | * State machine for the phone. |
diff --git a/src/conversation/gnunet-conversation.c b/src/conversation/gnunet-conversation.c index 7a2a727a5..9ff0002e7 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_CRYPTO_EcdsaPublicKey caller_id; | 119 | struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPublicKey peer_key; | 197 | static struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPublicKey *caller_id) | 247 | const struct GNUNET_IDENTITY_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 502146255..a69c95a80 100644 --- a/src/conversation/gnunet-service-conversation.c +++ b/src/conversation/gnunet-service-conversation.c | |||
@@ -752,10 +752,11 @@ handle_cadet_ring_message (void *cls, const struct CadetPhoneRingMessage *msg) | |||
752 | rs.expiration_time = msg->expiration_time; | 752 | rs.expiration_time = msg->expiration_time; |
753 | 753 | ||
754 | if (GNUNET_OK != | 754 | if (GNUNET_OK != |
755 | GNUNET_CRYPTO_ecdsa_verify (GNUNET_SIGNATURE_PURPOSE_CONVERSATION_RING, | 755 | GNUNET_IDENTITY_signature_verify ( |
756 | &rs, | 756 | GNUNET_SIGNATURE_PURPOSE_CONVERSATION_RING, |
757 | &msg->signature, | 757 | &rs, |
758 | &msg->caller_id)) | 758 | &msg->signature, |
759 | &msg->caller_id)) | ||
759 | { | 760 | { |
760 | GNUNET_break_op (0); | 761 | GNUNET_break_op (0); |
761 | destroy_line_cadet_channels (ch); | 762 | destroy_line_cadet_channels (ch); |
@@ -1136,11 +1137,9 @@ handle_client_call_message (void *cls, const struct ClientCallMessage *msg) | |||
1136 | cadet_handlers); | 1137 | cadet_handlers); |
1137 | ch->mq = GNUNET_CADET_get_mq (ch->channel); | 1138 | ch->mq = GNUNET_CADET_get_mq (ch->channel); |
1138 | e = GNUNET_MQ_msg (ring, GNUNET_MESSAGE_TYPE_CONVERSATION_CADET_PHONE_RING); | 1139 | e = GNUNET_MQ_msg (ring, GNUNET_MESSAGE_TYPE_CONVERSATION_CADET_PHONE_RING); |
1139 | GNUNET_CRYPTO_ecdsa_key_get_public (&msg->caller_id, &ring->caller_id); | 1140 | GNUNET_IDENTITY_key_get_public (&msg->caller_id, &ring->caller_id); |
1140 | ring->expiration_time = rs.expiration_time; | 1141 | ring->expiration_time = rs.expiration_time; |
1141 | GNUNET_CRYPTO_ecdsa_sign (&msg->caller_id, | 1142 | GNUNET_IDENTITY_sign (&msg->caller_id, &rs, &ring->signature); |
1142 | &rs, | ||
1143 | &ring->signature); | ||
1144 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Sending RING message via CADET\n"); | 1143 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Sending RING message via CADET\n"); |
1145 | GNUNET_MQ_send (ch->mq, e); | 1144 | GNUNET_MQ_send (ch->mq, e); |
1146 | GNUNET_SERVICE_client_continue (line->client); | 1145 | GNUNET_SERVICE_client_continue (line->client); |
diff --git a/src/conversation/test_conversation_api.c b/src/conversation/test_conversation_api.c index b51186dc8..c5efecd52 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_CRYPTO_EcdsaPublicKey *caller_id) | 308 | const struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey *pk, | 388 | const struct GNUNET_IDENTITY_PrivateKey *pk, |
389 | const char *emsg) | 389 | const char *emsg) |
390 | { | 390 | { |
391 | (void) cls; | 391 | (void) cls; |
@@ -414,7 +414,7 @@ identity_cb (void *cls, | |||
414 | const char *name) | 414 | const char *name) |
415 | { | 415 | { |
416 | struct GNUNET_GNSRECORD_Data rd; | 416 | struct GNUNET_GNSRECORD_Data rd; |
417 | struct GNUNET_CRYPTO_EcdsaPublicKey pub; | 417 | struct GNUNET_IDENTITY_PublicKey pub; |
418 | 418 | ||
419 | (void) cls; | 419 | (void) cls; |
420 | (void) ctx; | 420 | (void) ctx; |
@@ -465,7 +465,7 @@ identity_cb (void *cls, | |||
465 | 465 | ||
466 | static void | 466 | static void |
467 | phone_ego_create_cont (void *cls, | 467 | phone_ego_create_cont (void *cls, |
468 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pk, | 468 | const struct GNUNET_IDENTITY_PrivateKey *pk, |
469 | const char *emsg) | 469 | const char *emsg) |
470 | { | 470 | { |
471 | (void) cls; | 471 | (void) cls; |
diff --git a/src/conversation/test_conversation_api_reject.c b/src/conversation/test_conversation_api_reject.c index 69fa9f1dc..08c64df37 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_CRYPTO_EcdsaPublicKey *caller_id) | 182 | const struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey *pk, | 241 | const struct GNUNET_IDENTITY_PrivateKey *pk, |
242 | const char *emsg) | 242 | const char *emsg) |
243 | { | 243 | { |
244 | (void) cls; | 244 | (void) cls; |
@@ -267,7 +267,7 @@ identity_cb (void *cls, | |||
267 | const char *name) | 267 | const char *name) |
268 | { | 268 | { |
269 | struct GNUNET_GNSRECORD_Data rd; | 269 | struct GNUNET_GNSRECORD_Data rd; |
270 | struct GNUNET_CRYPTO_EcdsaPublicKey pub; | 270 | struct GNUNET_IDENTITY_PublicKey pub; |
271 | 271 | ||
272 | (void) cls; | 272 | (void) cls; |
273 | (void) ctx; | 273 | (void) ctx; |
@@ -318,7 +318,7 @@ identity_cb (void *cls, | |||
318 | 318 | ||
319 | static void | 319 | static void |
320 | phone_ego_create_cont (void *cls, | 320 | phone_ego_create_cont (void *cls, |
321 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pk, | 321 | const struct GNUNET_IDENTITY_PrivateKey *pk, |
322 | const char *emsg) | 322 | const char *emsg) |
323 | { | 323 | { |
324 | (void) cls; | 324 | (void) cls; |
diff --git a/src/conversation/test_conversation_api_twocalls.c b/src/conversation/test_conversation_api_twocalls.c index 83e8cb55a..ac7a3c9dd 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_CRYPTO_EcdsaPublicKey *caller_id) | 406 | const struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey *pk, | 510 | const struct GNUNET_IDENTITY_PrivateKey *pk, |
511 | const char *emsg) | 511 | const char *emsg) |
512 | { | 512 | { |
513 | (void) cls; | 513 | (void) cls; |
@@ -536,7 +536,7 @@ identity_cb (void *cls, | |||
536 | const char *name) | 536 | const char *name) |
537 | { | 537 | { |
538 | struct GNUNET_GNSRECORD_Data rd; | 538 | struct GNUNET_GNSRECORD_Data rd; |
539 | struct GNUNET_CRYPTO_EcdsaPublicKey pub; | 539 | struct GNUNET_IDENTITY_PublicKey pub; |
540 | 540 | ||
541 | (void) cls; | 541 | (void) cls; |
542 | (void) ctx; | 542 | (void) ctx; |
@@ -594,7 +594,7 @@ identity_cb (void *cls, | |||
594 | 594 | ||
595 | static void | 595 | static void |
596 | phone_ego_create_cont (void *cls, | 596 | phone_ego_create_cont (void *cls, |
597 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pk, | 597 | const struct GNUNET_IDENTITY_PrivateKey *pk, |
598 | const char *emsg) | 598 | const char *emsg) |
599 | { | 599 | { |
600 | (void) cls; | 600 | (void) cls; |
diff --git a/src/datacache/plugin_datacache_postgres.c b/src/datacache/plugin_datacache_postgres.c index c21be9219..724324ca4 100644 --- a/src/datacache/plugin_datacache_postgres.c +++ b/src/datacache/plugin_datacache_postgres.c | |||
@@ -67,14 +67,19 @@ static int | |||
67 | init_connection (struct Plugin *plugin) | 67 | init_connection (struct Plugin *plugin) |
68 | { | 68 | { |
69 | struct GNUNET_PQ_ExecuteStatement es[] = { | 69 | struct GNUNET_PQ_ExecuteStatement es[] = { |
70 | GNUNET_PQ_make_try_execute ("CREATE TEMPORARY SEQUENCE IF NOT EXISTS gn011dc_oid_seq"), | ||
70 | GNUNET_PQ_make_execute ("CREATE TEMPORARY TABLE IF NOT EXISTS gn011dc (" | 71 | GNUNET_PQ_make_execute ("CREATE TEMPORARY TABLE IF NOT EXISTS gn011dc (" |
72 | " oid OID NOT NULL DEFAULT nextval('gn011dc_oid_seq')," | ||
71 | " type INTEGER NOT NULL," | 73 | " type INTEGER NOT NULL," |
72 | " prox INTEGER NOT NULL," | 74 | " prox INTEGER NOT NULL," |
73 | " discard_time BIGINT NOT NULL," | 75 | " discard_time BIGINT NOT NULL," |
74 | " key BYTEA NOT NULL," | 76 | " key BYTEA NOT NULL," |
75 | " value BYTEA NOT NULL," | 77 | " value BYTEA NOT NULL," |
76 | " path BYTEA DEFAULT NULL)" | 78 | " path BYTEA DEFAULT NULL)"), |
77 | "WITH OIDS"), | 79 | GNUNET_PQ_make_try_execute ( |
80 | "ALTER SEQUENCE gnu011dc_oid_seq OWNED BY gn011dc.oid"), | ||
81 | GNUNET_PQ_make_try_execute ( | ||
82 | "CREATE INDEX IF NOT EXISTS idx_oid ON gn011dc (oid)"), | ||
78 | GNUNET_PQ_make_try_execute ( | 83 | GNUNET_PQ_make_try_execute ( |
79 | "CREATE INDEX IF NOT EXISTS idx_key ON gn011dc (key)"), | 84 | "CREATE INDEX IF NOT EXISTS idx_key ON gn011dc (key)"), |
80 | GNUNET_PQ_make_try_execute ( | 85 | GNUNET_PQ_make_try_execute ( |
diff --git a/src/datastore/datastore_api.c b/src/datastore/datastore_api.c index 4537f6efe..bd7a612ed 100644 --- a/src/datastore/datastore_api.c +++ b/src/datastore/datastore_api.c | |||
@@ -994,8 +994,8 @@ GNUNET_DATASTORE_put (struct GNUNET_DATASTORE_Handle *h, | |||
994 | } | 994 | } |
995 | 995 | ||
996 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 996 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
997 | "Asked to put %u bytes of data under key `%s' for %s\n", | 997 | "Asked to put %lu bytes of data under key `%s' for %s\n", |
998 | size, | 998 | (unsigned long) size, |
999 | GNUNET_h2s (key), | 999 | GNUNET_h2s (key), |
1000 | GNUNET_STRINGS_relative_time_to_string ( | 1000 | GNUNET_STRINGS_relative_time_to_string ( |
1001 | GNUNET_TIME_absolute_get_remaining (expiration), | 1001 | GNUNET_TIME_absolute_get_remaining (expiration), |
@@ -1205,8 +1205,8 @@ GNUNET_DATASTORE_remove (struct GNUNET_DATASTORE_Handle *h, | |||
1205 | if (NULL == cont) | 1205 | if (NULL == cont) |
1206 | cont = &drop_status_cont; | 1206 | cont = &drop_status_cont; |
1207 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1207 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1208 | "Asked to remove %u bytes under key `%s'\n", | 1208 | "Asked to remove %lu bytes under key `%s'\n", |
1209 | size, | 1209 | (unsigned long) size, |
1210 | GNUNET_h2s (key)); | 1210 | GNUNET_h2s (key)); |
1211 | env = GNUNET_MQ_msg_extra (dm, | 1211 | env = GNUNET_MQ_msg_extra (dm, |
1212 | size, | 1212 | size, |
diff --git a/src/datastore/plugin_datastore_postgres.c b/src/datastore/plugin_datastore_postgres.c index 88ceb1b0a..6a5d45832 100644 --- a/src/datastore/plugin_datastore_postgres.c +++ b/src/datastore/plugin_datastore_postgres.c | |||
@@ -72,8 +72,10 @@ init_connection (struct Plugin *plugin) | |||
72 | * we only test equality on it and can cast it to/from uint32_t. For repl, prio, and anonLevel | 72 | * we only test equality on it and can cast it to/from uint32_t. For repl, prio, and anonLevel |
73 | * we do math or inequality tests, so we can't handle the entire range of uint32_t. | 73 | * we do math or inequality tests, so we can't handle the entire range of uint32_t. |
74 | * This will also cause problems for expiration times after 294247-01-10-04:00:54 UTC. | 74 | * This will also cause problems for expiration times after 294247-01-10-04:00:54 UTC. |
75 | * PostgreSQL also recommends against using WITH OIDS. | 75 | */ |
76 | */GNUNET_PQ_make_execute ("CREATE TABLE IF NOT EXISTS gn090 (" | 76 | GNUNET_PQ_make_try_execute ( |
77 | "CREATE SEQUENCE IF NOT EXISTS gn090_oid_seq"), | ||
78 | GNUNET_PQ_make_execute ("CREATE TABLE IF NOT EXISTS gn090 (" | ||
77 | " repl INTEGER NOT NULL DEFAULT 0," | 79 | " repl INTEGER NOT NULL DEFAULT 0," |
78 | " type INTEGER NOT NULL DEFAULT 0," | 80 | " type INTEGER NOT NULL DEFAULT 0," |
79 | " prio INTEGER NOT NULL DEFAULT 0," | 81 | " prio INTEGER NOT NULL DEFAULT 0," |
@@ -82,8 +84,12 @@ init_connection (struct Plugin *plugin) | |||
82 | " rvalue BIGINT NOT NULL DEFAULT 0," | 84 | " rvalue BIGINT NOT NULL DEFAULT 0," |
83 | " hash BYTEA NOT NULL DEFAULT ''," | 85 | " hash BYTEA NOT NULL DEFAULT ''," |
84 | " vhash BYTEA NOT NULL DEFAULT ''," | 86 | " vhash BYTEA NOT NULL DEFAULT ''," |
85 | " value BYTEA NOT NULL DEFAULT '')" | 87 | " value BYTEA NOT NULL DEFAULT ''," |
86 | "WITH OIDS"), | 88 | " oid OID NOT NULL DEFAULT nextval('gn090_oid_seq'))"), |
89 | GNUNET_PQ_make_try_execute ( | ||
90 | "ALTER SEQUENCE gn090_oid_seq OWNED BY gn090.oid"), | ||
91 | GNUNET_PQ_make_try_execute ( | ||
92 | "CREATE INDEX IF NOT EXISTS oid_hash ON gn090 (oid)"), | ||
87 | GNUNET_PQ_make_try_execute ( | 93 | GNUNET_PQ_make_try_execute ( |
88 | "CREATE INDEX IF NOT EXISTS idx_hash ON gn090 (hash)"), | 94 | "CREATE INDEX IF NOT EXISTS idx_hash ON gn090 (hash)"), |
89 | GNUNET_PQ_make_try_execute ( | 95 | GNUNET_PQ_make_try_execute ( |
diff --git a/src/dht/gnunet-service-dht_clients.c b/src/dht/gnunet-service-dht_clients.c index 1e44c1fad..5eb3115f4 100644 --- a/src/dht/gnunet-service-dht_clients.c +++ b/src/dht/gnunet-service-dht_clients.c | |||
@@ -488,8 +488,8 @@ handle_dht_local_put (void *cls, | |||
488 | GNUNET_h2s_full (&dht_msg->key)); | 488 | GNUNET_h2s_full (&dht_msg->key)); |
489 | /* give to local clients */ | 489 | /* give to local clients */ |
490 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 490 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
491 | "Handling local PUT of %u-bytes for query %s\n", | 491 | "Handling local PUT of %lu-bytes for query %s\n", |
492 | size - sizeof(struct GNUNET_DHT_ClientPutMessage), | 492 | (unsigned long) (size - sizeof(struct GNUNET_DHT_ClientPutMessage)), |
493 | GNUNET_h2s (&dht_msg->key)); | 493 | GNUNET_h2s (&dht_msg->key)); |
494 | GDS_CLIENTS_handle_reply (GNUNET_TIME_absolute_ntoh (dht_msg->expiration), | 494 | GDS_CLIENTS_handle_reply (GNUNET_TIME_absolute_ntoh (dht_msg->expiration), |
495 | &dht_msg->key, | 495 | &dht_msg->key, |
@@ -619,7 +619,7 @@ handle_dht_local_get (void *cls, | |||
619 | "Received GET request for %s from local client %p, xq: %.*s\n", | 619 | "Received GET request for %s from local client %p, xq: %.*s\n", |
620 | GNUNET_h2s (&get->key), | 620 | GNUNET_h2s (&get->key), |
621 | ch->client, | 621 | ch->client, |
622 | xquery_size, | 622 | (int) xquery_size, |
623 | xquery); | 623 | xquery); |
624 | LOG_TRAFFIC (GNUNET_ERROR_TYPE_DEBUG, | 624 | LOG_TRAFFIC (GNUNET_ERROR_TYPE_DEBUG, |
625 | "CLIENT-GET %s\n", | 625 | "CLIENT-GET %s\n", |
diff --git a/src/dht/gnunet-service-dht_datacache.c b/src/dht/gnunet-service-dht_datacache.c index 41b7a3a2b..7eded2152 100644 --- a/src/dht/gnunet-service-dht_datacache.c +++ b/src/dht/gnunet-service-dht_datacache.c | |||
@@ -94,9 +94,9 @@ GDS_DATACACHE_handle_put (struct GNUNET_TIME_Absolute expiration, | |||
94 | put_path_length, | 94 | put_path_length, |
95 | put_path); | 95 | put_path); |
96 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 96 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
97 | "DATACACHE PUT for key %s [%u] completed (%d) after %u hops\n", | 97 | "DATACACHE PUT for key %s [%lu] completed (%d) after %u hops\n", |
98 | GNUNET_h2s (key), | 98 | GNUNET_h2s (key), |
99 | data_size, | 99 | (unsigned long) data_size, |
100 | r, | 100 | r, |
101 | put_path_length); | 101 | put_path_length); |
102 | } | 102 | } |
diff --git a/src/dht/gnunet-service-dht_neighbours.c b/src/dht/gnunet-service-dht_neighbours.c index b211fca6b..88b0c5d92 100644 --- a/src/dht/gnunet-service-dht_neighbours.c +++ b/src/dht/gnunet-service-dht_neighbours.c | |||
@@ -2212,8 +2212,8 @@ handle_dht_p2p_get (void *cls, | |||
2212 | bg, | 2212 | bg, |
2213 | peer_bf); | 2213 | peer_bf); |
2214 | GDS_CLIENTS_process_get (options | 2214 | GDS_CLIENTS_process_get (options |
2215 | | (GNUNET_OK == forwarded) | 2215 | | ((GNUNET_OK == forwarded) |
2216 | ? GNUNET_DHT_RO_LAST_HOP : 0, | 2216 | ? GNUNET_DHT_RO_LAST_HOP : 0), |
2217 | type, | 2217 | type, |
2218 | ntohl (get->hop_count), | 2218 | ntohl (get->hop_count), |
2219 | ntohl (get->desired_replication_level), | 2219 | ntohl (get->desired_replication_level), |
diff --git a/src/dht/plugin_block_dht.c b/src/dht/plugin_block_dht.c index f213433ed..a9f336240 100644 --- a/src/dht/plugin_block_dht.c +++ b/src/dht/plugin_block_dht.c | |||
@@ -195,7 +195,7 @@ block_plugin_dht_get_key (void *cls, | |||
195 | { | 195 | { |
196 | GNUNET_log_from (GNUNET_ERROR_TYPE_ERROR, | 196 | GNUNET_log_from (GNUNET_ERROR_TYPE_ERROR, |
197 | "block-dht", | 197 | "block-dht", |
198 | _ ("Size mismatch for block\n"), | 198 | _ ("Size mismatch for block with type %u\n"), |
199 | GNUNET_BLOCK_TYPE_DHT_HELLO); | 199 | GNUNET_BLOCK_TYPE_DHT_HELLO); |
200 | return GNUNET_NO; | 200 | return GNUNET_NO; |
201 | } | 201 | } |
diff --git a/src/dns/gnunet-dns-monitor.c b/src/dns/gnunet-dns-monitor.c index d9830baa4..836d65c79 100644 --- a/src/dns/gnunet-dns-monitor.c +++ b/src/dns/gnunet-dns-monitor.c | |||
@@ -203,7 +203,7 @@ display_record (const struct GNUNET_DNSPARSER_Record *record) | |||
203 | else | 203 | else |
204 | { | 204 | { |
205 | GNUNET_asprintf (&tmp, | 205 | GNUNET_asprintf (&tmp, |
206 | "priority %u, weight = %s, port = %u, target = %s", | 206 | "priority %u, weight = %u, port = %u, target = %s", |
207 | (unsigned int) record->data.srv->priority, | 207 | (unsigned int) record->data.srv->priority, |
208 | (unsigned int) record->data.srv->weight, | 208 | (unsigned int) record->data.srv->weight, |
209 | (unsigned int) record->data.srv->port, | 209 | (unsigned int) record->data.srv->port, |
diff --git a/src/fragmentation/fragmentation.c b/src/fragmentation/fragmentation.c index 3a7da37e8..36e1c33f4 100644 --- a/src/fragmentation/fragmentation.c +++ b/src/fragmentation/fragmentation.c | |||
@@ -158,7 +158,7 @@ GNUNET_FRAGMENT_print_ack (const struct GNUNET_MessageHeader *ack) | |||
158 | sizeof(buf), | 158 | sizeof(buf), |
159 | "%u-%llX", | 159 | "%u-%llX", |
160 | ntohl (fa->fragment_id), | 160 | ntohl (fa->fragment_id), |
161 | GNUNET_ntohll (fa->bits)); | 161 | (unsigned long long) GNUNET_ntohll (fa->bits)); |
162 | return buf; | 162 | return buf; |
163 | } | 163 | } |
164 | 164 | ||
diff --git a/src/fs/fs_download.c b/src/fs/fs_download.c index 6154e8be0..d4677b794 100644 --- a/src/fs/fs_download.c +++ b/src/fs/fs_download.c | |||
@@ -1050,7 +1050,7 @@ process_result_with_request (void *cls, | |||
1050 | GNUNET_asprintf ( | 1050 | GNUNET_asprintf ( |
1051 | &dc->emsg, | 1051 | &dc->emsg, |
1052 | _ ( | 1052 | _ ( |
1053 | "Internal error or bogus download URI (expected %u bytes at depth %u and offset %llu/%llu, got %u bytes)"), | 1053 | "Internal error or bogus download URI (expected %lu bytes at depth %u and offset %llu/%llu, got %lu bytes)"), |
1054 | bs, | 1054 | bs, |
1055 | dr->depth, | 1055 | dr->depth, |
1056 | (unsigned long long) dr->offset, | 1056 | (unsigned long long) dr->offset, |
diff --git a/src/fs/gnunet-daemon-fsprofiler.c b/src/fs/gnunet-daemon-fsprofiler.c index 829906461..fbb7c6028 100644 --- a/src/fs/gnunet-daemon-fsprofiler.c +++ b/src/fs/gnunet-daemon-fsprofiler.c | |||
@@ -592,14 +592,14 @@ run (void *cls, char *const *args GNUNET_UNUSED, | |||
592 | &replication_level)) | 592 | &replication_level)) |
593 | replication_level = 1; | 593 | replication_level = 1; |
594 | GNUNET_snprintf (myoptname, sizeof(myoptname), | 594 | GNUNET_snprintf (myoptname, sizeof(myoptname), |
595 | "DOWNLOAD-PATTERN-%u", my_peerid); | 595 | "DOWNLOAD-PATTERN-%llu", my_peerid); |
596 | if (GNUNET_OK != | 596 | if (GNUNET_OK != |
597 | GNUNET_CONFIGURATION_get_value_string (cfg, | 597 | GNUNET_CONFIGURATION_get_value_string (cfg, |
598 | "FSPROFILER", myoptname, | 598 | "FSPROFILER", myoptname, |
599 | &download_pattern)) | 599 | &download_pattern)) |
600 | download_pattern = GNUNET_strdup (""); | 600 | download_pattern = GNUNET_strdup (""); |
601 | GNUNET_snprintf (myoptname, sizeof(myoptname), | 601 | GNUNET_snprintf (myoptname, sizeof(myoptname), |
602 | "PUBLISH-PATTERN-%u", my_peerid); | 602 | "PUBLISH-PATTERN-%llu", my_peerid); |
603 | if (GNUNET_OK != | 603 | if (GNUNET_OK != |
604 | GNUNET_CONFIGURATION_get_value_string (cfg, | 604 | GNUNET_CONFIGURATION_get_value_string (cfg, |
605 | "FSPROFILER", myoptname, | 605 | "FSPROFILER", myoptname, |
diff --git a/src/fs/gnunet-publish.c b/src/fs/gnunet-publish.c index 91fcd8f8a..dea467669 100644 --- a/src/fs/gnunet-publish.c +++ b/src/fs/gnunet-publish.c | |||
@@ -475,6 +475,7 @@ uri_ksk_continuation (void *cls, | |||
475 | const char *emsg) | 475 | const char *emsg) |
476 | { | 476 | { |
477 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *priv; | 477 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *priv; |
478 | const struct GNUNET_IDENTITY_PrivateKey *pk; | ||
478 | 479 | ||
479 | if (NULL != emsg) | 480 | if (NULL != emsg) |
480 | { | 481 | { |
@@ -486,7 +487,10 @@ uri_ksk_continuation (void *cls, | |||
486 | GNUNET_SCHEDULER_shutdown (); | 487 | GNUNET_SCHEDULER_shutdown (); |
487 | return; | 488 | return; |
488 | } | 489 | } |
489 | priv = GNUNET_IDENTITY_ego_get_private_key (namespace); | 490 | pk = GNUNET_IDENTITY_ego_get_private_key (namespace); |
491 | if (GNUNET_IDENTITY_TYPE_ECDSA != ntohl (pk->type)) | ||
492 | return; | ||
493 | priv = &pk->ecdsa_key; | ||
490 | GNUNET_FS_publish_sks (ctx, | 494 | GNUNET_FS_publish_sks (ctx, |
491 | priv, | 495 | priv, |
492 | this_id, | 496 | this_id, |
@@ -569,6 +573,7 @@ directory_trim_complete (struct GNUNET_FS_ShareTreeItem *directory_scan_result) | |||
569 | { | 573 | { |
570 | struct GNUNET_FS_FileInformation *fi; | 574 | struct GNUNET_FS_FileInformation *fi; |
571 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *priv; | 575 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *priv; |
576 | const struct GNUNET_IDENTITY_PrivateKey *pk; | ||
572 | 577 | ||
573 | fi = get_file_information (directory_scan_result); | 578 | fi = get_file_information (directory_scan_result); |
574 | GNUNET_FS_share_tree_free (directory_scan_result); | 579 | GNUNET_FS_share_tree_free (directory_scan_result); |
@@ -586,10 +591,13 @@ directory_trim_complete (struct GNUNET_FS_ShareTreeItem *directory_scan_result) | |||
586 | GNUNET_SCHEDULER_shutdown (); | 591 | GNUNET_SCHEDULER_shutdown (); |
587 | return; | 592 | return; |
588 | } | 593 | } |
589 | if (NULL == namespace) | 594 | priv = NULL; |
590 | priv = NULL; | 595 | if (NULL != namespace) |
591 | else | 596 | { |
592 | priv = GNUNET_IDENTITY_ego_get_private_key (namespace); | 597 | pk = GNUNET_IDENTITY_ego_get_private_key (namespace); |
598 | GNUNET_assert (GNUNET_IDENTITY_TYPE_ECDSA == ntohl (pk->type)); | ||
599 | priv = &pk->ecdsa_key; | ||
600 | } | ||
593 | pc = GNUNET_FS_publish_start (ctx, | 601 | pc = GNUNET_FS_publish_start (ctx, |
594 | fi, | 602 | fi, |
595 | priv, | 603 | priv, |
diff --git a/src/gns/Makefile.am b/src/gns/Makefile.am index 5a9c70997..744ba66ec 100644 --- a/src/gns/Makefile.am +++ b/src/gns/Makefile.am | |||
@@ -109,6 +109,7 @@ libgnunet_plugin_rest_gns_la_SOURCES = \ | |||
109 | plugin_rest_gns.c | 109 | plugin_rest_gns.c |
110 | libgnunet_plugin_rest_gns_la_LIBADD = \ | 110 | libgnunet_plugin_rest_gns_la_LIBADD = \ |
111 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 111 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
112 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecordjson.la \ | ||
112 | libgnunetgns.la \ | 113 | libgnunetgns.la \ |
113 | $(top_builddir)/src/rest/libgnunetrest.la \ | 114 | $(top_builddir)/src/rest/libgnunetrest.la \ |
114 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 115 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
@@ -124,6 +125,7 @@ libgnunet_plugin_gnsrecord_gns_la_SOURCES = \ | |||
124 | plugin_gnsrecord_gns.c | 125 | plugin_gnsrecord_gns.c |
125 | libgnunet_plugin_gnsrecord_gns_la_LIBADD = \ | 126 | libgnunet_plugin_gnsrecord_gns_la_LIBADD = \ |
126 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 127 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
128 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
127 | $(top_builddir)/src/util/libgnunetutil.la \ | 129 | $(top_builddir)/src/util/libgnunetutil.la \ |
128 | $(LTLIBINTL) | 130 | $(LTLIBINTL) |
129 | libgnunet_plugin_gnsrecord_gns_la_LDFLAGS = \ | 131 | libgnunet_plugin_gnsrecord_gns_la_LDFLAGS = \ |
@@ -135,6 +137,7 @@ gnunet_gns_SOURCES = \ | |||
135 | gnunet_gns_LDADD = \ | 137 | gnunet_gns_LDADD = \ |
136 | libgnunetgns.la \ | 138 | libgnunetgns.la \ |
137 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 139 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
140 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
138 | $(top_builddir)/src/util/libgnunetutil.la \ | 141 | $(top_builddir)/src/util/libgnunetutil.la \ |
139 | $(LIBIDN) $(LIBIDN2) \ | 142 | $(LIBIDN) $(LIBIDN2) \ |
140 | $(GN_LIBINTL) | 143 | $(GN_LIBINTL) |
@@ -144,6 +147,7 @@ gnunet_gns_benchmark_SOURCES = \ | |||
144 | gnunet_gns_benchmark_LDADD = \ | 147 | gnunet_gns_benchmark_LDADD = \ |
145 | libgnunetgns.la \ | 148 | libgnunetgns.la \ |
146 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 149 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
150 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
147 | $(top_builddir)/src/util/libgnunetutil.la \ | 151 | $(top_builddir)/src/util/libgnunetutil.la \ |
148 | $(GN_LIBINTL) | 152 | $(GN_LIBINTL) |
149 | 153 | ||
@@ -247,6 +251,7 @@ libgnunet_plugin_block_gns_la_LIBADD = \ | |||
247 | $(top_builddir)/src/util/libgnunetutil.la \ | 251 | $(top_builddir)/src/util/libgnunetutil.la \ |
248 | $(top_builddir)/src/block/libgnunetblock.la \ | 252 | $(top_builddir)/src/block/libgnunetblock.la \ |
249 | $(top_builddir)/src/block/libgnunetblockgroup.la \ | 253 | $(top_builddir)/src/block/libgnunetblockgroup.la \ |
254 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
250 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la | 255 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la |
251 | libgnunet_plugin_block_gns_la_LDFLAGS = \ | 256 | libgnunet_plugin_block_gns_la_LDFLAGS = \ |
252 | $(GN_LIBINTL) \ | 257 | $(GN_LIBINTL) \ |
diff --git a/src/gns/gns.h b/src/gns/gns.h index a193632b7..d824742ad 100644 --- a/src/gns/gns.h +++ b/src/gns/gns.h | |||
@@ -48,7 +48,7 @@ struct LookupMessage | |||
48 | /** | 48 | /** |
49 | * Zone that is to be used for lookup | 49 | * Zone that is to be used for lookup |
50 | */ | 50 | */ |
51 | struct GNUNET_CRYPTO_EcdsaPublicKey zone; | 51 | struct GNUNET_IDENTITY_PublicKey zone; |
52 | 52 | ||
53 | /** | 53 | /** |
54 | * Local options for where to look for results | 54 | * Local options for where to look for results |
diff --git a/src/gns/gns_api.c b/src/gns/gns_api.c index bf95bf340..841a0d240 100644 --- a/src/gns/gns_api.c +++ b/src/gns/gns_api.c | |||
@@ -343,7 +343,7 @@ GNUNET_GNS_lookup_cancel (struct GNUNET_GNS_LookupRequest *lr) | |||
343 | struct GNUNET_GNS_LookupRequest * | 343 | struct GNUNET_GNS_LookupRequest * |
344 | GNUNET_GNS_lookup_limited (struct GNUNET_GNS_Handle *handle, | 344 | GNUNET_GNS_lookup_limited (struct GNUNET_GNS_Handle *handle, |
345 | const char *name, | 345 | const char *name, |
346 | const struct GNUNET_CRYPTO_EcdsaPublicKey *zone, | 346 | const struct GNUNET_IDENTITY_PublicKey *zone, |
347 | uint32_t type, | 347 | uint32_t type, |
348 | enum GNUNET_GNS_LocalOptions options, | 348 | enum GNUNET_GNS_LocalOptions options, |
349 | uint16_t recursion_depth_limit, | 349 | uint16_t recursion_depth_limit, |
@@ -411,7 +411,7 @@ GNUNET_GNS_lookup_limited (struct GNUNET_GNS_Handle *handle, | |||
411 | struct GNUNET_GNS_LookupRequest* | 411 | struct GNUNET_GNS_LookupRequest* |
412 | GNUNET_GNS_lookup (struct GNUNET_GNS_Handle *handle, | 412 | GNUNET_GNS_lookup (struct GNUNET_GNS_Handle *handle, |
413 | const char *name, | 413 | const char *name, |
414 | const struct GNUNET_CRYPTO_EcdsaPublicKey *zone, | 414 | const struct GNUNET_IDENTITY_PublicKey *zone, |
415 | uint32_t type, | 415 | uint32_t type, |
416 | enum GNUNET_GNS_LocalOptions options, | 416 | enum GNUNET_GNS_LocalOptions options, |
417 | GNUNET_GNS_LookupResultProcessor proc, | 417 | GNUNET_GNS_LookupResultProcessor proc, |
diff --git a/src/gns/gns_tld_api.c b/src/gns/gns_tld_api.c index 3ebf07db6..b883662ad 100644 --- a/src/gns/gns_tld_api.c +++ b/src/gns/gns_tld_api.c | |||
@@ -167,7 +167,7 @@ process_lookup_result (void *cls, | |||
167 | */ | 167 | */ |
168 | static void | 168 | static void |
169 | lookup_with_public_key (struct GNUNET_GNS_LookupWithTldRequest *ltr, | 169 | lookup_with_public_key (struct GNUNET_GNS_LookupWithTldRequest *ltr, |
170 | const struct GNUNET_CRYPTO_EcdsaPublicKey *pkey) | 170 | const struct GNUNET_IDENTITY_PublicKey *pkey) |
171 | { | 171 | { |
172 | ltr->lr = GNUNET_GNS_lookup (ltr->gns_handle, | 172 | ltr->lr = GNUNET_GNS_lookup (ltr->gns_handle, |
173 | ltr->name, | 173 | ltr->name, |
@@ -190,11 +190,11 @@ lookup_with_public_key (struct GNUNET_GNS_LookupWithTldRequest *ltr, | |||
190 | */ | 190 | */ |
191 | static void | 191 | static void |
192 | identity_zone_cb (void *cls, | 192 | identity_zone_cb (void *cls, |
193 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *priv, | 193 | const struct GNUNET_IDENTITY_PrivateKey *priv, |
194 | const char *ego_name) | 194 | const char *ego_name) |
195 | { | 195 | { |
196 | struct GNUNET_GNS_LookupWithTldRequest *ltr = cls; | 196 | struct GNUNET_GNS_LookupWithTldRequest *ltr = cls; |
197 | struct GNUNET_CRYPTO_EcdsaPublicKey pkey; | 197 | struct GNUNET_IDENTITY_PublicKey pkey; |
198 | 198 | ||
199 | ltr->id_co = NULL; | 199 | ltr->id_co = NULL; |
200 | if (NULL == priv) | 200 | if (NULL == priv) |
@@ -219,7 +219,7 @@ identity_zone_cb (void *cls, | |||
219 | ltr->options = GNUNET_GNS_LO_NO_DHT; | 219 | ltr->options = GNUNET_GNS_LO_NO_DHT; |
220 | else | 220 | else |
221 | ltr->options = GNUNET_GNS_LO_LOCAL_MASTER; | 221 | ltr->options = GNUNET_GNS_LO_LOCAL_MASTER; |
222 | GNUNET_CRYPTO_ecdsa_key_get_public (priv, &pkey); | 222 | GNUNET_IDENTITY_key_get_public (priv, &pkey); |
223 | lookup_with_public_key (ltr, &pkey); | 223 | lookup_with_public_key (ltr, &pkey); |
224 | } | 224 | } |
225 | 225 | ||
@@ -249,7 +249,7 @@ GNUNET_GNS_lookup_with_tld (struct GNUNET_GNS_Handle *handle, | |||
249 | const char *tld; | 249 | const char *tld; |
250 | char *dot_tld; | 250 | char *dot_tld; |
251 | char *zonestr; | 251 | char *zonestr; |
252 | struct GNUNET_CRYPTO_EcdsaPublicKey pkey; | 252 | struct GNUNET_IDENTITY_PublicKey pkey; |
253 | 253 | ||
254 | ltr = GNUNET_new (struct GNUNET_GNS_LookupWithTldRequest); | 254 | ltr = GNUNET_new (struct GNUNET_GNS_LookupWithTldRequest); |
255 | ltr->gns_handle = handle; | 255 | ltr->gns_handle = handle; |
@@ -261,8 +261,10 @@ GNUNET_GNS_lookup_with_tld (struct GNUNET_GNS_Handle *handle, | |||
261 | /* start with trivial case: TLD is zkey */ | 261 | /* start with trivial case: TLD is zkey */ |
262 | tld = get_tld (ltr->name); | 262 | tld = get_tld (ltr->name); |
263 | if (GNUNET_OK == | 263 | if (GNUNET_OK == |
264 | GNUNET_CRYPTO_ecdsa_public_key_from_string (tld, strlen (tld), &pkey)) | 264 | GNUNET_IDENTITY_public_key_from_string (tld, &pkey)) |
265 | { | 265 | { |
266 | LOG (GNUNET_ERROR_TYPE_DEBUG, | ||
267 | "`%s' seems to be a valid zone key\n", tld); | ||
266 | eat_tld (ltr->name, tld); | 268 | eat_tld (ltr->name, tld); |
267 | lookup_with_public_key (ltr, &pkey); | 269 | lookup_with_public_key (ltr, &pkey); |
268 | return ltr; | 270 | return ltr; |
@@ -281,9 +283,8 @@ GNUNET_GNS_lookup_with_tld (struct GNUNET_GNS_Handle *handle, | |||
281 | &zonestr)) | 283 | &zonestr)) |
282 | { | 284 | { |
283 | if (GNUNET_OK != | 285 | if (GNUNET_OK != |
284 | GNUNET_CRYPTO_ecdsa_public_key_from_string (zonestr, | 286 | GNUNET_IDENTITY_public_key_from_string (zonestr, |
285 | strlen (zonestr), | 287 | &pkey)) |
286 | &pkey)) | ||
287 | { | 288 | { |
288 | GNUNET_log_config_invalid ( | 289 | GNUNET_log_config_invalid ( |
289 | GNUNET_ERROR_TYPE_ERROR, | 290 | GNUNET_ERROR_TYPE_ERROR, |
@@ -304,6 +305,8 @@ GNUNET_GNS_lookup_with_tld (struct GNUNET_GNS_Handle *handle, | |||
304 | } | 305 | } |
305 | GNUNET_free (dot_tld); | 306 | GNUNET_free (dot_tld); |
306 | } | 307 | } |
308 | LOG (GNUNET_ERROR_TYPE_DEBUG, | ||
309 | "`%s' should be a valid ego\n", ltr->name); | ||
307 | ltr->id_co = | 310 | ltr->id_co = |
308 | GNUNET_IDENTITY_ego_lookup_by_suffix (ltr->gns_handle->cfg, | 311 | GNUNET_IDENTITY_ego_lookup_by_suffix (ltr->gns_handle->cfg, |
309 | ltr->name, | 312 | ltr->name, |
diff --git a/src/gns/gnunet-gns-import.c b/src/gns/gnunet-gns-import.c index 78db28cab..972fb49cd 100644 --- a/src/gns/gnunet-gns-import.c +++ b/src/gns/gnunet-gns-import.c | |||
@@ -168,12 +168,17 @@ 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 | 172 | ||
172 | for (i = 0; i < rd_len; i++) | 173 | for (i = 0; i < rd_len; i++) |
173 | { | 174 | { |
174 | char *s; | 175 | char *s; |
175 | if ((GNUNET_GNSRECORD_TYPE_PKEY != rd[i].record_type) || | 176 | if (sizeof (uint32_t) > rd[i].data_size) |
176 | (rd[i].data_size != sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey)) ) | 177 | continue; |
178 | if (GNUNET_OK != GNUNET_GNSRECORD_identity_from_data (rd[i].data, | ||
179 | rd[i].data_size, | ||
180 | rd[i].record_type, | ||
181 | &pubkey)) | ||
177 | continue; | 182 | continue; |
178 | s = GNUNET_GNSRECORD_value_to_string (rd[i].record_type, | 183 | s = GNUNET_GNSRECORD_value_to_string (rd[i].record_type, |
179 | rd[i].data, | 184 | rd[i].data, |
diff --git a/src/gns/gnunet-service-gns.c b/src/gns/gnunet-service-gns.c index 8c5b2d6c4..52300ae3b 100644 --- a/src/gns/gnunet-service-gns.c +++ b/src/gns/gnunet-service-gns.c | |||
@@ -123,7 +123,7 @@ struct GNS_TopLevelDomain | |||
123 | /** | 123 | /** |
124 | * Public key associated with the @a tld. | 124 | * Public key associated with the @a tld. |
125 | */ | 125 | */ |
126 | struct GNUNET_CRYPTO_EcdsaPublicKey pkey; | 126 | struct GNUNET_IDENTITY_PublicKey pkey; |
127 | 127 | ||
128 | /** | 128 | /** |
129 | * Top-level domain as a string, including leading ".". | 129 | * Top-level domain as a string, including leading ".". |
@@ -177,7 +177,7 @@ static struct GNS_TopLevelDomain *tld_tail; | |||
177 | */ | 177 | */ |
178 | int | 178 | int |
179 | GNS_find_tld (const char *tld_str, | 179 | GNS_find_tld (const char *tld_str, |
180 | struct GNUNET_CRYPTO_EcdsaPublicKey *pkey) | 180 | struct GNUNET_IDENTITY_PublicKey *pkey) |
181 | { | 181 | { |
182 | if ('\0' == *tld_str) | 182 | if ('\0' == *tld_str) |
183 | return GNUNET_NO; | 183 | return GNUNET_NO; |
@@ -485,7 +485,7 @@ read_service_conf (void *cls, | |||
485 | const char *option, | 485 | const char *option, |
486 | const char *value) | 486 | const char *value) |
487 | { | 487 | { |
488 | struct GNUNET_CRYPTO_EcdsaPublicKey pk; | 488 | struct GNUNET_IDENTITY_PublicKey pk; |
489 | struct GNS_TopLevelDomain *tld; | 489 | struct GNS_TopLevelDomain *tld; |
490 | 490 | ||
491 | (void) cls; | 491 | (void) cls; |
diff --git a/src/gns/gnunet-service-gns.h b/src/gns/gnunet-service-gns.h index 2a432f8aa..d4fb9ec9f 100644 --- a/src/gns/gnunet-service-gns.h +++ b/src/gns/gnunet-service-gns.h | |||
@@ -26,6 +26,7 @@ | |||
26 | #ifndef GNUNET_SERVICE_GNS_H | 26 | #ifndef GNUNET_SERVICE_GNS_H |
27 | #define GNUNET_SERVICE_GNS_H | 27 | #define GNUNET_SERVICE_GNS_H |
28 | 28 | ||
29 | #include "gnunet_identity_service.h" | ||
29 | 30 | ||
30 | /** | 31 | /** |
31 | * Find GNS zone belonging to TLD @a tld. | 32 | * Find GNS zone belonging to TLD @a tld. |
@@ -36,7 +37,7 @@ | |||
36 | */ | 37 | */ |
37 | int | 38 | int |
38 | GNS_find_tld (const char *tld_str, | 39 | GNS_find_tld (const char *tld_str, |
39 | struct GNUNET_CRYPTO_EcdsaPublicKey *pkey); | 40 | struct GNUNET_IDENTITY_PublicKey *pkey); |
40 | 41 | ||
41 | 42 | ||
42 | /** | 43 | /** |
diff --git a/src/gns/gnunet-service-gns_interceptor.c b/src/gns/gnunet-service-gns_interceptor.c index 19416a506..b53f4af6b 100644 --- a/src/gns/gnunet-service-gns_interceptor.c +++ b/src/gns/gnunet-service-gns_interceptor.c | |||
@@ -314,7 +314,7 @@ handle_dns_request (void *cls, | |||
314 | { | 314 | { |
315 | struct GNUNET_DNSPARSER_Packet *p; | 315 | struct GNUNET_DNSPARSER_Packet *p; |
316 | struct InterceptLookupHandle *ilh; | 316 | struct InterceptLookupHandle *ilh; |
317 | struct GNUNET_CRYPTO_EcdsaPublicKey zone; | 317 | struct GNUNET_IDENTITY_PublicKey zone; |
318 | 318 | ||
319 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 319 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
320 | "Hijacked a DNS request. Processing.\n"); | 320 | "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 cb75b23c7..d9d0d3099 100644 --- a/src/gns/gnunet-service-gns_resolver.c +++ b/src/gns/gnunet-service-gns_resolver.c | |||
@@ -173,7 +173,7 @@ struct AuthorityChain | |||
173 | /** | 173 | /** |
174 | * The zone of the GNS authority | 174 | * The zone of the GNS authority |
175 | */ | 175 | */ |
176 | struct GNUNET_CRYPTO_EcdsaPublicKey gns_authority; | 176 | struct GNUNET_IDENTITY_PublicKey gns_authority; |
177 | 177 | ||
178 | struct | 178 | struct |
179 | { | 179 | { |
@@ -305,7 +305,7 @@ struct GNS_ResolverHandle | |||
305 | /** | 305 | /** |
306 | * The top-level GNS authoritative zone to query | 306 | * The top-level GNS authoritative zone to query |
307 | */ | 307 | */ |
308 | struct GNUNET_CRYPTO_EcdsaPublicKey authority_zone; | 308 | struct GNUNET_IDENTITY_PublicKey authority_zone; |
309 | 309 | ||
310 | /** | 310 | /** |
311 | * called when resolution phase finishes | 311 | * called when resolution phase finishes |
@@ -1251,7 +1251,7 @@ handle_gns_cname_result (struct GNS_ResolverHandle *rh, | |||
1251 | const char *tld; | 1251 | const char *tld; |
1252 | struct AuthorityChain *ac; | 1252 | struct AuthorityChain *ac; |
1253 | int af; | 1253 | int af; |
1254 | struct GNUNET_CRYPTO_EcdsaPublicKey zone; | 1254 | struct GNUNET_IDENTITY_PublicKey zone; |
1255 | 1255 | ||
1256 | nlen = strlen (cname); | 1256 | nlen = strlen (cname); |
1257 | tld = GNS_get_tld (cname); | 1257 | tld = GNS_get_tld (cname); |
@@ -1296,7 +1296,7 @@ handle_gns_cname_result (struct GNS_ResolverHandle *rh, | |||
1296 | { | 1296 | { |
1297 | GNUNET_asprintf (&res, | 1297 | GNUNET_asprintf (&res, |
1298 | "%.*s", | 1298 | "%.*s", |
1299 | strlen (cname) - (strlen (tld) + 1), | 1299 | (int) (strlen (cname) - (strlen (tld) + 1)), |
1300 | cname); | 1300 | cname); |
1301 | } | 1301 | } |
1302 | else | 1302 | else |
@@ -1305,7 +1305,7 @@ handle_gns_cname_result (struct GNS_ResolverHandle *rh, | |||
1305 | "%.*s.%.*s", | 1305 | "%.*s.%.*s", |
1306 | (int) rh->name_resolution_pos, | 1306 | (int) rh->name_resolution_pos, |
1307 | rh->name, | 1307 | rh->name, |
1308 | (int) strlen (cname) - (strlen (tld) + 1), | 1308 | (int) (strlen (cname) - (strlen (tld) + 1)), |
1309 | cname); | 1309 | cname); |
1310 | } | 1310 | } |
1311 | rh->name_resolution_pos = strlen (res); | 1311 | rh->name_resolution_pos = strlen (res); |
@@ -1696,10 +1696,13 @@ recursive_pkey_resolution (struct GNS_ResolverHandle *rh, | |||
1696 | const struct GNUNET_GNSRECORD_Data *rd) | 1696 | const struct GNUNET_GNSRECORD_Data *rd) |
1697 | { | 1697 | { |
1698 | struct AuthorityChain *ac; | 1698 | struct AuthorityChain *ac; |
1699 | struct GNUNET_IDENTITY_PublicKey auth; | ||
1699 | 1700 | ||
1700 | /* delegation to another zone */ | 1701 | /* delegation to another zone */ |
1701 | if (sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) != | 1702 | if (GNUNET_OK != GNUNET_GNSRECORD_identity_from_data (rd->data, |
1702 | rd->data_size) | 1703 | rd->data_size, |
1704 | rd->record_type, | ||
1705 | &auth)) | ||
1703 | { | 1706 | { |
1704 | GNUNET_break_op (0); | 1707 | GNUNET_break_op (0); |
1705 | fail_resolution (rh); | 1708 | fail_resolution (rh); |
@@ -1709,9 +1712,7 @@ recursive_pkey_resolution (struct GNS_ResolverHandle *rh, | |||
1709 | ac = GNUNET_new (struct AuthorityChain); | 1712 | ac = GNUNET_new (struct AuthorityChain); |
1710 | ac->rh = rh; | 1713 | ac->rh = rh; |
1711 | ac->gns_authority = GNUNET_YES; | 1714 | ac->gns_authority = GNUNET_YES; |
1712 | GNUNET_memcpy (&ac->authority_info.gns_authority, | 1715 | ac->authority_info.gns_authority = auth; |
1713 | rd->data, | ||
1714 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey)); | ||
1715 | ac->label = resolver_lookup_get_next_label (rh); | 1716 | ac->label = resolver_lookup_get_next_label (rh); |
1716 | /* add AC to tail */ | 1717 | /* add AC to tail */ |
1717 | GNUNET_CONTAINER_DLL_insert_tail (rh->ac_head, | 1718 | GNUNET_CONTAINER_DLL_insert_tail (rh->ac_head, |
@@ -1754,7 +1755,7 @@ recursive_gns2dns_resolution (struct GNS_ResolverHandle *rh, | |||
1754 | char *n; | 1755 | char *n; |
1755 | size_t off; | 1756 | size_t off; |
1756 | struct Gns2DnsPending *gp; | 1757 | struct Gns2DnsPending *gp; |
1757 | struct GNUNET_CRYPTO_EcdsaPublicKey zone; | 1758 | struct GNUNET_IDENTITY_PublicKey zone; |
1758 | struct sockaddr_in v4; | 1759 | struct sockaddr_in v4; |
1759 | struct sockaddr_in6 v6; | 1760 | struct sockaddr_in6 v6; |
1760 | 1761 | ||
@@ -2257,19 +2258,25 @@ handle_gns_resolution_result (void *cls, | |||
2257 | break; | 2258 | break; |
2258 | 2259 | ||
2259 | case GNUNET_GNSRECORD_TYPE_PKEY: | 2260 | case GNUNET_GNSRECORD_TYPE_PKEY: |
2261 | case GNUNET_GNSRECORD_TYPE_EDKEY: | ||
2260 | { | 2262 | { |
2261 | struct GNUNET_CRYPTO_EcdsaPublicKey pub; | 2263 | struct GNUNET_IDENTITY_PublicKey pubkey; |
2262 | 2264 | if (rd[i].data_size < sizeof(uint32_t)) | |
2263 | if (rd[i].data_size != sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey)) | 2265 | { |
2266 | GNUNET_break_op (0); | ||
2267 | break; | ||
2268 | } | ||
2269 | if (GNUNET_OK != | ||
2270 | GNUNET_GNSRECORD_identity_from_data (rd[i].data, | ||
2271 | rd[i].data_size, | ||
2272 | rd[i].record_type, | ||
2273 | &pubkey)) | ||
2264 | { | 2274 | { |
2265 | GNUNET_break_op (0); | 2275 | GNUNET_break_op (0); |
2266 | break; | 2276 | break; |
2267 | } | 2277 | } |
2268 | GNUNET_memcpy (&pub, | ||
2269 | rd[i].data, | ||
2270 | rd[i].data_size); | ||
2271 | rd_off++; | 2278 | rd_off++; |
2272 | if (GNUNET_GNSRECORD_TYPE_PKEY != rh->record_type) | 2279 | if (rd[i].record_type != rh->record_type) |
2273 | { | 2280 | { |
2274 | /* try to resolve "@" */ | 2281 | /* try to resolve "@" */ |
2275 | struct AuthorityChain *ac; | 2282 | struct AuthorityChain *ac; |
@@ -2277,7 +2284,7 @@ handle_gns_resolution_result (void *cls, | |||
2277 | ac = GNUNET_new (struct AuthorityChain); | 2284 | ac = GNUNET_new (struct AuthorityChain); |
2278 | ac->rh = rh; | 2285 | ac->rh = rh; |
2279 | ac->gns_authority = GNUNET_YES; | 2286 | ac->gns_authority = GNUNET_YES; |
2280 | ac->authority_info.gns_authority = pub; | 2287 | ac->authority_info.gns_authority = pubkey; |
2281 | ac->label = GNUNET_strdup (GNUNET_GNS_EMPTY_LABEL_AT); | 2288 | ac->label = GNUNET_strdup (GNUNET_GNS_EMPTY_LABEL_AT); |
2282 | GNUNET_CONTAINER_DLL_insert_tail (rh->ac_head, | 2289 | GNUNET_CONTAINER_DLL_insert_tail (rh->ac_head, |
2283 | rh->ac_tail, | 2290 | rh->ac_tail, |
@@ -2367,6 +2374,7 @@ handle_gns_resolution_result (void *cls, | |||
2367 | return; | 2374 | return; |
2368 | 2375 | ||
2369 | case GNUNET_GNSRECORD_TYPE_PKEY: | 2376 | case GNUNET_GNSRECORD_TYPE_PKEY: |
2377 | case GNUNET_GNSRECORD_TYPE_EDKEY: | ||
2370 | GNUNET_break_op (1 == rd_count); /* PKEY should be unique */ | 2378 | GNUNET_break_op (1 == rd_count); /* PKEY should be unique */ |
2371 | recursive_pkey_resolution (rh, | 2379 | recursive_pkey_resolution (rh, |
2372 | &rd[0]); | 2380 | &rd[0]); |
@@ -2469,10 +2477,7 @@ handle_dht_response (void *cls, | |||
2469 | return; | 2477 | return; |
2470 | } | 2478 | } |
2471 | block = data; | 2479 | block = data; |
2472 | if (size != | 2480 | if (size != GNUNET_GNSRECORD_block_get_size (block)) |
2473 | ntohl (block->purpose.size) | ||
2474 | + sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) | ||
2475 | + sizeof(struct GNUNET_CRYPTO_EcdsaSignature)) | ||
2476 | { | 2481 | { |
2477 | /* how did this pass DHT block validation!? */ | 2482 | /* how did this pass DHT block validation!? */ |
2478 | GNUNET_break (0); | 2483 | GNUNET_break (0); |
@@ -2480,8 +2485,8 @@ handle_dht_response (void *cls, | |||
2480 | return; | 2485 | return; |
2481 | } | 2486 | } |
2482 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 2487 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
2483 | "Decrypting DHT block of size %u for `%s', expires %s\n", | 2488 | "Decrypting DHT block of size %lu for `%s', expires %s\n", |
2484 | ntohl (block->purpose.size), | 2489 | GNUNET_GNSRECORD_block_get_size (block), |
2485 | rh->name, | 2490 | rh->name, |
2486 | GNUNET_STRINGS_absolute_time_to_string (exp)); | 2491 | GNUNET_STRINGS_absolute_time_to_string (exp)); |
2487 | if (GNUNET_OK != | 2492 | if (GNUNET_OK != |
@@ -2495,8 +2500,8 @@ handle_dht_response (void *cls, | |||
2495 | fail_resolution (rh); | 2500 | fail_resolution (rh); |
2496 | return; | 2501 | return; |
2497 | } | 2502 | } |
2498 | if (0 == GNUNET_TIME_absolute_get_remaining (GNUNET_TIME_absolute_ntoh ( | 2503 | if (0 == GNUNET_TIME_absolute_get_remaining ( |
2499 | block->expiration_time)). | 2504 | GNUNET_GNSRECORD_block_get_expiration (block)). |
2500 | rel_value_us) | 2505 | rel_value_us) |
2501 | { | 2506 | { |
2502 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 2507 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
@@ -2594,7 +2599,7 @@ handle_namecache_block_response (void *cls, | |||
2594 | struct GNS_ResolverHandle *rh = cls; | 2599 | struct GNS_ResolverHandle *rh = cls; |
2595 | struct AuthorityChain *ac = rh->ac_tail; | 2600 | struct AuthorityChain *ac = rh->ac_tail; |
2596 | const char *label = ac->label; | 2601 | const char *label = ac->label; |
2597 | const struct GNUNET_CRYPTO_EcdsaPublicKey *auth = | 2602 | const struct GNUNET_IDENTITY_PublicKey *auth = |
2598 | &ac->authority_info.gns_authority; | 2603 | &ac->authority_info.gns_authority; |
2599 | struct GNUNET_HashCode query; | 2604 | struct GNUNET_HashCode query; |
2600 | 2605 | ||
@@ -2604,8 +2609,8 @@ handle_namecache_block_response (void *cls, | |||
2604 | ((GNUNET_GNS_LO_LOCAL_MASTER == rh->options) && | 2609 | ((GNUNET_GNS_LO_LOCAL_MASTER == rh->options) && |
2605 | (ac != rh->ac_head))) && | 2610 | (ac != rh->ac_head))) && |
2606 | ((NULL == block) || | 2611 | ((NULL == block) || |
2607 | (0 == GNUNET_TIME_absolute_get_remaining (GNUNET_TIME_absolute_ntoh ( | 2612 | (0 == GNUNET_TIME_absolute_get_remaining ( |
2608 | block->expiration_time)). | 2613 | GNUNET_GNSRECORD_block_get_expiration (block)). |
2609 | rel_value_us))) | 2614 | rel_value_us))) |
2610 | { | 2615 | { |
2611 | /* namecache knows nothing; try DHT lookup */ | 2616 | /* namecache knows nothing; try DHT lookup */ |
@@ -2622,8 +2627,8 @@ handle_namecache_block_response (void *cls, | |||
2622 | } | 2627 | } |
2623 | 2628 | ||
2624 | if ((NULL == block) || | 2629 | if ((NULL == block) || |
2625 | (0 == GNUNET_TIME_absolute_get_remaining (GNUNET_TIME_absolute_ntoh ( | 2630 | (0 == GNUNET_TIME_absolute_get_remaining ( |
2626 | block->expiration_time)). | 2631 | GNUNET_GNSRECORD_block_get_expiration (block)). |
2627 | rel_value_us)) | 2632 | rel_value_us)) |
2628 | { | 2633 | { |
2629 | /* DHT not permitted and no local result, fail */ | 2634 | /* DHT not permitted and no local result, fail */ |
@@ -2857,7 +2862,7 @@ start_resolver_lookup (void *cls) | |||
2857 | * @return handle to cancel operation | 2862 | * @return handle to cancel operation |
2858 | */ | 2863 | */ |
2859 | struct GNS_ResolverHandle * | 2864 | struct GNS_ResolverHandle * |
2860 | GNS_resolver_lookup (const struct GNUNET_CRYPTO_EcdsaPublicKey *zone, | 2865 | GNS_resolver_lookup (const struct GNUNET_IDENTITY_PublicKey *zone, |
2861 | uint32_t record_type, | 2866 | uint32_t record_type, |
2862 | const char *name, | 2867 | const char *name, |
2863 | enum GNUNET_GNS_LocalOptions options, | 2868 | enum GNUNET_GNS_LocalOptions options, |
diff --git a/src/gns/gnunet-service-gns_resolver.h b/src/gns/gnunet-service-gns_resolver.h index 3dab3c91a..b099c5d65 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_CRYPTO_EcdsaPublicKey *zone, | 89 | GNS_resolver_lookup (const struct GNUNET_IDENTITY_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_block_gns.c b/src/gns/plugin_block_gns.c index aabedcaac..9b58c9034 100644 --- a/src/gns/plugin_block_gns.c +++ b/src/gns/plugin_block_gns.c | |||
@@ -145,17 +145,13 @@ block_plugin_gns_evaluate (void *cls, | |||
145 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | 145 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; |
146 | } | 146 | } |
147 | block = reply_block; | 147 | block = reply_block; |
148 | if (ntohl (block->purpose.size) + sizeof(struct | 148 | if (GNUNET_GNSRECORD_block_get_size (block) > reply_block_size) |
149 | GNUNET_CRYPTO_EcdsaSignature) | ||
150 | + sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) != | ||
151 | reply_block_size) | ||
152 | { | 149 | { |
153 | GNUNET_break_op (0); | 150 | GNUNET_break_op (0); |
154 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | 151 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; |
155 | } | 152 | } |
156 | GNUNET_CRYPTO_hash (&block->derived_key, | 153 | GNUNET_GNSRECORD_query_from_block (block, |
157 | sizeof(block->derived_key), | 154 | &h); |
158 | &h); | ||
159 | if (0 != GNUNET_memcmp (&h, query)) | 155 | if (0 != GNUNET_memcmp (&h, query)) |
160 | { | 156 | { |
161 | GNUNET_break_op (0); | 157 | GNUNET_break_op (0); |
@@ -206,9 +202,8 @@ block_plugin_gns_get_key (void *cls, | |||
206 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | 202 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; |
207 | } | 203 | } |
208 | block = reply_block; | 204 | block = reply_block; |
209 | GNUNET_CRYPTO_hash (&block->derived_key, | 205 | GNUNET_GNSRECORD_query_from_block (block, |
210 | sizeof(block->derived_key), | 206 | key); |
211 | key); | ||
212 | return GNUNET_OK; | 207 | return GNUNET_OK; |
213 | } | 208 | } |
214 | 209 | ||
diff --git a/src/gns/plugin_gnsrecord_gns.c b/src/gns/plugin_gnsrecord_gns.c index 81f2b9eff..a2ad0b905 100644 --- a/src/gns/plugin_gnsrecord_gns.c +++ b/src/gns/plugin_gnsrecord_gns.c | |||
@@ -50,13 +50,18 @@ gns_value_to_string (void *cls, | |||
50 | size_t data_size) | 50 | size_t data_size) |
51 | { | 51 | { |
52 | const char *cdata; | 52 | const char *cdata; |
53 | struct GNUNET_IDENTITY_PublicKey pk; | ||
53 | 54 | ||
54 | switch (type) | 55 | switch (type) |
55 | { | 56 | { |
56 | case GNUNET_GNSRECORD_TYPE_PKEY: | 57 | case GNUNET_GNSRECORD_TYPE_PKEY: |
57 | if (data_size != sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey)) | 58 | case GNUNET_GNSRECORD_TYPE_EDKEY: |
59 | if (GNUNET_OK != GNUNET_GNSRECORD_identity_from_data (data, | ||
60 | data_size, | ||
61 | type, | ||
62 | &pk)) | ||
58 | return NULL; | 63 | return NULL; |
59 | return GNUNET_CRYPTO_ecdsa_public_key_to_string (data); | 64 | return GNUNET_IDENTITY_public_key_to_string (&pk); |
60 | 65 | ||
61 | case GNUNET_GNSRECORD_TYPE_NICK: | 66 | case GNUNET_GNSRECORD_TYPE_NICK: |
62 | return GNUNET_strndup (data, data_size); | 67 | return GNUNET_strndup (data, data_size); |
@@ -153,24 +158,35 @@ gns_string_to_value (void *cls, | |||
153 | void **data, | 158 | void **data, |
154 | size_t *data_size) | 159 | size_t *data_size) |
155 | { | 160 | { |
156 | struct GNUNET_CRYPTO_EcdsaPublicKey pkey; | 161 | struct GNUNET_IDENTITY_PublicKey pk; |
162 | uint32_t record_type; | ||
157 | 163 | ||
158 | if (NULL == s) | 164 | if (NULL == s) |
159 | return GNUNET_SYSERR; | 165 | return GNUNET_SYSERR; |
160 | switch (type) | 166 | switch (type) |
161 | { | 167 | { |
162 | case GNUNET_GNSRECORD_TYPE_PKEY: | 168 | case GNUNET_GNSRECORD_TYPE_PKEY: |
169 | case GNUNET_GNSRECORD_TYPE_EDKEY: | ||
163 | if (GNUNET_OK != | 170 | if (GNUNET_OK != |
164 | GNUNET_CRYPTO_ecdsa_public_key_from_string (s, strlen (s), &pkey)) | 171 | GNUNET_IDENTITY_public_key_from_string (s, &pk)) |
165 | { | 172 | { |
166 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | 173 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, |
167 | _ ("Unable to parse PKEY record `%s'\n"), | 174 | _ ("Unable to parse zone key record `%s'\n"), |
168 | s); | 175 | s); |
169 | return GNUNET_SYSERR; | 176 | return GNUNET_SYSERR; |
170 | } | 177 | } |
171 | *data = GNUNET_new (struct GNUNET_CRYPTO_EcdsaPublicKey); | 178 | *data_size = GNUNET_IDENTITY_key_get_length (&pk); |
172 | GNUNET_memcpy (*data, &pkey, sizeof(pkey)); | 179 | if (GNUNET_OK != GNUNET_GNSRECORD_data_from_identity (&pk, |
173 | *data_size = sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey); | 180 | (char **) data, |
181 | data_size, | ||
182 | &record_type)) | ||
183 | return GNUNET_SYSERR; | ||
184 | if (record_type != type) | ||
185 | { | ||
186 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | ||
187 | _("Record type does not match parsed record type\n")); | ||
188 | return GNUNET_SYSERR; | ||
189 | } | ||
174 | return GNUNET_OK; | 190 | return GNUNET_OK; |
175 | 191 | ||
176 | case GNUNET_GNSRECORD_TYPE_NICK: | 192 | case GNUNET_GNSRECORD_TYPE_NICK: |
@@ -301,6 +317,7 @@ static struct | |||
301 | const char *name; | 317 | const char *name; |
302 | uint32_t number; | 318 | uint32_t number; |
303 | } gns_name_map[] = { { "PKEY", GNUNET_GNSRECORD_TYPE_PKEY }, | 319 | } gns_name_map[] = { { "PKEY", GNUNET_GNSRECORD_TYPE_PKEY }, |
320 | { "EDKEY", GNUNET_GNSRECORD_TYPE_PKEY }, | ||
304 | { "NICK", GNUNET_GNSRECORD_TYPE_NICK }, | 321 | { "NICK", GNUNET_GNSRECORD_TYPE_NICK }, |
305 | { "LEHO", GNUNET_GNSRECORD_TYPE_LEHO }, | 322 | { "LEHO", GNUNET_GNSRECORD_TYPE_LEHO }, |
306 | { "VPN", GNUNET_GNSRECORD_TYPE_VPN }, | 323 | { "VPN", GNUNET_GNSRECORD_TYPE_VPN }, |
diff --git a/src/gns/plugin_rest_gns.c b/src/gns/plugin_rest_gns.c index 6ec921f70..2ccb5be2b 100644 --- a/src/gns/plugin_rest_gns.c +++ b/src/gns/plugin_rest_gns.c | |||
@@ -28,6 +28,7 @@ | |||
28 | #include "gnunet_rest_lib.h" | 28 | #include "gnunet_rest_lib.h" |
29 | #include "gnunet_json_lib.h" | 29 | #include "gnunet_json_lib.h" |
30 | #include "gnunet_gnsrecord_lib.h" | 30 | #include "gnunet_gnsrecord_lib.h" |
31 | #include "gnunet_gnsrecord_json_lib.h" | ||
31 | #include "gnunet_gns_service.h" | 32 | #include "gnunet_gns_service.h" |
32 | #include "microhttpd.h" | 33 | #include "microhttpd.h" |
33 | #include <jansson.h> | 34 | #include <jansson.h> |
@@ -264,7 +265,7 @@ handle_gns_response (void *cls, | |||
264 | return; | 265 | return; |
265 | } | 266 | } |
266 | 267 | ||
267 | result_obj = GNUNET_JSON_from_gnsrecord (handle->name, rd, rd_count); | 268 | result_obj = GNUNET_GNSRECORD_JSON_from_gnsrecord (handle->name, rd, rd_count); |
268 | 269 | ||
269 | result = json_dumps (result_obj, 0); | 270 | result = json_dumps (result_obj, 0); |
270 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Result %s\n", result); | 271 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Result %s\n", result); |
diff --git a/src/gns/test_gns_dht_lookup.sh b/src/gns/test_gns_dht_lookup.sh index d5516fd03..8d446c507 100755 --- a/src/gns/test_gns_dht_lookup.sh +++ b/src/gns/test_gns_dht_lookup.sh | |||
@@ -26,6 +26,7 @@ gnunet-arm -i datastore -c test_gns_lookup.conf | |||
26 | gnunet-identity -C $OTHER_EGO -c test_gns_lookup.conf | 26 | gnunet-identity -C $OTHER_EGO -c test_gns_lookup.conf |
27 | DELEGATED_PKEY=$(gnunet-identity -d -c test_gns_lookup.conf | grep $OTHER_EGO | awk '{print $3}') | 27 | DELEGATED_PKEY=$(gnunet-identity -d -c test_gns_lookup.conf | grep $OTHER_EGO | awk '{print $3}') |
28 | gnunet-identity -C $MY_EGO -c test_gns_lookup.conf | 28 | gnunet-identity -C $MY_EGO -c test_gns_lookup.conf |
29 | echo "MYEGO: $MY_EGO OTHER_EGO: $DELEGATED_PKEY" | ||
29 | gnunet-namestore -p -z $MY_EGO -a -n b -t PKEY -V $DELEGATED_PKEY -e never -c test_gns_lookup.conf | 30 | gnunet-namestore -p -z $MY_EGO -a -n b -t PKEY -V $DELEGATED_PKEY -e never -c test_gns_lookup.conf |
30 | #This works | 31 | #This works |
31 | gnunet-namestore -p -z $OTHER_EGO -a -n www -t A -V $TEST_IP -e never -c test_gns_lookup.conf | 32 | gnunet-namestore -p -z $OTHER_EGO -a -n www -t A -V $TEST_IP -e never -c test_gns_lookup.conf |
diff --git a/src/gnsrecord/Makefile.am b/src/gnsrecord/Makefile.am index 2e6eca7ba..ab604eb92 100644 --- a/src/gnsrecord/Makefile.am +++ b/src/gnsrecord/Makefile.am | |||
@@ -1,5 +1,5 @@ | |||
1 | # This Makefile.am is in the public domain | 1 | # This Makefile.am is in the public domain |
2 | AM_CPPFLAGS = -I$(top_srcdir)/src/include | 2 | AM_CPPFLAGS = -I$(top_srcdir)/src/include ${MHD_CFLAGS} |
3 | 3 | ||
4 | plugindir = $(libdir)/gnunet | 4 | plugindir = $(libdir)/gnunet |
5 | 5 | ||
@@ -30,12 +30,14 @@ TESTS = \ | |||
30 | endif | 30 | endif |
31 | 31 | ||
32 | lib_LTLIBRARIES = \ | 32 | lib_LTLIBRARIES = \ |
33 | libgnunetgnsrecord.la | 33 | libgnunetgnsrecord.la \ |
34 | libgnunetgnsrecordjson.la | ||
34 | 35 | ||
35 | gnunet_gnsrecord_tvg_SOURCES = \ | 36 | gnunet_gnsrecord_tvg_SOURCES = \ |
36 | gnunet-gnsrecord-tvg.c | 37 | gnunet-gnsrecord-tvg.c |
37 | gnunet_gnsrecord_tvg_LDADD = \ | 38 | gnunet_gnsrecord_tvg_LDADD = \ |
38 | $(top_builddir)/src/util/libgnunetutil.la \ | 39 | $(top_builddir)/src/util/libgnunetutil.la \ |
40 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
39 | libgnunetgnsrecord.la \ | 41 | libgnunetgnsrecord.la \ |
40 | $(GN_LIBINTL) | 42 | $(GN_LIBINTL) |
41 | 43 | ||
@@ -47,11 +49,26 @@ libgnunetgnsrecord_la_SOURCES = \ | |||
47 | gnsrecord_misc.c | 49 | gnsrecord_misc.c |
48 | libgnunetgnsrecord_la_LIBADD = \ | 50 | libgnunetgnsrecord_la_LIBADD = \ |
49 | $(top_builddir)/src/util/libgnunetutil.la \ | 51 | $(top_builddir)/src/util/libgnunetutil.la \ |
52 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
53 | $(LIBGCRYPT_LIBS) \ | ||
50 | $(GN_LIBINTL) | 54 | $(GN_LIBINTL) |
55 | libgnunetgnsrecord_la_DEPENDENCIES = \ | ||
56 | $(top_builddir)/src/identity/libgnunetidentity.la | ||
51 | libgnunetgnsrecord_la_LDFLAGS = \ | 57 | libgnunetgnsrecord_la_LDFLAGS = \ |
52 | $(GN_LIB_LDFLAGS) \ | 58 | $(GN_LIB_LDFLAGS) \ |
53 | -version-info 0:0:0 | 59 | -version-info 0:0:0 |
54 | 60 | ||
61 | libgnunetgnsrecordjson_la_SOURCES = \ | ||
62 | json_gnsrecord.c | ||
63 | libgnunetgnsrecordjson_la_LIBADD = \ | ||
64 | $(top_builddir)/src/util/libgnunetutil.la \ | ||
65 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
66 | libgnunetgnsrecord.la \ | ||
67 | -ljansson \ | ||
68 | $(GN_LIBINTL) | ||
69 | libgnunetgnsrecordjson_la_LDFLAGS = \ | ||
70 | $(GN_LIB_LDFLAGS) \ | ||
71 | -version-info 0:0:0 | ||
55 | 72 | ||
56 | plugin_LTLIBRARIES = \ | 73 | plugin_LTLIBRARIES = \ |
57 | libgnunet_plugin_gnsrecord_dns.la | 74 | libgnunet_plugin_gnsrecord_dns.la |
diff --git a/src/gnsrecord/gnsrecord_crypto.c b/src/gnsrecord/gnsrecord_crypto.c index c8919760a..9c551a936 100644 --- a/src/gnsrecord/gnsrecord_crypto.c +++ b/src/gnsrecord/gnsrecord_crypto.c | |||
@@ -37,6 +37,61 @@ | |||
37 | 37 | ||
38 | #define LOG(kind, ...) GNUNET_log_from (kind, "gnsrecord", __VA_ARGS__) | 38 | #define LOG(kind, ...) GNUNET_log_from (kind, "gnsrecord", __VA_ARGS__) |
39 | 39 | ||
40 | ssize_t | ||
41 | ecdsa_symmetric_decrypt ( | ||
42 | const void *block, | ||
43 | size_t size, | ||
44 | const unsigned char *key, | ||
45 | const unsigned char *ctr, | ||
46 | void *result) | ||
47 | { | ||
48 | gcry_cipher_hd_t handle; | ||
49 | int rc; | ||
50 | |||
51 | GNUNET_assert (0 == gcry_cipher_open (&handle, GCRY_CIPHER_AES256, | ||
52 | GCRY_CIPHER_MODE_CTR, 0)); | ||
53 | rc = gcry_cipher_setkey (handle, | ||
54 | key, | ||
55 | GNUNET_CRYPTO_AES_KEY_LENGTH); | ||
56 | GNUNET_assert ((0 == rc) || ((char) rc == GPG_ERR_WEAK_KEY)); | ||
57 | rc = gcry_cipher_setctr (handle, | ||
58 | ctr, | ||
59 | GNUNET_CRYPTO_AES_KEY_LENGTH / 2); | ||
60 | GNUNET_assert ((0 == rc) || ((char) rc == GPG_ERR_WEAK_KEY)); | ||
61 | GNUNET_assert (0 == gcry_cipher_decrypt (handle, result, size, block, size)); | ||
62 | gcry_cipher_close (handle); | ||
63 | return size; | ||
64 | } | ||
65 | |||
66 | |||
67 | |||
68 | ssize_t | ||
69 | ecdsa_symmetric_encrypt ( | ||
70 | const void *block, | ||
71 | size_t size, | ||
72 | const unsigned char *key, | ||
73 | const unsigned char *ctr, | ||
74 | void *result) | ||
75 | { | ||
76 | gcry_cipher_hd_t handle; | ||
77 | int rc; | ||
78 | |||
79 | GNUNET_assert (0 == gcry_cipher_open (&handle, GCRY_CIPHER_AES256, | ||
80 | GCRY_CIPHER_MODE_CTR, 0)); | ||
81 | rc = gcry_cipher_setkey (handle, | ||
82 | key, | ||
83 | GNUNET_CRYPTO_AES_KEY_LENGTH); | ||
84 | GNUNET_assert ((0 == rc) || ((char) rc == GPG_ERR_WEAK_KEY)); | ||
85 | rc = gcry_cipher_setctr (handle, | ||
86 | ctr, | ||
87 | GNUNET_CRYPTO_AES_KEY_LENGTH / 2); | ||
88 | GNUNET_assert ((0 == rc) || ((char) rc == GPG_ERR_WEAK_KEY)); | ||
89 | GNUNET_assert (0 == gcry_cipher_encrypt (handle, result, size, block, size)); | ||
90 | gcry_cipher_close (handle); | ||
91 | return size; | ||
92 | } | ||
93 | |||
94 | |||
40 | 95 | ||
41 | /** | 96 | /** |
42 | * Derive session key and iv from label and public key. | 97 | * Derive session key and iv from label and public key. |
@@ -47,25 +102,31 @@ | |||
47 | * @param pub public key to use for KDF | 102 | * @param pub public key to use for KDF |
48 | */ | 103 | */ |
49 | static void | 104 | static void |
50 | derive_block_aes_key (struct GNUNET_CRYPTO_SymmetricInitializationVector *iv, | 105 | derive_block_aes_key (unsigned char *ctr, |
51 | struct GNUNET_CRYPTO_SymmetricSessionKey *skey, | 106 | unsigned char *key, |
52 | const char *label, | 107 | const char *label, |
108 | uint64_t exp, | ||
53 | const struct GNUNET_CRYPTO_EcdsaPublicKey *pub) | 109 | const struct GNUNET_CRYPTO_EcdsaPublicKey *pub) |
54 | { | 110 | { |
55 | static const char ctx_key[] = "gns-aes-ctx-key"; | 111 | static const char ctx_key[] = "gns-aes-ctx-key"; |
56 | static const char ctx_iv[] = "gns-aes-ctx-iv"; | 112 | static const char ctx_iv[] = "gns-aes-ctx-iv"; |
57 | 113 | ||
58 | GNUNET_CRYPTO_kdf (skey, sizeof(struct GNUNET_CRYPTO_SymmetricSessionKey), | 114 | GNUNET_CRYPTO_kdf (key, GNUNET_CRYPTO_AES_KEY_LENGTH, |
59 | ctx_key, strlen (ctx_key), | 115 | ctx_key, strlen (ctx_key), |
60 | pub, sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey), | 116 | pub, sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey), |
61 | label, strlen (label), | 117 | label, strlen (label), |
62 | NULL, 0); | 118 | NULL, 0); |
63 | GNUNET_CRYPTO_kdf (iv, sizeof(struct | 119 | memset (ctr, 0, GNUNET_CRYPTO_AES_KEY_LENGTH / 2); |
64 | GNUNET_CRYPTO_SymmetricInitializationVector), | 120 | /** 4 byte nonce **/ |
121 | GNUNET_CRYPTO_kdf (ctr, 4, | ||
65 | ctx_iv, strlen (ctx_iv), | 122 | ctx_iv, strlen (ctx_iv), |
66 | pub, sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey), | 123 | pub, sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey), |
67 | label, strlen (label), | 124 | label, strlen (label), |
68 | NULL, 0); | 125 | NULL, 0); |
126 | /** Expiration time 64 bit. **/ | ||
127 | memcpy (ctr + 4, &exp, sizeof (exp)); | ||
128 | /** Set counter part to 1 **/ | ||
129 | ctr[15] |= 0x01; | ||
69 | } | 130 | } |
70 | 131 | ||
71 | 132 | ||
@@ -81,19 +142,20 @@ derive_block_aes_key (struct GNUNET_CRYPTO_SymmetricInitializationVector *iv, | |||
81 | * @return NULL on error (block too large) | 142 | * @return NULL on error (block too large) |
82 | */ | 143 | */ |
83 | static struct GNUNET_GNSRECORD_Block * | 144 | static struct GNUNET_GNSRECORD_Block * |
84 | block_create (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | 145 | block_create_ecdsa (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, |
85 | const struct GNUNET_CRYPTO_EcdsaPublicKey *pkey, | 146 | const struct GNUNET_CRYPTO_EcdsaPublicKey *pkey, |
86 | struct GNUNET_TIME_Absolute expire, | 147 | struct GNUNET_TIME_Absolute expire, |
87 | const char *label, | 148 | const char *label, |
88 | const struct GNUNET_GNSRECORD_Data *rd, | 149 | const struct GNUNET_GNSRECORD_Data *rd, |
89 | unsigned int rd_count) | 150 | unsigned int rd_count) |
90 | { | 151 | { |
91 | ssize_t payload_len = GNUNET_GNSRECORD_records_get_size (rd_count, | 152 | ssize_t payload_len = GNUNET_GNSRECORD_records_get_size (rd_count, |
92 | rd); | 153 | rd); |
93 | struct GNUNET_GNSRECORD_Block *block; | 154 | struct GNUNET_GNSRECORD_Block *block; |
155 | struct GNUNET_GNSRECORD_EcdsaBlock *ecblock; | ||
94 | struct GNUNET_CRYPTO_EcdsaPrivateKey *dkey; | 156 | struct GNUNET_CRYPTO_EcdsaPrivateKey *dkey; |
95 | struct GNUNET_CRYPTO_SymmetricInitializationVector iv; | 157 | unsigned char ctr[GNUNET_CRYPTO_AES_KEY_LENGTH / 2]; |
96 | struct GNUNET_CRYPTO_SymmetricSessionKey skey; | 158 | unsigned char skey[GNUNET_CRYPTO_AES_KEY_LENGTH]; |
97 | struct GNUNET_GNSRECORD_Data rdc[GNUNET_NZL (rd_count)]; | 159 | struct GNUNET_GNSRECORD_Data rdc[GNUNET_NZL (rd_count)]; |
98 | uint32_t rd_count_nbo; | 160 | uint32_t rd_count_nbo; |
99 | struct GNUNET_TIME_Absolute now; | 161 | struct GNUNET_TIME_Absolute now; |
@@ -140,35 +202,38 @@ block_create (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | |||
140 | block = GNUNET_malloc (sizeof(struct GNUNET_GNSRECORD_Block) | 202 | block = GNUNET_malloc (sizeof(struct GNUNET_GNSRECORD_Block) |
141 | + sizeof(uint32_t) | 203 | + sizeof(uint32_t) |
142 | + payload_len); | 204 | + payload_len); |
143 | block->purpose.size = htonl (sizeof(uint32_t) | 205 | ecblock = &block->ecdsa_block; |
144 | + payload_len | 206 | block->type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
145 | + sizeof(struct | 207 | ecblock->purpose.size = htonl (sizeof(uint32_t) |
146 | GNUNET_CRYPTO_EccSignaturePurpose) | 208 | + payload_len |
147 | + sizeof(struct GNUNET_TIME_AbsoluteNBO)); | 209 | + sizeof(struct |
148 | block->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_GNS_RECORD_SIGN); | 210 | GNUNET_CRYPTO_EccSignaturePurpose) |
149 | block->expiration_time = GNUNET_TIME_absolute_hton (expire); | 211 | + sizeof(struct GNUNET_TIME_AbsoluteNBO)); |
212 | ecblock->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_GNS_RECORD_SIGN); | ||
213 | ecblock->expiration_time = GNUNET_TIME_absolute_hton (expire); | ||
150 | /* encrypt and sign */ | 214 | /* encrypt and sign */ |
151 | dkey = GNUNET_CRYPTO_ecdsa_private_key_derive (key, | 215 | dkey = GNUNET_CRYPTO_ecdsa_private_key_derive (key, |
152 | label, | 216 | label, |
153 | "gns"); | 217 | "gns"); |
154 | GNUNET_CRYPTO_ecdsa_key_get_public (dkey, | 218 | GNUNET_CRYPTO_ecdsa_key_get_public (dkey, |
155 | &block->derived_key); | 219 | &ecblock->derived_key); |
156 | derive_block_aes_key (&iv, | 220 | derive_block_aes_key (ctr, |
157 | &skey, | 221 | skey, |
158 | label, | 222 | label, |
223 | ecblock->expiration_time.abs_value_us__, | ||
159 | pkey); | 224 | pkey); |
160 | GNUNET_break (payload_len + sizeof(uint32_t) == | 225 | GNUNET_break (payload_len + sizeof(uint32_t) == |
161 | GNUNET_CRYPTO_symmetric_encrypt (payload, | 226 | ecdsa_symmetric_encrypt (payload, |
162 | payload_len | 227 | payload_len |
163 | + sizeof(uint32_t), | 228 | + sizeof(uint32_t), |
164 | &skey, | 229 | skey, |
165 | &iv, | 230 | ctr, |
166 | &block[1])); | 231 | &ecblock[1])); |
167 | } | 232 | } |
168 | if (GNUNET_OK != | 233 | if (GNUNET_OK != |
169 | GNUNET_CRYPTO_ecdsa_sign_ (dkey, | 234 | GNUNET_CRYPTO_ecdsa_sign_ (dkey, |
170 | &block->purpose, | 235 | &ecblock->purpose, |
171 | &block->signature)) | 236 | &ecblock->signature)) |
172 | { | 237 | { |
173 | GNUNET_break (0); | 238 | GNUNET_break (0); |
174 | GNUNET_free (dkey); | 239 | GNUNET_free (dkey); |
@@ -191,7 +256,7 @@ block_create (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | |||
191 | * @return NULL on error (block too large) | 256 | * @return NULL on error (block too large) |
192 | */ | 257 | */ |
193 | struct GNUNET_GNSRECORD_Block * | 258 | struct GNUNET_GNSRECORD_Block * |
194 | GNUNET_GNSRECORD_block_create (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | 259 | GNUNET_GNSRECORD_block_create (const struct GNUNET_IDENTITY_PrivateKey *key, |
195 | struct GNUNET_TIME_Absolute expire, | 260 | struct GNUNET_TIME_Absolute expire, |
196 | const char *label, | 261 | const char *label, |
197 | const struct GNUNET_GNSRECORD_Data *rd, | 262 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -199,14 +264,21 @@ GNUNET_GNSRECORD_block_create (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | |||
199 | { | 264 | { |
200 | struct GNUNET_CRYPTO_EcdsaPublicKey pkey; | 265 | struct GNUNET_CRYPTO_EcdsaPublicKey pkey; |
201 | 266 | ||
202 | GNUNET_CRYPTO_ecdsa_key_get_public (key, | 267 | switch (ntohl (key->type)) |
203 | &pkey); | 268 | { |
204 | return block_create (key, | 269 | case GNUNET_GNSRECORD_TYPE_PKEY: |
205 | &pkey, | 270 | GNUNET_CRYPTO_ecdsa_key_get_public (&key->ecdsa_key, |
206 | expire, | 271 | &pkey); |
207 | label, | 272 | return block_create_ecdsa (&key->ecdsa_key, |
208 | rd, | 273 | &pkey, |
209 | rd_count); | 274 | expire, |
275 | label, | ||
276 | rd, | ||
277 | rd_count); | ||
278 | default: | ||
279 | GNUNET_assert (0); | ||
280 | } | ||
281 | return NULL; | ||
210 | } | 282 | } |
211 | 283 | ||
212 | 284 | ||
@@ -240,12 +312,19 @@ struct KeyCacheLine | |||
240 | * @return NULL on error (block too large) | 312 | * @return NULL on error (block too large) |
241 | */ | 313 | */ |
242 | struct GNUNET_GNSRECORD_Block * | 314 | struct GNUNET_GNSRECORD_Block * |
243 | GNUNET_GNSRECORD_block_create2 (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | 315 | GNUNET_GNSRECORD_block_create2 (const struct GNUNET_IDENTITY_PrivateKey *pkey, |
244 | struct GNUNET_TIME_Absolute expire, | 316 | struct GNUNET_TIME_Absolute expire, |
245 | const char *label, | 317 | const char *label, |
246 | const struct GNUNET_GNSRECORD_Data *rd, | 318 | const struct GNUNET_GNSRECORD_Data *rd, |
247 | unsigned int rd_count) | 319 | unsigned int rd_count) |
248 | { | 320 | { |
321 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *key; | ||
322 | |||
323 | if (GNUNET_IDENTITY_TYPE_ECDSA != ntohl (pkey->type)) | ||
324 | { | ||
325 | return NULL; // FIXME | ||
326 | } | ||
327 | key = &pkey->ecdsa_key; | ||
249 | #define CSIZE 64 | 328 | #define CSIZE 64 |
250 | static struct KeyCacheLine cache[CSIZE]; | 329 | static struct KeyCacheLine cache[CSIZE]; |
251 | struct KeyCacheLine *line; | 330 | struct KeyCacheLine *line; |
@@ -261,12 +340,12 @@ GNUNET_GNSRECORD_block_create2 (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | |||
261 | &line->pkey); | 340 | &line->pkey); |
262 | } | 341 | } |
263 | #undef CSIZE | 342 | #undef CSIZE |
264 | return block_create (key, | 343 | return block_create_ecdsa (key, |
265 | &line->pkey, | 344 | &line->pkey, |
266 | expire, | 345 | expire, |
267 | label, | 346 | label, |
268 | rd, | 347 | rd, |
269 | rd_count); | 348 | rd_count); |
270 | } | 349 | } |
271 | 350 | ||
272 | 351 | ||
@@ -277,40 +356,40 @@ GNUNET_GNSRECORD_block_create2 (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | |||
277 | * @param block block to verify | 356 | * @param block block to verify |
278 | * @return #GNUNET_OK if the signature is valid | 357 | * @return #GNUNET_OK if the signature is valid |
279 | */ | 358 | */ |
280 | int | 359 | enum GNUNET_GenericReturnValue |
281 | GNUNET_GNSRECORD_block_verify (const struct GNUNET_GNSRECORD_Block *block) | 360 | GNUNET_GNSRECORD_block_verify (const struct GNUNET_GNSRECORD_Block *block) |
282 | { | 361 | { |
362 | const struct GNUNET_CRYPTO_EcdsaPublicKey *key; | ||
363 | const struct GNUNET_GNSRECORD_EcdsaBlock *ecblock; | ||
364 | |||
365 | if (GNUNET_GNSRECORD_TYPE_PKEY != ntohl (block->type)) | ||
366 | { | ||
367 | GNUNET_break (0); | ||
368 | return GNUNET_NO; | ||
369 | } | ||
370 | ecblock = &block->ecdsa_block; | ||
371 | key = &ecblock->derived_key; | ||
372 | |||
283 | return GNUNET_CRYPTO_ecdsa_verify_ (GNUNET_SIGNATURE_PURPOSE_GNS_RECORD_SIGN, | 373 | return GNUNET_CRYPTO_ecdsa_verify_ (GNUNET_SIGNATURE_PURPOSE_GNS_RECORD_SIGN, |
284 | &block->purpose, | 374 | &ecblock->purpose, |
285 | &block->signature, | 375 | &ecblock->signature, |
286 | &block->derived_key); | 376 | key); |
287 | } | 377 | } |
288 | 378 | ||
289 | 379 | ||
290 | /** | 380 | enum GNUNET_GenericReturnValue |
291 | * Decrypt block. | 381 | block_decrypt_ecdsa (const struct GNUNET_GNSRECORD_EcdsaBlock *block, |
292 | * | 382 | const struct |
293 | * @param block block to decrypt | 383 | GNUNET_CRYPTO_EcdsaPublicKey *zone_key, |
294 | * @param zone_key public key of the zone | 384 | const char *label, |
295 | * @param label the name for the records | 385 | GNUNET_GNSRECORD_RecordCallback proc, |
296 | * @param proc function to call with the result | 386 | void *proc_cls) |
297 | * @param proc_cls closure for proc | ||
298 | * @return #GNUNET_OK on success, #GNUNET_SYSERR if the block was | ||
299 | * not well-formed | ||
300 | */ | ||
301 | int | ||
302 | GNUNET_GNSRECORD_block_decrypt (const struct GNUNET_GNSRECORD_Block *block, | ||
303 | const struct | ||
304 | GNUNET_CRYPTO_EcdsaPublicKey *zone_key, | ||
305 | const char *label, | ||
306 | GNUNET_GNSRECORD_RecordCallback proc, | ||
307 | void *proc_cls) | ||
308 | { | 387 | { |
309 | size_t payload_len = ntohl (block->purpose.size) | 388 | size_t payload_len = ntohl (block->purpose.size) |
310 | - sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) | 389 | - sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) |
311 | - sizeof(struct GNUNET_TIME_AbsoluteNBO); | 390 | - sizeof(struct GNUNET_TIME_AbsoluteNBO); |
312 | struct GNUNET_CRYPTO_SymmetricInitializationVector iv; | 391 | unsigned char ctr[GNUNET_CRYPTO_AES_KEY_LENGTH / 2]; |
313 | struct GNUNET_CRYPTO_SymmetricSessionKey skey; | 392 | unsigned char key[GNUNET_CRYPTO_AES_KEY_LENGTH]; |
314 | 393 | ||
315 | if (ntohl (block->purpose.size) < | 394 | if (ntohl (block->purpose.size) < |
316 | sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) | 395 | sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) |
@@ -319,18 +398,19 @@ GNUNET_GNSRECORD_block_decrypt (const struct GNUNET_GNSRECORD_Block *block, | |||
319 | GNUNET_break_op (0); | 398 | GNUNET_break_op (0); |
320 | return GNUNET_SYSERR; | 399 | return GNUNET_SYSERR; |
321 | } | 400 | } |
322 | derive_block_aes_key (&iv, | 401 | derive_block_aes_key (ctr, |
323 | &skey, | 402 | key, |
324 | label, | 403 | label, |
404 | block->expiration_time.abs_value_us__, | ||
325 | zone_key); | 405 | zone_key); |
326 | { | 406 | { |
327 | char payload[payload_len]; | 407 | char payload[payload_len]; |
328 | uint32_t rd_count; | 408 | uint32_t rd_count; |
329 | 409 | ||
330 | GNUNET_break (payload_len == | 410 | GNUNET_break (payload_len == |
331 | GNUNET_CRYPTO_symmetric_decrypt (&block[1], payload_len, | 411 | ecdsa_symmetric_decrypt (&block[1], payload_len, |
332 | &skey, &iv, | 412 | key, ctr, |
333 | payload)); | 413 | payload)); |
334 | GNUNET_memcpy (&rd_count, | 414 | GNUNET_memcpy (&rd_count, |
335 | payload, | 415 | payload, |
336 | sizeof(uint32_t)); | 416 | sizeof(uint32_t)); |
@@ -426,6 +506,39 @@ GNUNET_GNSRECORD_block_decrypt (const struct GNUNET_GNSRECORD_Block *block, | |||
426 | 506 | ||
427 | 507 | ||
428 | /** | 508 | /** |
509 | * Decrypt block. | ||
510 | * | ||
511 | * @param block block to decrypt | ||
512 | * @param zone_key public key of the zone | ||
513 | * @param label the name for the records | ||
514 | * @param proc function to call with the result | ||
515 | * @param proc_cls closure for proc | ||
516 | * @return #GNUNET_OK on success, #GNUNET_SYSERR if the block was | ||
517 | * not well-formed | ||
518 | */ | ||
519 | enum GNUNET_GenericReturnValue | ||
520 | GNUNET_GNSRECORD_block_decrypt (const struct GNUNET_GNSRECORD_Block *block, | ||
521 | const struct | ||
522 | GNUNET_IDENTITY_PublicKey *zone_key, | ||
523 | const char *label, | ||
524 | GNUNET_GNSRECORD_RecordCallback proc, | ||
525 | void *proc_cls) | ||
526 | { | ||
527 | const struct GNUNET_CRYPTO_EcdsaPublicKey *key; | ||
528 | |||
529 | if (GNUNET_IDENTITY_TYPE_ECDSA != ntohl (zone_key->type)) | ||
530 | { | ||
531 | return GNUNET_NO; | ||
532 | } | ||
533 | key = &zone_key->ecdsa_key; | ||
534 | |||
535 | return block_decrypt_ecdsa (&block->ecdsa_block, | ||
536 | key, label, proc, proc_cls); | ||
537 | |||
538 | } | ||
539 | |||
540 | |||
541 | /** | ||
429 | * Calculate the DHT query for a given @a label in a given @a zone. | 542 | * Calculate the DHT query for a given @a label in a given @a zone. |
430 | * | 543 | * |
431 | * @param zone private key of the zone | 544 | * @param zone private key of the zone |
@@ -434,17 +547,24 @@ GNUNET_GNSRECORD_block_decrypt (const struct GNUNET_GNSRECORD_Block *block, | |||
434 | */ | 547 | */ |
435 | void | 548 | void |
436 | GNUNET_GNSRECORD_query_from_private_key (const struct | 549 | GNUNET_GNSRECORD_query_from_private_key (const struct |
437 | GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 550 | GNUNET_IDENTITY_PrivateKey *zone, |
438 | const char *label, | 551 | const char *label, |
439 | struct GNUNET_HashCode *query) | 552 | struct GNUNET_HashCode *query) |
440 | { | 553 | { |
441 | struct GNUNET_CRYPTO_EcdsaPublicKey pub; | 554 | struct GNUNET_IDENTITY_PublicKey pub; |
442 | 555 | switch (ntohl (zone->type)) | |
443 | GNUNET_CRYPTO_ecdsa_key_get_public (zone, | 556 | { |
444 | &pub); | 557 | case GNUNET_GNSRECORD_TYPE_PKEY: |
445 | GNUNET_GNSRECORD_query_from_public_key (&pub, | 558 | |
446 | label, | 559 | GNUNET_IDENTITY_key_get_public (zone, |
447 | query); | 560 | &pub); |
561 | GNUNET_GNSRECORD_query_from_public_key (&pub, | ||
562 | label, | ||
563 | query); | ||
564 | break; | ||
565 | default: | ||
566 | GNUNET_assert (0); | ||
567 | } | ||
448 | } | 568 | } |
449 | 569 | ||
450 | 570 | ||
@@ -457,18 +577,27 @@ GNUNET_GNSRECORD_query_from_private_key (const struct | |||
457 | */ | 577 | */ |
458 | void | 578 | void |
459 | GNUNET_GNSRECORD_query_from_public_key (const struct | 579 | GNUNET_GNSRECORD_query_from_public_key (const struct |
460 | GNUNET_CRYPTO_EcdsaPublicKey *pub, | 580 | GNUNET_IDENTITY_PublicKey *pub, |
461 | const char *label, | 581 | const char *label, |
462 | struct GNUNET_HashCode *query) | 582 | struct GNUNET_HashCode *query) |
463 | { | 583 | { |
464 | struct GNUNET_CRYPTO_EcdsaPublicKey pd; | 584 | struct GNUNET_IDENTITY_PublicKey pd; |
465 | GNUNET_CRYPTO_ecdsa_public_key_derive (pub, | 585 | |
466 | label, | 586 | switch (ntohl (pub->type)) |
467 | "gns", | 587 | { |
468 | &pd); | 588 | case GNUNET_GNSRECORD_TYPE_PKEY: |
469 | GNUNET_CRYPTO_hash (&pd, | 589 | pd.type = pub->type; |
470 | sizeof(pd), | 590 | GNUNET_CRYPTO_ecdsa_public_key_derive (&pub->ecdsa_key, |
471 | query); | 591 | label, |
592 | "gns", | ||
593 | &pd.ecdsa_key); | ||
594 | GNUNET_CRYPTO_hash (&pd.ecdsa_key, | ||
595 | sizeof (pd.ecdsa_key), | ||
596 | query); | ||
597 | break; | ||
598 | default: | ||
599 | GNUNET_assert (0); | ||
600 | } | ||
472 | } | 601 | } |
473 | 602 | ||
474 | 603 | ||
diff --git a/src/gnsrecord/gnsrecord_misc.c b/src/gnsrecord/gnsrecord_misc.c index 5061f8493..82c38f19a 100644 --- a/src/gnsrecord/gnsrecord_misc.c +++ b/src/gnsrecord/gnsrecord_misc.c | |||
@@ -62,14 +62,14 @@ GNUNET_GNSRECORD_string_to_lowercase (const char *src) | |||
62 | * @return string form; will be overwritten by next call to #GNUNET_GNSRECORD_z2s | 62 | * @return string form; will be overwritten by next call to #GNUNET_GNSRECORD_z2s |
63 | */ | 63 | */ |
64 | const char * | 64 | const char * |
65 | GNUNET_GNSRECORD_z2s (const struct GNUNET_CRYPTO_EcdsaPublicKey *z) | 65 | GNUNET_GNSRECORD_z2s (const struct GNUNET_IDENTITY_PublicKey *z) |
66 | { | 66 | { |
67 | static char buf[sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) * 8]; | 67 | static char buf[sizeof(struct GNUNET_IDENTITY_PublicKey) * 8]; |
68 | char *end; | 68 | char *end; |
69 | 69 | ||
70 | end = GNUNET_STRINGS_data_to_string ((const unsigned char *) z, | 70 | end = GNUNET_STRINGS_data_to_string ((const unsigned char *) z, |
71 | sizeof(struct | 71 | sizeof(struct |
72 | GNUNET_CRYPTO_EcdsaPublicKey), | 72 | GNUNET_IDENTITY_PublicKey), |
73 | buf, sizeof(buf)); | 73 | buf, sizeof(buf)); |
74 | if (NULL == end) | 74 | if (NULL == end) |
75 | { | 75 | { |
@@ -99,7 +99,7 @@ GNUNET_GNSRECORD_records_cmp (const struct GNUNET_GNSRECORD_Data *a, | |||
99 | if (a->record_type != b->record_type) | 99 | if (a->record_type != b->record_type) |
100 | { | 100 | { |
101 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 101 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
102 | "Record type %lu != %lu\n", a->record_type, b->record_type); | 102 | "Record type %u != %u\n", a->record_type, b->record_type); |
103 | return GNUNET_NO; | 103 | return GNUNET_NO; |
104 | } | 104 | } |
105 | if ((a->expiration_time != b->expiration_time) && | 105 | if ((a->expiration_time != b->expiration_time) && |
@@ -107,15 +107,15 @@ GNUNET_GNSRECORD_records_cmp (const struct GNUNET_GNSRECORD_Data *a, | |||
107 | { | 107 | { |
108 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 108 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
109 | "Expiration time %llu != %llu\n", | 109 | "Expiration time %llu != %llu\n", |
110 | a->expiration_time, | 110 | (unsigned long long) a->expiration_time, |
111 | b->expiration_time); | 111 | (unsigned long long) b->expiration_time); |
112 | return GNUNET_NO; | 112 | return GNUNET_NO; |
113 | } | 113 | } |
114 | if ((a->flags & GNUNET_GNSRECORD_RF_RCMP_FLAGS) | 114 | if ((a->flags & GNUNET_GNSRECORD_RF_RCMP_FLAGS) |
115 | != (b->flags & GNUNET_GNSRECORD_RF_RCMP_FLAGS)) | 115 | != (b->flags & GNUNET_GNSRECORD_RF_RCMP_FLAGS)) |
116 | { | 116 | { |
117 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 117 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
118 | "Flags %lu (%lu) != %lu (%lu)\n", a->flags, | 118 | "Flags %u (%u) != %u (%u)\n", a->flags, |
119 | a->flags & GNUNET_GNSRECORD_RF_RCMP_FLAGS, b->flags, | 119 | a->flags & GNUNET_GNSRECORD_RF_RCMP_FLAGS, b->flags, |
120 | b->flags & GNUNET_GNSRECORD_RF_RCMP_FLAGS); | 120 | b->flags & GNUNET_GNSRECORD_RF_RCMP_FLAGS); |
121 | return GNUNET_NO; | 121 | return GNUNET_NO; |
@@ -236,12 +236,12 @@ GNUNET_GNSRECORD_is_expired (const struct GNUNET_GNSRECORD_Data *rd) | |||
236 | * key in an encoding suitable for DNS labels. | 236 | * key in an encoding suitable for DNS labels. |
237 | */ | 237 | */ |
238 | const char * | 238 | const char * |
239 | GNUNET_GNSRECORD_pkey_to_zkey (const struct GNUNET_CRYPTO_EcdsaPublicKey *pkey) | 239 | GNUNET_GNSRECORD_pkey_to_zkey (const struct GNUNET_IDENTITY_PublicKey *pkey) |
240 | { | 240 | { |
241 | static char ret[128]; | 241 | static char ret[128]; |
242 | char *pkeys; | 242 | char *pkeys; |
243 | 243 | ||
244 | pkeys = GNUNET_CRYPTO_ecdsa_public_key_to_string (pkey); | 244 | pkeys = GNUNET_IDENTITY_public_key_to_string (pkey); |
245 | GNUNET_snprintf (ret, | 245 | GNUNET_snprintf (ret, |
246 | sizeof(ret), | 246 | sizeof(ret), |
247 | "%s", | 247 | "%s", |
@@ -262,15 +262,140 @@ GNUNET_GNSRECORD_pkey_to_zkey (const struct GNUNET_CRYPTO_EcdsaPublicKey *pkey) | |||
262 | */ | 262 | */ |
263 | int | 263 | int |
264 | GNUNET_GNSRECORD_zkey_to_pkey (const char *zkey, | 264 | GNUNET_GNSRECORD_zkey_to_pkey (const char *zkey, |
265 | struct GNUNET_CRYPTO_EcdsaPublicKey *pkey) | 265 | struct GNUNET_IDENTITY_PublicKey *pkey) |
266 | { | 266 | { |
267 | if (GNUNET_OK != | 267 | if (GNUNET_OK != |
268 | GNUNET_CRYPTO_ecdsa_public_key_from_string (zkey, | 268 | GNUNET_IDENTITY_public_key_from_string (zkey, |
269 | strlen (zkey), | 269 | pkey)) |
270 | pkey)) | ||
271 | return GNUNET_SYSERR; | 270 | return GNUNET_SYSERR; |
272 | return GNUNET_OK; | 271 | return GNUNET_OK; |
273 | } | 272 | } |
274 | 273 | ||
275 | 274 | ||
275 | enum GNUNET_GenericReturnValue | ||
276 | GNUNET_GNSRECORD_identity_from_data (const char *data, | ||
277 | size_t data_size, | ||
278 | uint32_t type, | ||
279 | struct GNUNET_IDENTITY_PublicKey *key) | ||
280 | { | ||
281 | if (GNUNET_NO == GNUNET_GNSRECORD_is_zonekey_type (type)) | ||
282 | return GNUNET_SYSERR; | ||
283 | if (data_size > sizeof (struct GNUNET_IDENTITY_PublicKey)) | ||
284 | return GNUNET_SYSERR; | ||
285 | return (GNUNET_IDENTITY_read_key_from_buffer (key, data, data_size) == | ||
286 | data_size? | ||
287 | GNUNET_OK : | ||
288 | GNUNET_SYSERR); | ||
289 | } | ||
290 | |||
291 | |||
292 | enum GNUNET_GenericReturnValue | ||
293 | GNUNET_GNSRECORD_data_from_identity (const struct | ||
294 | GNUNET_IDENTITY_PublicKey *key, | ||
295 | char **data, | ||
296 | size_t *data_size, | ||
297 | uint32_t *type) | ||
298 | { | ||
299 | *type = ntohl (key->type); | ||
300 | *data_size = GNUNET_IDENTITY_key_get_length (key); | ||
301 | if (0 == *data_size) | ||
302 | return GNUNET_SYSERR; | ||
303 | *data = GNUNET_malloc (*data_size); | ||
304 | return (GNUNET_IDENTITY_write_key_to_buffer (key, *data, *data_size) == | ||
305 | *data_size? | ||
306 | GNUNET_OK : | ||
307 | GNUNET_SYSERR); | ||
308 | } | ||
309 | |||
310 | |||
311 | enum GNUNET_GenericReturnValue | ||
312 | GNUNET_GNSRECORD_is_zonekey_type (uint32_t type) | ||
313 | { | ||
314 | switch (type) | ||
315 | { | ||
316 | case GNUNET_GNSRECORD_TYPE_PKEY: | ||
317 | case GNUNET_GNSRECORD_TYPE_EDKEY: | ||
318 | return GNUNET_YES; | ||
319 | default: | ||
320 | return GNUNET_NO; | ||
321 | } | ||
322 | } | ||
323 | |||
324 | |||
325 | size_t | ||
326 | GNUNET_GNSRECORD_block_get_size (const struct GNUNET_GNSRECORD_Block *block) | ||
327 | { | ||
328 | switch (ntohl (block->type)) | ||
329 | { | ||
330 | case GNUNET_GNSRECORD_TYPE_PKEY: | ||
331 | return sizeof (uint32_t) /* zone type */ | ||
332 | + sizeof (block->ecdsa_block) /* EcdsaBlock */ | ||
333 | + ntohl (block->ecdsa_block.purpose.size) /* Length of signed data */ | ||
334 | - sizeof (block->ecdsa_block.purpose); /* Purpose already in EcdsaBlock */ | ||
335 | break; | ||
336 | default: | ||
337 | return 0; | ||
338 | } | ||
339 | return 0; | ||
340 | } | ||
341 | |||
342 | |||
343 | struct GNUNET_TIME_Absolute | ||
344 | GNUNET_GNSRECORD_block_get_expiration (const struct | ||
345 | GNUNET_GNSRECORD_Block *block) | ||
346 | { | ||
347 | |||
348 | switch (ntohl (block->type)) | ||
349 | { | ||
350 | case GNUNET_GNSRECORD_TYPE_PKEY: | ||
351 | return GNUNET_TIME_absolute_ntoh (block->ecdsa_block.expiration_time); | ||
352 | default: | ||
353 | return GNUNET_TIME_absolute_get_zero_ (); | ||
354 | } | ||
355 | return GNUNET_TIME_absolute_get_zero_ (); | ||
356 | |||
357 | } | ||
358 | |||
359 | |||
360 | enum GNUNET_GenericReturnValue | ||
361 | GNUNET_GNSRECORD_query_from_block (const struct GNUNET_GNSRECORD_Block *block, | ||
362 | struct GNUNET_HashCode *query) | ||
363 | { | ||
364 | switch (ntohl (block->type)) | ||
365 | { | ||
366 | case GNUNET_GNSRECORD_TYPE_PKEY: | ||
367 | GNUNET_CRYPTO_hash (&block->ecdsa_block.derived_key, | ||
368 | sizeof (block->ecdsa_block.derived_key), | ||
369 | query); | ||
370 | return GNUNET_OK; | ||
371 | default: | ||
372 | return GNUNET_SYSERR; | ||
373 | } | ||
374 | return GNUNET_SYSERR; | ||
375 | |||
376 | } | ||
377 | |||
378 | |||
379 | enum GNUNET_GenericReturnValue | ||
380 | GNUNET_GNSRECORD_record_to_identity_key (const struct GNUNET_GNSRECORD_Data *rd, | ||
381 | struct GNUNET_IDENTITY_PublicKey *key) | ||
382 | { | ||
383 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
384 | "Got record of type %u\n", | ||
385 | rd->record_type); | ||
386 | switch (rd->record_type) | ||
387 | { | ||
388 | case GNUNET_GNSRECORD_TYPE_PKEY: | ||
389 | key->type = htonl (rd->record_type); | ||
390 | memcpy (&key->ecdsa_key, rd->data, sizeof (key->ecdsa_key)); | ||
391 | return GNUNET_OK; | ||
392 | default: | ||
393 | return GNUNET_SYSERR; | ||
394 | } | ||
395 | return GNUNET_SYSERR; | ||
396 | |||
397 | |||
398 | } | ||
399 | |||
400 | |||
276 | /* end of gnsrecord_misc.c */ | 401 | /* end of gnsrecord_misc.c */ |
diff --git a/src/gnsrecord/gnunet-gnsrecord-tvg.c b/src/gnsrecord/gnunet-gnsrecord-tvg.c index 789ff8aa3..47b13bdab 100644 --- a/src/gnsrecord/gnunet-gnsrecord-tvg.c +++ b/src/gnsrecord/gnunet-gnsrecord-tvg.c | |||
@@ -90,28 +90,38 @@ run (void *cls, | |||
90 | struct GNUNET_TIME_Absolute exp_abs = GNUNET_TIME_absolute_get (); | 90 | struct GNUNET_TIME_Absolute exp_abs = GNUNET_TIME_absolute_get (); |
91 | struct GNUNET_GNSRECORD_Block *rrblock; | 91 | struct GNUNET_GNSRECORD_Block *rrblock; |
92 | char *bdata; | 92 | char *bdata; |
93 | struct GNUNET_CRYPTO_EcdsaPrivateKey id_priv; | 93 | struct GNUNET_IDENTITY_PrivateKey id_priv; |
94 | struct GNUNET_CRYPTO_EcdsaPublicKey id_pub; | 94 | struct GNUNET_IDENTITY_PublicKey id_pub; |
95 | struct GNUNET_CRYPTO_EcdsaPrivateKey pkey_data_p; | 95 | struct GNUNET_IDENTITY_PrivateKey pkey_data_p; |
96 | struct GNUNET_CRYPTO_EcdsaPublicKey pkey_data; | 96 | struct GNUNET_IDENTITY_PublicKey pkey_data; |
97 | void *data; | 97 | void *data; |
98 | size_t data_size; | 98 | size_t data_size; |
99 | char *rdata; | 99 | char *rdata; |
100 | size_t rdata_size; | 100 | size_t rdata_size; |
101 | 101 | char ztld[128]; | |
102 | GNUNET_CRYPTO_ecdsa_key_create (&id_priv); | 102 | |
103 | GNUNET_CRYPTO_ecdsa_key_get_public (&id_priv, | 103 | id_priv.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
104 | &id_pub); | 104 | GNUNET_CRYPTO_ecdsa_key_create (&id_priv.ecdsa_key); |
105 | fprintf (stdout, "Zone private key (d, little-endian scalar):\n"); | 105 | GNUNET_IDENTITY_key_get_public (&id_priv, |
106 | print_bytes (&id_priv, sizeof(id_priv), 0); | 106 | &id_pub); |
107 | fprintf (stdout, "Zone private key (d, little-endian, with ztype prepended):\n"); | ||
108 | print_bytes (&id_priv, GNUNET_IDENTITY_key_get_length (&id_pub), 8); //FIXME length for privkey? | ||
109 | fprintf (stdout, "\n"); | ||
110 | fprintf (stdout, "Zone identifier (zid):\n"); | ||
111 | print_bytes (&id_pub, GNUNET_IDENTITY_key_get_length (&id_pub), 8); | ||
112 | GNUNET_STRINGS_data_to_string (&id_pub, | ||
113 | GNUNET_IDENTITY_key_get_length (&id_pub), | ||
114 | ztld, | ||
115 | sizeof (ztld)); | ||
107 | fprintf (stdout, "\n"); | 116 | fprintf (stdout, "\n"); |
108 | fprintf (stdout, "Zone public key (zk):\n"); | 117 | fprintf (stdout, "Encoded zone identifier (zkl = zTLD):\n"); |
109 | print_bytes (&id_pub, sizeof(id_pub), 0); | 118 | fprintf (stdout, "%s\n", ztld); |
110 | fprintf (stdout, "\n"); | 119 | fprintf (stdout, "\n"); |
111 | 120 | ||
112 | GNUNET_CRYPTO_ecdsa_key_create (&pkey_data_p); | 121 | pkey_data_p.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
113 | GNUNET_CRYPTO_ecdsa_key_get_public (&pkey_data_p, | 122 | GNUNET_CRYPTO_ecdsa_key_create (&pkey_data_p.ecdsa_key); |
114 | &pkey_data); | 123 | GNUNET_IDENTITY_key_get_public (&pkey_data_p, |
124 | &pkey_data); | ||
115 | fprintf (stdout, | 125 | fprintf (stdout, |
116 | "Label: %s\nRRCOUNT: %d\n\n", TEST_RECORD_LABEL, TEST_RRCOUNT); | 126 | "Label: %s\nRRCOUNT: %d\n\n", TEST_RECORD_LABEL, TEST_RRCOUNT); |
117 | memset (rd, 0, sizeof (struct GNUNET_GNSRECORD_Data) * 2); | 127 | memset (rd, 0, sizeof (struct GNUNET_GNSRECORD_Data) * 2); |
@@ -147,19 +157,20 @@ run (void *cls, | |||
147 | TEST_RECORD_LABEL, | 157 | TEST_RECORD_LABEL, |
148 | rd, | 158 | rd, |
149 | TEST_RRCOUNT); | 159 | TEST_RRCOUNT); |
150 | size_t bdata_size = ntohl (rrblock->purpose.size) | 160 | size_t bdata_size = ntohl (rrblock->ecdsa_block.purpose.size) |
151 | - sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) | 161 | - sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) |
152 | - sizeof(struct GNUNET_TIME_AbsoluteNBO); | 162 | - sizeof(struct GNUNET_TIME_AbsoluteNBO); |
153 | size_t rrblock_size = ntohl (rrblock->purpose.size) | 163 | size_t ecblock_size = ntohl (rrblock->ecdsa_block.purpose.size) |
154 | + sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) | 164 | + sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) |
155 | + sizeof(struct GNUNET_CRYPTO_EcdsaSignature); | 165 | + sizeof(struct GNUNET_CRYPTO_EcdsaSignature); |
166 | size_t block_size = ecblock_size + sizeof (uint32_t); | ||
156 | 167 | ||
157 | bdata = (char*) &rrblock[1]; | 168 | bdata = (char*) &(&rrblock->ecdsa_block)[1]; |
158 | fprintf (stdout, "BDATA:\n"); | 169 | fprintf (stdout, "BDATA:\n"); |
159 | print_bytes (bdata, bdata_size, 8); | 170 | print_bytes (bdata, bdata_size, 8); |
160 | fprintf (stdout, "\n"); | 171 | fprintf (stdout, "\n"); |
161 | fprintf (stdout, "RRBLOCK:\n"); | 172 | fprintf (stdout, "RRBLOCK:\n"); |
162 | print_bytes (rrblock, rrblock_size, 8); | 173 | print_bytes (rrblock, block_size, 8); |
163 | fprintf (stdout, "\n"); | 174 | fprintf (stdout, "\n"); |
164 | 175 | ||
165 | } | 176 | } |
diff --git a/src/json/json_gnsrecord.c b/src/gnsrecord/json_gnsrecord.c index 7e11aba94..068ff48c1 100644 --- a/src/json/json_gnsrecord.c +++ b/src/gnsrecord/json_gnsrecord.c | |||
@@ -26,6 +26,7 @@ | |||
26 | #include "platform.h" | 26 | #include "platform.h" |
27 | #include "gnunet_util_lib.h" | 27 | #include "gnunet_util_lib.h" |
28 | #include "gnunet_json_lib.h" | 28 | #include "gnunet_json_lib.h" |
29 | #include "gnunet_gnsrecord_lib.h" | ||
29 | 30 | ||
30 | #define GNUNET_JSON_GNSRECORD_VALUE "value" | 31 | #define GNUNET_JSON_GNSRECORD_VALUE "value" |
31 | #define GNUNET_JSON_GNSRECORD_RECORD_DATA "data" | 32 | #define GNUNET_JSON_GNSRECORD_RECORD_DATA "data" |
@@ -258,7 +259,7 @@ clean_gnsrecordobject (void *cls, struct GNUNET_JSON_Specification *spec) | |||
258 | * @return JSON Specification | 259 | * @return JSON Specification |
259 | */ | 260 | */ |
260 | struct GNUNET_JSON_Specification | 261 | struct GNUNET_JSON_Specification |
261 | GNUNET_JSON_spec_gnsrecord (struct GNUNET_GNSRECORD_Data **rd, | 262 | GNUNET_GNSRECORD_JSON_spec_gnsrecord (struct GNUNET_GNSRECORD_Data **rd, |
262 | unsigned int *rd_count, | 263 | unsigned int *rd_count, |
263 | char **name) | 264 | char **name) |
264 | { | 265 | { |
@@ -277,3 +278,114 @@ GNUNET_JSON_spec_gnsrecord (struct GNUNET_GNSRECORD_Data **rd, | |||
277 | .size_ptr = NULL }; | 278 | .size_ptr = NULL }; |
278 | return ret; | 279 | return ret; |
279 | } | 280 | } |
281 | |||
282 | |||
283 | /** | ||
284 | * Convert GNS record to JSON. | ||
285 | * | ||
286 | * @param rname name of record | ||
287 | * @param rd record data | ||
288 | * @return corresponding JSON encoding | ||
289 | */ | ||
290 | json_t * | ||
291 | GNUNET_GNSRECORD_JSON_from_gnsrecord (const char*rname, | ||
292 | const struct GNUNET_GNSRECORD_Data *rd, | ||
293 | unsigned int rd_count) | ||
294 | { | ||
295 | struct GNUNET_TIME_Absolute abs_exp; | ||
296 | struct GNUNET_TIME_Relative rel_exp; | ||
297 | const char *expiration_time_str; | ||
298 | const char *record_type_str; | ||
299 | char *value_str; | ||
300 | json_t *data; | ||
301 | json_t *record; | ||
302 | json_t *records; | ||
303 | |||
304 | data = json_object (); | ||
305 | if (NULL == data) | ||
306 | { | ||
307 | GNUNET_break (0); | ||
308 | return NULL; | ||
309 | } | ||
310 | if (0 != | ||
311 | json_object_set_new (data, | ||
312 | "record_name", | ||
313 | json_string (rname))) | ||
314 | { | ||
315 | GNUNET_break (0); | ||
316 | json_decref (data); | ||
317 | return NULL; | ||
318 | } | ||
319 | records = json_array (); | ||
320 | if (NULL == records) | ||
321 | { | ||
322 | GNUNET_break (0); | ||
323 | json_decref (data); | ||
324 | return NULL; | ||
325 | } | ||
326 | for (int i = 0; i < rd_count; i++) | ||
327 | { | ||
328 | value_str = GNUNET_GNSRECORD_value_to_string (rd[i].record_type, | ||
329 | rd[i].data, | ||
330 | rd[i].data_size); | ||
331 | if (GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION & rd[i].flags) | ||
332 | { | ||
333 | rel_exp.rel_value_us = rd[i].expiration_time; | ||
334 | expiration_time_str = GNUNET_STRINGS_relative_time_to_string (rel_exp, | ||
335 | GNUNET_NO); | ||
336 | } | ||
337 | else | ||
338 | { | ||
339 | abs_exp.abs_value_us = rd[i].expiration_time; | ||
340 | expiration_time_str = GNUNET_STRINGS_absolute_time_to_string (abs_exp); | ||
341 | } | ||
342 | record_type_str = GNUNET_GNSRECORD_number_to_typename (rd[i].record_type); | ||
343 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
344 | "Packing %s %s %s %d\n", | ||
345 | value_str, record_type_str, expiration_time_str, rd[i].flags); | ||
346 | record = json_pack ("{s:s,s:s,s:s,s:b,s:b,s:b,s:b}", | ||
347 | "value", | ||
348 | value_str, | ||
349 | "record_type", | ||
350 | record_type_str, | ||
351 | "expiration_time", | ||
352 | expiration_time_str, | ||
353 | "private", | ||
354 | rd[i].flags & GNUNET_GNSRECORD_RF_PRIVATE, | ||
355 | "relative_expiration", | ||
356 | rd[i].flags & GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION, | ||
357 | "supplemental", | ||
358 | rd[i].flags & GNUNET_GNSRECORD_RF_SUPPLEMENTAL, | ||
359 | "shadow", | ||
360 | rd[i].flags & GNUNET_GNSRECORD_RF_SHADOW_RECORD); | ||
361 | GNUNET_free (value_str); | ||
362 | if (NULL == record) | ||
363 | { | ||
364 | GNUNET_break (0); | ||
365 | json_decref (records); | ||
366 | json_decref (data); | ||
367 | return NULL; | ||
368 | } | ||
369 | if (0 != | ||
370 | json_array_append_new (records, | ||
371 | record)) | ||
372 | { | ||
373 | GNUNET_break (0); | ||
374 | json_decref (records); | ||
375 | json_decref (data); | ||
376 | return NULL; | ||
377 | } | ||
378 | } | ||
379 | if (0 != | ||
380 | json_object_set_new (data, | ||
381 | "data", | ||
382 | records)) | ||
383 | { | ||
384 | GNUNET_break (0); | ||
385 | json_decref (data); | ||
386 | return NULL; | ||
387 | } | ||
388 | return data; | ||
389 | } | ||
390 | |||
391 | |||
diff --git a/src/gnsrecord/perf_gnsrecord_crypto.c b/src/gnsrecord/perf_gnsrecord_crypto.c index eb4633f75..d9a3c20cf 100644 --- a/src/gnsrecord/perf_gnsrecord_crypto.c +++ b/src/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_CRYPTO_EcdsaPrivateKey privkey; | 76 | struct GNUNET_IDENTITY_PrivateKey privkey; |
77 | struct GNUNET_TIME_Absolute expire; | 77 | struct GNUNET_TIME_Absolute expire; |
78 | 78 | ||
79 | (void) cls; | 79 | (void) cls; |
@@ -81,7 +81,8 @@ run (void *cls, | |||
81 | (void) cfgfile; | 81 | (void) cfgfile; |
82 | (void) cfg; | 82 | (void) cfg; |
83 | expire = GNUNET_TIME_absolute_get (); | 83 | expire = GNUNET_TIME_absolute_get (); |
84 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 84 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
85 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | ||
85 | 86 | ||
86 | /* test block creation */ | 87 | /* test block creation */ |
87 | s_name = "DUMMY.dummy.gnunet"; | 88 | s_name = "DUMMY.dummy.gnunet"; |
diff --git a/src/gnsrecord/plugin_gnsrecord_dns.c b/src/gnsrecord/plugin_gnsrecord_dns.c index 9ac6fb9e6..bde9944e2 100644 --- a/src/gnsrecord/plugin_gnsrecord_dns.c +++ b/src/gnsrecord/plugin_gnsrecord_dns.c | |||
@@ -100,7 +100,7 @@ dns_value_to_string (void *cls, | |||
100 | return NULL; | 100 | return NULL; |
101 | } | 101 | } |
102 | GNUNET_asprintf (&result, | 102 | GNUNET_asprintf (&result, |
103 | "rname=%s mname=%s %lu,%lu,%lu,%lu,%lu", | 103 | "rname=%s mname=%s %u,%u,%u,%u,%u", |
104 | soa->rname, | 104 | soa->rname, |
105 | soa->mname, | 105 | soa->mname, |
106 | soa->serial, | 106 | soa->serial, |
diff --git a/src/gnsrecord/test_gnsrecord_crypto.c b/src/gnsrecord/test_gnsrecord_crypto.c index b67e9a123..d541f3076 100644 --- a/src/gnsrecord/test_gnsrecord_crypto.c +++ b/src/gnsrecord/test_gnsrecord_crypto.c | |||
@@ -100,17 +100,18 @@ run (void *cls, | |||
100 | const struct GNUNET_CONFIGURATION_Handle *cfg) | 100 | const struct GNUNET_CONFIGURATION_Handle *cfg) |
101 | { | 101 | { |
102 | struct GNUNET_GNSRECORD_Block *block; | 102 | struct GNUNET_GNSRECORD_Block *block; |
103 | struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 103 | struct GNUNET_IDENTITY_PublicKey pubkey; |
104 | struct GNUNET_HashCode query_pub; | 104 | struct GNUNET_HashCode query_pub; |
105 | struct GNUNET_HashCode query_priv; | 105 | struct GNUNET_HashCode query_priv; |
106 | struct GNUNET_TIME_Absolute expire = GNUNET_TIME_absolute_get (); | 106 | struct GNUNET_TIME_Absolute expire = GNUNET_TIME_absolute_get (); |
107 | struct GNUNET_CRYPTO_EcdsaPrivateKey privkey; | 107 | struct GNUNET_IDENTITY_PrivateKey privkey; |
108 | 108 | ||
109 | 109 | ||
110 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 110 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
111 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | ||
111 | /* get public key */ | 112 | /* get public key */ |
112 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, | 113 | GNUNET_IDENTITY_key_get_public (&privkey, |
113 | &pubkey); | 114 | &pubkey); |
114 | 115 | ||
115 | /* test query derivation */ | 116 | /* test query derivation */ |
116 | GNUNET_GNSRECORD_query_from_private_key (&privkey, | 117 | GNUNET_GNSRECORD_query_from_private_key (&privkey, |
diff --git a/src/identity/gnunet-identity.c b/src/identity/gnunet-identity.c index d0f5546f3..a01cd1ed7 100644 --- a/src/identity/gnunet-identity.c +++ b/src/identity/gnunet-identity.c | |||
@@ -66,6 +66,11 @@ static unsigned int verbose; | |||
66 | static int quiet; | 66 | static int quiet; |
67 | 67 | ||
68 | /** | 68 | /** |
69 | * Was "eddsa" specified? | ||
70 | */ | ||
71 | static int type_eddsa; | ||
72 | |||
73 | /** | ||
69 | * -C option | 74 | * -C option |
70 | */ | 75 | */ |
71 | static char *create_ego; | 76 | static char *create_ego; |
@@ -108,7 +113,7 @@ static struct GNUNET_IDENTITY_Operation *delete_op; | |||
108 | /** | 113 | /** |
109 | * Private key from command line option, or NULL. | 114 | * Private key from command line option, or NULL. |
110 | */ | 115 | */ |
111 | struct GNUNET_CRYPTO_EcdsaPrivateKey pk; | 116 | struct GNUNET_IDENTITY_PrivateKey pk; |
112 | 117 | ||
113 | /** | 118 | /** |
114 | * Value to return from #main(). | 119 | * Value to return from #main(). |
@@ -197,7 +202,7 @@ delete_finished (void *cls, | |||
197 | */ | 202 | */ |
198 | static void | 203 | static void |
199 | create_finished (void *cls, | 204 | create_finished (void *cls, |
200 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pk, | 205 | const struct GNUNET_IDENTITY_PrivateKey *pk, |
201 | const char *emsg) | 206 | const char *emsg) |
202 | { | 207 | { |
203 | struct GNUNET_IDENTITY_Operation **op = cls; | 208 | struct GNUNET_IDENTITY_Operation **op = cls; |
@@ -212,16 +217,16 @@ create_finished (void *cls, | |||
212 | } | 217 | } |
213 | else if (verbose) | 218 | else if (verbose) |
214 | { | 219 | { |
215 | struct GNUNET_CRYPTO_EcdsaPublicKey pub; | 220 | struct GNUNET_IDENTITY_PublicKey pub; |
216 | char *pubs; | 221 | char *pubs; |
217 | 222 | ||
218 | GNUNET_CRYPTO_ecdsa_key_get_public (pk, &pub); | 223 | GNUNET_IDENTITY_key_get_public (pk, &pub); |
219 | pubs = GNUNET_CRYPTO_ecdsa_public_key_to_string (&pub); | 224 | pubs = GNUNET_IDENTITY_public_key_to_string (&pub); |
220 | if (private_keys) | 225 | if (private_keys) |
221 | { | 226 | { |
222 | char *privs; | 227 | char *privs; |
223 | 228 | ||
224 | privs = GNUNET_CRYPTO_ecdsa_private_key_to_string (pk); | 229 | privs = GNUNET_IDENTITY_private_key_to_string (pk); |
225 | fprintf (stdout, "%s - %s\n", pubs, privs); | 230 | fprintf (stdout, "%s - %s\n", pubs, privs); |
226 | GNUNET_free (privs); | 231 | GNUNET_free (privs); |
227 | } | 232 | } |
@@ -293,7 +298,7 @@ print_ego (void *cls, | |||
293 | void **ctx, | 298 | void **ctx, |
294 | const char *identifier) | 299 | const char *identifier) |
295 | { | 300 | { |
296 | struct GNUNET_CRYPTO_EcdsaPublicKey pk; | 301 | struct GNUNET_IDENTITY_PublicKey pk; |
297 | char *s; | 302 | char *s; |
298 | char *privs; | 303 | char *privs; |
299 | 304 | ||
@@ -342,8 +347,8 @@ print_ego (void *cls, | |||
342 | set_ego)) ) | 347 | set_ego)) ) |
343 | return; | 348 | return; |
344 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 349 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
345 | s = GNUNET_CRYPTO_ecdsa_public_key_to_string (&pk); | 350 | s = GNUNET_IDENTITY_public_key_to_string (&pk); |
346 | privs = GNUNET_CRYPTO_ecdsa_private_key_to_string ( | 351 | privs = GNUNET_IDENTITY_private_key_to_string ( |
347 | GNUNET_IDENTITY_ego_get_private_key (ego)); | 352 | GNUNET_IDENTITY_ego_get_private_key (ego)); |
348 | if ((monitor) || (NULL != identifier)) | 353 | if ((monitor) || (NULL != identifier)) |
349 | { | 354 | { |
@@ -357,9 +362,16 @@ print_ego (void *cls, | |||
357 | else | 362 | else |
358 | { | 363 | { |
359 | if (private_keys) | 364 | if (private_keys) |
360 | fprintf (stdout, "%s - %s - %s\n", identifier, s, privs); | 365 | fprintf (stdout, "%s - %s - %s - %s\n", |
366 | identifier, s, privs, | ||
367 | (ntohl (pk.type) == GNUNET_IDENTITY_TYPE_ECDSA) ? | ||
368 | "ECDSA" : "EdDSA"); | ||
361 | else | 369 | else |
362 | fprintf (stdout, "%s - %s\n", identifier, s); | 370 | fprintf (stdout, "%s - %s - %s\n", |
371 | identifier, s, | ||
372 | (ntohl (pk.type) == GNUNET_IDENTITY_TYPE_ECDSA) ? | ||
373 | "ECDSA" : "EdDSA"); | ||
374 | |||
363 | } | 375 | } |
364 | } | 376 | } |
365 | GNUNET_free (privs); | 377 | GNUNET_free (privs); |
@@ -407,11 +419,12 @@ run (void *cls, | |||
407 | strlen (privkey_ego), | 419 | strlen (privkey_ego), |
408 | &pk, | 420 | &pk, |
409 | sizeof(struct | 421 | sizeof(struct |
410 | GNUNET_CRYPTO_EcdsaPrivateKey)); | 422 | GNUNET_IDENTITY_PrivateKey)); |
411 | create_op = | 423 | create_op = |
412 | GNUNET_IDENTITY_create (sh, | 424 | GNUNET_IDENTITY_create (sh, |
413 | create_ego, | 425 | create_ego, |
414 | &pk, | 426 | &pk, |
427 | 0, // Ignored | ||
415 | &create_finished, | 428 | &create_finished, |
416 | &create_op); | 429 | &create_op); |
417 | } | 430 | } |
@@ -420,6 +433,9 @@ run (void *cls, | |||
420 | GNUNET_IDENTITY_create (sh, | 433 | GNUNET_IDENTITY_create (sh, |
421 | create_ego, | 434 | create_ego, |
422 | NULL, | 435 | NULL, |
436 | (type_eddsa) ? | ||
437 | GNUNET_IDENTITY_TYPE_EDDSA : | ||
438 | GNUNET_IDENTITY_TYPE_ECDSA, | ||
423 | &create_finished, | 439 | &create_finished, |
424 | &create_op); | 440 | &create_op); |
425 | } | 441 | } |
@@ -456,6 +472,11 @@ main (int argc, char *const *argv) | |||
456 | gettext_noop ( | 472 | gettext_noop ( |
457 | "set the private key for the identity to PRIVATE_KEY (use together with -C)"), | 473 | "set the private key for the identity to PRIVATE_KEY (use together with -C)"), |
458 | &privkey_ego), | 474 | &privkey_ego), |
475 | GNUNET_GETOPT_option_flag ('X', | ||
476 | "eddsa", | ||
477 | gettext_noop ( | ||
478 | "generate an EdDSA identity. (use together with -C) EXPERIMENTAL"), | ||
479 | &type_eddsa), | ||
459 | GNUNET_GETOPT_option_flag ('d', | 480 | GNUNET_GETOPT_option_flag ('d', |
460 | "display", | 481 | "display", |
461 | gettext_noop ("display all egos"), | 482 | gettext_noop ("display all egos"), |
diff --git a/src/identity/gnunet-service-identity.c b/src/identity/gnunet-service-identity.c index bdacf3ba0..6cdb1c2f7 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_CRYPTO_EcdsaPrivateKey pk; | 60 | struct GNUNET_IDENTITY_PrivateKey pk; |
61 | 61 | ||
62 | /** | 62 | /** |
63 | * String identifier for the ego. | 63 | * String identifier for the ego. |
@@ -538,8 +538,8 @@ handle_get_default_message (void *cls, | |||
538 | * @return 0 if the keys are equal | 538 | * @return 0 if the keys are equal |
539 | */ | 539 | */ |
540 | static int | 540 | static int |
541 | key_cmp (const struct GNUNET_CRYPTO_EcdsaPrivateKey *pk1, | 541 | key_cmp (const struct GNUNET_IDENTITY_PrivateKey *pk1, |
542 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pk2) | 542 | const struct GNUNET_IDENTITY_PrivateKey *pk2) |
543 | { | 543 | { |
544 | return GNUNET_memcmp (pk1, pk2); | 544 | return GNUNET_memcmp (pk1, pk2); |
545 | } | 545 | } |
@@ -738,10 +738,10 @@ handle_create_message (void *cls, | |||
738 | send_result_code (client, 0, NULL); | 738 | send_result_code (client, 0, NULL); |
739 | fn = get_ego_filename (ego); | 739 | fn = get_ego_filename (ego); |
740 | (void) GNUNET_DISK_directory_create_for_file (fn); | 740 | (void) GNUNET_DISK_directory_create_for_file (fn); |
741 | if (sizeof(struct GNUNET_CRYPTO_EcdsaPrivateKey) != | 741 | if (sizeof(struct GNUNET_IDENTITY_PrivateKey) != |
742 | GNUNET_DISK_fn_write (fn, | 742 | GNUNET_DISK_fn_write (fn, |
743 | &crm->private_key, | 743 | &crm->private_key, |
744 | sizeof(struct GNUNET_CRYPTO_EcdsaPrivateKey), | 744 | sizeof(struct GNUNET_IDENTITY_PrivateKey), |
745 | GNUNET_DISK_PERM_USER_READ | 745 | GNUNET_DISK_PERM_USER_READ |
746 | | GNUNET_DISK_PERM_USER_WRITE)) | 746 | | GNUNET_DISK_PERM_USER_WRITE)) |
747 | GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_ERROR, "write", fn); | 747 | GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_ERROR, "write", fn); |
@@ -1038,6 +1038,67 @@ handle_delete_message (void *cls, const struct DeleteMessage *dm) | |||
1038 | } | 1038 | } |
1039 | 1039 | ||
1040 | 1040 | ||
1041 | static int | ||
1042 | read_from_file (const char *filename, | ||
1043 | void *buf, | ||
1044 | size_t buf_size) | ||
1045 | { | ||
1046 | int fd; | ||
1047 | struct stat sb; | ||
1048 | |||
1049 | fd = open (filename, | ||
1050 | O_RDONLY); | ||
1051 | if (-1 == fd) | ||
1052 | { | ||
1053 | memset (buf, | ||
1054 | 0, | ||
1055 | buf_size); | ||
1056 | return GNUNET_SYSERR; | ||
1057 | } | ||
1058 | if (0 != fstat (fd, | ||
1059 | &sb)) | ||
1060 | { | ||
1061 | GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_WARNING, | ||
1062 | "stat", | ||
1063 | filename); | ||
1064 | GNUNET_assert (0 == close (fd)); | ||
1065 | memset (buf, | ||
1066 | 0, | ||
1067 | buf_size); | ||
1068 | return GNUNET_SYSERR; | ||
1069 | } | ||
1070 | if (sb.st_size != buf_size) | ||
1071 | { | ||
1072 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | ||
1073 | "File `%s' has wrong size (%llu), expected %llu bytes\n", | ||
1074 | filename, | ||
1075 | (unsigned long long) sb.st_size, | ||
1076 | (unsigned long long) buf_size); | ||
1077 | GNUNET_assert (0 == close (fd)); | ||
1078 | memset (buf, | ||
1079 | 0, | ||
1080 | buf_size); | ||
1081 | return GNUNET_SYSERR; | ||
1082 | } | ||
1083 | if (buf_size != | ||
1084 | read (fd, | ||
1085 | buf, | ||
1086 | buf_size)) | ||
1087 | { | ||
1088 | GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_WARNING, | ||
1089 | "read", | ||
1090 | filename); | ||
1091 | GNUNET_assert (0 == close (fd)); | ||
1092 | memset (buf, | ||
1093 | 0, | ||
1094 | buf_size); | ||
1095 | return GNUNET_SYSERR; | ||
1096 | } | ||
1097 | GNUNET_assert (0 == close (fd)); | ||
1098 | return GNUNET_OK; | ||
1099 | } | ||
1100 | |||
1101 | |||
1041 | /** | 1102 | /** |
1042 | * Process the given file from the "EGODIR". Parses the file | 1103 | * Process the given file from the "EGODIR". Parses the file |
1043 | * and creates the respective 'struct Ego' in memory. | 1104 | * and creates the respective 'struct Ego' in memory. |
@@ -1063,9 +1124,9 @@ process_ego_file (void *cls, | |||
1063 | } | 1124 | } |
1064 | ego = GNUNET_new (struct Ego); | 1125 | ego = GNUNET_new (struct Ego); |
1065 | if (GNUNET_OK != | 1126 | if (GNUNET_OK != |
1066 | GNUNET_CRYPTO_ecdsa_key_from_file (filename, | 1127 | read_from_file (filename, |
1067 | GNUNET_NO, | 1128 | &ego->pk, |
1068 | &ego->pk)) | 1129 | sizeof (ego->pk))) |
1069 | { | 1130 | { |
1070 | GNUNET_free (ego); | 1131 | GNUNET_free (ego); |
1071 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | 1132 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, |
diff --git a/src/identity/identity.h b/src/identity/identity.h index ef638fa36..11c5883bc 100644 --- a/src/identity/identity.h +++ b/src/identity/identity.h | |||
@@ -30,6 +30,44 @@ | |||
30 | 30 | ||
31 | #include "gnunet_common.h" | 31 | #include "gnunet_common.h" |
32 | 32 | ||
33 | /** | ||
34 | * Handle for an ego. | ||
35 | */ | ||
36 | struct GNUNET_IDENTITY_Ego | ||
37 | { | ||
38 | /** | ||
39 | * Hash of the private key of this ego. | ||
40 | */ | ||
41 | struct GNUNET_HashCode id; | ||
42 | |||
43 | /** | ||
44 | * The identity key pair | ||
45 | */ | ||
46 | struct GNUNET_IDENTITY_PublicKey pub; | ||
47 | |||
48 | /** | ||
49 | * The identity key pair | ||
50 | */ | ||
51 | struct GNUNET_IDENTITY_PrivateKey pk; | ||
52 | |||
53 | /** | ||
54 | * Current name associated with this ego. | ||
55 | */ | ||
56 | char *name; | ||
57 | |||
58 | /** | ||
59 | * Client context associated with this ego. | ||
60 | */ | ||
61 | void *ctx; | ||
62 | |||
63 | /** | ||
64 | * Set to true once @e pub was initialized | ||
65 | */ | ||
66 | bool pub_initialized; | ||
67 | }; | ||
68 | |||
69 | |||
70 | |||
33 | 71 | ||
34 | GNUNET_NETWORK_STRUCT_BEGIN | 72 | GNUNET_NETWORK_STRUCT_BEGIN |
35 | 73 | ||
@@ -95,7 +133,7 @@ struct UpdateMessage | |||
95 | /** | 133 | /** |
96 | * The private key | 134 | * The private key |
97 | */ | 135 | */ |
98 | struct GNUNET_CRYPTO_EcdsaPrivateKey private_key; | 136 | struct GNUNET_IDENTITY_PrivateKey private_key; |
99 | 137 | ||
100 | /* followed by 0-terminated ego name */ | 138 | /* followed by 0-terminated ego name */ |
101 | }; | 139 | }; |
@@ -151,7 +189,7 @@ struct SetDefaultMessage | |||
151 | /** | 189 | /** |
152 | * The private key | 190 | * The private key |
153 | */ | 191 | */ |
154 | struct GNUNET_CRYPTO_EcdsaPrivateKey private_key; | 192 | struct GNUNET_IDENTITY_PrivateKey private_key; |
155 | 193 | ||
156 | /* followed by 0-terminated service name */ | 194 | /* followed by 0-terminated service name */ |
157 | }; | 195 | }; |
@@ -181,7 +219,7 @@ struct CreateRequestMessage | |||
181 | /** | 219 | /** |
182 | * The private key | 220 | * The private key |
183 | */ | 221 | */ |
184 | struct GNUNET_CRYPTO_EcdsaPrivateKey private_key; | 222 | struct GNUNET_IDENTITY_PrivateKey private_key; |
185 | 223 | ||
186 | /* followed by 0-terminated identity name */ | 224 | /* followed by 0-terminated identity name */ |
187 | }; | 225 | }; |
@@ -239,42 +277,5 @@ struct DeleteMessage | |||
239 | 277 | ||
240 | GNUNET_NETWORK_STRUCT_END | 278 | GNUNET_NETWORK_STRUCT_END |
241 | 279 | ||
242 | /** | ||
243 | * Handle for an ego. | ||
244 | */ | ||
245 | struct GNUNET_IDENTITY_Ego | ||
246 | { | ||
247 | /** | ||
248 | * Hash of the private key of this ego. | ||
249 | */ | ||
250 | struct GNUNET_HashCode id; | ||
251 | |||
252 | /** | ||
253 | * Private key associated with this ego. | ||
254 | */ | ||
255 | struct GNUNET_CRYPTO_EcdsaPrivateKey pk; | ||
256 | |||
257 | /** | ||
258 | * Public key associated with this ego. Initialized on demand. | ||
259 | * Always use #GNUNET_IDENTITY_ego_get_public_key() to obtain. | ||
260 | */ | ||
261 | struct GNUNET_CRYPTO_EcdsaPublicKey pub; | ||
262 | |||
263 | /** | ||
264 | * Current name associated with this ego. | ||
265 | */ | ||
266 | char *name; | ||
267 | |||
268 | /** | ||
269 | * Client context associated with this ego. | ||
270 | */ | ||
271 | void *ctx; | ||
272 | |||
273 | /** | ||
274 | * Set to true once @e pub was initialized | ||
275 | */ | ||
276 | bool pub_initialized; | ||
277 | }; | ||
278 | |||
279 | 280 | ||
280 | #endif | 281 | #endif |
diff --git a/src/identity/identity_api.c b/src/identity/identity_api.c index f7aca1655..64c088923 100644 --- a/src/identity/identity_api.c +++ b/src/identity/identity_api.c | |||
@@ -74,7 +74,7 @@ struct GNUNET_IDENTITY_Operation | |||
74 | /** | 74 | /** |
75 | * Private key to return to @e create_cont, or NULL. | 75 | * Private key to return to @e create_cont, or NULL. |
76 | */ | 76 | */ |
77 | struct GNUNET_CRYPTO_EcdsaPrivateKey pk; | 77 | struct GNUNET_IDENTITY_PrivateKey pk; |
78 | 78 | ||
79 | /** | 79 | /** |
80 | * Continuation to invoke with the result of the transmission for | 80 | * Continuation to invoke with the result of the transmission for |
@@ -157,13 +157,12 @@ GNUNET_IDENTITY_ego_get_anonymous () | |||
157 | { | 157 | { |
158 | static struct GNUNET_IDENTITY_Ego anon; | 158 | static struct GNUNET_IDENTITY_Ego anon; |
159 | static int setup; | 159 | static int setup; |
160 | struct GNUNET_CRYPTO_EcdsaPublicKey pub; | ||
161 | 160 | ||
162 | if (setup) | 161 | if (setup) |
163 | return &anon; | 162 | return &anon; |
164 | anon.pk = *GNUNET_CRYPTO_ecdsa_key_get_anonymous (); | 163 | anon.pk.type = htonl (GNUNET_IDENTITY_TYPE_ECDSA); |
165 | GNUNET_CRYPTO_ecdsa_key_get_public (&anon.pk, | 164 | anon.pub.type = htonl (GNUNET_IDENTITY_TYPE_ECDSA); |
166 | &pub); | 165 | anon.pk.ecdsa_key = *GNUNET_CRYPTO_ecdsa_key_get_anonymous (); |
167 | GNUNET_CRYPTO_hash (&anon.pk, | 166 | GNUNET_CRYPTO_hash (&anon.pk, |
168 | sizeof(anon.pk), | 167 | sizeof(anon.pk), |
169 | &anon.id); | 168 | &anon.id); |
@@ -172,6 +171,51 @@ GNUNET_IDENTITY_ego_get_anonymous () | |||
172 | } | 171 | } |
173 | 172 | ||
174 | 173 | ||
174 | enum GNUNET_GenericReturnValue | ||
175 | GNUNET_IDENTITY_key_get_public (const struct | ||
176 | GNUNET_IDENTITY_PrivateKey *privkey, | ||
177 | struct GNUNET_IDENTITY_PublicKey *key) | ||
178 | { | ||
179 | key->type = privkey->type; | ||
180 | switch (ntohl (privkey->type)) | ||
181 | { | ||
182 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
183 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey->ecdsa_key, | ||
184 | &key->ecdsa_key); | ||
185 | break; | ||
186 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
187 | GNUNET_CRYPTO_eddsa_key_get_public (&privkey->eddsa_key, | ||
188 | &key->eddsa_key); | ||
189 | break; | ||
190 | default: | ||
191 | GNUNET_break (0); | ||
192 | return GNUNET_SYSERR; | ||
193 | } | ||
194 | return GNUNET_OK; | ||
195 | } | ||
196 | |||
197 | |||
198 | static int | ||
199 | private_key_create (enum GNUNET_IDENTITY_KeyType ktype, | ||
200 | struct GNUNET_IDENTITY_PrivateKey *key) | ||
201 | { | ||
202 | key->type = htonl (ktype); | ||
203 | switch (ktype) | ||
204 | { | ||
205 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
206 | GNUNET_CRYPTO_ecdsa_key_create (&key->ecdsa_key); | ||
207 | break; | ||
208 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
209 | GNUNET_CRYPTO_eddsa_key_create (&key->eddsa_key); | ||
210 | break; | ||
211 | default: | ||
212 | GNUNET_break (0); | ||
213 | return GNUNET_SYSERR; | ||
214 | } | ||
215 | return GNUNET_OK; | ||
216 | } | ||
217 | |||
218 | |||
175 | /** | 219 | /** |
176 | * Try again to connect to the identity service. | 220 | * Try again to connect to the identity service. |
177 | * | 221 | * |
@@ -591,7 +635,7 @@ GNUNET_IDENTITY_connect (const struct GNUNET_CONFIGURATION_Handle *cfg, | |||
591 | * @param ego the ego | 635 | * @param ego the ego |
592 | * @return associated ECC key, valid as long as the ego is valid | 636 | * @return associated ECC key, valid as long as the ego is valid |
593 | */ | 637 | */ |
594 | const struct GNUNET_CRYPTO_EcdsaPrivateKey * | 638 | const struct GNUNET_IDENTITY_PrivateKey * |
595 | GNUNET_IDENTITY_ego_get_private_key (const struct GNUNET_IDENTITY_Ego *ego) | 639 | GNUNET_IDENTITY_ego_get_private_key (const struct GNUNET_IDENTITY_Ego *ego) |
596 | { | 640 | { |
597 | return &ego->pk; | 641 | return &ego->pk; |
@@ -606,12 +650,11 @@ GNUNET_IDENTITY_ego_get_private_key (const struct GNUNET_IDENTITY_Ego *ego) | |||
606 | */ | 650 | */ |
607 | void | 651 | void |
608 | GNUNET_IDENTITY_ego_get_public_key (struct GNUNET_IDENTITY_Ego *ego, | 652 | GNUNET_IDENTITY_ego_get_public_key (struct GNUNET_IDENTITY_Ego *ego, |
609 | struct GNUNET_CRYPTO_EcdsaPublicKey *pk) | 653 | struct GNUNET_IDENTITY_PublicKey *pk) |
610 | { | 654 | { |
611 | if (GNUNET_NO == ego->pub_initialized) | 655 | if (GNUNET_NO == ego->pub_initialized) |
612 | { | 656 | { |
613 | GNUNET_CRYPTO_ecdsa_key_get_public (&ego->pk, | 657 | GNUNET_IDENTITY_key_get_public (&ego->pk, &ego->pub); |
614 | &ego->pub); | ||
615 | ego->pub_initialized = GNUNET_YES; | 658 | ego->pub_initialized = GNUNET_YES; |
616 | } | 659 | } |
617 | *pk = ego->pub; | 660 | *pk = ego->pub; |
@@ -710,20 +753,11 @@ GNUNET_IDENTITY_set (struct GNUNET_IDENTITY_Handle *h, | |||
710 | } | 753 | } |
711 | 754 | ||
712 | 755 | ||
713 | /** | ||
714 | * Create a new identity with the given name. | ||
715 | * | ||
716 | * @param h identity service to use | ||
717 | * @param name desired name | ||
718 | * @param privkey desired private key or NULL to create one | ||
719 | * @param cont function to call with the result (will only be called once) | ||
720 | * @param cont_cls closure for @a cont | ||
721 | * @return handle to abort the operation | ||
722 | */ | ||
723 | struct GNUNET_IDENTITY_Operation * | 756 | struct GNUNET_IDENTITY_Operation * |
724 | GNUNET_IDENTITY_create (struct GNUNET_IDENTITY_Handle *h, | 757 | GNUNET_IDENTITY_create (struct GNUNET_IDENTITY_Handle *h, |
725 | const char *name, | 758 | const char *name, |
726 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *privkey, | 759 | const struct GNUNET_IDENTITY_PrivateKey *privkey, |
760 | enum GNUNET_IDENTITY_KeyType ktype, | ||
727 | GNUNET_IDENTITY_CreateContinuation cont, | 761 | GNUNET_IDENTITY_CreateContinuation cont, |
728 | void *cont_cls) | 762 | void *cont_cls) |
729 | { | 763 | { |
@@ -749,7 +783,10 @@ GNUNET_IDENTITY_create (struct GNUNET_IDENTITY_Handle *h, | |||
749 | crm->name_len = htons (slen); | 783 | crm->name_len = htons (slen); |
750 | crm->reserved = htons (0); | 784 | crm->reserved = htons (0); |
751 | if (NULL == privkey) | 785 | if (NULL == privkey) |
752 | GNUNET_CRYPTO_ecdsa_key_create (&crm->private_key); | 786 | { |
787 | GNUNET_assert (GNUNET_OK == | ||
788 | private_key_create (ktype, &crm->private_key)); | ||
789 | } | ||
753 | else | 790 | else |
754 | crm->private_key = *privkey; | 791 | crm->private_key = *privkey; |
755 | op->pk = crm->private_key; | 792 | op->pk = crm->private_key; |
@@ -917,4 +954,316 @@ GNUNET_IDENTITY_disconnect (struct GNUNET_IDENTITY_Handle *h) | |||
917 | } | 954 | } |
918 | 955 | ||
919 | 956 | ||
957 | ssize_t | ||
958 | private_key_get_length (const struct GNUNET_IDENTITY_PrivateKey *key) | ||
959 | { | ||
960 | switch (ntohl (key->type)) | ||
961 | { | ||
962 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
963 | return sizeof (key->type) + sizeof (key->ecdsa_key); | ||
964 | break; | ||
965 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
966 | return sizeof (key->type) + sizeof (key->eddsa_key); | ||
967 | break; | ||
968 | default: | ||
969 | GNUNET_break (0); | ||
970 | } | ||
971 | return -1; | ||
972 | } | ||
973 | |||
974 | |||
975 | ssize_t | ||
976 | GNUNET_IDENTITY_key_get_length (const struct GNUNET_IDENTITY_PublicKey *key) | ||
977 | { | ||
978 | switch (ntohl (key->type)) | ||
979 | { | ||
980 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
981 | return sizeof (key->type) + sizeof (key->ecdsa_key); | ||
982 | break; | ||
983 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
984 | return sizeof (key->type) + sizeof (key->eddsa_key); | ||
985 | break; | ||
986 | default: | ||
987 | GNUNET_break (0); | ||
988 | } | ||
989 | return -1; | ||
990 | } | ||
991 | |||
992 | |||
993 | ssize_t | ||
994 | GNUNET_IDENTITY_read_key_from_buffer (struct GNUNET_IDENTITY_PublicKey *key, | ||
995 | const void*buffer, | ||
996 | size_t len) | ||
997 | { | ||
998 | if (len < sizeof (key->type)) | ||
999 | return -1; | ||
1000 | GNUNET_memcpy (&(key->type), buffer, sizeof (key->type)); | ||
1001 | const ssize_t length = GNUNET_IDENTITY_key_get_length (key); | ||
1002 | if (len < length) | ||
1003 | return -1; | ||
1004 | if (length < 0) | ||
1005 | return -2; | ||
1006 | GNUNET_memcpy (&(key->ecdsa_key), buffer + sizeof (key->type), length | ||
1007 | - sizeof (key->type)); | ||
1008 | return length; | ||
1009 | } | ||
1010 | |||
1011 | |||
1012 | ssize_t | ||
1013 | GNUNET_IDENTITY_write_key_to_buffer (const struct | ||
1014 | GNUNET_IDENTITY_PublicKey *key, | ||
1015 | void*buffer, | ||
1016 | size_t len) | ||
1017 | { | ||
1018 | const ssize_t length = GNUNET_IDENTITY_key_get_length (key); | ||
1019 | if (len < length) | ||
1020 | return -1; | ||
1021 | if (length < 0) | ||
1022 | return -2; | ||
1023 | GNUNET_memcpy (buffer, key, length); | ||
1024 | return length; | ||
1025 | } | ||
1026 | |||
1027 | |||
1028 | ssize_t | ||
1029 | GNUNET_IDENTITY_signature_get_length (const struct | ||
1030 | GNUNET_IDENTITY_Signature *sig) | ||
1031 | { | ||
1032 | switch (ntohl (sig->type)) | ||
1033 | { | ||
1034 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
1035 | return sizeof (sig->type) + sizeof (sig->ecdsa_signature); | ||
1036 | break; | ||
1037 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
1038 | return sizeof (sig->type) + sizeof (sig->eddsa_signature); | ||
1039 | break; | ||
1040 | default: | ||
1041 | GNUNET_break (0); | ||
1042 | } | ||
1043 | return -1; | ||
1044 | } | ||
1045 | |||
1046 | |||
1047 | ssize_t | ||
1048 | GNUNET_IDENTITY_read_signature_from_buffer (struct | ||
1049 | GNUNET_IDENTITY_Signature *sig, | ||
1050 | const void*buffer, | ||
1051 | size_t len) | ||
1052 | { | ||
1053 | if (len < sizeof (sig->type)) | ||
1054 | return -1; | ||
1055 | GNUNET_memcpy (&(sig->type), buffer, sizeof (sig->type)); | ||
1056 | const ssize_t length = GNUNET_IDENTITY_signature_get_length (sig); | ||
1057 | if (len < length) | ||
1058 | return -1; | ||
1059 | if (length < 0) | ||
1060 | return -2; | ||
1061 | GNUNET_memcpy (&(sig->ecdsa_signature), buffer + sizeof (sig->type), length | ||
1062 | - sizeof (sig->type)); | ||
1063 | return length; | ||
1064 | } | ||
1065 | |||
1066 | |||
1067 | ssize_t | ||
1068 | GNUNET_IDENTITY_write_signature_to_buffer (const struct | ||
1069 | GNUNET_IDENTITY_Signature *sig, | ||
1070 | void*buffer, | ||
1071 | size_t len) | ||
1072 | { | ||
1073 | const ssize_t length = GNUNET_IDENTITY_signature_get_length (sig); | ||
1074 | if (len < length) | ||
1075 | return -1; | ||
1076 | if (length < 0) | ||
1077 | return -2; | ||
1078 | GNUNET_memcpy (buffer, &(sig->type), sizeof (sig->type)); | ||
1079 | GNUNET_memcpy (buffer + sizeof (sig->type), &(sig->ecdsa_signature), length | ||
1080 | - sizeof (sig->type)); | ||
1081 | return length; | ||
1082 | } | ||
1083 | |||
1084 | |||
1085 | int | ||
1086 | GNUNET_IDENTITY_sign_ (const struct | ||
1087 | GNUNET_IDENTITY_PrivateKey *priv, | ||
1088 | const struct | ||
1089 | GNUNET_CRYPTO_EccSignaturePurpose *purpose, | ||
1090 | struct GNUNET_IDENTITY_Signature *sig) | ||
1091 | { | ||
1092 | sig->type = priv->type; | ||
1093 | switch (ntohl (priv->type)) | ||
1094 | { | ||
1095 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
1096 | return GNUNET_CRYPTO_ecdsa_sign_ (&(priv->ecdsa_key), purpose, | ||
1097 | &(sig->ecdsa_signature)); | ||
1098 | break; | ||
1099 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
1100 | return GNUNET_CRYPTO_eddsa_sign_ (&(priv->eddsa_key), purpose, | ||
1101 | &(sig->eddsa_signature)); | ||
1102 | break; | ||
1103 | default: | ||
1104 | GNUNET_break (0); | ||
1105 | } | ||
1106 | |||
1107 | return GNUNET_SYSERR; | ||
1108 | } | ||
1109 | |||
1110 | |||
1111 | int | ||
1112 | GNUNET_IDENTITY_signature_verify_ (uint32_t purpose, | ||
1113 | const struct | ||
1114 | GNUNET_CRYPTO_EccSignaturePurpose *validate, | ||
1115 | const struct GNUNET_IDENTITY_Signature *sig, | ||
1116 | const struct GNUNET_IDENTITY_PublicKey *pub) | ||
1117 | { | ||
1118 | /* check type matching of 'sig' and 'pub' */ | ||
1119 | GNUNET_assert (ntohl (pub->type) == ntohl (sig->type)); | ||
1120 | switch (ntohl (pub->type)) | ||
1121 | { | ||
1122 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
1123 | return GNUNET_CRYPTO_ecdsa_verify_ (purpose, validate, | ||
1124 | &(sig->ecdsa_signature), | ||
1125 | &(pub->ecdsa_key)); | ||
1126 | break; | ||
1127 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
1128 | return GNUNET_CRYPTO_eddsa_verify_ (purpose, validate, | ||
1129 | &(sig->eddsa_signature), | ||
1130 | &(pub->eddsa_key)); | ||
1131 | break; | ||
1132 | default: | ||
1133 | GNUNET_break (0); | ||
1134 | } | ||
1135 | |||
1136 | return GNUNET_SYSERR; | ||
1137 | } | ||
1138 | |||
1139 | |||
1140 | ssize_t | ||
1141 | GNUNET_IDENTITY_encrypt (const void *block, | ||
1142 | size_t size, | ||
1143 | const struct GNUNET_IDENTITY_PublicKey *pub, | ||
1144 | struct GNUNET_CRYPTO_EcdhePublicKey *ecc, | ||
1145 | void *result) | ||
1146 | { | ||
1147 | struct GNUNET_CRYPTO_EcdhePrivateKey pk; | ||
1148 | GNUNET_CRYPTO_ecdhe_key_create (&pk); | ||
1149 | struct GNUNET_HashCode hash; | ||
1150 | switch (ntohl (pub->type)) | ||
1151 | { | ||
1152 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
1153 | if (GNUNET_SYSERR == GNUNET_CRYPTO_ecdh_ecdsa (&pk, &(pub->ecdsa_key), | ||
1154 | &hash)) | ||
1155 | return -1; | ||
1156 | break; | ||
1157 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
1158 | if (GNUNET_SYSERR == GNUNET_CRYPTO_ecdh_eddsa (&pk, &(pub->eddsa_key), | ||
1159 | &hash)) | ||
1160 | return -1; | ||
1161 | break; | ||
1162 | default: | ||
1163 | return -1; | ||
1164 | } | ||
1165 | GNUNET_CRYPTO_ecdhe_key_get_public (&pk, ecc); | ||
1166 | GNUNET_CRYPTO_ecdhe_key_clear (&pk); | ||
1167 | struct GNUNET_CRYPTO_SymmetricSessionKey key; | ||
1168 | struct GNUNET_CRYPTO_SymmetricInitializationVector iv; | ||
1169 | GNUNET_CRYPTO_hash_to_aes_key (&hash, &key, &iv); | ||
1170 | GNUNET_CRYPTO_zero_keys (&hash, sizeof(hash)); | ||
1171 | const ssize_t encrypted = GNUNET_CRYPTO_symmetric_encrypt (block, size, &key, | ||
1172 | &iv, result); | ||
1173 | GNUNET_CRYPTO_zero_keys (&key, sizeof(key)); | ||
1174 | GNUNET_CRYPTO_zero_keys (&iv, sizeof(iv)); | ||
1175 | return encrypted; | ||
1176 | } | ||
1177 | |||
1178 | |||
1179 | ssize_t | ||
1180 | GNUNET_IDENTITY_decrypt (const void *block, | ||
1181 | size_t size, | ||
1182 | const struct GNUNET_IDENTITY_PrivateKey *priv, | ||
1183 | const struct GNUNET_CRYPTO_EcdhePublicKey *ecc, | ||
1184 | void *result) | ||
1185 | { | ||
1186 | struct GNUNET_HashCode hash; | ||
1187 | switch (ntohl (priv->type)) | ||
1188 | { | ||
1189 | case GNUNET_IDENTITY_TYPE_ECDSA: | ||
1190 | if (GNUNET_SYSERR == GNUNET_CRYPTO_ecdsa_ecdh (&(priv->ecdsa_key), ecc, | ||
1191 | &hash)) | ||
1192 | return -1; | ||
1193 | break; | ||
1194 | case GNUNET_IDENTITY_TYPE_EDDSA: | ||
1195 | if (GNUNET_SYSERR == GNUNET_CRYPTO_eddsa_ecdh (&(priv->eddsa_key), ecc, | ||
1196 | &hash)) | ||
1197 | return -1; | ||
1198 | break; | ||
1199 | default: | ||
1200 | return -1; | ||
1201 | } | ||
1202 | struct GNUNET_CRYPTO_SymmetricSessionKey key; | ||
1203 | struct GNUNET_CRYPTO_SymmetricInitializationVector iv; | ||
1204 | GNUNET_CRYPTO_hash_to_aes_key (&hash, &key, &iv); | ||
1205 | GNUNET_CRYPTO_zero_keys (&hash, sizeof(hash)); | ||
1206 | const ssize_t decrypted = GNUNET_CRYPTO_symmetric_decrypt (block, size, &key, | ||
1207 | &iv, result); | ||
1208 | GNUNET_CRYPTO_zero_keys (&key, sizeof(key)); | ||
1209 | GNUNET_CRYPTO_zero_keys (&iv, sizeof(iv)); | ||
1210 | return decrypted; | ||
1211 | } | ||
1212 | |||
1213 | |||
1214 | char * | ||
1215 | GNUNET_IDENTITY_public_key_to_string (const struct | ||
1216 | GNUNET_IDENTITY_PublicKey *key) | ||
1217 | { | ||
1218 | size_t size = GNUNET_IDENTITY_key_get_length (key); | ||
1219 | return GNUNET_STRINGS_data_to_string_alloc (key, | ||
1220 | size); | ||
1221 | } | ||
1222 | |||
1223 | |||
1224 | char * | ||
1225 | GNUNET_IDENTITY_private_key_to_string (const struct | ||
1226 | GNUNET_IDENTITY_PrivateKey *key) | ||
1227 | { | ||
1228 | size_t size = private_key_get_length (key); | ||
1229 | return GNUNET_STRINGS_data_to_string_alloc (key, | ||
1230 | size); | ||
1231 | } | ||
1232 | |||
1233 | |||
1234 | enum GNUNET_GenericReturnValue | ||
1235 | GNUNET_IDENTITY_public_key_from_string (const char *str, | ||
1236 | struct GNUNET_IDENTITY_PublicKey *key) | ||
1237 | { | ||
1238 | enum GNUNET_GenericReturnValue ret; | ||
1239 | enum GNUNET_IDENTITY_KeyType ktype; | ||
1240 | ret = GNUNET_STRINGS_string_to_data (str, | ||
1241 | strlen (str), | ||
1242 | key, | ||
1243 | sizeof (*key)); | ||
1244 | if (GNUNET_OK != ret) | ||
1245 | return GNUNET_SYSERR; | ||
1246 | ktype = ntohl (key->type); | ||
1247 | return (GNUNET_IDENTITY_TYPE_ECDSA == ktype) ? GNUNET_OK : GNUNET_SYSERR; // FIXME other keys, cleaner way? | ||
1248 | |||
1249 | } | ||
1250 | |||
1251 | |||
1252 | enum GNUNET_GenericReturnValue | ||
1253 | GNUNET_IDENTITY_private_key_from_string (const char *str, | ||
1254 | struct GNUNET_IDENTITY_PrivateKey *key) | ||
1255 | { | ||
1256 | enum GNUNET_GenericReturnValue ret; | ||
1257 | enum GNUNET_IDENTITY_KeyType ktype; | ||
1258 | ret = GNUNET_STRINGS_string_to_data (str, | ||
1259 | strlen (str), | ||
1260 | key, | ||
1261 | sizeof (*key)); | ||
1262 | if (GNUNET_OK != ret) | ||
1263 | return GNUNET_SYSERR; | ||
1264 | ktype = ntohl (key->type); | ||
1265 | return (GNUNET_IDENTITY_TYPE_ECDSA == ktype) ? GNUNET_OK : GNUNET_SYSERR; // FIXME other keys, cleaner way? | ||
1266 | } | ||
1267 | |||
1268 | |||
920 | /* end of identity_api.c */ | 1269 | /* end of identity_api.c */ |
diff --git a/src/identity/identity_api_lookup.c b/src/identity/identity_api_lookup.c index 26b1eacd7..51afb2515 100644 --- a/src/identity/identity_api_lookup.c +++ b/src/identity/identity_api_lookup.c | |||
@@ -127,14 +127,12 @@ handle_identity_update (void *cls, const struct UpdateMessage *um) | |||
127 | struct GNUNET_IDENTITY_EgoLookup *el = cls; | 127 | struct GNUNET_IDENTITY_EgoLookup *el = cls; |
128 | uint16_t name_len = ntohs (um->name_len); | 128 | uint16_t name_len = ntohs (um->name_len); |
129 | const char *str = (0 == name_len) ? NULL : (const char *) &um[1]; | 129 | const char *str = (0 == name_len) ? NULL : (const char *) &um[1]; |
130 | struct GNUNET_CRYPTO_EcdsaPublicKey pub; | ||
131 | struct GNUNET_HashCode id; | 130 | struct GNUNET_HashCode id; |
132 | struct GNUNET_IDENTITY_Ego ego; | 131 | struct GNUNET_IDENTITY_Ego ego; |
133 | memset (&ego, 0, sizeof (ego)); | 132 | memset (&ego, 0, sizeof (ego)); |
134 | 133 | ||
135 | GNUNET_break (GNUNET_YES != ntohs (um->end_of_list)); | 134 | GNUNET_break (GNUNET_YES != ntohs (um->end_of_list)); |
136 | GNUNET_CRYPTO_ecdsa_key_get_public (&um->private_key, &pub); | 135 | GNUNET_CRYPTO_hash (&um->private_key, sizeof(um->private_key), &id); |
137 | GNUNET_CRYPTO_hash (&pub, sizeof(pub), &id); | ||
138 | ego.pk = um->private_key; | 136 | ego.pk = um->private_key; |
139 | ego.name = (char *) str; | 137 | ego.name = (char *) str; |
140 | ego.id = id; | 138 | ego.id = id; |
diff --git a/src/identity/plugin_rest_identity.c b/src/identity/plugin_rest_identity.c index d86d29e36..dba1d478d 100644 --- a/src/identity/plugin_rest_identity.c +++ b/src/identity/plugin_rest_identity.c | |||
@@ -384,7 +384,7 @@ ego_get_for_subsystem (void *cls, | |||
384 | { | 384 | { |
385 | struct RequestHandle *handle = cls; | 385 | struct RequestHandle *handle = cls; |
386 | struct MHD_Response *resp; | 386 | struct MHD_Response *resp; |
387 | struct GNUNET_CRYPTO_EcdsaPublicKey public_key; | 387 | struct GNUNET_IDENTITY_PublicKey public_key; |
388 | json_t *json_root; | 388 | json_t *json_root; |
389 | char *result_str; | 389 | char *result_str; |
390 | char *public_key_string; | 390 | char *public_key_string; |
@@ -398,7 +398,7 @@ ego_get_for_subsystem (void *cls, | |||
398 | } | 398 | } |
399 | 399 | ||
400 | GNUNET_IDENTITY_ego_get_public_key (ego, &public_key); | 400 | GNUNET_IDENTITY_ego_get_public_key (ego, &public_key); |
401 | public_key_string = GNUNET_CRYPTO_ecdsa_public_key_to_string (&public_key); | 401 | public_key_string = GNUNET_IDENTITY_public_key_to_string (&public_key); |
402 | 402 | ||
403 | // create json with subsystem identity | 403 | // create json with subsystem identity |
404 | json_root = json_object (); | 404 | json_root = json_object (); |
@@ -496,7 +496,7 @@ ego_get_all (struct GNUNET_REST_RequestHandle *con_handle, | |||
496 | GNUNET_CONTAINER_multihashmap_contains ( | 496 | GNUNET_CONTAINER_multihashmap_contains ( |
497 | handle->rest_handle->url_param_map, &key)) | 497 | handle->rest_handle->url_param_map, &key)) |
498 | { | 498 | { |
499 | privkey_str = GNUNET_CRYPTO_ecdsa_private_key_to_string ( | 499 | privkey_str = GNUNET_IDENTITY_private_key_to_string ( |
500 | GNUNET_IDENTITY_ego_get_private_key (ego_entry->ego)); | 500 | GNUNET_IDENTITY_ego_get_private_key (ego_entry->ego)); |
501 | json_object_set_new (json_ego, | 501 | json_object_set_new (json_ego, |
502 | GNUNET_REST_IDENTITY_PARAM_PRIVKEY, | 502 | GNUNET_REST_IDENTITY_PARAM_PRIVKEY, |
@@ -549,7 +549,7 @@ ego_get_response (struct RequestHandle *handle, struct EgoEntry *ego_entry) | |||
549 | GNUNET_CONTAINER_multihashmap_contains ( | 549 | GNUNET_CONTAINER_multihashmap_contains ( |
550 | handle->rest_handle->url_param_map, &key)) | 550 | handle->rest_handle->url_param_map, &key)) |
551 | { | 551 | { |
552 | privkey_str = GNUNET_CRYPTO_ecdsa_private_key_to_string ( | 552 | privkey_str = GNUNET_IDENTITY_private_key_to_string ( |
553 | GNUNET_IDENTITY_ego_get_private_key (ego_entry->ego)); | 553 | GNUNET_IDENTITY_ego_get_private_key (ego_entry->ego)); |
554 | json_object_set_new (json_ego, | 554 | json_object_set_new (json_ego, |
555 | GNUNET_REST_IDENTITY_PARAM_PRIVKEY, | 555 | GNUNET_REST_IDENTITY_PARAM_PRIVKEY, |
@@ -686,7 +686,7 @@ do_finished (void *cls, const char *emsg) | |||
686 | */ | 686 | */ |
687 | static void | 687 | static void |
688 | do_finished_create (void *cls, | 688 | do_finished_create (void *cls, |
689 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pk, | 689 | const struct GNUNET_IDENTITY_PrivateKey *pk, |
690 | const char *emsg) | 690 | const char *emsg) |
691 | { | 691 | { |
692 | struct RequestHandle *handle = cls; | 692 | struct RequestHandle *handle = cls; |
@@ -999,8 +999,8 @@ ego_create (struct GNUNET_REST_RequestHandle *con_handle, | |||
999 | json_error_t err; | 999 | json_error_t err; |
1000 | char *egoname; | 1000 | char *egoname; |
1001 | char *privkey; | 1001 | char *privkey; |
1002 | struct GNUNET_CRYPTO_EcdsaPrivateKey pk; | 1002 | struct GNUNET_IDENTITY_PrivateKey pk; |
1003 | struct GNUNET_CRYPTO_EcdsaPrivateKey *pk_ptr; | 1003 | struct GNUNET_IDENTITY_PrivateKey *pk_ptr; |
1004 | int json_unpack_state; | 1004 | int json_unpack_state; |
1005 | char term_data[handle->data_size + 1]; | 1005 | char term_data[handle->data_size + 1]; |
1006 | 1006 | ||
@@ -1074,7 +1074,7 @@ ego_create (struct GNUNET_REST_RequestHandle *con_handle, | |||
1074 | strlen (privkey), | 1074 | strlen (privkey), |
1075 | &pk, | 1075 | &pk, |
1076 | sizeof(struct | 1076 | sizeof(struct |
1077 | GNUNET_CRYPTO_EcdsaPrivateKey)); | 1077 | GNUNET_IDENTITY_PrivateKey)); |
1078 | pk_ptr = &pk; | 1078 | pk_ptr = &pk; |
1079 | } | 1079 | } |
1080 | else | 1080 | else |
@@ -1084,6 +1084,7 @@ ego_create (struct GNUNET_REST_RequestHandle *con_handle, | |||
1084 | handle->op = GNUNET_IDENTITY_create (identity_handle, | 1084 | handle->op = GNUNET_IDENTITY_create (identity_handle, |
1085 | handle->name, | 1085 | handle->name, |
1086 | pk_ptr, | 1086 | pk_ptr, |
1087 | GNUNET_IDENTITY_TYPE_ECDSA, | ||
1087 | &do_finished_create, | 1088 | &do_finished_create, |
1088 | handle); | 1089 | handle); |
1089 | } | 1090 | } |
@@ -1208,7 +1209,7 @@ list_ego (void *cls, | |||
1208 | const char *identifier) | 1209 | const char *identifier) |
1209 | { | 1210 | { |
1210 | struct EgoEntry *ego_entry; | 1211 | struct EgoEntry *ego_entry; |
1211 | struct GNUNET_CRYPTO_EcdsaPublicKey pk; | 1212 | struct GNUNET_IDENTITY_PublicKey pk; |
1212 | 1213 | ||
1213 | if ((NULL == ego) && (ID_REST_STATE_INIT == state)) | 1214 | if ((NULL == ego) && (ID_REST_STATE_INIT == state)) |
1214 | { | 1215 | { |
@@ -1219,7 +1220,7 @@ list_ego (void *cls, | |||
1219 | { | 1220 | { |
1220 | ego_entry = GNUNET_new (struct EgoEntry); | 1221 | ego_entry = GNUNET_new (struct EgoEntry); |
1221 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 1222 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
1222 | ego_entry->keystring = GNUNET_CRYPTO_ecdsa_public_key_to_string (&pk); | 1223 | ego_entry->keystring = GNUNET_IDENTITY_public_key_to_string (&pk); |
1223 | ego_entry->ego = ego; | 1224 | ego_entry->ego = ego; |
1224 | ego_entry->identifier = GNUNET_strdup (identifier); | 1225 | ego_entry->identifier = GNUNET_strdup (identifier); |
1225 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, | 1226 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, |
@@ -1245,7 +1246,7 @@ list_ego (void *cls, | |||
1245 | /* Add */ | 1246 | /* Add */ |
1246 | ego_entry = GNUNET_new (struct EgoEntry); | 1247 | ego_entry = GNUNET_new (struct EgoEntry); |
1247 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 1248 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
1248 | ego_entry->keystring = GNUNET_CRYPTO_ecdsa_public_key_to_string (&pk); | 1249 | ego_entry->keystring = GNUNET_IDENTITY_public_key_to_string (&pk); |
1249 | ego_entry->ego = ego; | 1250 | ego_entry->ego = ego; |
1250 | ego_entry->identifier = GNUNET_strdup (identifier); | 1251 | ego_entry->identifier = GNUNET_strdup (identifier); |
1251 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, | 1252 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, |
diff --git a/src/identity/test_identity.c b/src/identity/test_identity.c index 37eeab238..4954fe7be 100644 --- a/src/identity/test_identity.c +++ b/src/identity/test_identity.c | |||
@@ -253,7 +253,7 @@ success_rename_cont (void *cls, const char *emsg) | |||
253 | */ | 253 | */ |
254 | static void | 254 | static void |
255 | create_cb (void *cls, | 255 | create_cb (void *cls, |
256 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pk, | 256 | const struct GNUNET_IDENTITY_PrivateKey *pk, |
257 | const char *emsg) | 257 | const char *emsg) |
258 | { | 258 | { |
259 | CHECK (NULL != pk); | 259 | CHECK (NULL != pk); |
@@ -279,7 +279,11 @@ run (void *cls, | |||
279 | GNUNET_SCHEDULER_add_shutdown (&cleanup, NULL); | 279 | GNUNET_SCHEDULER_add_shutdown (&cleanup, NULL); |
280 | h = GNUNET_IDENTITY_connect (cfg, ¬ification_cb, NULL); | 280 | h = GNUNET_IDENTITY_connect (cfg, ¬ification_cb, NULL); |
281 | CHECK (NULL != h); | 281 | CHECK (NULL != h); |
282 | op = GNUNET_IDENTITY_create (h, "test-id", NULL, &create_cb, NULL); | 282 | op = GNUNET_IDENTITY_create (h, |
283 | "test-id", | ||
284 | NULL, | ||
285 | GNUNET_IDENTITY_TYPE_ECDSA, | ||
286 | &create_cb, NULL); | ||
283 | } | 287 | } |
284 | 288 | ||
285 | 289 | ||
diff --git a/src/identity/test_identity_defaults.c b/src/identity/test_identity_defaults.c index 53eec1252..2d5244d1b 100644 --- a/src/identity/test_identity_defaults.c +++ b/src/identity/test_identity_defaults.c | |||
@@ -241,7 +241,7 @@ notification_cb (void *cls, | |||
241 | */ | 241 | */ |
242 | static void | 242 | static void |
243 | create_cb (void *cls, | 243 | create_cb (void *cls, |
244 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pk, | 244 | const struct GNUNET_IDENTITY_PrivateKey *pk, |
245 | const char *emsg) | 245 | const char *emsg) |
246 | { | 246 | { |
247 | CHECK (NULL == emsg); | 247 | CHECK (NULL == emsg); |
@@ -266,7 +266,11 @@ run_set (void *cls, | |||
266 | GNUNET_SCHEDULER_add_shutdown (&cleanup, NULL); | 266 | GNUNET_SCHEDULER_add_shutdown (&cleanup, NULL); |
267 | h = GNUNET_IDENTITY_connect (cfg, ¬ification_cb, NULL); | 267 | h = GNUNET_IDENTITY_connect (cfg, ¬ification_cb, NULL); |
268 | CHECK (NULL != h); | 268 | CHECK (NULL != h); |
269 | op = GNUNET_IDENTITY_create (h, "test-id", NULL, &create_cb, NULL); | 269 | op = GNUNET_IDENTITY_create (h, |
270 | "test-id", | ||
271 | NULL, | ||
272 | GNUNET_IDENTITY_TYPE_ECDSA, | ||
273 | &create_cb, NULL); | ||
270 | } | 274 | } |
271 | 275 | ||
272 | 276 | ||
diff --git a/src/include/Makefile.am b/src/include/Makefile.am index 202abb7ac..fc3d745a6 100644 --- a/src/include/Makefile.am +++ b/src/include/Makefile.am | |||
@@ -62,6 +62,7 @@ gnunetinclude_HEADERS = \ | |||
62 | gnunet_json_lib.h \ | 62 | gnunet_json_lib.h \ |
63 | gnunet_load_lib.h \ | 63 | gnunet_load_lib.h \ |
64 | gnunet_cadet_service.h \ | 64 | gnunet_cadet_service.h \ |
65 | gnunet_messenger_service.h \ | ||
65 | gnunet_mhd_compat.h \ | 66 | gnunet_mhd_compat.h \ |
66 | gnunet_microphone_lib.h \ | 67 | gnunet_microphone_lib.h \ |
67 | gnunet_mst_lib.h \ | 68 | gnunet_mst_lib.h \ |
diff --git a/src/include/gnunet_buffer_lib.h b/src/include/gnunet_buffer_lib.h index 0c566df75..7239eccfb 100644 --- a/src/include/gnunet_buffer_lib.h +++ b/src/include/gnunet_buffer_lib.h | |||
@@ -147,7 +147,8 @@ GNUNET_buffer_write_path (struct GNUNET_Buffer *buf, const char *str); | |||
147 | * @param ... format arguments | 147 | * @param ... format arguments |
148 | */ | 148 | */ |
149 | void | 149 | void |
150 | GNUNET_buffer_write_fstr (struct GNUNET_Buffer *buf, const char *fmt, ...); | 150 | GNUNET_buffer_write_fstr (struct GNUNET_Buffer *buf, const char *fmt, ...) |
151 | __attribute__ ((format (printf, 2, 3))); | ||
151 | 152 | ||
152 | 153 | ||
153 | /** | 154 | /** |
diff --git a/src/include/gnunet_common.h b/src/include/gnunet_common.h index fcaae1026..21b87b0f5 100644 --- a/src/include/gnunet_common.h +++ b/src/include/gnunet_common.h | |||
@@ -488,7 +488,8 @@ void | |||
488 | GNUNET_log_from_nocheck (enum GNUNET_ErrorType kind, | 488 | GNUNET_log_from_nocheck (enum GNUNET_ErrorType kind, |
489 | const char *comp, | 489 | const char *comp, |
490 | const char *message, | 490 | const char *message, |
491 | ...); | 491 | ...) |
492 | __attribute__ ((format (printf, 3, 4))); | ||
492 | 493 | ||
493 | #if ! defined(GNUNET_CULL_LOGGING) | 494 | #if ! defined(GNUNET_CULL_LOGGING) |
494 | #define GNUNET_log_from(kind, comp, ...) \ | 495 | #define GNUNET_log_from(kind, comp, ...) \ |
@@ -1445,6 +1446,7 @@ GNUNET_is_zero_ (const void *a, | |||
1445 | memcpy (&(arr1) [(len1) - (len2)], _a2, (len2) * sizeof (*arr1)); \ | 1446 | memcpy (&(arr1) [(len1) - (len2)], _a2, (len2) * sizeof (*arr1)); \ |
1446 | } while (0) | 1447 | } while (0) |
1447 | 1448 | ||
1449 | |||
1448 | /** | 1450 | /** |
1449 | * @ingroup memory | 1451 | * @ingroup memory |
1450 | * Like snprintf, just aborts if the buffer is of insufficient size. | 1452 | * Like snprintf, just aborts if the buffer is of insufficient size. |
@@ -1456,7 +1458,11 @@ GNUNET_is_zero_ (const void *a, | |||
1456 | * @return number of bytes written to buf or negative value on error | 1458 | * @return number of bytes written to buf or negative value on error |
1457 | */ | 1459 | */ |
1458 | int | 1460 | int |
1459 | GNUNET_snprintf (char *buf, size_t size, const char *format, ...); | 1461 | GNUNET_snprintf (char *buf, |
1462 | size_t size, | ||
1463 | const char *format, | ||
1464 | ...) | ||
1465 | __attribute__ ((format (printf, 3, 4))); | ||
1460 | 1466 | ||
1461 | 1467 | ||
1462 | /** | 1468 | /** |
@@ -1469,7 +1475,10 @@ GNUNET_snprintf (char *buf, size_t size, const char *format, ...); | |||
1469 | * @return number of bytes in "*buf" excluding 0-termination | 1475 | * @return number of bytes in "*buf" excluding 0-termination |
1470 | */ | 1476 | */ |
1471 | int | 1477 | int |
1472 | GNUNET_asprintf (char **buf, const char *format, ...); | 1478 | GNUNET_asprintf (char **buf, |
1479 | const char *format, | ||
1480 | ...) | ||
1481 | __attribute__ ((format (printf, 2, 3))); | ||
1473 | 1482 | ||
1474 | 1483 | ||
1475 | /* ************** internal implementations, use macros above! ************** */ | 1484 | /* ************** internal implementations, use macros above! ************** */ |
diff --git a/src/include/gnunet_conversation_service.h b/src/include/gnunet_conversation_service.h index 4566caad0..be5a81cfb 100644 --- a/src/include/gnunet_conversation_service.h +++ b/src/include/gnunet_conversation_service.h | |||
@@ -147,7 +147,7 @@ typedef void | |||
147 | struct GNUNET_CONVERSATION_Caller * | 147 | struct GNUNET_CONVERSATION_Caller * |
148 | caller, | 148 | caller, |
149 | const struct | 149 | const struct |
150 | GNUNET_CRYPTO_EcdsaPublicKey *caller_id); | 150 | GNUNET_IDENTITY_PublicKey *caller_id); |
151 | 151 | ||
152 | 152 | ||
153 | /** | 153 | /** |
diff --git a/src/include/gnunet_crypto_lib.h b/src/include/gnunet_crypto_lib.h index 03fb16a43..2bbf2b1e7 100644 --- a/src/include/gnunet_crypto_lib.h +++ b/src/include/gnunet_crypto_lib.h | |||
@@ -1700,7 +1700,7 @@ GNUNET_CRYPTO_eddsa_sign_ ( | |||
1700 | */ | 1700 | */ |
1701 | #define GNUNET_CRYPTO_eddsa_sign(priv,ps,sig) do { \ | 1701 | #define GNUNET_CRYPTO_eddsa_sign(priv,ps,sig) do { \ |
1702 | /* check size is set correctly */ \ | 1702 | /* check size is set correctly */ \ |
1703 | GNUNET_assert (htonl ((ps)->purpose.size) == sizeof (*ps)); \ | 1703 | GNUNET_assert (ntohl ((ps)->purpose.size) == sizeof (*ps)); \ |
1704 | /* check 'ps' begins with the purpose */ \ | 1704 | /* check 'ps' begins with the purpose */ \ |
1705 | GNUNET_static_assert (((void*) (ps)) == \ | 1705 | GNUNET_static_assert (((void*) (ps)) == \ |
1706 | ((void*) &(ps)->purpose)); \ | 1706 | ((void*) &(ps)->purpose)); \ |
@@ -1747,7 +1747,7 @@ GNUNET_CRYPTO_ecdsa_sign_ ( | |||
1747 | */ | 1747 | */ |
1748 | #define GNUNET_CRYPTO_ecdsa_sign(priv,ps,sig) do { \ | 1748 | #define GNUNET_CRYPTO_ecdsa_sign(priv,ps,sig) do { \ |
1749 | /* check size is set correctly */ \ | 1749 | /* check size is set correctly */ \ |
1750 | GNUNET_assert (htonl ((ps)->purpose.size) == sizeof (*(ps))); \ | 1750 | GNUNET_assert (ntohl ((ps)->purpose.size) == sizeof (*(ps))); \ |
1751 | /* check 'ps' begins with the purpose */ \ | 1751 | /* check 'ps' begins with the purpose */ \ |
1752 | GNUNET_static_assert (((void*) (ps)) == \ | 1752 | GNUNET_static_assert (((void*) (ps)) == \ |
1753 | ((void*) &(ps)->purpose)); \ | 1753 | ((void*) &(ps)->purpose)); \ |
@@ -1853,7 +1853,7 @@ GNUNET_CRYPTO_ecdsa_verify_ ( | |||
1853 | */ | 1853 | */ |
1854 | #define GNUNET_CRYPTO_ecdsa_verify(purp,ps,sig,pub) ({ \ | 1854 | #define GNUNET_CRYPTO_ecdsa_verify(purp,ps,sig,pub) ({ \ |
1855 | /* check size is set correctly */ \ | 1855 | /* check size is set correctly */ \ |
1856 | GNUNET_assert (htonl ((ps)->purpose.size) == sizeof (*(ps))); \ | 1856 | GNUNET_assert (ntohl ((ps)->purpose.size) == sizeof (*(ps))); \ |
1857 | /* check 'ps' begins with the purpose */ \ | 1857 | /* check 'ps' begins with the purpose */ \ |
1858 | GNUNET_static_assert (((void*) (ps)) == \ | 1858 | GNUNET_static_assert (((void*) (ps)) == \ |
1859 | ((void*) &(ps)->purpose)); \ | 1859 | ((void*) &(ps)->purpose)); \ |
diff --git a/src/include/gnunet_gns_service.h b/src/include/gnunet_gns_service.h index ef81e9a88..3f6c9b9aa 100644 --- a/src/include/gnunet_gns_service.h +++ b/src/include/gnunet_gns_service.h | |||
@@ -36,6 +36,7 @@ | |||
36 | 36 | ||
37 | #include "gnunet_util_lib.h" | 37 | #include "gnunet_util_lib.h" |
38 | #include "gnunet_dnsparser_lib.h" | 38 | #include "gnunet_dnsparser_lib.h" |
39 | #include "gnunet_identity_service.h" | ||
39 | #include "gnunet_namestore_service.h" | 40 | #include "gnunet_namestore_service.h" |
40 | 41 | ||
41 | #ifdef __cplusplus | 42 | #ifdef __cplusplus |
@@ -139,7 +140,7 @@ enum GNUNET_GNS_LocalOptions | |||
139 | struct GNUNET_GNS_LookupRequest * | 140 | struct GNUNET_GNS_LookupRequest * |
140 | GNUNET_GNS_lookup (struct GNUNET_GNS_Handle *handle, | 141 | GNUNET_GNS_lookup (struct GNUNET_GNS_Handle *handle, |
141 | const char *name, | 142 | const char *name, |
142 | const struct GNUNET_CRYPTO_EcdsaPublicKey *zone, | 143 | const struct GNUNET_IDENTITY_PublicKey *zone, |
143 | uint32_t type, | 144 | uint32_t type, |
144 | enum GNUNET_GNS_LocalOptions options, | 145 | enum GNUNET_GNS_LocalOptions options, |
145 | GNUNET_GNS_LookupResultProcessor proc, | 146 | GNUNET_GNS_LookupResultProcessor proc, |
@@ -163,7 +164,7 @@ GNUNET_GNS_lookup (struct GNUNET_GNS_Handle *handle, | |||
163 | struct GNUNET_GNS_LookupRequest * | 164 | struct GNUNET_GNS_LookupRequest * |
164 | GNUNET_GNS_lookup_limited (struct GNUNET_GNS_Handle *handle, | 165 | GNUNET_GNS_lookup_limited (struct GNUNET_GNS_Handle *handle, |
165 | const char *name, | 166 | const char *name, |
166 | const struct GNUNET_CRYPTO_EcdsaPublicKey *zone, | 167 | const struct GNUNET_IDENTITY_PublicKey *zone, |
167 | uint32_t type, | 168 | uint32_t type, |
168 | enum GNUNET_GNS_LocalOptions options, | 169 | enum GNUNET_GNS_LocalOptions options, |
169 | uint16_t recursion_depth_limit, | 170 | uint16_t recursion_depth_limit, |
diff --git a/src/include/gnunet_gnsrecord_json_lib.h b/src/include/gnunet_gnsrecord_json_lib.h new file mode 100644 index 000000000..966461705 --- /dev/null +++ b/src/include/gnunet_gnsrecord_json_lib.h | |||
@@ -0,0 +1,73 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet | ||
3 | Copyright (C) 2012, 2013 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 | * @author Martin Schanzenbach | ||
23 | * | ||
24 | * @file | ||
25 | * API that can be used to manipulate JSON GNS record data | ||
26 | * | ||
27 | * @defgroup gnsrecord GNS Record library | ||
28 | * Manipulate GNS record data | ||
29 | * | ||
30 | * @see [Documentation](https://gnunet.org/gns-plugins) | ||
31 | * | ||
32 | * @{ | ||
33 | */ | ||
34 | #ifndef GNUNET_GNSRECORD_JSON_LIB_H | ||
35 | #define GNUNET_GNSRECORD_JSON_LIB_H | ||
36 | |||
37 | #include "gnunet_gnsrecord_lib.h" | ||
38 | #include "gnunet_json_lib.h" | ||
39 | |||
40 | #ifdef __cplusplus | ||
41 | extern "C" { | ||
42 | #if 0 /* keep Emacsens' auto-indent happy */ | ||
43 | } | ||
44 | #endif | ||
45 | #endif | ||
46 | |||
47 | |||
48 | /** | ||
49 | * JSON Specification for GNS Records. | ||
50 | * | ||
51 | * @param gnsrecord_object struct of GNUNET_GNSRECORD_Data to fill | ||
52 | * @return JSON Specification | ||
53 | */ | ||
54 | struct GNUNET_JSON_Specification | ||
55 | GNUNET_GNSRECORD_JSON_spec_gnsrecord (struct GNUNET_GNSRECORD_Data **rd, | ||
56 | unsigned int *rd_count, | ||
57 | char **name); | ||
58 | |||
59 | |||
60 | /** | ||
61 | * Convert GNS record to JSON. | ||
62 | * | ||
63 | * @param rname name of record | ||
64 | * @param rd record data | ||
65 | * @return corresponding JSON encoding | ||
66 | */ | ||
67 | json_t * | ||
68 | GNUNET_GNSRECORD_JSON_from_gnsrecord (const char*rname, | ||
69 | const struct GNUNET_GNSRECORD_Data *rd, | ||
70 | unsigned int rd_count); | ||
71 | |||
72 | |||
73 | #endif | ||
diff --git a/src/include/gnunet_gnsrecord_lib.h b/src/include/gnunet_gnsrecord_lib.h index 960203fb1..0bf2ceed7 100644 --- a/src/include/gnunet_gnsrecord_lib.h +++ b/src/include/gnunet_gnsrecord_lib.h | |||
@@ -34,6 +34,8 @@ | |||
34 | #ifndef GNUNET_GNSRECORD_LIB_H | 34 | #ifndef GNUNET_GNSRECORD_LIB_H |
35 | #define GNUNET_GNSRECORD_LIB_H | 35 | #define GNUNET_GNSRECORD_LIB_H |
36 | 36 | ||
37 | #include "gnunet_identity_service.h" | ||
38 | |||
37 | #ifdef __cplusplus | 39 | #ifdef __cplusplus |
38 | extern "C" { | 40 | extern "C" { |
39 | #if 0 /* keep Emacsens' auto-indent happy */ | 41 | #if 0 /* keep Emacsens' auto-indent happy */ |
@@ -55,7 +57,7 @@ extern "C" { | |||
55 | /** | 57 | /** |
56 | * Record type for GNS zone transfer ("PKEY"). | 58 | * Record type for GNS zone transfer ("PKEY"). |
57 | */ | 59 | */ |
58 | #define GNUNET_GNSRECORD_TYPE_PKEY 65536 | 60 | #define GNUNET_GNSRECORD_TYPE_PKEY GNUNET_IDENTITY_TYPE_ECDSA |
59 | 61 | ||
60 | /** | 62 | /** |
61 | * Record type for GNS nick names ("NICK"). | 63 | * Record type for GNS nick names ("NICK"). |
@@ -151,6 +153,11 @@ extern "C" { | |||
151 | */ | 153 | */ |
152 | #define GNUNET_GNSRECORD_TYPE_RECLAIM_PRESENTATION 65555 | 154 | #define GNUNET_GNSRECORD_TYPE_RECLAIM_PRESENTATION 65555 |
153 | 155 | ||
156 | /** | ||
157 | * Record type for EDKEY delegations. | ||
158 | */ | ||
159 | #define GNUNET_GNSRECORD_TYPE_EDKEY GNUNET_IDENTITY_TYPE_EDDSA | ||
160 | |||
154 | 161 | ||
155 | /** | 162 | /** |
156 | * Flags that can be set for a record. | 163 | * Flags that can be set for a record. |
@@ -261,21 +268,20 @@ struct GNUNET_GNSRECORD_PlaceData | |||
261 | /* Followed by struct GNUNET_PeerIdentity relays[relay_count] */ | 268 | /* Followed by struct GNUNET_PeerIdentity relays[relay_count] */ |
262 | }; | 269 | }; |
263 | 270 | ||
264 | |||
265 | /** | 271 | /** |
266 | * Information we have in an encrypted block with record data (i.e. in the DHT). | 272 | * Information we have in an encrypted block with record data (i.e. in the DHT). |
267 | */ | 273 | */ |
268 | struct GNUNET_GNSRECORD_Block | 274 | struct GNUNET_GNSRECORD_EcdsaBlock |
269 | { | 275 | { |
270 | /** | 276 | /** |
271 | * Signature of the block. | 277 | * Derived key used for signing; hash of this is the query. |
272 | */ | 278 | */ |
273 | struct GNUNET_CRYPTO_EcdsaSignature signature; | 279 | struct GNUNET_CRYPTO_EcdsaPublicKey derived_key; |
274 | 280 | ||
275 | /** | 281 | /** |
276 | * Derived key used for signing; hash of this is the query. | 282 | * Signature of the block. |
277 | */ | 283 | */ |
278 | struct GNUNET_CRYPTO_EcdsaPublicKey derived_key; | 284 | struct GNUNET_CRYPTO_EcdsaSignature signature; |
279 | 285 | ||
280 | /** | 286 | /** |
281 | * Number of bytes signed; also specifies the number of bytes | 287 | * Number of bytes signed; also specifies the number of bytes |
@@ -291,6 +297,17 @@ struct GNUNET_GNSRECORD_Block | |||
291 | /* followed by encrypted data */ | 297 | /* followed by encrypted data */ |
292 | }; | 298 | }; |
293 | 299 | ||
300 | struct GNUNET_GNSRECORD_Block | ||
301 | { | ||
302 | uint32_t type; | ||
303 | |||
304 | union | ||
305 | { | ||
306 | struct GNUNET_GNSRECORD_EcdsaBlock ecdsa_block; | ||
307 | //struct GNUNET_GNSRECORD_EddsaBlock eddsa_block; | ||
308 | }; | ||
309 | }; | ||
310 | |||
294 | 311 | ||
295 | /** | 312 | /** |
296 | * Record type used to box up SRV and TLSA records. For example, a | 313 | * Record type used to box up SRV and TLSA records. For example, a |
@@ -335,7 +352,7 @@ struct GNUNET_GNSRECORD_ReverseRecord | |||
335 | /** | 352 | /** |
336 | * The public key of the namespace the is delegating to our namespace | 353 | * The public key of the namespace the is delegating to our namespace |
337 | */ | 354 | */ |
338 | struct GNUNET_CRYPTO_EcdsaPublicKey pkey; | 355 | struct GNUNET_IDENTITY_PublicKey pkey; |
339 | 356 | ||
340 | /** | 357 | /** |
341 | * The expiration time of the delegation | 358 | * The expiration time of the delegation |
@@ -488,7 +505,7 @@ GNUNET_GNSRECORD_string_to_lowercase (const char *src); | |||
488 | * #GNUNET_GNSRECORD_z2s. | 505 | * #GNUNET_GNSRECORD_z2s. |
489 | */ | 506 | */ |
490 | const char * | 507 | const char * |
491 | GNUNET_GNSRECORD_z2s (const struct GNUNET_CRYPTO_EcdsaPublicKey *z); | 508 | GNUNET_GNSRECORD_z2s (const struct GNUNET_IDENTITY_PublicKey *z); |
492 | 509 | ||
493 | 510 | ||
494 | /** | 511 | /** |
@@ -502,7 +519,7 @@ GNUNET_GNSRECORD_z2s (const struct GNUNET_CRYPTO_EcdsaPublicKey *z); | |||
502 | * key in an encoding suitable for DNS labels. | 519 | * key in an encoding suitable for DNS labels. |
503 | */ | 520 | */ |
504 | const char * | 521 | const char * |
505 | GNUNET_GNSRECORD_pkey_to_zkey (const struct GNUNET_CRYPTO_EcdsaPublicKey *pkey); | 522 | GNUNET_GNSRECORD_pkey_to_zkey (const struct GNUNET_IDENTITY_PublicKey *pkey); |
506 | 523 | ||
507 | 524 | ||
508 | /** | 525 | /** |
@@ -516,7 +533,7 @@ GNUNET_GNSRECORD_pkey_to_zkey (const struct GNUNET_CRYPTO_EcdsaPublicKey *pkey); | |||
516 | */ | 533 | */ |
517 | int | 534 | int |
518 | GNUNET_GNSRECORD_zkey_to_pkey (const char *zkey, | 535 | GNUNET_GNSRECORD_zkey_to_pkey (const char *zkey, |
519 | struct GNUNET_CRYPTO_EcdsaPublicKey *pkey); | 536 | struct GNUNET_IDENTITY_PublicKey *pkey); |
520 | 537 | ||
521 | 538 | ||
522 | /** | 539 | /** |
@@ -528,7 +545,7 @@ GNUNET_GNSRECORD_zkey_to_pkey (const char *zkey, | |||
528 | */ | 545 | */ |
529 | void | 546 | void |
530 | GNUNET_GNSRECORD_query_from_private_key ( | 547 | GNUNET_GNSRECORD_query_from_private_key ( |
531 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, const char *label, | 548 | const struct GNUNET_IDENTITY_PrivateKey *zone, const char *label, |
532 | struct GNUNET_HashCode *query); | 549 | struct GNUNET_HashCode *query); |
533 | 550 | ||
534 | 551 | ||
@@ -541,7 +558,7 @@ GNUNET_GNSRECORD_query_from_private_key ( | |||
541 | */ | 558 | */ |
542 | void | 559 | void |
543 | GNUNET_GNSRECORD_query_from_public_key ( | 560 | GNUNET_GNSRECORD_query_from_public_key ( |
544 | const struct GNUNET_CRYPTO_EcdsaPublicKey *pub, const char *label, | 561 | const struct GNUNET_IDENTITY_PublicKey *pub, const char *label, |
545 | struct GNUNET_HashCode *query); | 562 | struct GNUNET_HashCode *query); |
546 | 563 | ||
547 | 564 | ||
@@ -555,7 +572,7 @@ GNUNET_GNSRECORD_query_from_public_key ( | |||
555 | * @param rd_count number of records in @a rd | 572 | * @param rd_count number of records in @a rd |
556 | */ | 573 | */ |
557 | struct GNUNET_GNSRECORD_Block * | 574 | struct GNUNET_GNSRECORD_Block * |
558 | GNUNET_GNSRECORD_block_create (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | 575 | GNUNET_GNSRECORD_block_create (const struct GNUNET_IDENTITY_PrivateKey *key, |
559 | struct GNUNET_TIME_Absolute expire, | 576 | struct GNUNET_TIME_Absolute expire, |
560 | const char *label, | 577 | const char *label, |
561 | const struct GNUNET_GNSRECORD_Data *rd, | 578 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -574,7 +591,7 @@ GNUNET_GNSRECORD_block_create (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | |||
574 | * @param rd_count number of records in @a rd | 591 | * @param rd_count number of records in @a rd |
575 | */ | 592 | */ |
576 | struct GNUNET_GNSRECORD_Block * | 593 | struct GNUNET_GNSRECORD_Block * |
577 | GNUNET_GNSRECORD_block_create2 (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | 594 | GNUNET_GNSRECORD_block_create2 (const struct GNUNET_IDENTITY_PrivateKey *key, |
578 | struct GNUNET_TIME_Absolute expire, | 595 | struct GNUNET_TIME_Absolute expire, |
579 | const char *label, | 596 | const char *label, |
580 | const struct GNUNET_GNSRECORD_Data *rd, | 597 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -606,7 +623,7 @@ GNUNET_GNSRECORD_block_verify (const struct GNUNET_GNSRECORD_Block *block); | |||
606 | int | 623 | int |
607 | GNUNET_GNSRECORD_block_decrypt ( | 624 | GNUNET_GNSRECORD_block_decrypt ( |
608 | const struct GNUNET_GNSRECORD_Block *block, | 625 | const struct GNUNET_GNSRECORD_Block *block, |
609 | const struct GNUNET_CRYPTO_EcdsaPublicKey *zone_key, const char *label, | 626 | const struct GNUNET_IDENTITY_PublicKey *zone_key, const char *label, |
610 | GNUNET_GNSRECORD_RecordCallback proc, void *proc_cls); | 627 | GNUNET_GNSRECORD_RecordCallback proc, void *proc_cls); |
611 | 628 | ||
612 | 629 | ||
@@ -636,6 +653,82 @@ GNUNET_GNSRECORD_record_get_expiration_time ( | |||
636 | unsigned int rd_count, const struct GNUNET_GNSRECORD_Data *rd); | 653 | unsigned int rd_count, const struct GNUNET_GNSRECORD_Data *rd); |
637 | 654 | ||
638 | 655 | ||
656 | /** | ||
657 | * Returns the length of this block in bytes. | ||
658 | * Block length strongly depends on the zone type. | ||
659 | * | ||
660 | * @param block the block. | ||
661 | * @return the length of this block in bytes | ||
662 | */ | ||
663 | size_t | ||
664 | GNUNET_GNSRECORD_block_get_size (const struct GNUNET_GNSRECORD_Block *block); | ||
665 | |||
666 | /** | ||
667 | * Returns the expiration of a block. | ||
668 | * | ||
669 | * @param block the block. | ||
670 | * @return the block expiration. | ||
671 | */ | ||
672 | struct GNUNET_TIME_Absolute | ||
673 | GNUNET_GNSRECORD_block_get_expiration (const struct GNUNET_GNSRECORD_Block *block); | ||
674 | |||
675 | |||
676 | /** | ||
677 | * Builds the query hash from a block. | ||
678 | * | ||
679 | * @param block the block. | ||
680 | * @param query where to write the query hash. | ||
681 | * @return GNUNET_SYSERR on error. | ||
682 | */ | ||
683 | enum GNUNET_GenericReturnValue | ||
684 | GNUNET_GNSRECORD_query_from_block (const struct GNUNET_GNSRECORD_Block *block, | ||
685 | struct GNUNET_HashCode *query); | ||
686 | |||
687 | |||
688 | /** | ||
689 | * Build a #GNUNET_GNSRECORD_PublicKey from | ||
690 | * zone delegation resource record data. | ||
691 | * | ||
692 | * @param data the record data- | ||
693 | * @param data_size the data size. | ||
694 | * @param type the record type | ||
695 | * @param key the identity key to store the data in (must be allocated). | ||
696 | * @return GNUNET_OK if successful. | ||
697 | */ | ||
698 | enum GNUNET_GenericReturnValue | ||
699 | GNUNET_GNSRECORD_identity_from_data (const char *data, | ||
700 | size_t data_size, | ||
701 | uint32_t type, | ||
702 | struct GNUNET_IDENTITY_PublicKey *key); | ||
703 | |||
704 | |||
705 | /** | ||
706 | * Create record data and size from an identity key. | ||
707 | * | ||
708 | * @param key the identity key to use. | ||
709 | * @param data the record data (will be allocated) | ||
710 | * @param data_size the allocated data size. | ||
711 | * @param type the resulting record type | ||
712 | * @return GNUNET_OK if successful. | ||
713 | */ | ||
714 | enum GNUNET_GenericReturnValue | ||
715 | GNUNET_GNSRECORD_data_from_identity (const struct GNUNET_IDENTITY_PublicKey *key, | ||
716 | char **data, | ||
717 | size_t *data_size, | ||
718 | uint32_t *type); | ||
719 | |||
720 | |||
721 | /** | ||
722 | * Check if this type is one of the supported GNS zone | ||
723 | * types. | ||
724 | * | ||
725 | * @param type the type to check | ||
726 | * @return GNUNET_YES if it is one of the supported types. | ||
727 | */ | ||
728 | enum GNUNET_GenericReturnValue | ||
729 | GNUNET_GNSRECORD_is_zonekey_type (uint32_t type); | ||
730 | |||
731 | |||
639 | #if 0 /* keep Emacsens' auto-indent happy */ | 732 | #if 0 /* keep Emacsens' auto-indent happy */ |
640 | { | 733 | { |
641 | #endif | 734 | #endif |
diff --git a/src/include/gnunet_identity_service.h b/src/include/gnunet_identity_service.h index 94127248e..2974568db 100644 --- a/src/include/gnunet_identity_service.h +++ b/src/include/gnunet_identity_service.h | |||
@@ -57,6 +57,21 @@ extern "C" { | |||
57 | */ | 57 | */ |
58 | #define GNUNET_IDENTITY_VERSION 0x00000100 | 58 | #define GNUNET_IDENTITY_VERSION 0x00000100 |
59 | 59 | ||
60 | enum GNUNET_IDENTITY_KeyType | ||
61 | { | ||
62 | /** | ||
63 | * The identity type. The value is the same as the | ||
64 | * PKEY record type. | ||
65 | */ | ||
66 | GNUNET_IDENTITY_TYPE_ECDSA = 65536, | ||
67 | |||
68 | /** | ||
69 | * EDDSA identity. The value is the same as the EDKEY | ||
70 | * record type. | ||
71 | */ | ||
72 | GNUNET_IDENTITY_TYPE_EDDSA = 65556 | ||
73 | }; | ||
74 | |||
60 | /** | 75 | /** |
61 | * Handle to access the identity service. | 76 | * Handle to access the identity service. |
62 | */ | 77 | */ |
@@ -67,6 +82,88 @@ struct GNUNET_IDENTITY_Handle; | |||
67 | */ | 82 | */ |
68 | struct GNUNET_IDENTITY_Ego; | 83 | struct GNUNET_IDENTITY_Ego; |
69 | 84 | ||
85 | |||
86 | /** | ||
87 | * A private key for an identity as per LSD0001. | ||
88 | */ | ||
89 | struct GNUNET_IDENTITY_PrivateKey | ||
90 | { | ||
91 | /** | ||
92 | * Type of public key. | ||
93 | * Defined by the GNS zone type value. | ||
94 | * In NBO. | ||
95 | */ | ||
96 | uint32_t type; | ||
97 | |||
98 | union | ||
99 | { | ||
100 | /** | ||
101 | * An ECDSA identity key. | ||
102 | */ | ||
103 | struct GNUNET_CRYPTO_EcdsaPrivateKey ecdsa_key; | ||
104 | |||
105 | /** | ||
106 | * AN EdDSA identtiy key | ||
107 | */ | ||
108 | struct GNUNET_CRYPTO_EddsaPrivateKey eddsa_key; | ||
109 | }; | ||
110 | }; | ||
111 | |||
112 | |||
113 | /** | ||
114 | * An identity key as per LSD0001. | ||
115 | */ | ||
116 | struct GNUNET_IDENTITY_PublicKey | ||
117 | { | ||
118 | /** | ||
119 | * Type of public key. | ||
120 | * Defined by the GNS zone type value. | ||
121 | * In NBO. | ||
122 | */ | ||
123 | uint32_t type; | ||
124 | |||
125 | union | ||
126 | { | ||
127 | /** | ||
128 | * An ECDSA identity key. | ||
129 | */ | ||
130 | struct GNUNET_CRYPTO_EcdsaPublicKey ecdsa_key; | ||
131 | |||
132 | /** | ||
133 | * AN EdDSA identtiy key | ||
134 | */ | ||
135 | struct GNUNET_CRYPTO_EddsaPublicKey eddsa_key; | ||
136 | }; | ||
137 | }; | ||
138 | |||
139 | |||
140 | /** | ||
141 | * An identity signature as per LSD0001. | ||
142 | */ | ||
143 | struct GNUNET_IDENTITY_Signature | ||
144 | { | ||
145 | /** | ||
146 | * Type of signature. | ||
147 | * Defined by the GNS zone type value. | ||
148 | * In NBO. | ||
149 | */ | ||
150 | uint32_t type; | ||
151 | |||
152 | union | ||
153 | { | ||
154 | /** | ||
155 | * An ECDSA signature | ||
156 | */ | ||
157 | struct GNUNET_CRYPTO_EcdsaSignature ecdsa_signature; | ||
158 | |||
159 | /** | ||
160 | * AN EdDSA signature | ||
161 | */ | ||
162 | struct GNUNET_CRYPTO_EddsaSignature eddsa_signature; | ||
163 | }; | ||
164 | }; | ||
165 | |||
166 | |||
70 | /** | 167 | /** |
71 | * Handle for an operation with the identity service. | 168 | * Handle for an operation with the identity service. |
72 | */ | 169 | */ |
@@ -79,7 +176,7 @@ struct GNUNET_IDENTITY_Operation; | |||
79 | * @param ego the ego | 176 | * @param ego the ego |
80 | * @return associated ECC key, valid as long as the ego is valid | 177 | * @return associated ECC key, valid as long as the ego is valid |
81 | */ | 178 | */ |
82 | const struct GNUNET_CRYPTO_EcdsaPrivateKey * | 179 | const struct GNUNET_IDENTITY_PrivateKey * |
83 | GNUNET_IDENTITY_ego_get_private_key (const struct GNUNET_IDENTITY_Ego *ego); | 180 | GNUNET_IDENTITY_ego_get_private_key (const struct GNUNET_IDENTITY_Ego *ego); |
84 | 181 | ||
85 | 182 | ||
@@ -100,7 +197,7 @@ GNUNET_IDENTITY_ego_get_anonymous (void); | |||
100 | */ | 197 | */ |
101 | void | 198 | void |
102 | GNUNET_IDENTITY_ego_get_public_key (struct GNUNET_IDENTITY_Ego *ego, | 199 | GNUNET_IDENTITY_ego_get_public_key (struct GNUNET_IDENTITY_Ego *ego, |
103 | struct GNUNET_CRYPTO_EcdsaPublicKey *pk); | 200 | struct GNUNET_IDENTITY_PublicKey *pk); |
104 | 201 | ||
105 | 202 | ||
106 | /** | 203 | /** |
@@ -224,7 +321,7 @@ GNUNET_IDENTITY_disconnect (struct GNUNET_IDENTITY_Handle *h); | |||
224 | typedef void | 321 | typedef void |
225 | (*GNUNET_IDENTITY_CreateContinuation) ( | 322 | (*GNUNET_IDENTITY_CreateContinuation) ( |
226 | void *cls, | 323 | void *cls, |
227 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pk, | 324 | const struct GNUNET_IDENTITY_PrivateKey *pk, |
228 | const char *emsg); | 325 | const char *emsg); |
229 | 326 | ||
230 | 327 | ||
@@ -234,6 +331,7 @@ typedef void | |||
234 | * @param id identity service to use | 331 | * @param id identity service to use |
235 | * @param name desired name | 332 | * @param name desired name |
236 | * @param privkey desired private key or NULL to create one | 333 | * @param privkey desired private key or NULL to create one |
334 | * @param ktype the type of key to create. Ignored if privkey != NULL. | ||
237 | * @param cont function to call with the result (will only be called once) | 335 | * @param cont function to call with the result (will only be called once) |
238 | * @param cont_cls closure for @a cont | 336 | * @param cont_cls closure for @a cont |
239 | * @return handle to abort the operation | 337 | * @return handle to abort the operation |
@@ -241,7 +339,8 @@ typedef void | |||
241 | struct GNUNET_IDENTITY_Operation * | 339 | struct GNUNET_IDENTITY_Operation * |
242 | GNUNET_IDENTITY_create (struct GNUNET_IDENTITY_Handle *id, | 340 | GNUNET_IDENTITY_create (struct GNUNET_IDENTITY_Handle *id, |
243 | const char *name, | 341 | const char *name, |
244 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *privkey, | 342 | const struct GNUNET_IDENTITY_PrivateKey *privkey, |
343 | enum GNUNET_IDENTITY_KeyType ktype, | ||
245 | GNUNET_IDENTITY_CreateContinuation cont, | 344 | GNUNET_IDENTITY_CreateContinuation cont, |
246 | void *cont_cls); | 345 | void *cont_cls); |
247 | 346 | ||
@@ -292,6 +391,319 @@ void | |||
292 | GNUNET_IDENTITY_cancel (struct GNUNET_IDENTITY_Operation *op); | 391 | GNUNET_IDENTITY_cancel (struct GNUNET_IDENTITY_Operation *op); |
293 | 392 | ||
294 | 393 | ||
394 | /** | ||
395 | * Get the compacted length of a #GNUNET_IDENTITY_PublicKey. | ||
396 | * Compacted means that it returns the minimum number of bytes this | ||
397 | * key is long, as opposed to the union structure inside | ||
398 | * #GNUNET_IDENTITY_PublicKey. | ||
399 | * Useful for compact serializations. | ||
400 | * | ||
401 | * @param key the key. | ||
402 | * @return -1 on error, else the compacted length of the key. | ||
403 | */ | ||
404 | ssize_t | ||
405 | GNUNET_IDENTITY_key_get_length (const struct GNUNET_IDENTITY_PublicKey *key); | ||
406 | |||
407 | |||
408 | /** | ||
409 | * Reads a #GNUNET_IDENTITY_PublicKey from a compact buffer. | ||
410 | * The buffer has to contain at least the compacted length of | ||
411 | * a #GNUNET_IDENTITY_PublicKey in bytes. | ||
412 | * If the buffer is too small, the function returns -1 as error. | ||
413 | * If the buffer does not contain a valid key, it returns -2 as error. | ||
414 | * | ||
415 | * @param key the key | ||
416 | * @param buffer the buffer | ||
417 | * @param len the length of buffer | ||
418 | * @return -1 or -2 on error, else the amount of bytes read from the buffer | ||
419 | */ | ||
420 | ssize_t | ||
421 | GNUNET_IDENTITY_read_key_from_buffer (struct GNUNET_IDENTITY_PublicKey *key, | ||
422 | const void*buffer, | ||
423 | size_t len); | ||
424 | |||
425 | |||
426 | /** | ||
427 | * Writes a #GNUNET_IDENTITY_PublicKey to a compact buffer. | ||
428 | * The buffer requires space for at least the compacted length of | ||
429 | * a #GNUNET_IDENTITY_PublicKey in bytes. | ||
430 | * If the buffer is too small, the function returns -1 as error. | ||
431 | * If the key is not valid, it returns -2 as error. | ||
432 | * | ||
433 | * @param key the key | ||
434 | * @param buffer the buffer | ||
435 | * @param len the length of buffer | ||
436 | * @return -1 or -2 on error, else the amount of bytes written to the buffer | ||
437 | */ | ||
438 | ssize_t | ||
439 | GNUNET_IDENTITY_write_key_to_buffer (const struct | ||
440 | GNUNET_IDENTITY_PublicKey *key, | ||
441 | void*buffer, | ||
442 | size_t len); | ||
443 | |||
444 | |||
445 | /** | ||
446 | * Get the compacted length of a #GNUNET_IDENTITY_Signature. | ||
447 | * Compacted means that it returns the minimum number of bytes this | ||
448 | * signature is long, as opposed to the union structure inside | ||
449 | * #GNUNET_IDENTITY_Signature. | ||
450 | * Useful for compact serializations. | ||
451 | * | ||
452 | * @param sig the signature. | ||
453 | * @return -1 on error, else the compacted length of the signature. | ||
454 | */ | ||
455 | ssize_t | ||
456 | GNUNET_IDENTITY_signature_get_length (const struct | ||
457 | GNUNET_IDENTITY_Signature *sig); | ||
458 | |||
459 | |||
460 | /** | ||
461 | * Reads a #GNUNET_IDENTITY_Signature from a compact buffer. | ||
462 | * The buffer has to contain at least the compacted length of | ||
463 | * a #GNUNET_IDENTITY_Signature in bytes. | ||
464 | * If the buffer is too small, the function returns -1 as error. | ||
465 | * If the buffer does not contain a valid key, it returns -2 as error. | ||
466 | * | ||
467 | * @param sig the signature | ||
468 | * @param buffer the buffer | ||
469 | * @param len the length of buffer | ||
470 | * @return -1 or -2 on error, else the amount of bytes read from the buffer | ||
471 | */ | ||
472 | ssize_t | ||
473 | GNUNET_IDENTITY_read_signature_from_buffer (struct | ||
474 | GNUNET_IDENTITY_Signature *sig, | ||
475 | const void*buffer, | ||
476 | size_t len); | ||
477 | |||
478 | |||
479 | /** | ||
480 | * Writes a #GNUNET_IDENTITY_Signature to a compact buffer. | ||
481 | * The buffer requires space for at least the compacted length of | ||
482 | * a #GNUNET_IDENTITY_Signature in bytes. | ||
483 | * If the buffer is too small, the function returns -1 as error. | ||
484 | * If the key is not valid, it returns -2 as error. | ||
485 | * | ||
486 | * @param sig the signature | ||
487 | * @param buffer the buffer | ||
488 | * @param len the length of buffer | ||
489 | * @return -1 or -2 on error, else the amount of bytes written to the buffer | ||
490 | */ | ||
491 | ssize_t | ||
492 | GNUNET_IDENTITY_write_signature_to_buffer (const struct | ||
493 | GNUNET_IDENTITY_Signature *sig, | ||
494 | void*buffer, | ||
495 | size_t len); | ||
496 | |||
497 | |||
498 | /** | ||
499 | * @brief Sign a given block. | ||
500 | * | ||
501 | * The @a purpose data is the beginning of the data of which the signature is | ||
502 | * to be created. The `size` field in @a purpose must correctly indicate the | ||
503 | * number of bytes of the data structure, including its header. If possible, | ||
504 | * use #GNUNET_IDENTITY_sign() instead of this function. | ||
505 | * | ||
506 | * @param priv private key to use for the signing | ||
507 | * @param purpose what to sign (size, purpose) | ||
508 | * @param[out] sig where to write the signature | ||
509 | * @return #GNUNET_SYSERR on error, #GNUNET_OK on success | ||
510 | */ | ||
511 | int | ||
512 | GNUNET_IDENTITY_sign_ (const struct | ||
513 | GNUNET_IDENTITY_PrivateKey *priv, | ||
514 | const struct | ||
515 | GNUNET_CRYPTO_EccSignaturePurpose *purpose, | ||
516 | struct GNUNET_IDENTITY_Signature *sig); | ||
517 | |||
518 | |||
519 | /** | ||
520 | * @brief Sign a given block with #GNUNET_IDENTITY_PrivateKey. | ||
521 | * | ||
522 | * The @a ps data must be a fixed-size struct for which the signature is to be | ||
523 | * created. The `size` field in @a ps->purpose must correctly indicate the | ||
524 | * number of bytes of the data structure, including its header. | ||
525 | * | ||
526 | * @param priv private key to use for the signing | ||
527 | * @param ps packed struct with what to sign, MUST begin with a purpose | ||
528 | * @param[out] sig where to write the signature | ||
529 | */ | ||
530 | #define GNUNET_IDENTITY_sign(priv,ps,sig) do { \ | ||
531 | /* check size is set correctly */ \ | ||
532 | GNUNET_assert (ntohl ((ps)->purpose.size) == sizeof (*(ps))); \ | ||
533 | /* check 'ps' begins with the purpose */ \ | ||
534 | GNUNET_static_assert (((void*) (ps)) == \ | ||
535 | ((void*) &(ps)->purpose)); \ | ||
536 | GNUNET_assert (GNUNET_OK == \ | ||
537 | GNUNET_IDENTITY_sign_ (priv, \ | ||
538 | &(ps)->purpose, \ | ||
539 | sig)); \ | ||
540 | } while (0) | ||
541 | |||
542 | |||
543 | /** | ||
544 | * @brief Verify a given signature. | ||
545 | * | ||
546 | * The @a validate data is the beginning of the data of which the signature | ||
547 | * is to be verified. The `size` field in @a validate must correctly indicate | ||
548 | * the number of bytes of the data structure, including its header. If @a | ||
549 | * purpose does not match the purpose given in @a validate (the latter must be | ||
550 | * in big endian), signature verification fails. If possible, | ||
551 | * use #GNUNET_IDENTITY_signature_verify() instead of this function (only if @a validate | ||
552 | * is not fixed-size, you must use this function directly). | ||
553 | * | ||
554 | * @param purpose what is the purpose that the signature should have? | ||
555 | * @param validate block to validate (size, purpose, data) | ||
556 | * @param sig signature that is being validated | ||
557 | * @param pub public key of the signer | ||
558 | * @returns #GNUNET_OK if ok, #GNUNET_SYSERR if invalid | ||
559 | */ | ||
560 | int | ||
561 | GNUNET_IDENTITY_signature_verify_ (uint32_t purpose, | ||
562 | const struct | ||
563 | GNUNET_CRYPTO_EccSignaturePurpose *validate, | ||
564 | const struct GNUNET_IDENTITY_Signature *sig, | ||
565 | const struct | ||
566 | GNUNET_IDENTITY_PublicKey *pub); | ||
567 | |||
568 | |||
569 | /** | ||
570 | * @brief Verify a given signature with #GNUNET_IDENTITY_PublicKey. | ||
571 | * | ||
572 | * The @a ps data must be a fixed-size struct for which the signature is to be | ||
573 | * created. The `size` field in @a ps->purpose must correctly indicate the | ||
574 | * number of bytes of the data structure, including its header. | ||
575 | * | ||
576 | * @param purp purpose of the signature, must match 'ps->purpose.purpose' | ||
577 | * (except in host byte order) | ||
578 | * @param ps packed struct with what to sign, MUST begin with a purpose | ||
579 | * @param sig where to read the signature from | ||
580 | * @param pub public key to use for the verifying | ||
581 | */ | ||
582 | #define GNUNET_IDENTITY_signature_verify(purp,ps,sig,pub) ({ \ | ||
583 | /* check size is set correctly */ \ | ||
584 | GNUNET_assert (ntohl ((ps)->purpose.size) == sizeof (*(ps))); \ | ||
585 | /* check 'ps' begins with the purpose */ \ | ||
586 | GNUNET_static_assert (((void*) (ps)) == \ | ||
587 | ((void*) &(ps)->purpose)); \ | ||
588 | GNUNET_IDENTITY_signature_verify_ (purp, \ | ||
589 | &(ps)->purpose, \ | ||
590 | sig, \ | ||
591 | pub); \ | ||
592 | }) | ||
593 | |||
594 | |||
595 | /** | ||
596 | * Encrypt a block with #GNUNET_IDENTITY_PublicKey and derives a | ||
597 | * #GNUNET_CRYPTO_EcdhePublicKey which is required for decryption | ||
598 | * using ecdh to derive a symmetric key. | ||
599 | * | ||
600 | * @param block the block to encrypt | ||
601 | * @param size the size of the @a block | ||
602 | * @param pub public key to use for ecdh | ||
603 | * @param ecc where to write the ecc public key | ||
604 | * @param result the output parameter in which to store the encrypted result | ||
605 | * can be the same or overlap with @c block | ||
606 | * @returns the size of the encrypted block, -1 for errors. | ||
607 | * Due to the use of CFB and therefore an effective stream cipher, | ||
608 | * this size should be the same as @c len. | ||
609 | */ | ||
610 | ssize_t | ||
611 | GNUNET_IDENTITY_encrypt (const void *block, | ||
612 | size_t size, | ||
613 | const struct GNUNET_IDENTITY_PublicKey *pub, | ||
614 | struct GNUNET_CRYPTO_EcdhePublicKey *ecc, | ||
615 | void *result); | ||
616 | |||
617 | |||
618 | /** | ||
619 | * Decrypt a given block with #GNUNET_IDENTITY_PrivateKey and a given | ||
620 | * #GNUNET_CRYPTO_EcdhePublicKey using ecdh to derive a symmetric key. | ||
621 | * | ||
622 | * @param block the data to decrypt, encoded as returned by encrypt | ||
623 | * @param size the size of the @a block to decrypt | ||
624 | * @param priv private key to use for ecdh | ||
625 | * @param ecc the ecc public key | ||
626 | * @param result address to store the result at | ||
627 | * can be the same or overlap with @c block | ||
628 | * @return -1 on failure, size of decrypted block on success. | ||
629 | * Due to the use of CFB and therefore an effective stream cipher, | ||
630 | * this size should be the same as @c size. | ||
631 | */ | ||
632 | ssize_t | ||
633 | GNUNET_IDENTITY_decrypt (const void *block, | ||
634 | size_t size, | ||
635 | const struct | ||
636 | GNUNET_IDENTITY_PrivateKey *priv, | ||
637 | const struct | ||
638 | GNUNET_CRYPTO_EcdhePublicKey *ecc, | ||
639 | void *result); | ||
640 | |||
641 | |||
642 | /** | ||
643 | * Creates a (Base32) string representation of the public key. | ||
644 | * The resulting string encodes a compacted representation of the key. | ||
645 | * See also #GNUNET_IDENTITY_key_get_length. | ||
646 | * | ||
647 | * @param key the key. | ||
648 | * @return the string representation of the key, or NULL on error. | ||
649 | */ | ||
650 | char * | ||
651 | GNUNET_IDENTITY_public_key_to_string (const struct | ||
652 | GNUNET_IDENTITY_PublicKey *key); | ||
653 | |||
654 | |||
655 | /** | ||
656 | * Creates a (Base32) string representation of the private key. | ||
657 | * The resulting string encodes a compacted representation of the key. | ||
658 | * See also #GNUNET_IDENTITY_key_get_length. | ||
659 | * | ||
660 | * @param key the key. | ||
661 | * @return the string representation of the key, or NULL on error. | ||
662 | */ | ||
663 | char * | ||
664 | GNUNET_IDENTITY_private_key_to_string (const struct | ||
665 | GNUNET_IDENTITY_PrivateKey *key); | ||
666 | |||
667 | |||
668 | /** | ||
669 | * Parses a (Base32) string representation of the public key. | ||
670 | * See also #GNUNET_IDENTITY_public_key_to_string. | ||
671 | * | ||
672 | * @param str the encoded key. | ||
673 | * @param key where to write the key. | ||
674 | * @return GNUNET_SYSERR on error. | ||
675 | */ | ||
676 | enum GNUNET_GenericReturnValue | ||
677 | GNUNET_IDENTITY_public_key_from_string (const char*str, | ||
678 | struct GNUNET_IDENTITY_PublicKey *key); | ||
679 | |||
680 | |||
681 | /** | ||
682 | * Parses a (Base32) string representation of the private key. | ||
683 | * See also #GNUNET_IDENTITY_private_key_to_string. | ||
684 | * | ||
685 | * @param str the encoded key. | ||
686 | * @param key where to write the key. | ||
687 | * @return GNUNET_SYSERR on error. | ||
688 | */ | ||
689 | enum GNUNET_GenericReturnValue | ||
690 | GNUNET_IDENTITY_private_key_from_string (const char*str, | ||
691 | struct GNUNET_IDENTITY_PrivateKey *key); | ||
692 | |||
693 | |||
694 | /** | ||
695 | * Retrieves the public key representation of a private key. | ||
696 | * | ||
697 | * @param privkey the private key. | ||
698 | * @param key the public key result. | ||
699 | * @return GNUNET_SYSERR on error. | ||
700 | */ | ||
701 | enum GNUNET_GenericReturnValue | ||
702 | GNUNET_IDENTITY_key_get_public (const struct | ||
703 | GNUNET_IDENTITY_PrivateKey *privkey, | ||
704 | struct GNUNET_IDENTITY_PublicKey *key); | ||
705 | |||
706 | |||
295 | /* ************* convenience API to lookup an ego ***************** */ | 707 | /* ************* convenience API to lookup an ego ***************** */ |
296 | 708 | ||
297 | /** | 709 | /** |
@@ -344,7 +756,7 @@ GNUNET_IDENTITY_ego_lookup_cancel (struct GNUNET_IDENTITY_EgoLookup *el); | |||
344 | typedef void | 756 | typedef void |
345 | (*GNUNET_IDENTITY_EgoSuffixCallback) ( | 757 | (*GNUNET_IDENTITY_EgoSuffixCallback) ( |
346 | void *cls, | 758 | void *cls, |
347 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *priv, | 759 | const struct GNUNET_IDENTITY_PrivateKey *priv, |
348 | const char *ego_name); | 760 | const char *ego_name); |
349 | 761 | ||
350 | 762 | ||
diff --git a/src/include/gnunet_json_lib.h b/src/include/gnunet_json_lib.h index 07a14d329..3dc79105e 100644 --- a/src/include/gnunet_json_lib.h +++ b/src/include/gnunet_json_lib.h | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet | 2 | This file is part of GNUnet |
3 | Copyright (C) 2014, 2015, 2016 GNUnet e.V. | 3 | Copyright (C) 2014, 2015, 2016, 2020 GNUnet e.V. |
4 | 4 | ||
5 | GNUnet is free software: you can redistribute it and/or modify it | 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 | 6 | under the terms of the GNU Affero General Public License as published |
@@ -28,7 +28,6 @@ | |||
28 | #define GNUNET_JSON_LIB_H | 28 | #define GNUNET_JSON_LIB_H |
29 | 29 | ||
30 | #include "gnunet_util_lib.h" | 30 | #include "gnunet_util_lib.h" |
31 | #include "gnunet_gnsrecord_lib.h" | ||
32 | #include <jansson.h> | 31 | #include <jansson.h> |
33 | #include <microhttpd.h> | 32 | #include <microhttpd.h> |
34 | 33 | ||
@@ -359,18 +358,6 @@ GNUNET_JSON_spec_rsa_signature (const char *name, | |||
359 | struct GNUNET_CRYPTO_RsaSignature **sig); | 358 | struct GNUNET_CRYPTO_RsaSignature **sig); |
360 | 359 | ||
361 | 360 | ||
362 | /** | ||
363 | * JSON Specification for GNS Records. | ||
364 | * | ||
365 | * @param gnsrecord_object struct of GNUNET_GNSRECORD_Data to fill | ||
366 | * @return JSON Specification | ||
367 | */ | ||
368 | struct GNUNET_JSON_Specification | ||
369 | GNUNET_JSON_spec_gnsrecord (struct GNUNET_GNSRECORD_Data **rd, | ||
370 | unsigned int *rd_count, | ||
371 | char **name); | ||
372 | |||
373 | |||
374 | /* ****************** Generic generator interface ******************* */ | 361 | /* ****************** Generic generator interface ******************* */ |
375 | 362 | ||
376 | 363 | ||
@@ -446,18 +433,6 @@ GNUNET_JSON_from_rsa_public_key (const struct GNUNET_CRYPTO_RsaPublicKey *pk); | |||
446 | json_t * | 433 | json_t * |
447 | GNUNET_JSON_from_rsa_signature (const struct GNUNET_CRYPTO_RsaSignature *sig); | 434 | GNUNET_JSON_from_rsa_signature (const struct GNUNET_CRYPTO_RsaSignature *sig); |
448 | 435 | ||
449 | /** | ||
450 | * Convert Gns record to JSON. | ||
451 | * | ||
452 | * @param rname name of record | ||
453 | * @param rd record data | ||
454 | * @return corresponding JSON encoding | ||
455 | */ | ||
456 | json_t * | ||
457 | GNUNET_JSON_from_gnsrecord (const char *rname, | ||
458 | const struct GNUNET_GNSRECORD_Data *rd, | ||
459 | unsigned int rd_count); | ||
460 | |||
461 | /* ******************* Helpers for MHD upload handling ******************* */ | 436 | /* ******************* Helpers for MHD upload handling ******************* */ |
462 | 437 | ||
463 | /** | 438 | /** |
diff --git a/src/include/gnunet_messenger_service.h b/src/include/gnunet_messenger_service.h new file mode 100644 index 000000000..8f5315c30 --- /dev/null +++ b/src/include/gnunet_messenger_service.h | |||
@@ -0,0 +1,436 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * | ||
23 | * @file | ||
24 | * MESSENGER service; manages decentralized chat groups | ||
25 | * | ||
26 | * @defgroup messenger MESSENGER service | ||
27 | * Instant messaging based on the CADET subsystem | ||
28 | * | ||
29 | * @{ | ||
30 | */ | ||
31 | |||
32 | #ifndef GNUNET_MESSENGER_SERVICE_H | ||
33 | #define GNUNET_MESSENGER_SERVICE_H | ||
34 | |||
35 | #ifdef __cplusplus | ||
36 | extern "C" { | ||
37 | #if 0 /* keep Emacsens' auto-indent happy */ | ||
38 | } | ||
39 | #endif | ||
40 | #endif | ||
41 | |||
42 | #include "platform.h" | ||
43 | #include "gnunet_configuration_lib.h" | ||
44 | #include "gnunet_crypto_lib.h" | ||
45 | #include "gnunet_identity_service.h" | ||
46 | #include "gnunet_mq_lib.h" | ||
47 | #include "gnunet_protocols.h" | ||
48 | #include "gnunet_scheduler_lib.h" | ||
49 | #include "gnunet_time_lib.h" | ||
50 | |||
51 | #define GNUNET_MESSENGER_SERVICE_NAME "messenger" | ||
52 | |||
53 | /** | ||
54 | * Opaque handle to the messenger | ||
55 | */ | ||
56 | struct GNUNET_MESSENGER_Handle; | ||
57 | |||
58 | /** | ||
59 | * Opaque handle to a room | ||
60 | */ | ||
61 | struct GNUNET_MESSENGER_Room; | ||
62 | |||
63 | /** | ||
64 | * Opaque handle to a contact | ||
65 | */ | ||
66 | struct GNUNET_MESSENGER_Contact; | ||
67 | |||
68 | /** | ||
69 | * Enum for the different supported kinds of messages | ||
70 | */ | ||
71 | enum GNUNET_MESSENGER_MessageKind | ||
72 | { | ||
73 | GNUNET_MESSENGER_KIND_INFO = 1, | ||
74 | |||
75 | GNUNET_MESSENGER_KIND_JOIN = 2, | ||
76 | GNUNET_MESSENGER_KIND_LEAVE = 3, | ||
77 | |||
78 | GNUNET_MESSENGER_KIND_NAME = 4, | ||
79 | GNUNET_MESSENGER_KIND_KEY = 5, | ||
80 | GNUNET_MESSENGER_KIND_PEER = 6, | ||
81 | GNUNET_MESSENGER_KIND_ID = 7, | ||
82 | |||
83 | GNUNET_MESSENGER_KIND_MISS = 8, | ||
84 | GNUNET_MESSENGER_KIND_MERGE = 9, | ||
85 | GNUNET_MESSENGER_KIND_REQUEST = 10, | ||
86 | |||
87 | GNUNET_MESSENGER_KIND_INVITE = 11, | ||
88 | GNUNET_MESSENGER_KIND_TEXT = 12, | ||
89 | GNUNET_MESSENGER_KIND_FILE = 13, | ||
90 | |||
91 | GNUNET_MESSENGER_KIND_PRIVATE = 14, | ||
92 | |||
93 | GNUNET_MESSENGER_KIND_UNKNOWN = 0 | ||
94 | }__attribute__((__packed__)); | ||
95 | |||
96 | /** | ||
97 | * Get the name of a message <i>kind</i>. | ||
98 | * | ||
99 | * @param kind Kind of a message | ||
100 | * @return Name of that kind | ||
101 | */ | ||
102 | const char* | ||
103 | GNUNET_MESSENGER_name_of_kind (enum GNUNET_MESSENGER_MessageKind kind); | ||
104 | |||
105 | struct GNUNET_MESSENGER_MessageHeader | ||
106 | { | ||
107 | struct GNUNET_IDENTITY_Signature signature; | ||
108 | |||
109 | struct GNUNET_TIME_AbsoluteNBO timestamp; | ||
110 | |||
111 | struct GNUNET_ShortHashCode sender_id; | ||
112 | struct GNUNET_HashCode previous; | ||
113 | |||
114 | enum GNUNET_MESSENGER_MessageKind kind; | ||
115 | }; | ||
116 | |||
117 | struct GNUNET_MESSENGER_MessageInfo | ||
118 | { | ||
119 | struct GNUNET_IDENTITY_PublicKey host_key; | ||
120 | struct GNUNET_ShortHashCode unique_id; | ||
121 | }; | ||
122 | |||
123 | struct GNUNET_MESSENGER_MessageJoin | ||
124 | { | ||
125 | struct GNUNET_IDENTITY_PublicKey key; | ||
126 | }; | ||
127 | |||
128 | struct GNUNET_MESSENGER_MessageLeave | ||
129 | { | ||
130 | }; | ||
131 | |||
132 | struct GNUNET_MESSENGER_MessageName | ||
133 | { | ||
134 | char *name; | ||
135 | }; | ||
136 | |||
137 | struct GNUNET_MESSENGER_MessageKey | ||
138 | { | ||
139 | struct GNUNET_IDENTITY_PublicKey key; | ||
140 | }; | ||
141 | |||
142 | struct GNUNET_MESSENGER_MessagePeer | ||
143 | { | ||
144 | struct GNUNET_PeerIdentity peer; | ||
145 | }; | ||
146 | |||
147 | struct GNUNET_MESSENGER_MessageId | ||
148 | { | ||
149 | struct GNUNET_ShortHashCode id; | ||
150 | }; | ||
151 | |||
152 | struct GNUNET_MESSENGER_MessageMiss | ||
153 | { | ||
154 | struct GNUNET_PeerIdentity peer; | ||
155 | }; | ||
156 | |||
157 | struct GNUNET_MESSENGER_MessageMerge | ||
158 | { | ||
159 | struct GNUNET_HashCode previous; | ||
160 | }; | ||
161 | |||
162 | struct GNUNET_MESSENGER_MessageRequest | ||
163 | { | ||
164 | struct GNUNET_HashCode hash; | ||
165 | }; | ||
166 | |||
167 | struct GNUNET_MESSENGER_MessageInvite | ||
168 | { | ||
169 | struct GNUNET_PeerIdentity door; | ||
170 | struct GNUNET_HashCode key; | ||
171 | }; | ||
172 | |||
173 | struct GNUNET_MESSENGER_MessageText | ||
174 | { | ||
175 | char *text; | ||
176 | }; | ||
177 | |||
178 | struct GNUNET_MESSENGER_MessageFile | ||
179 | { | ||
180 | struct GNUNET_CRYPTO_SymmetricSessionKey key; | ||
181 | struct GNUNET_HashCode hash; | ||
182 | char name[NAME_MAX]; | ||
183 | char *uri; | ||
184 | }; | ||
185 | |||
186 | struct GNUNET_MESSENGER_MessagePrivate | ||
187 | { | ||
188 | struct GNUNET_CRYPTO_EcdhePublicKey key; | ||
189 | |||
190 | uint16_t length; | ||
191 | char *data; | ||
192 | }; | ||
193 | |||
194 | struct GNUNET_MESSENGER_MessageBody | ||
195 | { | ||
196 | union | ||
197 | { | ||
198 | struct GNUNET_MESSENGER_MessageInfo info; | ||
199 | |||
200 | struct GNUNET_MESSENGER_MessageJoin join; | ||
201 | struct GNUNET_MESSENGER_MessageLeave leave; | ||
202 | |||
203 | struct GNUNET_MESSENGER_MessageName name; | ||
204 | struct GNUNET_MESSENGER_MessageKey key; | ||
205 | struct GNUNET_MESSENGER_MessagePeer peer; | ||
206 | struct GNUNET_MESSENGER_MessageId id; | ||
207 | |||
208 | struct GNUNET_MESSENGER_MessageMiss miss; | ||
209 | struct GNUNET_MESSENGER_MessageMerge merge; | ||
210 | struct GNUNET_MESSENGER_MessageRequest request; | ||
211 | |||
212 | struct GNUNET_MESSENGER_MessageInvite invite; | ||
213 | struct GNUNET_MESSENGER_MessageText text; | ||
214 | struct GNUNET_MESSENGER_MessageFile file; | ||
215 | |||
216 | struct GNUNET_MESSENGER_MessagePrivate private; | ||
217 | }; | ||
218 | }; | ||
219 | |||
220 | /** | ||
221 | * Struct to a message | ||
222 | */ | ||
223 | struct GNUNET_MESSENGER_Message | ||
224 | { | ||
225 | struct GNUNET_MESSENGER_MessageHeader header; | ||
226 | struct GNUNET_MESSENGER_MessageBody body; | ||
227 | }; | ||
228 | |||
229 | /** | ||
230 | * Method called whenever the EGO of a <i>handle</i> changes or if the first connection fails | ||
231 | * to load a valid EGO and the anonymous keypair will be used instead. | ||
232 | * | ||
233 | * @param cls Closure from <i>GNUNET_MESSENGER_connect</i> | ||
234 | * @param handle Messenger handle | ||
235 | */ | ||
236 | typedef void | ||
237 | (*GNUNET_MESSENGER_IdentityCallback) (void *cls, struct GNUNET_MESSENGER_Handle *handle); | ||
238 | |||
239 | /** | ||
240 | * Method called whenever a message is sent or received from a <i>room</i>. | ||
241 | * | ||
242 | * @param cls Closure from <i>GNUNET_MESSENGER_connect</i> | ||
243 | * @param room Room handle | ||
244 | * @param message Newly received or sent message | ||
245 | * @param hash Hash identifying the message | ||
246 | */ | ||
247 | typedef void | ||
248 | (*GNUNET_MESSENGER_MessageCallback) (void *cls, const struct GNUNET_MESSENGER_Room *room, | ||
249 | const struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
250 | |||
251 | /** | ||
252 | * Set up a handle for the messenger related functions and connects to all necessary services. It will look up the ego | ||
253 | * key identified by its <i>name</i> and use it for signing all messages from the handle. | ||
254 | * | ||
255 | * @param cfg Configuration to use | ||
256 | * @param name Name to look up an ego or NULL to stay anonymous | ||
257 | * @param identity_callback Function called when the EGO of the handle changes | ||
258 | * @param identity_cls Closure for the <i>identity_callback</i> handler | ||
259 | * @param msg_callback Function called when a new message is sent or received | ||
260 | * @param msg_cls Closure for the <i>msg_callback</i> handler | ||
261 | * @return Messenger handle to use, NULL on error | ||
262 | */ | ||
263 | struct GNUNET_MESSENGER_Handle* | ||
264 | GNUNET_MESSENGER_connect (const struct GNUNET_CONFIGURATION_Handle *cfg, const char *name, | ||
265 | GNUNET_MESSENGER_IdentityCallback identity_callback, void *identity_cls, | ||
266 | GNUNET_MESSENGER_MessageCallback msg_callback, void *msg_cls); | ||
267 | |||
268 | /** | ||
269 | * Update a handle of the messenger to use a different ego key and replace the old one with a newly generated one. All | ||
270 | * participated rooms get informed about the key renewal. The handle requires a set name for this function to work and | ||
271 | * it needs to be unused by other egos. | ||
272 | * | ||
273 | * Keep in mind that this will fully delete the old ego key (if any is used) even if any other service wants to use it | ||
274 | * as default. | ||
275 | * | ||
276 | * @param handle Messenger handle to use | ||
277 | * @return GNUNET_OK on success, GNUNET_SYSERR on failure | ||
278 | */ | ||
279 | int | ||
280 | GNUNET_MESSENGER_update (struct GNUNET_MESSENGER_Handle *handle); | ||
281 | |||
282 | /** | ||
283 | * Disconnect all of the messengers used services and clears up its used memory. | ||
284 | * | ||
285 | * @param handle Messenger handle to use | ||
286 | */ | ||
287 | void | ||
288 | GNUNET_MESSENGER_disconnect (struct GNUNET_MESSENGER_Handle *handle); | ||
289 | |||
290 | /** | ||
291 | * Get the name (if specified, otherwise NULL) used by the messenger. | ||
292 | * | ||
293 | * @param handle Messenger handle to use | ||
294 | * @return Name used by the messenger or NULL | ||
295 | */ | ||
296 | const char* | ||
297 | GNUNET_MESSENGER_get_name (const struct GNUNET_MESSENGER_Handle *handle); | ||
298 | |||
299 | /** | ||
300 | * Set the name for the messenger. This will rename the currently used ego and move all stored files related to the current | ||
301 | * name to its new directory. If anything fails during this process the function returns GNUNET_NO and the name for | ||
302 | * the messenger won't change as specified. | ||
303 | * | ||
304 | * @param handle Messenger handle to use | ||
305 | * @param name Name for the messenger to change to | ||
306 | * @return GNUNET_YES on success, GNUNET_NO on failure and GNUNET_SYSERR if <i>handle</i> is NULL | ||
307 | */ | ||
308 | int | ||
309 | GNUNET_MESSENGER_set_name (struct GNUNET_MESSENGER_Handle *handle, const char *name); | ||
310 | |||
311 | /** | ||
312 | * Get the public key used by the messenger. | ||
313 | * | ||
314 | * @param handle Messenger handle to use | ||
315 | * @return Used ego's public key | ||
316 | */ | ||
317 | const struct GNUNET_IDENTITY_PublicKey* | ||
318 | GNUNET_MESSENGER_get_key (const struct GNUNET_MESSENGER_Handle *handle); | ||
319 | |||
320 | /** | ||
321 | * Open a room to send and receive messages. The room will use the specified <i>key</i> as port for the underlying cadet | ||
322 | * service. Opening a room results in opening the port for incoming connections as possible <b>door</b>. | ||
323 | * | ||
324 | * Notice that there can only be one room related to a specific <i>key</i>. So trying to open two rooms with the same | ||
325 | * <i>key</i> will result in opening the room once but returning the handle both times because the room stays open. | ||
326 | * | ||
327 | * You can also open a room after entering it through a <b>door</b> using <i>GNUNET_MESSENGER_entry_room(...)</i>. This | ||
328 | * will notify all entered <b>doors</b> to list you as new <b>door</b>. | ||
329 | * | ||
330 | * ( All <b>doors</b> form a ring structured network to shorten the latency sending and receiving messages. ) | ||
331 | * | ||
332 | * @param handle Messenger handle to use | ||
333 | * @param key Hash identifying the port | ||
334 | * @return Room handle, NULL on error | ||
335 | */ | ||
336 | struct GNUNET_MESSENGER_Room* | ||
337 | GNUNET_MESSENGER_open_room (struct GNUNET_MESSENGER_Handle *handle, const struct GNUNET_HashCode *key); | ||
338 | |||
339 | /** | ||
340 | * Enter a room to send and receive messages through a <b>door</b> opened using <i>GNUNET_MESSENGER_open_room(...)</i>. | ||
341 | * | ||
342 | * Notice that there can only be one room related to a specific <i>key</i>. So trying to enter two rooms with the same | ||
343 | * <i>key</i> will result in entering the room once but returning the handle both times because the room stays entered. | ||
344 | * You can however enter a room through multiple <b>doors</b> in parallel which results in connecting both ends. But | ||
345 | * entering the room through the same <b>door</b> won't have any effect after the first time. | ||
346 | * | ||
347 | * You can also enter a room through a <b>door</b> after opening it using <i>GNUNET_MESSENGER_open_room(...)</i>. But the | ||
348 | * <b>door</b> may not be your own peer identity. | ||
349 | * | ||
350 | * ( All <b>doors</b> form a ring structured network to shorten the latency sending and receiving messages. ) | ||
351 | * | ||
352 | * @param handle Messenger handle to use | ||
353 | * @param door Peer identity of an open <b>door</b> | ||
354 | * @param key Hash identifying the port | ||
355 | * @return Room handle, NULL on error | ||
356 | */ | ||
357 | struct GNUNET_MESSENGER_Room* | ||
358 | GNUNET_MESSENGER_entry_room (struct GNUNET_MESSENGER_Handle *handle, const struct GNUNET_PeerIdentity *door, | ||
359 | const struct GNUNET_HashCode *key); | ||
360 | |||
361 | /** | ||
362 | * Close a room which was entered, opened or both in various order and variety. Closing a room will destroy all connections | ||
363 | * from your peer to another and the other way around. | ||
364 | * | ||
365 | * ( After a member closes a <b>door</b>, all members entered through that specific <b>door</b> have to use another one | ||
366 | * or open the room on their own. ) | ||
367 | * | ||
368 | * @param room Room handle | ||
369 | */ | ||
370 | void | ||
371 | GNUNET_MESSENGER_close_room (struct GNUNET_MESSENGER_Room *room); | ||
372 | |||
373 | /** | ||
374 | * Get the contact of a member in a <i>room</i> identified by their <i>id</i>. | ||
375 | * | ||
376 | * Notice that contacts are independent of rooms but will be removed if all rooms containing these contacts get closed. | ||
377 | * | ||
378 | * @param room Room handle | ||
379 | * @param id Hash identifying a member | ||
380 | * @return Contact handle, NULL if <i>id</i> is not in use | ||
381 | */ | ||
382 | struct GNUNET_MESSENGER_Contact* | ||
383 | GNUNET_MESSENGER_get_member (const struct GNUNET_MESSENGER_Room *room, const struct GNUNET_ShortHashCode *id); | ||
384 | |||
385 | /** | ||
386 | * Get the name used by the <i>contact</i>. | ||
387 | * | ||
388 | * @param contact Contact handle | ||
389 | * @return Name of <i>contact</i> or NULL | ||
390 | */ | ||
391 | const char* | ||
392 | GNUNET_MESSENGER_contact_get_name (const struct GNUNET_MESSENGER_Contact *contact); | ||
393 | |||
394 | /** | ||
395 | * Get the public key used by the <i>contact</i>. | ||
396 | * | ||
397 | * @param contact Contact handle | ||
398 | * @return Public key of the ego used by <i>contact</i> | ||
399 | */ | ||
400 | const struct GNUNET_IDENTITY_PublicKey* | ||
401 | GNUNET_MESSENGER_contact_get_key (const struct GNUNET_MESSENGER_Contact *contact); | ||
402 | |||
403 | /** | ||
404 | * Send a <i>message</i> into a </i>room</i>. If you opened the <i>room</i> all entered members will receive the | ||
405 | * <i>message</i>. If you entered the <i>room</i> through a <b>door</b> all so entered <b>doors</b> will receive the | ||
406 | * <i>message</i> as well. All members receiving the <i>message</i> will also propagate this <i>message</i> recursively | ||
407 | * as long as the <i>message</i> is unknown to them. | ||
408 | * | ||
409 | * Notice that all messages sent and received are also stored and can be propagated to new members entering the room. | ||
410 | * | ||
411 | * @param room Room handle | ||
412 | * @param message New message to send | ||
413 | */ | ||
414 | void | ||
415 | GNUNET_MESSENGER_send_message (struct GNUNET_MESSENGER_Room *room, const struct GNUNET_MESSENGER_Message *message); | ||
416 | |||
417 | /** | ||
418 | * Get the message in a <i>room</i> identified by its <i>hash</i>. | ||
419 | * | ||
420 | * @param room Room handle | ||
421 | * @param hash Hash identifying a message | ||
422 | * @return Message struct or NULL if no message with that hash is known | ||
423 | */ | ||
424 | const struct GNUNET_MESSENGER_Message* | ||
425 | GNUNET_MESSENGER_get_message (const struct GNUNET_MESSENGER_Room *room, const struct GNUNET_HashCode *hash); | ||
426 | |||
427 | #if 0 /* keep Emacsens' auto-indent happy */ | ||
428 | { | ||
429 | #endif | ||
430 | #ifdef __cplusplus | ||
431 | } | ||
432 | #endif | ||
433 | |||
434 | #endif //GNUNET_MESSENGER_SERVICE_H | ||
435 | |||
436 | /** @} *//* end of group */ | ||
diff --git a/src/include/gnunet_namestore_plugin.h b/src/include/gnunet_namestore_plugin.h index 443c9e451..9cc8abc6e 100644 --- a/src/include/gnunet_namestore_plugin.h +++ b/src/include/gnunet_namestore_plugin.h | |||
@@ -58,7 +58,7 @@ typedef void | |||
58 | (*GNUNET_NAMESTORE_RecordIterator) (void *cls, | 58 | (*GNUNET_NAMESTORE_RecordIterator) (void *cls, |
59 | uint64_t serial, | 59 | uint64_t serial, |
60 | const struct | 60 | const struct |
61 | GNUNET_CRYPTO_EcdsaPrivateKey *private_key, | 61 | GNUNET_IDENTITY_PrivateKey *private_key, |
62 | const char *label, | 62 | const char *label, |
63 | unsigned int rd_count, | 63 | unsigned int rd_count, |
64 | const struct GNUNET_GNSRECORD_Data *rd); | 64 | const struct GNUNET_GNSRECORD_Data *rd); |
@@ -87,7 +87,7 @@ struct GNUNET_NAMESTORE_PluginFunctions | |||
87 | */ | 87 | */ |
88 | int | 88 | int |
89 | (*store_records) (void *cls, | 89 | (*store_records) (void *cls, |
90 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 90 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
91 | const char *label, | 91 | const char *label, |
92 | unsigned int rd_count, | 92 | unsigned int rd_count, |
93 | const struct GNUNET_GNSRECORD_Data *rd); | 93 | const struct GNUNET_GNSRECORD_Data *rd); |
@@ -104,7 +104,7 @@ struct GNUNET_NAMESTORE_PluginFunctions | |||
104 | */ | 104 | */ |
105 | int | 105 | int |
106 | (*lookup_records) (void *cls, | 106 | (*lookup_records) (void *cls, |
107 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 107 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
108 | const char *label, | 108 | const char *label, |
109 | GNUNET_NAMESTORE_RecordIterator iter, | 109 | GNUNET_NAMESTORE_RecordIterator iter, |
110 | void *iter_cls); | 110 | void *iter_cls); |
@@ -126,7 +126,7 @@ struct GNUNET_NAMESTORE_PluginFunctions | |||
126 | */ | 126 | */ |
127 | int | 127 | int |
128 | (*iterate_records) (void *cls, | 128 | (*iterate_records) (void *cls, |
129 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 129 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
130 | uint64_t serial, | 130 | uint64_t serial, |
131 | uint64_t limit, | 131 | uint64_t limit, |
132 | GNUNET_NAMESTORE_RecordIterator iter, | 132 | GNUNET_NAMESTORE_RecordIterator iter, |
@@ -146,8 +146,8 @@ struct GNUNET_NAMESTORE_PluginFunctions | |||
146 | */ | 146 | */ |
147 | int | 147 | int |
148 | (*zone_to_name) (void *cls, | 148 | (*zone_to_name) (void *cls, |
149 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 149 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
150 | const struct GNUNET_CRYPTO_EcdsaPublicKey *value_zone, | 150 | const struct GNUNET_IDENTITY_PublicKey *value_zone, |
151 | GNUNET_NAMESTORE_RecordIterator iter, | 151 | GNUNET_NAMESTORE_RecordIterator iter, |
152 | void *iter_cls); | 152 | void *iter_cls); |
153 | }; | 153 | }; |
diff --git a/src/include/gnunet_namestore_service.h b/src/include/gnunet_namestore_service.h index bf42c8d34..ca4d2cb52 100644 --- a/src/include/gnunet_namestore_service.h +++ b/src/include/gnunet_namestore_service.h | |||
@@ -41,6 +41,7 @@ | |||
41 | #include "gnunet_util_lib.h" | 41 | #include "gnunet_util_lib.h" |
42 | #include "gnunet_block_lib.h" | 42 | #include "gnunet_block_lib.h" |
43 | #include "gnunet_gnsrecord_lib.h" | 43 | #include "gnunet_gnsrecord_lib.h" |
44 | #include "gnunet_identity_service.h" | ||
44 | 45 | ||
45 | #ifdef __cplusplus | 46 | #ifdef __cplusplus |
46 | extern "C" | 47 | extern "C" |
@@ -127,7 +128,7 @@ typedef void | |||
127 | struct GNUNET_NAMESTORE_QueueEntry * | 128 | struct GNUNET_NAMESTORE_QueueEntry * |
128 | GNUNET_NAMESTORE_records_store (struct GNUNET_NAMESTORE_Handle *h, | 129 | GNUNET_NAMESTORE_records_store (struct GNUNET_NAMESTORE_Handle *h, |
129 | const struct | 130 | const struct |
130 | GNUNET_CRYPTO_EcdsaPrivateKey *pkey, | 131 | GNUNET_IDENTITY_PrivateKey *pkey, |
131 | const char *label, | 132 | const char *label, |
132 | unsigned int rd_count, | 133 | unsigned int rd_count, |
133 | const struct GNUNET_GNSRECORD_Data *rd, | 134 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -147,7 +148,7 @@ GNUNET_NAMESTORE_records_store (struct GNUNET_NAMESTORE_Handle *h, | |||
147 | typedef void | 148 | typedef void |
148 | (*GNUNET_NAMESTORE_RecordMonitor) (void *cls, | 149 | (*GNUNET_NAMESTORE_RecordMonitor) (void *cls, |
149 | const struct | 150 | const struct |
150 | GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 151 | GNUNET_IDENTITY_PrivateKey *zone, |
151 | const char *label, | 152 | const char *label, |
152 | unsigned int rd_count, | 153 | unsigned int rd_count, |
153 | const struct GNUNET_GNSRECORD_Data *rd); | 154 | const struct GNUNET_GNSRECORD_Data *rd); |
@@ -170,7 +171,7 @@ typedef void | |||
170 | struct GNUNET_NAMESTORE_QueueEntry * | 171 | struct GNUNET_NAMESTORE_QueueEntry * |
171 | GNUNET_NAMESTORE_records_lookup (struct GNUNET_NAMESTORE_Handle *h, | 172 | GNUNET_NAMESTORE_records_lookup (struct GNUNET_NAMESTORE_Handle *h, |
172 | const struct | 173 | const struct |
173 | GNUNET_CRYPTO_EcdsaPrivateKey *pkey, | 174 | GNUNET_IDENTITY_PrivateKey *pkey, |
174 | const char *label, | 175 | const char *label, |
175 | GNUNET_SCHEDULER_TaskCallback error_cb, | 176 | GNUNET_SCHEDULER_TaskCallback error_cb, |
176 | void *error_cb_cls, | 177 | void *error_cb_cls, |
@@ -197,9 +198,9 @@ GNUNET_NAMESTORE_records_lookup (struct GNUNET_NAMESTORE_Handle *h, | |||
197 | */ | 198 | */ |
198 | struct GNUNET_NAMESTORE_QueueEntry * | 199 | struct GNUNET_NAMESTORE_QueueEntry * |
199 | GNUNET_NAMESTORE_zone_to_name (struct GNUNET_NAMESTORE_Handle *h, | 200 | GNUNET_NAMESTORE_zone_to_name (struct GNUNET_NAMESTORE_Handle *h, |
200 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 201 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
201 | const struct | 202 | const struct |
202 | GNUNET_CRYPTO_EcdsaPublicKey *value_zone, | 203 | GNUNET_IDENTITY_PublicKey *value_zone, |
203 | GNUNET_SCHEDULER_TaskCallback error_cb, | 204 | GNUNET_SCHEDULER_TaskCallback error_cb, |
204 | void *error_cb_cls, | 205 | void *error_cb_cls, |
205 | GNUNET_NAMESTORE_RecordMonitor proc, | 206 | GNUNET_NAMESTORE_RecordMonitor proc, |
@@ -246,7 +247,7 @@ GNUNET_NAMESTORE_cancel (struct GNUNET_NAMESTORE_QueueEntry *qe); | |||
246 | struct GNUNET_NAMESTORE_ZoneIterator * | 247 | struct GNUNET_NAMESTORE_ZoneIterator * |
247 | GNUNET_NAMESTORE_zone_iteration_start (struct GNUNET_NAMESTORE_Handle *h, | 248 | GNUNET_NAMESTORE_zone_iteration_start (struct GNUNET_NAMESTORE_Handle *h, |
248 | const struct | 249 | const struct |
249 | GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 250 | GNUNET_IDENTITY_PrivateKey *zone, |
250 | GNUNET_SCHEDULER_TaskCallback error_cb, | 251 | GNUNET_SCHEDULER_TaskCallback error_cb, |
251 | void *error_cb_cls, | 252 | void *error_cb_cls, |
252 | GNUNET_NAMESTORE_RecordMonitor proc, | 253 | GNUNET_NAMESTORE_RecordMonitor proc, |
@@ -316,7 +317,7 @@ struct GNUNET_NAMESTORE_ZoneMonitor * | |||
316 | GNUNET_NAMESTORE_zone_monitor_start (const struct | 317 | GNUNET_NAMESTORE_zone_monitor_start (const struct |
317 | GNUNET_CONFIGURATION_Handle *cfg, | 318 | GNUNET_CONFIGURATION_Handle *cfg, |
318 | const struct | 319 | const struct |
319 | GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 320 | GNUNET_IDENTITY_PrivateKey *zone, |
320 | int iterate_first, | 321 | int iterate_first, |
321 | GNUNET_SCHEDULER_TaskCallback error_cb, | 322 | GNUNET_SCHEDULER_TaskCallback error_cb, |
322 | void *error_cb_cls, | 323 | void *error_cb_cls, |
diff --git a/src/include/gnunet_pq_lib.h b/src/include/gnunet_pq_lib.h index ca549f77c..de717526c 100644 --- a/src/include/gnunet_pq_lib.h +++ b/src/include/gnunet_pq_lib.h | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet | 2 | This file is part of GNUnet |
3 | Copyright (C) 2016, 2017 GNUnet e.V. | 3 | Copyright (C) 2016, 2017, 2020 GNUnet e.V. |
4 | 4 | ||
5 | GNUnet is free software: you can redistribute it and/or modify it | 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 | 6 | under the terms of the GNU Affero General Public License as published |
@@ -87,6 +87,7 @@ struct GNUNET_PQ_QueryParam | |||
87 | * Number of parameters eaten by this operation. | 87 | * Number of parameters eaten by this operation. |
88 | */ | 88 | */ |
89 | unsigned int num_params; | 89 | unsigned int num_params; |
90 | |||
90 | }; | 91 | }; |
91 | 92 | ||
92 | 93 | ||
@@ -100,20 +101,32 @@ struct GNUNET_PQ_QueryParam | |||
100 | 101 | ||
101 | 102 | ||
102 | /** | 103 | /** |
104 | * Generate query parameter to create a NULL value. | ||
105 | * | ||
106 | * @return query parameter to use to insert NULL into DB | ||
107 | */ | ||
108 | struct GNUNET_PQ_QueryParam | ||
109 | GNUNET_PQ_query_param_null (void); | ||
110 | |||
111 | |||
112 | /** | ||
103 | * Generate query parameter for a buffer @a ptr of | 113 | * Generate query parameter for a buffer @a ptr of |
104 | * @a ptr_size bytes. | 114 | * @a ptr_size bytes. |
105 | * | 115 | * |
106 | * @param ptr pointer to the query parameter to pass | 116 | * @param ptr pointer to the query parameter to pass |
107 | * @oaran ptr_size number of bytes in @a ptr | 117 | * @oaran ptr_size number of bytes in @a ptr |
118 | * @return query parameter to use | ||
108 | */ | 119 | */ |
109 | struct GNUNET_PQ_QueryParam | 120 | struct GNUNET_PQ_QueryParam |
110 | GNUNET_PQ_query_param_fixed_size (const void *ptr, size_t ptr_size); | 121 | GNUNET_PQ_query_param_fixed_size (const void *ptr, |
122 | size_t ptr_size); | ||
111 | 123 | ||
112 | 124 | ||
113 | /** | 125 | /** |
114 | * Generate query parameter for a string. | 126 | * Generate query parameter for a string. |
115 | * | 127 | * |
116 | * @param ptr pointer to the string query parameter to pass | 128 | * @param ptr pointer to the string query parameter to pass |
129 | * @return query parameter to use | ||
117 | */ | 130 | */ |
118 | struct GNUNET_PQ_QueryParam | 131 | struct GNUNET_PQ_QueryParam |
119 | GNUNET_PQ_query_param_string (const char *ptr); | 132 | GNUNET_PQ_query_param_string (const char *ptr); |
@@ -124,6 +137,7 @@ GNUNET_PQ_query_param_string (const char *ptr); | |||
124 | * by variable type. | 137 | * by variable type. |
125 | * | 138 | * |
126 | * @param x pointer to the query parameter to pass. | 139 | * @param x pointer to the query parameter to pass. |
140 | * @return query parameter to use | ||
127 | */ | 141 | */ |
128 | #define GNUNET_PQ_query_param_auto_from_type(x) \ | 142 | #define GNUNET_PQ_query_param_auto_from_type(x) \ |
129 | GNUNET_PQ_query_param_fixed_size ((x), sizeof(*(x))) | 143 | GNUNET_PQ_query_param_fixed_size ((x), sizeof(*(x))) |
@@ -134,6 +148,7 @@ GNUNET_PQ_query_param_string (const char *ptr); | |||
134 | * database must contain a BLOB type in the respective position. | 148 | * database must contain a BLOB type in the respective position. |
135 | * | 149 | * |
136 | * @param x the query parameter to pass. | 150 | * @param x the query parameter to pass. |
151 | * @return query parameter to use | ||
137 | */ | 152 | */ |
138 | struct GNUNET_PQ_QueryParam | 153 | struct GNUNET_PQ_QueryParam |
139 | GNUNET_PQ_query_param_rsa_public_key ( | 154 | GNUNET_PQ_query_param_rsa_public_key ( |
@@ -145,6 +160,7 @@ GNUNET_PQ_query_param_rsa_public_key ( | |||
145 | * database must contain a BLOB type in the respective position. | 160 | * database must contain a BLOB type in the respective position. |
146 | * | 161 | * |
147 | * @param x the query parameter to pass | 162 | * @param x the query parameter to pass |
163 | * @return query parameter to use | ||
148 | */ | 164 | */ |
149 | struct GNUNET_PQ_QueryParam | 165 | struct GNUNET_PQ_QueryParam |
150 | GNUNET_PQ_query_param_rsa_signature ( | 166 | GNUNET_PQ_query_param_rsa_signature ( |
@@ -156,6 +172,7 @@ GNUNET_PQ_query_param_rsa_signature ( | |||
156 | * The database must store a 64-bit integer. | 172 | * The database must store a 64-bit integer. |
157 | * | 173 | * |
158 | * @param x pointer to the query parameter to pass | 174 | * @param x pointer to the query parameter to pass |
175 | * @return query parameter to use | ||
159 | */ | 176 | */ |
160 | struct GNUNET_PQ_QueryParam | 177 | struct GNUNET_PQ_QueryParam |
161 | GNUNET_PQ_query_param_relative_time (const struct GNUNET_TIME_Relative *x); | 178 | GNUNET_PQ_query_param_relative_time (const struct GNUNET_TIME_Relative *x); |
@@ -166,6 +183,7 @@ GNUNET_PQ_query_param_relative_time (const struct GNUNET_TIME_Relative *x); | |||
166 | * The database must store a 64-bit integer. | 183 | * The database must store a 64-bit integer. |
167 | * | 184 | * |
168 | * @param x pointer to the query parameter to pass | 185 | * @param x pointer to the query parameter to pass |
186 | * @return query parameter to use | ||
169 | */ | 187 | */ |
170 | struct GNUNET_PQ_QueryParam | 188 | struct GNUNET_PQ_QueryParam |
171 | GNUNET_PQ_query_param_absolute_time (const struct GNUNET_TIME_Absolute *x); | 189 | GNUNET_PQ_query_param_absolute_time (const struct GNUNET_TIME_Absolute *x); |
@@ -176,6 +194,7 @@ GNUNET_PQ_query_param_absolute_time (const struct GNUNET_TIME_Absolute *x); | |||
176 | * The database must store a 64-bit integer. | 194 | * The database must store a 64-bit integer. |
177 | * | 195 | * |
178 | * @param x pointer to the query parameter to pass | 196 | * @param x pointer to the query parameter to pass |
197 | * @return query parameter to use | ||
179 | */ | 198 | */ |
180 | struct GNUNET_PQ_QueryParam | 199 | struct GNUNET_PQ_QueryParam |
181 | GNUNET_PQ_query_param_absolute_time_nbo ( | 200 | GNUNET_PQ_query_param_absolute_time_nbo ( |
@@ -186,6 +205,7 @@ GNUNET_PQ_query_param_absolute_time_nbo ( | |||
186 | * Generate query parameter for an uint16_t in host byte order. | 205 | * Generate query parameter for an uint16_t in host byte order. |
187 | * | 206 | * |
188 | * @param x pointer to the query parameter to pass | 207 | * @param x pointer to the query parameter to pass |
208 | * @return query parameter to use | ||
189 | */ | 209 | */ |
190 | struct GNUNET_PQ_QueryParam | 210 | struct GNUNET_PQ_QueryParam |
191 | GNUNET_PQ_query_param_uint16 (const uint16_t *x); | 211 | GNUNET_PQ_query_param_uint16 (const uint16_t *x); |
@@ -195,6 +215,7 @@ GNUNET_PQ_query_param_uint16 (const uint16_t *x); | |||
195 | * Generate query parameter for an uint32_t in host byte order. | 215 | * Generate query parameter for an uint32_t in host byte order. |
196 | * | 216 | * |
197 | * @param x pointer to the query parameter to pass | 217 | * @param x pointer to the query parameter to pass |
218 | * @return query parameter to use | ||
198 | */ | 219 | */ |
199 | struct GNUNET_PQ_QueryParam | 220 | struct GNUNET_PQ_QueryParam |
200 | GNUNET_PQ_query_param_uint32 (const uint32_t *x); | 221 | GNUNET_PQ_query_param_uint32 (const uint32_t *x); |
@@ -204,6 +225,7 @@ GNUNET_PQ_query_param_uint32 (const uint32_t *x); | |||
204 | * Generate query parameter for an uint16_t in host byte order. | 225 | * Generate query parameter for an uint16_t in host byte order. |
205 | * | 226 | * |
206 | * @param x pointer to the query parameter to pass | 227 | * @param x pointer to the query parameter to pass |
228 | * @return query parameter to use | ||
207 | */ | 229 | */ |
208 | struct GNUNET_PQ_QueryParam | 230 | struct GNUNET_PQ_QueryParam |
209 | GNUNET_PQ_query_param_uint64 (const uint64_t *x); | 231 | GNUNET_PQ_query_param_uint64 (const uint64_t *x); |
@@ -288,6 +310,20 @@ struct GNUNET_PQ_ResultSpec | |||
288 | * Where to store actual size of the result. | 310 | * Where to store actual size of the result. |
289 | */ | 311 | */ |
290 | size_t *result_size; | 312 | size_t *result_size; |
313 | |||
314 | /** | ||
315 | * True if NULL is allowed for a value in the database. | ||
316 | */ | ||
317 | bool is_nullable; | ||
318 | |||
319 | /** | ||
320 | * Points to a location where we should store | ||
321 | * "true" if the result found is NULL, and | ||
322 | * otherwise "false". Only used if @e is_nullable | ||
323 | * is true. | ||
324 | */ | ||
325 | bool *is_null; | ||
326 | |||
291 | }; | 327 | }; |
292 | 328 | ||
293 | 329 | ||
@@ -303,6 +339,21 @@ struct GNUNET_PQ_ResultSpec | |||
303 | 339 | ||
304 | 340 | ||
305 | /** | 341 | /** |
342 | * Allow NULL value to be found in the database | ||
343 | * for the given value. | ||
344 | * | ||
345 | * @param rs result spec entry to modify | ||
346 | * @param[out] is_null location set to 'true' if the | ||
347 | * value was indeed NULL, set to 'false' if the | ||
348 | * value was non-NULL | ||
349 | * @return array entry for the result specification to use | ||
350 | */ | ||
351 | struct GNUNET_PQ_ResultSpec | ||
352 | GNUNET_PQ_result_spec_allow_null (struct GNUNET_PQ_ResultSpec rs, | ||
353 | bool *is_null); | ||
354 | |||
355 | |||
356 | /** | ||
306 | * Variable-size result expected. | 357 | * Variable-size result expected. |
307 | * | 358 | * |
308 | * @param name name of the field in the table | 359 | * @param name name of the field in the table |
diff --git a/src/include/gnunet_protocols.h b/src/include/gnunet_protocols.h index d9821ffe8..3bdebeb50 100644 --- a/src/include/gnunet_protocols.h +++ b/src/include/gnunet_protocols.h | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet. | 2 | This file is part of GNUnet. |
3 | Copyright (C) 2001--2018 GNUnet e.V. | 3 | Copyright (C) 2001--2020 GNUnet e.V. |
4 | 4 | ||
5 | GNUnet is free software: you can redistribute it and/or modify it | 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 | 6 | under the terms of the GNU Affero General Public License as published |
@@ -20,6 +20,7 @@ | |||
20 | 20 | ||
21 | /** | 21 | /** |
22 | * @author Christian Grothoff | 22 | * @author Christian Grothoff |
23 | * @author Tobias Frisch | ||
23 | * | 24 | * |
24 | * @file | 25 | * @file |
25 | * Constants for network protocols | 26 | * Constants for network protocols |
@@ -3518,6 +3519,46 @@ extern "C" { | |||
3518 | #define GNUNET_MESSAGE_TYPE_RECLAIM_REFERENCE_RESULT 1501 | 3519 | #define GNUNET_MESSAGE_TYPE_RECLAIM_REFERENCE_RESULT 1501 |
3519 | 3520 | ||
3520 | 3521 | ||
3522 | /*********************************************************************************/ | ||
3523 | /********************************** MESSENGER **********************************/ | ||
3524 | /*********************************************************************************/ | ||
3525 | /* MESSENGER: message types 1600-1629 | ||
3526 | * 1600-1609 Connection-level Messages | ||
3527 | * 1610-1619 Room-level Messages | ||
3528 | */ | ||
3529 | |||
3530 | /********************************* Connection **********************************/ | ||
3531 | |||
3532 | #define GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_CREATE 1600 | ||
3533 | |||
3534 | #define GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_UPDATE 1601 | ||
3535 | |||
3536 | #define GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_DESTROY 1602 | ||
3537 | |||
3538 | #define GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_GET_NAME 1603 | ||
3539 | |||
3540 | #define GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_SET_NAME 1604 | ||
3541 | |||
3542 | #define GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_GET_KEY 1605 | ||
3543 | |||
3544 | #define GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_MEMBER_ID 1606 | ||
3545 | |||
3546 | /************************************ Room *************************************/ | ||
3547 | |||
3548 | #define GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_OPEN 1610 | ||
3549 | |||
3550 | #define GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_ENTRY 1611 | ||
3551 | |||
3552 | #define GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_CLOSE 1612 | ||
3553 | |||
3554 | #define GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_SEND_MESSAGE 1614 | ||
3555 | |||
3556 | #define GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_RECV_MESSAGE 1615 | ||
3557 | |||
3558 | #define GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_GET_MESSAGE 1616 | ||
3559 | |||
3560 | /*********************************************************************************/ | ||
3561 | |||
3521 | /** | 3562 | /** |
3522 | * Type used to match 'all' message types. | 3563 | * Type used to match 'all' message types. |
3523 | */ | 3564 | */ |
diff --git a/src/include/gnunet_reclaim_service.h b/src/include/gnunet_reclaim_service.h index 368058f56..8549081a1 100644 --- a/src/include/gnunet_reclaim_service.h +++ b/src/include/gnunet_reclaim_service.h | |||
@@ -38,6 +38,7 @@ extern "C" { | |||
38 | #endif | 38 | #endif |
39 | #endif | 39 | #endif |
40 | 40 | ||
41 | #include "gnunet_identity_service.h" | ||
41 | #include "gnunet_reclaim_lib.h" | 42 | #include "gnunet_reclaim_lib.h" |
42 | #include "gnunet_util_lib.h" | 43 | #include "gnunet_util_lib.h" |
43 | 44 | ||
@@ -69,12 +70,12 @@ struct GNUNET_RECLAIM_Ticket | |||
69 | /** | 70 | /** |
70 | * The ticket issuer (= the user) | 71 | * The ticket issuer (= the user) |
71 | */ | 72 | */ |
72 | struct GNUNET_CRYPTO_EcdsaPublicKey identity; | 73 | struct GNUNET_IDENTITY_PublicKey identity; |
73 | 74 | ||
74 | /** | 75 | /** |
75 | * The ticket audience (= relying party) | 76 | * The ticket audience (= relying party) |
76 | */ | 77 | */ |
77 | struct GNUNET_CRYPTO_EcdsaPublicKey audience; | 78 | struct GNUNET_IDENTITY_PublicKey audience; |
78 | 79 | ||
79 | /** | 80 | /** |
80 | * The ticket random identifier | 81 | * The ticket random identifier |
@@ -129,7 +130,7 @@ typedef void (*GNUNET_RECLAIM_ContinuationWithStatus) (void *cls, | |||
129 | * @param attr The attribute | 130 | * @param attr The attribute |
130 | */ | 131 | */ |
131 | typedef void (*GNUNET_RECLAIM_AttributeResult) ( | 132 | typedef void (*GNUNET_RECLAIM_AttributeResult) ( |
132 | void *cls, const struct GNUNET_CRYPTO_EcdsaPublicKey *identity, | 133 | void *cls, const struct GNUNET_IDENTITY_PublicKey *identity, |
133 | const struct GNUNET_RECLAIM_Attribute *attr); | 134 | const struct GNUNET_RECLAIM_Attribute *attr); |
134 | 135 | ||
135 | /** | 136 | /** |
@@ -141,7 +142,7 @@ typedef void (*GNUNET_RECLAIM_AttributeResult) ( | |||
141 | * @param presentation The presentation for the credential (may be NULL) | 142 | * @param presentation The presentation for the credential (may be NULL) |
142 | */ | 143 | */ |
143 | typedef void (*GNUNET_RECLAIM_AttributeTicketResult) ( | 144 | typedef void (*GNUNET_RECLAIM_AttributeTicketResult) ( |
144 | void *cls, const struct GNUNET_CRYPTO_EcdsaPublicKey *identity, | 145 | void *cls, const struct GNUNET_IDENTITY_PublicKey *identity, |
145 | const struct GNUNET_RECLAIM_Attribute *attr, | 146 | const struct GNUNET_RECLAIM_Attribute *attr, |
146 | const struct GNUNET_RECLAIM_Presentation *presentation); | 147 | const struct GNUNET_RECLAIM_Presentation *presentation); |
147 | 148 | ||
@@ -155,7 +156,7 @@ typedef void (*GNUNET_RECLAIM_AttributeTicketResult) ( | |||
155 | * @param attributes the parsed attributes | 156 | * @param attributes the parsed attributes |
156 | */ | 157 | */ |
157 | typedef void (*GNUNET_RECLAIM_CredentialResult) ( | 158 | typedef void (*GNUNET_RECLAIM_CredentialResult) ( |
158 | void *cls, const struct GNUNET_CRYPTO_EcdsaPublicKey *identity, | 159 | void *cls, const struct GNUNET_IDENTITY_PublicKey *identity, |
159 | const struct GNUNET_RECLAIM_Credential *credential); | 160 | const struct GNUNET_RECLAIM_Credential *credential); |
160 | 161 | ||
161 | 162 | ||
@@ -184,7 +185,7 @@ GNUNET_RECLAIM_connect (const struct GNUNET_CONFIGURATION_Handle *cfg); | |||
184 | struct GNUNET_RECLAIM_Operation * | 185 | struct GNUNET_RECLAIM_Operation * |
185 | GNUNET_RECLAIM_attribute_store ( | 186 | GNUNET_RECLAIM_attribute_store ( |
186 | struct GNUNET_RECLAIM_Handle *h, | 187 | struct GNUNET_RECLAIM_Handle *h, |
187 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pkey, | 188 | const struct GNUNET_IDENTITY_PrivateKey *pkey, |
188 | const struct GNUNET_RECLAIM_Attribute *attr, | 189 | const struct GNUNET_RECLAIM_Attribute *attr, |
189 | const struct GNUNET_TIME_Relative *exp_interval, | 190 | const struct GNUNET_TIME_Relative *exp_interval, |
190 | GNUNET_RECLAIM_ContinuationWithStatus cont, void *cont_cls); | 191 | GNUNET_RECLAIM_ContinuationWithStatus cont, void *cont_cls); |
@@ -205,7 +206,7 @@ GNUNET_RECLAIM_attribute_store ( | |||
205 | struct GNUNET_RECLAIM_Operation * | 206 | struct GNUNET_RECLAIM_Operation * |
206 | GNUNET_RECLAIM_credential_store ( | 207 | GNUNET_RECLAIM_credential_store ( |
207 | struct GNUNET_RECLAIM_Handle *h, | 208 | struct GNUNET_RECLAIM_Handle *h, |
208 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pkey, | 209 | const struct GNUNET_IDENTITY_PrivateKey *pkey, |
209 | const struct GNUNET_RECLAIM_Credential *credential, | 210 | const struct GNUNET_RECLAIM_Credential *credential, |
210 | const struct GNUNET_TIME_Relative *exp_interval, | 211 | const struct GNUNET_TIME_Relative *exp_interval, |
211 | GNUNET_RECLAIM_ContinuationWithStatus cont, | 212 | GNUNET_RECLAIM_ContinuationWithStatus cont, |
@@ -226,7 +227,7 @@ GNUNET_RECLAIM_credential_store ( | |||
226 | struct GNUNET_RECLAIM_Operation * | 227 | struct GNUNET_RECLAIM_Operation * |
227 | GNUNET_RECLAIM_attribute_delete ( | 228 | GNUNET_RECLAIM_attribute_delete ( |
228 | struct GNUNET_RECLAIM_Handle *h, | 229 | struct GNUNET_RECLAIM_Handle *h, |
229 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pkey, | 230 | const struct GNUNET_IDENTITY_PrivateKey *pkey, |
230 | const struct GNUNET_RECLAIM_Attribute *attr, | 231 | const struct GNUNET_RECLAIM_Attribute *attr, |
231 | GNUNET_RECLAIM_ContinuationWithStatus cont, void *cont_cls); | 232 | GNUNET_RECLAIM_ContinuationWithStatus cont, void *cont_cls); |
232 | 233 | ||
@@ -244,7 +245,7 @@ GNUNET_RECLAIM_attribute_delete ( | |||
244 | struct GNUNET_RECLAIM_Operation * | 245 | struct GNUNET_RECLAIM_Operation * |
245 | GNUNET_RECLAIM_credential_delete ( | 246 | GNUNET_RECLAIM_credential_delete ( |
246 | struct GNUNET_RECLAIM_Handle *h, | 247 | struct GNUNET_RECLAIM_Handle *h, |
247 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pkey, | 248 | const struct GNUNET_IDENTITY_PrivateKey *pkey, |
248 | const struct GNUNET_RECLAIM_Credential *cred, | 249 | const struct GNUNET_RECLAIM_Credential *cred, |
249 | GNUNET_RECLAIM_ContinuationWithStatus cont, | 250 | GNUNET_RECLAIM_ContinuationWithStatus cont, |
250 | void *cont_cls); | 251 | void *cont_cls); |
@@ -276,7 +277,7 @@ GNUNET_RECLAIM_credential_delete ( | |||
276 | struct GNUNET_RECLAIM_AttributeIterator * | 277 | struct GNUNET_RECLAIM_AttributeIterator * |
277 | GNUNET_RECLAIM_get_attributes_start ( | 278 | GNUNET_RECLAIM_get_attributes_start ( |
278 | struct GNUNET_RECLAIM_Handle *h, | 279 | struct GNUNET_RECLAIM_Handle *h, |
279 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity, | 280 | const struct GNUNET_IDENTITY_PrivateKey *identity, |
280 | GNUNET_SCHEDULER_TaskCallback error_cb, void *error_cb_cls, | 281 | GNUNET_SCHEDULER_TaskCallback error_cb, void *error_cb_cls, |
281 | GNUNET_RECLAIM_AttributeResult proc, void *proc_cls, | 282 | GNUNET_RECLAIM_AttributeResult proc, void *proc_cls, |
282 | GNUNET_SCHEDULER_TaskCallback finish_cb, void *finish_cb_cls); | 283 | GNUNET_SCHEDULER_TaskCallback finish_cb, void *finish_cb_cls); |
@@ -332,7 +333,7 @@ GNUNET_RECLAIM_get_attributes_stop ( | |||
332 | struct GNUNET_RECLAIM_CredentialIterator * | 333 | struct GNUNET_RECLAIM_CredentialIterator * |
333 | GNUNET_RECLAIM_get_credentials_start ( | 334 | GNUNET_RECLAIM_get_credentials_start ( |
334 | struct GNUNET_RECLAIM_Handle *h, | 335 | struct GNUNET_RECLAIM_Handle *h, |
335 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity, | 336 | const struct GNUNET_IDENTITY_PrivateKey *identity, |
336 | GNUNET_SCHEDULER_TaskCallback error_cb, | 337 | GNUNET_SCHEDULER_TaskCallback error_cb, |
337 | void *error_cb_cls, | 338 | void *error_cb_cls, |
338 | GNUNET_RECLAIM_CredentialResult proc, | 339 | GNUNET_RECLAIM_CredentialResult proc, |
@@ -380,8 +381,8 @@ GNUNET_RECLAIM_get_credentials_stop ( | |||
380 | struct GNUNET_RECLAIM_Operation * | 381 | struct GNUNET_RECLAIM_Operation * |
381 | GNUNET_RECLAIM_ticket_issue ( | 382 | GNUNET_RECLAIM_ticket_issue ( |
382 | struct GNUNET_RECLAIM_Handle *h, | 383 | struct GNUNET_RECLAIM_Handle *h, |
383 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *iss, | 384 | const struct GNUNET_IDENTITY_PrivateKey *iss, |
384 | const struct GNUNET_CRYPTO_EcdsaPublicKey *rp, | 385 | const struct GNUNET_IDENTITY_PublicKey *rp, |
385 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 386 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
386 | GNUNET_RECLAIM_IssueTicketCallback cb, void *cb_cls); | 387 | GNUNET_RECLAIM_IssueTicketCallback cb, void *cb_cls); |
387 | 388 | ||
@@ -402,7 +403,7 @@ GNUNET_RECLAIM_ticket_issue ( | |||
402 | struct GNUNET_RECLAIM_Operation * | 403 | struct GNUNET_RECLAIM_Operation * |
403 | GNUNET_RECLAIM_ticket_revoke ( | 404 | GNUNET_RECLAIM_ticket_revoke ( |
404 | struct GNUNET_RECLAIM_Handle *h, | 405 | struct GNUNET_RECLAIM_Handle *h, |
405 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity, | 406 | const struct GNUNET_IDENTITY_PrivateKey *identity, |
406 | const struct GNUNET_RECLAIM_Ticket *ticket, | 407 | const struct GNUNET_RECLAIM_Ticket *ticket, |
407 | GNUNET_RECLAIM_ContinuationWithStatus cb, void *cb_cls); | 408 | GNUNET_RECLAIM_ContinuationWithStatus cb, void *cb_cls); |
408 | 409 | ||
@@ -422,7 +423,7 @@ GNUNET_RECLAIM_ticket_revoke ( | |||
422 | struct GNUNET_RECLAIM_Operation * | 423 | struct GNUNET_RECLAIM_Operation * |
423 | GNUNET_RECLAIM_ticket_consume ( | 424 | GNUNET_RECLAIM_ticket_consume ( |
424 | struct GNUNET_RECLAIM_Handle *h, | 425 | struct GNUNET_RECLAIM_Handle *h, |
425 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity, | 426 | const struct GNUNET_IDENTITY_PrivateKey *identity, |
426 | const struct GNUNET_RECLAIM_Ticket *ticket, | 427 | const struct GNUNET_RECLAIM_Ticket *ticket, |
427 | GNUNET_RECLAIM_AttributeTicketResult cb, void *cb_cls); | 428 | GNUNET_RECLAIM_AttributeTicketResult cb, void *cb_cls); |
428 | 429 | ||
@@ -447,7 +448,7 @@ GNUNET_RECLAIM_ticket_consume ( | |||
447 | struct GNUNET_RECLAIM_TicketIterator * | 448 | struct GNUNET_RECLAIM_TicketIterator * |
448 | GNUNET_RECLAIM_ticket_iteration_start ( | 449 | GNUNET_RECLAIM_ticket_iteration_start ( |
449 | struct GNUNET_RECLAIM_Handle *h, | 450 | struct GNUNET_RECLAIM_Handle *h, |
450 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity, | 451 | const struct GNUNET_IDENTITY_PrivateKey *identity, |
451 | GNUNET_SCHEDULER_TaskCallback error_cb, void *error_cb_cls, | 452 | GNUNET_SCHEDULER_TaskCallback error_cb, void *error_cb_cls, |
452 | GNUNET_RECLAIM_TicketCallback proc, void *proc_cls, | 453 | GNUNET_RECLAIM_TicketCallback proc, void *proc_cls, |
453 | GNUNET_SCHEDULER_TaskCallback finish_cb, void *finish_cb_cls); | 454 | 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 105bb1149..d56116914 100644 --- a/src/include/gnunet_revocation_service.h +++ b/src/include/gnunet_revocation_service.h | |||
@@ -21,6 +21,8 @@ | |||
21 | #ifndef GNUNET_REVOCATION_SERVICE_H_ | 21 | #ifndef GNUNET_REVOCATION_SERVICE_H_ |
22 | #define GNUNET_REVOCATION_SERVICE_H_ | 22 | #define GNUNET_REVOCATION_SERVICE_H_ |
23 | 23 | ||
24 | #include "gnunet_identity_service.h" | ||
25 | |||
24 | /** | 26 | /** |
25 | * @author Christian Grothoff | 27 | * @author Christian Grothoff |
26 | * | 28 | * |
@@ -51,6 +53,13 @@ extern "C" | |||
51 | #define GNUNET_REVOCATION_VERSION 0x00000001 | 53 | #define GNUNET_REVOCATION_VERSION 0x00000001 |
52 | 54 | ||
53 | /** | 55 | /** |
56 | * Maximum length of a revocation | ||
57 | */ | ||
58 | #define GNUNET_REVOCATION_MAX_PROOF_SIZE sizeof(struct GNUNET_REVOCATION_PowP) +\ | ||
59 | sizeof(struct GNUNET_IDENTITY_PublicKey) +\ | ||
60 | 1024 //FIXME max sig_len | ||
61 | |||
62 | /** | ||
54 | * The proof-of-work narrowing factor. | 63 | * The proof-of-work narrowing factor. |
55 | * The number of PoWs that are calculates as part of revocation. | 64 | * The number of PoWs that are calculates as part of revocation. |
56 | */ | 65 | */ |
@@ -79,15 +88,7 @@ struct GNUNET_REVOCATION_PowP | |||
79 | */ | 88 | */ |
80 | uint64_t pow[POW_COUNT] GNUNET_PACKED; | 89 | uint64_t pow[POW_COUNT] GNUNET_PACKED; |
81 | 90 | ||
82 | /** | 91 | /** followed by the public key type, the key and a signature **/ |
83 | * The signature | ||
84 | */ | ||
85 | struct GNUNET_CRYPTO_EcdsaSignature signature; | ||
86 | |||
87 | /** | ||
88 | * The revoked public key | ||
89 | */ | ||
90 | struct GNUNET_CRYPTO_EcdsaPublicKey key; | ||
91 | }; | 92 | }; |
92 | 93 | ||
93 | 94 | ||
@@ -102,14 +103,11 @@ struct GNUNET_REVOCATION_SignaturePurposePS | |||
102 | struct GNUNET_CRYPTO_EccSignaturePurpose purpose; | 103 | struct GNUNET_CRYPTO_EccSignaturePurpose purpose; |
103 | 104 | ||
104 | /** | 105 | /** |
105 | * The revoked public key | ||
106 | */ | ||
107 | struct GNUNET_CRYPTO_EcdsaPublicKey key; | ||
108 | |||
109 | /** | ||
110 | * The timestamp of the revocation | 106 | * The timestamp of the revocation |
111 | */ | 107 | */ |
112 | struct GNUNET_TIME_AbsoluteNBO timestamp; | 108 | struct GNUNET_TIME_AbsoluteNBO timestamp; |
109 | |||
110 | /** Followed by the zone public key type and key **/ | ||
113 | }; | 111 | }; |
114 | 112 | ||
115 | GNUNET_NETWORK_STRUCT_END | 113 | GNUNET_NETWORK_STRUCT_END |
@@ -150,7 +148,7 @@ typedef void (*GNUNET_REVOCATION_Callback) (void *cls, | |||
150 | */ | 148 | */ |
151 | struct GNUNET_REVOCATION_Query * | 149 | struct GNUNET_REVOCATION_Query * |
152 | GNUNET_REVOCATION_query (const struct GNUNET_CONFIGURATION_Handle *cfg, | 150 | GNUNET_REVOCATION_query (const struct GNUNET_CONFIGURATION_Handle *cfg, |
153 | const struct GNUNET_CRYPTO_EcdsaPublicKey *key, | 151 | const struct GNUNET_IDENTITY_PublicKey *key, |
154 | GNUNET_REVOCATION_Callback func, void *func_cls); | 152 | GNUNET_REVOCATION_Callback func, void *func_cls); |
155 | 153 | ||
156 | 154 | ||
@@ -217,7 +215,7 @@ GNUNET_REVOCATION_check_pow (const struct GNUNET_REVOCATION_PowP *pow, | |||
217 | * @param pow the pow object to work with in the calculation. | 215 | * @param pow the pow object to work with in the calculation. |
218 | */ | 216 | */ |
219 | void | 217 | void |
220 | GNUNET_REVOCATION_pow_init (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | 218 | GNUNET_REVOCATION_pow_init (const struct GNUNET_IDENTITY_PrivateKey *key, |
221 | struct GNUNET_REVOCATION_PowP *pow); | 219 | struct GNUNET_REVOCATION_PowP *pow); |
222 | 220 | ||
223 | 221 | ||
@@ -256,6 +254,10 @@ GNUNET_REVOCATION_pow_round (struct GNUNET_REVOCATION_PowCalculationHandle *pc); | |||
256 | void | 254 | void |
257 | GNUNET_REVOCATION_pow_stop (struct GNUNET_REVOCATION_PowCalculationHandle *pc); | 255 | GNUNET_REVOCATION_pow_stop (struct GNUNET_REVOCATION_PowCalculationHandle *pc); |
258 | 256 | ||
257 | size_t | ||
258 | GNUNET_REVOCATION_proof_get_size (const struct GNUNET_REVOCATION_PowP *pow); | ||
259 | |||
260 | |||
259 | #if 0 /* keep Emacsens' auto-indent happy */ | 261 | #if 0 /* keep Emacsens' auto-indent happy */ |
260 | { | 262 | { |
261 | #endif | 263 | #endif |
diff --git a/src/include/gnunet_uri_lib.h b/src/include/gnunet_uri_lib.h index d428bdd9a..57c9e9316 100644 --- a/src/include/gnunet_uri_lib.h +++ b/src/include/gnunet_uri_lib.h | |||
@@ -26,12 +26,13 @@ | |||
26 | /** | 26 | /** |
27 | * The struct where the parsed values will be stored: | 27 | * The struct where the parsed values will be stored: |
28 | * | 28 | * |
29 | * scheme ":" [ "//" ] [ username ":" password "@" ] host [ ":" port ] [ "/" ] [ path ] [ "?" query ] | 29 | * scheme ":" [ "//" ] [ username ":" password "@" ] host [ ":" port ] [ "/" ] [ path ] [ "?" query ] [ "#" fragment ] |
30 | * | 30 | * |
31 | * Note: to make sure that no strings are copied, the first slash "/" in the | 31 | * Note: to make sure that no strings are copied, the first slash "/" in the |
32 | * path will be used to null terminate the hostname if no port is supplied. | 32 | * path will be used to null terminate the hostname if no port is supplied. |
33 | */ | 33 | */ |
34 | struct GNUNET_Uri { | 34 | struct GNUNET_Uri |
35 | { | ||
35 | char *scheme; /* scheme, without ":" and "//" */ | 36 | char *scheme; /* scheme, without ":" and "//" */ |
36 | char *username; /* username, default: NULL */ | 37 | char *username; /* username, default: NULL */ |
37 | char *password; /* password, default: NULL */ | 38 | char *password; /* password, default: NULL */ |
@@ -44,7 +45,8 @@ struct GNUNET_Uri { | |||
44 | 45 | ||
45 | 46 | ||
46 | /* A struct to hold the query string parameter values. */ | 47 | /* A struct to hold the query string parameter values. */ |
47 | struct GNUNET_UriParam { | 48 | struct GNUNET_UriParam |
49 | { | ||
48 | char *key; | 50 | char *key; |
49 | char *val; | 51 | char *val; |
50 | }; | 52 | }; |
diff --git a/src/json/Makefile.am b/src/json/Makefile.am index 2ed05c35a..d4ea38adf 100644 --- a/src/json/Makefile.am +++ b/src/json/Makefile.am | |||
@@ -18,18 +18,15 @@ libgnunetjson_la_SOURCES = \ | |||
18 | json.c \ | 18 | json.c \ |
19 | json_mhd.c \ | 19 | json_mhd.c \ |
20 | json_generator.c \ | 20 | json_generator.c \ |
21 | json_helper.c \ | 21 | json_helper.c |
22 | json_gnsrecord.c | ||
23 | libgnunetjson_la_LIBADD = \ | 22 | libgnunetjson_la_LIBADD = \ |
24 | $(top_builddir)/src/util/libgnunetutil.la \ | 23 | $(top_builddir)/src/util/libgnunetutil.la \ |
25 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | ||
26 | -ljansson \ | 24 | -ljansson \ |
27 | $(MHD_LIBS) \ | 25 | $(MHD_LIBS) \ |
28 | $(XLIB) \ | 26 | $(XLIB) \ |
29 | $(Z_LIBS) | 27 | $(Z_LIBS) |
30 | libgnunetjson_la_DEPENDENCIES = \ | 28 | libgnunetjson_la_DEPENDENCIES = \ |
31 | $(top_builddir)/src/util/libgnunetutil.la \ | 29 | $(top_builddir)/src/util/libgnunetutil.la |
32 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la | ||
33 | 30 | ||
34 | 31 | ||
35 | check_PROGRAMS = \ | 32 | check_PROGRAMS = \ |
diff --git a/src/json/json.c b/src/json/json.c index 0631c51bb..503702962 100644 --- a/src/json/json.c +++ b/src/json/json.c | |||
@@ -56,11 +56,17 @@ GNUNET_JSON_parse (const json_t *root, | |||
56 | if (NULL == spec[i].field) | 56 | if (NULL == spec[i].field) |
57 | pos = (json_t *) root; | 57 | pos = (json_t *) root; |
58 | else | 58 | else |
59 | pos = json_object_get (root, spec[i].field); | 59 | pos = json_object_get (root, |
60 | if ((NULL == pos) && (spec[i].is_optional)) | 60 | spec[i].field); |
61 | if ( ( (NULL == pos) || | ||
62 | (json_is_null (pos) ) ) && | ||
63 | (spec[i].is_optional) ) | ||
61 | continue; | 64 | continue; |
62 | if ((NULL == pos) || | 65 | if ( (NULL == pos) || |
63 | (GNUNET_OK != spec[i].parser (spec[i].cls, pos, &spec[i]))) | 66 | (GNUNET_OK != |
67 | spec[i].parser (spec[i].cls, | ||
68 | pos, | ||
69 | &spec[i])) ) | ||
64 | { | 70 | { |
65 | if (NULL != error_json_name) | 71 | if (NULL != error_json_name) |
66 | *error_json_name = spec[i].field; | 72 | *error_json_name = spec[i].field; |
diff --git a/src/json/json_generator.c b/src/json/json_generator.c index 3f82a5f17..5806eb174 100644 --- a/src/json/json_generator.c +++ b/src/json/json_generator.c | |||
@@ -201,113 +201,5 @@ GNUNET_JSON_from_rsa_signature (const struct GNUNET_CRYPTO_RsaSignature *sig) | |||
201 | } | 201 | } |
202 | 202 | ||
203 | 203 | ||
204 | /** | ||
205 | * Convert GNS record to JSON. | ||
206 | * | ||
207 | * @param rname name of record | ||
208 | * @param rd record data | ||
209 | * @return corresponding JSON encoding | ||
210 | */ | ||
211 | json_t * | ||
212 | GNUNET_JSON_from_gnsrecord (const char*rname, | ||
213 | const struct GNUNET_GNSRECORD_Data *rd, | ||
214 | unsigned int rd_count) | ||
215 | { | ||
216 | struct GNUNET_TIME_Absolute abs_exp; | ||
217 | struct GNUNET_TIME_Relative rel_exp; | ||
218 | const char *expiration_time_str; | ||
219 | const char *record_type_str; | ||
220 | char *value_str; | ||
221 | json_t *data; | ||
222 | json_t *record; | ||
223 | json_t *records; | ||
224 | |||
225 | data = json_object (); | ||
226 | if (NULL == data) | ||
227 | { | ||
228 | GNUNET_break (0); | ||
229 | return NULL; | ||
230 | } | ||
231 | if (0 != | ||
232 | json_object_set_new (data, | ||
233 | "record_name", | ||
234 | json_string (rname))) | ||
235 | { | ||
236 | GNUNET_break (0); | ||
237 | json_decref (data); | ||
238 | return NULL; | ||
239 | } | ||
240 | records = json_array (); | ||
241 | if (NULL == records) | ||
242 | { | ||
243 | GNUNET_break (0); | ||
244 | json_decref (data); | ||
245 | return NULL; | ||
246 | } | ||
247 | for (int i = 0; i < rd_count; i++) | ||
248 | { | ||
249 | value_str = GNUNET_GNSRECORD_value_to_string (rd[i].record_type, | ||
250 | rd[i].data, | ||
251 | rd[i].data_size); | ||
252 | if (GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION & rd[i].flags) | ||
253 | { | ||
254 | rel_exp.rel_value_us = rd[i].expiration_time; | ||
255 | expiration_time_str = GNUNET_STRINGS_relative_time_to_string (rel_exp, | ||
256 | GNUNET_NO); | ||
257 | } | ||
258 | else | ||
259 | { | ||
260 | abs_exp.abs_value_us = rd[i].expiration_time; | ||
261 | expiration_time_str = GNUNET_STRINGS_absolute_time_to_string (abs_exp); | ||
262 | } | ||
263 | record_type_str = GNUNET_GNSRECORD_number_to_typename (rd[i].record_type); | ||
264 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
265 | "Packing %s %s %s %d\n", | ||
266 | value_str, record_type_str, expiration_time_str, rd[i].flags); | ||
267 | record = json_pack ("{s:s,s:s,s:s,s:b,s:b,s:b,s:b}", | ||
268 | "value", | ||
269 | value_str, | ||
270 | "record_type", | ||
271 | record_type_str, | ||
272 | "expiration_time", | ||
273 | expiration_time_str, | ||
274 | "private", | ||
275 | rd[i].flags & GNUNET_GNSRECORD_RF_PRIVATE, | ||
276 | "relative_expiration", | ||
277 | rd[i].flags & GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION, | ||
278 | "supplemental", | ||
279 | rd[i].flags & GNUNET_GNSRECORD_RF_SUPPLEMENTAL, | ||
280 | "shadow", | ||
281 | rd[i].flags & GNUNET_GNSRECORD_RF_SHADOW_RECORD); | ||
282 | GNUNET_free (value_str); | ||
283 | if (NULL == record) | ||
284 | { | ||
285 | GNUNET_break (0); | ||
286 | json_decref (records); | ||
287 | json_decref (data); | ||
288 | return NULL; | ||
289 | } | ||
290 | if (0 != | ||
291 | json_array_append_new (records, | ||
292 | record)) | ||
293 | { | ||
294 | GNUNET_break (0); | ||
295 | json_decref (records); | ||
296 | json_decref (data); | ||
297 | return NULL; | ||
298 | } | ||
299 | } | ||
300 | if (0 != | ||
301 | json_object_set_new (data, | ||
302 | "data", | ||
303 | records)) | ||
304 | { | ||
305 | GNUNET_break (0); | ||
306 | json_decref (data); | ||
307 | return NULL; | ||
308 | } | ||
309 | return data; | ||
310 | } | ||
311 | |||
312 | 204 | ||
313 | /* End of json/json_generator.c */ | 205 | /* End of json/json_generator.c */ |
diff --git a/src/messenger/.gitignore b/src/messenger/.gitignore new file mode 100644 index 000000000..9de3fb304 --- /dev/null +++ b/src/messenger/.gitignore | |||
@@ -0,0 +1,4 @@ | |||
1 | gnunet-service-messenger | ||
2 | gnunet-messenger | ||
3 | test_messenger_api | ||
4 | test_messenger_anonymous | ||
diff --git a/src/messenger/Makefile.am b/src/messenger/Makefile.am new file mode 100644 index 000000000..ebe08290e --- /dev/null +++ b/src/messenger/Makefile.am | |||
@@ -0,0 +1,131 @@ | |||
1 | # This Makefile.am is in the public domain | ||
2 | AM_CPPFLAGS = -I$(top_srcdir)/src/include | ||
3 | |||
4 | if USE_COVERAGE | ||
5 | AM_CFLAGS = --coverage -O0 | ||
6 | XLIB = -lgcov | ||
7 | endif | ||
8 | |||
9 | pkgcfgdir= $(pkgdatadir)/config.d/ | ||
10 | |||
11 | libexecdir= $(pkglibdir)/libexec/ | ||
12 | |||
13 | pkgcfg_DATA = \ | ||
14 | messenger.conf | ||
15 | |||
16 | plugindir = $(libdir)/gnunet | ||
17 | |||
18 | AM_CLFAGS = -g | ||
19 | |||
20 | libexec_PROGRAMS = \ | ||
21 | gnunet-service-messenger \ | ||
22 | $(EXP_LIBEXEC) | ||
23 | |||
24 | bin_PROGRAMS = \ | ||
25 | gnunet-messenger | ||
26 | |||
27 | lib_LTLIBRARIES = \ | ||
28 | libgnunetmessenger_common.la \ | ||
29 | libgnunetmessenger.la \ | ||
30 | $(EXP_LIB) | ||
31 | |||
32 | libgnunetmessenger_common_la_SOURCES = \ | ||
33 | messenger_api_ego.h \ | ||
34 | messenger_api_message.c messenger_api_message.h \ | ||
35 | messenger_api_list_tunnels.c messenger_api_list_tunnels.h | ||
36 | libgnunetmessenger_common_la_LIBADD = \ | ||
37 | $(top_builddir)/src/util/libgnunetutil.la \ | ||
38 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
39 | $(XLIB) \ | ||
40 | $(LTLIBINTL) | ||
41 | libgnunetmessenger_common_la_LDFLAGS = \ | ||
42 | $(GN_LIB_LDFLAGS) \ | ||
43 | -version-info 0:0:0 | ||
44 | |||
45 | libgnunetmessenger_la_SOURCES = \ | ||
46 | messenger_api.c \ | ||
47 | messenger_api_contact.c messenger_api_contact.h \ | ||
48 | messenger_api_handle.c messenger_api_handle.h \ | ||
49 | messenger_api_room.c messenger_api_room.h | ||
50 | libgnunetmessenger_la_LIBADD = \ | ||
51 | $(top_builddir)/src/util/libgnunetutil.la \ | ||
52 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
53 | libgnunetmessenger_common.la \ | ||
54 | $(XLIB) \ | ||
55 | $(LTLIBINTL) | ||
56 | libgnunetmessenger_la_LDFLAGS = \ | ||
57 | $(GN_LIB_LDFLAGS) \ | ||
58 | -version-info 0:0:0 | ||
59 | |||
60 | gnunet_messenger_SOURCES = \ | ||
61 | gnunet-messenger.c | ||
62 | gnunet_messenger_LDADD = \ | ||
63 | libgnunetmessenger_common.la \ | ||
64 | libgnunetmessenger.la \ | ||
65 | $(top_builddir)/src/util/libgnunetutil.la | ||
66 | gnunet_messenger_LDFLAGS = \ | ||
67 | $(GN_LIBINTL) | ||
68 | |||
69 | gnunet_service_messenger_SOURCES = \ | ||
70 | gnunet-service-messenger.c gnunet-service-messenger.h \ | ||
71 | gnunet-service-messenger_service.c gnunet-service-messenger_service.h \ | ||
72 | gnunet-service-messenger_list_handles.c gnunet-service-messenger_list_handles.h \ | ||
73 | gnunet-service-messenger_list_messages.c gnunet-service-messenger_list_messages.h \ | ||
74 | gnunet-service-messenger_message_handle.c gnunet-service-messenger_message_handle.h \ | ||
75 | gnunet-service-messenger_message_kind.c gnunet-service-messenger_message_kind.h \ | ||
76 | gnunet-service-messenger_message_recv.c gnunet-service-messenger_message_recv.h \ | ||
77 | gnunet-service-messenger_message_send.c gnunet-service-messenger_message_send.h \ | ||
78 | gnunet-service-messenger_message_store.c gnunet-service-messenger_message_store.h \ | ||
79 | gnunet-service-messenger_basement.c gnunet-service-messenger_basement.h \ | ||
80 | gnunet-service-messenger_contact.c gnunet-service-messenger_contact.h \ | ||
81 | gnunet-service-messenger_handle.c gnunet-service-messenger_handle.h \ | ||
82 | gnunet-service-messenger_room.c gnunet-service-messenger_room.h \ | ||
83 | gnunet-service-messenger_tunnel.c gnunet-service-messenger_tunnel.h \ | ||
84 | gnunet-service-messenger_util.c gnunet-service-messenger_util.h | ||
85 | gnunet_service_messenger_LDADD = \ | ||
86 | $(top_builddir)/src/util/libgnunetutil.la \ | ||
87 | $(top_builddir)/src/cadet/libgnunetcadet.la \ | ||
88 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
89 | libgnunetmessenger_common.la \ | ||
90 | libgnunetmessenger.la \ | ||
91 | $(GN_LIBINTL) | ||
92 | |||
93 | check_PROGRAMS = \ | ||
94 | test_messenger_api \ | ||
95 | test_messenger_anonymous \ | ||
96 | test_messenger_comm0 | ||
97 | |||
98 | if ENABLE_TEST_RUN | ||
99 | AM_TESTS_ENVIRONMENT=export GNUNET_PREFIX=$${GNUNET_PREFIX:-@libdir@};export PATH=$${GNUNET_PREFIX:-@prefix@}/bin:$$PATH;unset XDG_DATA_HOME;unset XDG_CONFIG_HOME; | ||
100 | TESTS = \ | ||
101 | $(check_PROGRAMS) | ||
102 | endif | ||
103 | |||
104 | test_messenger_api_SOURCES = \ | ||
105 | test_messenger.c | ||
106 | test_messenger_api_LDADD = \ | ||
107 | libgnunetmessenger_common.la \ | ||
108 | libgnunetmessenger.la \ | ||
109 | $(top_builddir)/src/testing/libgnunettesting.la \ | ||
110 | $(top_builddir)/src/util/libgnunetutil.la | ||
111 | |||
112 | test_messenger_anonymous_SOURCES = \ | ||
113 | test_messenger_anonymous.c | ||
114 | test_messenger_anonymous_LDADD = \ | ||
115 | libgnunetmessenger_common.la \ | ||
116 | libgnunetmessenger.la \ | ||
117 | $(top_builddir)/src/testing/libgnunettesting.la \ | ||
118 | $(top_builddir)/src/util/libgnunetutil.la | ||
119 | |||
120 | test_messenger_comm0_SOURCES = \ | ||
121 | test_messenger_comm0.c | ||
122 | test_messenger_comm0_LDADD = \ | ||
123 | libgnunetmessenger_common.la \ | ||
124 | libgnunetmessenger.la \ | ||
125 | $(top_builddir)/src/testbed/libgnunettestbed.la \ | ||
126 | $(top_builddir)/src/testbed-logger/libgnunettestbedlogger.la \ | ||
127 | $(top_builddir)/src/testing/libgnunettesting.la \ | ||
128 | $(top_builddir)/src/util/libgnunetutil.la | ||
129 | |||
130 | EXTRA_DIST = \ | ||
131 | test_messenger_api.conf | ||
diff --git a/src/messenger/gnunet-messenger.c b/src/messenger/gnunet-messenger.c new file mode 100644 index 000000000..579e5c3ad --- /dev/null +++ b/src/messenger/gnunet-messenger.c | |||
@@ -0,0 +1,306 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-messenger.c | ||
23 | * @brief Print information about messenger groups. | ||
24 | */ | ||
25 | |||
26 | #include <stdio.h> | ||
27 | |||
28 | #include "platform.h" | ||
29 | #include "gnunet_util_lib.h" | ||
30 | #include "gnunet_messenger_service.h" | ||
31 | |||
32 | struct GNUNET_MESSENGER_Handle *messenger; | ||
33 | |||
34 | /** | ||
35 | * Function called whenever a message is received or sent. | ||
36 | * | ||
37 | * @param cls Closure | ||
38 | * @param room Room | ||
39 | * @param message Message | ||
40 | * @param hash Hash of message | ||
41 | */ | ||
42 | void | ||
43 | on_message (void *cls, const struct GNUNET_MESSENGER_Room *room, const struct GNUNET_MESSENGER_Message *message, | ||
44 | const struct GNUNET_HashCode *hash) | ||
45 | { | ||
46 | struct GNUNET_MESSENGER_Contact *sender = GNUNET_MESSENGER_get_member (room, &(message->header.sender_id)); | ||
47 | |||
48 | const char *sender_name = GNUNET_MESSENGER_contact_get_name (sender); | ||
49 | |||
50 | if (!sender_name) | ||
51 | sender_name = "anonymous"; | ||
52 | |||
53 | switch (message->header.kind) | ||
54 | { | ||
55 | case GNUNET_MESSENGER_KIND_JOIN: | ||
56 | { | ||
57 | printf ("* '%s' joined the room! [ %u %u %u %u ]\n", sender_name, message->body.join.key.ecdsa_key.q_y[0], | ||
58 | message->body.join.key.ecdsa_key.q_y[1], message->body.join.key.ecdsa_key.q_y[2], | ||
59 | message->body.join.key.ecdsa_key.q_y[3]); | ||
60 | break; | ||
61 | } | ||
62 | case GNUNET_MESSENGER_KIND_LEAVE: | ||
63 | { | ||
64 | printf ("* '%s' leaves the room!\n", sender_name); | ||
65 | break; | ||
66 | } | ||
67 | case GNUNET_MESSENGER_KIND_PEER: | ||
68 | { | ||
69 | printf ("* '%s' opened the room on: %s\n", sender_name, GNUNET_i2s_full (&(message->body.peer.peer))); | ||
70 | break; | ||
71 | } | ||
72 | case GNUNET_MESSENGER_KIND_TEXT: | ||
73 | { | ||
74 | printf ("* '%s' says: \"%s\"\n", sender_name, message->body.text.text); | ||
75 | break; | ||
76 | } | ||
77 | default: | ||
78 | { | ||
79 | break; | ||
80 | } | ||
81 | } | ||
82 | } | ||
83 | |||
84 | struct GNUNET_SCHEDULER_Task *read_task; | ||
85 | |||
86 | /** | ||
87 | * Task to shut down this application. | ||
88 | * | ||
89 | * @param cls Closure | ||
90 | */ | ||
91 | static void | ||
92 | shutdown_hook (void *cls) | ||
93 | { | ||
94 | struct GNUNET_MESSENGER_Room *room = cls; | ||
95 | |||
96 | if (read_task) | ||
97 | GNUNET_SCHEDULER_cancel (read_task); | ||
98 | |||
99 | if (room) | ||
100 | GNUNET_MESSENGER_close_room (room); | ||
101 | |||
102 | if (messenger) | ||
103 | GNUNET_MESSENGER_disconnect (messenger); | ||
104 | } | ||
105 | |||
106 | static void | ||
107 | listen_stdio (void *cls); | ||
108 | |||
109 | #define MAX_BUFFER_SIZE 60000 | ||
110 | |||
111 | /** | ||
112 | * Task run in stdio mode, after some data is available at stdin. | ||
113 | * | ||
114 | * @param cls Closure | ||
115 | */ | ||
116 | static void | ||
117 | read_stdio (void *cls) | ||
118 | { | ||
119 | read_task = NULL; | ||
120 | |||
121 | char buffer[MAX_BUFFER_SIZE]; | ||
122 | ssize_t length; | ||
123 | |||
124 | length = read (0, buffer, MAX_BUFFER_SIZE); | ||
125 | |||
126 | if ((length <= 0) || (length >= MAX_BUFFER_SIZE)) | ||
127 | { | ||
128 | GNUNET_SCHEDULER_shutdown (); | ||
129 | return; | ||
130 | } | ||
131 | |||
132 | if (buffer[length - 1] == '\n') | ||
133 | buffer[length - 1] = '\0'; | ||
134 | else | ||
135 | buffer[length] = '\0'; | ||
136 | |||
137 | struct GNUNET_MESSENGER_Room *room = cls; | ||
138 | |||
139 | struct GNUNET_MESSENGER_Message message; | ||
140 | message.header.kind = GNUNET_MESSENGER_KIND_TEXT; | ||
141 | message.body.text.text = buffer; | ||
142 | |||
143 | GNUNET_MESSENGER_send_message (room, &message); | ||
144 | |||
145 | read_task = GNUNET_SCHEDULER_add_now (listen_stdio, cls); | ||
146 | } | ||
147 | |||
148 | /** | ||
149 | * Wait for input on STDIO and send it out over the #ch. | ||
150 | * | ||
151 | * @param cls Closure | ||
152 | */ | ||
153 | static void | ||
154 | listen_stdio (void *cls) | ||
155 | { | ||
156 | read_task = NULL; | ||
157 | |||
158 | struct GNUNET_NETWORK_FDSet *rs = GNUNET_NETWORK_fdset_create (); | ||
159 | |||
160 | GNUNET_NETWORK_fdset_set_native (rs, 0); | ||
161 | |||
162 | read_task = GNUNET_SCHEDULER_add_select (GNUNET_SCHEDULER_PRIORITY_DEFAULT, | ||
163 | GNUNET_TIME_UNIT_FOREVER_REL, | ||
164 | rs, | ||
165 | NULL, | ||
166 | &read_stdio, cls); | ||
167 | |||
168 | GNUNET_NETWORK_fdset_destroy (rs); | ||
169 | } | ||
170 | |||
171 | /** | ||
172 | * Initial task to startup application. | ||
173 | * | ||
174 | * @param cls Closure | ||
175 | */ | ||
176 | static void | ||
177 | idle (void *cls) | ||
178 | { | ||
179 | struct GNUNET_MESSENGER_Room *room = cls; | ||
180 | |||
181 | printf ("* You joined the room.\n"); | ||
182 | |||
183 | read_task = GNUNET_SCHEDULER_add_now (listen_stdio, room); | ||
184 | } | ||
185 | |||
186 | char *door_id; | ||
187 | char *ego_name; | ||
188 | char *room_key; | ||
189 | |||
190 | struct GNUNET_SCHEDULER_Task *shutdown_task; | ||
191 | |||
192 | /** | ||
193 | * Function called when an identity is retrieved. | ||
194 | * | ||
195 | * @param cls Closure | ||
196 | * @param handle Handle of messenger service | ||
197 | */ | ||
198 | static void | ||
199 | on_identity (void *cls, struct GNUNET_MESSENGER_Handle *handle) | ||
200 | { | ||
201 | struct GNUNET_HashCode key; | ||
202 | memset (&key, 0, sizeof(key)); | ||
203 | |||
204 | if (room_key) | ||
205 | GNUNET_CRYPTO_hash (room_key, strlen (room_key), &key); | ||
206 | |||
207 | struct GNUNET_PeerIdentity *door = NULL; | ||
208 | |||
209 | if (door_id) | ||
210 | { | ||
211 | door = GNUNET_new(struct GNUNET_PeerIdentity); | ||
212 | |||
213 | if (GNUNET_OK != GNUNET_CRYPTO_eddsa_public_key_from_string (door_id, strlen (door_id), &(door->public_key))) | ||
214 | { | ||
215 | GNUNET_free(door); | ||
216 | door = NULL; | ||
217 | } | ||
218 | } | ||
219 | |||
220 | const char *name = GNUNET_MESSENGER_get_name (handle); | ||
221 | |||
222 | if (!name) | ||
223 | name = "anonymous"; | ||
224 | |||
225 | printf ("* Welcome to the messenger, '%s'!\n", name); | ||
226 | |||
227 | struct GNUNET_MESSENGER_Room *room; | ||
228 | |||
229 | if (door) | ||
230 | { | ||
231 | printf ("* You try to entry a room...\n"); | ||
232 | |||
233 | room = GNUNET_MESSENGER_entry_room (messenger, door, &key); | ||
234 | } | ||
235 | else | ||
236 | { | ||
237 | printf ("* You try to open a room...\n"); | ||
238 | |||
239 | room = GNUNET_MESSENGER_open_room (messenger, &key); | ||
240 | } | ||
241 | |||
242 | GNUNET_SCHEDULER_cancel (shutdown_task); | ||
243 | |||
244 | shutdown_task = GNUNET_SCHEDULER_add_shutdown (shutdown_hook, room); | ||
245 | |||
246 | if (!room) | ||
247 | GNUNET_SCHEDULER_shutdown (); | ||
248 | else | ||
249 | GNUNET_SCHEDULER_add_delayed_with_priority (GNUNET_TIME_relative_get_zero_ (), GNUNET_SCHEDULER_PRIORITY_IDLE, idle, | ||
250 | room); | ||
251 | } | ||
252 | |||
253 | /** | ||
254 | * Main function that will be run by the scheduler. | ||
255 | * | ||
256 | * @param cls closure | ||
257 | * @param args remaining command-line arguments | ||
258 | * @param cfgfile name of the configuration file used (for saving, can be NULL!) | ||
259 | * @param cfg configuration | ||
260 | */ | ||
261 | static void | ||
262 | run (void *cls, char *const*args, const char *cfgfile, const struct GNUNET_CONFIGURATION_Handle *cfg) | ||
263 | { | ||
264 | messenger = GNUNET_MESSENGER_connect (cfg, ego_name, &on_identity, NULL, &on_message, NULL); | ||
265 | |||
266 | shutdown_task = GNUNET_SCHEDULER_add_shutdown (shutdown_hook, NULL); | ||
267 | } | ||
268 | |||
269 | /** | ||
270 | * The main function to obtain messenger information. | ||
271 | * | ||
272 | * @param argc number of arguments from the command line | ||
273 | * @param argv command line arguments | ||
274 | * @return 0 ok, 1 on error | ||
275 | */ | ||
276 | int | ||
277 | main (int argc, char **argv) | ||
278 | { | ||
279 | const char *description = "Open and connect to rooms using the MESSENGER to chat."; | ||
280 | |||
281 | struct GNUNET_GETOPT_CommandLineOption options[] = { | ||
282 | GNUNET_GETOPT_option_string ('d', | ||
283 | "door", | ||
284 | "PEERIDENTITY", | ||
285 | "peer identity to entry into the room", | ||
286 | &door_id), | ||
287 | GNUNET_GETOPT_option_string ('e', | ||
288 | "ego", | ||
289 | "IDENTITY", | ||
290 | "identity to use for messaging", | ||
291 | &ego_name), | ||
292 | GNUNET_GETOPT_option_string ('r', | ||
293 | "room", | ||
294 | "ROOMKEY", | ||
295 | "key of the room to connect to", | ||
296 | &room_key), | ||
297 | GNUNET_GETOPT_OPTION_END }; | ||
298 | |||
299 | return (GNUNET_OK == GNUNET_PROGRAM_run (argc, | ||
300 | argv, | ||
301 | "gnunet-messenger\0", | ||
302 | gettext_noop(description), | ||
303 | options, | ||
304 | &run, | ||
305 | NULL) ? EXIT_SUCCESS : EXIT_FAILURE); | ||
306 | } | ||
diff --git a/src/messenger/gnunet-service-messenger.c b/src/messenger/gnunet-service-messenger.c new file mode 100644 index 000000000..2c92305c4 --- /dev/null +++ b/src/messenger/gnunet-service-messenger.c | |||
@@ -0,0 +1,306 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger.c | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "gnunet-service-messenger.h" | ||
27 | |||
28 | #include "gnunet-service-messenger_service.h" | ||
29 | #include "messenger_api_message.h" | ||
30 | |||
31 | struct GNUNET_MESSENGER_Client | ||
32 | { | ||
33 | struct GNUNET_SERVICE_Client *client; | ||
34 | struct GNUNET_MESSENGER_SrvHandle *handle; | ||
35 | }; | ||
36 | |||
37 | struct GNUNET_MESSENGER_Service *messenger; | ||
38 | |||
39 | static int | ||
40 | check_create (void *cls, const struct GNUNET_MESSENGER_CreateMessage *msg) | ||
41 | { | ||
42 | GNUNET_MQ_check_zero_termination(msg); | ||
43 | return GNUNET_OK; | ||
44 | } | ||
45 | |||
46 | static void | ||
47 | handle_create (void *cls, const struct GNUNET_MESSENGER_CreateMessage *msg) | ||
48 | { | ||
49 | struct GNUNET_MESSENGER_Client *msg_client = cls; | ||
50 | |||
51 | const char *name = ((const char*) msg) + sizeof(*msg); | ||
52 | |||
53 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Handle created with name: %s\n", name); | ||
54 | |||
55 | setup_handle_name (msg_client->handle, strlen (name) > 0? name : NULL); | ||
56 | |||
57 | GNUNET_SERVICE_client_continue (msg_client->client); | ||
58 | } | ||
59 | |||
60 | static void | ||
61 | handle_update (void *cls, const struct GNUNET_MESSENGER_UpdateMessage *msg) | ||
62 | { | ||
63 | struct GNUNET_MESSENGER_Client *msg_client = cls; | ||
64 | |||
65 | if (GNUNET_OK != update_handle (msg_client->handle)) | ||
66 | GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "Name is required to update key!\n"); | ||
67 | |||
68 | GNUNET_SERVICE_client_continue (msg_client->client); | ||
69 | } | ||
70 | |||
71 | static void | ||
72 | handle_destroy (void *cls, const struct GNUNET_MESSENGER_DestroyMessage *msg) | ||
73 | { | ||
74 | struct GNUNET_MESSENGER_Client *msg_client = cls; | ||
75 | |||
76 | GNUNET_SERVICE_client_drop (msg_client->client); | ||
77 | } | ||
78 | |||
79 | static int | ||
80 | check_set_name (void *cls, const struct GNUNET_MESSENGER_NameMessage *msg) | ||
81 | { | ||
82 | GNUNET_MQ_check_zero_termination(msg); | ||
83 | return GNUNET_OK; | ||
84 | } | ||
85 | |||
86 | static void | ||
87 | handle_set_name (void *cls, const struct GNUNET_MESSENGER_NameMessage *msg) | ||
88 | { | ||
89 | struct GNUNET_MESSENGER_Client *msg_client = cls; | ||
90 | |||
91 | const char *name = ((const char*) msg) + sizeof(*msg); | ||
92 | |||
93 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Handles name is now: %s\n", name); | ||
94 | |||
95 | if (GNUNET_YES != set_handle_name (msg_client->handle, name)) | ||
96 | GNUNET_log(GNUNET_ERROR_TYPE_ERROR, "No valid name: %s\n", name); | ||
97 | |||
98 | GNUNET_SERVICE_client_continue (msg_client->client); | ||
99 | } | ||
100 | |||
101 | static void | ||
102 | handle_room_open (void *cls, const struct GNUNET_MESSENGER_RoomMessage *msg) | ||
103 | { | ||
104 | struct GNUNET_MESSENGER_Client *msg_client = cls; | ||
105 | |||
106 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Opening room: %s\n", | ||
107 | GNUNET_h2s (&(msg->key))); | ||
108 | |||
109 | if (GNUNET_YES == open_handle_room (msg_client->handle, &(msg->key))) | ||
110 | { | ||
111 | const struct GNUNET_ShortHashCode* member_id = get_handle_member_id(msg_client->handle, &(msg->key)); | ||
112 | |||
113 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Opening room with member id: %s\n", | ||
114 | GNUNET_sh2s (member_id)); | ||
115 | |||
116 | struct GNUNET_MESSENGER_RoomMessage *response; | ||
117 | struct GNUNET_MQ_Envelope *env; | ||
118 | |||
119 | env = GNUNET_MQ_msg(response, GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_OPEN); | ||
120 | GNUNET_memcpy(&(response->key), &(msg->key), sizeof(msg->key)); | ||
121 | GNUNET_MQ_send (msg_client->handle->mq, env); | ||
122 | } | ||
123 | else | ||
124 | GNUNET_log(GNUNET_ERROR_TYPE_ERROR, "Opening room failed: %s\n", | ||
125 | GNUNET_h2s (&(msg->key))); | ||
126 | |||
127 | GNUNET_SERVICE_client_continue (msg_client->client); | ||
128 | } | ||
129 | |||
130 | static void | ||
131 | handle_room_entry (void *cls, const struct GNUNET_MESSENGER_RoomMessage *msg) | ||
132 | { | ||
133 | struct GNUNET_MESSENGER_Client *msg_client = cls; | ||
134 | |||
135 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Entering room: %s, %s\n", | ||
136 | GNUNET_h2s (&(msg->key)), GNUNET_i2s (&(msg->door))); | ||
137 | |||
138 | if (GNUNET_YES == entry_handle_room (msg_client->handle, &(msg->door), &(msg->key))) | ||
139 | { | ||
140 | const struct GNUNET_ShortHashCode* member_id = get_handle_member_id(msg_client->handle, &(msg->key)); | ||
141 | |||
142 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Entering room with member id: %s\n", | ||
143 | GNUNET_sh2s (member_id)); | ||
144 | |||
145 | struct GNUNET_MESSENGER_RoomMessage *response; | ||
146 | struct GNUNET_MQ_Envelope *env; | ||
147 | |||
148 | env = GNUNET_MQ_msg(response, GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_ENTRY); | ||
149 | GNUNET_memcpy(&(response->door), &(msg->door), sizeof(msg->door)); | ||
150 | GNUNET_memcpy(&(response->key), &(msg->key), sizeof(msg->key)); | ||
151 | GNUNET_MQ_send (msg_client->handle->mq, env); | ||
152 | } | ||
153 | else | ||
154 | GNUNET_log(GNUNET_ERROR_TYPE_ERROR, "Entrance into room failed: %s, %s\n", | ||
155 | GNUNET_h2s (&(msg->key)), GNUNET_i2s (&(msg->door))); | ||
156 | |||
157 | GNUNET_SERVICE_client_continue (msg_client->client); | ||
158 | } | ||
159 | |||
160 | static void | ||
161 | handle_room_close (void *cls, const struct GNUNET_MESSENGER_RoomMessage *msg) | ||
162 | { | ||
163 | struct GNUNET_MESSENGER_Client *msg_client = cls; | ||
164 | |||
165 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Closing room: %s\n", GNUNET_h2s (&(msg->key))); | ||
166 | |||
167 | if (GNUNET_YES == close_handle_room (msg_client->handle, &(msg->key))) | ||
168 | { | ||
169 | const struct GNUNET_ShortHashCode* member_id = get_handle_member_id(msg_client->handle, &(msg->key)); | ||
170 | |||
171 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Closing room with member id: %s\n", | ||
172 | GNUNET_sh2s (member_id)); | ||
173 | |||
174 | struct GNUNET_MESSENGER_RoomMessage *response; | ||
175 | struct GNUNET_MQ_Envelope *env; | ||
176 | |||
177 | env = GNUNET_MQ_msg(response, GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_CLOSE); | ||
178 | GNUNET_memcpy(&(response->key), &(msg->key), sizeof(msg->key)); | ||
179 | GNUNET_MQ_send (msg_client->handle->mq, env); | ||
180 | } | ||
181 | else | ||
182 | GNUNET_log(GNUNET_ERROR_TYPE_ERROR, "Closing room failed: %s\n", GNUNET_h2s (&(msg->key))); | ||
183 | |||
184 | GNUNET_SERVICE_client_continue (msg_client->client); | ||
185 | } | ||
186 | |||
187 | static int | ||
188 | check_send_message (void *cls, const struct GNUNET_MESSENGER_SendMessage *msg) | ||
189 | { | ||
190 | const uint16_t full_length = ntohs (msg->header.size) - sizeof(msg->header); | ||
191 | |||
192 | if (full_length < sizeof(msg->key)) | ||
193 | return GNUNET_NO; | ||
194 | |||
195 | const uint16_t length = full_length - sizeof(msg->key); | ||
196 | const char *buffer = ((const char*) msg) + sizeof(*msg); | ||
197 | |||
198 | struct GNUNET_MESSENGER_Message message; | ||
199 | |||
200 | if (GNUNET_YES != decode_message (&message, length, buffer)) | ||
201 | return GNUNET_NO; | ||
202 | |||
203 | return GNUNET_OK; | ||
204 | } | ||
205 | |||
206 | static void | ||
207 | handle_send_message (void *cls, const struct GNUNET_MESSENGER_SendMessage *msg) | ||
208 | { | ||
209 | struct GNUNET_MESSENGER_Client *msg_client = cls; | ||
210 | |||
211 | const struct GNUNET_HashCode *key = &(msg->key); | ||
212 | const char *buffer = ((const char*) msg) + sizeof(*msg); | ||
213 | |||
214 | const uint16_t length = ntohs (msg->header.size) - sizeof(*msg); | ||
215 | |||
216 | struct GNUNET_MESSENGER_Message message; | ||
217 | decode_message (&message, length, buffer); | ||
218 | |||
219 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Sending message: %s to %s\n", | ||
220 | GNUNET_MESSENGER_name_of_kind (message.header.kind), | ||
221 | GNUNET_h2s (key)); | ||
222 | |||
223 | if (GNUNET_YES != send_handle_message (msg_client->handle, key, &message)) | ||
224 | GNUNET_log(GNUNET_ERROR_TYPE_ERROR, "Sending message failed: %s to %s\n", | ||
225 | GNUNET_MESSENGER_name_of_kind (message.header.kind), | ||
226 | GNUNET_h2s (key)); | ||
227 | |||
228 | GNUNET_SERVICE_client_continue (msg_client->client); | ||
229 | } | ||
230 | |||
231 | static void | ||
232 | handle_get_message (void *cls, const struct GNUNET_MESSENGER_RecvMessage *msg) | ||
233 | { | ||
234 | struct GNUNET_MESSENGER_Client *msg_client = cls; | ||
235 | |||
236 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Requesting message from room: %s\n", | ||
237 | GNUNET_h2s (&(msg->key))); | ||
238 | |||
239 | struct GNUNET_MESSENGER_SrvRoom *room = get_service_room (messenger, &(msg->key)); | ||
240 | |||
241 | if (room) | ||
242 | get_room_message (room, msg_client->handle, &(msg->hash), GNUNET_YES); | ||
243 | else | ||
244 | GNUNET_log(GNUNET_ERROR_TYPE_ERROR, "Room not found: %s\n", | ||
245 | GNUNET_h2s (&(msg->key))); | ||
246 | |||
247 | GNUNET_SERVICE_client_continue (msg_client->client); | ||
248 | } | ||
249 | |||
250 | static void* | ||
251 | callback_client_connect (void *cls, struct GNUNET_SERVICE_Client *client, struct GNUNET_MQ_Handle *mq) | ||
252 | { | ||
253 | struct GNUNET_MESSENGER_Client *msg_client = GNUNET_new(struct GNUNET_MESSENGER_Client); | ||
254 | |||
255 | msg_client->client = client; | ||
256 | msg_client->handle = add_service_handle (messenger, mq); | ||
257 | |||
258 | return msg_client; | ||
259 | } | ||
260 | |||
261 | static void | ||
262 | callback_client_disconnect (void *cls, struct GNUNET_SERVICE_Client *client, void *internal_cls) | ||
263 | { | ||
264 | struct GNUNET_MESSENGER_Client *msg_client = internal_cls; | ||
265 | |||
266 | remove_service_handle (messenger, msg_client->handle); | ||
267 | |||
268 | GNUNET_free(msg_client); | ||
269 | } | ||
270 | |||
271 | /** | ||
272 | * Setup MESSENGER internals. | ||
273 | * | ||
274 | * @param cls closure | ||
275 | * @param config configuration to use | ||
276 | * @param service the initialized service | ||
277 | */ | ||
278 | static void | ||
279 | run (void *cls, const struct GNUNET_CONFIGURATION_Handle *config, struct GNUNET_SERVICE_Handle *service) | ||
280 | { | ||
281 | messenger = create_service (config, service); | ||
282 | |||
283 | if ((!messenger) || (!messenger->cadet) || (!messenger->identity)) | ||
284 | GNUNET_SCHEDULER_shutdown (); | ||
285 | } | ||
286 | |||
287 | /** | ||
288 | * Define "main" method using service macro. | ||
289 | */ | ||
290 | GNUNET_SERVICE_MAIN( | ||
291 | GNUNET_MESSENGER_SERVICE_NAME, | ||
292 | GNUNET_SERVICE_OPTION_NONE, | ||
293 | &run, | ||
294 | &callback_client_connect, | ||
295 | &callback_client_disconnect, | ||
296 | NULL, | ||
297 | GNUNET_MQ_hd_var_size( create, GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_CREATE, struct GNUNET_MESSENGER_CreateMessage, NULL ), | ||
298 | GNUNET_MQ_hd_fixed_size( update, GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_UPDATE, struct GNUNET_MESSENGER_UpdateMessage, NULL ), | ||
299 | GNUNET_MQ_hd_fixed_size( destroy, GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_DESTROY, struct GNUNET_MESSENGER_DestroyMessage, NULL ), | ||
300 | GNUNET_MQ_hd_var_size( set_name, GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_SET_NAME, struct GNUNET_MESSENGER_NameMessage, NULL ), | ||
301 | GNUNET_MQ_hd_fixed_size( room_open, GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_OPEN, struct GNUNET_MESSENGER_RoomMessage, NULL ), | ||
302 | GNUNET_MQ_hd_fixed_size( room_entry, GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_ENTRY, struct GNUNET_MESSENGER_RoomMessage, NULL ), | ||
303 | GNUNET_MQ_hd_fixed_size( room_close, GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_CLOSE, struct GNUNET_MESSENGER_RoomMessage, NULL ), | ||
304 | GNUNET_MQ_hd_var_size( send_message, GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_SEND_MESSAGE, struct GNUNET_MESSENGER_SendMessage, NULL ), | ||
305 | GNUNET_MQ_hd_fixed_size( get_message, GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_GET_MESSAGE, struct GNUNET_MESSENGER_RecvMessage, NULL ), | ||
306 | GNUNET_MQ_handler_end()); | ||
diff --git a/src/messenger/gnunet-service-messenger.h b/src/messenger/gnunet-service-messenger.h new file mode 100644 index 000000000..85a1d2549 --- /dev/null +++ b/src/messenger/gnunet-service-messenger.h | |||
@@ -0,0 +1,121 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_SERVICE_MESSENGER_H | ||
27 | #define GNUNET_SERVICE_MESSENGER_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_cadet_service.h" | ||
31 | #include "gnunet_container_lib.h" | ||
32 | #include "gnunet_crypto_lib.h" | ||
33 | #include "gnunet_identity_service.h" | ||
34 | #include "gnunet_mq_lib.h" | ||
35 | #include "gnunet_peer_lib.h" | ||
36 | #include "gnunet_protocols.h" | ||
37 | #include "gnunet_util_lib.h" | ||
38 | |||
39 | /** | ||
40 | * Message to create a handle for a client | ||
41 | */ | ||
42 | struct GNUNET_MESSENGER_CreateMessage | ||
43 | { | ||
44 | struct GNUNET_MessageHeader header; | ||
45 | }; | ||
46 | |||
47 | /** | ||
48 | * Message to update the handle (its EGO key) for a client | ||
49 | */ | ||
50 | struct GNUNET_MESSENGER_UpdateMessage | ||
51 | { | ||
52 | struct GNUNET_MessageHeader header; | ||
53 | }; | ||
54 | |||
55 | /** | ||
56 | * Message to destroy the handle for a client | ||
57 | */ | ||
58 | struct GNUNET_MESSENGER_DestroyMessage | ||
59 | { | ||
60 | struct GNUNET_MessageHeader header; | ||
61 | }; | ||
62 | |||
63 | /** | ||
64 | * Message to receive the current name of a handle | ||
65 | */ | ||
66 | struct GNUNET_MESSENGER_NameMessage | ||
67 | { | ||
68 | struct GNUNET_MessageHeader header; | ||
69 | }; | ||
70 | |||
71 | /** | ||
72 | * Message to receive the current public key of a handle | ||
73 | */ | ||
74 | struct GNUNET_MESSENGER_KeyMessage | ||
75 | { | ||
76 | struct GNUNET_MessageHeader header; | ||
77 | struct GNUNET_IDENTITY_PublicKey pubkey; | ||
78 | }; | ||
79 | |||
80 | /** | ||
81 | * General message to confirm interaction with a room | ||
82 | */ | ||
83 | struct GNUNET_MESSENGER_RoomMessage | ||
84 | { | ||
85 | struct GNUNET_MessageHeader header; | ||
86 | |||
87 | struct GNUNET_PeerIdentity door; | ||
88 | struct GNUNET_HashCode key; | ||
89 | }; | ||
90 | |||
91 | /** | ||
92 | * Message to receive the current member id of a handle in room | ||
93 | */ | ||
94 | struct GNUNET_MESSENGER_MemberMessage | ||
95 | { | ||
96 | struct GNUNET_MessageHeader header; | ||
97 | |||
98 | struct GNUNET_HashCode key; | ||
99 | struct GNUNET_ShortHashCode id; | ||
100 | }; | ||
101 | |||
102 | /** | ||
103 | * Message to send something into a room | ||
104 | */ | ||
105 | struct GNUNET_MESSENGER_SendMessage | ||
106 | { | ||
107 | struct GNUNET_MessageHeader header; | ||
108 | struct GNUNET_HashCode key; | ||
109 | }; | ||
110 | |||
111 | /** | ||
112 | * Message to receive something from a room | ||
113 | */ | ||
114 | struct GNUNET_MESSENGER_RecvMessage | ||
115 | { | ||
116 | struct GNUNET_MessageHeader header; | ||
117 | struct GNUNET_HashCode key; | ||
118 | struct GNUNET_HashCode hash; | ||
119 | }; | ||
120 | |||
121 | #endif //GNUNET_SERVICE_MESSENGER_H | ||
diff --git a/src/messenger/gnunet-service-messenger_basement.c b/src/messenger/gnunet-service-messenger_basement.c new file mode 100644 index 000000000..190cf2de5 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_basement.c | |||
@@ -0,0 +1,58 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_basement.c | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "gnunet-service-messenger_basement.h" | ||
27 | |||
28 | size_t | ||
29 | count_of_tunnels (const struct GNUNET_MESSENGER_ListTunnels *tunnels) | ||
30 | { | ||
31 | const struct GNUNET_MESSENGER_ListTunnel *element; | ||
32 | size_t count = 0; | ||
33 | |||
34 | for (element = tunnels->head; element; element = element->next) | ||
35 | count++; | ||
36 | |||
37 | return count; | ||
38 | } | ||
39 | |||
40 | int | ||
41 | should_connect_tunnel_to (size_t count, size_t src, size_t dst) | ||
42 | { | ||
43 | if ((src + 1) % count == dst % count) | ||
44 | return GNUNET_YES; | ||
45 | |||
46 | return GNUNET_NO; | ||
47 | } | ||
48 | |||
49 | int | ||
50 | required_connection_between (size_t count, size_t src, size_t dst) | ||
51 | { | ||
52 | if (GNUNET_YES == should_connect_tunnel_to (count, src, dst)) | ||
53 | return GNUNET_YES; | ||
54 | if (GNUNET_YES == should_connect_tunnel_to (count, dst, src)) | ||
55 | return GNUNET_YES; | ||
56 | |||
57 | return GNUNET_NO; | ||
58 | } | ||
diff --git a/src/messenger/gnunet-service-messenger_basement.h b/src/messenger/gnunet-service-messenger_basement.h new file mode 100644 index 000000000..0a1a9b126 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_basement.h | |||
@@ -0,0 +1,66 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_basement.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_SERVICE_MESSENGER_BASEMENT_H | ||
27 | #define GNUNET_SERVICE_MESSENGER_BASEMENT_H | ||
28 | |||
29 | #include "messenger_api_list_tunnels.h" | ||
30 | |||
31 | /** | ||
32 | * Returns the count of peers in a list (typically from the basement of a room). | ||
33 | * | ||
34 | * @param tunnels List of peer identities | ||
35 | * @return Count of the entries in the list | ||
36 | */ | ||
37 | size_t | ||
38 | count_of_tunnels (const struct GNUNET_MESSENGER_ListTunnels *tunnels); | ||
39 | |||
40 | /** | ||
41 | * Returns GNUNET_YES or GNUNET_NO to determine if the peer at index <i>src</i> should | ||
42 | * or should not connect outgoing to the peer at index <i>dst</i> to construct a complete | ||
43 | * basement with a given <i>count</i> of peers. | ||
44 | * | ||
45 | * @param count Count of peers | ||
46 | * @param src Source index | ||
47 | * @param dst Destination index | ||
48 | * @return GNUNET_YES or GNUNET_NO based on topologic requirement | ||
49 | */ | ||
50 | int | ||
51 | should_connect_tunnel_to (size_t count, size_t src, size_t dst); | ||
52 | |||
53 | /** | ||
54 | * Returns GNUNET_YES or GNUNET_NO to determine if the peers of index <i>src</i> and | ||
55 | * index <i>dst</i> should be connected in any direction to construct a complete | ||
56 | * basement with a given <i>count</i> of peers. | ||
57 | * | ||
58 | * @param count Count of peers | ||
59 | * @param src Source index | ||
60 | * @param dst Destination index | ||
61 | * @return GNUNET_YES or GNUNET_NO based on topologic requirement | ||
62 | */ | ||
63 | int | ||
64 | required_connection_between (size_t count, size_t src, size_t dst); | ||
65 | |||
66 | #endif //GNUNET_SERVICE_MESSENGER_BASEMENT_H | ||
diff --git a/src/messenger/gnunet-service-messenger_contact.c b/src/messenger/gnunet-service-messenger_contact.c new file mode 100644 index 000000000..1ec125402 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_contact.c | |||
@@ -0,0 +1,96 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_contact.c | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "gnunet-service-messenger_contact.h" | ||
27 | |||
28 | struct GNUNET_MESSENGER_SrvContact* | ||
29 | create_contact (const struct GNUNET_IDENTITY_PublicKey *key) | ||
30 | { | ||
31 | struct GNUNET_MESSENGER_SrvContact *contact = GNUNET_new(struct GNUNET_MESSENGER_SrvContact); | ||
32 | |||
33 | contact->name = NULL; | ||
34 | contact->rc = 0; | ||
35 | |||
36 | GNUNET_memcpy(&(contact->public_key), key, sizeof(contact->public_key)); | ||
37 | |||
38 | return contact; | ||
39 | } | ||
40 | |||
41 | void | ||
42 | destroy_contact (struct GNUNET_MESSENGER_SrvContact *contact) | ||
43 | { | ||
44 | if (contact->name) | ||
45 | GNUNET_free(contact->name); | ||
46 | |||
47 | GNUNET_free(contact); | ||
48 | } | ||
49 | |||
50 | const char* | ||
51 | get_contact_name (const struct GNUNET_MESSENGER_SrvContact *contact) | ||
52 | { | ||
53 | return contact->name; | ||
54 | } | ||
55 | |||
56 | void | ||
57 | set_contact_name (struct GNUNET_MESSENGER_SrvContact *contact, const char *name) | ||
58 | { | ||
59 | GNUNET_assert(name); | ||
60 | |||
61 | if (contact->name) | ||
62 | GNUNET_free(contact->name); | ||
63 | |||
64 | contact->name = GNUNET_strdup(name); | ||
65 | } | ||
66 | |||
67 | const struct GNUNET_IDENTITY_PublicKey* | ||
68 | get_contact_key (const struct GNUNET_MESSENGER_SrvContact *contact) | ||
69 | { | ||
70 | return &(contact->public_key); | ||
71 | } | ||
72 | |||
73 | void | ||
74 | increase_contact_rc (struct GNUNET_MESSENGER_SrvContact *contact) | ||
75 | { | ||
76 | contact->rc++; | ||
77 | } | ||
78 | |||
79 | int | ||
80 | decrease_contact_rc (struct GNUNET_MESSENGER_SrvContact *contact) | ||
81 | { | ||
82 | if (contact->rc > 0) | ||
83 | contact->rc--; | ||
84 | |||
85 | return contact->rc ? GNUNET_NO : GNUNET_YES; | ||
86 | } | ||
87 | |||
88 | const struct GNUNET_HashCode* | ||
89 | get_contact_id_from_key (const struct GNUNET_MESSENGER_SrvContact *contact) | ||
90 | { | ||
91 | static struct GNUNET_HashCode id; | ||
92 | |||
93 | GNUNET_CRYPTO_hash (&(contact->public_key), sizeof(contact->public_key), &id); | ||
94 | |||
95 | return &id; | ||
96 | } | ||
diff --git a/src/messenger/gnunet-service-messenger_contact.h b/src/messenger/gnunet-service-messenger_contact.h new file mode 100644 index 000000000..4a4f8bf0f --- /dev/null +++ b/src/messenger/gnunet-service-messenger_contact.h | |||
@@ -0,0 +1,112 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_contact.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_SERVICE_MESSENGER_CONTACT_H | ||
27 | #define GNUNET_SERVICE_MESSENGER_CONTACT_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_crypto_lib.h" | ||
31 | #include "gnunet_identity_service.h" | ||
32 | |||
33 | struct GNUNET_MESSENGER_SrvContact | ||
34 | { | ||
35 | char *name; | ||
36 | size_t rc; | ||
37 | |||
38 | struct GNUNET_IDENTITY_PublicKey public_key; | ||
39 | }; | ||
40 | |||
41 | /** | ||
42 | * Creates and allocates a new contact with a given public <i>key</i> from an EGO. | ||
43 | * | ||
44 | * @param key Public key | ||
45 | * @return New contact | ||
46 | */ | ||
47 | struct GNUNET_MESSENGER_SrvContact* | ||
48 | create_contact (const struct GNUNET_IDENTITY_PublicKey *key); | ||
49 | |||
50 | /** | ||
51 | * Destroys a contact and frees its memory fully. | ||
52 | * | ||
53 | * @param contact Contact | ||
54 | */ | ||
55 | void | ||
56 | destroy_contact (struct GNUNET_MESSENGER_SrvContact *contact); | ||
57 | |||
58 | /** | ||
59 | * Returns the current name of a given <i>contact</i> or NULL if no valid name was assigned yet. | ||
60 | * | ||
61 | * @param contact Contact | ||
62 | * @return Name of the contact or NULL | ||
63 | */ | ||
64 | const char* | ||
65 | get_contact_name (const struct GNUNET_MESSENGER_SrvContact *contact); | ||
66 | |||
67 | /** | ||
68 | * Changes the current name of a given <i>contact</i> by copying it from the parameter <i>name</i>. | ||
69 | * | ||
70 | * @param contact Contact | ||
71 | * @param name Valid name (may not be NULL!) | ||
72 | */ | ||
73 | void | ||
74 | set_contact_name (struct GNUNET_MESSENGER_SrvContact *contact, const char *name); | ||
75 | |||
76 | /** | ||
77 | * Returns the public key of a given <i>contact</i>. | ||
78 | * | ||
79 | * @param contact Contact | ||
80 | * @return Public key of the contact | ||
81 | */ | ||
82 | const struct GNUNET_IDENTITY_PublicKey* | ||
83 | get_contact_key (const struct GNUNET_MESSENGER_SrvContact *contact); | ||
84 | |||
85 | /** | ||
86 | * Increases the reference counter of a given <i>contact</i> which is zero as default. | ||
87 | * | ||
88 | * @param contact Contact | ||
89 | */ | ||
90 | void | ||
91 | increase_contact_rc (struct GNUNET_MESSENGER_SrvContact *contact); | ||
92 | |||
93 | /** | ||
94 | * Decreases the reference counter if possible (can not underflow!) of a given <i>contact</i> | ||
95 | * and returns GNUNET_YES if the counter is equal to zero, otherwise GNUNET_NO. | ||
96 | * | ||
97 | * @param contact Contact | ||
98 | * @return GNUNET_YES or GNUNET_NO depending on the reference counter | ||
99 | */ | ||
100 | int | ||
101 | decrease_contact_rc (struct GNUNET_MESSENGER_SrvContact *contact); | ||
102 | |||
103 | /** | ||
104 | * Returns the resulting hashcode of the public key from a given <i>contact</i>. | ||
105 | * | ||
106 | * @param contact Contact | ||
107 | * @return Hash of the contacts public key | ||
108 | */ | ||
109 | const struct GNUNET_HashCode* | ||
110 | get_contact_id_from_key (const struct GNUNET_MESSENGER_SrvContact *contact); | ||
111 | |||
112 | #endif //GNUNET_SERVICE_MESSENGER_CONTACT_H | ||
diff --git a/src/messenger/gnunet-service-messenger_handle.c b/src/messenger/gnunet-service-messenger_handle.c new file mode 100644 index 000000000..38ad6fbb4 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_handle.c | |||
@@ -0,0 +1,503 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_handle.c | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "gnunet-service-messenger_handle.h" | ||
27 | |||
28 | #include "gnunet-service-messenger.h" | ||
29 | #include "gnunet-service-messenger_message_kind.h" | ||
30 | |||
31 | struct GNUNET_MESSENGER_SrvHandle* | ||
32 | create_handle (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MQ_Handle *mq) | ||
33 | { | ||
34 | struct GNUNET_MESSENGER_SrvHandle *handle = GNUNET_new(struct GNUNET_MESSENGER_SrvHandle); | ||
35 | |||
36 | handle->service = service; | ||
37 | handle->mq = mq; | ||
38 | |||
39 | handle->name = NULL; | ||
40 | |||
41 | handle->operation = NULL; | ||
42 | |||
43 | handle->ego = NULL; | ||
44 | |||
45 | handle->member_ids = GNUNET_CONTAINER_multihashmap_create (8, GNUNET_NO); | ||
46 | |||
47 | return handle; | ||
48 | } | ||
49 | |||
50 | int | ||
51 | iterate_free_member_ids (void *cls, const struct GNUNET_HashCode *key, void *value) | ||
52 | { | ||
53 | GNUNET_free(value); | ||
54 | |||
55 | return GNUNET_YES; | ||
56 | } | ||
57 | |||
58 | void | ||
59 | destroy_handle (struct GNUNET_MESSENGER_SrvHandle *handle) | ||
60 | { | ||
61 | if (handle->service->dir) | ||
62 | save_handle_configuration(handle); | ||
63 | |||
64 | if (handle->operation) | ||
65 | GNUNET_IDENTITY_cancel (handle->operation); | ||
66 | |||
67 | if (handle->name) | ||
68 | GNUNET_free(handle->name); | ||
69 | |||
70 | GNUNET_CONTAINER_multihashmap_iterate (handle->member_ids, iterate_free_member_ids, NULL); | ||
71 | GNUNET_CONTAINER_multihashmap_destroy (handle->member_ids); | ||
72 | |||
73 | GNUNET_free(handle); | ||
74 | } | ||
75 | |||
76 | void | ||
77 | get_handle_data_subdir (struct GNUNET_MESSENGER_SrvHandle *handle, const char *name, char **dir) | ||
78 | { | ||
79 | if (name) | ||
80 | GNUNET_asprintf (dir, "%s%s%c%s%c", handle->service->dir, "identities", | ||
81 | DIR_SEPARATOR, name, DIR_SEPARATOR); | ||
82 | else | ||
83 | GNUNET_asprintf (dir, "%s%s%c", handle->service->dir, "anonymous", | ||
84 | DIR_SEPARATOR); | ||
85 | } | ||
86 | |||
87 | static int | ||
88 | create_handle_member_id (const struct GNUNET_MESSENGER_SrvHandle *handle, const struct GNUNET_HashCode *key) | ||
89 | { | ||
90 | struct GNUNET_ShortHashCode *random_id = generate_service_new_member_id (handle->service, key); | ||
91 | |||
92 | if (!random_id) | ||
93 | return GNUNET_NO; | ||
94 | |||
95 | if (GNUNET_OK != GNUNET_CONTAINER_multihashmap_put (handle->member_ids, key, random_id, | ||
96 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST)) | ||
97 | { | ||
98 | GNUNET_free(random_id); | ||
99 | return GNUNET_NO; | ||
100 | } | ||
101 | |||
102 | GNUNET_log(GNUNET_ERROR_TYPE_INFO, "Created a new member id (%s) for room: %s\n", | ||
103 | GNUNET_sh2s(random_id), GNUNET_h2s(key)); | ||
104 | |||
105 | return GNUNET_YES; | ||
106 | } | ||
107 | |||
108 | const struct GNUNET_ShortHashCode* | ||
109 | get_handle_member_id (const struct GNUNET_MESSENGER_SrvHandle *handle, const struct GNUNET_HashCode *key) | ||
110 | { | ||
111 | return GNUNET_CONTAINER_multihashmap_get (handle->member_ids, key); | ||
112 | } | ||
113 | |||
114 | void | ||
115 | change_handle_member_id (struct GNUNET_MESSENGER_SrvHandle *handle, const struct GNUNET_HashCode *key, | ||
116 | const struct GNUNET_ShortHashCode *unique_id) | ||
117 | { | ||
118 | struct GNUNET_ShortHashCode *member_id = GNUNET_CONTAINER_multihashmap_get (handle->member_ids, key); | ||
119 | |||
120 | if (member_id) | ||
121 | { | ||
122 | GNUNET_log(GNUNET_ERROR_TYPE_INFO, "Changed a member id (%s) for room (%s) ", | ||
123 | GNUNET_sh2s(member_id), GNUNET_h2s(key)); | ||
124 | GNUNET_log(GNUNET_ERROR_TYPE_INFO, "into (%s).\n", | ||
125 | GNUNET_sh2s(unique_id)); | ||
126 | |||
127 | GNUNET_memcpy(member_id, unique_id, sizeof(*unique_id)); | ||
128 | |||
129 | struct GNUNET_MESSENGER_MemberMessage *msg; | ||
130 | struct GNUNET_MQ_Envelope *env; | ||
131 | |||
132 | env = GNUNET_MQ_msg(msg, GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_MEMBER_ID); | ||
133 | |||
134 | GNUNET_memcpy(&(msg->key), key, sizeof(*key)); | ||
135 | GNUNET_memcpy(&(msg->id), member_id, sizeof(*member_id)); | ||
136 | |||
137 | GNUNET_MQ_send (handle->mq, env); | ||
138 | } | ||
139 | else | ||
140 | { | ||
141 | member_id = GNUNET_new(struct GNUNET_ShortHashCode); | ||
142 | GNUNET_memcpy(member_id, unique_id, sizeof(*member_id)); | ||
143 | |||
144 | if (GNUNET_OK != GNUNET_CONTAINER_multihashmap_put (handle->member_ids, key, member_id, | ||
145 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST)) | ||
146 | GNUNET_free(member_id); | ||
147 | } | ||
148 | } | ||
149 | |||
150 | static void | ||
151 | change_handle_name (struct GNUNET_MESSENGER_SrvHandle *handle, const char *name) | ||
152 | { | ||
153 | if (handle->name) | ||
154 | GNUNET_free(handle->name); | ||
155 | |||
156 | handle->name = name ? GNUNET_strdup(name) : NULL; | ||
157 | |||
158 | const uint16_t name_len = handle->name ? strlen (handle->name) : 0; | ||
159 | |||
160 | struct GNUNET_MESSENGER_NameMessage *msg; | ||
161 | struct GNUNET_MQ_Envelope *env; | ||
162 | |||
163 | env = GNUNET_MQ_msg_extra(msg, name_len + 1, GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_GET_NAME); | ||
164 | |||
165 | char *extra = ((char*) msg) + sizeof(*msg); | ||
166 | |||
167 | if (name_len) | ||
168 | GNUNET_memcpy(extra, handle->name, name_len); | ||
169 | |||
170 | extra[name_len] = '\0'; | ||
171 | |||
172 | GNUNET_MQ_send (handle->mq, env); | ||
173 | } | ||
174 | |||
175 | static void | ||
176 | change_handle_ego (struct GNUNET_MESSENGER_SrvHandle *handle, struct GNUNET_MESSENGER_Ego *ego) | ||
177 | { | ||
178 | handle->ego = ego; | ||
179 | |||
180 | ego = get_handle_ego(handle); | ||
181 | |||
182 | struct GNUNET_MESSENGER_KeyMessage *msg; | ||
183 | struct GNUNET_MQ_Envelope *env; | ||
184 | |||
185 | env = GNUNET_MQ_msg(msg, GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_GET_KEY); | ||
186 | |||
187 | GNUNET_memcpy(&(msg->pubkey), &(ego->pub), sizeof(ego->pub)); | ||
188 | |||
189 | GNUNET_MQ_send (handle->mq, env); | ||
190 | } | ||
191 | |||
192 | struct GNUNET_MESSENGER_Ego* | ||
193 | get_handle_ego (struct GNUNET_MESSENGER_SrvHandle *handle) | ||
194 | { | ||
195 | static struct GNUNET_MESSENGER_Ego anonymous; | ||
196 | static int read_keys = 0; | ||
197 | |||
198 | if (handle->ego) | ||
199 | return handle->ego; | ||
200 | |||
201 | if (!read_keys) | ||
202 | { | ||
203 | struct GNUNET_IDENTITY_Ego* ego = GNUNET_IDENTITY_ego_get_anonymous (); | ||
204 | GNUNET_memcpy(&(anonymous.priv), GNUNET_IDENTITY_ego_get_private_key(ego), sizeof(anonymous.priv)); | ||
205 | GNUNET_IDENTITY_ego_get_public_key(ego, &(anonymous.pub)); | ||
206 | read_keys = 1; | ||
207 | } | ||
208 | |||
209 | return &anonymous; | ||
210 | } | ||
211 | |||
212 | void | ||
213 | setup_handle_name (struct GNUNET_MESSENGER_SrvHandle *handle, const char *name) | ||
214 | { | ||
215 | change_handle_name (handle, name); | ||
216 | change_handle_ego (handle, handle->name? lookup_service_ego(handle->service, handle->name) : NULL); | ||
217 | |||
218 | if (handle->service->dir) | ||
219 | load_handle_configuration(handle); | ||
220 | } | ||
221 | |||
222 | struct GNUNET_MESSENGER_MessageHandle | ||
223 | { | ||
224 | struct GNUNET_MESSENGER_SrvHandle *handle; | ||
225 | struct GNUNET_MESSENGER_Message *message; | ||
226 | }; | ||
227 | |||
228 | static int | ||
229 | iterate_send_message (void *cls, const struct GNUNET_HashCode *key, void *value) | ||
230 | { | ||
231 | struct GNUNET_MESSENGER_MessageHandle *msg_handle = cls; | ||
232 | |||
233 | send_handle_message (msg_handle->handle, key, msg_handle->message); | ||
234 | |||
235 | return GNUNET_YES; | ||
236 | } | ||
237 | |||
238 | static void | ||
239 | callback_ego_create (void *cls, const struct GNUNET_IDENTITY_PrivateKey *key, const char *emsg) | ||
240 | { | ||
241 | struct GNUNET_MESSENGER_SrvHandle *handle = cls; | ||
242 | |||
243 | handle->operation = NULL; | ||
244 | |||
245 | if (emsg) | ||
246 | GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "%s\n", emsg); | ||
247 | |||
248 | if (key) | ||
249 | { | ||
250 | struct GNUNET_MESSENGER_MessageHandle msg_handle; | ||
251 | |||
252 | msg_handle.handle = handle; | ||
253 | msg_handle.message = create_message_key (key); | ||
254 | |||
255 | GNUNET_CONTAINER_multihashmap_iterate (handle->member_ids, iterate_send_message, &msg_handle); | ||
256 | |||
257 | destroy_message (msg_handle.message); | ||
258 | |||
259 | update_service_ego(handle->service, handle->name, key); | ||
260 | |||
261 | change_handle_ego (handle, lookup_service_ego(handle->service, handle->name)); | ||
262 | } | ||
263 | } | ||
264 | |||
265 | int | ||
266 | update_handle (struct GNUNET_MESSENGER_SrvHandle *handle) | ||
267 | { | ||
268 | GNUNET_assert(handle); | ||
269 | |||
270 | if (!handle->name) | ||
271 | return GNUNET_SYSERR; | ||
272 | |||
273 | struct GNUNET_MESSENGER_Ego *ego = lookup_service_ego(handle->service, handle->name); | ||
274 | |||
275 | if (!ego) | ||
276 | handle->operation = GNUNET_IDENTITY_create (handle->service->identity, handle->name, NULL, | ||
277 | GNUNET_IDENTITY_TYPE_ECDSA, callback_ego_create, handle); | ||
278 | else | ||
279 | change_handle_ego (handle, ego); | ||
280 | |||
281 | return GNUNET_OK; | ||
282 | } | ||
283 | |||
284 | int | ||
285 | set_handle_name (struct GNUNET_MESSENGER_SrvHandle *handle, const char *name) | ||
286 | { | ||
287 | GNUNET_assert(handle); | ||
288 | |||
289 | if ((name) && (lookup_service_ego(handle->service, name))) | ||
290 | return GNUNET_NO; | ||
291 | |||
292 | struct GNUNET_IDENTITY_Operation *operation = handle->operation; | ||
293 | |||
294 | if (handle->name) | ||
295 | handle->operation = GNUNET_IDENTITY_rename (handle->service->identity, handle->name, name, NULL, NULL); | ||
296 | |||
297 | char *old_dir; | ||
298 | get_handle_data_subdir (handle, handle->name, &old_dir); | ||
299 | |||
300 | char *new_dir; | ||
301 | get_handle_data_subdir (handle, name, &new_dir); | ||
302 | |||
303 | int result = 0; | ||
304 | |||
305 | if (GNUNET_YES == GNUNET_DISK_directory_test (old_dir, GNUNET_YES)) | ||
306 | { | ||
307 | GNUNET_DISK_directory_create_for_file (new_dir); | ||
308 | |||
309 | result = rename (old_dir, new_dir); | ||
310 | } | ||
311 | else if (GNUNET_YES == GNUNET_DISK_directory_test (new_dir, GNUNET_NO)) | ||
312 | result = -1; | ||
313 | |||
314 | if (0 == result) | ||
315 | { | ||
316 | struct GNUNET_MESSENGER_MessageHandle msg_handle; | ||
317 | |||
318 | msg_handle.handle = handle; | ||
319 | msg_handle.message = create_message_name (name); | ||
320 | |||
321 | GNUNET_CONTAINER_multihashmap_iterate (handle->member_ids, iterate_send_message, &msg_handle); | ||
322 | |||
323 | destroy_message (msg_handle.message); | ||
324 | |||
325 | change_handle_name (handle, name); | ||
326 | |||
327 | if (operation) | ||
328 | GNUNET_IDENTITY_cancel (operation); | ||
329 | } | ||
330 | else | ||
331 | { | ||
332 | if (handle->operation) | ||
333 | { | ||
334 | GNUNET_IDENTITY_cancel (handle->operation); | ||
335 | |||
336 | handle->operation = operation; | ||
337 | } | ||
338 | } | ||
339 | |||
340 | GNUNET_free(old_dir); | ||
341 | GNUNET_free(new_dir); | ||
342 | |||
343 | return (result == 0 ? GNUNET_OK : GNUNET_NO); | ||
344 | } | ||
345 | |||
346 | int | ||
347 | open_handle_room (struct GNUNET_MESSENGER_SrvHandle *handle, const struct GNUNET_HashCode *key) | ||
348 | { | ||
349 | if ((!get_handle_member_id (handle, key)) && (GNUNET_YES != create_handle_member_id (handle, key))) | ||
350 | return GNUNET_NO; | ||
351 | |||
352 | return open_service_room (handle->service, handle, key); | ||
353 | } | ||
354 | |||
355 | int | ||
356 | entry_handle_room (struct GNUNET_MESSENGER_SrvHandle *handle, const struct GNUNET_PeerIdentity *door, | ||
357 | const struct GNUNET_HashCode *key) | ||
358 | { | ||
359 | if ((!get_handle_member_id (handle, key)) && (GNUNET_YES != create_handle_member_id (handle, key))) | ||
360 | return GNUNET_NO; | ||
361 | |||
362 | return entry_service_room (handle->service, handle, door, key); | ||
363 | } | ||
364 | |||
365 | int | ||
366 | close_handle_room (struct GNUNET_MESSENGER_SrvHandle *handle, const struct GNUNET_HashCode *key) | ||
367 | { | ||
368 | if (!get_handle_member_id (handle, key)) | ||
369 | return GNUNET_NO; | ||
370 | |||
371 | return close_service_room (handle->service, handle, key); | ||
372 | } | ||
373 | |||
374 | int | ||
375 | send_handle_message (struct GNUNET_MESSENGER_SrvHandle *handle, const struct GNUNET_HashCode *key, | ||
376 | struct GNUNET_MESSENGER_Message *message) | ||
377 | { | ||
378 | const struct GNUNET_ShortHashCode *id = get_handle_member_id (handle, key); | ||
379 | |||
380 | if (!id) | ||
381 | { | ||
382 | GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "It is required to be a member of a room to send messages!\n"); | ||
383 | return GNUNET_NO; | ||
384 | } | ||
385 | |||
386 | struct GNUNET_MESSENGER_SrvRoom *room = get_service_room (handle->service, key); | ||
387 | |||
388 | if (!room) | ||
389 | { | ||
390 | GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "The room (%s) is unknown!\n", GNUNET_h2s (key)); | ||
391 | return GNUNET_NO; | ||
392 | } | ||
393 | |||
394 | struct GNUNET_HashCode hash; | ||
395 | |||
396 | GNUNET_memcpy(&(message->header.sender_id), id, sizeof(*id)); | ||
397 | |||
398 | send_room_message (room, handle, message, &hash); | ||
399 | return GNUNET_YES; | ||
400 | } | ||
401 | |||
402 | static int callback_scan_for_rooms(void* cls, const char *filename) { | ||
403 | struct GNUNET_MESSENGER_SrvHandle* handle = cls; | ||
404 | |||
405 | struct GNUNET_CONFIGURATION_Handle* cfg = GNUNET_CONFIGURATION_create(); | ||
406 | |||
407 | if ((GNUNET_YES == GNUNET_DISK_file_test(filename)) && | ||
408 | (GNUNET_OK == GNUNET_CONFIGURATION_parse(cfg, filename))) | ||
409 | { | ||
410 | struct GNUNET_HashCode key; | ||
411 | struct GNUNET_ShortHashCode member_id; | ||
412 | |||
413 | if ((GNUNET_OK == GNUNET_CONFIGURATION_get_data(cfg, "room", "key", &key, sizeof(key))) && | ||
414 | (GNUNET_OK == GNUNET_CONFIGURATION_get_data(cfg, "room", "member_id", &member_id, sizeof(member_id)))) | ||
415 | change_handle_member_id(handle, &key, &member_id); | ||
416 | } | ||
417 | |||
418 | GNUNET_CONFIGURATION_destroy(cfg); | ||
419 | return GNUNET_OK; | ||
420 | } | ||
421 | |||
422 | void load_handle_configuration(struct GNUNET_MESSENGER_SrvHandle *handle) { | ||
423 | char* id_dir; | ||
424 | get_handle_data_subdir(handle, handle->name, &id_dir); | ||
425 | |||
426 | if (GNUNET_YES == GNUNET_DISK_directory_test(id_dir, GNUNET_YES)) | ||
427 | { | ||
428 | char* scan_dir; | ||
429 | GNUNET_asprintf(&scan_dir, "%s%s%c", id_dir, "rooms", DIR_SEPARATOR); | ||
430 | |||
431 | if (GNUNET_OK == GNUNET_DISK_directory_test(scan_dir, GNUNET_YES)) | ||
432 | GNUNET_DISK_directory_scan(scan_dir, callback_scan_for_rooms, handle); | ||
433 | |||
434 | GNUNET_free(scan_dir); | ||
435 | } | ||
436 | |||
437 | GNUNET_free(id_dir); | ||
438 | } | ||
439 | |||
440 | static int | ||
441 | iterate_save_rooms(void* cls, const struct GNUNET_HashCode* key, void* value) | ||
442 | { | ||
443 | struct GNUNET_MESSENGER_SrvHandle* handle = cls; | ||
444 | struct GNUNET_ShortHashCode* member_id = value; | ||
445 | |||
446 | char* id_dir; | ||
447 | get_handle_data_subdir(handle, handle->name, &id_dir); | ||
448 | |||
449 | char* filename; | ||
450 | GNUNET_asprintf(&filename, "%s%s%c%s.cfg", | ||
451 | id_dir, "rooms", DIR_SEPARATOR, | ||
452 | GNUNET_h2s(key)); | ||
453 | |||
454 | GNUNET_free(id_dir); | ||
455 | |||
456 | struct GNUNET_CONFIGURATION_Handle* cfg = GNUNET_CONFIGURATION_create(); | ||
457 | |||
458 | char* key_data = GNUNET_STRINGS_data_to_string_alloc(key, sizeof(*key)); | ||
459 | |||
460 | if (key_data) | ||
461 | { | ||
462 | GNUNET_CONFIGURATION_set_value_string(cfg, "room", "key", key_data); | ||
463 | |||
464 | GNUNET_free(key_data); | ||
465 | } | ||
466 | |||
467 | char* member_id_data = GNUNET_STRINGS_data_to_string_alloc(member_id, sizeof(*member_id)); | ||
468 | |||
469 | if (member_id_data) | ||
470 | { | ||
471 | GNUNET_CONFIGURATION_set_value_string(cfg, "room", "member_id", member_id_data); | ||
472 | |||
473 | GNUNET_free(member_id_data); | ||
474 | } | ||
475 | |||
476 | GNUNET_CONFIGURATION_write(cfg, filename); | ||
477 | GNUNET_CONFIGURATION_destroy(cfg); | ||
478 | |||
479 | GNUNET_free(filename); | ||
480 | |||
481 | return GNUNET_YES; | ||
482 | } | ||
483 | |||
484 | void save_handle_configuration(struct GNUNET_MESSENGER_SrvHandle *handle) | ||
485 | { | ||
486 | char* id_dir; | ||
487 | get_handle_data_subdir(handle, handle->name, &id_dir); | ||
488 | |||
489 | if ((GNUNET_YES == GNUNET_DISK_directory_test(id_dir, GNUNET_NO)) || | ||
490 | (GNUNET_OK == GNUNET_DISK_directory_create(id_dir))) | ||
491 | { | ||
492 | char* save_dir; | ||
493 | GNUNET_asprintf(&save_dir, "%s%s%c", id_dir, "rooms", DIR_SEPARATOR); | ||
494 | |||
495 | if ((GNUNET_YES == GNUNET_DISK_directory_test(save_dir, GNUNET_NO)) || | ||
496 | (GNUNET_OK == GNUNET_DISK_directory_create(save_dir))) | ||
497 | GNUNET_CONTAINER_multihashmap_iterate(handle->member_ids, iterate_save_rooms, handle); | ||
498 | |||
499 | GNUNET_free(save_dir); | ||
500 | } | ||
501 | |||
502 | GNUNET_free(id_dir); | ||
503 | } | ||
diff --git a/src/messenger/gnunet-service-messenger_handle.h b/src/messenger/gnunet-service-messenger_handle.h new file mode 100644 index 000000000..81cf377a8 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_handle.h | |||
@@ -0,0 +1,216 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_handle.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_SERVICE_MESSENGER_HANDLE_H | ||
27 | #define GNUNET_SERVICE_MESSENGER_HANDLE_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_cadet_service.h" | ||
31 | #include "gnunet_container_lib.h" | ||
32 | #include "gnunet_crypto_lib.h" | ||
33 | #include "gnunet_identity_service.h" | ||
34 | #include "gnunet_peer_lib.h" | ||
35 | #include "gnunet_mq_lib.h" | ||
36 | |||
37 | #include "gnunet-service-messenger_service.h" | ||
38 | |||
39 | #include "messenger_api_ego.h" | ||
40 | #include "messenger_api_message.h" | ||
41 | |||
42 | struct GNUNET_MESSENGER_SrvHandle | ||
43 | { | ||
44 | struct GNUNET_MESSENGER_Service *service; | ||
45 | struct GNUNET_MQ_Handle *mq; | ||
46 | |||
47 | char *name; | ||
48 | |||
49 | struct GNUNET_IDENTITY_Operation *operation; | ||
50 | |||
51 | struct GNUNET_MESSENGER_Ego *ego; | ||
52 | |||
53 | struct GNUNET_CONTAINER_MultiHashMap *member_ids; | ||
54 | }; | ||
55 | |||
56 | /** | ||
57 | * Creates and allocates a new handle related to a <i>service</i> and using a given <i>mq</i> (message queue). | ||
58 | * | ||
59 | * @param service MESSENGER Service | ||
60 | * @param mq Message queue | ||
61 | * @return New handle | ||
62 | */ | ||
63 | struct GNUNET_MESSENGER_SrvHandle* | ||
64 | create_handle (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MQ_Handle *mq); | ||
65 | |||
66 | /** | ||
67 | * Destroys a handle and frees its memory fully. | ||
68 | * | ||
69 | * @param handle Handle | ||
70 | */ | ||
71 | void | ||
72 | destroy_handle (struct GNUNET_MESSENGER_SrvHandle *handle); | ||
73 | |||
74 | /** | ||
75 | * Writes the path of the directory for a given <i>handle</i> using a specific <i>name</i> to the parameter | ||
76 | * <i>dir</i>. This directory will be used to store data regarding the handle and its messages. | ||
77 | * | ||
78 | * @param handle Handle | ||
79 | * @param name Potential name of the handle | ||
80 | * @param dir[out] Path to store data | ||
81 | */ | ||
82 | void | ||
83 | get_handle_data_subdir (struct GNUNET_MESSENGER_SrvHandle *handle, const char *name, char **dir); | ||
84 | |||
85 | /** | ||
86 | * Returns the member id of a given <i>handle</i> in a specific <i>room</i>. | ||
87 | * | ||
88 | * If the handle is not a member of the specific <i>room</i>, NULL gets returned. | ||
89 | * | ||
90 | * @param handle Handle | ||
91 | * @param key Key of a room | ||
92 | * @return Member id or NULL | ||
93 | */ | ||
94 | const struct GNUNET_ShortHashCode* | ||
95 | get_handle_member_id (const struct GNUNET_MESSENGER_SrvHandle *handle, const struct GNUNET_HashCode *key); | ||
96 | |||
97 | /** | ||
98 | * Changes the member id of a given <i>handle</i> in a specific <i>room</i> to match a <i>unique_id</i>. | ||
99 | * | ||
100 | * The client connected to the <i>handle</i> will be informed afterwards automatically. | ||
101 | * | ||
102 | * @param handle Handle | ||
103 | * @param key Key of a room | ||
104 | * @param unique_id Unique member id | ||
105 | */ | ||
106 | void | ||
107 | change_handle_member_id (struct GNUNET_MESSENGER_SrvHandle *handle, const struct GNUNET_HashCode *key, | ||
108 | const struct GNUNET_ShortHashCode *unique_id); | ||
109 | |||
110 | /** | ||
111 | * Returns the EGO used by a given <i>handle</i>. | ||
112 | * | ||
113 | * @param handle Handle | ||
114 | * @return EGO keypair | ||
115 | */ | ||
116 | struct GNUNET_MESSENGER_Ego* | ||
117 | get_handle_ego (struct GNUNET_MESSENGER_SrvHandle *handle); | ||
118 | |||
119 | /** | ||
120 | * Tries to set the name and EGO key of a <i>handle</i> initially by looking up a specific <i>name</i>. | ||
121 | * | ||
122 | * @param handle Handle | ||
123 | * @param name Name (optionally: valid EGO name) | ||
124 | */ | ||
125 | void | ||
126 | setup_handle_name (struct GNUNET_MESSENGER_SrvHandle *handle, const char *name); | ||
127 | |||
128 | /** | ||
129 | * Tries to change the keypair of an EGO of a <i>handle</i> under the same name and informs all rooms | ||
130 | * about the change automatically. | ||
131 | * | ||
132 | * @param handle Handle | ||
133 | * @return GNUNET_OK on success, otherwise GNUNET_SYSERR | ||
134 | */ | ||
135 | int | ||
136 | update_handle (struct GNUNET_MESSENGER_SrvHandle *handle); | ||
137 | |||
138 | /** | ||
139 | * Tries to rename the handle which implies renaming the EGO its using and moving all related data into | ||
140 | * the directory fitting to the changed <i>name</i>. | ||
141 | * | ||
142 | * The client connected to the <i>handle</i> will be informed afterwards automatically. | ||
143 | * | ||
144 | * @param handle Handle | ||
145 | * @param name New name | ||
146 | * @return GNUNET_OK on success, otherwise GNUNET_NO | ||
147 | */ | ||
148 | int | ||
149 | set_handle_name (struct GNUNET_MESSENGER_SrvHandle *handle, const char *name); | ||
150 | |||
151 | /** | ||
152 | * Makes a given <i>handle</i> a member of the room using a specific <i>key</i> and opens the | ||
153 | * room from the handles service. | ||
154 | * | ||
155 | * @param handle Handle | ||
156 | * @param key Key of a room | ||
157 | * @return GNUNET_YES on success, otherwise GNUNET_NO | ||
158 | */ | ||
159 | int | ||
160 | open_handle_room (struct GNUNET_MESSENGER_SrvHandle *handle, const struct GNUNET_HashCode *key); | ||
161 | |||
162 | /** | ||
163 | * Makes a given <i>handle</i> a member of the room using a specific <i>key</i> and enters the room | ||
164 | * through a tunnel to a peer identified by a given <i>door</i> (peer identity). | ||
165 | * | ||
166 | * @param handle Handle | ||
167 | * @param door Peer identity | ||
168 | * @param key Key of a room | ||
169 | * @return GNUNET_YES on success, otherwise GNUNET_NO | ||
170 | */ | ||
171 | int | ||
172 | entry_handle_room (struct GNUNET_MESSENGER_SrvHandle *handle, const struct GNUNET_PeerIdentity *door, | ||
173 | const struct GNUNET_HashCode *key); | ||
174 | |||
175 | /** | ||
176 | * Removes the membership of the room using a specific <i>key</i> and closes it if no other handle | ||
177 | * from this service is still a member of it. | ||
178 | * | ||
179 | * @param handle Handle | ||
180 | * @param key Key of a room | ||
181 | * @return GNUNET_YES on success, otherwise GNUNET_NO | ||
182 | */ | ||
183 | int | ||
184 | close_handle_room (struct GNUNET_MESSENGER_SrvHandle *handle, const struct GNUNET_HashCode *key); | ||
185 | |||
186 | /** | ||
187 | * Sends a <i>message</i> from a given <i>handle</i> to the room using a specific <i>key</i>. | ||
188 | * | ||
189 | * @param handle Handle | ||
190 | * @param key Key of a room | ||
191 | * @param message Message | ||
192 | * @return GNUNET_YES on success, otherwise GNUNET_NO | ||
193 | */ | ||
194 | int | ||
195 | send_handle_message (struct GNUNET_MESSENGER_SrvHandle *handle, const struct GNUNET_HashCode *key, | ||
196 | struct GNUNET_MESSENGER_Message *message); | ||
197 | |||
198 | /** | ||
199 | * Loads member ids and other potential configuration from a given <i>handle</i> which | ||
200 | * depends on the given name the <i>handle</i> uses. | ||
201 | * | ||
202 | * @param handle Handle | ||
203 | */ | ||
204 | void | ||
205 | load_handle_configuration(struct GNUNET_MESSENGER_SrvHandle *handle); | ||
206 | |||
207 | /** | ||
208 | * Saves member ids and other potential configuration from a given <i>handle</i> which | ||
209 | * depends on the given name the <i>handle</i> uses. | ||
210 | * | ||
211 | * @param handle Handle | ||
212 | */ | ||
213 | void | ||
214 | save_handle_configuration(struct GNUNET_MESSENGER_SrvHandle *handle); | ||
215 | |||
216 | #endif //GNUNET_SERVICE_MESSENGER_HANDLE_H | ||
diff --git a/src/messenger/gnunet-service-messenger_list_handles.c b/src/messenger/gnunet-service-messenger_list_handles.c new file mode 100644 index 000000000..16a160dea --- /dev/null +++ b/src/messenger/gnunet-service-messenger_list_handles.c | |||
@@ -0,0 +1,95 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_list_handles.c | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "gnunet-service-messenger_list_handles.h" | ||
27 | |||
28 | #include "gnunet-service-messenger_handle.h" | ||
29 | |||
30 | void | ||
31 | init_list_handles (struct GNUNET_MESSENGER_ListHandles *handles) | ||
32 | { | ||
33 | GNUNET_assert(handles); | ||
34 | |||
35 | handles->head = NULL; | ||
36 | handles->tail = NULL; | ||
37 | } | ||
38 | |||
39 | void | ||
40 | clear_list_handles (struct GNUNET_MESSENGER_ListHandles *handles) | ||
41 | { | ||
42 | GNUNET_assert(handles); | ||
43 | |||
44 | while (handles->head) | ||
45 | { | ||
46 | struct GNUNET_MESSENGER_ListHandle *element = handles->head; | ||
47 | |||
48 | GNUNET_CONTAINER_DLL_remove(handles->head, handles->tail, element); | ||
49 | destroy_handle (element->handle); | ||
50 | GNUNET_free(element); | ||
51 | } | ||
52 | |||
53 | handles->head = NULL; | ||
54 | handles->tail = NULL; | ||
55 | } | ||
56 | |||
57 | void | ||
58 | add_list_handle (struct GNUNET_MESSENGER_ListHandles *handles, void *handle) | ||
59 | { | ||
60 | struct GNUNET_MESSENGER_ListHandle *element = GNUNET_new(struct GNUNET_MESSENGER_ListHandle); | ||
61 | |||
62 | element->handle = handle; | ||
63 | |||
64 | GNUNET_CONTAINER_DLL_insert_tail(handles->head, handles->tail, element); | ||
65 | } | ||
66 | |||
67 | int | ||
68 | remove_list_handle (struct GNUNET_MESSENGER_ListHandles *handles, void *handle) | ||
69 | { | ||
70 | struct GNUNET_MESSENGER_ListHandle *element; | ||
71 | |||
72 | for (element = handles->head; element; element = element->next) | ||
73 | if (element->handle == handle) | ||
74 | break; | ||
75 | |||
76 | if (!element) | ||
77 | return GNUNET_NO; | ||
78 | |||
79 | GNUNET_CONTAINER_DLL_remove(handles->head, handles->tail, element); | ||
80 | GNUNET_free(element); | ||
81 | |||
82 | return GNUNET_YES; | ||
83 | } | ||
84 | |||
85 | void* | ||
86 | find_list_handle_by_member (struct GNUNET_MESSENGER_ListHandles *handles, const struct GNUNET_HashCode *key) | ||
87 | { | ||
88 | struct GNUNET_MESSENGER_ListHandle *element; | ||
89 | |||
90 | for (element = handles->head; element; element = element->next) | ||
91 | if (get_handle_member_id ((struct GNUNET_MESSENGER_SrvHandle*) element->handle, key)) | ||
92 | return element->handle; | ||
93 | |||
94 | return NULL; | ||
95 | } | ||
diff --git a/src/messenger/gnunet-service-messenger_list_handles.h b/src/messenger/gnunet-service-messenger_list_handles.h new file mode 100644 index 000000000..fe92cc58a --- /dev/null +++ b/src/messenger/gnunet-service-messenger_list_handles.h | |||
@@ -0,0 +1,96 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_list_handles.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_SERVICE_MESSENGER_LIST_HANDLES_H | ||
27 | #define GNUNET_SERVICE_MESSENGER_LIST_HANDLES_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_crypto_lib.h" | ||
31 | #include "gnunet_container_lib.h" | ||
32 | |||
33 | struct GNUNET_MESSENGER_ListHandle | ||
34 | { | ||
35 | struct GNUNET_MESSENGER_ListHandle *prev; | ||
36 | struct GNUNET_MESSENGER_ListHandle *next; | ||
37 | |||
38 | void *handle; | ||
39 | }; | ||
40 | |||
41 | struct GNUNET_MESSENGER_ListHandles | ||
42 | { | ||
43 | struct GNUNET_MESSENGER_ListHandle *head; | ||
44 | struct GNUNET_MESSENGER_ListHandle *tail; | ||
45 | }; | ||
46 | |||
47 | /** | ||
48 | * Initializes list of handles as empty list. | ||
49 | * | ||
50 | * @param handles List of handles | ||
51 | */ | ||
52 | void | ||
53 | init_list_handles (struct GNUNET_MESSENGER_ListHandles *handles); | ||
54 | |||
55 | /** | ||
56 | * Destroys remaining handles and clears the list. | ||
57 | * | ||
58 | * @param handles List of handles | ||
59 | */ | ||
60 | void | ||
61 | clear_list_handles (struct GNUNET_MESSENGER_ListHandles *handles); | ||
62 | |||
63 | /** | ||
64 | * Adds a specific <i>handle</i> to the end of the list. | ||
65 | * | ||
66 | * @param handles List of handles | ||
67 | * @param handle Handle | ||
68 | */ | ||
69 | void | ||
70 | add_list_handle (struct GNUNET_MESSENGER_ListHandles *handles, void *handle); | ||
71 | |||
72 | /** | ||
73 | * Removes the first entry matching with a specific <i>handle</i> from the list and | ||
74 | * returns GNUNET_YES on success or GNUNET_NO on failure. | ||
75 | * | ||
76 | * @param handles List of handles | ||
77 | * @param handle Handle | ||
78 | * @return GNUNET_YES on success, otherwise GNUNET_NO | ||
79 | */ | ||
80 | int | ||
81 | remove_list_handle (struct GNUNET_MESSENGER_ListHandles *handles, void *handle); | ||
82 | |||
83 | /** | ||
84 | * Searches linearly through the list of handles for members of a specific room | ||
85 | * which is identified by a given <i>key</i>. | ||
86 | * | ||
87 | * If no handle is found which is a current member, NULL gets returned. | ||
88 | * | ||
89 | * @param handles List of handles | ||
90 | * @param key Common key of a room | ||
91 | * @return First handle which is a current member | ||
92 | */ | ||
93 | void* | ||
94 | find_list_handle_by_member (struct GNUNET_MESSENGER_ListHandles *handles, const struct GNUNET_HashCode *key); | ||
95 | |||
96 | #endif //GNUNET_SERVICE_MESSENGER_LIST_HANDLES_H | ||
diff --git a/src/messenger/gnunet-service-messenger_list_messages.c b/src/messenger/gnunet-service-messenger_list_messages.c new file mode 100644 index 000000000..c4f1f7043 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_list_messages.c | |||
@@ -0,0 +1,76 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_list_messages.c | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "gnunet-service-messenger_list_messages.h" | ||
27 | |||
28 | void | ||
29 | init_list_messages (struct GNUNET_MESSENGER_ListMessages *messages) | ||
30 | { | ||
31 | GNUNET_assert(messages); | ||
32 | |||
33 | messages->head = NULL; | ||
34 | messages->tail = NULL; | ||
35 | } | ||
36 | |||
37 | void | ||
38 | clear_list_messages (struct GNUNET_MESSENGER_ListMessages *messages) | ||
39 | { | ||
40 | GNUNET_assert(messages); | ||
41 | |||
42 | while (messages->head) | ||
43 | { | ||
44 | struct GNUNET_MESSENGER_ListMessage *element = messages->head; | ||
45 | |||
46 | GNUNET_CONTAINER_DLL_remove(messages->head, messages->tail, element); | ||
47 | GNUNET_free(element); | ||
48 | } | ||
49 | |||
50 | messages->head = NULL; | ||
51 | messages->tail = NULL; | ||
52 | } | ||
53 | |||
54 | void | ||
55 | add_to_list_messages (struct GNUNET_MESSENGER_ListMessages *messages, const struct GNUNET_HashCode *hash) | ||
56 | { | ||
57 | struct GNUNET_MESSENGER_ListMessage *element = GNUNET_new(struct GNUNET_MESSENGER_ListMessage); | ||
58 | |||
59 | GNUNET_memcpy(&(element->hash), hash, sizeof(struct GNUNET_HashCode)); | ||
60 | |||
61 | GNUNET_CONTAINER_DLL_insert_tail(messages->head, messages->tail, element); | ||
62 | } | ||
63 | |||
64 | void | ||
65 | remove_from_list_messages (struct GNUNET_MESSENGER_ListMessages *messages, const struct GNUNET_HashCode *hash) | ||
66 | { | ||
67 | struct GNUNET_MESSENGER_ListMessage *element; | ||
68 | |||
69 | for (element = messages->head; element; element = element->next) | ||
70 | if (0 == GNUNET_CRYPTO_hash_cmp (&(element->hash), hash)) | ||
71 | { | ||
72 | GNUNET_CONTAINER_DLL_remove(messages->head, messages->tail, element); | ||
73 | GNUNET_free(element); | ||
74 | break; | ||
75 | } | ||
76 | } | ||
diff --git a/src/messenger/gnunet-service-messenger_list_messages.h b/src/messenger/gnunet-service-messenger_list_messages.h new file mode 100644 index 000000000..266c30ec6 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_list_messages.h | |||
@@ -0,0 +1,81 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_list_messages.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_SERVICE_MESSENGER_LIST_MESSAGES_H | ||
27 | #define GNUNET_SERVICE_MESSENGER_LIST_MESSAGES_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_crypto_lib.h" | ||
31 | #include "gnunet_container_lib.h" | ||
32 | |||
33 | struct GNUNET_MESSENGER_ListMessage | ||
34 | { | ||
35 | struct GNUNET_MESSENGER_ListMessage *prev; | ||
36 | struct GNUNET_MESSENGER_ListMessage *next; | ||
37 | |||
38 | struct GNUNET_HashCode hash; | ||
39 | }; | ||
40 | |||
41 | struct GNUNET_MESSENGER_ListMessages | ||
42 | { | ||
43 | struct GNUNET_MESSENGER_ListMessage *head; | ||
44 | struct GNUNET_MESSENGER_ListMessage *tail; | ||
45 | }; | ||
46 | |||
47 | /** | ||
48 | * Initializes list of message hashes as empty list. | ||
49 | * | ||
50 | * @param messages List of hashes | ||
51 | */ | ||
52 | void | ||
53 | init_list_messages (struct GNUNET_MESSENGER_ListMessages *messages); | ||
54 | |||
55 | /** | ||
56 | * Clears the list of message hashes. | ||
57 | * | ||
58 | * @param messages List of hashes | ||
59 | */ | ||
60 | void | ||
61 | clear_list_messages (struct GNUNET_MESSENGER_ListMessages *messages); | ||
62 | |||
63 | /** | ||
64 | * Adds a specific <i>hash</i> from a message to the end of the list. | ||
65 | * | ||
66 | * @param messages List of hashes | ||
67 | * @param hash Hash of message | ||
68 | */ | ||
69 | void | ||
70 | add_to_list_messages (struct GNUNET_MESSENGER_ListMessages *messages, const struct GNUNET_HashCode *hash); | ||
71 | |||
72 | /** | ||
73 | * Removes the first entry with a matching <i>hash</i> from the list. | ||
74 | * | ||
75 | * @param messages List of hashes | ||
76 | * @param hash Hash of message | ||
77 | */ | ||
78 | void | ||
79 | remove_from_list_messages (struct GNUNET_MESSENGER_ListMessages *messages, const struct GNUNET_HashCode *hash); | ||
80 | |||
81 | #endif //GNUNET_SERVICE_MESSENGER_LIST_MESSAGES_H | ||
diff --git a/src/messenger/gnunet-service-messenger_message_handle.c b/src/messenger/gnunet-service-messenger_message_handle.c new file mode 100644 index 000000000..1652435c8 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_message_handle.c | |||
@@ -0,0 +1,130 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_message_handle.c | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "gnunet-service-messenger_message_handle.h" | ||
27 | |||
28 | void | ||
29 | handle_message_join (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
30 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
31 | { | ||
32 | struct GNUNET_MESSENGER_SrvContact *contact = get_room_contact (room, &(message->header.sender_id)); | ||
33 | |||
34 | if (!contact) | ||
35 | add_room_contact (room, &(message->header.sender_id), &(message->body.join.key)); | ||
36 | |||
37 | struct GNUNET_MESSENGER_MemberInfo *info = get_room_member_info (room, &(message->header.sender_id)); | ||
38 | |||
39 | if (!info) | ||
40 | { | ||
41 | info = GNUNET_new(struct GNUNET_MESSENGER_MemberInfo); | ||
42 | |||
43 | info->access = GNUNET_MESSENGER_MEMBER_UNKNOWN; | ||
44 | init_list_messages (&(info->session_messages)); | ||
45 | } | ||
46 | else | ||
47 | clear_list_messages (&(info->session_messages)); | ||
48 | |||
49 | if (GNUNET_YES == GNUNET_CONTAINER_multishortmap_put (room->member_infos, &(message->header.sender_id), info, | ||
50 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST)) | ||
51 | add_to_list_messages (&(info->session_messages), hash); | ||
52 | } | ||
53 | |||
54 | void | ||
55 | handle_message_leave (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
56 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
57 | { | ||
58 | struct GNUNET_MESSENGER_MemberInfo *info = get_room_member_info (room, &(message->header.sender_id)); | ||
59 | |||
60 | if (info) | ||
61 | clear_list_messages (&(info->session_messages)); | ||
62 | } | ||
63 | |||
64 | void | ||
65 | handle_message_name (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
66 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
67 | { | ||
68 | struct GNUNET_MESSENGER_SrvContact *contact = get_room_contact (room, &(message->header.sender_id)); | ||
69 | |||
70 | if (contact) | ||
71 | set_contact_name (contact, message->body.name.name); | ||
72 | |||
73 | struct GNUNET_MESSENGER_MemberInfo *info = get_room_member_info (room, &(message->header.sender_id)); | ||
74 | |||
75 | if (info) | ||
76 | add_to_list_messages (&(info->session_messages), hash); | ||
77 | } | ||
78 | |||
79 | void | ||
80 | handle_message_key (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
81 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
82 | { | ||
83 | struct GNUNET_MESSENGER_SrvContact *contact = get_room_contact (room, &(message->header.sender_id)); | ||
84 | |||
85 | if (contact) | ||
86 | swap_service_contact_by_pubkey (room->service, contact, &(message->body.key.key)); | ||
87 | |||
88 | struct GNUNET_MESSENGER_MemberInfo *info = get_room_member_info (room, &(message->header.sender_id)); | ||
89 | |||
90 | if (info) | ||
91 | add_to_list_messages (&(info->session_messages), hash); | ||
92 | } | ||
93 | |||
94 | void | ||
95 | handle_message_peer (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
96 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
97 | { | ||
98 | if (GNUNET_NO == contains_list_tunnels (&(room->basement), &(message->body.peer.peer))) | ||
99 | add_to_list_tunnels (&(room->basement), &(message->body.peer.peer)); | ||
100 | |||
101 | if (room->peer_message) | ||
102 | rebuild_room_basement_structure (room); | ||
103 | } | ||
104 | |||
105 | void | ||
106 | handle_message_id (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
107 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
108 | { | ||
109 | struct GNUNET_MESSENGER_MemberInfo *info = get_room_member_info (room, &(message->header.sender_id)); | ||
110 | |||
111 | if (info) | ||
112 | add_to_list_messages (&(info->session_messages), hash); | ||
113 | |||
114 | switch_room_member_id (room, &(message->header.sender_id), &(message->body.id.id), hash); | ||
115 | } | ||
116 | |||
117 | void | ||
118 | handle_message_miss (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
119 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
120 | { | ||
121 | struct GNUNET_MESSENGER_ListTunnel *element = find_list_tunnels (&(room->basement), &(message->body.peer.peer), NULL); | ||
122 | |||
123 | if (!element) | ||
124 | return; | ||
125 | |||
126 | remove_from_list_tunnels (&(room->basement), element); | ||
127 | |||
128 | if (room->peer_message) | ||
129 | rebuild_room_basement_structure (room); | ||
130 | } | ||
diff --git a/src/messenger/gnunet-service-messenger_message_handle.h b/src/messenger/gnunet-service-messenger_message_handle.h new file mode 100644 index 000000000..d091e1d11 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_message_handle.h | |||
@@ -0,0 +1,128 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_message_handle.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_SERVICE_MESSENGER_MESSAGE_HANDLE_H | ||
27 | #define GNUNET_SERVICE_MESSENGER_MESSAGE_HANDLE_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_crypto_lib.h" | ||
31 | |||
32 | #include "gnunet-service-messenger_message_kind.h" | ||
33 | |||
34 | #include "gnunet-service-messenger_tunnel.h" | ||
35 | #include "messenger_api_message.h" | ||
36 | |||
37 | /** | ||
38 | * Handles a received or sent join message to make changes of current member information. | ||
39 | * (add matching member and clear member info) | ||
40 | * | ||
41 | * @param room Room of the message | ||
42 | * @param tunnel Receiving/sending connection (may be NULL) | ||
43 | * @param message JOIN-Message | ||
44 | * @param hash Hash of the message | ||
45 | */ | ||
46 | void | ||
47 | handle_message_join (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
48 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
49 | |||
50 | /** | ||
51 | * Handles a received or sent leave message to make changes of current member information. | ||
52 | * (remove matching member and clear member info) | ||
53 | * | ||
54 | * @param room Room of the message | ||
55 | * @param tunnel Receiving/sending connection (may be NULL) | ||
56 | * @param message LEAVE-Message | ||
57 | * @param hash Hash of the message | ||
58 | */ | ||
59 | void | ||
60 | handle_message_leave (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
61 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
62 | |||
63 | /** | ||
64 | * Handles a received or sent name message to rename a current member. | ||
65 | * (change name of matching member) | ||
66 | * | ||
67 | * @param room Room of the message | ||
68 | * @param tunnel Receiving/sending connection (may be NULL) | ||
69 | * @param message NAME-Message | ||
70 | * @param hash Hash of the message | ||
71 | */ | ||
72 | void | ||
73 | handle_message_name (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
74 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
75 | |||
76 | /** | ||
77 | * Handles a received or sent key message to change the key of a member and rearrange the contacts accordingly. | ||
78 | * (move the member in the contacts and change its key) | ||
79 | * | ||
80 | * @param room Room of the message | ||
81 | * @param tunnel Receiving/sending connection (may be NULL) | ||
82 | * @param message KEY-Message | ||
83 | * @param hash Hash of the message | ||
84 | */ | ||
85 | void | ||
86 | handle_message_key (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
87 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
88 | |||
89 | /** | ||
90 | * Handles a received or sent peer message to make changes of the basement in the room. | ||
91 | * (add a new peer to the basement and restructure connections based on updated list of peers) | ||
92 | * | ||
93 | * @param room Room of the message | ||
94 | * @param tunnel Receiving/sending connection (may be NULL) | ||
95 | * @param message PEER-Message | ||
96 | * @param hash Hash of the message | ||
97 | */ | ||
98 | void | ||
99 | handle_message_peer (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
100 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
101 | |||
102 | /** | ||
103 | * Handles a received or sent id message to change a members id. | ||
104 | * (change id of matching member) | ||
105 | * | ||
106 | * @param room Room of the message | ||
107 | * @param tunnel Receiving/sending connection (may be NULL) | ||
108 | * @param message ID-Message | ||
109 | * @param hash Hash of the message | ||
110 | */ | ||
111 | void | ||
112 | handle_message_id (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
113 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
114 | |||
115 | /** | ||
116 | * Handles a received or sent miss message to drop a peer from the basement in the room. | ||
117 | * (remove a peer from the basement and restructure connections based on updated list of peers) | ||
118 | * | ||
119 | * @param room Room of the message | ||
120 | * @param tunnel Receiving/sending connection (may be NULL) | ||
121 | * @param message MISS-Message | ||
122 | * @param hash Hash of the message | ||
123 | */ | ||
124 | void | ||
125 | handle_message_miss (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
126 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
127 | |||
128 | #endif //GNUNET_SERVICE_MESSENGER_MESSAGE_HANDLE_H | ||
diff --git a/src/messenger/gnunet-service-messenger_message_kind.c b/src/messenger/gnunet-service-messenger_message_kind.c new file mode 100644 index 000000000..9c829fe09 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_message_kind.c | |||
@@ -0,0 +1,192 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_message_kind.c | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "gnunet-service-messenger_message_kind.h" | ||
27 | #include "gnunet-service-messenger_util.h" | ||
28 | |||
29 | struct GNUNET_MESSENGER_Message* | ||
30 | create_message_info (struct GNUNET_MESSENGER_Ego *ego, struct GNUNET_CONTAINER_MultiShortmap *members) | ||
31 | { | ||
32 | struct GNUNET_MESSENGER_Message *message = create_message (GNUNET_MESSENGER_KIND_INFO); | ||
33 | |||
34 | if (!message) | ||
35 | return NULL; | ||
36 | |||
37 | GNUNET_memcpy(&(message->body.info.host_key), &(ego->pub), sizeof(ego->pub)); | ||
38 | |||
39 | if (GNUNET_YES == generate_free_member_id (&(message->body.info.unique_id), members)) | ||
40 | return message; | ||
41 | else | ||
42 | { | ||
43 | destroy_message (message); | ||
44 | return NULL; | ||
45 | } | ||
46 | } | ||
47 | |||
48 | struct GNUNET_MESSENGER_Message* | ||
49 | create_message_join (struct GNUNET_MESSENGER_Ego *ego) | ||
50 | { | ||
51 | struct GNUNET_MESSENGER_Message *message = create_message (GNUNET_MESSENGER_KIND_JOIN); | ||
52 | |||
53 | if (!message) | ||
54 | return NULL; | ||
55 | |||
56 | GNUNET_memcpy(&(message->body.join.key), &(ego->pub), sizeof(ego->pub)); | ||
57 | |||
58 | return message; | ||
59 | } | ||
60 | |||
61 | struct GNUNET_MESSENGER_Message* | ||
62 | create_message_leave () | ||
63 | { | ||
64 | return create_message (GNUNET_MESSENGER_KIND_LEAVE); | ||
65 | } | ||
66 | |||
67 | struct GNUNET_MESSENGER_Message* | ||
68 | create_message_name (const char *name) | ||
69 | { | ||
70 | struct GNUNET_MESSENGER_Message *message = create_message (GNUNET_MESSENGER_KIND_NAME); | ||
71 | |||
72 | if (!message) | ||
73 | return NULL; | ||
74 | |||
75 | message->body.name.name = GNUNET_strdup(name); | ||
76 | return message; | ||
77 | } | ||
78 | |||
79 | struct GNUNET_MESSENGER_Message* | ||
80 | create_message_key (const struct GNUNET_IDENTITY_PrivateKey *key) | ||
81 | { | ||
82 | struct GNUNET_MESSENGER_Message *message = create_message (GNUNET_MESSENGER_KIND_KEY); | ||
83 | |||
84 | if (!message) | ||
85 | return NULL; | ||
86 | |||
87 | GNUNET_IDENTITY_key_get_public (key, &(message->body.key.key)); | ||
88 | return message; | ||
89 | } | ||
90 | |||
91 | struct GNUNET_MESSENGER_Message* | ||
92 | create_message_peer (const struct GNUNET_MESSENGER_Service *service) | ||
93 | { | ||
94 | struct GNUNET_MESSENGER_Message *message = create_message (GNUNET_MESSENGER_KIND_PEER); | ||
95 | |||
96 | if (!message) | ||
97 | return NULL; | ||
98 | |||
99 | if (GNUNET_OK == get_service_peer_identity (service, &(message->body.peer.peer))) | ||
100 | return message; | ||
101 | else | ||
102 | { | ||
103 | destroy_message (message); | ||
104 | return NULL; | ||
105 | } | ||
106 | } | ||
107 | |||
108 | struct GNUNET_MESSENGER_Message* | ||
109 | create_message_id (const struct GNUNET_ShortHashCode *unique_id) | ||
110 | { | ||
111 | struct GNUNET_MESSENGER_Message *message = create_message (GNUNET_MESSENGER_KIND_ID); | ||
112 | |||
113 | if (!message) | ||
114 | return NULL; | ||
115 | |||
116 | GNUNET_memcpy(&(message->body.id.id), unique_id, sizeof(struct GNUNET_ShortHashCode)); | ||
117 | |||
118 | return message; | ||
119 | } | ||
120 | |||
121 | struct GNUNET_MESSENGER_Message* | ||
122 | create_message_miss (const struct GNUNET_PeerIdentity *peer) | ||
123 | { | ||
124 | struct GNUNET_MESSENGER_Message *message = create_message (GNUNET_MESSENGER_KIND_MISS); | ||
125 | |||
126 | if (!message) | ||
127 | { | ||
128 | return NULL; | ||
129 | } | ||
130 | |||
131 | GNUNET_memcpy(&(message->body.miss.peer), peer, sizeof(struct GNUNET_PeerIdentity)); | ||
132 | |||
133 | return message; | ||
134 | } | ||
135 | |||
136 | struct GNUNET_MESSENGER_Message* | ||
137 | create_message_merge (const struct GNUNET_HashCode *previous) | ||
138 | { | ||
139 | struct GNUNET_MESSENGER_Message *message = create_message (GNUNET_MESSENGER_KIND_MERGE); | ||
140 | |||
141 | if (!message) | ||
142 | return NULL; | ||
143 | |||
144 | GNUNET_memcpy(&(message->body.merge.previous), previous, sizeof(struct GNUNET_HashCode)); | ||
145 | |||
146 | return message; | ||
147 | } | ||
148 | |||
149 | struct GNUNET_MESSENGER_Message* | ||
150 | create_message_request (const struct GNUNET_HashCode *hash) | ||
151 | { | ||
152 | struct GNUNET_HashCode zero; | ||
153 | memset (&zero, 0, sizeof(zero)); | ||
154 | |||
155 | if (0 == GNUNET_CRYPTO_hash_cmp (hash, &zero)) | ||
156 | return NULL; | ||
157 | |||
158 | struct GNUNET_MESSENGER_Message *message = create_message (GNUNET_MESSENGER_KIND_REQUEST); | ||
159 | |||
160 | if (!message) | ||
161 | return NULL; | ||
162 | |||
163 | GNUNET_memcpy(&(message->body.request.hash), hash, sizeof(struct GNUNET_HashCode)); | ||
164 | |||
165 | return message; | ||
166 | } | ||
167 | |||
168 | struct GNUNET_MESSENGER_Message* | ||
169 | create_message_invite (const struct GNUNET_PeerIdentity *door, const struct GNUNET_HashCode *key) | ||
170 | { | ||
171 | struct GNUNET_MESSENGER_Message *message = create_message (GNUNET_MESSENGER_KIND_INVITE); | ||
172 | |||
173 | if (!message) | ||
174 | return NULL; | ||
175 | |||
176 | GNUNET_memcpy(&(message->body.invite.door), door, sizeof(struct GNUNET_PeerIdentity)); | ||
177 | GNUNET_memcpy(&(message->body.invite.key), key, sizeof(struct GNUNET_HashCode)); | ||
178 | |||
179 | return message; | ||
180 | } | ||
181 | |||
182 | struct GNUNET_MESSENGER_Message* | ||
183 | create_message_text (const char *text) | ||
184 | { | ||
185 | struct GNUNET_MESSENGER_Message *message = create_message (GNUNET_MESSENGER_KIND_TEXT); | ||
186 | |||
187 | if (!message) | ||
188 | return NULL; | ||
189 | |||
190 | message->body.text.text = GNUNET_strdup(text); | ||
191 | return message; | ||
192 | } | ||
diff --git a/src/messenger/gnunet-service-messenger_message_kind.h b/src/messenger/gnunet-service-messenger_message_kind.h new file mode 100644 index 000000000..dd89d0b2f --- /dev/null +++ b/src/messenger/gnunet-service-messenger_message_kind.h | |||
@@ -0,0 +1,160 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_message_kind.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_SERVICE_MESSENGER_MESSAGE_KIND_H | ||
27 | #define GNUNET_SERVICE_MESSENGER_MESSAGE_KIND_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_container_lib.h" | ||
31 | #include "gnunet_crypto_lib.h" | ||
32 | #include "gnunet_identity_service.h" | ||
33 | |||
34 | #include "messenger_api_message.h" | ||
35 | #include "gnunet-service-messenger_service.h" | ||
36 | #include "messenger_api_ego.h" | ||
37 | |||
38 | /** | ||
39 | * Creates and allocates a new info message containing the hosts public key and a newly generated unique member id. | ||
40 | * (all values are stored as copy) | ||
41 | * | ||
42 | * @param ego EGO of the host | ||
43 | * @param members Map of all assigned member ids | ||
44 | * @return New message | ||
45 | */ | ||
46 | struct GNUNET_MESSENGER_Message* | ||
47 | create_message_info (struct GNUNET_MESSENGER_Ego *ego, struct GNUNET_CONTAINER_MultiShortmap *members); | ||
48 | |||
49 | /** | ||
50 | * Creates and allocates a new join message containing the clients public key. | ||
51 | * (all values are stored as copy) | ||
52 | * | ||
53 | * @param ego EGO of the client | ||
54 | * @return New message | ||
55 | */ | ||
56 | struct GNUNET_MESSENGER_Message* | ||
57 | create_message_join (struct GNUNET_MESSENGER_Ego *ego); | ||
58 | |||
59 | /** | ||
60 | * Creates and allocates a new leave message. | ||
61 | * | ||
62 | * @return New message | ||
63 | */ | ||
64 | struct GNUNET_MESSENGER_Message* | ||
65 | create_message_leave (); | ||
66 | |||
67 | /** | ||
68 | * Creates and allocates a new name message containing the <i>name</i> to change to. | ||
69 | * (all values are stored as copy) | ||
70 | * | ||
71 | * @param name New name | ||
72 | * @return New message | ||
73 | */ | ||
74 | struct GNUNET_MESSENGER_Message* | ||
75 | create_message_name (const char *name); | ||
76 | |||
77 | /** | ||
78 | * Creates and allocates a new key message containing the public key to change to derived | ||
79 | * from its private counterpart. (all values are stored as copy) | ||
80 | * | ||
81 | * @param key Private key of EGO | ||
82 | * @return New message | ||
83 | */ | ||
84 | struct GNUNET_MESSENGER_Message* | ||
85 | create_message_key (const struct GNUNET_IDENTITY_PrivateKey *key); | ||
86 | |||
87 | /** | ||
88 | * Creates and allocates a new peer message containing a services peer identity. | ||
89 | * (all values are stored as copy) | ||
90 | * | ||
91 | * @param service Service | ||
92 | * @return New message | ||
93 | */ | ||
94 | struct GNUNET_MESSENGER_Message* | ||
95 | create_message_peer (const struct GNUNET_MESSENGER_Service *service); | ||
96 | |||
97 | /** | ||
98 | * Creates and allocates a new id message containing the unique member id to change to. | ||
99 | * (all values are stored as copy) | ||
100 | * | ||
101 | * @param unique_id Unique member id | ||
102 | * @return New message | ||
103 | */ | ||
104 | struct GNUNET_MESSENGER_Message* | ||
105 | create_message_id (const struct GNUNET_ShortHashCode *unique_id); | ||
106 | |||
107 | /** | ||
108 | * Creates and allocates a new miss message containing the missing peer identity. | ||
109 | * (all values are stored as copy) | ||
110 | * | ||
111 | * @param peer Missing peer identity | ||
112 | * @return New message | ||
113 | */ | ||
114 | struct GNUNET_MESSENGER_Message* | ||
115 | create_message_miss (const struct GNUNET_PeerIdentity *peer); | ||
116 | |||
117 | /** | ||
118 | * Creates and allocates a new merge message containing the hash of a second previous message | ||
119 | * besides the regular previous message mentioned in a messages header. | ||
120 | * (all values are stored as copy) | ||
121 | * | ||
122 | * @param previous Hash of message | ||
123 | * @return New message | ||
124 | */ | ||
125 | struct GNUNET_MESSENGER_Message* | ||
126 | create_message_merge (const struct GNUNET_HashCode *previous); | ||
127 | |||
128 | /** | ||
129 | * Creates and allocates a new request message containing the hash of a missing message. | ||
130 | * (all values are stored as copy) | ||
131 | * | ||
132 | * @param hash Hash of message | ||
133 | * @return New message | ||
134 | */ | ||
135 | struct GNUNET_MESSENGER_Message* | ||
136 | create_message_request (const struct GNUNET_HashCode *hash); | ||
137 | |||
138 | /** | ||
139 | * Creates and allocates a new invite message containing the peer identity of an entrance peer | ||
140 | * to a room using a given <i>key</i> as shared secret for communication. | ||
141 | * (all values are stored as copy) | ||
142 | * | ||
143 | * @param door Peer identity | ||
144 | * @param key Shared secret of a room | ||
145 | * @return New message | ||
146 | */ | ||
147 | struct GNUNET_MESSENGER_Message* | ||
148 | create_message_invite (const struct GNUNET_PeerIdentity *door, const struct GNUNET_HashCode *key); | ||
149 | |||
150 | /** | ||
151 | * Creates and allocates a new text message containing a string representing text. | ||
152 | * (all values are stored as copy) | ||
153 | * | ||
154 | * @param text Text | ||
155 | * @return New message | ||
156 | */ | ||
157 | struct GNUNET_MESSENGER_Message* | ||
158 | create_message_text (const char *text); | ||
159 | |||
160 | #endif //GNUNET_SERVICE_MESSENGER_MESSAGE_KIND_H | ||
diff --git a/src/messenger/gnunet-service-messenger_message_recv.c b/src/messenger/gnunet-service-messenger_message_recv.c new file mode 100644 index 000000000..aa28a36ea --- /dev/null +++ b/src/messenger/gnunet-service-messenger_message_recv.c | |||
@@ -0,0 +1,204 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_message_recv.c | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "gnunet-service-messenger_message_recv.h" | ||
27 | #include "gnunet-service-messenger_message_handle.h" | ||
28 | |||
29 | void | ||
30 | recv_message_info (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
31 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
32 | { | ||
33 | int conflict = GNUNET_CONTAINER_multishortmap_contains (room->members, &(message->body.info.unique_id)); | ||
34 | |||
35 | if (GNUNET_NO == conflict) | ||
36 | { | ||
37 | struct GNUNET_MESSENGER_Message *sync_message = create_message_id (&(message->body.info.unique_id)); | ||
38 | struct GNUNET_HashCode sync_hash; | ||
39 | |||
40 | send_room_message_ext (room, room->host, sync_message, &sync_hash, tunnel); | ||
41 | destroy_message (sync_message); | ||
42 | |||
43 | switch_room_member_id (room, get_room_host_id (room), &(message->body.info.unique_id), NULL); | ||
44 | |||
45 | change_room_host_id (room, &(message->body.info.unique_id)); | ||
46 | } | ||
47 | |||
48 | if (!tunnel->contact_id) | ||
49 | tunnel->contact_id = GNUNET_new(struct GNUNET_ShortHashCode); | ||
50 | |||
51 | GNUNET_memcpy(tunnel->contact_id, &(message->header.sender_id), sizeof(struct GNUNET_ShortHashCode)); | ||
52 | |||
53 | struct GNUNET_ShortHashCode original_id; | ||
54 | |||
55 | if (GNUNET_YES == conflict) | ||
56 | { | ||
57 | GNUNET_memcpy(&original_id, get_room_host_id (room), sizeof(struct GNUNET_ShortHashCode)); | ||
58 | |||
59 | change_room_host_id (room, &(message->body.info.unique_id)); | ||
60 | } | ||
61 | |||
62 | { | ||
63 | struct GNUNET_MESSENGER_Message *join_message = create_message_join (room->host->ego); | ||
64 | struct GNUNET_HashCode join_hash; | ||
65 | |||
66 | send_tunnel_message (tunnel, room->host, join_message, &join_hash); | ||
67 | destroy_message (join_message); | ||
68 | } | ||
69 | |||
70 | if ((GNUNET_YES == conflict) && (0 != GNUNET_memcmp(&original_id, get_room_host_id (room)))) | ||
71 | { | ||
72 | struct GNUNET_MESSENGER_Message *sync_message = create_message_id (&original_id); | ||
73 | struct GNUNET_HashCode sync_hash; | ||
74 | |||
75 | send_tunnel_message (tunnel, room->host, sync_message, &sync_hash); | ||
76 | destroy_message (sync_message); | ||
77 | } | ||
78 | } | ||
79 | |||
80 | struct GNUNET_MESSENGER_MemberInfoSpread | ||
81 | { | ||
82 | struct GNUNET_MESSENGER_SrvRoom *room; | ||
83 | struct GNUNET_MESSENGER_SrvTunnel *tunnel; | ||
84 | }; | ||
85 | |||
86 | static int | ||
87 | iterate_send_member_infos (void *cls, const struct GNUNET_ShortHashCode *key, void *value) | ||
88 | { | ||
89 | struct GNUNET_MESSENGER_MemberInfo *info = value; | ||
90 | struct GNUNET_MESSENGER_MemberInfoSpread *spread = cls; | ||
91 | |||
92 | struct GNUNET_MESSENGER_ListMessage *element = info->session_messages.head; | ||
93 | |||
94 | while (element) | ||
95 | { | ||
96 | const struct GNUNET_MESSENGER_Message *message = get_room_message (spread->room, spread->room->host, | ||
97 | &(element->hash), GNUNET_NO); | ||
98 | |||
99 | if (message) | ||
100 | forward_tunnel_message (spread->tunnel, message, &(element->hash)); | ||
101 | |||
102 | element = element->next; | ||
103 | } | ||
104 | |||
105 | return GNUNET_YES; | ||
106 | } | ||
107 | |||
108 | void | ||
109 | recv_message_join (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
110 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
111 | { | ||
112 | const struct GNUNET_MESSENGER_Message *info_msg = get_room_message (room, room->host, &(message->header.previous), | ||
113 | GNUNET_NO); | ||
114 | |||
115 | if ((info_msg) && (0 == GNUNET_memcmp(&(info_msg->header.sender_id), get_room_host_id (room))) | ||
116 | && (GNUNET_MESSENGER_KIND_INFO == info_msg->header.kind)) | ||
117 | { | ||
118 | struct GNUNET_MESSENGER_MemberInfoSpread spread; | ||
119 | |||
120 | spread.room = room; | ||
121 | |||
122 | if ((tunnel) && (tunnel->contact_id) && (0 == GNUNET_memcmp(tunnel->contact_id, &(message->header.sender_id)))) | ||
123 | spread.tunnel = tunnel; | ||
124 | else | ||
125 | spread.tunnel = find_room_tunnel_to (room, &(message->header.sender_id)); | ||
126 | |||
127 | if (spread.tunnel) | ||
128 | GNUNET_CONTAINER_multishortmap_iterate (room->member_infos, iterate_send_member_infos, &spread); | ||
129 | } | ||
130 | |||
131 | handle_message_join (room, tunnel, message, hash); | ||
132 | } | ||
133 | |||
134 | void | ||
135 | recv_message_leave (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
136 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
137 | { | ||
138 | handle_message_leave (room, tunnel, message, hash); | ||
139 | } | ||
140 | |||
141 | void | ||
142 | recv_message_name (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
143 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
144 | { | ||
145 | handle_message_name (room, tunnel, message, hash); | ||
146 | } | ||
147 | |||
148 | void | ||
149 | recv_message_key (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
150 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
151 | { | ||
152 | handle_message_key (room, tunnel, message, hash); | ||
153 | } | ||
154 | |||
155 | void | ||
156 | recv_message_peer (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
157 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
158 | { | ||
159 | struct GNUNET_PeerIdentity peer; | ||
160 | GNUNET_PEER_resolve (tunnel->peer, &peer); | ||
161 | |||
162 | if (0 == GNUNET_memcmp(&peer, &(message->body.peer.peer))) | ||
163 | { | ||
164 | if (!tunnel->peer_message) | ||
165 | tunnel->peer_message = GNUNET_new(struct GNUNET_HashCode); | ||
166 | |||
167 | GNUNET_memcpy(tunnel->peer_message, hash, sizeof(struct GNUNET_HashCode)); | ||
168 | |||
169 | if (!tunnel->contact_id) | ||
170 | tunnel->contact_id = GNUNET_new(struct GNUNET_ShortHashCode); | ||
171 | |||
172 | GNUNET_memcpy(tunnel->contact_id, &(message->header.sender_id), sizeof(struct GNUNET_ShortHashCode)); | ||
173 | } | ||
174 | |||
175 | handle_message_peer (room, tunnel, message, hash); | ||
176 | } | ||
177 | |||
178 | void | ||
179 | recv_message_id (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
180 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
181 | { | ||
182 | if ((tunnel->contact_id) && (0 == GNUNET_memcmp(tunnel->contact_id, &(message->header.sender_id)))) | ||
183 | GNUNET_memcpy(tunnel->contact_id, &(message->body.id.id), sizeof(struct GNUNET_ShortHashCode)); | ||
184 | |||
185 | handle_message_id (room, tunnel, message, hash); | ||
186 | } | ||
187 | |||
188 | void | ||
189 | recv_message_miss (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
190 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
191 | { | ||
192 | handle_message_miss (room, tunnel, message, hash); | ||
193 | } | ||
194 | |||
195 | void | ||
196 | recv_message_request (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
197 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
198 | { | ||
199 | const struct GNUNET_MESSENGER_Message *msg = get_room_message (room, room->host, &(message->body.request.hash), | ||
200 | GNUNET_NO); | ||
201 | |||
202 | if (msg) | ||
203 | forward_tunnel_message (tunnel, msg, &(message->body.request.hash)); | ||
204 | } | ||
diff --git a/src/messenger/gnunet-service-messenger_message_recv.h b/src/messenger/gnunet-service-messenger_message_recv.h new file mode 100644 index 000000000..245612cb0 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_message_recv.h | |||
@@ -0,0 +1,159 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_message_recv.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_SERVICE_MESSENGER_MESSAGE_RECV_H | ||
27 | #define GNUNET_SERVICE_MESSENGER_MESSAGE_RECV_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_crypto_lib.h" | ||
31 | |||
32 | #include "gnunet-service-messenger_tunnel.h" | ||
33 | #include "messenger_api_message.h" | ||
34 | |||
35 | /** | ||
36 | * Handles a received info message to change the current member id to the one generated by | ||
37 | * the host connected to. (all current tunnels will be informed about the id change) | ||
38 | * | ||
39 | * @param room Room of the message | ||
40 | * @param tunnel Receiving connection | ||
41 | * @param message INFO-Message | ||
42 | * @param hash Hash of the message | ||
43 | */ | ||
44 | void | ||
45 | recv_message_info (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
46 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
47 | |||
48 | /** | ||
49 | * Handles a received join message to forward all member information to the new member if the message was | ||
50 | * the direct reaction to a previous info message from this peer. | ||
51 | * | ||
52 | * @param room Room of the message | ||
53 | * @param tunnel Receiving connection | ||
54 | * @param message JOIN-Message | ||
55 | * @param hash Hash of the message | ||
56 | */ | ||
57 | void | ||
58 | recv_message_join (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
59 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
60 | |||
61 | /** | ||
62 | * Handles a received leave message. | ||
63 | * @see handle_message_leave() | ||
64 | * | ||
65 | * @param room Room of the message | ||
66 | * @param tunnel Receiving connection | ||
67 | * @param message LEAVE-Message | ||
68 | * @param hash Hash of the message | ||
69 | */ | ||
70 | void | ||
71 | recv_message_leave (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
72 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
73 | |||
74 | /** | ||
75 | * Handles a received name message. | ||
76 | * @see handle_message_name() | ||
77 | * | ||
78 | * @param room Room of the message | ||
79 | * @param tunnel Receiving connection | ||
80 | * @param message NAME-Message | ||
81 | * @param hash Hash of the message | ||
82 | */ | ||
83 | void | ||
84 | recv_message_name (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
85 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
86 | |||
87 | /** | ||
88 | * Handles a received key message. | ||
89 | * @see handle_message_key() | ||
90 | * | ||
91 | * @param room Room of the message | ||
92 | * @param tunnel Receiving connection | ||
93 | * @param message KEY-Message | ||
94 | * @param hash Hash of the message | ||
95 | */ | ||
96 | void | ||
97 | recv_message_key (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
98 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
99 | |||
100 | /** | ||
101 | * Handles a received peer message to link it to its origin tunnel if the peer identity matches. | ||
102 | * (the peer message and the member id can potentially be linked to the tunnel) | ||
103 | * | ||
104 | * TODO: This handling will only check the one given tunnel! | ||
105 | * | ||
106 | * @param room Room of the message | ||
107 | * @param tunnel Receiving connection | ||
108 | * @param message PEER-Message | ||
109 | * @param hash Hash of the message | ||
110 | */ | ||
111 | void | ||
112 | recv_message_peer (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
113 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
114 | |||
115 | /** | ||
116 | * Handles a received id message to change the tunnels linked member id if necessary. | ||
117 | * (the tunnels linked member id will be changed if the sender id is matching) | ||
118 | * | ||
119 | * TODO: This handling will only check the one given tunnel! | ||
120 | * | ||
121 | * @param room Room of the message | ||
122 | * @param tunnel Receiving connection | ||
123 | * @param message ID-Message | ||
124 | * @param hash Hash of the message | ||
125 | */ | ||
126 | void | ||
127 | recv_message_id (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
128 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
129 | |||
130 | /** | ||
131 | * Handles a received miss message. | ||
132 | * @see handle_message_miss() | ||
133 | * | ||
134 | * @param room Room of the message | ||
135 | * @param tunnel Receiving connection | ||
136 | * @param message MISS-Message | ||
137 | * @param hash Hash of the message | ||
138 | */ | ||
139 | void | ||
140 | recv_message_miss (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
141 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
142 | |||
143 | /** | ||
144 | * Handles a received request message by checking for the requested message and forwarding it back | ||
145 | * if the message was found. | ||
146 | * (this can also cause this peer to send a new request instead of only forwarding the received one) | ||
147 | * | ||
148 | * TODO: Requests can cause exponentially more requests! | ||
149 | * | ||
150 | * @param room Room of the message | ||
151 | * @param tunnel Receiving connection | ||
152 | * @param message REQUEST-Message | ||
153 | * @param hash Hash of the message | ||
154 | */ | ||
155 | void | ||
156 | recv_message_request (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
157 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
158 | |||
159 | #endif //GNUNET_SERVICE_MESSENGER_MESSAGE_RECV_H | ||
diff --git a/src/messenger/gnunet-service-messenger_message_send.c b/src/messenger/gnunet-service-messenger_message_send.c new file mode 100644 index 000000000..86cf9b888 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_message_send.c | |||
@@ -0,0 +1,118 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_message_send.c | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "gnunet-service-messenger_message_send.h" | ||
27 | #include "gnunet-service-messenger_message_handle.h" | ||
28 | |||
29 | void | ||
30 | send_message_info (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
31 | struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_MESSENGER_Message *message, | ||
32 | const struct GNUNET_HashCode *hash) | ||
33 | { | ||
34 | if (!tunnel->contact_id) | ||
35 | { | ||
36 | tunnel->contact_id = GNUNET_new(struct GNUNET_ShortHashCode); | ||
37 | |||
38 | GNUNET_memcpy(tunnel->contact_id, &(message->body.info.unique_id), sizeof(struct GNUNET_ShortHashCode)); | ||
39 | } | ||
40 | else | ||
41 | { | ||
42 | disconnect_tunnel (tunnel); | ||
43 | } | ||
44 | } | ||
45 | |||
46 | void | ||
47 | send_message_join (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
48 | struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_MESSENGER_Message *message, | ||
49 | const struct GNUNET_HashCode *hash) | ||
50 | { | ||
51 | handle_message_join (room, tunnel, message, hash); | ||
52 | |||
53 | if (room->peer_message) | ||
54 | { | ||
55 | const struct GNUNET_MESSENGER_Message *peer_message = get_room_message (room, handle, room->peer_message, | ||
56 | GNUNET_NO); | ||
57 | |||
58 | if ((peer_message) && (tunnel)) | ||
59 | { | ||
60 | forward_tunnel_message (tunnel, peer_message, room->peer_message); | ||
61 | } | ||
62 | } | ||
63 | } | ||
64 | |||
65 | void | ||
66 | send_message_leave (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
67 | struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_MESSENGER_Message *message, | ||
68 | const struct GNUNET_HashCode *hash) | ||
69 | { | ||
70 | handle_message_leave (room, tunnel, message, hash); | ||
71 | } | ||
72 | |||
73 | void | ||
74 | send_message_name (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
75 | struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_MESSENGER_Message *message, | ||
76 | const struct GNUNET_HashCode *hash) | ||
77 | { | ||
78 | handle_message_name (room, tunnel, message, hash); | ||
79 | } | ||
80 | |||
81 | void | ||
82 | send_message_key (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
83 | struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_MESSENGER_Message *message, | ||
84 | const struct GNUNET_HashCode *hash) | ||
85 | { | ||
86 | handle_message_key (room, tunnel, message, hash); | ||
87 | } | ||
88 | |||
89 | void | ||
90 | send_message_peer (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
91 | struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_MESSENGER_Message *message, | ||
92 | const struct GNUNET_HashCode *hash) | ||
93 | { | ||
94 | if (!room->peer_message) | ||
95 | { | ||
96 | room->peer_message = GNUNET_new(struct GNUNET_HashCode); | ||
97 | } | ||
98 | |||
99 | GNUNET_memcpy(room->peer_message, hash, sizeof(struct GNUNET_HashCode)); | ||
100 | |||
101 | handle_message_peer (room, tunnel, message, hash); | ||
102 | } | ||
103 | |||
104 | void | ||
105 | send_message_id (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
106 | struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_MESSENGER_Message *message, | ||
107 | const struct GNUNET_HashCode *hash) | ||
108 | { | ||
109 | handle_message_id (room, tunnel, message, hash); | ||
110 | } | ||
111 | |||
112 | void | ||
113 | send_message_miss (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
114 | struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_MESSENGER_Message *message, | ||
115 | const struct GNUNET_HashCode *hash) | ||
116 | { | ||
117 | handle_message_miss (room, tunnel, message, hash); | ||
118 | } | ||
diff --git a/src/messenger/gnunet-service-messenger_message_send.h b/src/messenger/gnunet-service-messenger_message_send.h new file mode 100644 index 000000000..c1096205a --- /dev/null +++ b/src/messenger/gnunet-service-messenger_message_send.h | |||
@@ -0,0 +1,155 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_message_send.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_SERVICE_MESSENGER_MESSAGE_SEND_H | ||
27 | #define GNUNET_SERVICE_MESSENGER_MESSAGE_SEND_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_crypto_lib.h" | ||
31 | |||
32 | #include "gnunet-service-messenger_tunnel.h" | ||
33 | #include "messenger_api_message.h" | ||
34 | |||
35 | /** | ||
36 | * Handles a sent info message to setup a tunnels linked member id. | ||
37 | * (if a tunnel has already got a member id linked to it, the connection will be closed) | ||
38 | * | ||
39 | * @param room Room of the message | ||
40 | * @param handle Sending handle | ||
41 | * @param tunnel Sending connection (may be NULL) | ||
42 | * @param message INFO-Message | ||
43 | * @param hash Hash of the message | ||
44 | */ | ||
45 | void | ||
46 | send_message_info (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
47 | struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_MESSENGER_Message *message, | ||
48 | const struct GNUNET_HashCode *hash); | ||
49 | |||
50 | /** | ||
51 | * Handles a sent join message to ensure growth of the decentralized room structure. | ||
52 | * (if the service provides a peer message for this room currently, it will be forwarded) | ||
53 | * | ||
54 | * @param room Room of the message | ||
55 | * @param handle Sending handle | ||
56 | * @param tunnel Sending connection (may be NULL) | ||
57 | * @param message JOIN-Message | ||
58 | * @param hash Hash of the message | ||
59 | */ | ||
60 | void | ||
61 | send_message_join (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
62 | struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_MESSENGER_Message *message, | ||
63 | const struct GNUNET_HashCode *hash); | ||
64 | |||
65 | /** | ||
66 | * Handles a sent leave message. | ||
67 | * @see handle_message_leave() | ||
68 | * | ||
69 | * @param room Room of the message | ||
70 | * @param handle Sending handle | ||
71 | * @param tunnel Sending connection (may be NULL) | ||
72 | * @param message LEAVE-Message | ||
73 | * @param hash Hash of the message | ||
74 | */ | ||
75 | void | ||
76 | send_message_leave (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
77 | struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_MESSENGER_Message *message, | ||
78 | const struct GNUNET_HashCode *hash); | ||
79 | |||
80 | /** | ||
81 | * Handles a sent name message. | ||
82 | * @see handle_message_name() | ||
83 | * | ||
84 | * @param room Room of the message | ||
85 | * @param handle Sending handle | ||
86 | * @param tunnel Sending connection (may be NULL) | ||
87 | * @param message NAME-Message | ||
88 | * @param hash Hash of the message | ||
89 | */ | ||
90 | void | ||
91 | send_message_name (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
92 | struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_MESSENGER_Message *message, | ||
93 | const struct GNUNET_HashCode *hash); | ||
94 | |||
95 | /** | ||
96 | * Handles a sent key message. | ||
97 | * @see handle_message_key() | ||
98 | * | ||
99 | * @param room Room of the message | ||
100 | * @param handle Sending handle | ||
101 | * @param tunnel Sending connection (may be NULL) | ||
102 | * @param message KEY-Message | ||
103 | * @param hash Hash of the message | ||
104 | */ | ||
105 | void | ||
106 | send_message_key (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
107 | struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_MESSENGER_Message *message, | ||
108 | const struct GNUNET_HashCode *hash); | ||
109 | |||
110 | /** | ||
111 | * Handles a sent peer message to update the rooms peer message of this service. | ||
112 | * (a set peer message indicates this service being a part of the decentralized room structure) | ||
113 | * | ||
114 | * @param room Room of the message | ||
115 | * @param handle Sending handle | ||
116 | * @param tunnel Sending connection (may be NULL) | ||
117 | * @param message PEER-Message | ||
118 | * @param hash Hash of the message | ||
119 | */ | ||
120 | void | ||
121 | send_message_peer (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
122 | struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_MESSENGER_Message *message, | ||
123 | const struct GNUNET_HashCode *hash); | ||
124 | |||
125 | /** | ||
126 | * Handles a sent id message. | ||
127 | * @see handle_message_id() | ||
128 | * | ||
129 | * @param room Room of the message | ||
130 | * @param handle Sending handle | ||
131 | * @param tunnel Sending connection (may be NULL) | ||
132 | * @param message ID-Message | ||
133 | * @param hash Hash of the message | ||
134 | */ | ||
135 | void | ||
136 | send_message_id (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
137 | struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_MESSENGER_Message *message, | ||
138 | const struct GNUNET_HashCode *hash); | ||
139 | |||
140 | /** | ||
141 | * Handles a sent miss message. | ||
142 | * @see handle_message_miss() | ||
143 | * | ||
144 | * @param room Room of the message | ||
145 | * @param handle Sending handle | ||
146 | * @param tunnel Sending connection (may be NULL) | ||
147 | * @param message MISS-Message | ||
148 | * @param hash Hash of the message | ||
149 | */ | ||
150 | void | ||
151 | send_message_miss (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
152 | struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_MESSENGER_Message *message, | ||
153 | const struct GNUNET_HashCode *hash); | ||
154 | |||
155 | #endif //GNUNET_SERVICE_MESSENGER_MESSAGE_SEND_H | ||
diff --git a/src/messenger/gnunet-service-messenger_message_store.c b/src/messenger/gnunet-service-messenger_message_store.c new file mode 100644 index 000000000..5933d6390 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_message_store.c | |||
@@ -0,0 +1,282 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_message_store.c | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "gnunet-service-messenger_message_store.h" | ||
27 | #include "messenger_api_message.h" | ||
28 | |||
29 | void | ||
30 | init_message_store (struct GNUNET_MESSENGER_MessageStore *store) | ||
31 | { | ||
32 | store->storage_messages = NULL; | ||
33 | |||
34 | store->entries = GNUNET_CONTAINER_multihashmap_create (8, GNUNET_NO); | ||
35 | store->messages = GNUNET_CONTAINER_multihashmap_create (8, GNUNET_NO); | ||
36 | } | ||
37 | |||
38 | static int | ||
39 | iterate_destroy_entries (void *cls, const struct GNUNET_HashCode *key, void *value) | ||
40 | { | ||
41 | struct GNUNET_MESSENGER_MessageEntry *entry = value; | ||
42 | |||
43 | GNUNET_free(entry); | ||
44 | |||
45 | return GNUNET_YES; | ||
46 | } | ||
47 | |||
48 | static int | ||
49 | iterate_destroy_messages (void *cls, const struct GNUNET_HashCode *key, void *value) | ||
50 | { | ||
51 | struct GNUNET_MESSENGER_Message *message = value; | ||
52 | |||
53 | destroy_message (message); | ||
54 | |||
55 | return GNUNET_YES; | ||
56 | } | ||
57 | |||
58 | void | ||
59 | clear_message_store (struct GNUNET_MESSENGER_MessageStore *store) | ||
60 | { | ||
61 | if (store->storage_messages) | ||
62 | { | ||
63 | GNUNET_DISK_file_close (store->storage_messages); | ||
64 | |||
65 | store->storage_messages = NULL; | ||
66 | } | ||
67 | |||
68 | GNUNET_CONTAINER_multihashmap_iterate (store->entries, iterate_destroy_entries, NULL); | ||
69 | GNUNET_CONTAINER_multihashmap_iterate (store->messages, iterate_destroy_messages, NULL); | ||
70 | |||
71 | GNUNET_CONTAINER_multihashmap_destroy (store->entries); | ||
72 | GNUNET_CONTAINER_multihashmap_destroy (store->messages); | ||
73 | } | ||
74 | |||
75 | struct GNUNET_MESSENGER_MessageEntryStorage | ||
76 | { | ||
77 | struct GNUNET_HashCode hash; | ||
78 | struct GNUNET_MESSENGER_MessageEntry entry; | ||
79 | }; | ||
80 | |||
81 | void | ||
82 | load_message_store (struct GNUNET_MESSENGER_MessageStore *store, const char *directory) | ||
83 | { | ||
84 | enum GNUNET_DISK_AccessPermissions permission = (GNUNET_DISK_PERM_USER_READ | GNUNET_DISK_PERM_USER_WRITE); | ||
85 | |||
86 | if (store->storage_messages) | ||
87 | GNUNET_DISK_file_close (store->storage_messages); | ||
88 | |||
89 | char *filename; | ||
90 | GNUNET_asprintf (&filename, "%s%s", directory, "messages.store"); | ||
91 | |||
92 | if (GNUNET_YES == GNUNET_DISK_file_test (filename)) | ||
93 | store->storage_messages = GNUNET_DISK_file_open (filename, GNUNET_DISK_OPEN_READ, permission); | ||
94 | else | ||
95 | store->storage_messages = NULL; | ||
96 | |||
97 | GNUNET_free(filename); | ||
98 | |||
99 | if (!store->storage_messages) | ||
100 | return; | ||
101 | |||
102 | GNUNET_asprintf (&filename, "%s%s", directory, "entries.store"); | ||
103 | |||
104 | if (GNUNET_YES != GNUNET_DISK_file_test (filename)) | ||
105 | goto free_filename; | ||
106 | |||
107 | struct GNUNET_DISK_FileHandle *entries = GNUNET_DISK_file_open (filename, GNUNET_DISK_OPEN_READ, permission); | ||
108 | |||
109 | if (!entries) | ||
110 | goto free_filename; | ||
111 | |||
112 | struct GNUNET_MESSENGER_MessageEntryStorage storage; | ||
113 | struct GNUNET_MESSENGER_MessageEntry *entry; | ||
114 | |||
115 | do | ||
116 | { | ||
117 | entry = GNUNET_new(struct GNUNET_MESSENGER_MessageEntry); | ||
118 | |||
119 | if (GNUNET_DISK_file_read (entries, &storage, sizeof(storage)) == sizeof(storage)) | ||
120 | { | ||
121 | GNUNET_memcpy(entry, &(storage.entry), sizeof(*entry)); | ||
122 | |||
123 | if (GNUNET_OK != GNUNET_CONTAINER_multihashmap_put (store->entries, &(storage.hash), entry, | ||
124 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST)) | ||
125 | GNUNET_free(entry); | ||
126 | } | ||
127 | else | ||
128 | { | ||
129 | GNUNET_free(entry); | ||
130 | |||
131 | entry = NULL; | ||
132 | } | ||
133 | } | ||
134 | while (entry); | ||
135 | |||
136 | GNUNET_DISK_file_close (entries); | ||
137 | |||
138 | free_filename: | ||
139 | GNUNET_free(filename); | ||
140 | } | ||
141 | |||
142 | struct GNUNET_MESSENGER_MessageSave | ||
143 | { | ||
144 | struct GNUNET_MESSENGER_MessageStore *store; | ||
145 | |||
146 | struct GNUNET_DISK_FileHandle *storage_entries; | ||
147 | }; | ||
148 | |||
149 | static int | ||
150 | iterate_save_messages (void *cls, const struct GNUNET_HashCode *key, void *value) | ||
151 | { | ||
152 | struct GNUNET_MESSENGER_MessageSave *save = cls; | ||
153 | |||
154 | if (GNUNET_NO != GNUNET_CONTAINER_multihashmap_contains (save->store->entries, key)) | ||
155 | return GNUNET_YES; | ||
156 | |||
157 | struct GNUNET_MESSENGER_Message *message = value; | ||
158 | struct GNUNET_MESSENGER_MessageEntryStorage storage; | ||
159 | |||
160 | GNUNET_memcpy(&(storage.hash), key, sizeof(storage.hash)); | ||
161 | |||
162 | storage.entry.length = get_message_size (message); | ||
163 | storage.entry.offset = GNUNET_DISK_file_seek (save->store->storage_messages, 0, GNUNET_DISK_SEEK_END); | ||
164 | |||
165 | if ((GNUNET_SYSERR == storage.entry.offset) || | ||
166 | (sizeof(storage) != GNUNET_DISK_file_write (save->storage_entries, &storage, sizeof(storage)))) | ||
167 | return GNUNET_YES; | ||
168 | |||
169 | char *buffer = GNUNET_malloc(storage.entry.length); | ||
170 | |||
171 | encode_message (message, storage.entry.length, buffer); | ||
172 | |||
173 | GNUNET_DISK_file_write (save->store->storage_messages, buffer, storage.entry.length); | ||
174 | |||
175 | GNUNET_free(buffer); | ||
176 | |||
177 | return GNUNET_YES; | ||
178 | } | ||
179 | |||
180 | void | ||
181 | save_message_store (struct GNUNET_MESSENGER_MessageStore *store, const char *directory) | ||
182 | { | ||
183 | struct GNUNET_MESSENGER_MessageSave save; | ||
184 | |||
185 | enum GNUNET_DISK_AccessPermissions permission = (GNUNET_DISK_PERM_USER_READ | GNUNET_DISK_PERM_USER_WRITE); | ||
186 | |||
187 | char *filename; | ||
188 | GNUNET_asprintf (&filename, "%s%s", directory, "entries.store"); | ||
189 | |||
190 | save.store = store; | ||
191 | save.storage_entries = GNUNET_DISK_file_open (filename, GNUNET_DISK_OPEN_WRITE | GNUNET_DISK_OPEN_CREATE, permission); | ||
192 | |||
193 | GNUNET_free(filename); | ||
194 | |||
195 | if (!save.storage_entries) | ||
196 | return; | ||
197 | |||
198 | if (GNUNET_SYSERR == GNUNET_DISK_file_seek (save.storage_entries, 0, GNUNET_DISK_SEEK_END)) | ||
199 | goto close_entries; | ||
200 | |||
201 | if (store->storage_messages) | ||
202 | GNUNET_DISK_file_close (store->storage_messages); | ||
203 | |||
204 | GNUNET_asprintf (&filename, "%s%s", directory, "messages.store"); | ||
205 | |||
206 | store->storage_messages = GNUNET_DISK_file_open (filename, GNUNET_DISK_OPEN_READWRITE | GNUNET_DISK_OPEN_CREATE, | ||
207 | permission); | ||
208 | |||
209 | GNUNET_free(filename); | ||
210 | |||
211 | if (store->storage_messages) | ||
212 | { | ||
213 | GNUNET_CONTAINER_multihashmap_iterate (store->messages, iterate_save_messages, &save); | ||
214 | |||
215 | GNUNET_DISK_file_sync (store->storage_messages); | ||
216 | GNUNET_DISK_file_sync (save.storage_entries); | ||
217 | } | ||
218 | |||
219 | close_entries: | ||
220 | GNUNET_DISK_file_close (save.storage_entries); | ||
221 | } | ||
222 | |||
223 | int | ||
224 | contains_store_message (struct GNUNET_MESSENGER_MessageStore *store, const struct GNUNET_HashCode *hash) | ||
225 | { | ||
226 | if (GNUNET_YES == GNUNET_CONTAINER_multihashmap_contains (store->messages, hash)) | ||
227 | return GNUNET_YES; | ||
228 | |||
229 | return GNUNET_CONTAINER_multihashmap_contains (store->entries, hash); | ||
230 | } | ||
231 | |||
232 | const struct GNUNET_MESSENGER_Message* | ||
233 | get_store_message (struct GNUNET_MESSENGER_MessageStore *store, const struct GNUNET_HashCode *hash) | ||
234 | { | ||
235 | struct GNUNET_MESSENGER_Message *message = GNUNET_CONTAINER_multihashmap_get (store->messages, hash); | ||
236 | |||
237 | if (message) | ||
238 | return message; | ||
239 | |||
240 | if (!store->storage_messages) | ||
241 | return NULL; | ||
242 | |||
243 | const struct GNUNET_MESSENGER_MessageEntry *entry = GNUNET_CONTAINER_multihashmap_get (store->entries, hash); | ||
244 | |||
245 | if (!entry) | ||
246 | return NULL; | ||
247 | |||
248 | if (entry->offset != GNUNET_DISK_file_seek (store->storage_messages, entry->offset, GNUNET_DISK_SEEK_SET)) | ||
249 | return message; | ||
250 | |||
251 | char *buffer = GNUNET_malloc(entry->length); | ||
252 | |||
253 | if (GNUNET_DISK_file_read (store->storage_messages, buffer, entry->length) != entry->length) | ||
254 | goto free_buffer; | ||
255 | |||
256 | |||
257 | message = create_message (GNUNET_MESSENGER_KIND_UNKNOWN); | ||
258 | |||
259 | if ((GNUNET_YES != decode_message (message, entry->length, buffer)) || (GNUNET_OK | ||
260 | != GNUNET_CONTAINER_multihashmap_put (store->messages, hash, message, | ||
261 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST))) | ||
262 | { | ||
263 | destroy_message (message); | ||
264 | |||
265 | message = NULL; | ||
266 | |||
267 | GNUNET_CONTAINER_multihashmap_remove (store->entries, hash, entry); | ||
268 | } | ||
269 | |||
270 | free_buffer: | ||
271 | GNUNET_free(buffer); | ||
272 | |||
273 | return message; | ||
274 | } | ||
275 | |||
276 | int | ||
277 | put_store_message (struct GNUNET_MESSENGER_MessageStore *store, const struct GNUNET_HashCode *hash, | ||
278 | struct GNUNET_MESSENGER_Message *message) | ||
279 | { | ||
280 | return GNUNET_CONTAINER_multihashmap_put (store->messages, hash, message, | ||
281 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST); | ||
282 | } | ||
diff --git a/src/messenger/gnunet-service-messenger_message_store.h b/src/messenger/gnunet-service-messenger_message_store.h new file mode 100644 index 000000000..e58459b21 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_message_store.h | |||
@@ -0,0 +1,120 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_message_store.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_SERVICE_MESSENGER_MESSAGE_STORE_H | ||
27 | #define GNUNET_SERVICE_MESSENGER_MESSAGE_STORE_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_container_lib.h" | ||
31 | #include "gnunet_disk_lib.h" | ||
32 | |||
33 | struct GNUNET_MESSENGER_MessageEntry | ||
34 | { | ||
35 | off_t offset; | ||
36 | uint16_t length; | ||
37 | }; | ||
38 | |||
39 | struct GNUNET_MESSENGER_MessageStore | ||
40 | { | ||
41 | struct GNUNET_DISK_FileHandle *storage_messages; | ||
42 | |||
43 | struct GNUNET_CONTAINER_MultiHashMap *entries; | ||
44 | struct GNUNET_CONTAINER_MultiHashMap *messages; | ||
45 | }; | ||
46 | |||
47 | /** | ||
48 | * Initializes a message store as fully empty. | ||
49 | * | ||
50 | * @param store Message store | ||
51 | */ | ||
52 | void | ||
53 | init_message_store (struct GNUNET_MESSENGER_MessageStore *store); | ||
54 | |||
55 | /** | ||
56 | * Clears a message store, wipes its content and deallocates its memory. | ||
57 | * | ||
58 | * @param store Message store | ||
59 | */ | ||
60 | void | ||
61 | clear_message_store (struct GNUNET_MESSENGER_MessageStore *store); | ||
62 | |||
63 | /** | ||
64 | * Loads messages from a directory into a message store. | ||
65 | * | ||
66 | * @param store Message store | ||
67 | * @param directory Path to a directory | ||
68 | */ | ||
69 | void | ||
70 | load_message_store (struct GNUNET_MESSENGER_MessageStore *store, const char *directory); | ||
71 | |||
72 | /** | ||
73 | * Saves messages from a message store into a directory. | ||
74 | * | ||
75 | * @param store Message store | ||
76 | * @param directory Path to a directory | ||
77 | */ | ||
78 | void | ||
79 | save_message_store (struct GNUNET_MESSENGER_MessageStore *store, const char *directory); | ||
80 | |||
81 | /** | ||
82 | * Checks if a message matching a given <i>hash</i> is stored in a message store. The function returns | ||
83 | * GNUNET_YES if a match is found, GNUNET_NO otherwise. | ||
84 | * | ||
85 | * The message has not to be loaded from disk into memory for this check! | ||
86 | * | ||
87 | * @param store Message store | ||
88 | * @param hash Hash of message | ||
89 | * @return GNUNET_YES on match, otherwise GNUNET_NO | ||
90 | */ | ||
91 | int | ||
92 | contains_store_message (struct GNUNET_MESSENGER_MessageStore *store, const struct GNUNET_HashCode *hash); | ||
93 | |||
94 | /** | ||
95 | * Returns the message from a message store matching a given <i>hash</i>. If no matching message is found, | ||
96 | * NULL gets returned. | ||
97 | * | ||
98 | * This function requires the message to be loaded into memory! | ||
99 | * @see contains_store_message() | ||
100 | * | ||
101 | * @param store Message store | ||
102 | * @param hash Hash of message | ||
103 | * @return Message or NULL | ||
104 | */ | ||
105 | const struct GNUNET_MESSENGER_Message* | ||
106 | get_store_message (struct GNUNET_MESSENGER_MessageStore *store, const struct GNUNET_HashCode *hash); | ||
107 | |||
108 | /** | ||
109 | * Stores a message into the message store. The result indicates if the operation was successful. | ||
110 | * | ||
111 | * @param store Message store | ||
112 | * @param hash Hash of message | ||
113 | * @param message Message | ||
114 | * @return GNUNET_OK on success, otherwise GNUNET_NO | ||
115 | */ | ||
116 | int | ||
117 | put_store_message (struct GNUNET_MESSENGER_MessageStore *store, const struct GNUNET_HashCode *hash, | ||
118 | struct GNUNET_MESSENGER_Message *message); | ||
119 | |||
120 | #endif //GNUNET_SERVICE_MESSENGER_MESSAGE_STORE_H | ||
diff --git a/src/messenger/gnunet-service-messenger_room.c b/src/messenger/gnunet-service-messenger_room.c new file mode 100644 index 000000000..7383e1d20 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_room.c | |||
@@ -0,0 +1,1051 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_room.c | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "gnunet-service-messenger_room.h" | ||
27 | |||
28 | #include "gnunet-service-messenger_message_kind.h" | ||
29 | |||
30 | #include "gnunet-service-messenger_service.h" | ||
31 | #include "gnunet-service-messenger_util.h" | ||
32 | |||
33 | static void | ||
34 | idle_request_room_messages (void *cls); | ||
35 | |||
36 | struct GNUNET_MESSENGER_SrvRoom* | ||
37 | create_room (struct GNUNET_MESSENGER_SrvHandle *handle, const struct GNUNET_HashCode *key) | ||
38 | { | ||
39 | GNUNET_assert((handle) && (key)); | ||
40 | |||
41 | struct GNUNET_MESSENGER_SrvRoom *room = GNUNET_new(struct GNUNET_MESSENGER_SrvRoom); | ||
42 | |||
43 | room->service = handle->service; | ||
44 | room->host = handle; | ||
45 | room->port = NULL; | ||
46 | |||
47 | GNUNET_memcpy(&(room->key), key, sizeof(struct GNUNET_HashCode)); | ||
48 | |||
49 | room->tunnels = GNUNET_CONTAINER_multipeermap_create (8, GNUNET_NO); | ||
50 | room->members = GNUNET_CONTAINER_multishortmap_create (8, GNUNET_NO); | ||
51 | room->member_infos = GNUNET_CONTAINER_multishortmap_create (8, GNUNET_NO); | ||
52 | |||
53 | init_message_store (&(room->store)); | ||
54 | room->requested = GNUNET_CONTAINER_multihashmap_create (8, GNUNET_NO); | ||
55 | |||
56 | init_list_tunnels (&(room->basement)); | ||
57 | init_list_messages (&(room->last_messages)); | ||
58 | |||
59 | room->peer_message = NULL; | ||
60 | |||
61 | init_list_messages (&(room->handling)); | ||
62 | room->idle = NULL; | ||
63 | |||
64 | room->strict_access = GNUNET_NO; | ||
65 | |||
66 | if (room->service->dir) | ||
67 | load_service_room_and_messages (room->service, room); | ||
68 | |||
69 | room->idle = GNUNET_SCHEDULER_add_with_priority (GNUNET_SCHEDULER_PRIORITY_IDLE, idle_request_room_messages, room); | ||
70 | |||
71 | return room; | ||
72 | } | ||
73 | |||
74 | static int | ||
75 | iterate_destroy_tunnels (void *cls, const struct GNUNET_PeerIdentity *key, void *value) | ||
76 | { | ||
77 | struct GNUNET_MESSENGER_SrvTunnel *tunnel = value; | ||
78 | destroy_tunnel (tunnel); | ||
79 | return GNUNET_YES; | ||
80 | } | ||
81 | |||
82 | static int | ||
83 | iterate_clear_members (void *cls, const struct GNUNET_ShortHashCode *key, void *value) | ||
84 | { | ||
85 | struct GNUNET_MESSENGER_SrvContact *contact = value; | ||
86 | |||
87 | if (GNUNET_YES == decrease_contact_rc (contact)) | ||
88 | { | ||
89 | struct GNUNET_MESSENGER_SrvRoom *room = cls; | ||
90 | |||
91 | const struct GNUNET_HashCode *id = get_contact_id_from_key (contact); | ||
92 | |||
93 | if (GNUNET_YES == GNUNET_CONTAINER_multihashmap_remove (room->service->contacts, id, contact)) | ||
94 | destroy_contact (contact); | ||
95 | } | ||
96 | |||
97 | return GNUNET_YES; | ||
98 | } | ||
99 | |||
100 | static int | ||
101 | iterate_destroy_member_infos (void *cls, const struct GNUNET_ShortHashCode *key, void *value) | ||
102 | { | ||
103 | struct GNUNET_MESSENGER_MemberInfo *info = value; | ||
104 | |||
105 | clear_list_messages (&(info->session_messages)); | ||
106 | |||
107 | GNUNET_free(info); | ||
108 | return GNUNET_YES; | ||
109 | } | ||
110 | |||
111 | void | ||
112 | destroy_room (struct GNUNET_MESSENGER_SrvRoom *room) | ||
113 | { | ||
114 | GNUNET_assert(room); | ||
115 | |||
116 | if (room->idle) | ||
117 | { | ||
118 | GNUNET_SCHEDULER_cancel (room->idle); | ||
119 | |||
120 | room->idle = NULL; | ||
121 | } | ||
122 | |||
123 | if (room->port) | ||
124 | GNUNET_CADET_close_port (room->port); | ||
125 | |||
126 | merge_room_last_messages (room, room->host); | ||
127 | |||
128 | GNUNET_CONTAINER_multipeermap_iterate (room->tunnels, iterate_destroy_tunnels, | ||
129 | NULL); | ||
130 | |||
131 | handle_room_messages (room); | ||
132 | |||
133 | if (room->service->dir) | ||
134 | save_service_room_and_messages (room->service, room); | ||
135 | |||
136 | GNUNET_CONTAINER_multishortmap_iterate (room->members, iterate_clear_members, room); | ||
137 | GNUNET_CONTAINER_multishortmap_iterate (room->member_infos, iterate_destroy_member_infos, NULL); | ||
138 | |||
139 | clear_message_store (&(room->store)); | ||
140 | |||
141 | GNUNET_CONTAINER_multihashmap_destroy (room->requested); | ||
142 | |||
143 | GNUNET_CONTAINER_multipeermap_destroy (room->tunnels); | ||
144 | GNUNET_CONTAINER_multishortmap_destroy (room->members); | ||
145 | GNUNET_CONTAINER_multishortmap_destroy (room->member_infos); | ||
146 | |||
147 | clear_list_tunnels (&(room->basement)); | ||
148 | clear_list_messages (&(room->last_messages)); | ||
149 | |||
150 | if (room->peer_message) | ||
151 | GNUNET_free(room->peer_message); | ||
152 | |||
153 | GNUNET_free(room); | ||
154 | } | ||
155 | |||
156 | struct GNUNET_MESSENGER_SrvContact* | ||
157 | get_room_contact (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_ShortHashCode *id) | ||
158 | { | ||
159 | GNUNET_assert((room) && (room->members)); | ||
160 | |||
161 | return GNUNET_CONTAINER_multishortmap_get (room->members, id); | ||
162 | } | ||
163 | |||
164 | void | ||
165 | add_room_contact (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_ShortHashCode *id, | ||
166 | const struct GNUNET_IDENTITY_PublicKey *pubkey) | ||
167 | { | ||
168 | struct GNUNET_MESSENGER_SrvContact *contact = get_service_contact_by_pubkey (room->service, pubkey); | ||
169 | |||
170 | if (GNUNET_OK == GNUNET_CONTAINER_multishortmap_put (room->members, id, contact, | ||
171 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST)) | ||
172 | increase_contact_rc (contact); | ||
173 | } | ||
174 | |||
175 | struct GNUNET_MESSENGER_MemberInfo* | ||
176 | get_room_member_info (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_ShortHashCode *id) | ||
177 | { | ||
178 | GNUNET_assert((room) && (room->member_infos)); | ||
179 | |||
180 | return GNUNET_CONTAINER_multishortmap_get (room->member_infos, id); | ||
181 | } | ||
182 | |||
183 | struct GNUNET_ShortHashCode* | ||
184 | generate_room_member_id (const struct GNUNET_MESSENGER_SrvRoom *room) | ||
185 | { | ||
186 | struct GNUNET_ShortHashCode *unique_id = GNUNET_new(struct GNUNET_ShortHashCode); | ||
187 | |||
188 | GNUNET_assert(room); | ||
189 | |||
190 | if (GNUNET_YES == generate_free_member_id (unique_id, room->members)) | ||
191 | return unique_id; | ||
192 | else | ||
193 | { | ||
194 | GNUNET_free(unique_id); | ||
195 | return NULL; | ||
196 | } | ||
197 | } | ||
198 | |||
199 | const struct GNUNET_ShortHashCode* | ||
200 | get_room_host_id (const struct GNUNET_MESSENGER_SrvRoom *room) | ||
201 | { | ||
202 | GNUNET_assert(room); | ||
203 | |||
204 | return get_handle_member_id (room->host, &(room->key)); | ||
205 | } | ||
206 | |||
207 | void | ||
208 | change_room_host_id (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_ShortHashCode *unique_id) | ||
209 | { | ||
210 | GNUNET_assert(room); | ||
211 | |||
212 | change_handle_member_id (room->host, &(room->key), unique_id); | ||
213 | } | ||
214 | |||
215 | static int | ||
216 | send_room_info (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
217 | struct GNUNET_MESSENGER_SrvTunnel *tunnel) | ||
218 | { | ||
219 | if (!handle) | ||
220 | return GNUNET_NO; | ||
221 | |||
222 | merge_room_last_messages (room, handle); | ||
223 | |||
224 | if (!is_tunnel_connected (tunnel)) | ||
225 | return GNUNET_NO; | ||
226 | |||
227 | struct GNUNET_MESSENGER_Message *message = create_message_info (get_handle_ego(handle), room->members); | ||
228 | |||
229 | if (!message) | ||
230 | return GNUNET_NO; | ||
231 | |||
232 | if ((tunnel->peer_message) && (tunnel->contact_id)) | ||
233 | { | ||
234 | GNUNET_memcpy(&(message->body.info.unique_id), &(tunnel->contact_id), sizeof(struct GNUNET_ShortHashCode)); | ||
235 | GNUNET_free(tunnel->contact_id); | ||
236 | |||
237 | tunnel->contact_id = NULL; | ||
238 | } | ||
239 | |||
240 | struct GNUNET_HashCode hash; | ||
241 | |||
242 | send_tunnel_message (tunnel, handle, message, &hash); | ||
243 | destroy_message (message); | ||
244 | |||
245 | if (tunnel->contact_id) | ||
246 | { | ||
247 | GNUNET_free(tunnel->contact_id); | ||
248 | |||
249 | tunnel->contact_id = NULL; | ||
250 | } | ||
251 | |||
252 | return GNUNET_YES; | ||
253 | } | ||
254 | |||
255 | static void* | ||
256 | callback_room_connect (void *cls, struct GNUNET_CADET_Channel *channel, const struct GNUNET_PeerIdentity *source) | ||
257 | { | ||
258 | struct GNUNET_MESSENGER_SrvRoom *room = cls; | ||
259 | |||
260 | struct GNUNET_MESSENGER_SrvTunnel *tunnel = GNUNET_CONTAINER_multipeermap_get (room->tunnels, source); | ||
261 | |||
262 | if (tunnel) | ||
263 | { | ||
264 | if (GNUNET_YES == bind_tunnel (tunnel, channel)) | ||
265 | { | ||
266 | if (GNUNET_YES == send_room_info (room, room->host, tunnel)) | ||
267 | return tunnel; | ||
268 | else | ||
269 | { | ||
270 | disconnect_tunnel (tunnel); | ||
271 | return NULL; | ||
272 | } | ||
273 | } | ||
274 | else | ||
275 | { | ||
276 | delayed_disconnect_channel (channel); | ||
277 | return NULL; | ||
278 | } | ||
279 | } | ||
280 | else | ||
281 | { | ||
282 | tunnel = create_tunnel (room, source); | ||
283 | |||
284 | if ((GNUNET_YES == bind_tunnel (tunnel, channel)) && (GNUNET_OK | ||
285 | == GNUNET_CONTAINER_multipeermap_put (room->tunnels, source, tunnel, | ||
286 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST))) | ||
287 | { | ||
288 | if (GNUNET_YES == send_room_info (room, room->host, tunnel)) | ||
289 | return tunnel; | ||
290 | else | ||
291 | { | ||
292 | GNUNET_CONTAINER_multipeermap_remove (room->tunnels, source, tunnel); | ||
293 | |||
294 | disconnect_tunnel (tunnel); | ||
295 | destroy_tunnel (tunnel); | ||
296 | return NULL; | ||
297 | } | ||
298 | } | ||
299 | else | ||
300 | { | ||
301 | tunnel->channel = NULL; | ||
302 | destroy_tunnel (tunnel); | ||
303 | |||
304 | delayed_disconnect_channel (channel); | ||
305 | return NULL; | ||
306 | } | ||
307 | } | ||
308 | } | ||
309 | |||
310 | static int | ||
311 | join_room (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
312 | const struct GNUNET_ShortHashCode *member_id) | ||
313 | { | ||
314 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Joining room: %s (%s)\n", GNUNET_h2s(get_room_key(room)), GNUNET_sh2s(member_id)); | ||
315 | |||
316 | struct GNUNET_MESSENGER_Message *message = create_message_join (get_handle_ego(handle)); | ||
317 | |||
318 | if (!message) | ||
319 | { | ||
320 | GNUNET_log(GNUNET_ERROR_TYPE_ERROR, "Your join message could not be created!\n"); | ||
321 | |||
322 | return GNUNET_NO; | ||
323 | } | ||
324 | |||
325 | struct GNUNET_HashCode hash; | ||
326 | |||
327 | send_room_message (room, handle, message, &hash); | ||
328 | destroy_message (message); | ||
329 | |||
330 | struct GNUNET_MESSENGER_MemberInfo *info = GNUNET_new(struct GNUNET_MESSENGER_MemberInfo); | ||
331 | |||
332 | info->access = GNUNET_MESSENGER_MEMBER_ALLOWED; | ||
333 | init_list_messages (&(info->session_messages)); | ||
334 | |||
335 | if (GNUNET_YES == GNUNET_CONTAINER_multishortmap_put (room->member_infos, member_id, info, | ||
336 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST)) | ||
337 | { | ||
338 | change_handle_member_id (handle, &(room->key), member_id); | ||
339 | |||
340 | add_to_list_messages (&(info->session_messages), &hash); | ||
341 | return GNUNET_YES; | ||
342 | } | ||
343 | else | ||
344 | { | ||
345 | GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "Your member information could not be registered!\n"); | ||
346 | |||
347 | GNUNET_free(info); | ||
348 | return GNUNET_NO; | ||
349 | } | ||
350 | } | ||
351 | |||
352 | static int | ||
353 | join_room_locally (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle) | ||
354 | { | ||
355 | const struct GNUNET_ShortHashCode *member_id = get_handle_member_id (handle, &(room->key)); | ||
356 | |||
357 | struct GNUNET_MESSENGER_MemberInfo *info = GNUNET_CONTAINER_multishortmap_get (room->member_infos, member_id); | ||
358 | |||
359 | if ((!info) && (GNUNET_NO == join_room (room, handle, member_id))) | ||
360 | return GNUNET_NO; | ||
361 | |||
362 | return GNUNET_YES; | ||
363 | } | ||
364 | |||
365 | extern int | ||
366 | check_tunnel_message (void *cls, const struct GNUNET_MessageHeader *header); | ||
367 | extern void | ||
368 | handle_tunnel_message (void *cls, const struct GNUNET_MessageHeader *header); | ||
369 | |||
370 | extern void | ||
371 | callback_tunnel_disconnect (void *cls, const struct GNUNET_CADET_Channel *channel); | ||
372 | |||
373 | int | ||
374 | open_room (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle) | ||
375 | { | ||
376 | if (room->port) | ||
377 | return join_room_locally (room, handle); | ||
378 | |||
379 | struct GNUNET_CADET_Handle *cadet = get_room_cadet (room); | ||
380 | struct GNUNET_HashCode *key = get_room_key (room); | ||
381 | |||
382 | struct GNUNET_MQ_MessageHandler handlers[] = { GNUNET_MQ_hd_var_size(tunnel_message, GNUNET_MESSAGE_TYPE_CADET_CLI, | ||
383 | struct GNUNET_MessageHeader, NULL), | ||
384 | GNUNET_MQ_handler_end() }; | ||
385 | |||
386 | room->port = GNUNET_CADET_open_port (cadet, key, callback_room_connect, room, NULL, | ||
387 | callback_tunnel_disconnect, handlers); | ||
388 | |||
389 | const struct GNUNET_ShortHashCode *member_id = get_handle_member_id (handle, &(room->key)); | ||
390 | |||
391 | struct GNUNET_MESSENGER_MemberInfo *info = GNUNET_CONTAINER_multishortmap_get (room->member_infos, member_id); | ||
392 | |||
393 | if ((!info) && (GNUNET_NO == join_room (room, handle, member_id)) && (room->port)) | ||
394 | { | ||
395 | GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "You could not join the room, therefore it keeps closed!\n"); | ||
396 | |||
397 | GNUNET_CADET_close_port (room->port); | ||
398 | room->port = NULL; | ||
399 | |||
400 | return GNUNET_NO; | ||
401 | } | ||
402 | |||
403 | struct GNUNET_MESSENGER_Message *message = create_message_peer (room->service); | ||
404 | |||
405 | if (message) | ||
406 | { | ||
407 | struct GNUNET_HashCode hash; | ||
408 | |||
409 | send_room_message (room, handle, message, &hash); | ||
410 | destroy_message (message); | ||
411 | } | ||
412 | |||
413 | return (room->port ? GNUNET_YES : GNUNET_NO); | ||
414 | } | ||
415 | |||
416 | int | ||
417 | entry_room_at (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
418 | const struct GNUNET_PeerIdentity *door) | ||
419 | { | ||
420 | if (room->peer_message) | ||
421 | { | ||
422 | const struct GNUNET_MESSENGER_Message *msg = get_room_message (room, handle, room->peer_message, GNUNET_NO); | ||
423 | |||
424 | if (0 == GNUNET_memcmp(&(msg->body.peer.peer), door)) | ||
425 | return join_room_locally (room, handle); | ||
426 | } | ||
427 | |||
428 | struct GNUNET_MESSENGER_SrvTunnel *tunnel = GNUNET_CONTAINER_multipeermap_get (room->tunnels, door); | ||
429 | |||
430 | if (tunnel) | ||
431 | { | ||
432 | switch (connect_tunnel (tunnel)) | ||
433 | { | ||
434 | case GNUNET_YES: | ||
435 | return GNUNET_YES; | ||
436 | case GNUNET_NO: | ||
437 | return join_room_locally (room, handle); | ||
438 | default: | ||
439 | return GNUNET_NO; | ||
440 | } | ||
441 | } | ||
442 | |||
443 | tunnel = create_tunnel (room, door); | ||
444 | |||
445 | if ((GNUNET_YES == connect_tunnel (tunnel)) && | ||
446 | (GNUNET_OK == GNUNET_CONTAINER_multipeermap_put (room->tunnels, door, tunnel, | ||
447 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST))) | ||
448 | return GNUNET_YES; | ||
449 | else | ||
450 | { | ||
451 | GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "You could not connect to that door!\n"); | ||
452 | |||
453 | destroy_tunnel (tunnel); | ||
454 | return GNUNET_NO; | ||
455 | } | ||
456 | } | ||
457 | |||
458 | struct GNUNET_MESSENGER_SrvTunnelFinder | ||
459 | { | ||
460 | const struct GNUNET_ShortHashCode *needle; | ||
461 | struct GNUNET_MESSENGER_SrvTunnel *tunnel; | ||
462 | }; | ||
463 | |||
464 | static int | ||
465 | iterate_find_tunnel (void *cls, const struct GNUNET_PeerIdentity *peer, void *value) | ||
466 | { | ||
467 | struct GNUNET_MESSENGER_SrvTunnel *tunnel = value; | ||
468 | struct GNUNET_MESSENGER_SrvTunnelFinder *finder = cls; | ||
469 | |||
470 | if ((tunnel->contact_id) && (0 == GNUNET_memcmp(tunnel->contact_id, finder->needle))) | ||
471 | { | ||
472 | finder->tunnel = tunnel; | ||
473 | return GNUNET_NO; | ||
474 | } | ||
475 | |||
476 | return GNUNET_YES; | ||
477 | } | ||
478 | |||
479 | struct GNUNET_MESSENGER_SrvTunnel* | ||
480 | find_room_tunnel_to (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_ShortHashCode *contact_id) | ||
481 | { | ||
482 | struct GNUNET_MESSENGER_SrvTunnelFinder finder; | ||
483 | |||
484 | finder.needle = contact_id; | ||
485 | finder.tunnel = NULL; | ||
486 | |||
487 | GNUNET_CONTAINER_multipeermap_iterate (room->tunnels, iterate_find_tunnel, &finder); | ||
488 | |||
489 | return finder.tunnel; | ||
490 | } | ||
491 | |||
492 | struct GNUNET_MQ_Envelope* | ||
493 | pack_room_message (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
494 | struct GNUNET_MESSENGER_Message *message, struct GNUNET_HashCode *hash, int mode) | ||
495 | { | ||
496 | message->header.timestamp = GNUNET_TIME_absolute_hton (GNUNET_TIME_absolute_get ()); | ||
497 | |||
498 | const struct GNUNET_ShortHashCode *id = get_handle_member_id (handle, &(room->key)); | ||
499 | |||
500 | GNUNET_assert(id); | ||
501 | |||
502 | GNUNET_memcpy(&(message->header.sender_id), id, sizeof(struct GNUNET_ShortHashCode)); | ||
503 | |||
504 | if (room->last_messages.head) | ||
505 | GNUNET_memcpy(&(message->header.previous), &(room->last_messages.head->hash), sizeof(struct GNUNET_HashCode)); | ||
506 | else | ||
507 | memset (&(message->header.previous), 0, sizeof(struct GNUNET_HashCode)); | ||
508 | |||
509 | return pack_message (message, hash, get_handle_ego (handle), mode); | ||
510 | } | ||
511 | |||
512 | struct GNUNET_MESSENGER_ClosureSendRoom | ||
513 | { | ||
514 | struct GNUNET_MESSENGER_SrvRoom *room; | ||
515 | struct GNUNET_MESSENGER_SrvHandle *handle; | ||
516 | struct GNUNET_MESSENGER_SrvTunnel *exclude; | ||
517 | struct GNUNET_MESSENGER_Message *message; | ||
518 | struct GNUNET_HashCode *hash; | ||
519 | int packed; | ||
520 | }; | ||
521 | |||
522 | static int | ||
523 | iterate_send_room_message (void *cls, const struct GNUNET_PeerIdentity *key, void *value) | ||
524 | { | ||
525 | struct GNUNET_MESSENGER_SrvTunnel *tunnel = value; | ||
526 | |||
527 | if ((!is_tunnel_connected (tunnel)) || (!tunnel->contact_id)) | ||
528 | return GNUNET_YES; | ||
529 | |||
530 | struct GNUNET_MESSENGER_ClosureSendRoom *closure = cls; | ||
531 | |||
532 | if (tunnel == closure->exclude) | ||
533 | return GNUNET_YES; | ||
534 | |||
535 | struct GNUNET_MQ_Envelope *env = NULL; | ||
536 | |||
537 | if (closure->packed == GNUNET_NO) | ||
538 | { | ||
539 | env = pack_room_message (closure->room, closure->handle, closure->message, closure->hash, | ||
540 | GNUNET_MESSENGER_PACK_MODE_ENVELOPE); | ||
541 | |||
542 | if (env) | ||
543 | { | ||
544 | closure->message = copy_message (closure->message); | ||
545 | closure->packed = GNUNET_YES; | ||
546 | } | ||
547 | } | ||
548 | else | ||
549 | { | ||
550 | env = pack_message (closure->message, NULL, NULL, | ||
551 | GNUNET_MESSENGER_PACK_MODE_ENVELOPE); | ||
552 | } | ||
553 | |||
554 | if (env) | ||
555 | send_tunnel_envelope (tunnel, closure->handle, env, closure->message, closure->hash); | ||
556 | |||
557 | return GNUNET_YES; | ||
558 | } | ||
559 | |||
560 | void | ||
561 | callback_room_sent (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, void *cls, | ||
562 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
563 | |||
564 | void | ||
565 | send_room_message (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
566 | struct GNUNET_MESSENGER_Message *message, struct GNUNET_HashCode *hash) | ||
567 | { | ||
568 | struct GNUNET_MESSENGER_ClosureSendRoom closure; | ||
569 | |||
570 | closure.room = room; | ||
571 | closure.handle = handle; | ||
572 | closure.exclude = NULL; | ||
573 | closure.message = message; | ||
574 | closure.hash = hash; | ||
575 | closure.packed = GNUNET_NO; | ||
576 | |||
577 | GNUNET_CONTAINER_multipeermap_iterate (room->tunnels, iterate_send_room_message, &closure); | ||
578 | |||
579 | if ((GNUNET_NO == closure.packed) && (closure.message == message)) | ||
580 | { | ||
581 | pack_room_message (room, handle, message, hash, | ||
582 | GNUNET_MESSENGER_PACK_MODE_UNKNOWN); | ||
583 | |||
584 | callback_room_sent (room, handle, NULL, copy_message (message), hash); | ||
585 | } | ||
586 | } | ||
587 | |||
588 | void | ||
589 | send_room_message_ext (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
590 | struct GNUNET_MESSENGER_Message *message, struct GNUNET_HashCode *hash, | ||
591 | struct GNUNET_MESSENGER_SrvTunnel *tunnel) | ||
592 | { | ||
593 | struct GNUNET_MESSENGER_ClosureSendRoom closure; | ||
594 | |||
595 | closure.room = room; | ||
596 | closure.handle = handle; | ||
597 | closure.exclude = tunnel; | ||
598 | closure.message = message; | ||
599 | closure.hash = hash; | ||
600 | closure.packed = GNUNET_NO; | ||
601 | |||
602 | GNUNET_CONTAINER_multipeermap_iterate (room->tunnels, iterate_send_room_message, &closure); | ||
603 | |||
604 | if ((GNUNET_NO == closure.packed) && (closure.message == message)) | ||
605 | { | ||
606 | pack_room_message (room, handle, message, hash, | ||
607 | GNUNET_MESSENGER_PACK_MODE_UNKNOWN); | ||
608 | |||
609 | callback_room_sent (room, handle, NULL, copy_message (message), hash); | ||
610 | } | ||
611 | } | ||
612 | |||
613 | void | ||
614 | forward_room_message (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
615 | const struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
616 | { | ||
617 | struct GNUNET_MESSENGER_ClosureSendRoom closure; | ||
618 | struct GNUNET_HashCode message_hash; | ||
619 | |||
620 | GNUNET_memcpy(&message_hash, hash, sizeof(struct GNUNET_HashCode)); | ||
621 | |||
622 | closure.room = room; | ||
623 | closure.handle = NULL; | ||
624 | closure.exclude = tunnel; | ||
625 | closure.message = copy_message (message); | ||
626 | closure.hash = &message_hash; | ||
627 | closure.packed = GNUNET_YES; | ||
628 | |||
629 | GNUNET_CONTAINER_multipeermap_iterate (room->tunnels, iterate_send_room_message, &closure); | ||
630 | } | ||
631 | |||
632 | void | ||
633 | merge_room_last_messages (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle) | ||
634 | { | ||
635 | if (!handle) | ||
636 | return; | ||
637 | |||
638 | if (!room->last_messages.head) | ||
639 | return; | ||
640 | |||
641 | while (room->last_messages.head != room->last_messages.tail) | ||
642 | { | ||
643 | struct GNUNET_MESSENGER_ListMessage *element = room->last_messages.tail; | ||
644 | |||
645 | struct GNUNET_MESSENGER_Message *message = create_message_merge (&(element->hash)); | ||
646 | |||
647 | if (message) | ||
648 | { | ||
649 | struct GNUNET_HashCode hash; | ||
650 | |||
651 | send_room_message (room, handle, message, &hash); | ||
652 | destroy_message (message); | ||
653 | } | ||
654 | |||
655 | if (element->prev) | ||
656 | GNUNET_CONTAINER_DLL_remove(room->last_messages.head, room->last_messages.tail, element); | ||
657 | } | ||
658 | } | ||
659 | |||
660 | struct GNUNET_CADET_Handle* | ||
661 | get_room_cadet (struct GNUNET_MESSENGER_SrvRoom *room) | ||
662 | { | ||
663 | return room->service->cadet; | ||
664 | } | ||
665 | |||
666 | struct GNUNET_HashCode* | ||
667 | get_room_key (struct GNUNET_MESSENGER_SrvRoom *room) | ||
668 | { | ||
669 | return &(room->key); | ||
670 | } | ||
671 | |||
672 | const struct GNUNET_MESSENGER_SrvTunnel* | ||
673 | get_room_tunnel (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_PeerIdentity *peer) | ||
674 | { | ||
675 | return GNUNET_CONTAINER_multipeermap_get (room->tunnels, peer); | ||
676 | } | ||
677 | |||
678 | const struct GNUNET_MESSENGER_Message* | ||
679 | get_room_message (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
680 | const struct GNUNET_HashCode *hash, int request) | ||
681 | { | ||
682 | const struct GNUNET_MESSENGER_Message *message = get_store_message (&(room->store), hash); | ||
683 | |||
684 | if ((message) || (!handle) || (GNUNET_YES != request) | ||
685 | || (GNUNET_NO != GNUNET_CONTAINER_multihashmap_contains (room->requested, hash))) | ||
686 | return message; | ||
687 | |||
688 | struct GNUNET_MESSENGER_Message *request_msg = create_message_request (hash); | ||
689 | |||
690 | if (request_msg) | ||
691 | { | ||
692 | if (GNUNET_CONTAINER_multihashmap_put (room->requested, hash, NULL, GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST) == GNUNET_OK) | ||
693 | { | ||
694 | struct GNUNET_HashCode request_hash; | ||
695 | |||
696 | send_room_message (room, handle, request_msg, &request_hash); | ||
697 | } | ||
698 | |||
699 | destroy_message (request_msg); | ||
700 | } | ||
701 | |||
702 | return message; | ||
703 | } | ||
704 | |||
705 | void | ||
706 | callback_room_disconnect (struct GNUNET_MESSENGER_SrvRoom *room, void *cls) | ||
707 | { | ||
708 | struct GNUNET_MESSENGER_SrvTunnel *tunnel = cls; | ||
709 | |||
710 | if (!room->host) | ||
711 | return; | ||
712 | |||
713 | struct GNUNET_PeerIdentity identity; | ||
714 | |||
715 | GNUNET_PEER_resolve (tunnel->peer, &identity); | ||
716 | |||
717 | if (GNUNET_YES == contains_list_tunnels (&(room->basement), &identity)) | ||
718 | { | ||
719 | struct GNUNET_MESSENGER_Message *message = create_message_miss (&identity); | ||
720 | |||
721 | if (message) | ||
722 | { | ||
723 | struct GNUNET_HashCode hash; | ||
724 | |||
725 | send_room_message (room, room->host, message, &hash); | ||
726 | destroy_message (message); | ||
727 | } | ||
728 | } | ||
729 | } | ||
730 | |||
731 | int | ||
732 | callback_verify_room_message (struct GNUNET_MESSENGER_SrvRoom *room, void *cls, | ||
733 | struct GNUNET_MESSENGER_Message *message, struct GNUNET_HashCode *hash) | ||
734 | { | ||
735 | if (GNUNET_MESSENGER_KIND_UNKNOWN == message->header.kind) | ||
736 | return GNUNET_SYSERR; | ||
737 | |||
738 | struct GNUNET_MESSENGER_SrvContact *contact = GNUNET_CONTAINER_multishortmap_get (room->members, | ||
739 | &(message->header.sender_id)); | ||
740 | |||
741 | if (!contact) | ||
742 | { | ||
743 | if (GNUNET_MESSENGER_KIND_INFO == message->header.kind) | ||
744 | contact = get_service_contact_by_pubkey (room->service, &(message->body.info.host_key)); | ||
745 | else if (GNUNET_MESSENGER_KIND_JOIN == message->header.kind) | ||
746 | contact = get_service_contact_by_pubkey (room->service, &(message->body.join.key)); | ||
747 | } | ||
748 | |||
749 | if ((!contact) || (GNUNET_SYSERR == verify_message (message, hash, get_contact_key (contact)))) | ||
750 | return GNUNET_SYSERR; | ||
751 | |||
752 | if (GNUNET_YES == room->strict_access) | ||
753 | { | ||
754 | struct GNUNET_MESSENGER_MemberInfo *info = GNUNET_CONTAINER_multishortmap_get (room->member_infos, | ||
755 | &(message->header.sender_id)); | ||
756 | |||
757 | if ((info) && (GNUNET_MESSENGER_MEMBER_BLOCKED == info->access)) | ||
758 | return GNUNET_SYSERR; | ||
759 | } | ||
760 | |||
761 | if (GNUNET_YES == contains_store_message (&(room->store), hash)) | ||
762 | return GNUNET_NO; | ||
763 | |||
764 | return GNUNET_YES; | ||
765 | } | ||
766 | |||
767 | static void | ||
768 | search_room_for_message (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_HashCode *hash) | ||
769 | { | ||
770 | const struct GNUNET_MESSENGER_Message *message = get_room_message (room, room->host, hash, GNUNET_YES); | ||
771 | |||
772 | if (!message) | ||
773 | return; | ||
774 | |||
775 | if (GNUNET_MESSENGER_KIND_MERGE == message->header.kind) | ||
776 | search_room_for_message (room, &(message->body.merge.previous)); | ||
777 | |||
778 | search_room_for_message (room, &(message->header.previous)); | ||
779 | } | ||
780 | |||
781 | static void | ||
782 | idle_request_room_messages (void *cls) | ||
783 | { | ||
784 | struct GNUNET_MESSENGER_SrvRoom *room = cls; | ||
785 | |||
786 | room->idle = NULL; | ||
787 | |||
788 | struct GNUNET_MESSENGER_ListMessage *element = room->last_messages.head; | ||
789 | |||
790 | while (element) | ||
791 | { | ||
792 | search_room_for_message (room, &(element->hash)); | ||
793 | |||
794 | element = element->next; | ||
795 | } | ||
796 | |||
797 | merge_room_last_messages (room, room->host); | ||
798 | |||
799 | room->idle = GNUNET_SCHEDULER_add_delayed_with_priority (GNUNET_TIME_relative_get_second_ (), | ||
800 | GNUNET_SCHEDULER_PRIORITY_IDLE, idle_request_room_messages, | ||
801 | cls); | ||
802 | } | ||
803 | |||
804 | void | ||
805 | update_room_last_messages (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_MESSENGER_Message *message, | ||
806 | const struct GNUNET_HashCode *hash) | ||
807 | { | ||
808 | struct GNUNET_MESSENGER_ListMessage *element = room->last_messages.head; | ||
809 | struct GNUNET_MESSENGER_ListMessage *merging = NULL; | ||
810 | |||
811 | if (GNUNET_MESSENGER_KIND_MERGE == message->header.kind) | ||
812 | { | ||
813 | merging = room->last_messages.head; | ||
814 | |||
815 | while (merging) | ||
816 | { | ||
817 | if (0 == GNUNET_CRYPTO_hash_cmp (&(merging->hash), &(message->body.merge.previous))) | ||
818 | break; | ||
819 | |||
820 | merging = merging->next; | ||
821 | } | ||
822 | |||
823 | if (merging) | ||
824 | element = merging->next; | ||
825 | } | ||
826 | |||
827 | while (element) | ||
828 | { | ||
829 | if (0 == GNUNET_CRYPTO_hash_cmp (&(element->hash), &(message->header.previous))) | ||
830 | break; | ||
831 | |||
832 | element = element->next; | ||
833 | } | ||
834 | |||
835 | if ((merging) && (!element)) | ||
836 | { | ||
837 | element = merging; | ||
838 | merging = NULL; | ||
839 | } | ||
840 | |||
841 | if (element) | ||
842 | { | ||
843 | GNUNET_memcpy(&(element->hash), hash, sizeof(struct GNUNET_HashCode)); | ||
844 | |||
845 | if (merging) | ||
846 | GNUNET_CONTAINER_DLL_remove(room->last_messages.head, room->last_messages.tail, merging); | ||
847 | } | ||
848 | else | ||
849 | add_to_list_messages (&(room->last_messages), hash); | ||
850 | |||
851 | if (GNUNET_YES == GNUNET_CONTAINER_multihashmap_contains (room->requested, hash)) | ||
852 | GNUNET_CONTAINER_multihashmap_remove_all (room->requested, hash); | ||
853 | } | ||
854 | |||
855 | void | ||
856 | switch_room_member_id (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_ShortHashCode *old_id, | ||
857 | const struct GNUNET_ShortHashCode *new_id, const struct GNUNET_HashCode *hash) | ||
858 | { | ||
859 | struct GNUNET_MESSENGER_SrvContact *contact = GNUNET_CONTAINER_multishortmap_get (room->members, old_id); | ||
860 | |||
861 | if ((contact) && (GNUNET_YES == GNUNET_CONTAINER_multishortmap_remove (room->members, old_id, contact))) | ||
862 | GNUNET_CONTAINER_multishortmap_put (room->members, new_id, contact, | ||
863 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST); | ||
864 | |||
865 | struct GNUNET_MESSENGER_MemberInfo *info = GNUNET_CONTAINER_multishortmap_get (room->member_infos, old_id); | ||
866 | |||
867 | if ((!info) || (GNUNET_YES != GNUNET_CONTAINER_multishortmap_remove (room->member_infos, old_id, contact)) | ||
868 | || (GNUNET_YES != GNUNET_CONTAINER_multishortmap_put (room->member_infos, new_id, contact, | ||
869 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST))) | ||
870 | return; | ||
871 | |||
872 | if (hash) | ||
873 | add_to_list_messages (&(info->session_messages), hash); | ||
874 | } | ||
875 | |||
876 | void | ||
877 | rebuild_room_basement_structure (struct GNUNET_MESSENGER_SrvRoom *room) | ||
878 | { | ||
879 | struct GNUNET_PeerIdentity peer; | ||
880 | size_t src; | ||
881 | |||
882 | if ((GNUNET_OK != get_service_peer_identity (room->service, &peer)) || (!find_list_tunnels (&(room->basement), &peer, | ||
883 | &src))) | ||
884 | return; | ||
885 | |||
886 | size_t count = count_of_tunnels (&(room->basement)); | ||
887 | |||
888 | struct GNUNET_MESSENGER_ListTunnel *element = room->basement.head; | ||
889 | struct GNUNET_MESSENGER_SrvTunnel *tunnel; | ||
890 | |||
891 | size_t dst = 0; | ||
892 | |||
893 | while (element) | ||
894 | { | ||
895 | GNUNET_PEER_resolve (element->peer, &peer); | ||
896 | |||
897 | tunnel = GNUNET_CONTAINER_multipeermap_get (room->tunnels, &peer); | ||
898 | |||
899 | if (!tunnel) | ||
900 | { | ||
901 | element = remove_from_list_tunnels (&(room->basement), element); | ||
902 | continue; | ||
903 | } | ||
904 | |||
905 | if (GNUNET_YES == required_connection_between (count, src, dst)) | ||
906 | { | ||
907 | if (GNUNET_SYSERR == connect_tunnel (tunnel)) | ||
908 | { | ||
909 | element = remove_from_list_tunnels (&(room->basement), element); | ||
910 | continue; | ||
911 | } | ||
912 | } | ||
913 | else | ||
914 | disconnect_tunnel (tunnel); | ||
915 | |||
916 | element = element->next; | ||
917 | dst++; | ||
918 | } | ||
919 | } | ||
920 | |||
921 | void | ||
922 | handle_room_messages (struct GNUNET_MESSENGER_SrvRoom *room) | ||
923 | { | ||
924 | while (room->handling.head) | ||
925 | { | ||
926 | struct GNUNET_MESSENGER_ListMessage *element = room->handling.head; | ||
927 | |||
928 | const struct GNUNET_MESSENGER_Message *msg = get_room_message (room, room->host, &(element->hash), GNUNET_NO); | ||
929 | |||
930 | if (msg) | ||
931 | handle_service_message (room->service, room, msg, &(element->hash)); | ||
932 | |||
933 | GNUNET_CONTAINER_DLL_remove(room->handling.head, room->handling.tail, element); | ||
934 | GNUNET_free(element); | ||
935 | } | ||
936 | } | ||
937 | |||
938 | #include "gnunet-service-messenger_message_recv.h" | ||
939 | |||
940 | void | ||
941 | callback_room_recv (struct GNUNET_MESSENGER_SrvRoom *room, void *cls, struct GNUNET_MESSENGER_Message *message, | ||
942 | const struct GNUNET_HashCode *hash) | ||
943 | { | ||
944 | struct GNUNET_MESSENGER_SrvTunnel *tunnel = cls; | ||
945 | |||
946 | if (GNUNET_OK != put_store_message (&(room->store), hash, message)) | ||
947 | return; | ||
948 | |||
949 | update_room_last_messages (room, message, hash); | ||
950 | |||
951 | if (GNUNET_MESSENGER_KIND_INFO != message->header.kind) | ||
952 | forward_room_message (room, tunnel, message, hash); | ||
953 | |||
954 | const int start_handle = room->handling.head ? GNUNET_NO : GNUNET_YES; | ||
955 | |||
956 | add_to_list_messages (&(room->handling), hash); | ||
957 | |||
958 | switch (message->header.kind) | ||
959 | { | ||
960 | case GNUNET_MESSENGER_KIND_INFO: | ||
961 | recv_message_info (room, tunnel, message, hash); | ||
962 | break; | ||
963 | case GNUNET_MESSENGER_KIND_JOIN: | ||
964 | recv_message_join (room, tunnel, message, hash); | ||
965 | break; | ||
966 | case GNUNET_MESSENGER_KIND_LEAVE: | ||
967 | recv_message_leave (room, tunnel, message, hash); | ||
968 | break; | ||
969 | case GNUNET_MESSENGER_KIND_NAME: | ||
970 | recv_message_name (room, tunnel, message, hash); | ||
971 | break; | ||
972 | case GNUNET_MESSENGER_KIND_KEY: | ||
973 | recv_message_key (room, tunnel, message, hash); | ||
974 | break; | ||
975 | case GNUNET_MESSENGER_KIND_PEER: | ||
976 | recv_message_peer (room, tunnel, message, hash); | ||
977 | break; | ||
978 | case GNUNET_MESSENGER_KIND_ID: | ||
979 | recv_message_id (room, tunnel, message, hash); | ||
980 | break; | ||
981 | case GNUNET_MESSENGER_KIND_MISS: | ||
982 | recv_message_miss (room, tunnel, message, hash); | ||
983 | break; | ||
984 | case GNUNET_MESSENGER_KIND_REQUEST: | ||
985 | recv_message_request (room, tunnel, message, hash); | ||
986 | break; | ||
987 | default: | ||
988 | break; | ||
989 | } | ||
990 | |||
991 | if (GNUNET_YES == start_handle) | ||
992 | handle_room_messages (room); | ||
993 | } | ||
994 | |||
995 | #include "gnunet-service-messenger_message_send.h" | ||
996 | |||
997 | void | ||
998 | callback_room_sent (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, void *cls, | ||
999 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
1000 | { | ||
1001 | const struct GNUNET_MESSENGER_Message *old_message = get_room_message (room, handle, hash, GNUNET_NO); | ||
1002 | |||
1003 | if ((old_message) || (GNUNET_OK != put_store_message (&(room->store), hash, message))) | ||
1004 | { | ||
1005 | if (old_message != message) | ||
1006 | GNUNET_free(message); | ||
1007 | } | ||
1008 | else | ||
1009 | { | ||
1010 | struct GNUNET_MESSENGER_SrvTunnel *tunnel = cls; // may be NULL | ||
1011 | |||
1012 | update_room_last_messages (room, message, hash); | ||
1013 | |||
1014 | const int start_handle = room->handling.head ? GNUNET_NO : GNUNET_YES; | ||
1015 | |||
1016 | add_to_list_messages (&(room->handling), hash); | ||
1017 | |||
1018 | switch (message->header.kind) | ||
1019 | { | ||
1020 | case GNUNET_MESSENGER_KIND_INFO: | ||
1021 | send_message_info (room, handle, tunnel, message, hash); | ||
1022 | break; | ||
1023 | case GNUNET_MESSENGER_KIND_JOIN: | ||
1024 | send_message_join (room, handle, tunnel, message, hash); | ||
1025 | break; | ||
1026 | case GNUNET_MESSENGER_KIND_LEAVE: | ||
1027 | send_message_leave (room, handle, tunnel, message, hash); | ||
1028 | break; | ||
1029 | case GNUNET_MESSENGER_KIND_NAME: | ||
1030 | send_message_name (room, handle, tunnel, message, hash); | ||
1031 | break; | ||
1032 | case GNUNET_MESSENGER_KIND_KEY: | ||
1033 | send_message_key (room, handle, tunnel, message, hash); | ||
1034 | break; | ||
1035 | case GNUNET_MESSENGER_KIND_PEER: | ||
1036 | send_message_peer (room, handle, tunnel, message, hash); | ||
1037 | break; | ||
1038 | case GNUNET_MESSENGER_KIND_ID: | ||
1039 | send_message_id (room, handle, tunnel, message, hash); | ||
1040 | break; | ||
1041 | case GNUNET_MESSENGER_KIND_MISS: | ||
1042 | send_message_miss (room, handle, tunnel, message, hash); | ||
1043 | break; | ||
1044 | default: | ||
1045 | break; | ||
1046 | } | ||
1047 | |||
1048 | if (GNUNET_YES == start_handle) | ||
1049 | handle_room_messages (room); | ||
1050 | } | ||
1051 | } | ||
diff --git a/src/messenger/gnunet-service-messenger_room.h b/src/messenger/gnunet-service-messenger_room.h new file mode 100644 index 000000000..36c9e8cf5 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_room.h | |||
@@ -0,0 +1,378 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_room.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_SERVICE_MESSENGER_ROOM_H | ||
27 | #define GNUNET_SERVICE_MESSENGER_ROOM_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_cadet_service.h" | ||
31 | #include "gnunet_container_lib.h" | ||
32 | #include "gnunet_crypto_lib.h" | ||
33 | #include "gnunet_identity_service.h" | ||
34 | #include "gnunet_mq_lib.h" | ||
35 | |||
36 | #include "gnunet-service-messenger_contact.h" | ||
37 | |||
38 | #include "gnunet_messenger_service.h" | ||
39 | #include "gnunet-service-messenger_basement.h" | ||
40 | #include "gnunet-service-messenger_handle.h" | ||
41 | #include "gnunet-service-messenger_tunnel.h" | ||
42 | |||
43 | #include "gnunet-service-messenger_list_messages.h" | ||
44 | #include "messenger_api_list_tunnels.h" | ||
45 | |||
46 | #include "gnunet-service-messenger_message_store.h" | ||
47 | #include "messenger_api_ego.h" | ||
48 | |||
49 | enum GNUNET_MESSENGER_MemberAccess | ||
50 | { | ||
51 | GNUNET_MESSENGER_MEMBER_ALLOWED = 1, | ||
52 | GNUNET_MESSENGER_MEMBER_BLOCKED = 1, | ||
53 | |||
54 | GNUNET_MESSENGER_MEMBER_UNKNOWN = 0 | ||
55 | }; | ||
56 | |||
57 | struct GNUNET_MESSENGER_MemberInfo | ||
58 | { | ||
59 | enum GNUNET_MESSENGER_MemberAccess access; | ||
60 | |||
61 | struct GNUNET_MESSENGER_ListMessages session_messages; | ||
62 | }; | ||
63 | |||
64 | struct GNUNET_MESSENGER_SrvRoom | ||
65 | { | ||
66 | struct GNUNET_MESSENGER_Service *service; | ||
67 | struct GNUNET_MESSENGER_SrvHandle *host; | ||
68 | struct GNUNET_CADET_Port *port; | ||
69 | |||
70 | struct GNUNET_HashCode key; | ||
71 | |||
72 | struct GNUNET_CONTAINER_MultiPeerMap *tunnels; | ||
73 | struct GNUNET_CONTAINER_MultiShortmap *members; | ||
74 | struct GNUNET_CONTAINER_MultiShortmap *member_infos; | ||
75 | |||
76 | struct GNUNET_MESSENGER_MessageStore store; | ||
77 | struct GNUNET_CONTAINER_MultiHashMap *requested; | ||
78 | |||
79 | struct GNUNET_MESSENGER_ListTunnels basement; | ||
80 | struct GNUNET_MESSENGER_ListMessages last_messages; | ||
81 | |||
82 | struct GNUNET_HashCode *peer_message; | ||
83 | |||
84 | struct GNUNET_MESSENGER_ListMessages handling; | ||
85 | struct GNUNET_SCHEDULER_Task *idle; | ||
86 | |||
87 | int strict_access; | ||
88 | }; | ||
89 | |||
90 | /** | ||
91 | * Creates and allocates a new room for a <i>handle</i> with a given <i>key</i>. | ||
92 | * | ||
93 | * @param handle Handle | ||
94 | * @param key Key of room | ||
95 | * @return New room | ||
96 | */ | ||
97 | struct GNUNET_MESSENGER_SrvRoom* | ||
98 | create_room (struct GNUNET_MESSENGER_SrvHandle *handle, const struct GNUNET_HashCode *key); | ||
99 | |||
100 | /** | ||
101 | * Destroys a room and frees its memory fully. | ||
102 | * | ||
103 | * @param room Room | ||
104 | */ | ||
105 | void | ||
106 | destroy_room (struct GNUNET_MESSENGER_SrvRoom *room); | ||
107 | |||
108 | /** | ||
109 | * Returns the contact of a member in a <i>room</i> identified by a given <i>id</i>. If the <i>room</i> | ||
110 | * does not contain a member with the given <i>id</i>, NULL gets returned. | ||
111 | * | ||
112 | * @param room Room | ||
113 | * @param id Member id | ||
114 | * @return Contact or NULL | ||
115 | */ | ||
116 | struct GNUNET_MESSENGER_SrvContact* | ||
117 | get_room_contact (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_ShortHashCode *id); | ||
118 | |||
119 | /** | ||
120 | * Adds a contact from the service to a <i>room</i> under a specific <i>id</i> with a given public key. | ||
121 | * | ||
122 | * @param room Room | ||
123 | * @param id Member id | ||
124 | * @param pubkey Public key of EGO | ||
125 | */ | ||
126 | void | ||
127 | add_room_contact (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_ShortHashCode *id, | ||
128 | const struct GNUNET_IDENTITY_PublicKey *pubkey); | ||
129 | |||
130 | /** | ||
131 | * Returns the member information of a member in a <i>room</i> identified by a given <i>id</i>. If the <i>room</i> | ||
132 | * does not contain a member with the given <i>id</i>, NULL gets returned. | ||
133 | * | ||
134 | * @param room Room | ||
135 | * @param id Member id | ||
136 | * @return Member information or NULL | ||
137 | */ | ||
138 | struct GNUNET_MESSENGER_MemberInfo* | ||
139 | get_room_member_info (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_ShortHashCode *id); | ||
140 | |||
141 | /** | ||
142 | * Tries to generate and allocate a new unique member id checking all current members for possible | ||
143 | * duplicates. If the function fails, NULL gets returned. | ||
144 | * | ||
145 | * @param room Room | ||
146 | * @return New member id or NULL | ||
147 | */ | ||
148 | struct GNUNET_ShortHashCode* | ||
149 | generate_room_member_id (const struct GNUNET_MESSENGER_SrvRoom *room); | ||
150 | |||
151 | /** | ||
152 | * Returns the member id of the member representing the handle currently hosting this <i>room</i>. | ||
153 | * | ||
154 | * @param room Room | ||
155 | * @return Host member id or NULL | ||
156 | */ | ||
157 | const struct GNUNET_ShortHashCode* | ||
158 | get_room_host_id (const struct GNUNET_MESSENGER_SrvRoom *room); | ||
159 | |||
160 | /** | ||
161 | * Changes the member id of the member representing the handle currently hosting this <i>room</i>. | ||
162 | * | ||
163 | * @param room Room | ||
164 | * @param unique_id Unique member id | ||
165 | */ | ||
166 | void | ||
167 | change_room_host_id (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_ShortHashCode *unique_id); | ||
168 | |||
169 | /** | ||
170 | * Tries to open a <i>room</i> for a given <i>handle</i>. If the room has already been opened, the handle | ||
171 | * will locally join the room. | ||
172 | * | ||
173 | * Calling this method should result in joining a room and sending a peer message as well for this peer. | ||
174 | * | ||
175 | * If the function returns GNUNET_YES the port for this room is guranteed to be open for incoming connections. | ||
176 | * | ||
177 | * @param room Room | ||
178 | * @param handle Handle | ||
179 | * @return GNUNET_YES on success, GNUNET_NO on failure. | ||
180 | */ | ||
181 | int | ||
182 | open_room (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle); | ||
183 | |||
184 | /** | ||
185 | * Connects a tunnel to a hosting peer of a <i>room</i> through a so called <i>door</i> which is represented by | ||
186 | * a peer identity of a hosting peer. During the connection the handle will join the room as a member, waiting for | ||
187 | * an info message from the selected host. | ||
188 | * | ||
189 | * @param room Room | ||
190 | * @param handle Handle | ||
191 | * @param door Peer identity | ||
192 | * @return GNUNET_YES on success, GNUNET_NO on failure. | ||
193 | */ | ||
194 | int | ||
195 | entry_room_at (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
196 | const struct GNUNET_PeerIdentity *door); | ||
197 | |||
198 | /** | ||
199 | * Returns a tunnel granting a direct connection to a specific member in a <i>room</i>. The member gets identified | ||
200 | * by an <i>id</i>. If no tunnel has been linked to the selected id, NULL gets returned. | ||
201 | * | ||
202 | * @param room Room | ||
203 | * @param contact_id Member id | ||
204 | * @return Tunnel to the member or NULL | ||
205 | */ | ||
206 | struct GNUNET_MESSENGER_SrvTunnel* | ||
207 | find_room_tunnel_to (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_ShortHashCode *contact_id); | ||
208 | |||
209 | /** | ||
210 | * Packs a <i>message</i> depending on the selected <i>mode</i> into a newly allocated envelope. It will set the | ||
211 | * timestamp of the message, the sender id and the previous messages hash automatically before packing. The message | ||
212 | * will be signed by the handles EGO. | ||
213 | * | ||
214 | * If the optional <i>hash</i> parameter is a valid pointer, its value will be overriden by the signed messages hash. | ||
215 | * | ||
216 | * If <i>mode</i> is set to GNUNET_MESSENGER_PACK_MODE_ENVELOPE, the function returns a valid envelope to send | ||
217 | * through a message queue, otherwise NULL. | ||
218 | * | ||
219 | * @param room Room | ||
220 | * @param handle Handle | ||
221 | * @param message Message | ||
222 | * @param[out] hash Hash of message | ||
223 | * @param mode Packing mode | ||
224 | * @return New envelope or NULL | ||
225 | */ | ||
226 | struct GNUNET_MQ_Envelope* | ||
227 | pack_room_message (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
228 | struct GNUNET_MESSENGER_Message *message, struct GNUNET_HashCode *hash, int mode); | ||
229 | |||
230 | /** | ||
231 | * Sends a <i>message</i> from a given <i>handle</i> into a <i>room</i>. The <i>hash</i> parameter will be | ||
232 | * updated with the hash-value resulting from the sent message. | ||
233 | * | ||
234 | * The function handles packing the message automatically and will call linked message-events locally even if | ||
235 | * the message won't be sent to another peer. | ||
236 | * | ||
237 | * @param room Room | ||
238 | * @param handle Handle | ||
239 | * @param message Message | ||
240 | * @param[out] hash Hash of message | ||
241 | */ | ||
242 | void | ||
243 | send_room_message (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
244 | struct GNUNET_MESSENGER_Message *message, struct GNUNET_HashCode *hash); | ||
245 | |||
246 | /** | ||
247 | * Sends a <i>message</i> from a given <i>handle</i> into a <i>room</i> excluding one specific <i>tunnel</i>. | ||
248 | * The <i>hash</i> parameter will be updated with the hash-value resulting from the sent message. | ||
249 | * | ||
250 | * The function handles packing the message automatically and will call linked message-events locally even if | ||
251 | * the message won't be sent to another peer. | ||
252 | * | ||
253 | * @param room Room | ||
254 | * @param handle Handle | ||
255 | * @param message Message | ||
256 | * @param[out] hash Hash of message | ||
257 | * @param tunnel Tunnel | ||
258 | */ | ||
259 | void | ||
260 | send_room_message_ext (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
261 | struct GNUNET_MESSENGER_Message *message, struct GNUNET_HashCode *hash, | ||
262 | struct GNUNET_MESSENGER_SrvTunnel *tunnel); | ||
263 | |||
264 | /** | ||
265 | * Forwards a <i>message</i> with a given <i>hash</i> to a specific <i>tunnel</i> inside of a <i>room</i>. | ||
266 | * | ||
267 | * @param room Room | ||
268 | * @param tunnel Tunnel | ||
269 | * @param message Message | ||
270 | * @param hash Hash of message | ||
271 | */ | ||
272 | void | ||
273 | forward_room_message (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvTunnel *tunnel, | ||
274 | const struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
275 | |||
276 | /** | ||
277 | * Reduces all current forks inside of the message history of a <i>room</i> to one remaining last message | ||
278 | * by merging them down. All merge messages will be sent from a given <i>handle</i>. | ||
279 | * | ||
280 | * @param room Room | ||
281 | * @param handle Handle | ||
282 | */ | ||
283 | void | ||
284 | merge_room_last_messages (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle); | ||
285 | |||
286 | /** | ||
287 | * Returns the CADET handle from a rooms service. | ||
288 | * | ||
289 | * @param room Room | ||
290 | * @return CADET handle | ||
291 | */ | ||
292 | struct GNUNET_CADET_Handle* | ||
293 | get_room_cadet (struct GNUNET_MESSENGER_SrvRoom *room); | ||
294 | |||
295 | /** | ||
296 | * Returns the shared secret you need to access a <i>room</i>. | ||
297 | * | ||
298 | * @param room Room | ||
299 | * @return Shared secret | ||
300 | */ | ||
301 | struct GNUNET_HashCode* | ||
302 | get_room_key (struct GNUNET_MESSENGER_SrvRoom *room); | ||
303 | |||
304 | /** | ||
305 | * Returns a tunnel inside of a <i>room</i> leading towards a given <i>peer</i> if such a tunnel exists, | ||
306 | * otherwise NULL. | ||
307 | * | ||
308 | * @param room Room | ||
309 | * @param peer Peer identity | ||
310 | * @return Tunnel or NULL | ||
311 | */ | ||
312 | const struct GNUNET_MESSENGER_SrvTunnel* | ||
313 | get_room_tunnel (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_PeerIdentity *peer); | ||
314 | |||
315 | /** | ||
316 | * Returns a message from a <i>room</i> identified by a given <i>hash</i>. If no matching message is | ||
317 | * found and <i>request</i> is set to GNUNET_YES, the <i>handle</i> will request the missing message | ||
318 | * automatically. | ||
319 | * | ||
320 | * The function uses the optimized check for a message via its hash from the message store. | ||
321 | * @see contains_store_message() | ||
322 | * | ||
323 | * If a message is missing independent of the following request, NULL gets returned instead of the | ||
324 | * matching message. | ||
325 | * | ||
326 | * @param room Room | ||
327 | * @param handle Handle | ||
328 | * @param hash Hash of message | ||
329 | * @param request Flag to request a message | ||
330 | * @return Message or NULL | ||
331 | */ | ||
332 | const struct GNUNET_MESSENGER_Message* | ||
333 | get_room_message (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
334 | const struct GNUNET_HashCode *hash, int request); | ||
335 | |||
336 | /** | ||
337 | * Updates the last messages of a <i>room</i> by replacing them if the previous hash of a given <i>message</i> | ||
338 | * matches with one of the latest messages. | ||
339 | * | ||
340 | * @param room Room | ||
341 | * @param message Message | ||
342 | * @param hash Hash of message | ||
343 | */ | ||
344 | void | ||
345 | update_room_last_messages (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_MESSENGER_Message *message, | ||
346 | const struct GNUNET_HashCode *hash); | ||
347 | |||
348 | /** | ||
349 | * Changes an id of a current member from an old id to a new one and adds optionally the <i>hash</i> of an | ||
350 | * id message to the members information. | ||
351 | * | ||
352 | * @param room Room | ||
353 | * @param old_id Old member id | ||
354 | * @param new_id New member id | ||
355 | * @param hash Hash of id message | ||
356 | */ | ||
357 | void | ||
358 | switch_room_member_id (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_ShortHashCode *old_id, | ||
359 | const struct GNUNET_ShortHashCode *new_id, const struct GNUNET_HashCode *hash); | ||
360 | |||
361 | /** | ||
362 | * Rebuilds the decentralized structure for a <i>room</i> by ensuring all required connections are made | ||
363 | * depending on the amount of peers and this peers index in the list of them. | ||
364 | * | ||
365 | * @param room Room | ||
366 | */ | ||
367 | void | ||
368 | rebuild_room_basement_structure (struct GNUNET_MESSENGER_SrvRoom *room); | ||
369 | |||
370 | /** | ||
371 | * Handles all queued up messages of a room to handle in correct order. | ||
372 | * | ||
373 | * @param room Room | ||
374 | */ | ||
375 | void | ||
376 | handle_room_messages (struct GNUNET_MESSENGER_SrvRoom *room); | ||
377 | |||
378 | #endif //GNUNET_SERVICE_MESSENGER_ROOM_H | ||
diff --git a/src/messenger/gnunet-service-messenger_service.c b/src/messenger/gnunet-service-messenger_service.c new file mode 100644 index 000000000..963314fd8 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_service.c | |||
@@ -0,0 +1,516 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_service.c | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "gnunet-service-messenger_service.h" | ||
27 | |||
28 | #include "gnunet-service-messenger_message_kind.h" | ||
29 | |||
30 | #include "gnunet-service-messenger.h" | ||
31 | #include "gnunet-service-messenger_util.h" | ||
32 | |||
33 | static void | ||
34 | callback_shutdown_service (void *cls) | ||
35 | { | ||
36 | struct GNUNET_MESSENGER_Service *service = cls; | ||
37 | |||
38 | if (service) | ||
39 | { | ||
40 | service->shutdown = NULL; | ||
41 | |||
42 | destroy_service (service); | ||
43 | } | ||
44 | } | ||
45 | |||
46 | static void | ||
47 | callback_update_ego (void *cls, | ||
48 | struct GNUNET_IDENTITY_Ego *ego, | ||
49 | void **ctx, | ||
50 | const char *identifier) | ||
51 | { | ||
52 | if ((!ego) || (!identifier)) | ||
53 | return; | ||
54 | |||
55 | struct GNUNET_MESSENGER_Service *service = cls; | ||
56 | |||
57 | update_service_ego(service, identifier, GNUNET_IDENTITY_ego_get_private_key(ego)); | ||
58 | } | ||
59 | |||
60 | struct GNUNET_MESSENGER_Service* | ||
61 | create_service (const struct GNUNET_CONFIGURATION_Handle *config, struct GNUNET_SERVICE_Handle *service_handle) | ||
62 | { | ||
63 | struct GNUNET_MESSENGER_Service *service = GNUNET_new(struct GNUNET_MESSENGER_Service); | ||
64 | |||
65 | service->config = config; | ||
66 | service->service = service_handle; | ||
67 | |||
68 | service->shutdown = GNUNET_SCHEDULER_add_shutdown (&callback_shutdown_service, service); | ||
69 | |||
70 | service->dir = NULL; | ||
71 | |||
72 | if (GNUNET_OK != GNUNET_CONFIGURATION_get_value_filename (service->config, | ||
73 | GNUNET_MESSENGER_SERVICE_NAME, | ||
74 | "MESSENGER_DIR", &(service->dir))) | ||
75 | { | ||
76 | if (service->dir) | ||
77 | GNUNET_free(service->dir); | ||
78 | |||
79 | service->dir = NULL; | ||
80 | } | ||
81 | else | ||
82 | { | ||
83 | if ((GNUNET_YES != GNUNET_DISK_directory_test (service->dir, GNUNET_YES)) && (GNUNET_OK | ||
84 | != GNUNET_DISK_directory_create (service->dir))) | ||
85 | { | ||
86 | GNUNET_free(service->dir); | ||
87 | |||
88 | service->dir = NULL; | ||
89 | } | ||
90 | } | ||
91 | |||
92 | service->cadet = GNUNET_CADET_connect (service->config); | ||
93 | service->identity = GNUNET_IDENTITY_connect (service->config, &callback_update_ego, service); | ||
94 | |||
95 | service->egos = GNUNET_CONTAINER_multihashmap_create (8, GNUNET_NO); | ||
96 | |||
97 | init_list_handles (&(service->handles)); | ||
98 | |||
99 | service->contacts = GNUNET_CONTAINER_multihashmap_create (8, GNUNET_NO); | ||
100 | service->rooms = GNUNET_CONTAINER_multihashmap_create (8, GNUNET_NO); | ||
101 | |||
102 | return service; | ||
103 | } | ||
104 | |||
105 | static int | ||
106 | iterate_destroy_egos (void *cls, const struct GNUNET_HashCode *key, void *value) | ||
107 | { | ||
108 | struct GNUNET_MESSENGER_Ego *ego = value; | ||
109 | GNUNET_free(ego); | ||
110 | return GNUNET_YES; | ||
111 | } | ||
112 | |||
113 | static int | ||
114 | iterate_destroy_rooms (void *cls, const struct GNUNET_HashCode *key, void *value) | ||
115 | { | ||
116 | struct GNUNET_MESSENGER_SrvRoom *room = value; | ||
117 | destroy_room (room); | ||
118 | return GNUNET_YES; | ||
119 | } | ||
120 | |||
121 | static int | ||
122 | iterate_destroy_contacts (void *cls, const struct GNUNET_HashCode *key, void *value) | ||
123 | { | ||
124 | struct GNUNET_MESSENGER_SrvContact *contact = value; | ||
125 | destroy_contact (contact); | ||
126 | return GNUNET_YES; | ||
127 | } | ||
128 | |||
129 | void | ||
130 | destroy_service (struct GNUNET_MESSENGER_Service *service) | ||
131 | { | ||
132 | if (service->shutdown) | ||
133 | { | ||
134 | GNUNET_SCHEDULER_cancel (service->shutdown); | ||
135 | |||
136 | service->shutdown = NULL; | ||
137 | } | ||
138 | |||
139 | GNUNET_CONTAINER_multihashmap_iterate (service->egos, iterate_destroy_egos, NULL); | ||
140 | |||
141 | clear_list_handles (&(service->handles)); | ||
142 | |||
143 | GNUNET_CONTAINER_multihashmap_iterate (service->rooms, iterate_destroy_rooms, NULL); | ||
144 | GNUNET_CONTAINER_multihashmap_iterate (service->contacts, iterate_destroy_contacts, NULL); | ||
145 | |||
146 | GNUNET_CONTAINER_multihashmap_destroy (service->egos); | ||
147 | GNUNET_CONTAINER_multihashmap_destroy (service->rooms); | ||
148 | GNUNET_CONTAINER_multihashmap_destroy (service->contacts); | ||
149 | |||
150 | if (service->cadet) | ||
151 | { | ||
152 | GNUNET_CADET_disconnect (service->cadet); | ||
153 | |||
154 | service->cadet = NULL; | ||
155 | } | ||
156 | |||
157 | if (service->identity) | ||
158 | { | ||
159 | GNUNET_IDENTITY_disconnect (service->identity); | ||
160 | |||
161 | service->identity = NULL; | ||
162 | } | ||
163 | |||
164 | if (service->dir) | ||
165 | { | ||
166 | GNUNET_free(service->dir); | ||
167 | |||
168 | service->dir = NULL; | ||
169 | } | ||
170 | |||
171 | GNUNET_SERVICE_shutdown (service->service); | ||
172 | |||
173 | GNUNET_free(service); | ||
174 | } | ||
175 | |||
176 | struct GNUNET_MESSENGER_Ego* | ||
177 | lookup_service_ego (struct GNUNET_MESSENGER_Service *service, const char *identifier) | ||
178 | { | ||
179 | GNUNET_assert(identifier); | ||
180 | |||
181 | struct GNUNET_HashCode hash; | ||
182 | |||
183 | GNUNET_CRYPTO_hash(identifier, strlen(identifier), &hash); | ||
184 | return GNUNET_CONTAINER_multihashmap_get(service->egos, &hash); | ||
185 | } | ||
186 | |||
187 | void | ||
188 | update_service_ego (struct GNUNET_MESSENGER_Service *service, const char *identifier, | ||
189 | const struct GNUNET_IDENTITY_PrivateKey* key) | ||
190 | { | ||
191 | GNUNET_assert((identifier) && (key)); | ||
192 | |||
193 | struct GNUNET_HashCode hash; | ||
194 | |||
195 | GNUNET_CRYPTO_hash(identifier, strlen(identifier), &hash); | ||
196 | |||
197 | struct GNUNET_MESSENGER_Ego* ego = GNUNET_CONTAINER_multihashmap_get(service->egos, &hash); | ||
198 | |||
199 | if (!ego) | ||
200 | { | ||
201 | ego = GNUNET_new(struct GNUNET_MESSENGER_Ego); | ||
202 | GNUNET_CONTAINER_multihashmap_put(service->egos, &hash, ego, GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST); | ||
203 | } | ||
204 | |||
205 | GNUNET_memcpy(&(ego->priv), key, sizeof(*key)); | ||
206 | |||
207 | if (GNUNET_OK != GNUNET_IDENTITY_key_get_public(key, &(ego->pub))) | ||
208 | GNUNET_log(GNUNET_ERROR_TYPE_WARNING, "Updating invalid ego key failed!\n"); | ||
209 | } | ||
210 | |||
211 | struct GNUNET_MESSENGER_SrvHandle* | ||
212 | add_service_handle (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MQ_Handle *mq) | ||
213 | { | ||
214 | struct GNUNET_MESSENGER_SrvHandle *handle = create_handle (service, mq); | ||
215 | |||
216 | if (handle) | ||
217 | { | ||
218 | add_list_handle (&(service->handles), handle); | ||
219 | } | ||
220 | |||
221 | return handle; | ||
222 | } | ||
223 | |||
224 | void | ||
225 | remove_service_handle (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvHandle *handle) | ||
226 | { | ||
227 | if (!handle) | ||
228 | return; | ||
229 | |||
230 | if (GNUNET_YES == remove_list_handle (&(service->handles), handle)) | ||
231 | destroy_handle (handle); | ||
232 | } | ||
233 | |||
234 | int | ||
235 | get_service_peer_identity (const struct GNUNET_MESSENGER_Service *service, struct GNUNET_PeerIdentity *peer) | ||
236 | { | ||
237 | return GNUNET_CRYPTO_get_peer_identity (service->config, peer); | ||
238 | } | ||
239 | |||
240 | struct GNUNET_MESSENGER_SrvContact* | ||
241 | get_service_contact_by_pubkey (struct GNUNET_MESSENGER_Service *service, const struct GNUNET_IDENTITY_PublicKey *pubkey) | ||
242 | { | ||
243 | struct GNUNET_HashCode hash; | ||
244 | |||
245 | GNUNET_CRYPTO_hash (pubkey, sizeof(*pubkey), &hash); | ||
246 | |||
247 | struct GNUNET_MESSENGER_SrvContact *contact = GNUNET_CONTAINER_multihashmap_get (service->contacts, &hash); | ||
248 | |||
249 | if (contact) | ||
250 | return contact; | ||
251 | |||
252 | contact = create_contact (pubkey); | ||
253 | |||
254 | if (GNUNET_OK == GNUNET_CONTAINER_multihashmap_put (service->contacts, &hash, contact, | ||
255 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST)) | ||
256 | return contact; | ||
257 | |||
258 | destroy_contact (contact); | ||
259 | return NULL; | ||
260 | } | ||
261 | |||
262 | void | ||
263 | swap_service_contact_by_pubkey (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvContact *contact, | ||
264 | const struct GNUNET_IDENTITY_PublicKey *pubkey) | ||
265 | { | ||
266 | const struct GNUNET_HashCode *hash = get_contact_id_from_key (contact); | ||
267 | |||
268 | if (GNUNET_YES == GNUNET_CONTAINER_multihashmap_remove (service->contacts, hash, contact)) | ||
269 | { | ||
270 | GNUNET_memcpy(&(contact->public_key), pubkey, sizeof(*pubkey)); | ||
271 | |||
272 | hash = get_contact_id_from_key (contact); | ||
273 | |||
274 | GNUNET_CONTAINER_multihashmap_put (service->contacts, hash, contact, | ||
275 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST); | ||
276 | } | ||
277 | } | ||
278 | |||
279 | struct GNUNET_ShortHashCode* | ||
280 | generate_service_new_member_id (struct GNUNET_MESSENGER_Service *service, const struct GNUNET_HashCode *key) | ||
281 | { | ||
282 | struct GNUNET_MESSENGER_SrvRoom *room = get_service_room (service, key); | ||
283 | |||
284 | if (room) | ||
285 | { | ||
286 | return generate_room_member_id (room); | ||
287 | } | ||
288 | else | ||
289 | { | ||
290 | struct GNUNET_ShortHashCode *random_id = GNUNET_new(struct GNUNET_ShortHashCode); | ||
291 | generate_free_member_id (random_id, NULL); | ||
292 | return random_id; | ||
293 | } | ||
294 | } | ||
295 | |||
296 | struct GNUNET_MESSENGER_SrvRoom* | ||
297 | get_service_room (struct GNUNET_MESSENGER_Service *service, const struct GNUNET_HashCode *key) | ||
298 | { | ||
299 | return GNUNET_CONTAINER_multihashmap_get (service->rooms, key); | ||
300 | } | ||
301 | |||
302 | int | ||
303 | open_service_room (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
304 | const struct GNUNET_HashCode *key) | ||
305 | { | ||
306 | struct GNUNET_MESSENGER_SrvRoom *room = get_service_room (service, key); | ||
307 | |||
308 | if (room) | ||
309 | return open_room (room, handle); | ||
310 | |||
311 | room = create_room (handle, key); | ||
312 | |||
313 | if ((GNUNET_YES == open_room (room, handle)) && (GNUNET_OK | ||
314 | == GNUNET_CONTAINER_multihashmap_put (service->rooms, key, room, GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST))) | ||
315 | return GNUNET_YES; | ||
316 | |||
317 | destroy_room (room); | ||
318 | return GNUNET_NO; | ||
319 | } | ||
320 | |||
321 | int | ||
322 | entry_service_room (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
323 | const struct GNUNET_PeerIdentity *door, const struct GNUNET_HashCode *key) | ||
324 | { | ||
325 | struct GNUNET_MESSENGER_SrvRoom *room = get_service_room (service, key); | ||
326 | |||
327 | if (room) | ||
328 | { | ||
329 | if (GNUNET_YES == entry_room_at (room, handle, door)) | ||
330 | return GNUNET_YES; | ||
331 | else | ||
332 | return GNUNET_NO; | ||
333 | } | ||
334 | |||
335 | room = create_room (handle, key); | ||
336 | |||
337 | if ((GNUNET_YES == entry_room_at (room, handle, door)) && (GNUNET_OK | ||
338 | == GNUNET_CONTAINER_multihashmap_put (service->rooms, key, room, GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST))) | ||
339 | { | ||
340 | return GNUNET_YES; | ||
341 | } | ||
342 | else | ||
343 | { | ||
344 | destroy_room (room); | ||
345 | return GNUNET_NO; | ||
346 | } | ||
347 | |||
348 | } | ||
349 | |||
350 | int | ||
351 | close_service_room (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
352 | const struct GNUNET_HashCode *key) | ||
353 | { | ||
354 | struct GNUNET_MESSENGER_SrvRoom *room = get_service_room (service, key); | ||
355 | |||
356 | if (!room) | ||
357 | return GNUNET_NO; | ||
358 | |||
359 | struct GNUNET_MESSENGER_Message *message = create_message_leave (); | ||
360 | |||
361 | if (message) | ||
362 | { | ||
363 | struct GNUNET_HashCode hash; | ||
364 | |||
365 | send_room_message (room, handle, message, &hash); | ||
366 | destroy_message (message); | ||
367 | } | ||
368 | |||
369 | const struct GNUNET_ShortHashCode *id = get_handle_member_id (handle, key); | ||
370 | |||
371 | GNUNET_assert(id); | ||
372 | |||
373 | if (GNUNET_YES != GNUNET_CONTAINER_multihashmap_remove (handle->member_ids, key, id)) | ||
374 | return GNUNET_NO; | ||
375 | |||
376 | struct GNUNET_MESSENGER_SrvHandle *member_handle = (struct GNUNET_MESSENGER_SrvHandle*) find_list_handle_by_member ( | ||
377 | &(service->handles), key); | ||
378 | |||
379 | if (!member_handle) | ||
380 | { | ||
381 | if (GNUNET_OK == GNUNET_CONTAINER_multihashmap_remove (service->rooms, key, room)) | ||
382 | { | ||
383 | destroy_room (room); | ||
384 | return GNUNET_YES; | ||
385 | } | ||
386 | else | ||
387 | return GNUNET_NO; | ||
388 | } | ||
389 | |||
390 | if (room->host == handle) | ||
391 | room->host = member_handle; | ||
392 | |||
393 | return GNUNET_YES; | ||
394 | } | ||
395 | |||
396 | static void | ||
397 | get_room_data_subdir (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvRoom *room, char **dir) | ||
398 | { | ||
399 | GNUNET_asprintf (dir, "%s%s%c%s%c", service->dir, "rooms", DIR_SEPARATOR, GNUNET_h2s (&(room->key)), DIR_SEPARATOR); | ||
400 | } | ||
401 | |||
402 | void | ||
403 | load_service_room_and_messages (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvRoom *room) | ||
404 | { | ||
405 | char *room_dir; | ||
406 | get_room_data_subdir (service, room, &room_dir); | ||
407 | |||
408 | if (GNUNET_YES == GNUNET_DISK_directory_test (room_dir, GNUNET_YES)) | ||
409 | { | ||
410 | load_message_store (&room->store, room_dir); | ||
411 | |||
412 | char *config_file; | ||
413 | GNUNET_asprintf (&config_file, "%s%s", room_dir, "room.cfg"); | ||
414 | |||
415 | struct GNUNET_CONFIGURATION_Handle *cfg = GNUNET_CONFIGURATION_create (); | ||
416 | |||
417 | if ((GNUNET_YES == GNUNET_DISK_file_test (config_file)) && (GNUNET_OK | ||
418 | == GNUNET_CONFIGURATION_parse (cfg, config_file))) | ||
419 | { | ||
420 | unsigned long long access; | ||
421 | |||
422 | if (GNUNET_OK == GNUNET_CONFIGURATION_get_value_number (cfg, "room", "access-rule", &access)) | ||
423 | room->strict_access = (int) (access); | ||
424 | |||
425 | char *message_string; | ||
426 | |||
427 | if ((GNUNET_OK == GNUNET_CONFIGURATION_get_value_string (cfg, "room", "last-message", &message_string)) && (message_string)) | ||
428 | { | ||
429 | struct GNUNET_HashCode hash; | ||
430 | |||
431 | GNUNET_CRYPTO_hash_from_string(message_string, &hash); | ||
432 | |||
433 | const struct GNUNET_MESSENGER_Message *message = get_room_message (room, room->host, &hash, GNUNET_NO); | ||
434 | |||
435 | if (message) | ||
436 | update_room_last_messages (room, message, &hash); | ||
437 | |||
438 | GNUNET_free(message_string); | ||
439 | } | ||
440 | } | ||
441 | |||
442 | GNUNET_CONFIGURATION_destroy (cfg); | ||
443 | |||
444 | GNUNET_free(config_file); | ||
445 | } | ||
446 | |||
447 | GNUNET_free(room_dir); | ||
448 | } | ||
449 | |||
450 | void | ||
451 | save_service_room_and_messages (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvRoom *room) | ||
452 | { | ||
453 | if (GNUNET_YES != GNUNET_CONTAINER_multihashmap_contains (service->rooms, &(room->key))) | ||
454 | { | ||
455 | return; | ||
456 | } | ||
457 | |||
458 | char *room_dir; | ||
459 | get_room_data_subdir (service, room, &room_dir); | ||
460 | |||
461 | if ((GNUNET_YES == GNUNET_DISK_directory_test (room_dir, GNUNET_NO)) || (GNUNET_OK | ||
462 | == GNUNET_DISK_directory_create (room_dir))) | ||
463 | { | ||
464 | save_message_store (&room->store, room_dir); | ||
465 | |||
466 | char *config_file; | ||
467 | GNUNET_asprintf (&config_file, "%s%s", room_dir, "room.cfg"); | ||
468 | |||
469 | struct GNUNET_CONFIGURATION_Handle *cfg = GNUNET_CONFIGURATION_create (); | ||
470 | |||
471 | GNUNET_CONFIGURATION_set_value_number (cfg, "room", "access-rule", room->strict_access); | ||
472 | |||
473 | if (room->last_messages.head) | ||
474 | GNUNET_CONFIGURATION_set_value_string (cfg, "room", "last-message", | ||
475 | GNUNET_h2s_full (&(room->last_messages.head->hash))); | ||
476 | |||
477 | GNUNET_CONFIGURATION_write (cfg, config_file); | ||
478 | GNUNET_CONFIGURATION_destroy (cfg); | ||
479 | |||
480 | GNUNET_free(config_file); | ||
481 | } | ||
482 | |||
483 | GNUNET_free(room_dir); | ||
484 | } | ||
485 | |||
486 | void | ||
487 | handle_service_message (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvRoom *room, | ||
488 | const struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
489 | { | ||
490 | struct GNUNET_MESSENGER_ListHandle *element = service->handles.head; | ||
491 | |||
492 | const uint16_t length = get_message_size (message); | ||
493 | |||
494 | while (element) | ||
495 | { | ||
496 | struct GNUNET_MESSENGER_SrvHandle *handle = (struct GNUNET_MESSENGER_SrvHandle*) element->handle; | ||
497 | |||
498 | if ((handle->mq) && (get_handle_member_id (handle, &(room->key)))) | ||
499 | { | ||
500 | struct GNUNET_MESSENGER_RecvMessage *msg; | ||
501 | struct GNUNET_MQ_Envelope *env; | ||
502 | |||
503 | env = GNUNET_MQ_msg_extra(msg, length, GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_RECV_MESSAGE); | ||
504 | |||
505 | GNUNET_memcpy(&(msg->key), &(room->key), sizeof(room->key)); | ||
506 | GNUNET_memcpy(&(msg->hash), hash, sizeof(*hash)); | ||
507 | |||
508 | char *buffer = ((char*) msg) + sizeof(*msg); | ||
509 | encode_message (message, length, buffer); | ||
510 | |||
511 | GNUNET_MQ_send (handle->mq, env); | ||
512 | } | ||
513 | |||
514 | element = element->next; | ||
515 | } | ||
516 | } | ||
diff --git a/src/messenger/gnunet-service-messenger_service.h b/src/messenger/gnunet-service-messenger_service.h new file mode 100644 index 000000000..246c74771 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_service.h | |||
@@ -0,0 +1,259 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_service.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_SERVICE_MESSENGER_SERVICE_H | ||
27 | #define GNUNET_SERVICE_MESSENGER_SERVICE_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_configuration_lib.h" | ||
31 | #include "gnunet_crypto_lib.h" | ||
32 | #include "gnunet_container_lib.h" | ||
33 | #include "gnunet_disk_lib.h" | ||
34 | #include "gnunet_identity_service.h" | ||
35 | |||
36 | #include "messenger_api_ego.h" | ||
37 | |||
38 | #include "gnunet-service-messenger_list_handles.h" | ||
39 | |||
40 | #include "gnunet-service-messenger_contact.h" | ||
41 | #include "gnunet-service-messenger_room.h" | ||
42 | |||
43 | struct GNUNET_MESSENGER_Service | ||
44 | { | ||
45 | const struct GNUNET_CONFIGURATION_Handle *config; | ||
46 | struct GNUNET_SERVICE_Handle *service; | ||
47 | |||
48 | struct GNUNET_SCHEDULER_Task *shutdown; | ||
49 | |||
50 | char *dir; | ||
51 | |||
52 | struct GNUNET_CADET_Handle *cadet; | ||
53 | struct GNUNET_IDENTITY_Handle *identity; | ||
54 | |||
55 | struct GNUNET_CONTAINER_MultiHashMap *egos; | ||
56 | |||
57 | struct GNUNET_MESSENGER_ListHandles handles; | ||
58 | |||
59 | struct GNUNET_CONTAINER_MultiHashMap *contacts; | ||
60 | struct GNUNET_CONTAINER_MultiHashMap *rooms; | ||
61 | }; | ||
62 | |||
63 | /** | ||
64 | * Creates and allocates a new service using a given <i>config</i> and a GNUnet service handle. | ||
65 | * | ||
66 | * @param config Configuration | ||
67 | * @param service_handle GNUnet service handle | ||
68 | * @return New service | ||
69 | */ | ||
70 | struct GNUNET_MESSENGER_Service* | ||
71 | create_service (const struct GNUNET_CONFIGURATION_Handle *config, struct GNUNET_SERVICE_Handle *service_handle); | ||
72 | |||
73 | /** | ||
74 | * Destroys a <i>service</i> and frees its memory fully. | ||
75 | * | ||
76 | * @param service Service | ||
77 | */ | ||
78 | void | ||
79 | destroy_service (struct GNUNET_MESSENGER_Service *service); | ||
80 | |||
81 | /** | ||
82 | * Lookups an EGO which was registered to a <i>service</i> under | ||
83 | * a specific <i>identifier</i>. | ||
84 | * | ||
85 | * @param service Service | ||
86 | * @param identifier Identifier string | ||
87 | * @return EGO or NULL | ||
88 | */ | ||
89 | struct GNUNET_MESSENGER_Ego* | ||
90 | lookup_service_ego (struct GNUNET_MESSENGER_Service *service, const char *identifier); | ||
91 | |||
92 | /** | ||
93 | * Updates the registration of an EGO to a <i>service</i> under | ||
94 | * a specific <i>identifier</i> with a new <i>key</i>. | ||
95 | * | ||
96 | * @param service Service | ||
97 | * @param identifier Identifier string | ||
98 | * @param key Private EGO key | ||
99 | */ | ||
100 | void | ||
101 | update_service_ego (struct GNUNET_MESSENGER_Service *service, const char *identifier, | ||
102 | const struct GNUNET_IDENTITY_PrivateKey* key); | ||
103 | |||
104 | /** | ||
105 | * Creates and adds a new handle to a <i>service</i> using a given message queue. | ||
106 | * | ||
107 | * @param service Service | ||
108 | * @param mq Message queue | ||
109 | * @return New handle | ||
110 | */ | ||
111 | struct GNUNET_MESSENGER_SrvHandle* | ||
112 | add_service_handle (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MQ_Handle *mq); | ||
113 | |||
114 | /** | ||
115 | * Removes a <i>handle</i> from a <i>service</i> and destroys it. | ||
116 | * | ||
117 | * @param service Service | ||
118 | * @param handle Handle | ||
119 | */ | ||
120 | void | ||
121 | remove_service_handle (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvHandle *handle); | ||
122 | |||
123 | /** | ||
124 | * Tries to write the peer identity of the peer running a <i>service</i> on to the <i>peer</i> | ||
125 | * parameter. The functions returns GNUNET_OK on success, otherwise GNUNET_SYSERR. | ||
126 | * | ||
127 | * @param service Service | ||
128 | * @param[out] peer Peer identity | ||
129 | * @return GNUNET_OK on success, otherwise GNUNET_SYSERR | ||
130 | */ | ||
131 | int | ||
132 | get_service_peer_identity (const struct GNUNET_MESSENGER_Service *service, struct GNUNET_PeerIdentity *peer); | ||
133 | |||
134 | /** | ||
135 | * Returns a contact of a <i>service</i> identified by a given public key. If no matching contact exists, | ||
136 | * it will tried to create one with the specific public key. If the function still fails to do so, | ||
137 | * NULL gets returned. | ||
138 | * | ||
139 | * @param service Service | ||
140 | * @param pubkey Public key of EGO | ||
141 | * @return Contact | ||
142 | */ | ||
143 | struct GNUNET_MESSENGER_SrvContact* | ||
144 | get_service_contact_by_pubkey (struct GNUNET_MESSENGER_Service *service, const struct GNUNET_IDENTITY_PublicKey *pubkey); | ||
145 | |||
146 | /** | ||
147 | * Changes the public key for a <i>contact</i> known to a <i>service</i> to a specific public key and | ||
148 | * updates local map entries to access the contact by its updated key. | ||
149 | * | ||
150 | * @param service Service | ||
151 | * @param contact Contact | ||
152 | * @param pubkey Public key of EGO | ||
153 | */ | ||
154 | void | ||
155 | swap_service_contact_by_pubkey (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvContact *contact, | ||
156 | const struct GNUNET_IDENTITY_PublicKey *pubkey); | ||
157 | |||
158 | /** | ||
159 | * Tries to generate and allocate a new unique member id for a given room of a service identified by its <i>key</i>. | ||
160 | * If the generation fails caused by too many tries of duplicates, it returns NULL. | ||
161 | * | ||
162 | * @param service Service | ||
163 | * @param key Key of room | ||
164 | * @return Newly generated member id or NULL | ||
165 | */ | ||
166 | struct GNUNET_ShortHashCode* | ||
167 | generate_service_new_member_id (struct GNUNET_MESSENGER_Service *service, const struct GNUNET_HashCode *key); | ||
168 | |||
169 | /** | ||
170 | * Returns the room identified by a given <i>key</i> for a <i>service</i>. If the service doesn't know any room | ||
171 | * using the given key, NULL gets returned. | ||
172 | * | ||
173 | * @param service Service | ||
174 | * @param key Key of room | ||
175 | * @return Room or NULL | ||
176 | */ | ||
177 | struct GNUNET_MESSENGER_SrvRoom* | ||
178 | get_service_room (struct GNUNET_MESSENGER_Service *service, const struct GNUNET_HashCode *key); | ||
179 | |||
180 | /** | ||
181 | * Tries to open a room using a given <i>key</i> for a <i>service</i> by a specific <i>handle</i>. The room will be | ||
182 | * created if necessary. If the function is successful, it returns GNUNET_YES, otherwise GNUNET_NO. | ||
183 | * | ||
184 | * @param service Service | ||
185 | * @param handle Handle | ||
186 | * @param key Key of room | ||
187 | * @return GNUNET_YES on success, otherwise GNUNET_NO | ||
188 | */ | ||
189 | int | ||
190 | open_service_room (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
191 | const struct GNUNET_HashCode *key); | ||
192 | |||
193 | /** | ||
194 | * Tries to enter a room using a given <i>key</i> for a <i>service</i> by a specific <i>handle</i>. The room will | ||
195 | * be created if necessary. If the function is successful, it returns GNUNET_YES, otherwise GNUNET_NO. | ||
196 | * | ||
197 | * The room will be entered through the peer identitied by the peer identity provided as <i>door</i> parameter and | ||
198 | * a new connection will be made. | ||
199 | * | ||
200 | * @param service Service | ||
201 | * @param handle Handle | ||
202 | * @param door Peer identity | ||
203 | * @param key Key of room | ||
204 | * @return GNUNET_YES on success, otherwise GNUNET_NO | ||
205 | */ | ||
206 | int | ||
207 | entry_service_room (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
208 | const struct GNUNET_PeerIdentity *door, const struct GNUNET_HashCode *key); | ||
209 | |||
210 | /** | ||
211 | * Tries to close a room using a given <i>key</i> for a <i>service</i> by a specific <i>handle</i>. The room will | ||
212 | * be created if necessary. If the function is successful, it returns GNUNET_YES, otherwise GNUNET_NO. | ||
213 | * | ||
214 | * If the specific handle is currently the host of the room for this service, a new handle which is a member will | ||
215 | * take its place. Otherwise the room will be destroyed for this service. | ||
216 | * | ||
217 | * @param service Service | ||
218 | * @param handle Handle | ||
219 | * @param key Key of room | ||
220 | * @return GNUNET_YES on success, otherwise GNUNET_NO | ||
221 | */ | ||
222 | int | ||
223 | close_service_room (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvHandle *handle, | ||
224 | const struct GNUNET_HashCode *key); | ||
225 | |||
226 | /** | ||
227 | * Loads the local configuration for a given <i>room</i> of a <i>service</i> which contains the last messages hash | ||
228 | * and the ruleset for general access of new members. | ||
229 | * | ||
230 | * @param service Service | ||
231 | * @param room Room | ||
232 | */ | ||
233 | void | ||
234 | load_service_room_and_messages (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvRoom *room); | ||
235 | |||
236 | /** | ||
237 | * Saves the configuration for a given <i>room</i> of a <i>service</i> which contains the last messages hash | ||
238 | * and the ruleset for general access of new members locally. | ||
239 | * | ||
240 | * @param service Service | ||
241 | * @param room Room | ||
242 | */ | ||
243 | void | ||
244 | save_service_room_and_messages (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvRoom *room); | ||
245 | |||
246 | /** | ||
247 | * Sends a received or sent <i>message</i> with a given <i>hash</i> to each handle of a <i>service</i> which | ||
248 | * is currently member of a specific <i>room</i> for handling it in the client API. | ||
249 | * | ||
250 | * @param service Service | ||
251 | * @param room Room | ||
252 | * @param message Message | ||
253 | * @param hash Hash of message | ||
254 | */ | ||
255 | void | ||
256 | handle_service_message (struct GNUNET_MESSENGER_Service *service, struct GNUNET_MESSENGER_SrvRoom *room, | ||
257 | const struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
258 | |||
259 | #endif //GNUNET_SERVICE_MESSENGER_SERVICE_H | ||
diff --git a/src/messenger/gnunet-service-messenger_tunnel.c b/src/messenger/gnunet-service-messenger_tunnel.c new file mode 100644 index 000000000..df9e5c4c7 --- /dev/null +++ b/src/messenger/gnunet-service-messenger_tunnel.c | |||
@@ -0,0 +1,300 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_tunnel.c | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "gnunet-service-messenger_tunnel.h" | ||
27 | |||
28 | #include "gnunet-service-messenger_handle.h" | ||
29 | #include "gnunet-service-messenger_util.h" | ||
30 | |||
31 | struct GNUNET_MESSENGER_SrvTunnel* | ||
32 | create_tunnel (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_PeerIdentity *door) | ||
33 | { | ||
34 | GNUNET_assert((room) && (door)); | ||
35 | |||
36 | struct GNUNET_MESSENGER_SrvTunnel *tunnel = GNUNET_new(struct GNUNET_MESSENGER_SrvTunnel); | ||
37 | |||
38 | tunnel->room = room; | ||
39 | tunnel->channel = NULL; | ||
40 | |||
41 | tunnel->peer = GNUNET_PEER_intern (door); | ||
42 | tunnel->contact_id = NULL; | ||
43 | |||
44 | tunnel->peer_message = NULL; | ||
45 | tunnel->last_message = NULL; | ||
46 | |||
47 | return tunnel; | ||
48 | } | ||
49 | |||
50 | void | ||
51 | destroy_tunnel (struct GNUNET_MESSENGER_SrvTunnel *tunnel) | ||
52 | { | ||
53 | GNUNET_assert(tunnel); | ||
54 | |||
55 | if (tunnel->channel) | ||
56 | GNUNET_CADET_channel_destroy (tunnel->channel); | ||
57 | |||
58 | GNUNET_PEER_change_rc (tunnel->peer, -1); | ||
59 | |||
60 | if (tunnel->contact_id) | ||
61 | GNUNET_free(tunnel->contact_id); | ||
62 | |||
63 | if (tunnel->peer_message) | ||
64 | GNUNET_free(tunnel->peer_message); | ||
65 | |||
66 | if (tunnel->last_message) | ||
67 | GNUNET_free(tunnel->last_message); | ||
68 | |||
69 | GNUNET_free(tunnel); | ||
70 | } | ||
71 | |||
72 | int | ||
73 | bind_tunnel (struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_CADET_Channel *channel) | ||
74 | { | ||
75 | GNUNET_assert(tunnel); | ||
76 | |||
77 | if (tunnel->channel) | ||
78 | { | ||
79 | if (tunnel->contact_id) | ||
80 | return GNUNET_NO; | ||
81 | |||
82 | delayed_disconnect_channel (tunnel->channel); | ||
83 | } | ||
84 | |||
85 | tunnel->channel = channel; | ||
86 | |||
87 | return GNUNET_YES; | ||
88 | } | ||
89 | |||
90 | extern void | ||
91 | callback_room_disconnect (struct GNUNET_MESSENGER_SrvRoom *room, void *cls); | ||
92 | |||
93 | void | ||
94 | callback_tunnel_disconnect (void *cls, const struct GNUNET_CADET_Channel *channel) | ||
95 | { | ||
96 | struct GNUNET_MESSENGER_SrvTunnel *tunnel = cls; | ||
97 | |||
98 | if (tunnel) | ||
99 | { | ||
100 | tunnel->channel = NULL; | ||
101 | |||
102 | callback_room_disconnect (tunnel->room, cls); | ||
103 | } | ||
104 | } | ||
105 | |||
106 | extern int | ||
107 | callback_verify_room_message (struct GNUNET_MESSENGER_SrvRoom *room, void *cls, | ||
108 | struct GNUNET_MESSENGER_Message *message, struct GNUNET_HashCode *hash); | ||
109 | |||
110 | int | ||
111 | check_tunnel_message (void *cls, const struct GNUNET_MessageHeader *header) | ||
112 | { | ||
113 | struct GNUNET_MESSENGER_SrvTunnel *tunnel = cls; | ||
114 | |||
115 | if (!tunnel) | ||
116 | return GNUNET_NO; | ||
117 | |||
118 | const uint16_t length = ntohs (header->size) - sizeof(*header); | ||
119 | const char *buffer = (const char*) &header[1]; | ||
120 | |||
121 | struct GNUNET_MESSENGER_Message message; | ||
122 | |||
123 | if (length < sizeof(message.header)) | ||
124 | return GNUNET_NO; | ||
125 | |||
126 | if (GNUNET_YES != decode_message (&message, length, buffer)) | ||
127 | return GNUNET_NO; | ||
128 | |||
129 | struct GNUNET_HashCode hash; | ||
130 | hash_message (length, buffer, &hash); | ||
131 | |||
132 | int result = callback_verify_room_message (tunnel->room, cls, &message, &hash); | ||
133 | |||
134 | if (GNUNET_MESSENGER_KIND_PEER == message.header.kind) | ||
135 | { | ||
136 | struct GNUNET_PeerIdentity identity; | ||
137 | |||
138 | GNUNET_PEER_resolve (tunnel->peer, &identity); | ||
139 | |||
140 | if (0 == GNUNET_memcmp(&(message.body.peer.peer), &(identity))) | ||
141 | { | ||
142 | if (tunnel->contact_id) | ||
143 | { | ||
144 | if (0 != GNUNET_memcmp(tunnel->contact_id, &(message.header.sender_id))) | ||
145 | result = GNUNET_SYSERR; | ||
146 | } | ||
147 | else | ||
148 | { | ||
149 | tunnel->contact_id = GNUNET_new(struct GNUNET_ShortHashCode); | ||
150 | |||
151 | GNUNET_memcpy(tunnel->contact_id, &(message.header.sender_id), sizeof(struct GNUNET_ShortHashCode)); | ||
152 | } | ||
153 | } | ||
154 | } | ||
155 | |||
156 | return (result == GNUNET_YES ? GNUNET_OK : GNUNET_NO); | ||
157 | } | ||
158 | |||
159 | extern void | ||
160 | callback_room_recv (struct GNUNET_MESSENGER_SrvRoom *room, void *cls, struct GNUNET_MESSENGER_Message *message, | ||
161 | const struct GNUNET_HashCode *hash); | ||
162 | |||
163 | void | ||
164 | handle_tunnel_message (void *cls, const struct GNUNET_MessageHeader *header) | ||
165 | { | ||
166 | struct GNUNET_MESSENGER_SrvTunnel *tunnel = cls; | ||
167 | |||
168 | const uint16_t length = ntohs (header->size) - sizeof(*header); | ||
169 | const char *buffer = (const char*) &header[1]; | ||
170 | |||
171 | struct GNUNET_MESSENGER_Message message; | ||
172 | struct GNUNET_HashCode hash; | ||
173 | |||
174 | decode_message (&message, length, buffer); | ||
175 | hash_message (length, buffer, &hash); | ||
176 | |||
177 | if (tunnel) | ||
178 | { | ||
179 | if (!tunnel->last_message) | ||
180 | tunnel->last_message = GNUNET_new(struct GNUNET_HashCode); | ||
181 | |||
182 | GNUNET_memcpy(tunnel->last_message, &hash, sizeof(struct GNUNET_HashCode)); | ||
183 | |||
184 | callback_room_recv (tunnel->room, cls, copy_message (&message), &hash); | ||
185 | } | ||
186 | |||
187 | GNUNET_CADET_receive_done (tunnel->channel); | ||
188 | } | ||
189 | |||
190 | int | ||
191 | connect_tunnel (struct GNUNET_MESSENGER_SrvTunnel *tunnel) | ||
192 | { | ||
193 | GNUNET_assert(tunnel); | ||
194 | |||
195 | if (tunnel->channel) | ||
196 | return GNUNET_NO; | ||
197 | |||
198 | const struct GNUNET_PeerIdentity *door = GNUNET_PEER_resolve2 (tunnel->peer); | ||
199 | |||
200 | struct GNUNET_CADET_Handle *cadet = get_room_cadet (tunnel->room); | ||
201 | struct GNUNET_HashCode *key = get_room_key (tunnel->room); | ||
202 | |||
203 | struct GNUNET_MQ_MessageHandler handlers[] = { GNUNET_MQ_hd_var_size(tunnel_message, GNUNET_MESSAGE_TYPE_CADET_CLI, | ||
204 | struct GNUNET_MessageHeader, NULL), | ||
205 | GNUNET_MQ_handler_end() }; | ||
206 | |||
207 | tunnel->channel = GNUNET_CADET_channel_create (cadet, tunnel, door, key, NULL, callback_tunnel_disconnect, handlers); | ||
208 | |||
209 | return GNUNET_YES; | ||
210 | } | ||
211 | |||
212 | void | ||
213 | disconnect_tunnel (struct GNUNET_MESSENGER_SrvTunnel *tunnel) | ||
214 | { | ||
215 | if (tunnel->channel) | ||
216 | { | ||
217 | delayed_disconnect_channel (tunnel->channel); | ||
218 | |||
219 | tunnel->channel = NULL; | ||
220 | } | ||
221 | } | ||
222 | |||
223 | int | ||
224 | is_tunnel_connected (const struct GNUNET_MESSENGER_SrvTunnel *tunnel) | ||
225 | { | ||
226 | return (tunnel->channel ? GNUNET_YES : GNUNET_NO); | ||
227 | } | ||
228 | |||
229 | struct GNUNET_MESSENGER_MessageSent | ||
230 | { | ||
231 | struct GNUNET_MESSENGER_SrvTunnel *tunnel; | ||
232 | struct GNUNET_HashCode hash; | ||
233 | }; | ||
234 | |||
235 | extern void | ||
236 | callback_room_sent (struct GNUNET_MESSENGER_SrvRoom *room, struct GNUNET_MESSENGER_SrvHandle *handle, void *cls, | ||
237 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
238 | |||
239 | static void | ||
240 | callback_tunnel_sent (void *cls) | ||
241 | { | ||
242 | struct GNUNET_MESSENGER_MessageSent *sent = cls; | ||
243 | |||
244 | if (sent->tunnel) | ||
245 | { | ||
246 | if (!sent->tunnel->last_message) | ||
247 | sent->tunnel->last_message = GNUNET_new(struct GNUNET_HashCode); | ||
248 | |||
249 | GNUNET_memcpy(sent->tunnel->last_message, &(sent->hash), sizeof(struct GNUNET_HashCode)); | ||
250 | } | ||
251 | |||
252 | GNUNET_free(sent); | ||
253 | } | ||
254 | |||
255 | void | ||
256 | send_tunnel_envelope (struct GNUNET_MESSENGER_SrvTunnel *tunnel, void *handle, struct GNUNET_MQ_Envelope *env, | ||
257 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash) | ||
258 | { | ||
259 | struct GNUNET_MQ_Handle *mq = GNUNET_CADET_get_mq (tunnel->channel); | ||
260 | |||
261 | struct GNUNET_MESSENGER_MessageSent *sent = GNUNET_new(struct GNUNET_MESSENGER_MessageSent); | ||
262 | |||
263 | GNUNET_memcpy(&(sent->hash), hash, sizeof(struct GNUNET_HashCode)); | ||
264 | |||
265 | sent->tunnel = tunnel; | ||
266 | |||
267 | GNUNET_MQ_notify_sent (env, callback_tunnel_sent, sent); | ||
268 | GNUNET_MQ_send (mq, env); | ||
269 | |||
270 | callback_room_sent (tunnel->room, (struct GNUNET_MESSENGER_SrvHandle*) handle, tunnel, message, hash); | ||
271 | } | ||
272 | |||
273 | void | ||
274 | send_tunnel_message (struct GNUNET_MESSENGER_SrvTunnel *tunnel, void *handle, struct GNUNET_MESSENGER_Message *message, | ||
275 | struct GNUNET_HashCode *hash) | ||
276 | { | ||
277 | struct GNUNET_MQ_Envelope *env = pack_room_message (tunnel->room, (struct GNUNET_MESSENGER_SrvHandle*) handle, | ||
278 | message, hash, | ||
279 | GNUNET_MESSENGER_PACK_MODE_ENVELOPE); | ||
280 | |||
281 | if (env) | ||
282 | send_tunnel_envelope (tunnel, handle, env, copy_message (message), hash); | ||
283 | } | ||
284 | |||
285 | void | ||
286 | forward_tunnel_message (struct GNUNET_MESSENGER_SrvTunnel *tunnel, const struct GNUNET_MESSENGER_Message *message, | ||
287 | const struct GNUNET_HashCode *hash) | ||
288 | { | ||
289 | struct GNUNET_MESSENGER_Message *clone = copy_message (message); | ||
290 | struct GNUNET_MQ_Envelope *env = pack_message (clone, NULL, NULL, GNUNET_MESSENGER_PACK_MODE_ENVELOPE); | ||
291 | |||
292 | if (env) | ||
293 | send_tunnel_envelope (tunnel, NULL, env, clone, hash); | ||
294 | } | ||
295 | |||
296 | const struct GNUNET_HashCode* | ||
297 | get_tunnel_peer_message (const struct GNUNET_MESSENGER_SrvTunnel *tunnel) | ||
298 | { | ||
299 | return tunnel->peer_message; | ||
300 | } | ||
diff --git a/src/messenger/gnunet-service-messenger_tunnel.h b/src/messenger/gnunet-service-messenger_tunnel.h new file mode 100644 index 000000000..e6efb226d --- /dev/null +++ b/src/messenger/gnunet-service-messenger_tunnel.h | |||
@@ -0,0 +1,155 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_tunnel.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_SERVICE_MESSENGER_TUNNEL_H | ||
27 | #define GNUNET_SERVICE_MESSENGER_TUNNEL_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_cadet_service.h" | ||
31 | #include "gnunet_peer_lib.h" | ||
32 | #include "gnunet_crypto_lib.h" | ||
33 | |||
34 | #include "gnunet-service-messenger_room.h" | ||
35 | |||
36 | struct GNUNET_MESSENGER_SrvTunnel | ||
37 | { | ||
38 | struct GNUNET_MESSENGER_SrvRoom *room; | ||
39 | struct GNUNET_CADET_Channel *channel; | ||
40 | |||
41 | GNUNET_PEER_Id peer; | ||
42 | struct GNUNET_ShortHashCode *contact_id; | ||
43 | |||
44 | struct GNUNET_HashCode *peer_message; | ||
45 | struct GNUNET_HashCode *last_message; | ||
46 | }; | ||
47 | |||
48 | /** | ||
49 | * Creates and allocates a tunnel of a <i>room</i> to a specific peer identity. | ||
50 | * | ||
51 | * @param room Room | ||
52 | * @param door Peer identity | ||
53 | * @return New tunnel | ||
54 | */ | ||
55 | struct GNUNET_MESSENGER_SrvTunnel* | ||
56 | create_tunnel (struct GNUNET_MESSENGER_SrvRoom *room, const struct GNUNET_PeerIdentity *door); | ||
57 | |||
58 | /** | ||
59 | * Destroys a <i>tunnel</i> and frees its memory fully. | ||
60 | * | ||
61 | * @param tunnel | ||
62 | */ | ||
63 | void | ||
64 | destroy_tunnel (struct GNUNET_MESSENGER_SrvTunnel *tunnel); | ||
65 | |||
66 | /** | ||
67 | * Binds a CADET <i>channel</i> to a <i>tunnel</i> on returns GNUNET_YES only if | ||
68 | * the bounds channel was replaced successfully, otherwise GNUNET_NO gets returned. | ||
69 | * | ||
70 | * @param tunnel Tunnel | ||
71 | * @param channel CADET channel | ||
72 | * @return GNUNET_YES on success, otherwise GNUNET_NO | ||
73 | */ | ||
74 | int | ||
75 | bind_tunnel (struct GNUNET_MESSENGER_SrvTunnel *tunnel, struct GNUNET_CADET_Channel *channel); | ||
76 | |||
77 | /** | ||
78 | * Tries to connect a <i>tunnel</i> by creating a new CADET channel and binding it. | ||
79 | * The function returns GNUNET_YES on success, otherwise GNUNET_NO. | ||
80 | * | ||
81 | * @param tunnel Tunnel | ||
82 | * @return GNUNET_YES on success, otherwise GNUNET_NO | ||
83 | */ | ||
84 | int | ||
85 | connect_tunnel (struct GNUNET_MESSENGER_SrvTunnel *tunnel); | ||
86 | |||
87 | /** | ||
88 | * Disconnects and unbinds a channel from a <i>tunnel</i>. The actual disconnection | ||
89 | * will be asynchronous. | ||
90 | * | ||
91 | * @param tunnel Tunnel | ||
92 | */ | ||
93 | void | ||
94 | disconnect_tunnel (struct GNUNET_MESSENGER_SrvTunnel *tunnel); | ||
95 | |||
96 | /** | ||
97 | * Returns the status of a currently bound channel of a <i>tunnel</i>. | ||
98 | * | ||
99 | * @param tunnel Tunnel | ||
100 | * @return GNUNET_YES or GNUNET_NO | ||
101 | */ | ||
102 | int | ||
103 | is_tunnel_connected (const struct GNUNET_MESSENGER_SrvTunnel *tunnel); | ||
104 | |||
105 | /** | ||
106 | * Sends an envelope containing a <i>message</i> with a given <i>hash</i> through | ||
107 | * a <i>tunnel</i> by a given <i>handle</i>. | ||
108 | * | ||
109 | * @param tunnel Tunnel | ||
110 | * @param handle Handle | ||
111 | * @param env Envelope | ||
112 | * @param message Message | ||
113 | * @param hash Hash of message | ||
114 | */ | ||
115 | void | ||
116 | send_tunnel_envelope (struct GNUNET_MESSENGER_SrvTunnel *tunnel, void *handle, struct GNUNET_MQ_Envelope *env, | ||
117 | struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash); | ||
118 | |||
119 | /** | ||
120 | * Sends a <i>message</i> by packing it automatically into an envelope and passing it | ||
121 | * through the <i>tunnel</i>. The used <i>handle</i> will sign the message and | ||
122 | * the <i>hash</i> will be calculated and stored. | ||
123 | * | ||
124 | * @param tunnel Tunnel | ||
125 | * @param handle Handle | ||
126 | * @param[out] message Message | ||
127 | * @param[out] hash Hash of message | ||
128 | */ | ||
129 | void | ||
130 | send_tunnel_message (struct GNUNET_MESSENGER_SrvTunnel *tunnel, void *handle, struct GNUNET_MESSENGER_Message *message, | ||
131 | struct GNUNET_HashCode *hash); | ||
132 | |||
133 | /** | ||
134 | * Forwards a given <i>message</i> with a known <i>hash</i> through a <i>tunnel</i>. | ||
135 | * | ||
136 | * @param tunnel Tunnel | ||
137 | * @param message Message | ||
138 | * @param hash Hash of message | ||
139 | */ | ||
140 | void | ||
141 | forward_tunnel_message (struct GNUNET_MESSENGER_SrvTunnel *tunnel, const struct GNUNET_MESSENGER_Message *message, | ||
142 | const struct GNUNET_HashCode *hash); | ||
143 | |||
144 | /** | ||
145 | * Returns the hash of the latest peer message published through a given <i>tunnel</i> | ||
146 | * and matching the tunnels peer identity. If no peer message has been linked to the tunnel | ||
147 | * yet, NULL gets returned. | ||
148 | * | ||
149 | * @param tunnel Tunnel | ||
150 | * @return Hash of peer message or NULL | ||
151 | */ | ||
152 | const struct GNUNET_HashCode* | ||
153 | get_tunnel_peer_message (const struct GNUNET_MESSENGER_SrvTunnel *tunnel); | ||
154 | |||
155 | #endif //GNUNET_SERVICE_MESSENGER_TUNNEL_H | ||
diff --git a/src/messenger/gnunet-service-messenger_util.c b/src/messenger/gnunet-service-messenger_util.c new file mode 100644 index 000000000..94fc9469d --- /dev/null +++ b/src/messenger/gnunet-service-messenger_util.c | |||
@@ -0,0 +1,64 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_util.c | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "gnunet-service-messenger_util.h" | ||
27 | |||
28 | static void | ||
29 | callback_close_channel (void *cls) | ||
30 | { | ||
31 | struct GNUNET_CADET_Channel *channel = cls; | ||
32 | |||
33 | if (channel) | ||
34 | GNUNET_CADET_channel_destroy (channel); | ||
35 | } | ||
36 | |||
37 | void | ||
38 | delayed_disconnect_channel (struct GNUNET_CADET_Channel *channel) | ||
39 | { | ||
40 | GNUNET_SCHEDULER_add_delayed_with_priority (GNUNET_TIME_relative_get_zero_ (), GNUNET_SCHEDULER_PRIORITY_URGENT, | ||
41 | callback_close_channel, channel); | ||
42 | } | ||
43 | |||
44 | int | ||
45 | generate_free_member_id (struct GNUNET_ShortHashCode *id, const struct GNUNET_CONTAINER_MultiShortmap *members) | ||
46 | { | ||
47 | size_t counter = 1 + (members ? GNUNET_CONTAINER_multishortmap_size (members) : 0); | ||
48 | |||
49 | do | ||
50 | { | ||
51 | GNUNET_CRYPTO_random_block (GNUNET_CRYPTO_QUALITY_STRONG, id, sizeof(struct GNUNET_ShortHashCode)); | ||
52 | |||
53 | if ((members) && (GNUNET_YES == GNUNET_CONTAINER_multishortmap_contains (members, id))) | ||
54 | counter--; | ||
55 | else | ||
56 | break; | ||
57 | } | ||
58 | while (counter > 0); | ||
59 | |||
60 | if (counter) | ||
61 | return GNUNET_YES; | ||
62 | |||
63 | return GNUNET_NO; | ||
64 | } | ||
diff --git a/src/messenger/gnunet-service-messenger_util.h b/src/messenger/gnunet-service-messenger_util.h new file mode 100644 index 000000000..20f8f0afe --- /dev/null +++ b/src/messenger/gnunet-service-messenger_util.h | |||
@@ -0,0 +1,53 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/gnunet-service-messenger_util.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_SERVICE_MESSENGER_UTIL_H | ||
27 | #define GNUNET_SERVICE_MESSENGER_UTIL_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_cadet_service.h" | ||
31 | #include "gnunet_container_lib.h" | ||
32 | #include "gnunet_crypto_lib.h" | ||
33 | |||
34 | /** | ||
35 | * Starts an urgent task to close a CADET channel asynchronously. | ||
36 | * | ||
37 | * @param channel Channel | ||
38 | */ | ||
39 | void | ||
40 | delayed_disconnect_channel (struct GNUNET_CADET_Channel *channel); | ||
41 | |||
42 | /** | ||
43 | * Tries to generate an unused member id and store it into the <i>id</i> parameter. A map containing all currently | ||
44 | * used member ids is used to check against. | ||
45 | * | ||
46 | * @param[out] id New member id | ||
47 | * @param members Map of member ids | ||
48 | * @return GNUNET_YES on success, GNUNET_NO on failure | ||
49 | */ | ||
50 | int | ||
51 | generate_free_member_id (struct GNUNET_ShortHashCode *id, const struct GNUNET_CONTAINER_MultiShortmap *members); | ||
52 | |||
53 | #endif //GNUNET_SERVICE_MESSENGER_UTIL_H | ||
diff --git a/src/messenger/messenger.conf.in b/src/messenger/messenger.conf.in new file mode 100644 index 000000000..59e11b166 --- /dev/null +++ b/src/messenger/messenger.conf.in | |||
@@ -0,0 +1,13 @@ | |||
1 | [messenger] | ||
2 | START_ON_DEMAND = YES | ||
3 | PORT = 2097 | ||
4 | HOSTNAME = localhost | ||
5 | BINARY = gnunet-service-messenger | ||
6 | ACCEPT_FROM = 127.0.0.1; | ||
7 | ACCEPT_FROM6 = ::1; | ||
8 | UNIXPATH = $GNUNET_RUNTIME_DIR/gnunet-service-messenger.sock | ||
9 | UNIX_MATCH_UID = NO | ||
10 | UNIX_MATCH_GID = YES | ||
11 | |||
12 | # Directory to store messages and contacts | ||
13 | MESSENGER_DIR = $GNUNET_DATA_HOME/messenger/ \ No newline at end of file | ||
diff --git a/src/messenger/messenger_api.c b/src/messenger/messenger_api.c new file mode 100644 index 000000000..6401b18d7 --- /dev/null +++ b/src/messenger/messenger_api.c | |||
@@ -0,0 +1,568 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/messenger_api.c | ||
23 | * @brief messenger api: client implementation of GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "gnunet_messenger_service.h" | ||
27 | |||
28 | #include "gnunet-service-messenger.h" | ||
29 | |||
30 | #include "messenger_api_handle.h" | ||
31 | #include "messenger_api_message.h" | ||
32 | |||
33 | const char* | ||
34 | GNUNET_MESSENGER_name_of_kind (enum GNUNET_MESSENGER_MessageKind kind) | ||
35 | { | ||
36 | switch (kind) | ||
37 | { | ||
38 | case GNUNET_MESSENGER_KIND_INFO: | ||
39 | return "INFO"; | ||
40 | case GNUNET_MESSENGER_KIND_JOIN: | ||
41 | return "JOIN"; | ||
42 | case GNUNET_MESSENGER_KIND_LEAVE: | ||
43 | return "LEAVE"; | ||
44 | case GNUNET_MESSENGER_KIND_NAME: | ||
45 | return "NAME"; | ||
46 | case GNUNET_MESSENGER_KIND_KEY: | ||
47 | return "KEY"; | ||
48 | case GNUNET_MESSENGER_KIND_PEER: | ||
49 | return "PEER"; | ||
50 | case GNUNET_MESSENGER_KIND_ID: | ||
51 | return "ID"; | ||
52 | case GNUNET_MESSENGER_KIND_MISS: | ||
53 | return "MISS"; | ||
54 | case GNUNET_MESSENGER_KIND_MERGE: | ||
55 | return "MERGE"; | ||
56 | case GNUNET_MESSENGER_KIND_REQUEST: | ||
57 | return "REQUEST"; | ||
58 | case GNUNET_MESSENGER_KIND_INVITE: | ||
59 | return "INVITE"; | ||
60 | case GNUNET_MESSENGER_KIND_TEXT: | ||
61 | return "TEXT"; | ||
62 | case GNUNET_MESSENGER_KIND_FILE: | ||
63 | return "FILE"; | ||
64 | default: | ||
65 | return "UNKNOWN"; | ||
66 | } | ||
67 | } | ||
68 | |||
69 | static int | ||
70 | check_get_name (void *cls, const struct GNUNET_MESSENGER_NameMessage *msg) | ||
71 | { | ||
72 | GNUNET_MQ_check_zero_termination(msg); | ||
73 | return GNUNET_OK; | ||
74 | } | ||
75 | |||
76 | static void | ||
77 | handle_get_name (void *cls, const struct GNUNET_MESSENGER_NameMessage *msg) | ||
78 | { | ||
79 | struct GNUNET_MESSENGER_Handle *handle = cls; | ||
80 | |||
81 | const char *name = ((const char*) msg) + sizeof(*msg); | ||
82 | |||
83 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Set name of handle: %s\n", name); | ||
84 | |||
85 | set_handle_name (handle, strlen(name) > 0? name : NULL); | ||
86 | } | ||
87 | |||
88 | static void | ||
89 | handle_get_key (void *cls, const struct GNUNET_MESSENGER_KeyMessage *msg) | ||
90 | { | ||
91 | struct GNUNET_MESSENGER_Handle *handle = cls; | ||
92 | |||
93 | const struct GNUNET_IDENTITY_PublicKey *pubkey = &(msg->pubkey); | ||
94 | |||
95 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Set key of handle: %s\n", GNUNET_IDENTITY_public_key_to_string (pubkey)); | ||
96 | |||
97 | set_handle_key (handle, pubkey); | ||
98 | |||
99 | if (handle->identity_callback) | ||
100 | handle->identity_callback (handle->identity_cls, handle); | ||
101 | } | ||
102 | |||
103 | static void | ||
104 | handle_member_id (void *cls, const struct GNUNET_MESSENGER_MemberMessage *msg) | ||
105 | { | ||
106 | struct GNUNET_MESSENGER_Handle *handle = cls; | ||
107 | |||
108 | const struct GNUNET_HashCode *key = &(msg->key); | ||
109 | const struct GNUNET_ShortHashCode *id = &(msg->id); | ||
110 | |||
111 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Set id of handle in room: %s\n", GNUNET_h2s (key)); | ||
112 | |||
113 | struct GNUNET_MESSENGER_Room *room = GNUNET_CONTAINER_multihashmap_get (handle->rooms, key); | ||
114 | |||
115 | if (room) | ||
116 | { | ||
117 | if (!room->contact_id) | ||
118 | room->contact_id = GNUNET_new(struct GNUNET_ShortHashCode); | ||
119 | |||
120 | GNUNET_memcpy(room->contact_id, id, sizeof(*id)); | ||
121 | } | ||
122 | } | ||
123 | |||
124 | static void | ||
125 | handle_room_open (void *cls, const struct GNUNET_MESSENGER_RoomMessage *msg) | ||
126 | { | ||
127 | struct GNUNET_MESSENGER_Handle *handle = cls; | ||
128 | |||
129 | const struct GNUNET_HashCode *key = &(msg->key); | ||
130 | |||
131 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Opened room: %s\n", GNUNET_h2s (key)); | ||
132 | |||
133 | open_handle_room (handle, key); | ||
134 | } | ||
135 | |||
136 | static void | ||
137 | handle_room_entry (void *cls, const struct GNUNET_MESSENGER_RoomMessage *msg) | ||
138 | { | ||
139 | struct GNUNET_MESSENGER_Handle *handle = cls; | ||
140 | |||
141 | const struct GNUNET_PeerIdentity *door = &(msg->door); | ||
142 | const struct GNUNET_HashCode *key = &(msg->key); | ||
143 | |||
144 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Entered room: %s\n", GNUNET_h2s (key)); | ||
145 | |||
146 | entry_handle_room_at (handle, door, key); | ||
147 | } | ||
148 | |||
149 | static void | ||
150 | handle_room_close (void *cls, const struct GNUNET_MESSENGER_RoomMessage *msg) | ||
151 | { | ||
152 | struct GNUNET_MESSENGER_Handle *handle = cls; | ||
153 | |||
154 | const struct GNUNET_HashCode *key = &(msg->key); | ||
155 | |||
156 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Closed room: %s\n", GNUNET_h2s (key)); | ||
157 | |||
158 | close_handle_room (handle, key); | ||
159 | } | ||
160 | |||
161 | static int | ||
162 | check_recv_message (void *cls, const struct GNUNET_MESSENGER_RecvMessage *msg) | ||
163 | { | ||
164 | const uint16_t full_length = ntohs (msg->header.size) - sizeof(msg->header); | ||
165 | |||
166 | if (full_length < sizeof(msg->hash)) | ||
167 | return GNUNET_NO; | ||
168 | |||
169 | const uint16_t length = full_length - sizeof(msg->hash); | ||
170 | const char *buffer = ((const char*) msg) + sizeof(*msg); | ||
171 | |||
172 | struct GNUNET_MESSENGER_Message message; | ||
173 | |||
174 | if (length < sizeof(message.header)) | ||
175 | return GNUNET_NO; | ||
176 | |||
177 | if (GNUNET_YES != decode_message (&message, length, buffer)) | ||
178 | return GNUNET_NO; | ||
179 | |||
180 | return GNUNET_OK; | ||
181 | } | ||
182 | |||
183 | static void | ||
184 | handle_recv_message (void *cls, const struct GNUNET_MESSENGER_RecvMessage *msg) | ||
185 | { | ||
186 | struct GNUNET_MESSENGER_Handle *handle = cls; | ||
187 | |||
188 | const struct GNUNET_HashCode *key = &(msg->key); | ||
189 | const struct GNUNET_HashCode *hash = &(msg->hash); | ||
190 | |||
191 | const char *buffer = ((const char*) msg) + sizeof(*msg); | ||
192 | |||
193 | const uint16_t length = ntohs (msg->header.size) - sizeof(*msg); | ||
194 | |||
195 | struct GNUNET_MESSENGER_Message message; | ||
196 | decode_message (&message, length, buffer); | ||
197 | |||
198 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Receiving message: %s\n", GNUNET_MESSENGER_name_of_kind (message.header.kind)); | ||
199 | |||
200 | struct GNUNET_MESSENGER_Room *room = GNUNET_CONTAINER_multihashmap_get (handle->rooms, key); | ||
201 | |||
202 | if (room) | ||
203 | { | ||
204 | handle_room_message (room, &message, hash); | ||
205 | |||
206 | if (handle->msg_callback) | ||
207 | handle->msg_callback (handle->msg_cls, room, &message, hash); | ||
208 | } | ||
209 | else | ||
210 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "MESSENGER ERROR: Room not found\n"); | ||
211 | } | ||
212 | |||
213 | static void | ||
214 | reconnect (struct GNUNET_MESSENGER_Handle *handle); | ||
215 | |||
216 | static void | ||
217 | send_open_room (struct GNUNET_MESSENGER_Handle *handle, struct GNUNET_MESSENGER_Room *room) | ||
218 | { | ||
219 | struct GNUNET_MESSENGER_RoomMessage *msg; | ||
220 | struct GNUNET_MQ_Envelope *env; | ||
221 | |||
222 | env = GNUNET_MQ_msg(msg, GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_OPEN); | ||
223 | GNUNET_memcpy(&(msg->key), &(room->key), sizeof(room->key)); | ||
224 | GNUNET_MQ_send (handle->mq, env); | ||
225 | } | ||
226 | |||
227 | static void | ||
228 | send_entry_room (struct GNUNET_MESSENGER_Handle *handle, struct GNUNET_MESSENGER_Room *room, | ||
229 | const struct GNUNET_PeerIdentity *door) | ||
230 | { | ||
231 | struct GNUNET_MESSENGER_RoomMessage *msg; | ||
232 | struct GNUNET_MQ_Envelope *env; | ||
233 | |||
234 | env = GNUNET_MQ_msg(msg, GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_ENTRY); | ||
235 | GNUNET_memcpy(&(msg->door), door, sizeof(*door)); | ||
236 | GNUNET_memcpy(&(msg->key), &(room->key), sizeof(room->key)); | ||
237 | GNUNET_MQ_send (handle->mq, env); | ||
238 | } | ||
239 | |||
240 | static void | ||
241 | send_close_room (struct GNUNET_MESSENGER_Handle *handle, struct GNUNET_MESSENGER_Room *room) | ||
242 | { | ||
243 | struct GNUNET_MESSENGER_RoomMessage *msg; | ||
244 | struct GNUNET_MQ_Envelope *env; | ||
245 | |||
246 | env = GNUNET_MQ_msg(msg, GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_CLOSE); | ||
247 | GNUNET_memcpy(&(msg->key), &(room->key), sizeof(room->key)); | ||
248 | GNUNET_MQ_send (handle->mq, env); | ||
249 | } | ||
250 | |||
251 | static int | ||
252 | iterate_reset_room (void *cls, const struct GNUNET_HashCode *key, void *value) | ||
253 | { | ||
254 | struct GNUNET_MESSENGER_Handle *handle = cls; | ||
255 | struct GNUNET_MESSENGER_Room *room = value; | ||
256 | |||
257 | if (GNUNET_YES == room->opened) | ||
258 | send_open_room (handle, room); | ||
259 | |||
260 | struct GNUNET_MESSENGER_ListTunnel *entry = room->entries.head; | ||
261 | |||
262 | struct GNUNET_PeerIdentity door; | ||
263 | |||
264 | while (entry) | ||
265 | { | ||
266 | GNUNET_PEER_resolve (entry->peer, &door); | ||
267 | |||
268 | send_entry_room (handle, room, &door); | ||
269 | |||
270 | entry = entry->next; | ||
271 | } | ||
272 | |||
273 | return GNUNET_YES; | ||
274 | } | ||
275 | |||
276 | static void | ||
277 | callback_reconnect (void *cls) | ||
278 | { | ||
279 | struct GNUNET_MESSENGER_Handle *handle = cls; | ||
280 | |||
281 | handle->reconnect_task = NULL; | ||
282 | handle->reconnect_time = GNUNET_TIME_STD_BACKOFF(handle->reconnect_time) | ||
283 | ; | ||
284 | |||
285 | reconnect (handle); | ||
286 | |||
287 | GNUNET_CONTAINER_multihashmap_iterate (handle->rooms, iterate_reset_room, handle); | ||
288 | } | ||
289 | |||
290 | static int | ||
291 | iterate_close_room (void *cls, const struct GNUNET_HashCode *key, void *value) | ||
292 | { | ||
293 | struct GNUNET_MESSENGER_Handle *handle = cls; | ||
294 | struct GNUNET_MESSENGER_Room *room = value; | ||
295 | |||
296 | send_close_room (handle, room); | ||
297 | |||
298 | return GNUNET_YES; | ||
299 | } | ||
300 | |||
301 | static void | ||
302 | callback_mq_error (void *cls, enum GNUNET_MQ_Error error) | ||
303 | { | ||
304 | struct GNUNET_MESSENGER_Handle *handle = cls; | ||
305 | |||
306 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "MQ ERROR: %u\n", error); | ||
307 | |||
308 | GNUNET_CONTAINER_multihashmap_iterate (handle->rooms, iterate_close_room, handle); | ||
309 | |||
310 | if (handle->mq) | ||
311 | { | ||
312 | GNUNET_MQ_destroy (handle->mq); | ||
313 | handle->mq = NULL; | ||
314 | } | ||
315 | |||
316 | handle->reconnect_task = GNUNET_SCHEDULER_add_delayed (handle->reconnect_time, &callback_reconnect, handle); | ||
317 | } | ||
318 | |||
319 | static void | ||
320 | reconnect (struct GNUNET_MESSENGER_Handle *handle) | ||
321 | { | ||
322 | const struct GNUNET_MQ_MessageHandler handlers[] = { GNUNET_MQ_hd_var_size( | ||
323 | get_name, GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_GET_NAME, struct GNUNET_MESSENGER_NameMessage, handle), | ||
324 | GNUNET_MQ_hd_fixed_size( | ||
325 | get_key, GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_GET_KEY, | ||
326 | struct GNUNET_MESSENGER_KeyMessage, handle), | ||
327 | GNUNET_MQ_hd_fixed_size( | ||
328 | member_id, | ||
329 | GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_MEMBER_ID, | ||
330 | struct GNUNET_MESSENGER_MemberMessage, handle), | ||
331 | GNUNET_MQ_hd_fixed_size(room_open, | ||
332 | GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_OPEN, | ||
333 | struct GNUNET_MESSENGER_RoomMessage, | ||
334 | handle), | ||
335 | GNUNET_MQ_hd_fixed_size(room_entry, | ||
336 | GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_ENTRY, | ||
337 | struct GNUNET_MESSENGER_RoomMessage, | ||
338 | handle), | ||
339 | GNUNET_MQ_hd_fixed_size(room_close, | ||
340 | GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_CLOSE, | ||
341 | struct GNUNET_MESSENGER_RoomMessage, | ||
342 | handle), | ||
343 | GNUNET_MQ_hd_var_size( | ||
344 | recv_message, | ||
345 | GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_RECV_MESSAGE, | ||
346 | struct GNUNET_MESSENGER_RecvMessage, handle), | ||
347 | GNUNET_MQ_handler_end() }; | ||
348 | |||
349 | handle->mq = GNUNET_CLIENT_connect (handle->cfg, | ||
350 | GNUNET_MESSENGER_SERVICE_NAME, | ||
351 | handlers, &callback_mq_error, handle); | ||
352 | } | ||
353 | |||
354 | struct GNUNET_MESSENGER_Handle* | ||
355 | GNUNET_MESSENGER_connect (const struct GNUNET_CONFIGURATION_Handle *cfg, const char *name, | ||
356 | GNUNET_MESSENGER_IdentityCallback identity_callback, void *identity_cls, | ||
357 | GNUNET_MESSENGER_MessageCallback msg_callback, void *msg_cls) | ||
358 | { | ||
359 | struct GNUNET_MESSENGER_Handle *handle = create_handle (cfg, identity_callback, identity_cls, msg_callback, msg_cls); | ||
360 | |||
361 | reconnect (handle); | ||
362 | |||
363 | if (handle->mq) | ||
364 | { | ||
365 | const uint16_t name_len = name ? strlen (name) : 0; | ||
366 | |||
367 | struct GNUNET_MESSENGER_CreateMessage *msg; | ||
368 | struct GNUNET_MQ_Envelope *env; | ||
369 | |||
370 | env = GNUNET_MQ_msg_extra(msg, name_len + 1, GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_CREATE); | ||
371 | |||
372 | char *extra = ((char*) msg) + sizeof(*msg); | ||
373 | |||
374 | if (name_len) | ||
375 | GNUNET_memcpy(extra, name, name_len); | ||
376 | |||
377 | extra[name_len] = '\0'; | ||
378 | |||
379 | GNUNET_MQ_send (handle->mq, env); | ||
380 | return handle; | ||
381 | } | ||
382 | else | ||
383 | { | ||
384 | destroy_handle (handle); | ||
385 | return NULL; | ||
386 | } | ||
387 | } | ||
388 | |||
389 | int | ||
390 | GNUNET_MESSENGER_update (struct GNUNET_MESSENGER_Handle *handle) | ||
391 | { | ||
392 | if ((!handle) || (!get_handle_name(handle))) | ||
393 | return GNUNET_SYSERR; | ||
394 | |||
395 | struct GNUNET_MESSENGER_UpdateMessage *msg; | ||
396 | struct GNUNET_MQ_Envelope *env; | ||
397 | |||
398 | env = GNUNET_MQ_msg(msg, GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_UPDATE); | ||
399 | GNUNET_MQ_send (handle->mq, env); | ||
400 | return GNUNET_OK; | ||
401 | } | ||
402 | |||
403 | void | ||
404 | GNUNET_MESSENGER_disconnect (struct GNUNET_MESSENGER_Handle *handle) | ||
405 | { | ||
406 | if (!handle) | ||
407 | return; | ||
408 | |||
409 | struct GNUNET_MESSENGER_DestroyMessage *msg; | ||
410 | struct GNUNET_MQ_Envelope *env; | ||
411 | |||
412 | env = GNUNET_MQ_msg(msg, GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_DESTROY); | ||
413 | GNUNET_MQ_send (handle->mq, env); | ||
414 | |||
415 | destroy_handle (handle); | ||
416 | } | ||
417 | |||
418 | const char* | ||
419 | GNUNET_MESSENGER_get_name (const struct GNUNET_MESSENGER_Handle *handle) | ||
420 | { | ||
421 | if (!handle) | ||
422 | return NULL; | ||
423 | |||
424 | return get_handle_name (handle); | ||
425 | } | ||
426 | |||
427 | int | ||
428 | GNUNET_MESSENGER_set_name (struct GNUNET_MESSENGER_Handle *handle, const char *name) | ||
429 | { | ||
430 | if (!handle) | ||
431 | return GNUNET_SYSERR; | ||
432 | |||
433 | const uint16_t name_len = name ? strlen (name) : 0; | ||
434 | |||
435 | struct GNUNET_MESSENGER_NameMessage *msg; | ||
436 | struct GNUNET_MQ_Envelope *env; | ||
437 | |||
438 | env = GNUNET_MQ_msg_extra(msg, name_len + 1, GNUNET_MESSAGE_TYPE_MESSENGER_CONNECTION_SET_NAME); | ||
439 | |||
440 | char *extra = ((char*) msg) + sizeof(*msg); | ||
441 | |||
442 | if (name_len) | ||
443 | GNUNET_memcpy(extra, name, name_len); | ||
444 | |||
445 | extra[name_len] = '\0'; | ||
446 | |||
447 | GNUNET_MQ_send (handle->mq, env); | ||
448 | return GNUNET_YES; | ||
449 | } | ||
450 | |||
451 | const struct GNUNET_IDENTITY_PublicKey* | ||
452 | GNUNET_MESSENGER_get_key (const struct GNUNET_MESSENGER_Handle *handle) | ||
453 | { | ||
454 | if (!handle) | ||
455 | return NULL; | ||
456 | |||
457 | return get_handle_key (handle); | ||
458 | } | ||
459 | |||
460 | struct GNUNET_MESSENGER_Room* | ||
461 | GNUNET_MESSENGER_open_room (struct GNUNET_MESSENGER_Handle *handle, const struct GNUNET_HashCode *key) | ||
462 | { | ||
463 | struct GNUNET_MESSENGER_Room *room = GNUNET_CONTAINER_multihashmap_get (handle->rooms, key); | ||
464 | |||
465 | if (!room) | ||
466 | { | ||
467 | room = create_room (handle, key); | ||
468 | |||
469 | if (GNUNET_OK != GNUNET_CONTAINER_multihashmap_put (handle->rooms, key, room, | ||
470 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST)) | ||
471 | { | ||
472 | destroy_room (room); | ||
473 | return NULL; | ||
474 | } | ||
475 | } | ||
476 | |||
477 | send_open_room (handle, room); | ||
478 | return room; | ||
479 | } | ||
480 | |||
481 | struct GNUNET_MESSENGER_Room* | ||
482 | GNUNET_MESSENGER_entry_room (struct GNUNET_MESSENGER_Handle *handle, const struct GNUNET_PeerIdentity *door, | ||
483 | const struct GNUNET_HashCode *key) | ||
484 | { | ||
485 | struct GNUNET_MESSENGER_Room *room = GNUNET_CONTAINER_multihashmap_get (handle->rooms, key); | ||
486 | |||
487 | if (!room) | ||
488 | { | ||
489 | room = create_room (handle, key); | ||
490 | |||
491 | if (GNUNET_OK != GNUNET_CONTAINER_multihashmap_put (handle->rooms, key, room, | ||
492 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST)) | ||
493 | { | ||
494 | destroy_room (room); | ||
495 | return NULL; | ||
496 | } | ||
497 | } | ||
498 | |||
499 | send_entry_room (handle, room, door); | ||
500 | return room; | ||
501 | } | ||
502 | |||
503 | void | ||
504 | GNUNET_MESSENGER_close_room (struct GNUNET_MESSENGER_Room *room) | ||
505 | { | ||
506 | send_close_room (room->handle, room); | ||
507 | } | ||
508 | |||
509 | struct GNUNET_MESSENGER_Contact* | ||
510 | GNUNET_MESSENGER_get_member (const struct GNUNET_MESSENGER_Room *room, const struct GNUNET_ShortHashCode *id) | ||
511 | { | ||
512 | return GNUNET_CONTAINER_multishortmap_get (room->members, id); | ||
513 | } | ||
514 | |||
515 | const char* | ||
516 | GNUNET_MESSENGER_contact_get_name (const struct GNUNET_MESSENGER_Contact *contact) | ||
517 | { | ||
518 | if (!contact) | ||
519 | return NULL; | ||
520 | |||
521 | return get_contact_name (contact); | ||
522 | } | ||
523 | |||
524 | const struct GNUNET_IDENTITY_PublicKey* | ||
525 | GNUNET_MESSENGER_contact_get_key (const struct GNUNET_MESSENGER_Contact *contact) | ||
526 | { | ||
527 | if (!contact) | ||
528 | return NULL; | ||
529 | |||
530 | return get_contact_key (contact); | ||
531 | } | ||
532 | |||
533 | void | ||
534 | GNUNET_MESSENGER_send_message (struct GNUNET_MESSENGER_Room *room, const struct GNUNET_MESSENGER_Message *message) | ||
535 | { | ||
536 | const uint16_t length = get_message_size (message); | ||
537 | |||
538 | struct GNUNET_MESSENGER_SendMessage *msg; | ||
539 | struct GNUNET_MQ_Envelope *env; | ||
540 | |||
541 | env = GNUNET_MQ_msg_extra(msg, length, GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_SEND_MESSAGE); | ||
542 | |||
543 | GNUNET_memcpy(&(msg->key), &(room->key), sizeof(room->key)); | ||
544 | |||
545 | char *buffer = ((char*) msg) + sizeof(*msg); | ||
546 | encode_message (message, length, buffer); | ||
547 | |||
548 | GNUNET_MQ_send (room->handle->mq, env); | ||
549 | } | ||
550 | |||
551 | const struct GNUNET_MESSENGER_Message* | ||
552 | GNUNET_MESSENGER_get_message (const struct GNUNET_MESSENGER_Room *room, const struct GNUNET_HashCode *hash) | ||
553 | { | ||
554 | const struct GNUNET_MESSENGER_Message *message = get_room_message (room, hash); | ||
555 | |||
556 | if (!message) | ||
557 | { | ||
558 | struct GNUNET_MESSENGER_RecvMessage *msg; | ||
559 | struct GNUNET_MQ_Envelope *env; | ||
560 | |||
561 | env = GNUNET_MQ_msg(msg, GNUNET_MESSAGE_TYPE_MESSENGER_ROOM_GET_MESSAGE); | ||
562 | GNUNET_memcpy(&(msg->key), &(room->key), sizeof(room->key)); | ||
563 | GNUNET_memcpy(&(msg->hash), hash, sizeof(*hash)); | ||
564 | GNUNET_MQ_send (room->handle->mq, env); | ||
565 | } | ||
566 | |||
567 | return message; | ||
568 | } | ||
diff --git a/src/messenger/messenger_api_contact.c b/src/messenger/messenger_api_contact.c new file mode 100644 index 000000000..9a242aa00 --- /dev/null +++ b/src/messenger/messenger_api_contact.c | |||
@@ -0,0 +1,78 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/messenger_api_contact.c | ||
23 | * @brief messenger api: client implementation of GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "messenger_api_contact.h" | ||
27 | |||
28 | struct GNUNET_MESSENGER_Contact* | ||
29 | create_contact (const struct GNUNET_IDENTITY_PublicKey *key) | ||
30 | { | ||
31 | struct GNUNET_MESSENGER_Contact *contact = GNUNET_new(struct GNUNET_MESSENGER_Contact); | ||
32 | |||
33 | contact->name = NULL; | ||
34 | |||
35 | GNUNET_memcpy(&(contact->public_key), key, sizeof(contact->public_key)); | ||
36 | |||
37 | return contact; | ||
38 | } | ||
39 | |||
40 | void | ||
41 | destroy_contact (struct GNUNET_MESSENGER_Contact *contact) | ||
42 | { | ||
43 | if (contact->name) | ||
44 | GNUNET_free(contact->name); | ||
45 | |||
46 | GNUNET_free(contact); | ||
47 | } | ||
48 | |||
49 | const char* | ||
50 | get_contact_name (const struct GNUNET_MESSENGER_Contact *contact) | ||
51 | { | ||
52 | return contact->name; | ||
53 | } | ||
54 | |||
55 | void | ||
56 | set_contact_name (struct GNUNET_MESSENGER_Contact *contact, const char *name) | ||
57 | { | ||
58 | if (contact->name) | ||
59 | GNUNET_free(contact->name); | ||
60 | |||
61 | contact->name = name? GNUNET_strdup(name) : NULL; | ||
62 | } | ||
63 | |||
64 | const struct GNUNET_IDENTITY_PublicKey* | ||
65 | get_contact_key (const struct GNUNET_MESSENGER_Contact *contact) | ||
66 | { | ||
67 | return &(contact->public_key); | ||
68 | } | ||
69 | |||
70 | const struct GNUNET_HashCode* | ||
71 | get_contact_id_from_key (const struct GNUNET_MESSENGER_Contact *contact) | ||
72 | { | ||
73 | static struct GNUNET_HashCode id; | ||
74 | |||
75 | GNUNET_CRYPTO_hash (&(contact->public_key), sizeof(contact->public_key), &id); | ||
76 | |||
77 | return &id; | ||
78 | } | ||
diff --git a/src/messenger/messenger_api_contact.h b/src/messenger/messenger_api_contact.h new file mode 100644 index 000000000..0673b9b85 --- /dev/null +++ b/src/messenger/messenger_api_contact.h | |||
@@ -0,0 +1,93 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/messenger_api_contact.h | ||
23 | * @brief messenger api: client implementation of GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_MESSENGER_API_CONTACT_H | ||
27 | #define GNUNET_MESSENGER_API_CONTACT_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_crypto_lib.h" | ||
31 | #include "gnunet_identity_service.h" | ||
32 | |||
33 | struct GNUNET_MESSENGER_Contact | ||
34 | { | ||
35 | char *name; | ||
36 | |||
37 | struct GNUNET_IDENTITY_PublicKey public_key; | ||
38 | }; | ||
39 | |||
40 | /** | ||
41 | * Creates and allocates a new contact with a given public <i>key</i> from an EGO. | ||
42 | * | ||
43 | * @param key Public key | ||
44 | * @return New contact | ||
45 | */ | ||
46 | struct GNUNET_MESSENGER_Contact* | ||
47 | create_contact (const struct GNUNET_IDENTITY_PublicKey *key); | ||
48 | |||
49 | /** | ||
50 | * Destroys a contact and frees its memory fully. | ||
51 | * | ||
52 | * @param contact Contact | ||
53 | */ | ||
54 | void | ||
55 | destroy_contact (struct GNUNET_MESSENGER_Contact *contact); | ||
56 | |||
57 | /** | ||
58 | * Returns the current name of a given <i>contact</i> or NULL if no valid name was assigned yet. | ||
59 | * | ||
60 | * @param contact Contact | ||
61 | * @return Name of the contact or NULL | ||
62 | */ | ||
63 | const char* | ||
64 | get_contact_name (const struct GNUNET_MESSENGER_Contact *contact); | ||
65 | |||
66 | /** | ||
67 | * Changes the current name of a given <i>contact</i> by copying it from the parameter <i>name</i>. | ||
68 | * | ||
69 | * @param contact Contact | ||
70 | * @param name Valid name (may not be NULL!) | ||
71 | */ | ||
72 | void | ||
73 | set_contact_name (struct GNUNET_MESSENGER_Contact *contact, const char *name); | ||
74 | |||
75 | /** | ||
76 | * Returns the public key of a given <i>contact</i>. | ||
77 | * | ||
78 | * @param contact Contact | ||
79 | * @return Public key of the contact | ||
80 | */ | ||
81 | const struct GNUNET_IDENTITY_PublicKey* | ||
82 | get_contact_key (const struct GNUNET_MESSENGER_Contact *contact); | ||
83 | |||
84 | /** | ||
85 | * Returns the resulting hashcode of the public key from a given <i>contact</i>. | ||
86 | * | ||
87 | * @param contact Contact | ||
88 | * @return Hash of the contacts public key | ||
89 | */ | ||
90 | const struct GNUNET_HashCode* | ||
91 | get_contact_id_from_key (const struct GNUNET_MESSENGER_Contact *contact); | ||
92 | |||
93 | #endif //GNUNET_MESSENGER_API_CONTACT_H | ||
diff --git a/src/messenger/messenger_api_ego.h b/src/messenger/messenger_api_ego.h new file mode 100644 index 000000000..c60eeac50 --- /dev/null +++ b/src/messenger/messenger_api_ego.h | |||
@@ -0,0 +1,38 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/messenger_api_ego.h | ||
23 | * @brief GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_MESSENGER_API_EGO_H | ||
27 | #define GNUNET_MESSENGER_API_EGO_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_identity_service.h" | ||
31 | |||
32 | struct GNUNET_MESSENGER_Ego | ||
33 | { | ||
34 | struct GNUNET_IDENTITY_PrivateKey priv; | ||
35 | struct GNUNET_IDENTITY_PublicKey pub; | ||
36 | }; | ||
37 | |||
38 | #endif //GNUNET_MESSENGER_API_EGO_H | ||
diff --git a/src/messenger/messenger_api_handle.c b/src/messenger/messenger_api_handle.c new file mode 100644 index 000000000..20ef77254 --- /dev/null +++ b/src/messenger/messenger_api_handle.c | |||
@@ -0,0 +1,213 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/messenger_api_handle.c | ||
23 | * @brief messenger api: client implementation of GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "messenger_api_handle.h" | ||
27 | |||
28 | struct GNUNET_MESSENGER_Handle* | ||
29 | create_handle (const struct GNUNET_CONFIGURATION_Handle *cfg, GNUNET_MESSENGER_IdentityCallback identity_callback, | ||
30 | void *identity_cls, GNUNET_MESSENGER_MessageCallback msg_callback, void *msg_cls) | ||
31 | { | ||
32 | struct GNUNET_MESSENGER_Handle *handle = GNUNET_new(struct GNUNET_MESSENGER_Handle); | ||
33 | |||
34 | handle->cfg = cfg; | ||
35 | handle->mq = NULL; | ||
36 | |||
37 | handle->identity_callback = identity_callback; | ||
38 | handle->identity_cls = identity_cls; | ||
39 | |||
40 | handle->msg_callback = msg_callback; | ||
41 | handle->msg_cls = msg_cls; | ||
42 | |||
43 | handle->name = NULL; | ||
44 | handle->pubkey = NULL; | ||
45 | |||
46 | handle->reconnect_time = GNUNET_TIME_relative_get_zero_ (); | ||
47 | handle->reconnect_task = NULL; | ||
48 | |||
49 | handle->rooms = GNUNET_CONTAINER_multihashmap_create (8, GNUNET_NO); | ||
50 | handle->contacts = GNUNET_CONTAINER_multihashmap_create (8, GNUNET_NO); | ||
51 | |||
52 | return handle; | ||
53 | } | ||
54 | |||
55 | static int | ||
56 | iterate_destroy_room (void *cls, const struct GNUNET_HashCode *key, void *value) | ||
57 | { | ||
58 | struct GNUNET_MESSENGER_Room *room = value; | ||
59 | |||
60 | destroy_room (room); | ||
61 | |||
62 | return GNUNET_YES; | ||
63 | } | ||
64 | |||
65 | static int | ||
66 | iterate_destroy_contact (void *cls, const struct GNUNET_HashCode *key, void *value) | ||
67 | { | ||
68 | struct GNUNET_MESSENGER_Contact *contact = value; | ||
69 | |||
70 | destroy_contact (contact); | ||
71 | |||
72 | return GNUNET_YES; | ||
73 | } | ||
74 | |||
75 | void | ||
76 | destroy_handle (struct GNUNET_MESSENGER_Handle *handle) | ||
77 | { | ||
78 | if (handle->reconnect_task) | ||
79 | GNUNET_SCHEDULER_cancel (handle->reconnect_task); | ||
80 | |||
81 | if (handle->mq) | ||
82 | GNUNET_MQ_destroy (handle->mq); | ||
83 | |||
84 | if (handle->name) | ||
85 | GNUNET_free(handle->name); | ||
86 | |||
87 | if (handle->pubkey) | ||
88 | GNUNET_free(handle->pubkey); | ||
89 | |||
90 | if (handle->rooms) | ||
91 | { | ||
92 | GNUNET_CONTAINER_multihashmap_iterate (handle->rooms, iterate_destroy_room, NULL); | ||
93 | |||
94 | GNUNET_CONTAINER_multihashmap_destroy (handle->rooms); | ||
95 | } | ||
96 | |||
97 | if (handle->contacts) | ||
98 | { | ||
99 | GNUNET_CONTAINER_multihashmap_iterate (handle->contacts, iterate_destroy_contact, NULL); | ||
100 | |||
101 | GNUNET_CONTAINER_multihashmap_destroy (handle->contacts); | ||
102 | } | ||
103 | |||
104 | GNUNET_free(handle->name); | ||
105 | } | ||
106 | |||
107 | void | ||
108 | set_handle_name (struct GNUNET_MESSENGER_Handle *handle, const char *name) | ||
109 | { | ||
110 | if (handle->name) | ||
111 | GNUNET_free(handle->name); | ||
112 | |||
113 | handle->name = name? GNUNET_strdup(name) : NULL; | ||
114 | } | ||
115 | |||
116 | const char* | ||
117 | get_handle_name (const struct GNUNET_MESSENGER_Handle *handle) | ||
118 | { | ||
119 | return handle->name; | ||
120 | } | ||
121 | |||
122 | void | ||
123 | set_handle_key (struct GNUNET_MESSENGER_Handle *handle, const struct GNUNET_IDENTITY_PublicKey *pubkey) | ||
124 | { | ||
125 | if (!handle->pubkey) | ||
126 | handle->pubkey = GNUNET_new(struct GNUNET_IDENTITY_PublicKey); | ||
127 | |||
128 | GNUNET_memcpy(handle->pubkey, pubkey, sizeof(*pubkey)); | ||
129 | } | ||
130 | |||
131 | const struct GNUNET_IDENTITY_PublicKey* | ||
132 | get_handle_key (const struct GNUNET_MESSENGER_Handle *handle) | ||
133 | { | ||
134 | if (!handle->pubkey) | ||
135 | { | ||
136 | struct GNUNET_IDENTITY_Ego *anonymous = GNUNET_IDENTITY_ego_get_anonymous (); | ||
137 | static struct GNUNET_IDENTITY_PublicKey pubkey; | ||
138 | |||
139 | GNUNET_IDENTITY_ego_get_public_key (anonymous, &pubkey); | ||
140 | |||
141 | return &pubkey; | ||
142 | } | ||
143 | |||
144 | return handle->pubkey; | ||
145 | } | ||
146 | |||
147 | struct GNUNET_MESSENGER_Contact* | ||
148 | get_handle_contact_by_pubkey (const struct GNUNET_MESSENGER_Handle *handle, | ||
149 | const struct GNUNET_IDENTITY_PublicKey *pubkey) | ||
150 | { | ||
151 | struct GNUNET_HashCode hash; | ||
152 | |||
153 | GNUNET_CRYPTO_hash (pubkey, sizeof(*pubkey), &hash); | ||
154 | |||
155 | struct GNUNET_MESSENGER_Contact *contact = GNUNET_CONTAINER_multihashmap_get (handle->contacts, &hash); | ||
156 | |||
157 | if (contact) | ||
158 | return contact; | ||
159 | |||
160 | contact = create_contact (pubkey); | ||
161 | |||
162 | if (GNUNET_OK == GNUNET_CONTAINER_multihashmap_put (handle->contacts, &hash, contact, | ||
163 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST)) | ||
164 | return contact; | ||
165 | |||
166 | destroy_contact (contact); | ||
167 | return NULL; | ||
168 | } | ||
169 | |||
170 | void | ||
171 | swap_handle_contact_by_pubkey (struct GNUNET_MESSENGER_Handle *handle, struct GNUNET_MESSENGER_Contact *contact, | ||
172 | const struct GNUNET_IDENTITY_PublicKey *pubkey) | ||
173 | { | ||
174 | const struct GNUNET_HashCode *hash = get_contact_id_from_key (contact); | ||
175 | |||
176 | if (GNUNET_YES == GNUNET_CONTAINER_multihashmap_remove (handle->contacts, hash, contact)) | ||
177 | { | ||
178 | GNUNET_memcpy(&(contact->public_key), pubkey, sizeof(*pubkey)); | ||
179 | |||
180 | hash = get_contact_id_from_key (contact); | ||
181 | |||
182 | GNUNET_CONTAINER_multihashmap_put (handle->contacts, hash, contact, | ||
183 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST); | ||
184 | } | ||
185 | } | ||
186 | |||
187 | void | ||
188 | open_handle_room (struct GNUNET_MESSENGER_Handle *handle, const struct GNUNET_HashCode *key) | ||
189 | { | ||
190 | struct GNUNET_MESSENGER_Room *room = GNUNET_CONTAINER_multihashmap_get (handle->rooms, key); | ||
191 | |||
192 | if (room) | ||
193 | room->opened = GNUNET_YES; | ||
194 | } | ||
195 | |||
196 | void | ||
197 | entry_handle_room_at (struct GNUNET_MESSENGER_Handle *handle, const struct GNUNET_PeerIdentity *door, | ||
198 | const struct GNUNET_HashCode *key) | ||
199 | { | ||
200 | struct GNUNET_MESSENGER_Room *room = GNUNET_CONTAINER_multihashmap_get (handle->rooms, key); | ||
201 | |||
202 | if (room) | ||
203 | add_to_list_tunnels (&(room->entries), door); | ||
204 | } | ||
205 | |||
206 | void | ||
207 | close_handle_room (struct GNUNET_MESSENGER_Handle *handle, const struct GNUNET_HashCode *key) | ||
208 | { | ||
209 | struct GNUNET_MESSENGER_Room *room = GNUNET_CONTAINER_multihashmap_get (handle->rooms, key); | ||
210 | |||
211 | if ((room) && (GNUNET_YES == GNUNET_CONTAINER_multihashmap_remove (handle->rooms, key, room))) | ||
212 | destroy_room (room); | ||
213 | } | ||
diff --git a/src/messenger/messenger_api_handle.h b/src/messenger/messenger_api_handle.h new file mode 100644 index 000000000..d6cde0106 --- /dev/null +++ b/src/messenger/messenger_api_handle.h | |||
@@ -0,0 +1,174 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/messenger_api_handle.h | ||
23 | * @brief messenger api: client implementation of GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_MESSENGER_API_HANDLE_H | ||
27 | #define GNUNET_MESSENGER_API_HANDLE_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_cadet_service.h" | ||
31 | #include "gnunet_container_lib.h" | ||
32 | #include "gnunet_crypto_lib.h" | ||
33 | #include "gnunet_identity_service.h" | ||
34 | #include "gnunet_peer_lib.h" | ||
35 | |||
36 | #include "gnunet_messenger_service.h" | ||
37 | |||
38 | #include "messenger_api_contact.h" | ||
39 | #include "messenger_api_room.h" | ||
40 | |||
41 | struct GNUNET_MESSENGER_Handle | ||
42 | { | ||
43 | const struct GNUNET_CONFIGURATION_Handle *cfg; | ||
44 | |||
45 | struct GNUNET_MQ_Handle *mq; | ||
46 | |||
47 | GNUNET_MESSENGER_IdentityCallback identity_callback; | ||
48 | void *identity_cls; | ||
49 | |||
50 | GNUNET_MESSENGER_MessageCallback msg_callback; | ||
51 | void *msg_cls; | ||
52 | |||
53 | char *name; | ||
54 | struct GNUNET_IDENTITY_PublicKey *pubkey; | ||
55 | |||
56 | struct GNUNET_TIME_Relative reconnect_time; | ||
57 | struct GNUNET_SCHEDULER_Task *reconnect_task; | ||
58 | |||
59 | struct GNUNET_CONTAINER_MultiHashMap *rooms; | ||
60 | struct GNUNET_CONTAINER_MultiHashMap *contacts; | ||
61 | }; | ||
62 | |||
63 | /** | ||
64 | * Creates and allocates a new handle using a given configuration and a custom message callback | ||
65 | * with a given closure for the client API. | ||
66 | * | ||
67 | * @param cfg Configuration | ||
68 | * @param msg_callback Message callback | ||
69 | * @param msg_cls Closure | ||
70 | * @return New handle | ||
71 | */ | ||
72 | struct GNUNET_MESSENGER_Handle* | ||
73 | create_handle (const struct GNUNET_CONFIGURATION_Handle *cfg, GNUNET_MESSENGER_IdentityCallback identity_callback, | ||
74 | void *identity_cls, GNUNET_MESSENGER_MessageCallback msg_callback, void *msg_cls); | ||
75 | |||
76 | /** | ||
77 | * Destroys a <i>handle</i> and frees its memory fully from the client API. | ||
78 | * | ||
79 | * @param handle Handle | ||
80 | */ | ||
81 | void | ||
82 | destroy_handle (struct GNUNET_MESSENGER_Handle *handle); | ||
83 | |||
84 | /** | ||
85 | * Sets the name of a <i>handle</i> to a specific <i>name</i>. | ||
86 | * | ||
87 | * @param handle Handle | ||
88 | * @param name New name | ||
89 | */ | ||
90 | void | ||
91 | set_handle_name (struct GNUNET_MESSENGER_Handle *handle, const char *name); | ||
92 | |||
93 | /** | ||
94 | * Returns the current name of a given <i>handle</i> or NULL if no valid name was assigned yet. | ||
95 | * | ||
96 | * @param handle Handle | ||
97 | * @return Name of the handle or NULL | ||
98 | */ | ||
99 | const char* | ||
100 | get_handle_name (const struct GNUNET_MESSENGER_Handle *handle); | ||
101 | |||
102 | /** | ||
103 | * Sets the public key of a given <i>handle</i> to a specific public key. | ||
104 | * | ||
105 | * @param handle Handle | ||
106 | * @param pubkey Public key | ||
107 | */ | ||
108 | void | ||
109 | set_handle_key (struct GNUNET_MESSENGER_Handle *handle, const struct GNUNET_IDENTITY_PublicKey *pubkey); | ||
110 | |||
111 | /** | ||
112 | * Returns the public key of a given <i>handle</i>. | ||
113 | * | ||
114 | * @param handle Handle | ||
115 | * @return Public key of the handle | ||
116 | */ | ||
117 | const struct GNUNET_IDENTITY_PublicKey* | ||
118 | get_handle_key (const struct GNUNET_MESSENGER_Handle *handle); | ||
119 | |||
120 | /** | ||
121 | * Returns a contact known to a <i>handle</i> identified by a given public key. If not matching | ||
122 | * contact is found, NULL gets returned. | ||
123 | * | ||
124 | * @param handle Handle | ||
125 | * @param pubkey Public key of EGO | ||
126 | * @return Contact or NULL | ||
127 | */ | ||
128 | struct GNUNET_MESSENGER_Contact* | ||
129 | get_handle_contact_by_pubkey (const struct GNUNET_MESSENGER_Handle *handle, | ||
130 | const struct GNUNET_IDENTITY_PublicKey *pubkey); | ||
131 | |||
132 | /** | ||
133 | * Changes the public key for a <i>contact</i> known to a <i>handle</i> to a specific public key and | ||
134 | * updates local map entries to access the contact by its updated key. | ||
135 | * | ||
136 | * @param handle Handle | ||
137 | * @param contact Contact | ||
138 | * @param pubkey Public key of EGO | ||
139 | */ | ||
140 | void | ||
141 | swap_handle_contact_by_pubkey (struct GNUNET_MESSENGER_Handle *handle, struct GNUNET_MESSENGER_Contact *contact, | ||
142 | const struct GNUNET_IDENTITY_PublicKey *pubkey); | ||
143 | |||
144 | /** | ||
145 | * Marks a room known to a <i>handle</i> identified by a given <i>key</i> as open. | ||
146 | * | ||
147 | * @param handle Handle | ||
148 | * @param key Key of room | ||
149 | */ | ||
150 | void | ||
151 | open_handle_room (struct GNUNET_MESSENGER_Handle *handle, const struct GNUNET_HashCode *key); | ||
152 | |||
153 | /** | ||
154 | * Adds a tunnel for a room known to a <i>handle</i> identified by a given <i>key</i> to a | ||
155 | * list of opened connections. | ||
156 | * | ||
157 | * @param handle Handle | ||
158 | * @param door Peer identity | ||
159 | * @param key Key of room | ||
160 | */ | ||
161 | void | ||
162 | entry_handle_room_at (struct GNUNET_MESSENGER_Handle *handle, const struct GNUNET_PeerIdentity *door, | ||
163 | const struct GNUNET_HashCode *key); | ||
164 | |||
165 | /** | ||
166 | * Destroys and so implicitly closes a room known to a <i>handle</i> identified by a given <i>key</i>. | ||
167 | * | ||
168 | * @param handle Handle | ||
169 | * @param key Key of room | ||
170 | */ | ||
171 | void | ||
172 | close_handle_room (struct GNUNET_MESSENGER_Handle *handle, const struct GNUNET_HashCode *key); | ||
173 | |||
174 | #endif //GNUNET_MESSENGER_API_HANDLE_H | ||
diff --git a/src/messenger/messenger_api_list_tunnels.c b/src/messenger/messenger_api_list_tunnels.c new file mode 100644 index 000000000..13d8c1906 --- /dev/null +++ b/src/messenger/messenger_api_list_tunnels.c | |||
@@ -0,0 +1,112 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/messenger_api_list_tunnels.c | ||
23 | * @brief messenger api: client and service implementation of GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "messenger_api_list_tunnels.h" | ||
27 | |||
28 | void | ||
29 | init_list_tunnels (struct GNUNET_MESSENGER_ListTunnels *tunnels) | ||
30 | { | ||
31 | GNUNET_assert(tunnels); | ||
32 | |||
33 | tunnels->head = NULL; | ||
34 | tunnels->tail = NULL; | ||
35 | } | ||
36 | |||
37 | void | ||
38 | clear_list_tunnels (struct GNUNET_MESSENGER_ListTunnels *tunnels) | ||
39 | { | ||
40 | GNUNET_assert(tunnels); | ||
41 | |||
42 | struct GNUNET_MESSENGER_ListTunnel *element; | ||
43 | |||
44 | for (element = tunnels->head; element; element = tunnels->head) | ||
45 | { | ||
46 | GNUNET_CONTAINER_DLL_remove(tunnels->head, tunnels->tail, element); | ||
47 | GNUNET_PEER_change_rc (element->peer, -1); | ||
48 | GNUNET_free(element); | ||
49 | } | ||
50 | |||
51 | tunnels->head = NULL; | ||
52 | tunnels->tail = NULL; | ||
53 | } | ||
54 | |||
55 | static int | ||
56 | compare_list_tunnels (void *cls, struct GNUNET_MESSENGER_ListTunnel *element0, | ||
57 | struct GNUNET_MESSENGER_ListTunnel *element1) | ||
58 | { | ||
59 | return ((int) element0->peer) - ((int) element1->peer); | ||
60 | } | ||
61 | |||
62 | void | ||
63 | add_to_list_tunnels (struct GNUNET_MESSENGER_ListTunnels *tunnels, const struct GNUNET_PeerIdentity *peer) | ||
64 | { | ||
65 | struct GNUNET_MESSENGER_ListTunnel *element = GNUNET_new(struct GNUNET_MESSENGER_ListTunnel); | ||
66 | |||
67 | element->peer = GNUNET_PEER_intern (peer); | ||
68 | |||
69 | GNUNET_CONTAINER_DLL_insert_sorted(struct GNUNET_MESSENGER_ListTunnel, compare_list_tunnels, NULL, tunnels->head, | ||
70 | tunnels->tail, element); | ||
71 | } | ||
72 | |||
73 | struct GNUNET_MESSENGER_ListTunnel* | ||
74 | find_list_tunnels (struct GNUNET_MESSENGER_ListTunnels *tunnels, const struct GNUNET_PeerIdentity *peer, size_t *index) | ||
75 | { | ||
76 | struct GNUNET_MESSENGER_ListTunnel *element; | ||
77 | struct GNUNET_PeerIdentity pid; | ||
78 | |||
79 | if (index) | ||
80 | *index = 0; | ||
81 | |||
82 | for (element = tunnels->head; element; element = element->next) | ||
83 | { | ||
84 | GNUNET_PEER_resolve (element->peer, &pid); | ||
85 | |||
86 | if (0 == GNUNET_memcmp(&pid, peer)) | ||
87 | return element; | ||
88 | |||
89 | if (index) | ||
90 | (*index) = (*index) + 1; | ||
91 | } | ||
92 | |||
93 | return NULL; | ||
94 | } | ||
95 | |||
96 | int | ||
97 | contains_list_tunnels (struct GNUNET_MESSENGER_ListTunnels *tunnels, const struct GNUNET_PeerIdentity *peer) | ||
98 | { | ||
99 | return find_list_tunnels (tunnels, peer, NULL) != NULL ? GNUNET_YES : GNUNET_NO; | ||
100 | } | ||
101 | |||
102 | struct GNUNET_MESSENGER_ListTunnel* | ||
103 | remove_from_list_tunnels (struct GNUNET_MESSENGER_ListTunnels *tunnels, struct GNUNET_MESSENGER_ListTunnel *element) | ||
104 | { | ||
105 | struct GNUNET_MESSENGER_ListTunnel *next = element->next; | ||
106 | |||
107 | GNUNET_CONTAINER_DLL_remove(tunnels->head, tunnels->tail, element); | ||
108 | GNUNET_PEER_change_rc (element->peer, -1); | ||
109 | GNUNET_free(element); | ||
110 | |||
111 | return next; | ||
112 | } | ||
diff --git a/src/messenger/messenger_api_list_tunnels.h b/src/messenger/messenger_api_list_tunnels.h new file mode 100644 index 000000000..0240fceb8 --- /dev/null +++ b/src/messenger/messenger_api_list_tunnels.h | |||
@@ -0,0 +1,112 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/messenger_api_list_tunnels.h | ||
23 | * @brief messenger api: client and service implementation of GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_MESSENGER_API_LIST_TUNNELS_H | ||
27 | #define GNUNET_MESSENGER_API_LIST_TUNNELS_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_peer_lib.h" | ||
31 | #include "gnunet_container_lib.h" | ||
32 | |||
33 | struct GNUNET_MESSENGER_ListTunnel | ||
34 | { | ||
35 | struct GNUNET_MESSENGER_ListTunnel *prev; | ||
36 | struct GNUNET_MESSENGER_ListTunnel *next; | ||
37 | |||
38 | GNUNET_PEER_Id peer; | ||
39 | }; | ||
40 | |||
41 | struct GNUNET_MESSENGER_ListTunnels | ||
42 | { | ||
43 | struct GNUNET_MESSENGER_ListTunnel *head; | ||
44 | struct GNUNET_MESSENGER_ListTunnel *tail; | ||
45 | }; | ||
46 | |||
47 | /** | ||
48 | * Initializes list of tunnels peer identities as empty list. | ||
49 | * | ||
50 | * @param tunnels List of peer identities | ||
51 | */ | ||
52 | void | ||
53 | init_list_tunnels (struct GNUNET_MESSENGER_ListTunnels *tunnels); | ||
54 | |||
55 | /** | ||
56 | * Clears the list of tunnels peer identities. | ||
57 | * | ||
58 | * @param tunnels List of peer identities | ||
59 | */ | ||
60 | void | ||
61 | clear_list_tunnels (struct GNUNET_MESSENGER_ListTunnels *tunnels); | ||
62 | |||
63 | /** | ||
64 | * Adds a specific <i>peer</i> from a tunnel to the end of the list. | ||
65 | * | ||
66 | * @param tunnels List of peer identities | ||
67 | * @param peer Peer identity of tunnel | ||
68 | */ | ||
69 | void | ||
70 | add_to_list_tunnels (struct GNUNET_MESSENGER_ListTunnels *tunnels, const struct GNUNET_PeerIdentity *peer); | ||
71 | |||
72 | /** | ||
73 | * Searches linearly through the list of tunnels peer identities for matching a | ||
74 | * specific <i>peer</i> identity and returns the matching element of the list. | ||
75 | * | ||
76 | * If no matching element is found, NULL gets returned. | ||
77 | * | ||
78 | * If <i>index</i> is not NULL, <i>index</i> will be overriden with the numeric index of | ||
79 | * the found element in the list. If no matching element is found, <i>index</i> will | ||
80 | * contain the total amount of elements in the list. | ||
81 | * | ||
82 | * @param tunnels List of peer identities | ||
83 | * @param peer Peer identity of tunnel | ||
84 | * @param[out] index Index of found element (optional) | ||
85 | * @return Element in the list with matching peer identity | ||
86 | */ | ||
87 | struct GNUNET_MESSENGER_ListTunnel* | ||
88 | find_list_tunnels (struct GNUNET_MESSENGER_ListTunnels *tunnels, const struct GNUNET_PeerIdentity *peer, size_t *index); | ||
89 | |||
90 | /** | ||
91 | * Tests linearly if the list of tunnels peer identities contains a specific | ||
92 | * <i>peer</i> identity and returns GNUNET_YES on success, otherwise GNUNET_NO. | ||
93 | * | ||
94 | * @param tunnels List of peer identities | ||
95 | * @param peer Peer identity of tunnel | ||
96 | * @return GNUNET_YES on success, otherwise GNUNET_NO | ||
97 | */ | ||
98 | int | ||
99 | contains_list_tunnels (struct GNUNET_MESSENGER_ListTunnels *tunnels, const struct GNUNET_PeerIdentity *peer); | ||
100 | |||
101 | /** | ||
102 | * Removes a specific <i>element</i> from the list of tunnels peer identities and returns | ||
103 | * the next element in the list. | ||
104 | * | ||
105 | * @param tunnels List of peer identities | ||
106 | * @param element Element of the list | ||
107 | * @return Next element in the list | ||
108 | */ | ||
109 | struct GNUNET_MESSENGER_ListTunnel* | ||
110 | remove_from_list_tunnels (struct GNUNET_MESSENGER_ListTunnels *tunnels, struct GNUNET_MESSENGER_ListTunnel *element); | ||
111 | |||
112 | #endif //GNUNET_MESSENGER_API_LIST_TUNNELS_H | ||
diff --git a/src/messenger/messenger_api_message.c b/src/messenger/messenger_api_message.c new file mode 100644 index 000000000..fdab60eef --- /dev/null +++ b/src/messenger/messenger_api_message.c | |||
@@ -0,0 +1,602 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/messenger_api_message.c | ||
23 | * @brief messenger api: client and service implementation of GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "messenger_api_message.h" | ||
27 | |||
28 | struct GNUNET_MESSENGER_MessageSignature | ||
29 | { | ||
30 | struct GNUNET_CRYPTO_EccSignaturePurpose purpose; | ||
31 | struct GNUNET_HashCode hash; | ||
32 | }; | ||
33 | |||
34 | struct GNUNET_MESSENGER_ShortMessage | ||
35 | { | ||
36 | enum GNUNET_MESSENGER_MessageKind kind; | ||
37 | struct GNUNET_MESSENGER_MessageBody body; | ||
38 | }; | ||
39 | |||
40 | struct GNUNET_MESSENGER_Message* | ||
41 | create_message (enum GNUNET_MESSENGER_MessageKind kind) | ||
42 | { | ||
43 | struct GNUNET_MESSENGER_Message *message = GNUNET_new(struct GNUNET_MESSENGER_Message); | ||
44 | |||
45 | message->header.kind = kind; | ||
46 | |||
47 | switch (message->header.kind) | ||
48 | { | ||
49 | case GNUNET_MESSENGER_KIND_NAME: | ||
50 | message->body.name.name = NULL; | ||
51 | break; | ||
52 | case GNUNET_MESSENGER_KIND_TEXT: | ||
53 | message->body.text.text = NULL; | ||
54 | break; | ||
55 | case GNUNET_MESSENGER_KIND_FILE: | ||
56 | message->body.file.uri = NULL; | ||
57 | break; | ||
58 | case GNUNET_MESSENGER_KIND_PRIVATE: | ||
59 | message->body.private.length = 0; | ||
60 | message->body.private.data = NULL; | ||
61 | break; | ||
62 | default: | ||
63 | break; | ||
64 | } | ||
65 | |||
66 | return message; | ||
67 | } | ||
68 | |||
69 | struct GNUNET_MESSENGER_Message* | ||
70 | copy_message (const struct GNUNET_MESSENGER_Message *message) | ||
71 | { | ||
72 | struct GNUNET_MESSENGER_Message *copy = GNUNET_new(struct GNUNET_MESSENGER_Message); | ||
73 | |||
74 | GNUNET_memcpy(copy, message, sizeof(struct GNUNET_MESSENGER_Message)); | ||
75 | |||
76 | switch (message->header.kind) | ||
77 | { | ||
78 | case GNUNET_MESSENGER_KIND_NAME: | ||
79 | copy->body.name.name = GNUNET_strdup(message->body.name.name); | ||
80 | break; | ||
81 | case GNUNET_MESSENGER_KIND_TEXT: | ||
82 | copy->body.text.text = GNUNET_strdup(message->body.text.text); | ||
83 | break; | ||
84 | case GNUNET_MESSENGER_KIND_FILE: | ||
85 | copy->body.file.uri = GNUNET_strdup(message->body.file.uri); | ||
86 | break; | ||
87 | case GNUNET_MESSENGER_KIND_PRIVATE: | ||
88 | copy->body.private.data = copy->body.private.length ? GNUNET_malloc(copy->body.private.length) : NULL; | ||
89 | |||
90 | if (copy->body.private.data) | ||
91 | { | ||
92 | GNUNET_memcpy(copy->body.private.data, message->body.private.data, copy->body.private.length); | ||
93 | } | ||
94 | |||
95 | break; | ||
96 | default: | ||
97 | break; | ||
98 | } | ||
99 | |||
100 | return copy; | ||
101 | } | ||
102 | |||
103 | static void | ||
104 | destroy_message_body (enum GNUNET_MESSENGER_MessageKind kind, struct GNUNET_MESSENGER_MessageBody *body) | ||
105 | { | ||
106 | switch (kind) | ||
107 | { | ||
108 | case GNUNET_MESSENGER_KIND_NAME: | ||
109 | GNUNET_free(body->name.name); | ||
110 | break; | ||
111 | case GNUNET_MESSENGER_KIND_TEXT: | ||
112 | GNUNET_free(body->text.text); | ||
113 | break; | ||
114 | case GNUNET_MESSENGER_KIND_FILE: | ||
115 | GNUNET_free(body->file.uri); | ||
116 | break; | ||
117 | case GNUNET_MESSENGER_KIND_PRIVATE: | ||
118 | GNUNET_free(body->private.data); | ||
119 | break; | ||
120 | default: | ||
121 | break; | ||
122 | } | ||
123 | } | ||
124 | |||
125 | void | ||
126 | destroy_message (struct GNUNET_MESSENGER_Message *message) | ||
127 | { | ||
128 | destroy_message_body (message->header.kind, &(message->body)); | ||
129 | |||
130 | GNUNET_free(message); | ||
131 | } | ||
132 | |||
133 | static void | ||
134 | fold_short_message (const struct GNUNET_MESSENGER_Message *message, struct GNUNET_MESSENGER_ShortMessage *shortened) | ||
135 | { | ||
136 | shortened->kind = message->header.kind; | ||
137 | |||
138 | GNUNET_memcpy(&(shortened->body), &(message->body), sizeof(struct GNUNET_MESSENGER_MessageBody)); | ||
139 | } | ||
140 | |||
141 | static void | ||
142 | unfold_short_message (struct GNUNET_MESSENGER_ShortMessage *shortened, struct GNUNET_MESSENGER_Message *message) | ||
143 | { | ||
144 | destroy_message_body (message->header.kind, &(message->body)); | ||
145 | |||
146 | message->header.kind = shortened->kind; | ||
147 | |||
148 | GNUNET_memcpy(&(message->body), &(shortened->body), sizeof(struct GNUNET_MESSENGER_MessageBody)); | ||
149 | } | ||
150 | |||
151 | #define member_size(type, member) sizeof(((type*) NULL)->member) | ||
152 | |||
153 | static uint16_t | ||
154 | get_message_body_kind_size (enum GNUNET_MESSENGER_MessageKind kind) | ||
155 | { | ||
156 | uint16_t length = 0; | ||
157 | |||
158 | switch (kind) | ||
159 | { | ||
160 | case GNUNET_MESSENGER_KIND_INFO: | ||
161 | length += member_size(struct GNUNET_MESSENGER_Message, body.info.host_key); | ||
162 | length += member_size(struct GNUNET_MESSENGER_Message, body.info.unique_id); | ||
163 | break; | ||
164 | case GNUNET_MESSENGER_KIND_JOIN: | ||
165 | length += member_size(struct GNUNET_MESSENGER_Message, body.join.key); | ||
166 | break; | ||
167 | case GNUNET_MESSENGER_KIND_LEAVE: | ||
168 | break; | ||
169 | case GNUNET_MESSENGER_KIND_NAME: | ||
170 | break; | ||
171 | case GNUNET_MESSENGER_KIND_KEY: | ||
172 | length += member_size(struct GNUNET_MESSENGER_Message, body.key.key); | ||
173 | break; | ||
174 | case GNUNET_MESSENGER_KIND_PEER: | ||
175 | length += member_size(struct GNUNET_MESSENGER_Message, body.peer.peer); | ||
176 | break; | ||
177 | case GNUNET_MESSENGER_KIND_ID: | ||
178 | length += member_size(struct GNUNET_MESSENGER_Message, body.id.id); | ||
179 | break; | ||
180 | case GNUNET_MESSENGER_KIND_MISS: | ||
181 | length += member_size(struct GNUNET_MESSENGER_Message, body.miss.peer); | ||
182 | break; | ||
183 | case GNUNET_MESSENGER_KIND_MERGE: | ||
184 | length += member_size(struct GNUNET_MESSENGER_Message, body.merge.previous); | ||
185 | break; | ||
186 | case GNUNET_MESSENGER_KIND_REQUEST: | ||
187 | length += member_size(struct GNUNET_MESSENGER_Message, body.request.hash); | ||
188 | break; | ||
189 | case GNUNET_MESSENGER_KIND_INVITE: | ||
190 | length += member_size(struct GNUNET_MESSENGER_Message, body.invite.door); | ||
191 | length += member_size(struct GNUNET_MESSENGER_Message, body.invite.key); | ||
192 | break; | ||
193 | case GNUNET_MESSENGER_KIND_TEXT: | ||
194 | break; | ||
195 | case GNUNET_MESSENGER_KIND_FILE: | ||
196 | length += member_size(struct GNUNET_MESSENGER_Message, body.file.key); | ||
197 | length += member_size(struct GNUNET_MESSENGER_Message, body.file.hash); | ||
198 | length += NAME_MAX; | ||
199 | break; | ||
200 | case GNUNET_MESSENGER_KIND_PRIVATE: | ||
201 | length += member_size(struct GNUNET_MESSENGER_Message, body.private.key); | ||
202 | break; | ||
203 | default: | ||
204 | break; | ||
205 | } | ||
206 | |||
207 | return length; | ||
208 | } | ||
209 | |||
210 | uint16_t | ||
211 | get_message_kind_size (enum GNUNET_MESSENGER_MessageKind kind) | ||
212 | { | ||
213 | uint16_t length = 0; | ||
214 | |||
215 | length += member_size(struct GNUNET_MESSENGER_Message, header.signature); | ||
216 | length += member_size(struct GNUNET_MESSENGER_Message, header.timestamp); | ||
217 | length += member_size(struct GNUNET_MESSENGER_Message, header.sender_id); | ||
218 | length += member_size(struct GNUNET_MESSENGER_Message, header.previous); | ||
219 | length += member_size(struct GNUNET_MESSENGER_Message, header.kind); | ||
220 | |||
221 | return length + get_message_body_kind_size (kind); | ||
222 | } | ||
223 | |||
224 | static uint16_t | ||
225 | get_message_body_size (enum GNUNET_MESSENGER_MessageKind kind, const struct GNUNET_MESSENGER_MessageBody *body) | ||
226 | { | ||
227 | uint16_t length = 0; | ||
228 | |||
229 | switch (kind) | ||
230 | { | ||
231 | case GNUNET_MESSENGER_KIND_NAME: | ||
232 | length += (body->name.name? strlen (body->name.name) : 0); | ||
233 | break; | ||
234 | case GNUNET_MESSENGER_KIND_TEXT: | ||
235 | length += strlen (body->text.text); | ||
236 | break; | ||
237 | case GNUNET_MESSENGER_KIND_FILE: | ||
238 | length += strlen (body->file.uri); | ||
239 | break; | ||
240 | case GNUNET_MESSENGER_KIND_PRIVATE: | ||
241 | length += body->private.length; | ||
242 | break; | ||
243 | default: | ||
244 | break; | ||
245 | } | ||
246 | |||
247 | return length; | ||
248 | } | ||
249 | |||
250 | uint16_t | ||
251 | get_message_size (const struct GNUNET_MESSENGER_Message *message) | ||
252 | { | ||
253 | return get_message_kind_size (message->header.kind) + get_message_body_size (message->header.kind, &(message->body)); | ||
254 | } | ||
255 | |||
256 | static uint16_t | ||
257 | get_short_message_size (const struct GNUNET_MESSENGER_ShortMessage *message) | ||
258 | { | ||
259 | if (message) | ||
260 | return sizeof(message->kind) + get_message_body_kind_size (message->kind) | ||
261 | + get_message_body_size (message->kind, &(message->body)); | ||
262 | else | ||
263 | return sizeof(message->kind); | ||
264 | } | ||
265 | |||
266 | #define min(x, y) (x < y? x : y) | ||
267 | |||
268 | #define encode_step_ext(dst, offset, src, size) do { \ | ||
269 | GNUNET_memcpy(dst + offset, src, size); \ | ||
270 | offset += size; \ | ||
271 | } while (0) | ||
272 | |||
273 | #define encode_step(dst, offset, src) do { \ | ||
274 | encode_step_ext(dst, offset, src, sizeof(*src)); \ | ||
275 | } while(0) | ||
276 | |||
277 | static void | ||
278 | encode_message_body (enum GNUNET_MESSENGER_MessageKind kind, const struct GNUNET_MESSENGER_MessageBody *body, | ||
279 | uint16_t length, char *buffer, uint16_t offset) | ||
280 | { | ||
281 | switch (kind) | ||
282 | { | ||
283 | case GNUNET_MESSENGER_KIND_INFO: | ||
284 | encode_step(buffer, offset, &(body->info.host_key)); | ||
285 | encode_step(buffer, offset, &(body->info.unique_id)); | ||
286 | break; | ||
287 | case GNUNET_MESSENGER_KIND_JOIN: | ||
288 | encode_step(buffer, offset, &(body->join.key)); | ||
289 | break; | ||
290 | case GNUNET_MESSENGER_KIND_LEAVE: | ||
291 | break; | ||
292 | case GNUNET_MESSENGER_KIND_NAME: | ||
293 | if (body->name.name) | ||
294 | encode_step_ext(buffer, offset, body->name.name, min(length - offset, strlen(body->name.name))); | ||
295 | break; | ||
296 | case GNUNET_MESSENGER_KIND_KEY: | ||
297 | encode_step(buffer, offset, &(body->key.key)); | ||
298 | break; | ||
299 | case GNUNET_MESSENGER_KIND_PEER: | ||
300 | encode_step(buffer, offset, &(body->peer.peer)); | ||
301 | break; | ||
302 | case GNUNET_MESSENGER_KIND_ID: | ||
303 | encode_step(buffer, offset, &(body->id.id)); | ||
304 | break; | ||
305 | case GNUNET_MESSENGER_KIND_MISS: | ||
306 | encode_step(buffer, offset, &(body->miss.peer)); | ||
307 | break; | ||
308 | case GNUNET_MESSENGER_KIND_MERGE: | ||
309 | encode_step(buffer, offset, &(body->merge.previous)); | ||
310 | break; | ||
311 | case GNUNET_MESSENGER_KIND_REQUEST: | ||
312 | encode_step(buffer, offset, &(body->request.hash)); | ||
313 | break; | ||
314 | case GNUNET_MESSENGER_KIND_INVITE: | ||
315 | encode_step(buffer, offset, &(body->invite.door)); | ||
316 | encode_step(buffer, offset, &(body->invite.key)); | ||
317 | break; | ||
318 | case GNUNET_MESSENGER_KIND_TEXT: | ||
319 | encode_step_ext(buffer, offset, body->text.text, min(length - offset, strlen(body->text.text))); | ||
320 | break; | ||
321 | case GNUNET_MESSENGER_KIND_FILE: | ||
322 | encode_step(buffer, offset, &(body->file.key)); | ||
323 | encode_step(buffer, offset, &(body->file.hash)); | ||
324 | encode_step_ext(buffer, offset, body->file.name, NAME_MAX); | ||
325 | encode_step_ext(buffer, offset, body->file.uri, min(length - offset, strlen(body->file.uri))); | ||
326 | break; | ||
327 | case GNUNET_MESSENGER_KIND_PRIVATE: | ||
328 | encode_step(buffer, offset, &(body->private.key)); | ||
329 | encode_step_ext(buffer, offset, body->private.data, min(length - offset, body->private.length)); | ||
330 | break; | ||
331 | default: | ||
332 | break; | ||
333 | } | ||
334 | } | ||
335 | |||
336 | void | ||
337 | encode_message (const struct GNUNET_MESSENGER_Message *message, uint16_t length, char *buffer) | ||
338 | { | ||
339 | uint16_t offset = 0; | ||
340 | |||
341 | encode_step(buffer, offset, &(message->header.signature)); | ||
342 | encode_step(buffer, offset, &(message->header.timestamp)); | ||
343 | encode_step(buffer, offset, &(message->header.sender_id)); | ||
344 | encode_step(buffer, offset, &(message->header.previous)); | ||
345 | encode_step(buffer, offset, &(message->header.kind)); | ||
346 | |||
347 | encode_message_body (message->header.kind, &(message->body), length, buffer, offset); | ||
348 | } | ||
349 | |||
350 | static void | ||
351 | encode_short_message (const struct GNUNET_MESSENGER_ShortMessage *message, uint16_t length, char *buffer) | ||
352 | { | ||
353 | uint16_t offset = 0; | ||
354 | |||
355 | encode_step(buffer, offset, &(message->kind)); | ||
356 | |||
357 | encode_message_body (message->kind, &(message->body), length, buffer, offset); | ||
358 | } | ||
359 | |||
360 | #define decode_step_ext(src, offset, dst, size) do { \ | ||
361 | GNUNET_memcpy(dst, src + offset, size); \ | ||
362 | offset += size; \ | ||
363 | } while (0) | ||
364 | |||
365 | #define decode_step(src, offset, dst) do { \ | ||
366 | decode_step_ext(src, offset, dst, sizeof(*dst)); \ | ||
367 | } while (0) | ||
368 | |||
369 | #define decode_step_malloc(src, offset, dst, size, zero) do { \ | ||
370 | dst = GNUNET_malloc(size + zero); \ | ||
371 | if (zero) dst[size] = 0; \ | ||
372 | decode_step_ext(src, offset, dst, size); \ | ||
373 | } while (0) | ||
374 | |||
375 | static void | ||
376 | decode_message_body (enum GNUNET_MESSENGER_MessageKind *kind, struct GNUNET_MESSENGER_MessageBody *body, | ||
377 | uint16_t length, const char *buffer, uint16_t offset) | ||
378 | { | ||
379 | switch (*kind) | ||
380 | { | ||
381 | case GNUNET_MESSENGER_KIND_INFO: | ||
382 | decode_step(buffer, offset, &(body->info.host_key)); | ||
383 | decode_step(buffer, offset, &(body->info.unique_id)); | ||
384 | break; | ||
385 | case GNUNET_MESSENGER_KIND_JOIN: | ||
386 | decode_step(buffer, offset, &(body->join.key)); | ||
387 | break; | ||
388 | case GNUNET_MESSENGER_KIND_LEAVE: | ||
389 | break; | ||
390 | case GNUNET_MESSENGER_KIND_NAME: | ||
391 | if (length - offset > 0) | ||
392 | decode_step_malloc(buffer, offset, body->name.name, length - offset, 1); | ||
393 | else | ||
394 | body->name.name = NULL; | ||
395 | break; | ||
396 | case GNUNET_MESSENGER_KIND_KEY: | ||
397 | decode_step(buffer, offset, &(body->key.key)); | ||
398 | break; | ||
399 | case GNUNET_MESSENGER_KIND_PEER: | ||
400 | decode_step(buffer, offset, &(body->peer.peer)); | ||
401 | break; | ||
402 | case GNUNET_MESSENGER_KIND_ID: | ||
403 | decode_step(buffer, offset, &(body->id.id)); | ||
404 | break; | ||
405 | case GNUNET_MESSENGER_KIND_MISS: | ||
406 | decode_step(buffer, offset, &(body->miss.peer)); | ||
407 | break; | ||
408 | case GNUNET_MESSENGER_KIND_MERGE: | ||
409 | decode_step(buffer, offset, &(body->merge.previous)); | ||
410 | break; | ||
411 | case GNUNET_MESSENGER_KIND_REQUEST: | ||
412 | decode_step(buffer, offset, &(body->request.hash)); | ||
413 | break; | ||
414 | case GNUNET_MESSENGER_KIND_INVITE: | ||
415 | decode_step(buffer, offset, &(body->invite.door)); | ||
416 | decode_step(buffer, offset, &(body->invite.key)); | ||
417 | break; | ||
418 | case GNUNET_MESSENGER_KIND_TEXT: | ||
419 | decode_step_malloc(buffer, offset, body->text.text, length - offset, 1); | ||
420 | break; | ||
421 | case GNUNET_MESSENGER_KIND_FILE: | ||
422 | decode_step(buffer, offset, &(body->file.key)); | ||
423 | decode_step(buffer, offset, &(body->file.hash)); | ||
424 | decode_step_ext(buffer, offset, body->file.name, NAME_MAX); | ||
425 | decode_step_malloc(buffer, offset, body->file.uri, length - offset, 1); | ||
426 | break; | ||
427 | case GNUNET_MESSENGER_KIND_PRIVATE: | ||
428 | decode_step(buffer, offset, &(body->private.key)); | ||
429 | |||
430 | body->private.length = (length - offset); | ||
431 | decode_step_malloc(buffer, offset, body->private.data, length - offset, 0); | ||
432 | break; | ||
433 | default: | ||
434 | *kind = GNUNET_MESSENGER_KIND_UNKNOWN; | ||
435 | break; | ||
436 | } | ||
437 | } | ||
438 | |||
439 | int | ||
440 | decode_message (struct GNUNET_MESSENGER_Message *message, uint16_t length, const char *buffer) | ||
441 | { | ||
442 | uint16_t offset = 0; | ||
443 | |||
444 | if (length < get_message_kind_size (GNUNET_MESSENGER_KIND_UNKNOWN)) | ||
445 | return GNUNET_NO; | ||
446 | |||
447 | decode_step(buffer, offset, &(message->header.signature)); | ||
448 | decode_step(buffer, offset, &(message->header.timestamp)); | ||
449 | decode_step(buffer, offset, &(message->header.sender_id)); | ||
450 | decode_step(buffer, offset, &(message->header.previous)); | ||
451 | decode_step(buffer, offset, &(message->header.kind)); | ||
452 | |||
453 | if (length < get_message_kind_size (message->header.kind)) | ||
454 | return GNUNET_NO; | ||
455 | |||
456 | decode_message_body (&(message->header.kind), &(message->body), length, buffer, offset); | ||
457 | |||
458 | return GNUNET_YES; | ||
459 | } | ||
460 | |||
461 | static int | ||
462 | decode_short_message (struct GNUNET_MESSENGER_ShortMessage *message, uint16_t length, const char *buffer) | ||
463 | { | ||
464 | uint16_t offset = 0; | ||
465 | |||
466 | if (length < get_short_message_size (NULL)) | ||
467 | return GNUNET_NO; | ||
468 | |||
469 | decode_step(buffer, offset, &(message->kind)); | ||
470 | |||
471 | if (length < get_short_message_size (message)) | ||
472 | return GNUNET_NO; | ||
473 | |||
474 | decode_message_body (&(message->kind), &(message->body), length, buffer, offset); | ||
475 | |||
476 | return GNUNET_YES; | ||
477 | } | ||
478 | |||
479 | void | ||
480 | hash_message (uint16_t length, const char *buffer, struct GNUNET_HashCode *hash) | ||
481 | { | ||
482 | GNUNET_CRYPTO_hash (buffer + sizeof(struct GNUNET_CRYPTO_EcdsaSignature), | ||
483 | length - sizeof(struct GNUNET_CRYPTO_EcdsaSignature), hash); | ||
484 | } | ||
485 | |||
486 | void | ||
487 | sign_message (struct GNUNET_MESSENGER_Message *message, uint16_t length, char *buffer, | ||
488 | const struct GNUNET_HashCode *hash, const struct GNUNET_MESSENGER_Ego *ego) | ||
489 | { | ||
490 | struct GNUNET_MESSENGER_MessageSignature signature; | ||
491 | |||
492 | signature.purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_CHAT_MESSAGE); | ||
493 | signature.purpose.size = htonl (sizeof(signature)); | ||
494 | |||
495 | GNUNET_memcpy(&(signature.hash), hash, sizeof(struct GNUNET_HashCode)); | ||
496 | |||
497 | GNUNET_IDENTITY_sign(&(ego->priv), &signature, &(message->header.signature)); | ||
498 | GNUNET_memcpy(buffer, &(message->header.signature), sizeof(struct GNUNET_CRYPTO_EcdsaSignature)); | ||
499 | } | ||
500 | |||
501 | int | ||
502 | verify_message (const struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash, | ||
503 | const struct GNUNET_IDENTITY_PublicKey *key) | ||
504 | { | ||
505 | struct GNUNET_MESSENGER_MessageSignature signature; | ||
506 | |||
507 | signature.purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_CHAT_MESSAGE); | ||
508 | signature.purpose.size = htonl (sizeof(signature)); | ||
509 | |||
510 | GNUNET_memcpy(&(signature.hash), hash, sizeof(struct GNUNET_HashCode)); | ||
511 | |||
512 | return GNUNET_IDENTITY_signature_verify(GNUNET_SIGNATURE_PURPOSE_CHAT_MESSAGE, &signature, | ||
513 | &(message->header.signature), key); | ||
514 | } | ||
515 | |||
516 | int | ||
517 | encrypt_message (struct GNUNET_MESSENGER_Message *message, const struct GNUNET_IDENTITY_PublicKey *key) | ||
518 | { | ||
519 | struct GNUNET_MESSENGER_ShortMessage shortened; | ||
520 | |||
521 | fold_short_message (message, &shortened); | ||
522 | |||
523 | const uint16_t length = get_short_message_size (&shortened); | ||
524 | |||
525 | message->header.kind = GNUNET_MESSENGER_KIND_PRIVATE; | ||
526 | message->body.private.data = GNUNET_malloc(length); | ||
527 | |||
528 | encode_short_message (&shortened, length, message->body.private.data); | ||
529 | |||
530 | if (GNUNET_IDENTITY_encrypt (message->body.private.data, length, key, &(message->body.private.key), | ||
531 | message->body.private.data) | ||
532 | == length) | ||
533 | { | ||
534 | destroy_message_body (shortened.kind, &(shortened.body)); | ||
535 | return GNUNET_YES; | ||
536 | } | ||
537 | else | ||
538 | { | ||
539 | unfold_short_message (&shortened, message); | ||
540 | return GNUNET_NO; | ||
541 | } | ||
542 | } | ||
543 | |||
544 | int | ||
545 | decrypt_message (struct GNUNET_MESSENGER_Message *message, const struct GNUNET_IDENTITY_PrivateKey *key) | ||
546 | { | ||
547 | if (message->body.private.length != GNUNET_IDENTITY_decrypt (message->body.private.data, | ||
548 | message->body.private.length, key, | ||
549 | &(message->body.private.key), | ||
550 | message->body.private.data)) | ||
551 | return GNUNET_NO; | ||
552 | |||
553 | struct GNUNET_MESSENGER_ShortMessage shortened; | ||
554 | |||
555 | if (GNUNET_YES != decode_short_message (&shortened, message->body.private.length, message->body.private.data)) | ||
556 | return GNUNET_NO; | ||
557 | |||
558 | unfold_short_message (&shortened, message); | ||
559 | return GNUNET_YES; | ||
560 | } | ||
561 | |||
562 | struct GNUNET_MQ_Envelope* | ||
563 | pack_message (struct GNUNET_MESSENGER_Message *message, struct GNUNET_HashCode *hash, | ||
564 | const struct GNUNET_MESSENGER_Ego *ego, int mode) | ||
565 | { | ||
566 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Packing message: %u\n", message->header.kind); | ||
567 | |||
568 | struct GNUNET_MessageHeader *header; | ||
569 | |||
570 | uint16_t length = get_message_size (message); | ||
571 | |||
572 | struct GNUNET_MQ_Envelope *env; | ||
573 | char *buffer; | ||
574 | |||
575 | if (GNUNET_MESSENGER_PACK_MODE_ENVELOPE == mode) | ||
576 | { | ||
577 | env = GNUNET_MQ_msg_extra(header, length, GNUNET_MESSAGE_TYPE_CADET_CLI); | ||
578 | |||
579 | buffer = (char*) &(header[1]); | ||
580 | } | ||
581 | else | ||
582 | { | ||
583 | env = NULL; | ||
584 | |||
585 | buffer = GNUNET_malloc(length); | ||
586 | } | ||
587 | |||
588 | encode_message (message, length, buffer); | ||
589 | |||
590 | if (hash) | ||
591 | { | ||
592 | hash_message (length, buffer, hash); | ||
593 | |||
594 | if (ego) | ||
595 | sign_message (message, length, buffer, hash, ego); | ||
596 | } | ||
597 | |||
598 | if (GNUNET_MESSENGER_PACK_MODE_ENVELOPE != mode) | ||
599 | GNUNET_free(buffer); | ||
600 | |||
601 | return env; | ||
602 | } | ||
diff --git a/src/messenger/messenger_api_message.h b/src/messenger/messenger_api_message.h new file mode 100644 index 000000000..0f0a97e9c --- /dev/null +++ b/src/messenger/messenger_api_message.h | |||
@@ -0,0 +1,190 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/messenger_api_message.h | ||
23 | * @brief messenger api: client and service implementation of GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_MESSENGER_API_MESSAGE_H | ||
27 | #define GNUNET_MESSENGER_API_MESSAGE_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_crypto_lib.h" | ||
31 | #include "gnunet_identity_service.h" | ||
32 | #include "gnunet_mq_lib.h" | ||
33 | #include "gnunet_signatures.h" | ||
34 | |||
35 | #include "gnunet_messenger_service.h" | ||
36 | |||
37 | #include "messenger_api_ego.h" | ||
38 | |||
39 | /** | ||
40 | * Creates and allocates a new message with a specific <i>kind</i>. | ||
41 | * | ||
42 | * @param kind Kind of message | ||
43 | * @return New message | ||
44 | */ | ||
45 | struct GNUNET_MESSENGER_Message* | ||
46 | create_message (enum GNUNET_MESSENGER_MessageKind kind); | ||
47 | |||
48 | /** | ||
49 | * Creates and allocates a copy of a given <i>message</i>. | ||
50 | * | ||
51 | * @param message Message | ||
52 | * @return New message | ||
53 | */ | ||
54 | struct GNUNET_MESSENGER_Message* | ||
55 | copy_message (const struct GNUNET_MESSENGER_Message *message); | ||
56 | |||
57 | /** | ||
58 | * Destroys a message and frees its memory fully. | ||
59 | * | ||
60 | * @param message Message | ||
61 | */ | ||
62 | void | ||
63 | destroy_message (struct GNUNET_MESSENGER_Message *message); | ||
64 | |||
65 | /** | ||
66 | * Returns the minimal size in bytes to encode a message of a specific <i>kind</i>. | ||
67 | * | ||
68 | * @param kind Kind of message | ||
69 | * @return Minimal size to encode | ||
70 | */ | ||
71 | uint16_t | ||
72 | get_message_kind_size (enum GNUNET_MESSENGER_MessageKind kind); | ||
73 | |||
74 | /** | ||
75 | * Returns the exact size in bytes to encode a given <i>message</i>. | ||
76 | * | ||
77 | * @param message Message | ||
78 | * @return Size to encode | ||
79 | */ | ||
80 | uint16_t | ||
81 | get_message_size (const struct GNUNET_MESSENGER_Message *message); | ||
82 | |||
83 | /** | ||
84 | * Encodes a given <i>message</i> into a <i>buffer</i> of a maximal <i>length</i> in bytes. | ||
85 | * | ||
86 | * @param message Message | ||
87 | * @param length Maximal length to encode | ||
88 | * @param[out] buffer Buffer | ||
89 | */ | ||
90 | void | ||
91 | encode_message (const struct GNUNET_MESSENGER_Message *message, uint16_t length, char *buffer); | ||
92 | |||
93 | /** | ||
94 | * Decodes a <i>message</i> from a given <i>buffer</i> of a maximal <i>length</i> in bytes. | ||
95 | * | ||
96 | * If the buffer is too small for a message of its decoded kind the function fails with | ||
97 | * resulting GNUNET_NO after decoding only the messages header. | ||
98 | * | ||
99 | * On success the function returns GNUNET_YES. | ||
100 | * | ||
101 | * @param[out] message Message | ||
102 | * @param length Maximal length to decode | ||
103 | * @param buffer Buffer | ||
104 | * @return GNUNET_YES on success, otherwise GNUNET_NO | ||
105 | */ | ||
106 | int | ||
107 | decode_message (struct GNUNET_MESSENGER_Message *message, uint16_t length, const char *buffer); | ||
108 | |||
109 | /** | ||
110 | * Calculates a <i>hash</i> of a given <i>buffer</i> of a <i>length</i> in bytes. | ||
111 | * | ||
112 | * @param length Length of buffer | ||
113 | * @param buffer Buffer | ||
114 | * @param[out] hash Hash | ||
115 | */ | ||
116 | void | ||
117 | hash_message (uint16_t length, const char *buffer, struct GNUNET_HashCode *hash); | ||
118 | |||
119 | /** | ||
120 | * Signs the <i>hash</i> of a <i>message</i> with a given <i>ego</i> and writes the signature | ||
121 | * into the <i>buffer</i> as well. | ||
122 | * | ||
123 | * @param[out] message Message | ||
124 | * @param length Length of buffer | ||
125 | * @param[out] buffer Buffer | ||
126 | * @param hash Hash of message | ||
127 | * @param ego EGO | ||
128 | */ | ||
129 | void | ||
130 | sign_message (struct GNUNET_MESSENGER_Message *message, uint16_t length, char *buffer, | ||
131 | const struct GNUNET_HashCode *hash, const struct GNUNET_MESSENGER_Ego *ego); | ||
132 | |||
133 | /** | ||
134 | * Verifies the signature of a given <i>message</i> and its <i>hash</i> with a specific | ||
135 | * public key. The function returns GNUNET_OK if the signature was valid, otherwise | ||
136 | * GNUNET_SYSERR. | ||
137 | * | ||
138 | * @param message Message | ||
139 | * @param hash Hash of message | ||
140 | * @param key Public key of EGO | ||
141 | * @return GNUNET_OK on success, otherwise GNUNET_SYSERR | ||
142 | */ | ||
143 | int | ||
144 | verify_message (const struct GNUNET_MESSENGER_Message *message, const struct GNUNET_HashCode *hash, | ||
145 | const struct GNUNET_IDENTITY_PublicKey *key); | ||
146 | |||
147 | /** | ||
148 | * Encrypts a <i>message</i> using a given public <i>key</i> and replaces its body | ||
149 | * and kind with the now private encrypted <i>message</i>. The function returns | ||
150 | * GNUNET_YES if the operation succeeded, otherwise GNUNET_NO. | ||
151 | * | ||
152 | * @param message Message | ||
153 | * @param key Public key of EGO | ||
154 | * @return GNUNET_YES on success, otherwise GNUNET_NO | ||
155 | */ | ||
156 | int | ||
157 | encrypt_message (struct GNUNET_MESSENGER_Message *message, const struct GNUNET_IDENTITY_PublicKey *key); | ||
158 | |||
159 | /** | ||
160 | * Decrypts a private <i>message</i> using a given private <i>key</i> and replaces its body | ||
161 | * and kind with the inner encrypted message. The function returns GNUNET_YES if the | ||
162 | * operation succeeded, otherwise GNUNET_NO. | ||
163 | * | ||
164 | * @param message Message | ||
165 | * @param key Private key of EGO | ||
166 | * @return GNUNET_YES on success, otherwise GNUNET_NO | ||
167 | */ | ||
168 | int | ||
169 | decrypt_message (struct GNUNET_MESSENGER_Message *message, const struct GNUNET_IDENTITY_PrivateKey *key); | ||
170 | |||
171 | #define GNUNET_MESSENGER_PACK_MODE_ENVELOPE 0x1 | ||
172 | #define GNUNET_MESSENGER_PACK_MODE_UNKNOWN 0x0 | ||
173 | |||
174 | /** | ||
175 | * Encodes the <i>message</i> to pack it into a newly allocated envelope if <i>mode</i> | ||
176 | * is equal to GNUNET_MESSENGER_PACK_MODE_ENVELOPE. Independent of the mode the message | ||
177 | * will be hashed if <i>hash</i> is not NULL and it will be signed if the <i>ego</i> is | ||
178 | * not NULL. | ||
179 | * | ||
180 | * @param[out] message Message | ||
181 | * @param[out] hash Hash of message | ||
182 | * @param ego EGO to sign | ||
183 | * @param mode Mode of packing | ||
184 | * @return Envelope or NULL | ||
185 | */ | ||
186 | struct GNUNET_MQ_Envelope* | ||
187 | pack_message (struct GNUNET_MESSENGER_Message *message, struct GNUNET_HashCode *hash, | ||
188 | const struct GNUNET_MESSENGER_Ego *ego, int mode); | ||
189 | |||
190 | #endif //GNUNET_MESSENGER_API_MESSAGE_H | ||
diff --git a/src/messenger/messenger_api_room.c b/src/messenger/messenger_api_room.c new file mode 100644 index 000000000..5fedf1a78 --- /dev/null +++ b/src/messenger/messenger_api_room.c | |||
@@ -0,0 +1,189 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/messenger_api_room.c | ||
23 | * @brief messenger api: client implementation of GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #include "messenger_api_room.h" | ||
27 | |||
28 | #include "messenger_api_handle.h" | ||
29 | |||
30 | struct GNUNET_MESSENGER_Room* | ||
31 | create_room (struct GNUNET_MESSENGER_Handle *handle, const struct GNUNET_HashCode *key) | ||
32 | { | ||
33 | struct GNUNET_MESSENGER_Room *room = GNUNET_new(struct GNUNET_MESSENGER_Room); | ||
34 | |||
35 | room->handle = handle; | ||
36 | GNUNET_memcpy(&(room->key), key, sizeof(*key)); | ||
37 | |||
38 | room->opened = GNUNET_NO; | ||
39 | room->contact_id = NULL; | ||
40 | |||
41 | room->members = GNUNET_CONTAINER_multishortmap_create (8, GNUNET_NO); | ||
42 | |||
43 | init_list_tunnels (&(room->entries)); | ||
44 | |||
45 | room->messages = GNUNET_CONTAINER_multihashmap_create (8, GNUNET_NO); | ||
46 | |||
47 | return room; | ||
48 | } | ||
49 | |||
50 | static int | ||
51 | iterate_destroy_message (void *cls, const struct GNUNET_HashCode *key, void *value) | ||
52 | { | ||
53 | struct GNUNET_MESSENGER_Message *message = value; | ||
54 | |||
55 | destroy_message (message); | ||
56 | |||
57 | return GNUNET_YES; | ||
58 | } | ||
59 | |||
60 | void | ||
61 | destroy_room (struct GNUNET_MESSENGER_Room *room) | ||
62 | { | ||
63 | if (room->members) | ||
64 | GNUNET_CONTAINER_multishortmap_destroy (room->members); | ||
65 | |||
66 | clear_list_tunnels (&(room->entries)); | ||
67 | |||
68 | if (room->messages) | ||
69 | { | ||
70 | GNUNET_CONTAINER_multihashmap_iterate (room->messages, iterate_destroy_message, NULL); | ||
71 | |||
72 | GNUNET_CONTAINER_multihashmap_destroy (room->messages); | ||
73 | } | ||
74 | |||
75 | if (room->contact_id) | ||
76 | GNUNET_free(room->contact_id); | ||
77 | |||
78 | GNUNET_free(room); | ||
79 | } | ||
80 | |||
81 | const struct GNUNET_MESSENGER_Message* | ||
82 | get_room_message (const struct GNUNET_MESSENGER_Room *room, const struct GNUNET_HashCode *hash) | ||
83 | { | ||
84 | return GNUNET_CONTAINER_multihashmap_get (room->messages, hash); | ||
85 | } | ||
86 | |||
87 | static void | ||
88 | handle_join_message (struct GNUNET_MESSENGER_Room *room, const struct GNUNET_MESSENGER_Message *message, | ||
89 | const struct GNUNET_HashCode *hash) | ||
90 | { | ||
91 | struct GNUNET_MESSENGER_Contact *contact = get_handle_contact_by_pubkey (room->handle, &(message->body.join.key)); | ||
92 | |||
93 | if (contact) | ||
94 | GNUNET_CONTAINER_multishortmap_put (room->members, &(message->header.sender_id), contact, | ||
95 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST); | ||
96 | } | ||
97 | |||
98 | static void | ||
99 | handle_leave_message (struct GNUNET_MESSENGER_Room *room, const struct GNUNET_MESSENGER_Message *message, | ||
100 | const struct GNUNET_HashCode *hash) | ||
101 | { | ||
102 | GNUNET_CONTAINER_multishortmap_remove_all (room->members, &(message->header.sender_id)); | ||
103 | } | ||
104 | |||
105 | static void | ||
106 | handle_name_message (struct GNUNET_MESSENGER_Room *room, const struct GNUNET_MESSENGER_Message *message, | ||
107 | const struct GNUNET_HashCode *hash) | ||
108 | { | ||
109 | struct GNUNET_MESSENGER_Contact *contact = GNUNET_CONTAINER_multishortmap_get (room->members, | ||
110 | &(message->header.sender_id)); | ||
111 | |||
112 | if (contact) | ||
113 | set_contact_name (contact, message->body.name.name); | ||
114 | } | ||
115 | |||
116 | static void | ||
117 | handle_key_message (struct GNUNET_MESSENGER_Room *room, const struct GNUNET_MESSENGER_Message *message, | ||
118 | const struct GNUNET_HashCode *hash) | ||
119 | { | ||
120 | struct GNUNET_MESSENGER_Contact *contact = GNUNET_CONTAINER_multishortmap_get (room->members, | ||
121 | &(message->header.sender_id)); | ||
122 | |||
123 | if (contact) | ||
124 | swap_handle_contact_by_pubkey (room->handle, contact, &(message->body.key.key)); | ||
125 | } | ||
126 | |||
127 | static void | ||
128 | handle_id_message (struct GNUNET_MESSENGER_Room *room, const struct GNUNET_MESSENGER_Message *message, | ||
129 | const struct GNUNET_HashCode *hash) | ||
130 | { | ||
131 | struct GNUNET_MESSENGER_Contact *contact = GNUNET_CONTAINER_multishortmap_get (room->members, | ||
132 | &(message->header.sender_id)); | ||
133 | |||
134 | if ((contact) && (GNUNET_OK | ||
135 | == GNUNET_CONTAINER_multishortmap_put (room->members, &(message->body.id.id), contact, | ||
136 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST))) | ||
137 | GNUNET_CONTAINER_multishortmap_remove (room->members, &(message->header.sender_id), contact); | ||
138 | } | ||
139 | |||
140 | static void | ||
141 | handle_miss_message (struct GNUNET_MESSENGER_Room *room, const struct GNUNET_MESSENGER_Message *message, | ||
142 | const struct GNUNET_HashCode *hash) | ||
143 | { | ||
144 | if ((room->contact_id) && (0 == GNUNET_memcmp(&(message->header.sender_id), room->contact_id))) | ||
145 | { | ||
146 | struct GNUNET_MESSENGER_ListTunnel *match = find_list_tunnels (&(room->entries), &(message->body.miss.peer), NULL); | ||
147 | |||
148 | if (match) | ||
149 | remove_from_list_tunnels (&(room->entries), match); | ||
150 | } | ||
151 | } | ||
152 | |||
153 | void | ||
154 | handle_room_message (struct GNUNET_MESSENGER_Room *room, const struct GNUNET_MESSENGER_Message *message, | ||
155 | const struct GNUNET_HashCode *hash) | ||
156 | { | ||
157 | if (GNUNET_NO != GNUNET_CONTAINER_multihashmap_contains (room->messages, hash)) | ||
158 | return; | ||
159 | |||
160 | switch (message->header.kind) | ||
161 | { | ||
162 | case GNUNET_MESSENGER_KIND_JOIN: | ||
163 | handle_join_message (room, message, hash); | ||
164 | break; | ||
165 | case GNUNET_MESSENGER_KIND_LEAVE: | ||
166 | handle_leave_message (room, message, hash); | ||
167 | break; | ||
168 | case GNUNET_MESSENGER_KIND_NAME: | ||
169 | handle_name_message (room, message, hash); | ||
170 | break; | ||
171 | case GNUNET_MESSENGER_KIND_KEY: | ||
172 | handle_key_message (room, message, hash); | ||
173 | break; | ||
174 | case GNUNET_MESSENGER_KIND_ID: | ||
175 | handle_id_message (room, message, hash); | ||
176 | break; | ||
177 | case GNUNET_MESSENGER_KIND_MISS: | ||
178 | handle_miss_message (room, message, hash); | ||
179 | break; | ||
180 | default: | ||
181 | break; | ||
182 | } | ||
183 | |||
184 | struct GNUNET_MESSENGER_Message *clone = copy_message (message); | ||
185 | |||
186 | if (GNUNET_OK != GNUNET_CONTAINER_multihashmap_put (room->messages, hash, clone, | ||
187 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST)) | ||
188 | destroy_message (clone); | ||
189 | } | ||
diff --git a/src/messenger/messenger_api_room.h b/src/messenger/messenger_api_room.h new file mode 100644 index 000000000..0038128d8 --- /dev/null +++ b/src/messenger/messenger_api_room.h | |||
@@ -0,0 +1,95 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 | * @author Tobias Frisch | ||
22 | * @file src/messenger/messenger_api_room.h | ||
23 | * @brief messenger api: client implementation of GNUnet MESSENGER service | ||
24 | */ | ||
25 | |||
26 | #ifndef GNUNET_MESSENGER_API_ROOM_H | ||
27 | #define GNUNET_MESSENGER_API_ROOM_H | ||
28 | |||
29 | #include "platform.h" | ||
30 | #include "gnunet_container_lib.h" | ||
31 | #include "gnunet_crypto_lib.h" | ||
32 | |||
33 | #include "gnunet_messenger_service.h" | ||
34 | |||
35 | #include "messenger_api_list_tunnels.h" | ||
36 | #include "messenger_api_contact.h" | ||
37 | #include "messenger_api_message.h" | ||
38 | |||
39 | struct GNUNET_MESSENGER_Room | ||
40 | { | ||
41 | struct GNUNET_MESSENGER_Handle *handle; | ||
42 | struct GNUNET_HashCode key; | ||
43 | |||
44 | int opened; | ||
45 | |||
46 | struct GNUNET_ShortHashCode *contact_id; | ||
47 | |||
48 | struct GNUNET_CONTAINER_MultiShortmap *members; | ||
49 | struct GNUNET_MESSENGER_ListTunnels entries; | ||
50 | |||
51 | struct GNUNET_CONTAINER_MultiHashMap *messages; | ||
52 | }; | ||
53 | |||
54 | /** | ||
55 | * Creates and allocates a new room for a <i>handle</i> with a given <i>key</i> for the client API. | ||
56 | * | ||
57 | * @param handle Handle | ||
58 | * @param key Key of room | ||
59 | * @return New room | ||
60 | */ | ||
61 | struct GNUNET_MESSENGER_Room* | ||
62 | create_room (struct GNUNET_MESSENGER_Handle *handle, const struct GNUNET_HashCode *key); | ||
63 | |||
64 | /** | ||
65 | * Destroys a room and frees its memory fully from the client API. | ||
66 | * | ||
67 | * @param room Room | ||
68 | */ | ||
69 | void | ||
70 | destroy_room (struct GNUNET_MESSENGER_Room *room); | ||
71 | |||
72 | /** | ||
73 | * Returns a message locally stored from a map for a given <i>hash</i> in a <i>room</i>. If no matching | ||
74 | * message is found, NULL gets returned. | ||
75 | * | ||
76 | * @param room Room | ||
77 | * @param hash Hash of message | ||
78 | * @return Message or NULL | ||
79 | */ | ||
80 | const struct GNUNET_MESSENGER_Message* | ||
81 | get_room_message (const struct GNUNET_MESSENGER_Room *room, const struct GNUNET_HashCode *hash); | ||
82 | |||
83 | /** | ||
84 | * Handles a <i>message</i> with a given <i>hash</i> in a <i>room</i> for the client API to update | ||
85 | * members and its information. The function also stores the message in map locally for access afterwards. | ||
86 | * | ||
87 | * @param room Room | ||
88 | * @param message Message | ||
89 | * @param hash Hash of message | ||
90 | */ | ||
91 | void | ||
92 | handle_room_message (struct GNUNET_MESSENGER_Room *room, const struct GNUNET_MESSENGER_Message *message, | ||
93 | const struct GNUNET_HashCode *hash); | ||
94 | |||
95 | #endif //GNUNET_MESSENGER_API_ROOM_H | ||
diff --git a/src/messenger/test_messenger.c b/src/messenger/test_messenger.c new file mode 100644 index 000000000..b42dfe6d9 --- /dev/null +++ b/src/messenger/test_messenger.c | |||
@@ -0,0 +1,187 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 messenger/test_messenger.c | ||
22 | * @author Tobias Frisch | ||
23 | * @brief Test for the messenger service using cadet API. | ||
24 | */ | ||
25 | #include <stdio.h> | ||
26 | #include "platform.h" | ||
27 | #include "gnunet_util_lib.h" | ||
28 | #include "gnunet_testing_lib.h" | ||
29 | #include "gnunet_messenger_service.h" | ||
30 | |||
31 | /** | ||
32 | * How long until we really give up on a particular testcase portion? | ||
33 | */ | ||
34 | #define TOTAL_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, \ | ||
35 | 60) | ||
36 | |||
37 | /** | ||
38 | * How long until we give up on any particular operation (and retry)? | ||
39 | */ | ||
40 | #define BASE_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 5) | ||
41 | |||
42 | #define TESTER_NAME "tester" | ||
43 | |||
44 | static int status = 1; | ||
45 | |||
46 | static struct GNUNET_SCHEDULER_Task *die_task = NULL; | ||
47 | static struct GNUNET_SCHEDULER_Task *op_task = NULL; | ||
48 | |||
49 | struct GNUNET_MESSENGER_Handle *messenger = NULL; | ||
50 | |||
51 | static void | ||
52 | end (void *cls) | ||
53 | { | ||
54 | die_task = NULL; | ||
55 | |||
56 | if (op_task) | ||
57 | { | ||
58 | GNUNET_SCHEDULER_cancel (op_task); | ||
59 | op_task = NULL; | ||
60 | } | ||
61 | |||
62 | if (messenger) | ||
63 | { | ||
64 | GNUNET_MESSENGER_disconnect(messenger); | ||
65 | messenger = NULL; | ||
66 | } | ||
67 | |||
68 | status = 0; | ||
69 | } | ||
70 | |||
71 | |||
72 | static void | ||
73 | end_badly (void *cls) | ||
74 | { | ||
75 | fprintf (stderr, "Testcase failed (timeout).\n"); | ||
76 | |||
77 | end (NULL); | ||
78 | status = 1; | ||
79 | } | ||
80 | |||
81 | static void | ||
82 | end_operation (void *cls) | ||
83 | { | ||
84 | op_task = NULL; | ||
85 | |||
86 | fprintf (stderr, "Testcase failed (operation: '%s').\n", cls? (const char*) cls : "unknown"); | ||
87 | |||
88 | if (die_task) | ||
89 | GNUNET_SCHEDULER_cancel (die_task); | ||
90 | |||
91 | end (NULL); | ||
92 | status = 1; | ||
93 | } | ||
94 | |||
95 | static int identity_counter = 0; | ||
96 | |||
97 | /** | ||
98 | * Function called when an identity is retrieved. | ||
99 | * | ||
100 | * @param cls Closure | ||
101 | * @param handle Handle of messenger service | ||
102 | */ | ||
103 | static void | ||
104 | on_identity (void *cls, struct GNUNET_MESSENGER_Handle *handle) | ||
105 | { | ||
106 | if (op_task) | ||
107 | { | ||
108 | GNUNET_SCHEDULER_cancel (op_task); | ||
109 | op_task = NULL; | ||
110 | } | ||
111 | |||
112 | const char* name = GNUNET_MESSENGER_get_name(handle); | ||
113 | |||
114 | if (0 != strcmp(name, TESTER_NAME)) | ||
115 | { | ||
116 | op_task = GNUNET_SCHEDULER_add_now (&end_operation, "name"); | ||
117 | return; | ||
118 | } | ||
119 | |||
120 | struct GNUNET_IDENTITY_Ego* ego = GNUNET_IDENTITY_ego_get_anonymous(); | ||
121 | struct GNUNET_IDENTITY_PublicKey anonymous_key; | ||
122 | |||
123 | GNUNET_IDENTITY_ego_get_public_key(ego, &anonymous_key); | ||
124 | |||
125 | const struct GNUNET_IDENTITY_PublicKey* key = GNUNET_MESSENGER_get_key(handle); | ||
126 | |||
127 | if (((!identity_counter) && (0 != GNUNET_memcmp(key, (&anonymous_key)))) || | ||
128 | ((identity_counter) && (0 == GNUNET_memcmp(key, (&anonymous_key))))) | ||
129 | { | ||
130 | op_task = GNUNET_SCHEDULER_add_now (&end_operation, "key"); | ||
131 | return; | ||
132 | } | ||
133 | |||
134 | if (identity_counter) { | ||
135 | GNUNET_MESSENGER_disconnect(handle); | ||
136 | |||
137 | op_task = NULL; | ||
138 | messenger = NULL; | ||
139 | |||
140 | if (die_task) | ||
141 | GNUNET_SCHEDULER_cancel (die_task); | ||
142 | |||
143 | die_task = GNUNET_SCHEDULER_add_now (&end, NULL); | ||
144 | return; | ||
145 | } | ||
146 | |||
147 | GNUNET_MESSENGER_update(messenger); | ||
148 | identity_counter++; | ||
149 | } | ||
150 | |||
151 | /** | ||
152 | * Main function for testcase. | ||
153 | * | ||
154 | * @param cls Closure | ||
155 | * @param cfg Configuration | ||
156 | * @param peer Peer for testing | ||
157 | */ | ||
158 | static void | ||
159 | run (void *cls, | ||
160 | const struct GNUNET_CONFIGURATION_Handle *cfg, | ||
161 | struct GNUNET_TESTING_Peer *peer) | ||
162 | { | ||
163 | die_task = GNUNET_SCHEDULER_add_delayed (TOTAL_TIMEOUT, &end_badly, NULL); | ||
164 | |||
165 | identity_counter = 0; | ||
166 | |||
167 | op_task = GNUNET_SCHEDULER_add_delayed (BASE_TIMEOUT, &end_operation, "connect"); | ||
168 | messenger = GNUNET_MESSENGER_connect(cfg, TESTER_NAME, &on_identity, NULL, NULL, NULL); | ||
169 | } | ||
170 | |||
171 | /** | ||
172 | * The main function. | ||
173 | * | ||
174 | * @param argc number of arguments from the command line | ||
175 | * @param argv command line arguments | ||
176 | * @return 0 ok, 1 on error | ||
177 | */ | ||
178 | int | ||
179 | main(int argc, char **argv) | ||
180 | { | ||
181 | if (0 != GNUNET_TESTING_peer_run("test-messenger", | ||
182 | "test_messenger_api.conf", | ||
183 | &run, NULL)) | ||
184 | return 1; | ||
185 | |||
186 | return status; | ||
187 | } | ||
diff --git a/src/messenger/test_messenger_anonymous.c b/src/messenger/test_messenger_anonymous.c new file mode 100644 index 000000000..e2057acc4 --- /dev/null +++ b/src/messenger/test_messenger_anonymous.c | |||
@@ -0,0 +1,179 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 messenger/test_messenger_anonymous.c | ||
22 | * @author Tobias Frisch | ||
23 | * @brief Test for the messenger service using cadet API. | ||
24 | */ | ||
25 | #include <stdio.h> | ||
26 | #include "platform.h" | ||
27 | #include "gnunet_util_lib.h" | ||
28 | #include "gnunet_testing_lib.h" | ||
29 | #include "gnunet_messenger_service.h" | ||
30 | |||
31 | /** | ||
32 | * How long until we really give up on a particular testcase portion? | ||
33 | */ | ||
34 | #define TOTAL_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, \ | ||
35 | 60) | ||
36 | |||
37 | /** | ||
38 | * How long until we give up on any particular operation (and retry)? | ||
39 | */ | ||
40 | #define BASE_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 5) | ||
41 | |||
42 | static int status = 1; | ||
43 | |||
44 | static struct GNUNET_SCHEDULER_Task *die_task = NULL; | ||
45 | static struct GNUNET_SCHEDULER_Task *op_task = NULL; | ||
46 | |||
47 | struct GNUNET_MESSENGER_Handle *messenger = NULL; | ||
48 | |||
49 | static void | ||
50 | end (void *cls) | ||
51 | { | ||
52 | die_task = NULL; | ||
53 | |||
54 | if (op_task) | ||
55 | { | ||
56 | GNUNET_SCHEDULER_cancel (op_task); | ||
57 | op_task = NULL; | ||
58 | } | ||
59 | |||
60 | if (messenger) | ||
61 | { | ||
62 | GNUNET_MESSENGER_disconnect(messenger); | ||
63 | messenger = NULL; | ||
64 | } | ||
65 | |||
66 | status = 0; | ||
67 | } | ||
68 | |||
69 | |||
70 | static void | ||
71 | end_badly (void *cls) | ||
72 | { | ||
73 | fprintf (stderr, "Testcase failed (timeout).\n"); | ||
74 | |||
75 | end (NULL); | ||
76 | status = 1; | ||
77 | } | ||
78 | |||
79 | static void | ||
80 | end_operation (void *cls) | ||
81 | { | ||
82 | op_task = NULL; | ||
83 | |||
84 | fprintf (stderr, "Testcase failed (operation: '%s').\n", cls? (const char*) cls : "unknown"); | ||
85 | |||
86 | if (die_task) | ||
87 | GNUNET_SCHEDULER_cancel (die_task); | ||
88 | |||
89 | end (NULL); | ||
90 | status = 1; | ||
91 | } | ||
92 | |||
93 | /** | ||
94 | * Function called when an identity is retrieved. | ||
95 | * | ||
96 | * @param cls Closure | ||
97 | * @param handle Handle of messenger service | ||
98 | */ | ||
99 | static void | ||
100 | on_identity (void *cls, struct GNUNET_MESSENGER_Handle *handle) | ||
101 | { | ||
102 | if (op_task) | ||
103 | { | ||
104 | GNUNET_SCHEDULER_cancel (op_task); | ||
105 | op_task = NULL; | ||
106 | } | ||
107 | |||
108 | const char* name = GNUNET_MESSENGER_get_name(handle); | ||
109 | |||
110 | if (NULL != name) | ||
111 | { | ||
112 | op_task = GNUNET_SCHEDULER_add_now (&end_operation, "name-anonymous"); | ||
113 | return; | ||
114 | } | ||
115 | |||
116 | if (GNUNET_SYSERR != GNUNET_MESSENGER_update(handle)) | ||
117 | { | ||
118 | op_task = GNUNET_SCHEDULER_add_now (&end_operation, "update-fail"); | ||
119 | return; | ||
120 | } | ||
121 | |||
122 | struct GNUNET_IDENTITY_Ego* ego = GNUNET_IDENTITY_ego_get_anonymous(); | ||
123 | struct GNUNET_IDENTITY_PublicKey anonymous_key; | ||
124 | |||
125 | GNUNET_IDENTITY_ego_get_public_key(ego, &anonymous_key); | ||
126 | |||
127 | const struct GNUNET_IDENTITY_PublicKey* key = GNUNET_MESSENGER_get_key(handle); | ||
128 | |||
129 | if (0 != GNUNET_memcmp(key, (&anonymous_key))) | ||
130 | { | ||
131 | op_task = GNUNET_SCHEDULER_add_now (&end_operation, "key-anonymous"); | ||
132 | return; | ||
133 | } | ||
134 | |||
135 | GNUNET_MESSENGER_disconnect(handle); | ||
136 | |||
137 | messenger = NULL; | ||
138 | |||
139 | if (die_task) | ||
140 | GNUNET_SCHEDULER_cancel (die_task); | ||
141 | |||
142 | die_task = GNUNET_SCHEDULER_add_now (&end, NULL); | ||
143 | } | ||
144 | |||
145 | /** | ||
146 | * Main function for testcase. | ||
147 | * | ||
148 | * @param cls Closure | ||
149 | * @param cfg Configuration | ||
150 | * @param peer Peer for testing | ||
151 | */ | ||
152 | static void | ||
153 | run (void *cls, | ||
154 | const struct GNUNET_CONFIGURATION_Handle *cfg, | ||
155 | struct GNUNET_TESTING_Peer *peer) | ||
156 | { | ||
157 | die_task = GNUNET_SCHEDULER_add_delayed (TOTAL_TIMEOUT, &end_badly, NULL); | ||
158 | |||
159 | op_task = GNUNET_SCHEDULER_add_delayed (BASE_TIMEOUT, &end_operation, "connect"); | ||
160 | messenger = GNUNET_MESSENGER_connect(cfg, NULL, &on_identity, NULL, NULL, NULL); | ||
161 | } | ||
162 | |||
163 | /** | ||
164 | * The main function. | ||
165 | * | ||
166 | * @param argc number of arguments from the command line | ||
167 | * @param argv command line arguments | ||
168 | * @return 0 ok, 1 on error | ||
169 | */ | ||
170 | int | ||
171 | main(int argc, char **argv) | ||
172 | { | ||
173 | if (0 != GNUNET_TESTING_peer_run("test-messenger", | ||
174 | "test_messenger_api.conf", | ||
175 | &run, NULL)) | ||
176 | return 1; | ||
177 | |||
178 | return status; | ||
179 | } | ||
diff --git a/src/messenger/test_messenger_comm0.c b/src/messenger/test_messenger_comm0.c new file mode 100644 index 000000000..631b5b2c9 --- /dev/null +++ b/src/messenger/test_messenger_comm0.c | |||
@@ -0,0 +1,252 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2020 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 messenger/test_messenger_comm0.c | ||
22 | * @author Tobias Frisch | ||
23 | * @brief Test for the messenger service using cadet API. | ||
24 | */ | ||
25 | #include <stdio.h> | ||
26 | #include "platform.h" | ||
27 | #include "gnunet_util_lib.h" | ||
28 | #include "gnunet_testbed_logger_service.h" | ||
29 | #include "gnunet_testbed_service.h" | ||
30 | #include "gnunet_testing_lib.h" | ||
31 | #include "gnunet_messenger_service.h" | ||
32 | |||
33 | /** | ||
34 | * How long until we really give up on a particular testcase portion? | ||
35 | */ | ||
36 | #define TOTAL_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, \ | ||
37 | 60) | ||
38 | |||
39 | /** | ||
40 | * How long until we give up on any particular operation (and retry)? | ||
41 | */ | ||
42 | #define BASE_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS, 5) | ||
43 | |||
44 | static int status = 1; | ||
45 | |||
46 | static struct GNUNET_SCHEDULER_Task *die_task = NULL; | ||
47 | static struct GNUNET_SCHEDULER_Task *op_task = NULL; | ||
48 | |||
49 | static void | ||
50 | end (void *cls) | ||
51 | { | ||
52 | die_task = NULL; | ||
53 | |||
54 | if (op_task) | ||
55 | { | ||
56 | GNUNET_SCHEDULER_cancel (op_task); | ||
57 | op_task = NULL; | ||
58 | } | ||
59 | |||
60 | GNUNET_SCHEDULER_shutdown (); | ||
61 | status = 0; | ||
62 | } | ||
63 | |||
64 | |||
65 | static void | ||
66 | end_badly (void *cls) | ||
67 | { | ||
68 | fprintf (stderr, "Testcase failed (timeout).\n"); | ||
69 | |||
70 | end (NULL); | ||
71 | status = 1; | ||
72 | } | ||
73 | |||
74 | static void | ||
75 | end_operation (void *cls) | ||
76 | { | ||
77 | op_task = NULL; | ||
78 | |||
79 | fprintf (stderr, "Testcase failed (operation: '%s').\n", cls? (const char*) cls : "unknown"); | ||
80 | |||
81 | if (die_task) | ||
82 | GNUNET_SCHEDULER_cancel (die_task); | ||
83 | |||
84 | end (NULL); | ||
85 | status = 1; | ||
86 | } | ||
87 | |||
88 | static void | ||
89 | end_error (void *cls) | ||
90 | { | ||
91 | op_task = NULL; | ||
92 | |||
93 | fprintf (stderr, "Testcase failed (error: '%s').\n", cls? (const char*) cls : "unknown"); | ||
94 | GNUNET_free(cls); | ||
95 | |||
96 | if (die_task) | ||
97 | GNUNET_SCHEDULER_cancel (die_task); | ||
98 | |||
99 | end (NULL); | ||
100 | status = 1; | ||
101 | } | ||
102 | |||
103 | /** | ||
104 | * Function called whenever a message is received or sent. | ||
105 | * | ||
106 | * @param cls Closure | ||
107 | * @param room Room | ||
108 | * @param message Message | ||
109 | * @param hash Hash of message | ||
110 | */ | ||
111 | static void | ||
112 | on_message (void *cls, const struct GNUNET_MESSENGER_Room *room, const struct GNUNET_MESSENGER_Message *message, | ||
113 | const struct GNUNET_HashCode *hash) | ||
114 | { | ||
115 | // TODO | ||
116 | } | ||
117 | |||
118 | /** | ||
119 | * Function called when an identity is retrieved. | ||
120 | * | ||
121 | * @param cls Closure | ||
122 | * @param handle Handle of messenger service | ||
123 | */ | ||
124 | static void | ||
125 | on_identity (void *cls, struct GNUNET_MESSENGER_Handle *handle) | ||
126 | { | ||
127 | // TODO | ||
128 | } | ||
129 | |||
130 | static void | ||
131 | on_peer (void *cb_cls, struct GNUNET_TESTBED_Operation *op, | ||
132 | const struct GNUNET_TESTBED_PeerInformation *pinfo, | ||
133 | const char *emsg) | ||
134 | { | ||
135 | if (emsg) | ||
136 | { | ||
137 | op_task = GNUNET_SCHEDULER_add_now (&end_error, GNUNET_strdup(emsg)); | ||
138 | return; | ||
139 | } | ||
140 | |||
141 | if (pinfo->pit != GNUNET_TESTBED_PIT_CONFIGURATION) | ||
142 | { | ||
143 | op_task = GNUNET_SCHEDULER_add_now (&end_operation, "config"); | ||
144 | return; | ||
145 | } | ||
146 | |||
147 | struct GNUNET_MESSENGER_Handle *handle; | ||
148 | struct GNUNET_MESSENGER_Room *room; | ||
149 | |||
150 | fprintf (stderr, "MSG: connect\n"); | ||
151 | |||
152 | handle = GNUNET_MESSENGER_connect(pinfo->result.cfg, "tester", &on_identity, NULL, &on_message, NULL); | ||
153 | |||
154 | struct GNUNET_HashCode hash; | ||
155 | GNUNET_CRYPTO_hash("test", 4, &hash); | ||
156 | |||
157 | fprintf (stderr, "MSG: open\n"); | ||
158 | |||
159 | room = GNUNET_MESSENGER_open_room(handle, &hash); | ||
160 | |||
161 | fprintf (stderr, "MSG: close\n"); | ||
162 | |||
163 | GNUNET_MESSENGER_close_room(room); | ||
164 | |||
165 | fprintf (stderr, "MSG: disconnect\n"); | ||
166 | |||
167 | GNUNET_MESSENGER_disconnect(handle); | ||
168 | |||
169 | GNUNET_TESTBED_operation_done(op); | ||
170 | |||
171 | } | ||
172 | |||
173 | /** | ||
174 | * Main function for a peer of the testcase. | ||
175 | * | ||
176 | * @param cls Closure | ||
177 | * @param event Information about the event | ||
178 | */ | ||
179 | static void | ||
180 | run (void *cls, const struct GNUNET_TESTBED_EventInformation *event) | ||
181 | { | ||
182 | if (GNUNET_TESTBED_ET_PEER_START != event->type) | ||
183 | { | ||
184 | op_task = GNUNET_SCHEDULER_add_now (&end_operation, "start"); | ||
185 | return; | ||
186 | } | ||
187 | |||
188 | GNUNET_TESTBED_peer_get_information(event->details.peer_start.peer, | ||
189 | GNUNET_TESTBED_PIT_CONFIGURATION, | ||
190 | on_peer, event->details.peer_start.peer); | ||
191 | |||
192 | fprintf (stderr, "MSG: barrier\n"); | ||
193 | |||
194 | GNUNET_TESTBED_barrier_wait("exit", NULL, NULL); | ||
195 | |||
196 | fprintf (stderr, "MSG: exit\n"); | ||
197 | } | ||
198 | |||
199 | static void | ||
200 | exit_status (void *cls, const char *name, | ||
201 | struct GNUNET_TESTBED_Barrier *barrier, | ||
202 | enum GNUNET_TESTBED_BarrierStatus status, | ||
203 | const char *emsg) | ||
204 | { | ||
205 | if (emsg) | ||
206 | { | ||
207 | op_task = GNUNET_SCHEDULER_add_now (&end_error, GNUNET_strdup(emsg)); | ||
208 | return; | ||
209 | } | ||
210 | |||
211 | if (GNUNET_TESTBED_BARRIERSTATUS_ERROR == status) | ||
212 | { | ||
213 | op_task = GNUNET_SCHEDULER_add_now (&end_operation, "exit"); | ||
214 | return; | ||
215 | } | ||
216 | else if (GNUNET_TESTBED_BARRIERSTATUS_CROSSED == status) | ||
217 | GNUNET_SCHEDULER_add_now(&end, NULL); | ||
218 | } | ||
219 | |||
220 | static void | ||
221 | init (void *cls, struct GNUNET_TESTBED_RunHandle *h, unsigned int num_peers, | ||
222 | struct GNUNET_TESTBED_Peer **peers, unsigned int links_succeeded, | ||
223 | unsigned int links_failed) | ||
224 | { | ||
225 | die_task = GNUNET_SCHEDULER_add_delayed (TOTAL_TIMEOUT, &end_badly, NULL); | ||
226 | |||
227 | struct GNUNET_TESTBED_Controller *controller; | ||
228 | |||
229 | controller = GNUNET_TESTBED_run_get_controller_handle(h); | ||
230 | |||
231 | GNUNET_TESTBED_barrier_init(controller, "exit", num_peers, exit_status, NULL); | ||
232 | } | ||
233 | |||
234 | /** | ||
235 | * The main function. | ||
236 | * | ||
237 | * @param argc number of arguments from the command line | ||
238 | * @param argv command line arguments | ||
239 | * @return 0 ok, 1 on error | ||
240 | */ | ||
241 | int | ||
242 | main(int argc, char **argv) | ||
243 | { | ||
244 | if (GNUNET_OK != GNUNET_TESTBED_test_run("test-messenger-comm0", | ||
245 | "test_messenger_api.conf", | ||
246 | 2, 0, | ||
247 | &run, NULL, | ||
248 | &init, NULL)) | ||
249 | return 1; | ||
250 | |||
251 | return status; | ||
252 | } | ||
diff --git a/src/my/my_query_helper.c b/src/my/my_query_helper.c index 526e57b8b..97ea04fd1 100644 --- a/src/my/my_query_helper.c +++ b/src/my/my_query_helper.c | |||
@@ -280,14 +280,14 @@ my_conv_rsa_public_key (void *cls, | |||
280 | MYSQL_BIND *qbind) | 280 | MYSQL_BIND *qbind) |
281 | { | 281 | { |
282 | const struct GNUNET_CRYPTO_RsaPublicKey *rsa = qp->data; | 282 | const struct GNUNET_CRYPTO_RsaPublicKey *rsa = qp->data; |
283 | char *buf; | 283 | void *buf; |
284 | size_t buf_size; | 284 | size_t buf_size; |
285 | 285 | ||
286 | (void) cls; | 286 | (void) cls; |
287 | GNUNET_assert (1 == qp->num_params); | 287 | GNUNET_assert (1 == qp->num_params); |
288 | buf_size = GNUNET_CRYPTO_rsa_public_key_encode (rsa, | 288 | buf_size = GNUNET_CRYPTO_rsa_public_key_encode (rsa, |
289 | &buf); | 289 | &buf); |
290 | qbind->buffer = (void *) buf; | 290 | qbind->buffer = buf; |
291 | qbind->buffer_length = buf_size; | 291 | qbind->buffer_length = buf_size; |
292 | qbind->buffer_type = MYSQL_TYPE_BLOB; | 292 | qbind->buffer_type = MYSQL_TYPE_BLOB; |
293 | return 1; | 293 | return 1; |
@@ -332,14 +332,14 @@ my_conv_rsa_signature (void *cls, | |||
332 | MYSQL_BIND *qbind) | 332 | MYSQL_BIND *qbind) |
333 | { | 333 | { |
334 | const struct GNUNET_CRYPTO_RsaSignature *sig = qp->data; | 334 | const struct GNUNET_CRYPTO_RsaSignature *sig = qp->data; |
335 | char *buf; | 335 | void *buf; |
336 | size_t buf_size; | 336 | size_t buf_size; |
337 | 337 | ||
338 | (void) cls; | 338 | (void) cls; |
339 | GNUNET_assert (1 == qp->num_params); | 339 | GNUNET_assert (1 == qp->num_params); |
340 | buf_size = GNUNET_CRYPTO_rsa_signature_encode (sig, | 340 | buf_size = GNUNET_CRYPTO_rsa_signature_encode (sig, |
341 | &buf); | 341 | &buf); |
342 | qbind->buffer = (void *) buf; | 342 | qbind->buffer = buf; |
343 | qbind->buffer_length = buf_size; | 343 | qbind->buffer_length = buf_size; |
344 | qbind->buffer_type = MYSQL_TYPE_BLOB; | 344 | qbind->buffer_type = MYSQL_TYPE_BLOB; |
345 | return 1; | 345 | return 1; |
diff --git a/src/namecache/Makefile.am b/src/namecache/Makefile.am index 5e80ea4c5..836a6b5d9 100644 --- a/src/namecache/Makefile.am +++ b/src/namecache/Makefile.am | |||
@@ -65,6 +65,7 @@ libgnunetnamecache_la_SOURCES = \ | |||
65 | namecache.h | 65 | namecache.h |
66 | libgnunetnamecache_la_LIBADD = \ | 66 | libgnunetnamecache_la_LIBADD = \ |
67 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 67 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
68 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
68 | $(top_builddir)/src/util/libgnunetutil.la \ | 69 | $(top_builddir)/src/util/libgnunetutil.la \ |
69 | $(GN_LIBINTL) | 70 | $(GN_LIBINTL) |
70 | libgnunetnamecache_la_LDFLAGS = \ | 71 | libgnunetnamecache_la_LDFLAGS = \ |
@@ -82,6 +83,7 @@ gnunet_namecache_SOURCES = \ | |||
82 | gnunet-namecache.c | 83 | gnunet-namecache.c |
83 | gnunet_namecache_LDADD = \ | 84 | gnunet_namecache_LDADD = \ |
84 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 85 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
86 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
85 | $(top_builddir)/src/util/libgnunetutil.la \ | 87 | $(top_builddir)/src/util/libgnunetutil.la \ |
86 | libgnunetnamecache.la \ | 88 | libgnunetnamecache.la \ |
87 | $(GN_LIBINTL) | 89 | $(GN_LIBINTL) |
@@ -91,6 +93,7 @@ gnunet_service_namecache_SOURCES = \ | |||
91 | 93 | ||
92 | gnunet_service_namecache_LDADD = \ | 94 | gnunet_service_namecache_LDADD = \ |
93 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 95 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
96 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
94 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 97 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
95 | $(top_builddir)/src/util/libgnunetutil.la \ | 98 | $(top_builddir)/src/util/libgnunetutil.la \ |
96 | libgnunetnamecache.la \ | 99 | libgnunetnamecache.la \ |
@@ -107,6 +110,8 @@ libgnunet_plugin_namecache_flat_la_SOURCES = \ | |||
107 | libgnunet_plugin_namecache_flat_la_LIBADD = \ | 110 | libgnunet_plugin_namecache_flat_la_LIBADD = \ |
108 | libgnunetnamecache.la \ | 111 | libgnunetnamecache.la \ |
109 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 112 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
113 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | ||
114 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
110 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 115 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ |
111 | $(LTLIBINTL) | 116 | $(LTLIBINTL) |
112 | libgnunet_plugin_namecache_flat_la_LDFLAGS = \ | 117 | libgnunet_plugin_namecache_flat_la_LDFLAGS = \ |
@@ -118,6 +123,8 @@ libgnunet_plugin_namecache_sqlite_la_LIBADD = \ | |||
118 | libgnunetnamecache.la \ | 123 | libgnunetnamecache.la \ |
119 | $(top_builddir)/src/sq/libgnunetsq.la \ | 124 | $(top_builddir)/src/sq/libgnunetsq.la \ |
120 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 125 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
126 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | ||
127 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
121 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) -lsqlite3 \ | 128 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) -lsqlite3 \ |
122 | $(LTLIBINTL) | 129 | $(LTLIBINTL) |
123 | libgnunet_plugin_namecache_sqlite_la_LDFLAGS = \ | 130 | libgnunet_plugin_namecache_sqlite_la_LDFLAGS = \ |
@@ -130,6 +137,8 @@ libgnunet_plugin_namecache_postgres_la_LIBADD = \ | |||
130 | libgnunetnamecache.la \ | 137 | libgnunetnamecache.la \ |
131 | $(top_builddir)/src/pq/libgnunetpq.la \ | 138 | $(top_builddir)/src/pq/libgnunetpq.la \ |
132 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 139 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
140 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | ||
141 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
133 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) -lpq \ | 142 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) -lpq \ |
134 | $(LTLIBINTL) | 143 | $(LTLIBINTL) |
135 | libgnunet_plugin_namecache_postgres_la_LDFLAGS = \ | 144 | libgnunet_plugin_namecache_postgres_la_LDFLAGS = \ |
diff --git a/src/namecache/gnunet-namecache.c b/src/namecache/gnunet-namecache.c index 2e3c733e6..19f2a5766 100644 --- a/src/namecache/gnunet-namecache.c +++ b/src/namecache/gnunet-namecache.c | |||
@@ -51,7 +51,7 @@ static char *name; | |||
51 | /** | 51 | /** |
52 | * Public key of the zone to look in. | 52 | * Public key of the zone to look in. |
53 | */ | 53 | */ |
54 | static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 54 | static struct GNUNET_IDENTITY_PublicKey pubkey; |
55 | 55 | ||
56 | /** | 56 | /** |
57 | * Public key of the zone to look in, in ASCII. | 57 | * Public key of the zone to look in, in ASCII. |
@@ -177,7 +177,7 @@ run (void *cls, | |||
177 | } | 177 | } |
178 | 178 | ||
179 | if (GNUNET_OK != | 179 | if (GNUNET_OK != |
180 | GNUNET_CRYPTO_ecdsa_public_key_from_string (pkey, strlen (pkey), &pubkey)) | 180 | GNUNET_IDENTITY_public_key_from_string (pkey, &pubkey)) |
181 | { | 181 | { |
182 | fprintf (stderr, _ ("Invalid public key for zone `%s'\n"), pkey); | 182 | fprintf (stderr, _ ("Invalid public key for zone `%s'\n"), pkey); |
183 | GNUNET_SCHEDULER_shutdown (); | 183 | GNUNET_SCHEDULER_shutdown (); |
diff --git a/src/namecache/gnunet-service-namecache.c b/src/namecache/gnunet-service-namecache.c index 7cf216ce3..07bf30de9 100644 --- a/src/namecache/gnunet-service-namecache.c +++ b/src/namecache/gnunet-service-namecache.c | |||
@@ -184,40 +184,24 @@ handle_lookup_block_it (void *cls, | |||
184 | struct LookupBlockContext *lnc = cls; | 184 | struct LookupBlockContext *lnc = cls; |
185 | struct GNUNET_MQ_Envelope *env; | 185 | struct GNUNET_MQ_Envelope *env; |
186 | struct LookupBlockResponseMessage *r; | 186 | struct LookupBlockResponseMessage *r; |
187 | size_t esize; | ||
188 | size_t bsize; | 187 | size_t bsize; |
189 | 188 | ||
190 | bsize = ntohl (block->purpose.size); | 189 | bsize = GNUNET_GNSRECORD_block_get_size (block); |
191 | if (bsize < | ||
192 | (sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) + sizeof(struct | ||
193 | GNUNET_TIME_AbsoluteNBO))) | ||
194 | { | ||
195 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | ||
196 | "Malformed block."); | ||
197 | lnc->status = GNUNET_SYSERR; | ||
198 | return; | ||
199 | } | ||
200 | esize = ntohl (block->purpose.size) | ||
201 | - sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) | ||
202 | - sizeof(struct GNUNET_TIME_AbsoluteNBO); | ||
203 | env = GNUNET_MQ_msg_extra (r, | 190 | env = GNUNET_MQ_msg_extra (r, |
204 | esize, | 191 | bsize, |
205 | GNUNET_MESSAGE_TYPE_NAMECACHE_LOOKUP_BLOCK_RESPONSE); | 192 | GNUNET_MESSAGE_TYPE_NAMECACHE_LOOKUP_BLOCK_RESPONSE); |
206 | r->gns_header.r_id = htonl (lnc->request_id); | 193 | r->gns_header.r_id = htonl (lnc->request_id); |
207 | r->expire = block->expiration_time; | ||
208 | r->signature = block->signature; | ||
209 | r->derived_key = block->derived_key; | ||
210 | GNUNET_memcpy (&r[1], | 194 | GNUNET_memcpy (&r[1], |
211 | &block[1], | 195 | block, |
212 | esize); | 196 | bsize); |
213 | GNUNET_STATISTICS_update (statistics, | 197 | GNUNET_STATISTICS_update (statistics, |
214 | "blocks found in cache", | 198 | "blocks found in cache", |
215 | 1, | 199 | 1, |
216 | GNUNET_NO); | 200 | GNUNET_NO); |
201 | r->expire = GNUNET_TIME_absolute_hton ( | ||
202 | GNUNET_GNSRECORD_block_get_expiration (block)); | ||
217 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 203 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
218 | "Sending NAMECACHE_LOOKUP_BLOCK_RESPONSE message with expiration time %s\n", | 204 | "Sending NAMECACHE_LOOKUP_BLOCK_RESPONSE message\n"); |
219 | GNUNET_STRINGS_absolute_time_to_string ( | ||
220 | GNUNET_TIME_absolute_ntoh (r->expire))); | ||
221 | GNUNET_MQ_send (lnc->nc->mq, | 205 | GNUNET_MQ_send (lnc->nc->mq, |
222 | env); | 206 | env); |
223 | } | 207 | } |
@@ -314,20 +298,11 @@ handle_block_cache (void *cls, | |||
314 | GNUNET_NO); | 298 | GNUNET_NO); |
315 | esize = ntohs (rp_msg->gns_header.header.size) - sizeof(struct | 299 | esize = ntohs (rp_msg->gns_header.header.size) - sizeof(struct |
316 | BlockCacheMessage); | 300 | BlockCacheMessage); |
317 | block = GNUNET_malloc (sizeof(struct GNUNET_GNSRECORD_Block) + esize); | 301 | block = GNUNET_malloc (esize); |
318 | block->signature = rp_msg->signature; | 302 | memcpy (block, &rp_msg[1], esize); |
319 | block->derived_key = rp_msg->derived_key; | ||
320 | block->purpose.size = htonl (sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) | ||
321 | + sizeof(struct GNUNET_TIME_AbsoluteNBO) | ||
322 | + esize); | ||
323 | block->expiration_time = rp_msg->expire; | ||
324 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 303 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
325 | "Received NAMECACHE_BLOCK_CACHE message with expiration time %s\n", | 304 | "Received NAMECACHE_BLOCK_CACHE message with type %u\n", |
326 | GNUNET_STRINGS_absolute_time_to_string ( | 305 | htonl (block->type)); |
327 | GNUNET_TIME_absolute_ntoh (block->expiration_time))); | ||
328 | GNUNET_memcpy (&block[1], | ||
329 | &rp_msg[1], | ||
330 | esize); | ||
331 | res = GSN_database->cache_block (GSN_database->cls, | 306 | res = GSN_database->cache_block (GSN_database->cls, |
332 | block); | 307 | block); |
333 | GNUNET_free (block); | 308 | GNUNET_free (block); |
diff --git a/src/namecache/namecache.h b/src/namecache/namecache.h index 1657662c2..43c8cf85f 100644 --- a/src/namecache/namecache.h +++ b/src/namecache/namecache.h | |||
@@ -92,7 +92,7 @@ struct LookupBlockResponseMessage | |||
92 | /** | 92 | /** |
93 | * Derived public key. | 93 | * Derived public key. |
94 | */ | 94 | */ |
95 | struct GNUNET_CRYPTO_EcdsaPublicKey derived_key; | 95 | struct GNUNET_IDENTITY_PublicKey derived_key; |
96 | 96 | ||
97 | /* follwed by encrypted block data */ | 97 | /* follwed by encrypted block data */ |
98 | }; | 98 | }; |
@@ -121,7 +121,7 @@ struct BlockCacheMessage | |||
121 | /** | 121 | /** |
122 | * Derived public key. | 122 | * Derived public key. |
123 | */ | 123 | */ |
124 | struct GNUNET_CRYPTO_EcdsaPublicKey derived_key; | 124 | struct GNUNET_IDENTITY_PublicKey derived_key; |
125 | 125 | ||
126 | /* follwed by encrypted block data */ | 126 | /* follwed by encrypted block data */ |
127 | }; | 127 | }; |
diff --git a/src/namecache/namecache_api.c b/src/namecache/namecache_api.c index 0c904c9ed..fdbf142a7 100644 --- a/src/namecache/namecache_api.c +++ b/src/namecache/namecache_api.c | |||
@@ -225,19 +225,11 @@ handle_lookup_block_response (void *cls, | |||
225 | size = ntohs (msg->gns_header.header.size) | 225 | size = ntohs (msg->gns_header.header.size) |
226 | - sizeof(struct LookupBlockResponseMessage); | 226 | - sizeof(struct LookupBlockResponseMessage); |
227 | { | 227 | { |
228 | char buf[size + sizeof(struct GNUNET_GNSRECORD_Block)] GNUNET_ALIGN; | 228 | char buf[size] GNUNET_ALIGN; |
229 | struct GNUNET_GNSRECORD_Block *block; | 229 | struct GNUNET_GNSRECORD_Block *block; |
230 | 230 | ||
231 | block = (struct GNUNET_GNSRECORD_Block *) buf; | 231 | block = (struct GNUNET_GNSRECORD_Block *) buf; |
232 | block->signature = msg->signature; | 232 | GNUNET_memcpy (block, |
233 | block->derived_key = msg->derived_key; | ||
234 | block->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_GNS_RECORD_SIGN); | ||
235 | block->purpose.size = htonl (size | ||
236 | + sizeof(struct GNUNET_TIME_AbsoluteNBO) | ||
237 | + sizeof(struct | ||
238 | GNUNET_CRYPTO_EccSignaturePurpose)); | ||
239 | block->expiration_time = msg->expire; | ||
240 | GNUNET_memcpy (&block[1], | ||
241 | &msg[1], | 233 | &msg[1], |
242 | size); | 234 | size); |
243 | if (GNUNET_OK != | 235 | if (GNUNET_OK != |
@@ -483,11 +475,7 @@ GNUNET_NAMECACHE_block_cache (struct GNUNET_NAMECACHE_Handle *h, | |||
483 | 475 | ||
484 | if (NULL == h->mq) | 476 | if (NULL == h->mq) |
485 | return NULL; | 477 | return NULL; |
486 | blen = ntohl (block->purpose.size); | 478 | blen = GNUNET_GNSRECORD_block_get_size (block); |
487 | GNUNET_assert (blen > (sizeof(struct GNUNET_TIME_AbsoluteNBO) | ||
488 | + sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose))); | ||
489 | blen -= (sizeof(struct GNUNET_TIME_AbsoluteNBO) | ||
490 | + sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose)); | ||
491 | rid = get_op_id (h); | 479 | rid = get_op_id (h); |
492 | qe = GNUNET_new (struct GNUNET_NAMECACHE_QueueEntry); | 480 | qe = GNUNET_new (struct GNUNET_NAMECACHE_QueueEntry); |
493 | qe->nsh = h; | 481 | qe->nsh = h; |
@@ -502,11 +490,8 @@ GNUNET_NAMECACHE_block_cache (struct GNUNET_NAMECACHE_Handle *h, | |||
502 | blen, | 490 | blen, |
503 | GNUNET_MESSAGE_TYPE_NAMECACHE_BLOCK_CACHE); | 491 | GNUNET_MESSAGE_TYPE_NAMECACHE_BLOCK_CACHE); |
504 | msg->gns_header.r_id = htonl (rid); | 492 | msg->gns_header.r_id = htonl (rid); |
505 | msg->expire = block->expiration_time; | ||
506 | msg->signature = block->signature; | ||
507 | msg->derived_key = block->derived_key; | ||
508 | GNUNET_memcpy (&msg[1], | 493 | GNUNET_memcpy (&msg[1], |
509 | &block[1], | 494 | block, |
510 | blen); | 495 | blen); |
511 | GNUNET_MQ_send (h->mq, | 496 | GNUNET_MQ_send (h->mq, |
512 | env); | 497 | env); |
diff --git a/src/namecache/plugin_namecache_flat.c b/src/namecache/plugin_namecache_flat.c index 24f4f2570..eb7800051 100644 --- a/src/namecache/plugin_namecache_flat.c +++ b/src/namecache/plugin_namecache_flat.c | |||
@@ -207,10 +207,7 @@ store_and_free_entries (void *cls, | |||
207 | struct GNUNET_CRYPTO_HashAsciiEncoded query; | 207 | struct GNUNET_CRYPTO_HashAsciiEncoded query; |
208 | size_t block_size; | 208 | size_t block_size; |
209 | 209 | ||
210 | block_size = ntohl (entry->block->purpose.size) | 210 | block_size = GNUNET_GNSRECORD_block_get_size (entry->block); |
211 | + sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) | ||
212 | + sizeof(struct GNUNET_CRYPTO_EcdsaSignature); | ||
213 | |||
214 | GNUNET_STRINGS_base64_encode ((char *) entry->block, | 211 | GNUNET_STRINGS_base64_encode ((char *) entry->block, |
215 | block_size, | 212 | block_size, |
216 | &block_b64); | 213 | &block_b64); |
@@ -277,7 +274,7 @@ expire_blocks (void *cls, | |||
277 | struct GNUNET_TIME_Absolute expiration; | 274 | struct GNUNET_TIME_Absolute expiration; |
278 | 275 | ||
279 | now = GNUNET_TIME_absolute_get (); | 276 | now = GNUNET_TIME_absolute_get (); |
280 | expiration = GNUNET_TIME_absolute_ntoh (entry->block->expiration_time); | 277 | expiration = GNUNET_GNSRECORD_block_get_expiration (entry->block); |
281 | 278 | ||
282 | if (0 == GNUNET_TIME_absolute_get_difference (now, | 279 | if (0 == GNUNET_TIME_absolute_get_difference (now, |
283 | expiration).rel_value_us) | 280 | expiration).rel_value_us) |
@@ -319,12 +316,9 @@ namecache_cache_block (void *cls, | |||
319 | size_t block_size; | 316 | size_t block_size; |
320 | 317 | ||
321 | namecache_expire_blocks (plugin); | 318 | namecache_expire_blocks (plugin); |
322 | GNUNET_CRYPTO_hash (&block->derived_key, | 319 | GNUNET_GNSRECORD_query_from_block (block, |
323 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey), | 320 | &query); |
324 | &query); | 321 | block_size = GNUNET_GNSRECORD_block_get_size (block); |
325 | block_size = ntohl (block->purpose.size) | ||
326 | + sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) | ||
327 | + sizeof(struct GNUNET_CRYPTO_EcdsaSignature); | ||
328 | if (block_size > 64 * 65536) | 322 | if (block_size > 64 * 65536) |
329 | { | 323 | { |
330 | GNUNET_break (0); | 324 | GNUNET_break (0); |
diff --git a/src/namecache/plugin_namecache_postgres.c b/src/namecache/plugin_namecache_postgres.c index 0e947e9c5..ae0f71a1f 100644 --- a/src/namecache/plugin_namecache_postgres.c +++ b/src/namecache/plugin_namecache_postgres.c | |||
@@ -64,15 +64,13 @@ database_setup (struct Plugin *plugin) | |||
64 | " query BYTEA NOT NULL DEFAULT ''," | 64 | " query BYTEA NOT NULL DEFAULT ''," |
65 | " block BYTEA NOT NULL DEFAULT ''," | 65 | " block BYTEA NOT NULL DEFAULT ''," |
66 | " expiration_time BIGINT NOT NULL DEFAULT 0" | 66 | " expiration_time BIGINT NOT NULL DEFAULT 0" |
67 | ")" | 67 | ")"); |
68 | "WITH OIDS"); | ||
69 | struct GNUNET_PQ_ExecuteStatement es_default = | 68 | struct GNUNET_PQ_ExecuteStatement es_default = |
70 | GNUNET_PQ_make_execute ("CREATE TABLE IF NOT EXISTS ns096blocks (" | 69 | GNUNET_PQ_make_execute ("CREATE TABLE IF NOT EXISTS ns096blocks (" |
71 | " query BYTEA NOT NULL DEFAULT ''," | 70 | " query BYTEA NOT NULL DEFAULT ''," |
72 | " block BYTEA NOT NULL DEFAULT ''," | 71 | " block BYTEA NOT NULL DEFAULT ''," |
73 | " expiration_time BIGINT NOT NULL DEFAULT 0" | 72 | " expiration_time BIGINT NOT NULL DEFAULT 0" |
74 | ")" | 73 | ")"); |
75 | "WITH OIDS"); | ||
76 | const struct GNUNET_PQ_ExecuteStatement *cr; | 74 | const struct GNUNET_PQ_ExecuteStatement *cr; |
77 | 75 | ||
78 | if (GNUNET_YES == | 76 | if (GNUNET_YES == |
@@ -155,11 +153,11 @@ namecache_postgres_expire_blocks (struct Plugin *plugin) | |||
155 | static void | 153 | static void |
156 | delete_old_block (struct Plugin *plugin, | 154 | delete_old_block (struct Plugin *plugin, |
157 | const struct GNUNET_HashCode *query, | 155 | const struct GNUNET_HashCode *query, |
158 | struct GNUNET_TIME_AbsoluteNBO expiration_time) | 156 | struct GNUNET_TIME_Absolute expiration_time) |
159 | { | 157 | { |
160 | struct GNUNET_PQ_QueryParam params[] = { | 158 | struct GNUNET_PQ_QueryParam params[] = { |
161 | GNUNET_PQ_query_param_auto_from_type (query), | 159 | GNUNET_PQ_query_param_auto_from_type (query), |
162 | GNUNET_PQ_query_param_absolute_time_nbo (&expiration_time), | 160 | GNUNET_PQ_query_param_absolute_time (&expiration_time), |
163 | GNUNET_PQ_query_param_end | 161 | GNUNET_PQ_query_param_end |
164 | }; | 162 | }; |
165 | enum GNUNET_DB_QueryStatus res; | 163 | enum GNUNET_DB_QueryStatus res; |
@@ -184,21 +182,20 @@ namecache_postgres_cache_block (void *cls, | |||
184 | { | 182 | { |
185 | struct Plugin *plugin = cls; | 183 | struct Plugin *plugin = cls; |
186 | struct GNUNET_HashCode query; | 184 | struct GNUNET_HashCode query; |
187 | size_t block_size = ntohl (block->purpose.size) | 185 | size_t block_size = GNUNET_GNSRECORD_block_get_size (block); |
188 | + sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) | 186 | struct GNUNET_TIME_Absolute exp; |
189 | + sizeof(struct GNUNET_CRYPTO_EcdsaSignature); | 187 | exp = GNUNET_GNSRECORD_block_get_expiration (block); |
190 | struct GNUNET_PQ_QueryParam params[] = { | 188 | struct GNUNET_PQ_QueryParam params[] = { |
191 | GNUNET_PQ_query_param_auto_from_type (&query), | 189 | GNUNET_PQ_query_param_auto_from_type (&query), |
192 | GNUNET_PQ_query_param_fixed_size (block, block_size), | 190 | GNUNET_PQ_query_param_fixed_size (block, block_size), |
193 | GNUNET_PQ_query_param_absolute_time_nbo (&block->expiration_time), | 191 | GNUNET_PQ_query_param_absolute_time (&exp), |
194 | GNUNET_PQ_query_param_end | 192 | GNUNET_PQ_query_param_end |
195 | }; | 193 | }; |
196 | enum GNUNET_DB_QueryStatus res; | 194 | enum GNUNET_DB_QueryStatus res; |
197 | 195 | ||
198 | namecache_postgres_expire_blocks (plugin); | 196 | namecache_postgres_expire_blocks (plugin); |
199 | GNUNET_CRYPTO_hash (&block->derived_key, | 197 | GNUNET_GNSRECORD_query_from_block (block, |
200 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey), | 198 | &query); |
201 | &query); | ||
202 | if (block_size > 64 * 65536) | 199 | if (block_size > 64 * 65536) |
203 | { | 200 | { |
204 | GNUNET_break (0); | 201 | GNUNET_break (0); |
@@ -206,7 +203,7 @@ namecache_postgres_cache_block (void *cls, | |||
206 | } | 203 | } |
207 | delete_old_block (plugin, | 204 | delete_old_block (plugin, |
208 | &query, | 205 | &query, |
209 | block->expiration_time); | 206 | exp); |
210 | 207 | ||
211 | res = GNUNET_PQ_eval_prepared_non_select (plugin->dbh, | 208 | res = GNUNET_PQ_eval_prepared_non_select (plugin->dbh, |
212 | "cache_block", | 209 | "cache_block", |
@@ -265,10 +262,7 @@ namecache_postgres_lookup_block (void *cls, | |||
265 | "Ending iteration (no more results)\n"); | 262 | "Ending iteration (no more results)\n"); |
266 | return GNUNET_NO; | 263 | return GNUNET_NO; |
267 | } | 264 | } |
268 | if ((bsize < sizeof(*block)) || | 265 | if ((bsize < sizeof(*block))) |
269 | (bsize != ntohl (block->purpose.size) | ||
270 | + sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) | ||
271 | + sizeof(struct GNUNET_CRYPTO_EcdsaSignature))) | ||
272 | { | 266 | { |
273 | GNUNET_break (0); | 267 | GNUNET_break (0); |
274 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 268 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
diff --git a/src/namecache/plugin_namecache_sqlite.c b/src/namecache/plugin_namecache_sqlite.c index c9d79ba2d..82008c837 100644 --- a/src/namecache/plugin_namecache_sqlite.c +++ b/src/namecache/plugin_namecache_sqlite.c | |||
@@ -332,9 +332,7 @@ namecache_sqlite_cache_block (void *cls, | |||
332 | struct Plugin *plugin = cls; | 332 | struct Plugin *plugin = cls; |
333 | struct GNUNET_HashCode query; | 333 | struct GNUNET_HashCode query; |
334 | struct GNUNET_TIME_Absolute expiration; | 334 | struct GNUNET_TIME_Absolute expiration; |
335 | size_t block_size = ntohl (block->purpose.size) | 335 | size_t block_size = GNUNET_GNSRECORD_block_get_size (block); |
336 | + sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) | ||
337 | + sizeof(struct GNUNET_CRYPTO_EcdsaSignature); | ||
338 | struct GNUNET_SQ_QueryParam del_params[] = { | 336 | struct GNUNET_SQ_QueryParam del_params[] = { |
339 | GNUNET_SQ_query_param_auto_from_type (&query), | 337 | GNUNET_SQ_query_param_auto_from_type (&query), |
340 | GNUNET_SQ_query_param_absolute_time (&expiration), | 338 | GNUNET_SQ_query_param_absolute_time (&expiration), |
@@ -356,10 +354,9 @@ namecache_sqlite_cache_block (void *cls, | |||
356 | last_expire = GNUNET_TIME_absolute_get (); | 354 | last_expire = GNUNET_TIME_absolute_get (); |
357 | namecache_sqlite_expire_blocks (plugin); | 355 | namecache_sqlite_expire_blocks (plugin); |
358 | } | 356 | } |
359 | GNUNET_CRYPTO_hash (&block->derived_key, | 357 | GNUNET_assert (GNUNET_OK == |
360 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey), | 358 | GNUNET_GNSRECORD_query_from_block (block, &query)); |
361 | &query); | 359 | expiration = GNUNET_GNSRECORD_block_get_expiration (block); |
362 | expiration = GNUNET_TIME_absolute_ntoh (block->expiration_time); | ||
363 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, | 360 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, |
364 | "Caching new version of block %s (expires %s)\n", | 361 | "Caching new version of block %s (expires %s)\n", |
365 | GNUNET_h2s (&query), | 362 | GNUNET_h2s (&query), |
@@ -498,10 +495,7 @@ namecache_sqlite_lookup_block (void *cls, | |||
498 | GNUNET_break (0); | 495 | GNUNET_break (0); |
499 | ret = GNUNET_SYSERR; | 496 | ret = GNUNET_SYSERR; |
500 | } | 497 | } |
501 | else if ((block_size < sizeof(struct GNUNET_GNSRECORD_Block)) || | 498 | else if ((block_size < sizeof(struct GNUNET_GNSRECORD_Block))) |
502 | (ntohl (block->purpose.size) | ||
503 | + sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) | ||
504 | + sizeof(struct GNUNET_CRYPTO_EcdsaSignature) != block_size)) | ||
505 | { | 499 | { |
506 | GNUNET_break (0); | 500 | GNUNET_break (0); |
507 | GNUNET_SQ_cleanup_result (rs); | 501 | GNUNET_SQ_cleanup_result (rs); |
diff --git a/src/namecache/test_namecache_api_cache_block.c b/src/namecache/test_namecache_api_cache_block.c index 12b72d93b..310c4de42 100644 --- a/src/namecache/test_namecache_api_cache_block.c +++ b/src/namecache/test_namecache_api_cache_block.c | |||
@@ -39,9 +39,9 @@ static struct GNUNET_NAMECACHE_Handle *nsh; | |||
39 | 39 | ||
40 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 40 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
41 | 41 | ||
42 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey; | 42 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
43 | 43 | ||
44 | static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 44 | static struct GNUNET_IDENTITY_PublicKey pubkey; |
45 | 45 | ||
46 | static int res; | 46 | static int res; |
47 | 47 | ||
@@ -172,23 +172,13 @@ run (void *cls, | |||
172 | { | 172 | { |
173 | struct GNUNET_GNSRECORD_Data rd; | 173 | struct GNUNET_GNSRECORD_Data rd; |
174 | struct GNUNET_GNSRECORD_Block *block; | 174 | struct GNUNET_GNSRECORD_Block *block; |
175 | char *hostkey_file; | ||
176 | const char *name = "dummy.dummy.gnunet"; | 175 | const char *name = "dummy.dummy.gnunet"; |
177 | 176 | ||
178 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, | 177 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, |
179 | &endbadly, NULL); | 178 | &endbadly, NULL); |
180 | GNUNET_asprintf (&hostkey_file, | 179 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
181 | "zonefiles%s%s", | 180 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
182 | DIR_SEPARATOR_STR, | 181 | GNUNET_IDENTITY_key_get_public (&privkey, &pubkey); |
183 | "N0UJMP015AFUNR2BTNM3FKPBLG38913BL8IDMCO2H0A1LIB81960.zkey"); | ||
184 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Using zonekey file `%s' \n", | ||
185 | hostkey_file); | ||
186 | GNUNET_assert (GNUNET_SYSERR != | ||
187 | GNUNET_CRYPTO_ecdsa_key_from_file (hostkey_file, | ||
188 | GNUNET_YES, | ||
189 | &privkey)); | ||
190 | GNUNET_free (hostkey_file); | ||
191 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, &pubkey); | ||
192 | 182 | ||
193 | 183 | ||
194 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us + 10000000000; | 184 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us + 10000000000; |
diff --git a/src/namestore/Makefile.am b/src/namestore/Makefile.am index 40ac64197..3a92f98c9 100644 --- a/src/namestore/Makefile.am +++ b/src/namestore/Makefile.am | |||
@@ -131,6 +131,7 @@ libgnunet_plugin_rest_namestore_la_LIBADD = \ | |||
131 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 131 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
132 | $(top_builddir)/src/json/libgnunetjson.la \ | 132 | $(top_builddir)/src/json/libgnunetjson.la \ |
133 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 133 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
134 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecordjson.la \ | ||
134 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 135 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ |
135 | $(LTLIBINTL) -ljansson $(MHD_LIBS) | 136 | $(LTLIBINTL) -ljansson $(MHD_LIBS) |
136 | libgnunet_plugin_rest_namestore_la_LDFLAGS = \ | 137 | libgnunet_plugin_rest_namestore_la_LDFLAGS = \ |
@@ -144,6 +145,7 @@ libgnunetnamestore_la_SOURCES = \ | |||
144 | namestore.h | 145 | namestore.h |
145 | libgnunetnamestore_la_LIBADD = \ | 146 | libgnunetnamestore_la_LIBADD = \ |
146 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 147 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
148 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
147 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 149 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
148 | $(top_builddir)/src/util/libgnunetutil.la \ | 150 | $(top_builddir)/src/util/libgnunetutil.la \ |
149 | $(GN_LIBINTL) | 151 | $(GN_LIBINTL) |
@@ -190,6 +192,7 @@ gnunet_service_namestore_SOURCES = \ | |||
190 | gnunet_service_namestore_LDADD = \ | 192 | gnunet_service_namestore_LDADD = \ |
191 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ | 193 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ |
192 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 194 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
195 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
193 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 196 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
194 | $(top_builddir)/src/util/libgnunetutil.la \ | 197 | $(top_builddir)/src/util/libgnunetutil.la \ |
195 | libgnunetnamestore.la \ | 198 | libgnunetnamestore.la \ |
@@ -200,7 +203,8 @@ gnunet_service_namestore_LDADD = \ | |||
200 | libgnunet_plugin_namestore_flat_la_SOURCES = \ | 203 | libgnunet_plugin_namestore_flat_la_SOURCES = \ |
201 | plugin_namestore_flat.c | 204 | plugin_namestore_flat.c |
202 | libgnunet_plugin_namestore_flat_la_LIBADD = \ | 205 | libgnunet_plugin_namestore_flat_la_LIBADD = \ |
203 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 206 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
207 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
204 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 208 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
205 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ | 209 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) \ |
206 | $(LTLIBINTL) | 210 | $(LTLIBINTL) |
@@ -212,6 +216,7 @@ libgnunet_plugin_namestore_sqlite_la_SOURCES = \ | |||
212 | plugin_namestore_sqlite.c | 216 | plugin_namestore_sqlite.c |
213 | libgnunet_plugin_namestore_sqlite_la_LIBADD = \ | 217 | libgnunet_plugin_namestore_sqlite_la_LIBADD = \ |
214 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 218 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
219 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
215 | $(top_builddir)/src/sq/libgnunetsq.la \ | 220 | $(top_builddir)/src/sq/libgnunetsq.la \ |
216 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 221 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
217 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) -lsqlite3 \ | 222 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) -lsqlite3 \ |
@@ -223,6 +228,7 @@ libgnunet_plugin_namestore_postgres_la_SOURCES = \ | |||
223 | plugin_namestore_postgres.c | 228 | plugin_namestore_postgres.c |
224 | libgnunet_plugin_namestore_postgres_la_LIBADD = \ | 229 | libgnunet_plugin_namestore_postgres_la_LIBADD = \ |
225 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 230 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
231 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
226 | $(top_builddir)/src/pq/libgnunetpq.la \ | 232 | $(top_builddir)/src/pq/libgnunetpq.la \ |
227 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 233 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
228 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) -lpq \ | 234 | $(top_builddir)/src/util/libgnunetutil.la $(XLIBS) -lpq \ |
@@ -236,6 +242,7 @@ test_namestore_api_store_flat_LDADD = \ | |||
236 | $(top_builddir)/src/testing/libgnunettesting.la \ | 242 | $(top_builddir)/src/testing/libgnunettesting.la \ |
237 | $(top_builddir)/src/util/libgnunetutil.la \ | 243 | $(top_builddir)/src/util/libgnunetutil.la \ |
238 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 244 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
245 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
239 | libgnunetnamestore.la | 246 | libgnunetnamestore.la |
240 | 247 | ||
241 | test_namestore_api_store_sqlite_SOURCES = \ | 248 | test_namestore_api_store_sqlite_SOURCES = \ |
@@ -244,6 +251,7 @@ test_namestore_api_store_sqlite_LDADD = \ | |||
244 | $(top_builddir)/src/testing/libgnunettesting.la \ | 251 | $(top_builddir)/src/testing/libgnunettesting.la \ |
245 | $(top_builddir)/src/util/libgnunetutil.la \ | 252 | $(top_builddir)/src/util/libgnunetutil.la \ |
246 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 253 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
254 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
247 | libgnunetnamestore.la | 255 | libgnunetnamestore.la |
248 | 256 | ||
249 | test_namestore_api_store_postgres_SOURCES = \ | 257 | test_namestore_api_store_postgres_SOURCES = \ |
@@ -252,6 +260,7 @@ test_namestore_api_store_postgres_LDADD = \ | |||
252 | $(top_builddir)/src/testing/libgnunettesting.la \ | 260 | $(top_builddir)/src/testing/libgnunettesting.la \ |
253 | $(top_builddir)/src/util/libgnunetutil.la \ | 261 | $(top_builddir)/src/util/libgnunetutil.la \ |
254 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 262 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
263 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
255 | libgnunetnamestore.la | 264 | libgnunetnamestore.la |
256 | 265 | ||
257 | test_namestore_api_store_update_flat_SOURCES = \ | 266 | test_namestore_api_store_update_flat_SOURCES = \ |
diff --git a/src/namestore/gnunet-namestore-fcfsd.c b/src/namestore/gnunet-namestore-fcfsd.c index 34641d22e..22d108067 100644 --- a/src/namestore/gnunet-namestore-fcfsd.c +++ b/src/namestore/gnunet-namestore-fcfsd.c | |||
@@ -164,7 +164,7 @@ struct Request | |||
164 | */ | 164 | */ |
165 | char public_key[128]; | 165 | char public_key[128]; |
166 | 166 | ||
167 | struct GNUNET_CRYPTO_EcdsaPublicKey pub; | 167 | struct GNUNET_IDENTITY_PublicKey pub; |
168 | }; | 168 | }; |
169 | 169 | ||
170 | /** | 170 | /** |
@@ -211,7 +211,7 @@ static struct GNUNET_NAMESTORE_Handle *ns; | |||
211 | /** | 211 | /** |
212 | * Private key for the fcfsd zone. | 212 | * Private key for the fcfsd zone. |
213 | */ | 213 | */ |
214 | static struct GNUNET_CRYPTO_EcdsaPrivateKey fcfs_zone_pkey; | 214 | static struct GNUNET_IDENTITY_PrivateKey fcfs_zone_pkey; |
215 | 215 | ||
216 | /** | 216 | /** |
217 | * Connection to identity service. | 217 | * Connection to identity service. |
@@ -306,7 +306,6 @@ zone_iteration_end (void *cls) | |||
306 | /* return static form */ | 306 | /* return static form */ |
307 | GNUNET_asprintf (&full_page, | 307 | GNUNET_asprintf (&full_page, |
308 | ZONEINFO_PAGE, | 308 | ZONEINFO_PAGE, |
309 | zr->zoneinfo, | ||
310 | zr->zoneinfo); | 309 | zr->zoneinfo); |
311 | response = MHD_create_response_from_buffer (strlen (full_page), | 310 | response = MHD_create_response_from_buffer (strlen (full_page), |
312 | (void *) full_page, | 311 | (void *) full_page, |
@@ -332,7 +331,7 @@ zone_iteration_end (void *cls) | |||
332 | */ | 331 | */ |
333 | static void | 332 | static void |
334 | iterate_cb (void *cls, | 333 | iterate_cb (void *cls, |
335 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 334 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, |
336 | const char *name, | 335 | const char *name, |
337 | unsigned int rd_len, | 336 | unsigned int rd_len, |
338 | const struct GNUNET_GNSRECORD_Data *rd) | 337 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -350,7 +349,8 @@ iterate_cb (void *cls, | |||
350 | return; | 349 | return; |
351 | } | 350 | } |
352 | 351 | ||
353 | if (GNUNET_GNSRECORD_TYPE_PKEY != rd->record_type) | 352 | if ((GNUNET_GNSRECORD_TYPE_PKEY != rd->record_type) && |
353 | (GNUNET_GNSRECORD_TYPE_EDKEY != rd->record_type)) | ||
354 | { | 354 | { |
355 | GNUNET_NAMESTORE_zone_iterator_next (zr->list_it, | 355 | GNUNET_NAMESTORE_zone_iterator_next (zr->list_it, |
356 | 1); | 356 | 1); |
@@ -615,13 +615,14 @@ zone_to_name_error (void *cls) | |||
615 | */ | 615 | */ |
616 | static void | 616 | static void |
617 | zone_to_name_cb (void *cls, | 617 | zone_to_name_cb (void *cls, |
618 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 618 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, |
619 | const char *name, | 619 | const char *name, |
620 | unsigned int rd_count, | 620 | unsigned int rd_count, |
621 | const struct GNUNET_GNSRECORD_Data *rd) | 621 | const struct GNUNET_GNSRECORD_Data *rd) |
622 | { | 622 | { |
623 | struct Request *request = cls; | 623 | struct Request *request = cls; |
624 | struct GNUNET_GNSRECORD_Data r; | 624 | struct GNUNET_GNSRECORD_Data r; |
625 | char *rdata; | ||
625 | 626 | ||
626 | (void) rd; | 627 | (void) rd; |
627 | (void) zone_key; | 628 | (void) zone_key; |
@@ -636,10 +637,21 @@ zone_to_name_cb (void *cls, | |||
636 | run_httpd_now (); | 637 | run_httpd_now (); |
637 | return; | 638 | return; |
638 | } | 639 | } |
639 | r.data = &request->pub; | 640 | if (GNUNET_OK != GNUNET_GNSRECORD_data_from_identity (&request->pub, |
640 | r.data_size = sizeof(request->pub); | 641 | &rdata, |
642 | &r.data_size, | ||
643 | &r.record_type)) | ||
644 | { | ||
645 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, | ||
646 | _ ("Error creating record data.\n")); | ||
647 | request->phase = RP_FAIL; | ||
648 | MHD_resume_connection (request->con); | ||
649 | run_httpd_now (); | ||
650 | return; | ||
651 | } | ||
652 | |||
653 | r.data = rdata; | ||
641 | r.expiration_time = UINT64_MAX; | 654 | r.expiration_time = UINT64_MAX; |
642 | r.record_type = GNUNET_GNSRECORD_TYPE_PKEY; | ||
643 | r.flags = GNUNET_GNSRECORD_RF_NONE; | 655 | r.flags = GNUNET_GNSRECORD_RF_NONE; |
644 | request->qe = GNUNET_NAMESTORE_records_store (ns, | 656 | request->qe = GNUNET_NAMESTORE_records_store (ns, |
645 | &fcfs_zone_pkey, | 657 | &fcfs_zone_pkey, |
@@ -647,6 +659,7 @@ zone_to_name_cb (void *cls, | |||
647 | 1, &r, | 659 | 1, &r, |
648 | &put_continuation, | 660 | &put_continuation, |
649 | request); | 661 | request); |
662 | GNUNET_free (rdata); | ||
650 | } | 663 | } |
651 | 664 | ||
652 | 665 | ||
@@ -677,7 +690,7 @@ lookup_it_error (void *cls) | |||
677 | */ | 690 | */ |
678 | static void | 691 | static void |
679 | lookup_it_processor (void *cls, | 692 | lookup_it_processor (void *cls, |
680 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zonekey, | 693 | const struct GNUNET_IDENTITY_PrivateKey *zonekey, |
681 | const char *label, | 694 | const char *label, |
682 | unsigned int rd_count, | 695 | unsigned int rd_count, |
683 | const struct GNUNET_GNSRECORD_Data *rd) | 696 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -712,9 +725,8 @@ lookup_it_finished (void *cls) | |||
712 | return; | 725 | return; |
713 | } | 726 | } |
714 | if (GNUNET_OK != | 727 | if (GNUNET_OK != |
715 | GNUNET_CRYPTO_ecdsa_public_key_from_string (request->public_key, | 728 | GNUNET_IDENTITY_public_key_from_string (request->public_key, |
716 | strlen (request->public_key), | 729 | &request->pub)) |
717 | &request->pub)) | ||
718 | { | 730 | { |
719 | GNUNET_break (0); | 731 | GNUNET_break (0); |
720 | request->phase = RP_FAIL; | 732 | request->phase = RP_FAIL; |
@@ -767,7 +779,7 @@ create_response (void *cls, | |||
767 | { | 779 | { |
768 | struct MHD_Response *response; | 780 | struct MHD_Response *response; |
769 | struct Request *request; | 781 | struct Request *request; |
770 | struct GNUNET_CRYPTO_EcdsaPublicKey pub; | 782 | struct GNUNET_IDENTITY_PublicKey pub; |
771 | MHD_RESULT ret; | 783 | MHD_RESULT ret; |
772 | 784 | ||
773 | (void) cls; | 785 | (void) cls; |
@@ -822,10 +834,8 @@ create_response (void *cls, | |||
822 | request->pp = NULL; | 834 | request->pp = NULL; |
823 | } | 835 | } |
824 | if (GNUNET_OK != | 836 | if (GNUNET_OK != |
825 | GNUNET_CRYPTO_ecdsa_public_key_from_string (request->public_key, | 837 | GNUNET_IDENTITY_public_key_from_string (request->public_key, |
826 | strlen ( | 838 | &pub)) |
827 | request->public_key), | ||
828 | &pub)) | ||
829 | { | 839 | { |
830 | /* parse error */ | 840 | /* parse error */ |
831 | return fill_s_reply ("Failed to parse given public key", | 841 | return fill_s_reply ("Failed to parse given public key", |
@@ -1211,7 +1221,8 @@ main (int argc, | |||
1211 | options, | 1221 | options, |
1212 | &run, NULL)) ? 0 : 1; | 1222 | &run, NULL)) ? 0 : 1; |
1213 | GNUNET_free_nz ((void *) argv); | 1223 | GNUNET_free_nz ((void *) argv); |
1214 | GNUNET_CRYPTO_ecdsa_key_clear (&fcfs_zone_pkey); | 1224 | // FIXME |
1225 | // GNUNET_CRYPTO_ecdsa_key_clear (&fcfs_zone_pkey); | ||
1215 | return ret; | 1226 | return ret; |
1216 | } | 1227 | } |
1217 | 1228 | ||
diff --git a/src/namestore/gnunet-namestore.c b/src/namestore/gnunet-namestore.c index 07d045b90..92d2cf627 100644 --- a/src/namestore/gnunet-namestore.c +++ b/src/namestore/gnunet-namestore.c | |||
@@ -59,7 +59,7 @@ static struct GNUNET_NAMESTORE_Handle *ns; | |||
59 | /** | 59 | /** |
60 | * Private key for the our zone. | 60 | * Private key for the our zone. |
61 | */ | 61 | */ |
62 | static struct GNUNET_CRYPTO_EcdsaPrivateKey zone_pkey; | 62 | static struct GNUNET_IDENTITY_PrivateKey zone_pkey; |
63 | 63 | ||
64 | /** | 64 | /** |
65 | * Handle to identity lookup. | 65 | * Handle to identity lookup. |
@@ -496,7 +496,7 @@ display_record (const char *rname, | |||
496 | */ | 496 | */ |
497 | static void | 497 | static void |
498 | display_record_iterator (void *cls, | 498 | display_record_iterator (void *cls, |
499 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 499 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, |
500 | const char *rname, | 500 | const char *rname, |
501 | unsigned int rd_len, | 501 | unsigned int rd_len, |
502 | const struct GNUNET_GNSRECORD_Data *rd) | 502 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -519,7 +519,7 @@ display_record_iterator (void *cls, | |||
519 | */ | 519 | */ |
520 | static void | 520 | static void |
521 | display_record_monitor (void *cls, | 521 | display_record_monitor (void *cls, |
522 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 522 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, |
523 | const char *rname, | 523 | const char *rname, |
524 | unsigned int rd_len, | 524 | unsigned int rd_len, |
525 | const struct GNUNET_GNSRECORD_Data *rd) | 525 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -542,7 +542,7 @@ display_record_monitor (void *cls, | |||
542 | */ | 542 | */ |
543 | static void | 543 | static void |
544 | display_record_lookup (void *cls, | 544 | display_record_lookup (void *cls, |
545 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 545 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, |
546 | const char *rname, | 546 | const char *rname, |
547 | unsigned int rd_len, | 547 | unsigned int rd_len, |
548 | const struct GNUNET_GNSRECORD_Data *rd) | 548 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -622,7 +622,7 @@ add_error_cb (void *cls) | |||
622 | */ | 622 | */ |
623 | static void | 623 | static void |
624 | get_existing_record (void *cls, | 624 | get_existing_record (void *cls, |
625 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 625 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, |
626 | const char *rec_name, | 626 | const char *rec_name, |
627 | unsigned int rd_count, | 627 | unsigned int rd_count, |
628 | const struct GNUNET_GNSRECORD_Data *rd) | 628 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -661,11 +661,11 @@ get_existing_record (void *cls, | |||
661 | return; | 661 | return; |
662 | 662 | ||
663 | case GNUNET_GNSRECORD_TYPE_PKEY: | 663 | case GNUNET_GNSRECORD_TYPE_PKEY: |
664 | case GNUNET_GNSRECORD_TYPE_EDKEY: | ||
664 | fprintf ( | 665 | fprintf ( |
665 | stderr, | 666 | stderr, |
666 | _ ( | 667 | _ ( |
667 | "A %s record exists already under `%s', no other records can be added.\n"), | 668 | "A zone key record exists already under `%s', no other records can be added.\n"), |
668 | "PKEY", | ||
669 | rec_name); | 669 | rec_name); |
670 | ret = 1; | 670 | ret = 1; |
671 | test_finished (); | 671 | test_finished (); |
@@ -703,13 +703,13 @@ get_existing_record (void *cls, | |||
703 | break; | 703 | break; |
704 | 704 | ||
705 | case GNUNET_GNSRECORD_TYPE_PKEY: | 705 | case GNUNET_GNSRECORD_TYPE_PKEY: |
706 | case GNUNET_GNSRECORD_TYPE_EDKEY: | ||
706 | if (0 != rd_count) | 707 | if (0 != rd_count) |
707 | { | 708 | { |
708 | fprintf (stderr, | 709 | fprintf (stderr, |
709 | _ ( | 710 | _ ( |
710 | "Records already exist under `%s', cannot add `%s' record.\n"), | 711 | "Records already exist under `%s', cannot add record.\n"), |
711 | rec_name, | 712 | rec_name); |
712 | "PKEY"); | ||
713 | ret = 1; | 713 | ret = 1; |
714 | test_finished (); | 714 | test_finished (); |
715 | return; | 715 | return; |
@@ -781,7 +781,7 @@ reverse_error_cb (void *cls) | |||
781 | */ | 781 | */ |
782 | static void | 782 | static void |
783 | handle_reverse_lookup (void *cls, | 783 | handle_reverse_lookup (void *cls, |
784 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 784 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
785 | const char *label, | 785 | const char *label, |
786 | unsigned int rd_count, | 786 | unsigned int rd_count, |
787 | const struct GNUNET_GNSRECORD_Data *rd) | 787 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -826,7 +826,7 @@ del_lookup_error_cb (void *cls) | |||
826 | */ | 826 | */ |
827 | static void | 827 | static void |
828 | del_monitor (void *cls, | 828 | del_monitor (void *cls, |
829 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 829 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
830 | const char *label, | 830 | const char *label, |
831 | unsigned int rd_count, | 831 | unsigned int rd_count, |
832 | const struct GNUNET_GNSRECORD_Data *rd) | 832 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1187,12 +1187,11 @@ run_with_zone_pkey (const struct GNUNET_CONFIGURATION_Handle *cfg) | |||
1187 | } | 1187 | } |
1188 | if (NULL != reverse_pkey) | 1188 | if (NULL != reverse_pkey) |
1189 | { | 1189 | { |
1190 | struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 1190 | struct GNUNET_IDENTITY_PublicKey pubkey; |
1191 | 1191 | ||
1192 | if (GNUNET_OK != | 1192 | if (GNUNET_OK != |
1193 | GNUNET_CRYPTO_ecdsa_public_key_from_string (reverse_pkey, | 1193 | GNUNET_IDENTITY_public_key_from_string (reverse_pkey, |
1194 | strlen (reverse_pkey), | 1194 | &pubkey)) |
1195 | &pubkey)) | ||
1196 | { | 1195 | { |
1197 | fprintf (stderr, | 1196 | fprintf (stderr, |
1198 | _ ("Invalid public key for reverse lookup `%s'\n"), | 1197 | _ ("Invalid public key for reverse lookup `%s'\n"), |
@@ -1211,12 +1210,12 @@ run_with_zone_pkey (const struct GNUNET_CONFIGURATION_Handle *cfg) | |||
1211 | { | 1210 | { |
1212 | char sh[105]; | 1211 | char sh[105]; |
1213 | char sname[64]; | 1212 | char sname[64]; |
1214 | struct GNUNET_CRYPTO_EcdsaPublicKey pkey; | 1213 | struct GNUNET_IDENTITY_PublicKey pkey; |
1215 | 1214 | ||
1216 | GNUNET_STRINGS_utf8_tolower (uri, uri); | 1215 | GNUNET_STRINGS_utf8_tolower (uri, uri); |
1217 | if ((2 != (sscanf (uri, "gnunet://gns/%52s/%63s", sh, sname))) || | 1216 | if ((2 != (sscanf (uri, "gnunet://gns/%52s/%63s", sh, sname))) || |
1218 | (GNUNET_OK != | 1217 | (GNUNET_OK != |
1219 | GNUNET_CRYPTO_ecdsa_public_key_from_string (sh, strlen (sh), &pkey))) | 1218 | GNUNET_IDENTITY_public_key_from_string (sh, &pkey))) |
1220 | { | 1219 | { |
1221 | fprintf (stderr, _ ("Invalid URI `%s'\n"), uri); | 1220 | fprintf (stderr, _ ("Invalid URI `%s'\n"), uri); |
1222 | GNUNET_SCHEDULER_shutdown (); | 1221 | GNUNET_SCHEDULER_shutdown (); |
@@ -1242,8 +1241,8 @@ run_with_zone_pkey (const struct GNUNET_CONFIGURATION_Handle *cfg) | |||
1242 | } | 1241 | } |
1243 | memset (&rd, 0, sizeof(rd)); | 1242 | memset (&rd, 0, sizeof(rd)); |
1244 | rd.data = &pkey; | 1243 | rd.data = &pkey; |
1245 | rd.data_size = sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey); | 1244 | rd.data_size = GNUNET_IDENTITY_key_get_length (&pkey); |
1246 | rd.record_type = GNUNET_GNSRECORD_TYPE_PKEY; | 1245 | rd.record_type = ntohl (pkey.type); |
1247 | rd.expiration_time = etime; | 1246 | rd.expiration_time = etime; |
1248 | if (GNUNET_YES == etime_is_rel) | 1247 | if (GNUNET_YES == etime_is_rel) |
1249 | rd.flags |= GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION; | 1248 | rd.flags |= GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION; |
@@ -1704,11 +1703,13 @@ main (int argc, char *const *argv) | |||
1704 | NULL))) | 1703 | NULL))) |
1705 | { | 1704 | { |
1706 | GNUNET_free_nz ((void *) argv); | 1705 | GNUNET_free_nz ((void *) argv); |
1707 | GNUNET_CRYPTO_ecdsa_key_clear (&zone_pkey); | 1706 | //FIXME |
1707 | //GNUNET_CRYPTO_ecdsa_key_clear (&zone_pkey); | ||
1708 | return lret; | 1708 | return lret; |
1709 | } | 1709 | } |
1710 | GNUNET_free_nz ((void *) argv); | 1710 | GNUNET_free_nz ((void *) argv); |
1711 | GNUNET_CRYPTO_ecdsa_key_clear (&zone_pkey); | 1711 | //FIXME |
1712 | //GNUNET_CRYPTO_ecdsa_key_clear (&zone_pkey); | ||
1712 | return ret; | 1713 | return ret; |
1713 | } | 1714 | } |
1714 | 1715 | ||
diff --git a/src/namestore/gnunet-service-namestore.c b/src/namestore/gnunet-service-namestore.c index b24bb2952..d6774b37b 100644 --- a/src/namestore/gnunet-service-namestore.c +++ b/src/namestore/gnunet-service-namestore.c | |||
@@ -82,7 +82,7 @@ struct ZoneIteration | |||
82 | /** | 82 | /** |
83 | * Key of the zone we are iterating over. | 83 | * Key of the zone we are iterating over. |
84 | */ | 84 | */ |
85 | struct GNUNET_CRYPTO_EcdsaPrivateKey zone; | 85 | struct GNUNET_IDENTITY_PrivateKey zone; |
86 | 86 | ||
87 | /** | 87 | /** |
88 | * Last sequence number in the zone iteration used to address next | 88 | * Last sequence number in the zone iteration used to address next |
@@ -174,7 +174,7 @@ struct ZoneMonitor | |||
174 | /** | 174 | /** |
175 | * Private key of the zone. | 175 | * Private key of the zone. |
176 | */ | 176 | */ |
177 | struct GNUNET_CRYPTO_EcdsaPrivateKey zone; | 177 | struct GNUNET_IDENTITY_PrivateKey zone; |
178 | 178 | ||
179 | /** | 179 | /** |
180 | * Task active during initial iteration. | 180 | * Task active during initial iteration. |
@@ -314,7 +314,7 @@ struct NickCache | |||
314 | /** | 314 | /** |
315 | * Zone the cache entry is for. | 315 | * Zone the cache entry is for. |
316 | */ | 316 | */ |
317 | struct GNUNET_CRYPTO_EcdsaPrivateKey zone; | 317 | struct GNUNET_IDENTITY_PrivateKey zone; |
318 | 318 | ||
319 | /** | 319 | /** |
320 | * Cached record data. | 320 | * Cached record data. |
@@ -336,7 +336,7 @@ static struct NickCache nick_cache[NC_SIZE]; | |||
336 | /** | 336 | /** |
337 | * Public key of all zeros. | 337 | * Public key of all zeros. |
338 | */ | 338 | */ |
339 | static const struct GNUNET_CRYPTO_EcdsaPrivateKey zero; | 339 | static const struct GNUNET_IDENTITY_PrivateKey zero; |
340 | 340 | ||
341 | /** | 341 | /** |
342 | * Configuration handle. | 342 | * Configuration handle. |
@@ -481,7 +481,7 @@ free_store_activity (struct StoreActivity *sa) | |||
481 | static void | 481 | static void |
482 | lookup_nick_it (void *cls, | 482 | lookup_nick_it (void *cls, |
483 | uint64_t seq, | 483 | uint64_t seq, |
484 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *private_key, | 484 | const struct GNUNET_IDENTITY_PrivateKey *private_key, |
485 | const char *label, | 485 | const char *label, |
486 | unsigned int rd_count, | 486 | unsigned int rd_count, |
487 | const struct GNUNET_GNSRECORD_Data *rd) | 487 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -521,7 +521,7 @@ lookup_nick_it (void *cls, | |||
521 | * @param nick nick entry to cache | 521 | * @param nick nick entry to cache |
522 | */ | 522 | */ |
523 | static void | 523 | static void |
524 | cache_nick (const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 524 | cache_nick (const struct GNUNET_IDENTITY_PrivateKey *zone, |
525 | const struct GNUNET_GNSRECORD_Data *nick) | 525 | const struct GNUNET_GNSRECORD_Data *nick) |
526 | { | 526 | { |
527 | struct NickCache *oldest; | 527 | struct NickCache *oldest; |
@@ -564,9 +564,9 @@ cache_nick (const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | |||
564 | * @return NULL if no NICK record was found | 564 | * @return NULL if no NICK record was found |
565 | */ | 565 | */ |
566 | static struct GNUNET_GNSRECORD_Data * | 566 | static struct GNUNET_GNSRECORD_Data * |
567 | get_nick_record (const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone) | 567 | get_nick_record (const struct GNUNET_IDENTITY_PrivateKey *zone) |
568 | { | 568 | { |
569 | struct GNUNET_CRYPTO_EcdsaPublicKey pub; | 569 | struct GNUNET_IDENTITY_PublicKey pub; |
570 | struct GNUNET_GNSRECORD_Data *nick; | 570 | struct GNUNET_GNSRECORD_Data *nick; |
571 | int res; | 571 | int res; |
572 | 572 | ||
@@ -606,7 +606,7 @@ get_nick_record (const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone) | |||
606 | __LINE__); | 606 | __LINE__); |
607 | if (1 == do_log) | 607 | if (1 == do_log) |
608 | { | 608 | { |
609 | GNUNET_CRYPTO_ecdsa_key_get_public (zone, &pub); | 609 | GNUNET_IDENTITY_key_get_public (zone, &pub); |
610 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG | GNUNET_ERROR_TYPE_BULK, | 610 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG | GNUNET_ERROR_TYPE_BULK, |
611 | "No nick name set for zone `%s'\n", | 611 | "No nick name set for zone `%s'\n", |
612 | GNUNET_GNSRECORD_z2s (&pub)); | 612 | GNUNET_GNSRECORD_z2s (&pub)); |
@@ -720,7 +720,7 @@ merge_with_nick_records (const struct GNUNET_GNSRECORD_Data *nick_rd, | |||
720 | static void | 720 | static void |
721 | send_lookup_response (struct NamestoreClient *nc, | 721 | send_lookup_response (struct NamestoreClient *nc, |
722 | uint32_t request_id, | 722 | uint32_t request_id, |
723 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 723 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, |
724 | const char *name, | 724 | const char *name, |
725 | unsigned int rd_count, | 725 | unsigned int rd_count, |
726 | const struct GNUNET_GNSRECORD_Data *rd) | 726 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -899,14 +899,14 @@ static void | |||
899 | refresh_block (struct NamestoreClient *nc, | 899 | refresh_block (struct NamestoreClient *nc, |
900 | struct ZoneIteration *zi, | 900 | struct ZoneIteration *zi, |
901 | uint32_t rid, | 901 | uint32_t rid, |
902 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 902 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, |
903 | const char *name, | 903 | const char *name, |
904 | unsigned int rd_count, | 904 | unsigned int rd_count, |
905 | const struct GNUNET_GNSRECORD_Data *rd) | 905 | const struct GNUNET_GNSRECORD_Data *rd) |
906 | { | 906 | { |
907 | struct GNUNET_GNSRECORD_Block *block; | 907 | struct GNUNET_GNSRECORD_Block *block; |
908 | struct CacheOperation *cop; | 908 | struct CacheOperation *cop; |
909 | struct GNUNET_CRYPTO_EcdsaPublicKey pkey; | 909 | struct GNUNET_IDENTITY_PublicKey pkey; |
910 | struct GNUNET_GNSRECORD_Data *nick; | 910 | struct GNUNET_GNSRECORD_Data *nick; |
911 | struct GNUNET_GNSRECORD_Data *res; | 911 | struct GNUNET_GNSRECORD_Data *res; |
912 | unsigned int res_count; | 912 | unsigned int res_count; |
@@ -946,7 +946,7 @@ refresh_block (struct NamestoreClient *nc, | |||
946 | block = | 946 | block = |
947 | GNUNET_GNSRECORD_block_create (zone_key, exp_time, name, res, res_count); | 947 | GNUNET_GNSRECORD_block_create (zone_key, exp_time, name, res, res_count); |
948 | GNUNET_assert (NULL != block); | 948 | GNUNET_assert (NULL != block); |
949 | GNUNET_CRYPTO_ecdsa_key_get_public (zone_key, &pkey); | 949 | GNUNET_IDENTITY_key_get_public (zone_key, &pkey); |
950 | GNUNET_log ( | 950 | GNUNET_log ( |
951 | GNUNET_ERROR_TYPE_DEBUG, | 951 | GNUNET_ERROR_TYPE_DEBUG, |
952 | "Caching block for label `%s' with %u records and expiration %s in zone `%s' in namecache\n", | 952 | "Caching block for label `%s' with %u records and expiration %s in zone `%s' in namecache\n", |
@@ -1214,7 +1214,7 @@ struct RecordLookupContext | |||
1214 | static void | 1214 | static void |
1215 | lookup_it (void *cls, | 1215 | lookup_it (void *cls, |
1216 | uint64_t seq, | 1216 | uint64_t seq, |
1217 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *private_key, | 1217 | const struct GNUNET_IDENTITY_PrivateKey *private_key, |
1218 | const char *label, | 1218 | const char *label, |
1219 | unsigned int rd_count, | 1219 | unsigned int rd_count, |
1220 | const struct GNUNET_GNSRECORD_Data *rd) | 1220 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1605,7 +1605,7 @@ struct ZoneToNameCtx | |||
1605 | static void | 1605 | static void |
1606 | handle_zone_to_name_it (void *cls, | 1606 | handle_zone_to_name_it (void *cls, |
1607 | uint64_t seq, | 1607 | uint64_t seq, |
1608 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 1608 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, |
1609 | const char *name, | 1609 | const char *name, |
1610 | unsigned int rd_count, | 1610 | unsigned int rd_count, |
1611 | const struct GNUNET_GNSRECORD_Data *rd) | 1611 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1738,7 +1738,7 @@ struct ZoneIterationProcResult | |||
1738 | static void | 1738 | static void |
1739 | zone_iterate_proc (void *cls, | 1739 | zone_iterate_proc (void *cls, |
1740 | uint64_t seq, | 1740 | uint64_t seq, |
1741 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 1741 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, |
1742 | const char *name, | 1742 | const char *name, |
1743 | unsigned int rd_count, | 1743 | unsigned int rd_count, |
1744 | const struct GNUNET_GNSRECORD_Data *rd) | 1744 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -2009,7 +2009,7 @@ monitor_iteration_next (void *cls); | |||
2009 | static void | 2009 | static void |
2010 | monitor_iterate_cb (void *cls, | 2010 | monitor_iterate_cb (void *cls, |
2011 | uint64_t seq, | 2011 | uint64_t seq, |
2012 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 2012 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, |
2013 | const char *name, | 2013 | const char *name, |
2014 | unsigned int rd_count, | 2014 | unsigned int rd_count, |
2015 | const struct GNUNET_GNSRECORD_Data *rd) | 2015 | const struct GNUNET_GNSRECORD_Data *rd) |
diff --git a/src/namestore/gnunet-zoneimport.c b/src/namestore/gnunet-zoneimport.c index 5b4e41475..ce62b52d5 100644 --- a/src/namestore/gnunet-zoneimport.c +++ b/src/namestore/gnunet-zoneimport.c | |||
@@ -96,7 +96,7 @@ struct Zone | |||
96 | /** | 96 | /** |
97 | * Private key of the zone. | 97 | * Private key of the zone. |
98 | */ | 98 | */ |
99 | struct GNUNET_CRYPTO_EcdsaPrivateKey key; | 99 | struct GNUNET_IDENTITY_PrivateKey key; |
100 | }; | 100 | }; |
101 | 101 | ||
102 | 102 | ||
@@ -1405,7 +1405,7 @@ ns_lookup_error_cb (void *cls) | |||
1405 | */ | 1405 | */ |
1406 | static void | 1406 | static void |
1407 | ns_lookup_result_cb (void *cls, | 1407 | ns_lookup_result_cb (void *cls, |
1408 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | 1408 | const struct GNUNET_IDENTITY_PrivateKey *key, |
1409 | const char *label, | 1409 | const char *label, |
1410 | unsigned int rd_count, | 1410 | unsigned int rd_count, |
1411 | const struct GNUNET_GNSRECORD_Data *rd) | 1411 | const struct GNUNET_GNSRECORD_Data *rd) |
diff --git a/src/namestore/namestore.h b/src/namestore/namestore.h index 6f45ab1c1..fd9a8ed47 100644 --- a/src/namestore/namestore.h +++ b/src/namestore/namestore.h | |||
@@ -90,7 +90,7 @@ struct RecordStoreMessage | |||
90 | /** | 90 | /** |
91 | * The private key of the authority. | 91 | * The private key of the authority. |
92 | */ | 92 | */ |
93 | struct GNUNET_CRYPTO_EcdsaPrivateKey private_key; | 93 | struct GNUNET_IDENTITY_PrivateKey private_key; |
94 | 94 | ||
95 | /* followed by: | 95 | /* followed by: |
96 | * name with length name_len | 96 | * name with length name_len |
@@ -134,7 +134,7 @@ struct LabelLookupMessage | |||
134 | /** | 134 | /** |
135 | * The private key of the zone to look up in | 135 | * The private key of the zone to look up in |
136 | */ | 136 | */ |
137 | struct GNUNET_CRYPTO_EcdsaPrivateKey zone; | 137 | struct GNUNET_IDENTITY_PrivateKey zone; |
138 | 138 | ||
139 | /* followed by: | 139 | /* followed by: |
140 | * name with length name_len | 140 | * name with length name_len |
@@ -176,7 +176,7 @@ struct LabelLookupResponseMessage | |||
176 | /** | 176 | /** |
177 | * The private key of the authority. | 177 | * The private key of the authority. |
178 | */ | 178 | */ |
179 | struct GNUNET_CRYPTO_EcdsaPrivateKey private_key; | 179 | struct GNUNET_IDENTITY_PrivateKey private_key; |
180 | 180 | ||
181 | /* followed by: | 181 | /* followed by: |
182 | * name with length name_len | 182 | * name with length name_len |
@@ -198,12 +198,12 @@ struct ZoneToNameMessage | |||
198 | /** | 198 | /** |
199 | * The private key of the zone to look up in | 199 | * The private key of the zone to look up in |
200 | */ | 200 | */ |
201 | struct GNUNET_CRYPTO_EcdsaPrivateKey zone; | 201 | struct GNUNET_IDENTITY_PrivateKey zone; |
202 | 202 | ||
203 | /** | 203 | /** |
204 | * The public key of the target zone | 204 | * The public key of the target zone |
205 | */ | 205 | */ |
206 | struct GNUNET_CRYPTO_EcdsaPublicKey value_zone; | 206 | struct GNUNET_IDENTITY_PublicKey value_zone; |
207 | }; | 207 | }; |
208 | 208 | ||
209 | 209 | ||
@@ -241,7 +241,7 @@ struct ZoneToNameResponseMessage | |||
241 | /** | 241 | /** |
242 | * The private key of the zone that contained the name. | 242 | * The private key of the zone that contained the name. |
243 | */ | 243 | */ |
244 | struct GNUNET_CRYPTO_EcdsaPrivateKey zone; | 244 | struct GNUNET_IDENTITY_PrivateKey zone; |
245 | 245 | ||
246 | /* followed by: | 246 | /* followed by: |
247 | * name with length name_len | 247 | * name with length name_len |
@@ -283,7 +283,7 @@ struct RecordResultMessage | |||
283 | /** | 283 | /** |
284 | * The private key of the authority. | 284 | * The private key of the authority. |
285 | */ | 285 | */ |
286 | struct GNUNET_CRYPTO_EcdsaPrivateKey private_key; | 286 | struct GNUNET_IDENTITY_PrivateKey private_key; |
287 | 287 | ||
288 | /* followed by: | 288 | /* followed by: |
289 | * name with length name_len | 289 | * name with length name_len |
@@ -311,7 +311,7 @@ struct ZoneMonitorStartMessage | |||
311 | /** | 311 | /** |
312 | * Zone key. | 312 | * Zone key. |
313 | */ | 313 | */ |
314 | struct GNUNET_CRYPTO_EcdsaPrivateKey zone; | 314 | struct GNUNET_IDENTITY_PrivateKey zone; |
315 | }; | 315 | }; |
316 | 316 | ||
317 | 317 | ||
@@ -352,7 +352,7 @@ struct ZoneIterationStartMessage | |||
352 | /** | 352 | /** |
353 | * Zone key. All zeros for "all zones". | 353 | * Zone key. All zeros for "all zones". |
354 | */ | 354 | */ |
355 | struct GNUNET_CRYPTO_EcdsaPrivateKey zone; | 355 | struct GNUNET_IDENTITY_PrivateKey zone; |
356 | }; | 356 | }; |
357 | 357 | ||
358 | 358 | ||
diff --git a/src/namestore/namestore_api.c b/src/namestore/namestore_api.c index f383f8b4a..c845b5019 100644 --- a/src/namestore/namestore_api.c +++ b/src/namestore/namestore_api.c | |||
@@ -174,7 +174,7 @@ struct GNUNET_NAMESTORE_ZoneIterator | |||
174 | /** | 174 | /** |
175 | * Private key of the zone. | 175 | * Private key of the zone. |
176 | */ | 176 | */ |
177 | struct GNUNET_CRYPTO_EcdsaPrivateKey zone; | 177 | struct GNUNET_IDENTITY_PrivateKey zone; |
178 | 178 | ||
179 | /** | 179 | /** |
180 | * The operation id this zone iteration operation has | 180 | * The operation id this zone iteration operation has |
@@ -493,7 +493,7 @@ handle_lookup_result (void *cls, const struct LabelLookupResponseMessage *msg) | |||
493 | static int | 493 | static int |
494 | check_record_result (void *cls, const struct RecordResultMessage *msg) | 494 | check_record_result (void *cls, const struct RecordResultMessage *msg) |
495 | { | 495 | { |
496 | static struct GNUNET_CRYPTO_EcdsaPrivateKey priv_dummy; | 496 | static struct GNUNET_IDENTITY_PrivateKey priv_dummy; |
497 | const char *name; | 497 | const char *name; |
498 | size_t msg_len; | 498 | size_t msg_len; |
499 | size_t name_len; | 499 | size_t name_len; |
@@ -981,7 +981,7 @@ warn_delay (void *cls) | |||
981 | struct GNUNET_NAMESTORE_QueueEntry * | 981 | struct GNUNET_NAMESTORE_QueueEntry * |
982 | GNUNET_NAMESTORE_records_store ( | 982 | GNUNET_NAMESTORE_records_store ( |
983 | struct GNUNET_NAMESTORE_Handle *h, | 983 | struct GNUNET_NAMESTORE_Handle *h, |
984 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pkey, | 984 | const struct GNUNET_IDENTITY_PrivateKey *pkey, |
985 | const char *label, | 985 | const char *label, |
986 | unsigned int rd_count, | 986 | unsigned int rd_count, |
987 | const struct GNUNET_GNSRECORD_Data *rd, | 987 | const struct GNUNET_GNSRECORD_Data *rd, |
@@ -1080,7 +1080,7 @@ GNUNET_NAMESTORE_records_store ( | |||
1080 | struct GNUNET_NAMESTORE_QueueEntry * | 1080 | struct GNUNET_NAMESTORE_QueueEntry * |
1081 | GNUNET_NAMESTORE_records_lookup ( | 1081 | GNUNET_NAMESTORE_records_lookup ( |
1082 | struct GNUNET_NAMESTORE_Handle *h, | 1082 | struct GNUNET_NAMESTORE_Handle *h, |
1083 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pkey, | 1083 | const struct GNUNET_IDENTITY_PrivateKey *pkey, |
1084 | const char *label, | 1084 | const char *label, |
1085 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1085 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1086 | void *error_cb_cls, | 1086 | void *error_cb_cls, |
@@ -1140,8 +1140,8 @@ GNUNET_NAMESTORE_records_lookup ( | |||
1140 | struct GNUNET_NAMESTORE_QueueEntry * | 1140 | struct GNUNET_NAMESTORE_QueueEntry * |
1141 | GNUNET_NAMESTORE_zone_to_name ( | 1141 | GNUNET_NAMESTORE_zone_to_name ( |
1142 | struct GNUNET_NAMESTORE_Handle *h, | 1142 | struct GNUNET_NAMESTORE_Handle *h, |
1143 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 1143 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
1144 | const struct GNUNET_CRYPTO_EcdsaPublicKey *value_zone, | 1144 | const struct GNUNET_IDENTITY_PublicKey *value_zone, |
1145 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1145 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1146 | void *error_cb_cls, | 1146 | void *error_cb_cls, |
1147 | GNUNET_NAMESTORE_RecordMonitor proc, | 1147 | GNUNET_NAMESTORE_RecordMonitor proc, |
@@ -1196,7 +1196,7 @@ GNUNET_NAMESTORE_zone_to_name ( | |||
1196 | struct GNUNET_NAMESTORE_ZoneIterator * | 1196 | struct GNUNET_NAMESTORE_ZoneIterator * |
1197 | GNUNET_NAMESTORE_zone_iteration_start ( | 1197 | GNUNET_NAMESTORE_zone_iteration_start ( |
1198 | struct GNUNET_NAMESTORE_Handle *h, | 1198 | struct GNUNET_NAMESTORE_Handle *h, |
1199 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 1199 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
1200 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1200 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1201 | void *error_cb_cls, | 1201 | void *error_cb_cls, |
1202 | GNUNET_NAMESTORE_RecordMonitor proc, | 1202 | GNUNET_NAMESTORE_RecordMonitor proc, |
diff --git a/src/namestore/namestore_api_monitor.c b/src/namestore/namestore_api_monitor.c index 9dc955544..6670e54ce 100644 --- a/src/namestore/namestore_api_monitor.c +++ b/src/namestore/namestore_api_monitor.c | |||
@@ -82,7 +82,7 @@ struct GNUNET_NAMESTORE_ZoneMonitor | |||
82 | /** | 82 | /** |
83 | * Monitored zone. | 83 | * Monitored zone. |
84 | */ | 84 | */ |
85 | struct GNUNET_CRYPTO_EcdsaPrivateKey zone; | 85 | struct GNUNET_IDENTITY_PrivateKey zone; |
86 | 86 | ||
87 | /** | 87 | /** |
88 | * Do we first iterate over all existing records? | 88 | * Do we first iterate over all existing records? |
@@ -302,7 +302,7 @@ reconnect (struct GNUNET_NAMESTORE_ZoneMonitor *zm) | |||
302 | struct GNUNET_NAMESTORE_ZoneMonitor * | 302 | struct GNUNET_NAMESTORE_ZoneMonitor * |
303 | GNUNET_NAMESTORE_zone_monitor_start ( | 303 | GNUNET_NAMESTORE_zone_monitor_start ( |
304 | const struct GNUNET_CONFIGURATION_Handle *cfg, | 304 | const struct GNUNET_CONFIGURATION_Handle *cfg, |
305 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 305 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
306 | int iterate_first, | 306 | int iterate_first, |
307 | GNUNET_SCHEDULER_TaskCallback error_cb, | 307 | GNUNET_SCHEDULER_TaskCallback error_cb, |
308 | void *error_cb_cls, | 308 | void *error_cb_cls, |
diff --git a/src/namestore/perf_namestore_api_zone_iteration.c b/src/namestore/perf_namestore_api_zone_iteration.c index c1012de62..f46a1c523 100644 --- a/src/namestore/perf_namestore_api_zone_iteration.c +++ b/src/namestore/perf_namestore_api_zone_iteration.c | |||
@@ -64,7 +64,7 @@ static struct GNUNET_SCHEDULER_Task *timeout_task; | |||
64 | 64 | ||
65 | static struct GNUNET_SCHEDULER_Task *t; | 65 | static struct GNUNET_SCHEDULER_Task *t; |
66 | 66 | ||
67 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey; | 67 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
68 | 68 | ||
69 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; | 69 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; |
70 | 70 | ||
@@ -188,7 +188,7 @@ fail_cb (void *cls) | |||
188 | 188 | ||
189 | static void | 189 | static void |
190 | zone_proc (void *cls, | 190 | zone_proc (void *cls, |
191 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 191 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
192 | const char *label, | 192 | const char *label, |
193 | unsigned int rd_count, | 193 | unsigned int rd_count, |
194 | const struct GNUNET_GNSRECORD_Data *rd) | 194 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -341,7 +341,8 @@ run (void *cls, | |||
341 | NULL); | 341 | NULL); |
342 | nsh = GNUNET_NAMESTORE_connect (cfg); | 342 | nsh = GNUNET_NAMESTORE_connect (cfg); |
343 | GNUNET_assert (NULL != nsh); | 343 | GNUNET_assert (NULL != nsh); |
344 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 344 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
345 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | ||
345 | start = GNUNET_TIME_absolute_get (); | 346 | start = GNUNET_TIME_absolute_get (); |
346 | t = GNUNET_SCHEDULER_add_now (&publish_record, | 347 | t = GNUNET_SCHEDULER_add_now (&publish_record, |
347 | NULL); | 348 | NULL); |
diff --git a/src/namestore/plugin_namestore_flat.c b/src/namestore/plugin_namestore_flat.c index 60b24df67..9ccc90cfd 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_CRYPTO_EcdsaPrivateKey private_key; | 57 | struct GNUNET_IDENTITY_PrivateKey private_key; |
58 | 58 | ||
59 | /** | 59 | /** |
60 | * Record cound | 60 | * Record cound |
@@ -86,7 +86,7 @@ struct FlatFileEntry | |||
86 | * @param h[out] initialized hash | 86 | * @param h[out] initialized hash |
87 | */ | 87 | */ |
88 | static void | 88 | static void |
89 | hash_pkey_and_label (const struct GNUNET_CRYPTO_EcdsaPrivateKey *pkey, | 89 | hash_pkey_and_label (const struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey *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_CRYPTO_EcdsaPrivateKey); | 98 | key_len = label_len + sizeof(struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey)); | 105 | sizeof(struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey *private_key; | 299 | struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey), | 348 | sizeof(struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey *zone_key, | 455 | GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey)); | 485 | sizeof(struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey *zone, | 520 | const struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey *zone; | 577 | const struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey *zone, | 650 | GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey *zone; | 677 | const struct GNUNET_IDENTITY_PrivateKey *zone; |
678 | const struct GNUNET_CRYPTO_EcdsaPublicKey *value_zone; | 678 | const struct GNUNET_IDENTITY_PublicKey *value_zone; |
679 | GNUNET_NAMESTORE_RecordIterator iter; | 679 | GNUNET_NAMESTORE_RecordIterator iter; |
680 | void *iter_cls; | 680 | void *iter_cls; |
681 | 681 | ||
@@ -698,11 +698,14 @@ zone_to_name (void *cls, | |||
698 | 698 | ||
699 | for (unsigned int i = 0; i < entry->record_count; i++) | 699 | for (unsigned int i = 0; i < entry->record_count; i++) |
700 | { | 700 | { |
701 | if (GNUNET_GNSRECORD_TYPE_PKEY != entry->record_data[i].record_type) | 701 | if (GNUNET_NO == |
702 | GNUNET_GNSRECORD_is_zonekey_type (entry->record_data[i].record_type)) | ||
703 | continue; | ||
704 | if (ztn->value_zone->type != entry->record_data[i].record_type) | ||
702 | continue; | 705 | continue; |
703 | if (0 == memcmp (ztn->value_zone, | 706 | if (0 == memcmp (ztn->value_zone, |
704 | entry->record_data[i].data, | 707 | entry->record_data[i].data, |
705 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey))) | 708 | entry->record_data[i].data_size)) |
706 | { | 709 | { |
707 | ztn->iter (ztn->iter_cls, | 710 | ztn->iter (ztn->iter_cls, |
708 | i + 1, /* zero is illegal! */ | 711 | i + 1, /* zero is illegal! */ |
@@ -730,9 +733,9 @@ zone_to_name (void *cls, | |||
730 | */ | 733 | */ |
731 | static int | 734 | static int |
732 | namestore_flat_zone_to_name (void *cls, | 735 | namestore_flat_zone_to_name (void *cls, |
733 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 736 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
734 | const struct | 737 | const struct |
735 | GNUNET_CRYPTO_EcdsaPublicKey *value_zone, | 738 | GNUNET_IDENTITY_PublicKey *value_zone, |
736 | GNUNET_NAMESTORE_RecordIterator iter, | 739 | GNUNET_NAMESTORE_RecordIterator iter, |
737 | void *iter_cls) | 740 | void *iter_cls) |
738 | { | 741 | { |
diff --git a/src/namestore/plugin_namestore_postgres.c b/src/namestore/plugin_namestore_postgres.c index 01dddde9e..bdbaf96b3 100644 --- a/src/namestore/plugin_namestore_postgres.c +++ b/src/namestore/plugin_namestore_postgres.c | |||
@@ -73,8 +73,7 @@ database_setup (struct Plugin *plugin) | |||
73 | " record_data BYTEA NOT NULL DEFAULT ''," | 73 | " record_data BYTEA NOT NULL DEFAULT ''," |
74 | " label TEXT NOT NULL DEFAULT ''," | 74 | " label TEXT NOT NULL DEFAULT ''," |
75 | " CONSTRAINT zl UNIQUE (zone_private_key,label)" | 75 | " CONSTRAINT zl UNIQUE (zone_private_key,label)" |
76 | ")" | 76 | ")"); |
77 | "WITH OIDS"); | ||
78 | struct GNUNET_PQ_ExecuteStatement es_default = | 77 | struct GNUNET_PQ_ExecuteStatement es_default = |
79 | GNUNET_PQ_make_execute ("CREATE TABLE IF NOT EXISTS ns098records (" | 78 | GNUNET_PQ_make_execute ("CREATE TABLE IF NOT EXISTS ns098records (" |
80 | " seq BIGSERIAL PRIMARY KEY," | 79 | " seq BIGSERIAL PRIMARY KEY," |
@@ -85,8 +84,7 @@ database_setup (struct Plugin *plugin) | |||
85 | " record_data BYTEA NOT NULL DEFAULT ''," | 84 | " record_data BYTEA NOT NULL DEFAULT ''," |
86 | " label TEXT NOT NULL DEFAULT ''," | 85 | " label TEXT NOT NULL DEFAULT ''," |
87 | " CONSTRAINT zl UNIQUE (zone_private_key,label)" | 86 | " CONSTRAINT zl UNIQUE (zone_private_key,label)" |
88 | ")" | 87 | ")"); |
89 | "WITH OIDS"); | ||
90 | const struct GNUNET_PQ_ExecuteStatement *cr; | 88 | const struct GNUNET_PQ_ExecuteStatement *cr; |
91 | struct GNUNET_PQ_ExecuteStatement sc = GNUNET_PQ_EXECUTE_STATEMENT_END; | 89 | struct GNUNET_PQ_ExecuteStatement sc = GNUNET_PQ_EXECUTE_STATEMENT_END; |
92 | 90 | ||
@@ -182,13 +180,13 @@ database_setup (struct Plugin *plugin) | |||
182 | static int | 180 | static int |
183 | namestore_postgres_store_records (void *cls, | 181 | namestore_postgres_store_records (void *cls, |
184 | const struct | 182 | const struct |
185 | GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 183 | GNUNET_IDENTITY_PrivateKey *zone_key, |
186 | const char *label, | 184 | const char *label, |
187 | unsigned int rd_count, | 185 | unsigned int rd_count, |
188 | const struct GNUNET_GNSRECORD_Data *rd) | 186 | const struct GNUNET_GNSRECORD_Data *rd) |
189 | { | 187 | { |
190 | struct Plugin *plugin = cls; | 188 | struct Plugin *plugin = cls; |
191 | struct GNUNET_CRYPTO_EcdsaPublicKey pkey; | 189 | struct GNUNET_IDENTITY_PublicKey pkey; |
192 | uint64_t rvalue; | 190 | uint64_t rvalue; |
193 | uint32_t rd_count32 = (uint32_t) rd_count; | 191 | uint32_t rd_count32 = (uint32_t) rd_count; |
194 | ssize_t data_size; | 192 | ssize_t data_size; |
@@ -197,13 +195,14 @@ namestore_postgres_store_records (void *cls, | |||
197 | 0, | 195 | 0, |
198 | sizeof(pkey)); | 196 | sizeof(pkey)); |
199 | for (unsigned int i = 0; i < rd_count; i++) | 197 | for (unsigned int i = 0; i < rd_count; i++) |
200 | if (GNUNET_GNSRECORD_TYPE_PKEY == rd[i].record_type) | 198 | if (GNUNET_YES == |
199 | GNUNET_GNSRECORD_is_zonekey_type (rd[i].record_type)) | ||
201 | { | 200 | { |
202 | GNUNET_break (sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) == | 201 | GNUNET_break (GNUNET_OK == |
203 | rd[i].data_size); | 202 | GNUNET_GNSRECORD_identity_from_data (rd[i].data, |
204 | GNUNET_memcpy (&pkey, | 203 | rd[i].data_size, |
205 | rd[i].data, | 204 | rd[i].record_type, |
206 | rd[i].data_size); | 205 | &pkey)); |
207 | break; | 206 | break; |
208 | } | 207 | } |
209 | rvalue = GNUNET_CRYPTO_random_u64 (GNUNET_CRYPTO_QUALITY_WEAK, | 208 | rvalue = GNUNET_CRYPTO_random_u64 (GNUNET_CRYPTO_QUALITY_WEAK, |
@@ -298,7 +297,7 @@ struct ParserContext | |||
298 | /** | 297 | /** |
299 | * Zone key, NULL if part of record. | 298 | * Zone key, NULL if part of record. |
300 | */ | 299 | */ |
301 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key; | 300 | const struct GNUNET_IDENTITY_PrivateKey *zone_key; |
302 | 301 | ||
303 | /** | 302 | /** |
304 | * Number of results still to return (counted down by | 303 | * Number of results still to return (counted down by |
@@ -332,7 +331,7 @@ parse_result_call_iterator (void *cls, | |||
332 | size_t data_size; | 331 | size_t data_size; |
333 | uint32_t record_count; | 332 | uint32_t record_count; |
334 | char *label; | 333 | char *label; |
335 | struct GNUNET_CRYPTO_EcdsaPrivateKey zk; | 334 | struct GNUNET_IDENTITY_PrivateKey zk; |
336 | struct GNUNET_PQ_ResultSpec rs_with_zone[] = { | 335 | struct GNUNET_PQ_ResultSpec rs_with_zone[] = { |
337 | GNUNET_PQ_result_spec_uint64 ("seq", &serial), | 336 | GNUNET_PQ_result_spec_uint64 ("seq", &serial), |
338 | GNUNET_PQ_result_spec_uint32 ("record_count", &record_count), | 337 | GNUNET_PQ_result_spec_uint32 ("record_count", &record_count), |
@@ -409,7 +408,7 @@ parse_result_call_iterator (void *cls, | |||
409 | static int | 408 | static int |
410 | namestore_postgres_lookup_records (void *cls, | 409 | namestore_postgres_lookup_records (void *cls, |
411 | const struct | 410 | const struct |
412 | GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 411 | GNUNET_IDENTITY_PrivateKey *zone, |
413 | const char *label, | 412 | const char *label, |
414 | GNUNET_NAMESTORE_RecordIterator iter, | 413 | GNUNET_NAMESTORE_RecordIterator iter, |
415 | void *iter_cls) | 414 | void *iter_cls) |
@@ -459,7 +458,7 @@ namestore_postgres_lookup_records (void *cls, | |||
459 | static int | 458 | static int |
460 | namestore_postgres_iterate_records (void *cls, | 459 | namestore_postgres_iterate_records (void *cls, |
461 | const struct | 460 | const struct |
462 | GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 461 | GNUNET_IDENTITY_PrivateKey *zone, |
463 | uint64_t serial, | 462 | uint64_t serial, |
464 | uint64_t limit, | 463 | uint64_t limit, |
465 | GNUNET_NAMESTORE_RecordIterator iter, | 464 | GNUNET_NAMESTORE_RecordIterator iter, |
@@ -526,9 +525,9 @@ namestore_postgres_iterate_records (void *cls, | |||
526 | static int | 525 | static int |
527 | namestore_postgres_zone_to_name (void *cls, | 526 | namestore_postgres_zone_to_name (void *cls, |
528 | const struct | 527 | const struct |
529 | GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 528 | GNUNET_IDENTITY_PrivateKey *zone, |
530 | const struct | 529 | const struct |
531 | GNUNET_CRYPTO_EcdsaPublicKey *value_zone, | 530 | GNUNET_IDENTITY_PublicKey *value_zone, |
532 | GNUNET_NAMESTORE_RecordIterator iter, | 531 | GNUNET_NAMESTORE_RecordIterator iter, |
533 | void *iter_cls) | 532 | void *iter_cls) |
534 | { | 533 | { |
diff --git a/src/namestore/plugin_namestore_sqlite.c b/src/namestore/plugin_namestore_sqlite.c index 45fb782f7..7cb9b7ed0 100644 --- a/src/namestore/plugin_namestore_sqlite.c +++ b/src/namestore/plugin_namestore_sqlite.c | |||
@@ -314,14 +314,14 @@ database_shutdown (struct Plugin *plugin) | |||
314 | static int | 314 | static int |
315 | namestore_sqlite_store_records (void *cls, | 315 | namestore_sqlite_store_records (void *cls, |
316 | const struct | 316 | const struct |
317 | GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 317 | GNUNET_IDENTITY_PrivateKey *zone_key, |
318 | const char *label, | 318 | const char *label, |
319 | unsigned int rd_count, | 319 | unsigned int rd_count, |
320 | const struct GNUNET_GNSRECORD_Data *rd) | 320 | const struct GNUNET_GNSRECORD_Data *rd) |
321 | { | 321 | { |
322 | struct Plugin *plugin = cls; | 322 | struct Plugin *plugin = cls; |
323 | int n; | 323 | int n; |
324 | struct GNUNET_CRYPTO_EcdsaPublicKey pkey; | 324 | struct GNUNET_IDENTITY_PublicKey pkey; |
325 | uint64_t rvalue; | 325 | uint64_t rvalue; |
326 | ssize_t data_size; | 326 | ssize_t data_size; |
327 | 327 | ||
@@ -329,13 +329,13 @@ namestore_sqlite_store_records (void *cls, | |||
329 | 0, | 329 | 0, |
330 | sizeof(pkey)); | 330 | sizeof(pkey)); |
331 | for (unsigned int i = 0; i < rd_count; i++) | 331 | for (unsigned int i = 0; i < rd_count; i++) |
332 | if (GNUNET_GNSRECORD_TYPE_PKEY == rd[i].record_type) | 332 | if (GNUNET_YES == GNUNET_GNSRECORD_is_zonekey_type (rd[i].record_type)) |
333 | { | 333 | { |
334 | GNUNET_break (sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) == | 334 | GNUNET_break (GNUNET_YES == |
335 | rd[i].data_size); | 335 | GNUNET_GNSRECORD_identity_from_data (rd[i].data, |
336 | GNUNET_memcpy (&pkey, | 336 | rd[i].data_size, |
337 | rd[i].data, | 337 | rd[i].record_type, |
338 | rd[i].data_size); | 338 | &pkey)); |
339 | break; | 339 | break; |
340 | } | 340 | } |
341 | rvalue = GNUNET_CRYPTO_random_u64 (GNUNET_CRYPTO_QUALITY_WEAK, | 341 | rvalue = GNUNET_CRYPTO_random_u64 (GNUNET_CRYPTO_QUALITY_WEAK, |
@@ -461,7 +461,7 @@ static int | |||
461 | get_records_and_call_iterator (struct Plugin *plugin, | 461 | get_records_and_call_iterator (struct Plugin *plugin, |
462 | sqlite3_stmt *stmt, | 462 | sqlite3_stmt *stmt, |
463 | const struct | 463 | const struct |
464 | GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 464 | GNUNET_IDENTITY_PrivateKey *zone_key, |
465 | uint64_t limit, | 465 | uint64_t limit, |
466 | GNUNET_NAMESTORE_RecordIterator iter, | 466 | GNUNET_NAMESTORE_RecordIterator iter, |
467 | void *iter_cls) | 467 | void *iter_cls) |
@@ -496,7 +496,7 @@ get_records_and_call_iterator (struct Plugin *plugin, | |||
496 | size_t data_size; | 496 | size_t data_size; |
497 | void *data; | 497 | void *data; |
498 | char *label; | 498 | char *label; |
499 | struct GNUNET_CRYPTO_EcdsaPrivateKey zk; | 499 | struct GNUNET_IDENTITY_PrivateKey zk; |
500 | struct GNUNET_SQ_ResultSpec rs[] = { | 500 | struct GNUNET_SQ_ResultSpec rs[] = { |
501 | GNUNET_SQ_result_spec_uint64 (&seq), | 501 | GNUNET_SQ_result_spec_uint64 (&seq), |
502 | GNUNET_SQ_result_spec_uint32 (&record_count), | 502 | GNUNET_SQ_result_spec_uint32 (&record_count), |
@@ -578,7 +578,7 @@ get_records_and_call_iterator (struct Plugin *plugin, | |||
578 | static int | 578 | static int |
579 | namestore_sqlite_lookup_records (void *cls, | 579 | namestore_sqlite_lookup_records (void *cls, |
580 | const struct | 580 | const struct |
581 | GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 581 | GNUNET_IDENTITY_PrivateKey *zone, |
582 | const char *label, | 582 | const char *label, |
583 | GNUNET_NAMESTORE_RecordIterator iter, | 583 | GNUNET_NAMESTORE_RecordIterator iter, |
584 | void *iter_cls) | 584 | void *iter_cls) |
@@ -629,7 +629,7 @@ namestore_sqlite_lookup_records (void *cls, | |||
629 | static int | 629 | static int |
630 | namestore_sqlite_iterate_records (void *cls, | 630 | namestore_sqlite_iterate_records (void *cls, |
631 | const struct | 631 | const struct |
632 | GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 632 | GNUNET_IDENTITY_PrivateKey *zone, |
633 | uint64_t serial, | 633 | uint64_t serial, |
634 | uint64_t limit, | 634 | uint64_t limit, |
635 | GNUNET_NAMESTORE_RecordIterator iter, | 635 | GNUNET_NAMESTORE_RecordIterator iter, |
@@ -695,9 +695,9 @@ namestore_sqlite_iterate_records (void *cls, | |||
695 | */ | 695 | */ |
696 | static int | 696 | static int |
697 | namestore_sqlite_zone_to_name (void *cls, | 697 | namestore_sqlite_zone_to_name (void *cls, |
698 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 698 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
699 | const struct | 699 | const struct |
700 | GNUNET_CRYPTO_EcdsaPublicKey *value_zone, | 700 | GNUNET_IDENTITY_PublicKey *value_zone, |
701 | GNUNET_NAMESTORE_RecordIterator iter, | 701 | GNUNET_NAMESTORE_RecordIterator iter, |
702 | void *iter_cls) | 702 | void *iter_cls) |
703 | { | 703 | { |
diff --git a/src/namestore/plugin_rest_namestore.c b/src/namestore/plugin_rest_namestore.c index 9354b9896..edcbeb874 100644 --- a/src/namestore/plugin_rest_namestore.c +++ b/src/namestore/plugin_rest_namestore.c | |||
@@ -30,7 +30,7 @@ | |||
30 | #include "gnunet_namestore_service.h" | 30 | #include "gnunet_namestore_service.h" |
31 | #include "gnunet_identity_service.h" | 31 | #include "gnunet_identity_service.h" |
32 | #include "gnunet_rest_lib.h" | 32 | #include "gnunet_rest_lib.h" |
33 | #include "gnunet_json_lib.h" | 33 | #include "gnunet_gnsrecord_json_lib.h" |
34 | #include "microhttpd.h" | 34 | #include "microhttpd.h" |
35 | #include <jansson.h> | 35 | #include <jansson.h> |
36 | 36 | ||
@@ -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_CRYPTO_EcdsaPrivateKey *zone_pkey; | 217 | const struct GNUNET_IDENTITY_PrivateKey *zone_pkey; |
218 | 218 | ||
219 | /** | 219 | /** |
220 | * IDENTITY Operation | 220 | * IDENTITY Operation |
@@ -510,7 +510,7 @@ namestore_list_finished (void *cls) | |||
510 | */ | 510 | */ |
511 | static void | 511 | static void |
512 | namestore_list_iteration (void *cls, | 512 | namestore_list_iteration (void *cls, |
513 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 513 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, |
514 | const char *rname, | 514 | const char *rname, |
515 | unsigned int rd_len, | 515 | unsigned int rd_len, |
516 | const struct GNUNET_GNSRECORD_Data *rd) | 516 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -535,9 +535,9 @@ namestore_list_iteration (void *cls, | |||
535 | /** Only add if not empty **/ | 535 | /** Only add if not empty **/ |
536 | if (j > 0) | 536 | if (j > 0) |
537 | { | 537 | { |
538 | record_obj = GNUNET_JSON_from_gnsrecord (rname, | 538 | record_obj = GNUNET_GNSRECORD_JSON_from_gnsrecord (rname, |
539 | rd_filtered, | 539 | rd_filtered, |
540 | j); | 540 | j); |
541 | json_array_append_new (handle->resp_object, record_obj); | 541 | json_array_append_new (handle->resp_object, record_obj); |
542 | } | 542 | } |
543 | GNUNET_NAMESTORE_zone_iterator_next (handle->list_it, 1); | 543 | GNUNET_NAMESTORE_zone_iterator_next (handle->list_it, 1); |
@@ -561,7 +561,7 @@ ns_lookup_error_cb (void *cls) | |||
561 | 561 | ||
562 | static void | 562 | static void |
563 | ns_get_lookup_cb (void *cls, | 563 | ns_get_lookup_cb (void *cls, |
564 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 564 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
565 | const char *label, | 565 | const char *label, |
566 | unsigned int rd_len, | 566 | unsigned int rd_len, |
567 | const struct GNUNET_GNSRECORD_Data *rd) | 567 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -587,9 +587,9 @@ ns_get_lookup_cb (void *cls, | |||
587 | /** Only add if not empty **/ | 587 | /** Only add if not empty **/ |
588 | if (j > 0) | 588 | if (j > 0) |
589 | { | 589 | { |
590 | record_obj = GNUNET_JSON_from_gnsrecord (label, | 590 | record_obj = GNUNET_GNSRECORD_JSON_from_gnsrecord (label, |
591 | rd_filtered, | 591 | rd_filtered, |
592 | j); | 592 | j); |
593 | json_array_append_new (handle->resp_object, record_obj); | 593 | json_array_append_new (handle->resp_object, record_obj); |
594 | } | 594 | } |
595 | GNUNET_SCHEDULER_add_now (&namestore_list_finished, handle); | 595 | GNUNET_SCHEDULER_add_now (&namestore_list_finished, handle); |
@@ -689,7 +689,7 @@ namestore_get (struct GNUNET_REST_RequestHandle *con_handle, | |||
689 | 689 | ||
690 | static void | 690 | static void |
691 | ns_lookup_cb (void *cls, | 691 | ns_lookup_cb (void *cls, |
692 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 692 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
693 | const char *label, | 693 | const char *label, |
694 | unsigned int rd_count, | 694 | unsigned int rd_count, |
695 | const struct GNUNET_GNSRECORD_Data *rd) | 695 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -755,7 +755,7 @@ namestore_add_or_update (struct GNUNET_REST_RequestHandle *con_handle, | |||
755 | handle->rest_handle->data_size); | 755 | handle->rest_handle->data_size); |
756 | data_js = json_loads (term_data, JSON_DECODE_ANY, &err); | 756 | data_js = json_loads (term_data, JSON_DECODE_ANY, &err); |
757 | struct GNUNET_JSON_Specification gnsspec[] = | 757 | struct GNUNET_JSON_Specification gnsspec[] = |
758 | { GNUNET_JSON_spec_gnsrecord (&handle->rd, &handle->rd_count, | 758 | { GNUNET_GNSRECORD_JSON_spec_gnsrecord (&handle->rd, &handle->rd_count, |
759 | &handle->record_name), | 759 | &handle->record_name), |
760 | GNUNET_JSON_spec_end () }; | 760 | GNUNET_JSON_spec_end () }; |
761 | if (GNUNET_OK != GNUNET_JSON_parse (data_js, gnsspec, NULL, NULL)) | 761 | if (GNUNET_OK != GNUNET_JSON_parse (data_js, gnsspec, NULL, NULL)) |
@@ -946,7 +946,7 @@ list_ego (void *cls, | |||
946 | const char *identifier) | 946 | const char *identifier) |
947 | { | 947 | { |
948 | struct EgoEntry *ego_entry; | 948 | struct EgoEntry *ego_entry; |
949 | struct GNUNET_CRYPTO_EcdsaPublicKey pk; | 949 | struct GNUNET_IDENTITY_PublicKey pk; |
950 | 950 | ||
951 | if ((NULL == ego) && (ID_REST_STATE_INIT == state)) | 951 | if ((NULL == ego) && (ID_REST_STATE_INIT == state)) |
952 | { | 952 | { |
@@ -957,7 +957,7 @@ list_ego (void *cls, | |||
957 | { | 957 | { |
958 | ego_entry = GNUNET_new (struct EgoEntry); | 958 | ego_entry = GNUNET_new (struct EgoEntry); |
959 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 959 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
960 | ego_entry->keystring = GNUNET_CRYPTO_ecdsa_public_key_to_string (&pk); | 960 | ego_entry->keystring = GNUNET_IDENTITY_public_key_to_string (&pk); |
961 | ego_entry->ego = ego; | 961 | ego_entry->ego = ego; |
962 | ego_entry->identifier = GNUNET_strdup (identifier); | 962 | ego_entry->identifier = GNUNET_strdup (identifier); |
963 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, | 963 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, |
@@ -983,7 +983,7 @@ list_ego (void *cls, | |||
983 | /* Add */ | 983 | /* Add */ |
984 | ego_entry = GNUNET_new (struct EgoEntry); | 984 | ego_entry = GNUNET_new (struct EgoEntry); |
985 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 985 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
986 | ego_entry->keystring = GNUNET_CRYPTO_ecdsa_public_key_to_string (&pk); | 986 | ego_entry->keystring = GNUNET_IDENTITY_public_key_to_string (&pk); |
987 | ego_entry->ego = ego; | 987 | ego_entry->ego = ego; |
988 | ego_entry->identifier = GNUNET_strdup (identifier); | 988 | ego_entry->identifier = GNUNET_strdup (identifier); |
989 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, | 989 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, |
diff --git a/src/namestore/test_namestore_api_lookup_nick.c b/src/namestore/test_namestore_api_lookup_nick.c index 14fe7fc70..6ce969c9b 100644 --- a/src/namestore/test_namestore_api_lookup_nick.c +++ b/src/namestore/test_namestore_api_lookup_nick.c | |||
@@ -41,9 +41,9 @@ 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_CRYPTO_EcdsaPrivateKey privkey; | 44 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
45 | 45 | ||
46 | static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 46 | static struct GNUNET_IDENTITY_PublicKey pubkey; |
47 | 47 | ||
48 | static int res; | 48 | static int res; |
49 | 49 | ||
@@ -98,7 +98,7 @@ end (void *cls) | |||
98 | 98 | ||
99 | static void | 99 | static void |
100 | lookup_it (void *cls, | 100 | lookup_it (void *cls, |
101 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 101 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
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) |
@@ -288,8 +288,9 @@ run (void *cls, | |||
288 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, | 288 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, |
289 | &endbadly, | 289 | &endbadly, |
290 | NULL); | 290 | NULL); |
291 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 291 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
292 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, | 292 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
293 | GNUNET_IDENTITY_key_get_public (&privkey, | ||
293 | &pubkey); | 294 | &pubkey); |
294 | 295 | ||
295 | nsh = GNUNET_NAMESTORE_connect (cfg); | 296 | nsh = GNUNET_NAMESTORE_connect (cfg); |
diff --git a/src/namestore/test_namestore_api_lookup_private.c b/src/namestore/test_namestore_api_lookup_private.c index d0ad726cc..67cf54582 100644 --- a/src/namestore/test_namestore_api_lookup_private.c +++ b/src/namestore/test_namestore_api_lookup_private.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_CRYPTO_EcdsaPrivateKey privkey; | 41 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
42 | 42 | ||
43 | static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 43 | static struct GNUNET_IDENTITY_PublicKey pubkey; |
44 | 44 | ||
45 | static int res; | 45 | static int res; |
46 | 46 | ||
@@ -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_CRYPTO_EcdsaPrivateKey *zone, | 94 | const struct GNUNET_IDENTITY_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) |
@@ -187,8 +187,9 @@ run (void *cls, | |||
187 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, | 187 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, |
188 | &endbadly, | 188 | &endbadly, |
189 | NULL); | 189 | NULL); |
190 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 190 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
191 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, &pubkey); | 191 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
192 | GNUNET_IDENTITY_key_get_public (&privkey, &pubkey); | ||
192 | 193 | ||
193 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us; | 194 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us; |
194 | rd.record_type = TEST_RECORD_TYPE; | 195 | rd.record_type = TEST_RECORD_TYPE; |
diff --git a/src/namestore/test_namestore_api_lookup_public.c b/src/namestore/test_namestore_api_lookup_public.c index 039c7cbf6..5e3e7bbd8 100644 --- a/src/namestore/test_namestore_api_lookup_public.c +++ b/src/namestore/test_namestore_api_lookup_public.c | |||
@@ -42,9 +42,9 @@ static struct GNUNET_NAMECACHE_Handle *nch; | |||
42 | 42 | ||
43 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 43 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
44 | 44 | ||
45 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey; | 45 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
46 | 46 | ||
47 | static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 47 | static struct GNUNET_IDENTITY_PublicKey pubkey; |
48 | 48 | ||
49 | static int res; | 49 | static int res; |
50 | 50 | ||
@@ -163,7 +163,7 @@ put_cont (void *cls, int32_t success, const char *emsg) | |||
163 | { | 163 | { |
164 | const char *name = cls; | 164 | const char *name = cls; |
165 | struct GNUNET_HashCode derived_hash; | 165 | struct GNUNET_HashCode derived_hash; |
166 | struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 166 | struct GNUNET_IDENTITY_PublicKey pubkey; |
167 | 167 | ||
168 | nsqe = NULL; | 168 | nsqe = NULL; |
169 | GNUNET_assert (NULL != cls); | 169 | GNUNET_assert (NULL != cls); |
@@ -173,8 +173,8 @@ put_cont (void *cls, int32_t success, const char *emsg) | |||
173 | (success == GNUNET_OK) ? "SUCCESS" : "FAIL"); | 173 | (success == GNUNET_OK) ? "SUCCESS" : "FAIL"); |
174 | 174 | ||
175 | /* Create derived hash */ | 175 | /* Create derived hash */ |
176 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, | 176 | GNUNET_IDENTITY_key_get_public (&privkey, |
177 | &pubkey); | 177 | &pubkey); |
178 | GNUNET_GNSRECORD_query_from_public_key (&pubkey, name, &derived_hash); | 178 | GNUNET_GNSRECORD_query_from_public_key (&pubkey, name, &derived_hash); |
179 | 179 | ||
180 | ncqe = GNUNET_NAMECACHE_lookup_block (nch, &derived_hash, | 180 | ncqe = GNUNET_NAMECACHE_lookup_block (nch, &derived_hash, |
@@ -193,9 +193,10 @@ run (void *cls, | |||
193 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, | 193 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, |
194 | &endbadly, | 194 | &endbadly, |
195 | NULL); | 195 | NULL); |
196 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 196 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
197 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, | 197 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
198 | &pubkey); | 198 | GNUNET_IDENTITY_key_get_public (&privkey, |
199 | &pubkey); | ||
199 | 200 | ||
200 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us + 1000000000; | 201 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us + 1000000000; |
201 | rd.record_type = TEST_RECORD_TYPE; | 202 | rd.record_type = TEST_RECORD_TYPE; |
diff --git a/src/namestore/test_namestore_api_lookup_shadow.c b/src/namestore/test_namestore_api_lookup_shadow.c index d399d903a..79fa4c9c6 100644 --- a/src/namestore/test_namestore_api_lookup_shadow.c +++ b/src/namestore/test_namestore_api_lookup_shadow.c | |||
@@ -44,9 +44,9 @@ static struct GNUNET_NAMECACHE_Handle *nch; | |||
44 | 44 | ||
45 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 45 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
46 | 46 | ||
47 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey; | 47 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
48 | 48 | ||
49 | static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 49 | static struct GNUNET_IDENTITY_PublicKey pubkey; |
50 | 50 | ||
51 | static int res; | 51 | static int res; |
52 | 52 | ||
@@ -195,7 +195,7 @@ put_cont (void *cls, int32_t success, const char *emsg) | |||
195 | { | 195 | { |
196 | const char *name = cls; | 196 | const char *name = cls; |
197 | struct GNUNET_HashCode derived_hash; | 197 | struct GNUNET_HashCode derived_hash; |
198 | struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 198 | struct GNUNET_IDENTITY_PublicKey pubkey; |
199 | 199 | ||
200 | nsqe = NULL; | 200 | nsqe = NULL; |
201 | GNUNET_assert (NULL != cls); | 201 | GNUNET_assert (NULL != cls); |
@@ -205,8 +205,8 @@ put_cont (void *cls, int32_t success, const char *emsg) | |||
205 | (success == GNUNET_OK) ? "SUCCESS" : "FAIL"); | 205 | (success == GNUNET_OK) ? "SUCCESS" : "FAIL"); |
206 | 206 | ||
207 | /* Create derived hash */ | 207 | /* Create derived hash */ |
208 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, | 208 | GNUNET_IDENTITY_key_get_public (&privkey, |
209 | &pubkey); | 209 | &pubkey); |
210 | GNUNET_GNSRECORD_query_from_public_key (&pubkey, | 210 | GNUNET_GNSRECORD_query_from_public_key (&pubkey, |
211 | name, | 211 | name, |
212 | &derived_hash); | 212 | &derived_hash); |
@@ -228,9 +228,10 @@ run (void *cls, | |||
228 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, | 228 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, |
229 | &endbadly, | 229 | &endbadly, |
230 | NULL); | 230 | NULL); |
231 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 231 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
232 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, | 232 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
233 | &pubkey); | 233 | GNUNET_IDENTITY_key_get_public (&privkey, |
234 | &pubkey); | ||
234 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us + 1000000000; | 235 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us + 1000000000; |
235 | rd.record_type = TEST_RECORD_TYPE; | 236 | rd.record_type = TEST_RECORD_TYPE; |
236 | rd.data_size = TEST_RECORD_DATALEN; | 237 | rd.data_size = TEST_RECORD_DATALEN; |
diff --git a/src/namestore/test_namestore_api_lookup_shadow_filter.c b/src/namestore/test_namestore_api_lookup_shadow_filter.c index 40dbeb90f..4fc197750 100644 --- a/src/namestore/test_namestore_api_lookup_shadow_filter.c +++ b/src/namestore/test_namestore_api_lookup_shadow_filter.c | |||
@@ -48,9 +48,9 @@ static struct GNUNET_SCHEDULER_Task *endbadly_task; | |||
48 | 48 | ||
49 | static struct GNUNET_SCHEDULER_Task *delayed_lookup_task; | 49 | static struct GNUNET_SCHEDULER_Task *delayed_lookup_task; |
50 | 50 | ||
51 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey; | 51 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
52 | 52 | ||
53 | static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 53 | static struct GNUNET_IDENTITY_PublicKey pubkey; |
54 | 54 | ||
55 | static int res; | 55 | static int res; |
56 | 56 | ||
@@ -66,7 +66,7 @@ static struct GNUNET_TIME_Absolute record_expiration; | |||
66 | 66 | ||
67 | static struct GNUNET_HashCode derived_hash; | 67 | static struct GNUNET_HashCode derived_hash; |
68 | 68 | ||
69 | static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 69 | static struct GNUNET_IDENTITY_PublicKey pubkey; |
70 | 70 | ||
71 | 71 | ||
72 | static void | 72 | static void |
@@ -267,8 +267,8 @@ put_cont (void *cls, int32_t success, const char *emsg) | |||
267 | (success == GNUNET_OK) ? "SUCCESS" : "FAIL"); | 267 | (success == GNUNET_OK) ? "SUCCESS" : "FAIL"); |
268 | 268 | ||
269 | /* Create derived hash */ | 269 | /* Create derived hash */ |
270 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, | 270 | GNUNET_IDENTITY_key_get_public (&privkey, |
271 | &pubkey); | 271 | &pubkey); |
272 | GNUNET_GNSRECORD_query_from_public_key (&pubkey, TEST_NAME, &derived_hash); | 272 | GNUNET_GNSRECORD_query_from_public_key (&pubkey, TEST_NAME, &derived_hash); |
273 | 273 | ||
274 | if (0 == GNUNET_TIME_absolute_get_remaining (record_expiration).rel_value_us) | 274 | if (0 == GNUNET_TIME_absolute_get_remaining (record_expiration).rel_value_us) |
@@ -297,9 +297,10 @@ run (void *cls, | |||
297 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, | 297 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, |
298 | &endbadly, | 298 | &endbadly, |
299 | NULL); | 299 | NULL); |
300 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 300 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
301 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, | 301 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
302 | &pubkey); | 302 | GNUNET_IDENTITY_key_get_public (&privkey, |
303 | &pubkey); | ||
303 | 304 | ||
304 | record_expiration = GNUNET_TIME_absolute_add (GNUNET_TIME_absolute_get (), | 305 | record_expiration = GNUNET_TIME_absolute_add (GNUNET_TIME_absolute_get (), |
305 | EXPIRATION); | 306 | EXPIRATION); |
diff --git a/src/namestore/test_namestore_api_monitoring.c b/src/namestore/test_namestore_api_monitoring.c index 3f1be1403..df0c38608 100644 --- a/src/namestore/test_namestore_api_monitoring.c +++ b/src/namestore/test_namestore_api_monitoring.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_CRYPTO_EcdsaPrivateKey privkey; | 40 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
41 | 41 | ||
42 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey2; | 42 | static struct GNUNET_IDENTITY_PrivateKey privkey2; |
43 | 43 | ||
44 | static struct GNUNET_NAMESTORE_ZoneMonitor *zm; | 44 | static struct GNUNET_NAMESTORE_ZoneMonitor *zm; |
45 | 45 | ||
@@ -133,7 +133,7 @@ end (void *cls) | |||
133 | 133 | ||
134 | static void | 134 | static void |
135 | zone_proc (void *cls, | 135 | zone_proc (void *cls, |
136 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 136 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, |
137 | const char *name, | 137 | const char *name, |
138 | unsigned int rd_count, | 138 | unsigned int rd_count, |
139 | const struct GNUNET_GNSRECORD_Data *rd) | 139 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -273,7 +273,8 @@ run (void *cls, | |||
273 | struct GNUNET_TESTING_Peer *peer) | 273 | struct GNUNET_TESTING_Peer *peer) |
274 | { | 274 | { |
275 | res = 1; | 275 | res = 1; |
276 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 276 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
277 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | ||
277 | /* Start monitoring */ | 278 | /* Start monitoring */ |
278 | zm = GNUNET_NAMESTORE_zone_monitor_start (cfg, | 279 | zm = GNUNET_NAMESTORE_zone_monitor_start (cfg, |
279 | &privkey, | 280 | &privkey, |
@@ -304,7 +305,8 @@ run (void *cls, | |||
304 | return; | 305 | return; |
305 | } | 306 | } |
306 | 307 | ||
307 | GNUNET_CRYPTO_ecdsa_key_create (&privkey2); | 308 | privkey2.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
309 | GNUNET_CRYPTO_ecdsa_key_create (&privkey2.ecdsa_key); | ||
308 | 310 | ||
309 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 311 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
310 | "Created record 3\n"); | 312 | "Created record 3\n"); |
diff --git a/src/namestore/test_namestore_api_monitoring_existing.c b/src/namestore/test_namestore_api_monitoring_existing.c index 728fcc25e..366f5739f 100644 --- a/src/namestore/test_namestore_api_monitoring_existing.c +++ b/src/namestore/test_namestore_api_monitoring_existing.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_CRYPTO_EcdsaPrivateKey privkey; | 41 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
42 | 42 | ||
43 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey2; | 43 | static struct GNUNET_IDENTITY_PrivateKey privkey2; |
44 | 44 | ||
45 | static struct GNUNET_NAMESTORE_ZoneMonitor *zm; | 45 | static struct GNUNET_NAMESTORE_ZoneMonitor *zm; |
46 | 46 | ||
@@ -129,7 +129,7 @@ end (void *cls) | |||
129 | 129 | ||
130 | static void | 130 | static void |
131 | zone_proc (void *cls, | 131 | zone_proc (void *cls, |
132 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 132 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, |
133 | const char *name, | 133 | const char *name, |
134 | unsigned int rd_count, | 134 | unsigned int rd_count, |
135 | const struct GNUNET_GNSRECORD_Data *rd) | 135 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -302,8 +302,10 @@ run (void *cls, | |||
302 | struct GNUNET_TESTING_Peer *peer) | 302 | struct GNUNET_TESTING_Peer *peer) |
303 | { | 303 | { |
304 | res = 1; | 304 | res = 1; |
305 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 305 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
306 | GNUNET_CRYPTO_ecdsa_key_create (&privkey2); | 306 | privkey2.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
307 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | ||
308 | GNUNET_CRYPTO_ecdsa_key_create (&privkey2.ecdsa_key); | ||
307 | 309 | ||
308 | cfg = mycfg; | 310 | cfg = mycfg; |
309 | GNUNET_SCHEDULER_add_shutdown (&end, | 311 | GNUNET_SCHEDULER_add_shutdown (&end, |
diff --git a/src/namestore/test_namestore_api_remove.c b/src/namestore/test_namestore_api_remove.c index e575821e8..b6254e531 100644 --- a/src/namestore/test_namestore_api_remove.c +++ b/src/namestore/test_namestore_api_remove.c | |||
@@ -39,9 +39,9 @@ static struct GNUNET_NAMESTORE_Handle *nsh; | |||
39 | 39 | ||
40 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 40 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
41 | 41 | ||
42 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey; | 42 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
43 | 43 | ||
44 | static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 44 | static struct GNUNET_IDENTITY_PublicKey pubkey; |
45 | 45 | ||
46 | static int res; | 46 | static int res; |
47 | 47 | ||
@@ -158,9 +158,10 @@ run (void *cls, | |||
158 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, | 158 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, |
159 | &endbadly, | 159 | &endbadly, |
160 | NULL); | 160 | NULL); |
161 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 161 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
162 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, | 162 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
163 | &pubkey); | 163 | GNUNET_IDENTITY_key_get_public (&privkey, |
164 | &pubkey); | ||
164 | 165 | ||
165 | removed = GNUNET_NO; | 166 | removed = GNUNET_NO; |
166 | 167 | ||
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 75e1cc3ed..e66992909 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_CRYPTO_EcdsaPrivateKey privkey; | 41 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
42 | 42 | ||
43 | static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 43 | static struct GNUNET_IDENTITY_PublicKey pubkey; |
44 | 44 | ||
45 | static int res; | 45 | static int res; |
46 | 46 | ||
@@ -132,8 +132,9 @@ run (void *cls, | |||
132 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, | 132 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, |
133 | &endbadly, | 133 | &endbadly, |
134 | NULL); | 134 | NULL); |
135 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 135 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
136 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, &pubkey); | 136 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
137 | GNUNET_IDENTITY_key_get_public (&privkey, &pubkey); | ||
137 | 138 | ||
138 | nsh = GNUNET_NAMESTORE_connect (cfg); | 139 | nsh = GNUNET_NAMESTORE_connect (cfg); |
139 | GNUNET_break (NULL != nsh); | 140 | GNUNET_break (NULL != nsh); |
diff --git a/src/namestore/test_namestore_api_store.c b/src/namestore/test_namestore_api_store.c index 9223b56a3..e0b7daa5d 100644 --- a/src/namestore/test_namestore_api_store.c +++ b/src/namestore/test_namestore_api_store.c | |||
@@ -39,9 +39,9 @@ static struct GNUNET_NAMESTORE_Handle *nsh; | |||
39 | 39 | ||
40 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 40 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
41 | 41 | ||
42 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey; | 42 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
43 | 43 | ||
44 | static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 44 | static struct GNUNET_IDENTITY_PublicKey pubkey; |
45 | 45 | ||
46 | static int res; | 46 | static int res; |
47 | 47 | ||
@@ -113,8 +113,9 @@ run (void *cls, | |||
113 | 113 | ||
114 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, | 114 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, |
115 | &endbadly, NULL); | 115 | &endbadly, NULL); |
116 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 116 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
117 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, &pubkey); | 117 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
118 | GNUNET_IDENTITY_key_get_public (&privkey, &pubkey); | ||
118 | 119 | ||
119 | 120 | ||
120 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us; | 121 | 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 7a5a69a6c..5c169734a 100644 --- a/src/namestore/test_namestore_api_store_update.c +++ b/src/namestore/test_namestore_api_store_update.c | |||
@@ -48,9 +48,9 @@ static struct GNUNET_NAMECACHE_Handle *nch; | |||
48 | 48 | ||
49 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 49 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
50 | 50 | ||
51 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey; | 51 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
52 | 52 | ||
53 | static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 53 | static struct GNUNET_IDENTITY_PublicKey pubkey; |
54 | 54 | ||
55 | static int res; | 55 | static int res; |
56 | 56 | ||
@@ -246,9 +246,10 @@ run (void *cls, | |||
246 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, | 246 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, |
247 | &endbadly, | 247 | &endbadly, |
248 | NULL); | 248 | NULL); |
249 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 249 | memset (&privkey, 0, sizeof (privkey)); |
250 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, | 250 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
251 | &pubkey); | 251 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
252 | GNUNET_IDENTITY_key_get_public (&privkey, &pubkey); | ||
252 | rd.flags = GNUNET_GNSRECORD_RF_NONE; | 253 | rd.flags = GNUNET_GNSRECORD_RF_NONE; |
253 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us + 1000000000; | 254 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us + 1000000000; |
254 | rd.record_type = TEST_RECORD_TYPE; | 255 | rd.record_type = TEST_RECORD_TYPE; |
@@ -291,7 +292,7 @@ main (int argc, | |||
291 | SETUP_CFG (plugin_name, cfg_name); | 292 | SETUP_CFG (plugin_name, cfg_name); |
292 | res = 1; | 293 | res = 1; |
293 | if (0 != | 294 | if (0 != |
294 | GNUNET_TESTING_peer_run ("test-namestore-api-store-update", | 295 | GNUNET_TESTING_peer_run ("test--store-update", |
295 | cfg_name, | 296 | cfg_name, |
296 | &run, | 297 | &run, |
297 | NULL)) | 298 | NULL)) |
diff --git a/src/namestore/test_namestore_api_zone_iteration.c b/src/namestore/test_namestore_api_zone_iteration.c index 5d02b9e49..55ca901e2 100644 --- a/src/namestore/test_namestore_api_zone_iteration.c +++ b/src/namestore/test_namestore_api_zone_iteration.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_CRYPTO_EcdsaPrivateKey privkey; | 40 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
41 | 41 | ||
42 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey2; | 42 | static struct GNUNET_IDENTITY_PrivateKey privkey2; |
43 | 43 | ||
44 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; | 44 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; |
45 | 45 | ||
@@ -142,7 +142,7 @@ fail_cb (void *cls) | |||
142 | 142 | ||
143 | static void | 143 | static void |
144 | zone_proc (void *cls, | 144 | zone_proc (void *cls, |
145 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 145 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
146 | const char *label, | 146 | const char *label, |
147 | unsigned int rd_count, | 147 | unsigned int rd_count, |
148 | const struct GNUNET_GNSRECORD_Data *rd) | 148 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -331,7 +331,7 @@ create_record (unsigned int count) | |||
331 | */ | 331 | */ |
332 | static void | 332 | static void |
333 | empty_zone_proc (void *cls, | 333 | empty_zone_proc (void *cls, |
334 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 334 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
335 | const char *label, | 335 | const char *label, |
336 | unsigned int rd_count, | 336 | unsigned int rd_count, |
337 | const struct GNUNET_GNSRECORD_Data *rd) | 337 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -362,34 +362,11 @@ empty_zone_proc (void *cls, | |||
362 | static void | 362 | static void |
363 | empty_zone_end (void *cls) | 363 | empty_zone_end (void *cls) |
364 | { | 364 | { |
365 | char *hostkey_file; | ||
366 | |||
367 | zi = NULL; | 365 | zi = NULL; |
368 | GNUNET_asprintf (&hostkey_file, | 366 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
369 | "zonefiles%s%s", | 367 | privkey2.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
370 | DIR_SEPARATOR_STR, | 368 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
371 | "N0UJMP015AFUNR2BTNM3FKPBLG38913BL8IDMCO2H0A1LIB81960.zkey"); | 369 | GNUNET_CRYPTO_ecdsa_key_create (&privkey2.ecdsa_key); |
372 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
373 | "Using zonekey file `%s' \n", | ||
374 | hostkey_file); | ||
375 | GNUNET_assert (GNUNET_SYSERR != | ||
376 | GNUNET_CRYPTO_ecdsa_key_from_file (hostkey_file, | ||
377 | GNUNET_YES, | ||
378 | &privkey)); | ||
379 | GNUNET_free (hostkey_file); | ||
380 | |||
381 | GNUNET_asprintf (&hostkey_file, | ||
382 | "zonefiles%s%s", | ||
383 | DIR_SEPARATOR_STR, | ||
384 | "HGU0A0VCU334DN7F2I9UIUMVQMM7JMSD142LIMNUGTTV9R0CF4EG.zkey"); | ||
385 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
386 | "Using zonekey file `%s' \n", | ||
387 | hostkey_file); | ||
388 | GNUNET_assert (GNUNET_SYSERR != | ||
389 | GNUNET_CRYPTO_ecdsa_key_from_file (hostkey_file, | ||
390 | GNUNET_YES, | ||
391 | &privkey2)); | ||
392 | GNUNET_free (hostkey_file); | ||
393 | 370 | ||
394 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Created record 1\n"); | 371 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Created record 1\n"); |
395 | 372 | ||
diff --git a/src/namestore/test_namestore_api_zone_iteration_nick.c b/src/namestore/test_namestore_api_zone_iteration_nick.c index 4e54a05d2..c203a63a6 100644 --- a/src/namestore/test_namestore_api_zone_iteration_nick.c +++ b/src/namestore/test_namestore_api_zone_iteration_nick.c | |||
@@ -38,9 +38,9 @@ | |||
38 | 38 | ||
39 | static struct GNUNET_NAMESTORE_Handle *nsh; | 39 | static struct GNUNET_NAMESTORE_Handle *nsh; |
40 | 40 | ||
41 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey; | 41 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
42 | 42 | ||
43 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey2; | 43 | static struct GNUNET_IDENTITY_PrivateKey privkey2; |
44 | 44 | ||
45 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; | 45 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; |
46 | 46 | ||
@@ -153,7 +153,7 @@ zone_proc_end (void *cls) | |||
153 | 153 | ||
154 | static void | 154 | static void |
155 | zone_proc (void *cls, | 155 | zone_proc (void *cls, |
156 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 156 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
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) |
@@ -345,7 +345,7 @@ nick_1_cont (void *cls, int32_t success, const char *emsg) | |||
345 | */ | 345 | */ |
346 | static void | 346 | static void |
347 | empty_zone_proc (void *cls, | 347 | empty_zone_proc (void *cls, |
348 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 348 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
349 | const char *label, | 349 | const char *label, |
350 | unsigned int rd_count, | 350 | unsigned int rd_count, |
351 | const struct GNUNET_GNSRECORD_Data *rd) | 351 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -379,8 +379,10 @@ empty_zone_end (void *cls) | |||
379 | struct GNUNET_GNSRECORD_Data rd; | 379 | struct GNUNET_GNSRECORD_Data rd; |
380 | 380 | ||
381 | zi = NULL; | 381 | zi = NULL; |
382 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 382 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
383 | GNUNET_CRYPTO_ecdsa_key_create (&privkey2); | 383 | privkey2.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
384 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | ||
385 | GNUNET_CRYPTO_ecdsa_key_create (&privkey2.ecdsa_key); | ||
384 | 386 | ||
385 | memset (&rd, 0, sizeof(rd)); | 387 | memset (&rd, 0, sizeof(rd)); |
386 | rd.data = ZONE_NICK_1; | 388 | rd.data = ZONE_NICK_1; |
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 30920713f..70097a69e 100644 --- a/src/namestore/test_namestore_api_zone_iteration_specific_zone.c +++ b/src/namestore/test_namestore_api_zone_iteration_specific_zone.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_CRYPTO_EcdsaPrivateKey privkey; | 41 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
42 | 42 | ||
43 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey2; | 43 | static struct GNUNET_IDENTITY_PrivateKey privkey2; |
44 | 44 | ||
45 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; | 45 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; |
46 | 46 | ||
@@ -124,7 +124,7 @@ fail_cb (void *cls) | |||
124 | 124 | ||
125 | static void | 125 | static void |
126 | zone_proc (void *cls, | 126 | zone_proc (void *cls, |
127 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 127 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
128 | const char *label, | 128 | const char *label, |
129 | unsigned int rd_count, | 129 | unsigned int rd_count, |
130 | const struct GNUNET_GNSRECORD_Data *rd) | 130 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -309,7 +309,7 @@ create_record (unsigned int count) | |||
309 | */ | 309 | */ |
310 | static void | 310 | static void |
311 | empty_zone_proc (void *cls, | 311 | empty_zone_proc (void *cls, |
312 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 312 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
313 | const char *label, | 313 | const char *label, |
314 | unsigned int rd_count, | 314 | unsigned int rd_count, |
315 | const struct GNUNET_GNSRECORD_Data *rd) | 315 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -341,8 +341,10 @@ static void | |||
341 | empty_zone_proc_end (void *cls) | 341 | empty_zone_proc_end (void *cls) |
342 | { | 342 | { |
343 | zi = NULL; | 343 | zi = NULL; |
344 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 344 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
345 | GNUNET_CRYPTO_ecdsa_key_create (&privkey2); | 345 | privkey2.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
346 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | ||
347 | GNUNET_CRYPTO_ecdsa_key_create (&privkey2.ecdsa_key); | ||
346 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 348 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
347 | "Created record 1\n"); | 349 | "Created record 1\n"); |
348 | GNUNET_asprintf (&s_name_1, | 350 | GNUNET_asprintf (&s_name_1, |
diff --git a/src/namestore/test_namestore_api_zone_iteration_stop.c b/src/namestore/test_namestore_api_zone_iteration_stop.c index bdcdd1706..71b36ba09 100644 --- a/src/namestore/test_namestore_api_zone_iteration_stop.c +++ b/src/namestore/test_namestore_api_zone_iteration_stop.c | |||
@@ -34,9 +34,9 @@ | |||
34 | 34 | ||
35 | static struct GNUNET_NAMESTORE_Handle *nsh; | 35 | static struct GNUNET_NAMESTORE_Handle *nsh; |
36 | 36 | ||
37 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey; | 37 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
38 | 38 | ||
39 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey2; | 39 | static struct GNUNET_IDENTITY_PrivateKey privkey2; |
40 | 40 | ||
41 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; | 41 | static struct GNUNET_NAMESTORE_ZoneIterator *zi; |
42 | 42 | ||
@@ -112,7 +112,7 @@ fail_cb (void *cls) | |||
112 | 112 | ||
113 | static void | 113 | static void |
114 | zone_proc (void *cls, | 114 | zone_proc (void *cls, |
115 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 115 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
116 | const char *label, | 116 | const char *label, |
117 | unsigned int rd_count, | 117 | unsigned int rd_count, |
118 | const struct GNUNET_GNSRECORD_Data *rd) | 118 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -318,7 +318,7 @@ create_record (unsigned int count) | |||
318 | */ | 318 | */ |
319 | static void | 319 | static void |
320 | empty_zone_proc (void *cls, | 320 | empty_zone_proc (void *cls, |
321 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 321 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
322 | const char *label, | 322 | const char *label, |
323 | unsigned int rd_count, | 323 | unsigned int rd_count, |
324 | const struct GNUNET_GNSRECORD_Data *rd) | 324 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -347,34 +347,13 @@ empty_zone_proc (void *cls, | |||
347 | static void | 347 | static void |
348 | empty_zone_proc_end (void *cls) | 348 | empty_zone_proc_end (void *cls) |
349 | { | 349 | { |
350 | char *hostkey_file; | ||
351 | |||
352 | GNUNET_assert (nsh == cls); | 350 | GNUNET_assert (nsh == cls); |
353 | zi = NULL; | 351 | zi = NULL; |
354 | GNUNET_asprintf (&hostkey_file, | 352 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
355 | "zonefiles%s%s", | 353 | privkey2.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
356 | DIR_SEPARATOR_STR, | 354 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); |
357 | "N0UJMP015AFUNR2BTNM3FKPBLG38913BL8IDMCO2H0A1LIB81960.zkey"); | 355 | GNUNET_CRYPTO_ecdsa_key_create (&privkey2.ecdsa_key); |
358 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 356 | |
359 | "Using zonekey file `%s' \n", | ||
360 | hostkey_file); | ||
361 | GNUNET_assert (GNUNET_SYSERR | ||
362 | != GNUNET_CRYPTO_ecdsa_key_from_file (hostkey_file, | ||
363 | GNUNET_YES, | ||
364 | &privkey)); | ||
365 | GNUNET_free (hostkey_file); | ||
366 | GNUNET_asprintf (&hostkey_file, | ||
367 | "zonefiles%s%s", | ||
368 | DIR_SEPARATOR_STR, | ||
369 | "HGU0A0VCU334DN7F2I9UIUMVQMM7JMSD142LIMNUGTTV9R0CF4EG.zkey"); | ||
370 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
371 | "Using zonekey file `%s'\n", | ||
372 | hostkey_file); | ||
373 | GNUNET_assert (GNUNET_SYSERR != | ||
374 | GNUNET_CRYPTO_ecdsa_key_from_file (hostkey_file, | ||
375 | GNUNET_YES, | ||
376 | &privkey2)); | ||
377 | GNUNET_free (hostkey_file); | ||
378 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 357 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
379 | "Created record 1\n"); | 358 | "Created record 1\n"); |
380 | 359 | ||
diff --git a/src/namestore/test_namestore_api_zone_to_name.c b/src/namestore/test_namestore_api_zone_to_name.c index 94cc5c285..3fd10e4a1 100644 --- a/src/namestore/test_namestore_api_zone_to_name.c +++ b/src/namestore/test_namestore_api_zone_to_name.c | |||
@@ -42,11 +42,11 @@ static struct GNUNET_NAMESTORE_Handle *nsh; | |||
42 | 42 | ||
43 | static struct GNUNET_SCHEDULER_Task *endbadly_task; | 43 | static struct GNUNET_SCHEDULER_Task *endbadly_task; |
44 | 44 | ||
45 | static struct GNUNET_CRYPTO_EcdsaPrivateKey privkey; | 45 | static struct GNUNET_IDENTITY_PrivateKey privkey; |
46 | 46 | ||
47 | static struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 47 | static struct GNUNET_IDENTITY_PublicKey pubkey; |
48 | 48 | ||
49 | static struct GNUNET_CRYPTO_EcdsaPublicKey s_zone_value; | 49 | static struct GNUNET_IDENTITY_PublicKey s_zone_value; |
50 | 50 | ||
51 | static char *s_name; | 51 | static char *s_name; |
52 | 52 | ||
@@ -92,7 +92,7 @@ end (void *cls) | |||
92 | 92 | ||
93 | static void | 93 | static void |
94 | zone_to_name_proc (void *cls, | 94 | zone_to_name_proc (void *cls, |
95 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key, | 95 | const struct GNUNET_IDENTITY_PrivateKey *zone_key, |
96 | const char *n, | 96 | const char *n, |
97 | unsigned int rd_count, | 97 | unsigned int rd_count, |
98 | const struct GNUNET_GNSRECORD_Data *rd) | 98 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -203,20 +203,22 @@ run (void *cls, | |||
203 | GNUNET_SCHEDULER_add_shutdown (&end, | 203 | GNUNET_SCHEDULER_add_shutdown (&end, |
204 | NULL); | 204 | NULL); |
205 | GNUNET_asprintf (&s_name, "dummy"); | 205 | GNUNET_asprintf (&s_name, "dummy"); |
206 | GNUNET_CRYPTO_ecdsa_key_create (&privkey); | 206 | privkey.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
207 | GNUNET_CRYPTO_ecdsa_key_create (&privkey.ecdsa_key); | ||
207 | /* get public key */ | 208 | /* get public key */ |
208 | GNUNET_CRYPTO_ecdsa_key_get_public (&privkey, | 209 | GNUNET_IDENTITY_key_get_public (&privkey, |
209 | &pubkey); | 210 | &pubkey); |
210 | 211 | ||
211 | GNUNET_CRYPTO_random_block (GNUNET_CRYPTO_QUALITY_WEAK, | 212 | GNUNET_CRYPTO_random_block (GNUNET_CRYPTO_QUALITY_WEAK, |
212 | &s_zone_value, | 213 | &s_zone_value, |
213 | sizeof(s_zone_value)); | 214 | sizeof(s_zone_value)); |
215 | s_zone_value.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); | ||
214 | { | 216 | { |
215 | struct GNUNET_GNSRECORD_Data rd; | 217 | struct GNUNET_GNSRECORD_Data rd; |
216 | 218 | ||
217 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us; | 219 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us; |
218 | rd.record_type = GNUNET_GNSRECORD_TYPE_PKEY; | 220 | rd.record_type = GNUNET_GNSRECORD_TYPE_PKEY; |
219 | rd.data_size = sizeof(s_zone_value); | 221 | rd.data_size = GNUNET_IDENTITY_key_get_length (&s_zone_value); |
220 | rd.data = &s_zone_value; | 222 | rd.data = &s_zone_value; |
221 | rd.flags = 0; | 223 | rd.flags = 0; |
222 | 224 | ||
diff --git a/src/namestore/test_plugin_namestore.c b/src/namestore/test_plugin_namestore.c index 0f9ce97e4..baea0e444 100644 --- a/src/namestore/test_plugin_namestore.c +++ b/src/namestore/test_plugin_namestore.c | |||
@@ -85,14 +85,14 @@ load_plugin (const struct GNUNET_CONFIGURATION_Handle *cfg) | |||
85 | static void | 85 | static void |
86 | test_record (void *cls, | 86 | test_record (void *cls, |
87 | uint64_t seq, | 87 | uint64_t seq, |
88 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *private_key, | 88 | const struct GNUNET_IDENTITY_PrivateKey *private_key, |
89 | const char *label, | 89 | const char *label, |
90 | unsigned int rd_count, | 90 | unsigned int rd_count, |
91 | const struct GNUNET_GNSRECORD_Data *rd) | 91 | const struct GNUNET_GNSRECORD_Data *rd) |
92 | { | 92 | { |
93 | int *idp = cls; | 93 | int *idp = cls; |
94 | int id = *idp; | 94 | int id = *idp; |
95 | struct GNUNET_CRYPTO_EcdsaPrivateKey tzone_private_key; | 95 | struct GNUNET_IDENTITY_PrivateKey tzone_private_key; |
96 | char tname[64]; | 96 | char tname[64]; |
97 | unsigned int trd_count = 1 + (id % 1024); | 97 | unsigned int trd_count = 1 + (id % 1024); |
98 | 98 | ||
@@ -123,7 +123,7 @@ get_record (struct GNUNET_NAMESTORE_PluginFunctions *nsp, int id) | |||
123 | static void | 123 | static void |
124 | put_record (struct GNUNET_NAMESTORE_PluginFunctions *nsp, int id) | 124 | put_record (struct GNUNET_NAMESTORE_PluginFunctions *nsp, int id) |
125 | { | 125 | { |
126 | struct GNUNET_CRYPTO_EcdsaPrivateKey zone_private_key; | 126 | struct GNUNET_IDENTITY_PrivateKey zone_private_key; |
127 | char label[64]; | 127 | char label[64]; |
128 | unsigned int rd_count = 1 + (id % 1024); | 128 | unsigned int rd_count = 1 + (id % 1024); |
129 | struct GNUNET_GNSRECORD_Data rd[GNUNET_NZL (rd_count)]; | 129 | struct GNUNET_GNSRECORD_Data rd[GNUNET_NZL (rd_count)]; |
diff --git a/src/namestore/test_plugin_rest_namestore.sh b/src/namestore/test_plugin_rest_namestore.sh index 12a7fa50c..8a45cebf5 100755 --- a/src/namestore/test_plugin_rest_namestore.sh +++ b/src/namestore/test_plugin_rest_namestore.sh | |||
@@ -84,14 +84,15 @@ gnunet-identity -C $TEST_ID -c test_namestore_api.conf | |||
84 | test="$(gnunet-namestore -D -z $TEST_ID -c test_namestore_api.conf)" | 84 | test="$(gnunet-namestore -D -z $TEST_ID -c test_namestore_api.conf)" |
85 | name=$TEST_ID | 85 | name=$TEST_ID |
86 | public="$(gnunet-identity -d -c test_namestore_api.conf | grep $TEST_ID | awk 'NR==1{print $3}')" | 86 | public="$(gnunet-identity -d -c test_namestore_api.conf | grep $TEST_ID | awk 'NR==1{print $3}')" |
87 | gnunet-namestore -z $name -p -a -n "test_entry" -e "1d" -V "HVX38H2CB7WJM0WCPWT9CFX6GASMYJVR65RN75SJSSKAYVYXHMRG" -t "PKEY" -c test_namestore_api.conf | 87 | echo "$name $public" |
88 | valgrind gnunet-namestore -z $name -p -a -n "test_entry" -e "1d" -V "000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8" -t "PKEY" -c test_namestore_api.conf | ||
88 | #curl_get "${namestore_link}" "HTTP/1.1 200 OK" | 89 | #curl_get "${namestore_link}" "HTTP/1.1 200 OK" |
89 | curl_get "${namestore_link}/$name" "HTTP/1.1 200 OK" | 90 | curl_get "${namestore_link}/$name" "HTTP/1.1 200 OK" |
90 | curl_get "${namestore_link}/$public" "error" | 91 | curl_get "${namestore_link}/$public" "error" |
91 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf | 92 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf |
92 | 93 | ||
93 | #Test POST with NAME | 94 | #Test POST with NAME |
94 | curl_post "${namestore_link}/$name" '{"data": [{"value":"HVX38H2CB7WJM0WCPWT9CFX6GASMYJVR65RN75SJSSKAYVYXHMRG", "record_type":"PKEY", "expiration_time":"1d","private": false, "relative_expiration": false, "supplemental": false, "shadow": false}],"record_name":"test_entry"}' "HTTP/1.1 204 No Content" | 95 | curl_post "${namestore_link}/$name" '{"data": [{"value":"000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8", "record_type":"PKEY", "expiration_time":"1d","private": false, "relative_expiration": false, "supplemental": false, "shadow": false}],"record_name":"test_entry"}' "HTTP/1.1 204 No Content" |
95 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/null 2>&1 | 96 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/null 2>&1 |
96 | 97 | ||
97 | # invalid values | 98 | # invalid values |
@@ -106,29 +107,29 @@ curl_post "${namestore_link}/$name" '{"data": [{"record_type":"PKEY", "expiratio | |||
106 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/null 2>&1 | 107 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/null 2>&1 |
107 | 108 | ||
108 | #expirations | 109 | #expirations |
109 | curl_post "${namestore_link}/$name" '{"data": [{"value":"HVX38H2CB7WJM0WCPWT9CFX6GASMYJVR65RN75SJSSKAYVYXHMRG", "record_type":"PKEY", "expiration_time":"0d","private": false, "relative_expiration": true, "supplemental": false, "shadow": false}],"record_name":"test_entry"}' "HTTP/1.1 204" | 110 | curl_post "${namestore_link}/$name" '{"data": [{"value":"000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8", "record_type":"PKEY", "expiration_time":"0d","private": false, "relative_expiration": true, "supplemental": false, "shadow": false}],"record_name":"test_entry"}' "HTTP/1.1 204" |
110 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/null 2>&1 | 111 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/null 2>&1 |
111 | 112 | ||
112 | curl_post "${namestore_link}/$name" '{"data": [{"value":"HVX38H2CB7WJM0WCPWT9CFX6GASMYJVR65RN75SJSSKAYVYXHMRG", "record_type":"PKEY", "expiration_time":"10000d","private": false, "relative_expiration": true, "supplemental": false, "shadow": false}],"record_name":"test_entry"}' "HTTP/1.1 204" | 113 | curl_post "${namestore_link}/$name" '{"data": [{"value":"000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8", "record_type":"PKEY", "expiration_time":"10000d","private": false, "relative_expiration": true, "supplemental": false, "shadow": false}],"record_name":"test_entry"}' "HTTP/1.1 204" |
113 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/null 2>&1 | 114 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/null 2>&1 |
114 | 115 | ||
115 | curl_post "${namestore_link}/$name" '{"data": [{"value":"HVX38H2CB7WJM0WCPWT9CFX6GASMYJVR65RN75SJSSKAYVYXHMRG", "record_type":"PKEY", "expiration_time":"now","private": false, "relative_expiration": false, "supplemental": false, "shadow": false}],"record_name":"test_entry"}' "error" | 116 | curl_post "${namestore_link}/$name" '{"data": [{"value":"000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8", "record_type":"PKEY", "expiration_time":"now","private": false, "relative_expiration": false, "supplemental": false, "shadow": false}],"record_name":"test_entry"}' "error" |
116 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/null 2>&1 | 117 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/null 2>&1 |
117 | 118 | ||
118 | curl_post "${namestore_link}/$name" '{"data": [{"value":"HVX38H2CB7WJM0WCPWT9CFX6GASMYJVR65RN75SJSSKAYVYXHMRG", "record_type":"PKEY", "expiration_time_missing":"1d","private": false, "relative_expiration": false, "supplemental": false, "shadow": false}],"record_name":"test_entry"}' "error" | 119 | curl_post "${namestore_link}/$name" '{"data": [{"value":"000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8", "record_type":"PKEY", "expiration_time_missing":"1d","private": false, "relative_expiration": false, "supplemental": false, "shadow": false}],"record_name":"test_entry"}' "error" |
119 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/null 2>&1 | 120 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/null 2>&1 |
120 | 121 | ||
121 | #record_name | 122 | #record_name |
122 | curl_post "${namestore_link}/$name" '{"data": [{"value":"HVX38H2CB7WJM0WCPWT9CFX6GASMYJVR65RN75SJSSKAYVYXHMRG", "record_type":"PKEY", "expiration_time":"1d","private": false, "relative_expiration": false, "supplemental": false, "shadow": false}],"record_name":""}' "error" | 123 | curl_post "${namestore_link}/$name" '{"data": [{"value":"000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8", "record_type":"PKEY", "expiration_time":"1d","private": false, "relative_expiration": false, "supplemental": false, "shadow": false}],"record_name":""}' "error" |
123 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/null 2>&1 | 124 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/null 2>&1 |
124 | curl_post "${namestore_link}/$name" '{"data": [{"value":"HVX38H2CB7WJM0WCPWT9CFX6GASMYJVR65RN75SJSSKAYVYXHMRG", "record_type":"PKEY", "expiration_time":"1d","private": false, "relative_expiration": false, "supplemental": false, "shadow": false}],"record_name_missing":"test_entry"}' "error" | 125 | curl_post "${namestore_link}/$name" '{"data": [{"value":"000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8", "record_type":"PKEY", "expiration_time":"1d","private": false, "relative_expiration": false, "supplemental": false, "shadow": false}],"record_name_missing":"test_entry"}' "error" |
125 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/null 2>&1 | 126 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/null 2>&1 |
126 | 127 | ||
127 | #Test DELETE | 128 | #Test DELETE |
128 | gnunet-namestore -z $name -p -a -n "test_entry" -e "1d" -V "HVX38H2CB7WJM0WCPWT9CFX6GASMYJVR65RN75SJSSKAYVYXHMRG" -t "PKEY" -c test_namestore_api.conf | 129 | gnunet-namestore -z $name -p -a -n "test_entry" -e "1d" -V "000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8" -t "PKEY" -c test_namestore_api.conf |
129 | curl_delete "${namestore_link}/$name/test_entry" "HTTP/1.1 204" | 130 | curl_delete "${namestore_link}/$name/test_entry" "HTTP/1.1 204" |
130 | curl_delete "${namestore_link}/$name/test_entry" "error" | 131 | curl_delete "${namestore_link}/$name/test_entry" "error" |
131 | gnunet-namestore -z $name -p -a -n "test_entry" -e "1d" -V "HVX38H2CB7WJM0WCPWT9CFX6GASMYJVR65RN75SJSSKAYVYXHMRG" -t "PKEY" -c test_namestore_api.conf | 132 | gnunet-namestore -z $name -p -a -n "test_entry" -e "1d" -V "000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8" -t "PKEY" -c test_namestore_api.conf |
132 | curl_delete "${namestore_link}/$public/test_entry" "error" | 133 | curl_delete "${namestore_link}/$public/test_entry" "error" |
133 | 134 | ||
134 | gnunet-arm -e -c test_namestore_api.conf | 135 | gnunet-arm -e -c test_namestore_api.conf |
diff --git a/src/nse/gnunet-nse-profiler.c b/src/nse/gnunet-nse-profiler.c index 81a16b245..f653a716e 100644 --- a/src/nse/gnunet-nse-profiler.c +++ b/src/nse/gnunet-nse-profiler.c | |||
@@ -317,7 +317,7 @@ handle_estimate (void *cls, | |||
317 | } | 317 | } |
318 | size = GNUNET_snprintf (output_buffer, | 318 | size = GNUNET_snprintf (output_buffer, |
319 | sizeof(output_buffer), | 319 | sizeof(output_buffer), |
320 | "%p %llu %llu %f %f %f\n", | 320 | "%p %u %llu %f %f %f\n", |
321 | peer, | 321 | peer, |
322 | peers_running, | 322 | peers_running, |
323 | (unsigned long long) timestamp.abs_value_us, | 323 | (unsigned long long) timestamp.abs_value_us, |
diff --git a/src/peerinfo-tool/gnunet-peerinfo.c b/src/peerinfo-tool/gnunet-peerinfo.c index 739249a93..987c7c3a0 100644 --- a/src/peerinfo-tool/gnunet-peerinfo.c +++ b/src/peerinfo-tool/gnunet-peerinfo.c | |||
@@ -338,9 +338,9 @@ print_address (void *cls, | |||
338 | ar->pc = pc; | 338 | ar->pc = pc; |
339 | ar->expiration = expiration; | 339 | ar->expiration = expiration; |
340 | GNUNET_asprintf (&ar->result, | 340 | GNUNET_asprintf (&ar->result, |
341 | "%s:%u:%u", | 341 | "%s:%lu:%u", |
342 | address->transport_name, | 342 | address->transport_name, |
343 | address->address_length, | 343 | (unsigned long) address->address_length, |
344 | address->local_info); | 344 | address->local_info); |
345 | ar->atsc = GNUNET_TRANSPORT_address_to_string (cfg, | 345 | ar->atsc = GNUNET_TRANSPORT_address_to_string (cfg, |
346 | address, | 346 | address, |
diff --git a/src/peerinfo-tool/plugin_rest_peerinfo.c b/src/peerinfo-tool/plugin_rest_peerinfo.c index 99cec7e58..4bbc7442e 100644 --- a/src/peerinfo-tool/plugin_rest_peerinfo.c +++ b/src/peerinfo-tool/plugin_rest_peerinfo.c | |||
@@ -554,9 +554,9 @@ print_address (void *cls, | |||
554 | ar->pc = pc; | 554 | ar->pc = pc; |
555 | ar->expiration = expiration; | 555 | ar->expiration = expiration; |
556 | GNUNET_asprintf (&ar->result, | 556 | GNUNET_asprintf (&ar->result, |
557 | "%s:%u:%u", | 557 | "%s:%lu:%u", |
558 | address->transport_name, | 558 | address->transport_name, |
559 | address->address_length, | 559 | (unsigned long) address->address_length, |
560 | address->local_info); | 560 | address->local_info); |
561 | ar->atsc = GNUNET_TRANSPORT_address_to_string (cfg, | 561 | ar->atsc = GNUNET_TRANSPORT_address_to_string (cfg, |
562 | address, | 562 | address, |
diff --git a/src/pq/pq.c b/src/pq/pq.c index eca097e58..e9c960e33 100644 --- a/src/pq/pq.c +++ b/src/pq/pq.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet | 2 | This file is part of GNUnet |
3 | Copyright (C) 2014, 2015, 2016, 2017, 2019 GNUnet e.V. | 3 | Copyright (C) 2014, 2015, 2016, 2017, 2019, 2020 GNUnet e.V. |
4 | 4 | ||
5 | GNUnet is free software: you can redistribute it and/or modify it | 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 | 6 | under the terms of the GNU Affero General Public License as published |
@@ -27,14 +27,7 @@ | |||
27 | #include "platform.h" | 27 | #include "platform.h" |
28 | #include "pq.h" | 28 | #include "pq.h" |
29 | 29 | ||
30 | /** | 30 | |
31 | * Execute a prepared statement. | ||
32 | * | ||
33 | * @param db database handle | ||
34 | * @param name name of the prepared statement | ||
35 | * @param params parameters to the statement | ||
36 | * @return postgres result | ||
37 | */ | ||
38 | PGresult * | 31 | PGresult * |
39 | GNUNET_PQ_exec_prepared (struct GNUNET_PQ_Context *db, | 32 | GNUNET_PQ_exec_prepared (struct GNUNET_PQ_Context *db, |
40 | const char *name, | 33 | const char *name, |
@@ -120,12 +113,6 @@ GNUNET_PQ_exec_prepared (struct GNUNET_PQ_Context *db, | |||
120 | } | 113 | } |
121 | 114 | ||
122 | 115 | ||
123 | /** | ||
124 | * Free all memory that was allocated in @a rs during | ||
125 | * #GNUNET_PQ_extract_result(). | ||
126 | * | ||
127 | * @param rs reult specification to clean up | ||
128 | */ | ||
129 | void | 116 | void |
130 | GNUNET_PQ_cleanup_result (struct GNUNET_PQ_ResultSpec *rs) | 117 | GNUNET_PQ_cleanup_result (struct GNUNET_PQ_ResultSpec *rs) |
131 | { | 118 | { |
@@ -136,17 +123,6 @@ GNUNET_PQ_cleanup_result (struct GNUNET_PQ_ResultSpec *rs) | |||
136 | } | 123 | } |
137 | 124 | ||
138 | 125 | ||
139 | /** | ||
140 | * Extract results from a query result according to the given | ||
141 | * specification. | ||
142 | * | ||
143 | * @param result result to process | ||
144 | * @param[in,out] rs result specification to extract for | ||
145 | * @param row row from the result to extract | ||
146 | * @return | ||
147 | * #GNUNET_YES if all results could be extracted | ||
148 | * #GNUNET_SYSERR if a result was invalid (non-existing field) | ||
149 | */ | ||
150 | int | 126 | int |
151 | GNUNET_PQ_extract_result (PGresult *result, | 127 | GNUNET_PQ_extract_result (PGresult *result, |
152 | struct GNUNET_PQ_ResultSpec *rs, | 128 | struct GNUNET_PQ_ResultSpec *rs, |
@@ -160,6 +136,23 @@ GNUNET_PQ_extract_result (PGresult *result, | |||
160 | int ret; | 136 | int ret; |
161 | 137 | ||
162 | spec = &rs[i]; | 138 | spec = &rs[i]; |
139 | if (spec->is_nullable) | ||
140 | { | ||
141 | int fnum; | ||
142 | |||
143 | fnum = PQfnumber (result, | ||
144 | spec->fname); | ||
145 | if (PQgetisnull (result, | ||
146 | row, | ||
147 | fnum)) | ||
148 | { | ||
149 | if (NULL != spec->is_null) | ||
150 | *spec->is_null = true; | ||
151 | continue; | ||
152 | } | ||
153 | if (NULL != spec->is_null) | ||
154 | *spec->is_null = false; | ||
155 | } | ||
163 | ret = spec->conv (spec->cls, | 156 | ret = spec->conv (spec->cls, |
164 | result, | 157 | result, |
165 | row, | 158 | row, |
diff --git a/src/pq/pq_eval.c b/src/pq/pq_eval.c index 5bcf8ca0e..8d8b5b0f2 100644 --- a/src/pq/pq_eval.c +++ b/src/pq/pq_eval.c | |||
@@ -263,6 +263,7 @@ GNUNET_PQ_eval_prepared_singleton_select (struct GNUNET_PQ_Context *db, | |||
263 | { | 263 | { |
264 | PGresult *result; | 264 | PGresult *result; |
265 | enum GNUNET_DB_QueryStatus qs; | 265 | enum GNUNET_DB_QueryStatus qs; |
266 | int ntuples; | ||
266 | 267 | ||
267 | result = GNUNET_PQ_exec_prepared (db, | 268 | result = GNUNET_PQ_exec_prepared (db, |
268 | statement_name, | 269 | statement_name, |
@@ -277,12 +278,13 @@ GNUNET_PQ_eval_prepared_singleton_select (struct GNUNET_PQ_Context *db, | |||
277 | PQclear (result); | 278 | PQclear (result); |
278 | return qs; | 279 | return qs; |
279 | } | 280 | } |
280 | if (0 == PQntuples (result)) | 281 | ntuples = PQntuples (result); |
282 | if (0 == ntuples) | ||
281 | { | 283 | { |
282 | PQclear (result); | 284 | PQclear (result); |
283 | return GNUNET_DB_STATUS_SUCCESS_NO_RESULTS; | 285 | return GNUNET_DB_STATUS_SUCCESS_NO_RESULTS; |
284 | } | 286 | } |
285 | if (1 != PQntuples (result)) | 287 | if (1 != ntuples) |
286 | { | 288 | { |
287 | /* more than one result, but there must be at most one */ | 289 | /* more than one result, but there must be at most one */ |
288 | GNUNET_break (0); | 290 | GNUNET_break (0); |
diff --git a/src/pq/pq_query_helper.c b/src/pq/pq_query_helper.c index a36848f3a..cee84d203 100644 --- a/src/pq/pq_query_helper.c +++ b/src/pq/pq_query_helper.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet | 2 | This file is part of GNUnet |
3 | Copyright (C) 2014, 2015, 2016 GNUnet e.V. | 3 | Copyright (C) 2014, 2015, 2016, 2020 GNUnet e.V. |
4 | 4 | ||
5 | GNUnet is free software: you can redistribute it and/or modify it | 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 | 6 | under the terms of the GNU Affero General Public License as published |
@@ -42,6 +42,56 @@ | |||
42 | * @return -1 on error, number of offsets used in @a scratch otherwise | 42 | * @return -1 on error, number of offsets used in @a scratch otherwise |
43 | */ | 43 | */ |
44 | static int | 44 | static int |
45 | qconv_null (void *cls, | ||
46 | const void *data, | ||
47 | size_t data_len, | ||
48 | void *param_values[], | ||
49 | int param_lengths[], | ||
50 | int param_formats[], | ||
51 | unsigned int param_length, | ||
52 | void *scratch[], | ||
53 | unsigned int scratch_length) | ||
54 | { | ||
55 | (void) scratch; | ||
56 | (void) scratch_length; | ||
57 | (void) data; | ||
58 | (void) data_len; | ||
59 | GNUNET_break (NULL == cls); | ||
60 | if (1 != param_length) | ||
61 | return -1; | ||
62 | param_values[0] = NULL; | ||
63 | param_lengths[0] = 0; | ||
64 | param_formats[0] = 1; | ||
65 | return 0; | ||
66 | } | ||
67 | |||
68 | |||
69 | struct GNUNET_PQ_QueryParam | ||
70 | GNUNET_PQ_query_param_null (void) | ||
71 | { | ||
72 | struct GNUNET_PQ_QueryParam res = { | ||
73 | &qconv_null, NULL, NULL, 0, 1 | ||
74 | }; | ||
75 | |||
76 | return res; | ||
77 | } | ||
78 | |||
79 | |||
80 | /** | ||
81 | * Function called to convert input argument into SQL parameters. | ||
82 | * | ||
83 | * @param cls closure | ||
84 | * @param data pointer to input argument | ||
85 | * @param data_len number of bytes in @a data (if applicable) | ||
86 | * @param[out] param_values SQL data to set | ||
87 | * @param[out] param_lengths SQL length data to set | ||
88 | * @param[out] param_formats SQL format data to set | ||
89 | * @param param_length number of entries available in the @a param_values, @a param_lengths and @a param_formats arrays | ||
90 | * @param[out] scratch buffer for dynamic allocations (to be done via #GNUNET_malloc() | ||
91 | * @param scratch_length number of entries left in @a scratch | ||
92 | * @return -1 on error, number of offsets used in @a scratch otherwise | ||
93 | */ | ||
94 | static int | ||
45 | qconv_fixed (void *cls, | 95 | qconv_fixed (void *cls, |
46 | const void *data, | 96 | const void *data, |
47 | size_t data_len, | 97 | size_t data_len, |
@@ -64,33 +114,23 @@ qconv_fixed (void *cls, | |||
64 | } | 114 | } |
65 | 115 | ||
66 | 116 | ||
67 | /** | ||
68 | * Generate query parameter for a buffer @a ptr of | ||
69 | * @a ptr_size bytes. | ||
70 | * | ||
71 | * @param ptr pointer to the query parameter to pass | ||
72 | * @oaran ptr_size number of bytes in @a ptr | ||
73 | */ | ||
74 | struct GNUNET_PQ_QueryParam | 117 | struct GNUNET_PQ_QueryParam |
75 | GNUNET_PQ_query_param_fixed_size (const void *ptr, | 118 | GNUNET_PQ_query_param_fixed_size (const void *ptr, |
76 | size_t ptr_size) | 119 | size_t ptr_size) |
77 | { | 120 | { |
78 | struct GNUNET_PQ_QueryParam res = | 121 | struct GNUNET_PQ_QueryParam res = { |
79 | { &qconv_fixed, NULL, ptr, ptr_size, 1 }; | 122 | &qconv_fixed, NULL, ptr, ptr_size, 1 |
123 | }; | ||
80 | 124 | ||
81 | return res; | 125 | return res; |
82 | } | 126 | } |
83 | 127 | ||
84 | 128 | ||
85 | /** | ||
86 | * Generate query parameter for a string. | ||
87 | * | ||
88 | * @param ptr pointer to the string query parameter to pass | ||
89 | */ | ||
90 | struct GNUNET_PQ_QueryParam | 129 | struct GNUNET_PQ_QueryParam |
91 | GNUNET_PQ_query_param_string (const char *ptr) | 130 | GNUNET_PQ_query_param_string (const char *ptr) |
92 | { | 131 | { |
93 | return GNUNET_PQ_query_param_fixed_size (ptr, strlen (ptr)); | 132 | return GNUNET_PQ_query_param_fixed_size (ptr, |
133 | strlen (ptr)); | ||
94 | } | 134 | } |
95 | 135 | ||
96 | 136 | ||
@@ -137,11 +177,6 @@ qconv_uint16 (void *cls, | |||
137 | } | 177 | } |
138 | 178 | ||
139 | 179 | ||
140 | /** | ||
141 | * Generate query parameter for an uint16_t in host byte order. | ||
142 | * | ||
143 | * @param x pointer to the query parameter to pass | ||
144 | */ | ||
145 | struct GNUNET_PQ_QueryParam | 180 | struct GNUNET_PQ_QueryParam |
146 | GNUNET_PQ_query_param_uint16 (const uint16_t *x) | 181 | GNUNET_PQ_query_param_uint16 (const uint16_t *x) |
147 | { | 182 | { |
@@ -195,11 +230,6 @@ qconv_uint32 (void *cls, | |||
195 | } | 230 | } |
196 | 231 | ||
197 | 232 | ||
198 | /** | ||
199 | * Generate query parameter for an uint32_t in host byte order. | ||
200 | * | ||
201 | * @param x pointer to the query parameter to pass | ||
202 | */ | ||
203 | struct GNUNET_PQ_QueryParam | 233 | struct GNUNET_PQ_QueryParam |
204 | GNUNET_PQ_query_param_uint32 (const uint32_t *x) | 234 | GNUNET_PQ_query_param_uint32 (const uint32_t *x) |
205 | { | 235 | { |
@@ -253,11 +283,6 @@ qconv_uint64 (void *cls, | |||
253 | } | 283 | } |
254 | 284 | ||
255 | 285 | ||
256 | /** | ||
257 | * Generate query parameter for an uint64_t in host byte order. | ||
258 | * | ||
259 | * @param x pointer to the query parameter to pass | ||
260 | */ | ||
261 | struct GNUNET_PQ_QueryParam | 286 | struct GNUNET_PQ_QueryParam |
262 | GNUNET_PQ_query_param_uint64 (const uint64_t *x) | 287 | GNUNET_PQ_query_param_uint64 (const uint64_t *x) |
263 | { | 288 | { |
@@ -310,13 +335,6 @@ qconv_rsa_public_key (void *cls, | |||
310 | } | 335 | } |
311 | 336 | ||
312 | 337 | ||
313 | /** | ||
314 | * Generate query parameter for an RSA public key. The | ||
315 | * database must contain a BLOB type in the respective position. | ||
316 | * | ||
317 | * @param x the query parameter to pass | ||
318 | * @return array entry for the query parameters to use | ||
319 | */ | ||
320 | struct GNUNET_PQ_QueryParam | 338 | struct GNUNET_PQ_QueryParam |
321 | GNUNET_PQ_query_param_rsa_public_key (const struct | 339 | GNUNET_PQ_query_param_rsa_public_key (const struct |
322 | GNUNET_CRYPTO_RsaPublicKey *x) | 340 | GNUNET_CRYPTO_RsaPublicKey *x) |
@@ -370,13 +388,6 @@ qconv_rsa_signature (void *cls, | |||
370 | } | 388 | } |
371 | 389 | ||
372 | 390 | ||
373 | /** | ||
374 | * Generate query parameter for an RSA signature. The | ||
375 | * database must contain a BLOB type in the respective position. | ||
376 | * | ||
377 | * @param x the query parameter to pass | ||
378 | * @return array entry for the query parameters to use | ||
379 | */ | ||
380 | struct GNUNET_PQ_QueryParam | 391 | struct GNUNET_PQ_QueryParam |
381 | GNUNET_PQ_query_param_rsa_signature (const struct GNUNET_CRYPTO_RsaSignature *x) | 392 | GNUNET_PQ_query_param_rsa_signature (const struct GNUNET_CRYPTO_RsaSignature *x) |
382 | { | 393 | { |
@@ -432,13 +443,6 @@ qconv_rel_time (void *cls, | |||
432 | } | 443 | } |
433 | 444 | ||
434 | 445 | ||
435 | /** | ||
436 | * Generate query parameter for a relative time value. | ||
437 | * The database must store a 64-bit integer. | ||
438 | * | ||
439 | * @param x pointer to the query parameter to pass | ||
440 | * @return array entry for the query parameters to use | ||
441 | */ | ||
442 | struct GNUNET_PQ_QueryParam | 446 | struct GNUNET_PQ_QueryParam |
443 | GNUNET_PQ_query_param_relative_time (const struct GNUNET_TIME_Relative *x) | 447 | GNUNET_PQ_query_param_relative_time (const struct GNUNET_TIME_Relative *x) |
444 | { | 448 | { |
@@ -494,29 +498,17 @@ qconv_abs_time (void *cls, | |||
494 | } | 498 | } |
495 | 499 | ||
496 | 500 | ||
497 | /** | ||
498 | * Generate query parameter for an absolute time value. | ||
499 | * The database must store a 64-bit integer. | ||
500 | * | ||
501 | * @param x pointer to the query parameter to pass | ||
502 | * @return array entry for the query parameters to use | ||
503 | */ | ||
504 | struct GNUNET_PQ_QueryParam | 501 | struct GNUNET_PQ_QueryParam |
505 | GNUNET_PQ_query_param_absolute_time (const struct GNUNET_TIME_Absolute *x) | 502 | GNUNET_PQ_query_param_absolute_time (const struct GNUNET_TIME_Absolute *x) |
506 | { | 503 | { |
507 | struct GNUNET_PQ_QueryParam res = | 504 | struct GNUNET_PQ_QueryParam res = { |
508 | { &qconv_abs_time, NULL, x, sizeof(*x), 1 }; | 505 | &qconv_abs_time, NULL, x, sizeof(*x), 1 |
506 | }; | ||
509 | 507 | ||
510 | return res; | 508 | return res; |
511 | } | 509 | } |
512 | 510 | ||
513 | 511 | ||
514 | /** | ||
515 | * Generate query parameter for an absolute time value. | ||
516 | * The database must store a 64-bit integer. | ||
517 | * | ||
518 | * @param x pointer to the query parameter to pass | ||
519 | */ | ||
520 | struct GNUNET_PQ_QueryParam | 512 | struct GNUNET_PQ_QueryParam |
521 | GNUNET_PQ_query_param_absolute_time_nbo (const struct | 513 | GNUNET_PQ_query_param_absolute_time_nbo (const struct |
522 | GNUNET_TIME_AbsoluteNBO *x) | 514 | GNUNET_TIME_AbsoluteNBO *x) |
diff --git a/src/pq/pq_result_helper.c b/src/pq/pq_result_helper.c index f764593b0..546822e45 100644 --- a/src/pq/pq_result_helper.c +++ b/src/pq/pq_result_helper.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet | 2 | This file is part of GNUnet |
3 | Copyright (C) 2014, 2015, 2016 GNUnet e.V. | 3 | Copyright (C) 2014, 2015, 2016, 2020 GNUnet e.V. |
4 | 4 | ||
5 | GNUnet is free software: you can redistribute it and/or modify it | 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 | 6 | under the terms of the GNU Affero General Public License as published |
@@ -27,6 +27,19 @@ | |||
27 | #include "gnunet_pq_lib.h" | 27 | #include "gnunet_pq_lib.h" |
28 | 28 | ||
29 | 29 | ||
30 | struct GNUNET_PQ_ResultSpec | ||
31 | GNUNET_PQ_result_spec_allow_null (struct GNUNET_PQ_ResultSpec rs, | ||
32 | bool *is_null) | ||
33 | { | ||
34 | struct GNUNET_PQ_ResultSpec rsr; | ||
35 | |||
36 | rsr = rs; | ||
37 | rsr.is_nullable = true; | ||
38 | rsr.is_null = is_null; | ||
39 | return rsr; | ||
40 | } | ||
41 | |||
42 | |||
30 | /** | 43 | /** |
31 | * Function called to clean up memory allocated | 44 | * Function called to clean up memory allocated |
32 | * by a #GNUNET_PQ_ResultConverter. | 45 | * by a #GNUNET_PQ_ResultConverter. |
@@ -112,14 +125,6 @@ extract_varsize_blob (void *cls, | |||
112 | } | 125 | } |
113 | 126 | ||
114 | 127 | ||
115 | /** | ||
116 | * Variable-size result expected. | ||
117 | * | ||
118 | * @param name name of the field in the table | ||
119 | * @param[out] dst where to store the result, allocated | ||
120 | * @param[out] sptr where to store the size of @a dst | ||
121 | * @return array entry for the result specification to use | ||
122 | */ | ||
123 | struct GNUNET_PQ_ResultSpec | 128 | struct GNUNET_PQ_ResultSpec |
124 | GNUNET_PQ_result_spec_variable_size (const char *name, | 129 | GNUNET_PQ_result_spec_variable_size (const char *name, |
125 | void **dst, | 130 | void **dst, |
@@ -196,14 +201,6 @@ extract_fixed_blob (void *cls, | |||
196 | } | 201 | } |
197 | 202 | ||
198 | 203 | ||
199 | /** | ||
200 | * Fixed-size result expected. | ||
201 | * | ||
202 | * @param name name of the field in the table | ||
203 | * @param[out] dst where to store the result | ||
204 | * @param dst_size number of bytes in @a dst | ||
205 | * @return array entry for the result specification to use | ||
206 | */ | ||
207 | struct GNUNET_PQ_ResultSpec | 204 | struct GNUNET_PQ_ResultSpec |
208 | GNUNET_PQ_result_spec_fixed_size (const char *name, | 205 | GNUNET_PQ_result_spec_fixed_size (const char *name, |
209 | void *dst, | 206 | void *dst, |
@@ -301,13 +298,6 @@ clean_rsa_public_key (void *cls, | |||
301 | } | 298 | } |
302 | 299 | ||
303 | 300 | ||
304 | /** | ||
305 | * RSA public key expected. | ||
306 | * | ||
307 | * @param name name of the field in the table | ||
308 | * @param[out] rsa where to store the result | ||
309 | * @return array entry for the result specification to use | ||
310 | */ | ||
311 | struct GNUNET_PQ_ResultSpec | 301 | struct GNUNET_PQ_ResultSpec |
312 | GNUNET_PQ_result_spec_rsa_public_key (const char *name, | 302 | GNUNET_PQ_result_spec_rsa_public_key (const char *name, |
313 | struct GNUNET_CRYPTO_RsaPublicKey **rsa) | 303 | struct GNUNET_CRYPTO_RsaPublicKey **rsa) |
@@ -405,13 +395,6 @@ clean_rsa_signature (void *cls, | |||
405 | } | 395 | } |
406 | 396 | ||
407 | 397 | ||
408 | /** | ||
409 | * RSA signature expected. | ||
410 | * | ||
411 | * @param name name of the field in the table | ||
412 | * @param[out] sig where to store the result; | ||
413 | * @return array entry for the result specification to use | ||
414 | */ | ||
415 | struct GNUNET_PQ_ResultSpec | 398 | struct GNUNET_PQ_ResultSpec |
416 | GNUNET_PQ_result_spec_rsa_signature (const char *name, | 399 | GNUNET_PQ_result_spec_rsa_signature (const char *name, |
417 | struct GNUNET_CRYPTO_RsaSignature **sig) | 400 | struct GNUNET_CRYPTO_RsaSignature **sig) |
@@ -509,13 +492,6 @@ clean_string (void *cls, | |||
509 | } | 492 | } |
510 | 493 | ||
511 | 494 | ||
512 | /** | ||
513 | * 0-terminated string expected. | ||
514 | * | ||
515 | * @param name name of the field in the table | ||
516 | * @param[out] dst where to store the result, allocated | ||
517 | * @return array entry for the result specification to use | ||
518 | */ | ||
519 | struct GNUNET_PQ_ResultSpec | 495 | struct GNUNET_PQ_ResultSpec |
520 | GNUNET_PQ_result_spec_string (const char *name, | 496 | GNUNET_PQ_result_spec_string (const char *name, |
521 | char **dst) | 497 | char **dst) |
@@ -595,13 +571,6 @@ extract_rel_time (void *cls, | |||
595 | } | 571 | } |
596 | 572 | ||
597 | 573 | ||
598 | /** | ||
599 | * Relative time expected. | ||
600 | * | ||
601 | * @param name name of the field in the table | ||
602 | * @param[out] at where to store the result | ||
603 | * @return array entry for the result specification to use | ||
604 | */ | ||
605 | struct GNUNET_PQ_ResultSpec | 574 | struct GNUNET_PQ_ResultSpec |
606 | GNUNET_PQ_result_spec_relative_time (const char *name, | 575 | GNUNET_PQ_result_spec_relative_time (const char *name, |
607 | struct GNUNET_TIME_Relative *rt) | 576 | struct GNUNET_TIME_Relative *rt) |
@@ -685,13 +654,6 @@ extract_abs_time (void *cls, | |||
685 | } | 654 | } |
686 | 655 | ||
687 | 656 | ||
688 | /** | ||
689 | * Absolute time expected. | ||
690 | * | ||
691 | * @param name name of the field in the table | ||
692 | * @param[out] at where to store the result | ||
693 | * @return array entry for the result specification to use | ||
694 | */ | ||
695 | struct GNUNET_PQ_ResultSpec | 657 | struct GNUNET_PQ_ResultSpec |
696 | GNUNET_PQ_result_spec_absolute_time (const char *name, | 658 | GNUNET_PQ_result_spec_absolute_time (const char *name, |
697 | struct GNUNET_TIME_Absolute *at) | 659 | struct GNUNET_TIME_Absolute *at) |
@@ -706,13 +668,6 @@ GNUNET_PQ_result_spec_absolute_time (const char *name, | |||
706 | } | 668 | } |
707 | 669 | ||
708 | 670 | ||
709 | /** | ||
710 | * Absolute time in network byte order expected. | ||
711 | * | ||
712 | * @param name name of the field in the table | ||
713 | * @param[out] at where to store the result | ||
714 | * @return array entry for the result specification to use | ||
715 | */ | ||
716 | struct GNUNET_PQ_ResultSpec | 671 | struct GNUNET_PQ_ResultSpec |
717 | GNUNET_PQ_result_spec_absolute_time_nbo (const char *name, | 672 | GNUNET_PQ_result_spec_absolute_time_nbo (const char *name, |
718 | struct GNUNET_TIME_AbsoluteNBO *at) | 673 | struct GNUNET_TIME_AbsoluteNBO *at) |
@@ -786,13 +741,6 @@ extract_uint16 (void *cls, | |||
786 | } | 741 | } |
787 | 742 | ||
788 | 743 | ||
789 | /** | ||
790 | * uint16_t expected. | ||
791 | * | ||
792 | * @param name name of the field in the table | ||
793 | * @param[out] u16 where to store the result | ||
794 | * @return array entry for the result specification to use | ||
795 | */ | ||
796 | struct GNUNET_PQ_ResultSpec | 744 | struct GNUNET_PQ_ResultSpec |
797 | GNUNET_PQ_result_spec_uint16 (const char *name, | 745 | GNUNET_PQ_result_spec_uint16 (const char *name, |
798 | uint16_t *u16) | 746 | uint16_t *u16) |
@@ -869,13 +817,6 @@ extract_uint32 (void *cls, | |||
869 | } | 817 | } |
870 | 818 | ||
871 | 819 | ||
872 | /** | ||
873 | * uint32_t expected. | ||
874 | * | ||
875 | * @param name name of the field in the table | ||
876 | * @param[out] u32 where to store the result | ||
877 | * @return array entry for the result specification to use | ||
878 | */ | ||
879 | struct GNUNET_PQ_ResultSpec | 820 | struct GNUNET_PQ_ResultSpec |
880 | GNUNET_PQ_result_spec_uint32 (const char *name, | 821 | GNUNET_PQ_result_spec_uint32 (const char *name, |
881 | uint32_t *u32) | 822 | uint32_t *u32) |
@@ -952,22 +893,16 @@ extract_uint64 (void *cls, | |||
952 | } | 893 | } |
953 | 894 | ||
954 | 895 | ||
955 | /** | ||
956 | * uint64_t expected. | ||
957 | * | ||
958 | * @param name name of the field in the table | ||
959 | * @param[out] u64 where to store the result | ||
960 | * @return array entry for the result specification to use | ||
961 | */ | ||
962 | struct GNUNET_PQ_ResultSpec | 896 | struct GNUNET_PQ_ResultSpec |
963 | GNUNET_PQ_result_spec_uint64 (const char *name, | 897 | GNUNET_PQ_result_spec_uint64 (const char *name, |
964 | uint64_t *u64) | 898 | uint64_t *u64) |
965 | { | 899 | { |
966 | struct GNUNET_PQ_ResultSpec res = | 900 | struct GNUNET_PQ_ResultSpec res = { |
967 | { &extract_uint64, | 901 | &extract_uint64, |
968 | NULL, | 902 | NULL, |
969 | NULL, | 903 | NULL, |
970 | (void *) u64, sizeof(*u64), (name), NULL }; | 904 | (void *) u64, sizeof(*u64), (name), NULL |
905 | }; | ||
971 | 906 | ||
972 | return res; | 907 | return res; |
973 | } | 908 | } |
diff --git a/src/pq/test_pq.c b/src/pq/test_pq.c index b09354af8..e588da45d 100644 --- a/src/pq/test_pq.c +++ b/src/pq/test_pq.c | |||
@@ -47,10 +47,11 @@ postgres_prepare (struct GNUNET_PQ_Context *db) | |||
47 | ",u16" | 47 | ",u16" |
48 | ",u32" | 48 | ",u32" |
49 | ",u64" | 49 | ",u64" |
50 | ",unn" | ||
50 | ") VALUES " | 51 | ") VALUES " |
51 | "($1, $2, $3, $4, $5, $6," | 52 | "($1, $2, $3, $4, $5, $6," |
52 | "$7, $8, $9);", | 53 | "$7, $8, $9, $10);", |
53 | 9), | 54 | 10), |
54 | GNUNET_PQ_make_prepare ("test_select", | 55 | GNUNET_PQ_make_prepare ("test_select", |
55 | "SELECT" | 56 | "SELECT" |
56 | " pub" | 57 | " pub" |
@@ -62,6 +63,7 @@ postgres_prepare (struct GNUNET_PQ_Context *db) | |||
62 | ",u16" | 63 | ",u16" |
63 | ",u32" | 64 | ",u32" |
64 | ",u64" | 65 | ",u64" |
66 | ",unn" | ||
65 | " FROM test_pq" | 67 | " FROM test_pq" |
66 | " ORDER BY abs_time DESC " | 68 | " ORDER BY abs_time DESC " |
67 | " LIMIT 1;", | 69 | " LIMIT 1;", |
@@ -106,7 +108,8 @@ run_queries (struct GNUNET_PQ_Context *db) | |||
106 | uint32_t u322; | 108 | uint32_t u322; |
107 | uint64_t u64; | 109 | uint64_t u64; |
108 | uint64_t u642; | 110 | uint64_t u642; |
109 | 111 | uint64_t uzzz = 42; | |
112 | |||
110 | priv = GNUNET_CRYPTO_rsa_private_key_create (1024); | 113 | priv = GNUNET_CRYPTO_rsa_private_key_create (1024); |
111 | pub = GNUNET_CRYPTO_rsa_private_key_get_public (priv); | 114 | pub = GNUNET_CRYPTO_rsa_private_key_get_public (priv); |
112 | memset (&hmsg, 42, sizeof(hmsg)); | 115 | memset (&hmsg, 42, sizeof(hmsg)); |
@@ -127,11 +130,13 @@ run_queries (struct GNUNET_PQ_Context *db) | |||
127 | GNUNET_PQ_query_param_uint16 (&u16), | 130 | GNUNET_PQ_query_param_uint16 (&u16), |
128 | GNUNET_PQ_query_param_uint32 (&u32), | 131 | GNUNET_PQ_query_param_uint32 (&u32), |
129 | GNUNET_PQ_query_param_uint64 (&u64), | 132 | GNUNET_PQ_query_param_uint64 (&u64), |
133 | GNUNET_PQ_query_param_null (), | ||
130 | GNUNET_PQ_query_param_end | 134 | GNUNET_PQ_query_param_end |
131 | }; | 135 | }; |
132 | struct GNUNET_PQ_QueryParam params_select[] = { | 136 | struct GNUNET_PQ_QueryParam params_select[] = { |
133 | GNUNET_PQ_query_param_end | 137 | GNUNET_PQ_query_param_end |
134 | }; | 138 | }; |
139 | bool got_null = false; | ||
135 | struct GNUNET_PQ_ResultSpec results_select[] = { | 140 | struct GNUNET_PQ_ResultSpec results_select[] = { |
136 | GNUNET_PQ_result_spec_rsa_public_key ("pub", &pub2), | 141 | GNUNET_PQ_result_spec_rsa_public_key ("pub", &pub2), |
137 | GNUNET_PQ_result_spec_rsa_signature ("sig", &sig2), | 142 | GNUNET_PQ_result_spec_rsa_signature ("sig", &sig2), |
@@ -142,6 +147,9 @@ run_queries (struct GNUNET_PQ_Context *db) | |||
142 | GNUNET_PQ_result_spec_uint16 ("u16", &u162), | 147 | GNUNET_PQ_result_spec_uint16 ("u16", &u162), |
143 | GNUNET_PQ_result_spec_uint32 ("u32", &u322), | 148 | GNUNET_PQ_result_spec_uint32 ("u32", &u322), |
144 | GNUNET_PQ_result_spec_uint64 ("u64", &u642), | 149 | GNUNET_PQ_result_spec_uint64 ("u64", &u642), |
150 | GNUNET_PQ_result_spec_allow_null ( | ||
151 | GNUNET_PQ_result_spec_uint64 ("unn", &uzzz), | ||
152 | &got_null), | ||
145 | GNUNET_PQ_result_spec_end | 153 | GNUNET_PQ_result_spec_end |
146 | }; | 154 | }; |
147 | 155 | ||
@@ -197,6 +205,8 @@ run_queries (struct GNUNET_PQ_Context *db) | |||
197 | GNUNET_break (16 == u162); | 205 | GNUNET_break (16 == u162); |
198 | GNUNET_break (32 == u322); | 206 | GNUNET_break (32 == u322); |
199 | GNUNET_break (64 == u642); | 207 | GNUNET_break (64 == u642); |
208 | GNUNET_break (42 == uzzz); | ||
209 | GNUNET_break (got_null); | ||
200 | GNUNET_PQ_cleanup_result (results_select); | 210 | GNUNET_PQ_cleanup_result (results_select); |
201 | PQclear (result); | 211 | PQclear (result); |
202 | } | 212 | } |
@@ -225,6 +235,7 @@ main (int argc, | |||
225 | ",u16 INT2 NOT NULL" | 235 | ",u16 INT2 NOT NULL" |
226 | ",u32 INT4 NOT NULL" | 236 | ",u32 INT4 NOT NULL" |
227 | ",u64 INT8 NOT NULL" | 237 | ",u64 INT8 NOT NULL" |
238 | ",unn INT8" | ||
228 | ")"), | 239 | ")"), |
229 | GNUNET_PQ_EXECUTE_STATEMENT_END | 240 | GNUNET_PQ_EXECUTE_STATEMENT_END |
230 | }; | 241 | }; |
diff --git a/src/pt/test_gns_vpn.c b/src/pt/test_gns_vpn.c index cf0455477..7b4abaec2 100644 --- a/src/pt/test_gns_vpn.c +++ b/src/pt/test_gns_vpn.c | |||
@@ -560,7 +560,7 @@ identity_cb (void *cls, | |||
560 | void **ctx, | 560 | void **ctx, |
561 | const char *name) | 561 | const char *name) |
562 | { | 562 | { |
563 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone_key; | 563 | const struct GNUNET_IDENTITY_PrivateKey *zone_key; |
564 | struct GNUNET_GNSRECORD_Data rd; | 564 | struct GNUNET_GNSRECORD_Data rd; |
565 | char *rd_string; | 565 | char *rd_string; |
566 | char *peername; | 566 | char *peername; |
diff --git a/src/reclaim/Makefile.am b/src/reclaim/Makefile.am index a58127abf..9463f19d9 100644 --- a/src/reclaim/Makefile.am +++ b/src/reclaim/Makefile.am | |||
@@ -103,6 +103,7 @@ gnunet_service_reclaim_SOURCES = \ | |||
103 | gnunet-service-reclaim_tickets.h | 103 | gnunet-service-reclaim_tickets.h |
104 | gnunet_service_reclaim_LDADD = \ | 104 | gnunet_service_reclaim_LDADD = \ |
105 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 105 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
106 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
106 | $(top_builddir)/src/util/libgnunetutil.la \ | 107 | $(top_builddir)/src/util/libgnunetutil.la \ |
107 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 108 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
108 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 109 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
diff --git a/src/reclaim/gnunet-reclaim.c b/src/reclaim/gnunet-reclaim.c index b9306b802..cefb66b8f 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_CRYPTO_EcdsaPrivateKey *pkey; | 155 | static const struct GNUNET_IDENTITY_PrivateKey *pkey; |
156 | 156 | ||
157 | /** | 157 | /** |
158 | * rp public key | 158 | * rp public key |
159 | */ | 159 | */ |
160 | static struct GNUNET_CRYPTO_EcdsaPublicKey rp_key; | 160 | static struct GNUNET_IDENTITY_PublicKey rp_key; |
161 | 161 | ||
162 | /** | 162 | /** |
163 | * Ticket to consume | 163 | * Ticket to consume |
@@ -261,7 +261,7 @@ store_cont (void *cls, int32_t success, const char *emsg) | |||
261 | 261 | ||
262 | static void | 262 | static void |
263 | process_attrs (void *cls, | 263 | process_attrs (void *cls, |
264 | const struct GNUNET_CRYPTO_EcdsaPublicKey *identity, | 264 | const struct GNUNET_IDENTITY_PublicKey *identity, |
265 | const struct GNUNET_RECLAIM_Attribute *attr, | 265 | const struct GNUNET_RECLAIM_Attribute *attr, |
266 | const struct GNUNET_RECLAIM_Presentation *presentation) | 266 | const struct GNUNET_RECLAIM_Presentation *presentation) |
267 | { | 267 | { |
@@ -346,7 +346,7 @@ ticket_iter (void *cls, const struct GNUNET_RECLAIM_Ticket *ticket) | |||
346 | aud = | 346 | aud = |
347 | GNUNET_STRINGS_data_to_string_alloc (&ticket->audience, | 347 | GNUNET_STRINGS_data_to_string_alloc (&ticket->audience, |
348 | sizeof(struct | 348 | sizeof(struct |
349 | GNUNET_CRYPTO_EcdsaPublicKey)); | 349 | GNUNET_IDENTITY_PublicKey)); |
350 | ref = GNUNET_STRINGS_data_to_string_alloc (&ticket->rnd, sizeof(ticket->rnd)); | 350 | ref = GNUNET_STRINGS_data_to_string_alloc (&ticket->rnd, sizeof(ticket->rnd)); |
351 | tkt = | 351 | tkt = |
352 | GNUNET_STRINGS_data_to_string_alloc (ticket, | 352 | GNUNET_STRINGS_data_to_string_alloc (ticket, |
@@ -511,7 +511,7 @@ iter_finished (void *cls) | |||
511 | 511 | ||
512 | static void | 512 | static void |
513 | iter_cb (void *cls, | 513 | iter_cb (void *cls, |
514 | const struct GNUNET_CRYPTO_EcdsaPublicKey *identity, | 514 | const struct GNUNET_IDENTITY_PublicKey *identity, |
515 | const struct GNUNET_RECLAIM_Attribute *attr) | 515 | const struct GNUNET_RECLAIM_Attribute *attr) |
516 | { | 516 | { |
517 | struct GNUNET_RECLAIM_AttributeListEntry *le; | 517 | struct GNUNET_RECLAIM_AttributeListEntry *le; |
@@ -653,7 +653,7 @@ cred_iter_finished (void *cls) | |||
653 | 653 | ||
654 | static void | 654 | static void |
655 | cred_iter_cb (void *cls, | 655 | cred_iter_cb (void *cls, |
656 | const struct GNUNET_CRYPTO_EcdsaPublicKey *identity, | 656 | const struct GNUNET_IDENTITY_PublicKey *identity, |
657 | const struct GNUNET_RECLAIM_Credential *cred) | 657 | const struct GNUNET_RECLAIM_Credential *cred) |
658 | { | 658 | { |
659 | char *cred_str; | 659 | char *cred_str; |
@@ -734,7 +734,7 @@ start_process () | |||
734 | 734 | ||
735 | if ((NULL != rp) && | 735 | if ((NULL != rp) && |
736 | (GNUNET_OK != | 736 | (GNUNET_OK != |
737 | GNUNET_CRYPTO_ecdsa_public_key_from_string (rp, strlen (rp), &rp_key)) ) | 737 | GNUNET_IDENTITY_public_key_from_string (rp, &rp_key)) ) |
738 | { | 738 | { |
739 | fprintf (stderr, "%s is not a public key!\n", rp); | 739 | fprintf (stderr, "%s is not a public key!\n", rp); |
740 | cleanup_task = GNUNET_SCHEDULER_add_now (&do_cleanup, NULL); | 740 | 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 d2cdc62a2..0774fecea 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_CRYPTO_EcdsaPrivateKey identity; | 113 | struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey identity; | 269 | struct GNUNET_IDENTITY_PrivateKey identity; |
270 | 270 | ||
271 | 271 | ||
272 | /** | 272 | /** |
@@ -334,12 +334,12 @@ struct AttributeStoreHandle | |||
334 | /** | 334 | /** |
335 | * Identity | 335 | * Identity |
336 | */ | 336 | */ |
337 | struct GNUNET_CRYPTO_EcdsaPrivateKey identity; | 337 | struct GNUNET_IDENTITY_PrivateKey identity; |
338 | 338 | ||
339 | /** | 339 | /** |
340 | * Identity pubkey | 340 | * Identity pubkey |
341 | */ | 341 | */ |
342 | struct GNUNET_CRYPTO_EcdsaPublicKey identity_pkey; | 342 | struct GNUNET_IDENTITY_PublicKey identity_pkey; |
343 | 343 | ||
344 | /** | 344 | /** |
345 | * QueueEntry | 345 | * QueueEntry |
@@ -862,7 +862,7 @@ handle_revoke_ticket_message (void *cls, const struct RevokeTicketMessage *rm) | |||
862 | */ | 862 | */ |
863 | static void | 863 | static void |
864 | consume_result_cb (void *cls, | 864 | consume_result_cb (void *cls, |
865 | const struct GNUNET_CRYPTO_EcdsaPublicKey *identity, | 865 | const struct GNUNET_IDENTITY_PublicKey *identity, |
866 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 866 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
867 | const struct GNUNET_RECLAIM_PresentationList *presentations, | 867 | const struct GNUNET_RECLAIM_PresentationList *presentations, |
868 | int32_t success, | 868 | int32_t success, |
@@ -1082,7 +1082,7 @@ handle_attribute_store_message (void *cls, | |||
1082 | ash->r_id = ntohl (sam->id); | 1082 | ash->r_id = ntohl (sam->id); |
1083 | ash->identity = sam->identity; | 1083 | ash->identity = sam->identity; |
1084 | ash->exp.rel_value_us = GNUNET_ntohll (sam->exp); | 1084 | ash->exp.rel_value_us = GNUNET_ntohll (sam->exp); |
1085 | GNUNET_CRYPTO_ecdsa_key_get_public (&sam->identity, &ash->identity_pkey); | 1085 | GNUNET_IDENTITY_key_get_public (&sam->identity, &ash->identity_pkey); |
1086 | 1086 | ||
1087 | GNUNET_SERVICE_client_continue (idp->client); | 1087 | GNUNET_SERVICE_client_continue (idp->client); |
1088 | ash->client = idp; | 1088 | ash->client = idp; |
@@ -1157,7 +1157,7 @@ cred_error (void *cls) | |||
1157 | */ | 1157 | */ |
1158 | static void | 1158 | static void |
1159 | cred_add_cb (void *cls, | 1159 | cred_add_cb (void *cls, |
1160 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 1160 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
1161 | const char *label, | 1161 | const char *label, |
1162 | unsigned int rd_count, | 1162 | unsigned int rd_count, |
1163 | const struct GNUNET_GNSRECORD_Data *rd) | 1163 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1266,7 +1266,7 @@ handle_credential_store_message (void *cls, | |||
1266 | ash->r_id = ntohl (sam->id); | 1266 | ash->r_id = ntohl (sam->id); |
1267 | ash->identity = sam->identity; | 1267 | ash->identity = sam->identity; |
1268 | ash->exp.rel_value_us = GNUNET_ntohll (sam->exp); | 1268 | ash->exp.rel_value_us = GNUNET_ntohll (sam->exp); |
1269 | GNUNET_CRYPTO_ecdsa_key_get_public (&sam->identity, &ash->identity_pkey); | 1269 | GNUNET_IDENTITY_key_get_public (&sam->identity, &ash->identity_pkey); |
1270 | 1270 | ||
1271 | GNUNET_SERVICE_client_continue (idp->client); | 1271 | GNUNET_SERVICE_client_continue (idp->client); |
1272 | ash->client = idp; | 1272 | ash->client = idp; |
@@ -1311,7 +1311,7 @@ send_delete_response (struct AttributeDeleteHandle *adh, int32_t success) | |||
1311 | */ | 1311 | */ |
1312 | static void | 1312 | static void |
1313 | ticket_iter (void *cls, | 1313 | ticket_iter (void *cls, |
1314 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 1314 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
1315 | const char *label, | 1315 | const char *label, |
1316 | unsigned int rd_count, | 1316 | unsigned int rd_count, |
1317 | const struct GNUNET_GNSRECORD_Data *rd) | 1317 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1739,7 +1739,7 @@ attr_iter_error (void *cls) | |||
1739 | */ | 1739 | */ |
1740 | static void | 1740 | static void |
1741 | attr_iter_cb (void *cls, | 1741 | attr_iter_cb (void *cls, |
1742 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 1742 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
1743 | const char *label, | 1743 | const char *label, |
1744 | unsigned int rd_count, | 1744 | unsigned int rd_count, |
1745 | const struct GNUNET_GNSRECORD_Data *rd) | 1745 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1764,7 +1764,7 @@ attr_iter_cb (void *cls, | |||
1764 | GNUNET_MESSAGE_TYPE_RECLAIM_ATTRIBUTE_RESULT); | 1764 | GNUNET_MESSAGE_TYPE_RECLAIM_ATTRIBUTE_RESULT); |
1765 | arm->id = htonl (ai->request_id); | 1765 | arm->id = htonl (ai->request_id); |
1766 | arm->attr_len = htons (rd->data_size); | 1766 | arm->attr_len = htons (rd->data_size); |
1767 | GNUNET_CRYPTO_ecdsa_key_get_public (zone, &arm->identity); | 1767 | GNUNET_IDENTITY_key_get_public (zone, &arm->identity); |
1768 | data_tmp = (char *) &arm[1]; | 1768 | data_tmp = (char *) &arm[1]; |
1769 | GNUNET_memcpy (data_tmp, rd->data, rd->data_size); | 1769 | GNUNET_memcpy (data_tmp, rd->data, rd->data_size); |
1770 | GNUNET_MQ_send (ai->client->mq, env); | 1770 | GNUNET_MQ_send (ai->client->mq, env); |
@@ -1923,7 +1923,7 @@ cred_iter_error (void *cls) | |||
1923 | */ | 1923 | */ |
1924 | static void | 1924 | static void |
1925 | cred_iter_cb (void *cls, | 1925 | cred_iter_cb (void *cls, |
1926 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 1926 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
1927 | const char *label, | 1927 | const char *label, |
1928 | unsigned int rd_count, | 1928 | unsigned int rd_count, |
1929 | const struct GNUNET_GNSRECORD_Data *rd) | 1929 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1948,7 +1948,7 @@ cred_iter_cb (void *cls, | |||
1948 | GNUNET_MESSAGE_TYPE_RECLAIM_CREDENTIAL_RESULT); | 1948 | GNUNET_MESSAGE_TYPE_RECLAIM_CREDENTIAL_RESULT); |
1949 | arm->id = htonl (ai->request_id); | 1949 | arm->id = htonl (ai->request_id); |
1950 | arm->credential_len = htons (rd->data_size); | 1950 | arm->credential_len = htons (rd->data_size); |
1951 | GNUNET_CRYPTO_ecdsa_key_get_public (zone, &arm->identity); | 1951 | GNUNET_IDENTITY_key_get_public (zone, &arm->identity); |
1952 | data_tmp = (char *) &arm[1]; | 1952 | data_tmp = (char *) &arm[1]; |
1953 | GNUNET_memcpy (data_tmp, rd->data, rd->data_size); | 1953 | GNUNET_memcpy (data_tmp, rd->data, rd->data_size); |
1954 | 1954 | ||
diff --git a/src/reclaim/gnunet-service-reclaim_tickets.c b/src/reclaim/gnunet-service-reclaim_tickets.c index 4dd8100f9..0b1730bec 100644 --- a/src/reclaim/gnunet-service-reclaim_tickets.c +++ b/src/reclaim/gnunet-service-reclaim_tickets.c | |||
@@ -86,12 +86,12 @@ struct RECLAIM_TICKETS_ConsumeHandle | |||
86 | /** | 86 | /** |
87 | * Audience Key | 87 | * Audience Key |
88 | */ | 88 | */ |
89 | struct GNUNET_CRYPTO_EcdsaPrivateKey identity; | 89 | struct GNUNET_IDENTITY_PrivateKey identity; |
90 | 90 | ||
91 | /** | 91 | /** |
92 | * Audience Key | 92 | * Audience Key |
93 | */ | 93 | */ |
94 | struct GNUNET_CRYPTO_EcdsaPublicKey identity_pub; | 94 | struct GNUNET_IDENTITY_PublicKey identity_pub; |
95 | 95 | ||
96 | /** | 96 | /** |
97 | * Lookup DLL | 97 | * Lookup DLL |
@@ -180,7 +180,7 @@ struct TicketIssueHandle | |||
180 | /** | 180 | /** |
181 | * Issuer Key | 181 | * Issuer Key |
182 | */ | 182 | */ |
183 | struct GNUNET_CRYPTO_EcdsaPrivateKey identity; | 183 | struct GNUNET_IDENTITY_PrivateKey identity; |
184 | 184 | ||
185 | /** | 185 | /** |
186 | * Ticket to issue | 186 | * Ticket to issue |
@@ -263,7 +263,7 @@ struct RECLAIM_TICKETS_RevokeHandle | |||
263 | /** | 263 | /** |
264 | * Issuer Key | 264 | * Issuer Key |
265 | */ | 265 | */ |
266 | struct GNUNET_CRYPTO_EcdsaPrivateKey identity; | 266 | struct GNUNET_IDENTITY_PrivateKey identity; |
267 | 267 | ||
268 | /** | 268 | /** |
269 | * Callback | 269 | * Callback |
@@ -490,7 +490,7 @@ rvk_ticket_update_finished (void *cls) | |||
490 | */ | 490 | */ |
491 | static void | 491 | static void |
492 | rvk_ticket_update (void *cls, | 492 | rvk_ticket_update (void *cls, |
493 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 493 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
494 | const char *label, | 494 | const char *label, |
495 | unsigned int rd_count, | 495 | unsigned int rd_count, |
496 | const struct GNUNET_GNSRECORD_Data *rd) | 496 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -665,7 +665,7 @@ move_attr_finished (void *cls, int32_t success, const char *emsg) | |||
665 | */ | 665 | */ |
666 | static void | 666 | static void |
667 | rvk_move_attr_cb (void *cls, | 667 | rvk_move_attr_cb (void *cls, |
668 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 668 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
669 | const char *label, | 669 | const char *label, |
670 | unsigned int rd_count, | 670 | unsigned int rd_count, |
671 | const struct GNUNET_GNSRECORD_Data *rd) | 671 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -850,7 +850,7 @@ remove_ticket_cont (void *cls, int32_t success, const char *emsg) | |||
850 | */ | 850 | */ |
851 | static void | 851 | static void |
852 | revoke_attrs_cb (void *cls, | 852 | revoke_attrs_cb (void *cls, |
853 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 853 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
854 | const char *label, | 854 | const char *label, |
855 | unsigned int rd_count, | 855 | unsigned int rd_count, |
856 | const struct GNUNET_GNSRECORD_Data *rd) | 856 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -913,7 +913,7 @@ rvk_attrs_err_cb (void *cls) | |||
913 | */ | 913 | */ |
914 | struct RECLAIM_TICKETS_RevokeHandle * | 914 | struct RECLAIM_TICKETS_RevokeHandle * |
915 | RECLAIM_TICKETS_revoke (const struct GNUNET_RECLAIM_Ticket *ticket, | 915 | RECLAIM_TICKETS_revoke (const struct GNUNET_RECLAIM_Ticket *ticket, |
916 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity, | 916 | const struct GNUNET_IDENTITY_PrivateKey *identity, |
917 | RECLAIM_TICKETS_RevokeCallback cb, | 917 | RECLAIM_TICKETS_RevokeCallback cb, |
918 | void *cb_cls) | 918 | void *cb_cls) |
919 | { | 919 | { |
@@ -925,7 +925,7 @@ RECLAIM_TICKETS_revoke (const struct GNUNET_RECLAIM_Ticket *ticket, | |||
925 | rvk->cb_cls = cb_cls; | 925 | rvk->cb_cls = cb_cls; |
926 | rvk->identity = *identity; | 926 | rvk->identity = *identity; |
927 | rvk->ticket = *ticket; | 927 | rvk->ticket = *ticket; |
928 | GNUNET_CRYPTO_ecdsa_key_get_public (&rvk->identity, &rvk->ticket.identity); | 928 | GNUNET_IDENTITY_key_get_public (&rvk->identity, &rvk->ticket.identity); |
929 | /** Get shared attributes **/ | 929 | /** Get shared attributes **/ |
930 | label = GNUNET_STRINGS_data_to_string_alloc (&ticket->rnd, | 930 | label = GNUNET_STRINGS_data_to_string_alloc (&ticket->rnd, |
931 | sizeof(ticket->rnd)); | 931 | sizeof(ticket->rnd)); |
@@ -1184,7 +1184,7 @@ lookup_authz_cb (void *cls, | |||
1184 | * @return handle to the operation | 1184 | * @return handle to the operation |
1185 | */ | 1185 | */ |
1186 | struct RECLAIM_TICKETS_ConsumeHandle * | 1186 | struct RECLAIM_TICKETS_ConsumeHandle * |
1187 | RECLAIM_TICKETS_consume (const struct GNUNET_CRYPTO_EcdsaPrivateKey *id, | 1187 | RECLAIM_TICKETS_consume (const struct GNUNET_IDENTITY_PrivateKey *id, |
1188 | const struct GNUNET_RECLAIM_Ticket *ticket, | 1188 | const struct GNUNET_RECLAIM_Ticket *ticket, |
1189 | RECLAIM_TICKETS_ConsumeCallback cb, | 1189 | RECLAIM_TICKETS_ConsumeCallback cb, |
1190 | void *cb_cls) | 1190 | void *cb_cls) |
@@ -1195,7 +1195,7 @@ RECLAIM_TICKETS_consume (const struct GNUNET_CRYPTO_EcdsaPrivateKey *id, | |||
1195 | cth = GNUNET_new (struct RECLAIM_TICKETS_ConsumeHandle); | 1195 | cth = GNUNET_new (struct RECLAIM_TICKETS_ConsumeHandle); |
1196 | 1196 | ||
1197 | cth->identity = *id; | 1197 | cth->identity = *id; |
1198 | GNUNET_CRYPTO_ecdsa_key_get_public (&cth->identity, &cth->identity_pub); | 1198 | GNUNET_IDENTITY_key_get_public (&cth->identity, &cth->identity_pub); |
1199 | cth->attrs = GNUNET_new (struct GNUNET_RECLAIM_AttributeList); | 1199 | cth->attrs = GNUNET_new (struct GNUNET_RECLAIM_AttributeList); |
1200 | cth->presentations = GNUNET_new (struct GNUNET_RECLAIM_PresentationList); | 1200 | cth->presentations = GNUNET_new (struct GNUNET_RECLAIM_PresentationList); |
1201 | cth->ticket = *ticket; | 1201 | cth->ticket = *ticket; |
@@ -1453,7 +1453,7 @@ filter_tickets_error_cb (void *cls) | |||
1453 | */ | 1453 | */ |
1454 | static void | 1454 | static void |
1455 | filter_tickets_cb (void *cls, | 1455 | filter_tickets_cb (void *cls, |
1456 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 1456 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
1457 | const char *label, | 1457 | const char *label, |
1458 | unsigned int rd_count, | 1458 | unsigned int rd_count, |
1459 | const struct GNUNET_GNSRECORD_Data *rd) | 1459 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1489,7 +1489,7 @@ filter_tickets_cb (void *cls, | |||
1489 | // cmp audience | 1489 | // cmp audience |
1490 | if (0 == memcmp (&tih->ticket.audience, | 1490 | if (0 == memcmp (&tih->ticket.audience, |
1491 | &ticket->audience, | 1491 | &ticket->audience, |
1492 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey))) | 1492 | sizeof(struct GNUNET_IDENTITY_PublicKey))) |
1493 | { | 1493 | { |
1494 | tih->ticket = *ticket; | 1494 | tih->ticket = *ticket; |
1495 | continue; | 1495 | continue; |
@@ -1602,7 +1602,7 @@ filter_tickets_finished_cb (void *cls) | |||
1602 | { | 1602 | { |
1603 | struct TicketIssueHandle *tih = cls; | 1603 | struct TicketIssueHandle *tih = cls; |
1604 | 1604 | ||
1605 | GNUNET_CRYPTO_ecdsa_key_get_public (&tih->identity, &tih->ticket.identity); | 1605 | GNUNET_IDENTITY_key_get_public (&tih->identity, &tih->ticket.identity); |
1606 | GNUNET_RECLAIM_id_generate (&tih->ticket.rnd); | 1606 | GNUNET_RECLAIM_id_generate (&tih->ticket.rnd); |
1607 | issue_ticket (tih); | 1607 | issue_ticket (tih); |
1608 | } | 1608 | } |
@@ -1620,9 +1620,9 @@ filter_tickets_finished_cb (void *cls) | |||
1620 | * FIXME: Return handle?? | 1620 | * FIXME: Return handle?? |
1621 | */ | 1621 | */ |
1622 | void | 1622 | void |
1623 | RECLAIM_TICKETS_issue (const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity, | 1623 | RECLAIM_TICKETS_issue (const struct GNUNET_IDENTITY_PrivateKey *identity, |
1624 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 1624 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
1625 | const struct GNUNET_CRYPTO_EcdsaPublicKey *audience, | 1625 | const struct GNUNET_IDENTITY_PublicKey *audience, |
1626 | RECLAIM_TICKETS_TicketResult cb, | 1626 | RECLAIM_TICKETS_TicketResult cb, |
1627 | void *cb_cls) | 1627 | void *cb_cls) |
1628 | { | 1628 | { |
@@ -1680,7 +1680,7 @@ cleanup_iter (struct RECLAIM_TICKETS_Iterator *iter) | |||
1680 | */ | 1680 | */ |
1681 | static void | 1681 | static void |
1682 | collect_tickets_cb (void *cls, | 1682 | collect_tickets_cb (void *cls, |
1683 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 1683 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
1684 | const char *label, | 1684 | const char *label, |
1685 | unsigned int rd_count, | 1685 | unsigned int rd_count, |
1686 | const struct GNUNET_GNSRECORD_Data *rd) | 1686 | const struct GNUNET_GNSRECORD_Data *rd) |
@@ -1765,7 +1765,7 @@ RECLAIM_TICKETS_iteration_stop (struct RECLAIM_TICKETS_Iterator *iter) | |||
1765 | */ | 1765 | */ |
1766 | struct RECLAIM_TICKETS_Iterator * | 1766 | struct RECLAIM_TICKETS_Iterator * |
1767 | RECLAIM_TICKETS_iteration_start ( | 1767 | RECLAIM_TICKETS_iteration_start ( |
1768 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity, | 1768 | const struct GNUNET_IDENTITY_PrivateKey *identity, |
1769 | RECLAIM_TICKETS_TicketIter cb, | 1769 | RECLAIM_TICKETS_TicketIter cb, |
1770 | void *cb_cls) | 1770 | void *cb_cls) |
1771 | { | 1771 | { |
diff --git a/src/reclaim/gnunet-service-reclaim_tickets.h b/src/reclaim/gnunet-service-reclaim_tickets.h index 0dd790fc7..9c31a6143 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_CRYPTO_EcdsaPublicKey *identity, | 141 | const struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey *identity, | 170 | const struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey *id, | 196 | RECLAIM_TICKETS_consume (const struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey *identity, | 223 | RECLAIM_TICKETS_issue (const struct GNUNET_IDENTITY_PrivateKey *identity, |
224 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 224 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
225 | const struct GNUNET_CRYPTO_EcdsaPublicKey *audience, | 225 | const struct GNUNET_IDENTITY_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_CRYPTO_EcdsaPrivateKey *identity, | 258 | const struct GNUNET_IDENTITY_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 b307a358c..c6d56e02d 100644 --- a/src/reclaim/oidc_helper.c +++ b/src/reclaim/oidc_helper.c | |||
@@ -154,10 +154,12 @@ fix_base64 (char *str) | |||
154 | replace_char (str, '/', '_'); | 154 | replace_char (str, '/', '_'); |
155 | } | 155 | } |
156 | 156 | ||
157 | |||
157 | static json_t* | 158 | static json_t* |
158 | generate_userinfo_json(const struct GNUNET_CRYPTO_EcdsaPublicKey *sub_key, | 159 | generate_userinfo_json (const struct GNUNET_IDENTITY_PublicKey *sub_key, |
159 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 160 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
160 | const struct GNUNET_RECLAIM_PresentationList *presentations) | 161 | const struct |
162 | GNUNET_RECLAIM_PresentationList *presentations) | ||
161 | { | 163 | { |
162 | struct GNUNET_RECLAIM_AttributeListEntry *le; | 164 | struct GNUNET_RECLAIM_AttributeListEntry *le; |
163 | struct GNUNET_RECLAIM_PresentationListEntry *ple; | 165 | struct GNUNET_RECLAIM_PresentationListEntry *ple; |
@@ -180,7 +182,7 @@ generate_userinfo_json(const struct GNUNET_CRYPTO_EcdsaPublicKey *sub_key, | |||
180 | subject = | 182 | subject = |
181 | GNUNET_STRINGS_data_to_string_alloc (sub_key, | 183 | GNUNET_STRINGS_data_to_string_alloc (sub_key, |
182 | sizeof(struct | 184 | sizeof(struct |
183 | GNUNET_CRYPTO_EcdsaPublicKey)); | 185 | GNUNET_IDENTITY_PublicKey)); |
184 | body = json_object (); | 186 | body = json_object (); |
185 | aggr_names = json_object (); | 187 | aggr_names = json_object (); |
186 | aggr_sources = json_object (); | 188 | aggr_sources = json_object (); |
@@ -206,7 +208,8 @@ generate_userinfo_json(const struct GNUNET_CRYPTO_EcdsaPublicKey *sub_key, | |||
206 | ple->presentation->data, | 208 | ple->presentation->data, |
207 | ple->presentation->data_size); | 209 | ple->presentation->data_size); |
208 | json_object_set_new (aggr_sources_jwt, | 210 | json_object_set_new (aggr_sources_jwt, |
209 | GNUNET_RECLAIM_presentation_number_to_typename (ple->presentation->type), | 211 | GNUNET_RECLAIM_presentation_number_to_typename ( |
212 | ple->presentation->type), | ||
210 | json_string (pres_val_str) ); | 213 | json_string (pres_val_str) ); |
211 | json_object_set_new (aggr_sources, source_name, aggr_sources_jwt); | 214 | json_object_set_new (aggr_sources, source_name, aggr_sources_jwt); |
212 | GNUNET_free (pres_val_str); | 215 | GNUNET_free (pres_val_str); |
@@ -286,6 +289,7 @@ generate_userinfo_json(const struct GNUNET_CRYPTO_EcdsaPublicKey *sub_key, | |||
286 | return body; | 289 | return body; |
287 | } | 290 | } |
288 | 291 | ||
292 | |||
289 | /** | 293 | /** |
290 | * Generate userinfo JSON as string | 294 | * Generate userinfo JSON as string |
291 | * | 295 | * |
@@ -295,14 +299,15 @@ generate_userinfo_json(const struct GNUNET_CRYPTO_EcdsaPublicKey *sub_key, | |||
295 | * @return Userinfo JSON | 299 | * @return Userinfo JSON |
296 | */ | 300 | */ |
297 | char * | 301 | char * |
298 | OIDC_generate_userinfo (const struct GNUNET_CRYPTO_EcdsaPublicKey *sub_key, | 302 | OIDC_generate_userinfo (const struct GNUNET_IDENTITY_PublicKey *sub_key, |
299 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 303 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
300 | const struct GNUNET_RECLAIM_PresentationList *presentations) | 304 | const struct |
305 | GNUNET_RECLAIM_PresentationList *presentations) | ||
301 | { | 306 | { |
302 | char *body_str; | 307 | char *body_str; |
303 | json_t* body = generate_userinfo_json (sub_key, | 308 | json_t*body = generate_userinfo_json (sub_key, |
304 | attrs, | 309 | attrs, |
305 | presentations); | 310 | presentations); |
306 | body_str = json_dumps (body, JSON_INDENT (0) | JSON_COMPACT); | 311 | body_str = json_dumps (body, JSON_INDENT (0) | JSON_COMPACT); |
307 | json_decref (body); | 312 | json_decref (body); |
308 | return body_str; | 313 | return body_str; |
@@ -321,10 +326,11 @@ OIDC_generate_userinfo (const struct GNUNET_CRYPTO_EcdsaPublicKey *sub_key, | |||
321 | * @return a new base64-encoded JWT string. | 326 | * @return a new base64-encoded JWT string. |
322 | */ | 327 | */ |
323 | char * | 328 | char * |
324 | OIDC_generate_id_token (const struct GNUNET_CRYPTO_EcdsaPublicKey *aud_key, | 329 | OIDC_generate_id_token (const struct GNUNET_IDENTITY_PublicKey *aud_key, |
325 | const struct GNUNET_CRYPTO_EcdsaPublicKey *sub_key, | 330 | const struct GNUNET_IDENTITY_PublicKey *sub_key, |
326 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 331 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
327 | const struct GNUNET_RECLAIM_PresentationList *presentations, | 332 | const struct |
333 | GNUNET_RECLAIM_PresentationList *presentations, | ||
328 | const struct GNUNET_TIME_Relative *expiration_time, | 334 | const struct GNUNET_TIME_Relative *expiration_time, |
329 | const char *nonce, | 335 | const char *nonce, |
330 | const char *secret_key) | 336 | const char *secret_key) |
@@ -356,11 +362,11 @@ OIDC_generate_id_token (const struct GNUNET_CRYPTO_EcdsaPublicKey *aud_key, | |||
356 | subject = | 362 | subject = |
357 | GNUNET_STRINGS_data_to_string_alloc (sub_key, | 363 | GNUNET_STRINGS_data_to_string_alloc (sub_key, |
358 | sizeof(struct | 364 | sizeof(struct |
359 | GNUNET_CRYPTO_EcdsaPublicKey)); | 365 | GNUNET_IDENTITY_PublicKey)); |
360 | audience = | 366 | audience = |
361 | GNUNET_STRINGS_data_to_string_alloc (aud_key, | 367 | GNUNET_STRINGS_data_to_string_alloc (aud_key, |
362 | sizeof(struct | 368 | sizeof(struct |
363 | GNUNET_CRYPTO_EcdsaPublicKey)); | 369 | GNUNET_IDENTITY_PublicKey)); |
364 | header = create_jwt_header (); | 370 | header = create_jwt_header (); |
365 | 371 | ||
366 | // aud REQUIRED public key client_id must be there | 372 | // aud REQUIRED public key client_id must be there |
@@ -438,10 +444,11 @@ OIDC_generate_id_token (const struct GNUNET_CRYPTO_EcdsaPublicKey *aud_key, | |||
438 | * @return a new authorization code (caller must free) | 444 | * @return a new authorization code (caller must free) |
439 | */ | 445 | */ |
440 | char * | 446 | char * |
441 | OIDC_build_authz_code (const struct GNUNET_CRYPTO_EcdsaPrivateKey *issuer, | 447 | OIDC_build_authz_code (const struct GNUNET_IDENTITY_PrivateKey *issuer, |
442 | const struct GNUNET_RECLAIM_Ticket *ticket, | 448 | const struct GNUNET_RECLAIM_Ticket *ticket, |
443 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 449 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
444 | const struct GNUNET_RECLAIM_PresentationList *presentations, | 450 | const struct |
451 | GNUNET_RECLAIM_PresentationList *presentations, | ||
445 | const char *nonce_str, | 452 | const char *nonce_str, |
446 | const char *code_challenge) | 453 | const char *code_challenge) |
447 | { | 454 | { |
@@ -525,7 +532,7 @@ OIDC_build_authz_code (const struct GNUNET_CRYPTO_EcdsaPrivateKey *issuer, | |||
525 | // Get length | 532 | // Get length |
526 | code_payload_len = sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) | 533 | code_payload_len = sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) |
527 | + payload_len + sizeof(struct | 534 | + payload_len + sizeof(struct |
528 | GNUNET_CRYPTO_EcdsaSignature); | 535 | GNUNET_IDENTITY_Signature); |
529 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 536 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
530 | "Length of data to encode: %lu\n", | 537 | "Length of data to encode: %lu\n", |
531 | code_payload_len); | 538 | code_payload_len); |
@@ -544,10 +551,10 @@ OIDC_build_authz_code (const struct GNUNET_CRYPTO_EcdsaPrivateKey *issuer, | |||
544 | buf_ptr += payload_len; | 551 | buf_ptr += payload_len; |
545 | // Sign and store signature | 552 | // Sign and store signature |
546 | if (GNUNET_SYSERR == | 553 | if (GNUNET_SYSERR == |
547 | GNUNET_CRYPTO_ecdsa_sign_ (issuer, | 554 | GNUNET_IDENTITY_sign_ (issuer, |
548 | purpose, | 555 | purpose, |
549 | (struct GNUNET_CRYPTO_EcdsaSignature *) | 556 | (struct GNUNET_IDENTITY_Signature *) |
550 | buf_ptr)) | 557 | buf_ptr)) |
551 | { | 558 | { |
552 | GNUNET_break (0); | 559 | GNUNET_break (0); |
553 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Unable to sign code\n"); | 560 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Unable to sign code\n"); |
@@ -576,7 +583,7 @@ OIDC_build_authz_code (const struct GNUNET_CRYPTO_EcdsaPrivateKey *issuer, | |||
576 | * @return GNUNET_OK if successful, else GNUNET_SYSERR | 583 | * @return GNUNET_OK if successful, else GNUNET_SYSERR |
577 | */ | 584 | */ |
578 | int | 585 | int |
579 | OIDC_parse_authz_code (const struct GNUNET_CRYPTO_EcdsaPublicKey *audience, | 586 | OIDC_parse_authz_code (const struct GNUNET_IDENTITY_PublicKey *audience, |
580 | const char *code, | 587 | const char *code, |
581 | const char *code_verifier, | 588 | const char *code_verifier, |
582 | struct GNUNET_RECLAIM_Ticket *ticket, | 589 | struct GNUNET_RECLAIM_Ticket *ticket, |
@@ -593,7 +600,7 @@ OIDC_parse_authz_code (const struct GNUNET_CRYPTO_EcdsaPublicKey *audience, | |||
593 | char *code_challenge; | 600 | char *code_challenge; |
594 | char *code_verifier_hash; | 601 | char *code_verifier_hash; |
595 | struct GNUNET_CRYPTO_EccSignaturePurpose *purpose; | 602 | struct GNUNET_CRYPTO_EccSignaturePurpose *purpose; |
596 | struct GNUNET_CRYPTO_EcdsaSignature *signature; | 603 | struct GNUNET_IDENTITY_Signature *signature; |
597 | uint32_t code_challenge_len; | 604 | uint32_t code_challenge_len; |
598 | uint32_t attrs_ser_len; | 605 | uint32_t attrs_ser_len; |
599 | uint32_t pres_ser_len; | 606 | uint32_t pres_ser_len; |
@@ -609,7 +616,7 @@ OIDC_parse_authz_code (const struct GNUNET_CRYPTO_EcdsaPublicKey *audience, | |||
609 | (void **) &code_payload); | 616 | (void **) &code_payload); |
610 | if (code_payload_len < sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) | 617 | if (code_payload_len < sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) |
611 | + sizeof(struct OIDC_Parameters) | 618 | + sizeof(struct OIDC_Parameters) |
612 | + sizeof(struct GNUNET_CRYPTO_EcdsaSignature)) | 619 | + sizeof(struct GNUNET_IDENTITY_Signature)) |
613 | { | 620 | { |
614 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Authorization code malformed\n"); | 621 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Authorization code malformed\n"); |
615 | GNUNET_free (code_payload); | 622 | GNUNET_free (code_payload); |
@@ -620,10 +627,10 @@ OIDC_parse_authz_code (const struct GNUNET_CRYPTO_EcdsaPublicKey *audience, | |||
620 | plaintext_len = code_payload_len; | 627 | plaintext_len = code_payload_len; |
621 | plaintext_len -= sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose); | 628 | plaintext_len -= sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose); |
622 | ptr = (char *) &purpose[1]; | 629 | ptr = (char *) &purpose[1]; |
623 | plaintext_len -= sizeof(struct GNUNET_CRYPTO_EcdsaSignature); | 630 | plaintext_len -= sizeof(struct GNUNET_IDENTITY_Signature); |
624 | plaintext = ptr; | 631 | plaintext = ptr; |
625 | ptr += plaintext_len; | 632 | ptr += plaintext_len; |
626 | signature = (struct GNUNET_CRYPTO_EcdsaSignature *) ptr; | 633 | signature = (struct GNUNET_IDENTITY_Signature *) ptr; |
627 | params = (struct OIDC_Parameters *) plaintext; | 634 | params = (struct OIDC_Parameters *) plaintext; |
628 | 635 | ||
629 | // cmp code_challenge code_verifier | 636 | // cmp code_challenge code_verifier |
@@ -684,10 +691,11 @@ OIDC_parse_authz_code (const struct GNUNET_CRYPTO_EcdsaPublicKey *audience, | |||
684 | return GNUNET_SYSERR; | 691 | return GNUNET_SYSERR; |
685 | } | 692 | } |
686 | if (GNUNET_OK != | 693 | if (GNUNET_OK != |
687 | GNUNET_CRYPTO_ecdsa_verify_ (GNUNET_SIGNATURE_PURPOSE_RECLAIM_CODE_SIGN, | 694 | GNUNET_IDENTITY_signature_verify_ ( |
688 | purpose, | 695 | GNUNET_SIGNATURE_PURPOSE_RECLAIM_CODE_SIGN, |
689 | signature, | 696 | purpose, |
690 | &ticket->identity)) | 697 | signature, |
698 | &(ticket->identity))) | ||
691 | { | 699 | { |
692 | GNUNET_free (code_payload); | 700 | GNUNET_free (code_payload); |
693 | if (NULL != *nonce_str) | 701 | if (NULL != *nonce_str) |
@@ -840,7 +848,8 @@ OIDC_check_scopes_for_claim_request (const char*scopes, | |||
840 | } | 848 | } |
841 | } | 849 | } |
842 | 850 | ||
843 | } else if (0 == strcmp (attr, scope_variable)) | 851 | } |
852 | else if (0 == strcmp (attr, scope_variable)) | ||
844 | { | 853 | { |
845 | /** attribute matches requested scope **/ | 854 | /** attribute matches requested scope **/ |
846 | GNUNET_free (scope_variables); | 855 | GNUNET_free (scope_variables); |
diff --git a/src/reclaim/oidc_helper.h b/src/reclaim/oidc_helper.h index 10a6f3d1f..eb1022423 100644 --- a/src/reclaim/oidc_helper.h +++ b/src/reclaim/oidc_helper.h | |||
@@ -50,8 +50,8 @@ | |||
50 | * @return a new base64-encoded JWT string. | 50 | * @return a new base64-encoded JWT string. |
51 | */ | 51 | */ |
52 | char* | 52 | char* |
53 | OIDC_generate_id_token (const struct GNUNET_CRYPTO_EcdsaPublicKey *aud_key, | 53 | OIDC_generate_id_token (const struct GNUNET_IDENTITY_PublicKey *aud_key, |
54 | const struct GNUNET_CRYPTO_EcdsaPublicKey *sub_key, | 54 | const struct GNUNET_IDENTITY_PublicKey *sub_key, |
55 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 55 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
56 | const struct GNUNET_RECLAIM_PresentationList *presentations, | 56 | const struct GNUNET_RECLAIM_PresentationList *presentations, |
57 | const struct GNUNET_TIME_Relative *expiration_time, | 57 | const struct GNUNET_TIME_Relative *expiration_time, |
@@ -71,7 +71,7 @@ OIDC_generate_id_token (const struct GNUNET_CRYPTO_EcdsaPublicKey *aud_key, | |||
71 | * @return a new authorization code (caller must free) | 71 | * @return a new authorization code (caller must free) |
72 | */ | 72 | */ |
73 | char* | 73 | char* |
74 | OIDC_build_authz_code (const struct GNUNET_CRYPTO_EcdsaPrivateKey *issuer, | 74 | OIDC_build_authz_code (const struct GNUNET_IDENTITY_PrivateKey *issuer, |
75 | const struct GNUNET_RECLAIM_Ticket *ticket, | 75 | const struct GNUNET_RECLAIM_Ticket *ticket, |
76 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 76 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
77 | const struct GNUNET_RECLAIM_PresentationList *presentations, | 77 | const struct GNUNET_RECLAIM_PresentationList *presentations, |
@@ -93,7 +93,7 @@ OIDC_build_authz_code (const struct GNUNET_CRYPTO_EcdsaPrivateKey *issuer, | |||
93 | * @return GNUNET_OK if successful, else GNUNET_SYSERR | 93 | * @return GNUNET_OK if successful, else GNUNET_SYSERR |
94 | */ | 94 | */ |
95 | int | 95 | int |
96 | OIDC_parse_authz_code (const struct GNUNET_CRYPTO_EcdsaPublicKey *ecdsa_pub, | 96 | OIDC_parse_authz_code (const struct GNUNET_IDENTITY_PublicKey *ecdsa_pub, |
97 | const char *code, | 97 | const char *code, |
98 | const char *code_verifier, | 98 | const char *code_verifier, |
99 | struct GNUNET_RECLAIM_Ticket *ticket, | 99 | struct GNUNET_RECLAIM_Ticket *ticket, |
@@ -152,7 +152,7 @@ OIDC_check_scopes_for_claim_request (const char *scopes, | |||
152 | * @return Userinfo JSON | 152 | * @return Userinfo JSON |
153 | */ | 153 | */ |
154 | char * | 154 | char * |
155 | OIDC_generate_userinfo (const struct GNUNET_CRYPTO_EcdsaPublicKey *sub_key, | 155 | OIDC_generate_userinfo (const struct GNUNET_IDENTITY_PublicKey *sub_key, |
156 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 156 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
157 | const struct GNUNET_RECLAIM_PresentationList *presentations); | 157 | const struct GNUNET_RECLAIM_PresentationList *presentations); |
158 | 158 | ||
diff --git a/src/reclaim/plugin_rest_openid_connect.c b/src/reclaim/plugin_rest_openid_connect.c index 5b0bb2b6f..7a8a886bd 100644 --- a/src/reclaim/plugin_rest_openid_connect.c +++ b/src/reclaim/plugin_rest_openid_connect.c | |||
@@ -300,7 +300,7 @@ struct OIDC_Variables | |||
300 | /** | 300 | /** |
301 | * The RP client public key | 301 | * The RP client public key |
302 | */ | 302 | */ |
303 | struct GNUNET_CRYPTO_EcdsaPublicKey client_pkey; | 303 | struct GNUNET_IDENTITY_PublicKey client_pkey; |
304 | 304 | ||
305 | /** | 305 | /** |
306 | * The OIDC client id of the RP | 306 | * The OIDC client id of the RP |
@@ -411,7 +411,7 @@ struct RequestHandle | |||
411 | /** | 411 | /** |
412 | * Pointer to ego private key | 412 | * Pointer to ego private key |
413 | */ | 413 | */ |
414 | struct GNUNET_CRYPTO_EcdsaPrivateKey priv_key; | 414 | struct GNUNET_IDENTITY_PrivateKey priv_key; |
415 | 415 | ||
416 | /** | 416 | /** |
417 | * OIDC variables | 417 | * OIDC variables |
@@ -972,7 +972,7 @@ oidc_ticket_issue_cb (void *cls, | |||
972 | (NULL != handle->tld)) | 972 | (NULL != handle->tld)) |
973 | { | 973 | { |
974 | GNUNET_asprintf (&redirect_uri, | 974 | GNUNET_asprintf (&redirect_uri, |
975 | "%s.%s/%s?%s=%s&state=%s", | 975 | "%s.%s/%s%s%s=%s&state=%s", |
976 | handle->redirect_prefix, | 976 | handle->redirect_prefix, |
977 | handle->tld, | 977 | handle->tld, |
978 | handle->redirect_suffix, | 978 | handle->redirect_suffix, |
@@ -1087,7 +1087,7 @@ oidc_cred_collect_finished_cb (void *cls) | |||
1087 | */ | 1087 | */ |
1088 | static void | 1088 | static void |
1089 | oidc_cred_collect (void *cls, | 1089 | oidc_cred_collect (void *cls, |
1090 | const struct GNUNET_CRYPTO_EcdsaPublicKey *identity, | 1090 | const struct GNUNET_IDENTITY_PublicKey *identity, |
1091 | const struct GNUNET_RECLAIM_Credential *cred) | 1091 | const struct GNUNET_RECLAIM_Credential *cred) |
1092 | { | 1092 | { |
1093 | struct RequestHandle *handle = cls; | 1093 | struct RequestHandle *handle = cls; |
@@ -1211,7 +1211,7 @@ attr_in_userinfo_request (struct RequestHandle *handle, | |||
1211 | */ | 1211 | */ |
1212 | static void | 1212 | static void |
1213 | oidc_attr_collect (void *cls, | 1213 | oidc_attr_collect (void *cls, |
1214 | const struct GNUNET_CRYPTO_EcdsaPublicKey *identity, | 1214 | const struct GNUNET_IDENTITY_PublicKey *identity, |
1215 | const struct GNUNET_RECLAIM_Attribute *attr) | 1215 | const struct GNUNET_RECLAIM_Attribute *attr) |
1216 | { | 1216 | { |
1217 | struct RequestHandle *handle = cls; | 1217 | struct RequestHandle *handle = cls; |
@@ -1260,8 +1260,8 @@ code_redirect (void *cls) | |||
1260 | struct RequestHandle *handle = cls; | 1260 | struct RequestHandle *handle = cls; |
1261 | struct GNUNET_TIME_Absolute current_time; | 1261 | struct GNUNET_TIME_Absolute current_time; |
1262 | struct GNUNET_TIME_Absolute *relog_time; | 1262 | struct GNUNET_TIME_Absolute *relog_time; |
1263 | struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 1263 | struct GNUNET_IDENTITY_PublicKey pubkey; |
1264 | struct GNUNET_CRYPTO_EcdsaPublicKey ego_pkey; | 1264 | struct GNUNET_IDENTITY_PublicKey ego_pkey; |
1265 | struct GNUNET_HashCode cache_key; | 1265 | struct GNUNET_HashCode cache_key; |
1266 | char *identity_cookie; | 1266 | char *identity_cookie; |
1267 | 1267 | ||
@@ -1281,11 +1281,8 @@ code_redirect (void *cls) | |||
1281 | if (current_time.abs_value_us <= relog_time->abs_value_us) | 1281 | if (current_time.abs_value_us <= relog_time->abs_value_us) |
1282 | { | 1282 | { |
1283 | if (GNUNET_OK != | 1283 | if (GNUNET_OK != |
1284 | GNUNET_CRYPTO_ecdsa_public_key_from_string (handle->oidc | 1284 | GNUNET_IDENTITY_public_key_from_string (handle->oidc |
1285 | ->login_identity, | 1285 | ->login_identity, |
1286 | strlen ( | ||
1287 | handle->oidc | ||
1288 | ->login_identity), | ||
1289 | &pubkey)) | 1286 | &pubkey)) |
1290 | { | 1287 | { |
1291 | handle->emsg = GNUNET_strdup (OIDC_ERROR_KEY_INVALID_COOKIE); | 1288 | handle->emsg = GNUNET_strdup (OIDC_ERROR_KEY_INVALID_COOKIE); |
@@ -1376,7 +1373,7 @@ lookup_redirect_uri_result (void *cls, | |||
1376 | char *tmp; | 1373 | char *tmp; |
1377 | char *tmp_key_str; | 1374 | char *tmp_key_str; |
1378 | char *pos; | 1375 | char *pos; |
1379 | struct GNUNET_CRYPTO_EcdsaPublicKey redirect_zone; | 1376 | struct GNUNET_IDENTITY_PublicKey redirect_zone; |
1380 | 1377 | ||
1381 | handle->gns_op = NULL; | 1378 | handle->gns_op = NULL; |
1382 | if (0 == rd_count) | 1379 | if (0 == rd_count) |
@@ -1608,10 +1605,10 @@ static void | |||
1608 | tld_iter (void *cls, const char *section, const char *option, const char *value) | 1605 | tld_iter (void *cls, const char *section, const char *option, const char *value) |
1609 | { | 1606 | { |
1610 | struct RequestHandle *handle = cls; | 1607 | struct RequestHandle *handle = cls; |
1611 | struct GNUNET_CRYPTO_EcdsaPublicKey pkey; | 1608 | struct GNUNET_IDENTITY_PublicKey pkey; |
1612 | 1609 | ||
1613 | if (GNUNET_OK != | 1610 | if (GNUNET_OK != |
1614 | GNUNET_CRYPTO_ecdsa_public_key_from_string (value, strlen (value), &pkey)) | 1611 | GNUNET_IDENTITY_public_key_from_string (value, &pkey)) |
1615 | { | 1612 | { |
1616 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Skipping non key %s\n", value); | 1613 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Skipping non key %s\n", value); |
1617 | return; | 1614 | return; |
@@ -1635,8 +1632,8 @@ authorize_endpoint (struct GNUNET_REST_RequestHandle *con_handle, | |||
1635 | { | 1632 | { |
1636 | struct RequestHandle *handle = cls; | 1633 | struct RequestHandle *handle = cls; |
1637 | struct EgoEntry *tmp_ego; | 1634 | struct EgoEntry *tmp_ego; |
1638 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *priv_key; | 1635 | const struct GNUNET_IDENTITY_PrivateKey *priv_key; |
1639 | struct GNUNET_CRYPTO_EcdsaPublicKey pkey; | 1636 | struct GNUNET_IDENTITY_PublicKey pkey; |
1640 | 1637 | ||
1641 | cookie_identity_interpretation (handle); | 1638 | cookie_identity_interpretation (handle); |
1642 | 1639 | ||
@@ -1664,9 +1661,7 @@ authorize_endpoint (struct GNUNET_REST_RequestHandle *con_handle, | |||
1664 | } | 1661 | } |
1665 | 1662 | ||
1666 | if (GNUNET_OK != | 1663 | if (GNUNET_OK != |
1667 | GNUNET_CRYPTO_ecdsa_public_key_from_string (handle->oidc->client_id, | 1664 | GNUNET_IDENTITY_public_key_from_string (handle->oidc->client_id, |
1668 | strlen ( | ||
1669 | handle->oidc->client_id), | ||
1670 | &handle->oidc->client_pkey)) | 1665 | &handle->oidc->client_pkey)) |
1671 | { | 1666 | { |
1672 | handle->emsg = GNUNET_strdup (OIDC_ERROR_KEY_UNAUTHORIZED_CLIENT); | 1667 | handle->emsg = GNUNET_strdup (OIDC_ERROR_KEY_UNAUTHORIZED_CLIENT); |
@@ -1682,7 +1677,7 @@ authorize_endpoint (struct GNUNET_REST_RequestHandle *con_handle, | |||
1682 | for (tmp_ego = ego_head; NULL != tmp_ego; tmp_ego = tmp_ego->next) | 1677 | for (tmp_ego = ego_head; NULL != tmp_ego; tmp_ego = tmp_ego->next) |
1683 | { | 1678 | { |
1684 | priv_key = GNUNET_IDENTITY_ego_get_private_key (tmp_ego->ego); | 1679 | priv_key = GNUNET_IDENTITY_ego_get_private_key (tmp_ego->ego); |
1685 | GNUNET_CRYPTO_ecdsa_key_get_public (priv_key, &pkey); | 1680 | GNUNET_IDENTITY_key_get_public (priv_key, &pkey); |
1686 | if (0 == GNUNET_memcmp (&pkey, &handle->oidc->client_pkey)) | 1681 | if (0 == GNUNET_memcmp (&pkey, &handle->oidc->client_pkey)) |
1687 | { | 1682 | { |
1688 | handle->tld = GNUNET_strdup (tmp_ego->identifier); | 1683 | handle->tld = GNUNET_strdup (tmp_ego->identifier); |
@@ -1865,7 +1860,7 @@ parse_credentials_post_body (struct RequestHandle *handle, | |||
1865 | 1860 | ||
1866 | static int | 1861 | static int |
1867 | check_authorization (struct RequestHandle *handle, | 1862 | check_authorization (struct RequestHandle *handle, |
1868 | struct GNUNET_CRYPTO_EcdsaPublicKey *cid) | 1863 | struct GNUNET_IDENTITY_PublicKey *cid) |
1869 | { | 1864 | { |
1870 | char *expected_pass; | 1865 | char *expected_pass; |
1871 | char *received_cid; | 1866 | char *received_cid; |
@@ -1902,7 +1897,7 @@ check_authorization (struct RequestHandle *handle, | |||
1902 | GNUNET_STRINGS_string_to_data (received_cid, | 1897 | GNUNET_STRINGS_string_to_data (received_cid, |
1903 | strlen (received_cid), | 1898 | strlen (received_cid), |
1904 | cid, | 1899 | cid, |
1905 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey)); | 1900 | sizeof(struct GNUNET_IDENTITY_PublicKey)); |
1906 | GNUNET_free (received_cid); | 1901 | GNUNET_free (received_cid); |
1907 | return GNUNET_OK; | 1902 | return GNUNET_OK; |
1908 | 1903 | ||
@@ -1948,7 +1943,7 @@ check_authorization (struct RequestHandle *handle, | |||
1948 | GNUNET_STRINGS_string_to_data (received_cid, | 1943 | GNUNET_STRINGS_string_to_data (received_cid, |
1949 | strlen (received_cid), | 1944 | strlen (received_cid), |
1950 | cid, | 1945 | cid, |
1951 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey)); | 1946 | sizeof(struct GNUNET_IDENTITY_PublicKey)); |
1952 | 1947 | ||
1953 | GNUNET_free (received_cpw); | 1948 | GNUNET_free (received_cpw); |
1954 | GNUNET_free (received_cid); | 1949 | GNUNET_free (received_cid); |
@@ -1958,10 +1953,10 @@ check_authorization (struct RequestHandle *handle, | |||
1958 | 1953 | ||
1959 | const struct EgoEntry * | 1954 | const struct EgoEntry * |
1960 | find_ego (struct RequestHandle *handle, | 1955 | find_ego (struct RequestHandle *handle, |
1961 | struct GNUNET_CRYPTO_EcdsaPublicKey *test_key) | 1956 | struct GNUNET_IDENTITY_PublicKey *test_key) |
1962 | { | 1957 | { |
1963 | struct EgoEntry *ego_entry; | 1958 | struct EgoEntry *ego_entry; |
1964 | struct GNUNET_CRYPTO_EcdsaPublicKey pub_key; | 1959 | struct GNUNET_IDENTITY_PublicKey pub_key; |
1965 | 1960 | ||
1966 | for (ego_entry = ego_head; NULL != ego_entry; | 1961 | for (ego_entry = ego_head; NULL != ego_entry; |
1967 | ego_entry = ego_entry->next) | 1962 | ego_entry = ego_entry->next) |
@@ -1992,7 +1987,7 @@ token_endpoint (struct GNUNET_REST_RequestHandle *con_handle, | |||
1992 | struct GNUNET_RECLAIM_AttributeList *cl = NULL; | 1987 | struct GNUNET_RECLAIM_AttributeList *cl = NULL; |
1993 | struct GNUNET_RECLAIM_PresentationList *pl = NULL; | 1988 | struct GNUNET_RECLAIM_PresentationList *pl = NULL; |
1994 | struct GNUNET_RECLAIM_Ticket ticket; | 1989 | struct GNUNET_RECLAIM_Ticket ticket; |
1995 | struct GNUNET_CRYPTO_EcdsaPublicKey cid; | 1990 | struct GNUNET_IDENTITY_PublicKey cid; |
1996 | struct GNUNET_HashCode cache_key; | 1991 | struct GNUNET_HashCode cache_key; |
1997 | struct MHD_Response *resp; | 1992 | struct MHD_Response *resp; |
1998 | char *grant_type; | 1993 | char *grant_type; |
@@ -2145,7 +2140,7 @@ token_endpoint (struct GNUNET_REST_RequestHandle *con_handle, | |||
2145 | */ | 2140 | */ |
2146 | static void | 2141 | static void |
2147 | consume_ticket (void *cls, | 2142 | consume_ticket (void *cls, |
2148 | const struct GNUNET_CRYPTO_EcdsaPublicKey *identity, | 2143 | const struct GNUNET_IDENTITY_PublicKey *identity, |
2149 | const struct GNUNET_RECLAIM_Attribute *attr, | 2144 | const struct GNUNET_RECLAIM_Attribute *attr, |
2150 | const struct GNUNET_RECLAIM_Presentation *pres) | 2145 | const struct GNUNET_RECLAIM_Presentation *pres) |
2151 | { | 2146 | { |
@@ -2225,7 +2220,7 @@ userinfo_endpoint (struct GNUNET_REST_RequestHandle *con_handle, | |||
2225 | char *authorization_type; | 2220 | char *authorization_type; |
2226 | char *authorization_access_token; | 2221 | char *authorization_access_token; |
2227 | const struct EgoEntry *aud_ego; | 2222 | const struct EgoEntry *aud_ego; |
2228 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *privkey; | 2223 | const struct GNUNET_IDENTITY_PrivateKey *privkey; |
2229 | 2224 | ||
2230 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Getting userinfo\n"); | 2225 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "Getting userinfo\n"); |
2231 | GNUNET_CRYPTO_hash (OIDC_AUTHORIZATION_HEADER_KEY, | 2226 | GNUNET_CRYPTO_hash (OIDC_AUTHORIZATION_HEADER_KEY, |
@@ -2349,7 +2344,7 @@ list_ego (void *cls, | |||
2349 | const char *identifier) | 2344 | const char *identifier) |
2350 | { | 2345 | { |
2351 | struct EgoEntry *ego_entry; | 2346 | struct EgoEntry *ego_entry; |
2352 | struct GNUNET_CRYPTO_EcdsaPublicKey pk; | 2347 | struct GNUNET_IDENTITY_PublicKey pk; |
2353 | 2348 | ||
2354 | if ((NULL == ego) && (ID_REST_STATE_INIT == state)) | 2349 | if ((NULL == ego) && (ID_REST_STATE_INIT == state)) |
2355 | { | 2350 | { |
@@ -2362,7 +2357,7 @@ list_ego (void *cls, | |||
2362 | { | 2357 | { |
2363 | ego_entry = GNUNET_new (struct EgoEntry); | 2358 | ego_entry = GNUNET_new (struct EgoEntry); |
2364 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 2359 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
2365 | ego_entry->keystring = GNUNET_CRYPTO_ecdsa_public_key_to_string (&pk); | 2360 | ego_entry->keystring = GNUNET_IDENTITY_public_key_to_string (&pk); |
2366 | ego_entry->ego = ego; | 2361 | ego_entry->ego = ego; |
2367 | ego_entry->identifier = GNUNET_strdup (identifier); | 2362 | ego_entry->identifier = GNUNET_strdup (identifier); |
2368 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, | 2363 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, |
@@ -2389,7 +2384,7 @@ list_ego (void *cls, | |||
2389 | /* Add */ | 2384 | /* Add */ |
2390 | ego_entry = GNUNET_new (struct EgoEntry); | 2385 | ego_entry = GNUNET_new (struct EgoEntry); |
2391 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 2386 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
2392 | ego_entry->keystring = GNUNET_CRYPTO_ecdsa_public_key_to_string (&pk); | 2387 | ego_entry->keystring = GNUNET_IDENTITY_public_key_to_string (&pk); |
2393 | ego_entry->ego = ego; | 2388 | ego_entry->ego = ego; |
2394 | ego_entry->identifier = GNUNET_strdup (identifier); | 2389 | ego_entry->identifier = GNUNET_strdup (identifier); |
2395 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, | 2390 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, |
diff --git a/src/reclaim/plugin_rest_reclaim.c b/src/reclaim/plugin_rest_reclaim.c index ff11d2a56..022744c82 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_CRYPTO_EcdsaPrivateKey priv_key; | 175 | struct GNUNET_IDENTITY_PrivateKey priv_key; |
176 | 176 | ||
177 | /** | 177 | /** |
178 | * Rest connection | 178 | * Rest connection |
@@ -440,14 +440,14 @@ ticket_collect (void *cls, const struct GNUNET_RECLAIM_Ticket *ticket) | |||
440 | tmp = | 440 | tmp = |
441 | GNUNET_STRINGS_data_to_string_alloc (&ticket->identity, | 441 | GNUNET_STRINGS_data_to_string_alloc (&ticket->identity, |
442 | sizeof(struct | 442 | sizeof(struct |
443 | GNUNET_CRYPTO_EcdsaPublicKey)); | 443 | GNUNET_IDENTITY_PublicKey)); |
444 | value = json_string (tmp); | 444 | value = json_string (tmp); |
445 | json_object_set_new (json_resource, "issuer", value); | 445 | json_object_set_new (json_resource, "issuer", value); |
446 | GNUNET_free (tmp); | 446 | GNUNET_free (tmp); |
447 | tmp = | 447 | tmp = |
448 | GNUNET_STRINGS_data_to_string_alloc (&ticket->audience, | 448 | GNUNET_STRINGS_data_to_string_alloc (&ticket->audience, |
449 | sizeof(struct | 449 | sizeof(struct |
450 | GNUNET_CRYPTO_EcdsaPublicKey)); | 450 | GNUNET_IDENTITY_PublicKey)); |
451 | value = json_string (tmp); | 451 | value = json_string (tmp); |
452 | json_object_set_new (json_resource, "audience", value); | 452 | json_object_set_new (json_resource, "audience", value); |
453 | GNUNET_free (tmp); | 453 | GNUNET_free (tmp); |
@@ -465,7 +465,7 @@ add_credential_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
465 | void *cls) | 465 | void *cls) |
466 | { | 466 | { |
467 | struct RequestHandle *handle = cls; | 467 | struct RequestHandle *handle = cls; |
468 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity_priv; | 468 | const struct GNUNET_IDENTITY_PrivateKey *identity_priv; |
469 | const char *identity; | 469 | const char *identity; |
470 | struct EgoEntry *ego_entry; | 470 | struct EgoEntry *ego_entry; |
471 | struct GNUNET_RECLAIM_Credential *attribute; | 471 | struct GNUNET_RECLAIM_Credential *attribute; |
@@ -545,7 +545,7 @@ add_credential_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
545 | */ | 545 | */ |
546 | static void | 546 | static void |
547 | cred_collect (void *cls, | 547 | cred_collect (void *cls, |
548 | const struct GNUNET_CRYPTO_EcdsaPublicKey *identity, | 548 | const struct GNUNET_IDENTITY_PublicKey *identity, |
549 | const struct GNUNET_RECLAIM_Credential *cred) | 549 | const struct GNUNET_RECLAIM_Credential *cred) |
550 | { | 550 | { |
551 | struct RequestHandle *handle = cls; | 551 | struct RequestHandle *handle = cls; |
@@ -631,7 +631,7 @@ list_credential_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
631 | void *cls) | 631 | void *cls) |
632 | { | 632 | { |
633 | struct RequestHandle *handle = cls; | 633 | struct RequestHandle *handle = cls; |
634 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *priv_key; | 634 | const struct GNUNET_IDENTITY_PrivateKey *priv_key; |
635 | struct EgoEntry *ego_entry; | 635 | struct EgoEntry *ego_entry; |
636 | char *identity; | 636 | char *identity; |
637 | 637 | ||
@@ -688,7 +688,7 @@ delete_credential_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
688 | void *cls) | 688 | void *cls) |
689 | { | 689 | { |
690 | struct RequestHandle *handle = cls; | 690 | struct RequestHandle *handle = cls; |
691 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *priv_key; | 691 | const struct GNUNET_IDENTITY_PrivateKey *priv_key; |
692 | struct GNUNET_RECLAIM_Credential attr; | 692 | struct GNUNET_RECLAIM_Credential attr; |
693 | struct EgoEntry *ego_entry; | 693 | struct EgoEntry *ego_entry; |
694 | char *identity_id_str; | 694 | char *identity_id_str; |
@@ -754,7 +754,7 @@ list_tickets_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
754 | const char *url, | 754 | const char *url, |
755 | void *cls) | 755 | void *cls) |
756 | { | 756 | { |
757 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *priv_key; | 757 | const struct GNUNET_IDENTITY_PrivateKey *priv_key; |
758 | struct RequestHandle *handle = cls; | 758 | struct RequestHandle *handle = cls; |
759 | struct EgoEntry *ego_entry; | 759 | struct EgoEntry *ego_entry; |
760 | char *identity; | 760 | char *identity; |
@@ -801,7 +801,7 @@ add_attribute_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
801 | const char *url, | 801 | const char *url, |
802 | void *cls) | 802 | void *cls) |
803 | { | 803 | { |
804 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity_priv; | 804 | const struct GNUNET_IDENTITY_PrivateKey *identity_priv; |
805 | const char *identity; | 805 | const char *identity; |
806 | struct RequestHandle *handle = cls; | 806 | struct RequestHandle *handle = cls; |
807 | struct EgoEntry *ego_entry; | 807 | struct EgoEntry *ego_entry; |
@@ -949,7 +949,7 @@ parse_jwt (const struct GNUNET_RECLAIM_Credential *cred, | |||
949 | */ | 949 | */ |
950 | static void | 950 | static void |
951 | attr_collect (void *cls, | 951 | attr_collect (void *cls, |
952 | const struct GNUNET_CRYPTO_EcdsaPublicKey *identity, | 952 | const struct GNUNET_IDENTITY_PublicKey *identity, |
953 | const struct GNUNET_RECLAIM_Attribute *attr) | 953 | const struct GNUNET_RECLAIM_Attribute *attr) |
954 | { | 954 | { |
955 | struct RequestHandle *handle = cls; | 955 | struct RequestHandle *handle = cls; |
@@ -996,7 +996,7 @@ list_attribute_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
996 | const char *url, | 996 | const char *url, |
997 | void *cls) | 997 | void *cls) |
998 | { | 998 | { |
999 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *priv_key; | 999 | const struct GNUNET_IDENTITY_PrivateKey *priv_key; |
1000 | struct RequestHandle *handle = cls; | 1000 | struct RequestHandle *handle = cls; |
1001 | struct EgoEntry *ego_entry; | 1001 | struct EgoEntry *ego_entry; |
1002 | char *identity; | 1002 | char *identity; |
@@ -1050,7 +1050,7 @@ delete_attribute_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
1050 | const char *url, | 1050 | const char *url, |
1051 | void *cls) | 1051 | void *cls) |
1052 | { | 1052 | { |
1053 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *priv_key; | 1053 | const struct GNUNET_IDENTITY_PrivateKey *priv_key; |
1054 | struct RequestHandle *handle = cls; | 1054 | struct RequestHandle *handle = cls; |
1055 | struct GNUNET_RECLAIM_Attribute attr; | 1055 | struct GNUNET_RECLAIM_Attribute attr; |
1056 | struct EgoEntry *ego_entry; | 1056 | struct EgoEntry *ego_entry; |
@@ -1108,11 +1108,11 @@ revoke_ticket_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
1108 | const char *url, | 1108 | const char *url, |
1109 | void *cls) | 1109 | void *cls) |
1110 | { | 1110 | { |
1111 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity_priv; | 1111 | const struct GNUNET_IDENTITY_PrivateKey *identity_priv; |
1112 | struct RequestHandle *handle = cls; | 1112 | struct RequestHandle *handle = cls; |
1113 | struct EgoEntry *ego_entry; | 1113 | struct EgoEntry *ego_entry; |
1114 | struct GNUNET_RECLAIM_Ticket *ticket = NULL; | 1114 | struct GNUNET_RECLAIM_Ticket *ticket = NULL; |
1115 | struct GNUNET_CRYPTO_EcdsaPublicKey tmp_pk; | 1115 | struct GNUNET_IDENTITY_PublicKey tmp_pk; |
1116 | char term_data[handle->rest_handle->data_size + 1]; | 1116 | char term_data[handle->rest_handle->data_size + 1]; |
1117 | json_t *data_json; | 1117 | json_t *data_json; |
1118 | json_error_t err; | 1118 | json_error_t err; |
@@ -1156,7 +1156,7 @@ revoke_ticket_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
1156 | GNUNET_IDENTITY_ego_get_public_key (ego_entry->ego, &tmp_pk); | 1156 | GNUNET_IDENTITY_ego_get_public_key (ego_entry->ego, &tmp_pk); |
1157 | if (0 == memcmp (&ticket->identity, | 1157 | if (0 == memcmp (&ticket->identity, |
1158 | &tmp_pk, | 1158 | &tmp_pk, |
1159 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey))) | 1159 | sizeof(struct GNUNET_IDENTITY_PublicKey))) |
1160 | break; | 1160 | break; |
1161 | } | 1161 | } |
1162 | if (NULL == ego_entry) | 1162 | if (NULL == ego_entry) |
@@ -1178,7 +1178,7 @@ revoke_ticket_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
1178 | 1178 | ||
1179 | static void | 1179 | static void |
1180 | consume_cont (void *cls, | 1180 | consume_cont (void *cls, |
1181 | const struct GNUNET_CRYPTO_EcdsaPublicKey *identity, | 1181 | const struct GNUNET_IDENTITY_PublicKey *identity, |
1182 | const struct GNUNET_RECLAIM_Attribute *attr, | 1182 | const struct GNUNET_RECLAIM_Attribute *attr, |
1183 | const struct GNUNET_RECLAIM_Presentation *pres) | 1183 | const struct GNUNET_RECLAIM_Presentation *pres) |
1184 | { | 1184 | { |
@@ -1215,11 +1215,11 @@ consume_ticket_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
1215 | const char *url, | 1215 | const char *url, |
1216 | void *cls) | 1216 | void *cls) |
1217 | { | 1217 | { |
1218 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity_priv; | 1218 | const struct GNUNET_IDENTITY_PrivateKey *identity_priv; |
1219 | struct RequestHandle *handle = cls; | 1219 | struct RequestHandle *handle = cls; |
1220 | struct EgoEntry *ego_entry; | 1220 | struct EgoEntry *ego_entry; |
1221 | struct GNUNET_RECLAIM_Ticket *ticket; | 1221 | struct GNUNET_RECLAIM_Ticket *ticket; |
1222 | struct GNUNET_CRYPTO_EcdsaPublicKey tmp_pk; | 1222 | struct GNUNET_IDENTITY_PublicKey tmp_pk; |
1223 | char term_data[handle->rest_handle->data_size + 1]; | 1223 | char term_data[handle->rest_handle->data_size + 1]; |
1224 | json_t *data_json; | 1224 | json_t *data_json; |
1225 | json_error_t err; | 1225 | json_error_t err; |
@@ -1259,7 +1259,7 @@ consume_ticket_cont (struct GNUNET_REST_RequestHandle *con_handle, | |||
1259 | GNUNET_IDENTITY_ego_get_public_key (ego_entry->ego, &tmp_pk); | 1259 | GNUNET_IDENTITY_ego_get_public_key (ego_entry->ego, &tmp_pk); |
1260 | if (0 == memcmp (&ticket->audience, | 1260 | if (0 == memcmp (&ticket->audience, |
1261 | &tmp_pk, | 1261 | &tmp_pk, |
1262 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey))) | 1262 | sizeof(struct GNUNET_IDENTITY_PublicKey))) |
1263 | break; | 1263 | break; |
1264 | } | 1264 | } |
1265 | if (NULL == ego_entry) | 1265 | if (NULL == ego_entry) |
@@ -1343,7 +1343,7 @@ list_ego (void *cls, | |||
1343 | const char *identifier) | 1343 | const char *identifier) |
1344 | { | 1344 | { |
1345 | struct EgoEntry *ego_entry; | 1345 | struct EgoEntry *ego_entry; |
1346 | struct GNUNET_CRYPTO_EcdsaPublicKey pk; | 1346 | struct GNUNET_IDENTITY_PublicKey pk; |
1347 | 1347 | ||
1348 | if ((NULL == ego) && (ID_REST_STATE_INIT == state)) | 1348 | if ((NULL == ego) && (ID_REST_STATE_INIT == state)) |
1349 | { | 1349 | { |
@@ -1354,7 +1354,7 @@ list_ego (void *cls, | |||
1354 | { | 1354 | { |
1355 | ego_entry = GNUNET_new (struct EgoEntry); | 1355 | ego_entry = GNUNET_new (struct EgoEntry); |
1356 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 1356 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
1357 | ego_entry->keystring = GNUNET_CRYPTO_ecdsa_public_key_to_string (&pk); | 1357 | ego_entry->keystring = GNUNET_IDENTITY_public_key_to_string (&pk); |
1358 | ego_entry->ego = ego; | 1358 | ego_entry->ego = ego; |
1359 | ego_entry->identifier = GNUNET_strdup (identifier); | 1359 | ego_entry->identifier = GNUNET_strdup (identifier); |
1360 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, | 1360 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, |
@@ -1380,7 +1380,7 @@ list_ego (void *cls, | |||
1380 | /* Add */ | 1380 | /* Add */ |
1381 | ego_entry = GNUNET_new (struct EgoEntry); | 1381 | ego_entry = GNUNET_new (struct EgoEntry); |
1382 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); | 1382 | GNUNET_IDENTITY_ego_get_public_key (ego, &pk); |
1383 | ego_entry->keystring = GNUNET_CRYPTO_ecdsa_public_key_to_string (&pk); | 1383 | ego_entry->keystring = GNUNET_IDENTITY_public_key_to_string (&pk); |
1384 | ego_entry->ego = ego; | 1384 | ego_entry->ego = ego; |
1385 | ego_entry->identifier = GNUNET_strdup (identifier); | 1385 | ego_entry->identifier = GNUNET_strdup (identifier); |
1386 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, | 1386 | GNUNET_CONTAINER_DLL_insert_tail (ego_head, |
diff --git a/src/reclaim/reclaim.h b/src/reclaim/reclaim.h index bc7f34365..aae8ee89a 100644 --- a/src/reclaim/reclaim.h +++ b/src/reclaim/reclaim.h | |||
@@ -29,7 +29,7 @@ | |||
29 | #define RECLAIM_H | 29 | #define RECLAIM_H |
30 | 30 | ||
31 | #include "gnunet_common.h" | 31 | #include "gnunet_common.h" |
32 | 32 | #include "gnunet_identity_service.h" | |
33 | 33 | ||
34 | GNUNET_NETWORK_STRUCT_BEGIN | 34 | GNUNET_NETWORK_STRUCT_BEGIN |
35 | 35 | ||
@@ -62,7 +62,7 @@ struct AttributeStoreMessage | |||
62 | /** | 62 | /** |
63 | * Identity | 63 | * Identity |
64 | */ | 64 | */ |
65 | struct GNUNET_CRYPTO_EcdsaPrivateKey identity; | 65 | struct GNUNET_IDENTITY_PrivateKey identity; |
66 | 66 | ||
67 | /* followed by the serialized attribute */ | 67 | /* followed by the serialized attribute */ |
68 | }; | 68 | }; |
@@ -91,7 +91,7 @@ struct AttributeDeleteMessage | |||
91 | /** | 91 | /** |
92 | * Identity | 92 | * Identity |
93 | */ | 93 | */ |
94 | struct GNUNET_CRYPTO_EcdsaPrivateKey identity; | 94 | struct GNUNET_IDENTITY_PrivateKey identity; |
95 | 95 | ||
96 | /* followed by the serialized attribute */ | 96 | /* followed by the serialized attribute */ |
97 | }; | 97 | }; |
@@ -151,7 +151,7 @@ struct AttributeResultMessage | |||
151 | /** | 151 | /** |
152 | * The public key of the identity. | 152 | * The public key of the identity. |
153 | */ | 153 | */ |
154 | struct GNUNET_CRYPTO_EcdsaPublicKey identity; | 154 | struct GNUNET_IDENTITY_PublicKey identity; |
155 | 155 | ||
156 | /* followed by: | 156 | /* followed by: |
157 | * serialized attribute data | 157 | * serialized attribute data |
@@ -186,7 +186,7 @@ struct CredentialResultMessage | |||
186 | /** | 186 | /** |
187 | * The public key of the identity. | 187 | * The public key of the identity. |
188 | */ | 188 | */ |
189 | struct GNUNET_CRYPTO_EcdsaPublicKey identity; | 189 | struct GNUNET_IDENTITY_PublicKey identity; |
190 | 190 | ||
191 | /* followed by: | 191 | /* followed by: |
192 | * serialized credential data | 192 | * serialized credential data |
@@ -212,7 +212,7 @@ struct AttributeIterationStartMessage | |||
212 | /** | 212 | /** |
213 | * Identity. | 213 | * Identity. |
214 | */ | 214 | */ |
215 | struct GNUNET_CRYPTO_EcdsaPrivateKey identity; | 215 | struct GNUNET_IDENTITY_PrivateKey identity; |
216 | }; | 216 | }; |
217 | 217 | ||
218 | 218 | ||
@@ -251,7 +251,7 @@ struct CredentialIterationStartMessage | |||
251 | /** | 251 | /** |
252 | * Identity. | 252 | * Identity. |
253 | */ | 253 | */ |
254 | struct GNUNET_CRYPTO_EcdsaPrivateKey identity; | 254 | struct GNUNET_IDENTITY_PrivateKey identity; |
255 | }; | 255 | }; |
256 | 256 | ||
257 | 257 | ||
@@ -323,7 +323,7 @@ struct TicketIterationStartMessage | |||
323 | /** | 323 | /** |
324 | * Identity. | 324 | * Identity. |
325 | */ | 325 | */ |
326 | struct GNUNET_CRYPTO_EcdsaPrivateKey identity; | 326 | struct GNUNET_IDENTITY_PrivateKey identity; |
327 | }; | 327 | }; |
328 | 328 | ||
329 | 329 | ||
@@ -379,12 +379,12 @@ struct IssueTicketMessage | |||
379 | /** | 379 | /** |
380 | * Identity. | 380 | * Identity. |
381 | */ | 381 | */ |
382 | struct GNUNET_CRYPTO_EcdsaPrivateKey identity; | 382 | struct GNUNET_IDENTITY_PrivateKey identity; |
383 | 383 | ||
384 | /** | 384 | /** |
385 | * Requesting party. | 385 | * Requesting party. |
386 | */ | 386 | */ |
387 | struct GNUNET_CRYPTO_EcdsaPublicKey rp; | 387 | struct GNUNET_IDENTITY_PublicKey rp; |
388 | 388 | ||
389 | /** | 389 | /** |
390 | * length of serialized attribute list | 390 | * length of serialized attribute list |
@@ -412,7 +412,7 @@ struct RevokeTicketMessage | |||
412 | /** | 412 | /** |
413 | * Identity. | 413 | * Identity. |
414 | */ | 414 | */ |
415 | struct GNUNET_CRYPTO_EcdsaPrivateKey identity; | 415 | struct GNUNET_IDENTITY_PrivateKey identity; |
416 | 416 | ||
417 | /** | 417 | /** |
418 | * length of serialized attribute list | 418 | * length of serialized attribute list |
@@ -493,7 +493,7 @@ struct ConsumeTicketMessage | |||
493 | /** | 493 | /** |
494 | * Identity. | 494 | * Identity. |
495 | */ | 495 | */ |
496 | struct GNUNET_CRYPTO_EcdsaPrivateKey identity; | 496 | struct GNUNET_IDENTITY_PrivateKey identity; |
497 | 497 | ||
498 | /** | 498 | /** |
499 | * The ticket to consume | 499 | * The ticket to consume |
@@ -539,7 +539,7 @@ struct ConsumeTicketResultMessage | |||
539 | /** | 539 | /** |
540 | * The public key of the identity. | 540 | * The public key of the identity. |
541 | */ | 541 | */ |
542 | struct GNUNET_CRYPTO_EcdsaPublicKey identity; | 542 | struct GNUNET_IDENTITY_PublicKey identity; |
543 | 543 | ||
544 | /* followed by: | 544 | /* followed by: |
545 | * serialized attributes data | 545 | * serialized attributes data |
diff --git a/src/reclaim/reclaim_api.c b/src/reclaim/reclaim_api.c index 1e0251519..f4f2b946a 100644 --- a/src/reclaim/reclaim_api.c +++ b/src/reclaim/reclaim_api.c | |||
@@ -235,7 +235,7 @@ struct GNUNET_RECLAIM_AttributeIterator | |||
235 | /** | 235 | /** |
236 | * Private key of the zone. | 236 | * Private key of the zone. |
237 | */ | 237 | */ |
238 | struct GNUNET_CRYPTO_EcdsaPrivateKey identity; | 238 | struct GNUNET_IDENTITY_PrivateKey identity; |
239 | 239 | ||
240 | /** | 240 | /** |
241 | * The operation id this zone iteration operation has | 241 | * The operation id this zone iteration operation has |
@@ -302,7 +302,7 @@ struct GNUNET_RECLAIM_CredentialIterator | |||
302 | /** | 302 | /** |
303 | * Private key of the zone. | 303 | * Private key of the zone. |
304 | */ | 304 | */ |
305 | struct GNUNET_CRYPTO_EcdsaPrivateKey identity; | 305 | struct GNUNET_IDENTITY_PrivateKey identity; |
306 | 306 | ||
307 | /** | 307 | /** |
308 | * The operation id this zone iteration operation has | 308 | * The operation id this zone iteration operation has |
@@ -704,7 +704,7 @@ check_attribute_result (void *cls, const struct AttributeResultMessage *msg) | |||
704 | static void | 704 | static void |
705 | handle_attribute_result (void *cls, const struct AttributeResultMessage *msg) | 705 | handle_attribute_result (void *cls, const struct AttributeResultMessage *msg) |
706 | { | 706 | { |
707 | static struct GNUNET_CRYPTO_EcdsaPrivateKey identity_dummy; | 707 | static struct GNUNET_IDENTITY_PrivateKey identity_dummy; |
708 | struct GNUNET_RECLAIM_Handle *h = cls; | 708 | struct GNUNET_RECLAIM_Handle *h = cls; |
709 | struct GNUNET_RECLAIM_AttributeIterator *it; | 709 | struct GNUNET_RECLAIM_AttributeIterator *it; |
710 | struct GNUNET_RECLAIM_Operation *op; | 710 | struct GNUNET_RECLAIM_Operation *op; |
@@ -806,7 +806,7 @@ static void | |||
806 | handle_credential_result (void *cls, const struct | 806 | handle_credential_result (void *cls, const struct |
807 | CredentialResultMessage *msg) | 807 | CredentialResultMessage *msg) |
808 | { | 808 | { |
809 | static struct GNUNET_CRYPTO_EcdsaPrivateKey identity_dummy; | 809 | static struct GNUNET_IDENTITY_PrivateKey identity_dummy; |
810 | struct GNUNET_RECLAIM_Handle *h = cls; | 810 | struct GNUNET_RECLAIM_Handle *h = cls; |
811 | struct GNUNET_RECLAIM_CredentialIterator *it; | 811 | struct GNUNET_RECLAIM_CredentialIterator *it; |
812 | struct GNUNET_RECLAIM_Operation *op; | 812 | struct GNUNET_RECLAIM_Operation *op; |
@@ -1134,7 +1134,7 @@ GNUNET_RECLAIM_disconnect (struct GNUNET_RECLAIM_Handle *h) | |||
1134 | struct GNUNET_RECLAIM_Operation * | 1134 | struct GNUNET_RECLAIM_Operation * |
1135 | GNUNET_RECLAIM_attribute_store ( | 1135 | GNUNET_RECLAIM_attribute_store ( |
1136 | struct GNUNET_RECLAIM_Handle *h, | 1136 | struct GNUNET_RECLAIM_Handle *h, |
1137 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pkey, | 1137 | const struct GNUNET_IDENTITY_PrivateKey *pkey, |
1138 | const struct GNUNET_RECLAIM_Attribute *attr, | 1138 | const struct GNUNET_RECLAIM_Attribute *attr, |
1139 | const struct GNUNET_TIME_Relative *exp_interval, | 1139 | const struct GNUNET_TIME_Relative *exp_interval, |
1140 | GNUNET_RECLAIM_ContinuationWithStatus cont, | 1140 | GNUNET_RECLAIM_ContinuationWithStatus cont, |
@@ -1181,7 +1181,7 @@ GNUNET_RECLAIM_attribute_store ( | |||
1181 | struct GNUNET_RECLAIM_Operation * | 1181 | struct GNUNET_RECLAIM_Operation * |
1182 | GNUNET_RECLAIM_attribute_delete ( | 1182 | GNUNET_RECLAIM_attribute_delete ( |
1183 | struct GNUNET_RECLAIM_Handle *h, | 1183 | struct GNUNET_RECLAIM_Handle *h, |
1184 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pkey, | 1184 | const struct GNUNET_IDENTITY_PrivateKey *pkey, |
1185 | const struct GNUNET_RECLAIM_Attribute *attr, | 1185 | const struct GNUNET_RECLAIM_Attribute *attr, |
1186 | GNUNET_RECLAIM_ContinuationWithStatus cont, | 1186 | GNUNET_RECLAIM_ContinuationWithStatus cont, |
1187 | void *cont_cls) | 1187 | void *cont_cls) |
@@ -1226,7 +1226,7 @@ GNUNET_RECLAIM_attribute_delete ( | |||
1226 | struct GNUNET_RECLAIM_Operation * | 1226 | struct GNUNET_RECLAIM_Operation * |
1227 | GNUNET_RECLAIM_credential_store ( | 1227 | GNUNET_RECLAIM_credential_store ( |
1228 | struct GNUNET_RECLAIM_Handle *h, | 1228 | struct GNUNET_RECLAIM_Handle *h, |
1229 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pkey, | 1229 | const struct GNUNET_IDENTITY_PrivateKey *pkey, |
1230 | const struct GNUNET_RECLAIM_Credential *attr, | 1230 | const struct GNUNET_RECLAIM_Credential *attr, |
1231 | const struct GNUNET_TIME_Relative *exp_interval, | 1231 | const struct GNUNET_TIME_Relative *exp_interval, |
1232 | GNUNET_RECLAIM_ContinuationWithStatus cont, | 1232 | GNUNET_RECLAIM_ContinuationWithStatus cont, |
@@ -1273,7 +1273,7 @@ GNUNET_RECLAIM_credential_store ( | |||
1273 | struct GNUNET_RECLAIM_Operation * | 1273 | struct GNUNET_RECLAIM_Operation * |
1274 | GNUNET_RECLAIM_credential_delete ( | 1274 | GNUNET_RECLAIM_credential_delete ( |
1275 | struct GNUNET_RECLAIM_Handle *h, | 1275 | struct GNUNET_RECLAIM_Handle *h, |
1276 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *pkey, | 1276 | const struct GNUNET_IDENTITY_PrivateKey *pkey, |
1277 | const struct GNUNET_RECLAIM_Credential *attr, | 1277 | const struct GNUNET_RECLAIM_Credential *attr, |
1278 | GNUNET_RECLAIM_ContinuationWithStatus cont, | 1278 | GNUNET_RECLAIM_ContinuationWithStatus cont, |
1279 | void *cont_cls) | 1279 | void *cont_cls) |
@@ -1330,7 +1330,7 @@ GNUNET_RECLAIM_credential_delete ( | |||
1330 | struct GNUNET_RECLAIM_AttributeIterator * | 1330 | struct GNUNET_RECLAIM_AttributeIterator * |
1331 | GNUNET_RECLAIM_get_attributes_start ( | 1331 | GNUNET_RECLAIM_get_attributes_start ( |
1332 | struct GNUNET_RECLAIM_Handle *h, | 1332 | struct GNUNET_RECLAIM_Handle *h, |
1333 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity, | 1333 | const struct GNUNET_IDENTITY_PrivateKey *identity, |
1334 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1334 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1335 | void *error_cb_cls, | 1335 | void *error_cb_cls, |
1336 | GNUNET_RECLAIM_AttributeResult proc, | 1336 | GNUNET_RECLAIM_AttributeResult proc, |
@@ -1439,7 +1439,7 @@ GNUNET_RECLAIM_get_attributes_stop (struct GNUNET_RECLAIM_AttributeIterator *it) | |||
1439 | struct GNUNET_RECLAIM_CredentialIterator * | 1439 | struct GNUNET_RECLAIM_CredentialIterator * |
1440 | GNUNET_RECLAIM_get_credentials_start ( | 1440 | GNUNET_RECLAIM_get_credentials_start ( |
1441 | struct GNUNET_RECLAIM_Handle *h, | 1441 | struct GNUNET_RECLAIM_Handle *h, |
1442 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity, | 1442 | const struct GNUNET_IDENTITY_PrivateKey *identity, |
1443 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1443 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1444 | void *error_cb_cls, | 1444 | void *error_cb_cls, |
1445 | GNUNET_RECLAIM_CredentialResult proc, | 1445 | GNUNET_RECLAIM_CredentialResult proc, |
@@ -1541,8 +1541,8 @@ GNUNET_RECLAIM_get_credentials_stop (struct | |||
1541 | struct GNUNET_RECLAIM_Operation * | 1541 | struct GNUNET_RECLAIM_Operation * |
1542 | GNUNET_RECLAIM_ticket_issue ( | 1542 | GNUNET_RECLAIM_ticket_issue ( |
1543 | struct GNUNET_RECLAIM_Handle *h, | 1543 | struct GNUNET_RECLAIM_Handle *h, |
1544 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *iss, | 1544 | const struct GNUNET_IDENTITY_PrivateKey *iss, |
1545 | const struct GNUNET_CRYPTO_EcdsaPublicKey *rp, | 1545 | const struct GNUNET_IDENTITY_PublicKey *rp, |
1546 | const struct GNUNET_RECLAIM_AttributeList *attrs, | 1546 | const struct GNUNET_RECLAIM_AttributeList *attrs, |
1547 | GNUNET_RECLAIM_IssueTicketCallback cb, | 1547 | GNUNET_RECLAIM_IssueTicketCallback cb, |
1548 | void *cb_cls) | 1548 | void *cb_cls) |
@@ -1590,7 +1590,7 @@ GNUNET_RECLAIM_ticket_issue ( | |||
1590 | struct GNUNET_RECLAIM_Operation * | 1590 | struct GNUNET_RECLAIM_Operation * |
1591 | GNUNET_RECLAIM_ticket_consume ( | 1591 | GNUNET_RECLAIM_ticket_consume ( |
1592 | struct GNUNET_RECLAIM_Handle *h, | 1592 | struct GNUNET_RECLAIM_Handle *h, |
1593 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity, | 1593 | const struct GNUNET_IDENTITY_PrivateKey *identity, |
1594 | const struct GNUNET_RECLAIM_Ticket *ticket, | 1594 | const struct GNUNET_RECLAIM_Ticket *ticket, |
1595 | GNUNET_RECLAIM_AttributeTicketResult cb, | 1595 | GNUNET_RECLAIM_AttributeTicketResult cb, |
1596 | void *cb_cls) | 1596 | void *cb_cls) |
@@ -1636,7 +1636,7 @@ GNUNET_RECLAIM_ticket_consume ( | |||
1636 | struct GNUNET_RECLAIM_TicketIterator * | 1636 | struct GNUNET_RECLAIM_TicketIterator * |
1637 | GNUNET_RECLAIM_ticket_iteration_start ( | 1637 | GNUNET_RECLAIM_ticket_iteration_start ( |
1638 | struct GNUNET_RECLAIM_Handle *h, | 1638 | struct GNUNET_RECLAIM_Handle *h, |
1639 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity, | 1639 | const struct GNUNET_IDENTITY_PrivateKey *identity, |
1640 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1640 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1641 | void *error_cb_cls, | 1641 | void *error_cb_cls, |
1642 | GNUNET_RECLAIM_TicketCallback proc, | 1642 | GNUNET_RECLAIM_TicketCallback proc, |
@@ -1731,7 +1731,7 @@ GNUNET_RECLAIM_ticket_iteration_stop (struct GNUNET_RECLAIM_TicketIterator *it) | |||
1731 | struct GNUNET_RECLAIM_Operation * | 1731 | struct GNUNET_RECLAIM_Operation * |
1732 | GNUNET_RECLAIM_ticket_revoke ( | 1732 | GNUNET_RECLAIM_ticket_revoke ( |
1733 | struct GNUNET_RECLAIM_Handle *h, | 1733 | struct GNUNET_RECLAIM_Handle *h, |
1734 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *identity, | 1734 | const struct GNUNET_IDENTITY_PrivateKey *identity, |
1735 | const struct GNUNET_RECLAIM_Ticket *ticket, | 1735 | const struct GNUNET_RECLAIM_Ticket *ticket, |
1736 | GNUNET_RECLAIM_ContinuationWithStatus cb, | 1736 | GNUNET_RECLAIM_ContinuationWithStatus cb, |
1737 | void *cb_cls) | 1737 | void *cb_cls) |
diff --git a/src/reclaim/test_reclaim_attribute.c b/src/reclaim/test_reclaim_attribute.c index f71d86b56..f8faf8021 100644 --- a/src/reclaim/test_reclaim_attribute.c +++ b/src/reclaim/test_reclaim_attribute.c | |||
@@ -9,12 +9,10 @@ main (int argc, char *argv[]) | |||
9 | struct GNUNET_RECLAIM_AttributeList *al; | 9 | struct GNUNET_RECLAIM_AttributeList *al; |
10 | struct GNUNET_RECLAIM_AttributeList *al_two; | 10 | struct GNUNET_RECLAIM_AttributeList *al_two; |
11 | struct GNUNET_RECLAIM_AttributeListEntry *ale; | 11 | struct GNUNET_RECLAIM_AttributeListEntry *ale; |
12 | struct GNUNET_RECLAIM_Attribute *attr; | ||
13 | char attrname[100]; | 12 | char attrname[100]; |
14 | char attrdata[100]; | 13 | char attrdata[100]; |
15 | size_t ser_len_claimed; | 14 | size_t ser_len_claimed; |
16 | size_t ser_len_actual; | 15 | size_t ser_len_actual; |
17 | ssize_t deser_len; | ||
18 | char *ser_data; | 16 | char *ser_data; |
19 | int count = 0; | 17 | int count = 0; |
20 | 18 | ||
diff --git a/src/regex/regex_block_lib.c b/src/regex/regex_block_lib.c index a309c2305..159e8bf8a 100644 --- a/src/regex/regex_block_lib.c +++ b/src/regex/regex_block_lib.c | |||
@@ -352,14 +352,14 @@ REGEX_BLOCK_iterate (const struct RegexBlock *block, | |||
352 | } | 352 | } |
353 | off = len; | 353 | off = len; |
354 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 354 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
355 | "Start iterating block of size %u, proof %u, off %u edges %u\n", | 355 | "Start iterating block of size %lu, proof %u, off %lu edges %u\n", |
356 | size, len, off, n); | 356 | (unsigned long) size, len, (unsigned long) off, n); |
357 | /* &aux[off] always points to our token */ | 357 | /* &aux[off] always points to our token */ |
358 | for (n = 0; n < num_edges; n++) | 358 | for (n = 0; n < num_edges; n++) |
359 | { | 359 | { |
360 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 360 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
361 | "Edge %u/%u, off %u tokenlen %u (%.*s)\n", | 361 | "Edge %u/%u, off %lu tokenlen %u (%.*s)\n", |
362 | n + 1, num_edges, off, | 362 | n + 1, num_edges, (unsigned long) off, |
363 | ntohs (edges[n].token_length), ntohs (edges[n].token_length), | 363 | ntohs (edges[n].token_length), ntohs (edges[n].token_length), |
364 | &aux[off]); | 364 | &aux[off]); |
365 | if (NULL != iterator) | 365 | if (NULL != iterator) |
diff --git a/src/regex/regex_internal_dht.c b/src/regex/regex_internal_dht.c index d2c69f131..39d7cd847 100644 --- a/src/regex/regex_internal_dht.c +++ b/src/regex/regex_internal_dht.c | |||
@@ -427,8 +427,7 @@ regex_find_path (const struct GNUNET_HashCode *key, | |||
427 | 427 | ||
428 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 428 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
429 | "Accept state found, now searching for paths to %s\n", | 429 | "Accept state found, now searching for paths to %s\n", |
430 | GNUNET_h2s (key), | 430 | GNUNET_h2s (key)); |
431 | (unsigned int) ctx->position); | ||
432 | get_h = GNUNET_DHT_get_start (ctx->info->dht, /* handle */ | 431 | get_h = GNUNET_DHT_get_start (ctx->info->dht, /* handle */ |
433 | GNUNET_BLOCK_TYPE_REGEX_ACCEPT, /* type */ | 432 | GNUNET_BLOCK_TYPE_REGEX_ACCEPT, /* type */ |
434 | key, /* key to search */ | 433 | key, /* key to search */ |
@@ -534,8 +533,8 @@ regex_result_iterator (void *cls, | |||
534 | return GNUNET_YES; // We found an accept state! | 533 | return GNUNET_YES; // We found an accept state! |
535 | } | 534 | } |
536 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 535 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
537 | "* %u, %u, [%u]\n", | 536 | "* %lu, %lu, [%u]\n", |
538 | ctx->position, | 537 | (unsigned long) ctx->position, |
539 | strlen (ctx->info->description), | 538 | strlen (ctx->info->description), |
540 | GNUNET_BLOCK_is_accepting (block, result->size)); | 539 | GNUNET_BLOCK_is_accepting (block, result->size)); |
541 | regex_next_edge (block, result->size, ctx); | 540 | regex_next_edge (block, result->size, ctx); |
@@ -729,7 +728,7 @@ REGEX_INTERNAL_search (struct GNUNET_DHT_Handle *dht, | |||
729 | "Initial key for `%s' is %s (based on `%.*s')\n", | 728 | "Initial key for `%s' is %s (based on `%.*s')\n", |
730 | string, | 729 | string, |
731 | GNUNET_h2s (&key), | 730 | GNUNET_h2s (&key), |
732 | size, | 731 | (int) size, |
733 | string); | 732 | string); |
734 | ctx = GNUNET_new (struct RegexSearchContext); | 733 | ctx = GNUNET_new (struct RegexSearchContext); |
735 | ctx->position = size; | 734 | ctx->position = size; |
diff --git a/src/regex/regex_test_graph.c b/src/regex/regex_test_graph.c index 8e1e00fd4..c8efae772 100644 --- a/src/regex/regex_test_graph.c +++ b/src/regex/regex_test_graph.c | |||
@@ -177,8 +177,7 @@ REGEX_TEST_automaton_save_graph_step (void *cls, unsigned int count, | |||
177 | } | 177 | } |
178 | else | 178 | else |
179 | { | 179 | { |
180 | GNUNET_asprintf (&s_acc, "\"%s\" [shape=doublecircle];\n", name, | 180 | GNUNET_asprintf (&s_acc, "\"%s\" [shape=doublecircle];\n", name); |
181 | s->scc_id); | ||
182 | } | 181 | } |
183 | } | 182 | } |
184 | else if (GNUNET_YES == ctx->coloring) | 183 | else if (GNUNET_YES == ctx->coloring) |
@@ -189,7 +188,7 @@ REGEX_TEST_automaton_save_graph_step (void *cls, unsigned int count, | |||
189 | } | 188 | } |
190 | else | 189 | else |
191 | { | 190 | { |
192 | GNUNET_asprintf (&s_acc, "\"%s\" [shape=circle];\n", name, s->scc_id); | 191 | GNUNET_asprintf (&s_acc, "\"%s\" [shape=circle];\n", name); |
193 | } | 192 | } |
194 | 193 | ||
195 | GNUNET_assert (NULL != s_acc); | 194 | GNUNET_assert (NULL != s_acc); |
@@ -228,7 +227,7 @@ REGEX_TEST_automaton_save_graph_step (void *cls, unsigned int count, | |||
228 | else | 227 | else |
229 | { | 228 | { |
230 | GNUNET_asprintf (&s_tran, "\"%s\" -> \"%s\" [label = \"ε\"];\n", name, | 229 | GNUNET_asprintf (&s_tran, "\"%s\" -> \"%s\" [label = \"ε\"];\n", name, |
231 | to_name, s->scc_id); | 230 | to_name); |
232 | } | 231 | } |
233 | } | 232 | } |
234 | else | 233 | else |
@@ -242,7 +241,7 @@ REGEX_TEST_automaton_save_graph_step (void *cls, unsigned int count, | |||
242 | else | 241 | else |
243 | { | 242 | { |
244 | GNUNET_asprintf (&s_tran, "\"%s\" -> \"%s\" [label = \"%s\"];\n", name, | 243 | GNUNET_asprintf (&s_tran, "\"%s\" -> \"%s\" [label = \"%s\"];\n", name, |
245 | to_name, ctran->label, s->scc_id); | 244 | to_name, ctran->label); |
246 | } | 245 | } |
247 | } | 246 | } |
248 | 247 | ||
diff --git a/src/revocation/Makefile.am b/src/revocation/Makefile.am index 9d98502a6..b1a079a0d 100644 --- a/src/revocation/Makefile.am +++ b/src/revocation/Makefile.am | |||
@@ -30,6 +30,7 @@ libgnunet_plugin_block_revocation_la_LIBADD = \ | |||
30 | $(top_builddir)/src/block/libgnunetblockgroup.la \ | 30 | $(top_builddir)/src/block/libgnunetblockgroup.la \ |
31 | $(top_builddir)/src/block/libgnunetblock.la \ | 31 | $(top_builddir)/src/block/libgnunetblock.la \ |
32 | $(top_builddir)/src/util/libgnunetutil.la \ | 32 | $(top_builddir)/src/util/libgnunetutil.la \ |
33 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
33 | $(LTLIBINTL) | 34 | $(LTLIBINTL) |
34 | libgnunet_plugin_block_revocation_la_DEPENDENCIES = \ | 35 | libgnunet_plugin_block_revocation_la_DEPENDENCIES = \ |
35 | libgnunetrevocation.la \ | 36 | libgnunetrevocation.la \ |
@@ -63,6 +64,7 @@ libgnunetrevocation_la_SOURCES = \ | |||
63 | revocation_api.c revocation.h | 64 | revocation_api.c revocation.h |
64 | libgnunetrevocation_la_LIBADD = \ | 65 | libgnunetrevocation_la_LIBADD = \ |
65 | $(top_builddir)/src/util/libgnunetutil.la \ | 66 | $(top_builddir)/src/util/libgnunetutil.la \ |
67 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
66 | $(LIBGCRYPT_LIBS) \ | 68 | $(LIBGCRYPT_LIBS) \ |
67 | $(GN_LIBINTL) $(XLIB) -lgcrypt | 69 | $(GN_LIBINTL) $(XLIB) -lgcrypt |
68 | libgnunetrevocation_la_LDFLAGS = \ | 70 | libgnunetrevocation_la_LDFLAGS = \ |
@@ -80,6 +82,7 @@ gnunet_service_revocation_LDADD = \ | |||
80 | $(top_builddir)/src/core/libgnunetcore.la \ | 82 | $(top_builddir)/src/core/libgnunetcore.la \ |
81 | $(top_builddir)/src/setu/libgnunetsetu.la \ | 83 | $(top_builddir)/src/setu/libgnunetsetu.la \ |
82 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 84 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
85 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
83 | $(top_builddir)/src/util/libgnunetutil.la \ | 86 | $(top_builddir)/src/util/libgnunetutil.la \ |
84 | -lm \ | 87 | -lm \ |
85 | $(GN_LIBINTL) | 88 | $(GN_LIBINTL) |
diff --git a/src/revocation/gnunet-revocation-tvg.c b/src/revocation/gnunet-revocation-tvg.c index 29df1bb4d..cb5e31fcd 100644 --- a/src/revocation/gnunet-revocation-tvg.c +++ b/src/revocation/gnunet-revocation-tvg.c | |||
@@ -65,25 +65,34 @@ run (void *cls, | |||
65 | const char *cfgfile, | 65 | const char *cfgfile, |
66 | const struct GNUNET_CONFIGURATION_Handle *cfg) | 66 | const struct GNUNET_CONFIGURATION_Handle *cfg) |
67 | { | 67 | { |
68 | struct GNUNET_CRYPTO_EcdsaPrivateKey id_priv; | 68 | struct GNUNET_IDENTITY_PrivateKey id_priv; |
69 | struct GNUNET_CRYPTO_EcdsaPublicKey id_pub; | 69 | struct GNUNET_IDENTITY_PublicKey id_pub; |
70 | struct GNUNET_REVOCATION_PowP pow; | 70 | struct GNUNET_REVOCATION_PowP *pow; |
71 | struct GNUNET_REVOCATION_PowCalculationHandle *ph; | 71 | struct GNUNET_REVOCATION_PowCalculationHandle *ph; |
72 | struct GNUNET_TIME_Relative exp; | 72 | struct GNUNET_TIME_Relative exp; |
73 | 73 | char ztld[128]; | |
74 | GNUNET_CRYPTO_ecdsa_key_create (&id_priv); | 74 | |
75 | GNUNET_CRYPTO_ecdsa_key_get_public (&id_priv, | 75 | id_priv.type = htonl (GNUNET_IDENTITY_TYPE_ECDSA); |
76 | &id_pub); | 76 | GNUNET_CRYPTO_ecdsa_key_create (&id_priv.ecdsa_key); |
77 | fprintf (stdout, "Zone private key (d, little-endian scalar):\n"); | 77 | GNUNET_IDENTITY_key_get_public (&id_priv, |
78 | print_bytes (&id_priv, sizeof(id_priv), 0); | 78 | &id_pub); |
79 | GNUNET_STRINGS_data_to_string (&id_pub, | ||
80 | GNUNET_IDENTITY_key_get_length (&id_pub), | ||
81 | ztld, | ||
82 | sizeof (ztld)); | ||
83 | fprintf (stdout, "Zone private key (d, little-endian scalar, with ztype prepended):\n"); | ||
84 | print_bytes (&id_priv, sizeof(id_priv), 8); | ||
85 | fprintf (stdout, "\n"); | ||
86 | fprintf (stdout, "Zone identifier (zid):\n"); | ||
87 | print_bytes (&id_pub, GNUNET_IDENTITY_key_get_length (&id_pub), 8); | ||
79 | fprintf (stdout, "\n"); | 88 | fprintf (stdout, "\n"); |
80 | fprintf (stdout, "Zone public key (zk):\n"); | 89 | fprintf (stdout, "Encoded zone identifier (zkl = zTLD):\n"); |
81 | print_bytes (&id_pub, sizeof(id_pub), 0); | 90 | fprintf (stdout, "%s\n", ztld); |
82 | fprintf (stdout, "\n"); | 91 | fprintf (stdout, "\n"); |
83 | memset (&pow, 0, sizeof (pow)); | 92 | pow = GNUNET_malloc (GNUNET_REVOCATION_MAX_PROOF_SIZE); |
84 | GNUNET_REVOCATION_pow_init (&id_priv, | 93 | GNUNET_REVOCATION_pow_init (&id_priv, |
85 | &pow); | 94 | pow); |
86 | ph = GNUNET_REVOCATION_pow_start (&pow, | 95 | ph = GNUNET_REVOCATION_pow_start (pow, |
87 | TEST_EPOCHS, | 96 | TEST_EPOCHS, |
88 | TEST_DIFFICULTY); | 97 | TEST_DIFFICULTY); |
89 | fprintf (stdout, "Difficulty (%d base difficulty + %d epochs): %d\n\n", | 98 | fprintf (stdout, "Difficulty (%d base difficulty + %d epochs): %d\n\n", |
@@ -97,12 +106,12 @@ run (void *cls, | |||
97 | } | 106 | } |
98 | exp = GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_YEARS, | 107 | exp = GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_YEARS, |
99 | TEST_EPOCHS); | 108 | TEST_EPOCHS); |
100 | GNUNET_assert (GNUNET_OK == GNUNET_REVOCATION_check_pow (&pow, | 109 | GNUNET_assert (GNUNET_OK == GNUNET_REVOCATION_check_pow (pow, |
101 | TEST_DIFFICULTY, | 110 | TEST_DIFFICULTY, |
102 | exp)); | 111 | exp)); |
103 | fprintf (stdout, "Proof:\n"); | 112 | fprintf (stdout, "Proof:\n"); |
104 | print_bytes (&pow, | 113 | print_bytes (pow, |
105 | sizeof (pow), | 114 | GNUNET_REVOCATION_proof_get_size (pow), |
106 | 8); | 115 | 8); |
107 | } | 116 | } |
108 | 117 | ||
diff --git a/src/revocation/gnunet-revocation.c b/src/revocation/gnunet-revocation.c index 0e1e482ab..d59ea7c81 100644 --- a/src/revocation/gnunet-revocation.c +++ b/src/revocation/gnunet-revocation.c | |||
@@ -101,7 +101,7 @@ static struct GNUNET_SCHEDULER_Task *pow_task; | |||
101 | /** | 101 | /** |
102 | * Proof-of-work object | 102 | * Proof-of-work object |
103 | */ | 103 | */ |
104 | static struct GNUNET_REVOCATION_PowP proof_of_work; | 104 | static struct GNUNET_REVOCATION_PowP *proof_of_work; |
105 | 105 | ||
106 | /** | 106 | /** |
107 | * Function run if the user aborts with CTRL-C. | 107 | * Function run if the user aborts with CTRL-C. |
@@ -213,7 +213,7 @@ static void | |||
213 | perform_revocation () | 213 | perform_revocation () |
214 | { | 214 | { |
215 | h = GNUNET_REVOCATION_revoke (cfg, | 215 | h = GNUNET_REVOCATION_revoke (cfg, |
216 | &proof_of_work, | 216 | proof_of_work, |
217 | &print_revocation_result, | 217 | &print_revocation_result, |
218 | NULL); | 218 | NULL); |
219 | } | 219 | } |
@@ -228,11 +228,12 @@ perform_revocation () | |||
228 | static void | 228 | static void |
229 | sync_pow () | 229 | sync_pow () |
230 | { | 230 | { |
231 | size_t psize = GNUNET_REVOCATION_proof_get_size (proof_of_work); | ||
231 | if ((NULL != filename) && | 232 | if ((NULL != filename) && |
232 | (sizeof(struct GNUNET_REVOCATION_PowP) != | 233 | (psize != |
233 | GNUNET_DISK_fn_write (filename, | 234 | GNUNET_DISK_fn_write (filename, |
234 | &proof_of_work, | 235 | proof_of_work, |
235 | sizeof(struct GNUNET_REVOCATION_PowP), | 236 | psize, |
236 | GNUNET_DISK_PERM_USER_READ | 237 | GNUNET_DISK_PERM_USER_READ |
237 | | GNUNET_DISK_PERM_USER_WRITE))) | 238 | | GNUNET_DISK_PERM_USER_WRITE))) |
238 | GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_ERROR, "write", filename); | 239 | GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_ERROR, "write", filename); |
@@ -269,6 +270,7 @@ static void | |||
269 | calculate_pow (void *cls) | 270 | calculate_pow (void *cls) |
270 | { | 271 | { |
271 | struct GNUNET_REVOCATION_PowCalculationHandle *ph = cls; | 272 | struct GNUNET_REVOCATION_PowCalculationHandle *ph = cls; |
273 | size_t psize; | ||
272 | 274 | ||
273 | /* store temporary results */ | 275 | /* store temporary results */ |
274 | pow_task = NULL; | 276 | pow_task = NULL; |
@@ -277,11 +279,12 @@ calculate_pow (void *cls) | |||
277 | /* actually do POW calculation */ | 279 | /* actually do POW calculation */ |
278 | if (GNUNET_OK == GNUNET_REVOCATION_pow_round (ph)) | 280 | if (GNUNET_OK == GNUNET_REVOCATION_pow_round (ph)) |
279 | { | 281 | { |
282 | psize = GNUNET_REVOCATION_proof_get_size (proof_of_work); | ||
280 | if ((NULL != filename) && | 283 | if ((NULL != filename) && |
281 | (sizeof(struct GNUNET_REVOCATION_PowP) != | 284 | (psize != |
282 | GNUNET_DISK_fn_write (filename, | 285 | GNUNET_DISK_fn_write (filename, |
283 | &proof_of_work, | 286 | proof_of_work, |
284 | sizeof(struct GNUNET_REVOCATION_PowP), | 287 | psize, |
285 | GNUNET_DISK_PERM_USER_READ | 288 | GNUNET_DISK_PERM_USER_READ |
286 | | GNUNET_DISK_PERM_USER_WRITE))) | 289 | | GNUNET_DISK_PERM_USER_WRITE))) |
287 | GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_ERROR, "write", filename); | 290 | GNUNET_log_strerror_file (GNUNET_ERROR_TYPE_ERROR, "write", filename); |
@@ -325,9 +328,10 @@ calculate_pow (void *cls) | |||
325 | static void | 328 | static void |
326 | ego_callback (void *cls, struct GNUNET_IDENTITY_Ego *ego) | 329 | ego_callback (void *cls, struct GNUNET_IDENTITY_Ego *ego) |
327 | { | 330 | { |
328 | struct GNUNET_CRYPTO_EcdsaPublicKey key; | 331 | struct GNUNET_IDENTITY_PublicKey key; |
329 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *privkey; | 332 | const struct GNUNET_IDENTITY_PrivateKey *privkey; |
330 | struct GNUNET_REVOCATION_PowCalculationHandle *ph = NULL; | 333 | struct GNUNET_REVOCATION_PowCalculationHandle *ph = NULL; |
334 | size_t psize; | ||
331 | 335 | ||
332 | el = NULL; | 336 | el = NULL; |
333 | if (NULL == ego) | 337 | if (NULL == ego) |
@@ -338,12 +342,15 @@ ego_callback (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
338 | } | 342 | } |
339 | GNUNET_IDENTITY_ego_get_public_key (ego, &key); | 343 | GNUNET_IDENTITY_ego_get_public_key (ego, &key); |
340 | privkey = GNUNET_IDENTITY_ego_get_private_key (ego); | 344 | privkey = GNUNET_IDENTITY_ego_get_private_key (ego); |
341 | memset (&proof_of_work, 0, sizeof (proof_of_work)); | 345 | proof_of_work = GNUNET_malloc (GNUNET_REVOCATION_MAX_PROOF_SIZE); |
342 | if ((NULL != filename) && (GNUNET_YES == GNUNET_DISK_file_test (filename)) && | 346 | if ((NULL != filename) && (GNUNET_YES == GNUNET_DISK_file_test (filename)) && |
343 | (sizeof(proof_of_work) == | 347 | (0 < (psize = |
344 | GNUNET_DISK_fn_read (filename, &proof_of_work, sizeof(proof_of_work)))) | 348 | GNUNET_DISK_fn_read (filename, proof_of_work, |
349 | GNUNET_REVOCATION_MAX_PROOF_SIZE)))) | ||
345 | { | 350 | { |
346 | if (0 != GNUNET_memcmp (&proof_of_work.key, &key)) | 351 | size_t ksize = GNUNET_IDENTITY_key_get_length (&key); |
352 | if (((psize - sizeof (*proof_of_work)) < ksize) || // Key too small | ||
353 | (0 != memcmp (&proof_of_work[1], &key, ksize))) // Keys do not match | ||
347 | { | 354 | { |
348 | fprintf (stderr, | 355 | fprintf (stderr, |
349 | _ ("Error: revocation certificate in `%s' is not for `%s'\n"), | 356 | _ ("Error: revocation certificate in `%s' is not for `%s'\n"), |
@@ -352,7 +359,7 @@ ego_callback (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
352 | return; | 359 | return; |
353 | } | 360 | } |
354 | if (GNUNET_YES == | 361 | if (GNUNET_YES == |
355 | GNUNET_REVOCATION_check_pow (&proof_of_work, | 362 | GNUNET_REVOCATION_check_pow (proof_of_work, |
356 | (unsigned int) matching_bits, | 363 | (unsigned int) matching_bits, |
357 | epoch_duration)) | 364 | epoch_duration)) |
358 | { | 365 | { |
@@ -369,7 +376,7 @@ ego_callback (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
369 | fprintf (stderr, | 376 | fprintf (stderr, |
370 | "%s", | 377 | "%s", |
371 | _ ("Continuing calculation where left off...\n")); | 378 | _ ("Continuing calculation where left off...\n")); |
372 | ph = GNUNET_REVOCATION_pow_start (&proof_of_work, | 379 | ph = GNUNET_REVOCATION_pow_start (proof_of_work, |
373 | epochs, | 380 | epochs, |
374 | matching_bits); | 381 | matching_bits); |
375 | } | 382 | } |
@@ -379,8 +386,8 @@ ego_callback (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
379 | if (NULL == ph) | 386 | if (NULL == ph) |
380 | { | 387 | { |
381 | GNUNET_REVOCATION_pow_init (privkey, | 388 | GNUNET_REVOCATION_pow_init (privkey, |
382 | &proof_of_work); | 389 | proof_of_work); |
383 | ph = GNUNET_REVOCATION_pow_start (&proof_of_work, | 390 | ph = GNUNET_REVOCATION_pow_start (proof_of_work, |
384 | epochs, /* Epochs */ | 391 | epochs, /* Epochs */ |
385 | matching_bits); | 392 | matching_bits); |
386 | } | 393 | } |
@@ -403,15 +410,15 @@ run (void *cls, | |||
403 | const char *cfgfile, | 410 | const char *cfgfile, |
404 | const struct GNUNET_CONFIGURATION_Handle *c) | 411 | const struct GNUNET_CONFIGURATION_Handle *c) |
405 | { | 412 | { |
406 | struct GNUNET_CRYPTO_EcdsaPublicKey pk; | 413 | struct GNUNET_IDENTITY_PublicKey pk; |
414 | size_t psize; | ||
407 | 415 | ||
408 | cfg = c; | 416 | cfg = c; |
409 | if (NULL != test_ego) | 417 | if (NULL != test_ego) |
410 | { | 418 | { |
411 | if (GNUNET_OK != | 419 | if (GNUNET_OK != |
412 | GNUNET_CRYPTO_ecdsa_public_key_from_string (test_ego, | 420 | GNUNET_IDENTITY_public_key_from_string (test_ego, |
413 | strlen (test_ego), | 421 | &pk)) |
414 | &pk)) | ||
415 | { | 422 | { |
416 | fprintf (stderr, _ ("Public key `%s' malformed\n"), test_ego); | 423 | fprintf (stderr, _ ("Public key `%s' malformed\n"), test_ego); |
417 | return; | 424 | return; |
@@ -463,23 +470,33 @@ run (void *cls, | |||
463 | } | 470 | } |
464 | if ((NULL != filename) && (perform)) | 471 | if ((NULL != filename) && (perform)) |
465 | { | 472 | { |
466 | if (sizeof(proof_of_work) != GNUNET_DISK_fn_read (filename, | 473 | size_t bread; |
467 | &proof_of_work, | 474 | proof_of_work = GNUNET_malloc (GNUNET_REVOCATION_MAX_PROOF_SIZE); |
468 | sizeof(proof_of_work))) | 475 | if (0 < (bread = GNUNET_DISK_fn_read (filename, |
476 | proof_of_work, | ||
477 | GNUNET_REVOCATION_MAX_PROOF_SIZE))) | ||
469 | { | 478 | { |
470 | fprintf (stderr, | 479 | fprintf (stderr, |
471 | _ ("Failed to read revocation certificate from `%s'\n"), | 480 | _ ("Failed to read revocation certificate from `%s'\n"), |
472 | filename); | 481 | filename); |
473 | return; | 482 | return; |
474 | } | 483 | } |
484 | psize = GNUNET_REVOCATION_proof_get_size (proof_of_work); | ||
485 | if (bread != psize) | ||
486 | { | ||
487 | fprintf (stderr, | ||
488 | _ ("Revocation certificate corrupted in `%s'\n"), | ||
489 | filename); | ||
490 | return; | ||
491 | } | ||
475 | GNUNET_SCHEDULER_add_shutdown (&do_shutdown, NULL); | 492 | GNUNET_SCHEDULER_add_shutdown (&do_shutdown, NULL); |
476 | if (GNUNET_YES != | 493 | if (GNUNET_YES != |
477 | GNUNET_REVOCATION_check_pow (&proof_of_work, | 494 | GNUNET_REVOCATION_check_pow (proof_of_work, |
478 | (unsigned int) matching_bits, | 495 | (unsigned int) matching_bits, |
479 | epoch_duration)) | 496 | epoch_duration)) |
480 | { | 497 | { |
481 | struct GNUNET_REVOCATION_PowCalculationHandle *ph; | 498 | struct GNUNET_REVOCATION_PowCalculationHandle *ph; |
482 | ph = GNUNET_REVOCATION_pow_start (&proof_of_work, | 499 | ph = GNUNET_REVOCATION_pow_start (proof_of_work, |
483 | epochs, /* Epochs */ | 500 | epochs, /* Epochs */ |
484 | matching_bits); | 501 | matching_bits); |
485 | 502 | ||
diff --git a/src/revocation/gnunet-service-revocation.c b/src/revocation/gnunet-service-revocation.c index ddebb38ad..0fa92f4a6 100644 --- a/src/revocation/gnunet-service-revocation.c +++ b/src/revocation/gnunet-service-revocation.c | |||
@@ -172,7 +172,8 @@ new_peer_entry (const struct GNUNET_PeerIdentity *peer) | |||
172 | static int | 172 | static int |
173 | verify_revoke_message (const struct RevokeMessage *rm) | 173 | verify_revoke_message (const struct RevokeMessage *rm) |
174 | { | 174 | { |
175 | if (GNUNET_YES != GNUNET_REVOCATION_check_pow (&rm->proof_of_work, | 175 | struct GNUNET_REVOCATION_PowP *pow = (struct GNUNET_REVOCATION_PowP *) &rm[1]; |
176 | if (GNUNET_YES != GNUNET_REVOCATION_check_pow (pow, | ||
176 | (unsigned | 177 | (unsigned |
177 | int) revocation_work_required, | 178 | int) revocation_work_required, |
178 | epoch_duration)) | 179 | epoch_duration)) |
@@ -236,7 +237,7 @@ handle_query_message (void *cls, | |||
236 | int res; | 237 | int res; |
237 | 238 | ||
238 | GNUNET_CRYPTO_hash (&qm->key, | 239 | GNUNET_CRYPTO_hash (&qm->key, |
239 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey), | 240 | sizeof(struct GNUNET_IDENTITY_PublicKey), |
240 | &hc); | 241 | &hc); |
241 | res = GNUNET_CONTAINER_multihashmap_contains (revocation_map, | 242 | res = GNUNET_CONTAINER_multihashmap_contains (revocation_map, |
242 | &hc); | 243 | &hc); |
@@ -276,9 +277,11 @@ do_flood (void *cls, | |||
276 | return GNUNET_OK; /* peer connected to us via SET, | 277 | return GNUNET_OK; /* peer connected to us via SET, |
277 | but we have no direct CORE | 278 | but we have no direct CORE |
278 | connection for flooding */ | 279 | connection for flooding */ |
279 | e = GNUNET_MQ_msg (cp, | 280 | e = GNUNET_MQ_msg_extra (cp, |
281 | htonl (rm->pow_size), | ||
280 | GNUNET_MESSAGE_TYPE_REVOCATION_REVOKE); | 282 | GNUNET_MESSAGE_TYPE_REVOCATION_REVOKE); |
281 | *cp = *rm; | 283 | *cp = *rm; |
284 | memcpy (&cp[1], &rm[1], htonl (rm->pow_size)); | ||
282 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 285 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
283 | "Flooding revocation to `%s'\n", | 286 | "Flooding revocation to `%s'\n", |
284 | GNUNET_i2s (target)); | 287 | GNUNET_i2s (target)); |
@@ -303,9 +306,12 @@ publicize_rm (const struct RevokeMessage *rm) | |||
303 | struct RevokeMessage *cp; | 306 | struct RevokeMessage *cp; |
304 | struct GNUNET_HashCode hc; | 307 | struct GNUNET_HashCode hc; |
305 | struct GNUNET_SETU_Element e; | 308 | struct GNUNET_SETU_Element e; |
309 | const struct GNUNET_IDENTITY_PublicKey *pk; | ||
306 | 310 | ||
307 | GNUNET_CRYPTO_hash (&rm->proof_of_work.key, | 311 | struct GNUNET_REVOCATION_PowP *pow = (struct GNUNET_REVOCATION_PowP *) &rm[1]; |
308 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey), | 312 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; |
313 | GNUNET_CRYPTO_hash (pk, | ||
314 | GNUNET_IDENTITY_key_get_length (pk), | ||
309 | &hc); | 315 | &hc); |
310 | if (GNUNET_YES == | 316 | if (GNUNET_YES == |
311 | GNUNET_CONTAINER_multihashmap_contains (revocation_map, | 317 | GNUNET_CONTAINER_multihashmap_contains (revocation_map, |
@@ -371,6 +377,23 @@ publicize_rm (const struct RevokeMessage *rm) | |||
371 | } | 377 | } |
372 | 378 | ||
373 | 379 | ||
380 | static int | ||
381 | check_revoke_message (void *cls, | ||
382 | const struct RevokeMessage *rm) | ||
383 | { | ||
384 | uint16_t size; | ||
385 | |||
386 | size = ntohs (rm->header.size); | ||
387 | if (size <= sizeof(struct RevokeMessage)) | ||
388 | { | ||
389 | GNUNET_break (0); | ||
390 | return GNUNET_SYSERR; | ||
391 | } | ||
392 | return GNUNET_OK; | ||
393 | |||
394 | } | ||
395 | |||
396 | |||
374 | /** | 397 | /** |
375 | * Handle REVOKE message from client. | 398 | * Handle REVOKE message from client. |
376 | * | 399 | * |
@@ -403,6 +426,23 @@ handle_revoke_message (void *cls, | |||
403 | } | 426 | } |
404 | 427 | ||
405 | 428 | ||
429 | static int | ||
430 | check_p2p_revoke (void *cls, | ||
431 | const struct RevokeMessage *rm) | ||
432 | { | ||
433 | uint16_t size; | ||
434 | |||
435 | size = ntohs (rm->header.size); | ||
436 | if (size <= sizeof(struct RevokeMessage)) | ||
437 | { | ||
438 | GNUNET_break (0); | ||
439 | return GNUNET_SYSERR; | ||
440 | } | ||
441 | return GNUNET_OK; | ||
442 | |||
443 | } | ||
444 | |||
445 | |||
406 | /** | 446 | /** |
407 | * Core handler for flooded revocation messages. | 447 | * Core handler for flooded revocation messages. |
408 | * | 448 | * |
@@ -784,16 +824,17 @@ run (void *cls, | |||
784 | struct GNUNET_SERVICE_Handle *service) | 824 | struct GNUNET_SERVICE_Handle *service) |
785 | { | 825 | { |
786 | struct GNUNET_MQ_MessageHandler core_handlers[] = { | 826 | struct GNUNET_MQ_MessageHandler core_handlers[] = { |
787 | GNUNET_MQ_hd_fixed_size (p2p_revoke, | 827 | GNUNET_MQ_hd_var_size (p2p_revoke, |
788 | GNUNET_MESSAGE_TYPE_REVOCATION_REVOKE, | 828 | GNUNET_MESSAGE_TYPE_REVOCATION_REVOKE, |
789 | struct RevokeMessage, | 829 | struct RevokeMessage, |
790 | NULL), | 830 | NULL), |
791 | GNUNET_MQ_handler_end () | 831 | GNUNET_MQ_handler_end () |
792 | }; | 832 | }; |
793 | char *fn; | 833 | char *fn; |
794 | uint64_t left; | 834 | uint64_t left; |
795 | struct RevokeMessage *rm; | 835 | struct RevokeMessage *rm; |
796 | struct GNUNET_HashCode hc; | 836 | struct GNUNET_HashCode hc; |
837 | const struct GNUNET_IDENTITY_PublicKey *pk; | ||
797 | 838 | ||
798 | GNUNET_CRYPTO_hash ("revocation-set-union-application-id", | 839 | GNUNET_CRYPTO_hash ("revocation-set-union-application-id", |
799 | strlen ("revocation-set-union-application-id"), | 840 | strlen ("revocation-set-union-application-id"), |
@@ -892,9 +933,11 @@ run (void *cls, | |||
892 | GNUNET_free (fn); | 933 | GNUNET_free (fn); |
893 | return; | 934 | return; |
894 | } | 935 | } |
895 | GNUNET_break (0 == ntohl (rm->reserved)); | 936 | struct GNUNET_REVOCATION_PowP *pow = (struct |
896 | GNUNET_CRYPTO_hash (&rm->proof_of_work.key, | 937 | GNUNET_REVOCATION_PowP *) &rm[1]; |
897 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey), | 938 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; |
939 | GNUNET_CRYPTO_hash (pk, | ||
940 | GNUNET_IDENTITY_key_get_length (pk), | ||
898 | &hc); | 941 | &hc); |
899 | GNUNET_break (GNUNET_OK == | 942 | GNUNET_break (GNUNET_OK == |
900 | GNUNET_CONTAINER_multihashmap_put (revocation_map, | 943 | GNUNET_CONTAINER_multihashmap_put (revocation_map, |
@@ -939,10 +982,10 @@ GNUNET_SERVICE_MAIN | |||
939 | GNUNET_MESSAGE_TYPE_REVOCATION_QUERY, | 982 | GNUNET_MESSAGE_TYPE_REVOCATION_QUERY, |
940 | struct QueryMessage, | 983 | struct QueryMessage, |
941 | NULL), | 984 | NULL), |
942 | GNUNET_MQ_hd_fixed_size (revoke_message, | 985 | GNUNET_MQ_hd_var_size (revoke_message, |
943 | GNUNET_MESSAGE_TYPE_REVOCATION_REVOKE, | 986 | GNUNET_MESSAGE_TYPE_REVOCATION_REVOKE, |
944 | struct RevokeMessage, | 987 | struct RevokeMessage, |
945 | NULL), | 988 | NULL), |
946 | GNUNET_MQ_handler_end ()); | 989 | GNUNET_MQ_handler_end ()); |
947 | 990 | ||
948 | 991 | ||
diff --git a/src/revocation/plugin_block_revocation.c b/src/revocation/plugin_block_revocation.c index 291c56f70..3c9344a49 100644 --- a/src/revocation/plugin_block_revocation.c +++ b/src/revocation/plugin_block_revocation.c | |||
@@ -143,16 +143,18 @@ block_plugin_revocation_evaluate (void *cls, | |||
143 | GNUNET_break_op (0); | 143 | GNUNET_break_op (0); |
144 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | 144 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; |
145 | } | 145 | } |
146 | if (0 >= | 146 | struct GNUNET_REVOCATION_PowP *pow = (struct GNUNET_REVOCATION_PowP *) &rm[1]; |
147 | GNUNET_REVOCATION_check_pow (&rm->proof_of_work, | 147 | const struct GNUNET_IDENTITY_PublicKey *pk; |
148 | ic->matching_bits, | 148 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; |
149 | ic->epoch_duration)) | 149 | if (GNUNET_YES != GNUNET_REVOCATION_check_pow (pow, |
150 | ic->matching_bits, | ||
151 | ic->epoch_duration)) | ||
150 | { | 152 | { |
151 | GNUNET_break_op (0); | 153 | GNUNET_break_op (0); |
152 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | 154 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; |
153 | } | 155 | } |
154 | GNUNET_CRYPTO_hash (&rm->proof_of_work.key, | 156 | GNUNET_CRYPTO_hash (pk, |
155 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey), | 157 | GNUNET_IDENTITY_key_get_length (pk), |
156 | &chash); | 158 | &chash); |
157 | if (GNUNET_YES == | 159 | if (GNUNET_YES == |
158 | GNUNET_BLOCK_GROUP_bf_test_and_set (group, | 160 | GNUNET_BLOCK_GROUP_bf_test_and_set (group, |
@@ -182,13 +184,16 @@ block_plugin_revocation_get_key (void *cls, | |||
182 | { | 184 | { |
183 | const struct RevokeMessage *rm = block; | 185 | const struct RevokeMessage *rm = block; |
184 | 186 | ||
185 | if (block_size != sizeof(*rm)) | 187 | if (block_size <= sizeof(*rm)) |
186 | { | 188 | { |
187 | GNUNET_break_op (0); | 189 | GNUNET_break_op (0); |
188 | return GNUNET_SYSERR; | 190 | return GNUNET_SYSERR; |
189 | } | 191 | } |
190 | GNUNET_CRYPTO_hash (&rm->proof_of_work.key, | 192 | struct GNUNET_REVOCATION_PowP *pow = (struct GNUNET_REVOCATION_PowP *) &rm[1]; |
191 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey), | 193 | const struct GNUNET_IDENTITY_PublicKey *pk; |
194 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | ||
195 | GNUNET_CRYPTO_hash (pk, | ||
196 | GNUNET_IDENTITY_key_get_length (pk), | ||
192 | key); | 197 | key); |
193 | return GNUNET_OK; | 198 | return GNUNET_OK; |
194 | } | 199 | } |
diff --git a/src/revocation/revocation.h b/src/revocation/revocation.h index 635c56cfc..c3a9c9e6b 100644 --- a/src/revocation/revocation.h +++ b/src/revocation/revocation.h | |||
@@ -49,7 +49,7 @@ struct QueryMessage | |||
49 | /** | 49 | /** |
50 | * Key to check. | 50 | * Key to check. |
51 | */ | 51 | */ |
52 | struct GNUNET_CRYPTO_EcdsaPublicKey key; | 52 | struct GNUNET_IDENTITY_PublicKey key; |
53 | }; | 53 | }; |
54 | 54 | ||
55 | 55 | ||
@@ -85,14 +85,11 @@ struct RevokeMessage | |||
85 | struct GNUNET_MessageHeader header; | 85 | struct GNUNET_MessageHeader header; |
86 | 86 | ||
87 | /** | 87 | /** |
88 | * For alignment. | 88 | * Length of PoW with signature. |
89 | */ | 89 | */ |
90 | uint32_t reserved GNUNET_PACKED; | 90 | uint32_t pow_size GNUNET_PACKED; |
91 | 91 | ||
92 | /** | 92 | /** Followed by the PoW **/ |
93 | * Number that causes a hash collision with the @e public_key. | ||
94 | */ | ||
95 | struct GNUNET_REVOCATION_PowP proof_of_work; | ||
96 | }; | 93 | }; |
97 | 94 | ||
98 | 95 | ||
diff --git a/src/revocation/revocation_api.c b/src/revocation/revocation_api.c index 75cfd8761..791c3d008 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_CRYPTO_EcdsaPublicKey *key, | 163 | const struct GNUNET_IDENTITY_PublicKey *key, |
164 | GNUNET_REVOCATION_Callback func, | 164 | GNUNET_REVOCATION_Callback func, |
165 | void *func_cls) | 165 | void *func_cls) |
166 | { | 166 | { |
@@ -359,10 +359,12 @@ GNUNET_REVOCATION_revoke (const struct GNUNET_CONFIGURATION_Handle *cfg, | |||
359 | } | 359 | } |
360 | h->func = func; | 360 | h->func = func; |
361 | h->func_cls = func_cls; | 361 | h->func_cls = func_cls; |
362 | env = GNUNET_MQ_msg (rm, | 362 | size_t extra_len = GNUNET_REVOCATION_proof_get_size (pow); |
363 | GNUNET_MESSAGE_TYPE_REVOCATION_REVOKE); | 363 | env = GNUNET_MQ_msg_extra (rm, |
364 | rm->reserved = htonl (0); | 364 | extra_len, |
365 | rm->proof_of_work = *pow; | 365 | GNUNET_MESSAGE_TYPE_REVOCATION_REVOKE); |
366 | rm->pow_size = htonl (extra_len); | ||
367 | memcpy (&rm[1], pow, extra_len); | ||
366 | GNUNET_MQ_send (h->mq, | 368 | GNUNET_MQ_send (h->mq, |
367 | env); | 369 | env); |
368 | return h; | 370 | return h; |
@@ -420,6 +422,51 @@ calculate_score (const struct GNUNET_REVOCATION_PowCalculationHandle *ph) | |||
420 | } | 422 | } |
421 | 423 | ||
422 | 424 | ||
425 | enum GNUNET_GenericReturnValue | ||
426 | check_signature_identity (const struct GNUNET_REVOCATION_PowP *pow, | ||
427 | const struct GNUNET_IDENTITY_PublicKey *key) | ||
428 | { | ||
429 | struct GNUNET_REVOCATION_SignaturePurposePS *spurp; | ||
430 | struct GNUNET_IDENTITY_Signature *sig; | ||
431 | const struct GNUNET_IDENTITY_PublicKey *pk; | ||
432 | size_t ksize; | ||
433 | |||
434 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | ||
435 | ksize = GNUNET_IDENTITY_key_get_length (pk); | ||
436 | |||
437 | spurp = GNUNET_malloc (sizeof (*spurp) + ksize); | ||
438 | spurp->timestamp = pow->timestamp; | ||
439 | spurp->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_REVOCATION); | ||
440 | spurp->purpose.size = htonl (sizeof(*spurp) + ksize); | ||
441 | GNUNET_IDENTITY_write_key_to_buffer (pk, | ||
442 | (char*) &spurp[1], | ||
443 | ksize); | ||
444 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
445 | "Expected signature payload len: %u\n", | ||
446 | ntohl (spurp->purpose.size)); | ||
447 | sig = (struct GNUNET_IDENTITY_Signature *) ((char*) &pow[1] + ksize); | ||
448 | if (GNUNET_OK != | ||
449 | GNUNET_IDENTITY_signature_verify_ (GNUNET_SIGNATURE_PURPOSE_REVOCATION, | ||
450 | &spurp->purpose, | ||
451 | sig, | ||
452 | key)) | ||
453 | { | ||
454 | return GNUNET_SYSERR; | ||
455 | } | ||
456 | return GNUNET_OK; | ||
457 | } | ||
458 | |||
459 | |||
460 | enum GNUNET_GenericReturnValue | ||
461 | check_signature (const struct GNUNET_REVOCATION_PowP *pow) | ||
462 | { | ||
463 | const struct GNUNET_IDENTITY_PublicKey *pk; | ||
464 | |||
465 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | ||
466 | return check_signature_identity (pow, pk); | ||
467 | } | ||
468 | |||
469 | |||
423 | /** | 470 | /** |
424 | * Check if the given proof-of-work is valid. | 471 | * Check if the given proof-of-work is valid. |
425 | * | 472 | * |
@@ -433,10 +480,9 @@ GNUNET_REVOCATION_check_pow (const struct GNUNET_REVOCATION_PowP *pow, | |||
433 | unsigned int difficulty, | 480 | unsigned int difficulty, |
434 | struct GNUNET_TIME_Relative epoch_duration) | 481 | struct GNUNET_TIME_Relative epoch_duration) |
435 | { | 482 | { |
436 | char buf[sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) | 483 | char buf[sizeof(struct GNUNET_IDENTITY_PublicKey) |
437 | + sizeof (struct GNUNET_TIME_AbsoluteNBO) | 484 | + sizeof (struct GNUNET_TIME_AbsoluteNBO) |
438 | + sizeof (uint64_t)] GNUNET_ALIGN; | 485 | + sizeof (uint64_t)] GNUNET_ALIGN; |
439 | struct GNUNET_REVOCATION_SignaturePurposePS spurp; | ||
440 | struct GNUNET_HashCode result; | 486 | struct GNUNET_HashCode result; |
441 | struct GNUNET_TIME_Absolute ts; | 487 | struct GNUNET_TIME_Absolute ts; |
442 | struct GNUNET_TIME_Absolute exp; | 488 | struct GNUNET_TIME_Absolute exp; |
@@ -446,25 +492,18 @@ GNUNET_REVOCATION_check_pow (const struct GNUNET_REVOCATION_PowP *pow, | |||
446 | unsigned int tmp_score = 0; | 492 | unsigned int tmp_score = 0; |
447 | unsigned int epochs; | 493 | unsigned int epochs; |
448 | uint64_t pow_val; | 494 | uint64_t pow_val; |
495 | const struct GNUNET_IDENTITY_PublicKey *pk; | ||
496 | |||
497 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | ||
449 | 498 | ||
450 | /** | 499 | /** |
451 | * Check if signature valid | 500 | * Check if signature valid |
452 | */ | 501 | */ |
453 | spurp.key = pow->key; | 502 | if (GNUNET_OK != check_signature (pow)) |
454 | spurp.timestamp = pow->timestamp; | ||
455 | spurp.purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_REVOCATION); | ||
456 | spurp.purpose.size = htonl (sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) | ||
457 | + sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) | ||
458 | + sizeof (struct GNUNET_TIME_AbsoluteNBO)); | ||
459 | if (GNUNET_OK != | ||
460 | GNUNET_CRYPTO_ecdsa_verify_ (GNUNET_SIGNATURE_PURPOSE_REVOCATION, | ||
461 | &spurp.purpose, | ||
462 | &pow->signature, | ||
463 | &pow->key)) | ||
464 | { | 503 | { |
465 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | 504 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, |
466 | "Proof of work signature invalid!\n"); | 505 | "Proof of work signature invalid!\n"); |
467 | return GNUNET_NO; | 506 | return GNUNET_SYSERR; |
468 | } | 507 | } |
469 | 508 | ||
470 | /** | 509 | /** |
@@ -479,8 +518,8 @@ GNUNET_REVOCATION_check_pow (const struct GNUNET_REVOCATION_PowP *pow, | |||
479 | &pow->timestamp, | 518 | &pow->timestamp, |
480 | sizeof (uint64_t)); | 519 | sizeof (uint64_t)); |
481 | GNUNET_memcpy (&buf[sizeof(uint64_t) * 2], | 520 | GNUNET_memcpy (&buf[sizeof(uint64_t) * 2], |
482 | &pow->key, | 521 | pk, |
483 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey)); | 522 | GNUNET_IDENTITY_key_get_length (pk)); |
484 | for (unsigned int i = 0; i < POW_COUNT; i++) | 523 | for (unsigned int i = 0; i < POW_COUNT; i++) |
485 | { | 524 | { |
486 | pow_val = GNUNET_ntohll (pow->pow[i]); | 525 | pow_val = GNUNET_ntohll (pow->pow[i]); |
@@ -529,18 +568,15 @@ GNUNET_REVOCATION_check_pow (const struct GNUNET_REVOCATION_PowP *pow, | |||
529 | } | 568 | } |
530 | 569 | ||
531 | 570 | ||
532 | /** | 571 | enum GNUNET_GenericReturnValue |
533 | * Initializes a fresh PoW computation. | 572 | sign_pow_identity (const struct GNUNET_IDENTITY_PrivateKey *key, |
534 | * | 573 | struct GNUNET_REVOCATION_PowP *pow) |
535 | * @param key the key to calculate the PoW for. | ||
536 | * @param[out] pow starting point for PoW calculation (not yet valid) | ||
537 | */ | ||
538 | void | ||
539 | GNUNET_REVOCATION_pow_init (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | ||
540 | struct GNUNET_REVOCATION_PowP *pow) | ||
541 | { | 574 | { |
542 | struct GNUNET_TIME_Absolute ts = GNUNET_TIME_absolute_get (); | 575 | struct GNUNET_TIME_Absolute ts = GNUNET_TIME_absolute_get (); |
543 | struct GNUNET_REVOCATION_SignaturePurposePS rp; | 576 | struct GNUNET_REVOCATION_SignaturePurposePS *rp; |
577 | const struct GNUNET_IDENTITY_PublicKey *pk; | ||
578 | size_t ksize; | ||
579 | char *sig; | ||
544 | 580 | ||
545 | /** | 581 | /** |
546 | * Predate the validity period to prevent rejections due to | 582 | * Predate the validity period to prevent rejections due to |
@@ -548,19 +584,53 @@ GNUNET_REVOCATION_pow_init (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | |||
548 | */ | 584 | */ |
549 | ts = GNUNET_TIME_absolute_subtract (ts, | 585 | ts = GNUNET_TIME_absolute_subtract (ts, |
550 | GNUNET_TIME_UNIT_WEEKS); | 586 | GNUNET_TIME_UNIT_WEEKS); |
551 | 587 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | |
588 | ksize = GNUNET_IDENTITY_key_get_length (pk); | ||
552 | pow->timestamp = GNUNET_TIME_absolute_hton (ts); | 589 | pow->timestamp = GNUNET_TIME_absolute_hton (ts); |
553 | rp.timestamp = pow->timestamp; | 590 | rp = GNUNET_malloc (sizeof (*rp) + ksize); |
554 | rp.purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_REVOCATION); | 591 | rp->timestamp = pow->timestamp; |
555 | rp.purpose.size = htonl (sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) | 592 | rp->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_REVOCATION); |
556 | + sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) | 593 | rp->purpose.size = htonl (sizeof(*rp) + ksize); |
557 | + sizeof (struct GNUNET_TIME_AbsoluteNBO)); | 594 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
558 | GNUNET_CRYPTO_ecdsa_key_get_public (key, &pow->key); | 595 | "Signature payload len: %u\n", |
559 | rp.key = pow->key; | 596 | ntohl (rp->purpose.size)); |
560 | GNUNET_assert (GNUNET_OK == | 597 | GNUNET_IDENTITY_write_key_to_buffer (pk, |
561 | GNUNET_CRYPTO_ecdsa_sign_ (key, | 598 | ((char*) &rp[1]), |
562 | &rp.purpose, | 599 | ksize); |
563 | &pow->signature)); | 600 | sig = ((char*) &pow[1]) + ksize; |
601 | int result = GNUNET_IDENTITY_sign_ (key, | ||
602 | &rp->purpose, | ||
603 | (void*) sig); | ||
604 | if (result == GNUNET_SYSERR) | ||
605 | return GNUNET_NO; | ||
606 | else | ||
607 | return result; | ||
608 | } | ||
609 | |||
610 | |||
611 | enum GNUNET_GenericReturnValue | ||
612 | sign_pow (const struct GNUNET_IDENTITY_PrivateKey *key, | ||
613 | struct GNUNET_REVOCATION_PowP *pow) | ||
614 | { | ||
615 | struct GNUNET_IDENTITY_PublicKey *pk; | ||
616 | |||
617 | pk = (struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | ||
618 | GNUNET_IDENTITY_key_get_public (key, pk); | ||
619 | return sign_pow_identity (key, pow); | ||
620 | } | ||
621 | |||
622 | |||
623 | /** | ||
624 | * Initializes a fresh PoW computation. | ||
625 | * | ||
626 | * @param key the key to calculate the PoW for. | ||
627 | * @param[out] pow starting point for PoW calculation (not yet valid) | ||
628 | */ | ||
629 | void | ||
630 | GNUNET_REVOCATION_pow_init (const struct GNUNET_IDENTITY_PrivateKey *key, | ||
631 | struct GNUNET_REVOCATION_PowP *pow) | ||
632 | { | ||
633 | GNUNET_assert (GNUNET_OK == sign_pow (key, pow)); | ||
564 | } | 634 | } |
565 | 635 | ||
566 | 636 | ||
@@ -622,15 +692,17 @@ cmp_pow_value (const void *a, const void *b) | |||
622 | enum GNUNET_GenericReturnValue | 692 | enum GNUNET_GenericReturnValue |
623 | GNUNET_REVOCATION_pow_round (struct GNUNET_REVOCATION_PowCalculationHandle *pc) | 693 | GNUNET_REVOCATION_pow_round (struct GNUNET_REVOCATION_PowCalculationHandle *pc) |
624 | { | 694 | { |
625 | char buf[sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey) | 695 | char buf[sizeof(struct GNUNET_IDENTITY_PublicKey) |
626 | + sizeof (uint64_t) | 696 | + sizeof (uint64_t) |
627 | + sizeof (uint64_t)] GNUNET_ALIGN; | 697 | + sizeof (uint64_t)] GNUNET_ALIGN; |
628 | struct GNUNET_HashCode result; | 698 | struct GNUNET_HashCode result; |
699 | const struct GNUNET_IDENTITY_PublicKey *pk; | ||
629 | unsigned int zeros; | 700 | unsigned int zeros; |
630 | int ret; | 701 | int ret; |
631 | uint64_t pow_nbo; | 702 | uint64_t pow_nbo; |
632 | 703 | ||
633 | pc->current_pow++; | 704 | pc->current_pow++; |
705 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &(pc->pow[1]); | ||
634 | 706 | ||
635 | /** | 707 | /** |
636 | * Do not try duplicates | 708 | * Do not try duplicates |
@@ -644,8 +716,8 @@ GNUNET_REVOCATION_pow_round (struct GNUNET_REVOCATION_PowCalculationHandle *pc) | |||
644 | &pc->pow->timestamp, | 716 | &pc->pow->timestamp, |
645 | sizeof (uint64_t)); | 717 | sizeof (uint64_t)); |
646 | GNUNET_memcpy (&buf[sizeof(uint64_t) * 2], | 718 | GNUNET_memcpy (&buf[sizeof(uint64_t) * 2], |
647 | &pc->pow->key, | 719 | pk, |
648 | sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey)); | 720 | GNUNET_IDENTITY_key_get_length (pk)); |
649 | GNUNET_CRYPTO_pow_hash (&salt, | 721 | GNUNET_CRYPTO_pow_hash (&salt, |
650 | buf, | 722 | buf, |
651 | sizeof(buf), | 723 | sizeof(buf), |
@@ -690,4 +762,22 @@ GNUNET_REVOCATION_pow_stop (struct GNUNET_REVOCATION_PowCalculationHandle *pc) | |||
690 | } | 762 | } |
691 | 763 | ||
692 | 764 | ||
765 | size_t | ||
766 | GNUNET_REVOCATION_proof_get_size (const struct GNUNET_REVOCATION_PowP *pow) | ||
767 | { | ||
768 | size_t size; | ||
769 | size_t ksize; | ||
770 | const struct GNUNET_IDENTITY_PublicKey *pk; | ||
771 | const struct GNUNET_IDENTITY_Signature *sig; | ||
772 | |||
773 | size = sizeof (struct GNUNET_REVOCATION_PowP); | ||
774 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | ||
775 | ksize = GNUNET_IDENTITY_key_get_length (pk); | ||
776 | size += ksize; | ||
777 | sig = (struct GNUNET_IDENTITY_Signature *) ((char*) &pow[1] + ksize); | ||
778 | size += GNUNET_IDENTITY_signature_get_length (sig); | ||
779 | return size; | ||
780 | } | ||
781 | |||
782 | |||
693 | /* end of revocation_api.c */ | 783 | /* end of revocation_api.c */ |
diff --git a/src/revocation/test_revocation.c b/src/revocation/test_revocation.c index b65567d79..c6457016f 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_CRYPTO_EcdsaPrivateKey *privkey; | 41 | const struct GNUNET_IDENTITY_PrivateKey *privkey; |
42 | struct GNUNET_CRYPTO_EcdsaPublicKey pubkey; | 42 | struct GNUNET_IDENTITY_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; |
@@ -142,13 +142,13 @@ revocation_cb (void *cls, enum GNUNET_GenericReturnValue is_valid) | |||
142 | } | 142 | } |
143 | 143 | ||
144 | 144 | ||
145 | static struct GNUNET_REVOCATION_PowP proof_of_work; | 145 | static struct GNUNET_REVOCATION_PowP *proof_of_work; |
146 | 146 | ||
147 | static void | 147 | 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_CRYPTO_EcdsaPrivateKey *privkey; | 151 | const struct GNUNET_IDENTITY_PrivateKey *privkey; |
152 | 152 | ||
153 | if ((NULL != ego) && (cls == &testpeers[0])) | 153 | if ((NULL != ego) && (cls == &testpeers[0])) |
154 | { | 154 | { |
@@ -164,10 +164,10 @@ ego_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
164 | GNUNET_IDENTITY_ego_get_public_key (ego, &testpeers[1].pubkey); | 164 | GNUNET_IDENTITY_ego_get_public_key (ego, &testpeers[1].pubkey); |
165 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, "Calculating proof of work...\n"); | 165 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, "Calculating proof of work...\n"); |
166 | privkey = GNUNET_IDENTITY_ego_get_private_key (ego); | 166 | privkey = GNUNET_IDENTITY_ego_get_private_key (ego); |
167 | memset (&proof_of_work, 0, sizeof (proof_of_work)); | 167 | proof_of_work = GNUNET_malloc (GNUNET_REVOCATION_MAX_PROOF_SIZE); |
168 | GNUNET_REVOCATION_pow_init (privkey, | 168 | GNUNET_REVOCATION_pow_init (privkey, |
169 | &proof_of_work); | 169 | proof_of_work); |
170 | testpeers[1].pow = GNUNET_REVOCATION_pow_start (&proof_of_work, | 170 | testpeers[1].pow = GNUNET_REVOCATION_pow_start (proof_of_work, |
171 | 1, | 171 | 1, |
172 | 5); | 172 | 5); |
173 | int res = | 173 | int res = |
@@ -184,7 +184,7 @@ ego_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
184 | { | 184 | { |
185 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, "Egos retrieved\n"); | 185 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, "Egos retrieved\n"); |
186 | testpeers[1].revok_handle = GNUNET_REVOCATION_revoke (testpeers[1].cfg, | 186 | testpeers[1].revok_handle = GNUNET_REVOCATION_revoke (testpeers[1].cfg, |
187 | &proof_of_work, | 187 | proof_of_work, |
188 | &revocation_cb, | 188 | &revocation_cb, |
189 | NULL); | 189 | NULL); |
190 | GNUNET_REVOCATION_pow_stop (testpeers[1].pow); | 190 | GNUNET_REVOCATION_pow_stop (testpeers[1].pow); |
@@ -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_CRYPTO_EcdsaPrivateKey *pk, | 197 | const struct GNUNET_IDENTITY_PrivateKey *pk, |
198 | const char *emsg) | 198 | const char *emsg) |
199 | { | 199 | { |
200 | static int completed = 0; | 200 | static int completed = 0; |
@@ -238,11 +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 | &identity_create_cb, | 242 | &identity_create_cb, |
242 | &testpeers[0]); | 243 | &testpeers[0]); |
243 | testpeers[1].create_id_op = GNUNET_IDENTITY_create (testpeers[1].idh, | 244 | testpeers[1].create_id_op = GNUNET_IDENTITY_create (testpeers[1].idh, |
244 | "toberevoked", | 245 | "toberevoked", |
245 | NULL, | 246 | NULL, |
247 | GNUNET_IDENTITY_TYPE_ECDSA, | ||
246 | &identity_create_cb, | 248 | &identity_create_cb, |
247 | &testpeers[1]); | 249 | &testpeers[1]); |
248 | } | 250 | } |
diff --git a/src/set/gnunet-service-set_union.c b/src/set/gnunet-service-set_union.c index 87c6faf98..931d7e753 100644 --- a/src/set/gnunet-service-set_union.c +++ b/src/set/gnunet-service-set_union.c | |||
@@ -563,8 +563,8 @@ prepare_ibf_iterator (void *cls, | |||
563 | struct IBF_Key salted_key; | 563 | struct IBF_Key salted_key; |
564 | 564 | ||
565 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 565 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
566 | "[OP %x] inserting %lx (hash %s) into ibf\n", | 566 | "[OP %p] inserting %lx (hash %s) into ibf\n", |
567 | (void *) op, | 567 | op, |
568 | (unsigned long) ke->ibf_key.key_val, | 568 | (unsigned long) ke->ibf_key.key_val, |
569 | GNUNET_h2s (&ke->element->element_hash)); | 569 | GNUNET_h2s (&ke->element->element_hash)); |
570 | salt_key (&ke->ibf_key, | 570 | salt_key (&ke->ibf_key, |
@@ -929,7 +929,7 @@ handle_union_p2p_strata_estimator (void *cls, | |||
929 | (0 == other_size)) | 929 | (0 == other_size)) |
930 | { | 930 | { |
931 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 931 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
932 | "Deciding to go for full set transmission (diff=%d, own set=%u)\n", | 932 | "Deciding to go for full set transmission (diff=%d, own set=%llu)\n", |
933 | diff, | 933 | diff, |
934 | op->state->initial_size); | 934 | op->state->initial_size); |
935 | GNUNET_STATISTICS_update (_GSS_statistics, | 935 | GNUNET_STATISTICS_update (_GSS_statistics, |
@@ -1004,8 +1004,8 @@ send_offers_iterator (void *cls, | |||
1004 | GNUNET_assert (NULL != ev); | 1004 | GNUNET_assert (NULL != ev); |
1005 | *(struct GNUNET_HashCode *) &mh[1] = ke->element->element_hash; | 1005 | *(struct GNUNET_HashCode *) &mh[1] = ke->element->element_hash; |
1006 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1006 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1007 | "[OP %x] sending element offer (%s) to peer\n", | 1007 | "[OP %p] sending element offer (%s) to peer\n", |
1008 | (void *) op, | 1008 | op, |
1009 | GNUNET_h2s (&ke->element->element_hash)); | 1009 | GNUNET_h2s (&ke->element->element_hash)); |
1010 | GNUNET_MQ_send (op->mq, ev); | 1010 | GNUNET_MQ_send (op->mq, ev); |
1011 | return GNUNET_YES; | 1011 | return GNUNET_YES; |
@@ -2004,8 +2004,8 @@ handle_union_p2p_demand (void *cls, | |||
2004 | emsg->reserved = htons (0); | 2004 | emsg->reserved = htons (0); |
2005 | emsg->element_type = htons (ee->element.element_type); | 2005 | emsg->element_type = htons (ee->element.element_type); |
2006 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 2006 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
2007 | "[OP %x] Sending demanded element (size %u, hash %s) to peer\n", | 2007 | "[OP %p] Sending demanded element (size %u, hash %s) to peer\n", |
2008 | (void *) op, | 2008 | op, |
2009 | (unsigned int) ee->element.size, | 2009 | (unsigned int) ee->element.size, |
2010 | GNUNET_h2s (&ee->element_hash)); | 2010 | GNUNET_h2s (&ee->element_hash)); |
2011 | GNUNET_MQ_send (op->mq, ev); | 2011 | GNUNET_MQ_send (op->mq, ev); |
@@ -2120,8 +2120,8 @@ handle_union_p2p_offer (void *cls, | |||
2120 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST)); | 2120 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST)); |
2121 | 2121 | ||
2122 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 2122 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
2123 | "[OP %x] Requesting element (hash %s)\n", | 2123 | "[OP %p] Requesting element (hash %s)\n", |
2124 | (void *) op, GNUNET_h2s (hash)); | 2124 | op, GNUNET_h2s (hash)); |
2125 | ev = GNUNET_MQ_msg_header_extra (demands, | 2125 | ev = GNUNET_MQ_msg_header_extra (demands, |
2126 | sizeof(struct GNUNET_HashCode), | 2126 | sizeof(struct GNUNET_HashCode), |
2127 | GNUNET_MESSAGE_TYPE_SET_UNION_P2P_DEMAND); | 2127 | GNUNET_MESSAGE_TYPE_SET_UNION_P2P_DEMAND); |
diff --git a/src/set/set_api.c b/src/set/set_api.c index ce4b1c965..a082c23c1 100644 --- a/src/set/set_api.c +++ b/src/set/set_api.c | |||
@@ -630,8 +630,7 @@ create_internal (const struct GNUNET_CONFIGURATION_Handle *cfg, | |||
630 | else | 630 | else |
631 | { | 631 | { |
632 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 632 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
633 | "Creating new set (lazy copy)\n", | 633 | "Creating new set (lazy copy)\n"); |
634 | op); | ||
635 | mqm = GNUNET_MQ_msg (copy_msg, | 634 | mqm = GNUNET_MQ_msg (copy_msg, |
636 | GNUNET_MESSAGE_TYPE_SET_COPY_LAZY_CONNECT); | 635 | GNUNET_MESSAGE_TYPE_SET_COPY_LAZY_CONNECT); |
637 | copy_msg->cookie = *cookie; | 636 | copy_msg->cookie = *cookie; |
diff --git a/src/setu/gnunet-service-setu.c b/src/setu/gnunet-service-setu.c index 326589186..d00303ca7 100644 --- a/src/setu/gnunet-service-setu.c +++ b/src/setu/gnunet-service-setu.c | |||
@@ -1049,8 +1049,8 @@ prepare_ibf_iterator (void *cls, | |||
1049 | struct IBF_Key salted_key; | 1049 | struct IBF_Key salted_key; |
1050 | 1050 | ||
1051 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1051 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1052 | "[OP %x] inserting %lx (hash %s) into ibf\n", | 1052 | "[OP %p] inserting %lx (hash %s) into ibf\n", |
1053 | (void *) op, | 1053 | op, |
1054 | (unsigned long) ke->ibf_key.key_val, | 1054 | (unsigned long) ke->ibf_key.key_val, |
1055 | GNUNET_h2s (&ke->element->element_hash)); | 1055 | GNUNET_h2s (&ke->element->element_hash)); |
1056 | salt_key (&ke->ibf_key, | 1056 | salt_key (&ke->ibf_key, |
@@ -1429,7 +1429,7 @@ handle_union_p2p_strata_estimator (void *cls, | |||
1429 | (0 == other_size)) | 1429 | (0 == other_size)) |
1430 | { | 1430 | { |
1431 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1431 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1432 | "Deciding to go for full set transmission (diff=%d, own set=%u)\n", | 1432 | "Deciding to go for full set transmission (diff=%d, own set=%llu)\n", |
1433 | diff, | 1433 | diff, |
1434 | op->initial_size); | 1434 | op->initial_size); |
1435 | GNUNET_STATISTICS_update (_GSS_statistics, | 1435 | GNUNET_STATISTICS_update (_GSS_statistics, |
@@ -1504,8 +1504,8 @@ send_offers_iterator (void *cls, | |||
1504 | GNUNET_assert (NULL != ev); | 1504 | GNUNET_assert (NULL != ev); |
1505 | *(struct GNUNET_HashCode *) &mh[1] = ke->element->element_hash; | 1505 | *(struct GNUNET_HashCode *) &mh[1] = ke->element->element_hash; |
1506 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1506 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1507 | "[OP %x] sending element offer (%s) to peer\n", | 1507 | "[OP %p] sending element offer (%s) to peer\n", |
1508 | (void *) op, | 1508 | op, |
1509 | GNUNET_h2s (&ke->element->element_hash)); | 1509 | GNUNET_h2s (&ke->element->element_hash)); |
1510 | GNUNET_MQ_send (op->mq, ev); | 1510 | GNUNET_MQ_send (op->mq, ev); |
1511 | return GNUNET_YES; | 1511 | return GNUNET_YES; |
@@ -2403,8 +2403,8 @@ handle_union_p2p_demand (void *cls, | |||
2403 | emsg->reserved = htons (0); | 2403 | emsg->reserved = htons (0); |
2404 | emsg->element_type = htons (ee->element.element_type); | 2404 | emsg->element_type = htons (ee->element.element_type); |
2405 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 2405 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
2406 | "[OP %x] Sending demanded element (size %u, hash %s) to peer\n", | 2406 | "[OP %p] Sending demanded element (size %u, hash %s) to peer\n", |
2407 | (void *) op, | 2407 | op, |
2408 | (unsigned int) ee->element.size, | 2408 | (unsigned int) ee->element.size, |
2409 | GNUNET_h2s (&ee->element_hash)); | 2409 | GNUNET_h2s (&ee->element_hash)); |
2410 | GNUNET_MQ_send (op->mq, ev); | 2410 | GNUNET_MQ_send (op->mq, ev); |
@@ -2502,8 +2502,8 @@ handle_union_p2p_offer (void *cls, | |||
2502 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST)); | 2502 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST)); |
2503 | 2503 | ||
2504 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 2504 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
2505 | "[OP %x] Requesting element (hash %s)\n", | 2505 | "[OP %p] Requesting element (hash %s)\n", |
2506 | (void *) op, GNUNET_h2s (hash)); | 2506 | op, GNUNET_h2s (hash)); |
2507 | ev = GNUNET_MQ_msg_header_extra (demands, | 2507 | ev = GNUNET_MQ_msg_header_extra (demands, |
2508 | sizeof(struct GNUNET_HashCode), | 2508 | sizeof(struct GNUNET_HashCode), |
2509 | GNUNET_MESSAGE_TYPE_SETU_P2P_DEMAND); | 2509 | GNUNET_MESSAGE_TYPE_SETU_P2P_DEMAND); |
@@ -2787,8 +2787,6 @@ check_incoming_msg (void *cls, | |||
2787 | * | 2787 | * |
2788 | * @param cls the operation state | 2788 | * @param cls the operation state |
2789 | * @param msg the received message | 2789 | * @param msg the received message |
2790 | * @return #GNUNET_OK if the channel should be kept alive, | ||
2791 | * #GNUNET_SYSERR to destroy the channel | ||
2792 | */ | 2790 | */ |
2793 | static void | 2791 | static void |
2794 | handle_incoming_msg (void *cls, | 2792 | handle_incoming_msg (void *cls, |
diff --git a/src/statistics/statistics_api.c b/src/statistics/statistics_api.c index 12c09b7d2..bf0a90b45 100644 --- a/src/statistics/statistics_api.c +++ b/src/statistics/statistics_api.c | |||
@@ -472,7 +472,7 @@ handle_statistics_value (void *cls, | |||
472 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 472 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
473 | "Received valid statistic on `%s:%s': %llu\n", | 473 | "Received valid statistic on `%s:%s': %llu\n", |
474 | service, name, | 474 | service, name, |
475 | GNUNET_ntohll (smsg->value)); | 475 | (unsigned long long) GNUNET_ntohll (smsg->value)); |
476 | if (GNUNET_OK != | 476 | if (GNUNET_OK != |
477 | h->current->proc (h->current->cls, | 477 | h->current->proc (h->current->cls, |
478 | service, | 478 | service, |
diff --git a/src/testbed-logger/gnunet-service-testbed-logger.c b/src/testbed-logger/gnunet-service-testbed-logger.c index 81652fa4f..bc2f0abe0 100644 --- a/src/testbed-logger/gnunet-service-testbed-logger.c +++ b/src/testbed-logger/gnunet-service-testbed-logger.c | |||
@@ -198,7 +198,7 @@ logger_run (void *cls, | |||
198 | GNUNET_asprintf (&fn, | 198 | GNUNET_asprintf (&fn, |
199 | "%s/%.*s_%jd.dat", | 199 | "%s/%.*s_%jd.dat", |
200 | dir, | 200 | dir, |
201 | hname_len, | 201 | (int) hname_len, |
202 | hname, | 202 | hname, |
203 | (intmax_t) pid); | 203 | (intmax_t) pid); |
204 | GNUNET_free (hname); | 204 | GNUNET_free (hname); |
diff --git a/src/testbed/gnunet-service-testbed_cpustatus.c b/src/testbed/gnunet-service-testbed_cpustatus.c index 70b865c73..440f2c24f 100644 --- a/src/testbed/gnunet-service-testbed_cpustatus.c +++ b/src/testbed/gnunet-service-testbed_cpustatus.c | |||
@@ -608,7 +608,7 @@ GST_stats_init (const struct GNUNET_CONFIGURATION_Handle *cfg) | |||
608 | return; | 608 | return; |
609 | } | 609 | } |
610 | fn = NULL; | 610 | fn = NULL; |
611 | (void) GNUNET_asprintf (&fn, "%s/%.*s-%jd.dat", stats_dir, len, | 611 | (void) GNUNET_asprintf (&fn, "%s/%.*s-%jd.dat", stats_dir, (int)len, |
612 | hostname, (intmax_t) getpid ()); | 612 | hostname, (intmax_t) getpid ()); |
613 | GNUNET_free (stats_dir); | 613 | GNUNET_free (stats_dir); |
614 | GNUNET_free (hostname); | 614 | GNUNET_free (hostname); |
diff --git a/src/testbed/test_testbed_api_template.conf b/src/testbed/test_testbed_api_template.conf index 255c1b766..ae0368a8b 100644 --- a/src/testbed/test_testbed_api_template.conf +++ b/src/testbed/test_testbed_api_template.conf | |||
@@ -32,7 +32,7 @@ WAN_QUOTA_IN = 3932160 | |||
32 | USE_EPHEMERAL_KEYS = NO | 32 | USE_EPHEMERAL_KEYS = NO |
33 | IMMEDIATE_START = YES | 33 | IMMEDIATE_START = YES |
34 | 34 | ||
35 | [transport-udp] | 35 | [transport-tcp] |
36 | TIMEOUT = 300 s | 36 | TIMEOUT = 300 s |
37 | 37 | ||
38 | [PATHS] | 38 | [PATHS] |
diff --git a/src/testbed/testbed_api.c b/src/testbed/testbed_api.c index 697783d96..09752ba28 100644 --- a/src/testbed/testbed_api.c +++ b/src/testbed/testbed_api.c | |||
@@ -448,7 +448,7 @@ handle_opsuccess ( | |||
448 | uint64_t op_id; | 448 | uint64_t op_id; |
449 | 449 | ||
450 | op_id = GNUNET_ntohll (msg->operation_id); | 450 | op_id = GNUNET_ntohll (msg->operation_id); |
451 | LOG_DEBUG ("Operation %lu successful\n", op_id); | 451 | LOG_DEBUG ("Operation %llu successful\n", op_id); |
452 | if (NULL == (opc = find_opc (c, op_id))) | 452 | if (NULL == (opc = find_opc (c, op_id))) |
453 | { | 453 | { |
454 | LOG_DEBUG ("Operation not found\n"); | 454 | LOG_DEBUG ("Operation not found\n"); |
diff --git a/src/testbed/testbed_api_topology.c b/src/testbed/testbed_api_topology.c index 1d765af92..a9a340e99 100644 --- a/src/testbed/testbed_api_topology.c +++ b/src/testbed/testbed_api_topology.c | |||
@@ -1089,7 +1089,7 @@ gen_topo_from_file (struct TopologyContext *tc, | |||
1089 | if (tc->num_peers <= peer_id) | 1089 | if (tc->num_peers <= peer_id) |
1090 | { | 1090 | { |
1091 | LOG (GNUNET_ERROR_TYPE_ERROR, | 1091 | LOG (GNUNET_ERROR_TYPE_ERROR, |
1092 | _ ("Topology file needs more peers than given ones\n"), filename); | 1092 | _ ("Topology file needs more peers than given ones\n")); |
1093 | goto _exit; | 1093 | goto _exit; |
1094 | } | 1094 | } |
1095 | state = OTHER_PEER_INDEX; | 1095 | state = OTHER_PEER_INDEX; |
@@ -1114,7 +1114,7 @@ gen_topo_from_file (struct TopologyContext *tc, | |||
1114 | if (tc->num_peers <= other_peer_id) | 1114 | if (tc->num_peers <= other_peer_id) |
1115 | { | 1115 | { |
1116 | LOG (GNUNET_ERROR_TYPE_ERROR, | 1116 | LOG (GNUNET_ERROR_TYPE_ERROR, |
1117 | _ ("Topology file needs more peers than given ones\n"), filename); | 1117 | _ ("Topology file needs more peers than given ones\n")); |
1118 | goto _exit; | 1118 | goto _exit; |
1119 | } | 1119 | } |
1120 | if (peer_id != other_peer_id) | 1120 | if (peer_id != other_peer_id) |
@@ -1150,7 +1150,7 @@ gen_topo_from_file (struct TopologyContext *tc, | |||
1150 | } | 1150 | } |
1151 | else | 1151 | else |
1152 | LOG (GNUNET_ERROR_TYPE_WARNING, | 1152 | LOG (GNUNET_ERROR_TYPE_WARNING, |
1153 | _ ("Ignoring to connect peer %u to peer %u\n"), | 1153 | _ ("Ignoring to connect peer %lu to peer %lu\n"), |
1154 | peer_id, | 1154 | peer_id, |
1155 | other_peer_id); | 1155 | other_peer_id); |
1156 | while (('\n' != data[offset]) && ('|' != data[offset]) && (offset < fs)) | 1156 | while (('\n' != data[offset]) && ('|' != data[offset]) && (offset < fs)) |
diff --git a/src/transport/gnunet-communicator-udp.c b/src/transport/gnunet-communicator-udp.c index 5ca5a4e86..e967e8e9a 100644 --- a/src/transport/gnunet-communicator-udp.c +++ b/src/transport/gnunet-communicator-udp.c | |||
@@ -75,6 +75,9 @@ | |||
75 | */ | 75 | */ |
76 | #define ADDRESS_VALIDITY_PERIOD GNUNET_TIME_UNIT_HOURS | 76 | #define ADDRESS_VALIDITY_PERIOD GNUNET_TIME_UNIT_HOURS |
77 | 77 | ||
78 | #define WORKING_QUEUE_INTERVALL \ | ||
79 | GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MICROSECONDS,1) | ||
80 | |||
78 | /** | 81 | /** |
79 | * AES key size. | 82 | * AES key size. |
80 | */ | 83 | */ |
@@ -90,6 +93,8 @@ | |||
90 | */ | 93 | */ |
91 | #define GCM_TAG_SIZE (128 / 8) | 94 | #define GCM_TAG_SIZE (128 / 8) |
92 | 95 | ||
96 | #define GENERATE_AT_ONCE 2 | ||
97 | |||
93 | /** | 98 | /** |
94 | * If we fall below this number of available KCNs, | 99 | * If we fall below this number of available KCNs, |
95 | * we generate additional ACKs until we reach | 100 | * we generate additional ACKs until we reach |
@@ -129,7 +134,7 @@ | |||
129 | * sense. Might make sense to adapt to RTT if we had | 134 | * sense. Might make sense to adapt to RTT if we had |
130 | * a good measurement... | 135 | * a good measurement... |
131 | */ | 136 | */ |
132 | #define MAX_SECRETS 128 | 137 | #define MAX_SECRETS 128000 |
133 | 138 | ||
134 | /** | 139 | /** |
135 | * How often do we rekey based on number of bytes transmitted? | 140 | * How often do we rekey based on number of bytes transmitted? |
@@ -251,6 +256,12 @@ struct UDPAck | |||
251 | uint32_t sequence_max GNUNET_PACKED; | 256 | uint32_t sequence_max GNUNET_PACKED; |
252 | 257 | ||
253 | /** | 258 | /** |
259 | * Sequence acknowledgement limit. Specifies current maximum sequence | ||
260 | * number supported by receiver. | ||
261 | */ | ||
262 | uint32_t acks_available GNUNET_PACKED; | ||
263 | |||
264 | /** | ||
254 | * CMAC of the base key being acknowledged. | 265 | * CMAC of the base key being acknowledged. |
255 | */ | 266 | */ |
256 | struct GNUNET_HashCode cmac; | 267 | struct GNUNET_HashCode cmac; |
@@ -500,6 +511,12 @@ struct SenderAddress | |||
500 | unsigned int num_secrets; | 511 | unsigned int num_secrets; |
501 | 512 | ||
502 | /** | 513 | /** |
514 | * Number of BOX keys from ACKs we have currently | ||
515 | * available for this sender. | ||
516 | */ | ||
517 | unsigned int acks_available; | ||
518 | |||
519 | /** | ||
503 | * Which network type does this queue use? | 520 | * Which network type does this queue use? |
504 | */ | 521 | */ |
505 | enum GNUNET_NetworkType nt; | 522 | enum GNUNET_NetworkType nt; |
@@ -653,6 +670,15 @@ struct BroadcastInterface | |||
653 | int found; | 670 | int found; |
654 | }; | 671 | }; |
655 | 672 | ||
673 | /** | ||
674 | * Timeout for this receiver address. | ||
675 | */ | ||
676 | struct GNUNET_TIME_Absolute *rekey_timeout; | ||
677 | |||
678 | /** | ||
679 | * Shared secret we finished the last kce working queue for. | ||
680 | */ | ||
681 | struct SharedSecret *ss_finished; | ||
656 | 682 | ||
657 | /** | 683 | /** |
658 | * Cache of pre-generated key IDs. | 684 | * Cache of pre-generated key IDs. |
@@ -670,6 +696,16 @@ static struct GNUNET_SCHEDULER_Task *read_task; | |||
670 | static struct GNUNET_SCHEDULER_Task *timeout_task; | 696 | static struct GNUNET_SCHEDULER_Task *timeout_task; |
671 | 697 | ||
672 | /** | 698 | /** |
699 | * ID of kce working queue task | ||
700 | */ | ||
701 | static struct GNUNET_SCHEDULER_Task *kce_task; | ||
702 | |||
703 | /** | ||
704 | * Is the kce_task finished? | ||
705 | */ | ||
706 | static int kce_task_finished = GNUNET_NO; | ||
707 | |||
708 | /** | ||
673 | * ID of master broadcast task | 709 | * ID of master broadcast task |
674 | */ | 710 | */ |
675 | static struct GNUNET_SCHEDULER_Task *broadcast_task; | 711 | static struct GNUNET_SCHEDULER_Task *broadcast_task; |
@@ -847,6 +883,7 @@ kce_destroy (struct KeyCacheEntry *kce) | |||
847 | struct SharedSecret *ss = kce->ss; | 883 | struct SharedSecret *ss = kce->ss; |
848 | 884 | ||
849 | ss->active_kce_count--; | 885 | ss->active_kce_count--; |
886 | ss->sender->acks_available--; | ||
850 | GNUNET_CONTAINER_DLL_remove (ss->kce_head, ss->kce_tail, kce); | 887 | GNUNET_CONTAINER_DLL_remove (ss->kce_head, ss->kce_tail, kce); |
851 | GNUNET_assert (GNUNET_YES == GNUNET_CONTAINER_multishortmap_remove (key_cache, | 888 | GNUNET_assert (GNUNET_YES == GNUNET_CONTAINER_multishortmap_remove (key_cache, |
852 | &kce->kid, | 889 | &kce->kid, |
@@ -902,6 +939,7 @@ kce_generate (struct SharedSecret *ss, uint32_t seq) | |||
902 | get_kid (&ss->master, seq, &kce->kid); | 939 | get_kid (&ss->master, seq, &kce->kid); |
903 | GNUNET_CONTAINER_DLL_insert (ss->kce_head, ss->kce_tail, kce); | 940 | GNUNET_CONTAINER_DLL_insert (ss->kce_head, ss->kce_tail, kce); |
904 | ss->active_kce_count++; | 941 | ss->active_kce_count++; |
942 | ss->sender->acks_available++; | ||
905 | (void) GNUNET_CONTAINER_multishortmap_put ( | 943 | (void) GNUNET_CONTAINER_multishortmap_put ( |
906 | key_cache, | 944 | key_cache, |
907 | &kce->kid, | 945 | &kce->kid, |
@@ -920,12 +958,20 @@ kce_generate (struct SharedSecret *ss, uint32_t seq) | |||
920 | * @param ss shared secret to destroy | 958 | * @param ss shared secret to destroy |
921 | */ | 959 | */ |
922 | static void | 960 | static void |
923 | secret_destroy (struct SharedSecret *ss) | 961 | secret_destroy (struct SharedSecret *ss, int withoutKce) |
924 | { | 962 | { |
925 | struct SenderAddress *sender; | 963 | struct SenderAddress *sender; |
926 | struct ReceiverAddress *receiver; | 964 | struct ReceiverAddress *receiver; |
927 | struct KeyCacheEntry *kce; | 965 | struct KeyCacheEntry *kce; |
928 | 966 | ||
967 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
968 | "secret destroy %u %u\n", | ||
969 | withoutKce, | ||
970 | ss->sequence_allowed); | ||
971 | |||
972 | if (withoutKce && (ss->sequence_allowed > 0)) | ||
973 | return; | ||
974 | |||
929 | if (NULL != (sender = ss->sender)) | 975 | if (NULL != (sender = ss->sender)) |
930 | { | 976 | { |
931 | GNUNET_CONTAINER_DLL_remove (sender->ss_head, sender->ss_tail, ss); | 977 | GNUNET_CONTAINER_DLL_remove (sender->ss_head, sender->ss_tail, ss); |
@@ -935,7 +981,9 @@ secret_destroy (struct SharedSecret *ss) | |||
935 | { | 981 | { |
936 | GNUNET_CONTAINER_DLL_remove (receiver->ss_head, receiver->ss_tail, ss); | 982 | GNUNET_CONTAINER_DLL_remove (receiver->ss_head, receiver->ss_tail, ss); |
937 | receiver->num_secrets--; | 983 | receiver->num_secrets--; |
984 | // Uncomment this for alternativ 1 of backchannel functionality | ||
938 | receiver->acks_available -= (ss->sequence_allowed - ss->sequence_used); | 985 | receiver->acks_available -= (ss->sequence_allowed - ss->sequence_used); |
986 | // Until here for alternativ 1 | ||
939 | } | 987 | } |
940 | while (NULL != (kce = ss->kce_head)) | 988 | while (NULL != (kce = ss->kce_head)) |
941 | kce_destroy (kce); | 989 | kce_destroy (kce); |
@@ -1284,8 +1332,11 @@ handle_ack (void *cls, const struct GNUNET_PeerIdentity *pid, void *value) | |||
1284 | { | 1332 | { |
1285 | const struct UDPAck *ack = cls; | 1333 | const struct UDPAck *ack = cls; |
1286 | struct ReceiverAddress *receiver = value; | 1334 | struct ReceiverAddress *receiver = value; |
1335 | struct SharedSecret *pos; | ||
1336 | |||
1287 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1337 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1288 | "in handle ack\n"); | 1338 | "in handle ack\n"); |
1339 | struct SharedSecret *ss_to_destroy; | ||
1289 | 1340 | ||
1290 | (void) pid; | 1341 | (void) pid; |
1291 | for (struct SharedSecret *ss = receiver->ss_head; NULL != ss; ss = ss->next) | 1342 | for (struct SharedSecret *ss = receiver->ss_head; NULL != ss; ss = ss->next) |
@@ -1301,9 +1352,12 @@ handle_ack (void *cls, const struct GNUNET_PeerIdentity *pid, void *value) | |||
1301 | if (allowed > ss->sequence_allowed) | 1352 | if (allowed > ss->sequence_allowed) |
1302 | { | 1353 | { |
1303 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1354 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1304 | "%u > %u (%u)\n", allowed, ss->sequence_allowed, | 1355 | "%u > %u (%u %u) for secrect %s\n", allowed, |
1305 | receiver->acks_available); | 1356 | ss->sequence_allowed, |
1306 | 1357 | receiver->acks_available, | |
1358 | ack->acks_available, | ||
1359 | GNUNET_h2s (&ss->master)); | ||
1360 | // Uncomment this for alternativ 1 of backchannel functionality | ||
1307 | receiver->acks_available += (allowed - ss->sequence_allowed); | 1361 | receiver->acks_available += (allowed - ss->sequence_allowed); |
1308 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1362 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1309 | "Tell transport we have more acks!\n"); | 1363 | "Tell transport we have more acks!\n"); |
@@ -1312,11 +1366,33 @@ handle_ack (void *cls, const struct GNUNET_PeerIdentity *pid, void *value) | |||
1312 | (allowed | 1366 | (allowed |
1313 | - ss->sequence_allowed), | 1367 | - ss->sequence_allowed), |
1314 | 1); | 1368 | 1); |
1369 | // Until here for alternativ 1 | ||
1315 | ss->sequence_allowed = allowed; | 1370 | ss->sequence_allowed = allowed; |
1316 | /* move ss to head to avoid discarding it anytime soon! */ | 1371 | /* move ss to head to avoid discarding it anytime soon! */ |
1317 | GNUNET_CONTAINER_DLL_remove (receiver->ss_head, receiver->ss_tail, ss); | 1372 | GNUNET_CONTAINER_DLL_remove (receiver->ss_head, receiver->ss_tail, ss); |
1318 | GNUNET_CONTAINER_DLL_insert (receiver->ss_head, receiver->ss_tail, ss); | 1373 | GNUNET_CONTAINER_DLL_insert (receiver->ss_head, receiver->ss_tail, ss); |
1374 | pos = receiver->ss_head; | ||
1375 | while ( NULL != pos) | ||
1376 | { | ||
1377 | ss_to_destroy = pos; | ||
1378 | pos = pos->next; | ||
1379 | |||
1380 | secret_destroy (ss_to_destroy, GNUNET_YES); | ||
1381 | } | ||
1319 | } | 1382 | } |
1383 | |||
1384 | // Uncomment this for alternativ 2 of backchannel functionality | ||
1385 | /*if (receiver->acks_available != ack->acks_available) | ||
1386 | { | ||
1387 | receiver->acks_available = ack->acks_available; | ||
1388 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1389 | "Tell transport we have different number of acks!\n"); | ||
1390 | GNUNET_TRANSPORT_communicator_mq_update (ch, | ||
1391 | receiver->d_qh, | ||
1392 | receiver->acks_available, | ||
1393 | 1); | ||
1394 | }*/ | ||
1395 | // Until here for alternativ 2 | ||
1320 | return GNUNET_NO; | 1396 | return GNUNET_NO; |
1321 | } | 1397 | } |
1322 | } | 1398 | } |
@@ -1370,6 +1446,36 @@ try_handle_plaintext (struct SenderAddress *sender, | |||
1370 | } | 1446 | } |
1371 | } | 1447 | } |
1372 | 1448 | ||
1449 | static void | ||
1450 | kce_generate_cb (void *cls) | ||
1451 | { | ||
1452 | struct SharedSecret *ss = cls; | ||
1453 | |||
1454 | |||
1455 | |||
1456 | if (ss->sender->acks_available < KCN_TARGET) | ||
1457 | { | ||
1458 | |||
1459 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1460 | "Precomputing keys\n"); | ||
1461 | |||
1462 | for (int i = 0; i < GENERATE_AT_ONCE; i++) | ||
1463 | kce_generate (ss, ++ss->sequence_allowed); | ||
1464 | |||
1465 | kce_task = GNUNET_SCHEDULER_add_delayed (WORKING_QUEUE_INTERVALL, | ||
1466 | kce_generate_cb, | ||
1467 | ss); | ||
1468 | } | ||
1469 | else | ||
1470 | { | ||
1471 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1472 | "We have enough keys.\n"); | ||
1473 | ss_finished = ss; | ||
1474 | kce_task_finished = GNUNET_YES; | ||
1475 | } | ||
1476 | |||
1477 | |||
1478 | } | ||
1373 | 1479 | ||
1374 | /** | 1480 | /** |
1375 | * We established a shared secret with a sender. We should try to send | 1481 | * We established a shared secret with a sender. We should try to send |
@@ -1378,21 +1484,81 @@ try_handle_plaintext (struct SenderAddress *sender, | |||
1378 | * recently). | 1484 | * recently). |
1379 | * | 1485 | * |
1380 | * @param ss shared secret to generate ACKs for | 1486 | * @param ss shared secret to generate ACKs for |
1487 | * @param intial The SharedSecret came with initial KX. | ||
1381 | */ | 1488 | */ |
1382 | static void | 1489 | static void |
1383 | consider_ss_ack (struct SharedSecret *ss) | 1490 | consider_ss_ack (struct SharedSecret *ss, int initial) |
1384 | { | 1491 | { |
1492 | struct SharedSecret *ss_to_destroy; | ||
1493 | struct SharedSecret *pos; | ||
1494 | |||
1385 | GNUNET_assert (NULL != ss->sender); | 1495 | GNUNET_assert (NULL != ss->sender); |
1386 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1496 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1387 | "Considering SS UDPAck %s\n", | 1497 | "Considering SS UDPAck %s\n", |
1388 | GNUNET_i2s_full (&ss->sender->target)); | 1498 | GNUNET_i2s_full (&ss->sender->target)); |
1389 | 1499 | ||
1500 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1501 | "We have %u acks available.\n", | ||
1502 | ss->sender->acks_available); | ||
1390 | /* drop ancient KeyCacheEntries */ | 1503 | /* drop ancient KeyCacheEntries */ |
1391 | while ((NULL != ss->kce_head) && | 1504 | while ((NULL != ss->kce_head) && |
1392 | (MAX_SQN_DELTA < | 1505 | (MAX_SQN_DELTA < |
1393 | ss->kce_head->sequence_number - ss->kce_tail->sequence_number)) | 1506 | ss->kce_head->sequence_number - ss->kce_tail->sequence_number)) |
1394 | kce_destroy (ss->kce_tail); | 1507 | kce_destroy (ss->kce_tail); |
1395 | if (ss->active_kce_count < KCN_THRESHOLD) | 1508 | |
1509 | |||
1510 | if (GNUNET_NO == initial) | ||
1511 | kce_generate (ss, ++ss->sequence_allowed); | ||
1512 | |||
1513 | /*if (0 == ss->sender->acks_available) | ||
1514 | { | ||
1515 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1516 | "Generating keys\n"); | ||
1517 | while (ss->active_kce_count < KCN_TARGET) | ||
1518 | kce_generate (ss, ++ss->sequence_allowed); | ||
1519 | }*/ | ||
1520 | |||
1521 | if (((NULL != kce_task) && kce_task_finished) || (GNUNET_NO == initial)) | ||
1522 | { | ||
1523 | struct UDPAck ack; | ||
1524 | |||
1525 | ack.header.type = htons (GNUNET_MESSAGE_TYPE_COMMUNICATOR_UDP_ACK); | ||
1526 | ack.header.size = htons (sizeof(ack)); | ||
1527 | ack.sequence_max = htonl (ss_finished->sequence_allowed); | ||
1528 | ack.acks_available = ss->sender->acks_available; | ||
1529 | ack.cmac = ss_finished->cmac; | ||
1530 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1531 | "Notifying transport of UDPAck %s with intial %u\n", | ||
1532 | GNUNET_i2s_full (&ss_finished->sender->target), | ||
1533 | initial); | ||
1534 | GNUNET_TRANSPORT_communicator_notify (ch, | ||
1535 | &ss_finished->sender->target, | ||
1536 | COMMUNICATOR_ADDRESS_PREFIX, | ||
1537 | &ack.header); | ||
1538 | pos = ss->sender->ss_head; | ||
1539 | while ( NULL != pos) | ||
1540 | { | ||
1541 | ss_to_destroy = pos; | ||
1542 | pos = pos->next; | ||
1543 | secret_destroy (ss_to_destroy, GNUNET_YES); | ||
1544 | } | ||
1545 | kce_task = NULL; | ||
1546 | } | ||
1547 | else if (((NULL == kce_task) && (KCN_THRESHOLD > | ||
1548 | ss->sender->acks_available)) || | ||
1549 | (ss->sender->num_secrets > MAX_SECRETS) ) | ||
1550 | { | ||
1551 | |||
1552 | // kce_generate (ss, ++ss->sequence_allowed); | ||
1553 | // kce_generate (ss, ++ss->sequence_allowed); | ||
1554 | kce_task = GNUNET_SCHEDULER_add_delayed (WORKING_QUEUE_INTERVALL, | ||
1555 | kce_generate_cb, | ||
1556 | ss); | ||
1557 | |||
1558 | } | ||
1559 | |||
1560 | |||
1561 | /*if (ss->active_kce_count < KCN_THRESHOLD) | ||
1396 | { | 1562 | { |
1397 | struct UDPAck ack; | 1563 | struct UDPAck ack; |
1398 | 1564 | ||
@@ -1402,11 +1568,13 @@ consider_ss_ack (struct SharedSecret *ss) | |||
1402 | * For the initial KX (active_kce_count==0), | 1568 | * For the initial KX (active_kce_count==0), |
1403 | * we only generate a single KCE to prevent | 1569 | * we only generate a single KCE to prevent |
1404 | * unnecessary overhead. | 1570 | * unnecessary overhead. |
1405 | */ | 1571 | |
1406 | if (0 < ss->active_kce_count) { | 1572 | if (0 < ss->active_kce_count) |
1573 | { | ||
1407 | while (ss->active_kce_count < KCN_TARGET) | 1574 | while (ss->active_kce_count < KCN_TARGET) |
1408 | kce_generate (ss, ++ss->sequence_allowed); | 1575 | kce_generate (ss, ++ss->sequence_allowed); |
1409 | } else { | 1576 | } |
1577 | else { | ||
1410 | kce_generate (ss, ++ss->sequence_allowed); | 1578 | kce_generate (ss, ++ss->sequence_allowed); |
1411 | } | 1579 | } |
1412 | ack.header.type = htons (GNUNET_MESSAGE_TYPE_COMMUNICATOR_UDP_ACK); | 1580 | ack.header.type = htons (GNUNET_MESSAGE_TYPE_COMMUNICATOR_UDP_ACK); |
@@ -1420,7 +1588,7 @@ consider_ss_ack (struct SharedSecret *ss) | |||
1420 | &ss->sender->target, | 1588 | &ss->sender->target, |
1421 | COMMUNICATOR_ADDRESS_PREFIX, | 1589 | COMMUNICATOR_ADDRESS_PREFIX, |
1422 | &ack.header); | 1590 | &ack.header); |
1423 | } | 1591 | }*/ |
1424 | } | 1592 | } |
1425 | 1593 | ||
1426 | 1594 | ||
@@ -1459,8 +1627,11 @@ decrypt_box (const struct UDPBox *box, | |||
1459 | "# bytes decrypted with BOX", | 1627 | "# bytes decrypted with BOX", |
1460 | sizeof(out_buf), | 1628 | sizeof(out_buf), |
1461 | GNUNET_NO); | 1629 | GNUNET_NO); |
1630 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1631 | "decrypted UDPBox with kid %s\n", | ||
1632 | GNUNET_sh2s (&box->kid)); | ||
1462 | try_handle_plaintext (ss->sender, out_buf, sizeof(out_buf)); | 1633 | try_handle_plaintext (ss->sender, out_buf, sizeof(out_buf)); |
1463 | consider_ss_ack (ss); | 1634 | consider_ss_ack (ss, GNUNET_NO); |
1464 | } | 1635 | } |
1465 | 1636 | ||
1466 | 1637 | ||
@@ -1530,8 +1701,8 @@ setup_sender (const struct GNUNET_PeerIdentity *target, | |||
1530 | { | 1701 | { |
1531 | struct SenderAddress *sender; | 1702 | struct SenderAddress *sender; |
1532 | struct SearchContext sc = { .address = address, | 1703 | struct SearchContext sc = { .address = address, |
1533 | .address_len = address_len, | 1704 | .address_len = address_len, |
1534 | .sender = NULL }; | 1705 | .sender = NULL }; |
1535 | 1706 | ||
1536 | GNUNET_CONTAINER_multipeermap_get_multiple (senders, | 1707 | GNUNET_CONTAINER_multipeermap_get_multiple (senders, |
1537 | target, | 1708 | target, |
@@ -1547,10 +1718,10 @@ setup_sender (const struct GNUNET_PeerIdentity *target, | |||
1547 | sender->address = GNUNET_memdup (address, address_len); | 1718 | sender->address = GNUNET_memdup (address, address_len); |
1548 | sender->address_len = address_len; | 1719 | sender->address_len = address_len; |
1549 | (void) GNUNET_CONTAINER_multipeermap_put ( | 1720 | (void) GNUNET_CONTAINER_multipeermap_put ( |
1550 | senders, | 1721 | senders, |
1551 | &sender->target, | 1722 | &sender->target, |
1552 | sender, | 1723 | sender, |
1553 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_MULTIPLE); | 1724 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_MULTIPLE); |
1554 | GNUNET_STATISTICS_set (stats, | 1725 | GNUNET_STATISTICS_set (stats, |
1555 | "# senders active", | 1726 | "# senders active", |
1556 | GNUNET_CONTAINER_multipeermap_size (receivers), | 1727 | GNUNET_CONTAINER_multipeermap_size (receivers), |
@@ -1587,10 +1758,10 @@ verify_confirmation (const struct GNUNET_CRYPTO_EcdhePublicKey *ephemeral, | |||
1587 | uhs.ephemeral = *ephemeral; | 1758 | uhs.ephemeral = *ephemeral; |
1588 | uhs.monotonic_time = uc->monotonic_time; | 1759 | uhs.monotonic_time = uc->monotonic_time; |
1589 | return GNUNET_CRYPTO_eddsa_verify ( | 1760 | return GNUNET_CRYPTO_eddsa_verify ( |
1590 | GNUNET_SIGNATURE_COMMUNICATOR_UDP_HANDSHAKE, | 1761 | GNUNET_SIGNATURE_COMMUNICATOR_UDP_HANDSHAKE, |
1591 | &uhs, | 1762 | &uhs, |
1592 | &uc->sender_sig, | 1763 | &uc->sender_sig, |
1593 | &uc->sender.public_key); | 1764 | &uc->sender.public_key); |
1594 | } | 1765 | } |
1595 | 1766 | ||
1596 | 1767 | ||
@@ -1610,22 +1781,22 @@ sockaddr_to_udpaddr_string (const struct sockaddr *address, | |||
1610 | 1781 | ||
1611 | switch (address->sa_family) | 1782 | switch (address->sa_family) |
1612 | { | 1783 | { |
1613 | case AF_INET: | 1784 | case AF_INET: |
1614 | GNUNET_asprintf (&ret, | 1785 | GNUNET_asprintf (&ret, |
1615 | "%s-%s", | 1786 | "%s-%s", |
1616 | COMMUNICATOR_ADDRESS_PREFIX, | 1787 | COMMUNICATOR_ADDRESS_PREFIX, |
1617 | GNUNET_a2s (address, address_len)); | 1788 | GNUNET_a2s (address, address_len)); |
1618 | break; | 1789 | break; |
1619 | 1790 | ||
1620 | case AF_INET6: | 1791 | case AF_INET6: |
1621 | GNUNET_asprintf (&ret, | 1792 | GNUNET_asprintf (&ret, |
1622 | "%s-%s", | 1793 | "%s-%s", |
1623 | COMMUNICATOR_ADDRESS_PREFIX, | 1794 | COMMUNICATOR_ADDRESS_PREFIX, |
1624 | GNUNET_a2s (address, address_len)); | 1795 | GNUNET_a2s (address, address_len)); |
1625 | break; | 1796 | break; |
1626 | 1797 | ||
1627 | default: | 1798 | default: |
1628 | GNUNET_assert (0); | 1799 | GNUNET_assert (0); |
1629 | } | 1800 | } |
1630 | return ret; | 1801 | return ret; |
1631 | } | 1802 | } |
@@ -1744,10 +1915,10 @@ sock_read (void *cls) | |||
1744 | "Unable to decrypt tag, dropping...\n"); | 1915 | "Unable to decrypt tag, dropping...\n"); |
1745 | GNUNET_free (ss); | 1916 | GNUNET_free (ss); |
1746 | GNUNET_STATISTICS_update ( | 1917 | GNUNET_STATISTICS_update ( |
1747 | stats, | 1918 | stats, |
1748 | "# messages dropped (no kid, AEAD decryption failed)", | 1919 | "# messages dropped (no kid, AEAD decryption failed)", |
1749 | 1, | 1920 | 1, |
1750 | GNUNET_NO); | 1921 | GNUNET_NO); |
1751 | return; | 1922 | return; |
1752 | } | 1923 | } |
1753 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1924 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
@@ -1778,9 +1949,9 @@ sock_read (void *cls) | |||
1778 | 1, | 1949 | 1, |
1779 | GNUNET_NO); | 1950 | GNUNET_NO); |
1780 | try_handle_plaintext (sender, &uc[1], sizeof(pbuf) - sizeof(*uc)); | 1951 | try_handle_plaintext (sender, &uc[1], sizeof(pbuf) - sizeof(*uc)); |
1781 | consider_ss_ack (ss); | 1952 | consider_ss_ack (ss, GNUNET_YES); |
1782 | if (sender->num_secrets > MAX_SECRETS) | 1953 | /*if (sender->num_secrets > MAX_SECRETS) |
1783 | secret_destroy (sender->ss_tail); | 1954 | secret_destroy (sender->ss_tail);*/ |
1784 | } | 1955 | } |
1785 | } | 1956 | } |
1786 | 1957 | ||
@@ -1859,9 +2030,9 @@ udp_address_to_sockaddr (const char *bindto, socklen_t *sock_len) | |||
1859 | else | 2030 | else |
1860 | { | 2031 | { |
1861 | GNUNET_log ( | 2032 | GNUNET_log ( |
1862 | GNUNET_ERROR_TYPE_ERROR, | 2033 | GNUNET_ERROR_TYPE_ERROR, |
1863 | "BINDTO specification `%s' invalid: last ':' not followed by number\n", | 2034 | "BINDTO specification `%s' invalid: last ':' not followed by number\n", |
1864 | bindto); | 2035 | bindto); |
1865 | GNUNET_free (cp); | 2036 | GNUNET_free (cp); |
1866 | return NULL; | 2037 | return NULL; |
1867 | } | 2038 | } |
@@ -1939,8 +2110,8 @@ do_pad (gcry_cipher_hd_t out_cipher, char *dgram, size_t pad_size) | |||
1939 | memcpy (pad, &hdr, sizeof(hdr)); | 2110 | memcpy (pad, &hdr, sizeof(hdr)); |
1940 | } | 2111 | } |
1941 | GNUNET_assert ( | 2112 | GNUNET_assert ( |
1942 | 0 == | 2113 | 0 == |
1943 | gcry_cipher_encrypt (out_cipher, dgram, sizeof(pad), pad, sizeof(pad))); | 2114 | gcry_cipher_encrypt (out_cipher, dgram, sizeof(pad), pad, sizeof(pad))); |
1944 | } | 2115 | } |
1945 | 2116 | ||
1946 | 2117 | ||
@@ -1967,6 +2138,19 @@ mq_send_kx (struct GNUNET_MQ_Handle *mq, | |||
1967 | size_t dpos; | 2138 | size_t dpos; |
1968 | gcry_cipher_hd_t out_cipher; | 2139 | gcry_cipher_hd_t out_cipher; |
1969 | struct SharedSecret *ss; | 2140 | struct SharedSecret *ss; |
2141 | struct SharedSecret *ss_to_destroy; | ||
2142 | struct SharedSecret *pos; | ||
2143 | |||
2144 | if (receiver->num_secrets > MAX_SECRETS) | ||
2145 | { | ||
2146 | pos = receiver->ss_head; | ||
2147 | while ( NULL != pos) | ||
2148 | { | ||
2149 | ss_to_destroy = pos; | ||
2150 | pos = pos->next; | ||
2151 | secret_destroy (ss_to_destroy, GNUNET_YES); | ||
2152 | } | ||
2153 | } | ||
1970 | 2154 | ||
1971 | 2155 | ||
1972 | GNUNET_assert (mq == receiver->kx_mq); | 2156 | GNUNET_assert (mq == receiver->kx_mq); |
@@ -2007,13 +2191,13 @@ mq_send_kx (struct GNUNET_MQ_Handle *mq, | |||
2007 | dpos += sizeof(uc); | 2191 | dpos += sizeof(uc); |
2008 | /* Append encrypted payload to dgram */ | 2192 | /* Append encrypted payload to dgram */ |
2009 | GNUNET_assert ( | 2193 | GNUNET_assert ( |
2010 | 0 == gcry_cipher_encrypt (out_cipher, &dgram[dpos], msize, msg, msize)); | 2194 | 0 == gcry_cipher_encrypt (out_cipher, &dgram[dpos], msize, msg, msize)); |
2011 | dpos += msize; | 2195 | dpos += msize; |
2012 | do_pad (out_cipher, &dgram[dpos], sizeof(dgram) - dpos); | 2196 | do_pad (out_cipher, &dgram[dpos], sizeof(dgram) - dpos); |
2013 | /* Datagram starts with kx */ | 2197 | /* Datagram starts with kx */ |
2014 | kx.ephemeral = uhs.ephemeral; | 2198 | kx.ephemeral = uhs.ephemeral; |
2015 | GNUNET_assert ( | 2199 | GNUNET_assert ( |
2016 | 0 == gcry_cipher_gettag (out_cipher, kx.gcm_tag, sizeof(kx.gcm_tag))); | 2200 | 0 == gcry_cipher_gettag (out_cipher, kx.gcm_tag, sizeof(kx.gcm_tag))); |
2017 | gcry_cipher_close (out_cipher); | 2201 | gcry_cipher_close (out_cipher); |
2018 | memcpy (dgram, &kx, sizeof(kx)); | 2202 | memcpy (dgram, &kx, sizeof(kx)); |
2019 | if (-1 == GNUNET_NETWORK_socket_sendto (udp_sock, | 2203 | if (-1 == GNUNET_NETWORK_socket_sendto (udp_sock, |
@@ -2044,6 +2228,8 @@ mq_send_d (struct GNUNET_MQ_Handle *mq, | |||
2044 | { | 2228 | { |
2045 | struct ReceiverAddress *receiver = impl_state; | 2229 | struct ReceiverAddress *receiver = impl_state; |
2046 | uint16_t msize = ntohs (msg->size); | 2230 | uint16_t msize = ntohs (msg->size); |
2231 | struct GNUNET_TIME_Relative rt; | ||
2232 | struct SharedSecret *pos; | ||
2047 | 2233 | ||
2048 | GNUNET_assert (mq == receiver->d_mq); | 2234 | GNUNET_assert (mq == receiver->d_mq); |
2049 | if ((msize > receiver->d_mtu) || | 2235 | if ((msize > receiver->d_mtu) || |
@@ -2058,7 +2244,18 @@ mq_send_d (struct GNUNET_MQ_Handle *mq, | |||
2058 | /* begin "BOX" encryption method, scan for ACKs from tail! */ | 2244 | /* begin "BOX" encryption method, scan for ACKs from tail! */ |
2059 | for (struct SharedSecret *ss = receiver->ss_tail; NULL != ss; ss = ss->prev) | 2245 | for (struct SharedSecret *ss = receiver->ss_tail; NULL != ss; ss = ss->prev) |
2060 | { | 2246 | { |
2247 | if (0 < ss->sequence_used) | ||
2248 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
2249 | "Trying to send UDPBox with shared secrect %s sequence_used %u and ss->sequence_allowed %u\n", | ||
2250 | GNUNET_h2s (&ss->master), | ||
2251 | ss->sequence_used, | ||
2252 | ss->sequence_allowed); | ||
2253 | // Uncomment this for alternativ 1 of backchannel functionality | ||
2061 | if (ss->sequence_used >= ss->sequence_allowed) | 2254 | if (ss->sequence_used >= ss->sequence_allowed) |
2255 | // Until here for alternativ 1 | ||
2256 | // Uncomment this for alternativ 2 of backchannel functionality | ||
2257 | // if (0 == ss->sequence_allowed) | ||
2258 | // Until here for alternativ 2 | ||
2062 | { | 2259 | { |
2063 | continue; | 2260 | continue; |
2064 | } | 2261 | } |
@@ -2074,7 +2271,7 @@ mq_send_d (struct GNUNET_MQ_Handle *mq, | |||
2074 | /* Append encrypted payload to dgram */ | 2271 | /* Append encrypted payload to dgram */ |
2075 | dpos = sizeof(struct UDPBox); | 2272 | dpos = sizeof(struct UDPBox); |
2076 | GNUNET_assert ( | 2273 | GNUNET_assert ( |
2077 | 0 == gcry_cipher_encrypt (out_cipher, &dgram[dpos], msize, msg, msize)); | 2274 | 0 == gcry_cipher_encrypt (out_cipher, &dgram[dpos], msize, msg, msize)); |
2078 | dpos += msize; | 2275 | dpos += msize; |
2079 | do_pad (out_cipher, &dgram[dpos], sizeof(dgram) - dpos); | 2276 | do_pad (out_cipher, &dgram[dpos], sizeof(dgram) - dpos); |
2080 | GNUNET_assert (0 == gcry_cipher_gettag (out_cipher, | 2277 | GNUNET_assert (0 == gcry_cipher_gettag (out_cipher, |
@@ -2087,14 +2284,43 @@ mq_send_d (struct GNUNET_MQ_Handle *mq, | |||
2087 | receiver->address, | 2284 | receiver->address, |
2088 | receiver->address_len)) | 2285 | receiver->address_len)) |
2089 | GNUNET_log_strerror (GNUNET_ERROR_TYPE_WARNING, "send"); | 2286 | GNUNET_log_strerror (GNUNET_ERROR_TYPE_WARNING, "send"); |
2287 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
2288 | "Sending UDPBox to %s\n", GNUNET_a2s (receiver->address, | ||
2289 | receiver->address_len)); | ||
2090 | GNUNET_MQ_impl_send_continue (mq); | 2290 | GNUNET_MQ_impl_send_continue (mq); |
2091 | receiver->acks_available--; | 2291 | // receiver->acks_available--; |
2092 | if (0 == receiver->acks_available) | 2292 | if (0 == receiver->acks_available) |
2093 | { | 2293 | { |
2094 | /* We have no more ACKs */ | 2294 | /* We have no more ACKs */ |
2095 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 2295 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
2096 | "No more acks\n"); | 2296 | "No more acks\n"); |
2097 | } | 2297 | } |
2298 | |||
2299 | /* (NULL == rekey_timeout) | ||
2300 | rekey_timeout = GNUNET_TIME_relative_to_absolute (REKEY_TIME_INTERVAL); | ||
2301 | else | ||
2302 | { | ||
2303 | rt = GNUNET_TIME_absolute_get_remaining (rekey_timeout); | ||
2304 | if (0 == rt.rel_value_us) | ||
2305 | { | ||
2306 | rekey_timeout = NULL; | ||
2307 | pos = receiver->ss_head; | ||
2308 | while ( NULL != pos) | ||
2309 | { | ||
2310 | ss_to_destroy = pos; | ||
2311 | pos = pos->next; | ||
2312 | secret_destroy (ss_to_destroy, GNUNET_NO); | ||
2313 | } | ||
2314 | if (0 != receiver->acks_available) | ||
2315 | GNUNET_TRANSPORT_communicator_mq_update (ch, | ||
2316 | receiver->d_qh, | ||
2317 | // TODO We can not do this. But how can we signal this queue is not able to handle a message. Test code interprets q-len as additional length. | ||
2318 | -receiver->acks_available, | ||
2319 | 1); | ||
2320 | } | ||
2321 | }*/ | ||
2322 | |||
2323 | |||
2098 | return; | 2324 | return; |
2099 | } | 2325 | } |
2100 | } | 2326 | } |
@@ -2205,25 +2431,25 @@ setup_receiver_mq (struct ReceiverAddress *receiver) | |||
2205 | // GNUNET_assert (NULL == receiver->mq); | 2431 | // GNUNET_assert (NULL == receiver->mq); |
2206 | switch (receiver->address->sa_family) | 2432 | switch (receiver->address->sa_family) |
2207 | { | 2433 | { |
2208 | case AF_INET: | 2434 | case AF_INET: |
2209 | base_mtu = 1480 /* Ethernet MTU, 1500 - Ethernet header - VLAN tag */ | 2435 | base_mtu = 1480 /* Ethernet MTU, 1500 - Ethernet header - VLAN tag */ |
2210 | - sizeof(struct GNUNET_TUN_IPv4Header) /* 20 */ | 2436 | - sizeof(struct GNUNET_TUN_IPv4Header) /* 20 */ |
2211 | - sizeof(struct GNUNET_TUN_UdpHeader) /* 8 */; | 2437 | - sizeof(struct GNUNET_TUN_UdpHeader) /* 8 */; |
2212 | break; | 2438 | break; |
2213 | 2439 | ||
2214 | case AF_INET6: | 2440 | case AF_INET6: |
2215 | base_mtu = 1280 /* Minimum MTU required by IPv6 */ | 2441 | base_mtu = 1280 /* Minimum MTU required by IPv6 */ |
2216 | - sizeof(struct GNUNET_TUN_IPv6Header) /* 40 */ | 2442 | - sizeof(struct GNUNET_TUN_IPv6Header) /* 40 */ |
2217 | - sizeof(struct GNUNET_TUN_UdpHeader) /* 8 */; | 2443 | - sizeof(struct GNUNET_TUN_UdpHeader) /* 8 */; |
2218 | break; | 2444 | break; |
2219 | 2445 | ||
2220 | default: | 2446 | default: |
2221 | GNUNET_assert (0); | 2447 | GNUNET_assert (0); |
2222 | break; | 2448 | break; |
2223 | } | 2449 | } |
2224 | /* MTU based on full KX messages */ | 2450 | /* MTU based on full KX messages */ |
2225 | receiver->kx_mtu = base_mtu - sizeof(struct InitialKX) /* 48 */ | 2451 | receiver->kx_mtu = base_mtu - sizeof(struct InitialKX) /* 48 */ |
2226 | - sizeof(struct UDPConfirmation); /* 104 */ | 2452 | - sizeof(struct UDPConfirmation); /* 104 */ |
2227 | /* MTU based on BOXed messages */ | 2453 | /* MTU based on BOXed messages */ |
2228 | receiver->d_mtu = base_mtu - sizeof(struct UDPBox); | 2454 | receiver->d_mtu = base_mtu - sizeof(struct UDPBox); |
2229 | 2455 | ||
@@ -2314,10 +2540,10 @@ mq_init (void *cls, const struct GNUNET_PeerIdentity *peer, const char *address) | |||
2314 | receiver->target = *peer; | 2540 | receiver->target = *peer; |
2315 | receiver->nt = GNUNET_NT_scanner_get_type (is, in, in_len); | 2541 | receiver->nt = GNUNET_NT_scanner_get_type (is, in, in_len); |
2316 | (void) GNUNET_CONTAINER_multipeermap_put ( | 2542 | (void) GNUNET_CONTAINER_multipeermap_put ( |
2317 | receivers, | 2543 | receivers, |
2318 | &receiver->target, | 2544 | &receiver->target, |
2319 | receiver, | 2545 | receiver, |
2320 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_MULTIPLE); | 2546 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_MULTIPLE); |
2321 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 2547 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
2322 | "Added %s to receivers\n", | 2548 | "Added %s to receivers\n", |
2323 | GNUNET_i2s_full (&receiver->target)); | 2549 | GNUNET_i2s_full (&receiver->target)); |
@@ -2553,55 +2779,55 @@ ifc_broadcast (void *cls) | |||
2553 | 2779 | ||
2554 | switch (bi->sa->sa_family) | 2780 | switch (bi->sa->sa_family) |
2555 | { | 2781 | { |
2556 | case AF_INET: { | 2782 | case AF_INET: { |
2557 | static int yes = 1; | 2783 | static int yes = 1; |
2558 | static int no = 0; | 2784 | static int no = 0; |
2559 | ssize_t sent; | 2785 | ssize_t sent; |
2560 | 2786 | ||
2561 | if (GNUNET_OK != GNUNET_NETWORK_socket_setsockopt (udp_sock, | 2787 | if (GNUNET_OK != GNUNET_NETWORK_socket_setsockopt (udp_sock, |
2562 | SOL_SOCKET, | 2788 | SOL_SOCKET, |
2563 | SO_BROADCAST, | 2789 | SO_BROADCAST, |
2564 | &yes, | 2790 | &yes, |
2565 | sizeof(int))) | 2791 | sizeof(int))) |
2566 | GNUNET_log_strerror (GNUNET_ERROR_TYPE_WARNING, "setsockopt"); | 2792 | GNUNET_log_strerror (GNUNET_ERROR_TYPE_WARNING, "setsockopt"); |
2567 | sent = GNUNET_NETWORK_socket_sendto (udp_sock, | 2793 | sent = GNUNET_NETWORK_socket_sendto (udp_sock, |
2568 | &bi->bcm, | 2794 | &bi->bcm, |
2569 | sizeof(bi->bcm), | 2795 | sizeof(bi->bcm), |
2570 | bi->ba, | 2796 | bi->ba, |
2571 | bi->salen); | 2797 | bi->salen); |
2572 | if (-1 == sent) | 2798 | if (-1 == sent) |
2573 | GNUNET_log_strerror (GNUNET_ERROR_TYPE_WARNING, "sendto"); | 2799 | GNUNET_log_strerror (GNUNET_ERROR_TYPE_WARNING, "sendto"); |
2574 | if (GNUNET_OK != GNUNET_NETWORK_socket_setsockopt (udp_sock, | 2800 | if (GNUNET_OK != GNUNET_NETWORK_socket_setsockopt (udp_sock, |
2575 | SOL_SOCKET, | 2801 | SOL_SOCKET, |
2576 | SO_BROADCAST, | 2802 | SO_BROADCAST, |
2577 | &no, | 2803 | &no, |
2578 | sizeof(int))) | 2804 | sizeof(int))) |
2579 | GNUNET_log_strerror (GNUNET_ERROR_TYPE_WARNING, "setsockopt"); | 2805 | GNUNET_log_strerror (GNUNET_ERROR_TYPE_WARNING, "setsockopt"); |
2580 | break; | 2806 | break; |
2581 | } | 2807 | } |
2582 | 2808 | ||
2583 | case AF_INET6: { | 2809 | case AF_INET6: { |
2584 | ssize_t sent; | 2810 | ssize_t sent; |
2585 | struct sockaddr_in6 dst; | 2811 | struct sockaddr_in6 dst; |
2586 | 2812 | ||
2587 | dst.sin6_family = AF_INET6; | 2813 | dst.sin6_family = AF_INET6; |
2588 | dst.sin6_port = htons (my_port); | 2814 | dst.sin6_port = htons (my_port); |
2589 | dst.sin6_addr = bi->mcreq.ipv6mr_multiaddr; | 2815 | dst.sin6_addr = bi->mcreq.ipv6mr_multiaddr; |
2590 | dst.sin6_scope_id = ((struct sockaddr_in6 *) bi->ba)->sin6_scope_id; | 2816 | dst.sin6_scope_id = ((struct sockaddr_in6 *) bi->ba)->sin6_scope_id; |
2591 | 2817 | ||
2592 | sent = GNUNET_NETWORK_socket_sendto (udp_sock, | 2818 | sent = GNUNET_NETWORK_socket_sendto (udp_sock, |
2593 | &bi->bcm, | 2819 | &bi->bcm, |
2594 | sizeof(bi->bcm), | 2820 | sizeof(bi->bcm), |
2595 | (const struct sockaddr *) &dst, | 2821 | (const struct sockaddr *) &dst, |
2596 | sizeof(dst)); | 2822 | sizeof(dst)); |
2597 | if (-1 == sent) | 2823 | if (-1 == sent) |
2598 | GNUNET_log_strerror (GNUNET_ERROR_TYPE_WARNING, "sendto"); | 2824 | GNUNET_log_strerror (GNUNET_ERROR_TYPE_WARNING, "sendto"); |
2599 | break; | 2825 | break; |
2600 | } | 2826 | } |
2601 | 2827 | ||
2602 | default: | 2828 | default: |
2603 | GNUNET_break (0); | 2829 | GNUNET_break (0); |
2604 | break; | 2830 | break; |
2605 | } | 2831 | } |
2606 | } | 2832 | } |
2607 | 2833 | ||
@@ -2683,7 +2909,7 @@ iface_proc (void *cls, | |||
2683 | (const struct sockaddr_in6 *) broadcast_addr; | 2909 | (const struct sockaddr_in6 *) broadcast_addr; |
2684 | 2910 | ||
2685 | GNUNET_assert ( | 2911 | GNUNET_assert ( |
2686 | 1 == inet_pton (AF_INET6, "FF05::13B", &bi->mcreq.ipv6mr_multiaddr)); | 2912 | 1 == inet_pton (AF_INET6, "FF05::13B", &bi->mcreq.ipv6mr_multiaddr)); |
2687 | 2913 | ||
2688 | /* http://tools.ietf.org/html/rfc2553#section-5.2: | 2914 | /* http://tools.ietf.org/html/rfc2553#section-5.2: |
2689 | * | 2915 | * |
@@ -2820,17 +3046,17 @@ run (void *cls, | |||
2820 | GNUNET_a2s ((const struct sockaddr *) &in_sto, sto_len)); | 3046 | GNUNET_a2s ((const struct sockaddr *) &in_sto, sto_len)); |
2821 | switch (in->sa_family) | 3047 | switch (in->sa_family) |
2822 | { | 3048 | { |
2823 | case AF_INET: | 3049 | case AF_INET: |
2824 | my_port = ntohs (((struct sockaddr_in *) in)->sin_port); | 3050 | my_port = ntohs (((struct sockaddr_in *) in)->sin_port); |
2825 | break; | 3051 | break; |
2826 | 3052 | ||
2827 | case AF_INET6: | 3053 | case AF_INET6: |
2828 | my_port = ntohs (((struct sockaddr_in6 *) in)->sin6_port); | 3054 | my_port = ntohs (((struct sockaddr_in6 *) in)->sin6_port); |
2829 | break; | 3055 | break; |
2830 | 3056 | ||
2831 | default: | 3057 | default: |
2832 | GNUNET_break (0); | 3058 | GNUNET_break (0); |
2833 | my_port = 0; | 3059 | my_port = 0; |
2834 | } | 3060 | } |
2835 | stats = GNUNET_STATISTICS_create ("C-UDP", cfg); | 3061 | stats = GNUNET_STATISTICS_create ("C-UDP", cfg); |
2836 | senders = GNUNET_CONTAINER_multipeermap_create (32, GNUNET_YES); | 3062 | senders = GNUNET_CONTAINER_multipeermap_create (32, GNUNET_YES); |
@@ -2845,9 +3071,9 @@ run (void *cls, | |||
2845 | if (NULL == my_private_key) | 3071 | if (NULL == my_private_key) |
2846 | { | 3072 | { |
2847 | GNUNET_log ( | 3073 | GNUNET_log ( |
2848 | GNUNET_ERROR_TYPE_ERROR, | 3074 | GNUNET_ERROR_TYPE_ERROR, |
2849 | _ ( | 3075 | _ ( |
2850 | "Transport service is lacking key configuration settings. Exiting.\n")); | 3076 | "Transport service is lacking key configuration settings. Exiting.\n")); |
2851 | GNUNET_SCHEDULER_shutdown (); | 3077 | GNUNET_SCHEDULER_shutdown (); |
2852 | return; | 3078 | return; |
2853 | } | 3079 | } |
@@ -2923,8 +3149,8 @@ main (int argc, char *const *argv) | |||
2923 | options, | 3149 | options, |
2924 | &run, | 3150 | &run, |
2925 | NULL)) | 3151 | NULL)) |
2926 | ? 0 | 3152 | ? 0 |
2927 | : 1; | 3153 | : 1; |
2928 | GNUNET_free_nz ((void *) argv); | 3154 | GNUNET_free_nz ((void *) argv); |
2929 | return ret; | 3155 | return ret; |
2930 | } | 3156 | } |
diff --git a/src/transport/gnunet-service-transport.c b/src/transport/gnunet-service-transport.c index 207c17f2f..92e37a91c 100644 --- a/src/transport/gnunet-service-transport.c +++ b/src/transport/gnunet-service-transport.c | |||
@@ -700,6 +700,7 @@ handle_send_transmit_continuation (void *cls, | |||
700 | 700 | ||
701 | delay = GNUNET_TIME_absolute_get_duration (stcc->send_time); | 701 | delay = GNUNET_TIME_absolute_get_duration (stcc->send_time); |
702 | addr = GST_neighbour_get_current_address (&stcc->target); | 702 | addr = GST_neighbour_get_current_address (&stcc->target); |
703 | #ifdef ENABLE_TTD | ||
703 | if (delay.rel_value_us > GNUNET_CONSTANTS_LATENCY_WARN.rel_value_us) | 704 | if (delay.rel_value_us > GNUNET_CONSTANTS_LATENCY_WARN.rel_value_us) |
704 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | 705 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, |
705 | "It took us %s to send %u/%u bytes to %s (%d, %s)\n", | 706 | "It took us %s to send %u/%u bytes to %s (%d, %s)\n", |
@@ -718,6 +719,7 @@ handle_send_transmit_continuation (void *cls, | |||
718 | GNUNET_i2s (&stcc->target), | 719 | GNUNET_i2s (&stcc->target), |
719 | success, | 720 | success, |
720 | (NULL != addr) ? addr->transport_name : "%"); | 721 | (NULL != addr) ? addr->transport_name : "%"); |
722 | #endif | ||
721 | 723 | ||
722 | if (GNUNET_NO == stcc->down) | 724 | if (GNUNET_NO == stcc->down) |
723 | { | 725 | { |
diff --git a/src/transport/plugin_transport_http_client.c b/src/transport/plugin_transport_http_client.c index 92ed2fe52..219fae57b 100644 --- a/src/transport/plugin_transport_http_client.c +++ b/src/transport/plugin_transport_http_client.c | |||
@@ -769,10 +769,10 @@ http_client_plugin_send (void *cls, | |||
769 | char *stat_txt; | 769 | char *stat_txt; |
770 | 770 | ||
771 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 771 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
772 | "Session %p/request %p: Sending message with %u to peer `%s' \n", | 772 | "Session %p/request %p: Sending message with %lu to peer `%s' \n", |
773 | s, | 773 | s, |
774 | s->put.easyhandle, | 774 | s->put.easyhandle, |
775 | msgbuf_size, | 775 | (unsigned long) msgbuf_size, |
776 | GNUNET_i2s (&s->address->peer)); | 776 | GNUNET_i2s (&s->address->peer)); |
777 | 777 | ||
778 | /* create new message and schedule */ | 778 | /* create new message and schedule */ |
@@ -1087,11 +1087,10 @@ client_send_cb (void *stream, | |||
1087 | if (msg->pos == msg->size) | 1087 | if (msg->pos == msg->size) |
1088 | { | 1088 | { |
1089 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1089 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1090 | "Session %p/request %p: sent message with %u bytes sent, removing message from queue\n", | 1090 | "Session %p/request %p: sent message with %lu bytes sent, removing message from queue\n", |
1091 | s, | 1091 | s, |
1092 | s->put.easyhandle, | 1092 | s->put.easyhandle, |
1093 | msg->size, | 1093 | (unsigned long) msg->size); |
1094 | msg->pos); | ||
1095 | /* Calling transmit continuation */ | 1094 | /* Calling transmit continuation */ |
1096 | GNUNET_CONTAINER_DLL_remove (s->msg_head, | 1095 | GNUNET_CONTAINER_DLL_remove (s->msg_head, |
1097 | s->msg_tail, | 1096 | s->msg_tail, |
@@ -1249,10 +1248,10 @@ client_receive (void *stream, | |||
1249 | size_t len = size * nmemb; | 1248 | size_t len = size * nmemb; |
1250 | 1249 | ||
1251 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1250 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1252 | "Session %p / request %p: Received %u bytes from peer `%s'\n", | 1251 | "Session %p / request %p: Received %lu bytes from peer `%s'\n", |
1253 | s, | 1252 | s, |
1254 | s->get.easyhandle, | 1253 | s->get.easyhandle, |
1255 | len, | 1254 | (unsigned long) len, |
1256 | GNUNET_i2s (&s->address->peer)); | 1255 | GNUNET_i2s (&s->address->peer)); |
1257 | now = GNUNET_TIME_absolute_get (); | 1256 | now = GNUNET_TIME_absolute_get (); |
1258 | if (now.abs_value_us < s->next_receive.abs_value_us) | 1257 | if (now.abs_value_us < s->next_receive.abs_value_us) |
@@ -1346,7 +1345,7 @@ client_run (void *cls) | |||
1346 | /* Log status of terminated request */ | 1345 | /* Log status of terminated request */ |
1347 | if ((0 != msg->data.result) || (http_statuscode != 200)) | 1346 | if ((0 != msg->data.result) || (http_statuscode != 200)) |
1348 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1347 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1349 | "Session %p/request %p: %s request to `%s' ended with status %i reason %i: `%s'\n", | 1348 | "Session %p/request %p: %s request to `%s' ended with status %li reason %i: `%s'\n", |
1350 | s, msg->easy_handle, | 1349 | s, msg->easy_handle, |
1351 | (GNUNET_YES == put_request) ? "PUT" : "GET", | 1350 | (GNUNET_YES == put_request) ? "PUT" : "GET", |
1352 | GNUNET_i2s (&s->address->peer), | 1351 | GNUNET_i2s (&s->address->peer), |
diff --git a/src/transport/plugin_transport_http_common.c b/src/transport/plugin_transport_http_common.c index d81d6db9c..0e3778837 100644 --- a/src/transport/plugin_transport_http_common.c +++ b/src/transport/plugin_transport_http_common.c | |||
@@ -629,7 +629,7 @@ http_common_plugin_address_to_string (const char *plugin, | |||
629 | if (addr_str[ntohl (address->urlen) - 1] != '\0') | 629 | if (addr_str[ntohl (address->urlen) - 1] != '\0') |
630 | return NULL; | 630 | return NULL; |
631 | GNUNET_asprintf (&res, "%s.%u.%s", plugin, ntohl (address->options), | 631 | GNUNET_asprintf (&res, "%s.%u.%s", plugin, ntohl (address->options), |
632 | &address[1]); | 632 | (char*)&address[1]); |
633 | if (strlen (res) + 1 < 500) | 633 | if (strlen (res) + 1 < 500) |
634 | { | 634 | { |
635 | GNUNET_memcpy (rbuf, res, strlen (res) + 1); | 635 | GNUNET_memcpy (rbuf, res, strlen (res) + 1); |
diff --git a/src/transport/plugin_transport_http_server.c b/src/transport/plugin_transport_http_server.c index d1b21ba9c..6e95ca00c 100644 --- a/src/transport/plugin_transport_http_server.c +++ b/src/transport/plugin_transport_http_server.c | |||
@@ -745,10 +745,10 @@ http_server_plugin_send (void *cls, | |||
745 | char *stat_txt; | 745 | char *stat_txt; |
746 | 746 | ||
747 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 747 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
748 | "Session %p/request %p: Sending message with %u to peer `%s'\n", | 748 | "Session %p/request %p: Sending message with %lu to peer `%s'\n", |
749 | session, | 749 | session, |
750 | session->server_send, | 750 | session->server_send, |
751 | msgbuf_size, | 751 | (unsigned long) msgbuf_size, |
752 | GNUNET_i2s (&session->target)); | 752 | GNUNET_i2s (&session->target)); |
753 | 753 | ||
754 | /* create new message and schedule */ | 754 | /* create new message and schedule */ |
@@ -1270,8 +1270,8 @@ server_parse_url (struct HTTP_Server_Plugin *plugin, | |||
1270 | if (hash_length != plugin->peer_id_length) | 1270 | if (hash_length != plugin->peer_id_length) |
1271 | { | 1271 | { |
1272 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1272 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1273 | "URL target is %u bytes, expecting %u\n", | 1273 | "URL target is %lu bytes, expecting %u\n", |
1274 | hash_length, plugin->peer_id_length); | 1274 | (unsigned long) hash_length, plugin->peer_id_length); |
1275 | return GNUNET_SYSERR; | 1275 | return GNUNET_SYSERR; |
1276 | } | 1276 | } |
1277 | if (GNUNET_OK != | 1277 | if (GNUNET_OK != |
@@ -1616,8 +1616,8 @@ server_send_callback (void *cls, | |||
1616 | { | 1616 | { |
1617 | sc->connected = GNUNET_YES; | 1617 | sc->connected = GNUNET_YES; |
1618 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1618 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1619 | "Sent %u bytes to peer `%s' with session %p \n", | 1619 | "Sent %lu bytes to peer `%s' with session %p \n", |
1620 | bytes_read, | 1620 | (unsigned long) bytes_read, |
1621 | GNUNET_i2s (&s->target), | 1621 | GNUNET_i2s (&s->target), |
1622 | s); | 1622 | s); |
1623 | GNUNET_asprintf (&stat_txt, | 1623 | GNUNET_asprintf (&stat_txt, |
@@ -1761,14 +1761,14 @@ server_access_cb (void *cls, | |||
1761 | 1761 | ||
1762 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1762 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1763 | _ ( | 1763 | _ ( |
1764 | "Access from connection %p (%u of %u) for `%s' `%s' url `%s' with upload data size %u\n"), | 1764 | "Access from connection %p (%u of %u) for `%s' `%s' url `%s' with upload data size %lu\n"), |
1765 | sc, | 1765 | sc, |
1766 | plugin->cur_request, | 1766 | plugin->cur_request, |
1767 | plugin->max_request, | 1767 | plugin->max_request, |
1768 | method, | 1768 | method, |
1769 | version, | 1769 | version, |
1770 | url, | 1770 | url, |
1771 | (*upload_data_size)); | 1771 | (unsigned long) (*upload_data_size)); |
1772 | if (NULL == sc) | 1772 | if (NULL == sc) |
1773 | { | 1773 | { |
1774 | /* CORS pre-flight request */ | 1774 | /* CORS pre-flight request */ |
@@ -1868,19 +1868,19 @@ server_access_cb (void *cls, | |||
1868 | 1868 | ||
1869 | /* (*upload_data_size > 0) for every segment received */ | 1869 | /* (*upload_data_size > 0) for every segment received */ |
1870 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1870 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1871 | "Session %p / Connection %p: Peer `%s' PUT on address `%s' received %u bytes\n", | 1871 | "Session %p / Connection %p: Peer `%s' PUT on address `%s' received %lu bytes\n", |
1872 | s, sc, | 1872 | s, sc, |
1873 | GNUNET_i2s (&s->target), | 1873 | GNUNET_i2s (&s->target), |
1874 | http_common_plugin_address_to_string (plugin->protocol, | 1874 | http_common_plugin_address_to_string (plugin->protocol, |
1875 | s->address->address, | 1875 | s->address->address, |
1876 | s->address->address_length), | 1876 | s->address->address_length), |
1877 | *upload_data_size); | 1877 | (unsigned long) *upload_data_size); |
1878 | delay = GNUNET_TIME_absolute_get_remaining (s->next_receive); | 1878 | delay = GNUNET_TIME_absolute_get_remaining (s->next_receive); |
1879 | if (0 == delay.rel_value_us) | 1879 | if (0 == delay.rel_value_us) |
1880 | { | 1880 | { |
1881 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1881 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1882 | "PUT with %u bytes forwarded to MST\n", | 1882 | "PUT with %lu bytes forwarded to MST\n", |
1883 | *upload_data_size); | 1883 | (unsigned long) *upload_data_size); |
1884 | if (s->msg_tk == NULL) | 1884 | if (s->msg_tk == NULL) |
1885 | { | 1885 | { |
1886 | s->msg_tk = GNUNET_MST_create (&server_receive_mst_cb, | 1886 | s->msg_tk = GNUNET_MST_create (&server_receive_mst_cb, |
diff --git a/src/transport/plugin_transport_tcp.c b/src/transport/plugin_transport_tcp.c index e3bc21543..8378a64dd 100644 --- a/src/transport/plugin_transport_tcp.c +++ b/src/transport/plugin_transport_tcp.c | |||
@@ -2010,8 +2010,8 @@ do_transmit (void *cls, size_t size, void *buf) | |||
2010 | GNUNET_assert (pos->message_size <= session->bytes_in_queue); | 2010 | GNUNET_assert (pos->message_size <= session->bytes_in_queue); |
2011 | session->bytes_in_queue -= pos->message_size; | 2011 | session->bytes_in_queue -= pos->message_size; |
2012 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 2012 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
2013 | "Failed to transmit %u byte message to `%s'.\n", | 2013 | "Failed to transmit %lu byte message to `%s'.\n", |
2014 | pos->message_size, | 2014 | (unsigned long) pos->message_size, |
2015 | GNUNET_i2s (&session->target)); | 2015 | GNUNET_i2s (&session->target)); |
2016 | ret += pos->message_size; | 2016 | ret += pos->message_size; |
2017 | GNUNET_CONTAINER_DLL_insert_after (hd, tl, tl, pos); | 2017 | GNUNET_CONTAINER_DLL_insert_after (hd, tl, tl, pos); |
@@ -2067,9 +2067,9 @@ do_transmit (void *cls, size_t size, void *buf) | |||
2067 | session->bytes_in_queue -= pos->message_size; | 2067 | session->bytes_in_queue -= pos->message_size; |
2068 | GNUNET_assert (size >= pos->message_size); | 2068 | GNUNET_assert (size >= pos->message_size); |
2069 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 2069 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
2070 | "Transmitting message of type %u size %u to peer %s at %s\n", | 2070 | "Transmitting message of type %u size %lu to peer %s at %s\n", |
2071 | ntohs (((struct GNUNET_MessageHeader *) pos->msg)->type), | 2071 | ntohs (((struct GNUNET_MessageHeader *) pos->msg)->type), |
2072 | pos->message_size, | 2072 | (unsigned long) pos->message_size, |
2073 | GNUNET_i2s (&session->target), | 2073 | GNUNET_i2s (&session->target), |
2074 | tcp_plugin_address_to_string (session->plugin, | 2074 | tcp_plugin_address_to_string (session->plugin, |
2075 | session->address->address, | 2075 | session->address->address, |
@@ -2192,8 +2192,8 @@ tcp_plugin_send (void *cls, | |||
2192 | pm->transmit_cont_cls = cont_cls; | 2192 | pm->transmit_cont_cls = cont_cls; |
2193 | 2193 | ||
2194 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 2194 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
2195 | "Asked to transmit %u bytes to `%s', added message to list.\n", | 2195 | "Asked to transmit %lu bytes to `%s', added message to list.\n", |
2196 | msgbuf_size, | 2196 | (unsigned long) msgbuf_size, |
2197 | GNUNET_i2s (&session->target)); | 2197 | GNUNET_i2s (&session->target)); |
2198 | 2198 | ||
2199 | if (GNUNET_YES == | 2199 | if (GNUNET_YES == |
diff --git a/src/transport/plugin_transport_udp.c b/src/transport/plugin_transport_udp.c index ec3a0edd8..49e84dfe7 100644 --- a/src/transport/plugin_transport_udp.c +++ b/src/transport/plugin_transport_udp.c | |||
@@ -1821,7 +1821,8 @@ enqueue_fragment (void *cls, const struct GNUNET_MessageHeader *msg) | |||
1821 | struct GNUNET_ATS_Session *session = frag_ctx->session; | 1821 | struct GNUNET_ATS_Session *session = frag_ctx->session; |
1822 | size_t msg_len = ntohs (msg->size); | 1822 | size_t msg_len = ntohs (msg->size); |
1823 | 1823 | ||
1824 | LOG (GNUNET_ERROR_TYPE_DEBUG, "Enqueuing fragment with %u bytes\n", msg_len); | 1824 | LOG (GNUNET_ERROR_TYPE_DEBUG, "Enqueuing fragment with %lu bytes\n", |
1825 | (unsigned long) msg_len); | ||
1825 | udpw = GNUNET_malloc (sizeof(struct UDP_MessageWrapper) + msg_len); | 1826 | udpw = GNUNET_malloc (sizeof(struct UDP_MessageWrapper) + msg_len); |
1826 | udpw->session = session; | 1827 | udpw->session = session; |
1827 | udpw->msg_buf = (char *) &udpw[1]; | 1828 | udpw->msg_buf = (char *) &udpw[1]; |
@@ -1996,8 +1997,8 @@ udp_plugin_send (void *cls, | |||
1996 | return GNUNET_SYSERR; | 1997 | return GNUNET_SYSERR; |
1997 | } | 1998 | } |
1998 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1999 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1999 | "UDP transmits %u-byte message to `%s' using address `%s'\n", | 2000 | "UDP transmits %lu-byte message to `%s' using address `%s'\n", |
2000 | udpmlen, | 2001 | (unsigned long) udpmlen, |
2001 | GNUNET_i2s (&s->target), | 2002 | GNUNET_i2s (&s->target), |
2002 | udp_address_to_string (plugin, | 2003 | udp_address_to_string (plugin, |
2003 | s->address->address, | 2004 | s->address->address, |
@@ -3113,18 +3114,18 @@ remove_timeout_messages_and_select (struct Plugin *plugin, | |||
3113 | { | 3114 | { |
3114 | /* this message is not delayed */ | 3115 | /* this message is not delayed */ |
3115 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 3116 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
3116 | "Message for peer `%s' (%u bytes) is not delayed \n", | 3117 | "Message for peer `%s' (%lu bytes) is not delayed \n", |
3117 | GNUNET_i2s (&udpw->session->target), | 3118 | GNUNET_i2s (&udpw->session->target), |
3118 | udpw->payload_size); | 3119 | (unsigned long) udpw->payload_size); |
3119 | break; /* Found message to send, break */ | 3120 | break; /* Found message to send, break */ |
3120 | } | 3121 | } |
3121 | else | 3122 | else |
3122 | { | 3123 | { |
3123 | /* Message is delayed, try next */ | 3124 | /* Message is delayed, try next */ |
3124 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 3125 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
3125 | "Message for peer `%s' (%u bytes) is delayed for %s\n", | 3126 | "Message for peer `%s' (%lu bytes) is delayed for %s\n", |
3126 | GNUNET_i2s (&udpw->session->target), | 3127 | GNUNET_i2s (&udpw->session->target), |
3127 | udpw->payload_size, | 3128 | (unsigned long) udpw->payload_size, |
3128 | GNUNET_STRINGS_relative_time_to_string (remaining, GNUNET_YES)); | 3129 | GNUNET_STRINGS_relative_time_to_string (remaining, GNUNET_YES)); |
3129 | udpw = udpw->next; | 3130 | udpw = udpw->next; |
3130 | } | 3131 | } |
diff --git a/src/transport/plugin_transport_unix.c b/src/transport/plugin_transport_unix.c index 9d3e7d354..2324914c9 100644 --- a/src/transport/plugin_transport_unix.c +++ b/src/transport/plugin_transport_unix.c | |||
@@ -1304,8 +1304,8 @@ unix_plugin_send (void *cls, | |||
1304 | return GNUNET_SYSERR; | 1304 | return GNUNET_SYSERR; |
1305 | } | 1305 | } |
1306 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1306 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1307 | "Sending %u bytes with session for peer `%s' `%s'\n", | 1307 | "Sending %lu bytes with session for peer `%s' `%s'\n", |
1308 | msgbuf_size, | 1308 | (unsigned long) msgbuf_size, |
1309 | GNUNET_i2s (&session->target), | 1309 | GNUNET_i2s (&session->target), |
1310 | unix_plugin_address_to_string (NULL, | 1310 | unix_plugin_address_to_string (NULL, |
1311 | session->address->address, | 1311 | session->address->address, |
diff --git a/src/transport/tcp_connection_legacy.c b/src/transport/tcp_connection_legacy.c index 3e173b8a4..924362ef2 100644 --- a/src/transport/tcp_connection_legacy.c +++ b/src/transport/tcp_connection_legacy.c | |||
@@ -1142,9 +1142,9 @@ RETRY: | |||
1142 | return; | 1142 | return; |
1143 | } | 1143 | } |
1144 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1144 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1145 | "receive_ready read %u/%u bytes from `%s' (%p)!\n", | 1145 | "receive_ready read %lu/%lu bytes from `%s' (%p)!\n", |
1146 | (unsigned int) ret, | 1146 | (unsigned long) ret, |
1147 | connection->max, | 1147 | (unsigned long) connection->max, |
1148 | GNUNET_a2s (connection->addr, connection->addrlen), | 1148 | GNUNET_a2s (connection->addr, connection->addrlen), |
1149 | connection); | 1149 | connection); |
1150 | GNUNET_assert (NULL != (receiver = connection->receiver)); | 1150 | GNUNET_assert (NULL != (receiver = connection->receiver)); |
@@ -1327,8 +1327,8 @@ connect_error (void *cls) | |||
1327 | GNUNET_CONNECTION_TransmitReadyNotify notify; | 1327 | GNUNET_CONNECTION_TransmitReadyNotify notify; |
1328 | 1328 | ||
1329 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1329 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1330 | "Transmission request of size %u fails (%s/%u), connection failed (%p).\n", | 1330 | "Transmission request of size %lu fails (%s/%u), connection failed (%p).\n", |
1331 | connection->nth.notify_size, | 1331 | (unsigned long) connection->nth.notify_size, |
1332 | connection->hostname, | 1332 | connection->hostname, |
1333 | connection->port, | 1333 | connection->port, |
1334 | connection); | 1334 | connection); |
@@ -1423,9 +1423,9 @@ RETRY: | |||
1423 | return; | 1423 | return; |
1424 | } | 1424 | } |
1425 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1425 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1426 | "Connection transmitted %u/%u bytes to `%s' (%p)\n", | 1426 | "Connection transmitted %lu/%lu bytes to `%s' (%p)\n", |
1427 | (unsigned int) ret, | 1427 | (unsigned long) ret, |
1428 | have, | 1428 | (unsigned long) have, |
1429 | GNUNET_a2s (connection->addr, connection->addrlen), | 1429 | GNUNET_a2s (connection->addr, connection->addrlen), |
1430 | connection); | 1430 | connection); |
1431 | connection->write_buffer_pos += ret; | 1431 | connection->write_buffer_pos += ret; |
diff --git a/src/transport/tcp_service_legacy.c b/src/transport/tcp_service_legacy.c index 12dce3993..8606b353b 100644 --- a/src/transport/tcp_service_legacy.c +++ b/src/transport/tcp_service_legacy.c | |||
@@ -1433,7 +1433,7 @@ LEGACY_SERVICE_run (int argc, | |||
1433 | { | 1433 | { |
1434 | clock_offset = skew_offset - skew_variance; | 1434 | clock_offset = skew_offset - skew_variance; |
1435 | GNUNET_TIME_set_offset (clock_offset); | 1435 | GNUNET_TIME_set_offset (clock_offset); |
1436 | LOG (GNUNET_ERROR_TYPE_DEBUG, "Skewing clock by %dll ms\n", clock_offset); | 1436 | LOG (GNUNET_ERROR_TYPE_DEBUG, "Skewing clock by %lld ms\n", clock_offset); |
1437 | } | 1437 | } |
1438 | /* actually run service */ | 1438 | /* actually run service */ |
1439 | err = 0; | 1439 | err = 0; |
diff --git a/src/transport/test_communicator_basic.c b/src/transport/test_communicator_basic.c index e3573ac2c..8251a5169 100644 --- a/src/transport/test_communicator_basic.c +++ b/src/transport/test_communicator_basic.c | |||
@@ -82,6 +82,11 @@ static struct GNUNET_TRANSPORT_TESTING_TransportCommunicatorHandle *my_tc; | |||
82 | 82 | ||
83 | static unsigned int iterations_left = TOTAL_ITERATIONS; | 83 | static unsigned int iterations_left = TOTAL_ITERATIONS; |
84 | 84 | ||
85 | #define TIMEOUT_MULTIPLIER 1 | ||
86 | |||
87 | #define DELAY \ | ||
88 | GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MICROSECONDS,50) | ||
89 | |||
85 | #define SHORT_BURST_WINDOW \ | 90 | #define SHORT_BURST_WINDOW \ |
86 | GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS,2) | 91 | GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_SECONDS,2) |
87 | 92 | ||
@@ -97,13 +102,21 @@ enum TestPhase | |||
97 | }; | 102 | }; |
98 | 103 | ||
99 | 104 | ||
100 | static size_t num_sent = 0; | 105 | static size_t num_sent_short = 0; |
106 | |||
107 | static size_t num_sent_long = 0; | ||
108 | |||
109 | static size_t num_sent_size = 0; | ||
101 | 110 | ||
102 | static uint32_t ack = 0; | 111 | static uint32_t ack = 0; |
103 | 112 | ||
104 | static enum TestPhase phase; | 113 | static enum TestPhase phase; |
105 | 114 | ||
106 | static size_t num_received = 0; | 115 | static size_t num_received_short = 0; |
116 | |||
117 | static size_t num_received_long = 0; | ||
118 | |||
119 | static size_t num_received_size = 0; | ||
107 | 120 | ||
108 | static uint64_t avg_latency = 0; | 121 | static uint64_t avg_latency = 0; |
109 | 122 | ||
@@ -230,6 +243,10 @@ make_payload (size_t payload_size) | |||
230 | static void | 243 | static void |
231 | latency_timeout (void *cls) | 244 | latency_timeout (void *cls) |
232 | { | 245 | { |
246 | |||
247 | size_t num_sent = 0; | ||
248 | size_t num_received = 0; | ||
249 | |||
233 | to_task = NULL; | 250 | to_task = NULL; |
234 | if (GNUNET_TIME_absolute_get_remaining (timeout).rel_value_us > 0) | 251 | if (GNUNET_TIME_absolute_get_remaining (timeout).rel_value_us > 0) |
235 | { | 252 | { |
@@ -239,6 +256,21 @@ latency_timeout (void *cls) | |||
239 | return; | 256 | return; |
240 | } | 257 | } |
241 | 258 | ||
259 | switch (phase) | ||
260 | { | ||
261 | case TP_BURST_SHORT: | ||
262 | num_sent = num_sent_short; | ||
263 | num_received = num_received_short; | ||
264 | break; | ||
265 | case TP_BURST_LONG: | ||
266 | num_sent = num_sent_long; | ||
267 | num_received = num_received_long; | ||
268 | break; | ||
269 | case TP_SIZE_CHECK: | ||
270 | num_sent = num_sent_size; | ||
271 | num_received = num_received_size; | ||
272 | break; | ||
273 | } | ||
242 | LOG (GNUNET_ERROR_TYPE_ERROR, | 274 | LOG (GNUNET_ERROR_TYPE_ERROR, |
243 | "Latency too high. Test failed. (Phase: %d. Sent: %lu, Received: %lu)\n", | 275 | "Latency too high. Test failed. (Phase: %d. Sent: %lu, Received: %lu)\n", |
244 | phase, num_sent, num_received); | 276 | phase, num_sent, num_received); |
@@ -246,6 +278,8 @@ latency_timeout (void *cls) | |||
246 | GNUNET_SCHEDULER_shutdown (); | 278 | GNUNET_SCHEDULER_shutdown (); |
247 | } | 279 | } |
248 | 280 | ||
281 | /*static void | ||
282 | size_test (void *cls);*/ | ||
249 | 283 | ||
250 | static void | 284 | static void |
251 | size_test (void *cls) | 285 | size_test (void *cls) |
@@ -253,6 +287,9 @@ size_test (void *cls) | |||
253 | char *payload; | 287 | char *payload; |
254 | size_t max_size = 64000; | 288 | size_t max_size = 64000; |
255 | 289 | ||
290 | LOG (GNUNET_ERROR_TYPE_DEBUG, | ||
291 | "size_test_cb %u\n", | ||
292 | num_sent_size); | ||
256 | GNUNET_assert (TP_SIZE_CHECK == phase); | 293 | GNUNET_assert (TP_SIZE_CHECK == phase); |
257 | if (LONG_MESSAGE_SIZE != long_message_size) | 294 | if (LONG_MESSAGE_SIZE != long_message_size) |
258 | max_size = long_message_size; | 295 | max_size = long_message_size; |
@@ -260,7 +297,7 @@ size_test (void *cls) | |||
260 | return; /* Leave some room for our protocol, so not 2^16 exactly */ | 297 | return; /* Leave some room for our protocol, so not 2^16 exactly */ |
261 | ack += 10; | 298 | ack += 10; |
262 | payload = make_payload (ack); | 299 | payload = make_payload (ack); |
263 | num_sent++; | 300 | num_sent_size++; |
264 | GNUNET_TRANSPORT_TESTING_transport_communicator_send (my_tc, | 301 | GNUNET_TRANSPORT_TESTING_transport_communicator_send (my_tc, |
265 | (ack < max_size) | 302 | (ack < max_size) |
266 | ? &size_test | 303 | ? &size_test |
@@ -269,47 +306,98 @@ size_test (void *cls) | |||
269 | payload, | 306 | payload, |
270 | ack); | 307 | ack); |
271 | GNUNET_free (payload); | 308 | GNUNET_free (payload); |
272 | timeout = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_UNIT_SECONDS); | 309 | timeout = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_relative_multiply ( |
310 | GNUNET_TIME_UNIT_SECONDS, | ||
311 | TIMEOUT_MULTIPLIER)); | ||
273 | } | 312 | } |
274 | 313 | ||
314 | /*static void | ||
315 | size_test (void *cls) | ||
316 | { | ||
317 | GNUNET_SCHEDULER_add_delayed (DELAY, | ||
318 | &size_test_cb, | ||
319 | NULL); | ||
320 | }*/ | ||
321 | |||
322 | static void | ||
323 | long_test (void *cls); | ||
275 | 324 | ||
276 | static void | 325 | static void |
277 | long_test (void *cls) | 326 | long_test_cb (void *cls) |
278 | { | 327 | { |
279 | char *payload; | 328 | char *payload; |
280 | 329 | ||
330 | LOG (GNUNET_ERROR_TYPE_DEBUG, | ||
331 | "long_test_cb %u/%u\n", | ||
332 | num_sent_long, | ||
333 | num_received_long); | ||
281 | payload = make_payload (long_message_size); | 334 | payload = make_payload (long_message_size); |
282 | num_sent++; | 335 | num_sent_long++; |
283 | GNUNET_TRANSPORT_TESTING_transport_communicator_send (my_tc, | 336 | GNUNET_TRANSPORT_TESTING_transport_communicator_send (my_tc, |
284 | (BURST_PACKETS == | 337 | ((BURST_PACKETS |
285 | num_sent) | 338 | * 0.91 == |
339 | num_received_long) || | ||
340 | (BURST_PACKETS == | ||
341 | num_sent_long)) | ||
286 | ? NULL | 342 | ? NULL |
287 | : &long_test, | 343 | : &long_test, |
288 | NULL, | 344 | NULL, |
289 | payload, | 345 | payload, |
290 | long_message_size); | 346 | long_message_size); |
291 | GNUNET_free (payload); | 347 | GNUNET_free (payload); |
292 | timeout = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_UNIT_SECONDS); | 348 | timeout = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_relative_multiply ( |
349 | GNUNET_TIME_UNIT_SECONDS, | ||
350 | TIMEOUT_MULTIPLIER)); | ||
293 | } | 351 | } |
294 | 352 | ||
353 | static void | ||
354 | long_test (void *cls) | ||
355 | { | ||
356 | /*LOG (GNUNET_ERROR_TYPE_DEBUG, | ||
357 | "long_test %u\n", | ||
358 | num_sent_long);*/ | ||
359 | GNUNET_SCHEDULER_add_delayed (DELAY, | ||
360 | &long_test_cb, | ||
361 | NULL); | ||
362 | } | ||
295 | 363 | ||
296 | static void | 364 | static void |
297 | short_test (void *cls) | 365 | short_test (void *cls); |
366 | |||
367 | static void | ||
368 | short_test_cb (void *cls) | ||
298 | { | 369 | { |
299 | char *payload; | 370 | char *payload; |
300 | 371 | ||
372 | LOG (GNUNET_ERROR_TYPE_DEBUG, | ||
373 | "short_test_cb %u/%u\n", | ||
374 | num_sent_short, | ||
375 | num_received_short); | ||
301 | payload = make_payload (SHORT_MESSAGE_SIZE); | 376 | payload = make_payload (SHORT_MESSAGE_SIZE); |
302 | num_sent++; | 377 | num_sent_short++; |
303 | GNUNET_TRANSPORT_TESTING_transport_communicator_send (my_tc, | 378 | GNUNET_TRANSPORT_TESTING_transport_communicator_send (my_tc, |
304 | (BURST_PACKETS == | 379 | ((BURST_PACKETS |
305 | num_sent) | 380 | * 0.91 == |
381 | num_received_short) || | ||
382 | (BURST_PACKETS == | ||
383 | num_sent_short)) | ||
306 | ? NULL | 384 | ? NULL |
307 | : &short_test, | 385 | : &short_test, |
308 | NULL, | 386 | NULL, |
309 | payload, | 387 | payload, |
310 | SHORT_MESSAGE_SIZE); | 388 | SHORT_MESSAGE_SIZE); |
311 | GNUNET_free (payload); | 389 | GNUNET_free (payload); |
312 | timeout = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_UNIT_SECONDS); | 390 | timeout = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_relative_multiply ( |
391 | GNUNET_TIME_UNIT_SECONDS, | ||
392 | TIMEOUT_MULTIPLIER)); | ||
393 | } | ||
394 | |||
395 | static void | ||
396 | short_test (void *cls) | ||
397 | { | ||
398 | GNUNET_SCHEDULER_add_delayed (DELAY, | ||
399 | &short_test_cb, | ||
400 | NULL); | ||
313 | } | 401 | } |
314 | 402 | ||
315 | 403 | ||
@@ -373,12 +461,17 @@ add_queue_cb (void *cls, | |||
373 | else | 461 | else |
374 | long_message_size = LONG_MESSAGE_SIZE; | 462 | long_message_size = LONG_MESSAGE_SIZE; |
375 | phase = TP_BURST_SHORT; | 463 | phase = TP_BURST_SHORT; |
376 | timeout = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_UNIT_MINUTES); | 464 | timeout = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_relative_multiply ( |
465 | GNUNET_TIME_UNIT_SECONDS, | ||
466 | TIMEOUT_MULTIPLIER)); | ||
377 | GNUNET_assert (NULL == to_task); | 467 | GNUNET_assert (NULL == to_task); |
378 | to_task = GNUNET_SCHEDULER_add_delayed (GNUNET_TIME_UNIT_MINUTES, | 468 | to_task = GNUNET_SCHEDULER_add_delayed (GNUNET_TIME_relative_multiply ( |
469 | GNUNET_TIME_UNIT_SECONDS, | ||
470 | TIMEOUT_MULTIPLIER), | ||
379 | &latency_timeout, | 471 | &latency_timeout, |
380 | NULL); | 472 | NULL); |
381 | prepare_test (NULL); | 473 | // prepare_test (NULL); |
474 | short_test (NULL); | ||
382 | } | 475 | } |
383 | 476 | ||
384 | 477 | ||
@@ -388,10 +481,26 @@ update_avg_latency (const char*payload) | |||
388 | struct GNUNET_TIME_AbsoluteNBO *ts_n; | 481 | struct GNUNET_TIME_AbsoluteNBO *ts_n; |
389 | struct GNUNET_TIME_Absolute ts; | 482 | struct GNUNET_TIME_Absolute ts; |
390 | struct GNUNET_TIME_Relative latency; | 483 | struct GNUNET_TIME_Relative latency; |
484 | size_t num_received = 0; | ||
391 | 485 | ||
392 | ts_n = (struct GNUNET_TIME_AbsoluteNBO *) payload; | 486 | ts_n = (struct GNUNET_TIME_AbsoluteNBO *) payload; |
393 | ts = GNUNET_TIME_absolute_ntoh (*ts_n); | 487 | ts = GNUNET_TIME_absolute_ntoh (*ts_n); |
394 | latency = GNUNET_TIME_absolute_get_duration (ts); | 488 | latency = GNUNET_TIME_absolute_get_duration (ts); |
489 | LOG (GNUNET_ERROR_TYPE_DEBUG, | ||
490 | "Latency of received packet: %u\n", | ||
491 | latency); | ||
492 | switch (phase) | ||
493 | { | ||
494 | case TP_BURST_SHORT: | ||
495 | num_received = num_received_short; | ||
496 | break; | ||
497 | case TP_BURST_LONG: | ||
498 | num_received = num_received_long; | ||
499 | break; | ||
500 | case TP_SIZE_CHECK: | ||
501 | num_received = num_received_size; | ||
502 | break; | ||
503 | } | ||
395 | if (1 >= num_received) | 504 | if (1 >= num_received) |
396 | avg_latency = latency.rel_value_us; | 505 | avg_latency = latency.rel_value_us; |
397 | else | 506 | else |
@@ -400,7 +509,6 @@ update_avg_latency (const char*payload) | |||
400 | 509 | ||
401 | } | 510 | } |
402 | 511 | ||
403 | |||
404 | /** | 512 | /** |
405 | * @brief Handle an incoming message | 513 | * @brief Handle an incoming message |
406 | * | 514 | * |
@@ -412,7 +520,8 @@ update_avg_latency (const char*payload) | |||
412 | */ | 520 | */ |
413 | static void | 521 | static void |
414 | incoming_message_cb (void *cls, | 522 | incoming_message_cb (void *cls, |
415 | struct GNUNET_TRANSPORT_TESTING_TransportCommunicatorHandle | 523 | struct |
524 | GNUNET_TRANSPORT_TESTING_TransportCommunicatorHandle | ||
416 | *tc_h, | 525 | *tc_h, |
417 | const char*payload, | 526 | const char*payload, |
418 | size_t payload_len) | 527 | size_t payload_len) |
@@ -424,7 +533,9 @@ incoming_message_cb (void *cls, | |||
424 | return; | 533 | return; |
425 | } | 534 | } |
426 | /* Reset timeout */ | 535 | /* Reset timeout */ |
427 | timeout = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_UNIT_SECONDS); | 536 | timeout = GNUNET_TIME_relative_to_absolute (GNUNET_TIME_relative_multiply ( |
537 | GNUNET_TIME_UNIT_SECONDS, | ||
538 | TIMEOUT_MULTIPLIER)); | ||
428 | switch (phase) | 539 | switch (phase) |
429 | { | 540 | { |
430 | case TP_INIT: | 541 | case TP_INIT: |
@@ -433,30 +544,31 @@ incoming_message_cb (void *cls, | |||
433 | case TP_BURST_SHORT: | 544 | case TP_BURST_SHORT: |
434 | { | 545 | { |
435 | GNUNET_assert (SHORT_MESSAGE_SIZE == payload_len); | 546 | GNUNET_assert (SHORT_MESSAGE_SIZE == payload_len); |
436 | num_received++; | 547 | num_received_short++; |
437 | duration = GNUNET_TIME_absolute_get_duration (start_short); | 548 | duration = GNUNET_TIME_absolute_get_duration (start_short); |
438 | update_avg_latency (payload); | 549 | update_avg_latency (payload); |
439 | if (num_received == BURST_PACKETS) | 550 | if (num_received_short == BURST_PACKETS * 0.91) |
440 | { | 551 | { |
441 | LOG (GNUNET_ERROR_TYPE_MESSAGE, | 552 | LOG (GNUNET_ERROR_TYPE_MESSAGE, |
442 | "Short size packet test done.\n"); | 553 | "Short size packet test done.\n"); |
443 | char *goodput = GNUNET_STRINGS_byte_size_fancy ((SHORT_MESSAGE_SIZE | 554 | char *goodput = GNUNET_STRINGS_byte_size_fancy ((SHORT_MESSAGE_SIZE |
444 | * num_received * 1000 | 555 | * num_received_short |
556 | * 1000 | ||
445 | * 1000) | 557 | * 1000) |
446 | / duration.rel_value_us); | 558 | / duration.rel_value_us); |
447 | LOG (GNUNET_ERROR_TYPE_MESSAGE, | 559 | LOG (GNUNET_ERROR_TYPE_MESSAGE, |
448 | "%lu/%lu packets in %llu us (%s/s) -- avg latency: %llu us\n", | 560 | "%lu/%lu packets in %llu us (%s/s) -- avg latency: %llu us\n", |
449 | (unsigned long) num_received, | 561 | (unsigned long) num_received_short, |
450 | (unsigned long) num_sent, | 562 | (unsigned long) num_sent_short, |
451 | (unsigned long long) duration.rel_value_us, | 563 | (unsigned long long) duration.rel_value_us, |
452 | goodput, | 564 | goodput, |
453 | (unsigned long long) avg_latency); | 565 | (unsigned long long) avg_latency); |
454 | GNUNET_free (goodput); | 566 | GNUNET_free (goodput); |
455 | start_long = GNUNET_TIME_absolute_get (); | 567 | start_long = GNUNET_TIME_absolute_get (); |
456 | phase = TP_BURST_LONG; | 568 | phase = TP_BURST_LONG; |
457 | num_sent = 0; | 569 | // num_sent_short = 0; |
458 | avg_latency = 0; | 570 | avg_latency = 0; |
459 | num_received = 0; | 571 | // num_received = 0; |
460 | long_test (NULL); | 572 | long_test (NULL); |
461 | } | 573 | } |
462 | break; | 574 | break; |
@@ -467,32 +579,34 @@ incoming_message_cb (void *cls, | |||
467 | { | 579 | { |
468 | LOG (GNUNET_ERROR_TYPE_WARNING, | 580 | LOG (GNUNET_ERROR_TYPE_WARNING, |
469 | "Ignoring packet with wrong length\n"); | 581 | "Ignoring packet with wrong length\n"); |
470 | return; // Ignore | 582 | return; // Ignore |
471 | } | 583 | } |
472 | num_received++; | 584 | num_received_long++; |
473 | duration = GNUNET_TIME_absolute_get_duration (start_long); | 585 | duration = GNUNET_TIME_absolute_get_duration (start_long); |
474 | update_avg_latency (payload); | 586 | update_avg_latency (payload); |
475 | if (num_received == BURST_PACKETS) | 587 | if (num_received_long == BURST_PACKETS * 0.91) |
476 | { | 588 | { |
477 | LOG (GNUNET_ERROR_TYPE_MESSAGE, | 589 | LOG (GNUNET_ERROR_TYPE_MESSAGE, |
478 | "Long size packet test done.\n"); | 590 | "Long size packet test done.\n"); |
479 | char *goodput = GNUNET_STRINGS_byte_size_fancy ((long_message_size | 591 | char *goodput = GNUNET_STRINGS_byte_size_fancy ((long_message_size |
480 | * num_received * 1000 | 592 | * num_received_long |
593 | * 1000 | ||
481 | * 1000) | 594 | * 1000) |
482 | / duration.rel_value_us); | 595 | / duration. |
596 | rel_value_us); | ||
483 | 597 | ||
484 | LOG (GNUNET_ERROR_TYPE_MESSAGE, | 598 | LOG (GNUNET_ERROR_TYPE_MESSAGE, |
485 | "%lu/%lu packets in %llu us (%s/s) -- avg latency: %llu us\n", | 599 | "%lu/%lu packets in %llu us (%s/s) -- avg latency: %llu us\n", |
486 | (unsigned long) num_received, | 600 | (unsigned long) num_received_long, |
487 | (unsigned long) num_sent, | 601 | (unsigned long) num_sent_long, |
488 | (unsigned long long) duration.rel_value_us, | 602 | (unsigned long long) duration.rel_value_us, |
489 | goodput, | 603 | goodput, |
490 | (unsigned long long) avg_latency); | 604 | (unsigned long long) avg_latency); |
491 | GNUNET_free (goodput); | 605 | GNUNET_free (goodput); |
492 | ack = 0; | 606 | ack = 0; |
493 | phase = TP_SIZE_CHECK; | 607 | phase = TP_SIZE_CHECK; |
494 | num_received = 0; | 608 | // num_received = 0; |
495 | num_sent = 0; | 609 | // num_sent_long = 0; |
496 | avg_latency = 0; | 610 | avg_latency = 0; |
497 | size_test (NULL); | 611 | size_test (NULL); |
498 | } | 612 | } |
@@ -505,25 +619,29 @@ incoming_message_cb (void *cls, | |||
505 | GNUNET_assert (TP_SIZE_CHECK == phase); | 619 | GNUNET_assert (TP_SIZE_CHECK == phase); |
506 | if (LONG_MESSAGE_SIZE != long_message_size) | 620 | if (LONG_MESSAGE_SIZE != long_message_size) |
507 | max_size = long_message_size; | 621 | max_size = long_message_size; |
508 | num_received++; | 622 | num_received_size++; |
509 | update_avg_latency (payload); | 623 | update_avg_latency (payload); |
510 | if (num_received >= (max_size) / 10) | 624 | if (num_received_size >= (max_size) / 10) |
511 | { | 625 | { |
512 | LOG (GNUNET_ERROR_TYPE_MESSAGE, | 626 | LOG (GNUNET_ERROR_TYPE_MESSAGE, |
513 | "Size packet test done.\n"); | 627 | "Size packet test done.\n"); |
514 | LOG (GNUNET_ERROR_TYPE_MESSAGE, | 628 | LOG (GNUNET_ERROR_TYPE_MESSAGE, |
515 | "%lu/%lu packets -- avg latency: %llu us\n", | 629 | "%lu/%lu packets -- avg latency: %llu us\n", |
516 | (unsigned long) num_received, | 630 | (unsigned long) num_received_size, |
517 | (unsigned long) num_sent, | 631 | (unsigned long) num_sent_size, |
518 | (unsigned long long) avg_latency); | 632 | (unsigned long long) avg_latency); |
519 | num_received = 0; | 633 | num_received_size = 0; |
520 | num_sent = 0; | 634 | num_sent_size = 0; |
521 | avg_latency = 0; | 635 | avg_latency = 0; |
522 | iterations_left--; | 636 | iterations_left--; |
523 | if (0 != iterations_left) | 637 | if (0 != iterations_left) |
524 | { | 638 | { |
525 | start_short = GNUNET_TIME_absolute_get (); | 639 | start_short = GNUNET_TIME_absolute_get (); |
526 | phase = TP_BURST_SHORT; | 640 | phase = TP_BURST_SHORT; |
641 | num_sent_short = 0; | ||
642 | num_sent_long = 0; | ||
643 | num_received_short = 0; | ||
644 | num_received_long = 0; | ||
527 | short_test (NULL); | 645 | short_test (NULL); |
528 | break; | 646 | break; |
529 | } | 647 | } |
@@ -561,8 +679,8 @@ static void | |||
561 | run (void *cls) | 679 | run (void *cls) |
562 | { | 680 | { |
563 | ret = 0; | 681 | ret = 0; |
564 | num_received = 0; | 682 | // num_received = 0; |
565 | num_sent = 0; | 683 | // num_sent = 0; |
566 | for (unsigned int i = 0; i < NUM_PEERS; i++) | 684 | for (unsigned int i = 0; i < NUM_PEERS; i++) |
567 | { | 685 | { |
568 | tc_hs[i] = GNUNET_TRANSPORT_TESTING_transport_communicator_service_start ( | 686 | tc_hs[i] = GNUNET_TRANSPORT_TESTING_transport_communicator_service_start ( |
diff --git a/src/transport/transport-testing2.c b/src/transport/transport-testing2.c index 98cfd5e29..076fbf331 100644 --- a/src/transport/transport-testing2.c +++ b/src/transport/transport-testing2.c | |||
@@ -553,7 +553,12 @@ handle_update_queue_message (void *cls, | |||
553 | tc_queue->mtu = ntohl (msg->mtu); | 553 | tc_queue->mtu = ntohl (msg->mtu); |
554 | tc_queue->cs = msg->cs; | 554 | tc_queue->cs = msg->cs; |
555 | tc_queue->priority = ntohl (msg->priority); | 555 | tc_queue->priority = ntohl (msg->priority); |
556 | // Uncomment this for alternativ 1 of backchannel functionality | ||
556 | tc_queue->q_len += GNUNET_ntohll (msg->q_len); | 557 | tc_queue->q_len += GNUNET_ntohll (msg->q_len); |
558 | // Until here for alternativ 1 | ||
559 | // Uncomment this for alternativ 2 of backchannel functionality | ||
560 | // tc_queue->q_len = GNUNET_ntohll (msg->q_len); | ||
561 | // Until here for alternativ 2 | ||
557 | GNUNET_SERVICE_client_continue (client->client); | 562 | GNUNET_SERVICE_client_continue (client->client); |
558 | } | 563 | } |
559 | 564 | ||
@@ -1130,8 +1135,10 @@ GNUNET_TRANSPORT_TESTING_transport_communicator_send | |||
1130 | } | 1135 | } |
1131 | } | 1136 | } |
1132 | GNUNET_assert (NULL != tc_queue); | 1137 | GNUNET_assert (NULL != tc_queue); |
1138 | // Uncomment this for alternativ 1 of backchannel functionality | ||
1133 | if (tc_queue->q_len != GNUNET_TRANSPORT_QUEUE_LENGTH_UNLIMITED) | 1139 | if (tc_queue->q_len != GNUNET_TRANSPORT_QUEUE_LENGTH_UNLIMITED) |
1134 | tc_queue->q_len--; | 1140 | tc_queue->q_len--; |
1141 | // Until here for alternativ 1 | ||
1135 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1142 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1136 | "Sending message\n"); | 1143 | "Sending message\n"); |
1137 | inbox_size = sizeof (struct GNUNET_MessageHeader) + payload_size; | 1144 | inbox_size = sizeof (struct GNUNET_MessageHeader) + payload_size; |
diff --git a/src/util/bio.c b/src/util/bio.c index 39050bb87..43a2abc89 100644 --- a/src/util/bio.c +++ b/src/util/bio.c | |||
@@ -356,10 +356,10 @@ GNUNET_BIO_read_string (struct GNUNET_BIO_ReadHandle *h, | |||
356 | if (big > max_length) | 356 | if (big > max_length) |
357 | { | 357 | { |
358 | GNUNET_asprintf (&h->emsg, | 358 | GNUNET_asprintf (&h->emsg, |
359 | _ ("String `%s' longer than allowed (%u > %u)"), | 359 | _ ("String `%s' longer than allowed (%u > %lu)"), |
360 | what, | 360 | what, |
361 | big, | 361 | big, |
362 | max_length); | 362 | (unsigned long) max_length); |
363 | return GNUNET_SYSERR; | 363 | return GNUNET_SYSERR; |
364 | } | 364 | } |
365 | buf = GNUNET_malloc (big); | 365 | buf = GNUNET_malloc (big); |
diff --git a/src/util/client.c b/src/util/client.c index 86dabe664..2df439175 100644 --- a/src/util/client.c +++ b/src/util/client.c | |||
@@ -654,7 +654,7 @@ try_connect_using_address (void *cls, | |||
654 | "Trying to connect using address `%s:%u'\n", | 654 | "Trying to connect using address `%s:%u'\n", |
655 | GNUNET_a2s (addr, | 655 | GNUNET_a2s (addr, |
656 | addrlen), | 656 | addrlen), |
657 | cstate->port); | 657 | (unsigned int) cstate->port); |
658 | ap = GNUNET_malloc (sizeof(struct AddressProbe) + addrlen); | 658 | ap = GNUNET_malloc (sizeof(struct AddressProbe) + addrlen); |
659 | ap->addr = (const struct sockaddr *) &ap[1]; | 659 | ap->addr = (const struct sockaddr *) &ap[1]; |
660 | GNUNET_memcpy (&ap[1], | 660 | GNUNET_memcpy (&ap[1], |
diff --git a/src/util/configuration_loader.c b/src/util/configuration_loader.c index b9e5cb67f..a59477b25 100644 --- a/src/util/configuration_loader.c +++ b/src/util/configuration_loader.c | |||
@@ -47,7 +47,8 @@ GNUNET_CONFIGURATION_load (struct GNUNET_CONFIGURATION_Handle *cfg, | |||
47 | 47 | ||
48 | base_config_varname = GNUNET_OS_project_data_get ()->base_config_varname; | 48 | base_config_varname = GNUNET_OS_project_data_get ()->base_config_varname; |
49 | 49 | ||
50 | if (NULL != (baseconfig = getenv (base_config_varname))) | 50 | if (NULL != base_config_varname |
51 | && NULL != (baseconfig = getenv (base_config_varname))) | ||
51 | { | 52 | { |
52 | baseconfig = GNUNET_strdup (baseconfig); | 53 | baseconfig = GNUNET_strdup (baseconfig); |
53 | } | 54 | } |
@@ -62,14 +63,16 @@ GNUNET_CONFIGURATION_load (struct GNUNET_CONFIGURATION_Handle *cfg, | |||
62 | GNUNET_free (ipath); | 63 | GNUNET_free (ipath); |
63 | } | 64 | } |
64 | 65 | ||
65 | if (GNUNET_SYSERR == | 66 | char *dname = GNUNET_STRINGS_filename_expand (baseconfig); |
66 | GNUNET_CONFIGURATION_load_from (cfg, | 67 | GNUNET_free (baseconfig); |
67 | baseconfig)) | 68 | |
69 | if (GNUNET_YES == GNUNET_DISK_directory_test (dname, GNUNET_YES) && | ||
70 | GNUNET_SYSERR == GNUNET_CONFIGURATION_load_from (cfg, dname)) | ||
68 | { | 71 | { |
69 | GNUNET_free (baseconfig); | 72 | GNUNET_free (dname); |
70 | return GNUNET_SYSERR; /* no configuration at all found */ | 73 | return GNUNET_SYSERR; /* no configuration at all found */ |
71 | } | 74 | } |
72 | GNUNET_free (baseconfig); | 75 | GNUNET_free (dname); |
73 | if ((NULL != filename) && | 76 | if ((NULL != filename) && |
74 | (GNUNET_OK != GNUNET_CONFIGURATION_parse (cfg, filename))) | 77 | (GNUNET_OK != GNUNET_CONFIGURATION_parse (cfg, filename))) |
75 | { | 78 | { |
diff --git a/src/util/os_installation.c b/src/util/os_installation.c index 34b88d761..1f2dd2e5b 100644 --- a/src/util/os_installation.c +++ b/src/util/os_installation.c | |||
@@ -150,6 +150,8 @@ get_path_from_proc_maps () | |||
150 | FILE *f; | 150 | FILE *f; |
151 | char *lgu; | 151 | char *lgu; |
152 | 152 | ||
153 | if (NULL == current_pd->libname) | ||
154 | return NULL; | ||
153 | GNUNET_snprintf (fn, sizeof(fn), "/proc/%u/maps", getpid ()); | 155 | GNUNET_snprintf (fn, sizeof(fn), "/proc/%u/maps", getpid ()); |
154 | if (NULL == (f = fopen (fn, "r"))) | 156 | if (NULL == (f = fopen (fn, "r"))) |
155 | return NULL; | 157 | return NULL; |
diff --git a/src/util/program.c b/src/util/program.c index 8bda34b4f..b5484855c 100644 --- a/src/util/program.c +++ b/src/util/program.c | |||
@@ -232,15 +232,20 @@ GNUNET_PROGRAM_run2 (int argc, | |||
232 | sizeof(struct GNUNET_GETOPT_CommandLineOption), | 232 | sizeof(struct GNUNET_GETOPT_CommandLineOption), |
233 | &cmd_sorter); | 233 | &cmd_sorter); |
234 | loglev = NULL; | 234 | loglev = NULL; |
235 | xdg = getenv ("XDG_CONFIG_HOME"); | 235 | if (NULL != pd->config_file && NULL != pd->user_config_file) |
236 | if (NULL != xdg) | 236 | { |
237 | GNUNET_asprintf (&cfg_fn, | 237 | xdg = getenv ("XDG_CONFIG_HOME"); |
238 | "%s%s%s", | 238 | if (NULL != xdg) |
239 | xdg, | 239 | GNUNET_asprintf (&cfg_fn, |
240 | DIR_SEPARATOR_STR, | 240 | "%s%s%s", |
241 | pd->config_file); | 241 | xdg, |
242 | DIR_SEPARATOR_STR, | ||
243 | pd->config_file); | ||
244 | else | ||
245 | cfg_fn = GNUNET_strdup (pd->user_config_file); | ||
246 | } | ||
242 | else | 247 | else |
243 | cfg_fn = GNUNET_strdup (pd->user_config_file); | 248 | cfg_fn = NULL; |
244 | lpfx = GNUNET_strdup (binaryName); | 249 | lpfx = GNUNET_strdup (binaryName); |
245 | if (NULL != (spc = strstr (lpfx, " "))) | 250 | if (NULL != (spc = strstr (lpfx, " "))) |
246 | *spc = '\0'; | 251 | *spc = '\0'; |
@@ -269,7 +274,7 @@ GNUNET_PROGRAM_run2 (int argc, | |||
269 | } | 274 | } |
270 | else | 275 | else |
271 | { | 276 | { |
272 | if (GNUNET_YES == GNUNET_DISK_file_test (cfg_fn)) | 277 | if (NULL != cfg_fn && GNUNET_YES == GNUNET_DISK_file_test (cfg_fn)) |
273 | { | 278 | { |
274 | if (GNUNET_SYSERR == GNUNET_CONFIGURATION_load (cfg, cfg_fn)) | 279 | if (GNUNET_SYSERR == GNUNET_CONFIGURATION_load (cfg, cfg_fn)) |
275 | { | 280 | { |
@@ -284,7 +289,7 @@ GNUNET_PROGRAM_run2 (int argc, | |||
284 | goto cleanup; | 289 | goto cleanup; |
285 | } | 290 | } |
286 | } | 291 | } |
287 | else | 292 | else if (NULL != cfg_fn) |
288 | { | 293 | { |
289 | GNUNET_free (cfg_fn); | 294 | GNUNET_free (cfg_fn); |
290 | cfg_fn = NULL; | 295 | cfg_fn = NULL; |
diff --git a/src/util/service.c b/src/util/service.c index ddd31181d..4c647430d 100644 --- a/src/util/service.c +++ b/src/util/service.c | |||
@@ -2120,7 +2120,9 @@ GNUNET_SERVICE_run_ (int argc, | |||
2120 | { | 2120 | { |
2121 | clock_offset = skew_offset - skew_variance; | 2121 | clock_offset = skew_offset - skew_variance; |
2122 | GNUNET_TIME_set_offset (clock_offset); | 2122 | GNUNET_TIME_set_offset (clock_offset); |
2123 | LOG (GNUNET_ERROR_TYPE_DEBUG, "Skewing clock by %dll ms\n", clock_offset); | 2123 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
2124 | "Skewing clock by %lld ms\n", | ||
2125 | (long long) clock_offset); | ||
2124 | } | 2126 | } |
2125 | GNUNET_RESOLVER_connect (sh.cfg); | 2127 | GNUNET_RESOLVER_connect (sh.cfg); |
2126 | 2128 | ||
diff --git a/src/util/strings.c b/src/util/strings.c index 9d6f4039e..0fb6eaf0c 100644 --- a/src/util/strings.c +++ b/src/util/strings.c | |||
@@ -176,7 +176,7 @@ GNUNET_STRINGS_buffer_tokenize (const char *buffer, | |||
176 | char * | 176 | char * |
177 | GNUNET_STRINGS_byte_size_fancy (unsigned long long size) | 177 | GNUNET_STRINGS_byte_size_fancy (unsigned long long size) |
178 | { | 178 | { |
179 | const char *unit = _ (/* size unit */ "b"); | 179 | const char *unit = /* size unit */ "b"; |
180 | char *ret; | 180 | char *ret; |
181 | 181 | ||
182 | if (size > 5 * 1024) | 182 | if (size > 5 * 1024) |
@@ -703,43 +703,44 @@ GNUNET_STRINGS_relative_time_to_string (struct GNUNET_TIME_Relative delta, | |||
703 | int do_round) | 703 | int do_round) |
704 | { | 704 | { |
705 | static GNUNET_THREAD_LOCAL char buf[128]; | 705 | static GNUNET_THREAD_LOCAL char buf[128]; |
706 | const char *unit = _ (/* time unit */ "µs"); | 706 | const char *unit = /* time unit */ "µs"; |
707 | uint64_t dval = delta.rel_value_us; | 707 | uint64_t dval = delta.rel_value_us; |
708 | 708 | ||
709 | if (GNUNET_TIME_UNIT_FOREVER_REL.rel_value_us == delta.rel_value_us) | 709 | if (GNUNET_TIME_UNIT_FOREVER_REL.rel_value_us == delta.rel_value_us) |
710 | return _ ("forever"); | 710 | return "forever"; |
711 | if (0 == delta.rel_value_us) | 711 | if (0 == delta.rel_value_us) |
712 | return _ ("0 ms"); | 712 | return "0 ms"; |
713 | if (((GNUNET_YES == do_round) && (dval > 5 * 1000)) || (0 == (dval % 1000))) | 713 | if (((GNUNET_YES == do_round) && (dval > 5 * 1000)) || (0 == (dval % 1000))) |
714 | { | 714 | { |
715 | dval = dval / 1000; | 715 | dval = dval / 1000; |
716 | unit = _ (/* time unit */ "ms"); | 716 | unit = /* time unit */ "ms"; |
717 | if (((GNUNET_YES == do_round) && (dval > 5 * 1000)) || (0 == (dval % 1000))) | 717 | if (((GNUNET_YES == do_round) && (dval > 5 * 1000)) || (0 == (dval % 1000))) |
718 | { | 718 | { |
719 | dval = dval / 1000; | 719 | dval = dval / 1000; |
720 | unit = _ (/* time unit */ "s"); | 720 | unit = /* time unit */ "s"; |
721 | if (((GNUNET_YES == do_round) && (dval > 5 * 60)) || (0 == (dval % 60))) | 721 | if (((GNUNET_YES == do_round) && (dval > 5 * 60)) || (0 == (dval % 60))) |
722 | { | 722 | { |
723 | dval = dval / 60; | 723 | dval = dval / 60; |
724 | unit = _ (/* time unit */ "m"); | 724 | unit = /* time unit */ "m"; |
725 | if (((GNUNET_YES == do_round) && (dval > 5 * 60)) || (0 == (dval % 60))) | 725 | if (((GNUNET_YES == do_round) && (dval > 5 * 60)) || (0 == (dval % 60))) |
726 | { | 726 | { |
727 | dval = dval / 60; | 727 | dval = dval / 60; |
728 | unit = _ (/* time unit */ "h"); | 728 | unit = /* time unit */ "h"; |
729 | if (((GNUNET_YES == do_round) && (dval > 5 * 24)) || | 729 | if (((GNUNET_YES == do_round) && (dval > 5 * 24)) || |
730 | (0 == (dval % 24))) | 730 | (0 == (dval % 24))) |
731 | { | 731 | { |
732 | dval = dval / 24; | 732 | dval = dval / 24; |
733 | if (1 == dval) | 733 | if (1 == dval) |
734 | unit = _ (/* time unit */ "day"); | 734 | unit = /* time unit */ "day"; |
735 | else | 735 | else |
736 | unit = _ (/* time unit */ "days"); | 736 | unit = /* time unit */ "days"; |
737 | } | 737 | } |
738 | } | 738 | } |
739 | } | 739 | } |
740 | } | 740 | } |
741 | } | 741 | } |
742 | GNUNET_snprintf (buf, sizeof(buf), "%llu %s", dval, unit); | 742 | GNUNET_snprintf (buf, sizeof(buf), "%llu %s", |
743 | (unsigned long long) dval, unit); | ||
743 | return buf; | 744 | return buf; |
744 | } | 745 | } |
745 | 746 | ||
@@ -761,7 +762,7 @@ GNUNET_STRINGS_absolute_time_to_string (struct GNUNET_TIME_Absolute t) | |||
761 | struct tm *tp; | 762 | struct tm *tp; |
762 | 763 | ||
763 | if (t.abs_value_us == GNUNET_TIME_UNIT_FOREVER_ABS.abs_value_us) | 764 | if (t.abs_value_us == GNUNET_TIME_UNIT_FOREVER_ABS.abs_value_us) |
764 | return _ ("end of time"); | 765 | return "end of time"; |
765 | tt = t.abs_value_us / 1000LL / 1000LL; | 766 | tt = t.abs_value_us / 1000LL / 1000LL; |
766 | tp = localtime (&tt); | 767 | tp = localtime (&tt); |
767 | /* This is hacky, but i don't know a way to detect libc character encoding. | 768 | /* This is hacky, but i don't know a way to detect libc character encoding. |
diff --git a/src/zonemaster/Makefile.am b/src/zonemaster/Makefile.am index 3d248efd8..f2d569c75 100644 --- a/src/zonemaster/Makefile.am +++ b/src/zonemaster/Makefile.am | |||
@@ -24,6 +24,7 @@ gnunet_service_zonemaster_SOURCES = \ | |||
24 | gnunet_service_zonemaster_LDADD = \ | 24 | gnunet_service_zonemaster_LDADD = \ |
25 | $(top_builddir)/src/dht/libgnunetdht.la \ | 25 | $(top_builddir)/src/dht/libgnunetdht.la \ |
26 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 26 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
27 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
27 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 28 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
28 | $(top_builddir)/src/util/libgnunetutil.la \ | 29 | $(top_builddir)/src/util/libgnunetutil.la \ |
29 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 30 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
@@ -32,10 +33,10 @@ gnunet_service_zonemaster_LDADD = \ | |||
32 | 33 | ||
33 | gnunet_service_zonemaster_monitor_SOURCES = \ | 34 | gnunet_service_zonemaster_monitor_SOURCES = \ |
34 | gnunet-service-zonemaster-monitor.c | 35 | gnunet-service-zonemaster-monitor.c |
35 | |||
36 | gnunet_service_zonemaster_monitor_LDADD = \ | 36 | gnunet_service_zonemaster_monitor_LDADD = \ |
37 | $(top_builddir)/src/dht/libgnunetdht.la \ | 37 | $(top_builddir)/src/dht/libgnunetdht.la \ |
38 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 38 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
39 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
39 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ | 40 | $(top_builddir)/src/statistics/libgnunetstatistics.la \ |
40 | $(top_builddir)/src/util/libgnunetutil.la \ | 41 | $(top_builddir)/src/util/libgnunetutil.la \ |
41 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ | 42 | $(top_builddir)/src/namestore/libgnunetnamestore.la \ |
diff --git a/src/zonemaster/gnunet-service-zonemaster-monitor.c b/src/zonemaster/gnunet-service-zonemaster-monitor.c index 4a368048e..c6dd2b6ca 100644 --- a/src/zonemaster/gnunet-service-zonemaster-monitor.c +++ b/src/zonemaster/gnunet-service-zonemaster-monitor.c | |||
@@ -240,7 +240,7 @@ convert_records_for_export (const struct GNUNET_GNSRECORD_Data *rd, | |||
240 | * @return DHT PUT handle, NULL on error | 240 | * @return DHT PUT handle, NULL on error |
241 | */ | 241 | */ |
242 | static struct GNUNET_DHT_PutHandle * | 242 | static struct GNUNET_DHT_PutHandle * |
243 | perform_dht_put (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | 243 | perform_dht_put (const struct GNUNET_IDENTITY_PrivateKey *key, |
244 | const char *label, | 244 | const char *label, |
245 | const struct GNUNET_GNSRECORD_Data *rd_public, | 245 | const struct GNUNET_GNSRECORD_Data *rd_public, |
246 | unsigned int rd_public_count, | 246 | unsigned int rd_public_count, |
@@ -271,9 +271,7 @@ perform_dht_put (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | |||
271 | GNUNET_break (0); | 271 | GNUNET_break (0); |
272 | return NULL; /* whoops */ | 272 | return NULL; /* whoops */ |
273 | } | 273 | } |
274 | block_size = ntohl (block->purpose.size) | 274 | block_size = GNUNET_GNSRECORD_block_get_size (block); |
275 | + sizeof(struct GNUNET_CRYPTO_EcdsaSignature) | ||
276 | + sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey); | ||
277 | GNUNET_GNSRECORD_query_from_private_key (key, | 275 | GNUNET_GNSRECORD_query_from_private_key (key, |
278 | label, | 276 | label, |
279 | &query); | 277 | &query); |
@@ -314,7 +312,7 @@ perform_dht_put (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | |||
314 | */ | 312 | */ |
315 | static void | 313 | static void |
316 | handle_monitor_event (void *cls, | 314 | handle_monitor_event (void *cls, |
317 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *zone, | 315 | const struct GNUNET_IDENTITY_PrivateKey *zone, |
318 | const char *label, | 316 | const char *label, |
319 | unsigned int rd_count, | 317 | unsigned int rd_count, |
320 | const struct GNUNET_GNSRECORD_Data *rd) | 318 | const struct GNUNET_GNSRECORD_Data *rd) |
diff --git a/src/zonemaster/gnunet-service-zonemaster.c b/src/zonemaster/gnunet-service-zonemaster.c index c5aab8d92..11fa9921d 100644 --- a/src/zonemaster/gnunet-service-zonemaster.c +++ b/src/zonemaster/gnunet-service-zonemaster.c | |||
@@ -579,7 +579,7 @@ convert_records_for_export (const struct GNUNET_GNSRECORD_Data *rd, | |||
579 | * @return DHT PUT handle, NULL on error | 579 | * @return DHT PUT handle, NULL on error |
580 | */ | 580 | */ |
581 | static struct GNUNET_DHT_PutHandle * | 581 | static struct GNUNET_DHT_PutHandle * |
582 | perform_dht_put (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | 582 | perform_dht_put (const struct GNUNET_IDENTITY_PrivateKey *key, |
583 | const char *label, | 583 | const char *label, |
584 | const struct GNUNET_GNSRECORD_Data *rd_public, | 584 | const struct GNUNET_GNSRECORD_Data *rd_public, |
585 | unsigned int rd_public_count, | 585 | unsigned int rd_public_count, |
@@ -610,9 +610,7 @@ perform_dht_put (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | |||
610 | GNUNET_break (0); | 610 | GNUNET_break (0); |
611 | return NULL; /* whoops */ | 611 | return NULL; /* whoops */ |
612 | } | 612 | } |
613 | block_size = ntohl (block->purpose.size) | 613 | block_size = GNUNET_GNSRECORD_block_get_size (block); |
614 | + sizeof(struct GNUNET_CRYPTO_EcdsaSignature) | ||
615 | + sizeof(struct GNUNET_CRYPTO_EcdsaPublicKey); | ||
616 | GNUNET_GNSRECORD_query_from_private_key (key, | 614 | GNUNET_GNSRECORD_query_from_private_key (key, |
617 | label, | 615 | label, |
618 | &query); | 616 | &query); |
@@ -725,7 +723,7 @@ zone_iteration_finished (void *cls) | |||
725 | */ | 723 | */ |
726 | static void | 724 | static void |
727 | put_gns_record (void *cls, | 725 | put_gns_record (void *cls, |
728 | const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | 726 | const struct GNUNET_IDENTITY_PrivateKey *key, |
729 | const char *label, | 727 | const char *label, |
730 | unsigned int rd_count, | 728 | unsigned int rd_count, |
731 | const struct GNUNET_GNSRECORD_Data *rd) | 729 | const struct GNUNET_GNSRECORD_Data *rd) |