diff options
author | t3sserakt <t3ss@posteo.de> | 2022-03-17 15:12:06 +0100 |
---|---|---|
committer | t3sserakt <t3ss@posteo.de> | 2022-03-17 15:12:06 +0100 |
commit | 8d41efc36bec5bc5ec29278a365d5a63d7349084 (patch) | |
tree | 99177b1b5400df5ae7180c2af1f47408cace1034 | |
parent | 95a1edacccd9b3bf769a144a12d41946d0ac25dc (diff) | |
parent | ea4a5dd6ca3d62f852b5c2de94071b7fc8f0544c (diff) | |
download | gnunet-8d41efc36bec5bc5ec29278a365d5a63d7349084.tar.gz gnunet-8d41efc36bec5bc5ec29278a365d5a63d7349084.zip |
Merge branch 'master' of ssh://git.gnunet.org/gnunet
173 files changed, 11592 insertions, 6949 deletions
@@ -1,3 +1,183 @@ | |||
1 | Fri, 4 Mar 2022 14:17:37 +0100 (0e6b1f4a2) | ||
2 | NAMESTORE: Warn use of low relative expiration times - Martin Schanzenbach | ||
3 | |||
4 | Thu, 3 Mar 2022 21:34:09 +0100 (0f0ff3785) | ||
5 | NAMESTORE: Do not display label for TOMBSTONE only record sets - Martin Schanzenbach | ||
6 | |||
7 | Thu, 3 Mar 2022 21:31:15 +0100 (64598c8fe) | ||
8 | GNS: Fix publishing of private records - Martin Schanzenbach | ||
9 | |||
10 | Mon, 28 Feb 2022 02:51:04 +0000 (8d9b10826) | ||
11 | Add `contrib/get_version.sh` to `EXTRA_DIST` (for allowing to launch `autoreconf -i` with the released tarball, when necessary) - madmurphy | ||
12 | |||
13 | Sun, 27 Feb 2022 20:54:49 +0100 (fd1d4df8f) | ||
14 | BUILD: Allow boostrap when offline (if gana files exist) - Martin Schanzenbach | ||
15 | |||
16 | Sat, 26 Feb 2022 23:26:33 +0100 (82d9ca012) | ||
17 | BUILD: Detect missing libsodium. Fixes #7153 - Martin Schanzenbach | ||
18 | |||
19 | Fri, 25 Feb 2022 00:46:09 +0100 (5e4cbb92b) | ||
20 | add GNUNET_B2S() macro; fix dht_line_test: we sign over query_hash, not block key - Martin Schanzenbach | ||
21 | |||
22 | Mon, 21 Feb 2022 00:11:28 +0100 (7bc5bb42a) | ||
23 | fix #7173 - Christian Grothoff | ||
24 | |||
25 | Sun, 20 Feb 2022 21:34:39 +0100 (3bda89642) | ||
26 | add salt argument to GNUNET_CRYPTO_CS_r_derive() - Christian Grothoff | ||
27 | |||
28 | Wed, 12 Jan 2022 20:42:34 +0100 (ac77d5f43) | ||
29 | add new HELLO_URI block support to block plugin - Christian Grothoff | ||
30 | |||
31 | Wed, 12 Jan 2022 14:34:56 +0100 (3e3081cfd) | ||
32 | incomplete first hack of new hello-uri lib - Christian Grothoff | ||
33 | |||
34 | Mon, 10 Jan 2022 21:51:53 +0100 (ba9296269) | ||
35 | first steps towards usable dhtu - Christian Grothoff | ||
36 | |||
37 | Fri, 18 Feb 2022 13:02:24 +0100 (a85bfe2fe) | ||
38 | DOC: Fix error - Martin Schanzenbach | ||
39 | |||
40 | Thu, 17 Feb 2022 12:53:23 +0100 (d4dffb077) | ||
41 | DOC: Fixed git links in tutorial - Martin Schanzenbach | ||
42 | |||
43 | Tue, 15 Feb 2022 14:37:56 +0100 (f72ffa1a9) | ||
44 | GNS: Allow lowercase and uppercase - Martin Schanzenbach | ||
45 | |||
46 | Tue, 15 Feb 2022 00:13:04 +0000 (839b4da34) | ||
47 | Fix incorrect information in `contrib/xdg-scheme-handler/README` - madmurphy | ||
48 | |||
49 | Tue, 15 Feb 2022 00:07:16 +0000 (679d390e4) | ||
50 | `gnunet-search`: Reduce the help page and include Alessio's suggestions - madmurphy | ||
51 | |||
52 | Mon, 14 Feb 2022 16:00:15 +0100 (336acc330) | ||
53 | GNS/NAMESTORE: Fix GNS2DNS delegations - Martin Schanzenbach | ||
54 | |||
55 | Mon, 14 Feb 2022 15:15:03 +0100 (6866469e6) | ||
56 | UTIL: Fix DNS resolution - Martin Schanzenbach | ||
57 | |||
58 | Mon, 14 Feb 2022 12:15:54 +0100 (8f7f4944a) | ||
59 | GNS: Rename CNAME test; bugfix - Martin Schanzenbach | ||
60 | |||
61 | Sat, 12 Feb 2022 20:18:16 +0000 (e94d71fdc) | ||
62 | `man gnunet-search`: better layout for `--printf` examples - madmurphy | ||
63 | |||
64 | Sat, 12 Feb 2022 18:14:33 +0000 (8c316d9dc) | ||
65 | `man gnunet-search`: add `--printf` examples, update page date - madmurphy | ||
66 | |||
67 | Fri, 11 Feb 2022 15:20:37 +0000 (c252554c5) | ||
68 | `man gnunet-search`: not just quotes - madmurphy | ||
69 | |||
70 | Fri, 11 Feb 2022 14:59:28 +0000 (b99f65d5e) | ||
71 | `man gnunet-search`: general review (cont'd) - madmurphy | ||
72 | |||
73 | Fri, 11 Feb 2022 03:20:27 +0000 (c4bd3744a) | ||
74 | `man gnunet-search`: general review - madmurphy | ||
75 | |||
76 | Fri, 11 Feb 2022 02:52:46 +0000 (0e04edc6b) | ||
77 | `man gnunet-search`: note about libextractor - madmurphy | ||
78 | |||
79 | Fri, 11 Feb 2022 02:45:23 +0000 (d267f384a) | ||
80 | `man gnunet-search`: metatype string - madmurphy | ||
81 | |||
82 | Fri, 11 Feb 2022 01:49:29 +0000 (55307d34d) | ||
83 | `man gnunet-search`: update synopsis - madmurphy | ||
84 | |||
85 | Fri, 11 Feb 2022 01:32:58 +0000 (3ce3d040f) | ||
86 | First draft of updated man page for `gnunet-search` (to be reviewed) - madmurphy | ||
87 | |||
88 | Thu, 10 Feb 2022 22:45:00 +0000 (9294003d1) | ||
89 | Add missing information to `gnunet-search`'s help page - madmurphy | ||
90 | |||
91 | Thu, 10 Feb 2022 22:24:56 +0000 (4b887d8a8) | ||
92 | New version of `gnunet-search` is ready to be tested - madmurphy | ||
93 | |||
94 | Thu, 10 Feb 2022 22:20:32 +0000 (82e288bca) | ||
95 | Use `const` for `GNUNET_FS_file_information_get_filename()`'s only argument - madmurphy | ||
96 | |||
97 | Thu, 10 Feb 2022 22:12:48 +0000 (99dcb607e) | ||
98 | Add newline before help pages' footer - madmurphy | ||
99 | |||
100 | Mon, 7 Feb 2022 15:59:04 +0100 (14b3c75ab) | ||
101 | GNS: LSD0001 improvements - Martin Schanzenbach | ||
102 | |||
103 | Sat, 5 Feb 2022 17:17:37 +0100 (aa85ac347) | ||
104 | GNS: Add tombstone string processing; also handle tombstones in monitor properly - Martin Schanzenbach | ||
105 | |||
106 | Sat, 5 Feb 2022 00:50:38 +0100 (ee865f851) | ||
107 | GNS: Implement Tombstone logic - Martin Schanzenbach | ||
108 | |||
109 | Thu, 3 Feb 2022 22:47:03 +0100 (f3eaf5dae) | ||
110 | GNS: Move VPN to DNS2GNS. Fixes #7171 - Martin Schanzenbach | ||
111 | |||
112 | Thu, 3 Feb 2022 18:44:40 +0100 (afd2cb5db) | ||
113 | GNS: Introduce REDIRECT records. Fixes #7172 - Martin Schanzenbach | ||
114 | |||
115 | Thu, 3 Feb 2022 18:12:10 +0100 (3d72be074) | ||
116 | GNS: Introduce CRITICAL flag. Fixes #7169 - Martin Schanzenbach | ||
117 | |||
118 | Thu, 3 Feb 2022 09:25:12 +0100 (112ef3796) | ||
119 | GNS: Rework GNS block wire format - Martin Schanzenbach | ||
120 | |||
121 | Tue, 1 Feb 2022 17:52:33 +0100 (4f07822ff) | ||
122 | GNS: Fix context strings in key derivation according to LSD0001 - Martin Schanzenbach | ||
123 | |||
124 | Tue, 1 Feb 2022 15:48:52 +0100 (816bab695) | ||
125 | GNS: Fix revocation wire format - Martin Schanzenbach | ||
126 | |||
127 | Wed, 26 Jan 2022 22:41:40 +0100 (e96a8d741) | ||
128 | added CS test vectors - Gian Demarmels | ||
129 | |||
130 | Thu, 20 Jan 2022 15:21:53 +0100 (856078f62) | ||
131 | DOC: Update README and handbook for dependencies - Martin Schanzenbach | ||
132 | |||
133 | Tue, 18 Jan 2022 14:05:12 +0100 (18bf1b905) | ||
134 | UTIL: Add UTF-8 NFC test - Martin Schanzenbach | ||
135 | |||
136 | Tue, 18 Jan 2022 11:05:41 +0100 (54554ca53) | ||
137 | GNS: Towards NFC - Martin Schanzenbach | ||
138 | |||
139 | Fri, 14 Jan 2022 18:42:27 +0100 (7e43ac554) | ||
140 | RECLAIM: Add DIDs - trizuz - Martin Schanzenbach | ||
141 | |||
142 | Mon, 10 Jan 2022 10:31:59 +0100 (8f8351c2d) | ||
143 | add more information to ensure signatures are fresh and request-specific - Christian Grothoff | ||
144 | |||
145 | Sun, 9 Jan 2022 12:22:04 +0100 (ec19c1e31) | ||
146 | DHT: modify API and protocol messages to add path signatures, except for now the actual signatures are just placeholders (signing and signature verification are missing) - Christian Grothoff | ||
147 | |||
148 | Tue, 4 Jan 2022 22:18:34 +0100 (d228a5859) | ||
149 | BUILD: Make GANA generation mandatory for beetstrap. Requires recutils - Martin Schanzenbach | ||
150 | |||
151 | Tue, 4 Jan 2022 15:53:29 +0100 (a5ca7d597) | ||
152 | BUILD: gnunet-signatures from gana - Martin Schanzenbach | ||
153 | |||
154 | Tue, 4 Jan 2022 15:37:21 +0100 (7b6e0eb4f) | ||
155 | BUILD: Add gana gnunet-signatures; do not yet copy - Martin Schanzenbach | ||
156 | |||
157 | Tue, 4 Jan 2022 15:23:22 +0100 (c5f6aafd6) | ||
158 | BUILD: Add gana GNS TLDs - Martin Schanzenbach | ||
159 | |||
160 | Tue, 4 Jan 2022 13:47:07 +0100 (8fc699d2a) | ||
161 | BUILD: Add gana build target for easy updates of generated headers - Martin Schanzenbach | ||
162 | |||
163 | Sun, 2 Jan 2022 14:53:35 +0100 (329f0458f) | ||
164 | clean up am_closest_peer and other functions - Christian Grothoff | ||
165 | |||
166 | Sun, 2 Jan 2022 13:10:25 +0100 (bb686c483) | ||
167 | revise DHT hashing functions, add test logic - Christian Grothoff | ||
168 | |||
169 | Wed, 29 Dec 2021 19:12:28 +0100 (daa928456) | ||
170 | implement revised block API - Christian Grothoff | ||
171 | |||
172 | Wed, 29 Dec 2021 00:11:40 +0100 (68b028c18) | ||
173 | implement new block API for FS, fix FTBFS - Christian Grothoff | ||
174 | |||
175 | Tue, 28 Dec 2021 23:39:36 +0100 (8d8976f00) | ||
176 | revise block plugin design as per discussion with Martin today (only implemented for GNS) - Christian Grothoff | ||
177 | |||
178 | Thu, 16 Dec 2021 18:13:21 +0100 (88fb1d89e) | ||
179 | IDENTITY: Expose encryption based on identities on CLI - Martin Schanzenbach | ||
180 | |||
1 | Tue, 21 Dec 2021 15:27:27 +0100 (ff714cca7) | 181 | Tue, 21 Dec 2021 15:27:27 +0100 (ff714cca7) |
2 | changed derive_secrets API - Gian Demarmels | 182 | changed derive_secrets API - Gian Demarmels |
3 | 183 | ||
@@ -97,9 +97,9 @@ submodules() | |||
97 | if ! git --version >/dev/null; then | 97 | if ! git --version >/dev/null; then |
98 | echo "git not installed, skipping submodule update" | 98 | echo "git not installed, skipping submodule update" |
99 | else | 99 | else |
100 | git submodule update --init || exit 1 | 100 | git submodule update --init && \ |
101 | git submodule update --remote --recursive || exit 1 | 101 | git submodule update --remote --recursive && \ |
102 | git submodule sync || exit 1 | 102 | git submodule sync |
103 | fi | 103 | fi |
104 | } | 104 | } |
105 | 105 | ||
@@ -112,17 +112,17 @@ gana_update() | |||
112 | cd gnu-name-system-record-types && \ | 112 | cd gnu-name-system-record-types && \ |
113 | make && \ | 113 | make && \ |
114 | cp gnu_name_system_record_types.h ../../../src/include/ && \ | 114 | cp gnu_name_system_record_types.h ../../../src/include/ && \ |
115 | make clean | 115 | make clean || exit 1 |
116 | cd ../gnu-name-system-default-tlds && \ | 116 | cd ../gnu-name-system-default-tlds && \ |
117 | make && \ | 117 | make && \ |
118 | cp tlds.conf ../../../src/gns && \ | 118 | cp tlds.conf ../../../src/gns && \ |
119 | make clean | 119 | make clean || exit 1 |
120 | 120 | ||
121 | # Signatures | 121 | # Signatures |
122 | cd ../gnunet-signatures && \ | 122 | cd ../gnunet-signatures && \ |
123 | make && \ | 123 | make && \ |
124 | cp gnunet_signatures.h ../../../src/include && \ | 124 | cp gnunet_signatures.h ../../../src/include && \ |
125 | make clean | 125 | make clean || exit 1 |
126 | cd $cwd | 126 | cd $cwd |
127 | else | 127 | else |
128 | echo "ERROR: No recutils found! Unable to generate recent GANA headers and configs." | 128 | echo "ERROR: No recutils found! Unable to generate recent GANA headers and configs." |
diff --git a/configure.ac b/configure.ac index 3ccfc9c1b..713817168 100644 --- a/configure.ac +++ b/configure.ac | |||
@@ -816,6 +816,7 @@ AC_CHECK_LIB([kvm], [kvm_open]) | |||
816 | AC_CHECK_LIB([kstat], [kstat_open]) | 816 | AC_CHECK_LIB([kstat], [kstat_open]) |
817 | 817 | ||
818 | # check for libsodium version >= 1.0.18 | 818 | # check for libsodium version >= 1.0.18 |
819 | libsodium=0 | ||
819 | AC_CHECK_HEADER([sodium.h], | 820 | AC_CHECK_HEADER([sodium.h], |
820 | [AC_CHECK_LIB([sodium], [crypto_core_ed25519_scalar_mul], | 821 | [AC_CHECK_LIB([sodium], [crypto_core_ed25519_scalar_mul], |
821 | [libsodium=1], | 822 | [libsodium=1], |
diff --git a/contrib/Makefile.am b/contrib/Makefile.am index 4e7928c7e..e05e9caf9 100644 --- a/contrib/Makefile.am +++ b/contrib/Makefile.am | |||
@@ -206,6 +206,7 @@ EXTRA_DIST = \ | |||
206 | docker/README.md \ | 206 | docker/README.md \ |
207 | docker/gnunet.conf \ | 207 | docker/gnunet.conf \ |
208 | benchmark/collect.awk \ | 208 | benchmark/collect.awk \ |
209 | get_version.sh \ | ||
209 | gnunet_infrastructure/handbook_pull.sh \ | 210 | gnunet_infrastructure/handbook_pull.sh \ |
210 | guix.scm \ | 211 | guix.scm \ |
211 | indent_pre-commit \ | 212 | indent_pre-commit \ |
diff --git a/contrib/conf/uncrustify.cfg b/contrib/conf/uncrustify.cfg index 6ced05d7a..b02ebc4a5 100644 --- a/contrib/conf/uncrustify.cfg +++ b/contrib/conf/uncrustify.cfg | |||
@@ -28,7 +28,7 @@ ls_code_width=true | |||
28 | pos_arith=lead | 28 | pos_arith=lead |
29 | 29 | ||
30 | # Fully parenthesize boolean exprs | 30 | # Fully parenthesize boolean exprs |
31 | mod_full_paren_if_bool=true | 31 | mod_full_paren_if_bool=false |
32 | 32 | ||
33 | # Braces should be on their own line | 33 | # Braces should be on their own line |
34 | nl_fdef_brace=add | 34 | nl_fdef_brace=add |
diff --git a/contrib/gana b/contrib/gana | |||
Subproject 3a71278a2aab67f9a1888af172b507d6e08364c | Subproject 048ad729b3177a5de1726517bc905e6cd7688d0 | ||
diff --git a/contrib/xdg-scheme-handler/README.md b/contrib/xdg-scheme-handler/README.md index 919ae37f8..07ff87bdc 100644 --- a/contrib/xdg-scheme-handler/README.md +++ b/contrib/xdg-scheme-handler/README.md | |||
@@ -5,4 +5,4 @@ To register the `gnunet://` URI scheme, launch the following commands from this | |||
5 | directory as a privileged user: | 5 | directory as a privileged user: |
6 | 6 | ||
7 | install -Dm644 gnunet-uri.desktop /usr/share/applications/gnunet-uri.desktop | 7 | install -Dm644 gnunet-uri.desktop /usr/share/applications/gnunet-uri.desktop |
8 | update-mime-database /usr/share/applications/ | 8 | update-mime-database /usr/share/mime |
diff --git a/doc/handbook/chapters/developer.texi b/doc/handbook/chapters/developer.texi index e3ff20dcd..5f91a646e 100644 --- a/doc/handbook/chapters/developer.texi +++ b/doc/handbook/chapters/developer.texi | |||
@@ -6250,7 +6250,7 @@ by NAMESTORE. | |||
6250 | Here a client uses the @code{GNUNET_NAMESTORE_zone_iteration_start} | 6250 | Here a client uses the @code{GNUNET_NAMESTORE_zone_iteration_start} |
6251 | function and passes the namestore handle, the zone to iterate over and a | 6251 | function and passes the namestore handle, the zone to iterate over and a |
6252 | callback function to call with the result. | 6252 | callback function to call with the result. |
6253 | If the client wants to iterate over all the WHAT!? FIXME, it passes NULL for the zone. | 6253 | To iterate over all the zones, it is possible to pass NULL for the zone. |
6254 | A @code{GNUNET_NAMESTORE_ZoneIterator} handle is returned to be used to | 6254 | A @code{GNUNET_NAMESTORE_ZoneIterator} handle is returned to be used to |
6255 | continue iteration. | 6255 | continue iteration. |
6256 | 6256 | ||
diff --git a/doc/handbook/chapters/philosophy.texi b/doc/handbook/chapters/philosophy.texi index 785a65e42..180589829 100644 --- a/doc/handbook/chapters/philosophy.texi +++ b/doc/handbook/chapters/philosophy.texi | |||
@@ -7,11 +7,12 @@ | |||
7 | @c of GNUnet. | 7 | @c of GNUnet. |
8 | The primary goal of the GNUnet project is to provide a reliable, open, | 8 | The primary goal of the GNUnet project is to provide a reliable, open, |
9 | non-discriminating and censorship-resistant system for information | 9 | non-discriminating and censorship-resistant system for information |
10 | exchange. We value free speech above state interests and intellectual | 10 | exchange. |
11 | We value free speech above state interests and intellectual | ||
11 | monopoly. GNUnet's long-term goal is to serve as a development | 12 | monopoly. GNUnet's long-term goal is to serve as a development |
12 | platform for the next generation of Internet protocols. | 13 | platform for the next generation of Internet protocols. |
13 | 14 | ||
14 | GNUnet is an anarchistic network. Participants are encouraged to | 15 | Participants are encouraged to |
15 | contribute at least as much resources (storage, bandwidth) to the network | 16 | contribute at least as much resources (storage, bandwidth) to the network |
16 | as they consume, so that their participation does not have a negative | 17 | as they consume, so that their participation does not have a negative |
17 | impact on other users. | 18 | impact on other users. |
diff --git a/doc/handbook/chapters/user.texi b/doc/handbook/chapters/user.texi index aa912f96f..0b44ab57c 100644 --- a/doc/handbook/chapters/user.texi +++ b/doc/handbook/chapters/user.texi | |||
@@ -1561,6 +1561,9 @@ The GNS currently supports the record types as defined in | |||
1561 | @uref{https://git.gnunet.org/gana.git/tree/gnu-name-system-record-types/registry.rec, GANA}. | 1561 | @uref{https://git.gnunet.org/gana.git/tree/gnu-name-system-record-types/registry.rec, GANA}. |
1562 | In addition, GNS supports DNS record types, such as A, AAAA or TXT. | 1562 | In addition, GNS supports DNS record types, such as A, AAAA or TXT. |
1563 | 1563 | ||
1564 | For a complete description of the records, please refer to the specification | ||
1565 | at @uref{https://lsd.gnunet.org/lsd0001, LSD0001}. | ||
1566 | |||
1564 | In the following, we discuss GNS records with specific behaviour or special | 1567 | In the following, we discuss GNS records with specific behaviour or special |
1565 | handling of DNS records. | 1568 | handling of DNS records. |
1566 | 1569 | ||
@@ -1570,8 +1573,9 @@ handling of DNS records. | |||
1570 | * BOX:: | 1573 | * BOX:: |
1571 | * LEHO:: | 1574 | * LEHO:: |
1572 | * VPN:: | 1575 | * VPN:: |
1573 | * CNAME:: | 1576 | * REDIRECT:: |
1574 | * GNS2DNS:: | 1577 | * GNS2DNS:: |
1578 | * TOMBSTONE:: | ||
1575 | * SOA SRV PTR and MX:: | 1579 | * SOA SRV PTR and MX:: |
1576 | @end menu | 1580 | @end menu |
1577 | 1581 | ||
@@ -1668,11 +1672,11 @@ having the following lines in the @file{gnunet.conf} configuration file: | |||
1668 | TCP_REDIRECTS = 80:localhost4:8080 | 1672 | TCP_REDIRECTS = 80:localhost4:8080 |
1669 | @end example | 1673 | @end example |
1670 | 1674 | ||
1671 | @node CNAME | 1675 | @node REDIRECT |
1672 | @subsubsection CNAME | 1676 | @subsubsection REDIRECT |
1673 | 1677 | ||
1674 | As specified in RFC 1035 whenever a CNAME is encountered the query | 1678 | As specified in LSD0001 whenever a REDIRECT is encountered the query |
1675 | needs to be restarted with the specified name. In GNS a CNAME | 1679 | needs to be restarted with the specified name. A REDIRECT |
1676 | can either be: | 1680 | can either be: |
1677 | 1681 | ||
1678 | @itemize @bullet | 1682 | @itemize @bullet |
@@ -1721,6 +1725,21 @@ However, imagine the nameserver was "ns.gnunet.org". In this case, | |||
1721 | delegating to "ns.gnunet.org" would mean that despite using GNS, | 1725 | delegating to "ns.gnunet.org" would mean that despite using GNS, |
1722 | censorship in the DNS ".org" zone would still be effective. | 1726 | censorship in the DNS ".org" zone would still be effective. |
1723 | 1727 | ||
1728 | @node TOMBSTONE | ||
1729 | @subsubsection TOMBSTONE | ||
1730 | |||
1731 | The GNUnet GNS implementation uses the TOMBSTONE record to ensure | ||
1732 | ciphertext indistinguishability for published records. | ||
1733 | It must be ensured that when relative expiration times are decreased, the | ||
1734 | expiration time of the next record block MUST be after the last published block. | ||
1735 | A similar issue arises if the record set under a label is deleted and reused | ||
1736 | later. | ||
1737 | |||
1738 | The creation and maintenance of the TOMBSTONE record is done automatically. | ||
1739 | You do not need to mind it yourself and can safely ignore any TOMBSTONE | ||
1740 | blocks you may see when investigating your zone(s). | ||
1741 | TOMBSTONE records are always private and will never be published. | ||
1742 | |||
1724 | @node SOA SRV PTR and MX | 1743 | @node SOA SRV PTR and MX |
1725 | @subsubsection SOA SRV PTR and MX | 1744 | @subsubsection SOA SRV PTR and MX |
1726 | 1745 | ||
diff --git a/doc/man/gnunet-search.1 b/doc/man/gnunet-search.1 index 4ec5189de..a3c6e8ece 100644 --- a/doc/man/gnunet-search.1 +++ b/doc/man/gnunet-search.1 | |||
@@ -21,7 +21,7 @@ | |||
21 | .\" | 21 | .\" |
22 | .\" SPDX-License-Identifier: GPL3.0-or-later OR FDL1.3-or-later | 22 | .\" SPDX-License-Identifier: GPL3.0-or-later OR FDL1.3-or-later |
23 | .\" | 23 | .\" |
24 | .Dd February 25, 2012 | 24 | .Dd February 12, 2022 |
25 | .Dt GNUNET-SEARCH 1 | 25 | .Dt GNUNET-SEARCH 1 |
26 | .Os | 26 | .Os |
27 | .Sh NAME | 27 | .Sh NAME |
@@ -30,13 +30,18 @@ | |||
30 | .Sh SYNOPSIS | 30 | .Sh SYNOPSIS |
31 | .Nm | 31 | .Nm |
32 | .Op Fl a Ar LEVEL | Fl -anonymity= Ns Ar LEVEL | 32 | .Op Fl a Ar LEVEL | Fl -anonymity= Ns Ar LEVEL |
33 | .Op Fl b | -bookmark-only | ||
33 | .Op Fl c Ar FILENAME | Fl -config= Ns Ar FILENAME | 34 | .Op Fl c Ar FILENAME | Fl -config= Ns Ar FILENAME |
35 | .Op Fl F Ar FORMAT | Fl -dir-printf= Ns Ar FORMAT | ||
36 | .Op Fl f Ar FORMAT | Fl -printf= Ns Ar FORMAT | ||
34 | .Op Fl h | -help | 37 | .Op Fl h | -help |
38 | .Op Fl i Ar FORMAT | Fl -iter-printf= Ns Ar FORMAT | ||
35 | .Op Fl L Ar LOGLEVEL | Fl -loglevel= Ns Ar LOGLEVEL | 39 | .Op Fl L Ar LOGLEVEL | Fl -loglevel= Ns Ar LOGLEVEL |
36 | .Op Fl l Ar FILENAME | Fl -logfile= Ns Ar FILENAME | 40 | .Op Fl l Ar FILENAME | Fl -logfile= Ns Ar FILENAME |
37 | .Op Fl o Ar FILENAME | Fl -output= Ns Ar FILENAME | 41 | .Op Fl o Ar FILENAME | Fl -output= Ns Ar FILENAME |
38 | .Op Fl n | -no-network | 42 | .Op Fl n | -no-network |
39 | .Op Fl N Ar VALUE | Fl -results= Ns Ar VALUE | 43 | .Op Fl N Ar VALUE | Fl -results= Ns Ar VALUE |
44 | .Op Fl s | -silent | ||
40 | .Op Fl t Ar DELAY | Fl -timeout= Ns Ar DELAY | 45 | .Op Fl t Ar DELAY | Fl -timeout= Ns Ar DELAY |
41 | .Op Fl v | -version | 46 | .Op Fl v | -version |
42 | .Op Fl V | -verbose | 47 | .Op Fl V | -verbose |
@@ -63,40 +68,207 @@ The specific numeric value (for anonymity levels above 1) is simple: | |||
63 | Given an anonymity level L (above 1), each request FS makes on your behalf must be hidden in L-1 equivalent requests of cover traffic (traffic your peer routes for others) in the same time-period. | 68 | Given an anonymity level L (above 1), each request FS makes on your behalf must be hidden in L-1 equivalent requests of cover traffic (traffic your peer routes for others) in the same time-period. |
64 | The time-period is twice the average delay by which GNUnet artificially delays traffic. | 69 | The time-period is twice the average delay by which GNUnet artificially delays traffic. |
65 | Note that regardless of the anonymity level you choose, peers that cache content in the network always use anonymity level 1. | 70 | Note that regardless of the anonymity level you choose, peers that cache content in the network always use anonymity level 1. |
71 | .It Fl b | -bookmark-only | ||
72 | Do not search, print only the URI that points to the search with the given keywords. | ||
66 | .It Fl c Ar FILENAME | Fl -config= Ns Ar FILENAME | 73 | .It Fl c Ar FILENAME | Fl -config= Ns Ar FILENAME |
67 | Use the configuration file | 74 | Use the configuration file |
68 | .Ar FILENAME | 75 | .Ar FILENAME |
69 | (default: | 76 | (default: |
70 | .Pa ~/.config/gnunet.conf ) | 77 | .Pa ~/.config/gnunet.conf Ns |
78 | ). | ||
79 | .It Fl F Ar FORMAT | Fl -dir-printf= Ns Ar FORMAT | ||
80 | Write the search results for directories according to | ||
81 | .Ar FORMAT Ns | ||
82 | \&. The directives supported here are identical to those supported in the | ||
83 | .Fl -printf | ||
84 | argument (please refer to it for more information). If missing, | ||
85 | .Fl -dir-printf | ||
86 | defaults to | ||
87 | .Fl -printf Ns | ||
88 | \&. If | ||
89 | .Fl -printf | ||
90 | is missing too | ||
91 | .Fl -dir-printf | ||
92 | defaults to | ||
93 | .Ql #%n:\engnunet-download -o "%f" -R %u\en\en Ns | ||
94 | \&. | ||
95 | .It Fl f Ar FORMAT | Fl -printf= Ns Ar FORMAT | ||
96 | Write the search results according to | ||
97 | .Ar FORMAT Ns | ||
98 | , in which | ||
99 | .Ql \e | ||
100 | and | ||
101 | .Ql % | ||
102 | directives are interpreted as follows: | ||
103 | .Bl -tag -width indent | ||
104 | .It Li \e\e | ||
105 | a literal backslash | ||
106 | .No ( Ql \e Ns ) | ||
107 | .It Li \ea | ||
108 | an alarm bell | ||
109 | .It Li \eb | ||
110 | a backspace | ||
111 | .It Li \ee | ||
112 | an escape | ||
113 | .It Li \ef | ||
114 | a form feed | ||
115 | .It Li \en | ||
116 | a newline | ||
117 | .It Li \er | ||
118 | a carriage return | ||
119 | .It Li \et | ||
120 | a horizontal tab | ||
121 | .It Li \ev | ||
122 | a vertical tab | ||
123 | .It Li \e0 | ||
124 | an ASCII NUL. | ||
125 | .It Li \eN... | ||
126 | the character whose ASCII code is N..., expressed in octal digits | ||
127 | .It Li \exX... | ||
128 | the character whose ASCII code is X..., expressed in hexadecimal digits | ||
129 | .Pp | ||
130 | .El | ||
131 | .Sy Note: | ||
132 | The | ||
133 | .Ql \e | ||
134 | character followed by any other character not listed above is treated as an ordinary character, so both characters are printed. | ||
135 | .Bl -tag -width indent | ||
136 | .It Li %% | ||
137 | a percent sign | ||
138 | .It Li %a | ||
139 | the complete list of all the printable metadata properties available, displayed according to the | ||
140 | .Fl -iter-printf | ||
141 | argument; this specifier optionally supports metatype filtering via hash sign | ||
142 | .No (e.g. | ||
143 | .Ql %2#a | ||
144 | prints all embedded file names, if present - see libextractor's metatypes for the complete list of numerical identifiers) | ||
145 | .It Li %f | ||
146 | the file's name | ||
147 | .It Li %j | ||
148 | the first printable metadata property available, displayed according to the | ||
149 | .Fl -iter-printf | ||
150 | argument; this specifier optionally supports metatype filtering via hash sign | ||
151 | .No (e.g. | ||
152 | .Ql %5#j | ||
153 | prints a book title, if present); see libextractor's metatypes for the complete list of numerical identifiers) | ||
154 | .It Li %l | ||
155 | the file name's length | ||
156 | .It Li %m | ||
157 | the file's mime type | ||
158 | .It Li %n | ||
159 | the search result number | ||
160 | .It Li %s | ||
161 | the file's size in bytes | ||
162 | .It Li %u | ||
163 | the file's URI | ||
164 | .El | ||
165 | .Pp | ||
166 | .Sy Note: | ||
167 | The | ||
168 | .Ql % | ||
169 | character followed by any other character not listed above is treated as an ordinary character, so both characters are printed. | ||
170 | .Pp | ||
171 | If missing, | ||
172 | .Fl -printf | ||
173 | defaults to | ||
174 | .Ql #%n:\engnunet-download -o "%f" %u\en\en Ns | ||
175 | \&. | ||
71 | .It Fl h | -help | 176 | .It Fl h | -help |
72 | Print the help page. | 177 | Print the help page. |
178 | .It Fl i Ar FORMAT | Fl -iter-printf= Ns Ar FORMAT | ||
179 | When the | ||
180 | .Ql %a | ||
181 | or | ||
182 | .Ql %j | ||
183 | format specifiers appear in | ||
184 | .Fl -printf | ||
185 | or | ||
186 | .Fl -dir-printf Ns | ||
187 | , list each metadata property according to | ||
188 | .Ar FORMAT Ns | ||
189 | , in which the | ||
190 | .Ql \e | ||
191 | directives are interpreted as in | ||
192 | .Fl -printf | ||
193 | and | ||
194 | .Fl -dir-printf Ns | ||
195 | , while the | ||
196 | .Ql % | ||
197 | directives are interpreted as follows: | ||
198 | .Bl -tag -width indent | ||
199 | .It Li %% | ||
200 | a percent sign | ||
201 | .It Li %p | ||
202 | the property's content | ||
203 | .It Li %l | ||
204 | the property content's length in bytes | ||
205 | .It Li %i | ||
206 | the property type's unique identifier | ||
207 | .It Li %n | ||
208 | the property number | ||
209 | .It Li %t | ||
210 | the property type (available only if compiled with libextractor) | ||
211 | .It Li %w | ||
212 | the name of the plugin that provided the information | ||
213 | .El | ||
214 | .Pp | ||
215 | .Sy Note: | ||
216 | The | ||
217 | .Ql % | ||
218 | character followed by any other character not listed above is treated as an ordinary character, so both characters are printed. | ||
219 | .Pp | ||
220 | If missing, | ||
221 | .Fl -iter-printf | ||
222 | defaults to | ||
223 | .Ql \& \& %t: %p\en | ||
224 | or | ||
225 | .Ql \& \& MetaType #%i: %p\en Ns | ||
226 | , depending on whether the program was compiled with libextractor or not. | ||
73 | .It Fl L Ar LOGLEVEL | Fl -loglevel= Ns Ar LOGLEVEL | 227 | .It Fl L Ar LOGLEVEL | Fl -loglevel= Ns Ar LOGLEVEL |
74 | Change the loglevel. | 228 | Change the loglevel. |
75 | Possible values for LOGLEVEL are ERROR, WARNING, INFO and DEBUG. | 229 | Possible values for |
230 | .Ar LOGLEVEL | ||
231 | are ERROR, WARNING, INFO and DEBUG. | ||
76 | .It Fl l Ar FILENAME | Fl -logfile= Ns Ar FILENAME | 232 | .It Fl l Ar FILENAME | Fl -logfile= Ns Ar FILENAME |
77 | Write logs to | 233 | Write logs to |
78 | .Ar FILENAME . | 234 | .Ar FILENAME . |
79 | .It Fl o Ar FILENAME | Fl -output= Ns Ar FILENAME | 235 | .It Fl o Ar FILENAME | Fl -output= Ns Ar FILENAME |
80 | Writes a GNUnet directory containing all of the search results to | 236 | Writes a GNUnet directory containing all of the search results to |
81 | .Ar FILENAME . | 237 | .Ar FILENAME |
238 | .No (e.g. | ||
239 | .Ql gnunet-search --output=commons.gnd commons Ns | ||
240 | ). | ||
82 | .It Fl n | -no-network | 241 | .It Fl n | -no-network |
83 | Only search locally, do not forward requests to other peers. | 242 | Only search locally, do not forward requests to other peers. |
84 | .It Fl N Ar VALUE | Fl -results= Ns Ar VALUE | 243 | .It Fl N Ar VALUE | Fl -results= Ns Ar VALUE |
85 | Automatically terminate the search after receiving | 244 | Automatically terminate the search after receiving |
86 | .Ar VALUE | 245 | .Ar VALUE |
87 | results. | 246 | results. |
247 | .It Fl s | -silent | ||
248 | Enable silent mode and do not print any result (the | ||
249 | .Fl -output | ||
250 | argument is required). | ||
88 | .It Fl t Ar DELAY | Fl -timeout= Ns Ar DELAY | 251 | .It Fl t Ar DELAY | Fl -timeout= Ns Ar DELAY |
89 | Automatically timeout search after | 252 | Automatically timeout search after |
90 | .Ar DELAY . | 253 | .Ar DELAY . |
91 | The value given must be a number followed by a space and a time unit, for example "500 ms". | 254 | The value given must be a number followed by a space and a time unit, for example "500 ms". |
92 | Note that the quotes are required on the shell. | 255 | Note that the quotes are required on the shell. Without a unit it defaults to microseconds (1000000 = 1 second). |
93 | Otherwise the search runs until gnunet-search is aborted with CTRL-C. | 256 | If 0 or omitted the search runs until gnunet-search is aborted with CTRL-C. |
94 | .It Fl v | -version | 257 | .It Fl v | -version |
95 | print the version number | 258 | print the version number |
96 | .It Fl V | -verbose | 259 | .It Fl V | -verbose |
97 | print meta data from search results as well | 260 | append |
261 | .Ql %a\en | ||
262 | to the default | ||
263 | .Fl -printf | ||
264 | and | ||
265 | .Fl -dir-printf | ||
266 | arguments \[u2013] ignored when these are provided by the user | ||
98 | .El | 267 | .El |
99 | You can run gnunet-search with an URI instead of a keyword. | 268 | .Pp |
269 | It is possible to run | ||
270 | .Nm gnunet-search | ||
271 | with an URI instead of a keyword. | ||
100 | The URI can have the format for a namespace search or for a keyword search. | 272 | The URI can have the format for a namespace search or for a keyword search. |
101 | For a namespace search, the format is | 273 | For a namespace search, the format is |
102 | .Pp | 274 | .Pp |
@@ -108,46 +280,137 @@ For a keyword search, use | |||
108 | .Pp | 280 | .Pp |
109 | If the format does not correspond to a GNUnet URI, GNUnet will automatically assume that keywords are supplied directly. | 281 | If the format does not correspond to a GNUnet URI, GNUnet will automatically assume that keywords are supplied directly. |
110 | .sp | 282 | .sp |
111 | If multiple keywords are passed, gnunet-search will look for content matching any of the keywords. | 283 | If multiple keywords are passed, |
112 | The prefix "+" makes a keyword mandatory. | 284 | .Nm gnunet-search |
285 | will look for content matching any of the keywords. | ||
286 | The | ||
287 | .Ql + | ||
288 | prefix makes a keyword mandatory. | ||
113 | .Sh FILES | 289 | .Sh FILES |
114 | .Pa ~/.config/gnunet.conf | 290 | .Pa ~/.config/gnunet.conf |
115 | GNUnet configuration file; specifies the default value for the timeout | 291 | GNUnet configuration file; specifies the default value for the timeout |
116 | .Sh EXAMPLES | 292 | .Sh EXAMPLES |
117 | .Dl $ gnunet-search "Das Kapital" | 293 | Example 1: |
294 | .Pp | ||
295 | .Dl $ gnunet-search 'Das Kapital' | ||
118 | .Pp | 296 | .Pp |
119 | Searches for content matching the keyword "Das Kapital". | 297 | searches for content matching the keyword |
298 | .Dq Das Kapital Ns | ||
299 | . | ||
300 | .Pp | ||
301 | Example 2: | ||
302 | .Pp | ||
303 | .Dl $ gnunet-search Das Kapital | ||
304 | .Pp | ||
305 | searches for content matching either keyword | ||
306 | .Dq Das | ||
307 | or keyword | ||
308 | .Dq Kapital Ns | ||
309 | . | ||
310 | .Pp | ||
311 | Example 3: | ||
120 | .Pp | 312 | .Pp |
121 | .Dl $ gnunet-search +Das +Kapital | 313 | .Dl $ gnunet-search +Das +Kapital |
122 | .Pp | 314 | .Pp |
123 | Searches for content matching both mandatory keywords "Das" and "Kapital". | 315 | searches for content matching both mandatory keywords |
316 | .Dq Das | ||
317 | and | ||
318 | .Dq Kapital Ns | ||
319 | . | ||
124 | .sp | 320 | .sp |
125 | Search results are printed by gnunet-search like this: | 321 | Search results are printed by |
322 | .Nm gnunet-search | ||
323 | like this: | ||
126 | .Pp | 324 | .Pp |
127 | .ad l | 325 | .ad l |
128 | gnunet-download -o "COPYING" gnunet://fs/chk/HASH1.HASH2.SIZE | 326 | gnunet-download -o "COPYING" gnunet://fs/chk/HASH1.HASH2.SIZE |
129 | Description: The GNU General Public License | 327 | .Pp |
130 | Mime-type: text/plain | 328 | Description: The GNU General Public License |
329 | Mime-type: text/plain | ||
330 | ... | ||
131 | .ad b | 331 | .ad b |
132 | 332 | .Pp | |
133 | The first line contains the command to run to download the file. | 333 | The first line contains the command to run to download the file. |
134 | The suggested filename in the example is COPYING. | 334 | The suggested filename in the example is |
135 | The GNUnet URI consists of the key and query hash of the file and finally the size of the file. | 335 | .Ql COPYING Ns |
136 | After the command to download the file, GNUnet will print meta-data about the file as advertised in the search result. | 336 | \&. The GNUnet URI consists of the key and query hash of the file and finally the size of the file. |
137 | The meta-data here is the description ("The GNU General Public License") and the mime-type ("text-plain"). | 337 | If the |
338 | .Fl -verbose | ||
339 | option was provided, after the command to download the file, GNUnet will print metadata about the file as advertised in the search result. | ||
340 | The metadata here is the description | ||
341 | .No ( Ns | ||
342 | .Dq The GNU General Public License Ns | ||
343 | ) and the mime-type | ||
344 | .No ( Ns | ||
345 | .Dq text-plain Ns | ||
346 | ). | ||
138 | See the options for | 347 | See the options for |
139 | .Xr gnunet-publish 1 | 348 | .Xr gnunet-publish 1 |
140 | on how to supply meta-data by hand. | 349 | on how to supply metadata by hand. |
350 | .Pp | ||
351 | The | ||
352 | .Fl -printf | ||
353 | .No ( Ns | ||
354 | .Fl f Ns | ||
355 | ), | ||
356 | .Fl -dir-printf | ||
357 | .No ( Ns | ||
358 | .Fl F Ns | ||
359 | ) and | ||
360 | .Fl -iter-printf | ||
361 | .No ( Ns | ||
362 | .Fl i Ns | ||
363 | ) arguments offer powerful tools for manipulating the output printed. For instance, | ||
364 | .Pp | ||
365 | Example 4: | ||
366 | .Pp | ||
367 | .ad l | ||
368 | $ gnunet-search -f '%f (%s bytes)\en' commons | ||
369 | .Pp | ||
370 | will print a simple list of the results that match the | ||
371 | .Dq commons | ||
372 | keyword, with only the file name and the size printed, without any URI. Or, for instance, | ||
373 | .Pp | ||
374 | Example 5: | ||
375 | .Pp | ||
376 | .ad l | ||
377 | #!/bin/sh | ||
378 | { | ||
379 | printf '<list>' | ||
380 | gnunet-search -f ' | ||
381 | <file uri="%u"> | ||
382 | <filename len="%l">%f</filename> | ||
383 | <size>%s</size> | ||
384 | <mimetype>%m</mimetype> | ||
385 | <result_id>%n</result_id> | ||
386 | <metadata>%a | ||
387 | </metadata> | ||
388 | </file>' \e | ||
389 | -i ' | ||
390 | <property tid="%i" type="%t"> | ||
391 | <content len="%l">%p</content> | ||
392 | <property_id>%n</property_id> | ||
393 | <provided_by>%w</provided_by> | ||
394 | </property>' \e | ||
395 | -t '2 s' commons | ||
396 | printf '\en</list>\en' | ||
397 | } > commons.xml | ||
398 | .Pp | ||
399 | will run for two seconds and then create a file named | ||
400 | .Pa commons.xml Ns | ||
401 | , containing the search results that match the | ||
402 | .Dq commons | ||
403 | keyword in XML format. | ||
141 | .Sh SEE ALSO | 404 | .Sh SEE ALSO |
142 | .Xr gnunet-download 1 , | 405 | .Xr gnunet-download 1 , |
143 | .Xr gnunet-fs-gtk 1 , | 406 | .Xr gnunet-fs-gtk 1 , |
144 | .Xr gnunet-publish 1 , | 407 | .Xr gnunet-publish 1 , |
145 | .Xr gnunet.conf 5 | 408 | .Xr gnunet.conf 5 |
146 | .sp | 409 | .sp |
147 | The full documentation for gnunet is maintained as a Texinfo manual. | 410 | The full documentation for GNUnet is maintained as a Texinfo manual. |
148 | If the | 411 | If the |
149 | .Xr info 1 | 412 | .Xr info 1 |
150 | and gnunet programs are properly installed at your site, the command | 413 | and gnunet packages are properly installed at your site, the command |
151 | .Pp | 414 | .Pp |
152 | .Dl info gnunet | 415 | .Dl info gnunet |
153 | .Pp | 416 | .Pp |
diff --git a/doc/tutorial/tutorial.texi b/doc/tutorial/tutorial.texi index 0a011c0c8..f849e116a 100644 --- a/doc/tutorial/tutorial.texi +++ b/doc/tutorial/tutorial.texi | |||
@@ -225,7 +225,7 @@ This is required for obtaining the repository, which is achieved with | |||
225 | the following command: | 225 | the following command: |
226 | 226 | ||
227 | @example | 227 | @example |
228 | $ git clone https://git.gnunet.org/gnunet | 228 | $ git clone https://git.gnunet.org/gnunet.git |
229 | @end example | 229 | @end example |
230 | 230 | ||
231 | @noindent | 231 | @noindent |
@@ -795,7 +795,7 @@ a template build system for writing GNUnet extensions in C. It can be | |||
795 | obtained as follows: | 795 | obtained as follows: |
796 | 796 | ||
797 | @example | 797 | @example |
798 | $ git clone https://git.gnunet.org/gnunet-ext | 798 | $ git clone https://git.gnunet.org/gnunet-ext.git |
799 | $ cd gnunet-ext/ | 799 | $ cd gnunet-ext/ |
800 | $ ./bootstrap | 800 | $ ./bootstrap |
801 | $ ./configure --prefix=$PREFIX --with-gnunet=$PREFIX | 801 | $ ./configure --prefix=$PREFIX --with-gnunet=$PREFIX |
diff --git a/po/POTFILES.in b/po/POTFILES.in index ad5c68056..64df0a13b 100644 --- a/po/POTFILES.in +++ b/po/POTFILES.in | |||
@@ -10,14 +10,13 @@ src/arm/arm_monitor_api.c | |||
10 | src/arm/gnunet-arm.c | 10 | src/arm/gnunet-arm.c |
11 | src/arm/gnunet-service-arm.c | 11 | src/arm/gnunet-service-arm.c |
12 | src/arm/mockup-service.c | 12 | src/arm/mockup-service.c |
13 | src/ats-tool/gnunet-ats.c | ||
14 | src/ats/ats_api_connectivity.c | 13 | src/ats/ats_api_connectivity.c |
15 | src/ats/ats_api_performance.c | 14 | src/ats/ats_api_performance.c |
16 | src/ats/ats_api_scanner.c | 15 | src/ats/ats_api_scanner.c |
17 | src/ats/ats_api_scheduling.c | 16 | src/ats/ats_api_scheduling.c |
18 | src/ats/gnunet-ats-solver-eval.c | 17 | src/ats/gnunet-ats-solver-eval.c |
19 | src/ats/gnunet-service-ats.c | ||
20 | src/ats/gnunet-service-ats_addresses.c | 18 | src/ats/gnunet-service-ats_addresses.c |
19 | src/ats/gnunet-service-ats.c | ||
21 | src/ats/gnunet-service-ats_connectivity.c | 20 | src/ats/gnunet-service-ats_connectivity.c |
22 | src/ats/gnunet-service-ats_normalization.c | 21 | src/ats/gnunet-service-ats_normalization.c |
23 | src/ats/gnunet-service-ats_performance.c | 22 | src/ats/gnunet-service-ats_performance.c |
@@ -26,6 +25,7 @@ src/ats/gnunet-service-ats_preferences.c | |||
26 | src/ats/gnunet-service-ats_reservations.c | 25 | src/ats/gnunet-service-ats_reservations.c |
27 | src/ats/gnunet-service-ats_scheduling.c | 26 | src/ats/gnunet-service-ats_scheduling.c |
28 | src/ats/plugin_ats_proportional.c | 27 | src/ats/plugin_ats_proportional.c |
28 | src/ats-tool/gnunet-ats.c | ||
29 | src/auction/gnunet-auction-create.c | 29 | src/auction/gnunet-auction-create.c |
30 | src/auction/gnunet-auction-info.c | 30 | src/auction/gnunet-auction-info.c |
31 | src/auction/gnunet-auction-join.c | 31 | src/auction/gnunet-auction-join.c |
@@ -43,8 +43,8 @@ src/cadet/cadet_api_list_peers.c | |||
43 | src/cadet/cadet_api_list_tunnels.c | 43 | src/cadet/cadet_api_list_tunnels.c |
44 | src/cadet/cadet_test_lib.c | 44 | src/cadet/cadet_test_lib.c |
45 | src/cadet/desirability_table.c | 45 | src/cadet/desirability_table.c |
46 | src/cadet/gnunet-cadet-profiler.c | ||
47 | src/cadet/gnunet-cadet.c | 46 | src/cadet/gnunet-cadet.c |
47 | src/cadet/gnunet-cadet-profiler.c | ||
48 | src/cadet/gnunet-service-cadet.c | 48 | src/cadet/gnunet-service-cadet.c |
49 | src/cadet/gnunet-service-cadet_channel.c | 49 | src/cadet/gnunet-service-cadet_channel.c |
50 | src/cadet/gnunet-service-cadet_connection.c | 50 | src/cadet/gnunet-service-cadet_connection.c |
@@ -60,15 +60,15 @@ src/consensus/gnunet-service-consensus.c | |||
60 | src/consensus/plugin_block_consensus.c | 60 | src/consensus/plugin_block_consensus.c |
61 | src/conversation/conversation_api.c | 61 | src/conversation/conversation_api.c |
62 | src/conversation/conversation_api_call.c | 62 | src/conversation/conversation_api_call.c |
63 | src/conversation/gnunet-conversation-test.c | ||
64 | src/conversation/gnunet-conversation.c | 63 | src/conversation/gnunet-conversation.c |
65 | src/conversation/gnunet-helper-audio-playback-gst.c | 64 | src/conversation/gnunet-conversation-test.c |
65 | src/conversation/gnunet_gst.c | ||
66 | src/conversation/gnunet_gst_test.c | ||
66 | src/conversation/gnunet-helper-audio-playback.c | 67 | src/conversation/gnunet-helper-audio-playback.c |
67 | src/conversation/gnunet-helper-audio-record-gst.c | 68 | src/conversation/gnunet-helper-audio-playback-gst.c |
68 | src/conversation/gnunet-helper-audio-record.c | 69 | src/conversation/gnunet-helper-audio-record.c |
70 | src/conversation/gnunet-helper-audio-record-gst.c | ||
69 | src/conversation/gnunet-service-conversation.c | 71 | src/conversation/gnunet-service-conversation.c |
70 | src/conversation/gnunet_gst.c | ||
71 | src/conversation/gnunet_gst_test.c | ||
72 | src/conversation/microphone.c | 72 | src/conversation/microphone.c |
73 | src/conversation/plugin_gnsrecord_conversation.c | 73 | src/conversation/plugin_gnsrecord_conversation.c |
74 | src/conversation/speaker.c | 74 | src/conversation/speaker.c |
@@ -97,16 +97,15 @@ src/datastore/plugin_datastore_template.c | |||
97 | src/dht/dht_api.c | 97 | src/dht/dht_api.c |
98 | src/dht/dht_test_lib.c | 98 | src/dht/dht_test_lib.c |
99 | src/dht/gnunet-dht-get.c | 99 | src/dht/gnunet-dht-get.c |
100 | src/dht/gnunet-dht-hello.c | ||
100 | src/dht/gnunet-dht-monitor.c | 101 | src/dht/gnunet-dht-monitor.c |
102 | src/dht/gnunet_dht_profiler.c | ||
101 | src/dht/gnunet-dht-put.c | 103 | src/dht/gnunet-dht-put.c |
102 | src/dht/gnunet-service-dht.c | 104 | src/dht/gnunet-service-dht.c |
103 | src/dht/gnunet-service-dht_clients.c | 105 | src/dht/gnunet-service-dht_clients.c |
104 | src/dht/gnunet-service-dht_datacache.c | 106 | src/dht/gnunet-service-dht_datacache.c |
105 | src/dht/gnunet-service-dht_hello.c | ||
106 | src/dht/gnunet-service-dht_neighbours.c | 107 | src/dht/gnunet-service-dht_neighbours.c |
107 | src/dht/gnunet-service-dht_nse.c | ||
108 | src/dht/gnunet-service-dht_routing.c | 108 | src/dht/gnunet-service-dht_routing.c |
109 | src/dht/gnunet_dht_profiler.c | ||
110 | src/dht/plugin_block_dht.c | 109 | src/dht/plugin_block_dht.c |
111 | src/dhtu/plugin_dhtu_gnunet.c | 110 | src/dhtu/plugin_dhtu_gnunet.c |
112 | src/dhtu/plugin_dhtu_ip.c | 111 | src/dhtu/plugin_dhtu_ip.c |
@@ -144,8 +143,8 @@ src/fs/gnunet-auto-share.c | |||
144 | src/fs/gnunet-daemon-fsprofiler.c | 143 | src/fs/gnunet-daemon-fsprofiler.c |
145 | src/fs/gnunet-directory.c | 144 | src/fs/gnunet-directory.c |
146 | src/fs/gnunet-download.c | 145 | src/fs/gnunet-download.c |
147 | src/fs/gnunet-fs-profiler.c | ||
148 | src/fs/gnunet-fs.c | 146 | src/fs/gnunet-fs.c |
147 | src/fs/gnunet-fs-profiler.c | ||
149 | src/fs/gnunet-helper-fs-publish.c | 148 | src/fs/gnunet-helper-fs-publish.c |
150 | src/fs/gnunet-publish.c | 149 | src/fs/gnunet-publish.c |
151 | src/fs/gnunet-search.c | 150 | src/fs/gnunet-search.c |
@@ -165,9 +164,9 @@ src/gns/gns_tld_api.c | |||
165 | src/gns/gnunet-bcd.c | 164 | src/gns/gnunet-bcd.c |
166 | src/gns/gnunet-dns2gns.c | 165 | src/gns/gnunet-dns2gns.c |
167 | src/gns/gnunet-gns-benchmark.c | 166 | src/gns/gnunet-gns-benchmark.c |
167 | src/gns/gnunet-gns.c | ||
168 | src/gns/gnunet-gns-import.c | 168 | src/gns/gnunet-gns-import.c |
169 | src/gns/gnunet-gns-proxy.c | 169 | src/gns/gnunet-gns-proxy.c |
170 | src/gns/gnunet-gns.c | ||
171 | src/gns/gnunet-service-gns.c | 170 | src/gns/gnunet-service-gns.c |
172 | src/gns/gnunet-service-gns_interceptor.c | 171 | src/gns/gnunet-service-gns_interceptor.c |
173 | src/gns/gnunet-service-gns_resolver.c | 172 | src/gns/gnunet-service-gns_resolver.c |
@@ -183,11 +182,11 @@ src/gnsrecord/gnsrecord_serialization.c | |||
183 | src/gnsrecord/gnunet-gnsrecord-tvg.c | 182 | src/gnsrecord/gnunet-gnsrecord-tvg.c |
184 | src/gnsrecord/json_gnsrecord.c | 183 | src/gnsrecord/json_gnsrecord.c |
185 | src/gnsrecord/plugin_gnsrecord_dns.c | 184 | src/gnsrecord/plugin_gnsrecord_dns.c |
186 | src/gnsrecord/test.c | ||
187 | src/hello/address.c | 185 | src/hello/address.c |
188 | src/hello/gnunet-hello.c | 186 | src/hello/gnunet-hello.c |
189 | src/hello/hello-ng.c | ||
190 | src/hello/hello.c | 187 | src/hello/hello.c |
188 | src/hello/hello-ng.c | ||
189 | src/hello/hello-uri.c | ||
191 | src/hostlist/gnunet-daemon-hostlist.c | 190 | src/hostlist/gnunet-daemon-hostlist.c |
192 | src/hostlist/gnunet-daemon-hostlist_client.c | 191 | src/hostlist/gnunet-daemon-hostlist_client.c |
193 | src/hostlist/gnunet-daemon-hostlist_server.c | 192 | src/hostlist/gnunet-daemon-hostlist_server.c |
@@ -203,8 +202,8 @@ src/json/json_helper.c | |||
203 | src/json/json_mhd.c | 202 | src/json/json_mhd.c |
204 | src/json/json_pack.c | 203 | src/json/json_pack.c |
205 | src/messenger/gnunet-messenger.c | 204 | src/messenger/gnunet-messenger.c |
206 | src/messenger/gnunet-service-messenger.c | ||
207 | src/messenger/gnunet-service-messenger_basement.c | 205 | src/messenger/gnunet-service-messenger_basement.c |
206 | src/messenger/gnunet-service-messenger.c | ||
208 | src/messenger/gnunet-service-messenger_ego_store.c | 207 | src/messenger/gnunet-service-messenger_ego_store.c |
209 | src/messenger/gnunet-service-messenger_handle.c | 208 | src/messenger/gnunet-service-messenger_handle.c |
210 | src/messenger/gnunet-service-messenger_list_handles.c | 209 | src/messenger/gnunet-service-messenger_list_handles.c |
@@ -244,8 +243,8 @@ src/namecache/namecache_api.c | |||
244 | src/namecache/plugin_namecache_flat.c | 243 | src/namecache/plugin_namecache_flat.c |
245 | src/namecache/plugin_namecache_postgres.c | 244 | src/namecache/plugin_namecache_postgres.c |
246 | src/namecache/plugin_namecache_sqlite.c | 245 | src/namecache/plugin_namecache_sqlite.c |
247 | src/namestore/gnunet-namestore-fcfsd.c | ||
248 | src/namestore/gnunet-namestore.c | 246 | src/namestore/gnunet-namestore.c |
247 | src/namestore/gnunet-namestore-fcfsd.c | ||
249 | src/namestore/gnunet-service-namestore.c | 248 | src/namestore/gnunet-service-namestore.c |
250 | src/namestore/gnunet-zoneimport.c | 249 | src/namestore/gnunet-zoneimport.c |
251 | src/namestore/namestore_api.c | 250 | src/namestore/namestore_api.c |
@@ -271,17 +270,17 @@ src/nat/gnunet-service-nat_mini.c | |||
271 | src/nat/gnunet-service-nat_stun.c | 270 | src/nat/gnunet-service-nat_stun.c |
272 | src/nat/nat_api.c | 271 | src/nat/nat_api.c |
273 | src/nat/nat_api_stun.c | 272 | src/nat/nat_api_stun.c |
274 | src/nse/gnunet-nse-profiler.c | ||
275 | src/nse/gnunet-nse.c | 273 | src/nse/gnunet-nse.c |
274 | src/nse/gnunet-nse-profiler.c | ||
276 | src/nse/gnunet-service-nse.c | 275 | src/nse/gnunet-service-nse.c |
277 | src/nse/nse_api.c | 276 | src/nse/nse_api.c |
278 | src/nt/nt.c | 277 | src/nt/nt.c |
279 | src/peerinfo-tool/gnunet-peerinfo.c | ||
280 | src/peerinfo-tool/gnunet-peerinfo_plugins.c | ||
281 | src/peerinfo-tool/plugin_rest_peerinfo.c | ||
282 | src/peerinfo/gnunet-service-peerinfo.c | 278 | src/peerinfo/gnunet-service-peerinfo.c |
283 | src/peerinfo/peerinfo_api.c | 279 | src/peerinfo/peerinfo_api.c |
284 | src/peerinfo/peerinfo_api_notify.c | 280 | src/peerinfo/peerinfo_api_notify.c |
281 | src/peerinfo-tool/gnunet-peerinfo.c | ||
282 | src/peerinfo-tool/gnunet-peerinfo_plugins.c | ||
283 | src/peerinfo-tool/plugin_rest_peerinfo.c | ||
285 | src/peerstore/gnunet-peerstore.c | 284 | src/peerstore/gnunet-peerstore.c |
286 | src/peerstore/gnunet-service-peerstore.c | 285 | src/peerstore/gnunet-service-peerstore.c |
287 | src/peerstore/peerstore_api.c | 286 | src/peerstore/peerstore_api.c |
@@ -315,7 +314,6 @@ src/reclaim/plugin_rest_reclaim.c | |||
315 | src/reclaim/reclaim_api.c | 314 | src/reclaim/reclaim_api.c |
316 | src/reclaim/reclaim_attribute.c | 315 | src/reclaim/reclaim_attribute.c |
317 | src/reclaim/reclaim_credential.c | 316 | src/reclaim/reclaim_credential.c |
318 | src/reclaim/test.c | ||
319 | src/regex/gnunet-daemon-regexprofiler.c | 317 | src/regex/gnunet-daemon-regexprofiler.c |
320 | src/regex/gnunet-regex-profiler.c | 318 | src/regex/gnunet-regex-profiler.c |
321 | src/regex/gnunet-regex-simulation-profiler.c | 319 | src/regex/gnunet-regex-simulation-profiler.c |
@@ -334,27 +332,27 @@ src/rest/gnunet-rest-server.c | |||
334 | src/rest/plugin_rest_config.c | 332 | src/rest/plugin_rest_config.c |
335 | src/rest/plugin_rest_copying.c | 333 | src/rest/plugin_rest_copying.c |
336 | src/rest/rest.c | 334 | src/rest/rest.c |
337 | src/revocation/gnunet-revocation-tvg.c | ||
338 | src/revocation/gnunet-revocation.c | 335 | src/revocation/gnunet-revocation.c |
336 | src/revocation/gnunet-revocation-tvg.c | ||
339 | src/revocation/gnunet-service-revocation.c | 337 | src/revocation/gnunet-service-revocation.c |
340 | src/revocation/plugin_block_revocation.c | 338 | src/revocation/plugin_block_revocation.c |
341 | src/revocation/revocation_api.c | 339 | src/revocation/revocation_api.c |
342 | src/rps/gnunet-rps-profiler.c | ||
343 | src/rps/gnunet-rps.c | 340 | src/rps/gnunet-rps.c |
341 | src/rps/gnunet-rps-profiler.c | ||
344 | src/rps/gnunet-service-rps.c | 342 | src/rps/gnunet-service-rps.c |
345 | src/rps/gnunet-service-rps_custommap.c | 343 | src/rps/gnunet-service-rps_custommap.c |
346 | src/rps/gnunet-service-rps_sampler.c | 344 | src/rps/gnunet-service-rps_sampler.c |
347 | src/rps/gnunet-service-rps_sampler_elem.c | 345 | src/rps/gnunet-service-rps_sampler_elem.c |
348 | src/rps/gnunet-service-rps_view.c | 346 | src/rps/gnunet-service-rps_view.c |
347 | src/rps/rps_api.c | ||
349 | src/rps/rps-sampler_client.c | 348 | src/rps/rps-sampler_client.c |
350 | src/rps/rps-sampler_common.c | 349 | src/rps/rps-sampler_common.c |
351 | src/rps/rps-test_util.c | 350 | src/rps/rps-test_util.c |
352 | src/rps/rps_api.c | ||
353 | src/scalarproduct/gnunet-scalarproduct.c | 351 | src/scalarproduct/gnunet-scalarproduct.c |
354 | src/scalarproduct/gnunet-service-scalarproduct-ecc_alice.c | ||
355 | src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c | ||
356 | src/scalarproduct/gnunet-service-scalarproduct_alice.c | 352 | src/scalarproduct/gnunet-service-scalarproduct_alice.c |
357 | src/scalarproduct/gnunet-service-scalarproduct_bob.c | 353 | src/scalarproduct/gnunet-service-scalarproduct_bob.c |
354 | src/scalarproduct/gnunet-service-scalarproduct-ecc_alice.c | ||
355 | src/scalarproduct/gnunet-service-scalarproduct-ecc_bob.c | ||
358 | src/scalarproduct/scalarproduct_api.c | 356 | src/scalarproduct/scalarproduct_api.c |
359 | src/secretsharing/gnunet-secretsharing-profiler.c | 357 | src/secretsharing/gnunet-secretsharing-profiler.c |
360 | src/secretsharing/gnunet-service-secretsharing.c | 358 | src/secretsharing/gnunet-service-secretsharing.c |
@@ -368,12 +366,12 @@ src/set/gnunet-set-ibf-profiler.c | |||
368 | src/set/gnunet-set-profiler.c | 366 | src/set/gnunet-set-profiler.c |
369 | src/set/ibf.c | 367 | src/set/ibf.c |
370 | src/set/ibf_sim.c | 368 | src/set/ibf_sim.c |
371 | src/set/plugin_block_set_test.c | ||
372 | src/set/set_api.c | ||
373 | src/seti/gnunet-service-seti.c | 369 | src/seti/gnunet-service-seti.c |
374 | src/seti/gnunet-seti-profiler.c | 370 | src/seti/gnunet-seti-profiler.c |
375 | src/seti/plugin_block_seti_test.c | 371 | src/seti/plugin_block_seti_test.c |
376 | src/seti/seti_api.c | 372 | src/seti/seti_api.c |
373 | src/set/plugin_block_set_test.c | ||
374 | src/set/set_api.c | ||
377 | src/setu/gnunet-service-setu.c | 375 | src/setu/gnunet-service-setu.c |
378 | src/setu/gnunet-service-setu_strata_estimator.c | 376 | src/setu/gnunet-service-setu_strata_estimator.c |
379 | src/setu/gnunet-setu-ibf-profiler.c | 377 | src/setu/gnunet-setu-ibf-profiler.c |
@@ -392,16 +390,15 @@ src/statistics/gnunet-statistics.c | |||
392 | src/statistics/statistics_api.c | 390 | src/statistics/statistics_api.c |
393 | src/template/gnunet-service-template.c | 391 | src/template/gnunet-service-template.c |
394 | src/template/gnunet-template.c | 392 | src/template/gnunet-template.c |
395 | src/testbed-logger/gnunet-service-testbed-logger.c | ||
396 | src/testbed-logger/testbed_logger_api.c | ||
397 | src/testbed/generate-underlay-topology.c | 393 | src/testbed/generate-underlay-topology.c |
398 | src/testbed/gnunet-daemon-latency-logger.c | 394 | src/testbed/gnunet-daemon-latency-logger.c |
399 | src/testbed/gnunet-daemon-testbed-blacklist.c | 395 | src/testbed/gnunet-daemon-testbed-blacklist.c |
400 | src/testbed/gnunet-daemon-testbed-underlay.c | 396 | src/testbed/gnunet-daemon-testbed-underlay.c |
401 | src/testbed/gnunet-helper-testbed.c | 397 | src/testbed/gnunet-helper-testbed.c |
398 | src/testbed/gnunet_mpi_test.c | ||
402 | src/testbed/gnunet-service-test-barriers.c | 399 | src/testbed/gnunet-service-test-barriers.c |
403 | src/testbed/gnunet-service-testbed.c | ||
404 | src/testbed/gnunet-service-testbed_barriers.c | 400 | src/testbed/gnunet-service-testbed_barriers.c |
401 | src/testbed/gnunet-service-testbed.c | ||
405 | src/testbed/gnunet-service-testbed_cache.c | 402 | src/testbed/gnunet-service-testbed_cache.c |
406 | src/testbed/gnunet-service-testbed_connectionpool.c | 403 | src/testbed/gnunet-service-testbed_connectionpool.c |
407 | src/testbed/gnunet-service-testbed_cpustatus.c | 404 | src/testbed/gnunet-service-testbed_cpustatus.c |
@@ -410,23 +407,23 @@ src/testbed/gnunet-service-testbed_meminfo.c | |||
410 | src/testbed/gnunet-service-testbed_oc.c | 407 | src/testbed/gnunet-service-testbed_oc.c |
411 | src/testbed/gnunet-service-testbed_peers.c | 408 | src/testbed/gnunet-service-testbed_peers.c |
412 | src/testbed/gnunet-testbed-profiler.c | 409 | src/testbed/gnunet-testbed-profiler.c |
413 | src/testbed/gnunet_mpi_test.c | 410 | src/testbed-logger/gnunet-service-testbed-logger.c |
414 | src/testbed/testbed_api.c | 411 | src/testbed-logger/testbed_logger_api.c |
415 | src/testbed/testbed_api_barriers.c | 412 | src/testbed/testbed_api_barriers.c |
413 | src/testbed/testbed_api.c | ||
416 | src/testbed/testbed_api_hosts.c | 414 | src/testbed/testbed_api_hosts.c |
417 | src/testbed/testbed_api_operations.c | 415 | src/testbed/testbed_api_operations.c |
418 | src/testbed/testbed_api_peers.c | 416 | src/testbed/testbed_api_peers.c |
419 | src/testbed/testbed_api_sd.c | 417 | src/testbed/testbed_api_sd.c |
420 | src/testbed/testbed_api_services.c | 418 | src/testbed/testbed_api_services.c |
421 | src/testbed/testbed_api_statistics.c | 419 | src/testbed/testbed_api_statistics.c |
422 | src/testbed/testbed_api_test.c | ||
423 | src/testbed/testbed_api_testbed.c | 420 | src/testbed/testbed_api_testbed.c |
421 | src/testbed/testbed_api_test.c | ||
424 | src/testbed/testbed_api_topology.c | 422 | src/testbed/testbed_api_topology.c |
425 | src/testbed/testbed_api_underlay.c | 423 | src/testbed/testbed_api_underlay.c |
426 | src/testing/gnunet-cmds-helper.c | 424 | src/testing/gnunet-cmds-helper.c |
427 | src/testing/gnunet-testing.c | 425 | src/testing/gnunet-testing.c |
428 | src/testing/list-keys.c | 426 | src/testing/list-keys.c |
429 | src/testing/testing.c | ||
430 | src/testing/testing_api_cmd_batch.c | 427 | src/testing/testing_api_cmd_batch.c |
431 | src/testing/testing_api_cmd_block_until_external_trigger.c | 428 | src/testing/testing_api_cmd_block_until_external_trigger.c |
432 | src/testing/testing_api_cmd_end.c | 429 | src/testing/testing_api_cmd_end.c |
@@ -442,51 +439,41 @@ src/testing/testing_api_cmd_system_create.c | |||
442 | src/testing/testing_api_cmd_system_destroy.c | 439 | src/testing/testing_api_cmd_system_destroy.c |
443 | src/testing/testing_api_loop.c | 440 | src/testing/testing_api_loop.c |
444 | src/testing/testing_api_traits.c | 441 | src/testing/testing_api_traits.c |
442 | src/testing/testing.c | ||
445 | src/topology/friends.c | 443 | src/topology/friends.c |
446 | src/topology/gnunet-daemon-topology.c | 444 | src/topology/gnunet-daemon-topology.c |
447 | src/transport/gnunet-communicator-tcp.c | 445 | src/transport/gnunet-communicator-tcp.c |
448 | src/transport/gnunet-communicator-udp.c | 446 | src/transport/gnunet-communicator-udp.c |
449 | src/transport/gnunet-communicator-unix.c | 447 | src/transport/gnunet-communicator-unix.c |
450 | src/transport/gnunet-helper-transport-bluetooth.c | 448 | src/transport/gnunet-helper-transport-bluetooth.c |
451 | src/transport/gnunet-helper-transport-wlan-dummy.c | ||
452 | src/transport/gnunet-helper-transport-wlan.c | 449 | src/transport/gnunet-helper-transport-wlan.c |
450 | src/transport/gnunet-helper-transport-wlan-dummy.c | ||
453 | src/transport/gnunet-service-tng.c | 451 | src/transport/gnunet-service-tng.c |
454 | src/transport/gnunet-service-transport.c | ||
455 | src/transport/gnunet-service-transport_ats.c | 452 | src/transport/gnunet-service-transport_ats.c |
453 | src/transport/gnunet-service-transport.c | ||
456 | src/transport/gnunet-service-transport_hello.c | 454 | src/transport/gnunet-service-transport_hello.c |
457 | src/transport/gnunet-service-transport_manipulation.c | 455 | src/transport/gnunet-service-transport_manipulation.c |
458 | src/transport/gnunet-service-transport_neighbours.c | 456 | src/transport/gnunet-service-transport_neighbours.c |
459 | src/transport/gnunet-service-transport_plugins.c | 457 | src/transport/gnunet-service-transport_plugins.c |
460 | src/transport/gnunet-service-transport_validation.c | 458 | src/transport/gnunet-service-transport_validation.c |
459 | src/transport/gnunet-transport.c | ||
461 | src/transport/gnunet-transport-profiler.c | 460 | src/transport/gnunet-transport-profiler.c |
462 | src/transport/gnunet-transport-wlan-receiver.c | 461 | src/transport/gnunet-transport-wlan-receiver.c |
463 | src/transport/gnunet-transport-wlan-sender.c | 462 | src/transport/gnunet-transport-wlan-sender.c |
464 | src/transport/gnunet-transport.c | ||
465 | src/transport/plugin_transport_http_client.c | 463 | src/transport/plugin_transport_http_client.c |
466 | src/transport/plugin_transport_http_common.c | 464 | src/transport/plugin_transport_http_common.c |
467 | src/transport/plugin_transport_http_server.c | 465 | src/transport/plugin_transport_http_server.c |
468 | src/transport/plugin_transport_smtp.c | 466 | src/transport/plugin_transport_smtp.c |
469 | src/transport/plugin_transport_tcp.c | 467 | src/transport/plugin_transport_tcp.c |
470 | src/transport/plugin_transport_template.c | 468 | src/transport/plugin_transport_template.c |
471 | src/transport/plugin_transport_udp.c | ||
472 | src/transport/plugin_transport_udp_broadcasting.c | 469 | src/transport/plugin_transport_udp_broadcasting.c |
470 | src/transport/plugin_transport_udp.c | ||
473 | src/transport/plugin_transport_unix.c | 471 | src/transport/plugin_transport_unix.c |
474 | src/transport/plugin_transport_wlan.c | 472 | src/transport/plugin_transport_wlan.c |
475 | src/transport/tcp_connection_legacy.c | 473 | src/transport/tcp_connection_legacy.c |
476 | src/transport/tcp_server_legacy.c | 474 | src/transport/tcp_server_legacy.c |
477 | src/transport/tcp_server_mst_legacy.c | 475 | src/transport/tcp_server_mst_legacy.c |
478 | src/transport/tcp_service_legacy.c | 476 | src/transport/tcp_service_legacy.c |
479 | src/transport/transport-testing-communicator.c | ||
480 | src/transport/transport-testing-filenames.c | ||
481 | src/transport/transport-testing-filenames2.c | ||
482 | src/transport/transport-testing-loggers.c | ||
483 | src/transport/transport-testing-loggers2.c | ||
484 | src/transport/transport-testing-main.c | ||
485 | src/transport/transport-testing-main2.c | ||
486 | src/transport/transport-testing-send.c | ||
487 | src/transport/transport-testing-send2.c | ||
488 | src/transport/transport-testing.c | ||
489 | src/transport/transport-testing2.c | ||
490 | src/transport/transport_api2_application.c | 477 | src/transport/transport_api2_application.c |
491 | src/transport/transport_api2_communication.c | 478 | src/transport/transport_api2_communication.c |
492 | src/transport/transport_api2_core.c | 479 | src/transport/transport_api2_core.c |
@@ -505,6 +492,17 @@ src/transport/transport_api_monitor_peers.c | |||
505 | src/transport/transport_api_monitor_plugins.c | 492 | src/transport/transport_api_monitor_plugins.c |
506 | src/transport/transport_api_offer_hello.c | 493 | src/transport/transport_api_offer_hello.c |
507 | src/transport/transport_api_traits.c | 494 | src/transport/transport_api_traits.c |
495 | src/transport/transport-testing2.c | ||
496 | src/transport/transport-testing.c | ||
497 | src/transport/transport-testing-communicator.c | ||
498 | src/transport/transport-testing-filenames2.c | ||
499 | src/transport/transport-testing-filenames.c | ||
500 | src/transport/transport-testing-loggers2.c | ||
501 | src/transport/transport-testing-loggers.c | ||
502 | src/transport/transport-testing-main2.c | ||
503 | src/transport/transport-testing-main.c | ||
504 | src/transport/transport-testing-send2.c | ||
505 | src/transport/transport-testing-send.c | ||
508 | src/util/bandwidth.c | 506 | src/util/bandwidth.c |
509 | src/util/benchmark.c | 507 | src/util/benchmark.c |
510 | src/util/bio.c | 508 | src/util/bio.c |
@@ -520,8 +518,8 @@ src/util/consttime_memcmp.c | |||
520 | src/util/container_bloomfilter.c | 518 | src/util/container_bloomfilter.c |
521 | src/util/container_heap.c | 519 | src/util/container_heap.c |
522 | src/util/container_meta_data.c | 520 | src/util/container_meta_data.c |
523 | src/util/container_multihashmap.c | ||
524 | src/util/container_multihashmap32.c | 521 | src/util/container_multihashmap32.c |
522 | src/util/container_multihashmap.c | ||
525 | src/util/container_multipeermap.c | 523 | src/util/container_multipeermap.c |
526 | src/util/container_multishortmap.c | 524 | src/util/container_multishortmap.c |
527 | src/util/container_multiuuidmap.c | 525 | src/util/container_multiuuidmap.c |
@@ -548,8 +546,8 @@ src/util/dnsstub.c | |||
548 | src/util/getopt.c | 546 | src/util/getopt.c |
549 | src/util/getopt_helpers.c | 547 | src/util/getopt_helpers.c |
550 | src/util/gnunet-base32.c | 548 | src/util/gnunet-base32.c |
551 | src/util/gnunet-config-diff.c | ||
552 | src/util/gnunet-config.c | 549 | src/util/gnunet-config.c |
550 | src/util/gnunet-config-diff.c | ||
553 | src/util/gnunet-crypto-tvg.c | 551 | src/util/gnunet-crypto-tvg.c |
554 | src/util/gnunet-ecc.c | 552 | src/util/gnunet-ecc.c |
555 | src/util/gnunet-qr.c | 553 | src/util/gnunet-qr.c |
@@ -587,8 +585,8 @@ src/vpn/gnunet-helper-vpn.c | |||
587 | src/vpn/gnunet-service-vpn.c | 585 | src/vpn/gnunet-service-vpn.c |
588 | src/vpn/gnunet-vpn.c | 586 | src/vpn/gnunet-vpn.c |
589 | src/vpn/vpn_api.c | 587 | src/vpn/vpn_api.c |
590 | src/zonemaster/gnunet-service-zonemaster-monitor.c | ||
591 | src/zonemaster/gnunet-service-zonemaster.c | 588 | src/zonemaster/gnunet-service-zonemaster.c |
589 | src/zonemaster/gnunet-service-zonemaster-monitor.c | ||
592 | src/fs/fs_api.h | 590 | src/fs/fs_api.h |
593 | src/include/gnunet_json_lib.h | 591 | src/include/gnunet_json_lib.h |
594 | src/testbed/testbed_api.h | 592 | src/testbed/testbed_api.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: 2022-01-10 15:13+0100\n" | 13 | "POT-Creation-Date: 2022-03-04 22:23+0100\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" |
@@ -21,7 +21,7 @@ msgstr "" | |||
21 | "Plural-Forms: nplurals=2; plural=(n != 1);\n" | 21 | "Plural-Forms: nplurals=2; plural=(n != 1);\n" |
22 | "X-Generator: Poedit 1.7.4\n" | 22 | "X-Generator: Poedit 1.7.4\n" |
23 | 23 | ||
24 | #: src/abd/gnunet-abd.c:392 src/namestore/gnunet-namestore.c:1304 | 24 | #: src/abd/gnunet-abd.c:392 src/namestore/gnunet-namestore.c:1254 |
25 | #, fuzzy, c-format | 25 | #, fuzzy, c-format |
26 | msgid "Ego `%s' not known to identity service\n" | 26 | msgid "Ego `%s' not known to identity service\n" |
27 | msgstr "`%s': unbekannter Dienst: %s\n" | 27 | msgstr "`%s': unbekannter Dienst: %s\n" |
@@ -33,7 +33,7 @@ msgstr "" | |||
33 | 33 | ||
34 | #: src/abd/gnunet-abd.c:558 src/abd/gnunet-service-abd.c:1751 | 34 | #: src/abd/gnunet-abd.c:558 src/abd/gnunet-service-abd.c:1751 |
35 | #: src/namestore/gnunet-namestore-fcfsd.c:1080 | 35 | #: src/namestore/gnunet-namestore-fcfsd.c:1080 |
36 | #: src/namestore/gnunet-namestore.c:1001 | 36 | #: src/namestore/gnunet-namestore.c:951 |
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" |
@@ -621,44 +621,44 @@ msgstr "" | |||
621 | msgid "Print information about ATS state" | 621 | msgid "Print information about ATS state" |
622 | msgstr "Informationen über andere GNUnet Knoten ausgeben." | 622 | msgstr "Informationen über andere GNUnet Knoten ausgeben." |
623 | 623 | ||
624 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | 624 | #: src/ats/gnunet-ats-solver-eval.c:2993 src/ats/gnunet-ats-solver-eval.c:3045 |
625 | #, c-format | 625 | #, c-format |
626 | msgid "" | 626 | msgid "" |
627 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | 627 | "Could not load quota for network `%s': `%s', assigning default bandwidth " |
628 | "%llu\n" | 628 | "%llu\n" |
629 | msgstr "" | 629 | msgstr "" |
630 | 630 | ||
631 | #: src/ats/gnunet-ats-solver-eval.c:3011 | 631 | #: src/ats/gnunet-ats-solver-eval.c:3012 |
632 | #, c-format | 632 | #, c-format |
633 | msgid "" | 633 | msgid "" |
634 | "No outbound quota configured for network `%s', assigning default bandwidth " | 634 | "No outbound quota configured for network `%s', assigning default bandwidth " |
635 | "%llu\n" | 635 | "%llu\n" |
636 | msgstr "" | 636 | msgstr "" |
637 | 637 | ||
638 | #: src/ats/gnunet-ats-solver-eval.c:3063 | 638 | #: src/ats/gnunet-ats-solver-eval.c:3064 |
639 | #, c-format | 639 | #, c-format |
640 | msgid "" | 640 | msgid "" |
641 | "No outbound quota configure for network `%s', assigning default bandwidth " | 641 | "No outbound quota configure for network `%s', assigning default bandwidth " |
642 | "%llu\n" | 642 | "%llu\n" |
643 | msgstr "" | 643 | msgstr "" |
644 | 644 | ||
645 | #: src/ats/gnunet-ats-solver-eval.c:3552 | 645 | #: src/ats/gnunet-ats-solver-eval.c:3553 |
646 | msgid "solver to use" | 646 | msgid "solver to use" |
647 | msgstr "" | 647 | msgstr "" |
648 | 648 | ||
649 | #: src/ats/gnunet-ats-solver-eval.c:3557 | 649 | #: src/ats/gnunet-ats-solver-eval.c:3558 |
650 | msgid "experiment to use" | 650 | msgid "experiment to use" |
651 | msgstr "" | 651 | msgstr "" |
652 | 652 | ||
653 | #: src/ats/gnunet-ats-solver-eval.c:3564 | 653 | #: src/ats/gnunet-ats-solver-eval.c:3565 |
654 | msgid "print logging" | 654 | msgid "print logging" |
655 | msgstr "" | 655 | msgstr "" |
656 | 656 | ||
657 | #: src/ats/gnunet-ats-solver-eval.c:3569 | 657 | #: src/ats/gnunet-ats-solver-eval.c:3570 |
658 | msgid "save logging to disk" | 658 | msgid "save logging to disk" |
659 | msgstr "" | 659 | msgstr "" |
660 | 660 | ||
661 | #: src/ats/gnunet-ats-solver-eval.c:3574 | 661 | #: src/ats/gnunet-ats-solver-eval.c:3575 |
662 | msgid "disable normalization" | 662 | msgid "disable normalization" |
663 | msgstr "" | 663 | msgstr "" |
664 | 664 | ||
@@ -1540,39 +1540,7 @@ msgstr "# Bytes empfangen über TCP" | |||
1540 | msgid "# updates to my type map" | 1540 | msgid "# updates to my type map" |
1541 | msgstr "" | 1541 | msgstr "" |
1542 | 1542 | ||
1543 | #: src/datacache/datacache.c:117 src/datacache/datacache.c:275 | 1543 | #: src/datacache/plugin_datacache_heap.c:555 |
1544 | #: src/datastore/gnunet-service-datastore.c:743 | ||
1545 | msgid "# bytes stored" | ||
1546 | msgstr "# gespeicherte Bytes" | ||
1547 | |||
1548 | #: src/datacache/datacache.c:121 src/datacache/datacache.c:279 | ||
1549 | msgid "# items stored" | ||
1550 | msgstr "# gespeicherte Objekte" | ||
1551 | |||
1552 | #: src/datacache/datacache.c:185 | ||
1553 | #, c-format | ||
1554 | msgid "Loading `%s' datacache plugin\n" | ||
1555 | msgstr "" | ||
1556 | |||
1557 | #: src/datacache/datacache.c:203 | ||
1558 | #, fuzzy, c-format | ||
1559 | msgid "Failed to load datacache plugin for `%s'\n" | ||
1560 | msgstr "Fehler beim Aktualisieren der Daten des Moduls `%s'\n" | ||
1561 | |||
1562 | #: src/datacache/datacache.c:297 | ||
1563 | msgid "# requests received" | ||
1564 | msgstr "# Anfragen empfangen" | ||
1565 | |||
1566 | #: src/datacache/datacache.c:308 | ||
1567 | msgid "# requests filtered by bloom filter" | ||
1568 | msgstr "" | ||
1569 | |||
1570 | #: src/datacache/datacache.c:329 | ||
1571 | #, fuzzy | ||
1572 | msgid "# proximity search requests received" | ||
1573 | msgstr "# Klartext PONG Nachrichten empfangen" | ||
1574 | |||
1575 | #: src/datacache/plugin_datacache_heap.c:527 | ||
1576 | msgid "Heap datacache running\n" | 1544 | msgid "Heap datacache running\n" |
1577 | msgstr "" | 1545 | msgstr "" |
1578 | 1546 | ||
@@ -1594,7 +1562,7 @@ msgstr "" | |||
1594 | msgid "`%s' failed at %s:%d with error: %s\n" | 1562 | msgid "`%s' failed at %s:%d with error: %s\n" |
1595 | msgstr "»%s« schlug bei %s:%d mit dem Fehler %s fehl\n" | 1563 | msgstr "»%s« schlug bei %s:%d mit dem Fehler %s fehl\n" |
1596 | 1564 | ||
1597 | #: src/datacache/plugin_datacache_sqlite.c:693 | 1565 | #: src/datacache/plugin_datacache_sqlite.c:723 |
1598 | #: src/datastore/plugin_datastore_sqlite.c:531 | 1566 | #: src/datastore/plugin_datastore_sqlite.c:531 |
1599 | #: src/namecache/plugin_namecache_sqlite.c:237 | 1567 | #: src/namecache/plugin_namecache_sqlite.c:237 |
1600 | #: src/namestore/plugin_namestore_sqlite.c:273 | 1568 | #: src/namestore/plugin_namestore_sqlite.c:273 |
@@ -1783,6 +1751,10 @@ msgstr "" | |||
1783 | msgid "Could not find matching reservation" | 1751 | msgid "Could not find matching reservation" |
1784 | msgstr "" | 1752 | msgstr "" |
1785 | 1753 | ||
1754 | #: src/datastore/gnunet-service-datastore.c:743 | ||
1755 | msgid "# bytes stored" | ||
1756 | msgstr "# gespeicherte Bytes" | ||
1757 | |||
1786 | #: src/datastore/gnunet-service-datastore.c:758 | 1758 | #: src/datastore/gnunet-service-datastore.c:758 |
1787 | #, c-format | 1759 | #, c-format |
1788 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" | 1760 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" |
@@ -1970,7 +1942,7 @@ msgstr "" | |||
1970 | 1942 | ||
1971 | #: src/datastore/plugin_datastore_sqlite.c:1337 | 1943 | #: src/datastore/plugin_datastore_sqlite.c:1337 |
1972 | #: src/namecache/plugin_namecache_sqlite.c:564 | 1944 | #: src/namecache/plugin_namecache_sqlite.c:564 |
1973 | #: src/namestore/plugin_namestore_sqlite.c:765 | 1945 | #: src/namestore/plugin_namestore_sqlite.c:775 |
1974 | msgid "Sqlite database running\n" | 1946 | msgid "Sqlite database running\n" |
1975 | msgstr "Sqlite-Datenbank läuft\n" | 1947 | msgstr "Sqlite-Datenbank läuft\n" |
1976 | 1948 | ||
@@ -1978,55 +1950,65 @@ msgstr "Sqlite-Datenbank läuft\n" | |||
1978 | msgid "Template database running\n" | 1950 | msgid "Template database running\n" |
1979 | msgstr "" | 1951 | msgstr "" |
1980 | 1952 | ||
1981 | #: src/dht/gnunet-dht-get.c:159 | 1953 | #: src/dht/gnunet-dht-get.c:164 |
1982 | #, c-format | 1954 | #, c-format |
1983 | msgid "" | 1955 | msgid "" |
1984 | "Result %d, type %d:\n" | 1956 | "Result %d, type %d:\n" |
1985 | "%.*s\n" | 1957 | "%.*s\n" |
1986 | msgstr "" | 1958 | msgstr "" |
1987 | 1959 | ||
1988 | #: src/dht/gnunet-dht-get.c:160 | 1960 | #: src/dht/gnunet-dht-get.c:165 |
1989 | #, c-format | 1961 | #, c-format |
1990 | msgid "Result %d, type %d:\n" | 1962 | msgid "Result %d, type %d:\n" |
1991 | msgstr "" | 1963 | msgstr "" |
1992 | 1964 | ||
1993 | #: src/dht/gnunet-dht-get.c:209 | 1965 | #: src/dht/gnunet-dht-get.c:215 |
1994 | msgid "Must provide key for DHT GET!\n" | 1966 | msgid "Must provide key for DHT GET!\n" |
1995 | msgstr "" | 1967 | msgstr "" |
1996 | 1968 | ||
1997 | #: src/dht/gnunet-dht-get.c:217 src/dht/gnunet-dht-monitor.c:255 | 1969 | #: src/dht/gnunet-dht-get.c:223 src/dht/gnunet-dht-hello.c:119 |
1970 | #: src/dht/gnunet-dht-monitor.c:255 | ||
1971 | #, c-format | ||
1998 | msgid "Failed to connect to DHT service!\n" | 1972 | msgid "Failed to connect to DHT service!\n" |
1999 | msgstr "Verbindung zum DHT-Dienst ist fehlgeschlagen!\n" | 1973 | msgstr "Verbindung zum DHT-Dienst ist fehlgeschlagen!\n" |
2000 | 1974 | ||
2001 | #: src/dht/gnunet-dht-get.c:227 | 1975 | #: src/dht/gnunet-dht-get.c:233 |
2002 | msgid "Issuing DHT GET with key" | 1976 | msgid "Issuing DHT GET with key" |
2003 | msgstr "" | 1977 | msgstr "" |
2004 | 1978 | ||
2005 | #: src/dht/gnunet-dht-get.c:260 src/dht/gnunet-dht-monitor.c:302 | 1979 | #: src/dht/gnunet-dht-get.c:269 src/dht/gnunet-dht-monitor.c:302 |
2006 | #: src/dht/gnunet-dht-put.c:200 | 1980 | #: src/dht/gnunet-dht-put.c:200 |
2007 | msgid "the query key" | 1981 | msgid "the query key" |
2008 | msgstr "" | 1982 | msgstr "" |
2009 | 1983 | ||
2010 | #: src/dht/gnunet-dht-get.c:266 | 1984 | #: src/dht/gnunet-dht-get.c:275 |
2011 | msgid "how many parallel requests (replicas) to create" | 1985 | msgid "how many parallel requests (replicas) to create" |
2012 | msgstr "" | 1986 | msgstr "" |
2013 | 1987 | ||
2014 | #: src/dht/gnunet-dht-get.c:272 src/dht/gnunet-dht-monitor.c:308 | 1988 | #: src/dht/gnunet-dht-get.c:280 src/dht/gnunet-dht-put.c:217 |
1989 | msgid "use DHT's record route option" | ||
1990 | msgstr "" | ||
1991 | |||
1992 | #: src/dht/gnunet-dht-get.c:286 src/dht/gnunet-dht-monitor.c:308 | ||
2015 | msgid "the type of data to look for" | 1993 | msgid "the type of data to look for" |
2016 | msgstr "" | 1994 | msgstr "" |
2017 | 1995 | ||
2018 | #: src/dht/gnunet-dht-get.c:278 | 1996 | #: src/dht/gnunet-dht-get.c:292 |
2019 | msgid "how long to execute this query before giving up?" | 1997 | msgid "how long to execute this query before giving up?" |
2020 | msgstr "" | 1998 | msgstr "" |
2021 | 1999 | ||
2022 | #: src/dht/gnunet-dht-get.c:284 src/dht/gnunet-dht-put.c:206 | 2000 | #: src/dht/gnunet-dht-get.c:298 src/dht/gnunet-dht-put.c:206 |
2023 | msgid "use DHT's demultiplex everywhere option" | 2001 | msgid "use DHT's demultiplex everywhere option" |
2024 | msgstr "" | 2002 | msgstr "" |
2025 | 2003 | ||
2026 | #: src/dht/gnunet-dht-get.c:301 | 2004 | #: src/dht/gnunet-dht-get.c:315 |
2027 | msgid "Issue a GET request to the GNUnet DHT, prints results." | 2005 | msgid "Issue a GET request to the GNUnet DHT, prints results." |
2028 | msgstr "" | 2006 | msgstr "" |
2029 | 2007 | ||
2008 | #: src/dht/gnunet-dht-hello.c:166 | ||
2009 | msgid "Obtain HELLO from DHT or provide HELLO to DHT for bootstrapping" | ||
2010 | msgstr "" | ||
2011 | |||
2030 | #: src/dht/gnunet-dht-monitor.c:315 | 2012 | #: src/dht/gnunet-dht-monitor.c:315 |
2031 | msgid "how long should the monitor command run" | 2013 | msgid "how long should the monitor command run" |
2032 | msgstr "" | 2014 | msgstr "" |
@@ -2066,10 +2048,6 @@ msgstr "" | |||
2066 | msgid "how many replicas to create" | 2048 | msgid "how many replicas to create" |
2067 | msgstr "" | 2049 | msgstr "" |
2068 | 2050 | ||
2069 | #: src/dht/gnunet-dht-put.c:217 | ||
2070 | msgid "use DHT's record route option" | ||
2071 | msgstr "" | ||
2072 | |||
2073 | #: src/dht/gnunet-dht-put.c:223 | 2051 | #: src/dht/gnunet-dht-put.c:223 |
2074 | msgid "the type to insert data as" | 2052 | msgid "the type to insert data as" |
2075 | msgstr "" | 2053 | msgstr "" |
@@ -2125,17 +2103,17 @@ msgstr "" | |||
2125 | msgid "Measure quality and performance of the DHT service." | 2103 | msgid "Measure quality and performance of the DHT service." |
2126 | msgstr "" | 2104 | msgstr "" |
2127 | 2105 | ||
2128 | #: src/dht/plugin_block_dht.c:328 | 2106 | #: src/dht/plugin_block_dht.c:404 |
2129 | #, fuzzy, c-format | 2107 | #, fuzzy, c-format |
2130 | msgid "Block not of type %u\n" | 2108 | msgid "Block not of type %u\n" |
2131 | msgstr "Kein Transport des Typs %d bekannt.\n" | 2109 | msgstr "Kein Transport des Typs %d bekannt.\n" |
2132 | 2110 | ||
2133 | #: src/dht/plugin_block_dht.c:337 | 2111 | #: src/dht/plugin_block_dht.c:413 |
2134 | #, c-format | 2112 | #, c-format |
2135 | msgid "Size mismatch for block with type %u\n" | 2113 | msgid "Size mismatch for block with type %u\n" |
2136 | msgstr "" | 2114 | msgstr "" |
2137 | 2115 | ||
2138 | #: src/dht/plugin_block_dht.c:348 | 2116 | #: src/dht/plugin_block_dht.c:424 |
2139 | #, c-format | 2117 | #, c-format |
2140 | msgid "Block of type %u is malformed\n" | 2118 | msgid "Block of type %u is malformed\n" |
2141 | msgstr "" | 2119 | msgstr "" |
@@ -2872,20 +2850,20 @@ msgstr "" | |||
2872 | msgid "LOC URI malformed (signature failed validation)" | 2850 | msgid "LOC URI malformed (signature failed validation)" |
2873 | msgstr "" | 2851 | msgstr "" |
2874 | 2852 | ||
2875 | #: src/fs/fs_uri.c:653 | 2853 | #: src/fs/fs_uri.c:652 |
2876 | #, fuzzy | 2854 | #, fuzzy |
2877 | msgid "invalid argument" | 2855 | msgid "invalid argument" |
2878 | msgstr "Ungültiges Argument »%s«\n" | 2856 | msgstr "Ungültiges Argument »%s«\n" |
2879 | 2857 | ||
2880 | #: src/fs/fs_uri.c:665 | 2858 | #: src/fs/fs_uri.c:671 |
2881 | msgid "Unrecognized URI type" | 2859 | msgid "Unrecognized URI type" |
2882 | msgstr "" | 2860 | msgstr "" |
2883 | 2861 | ||
2884 | #: src/fs/fs_uri.c:1071 src/fs/fs_uri.c:1098 | 2862 | #: src/fs/fs_uri.c:1075 src/fs/fs_uri.c:1102 |
2885 | msgid "No keywords specified!\n" | 2863 | msgid "No keywords specified!\n" |
2886 | msgstr "Keine Schlüsselwörter angegeben!\n" | 2864 | msgstr "Keine Schlüsselwörter angegeben!\n" |
2887 | 2865 | ||
2888 | #: src/fs/fs_uri.c:1104 | 2866 | #: src/fs/fs_uri.c:1108 |
2889 | msgid "Number of double-quotes not balanced!\n" | 2867 | msgid "Number of double-quotes not balanced!\n" |
2890 | msgstr "" | 2868 | msgstr "" |
2891 | 2869 | ||
@@ -3012,7 +2990,7 @@ msgid "Downloading `%s' done (%s/s).\n" | |||
3012 | msgstr "Dateien aus dem GNUnet herunterladen." | 2990 | msgstr "Dateien aus dem GNUnet herunterladen." |
3013 | 2991 | ||
3014 | #: src/fs/gnunet-download.c:206 src/fs/gnunet-publish.c:299 | 2992 | #: src/fs/gnunet-download.c:206 src/fs/gnunet-publish.c:299 |
3015 | #: src/fs/gnunet-search.c:229 src/fs/gnunet-unindex.c:117 | 2993 | #: src/fs/gnunet-search.c:538 src/fs/gnunet-unindex.c:117 |
3016 | #, c-format | 2994 | #, c-format |
3017 | msgid "Unexpected status: %d\n" | 2995 | msgid "Unexpected status: %d\n" |
3018 | msgstr "" | 2996 | msgstr "" |
@@ -3036,12 +3014,12 @@ msgid "Target filename must be specified.\n" | |||
3036 | msgstr "" | 3014 | msgstr "" |
3037 | 3015 | ||
3038 | #: src/fs/gnunet-download.c:271 src/fs/gnunet-publish.c:869 | 3016 | #: src/fs/gnunet-download.c:271 src/fs/gnunet-publish.c:869 |
3039 | #: src/fs/gnunet-search.c:294 src/fs/gnunet-unindex.c:154 | 3017 | #: src/fs/gnunet-unindex.c:154 |
3040 | #, fuzzy, c-format | 3018 | #, fuzzy, c-format |
3041 | msgid "Could not initialize `%s' subsystem.\n" | 3019 | msgid "Could not initialize `%s' subsystem.\n" |
3042 | msgstr "`%s' Dienst konnte nicht initialisiert werden.\n" | 3020 | msgstr "`%s' Dienst konnte nicht initialisiert werden.\n" |
3043 | 3021 | ||
3044 | #: src/fs/gnunet-download.c:318 src/fs/gnunet-search.c:334 | 3022 | #: src/fs/gnunet-download.c:318 |
3045 | msgid "set the desired LEVEL of receiver-anonymity" | 3023 | msgid "set the desired LEVEL of receiver-anonymity" |
3046 | msgstr "Den Grad LEVEL der gewünschten Empfänger-Anonymität setzen" | 3024 | msgstr "Den Grad LEVEL der gewünschten Empfänger-Anonymität setzen" |
3047 | 3025 | ||
@@ -3049,7 +3027,7 @@ msgstr "Den Grad LEVEL der gewünschten Empfänger-Anonymität setzen" | |||
3049 | msgid "delete incomplete downloads (when aborted with CTRL-C)" | 3027 | msgid "delete incomplete downloads (when aborted with CTRL-C)" |
3050 | msgstr "" | 3028 | msgstr "" |
3051 | 3029 | ||
3052 | #: src/fs/gnunet-download.c:330 src/fs/gnunet-search.c:339 | 3030 | #: src/fs/gnunet-download.c:330 src/fs/gnunet-search.c:740 |
3053 | msgid "only search the local peer (no P2P network search)" | 3031 | msgid "only search the local peer (no P2P network search)" |
3054 | msgstr "" | 3032 | msgstr "" |
3055 | 3033 | ||
@@ -3307,39 +3285,112 @@ msgstr "" | |||
3307 | msgid "Publish a file or directory on GNUnet" | 3285 | msgid "Publish a file or directory on GNUnet" |
3308 | msgstr "" | 3286 | msgstr "" |
3309 | 3287 | ||
3310 | #: src/fs/gnunet-search.c:130 | 3288 | #: src/fs/gnunet-search.c:441 |
3311 | #, c-format | 3289 | #, c-format |
3312 | msgid "Failed to write directory with search results to `%s'\n" | 3290 | msgid "Failed to write directory with search results to `%s'\n" |
3313 | msgstr "" | 3291 | msgstr "" |
3314 | 3292 | ||
3315 | #: src/fs/gnunet-search.c:219 | 3293 | #: src/fs/gnunet-search.c:527 |
3316 | #, fuzzy, c-format | 3294 | #, fuzzy, c-format |
3317 | msgid "Error searching: %s.\n" | 3295 | msgid "Error searching: %s.\n" |
3318 | msgstr "Fehler beim Verlassen der DHT.\n" | 3296 | msgstr "Fehler beim Verlassen der DHT.\n" |
3319 | 3297 | ||
3320 | #: src/fs/gnunet-search.c:281 | 3298 | #: src/fs/gnunet-search.c:587 |
3299 | #, c-format | ||
3300 | msgid "Conflicting options --bookmark-only and --silent.\n" | ||
3301 | msgstr "" | ||
3302 | |||
3303 | #: src/fs/gnunet-search.c:594 | ||
3304 | #, c-format | ||
3305 | msgid "Conflicting options --bookmark-only and --output.\n" | ||
3306 | msgstr "" | ||
3307 | |||
3308 | #: src/fs/gnunet-search.c:600 | ||
3309 | #, c-format | ||
3310 | msgid "An output file is mandatory for silent mode.\n" | ||
3311 | msgstr "" | ||
3312 | |||
3313 | #: src/fs/gnunet-search.c:621 | ||
3321 | msgid "Could not create keyword URI from arguments.\n" | 3314 | msgid "Could not create keyword URI from arguments.\n" |
3322 | msgstr "" | 3315 | msgstr "" |
3323 | 3316 | ||
3324 | #: src/fs/gnunet-search.c:308 | 3317 | #: src/fs/gnunet-search.c:629 |
3318 | msgid "" | ||
3319 | "Invalid URI. Valid URIs for searching are keyword query URIs\n" | ||
3320 | "(\"gnunet://fs/ksk/...\") and namespace content URIs (\"gnunet://fs/sks/..." | ||
3321 | "\").\n" | ||
3322 | msgstr "" | ||
3323 | |||
3324 | #: src/fs/gnunet-search.c:654 | ||
3325 | #, fuzzy, c-format | ||
3326 | msgid "Could not initialize the `%s` subsystem.\n" | ||
3327 | msgstr "`%s' Dienst konnte nicht initialisiert werden.\n" | ||
3328 | |||
3329 | #: src/fs/gnunet-search.c:668 | ||
3325 | #, fuzzy | 3330 | #, fuzzy |
3326 | msgid "Could not start searching.\n" | 3331 | msgid "Could not start searching.\n" |
3327 | msgstr "Fehler beim Starten der Collection.\n" | 3332 | msgstr "Fehler beim Starten der Collection.\n" |
3328 | 3333 | ||
3329 | #: src/fs/gnunet-search.c:345 | 3334 | #: src/fs/gnunet-search.c:694 |
3330 | msgid "write search results to file starting with PREFIX" | 3335 | #, fuzzy |
3336 | msgid "set the desired LEVEL of receiver-anonymity (default: 1)" | ||
3337 | msgstr "Den Grad LEVEL der gewünschten Empfänger-Anonymität setzen" | ||
3338 | |||
3339 | #: src/fs/gnunet-search.c:700 | ||
3340 | msgid "do not search, print only the URI that points to this search" | ||
3331 | msgstr "" | 3341 | msgstr "" |
3332 | 3342 | ||
3333 | #: src/fs/gnunet-search.c:351 | 3343 | #: src/fs/gnunet-search.c:707 |
3334 | msgid "automatically terminate search after DELAY" | 3344 | msgid "" |
3345 | "write search results for directories according to FORMAT; accepted " | ||
3346 | "placeholders are: %a, %f, %j, %l, %m, %n, %s; defaults to the value of --" | ||
3347 | "printf when omitted or to `" | ||
3335 | msgstr "" | 3348 | msgstr "" |
3336 | 3349 | ||
3337 | #: src/fs/gnunet-search.c:357 | 3350 | #: src/fs/gnunet-search.c:717 |
3351 | msgid "" | ||
3352 | "write search results according to FORMAT; accepted placeholders are: %a, %f, " | ||
3353 | "%j, %l, %m, %n, %s; defaults to `" | ||
3354 | msgstr "" | ||
3355 | |||
3356 | #: src/fs/gnunet-search.c:725 | ||
3357 | msgid "" | ||
3358 | "when the %a or %j placeholders appear in --printf or --dir-printf, list each " | ||
3359 | "metadata property according to FORMAT; accepted placeholders are: %i, %l, " | ||
3360 | "%n, %p" | ||
3361 | msgstr "" | ||
3362 | |||
3363 | #: src/fs/gnunet-search.c:734 | ||
3338 | msgid "automatically terminate search after VALUE results are found" | 3364 | msgid "automatically terminate search after VALUE results are found" |
3339 | msgstr "" | 3365 | msgstr "" |
3340 | 3366 | ||
3341 | #: src/fs/gnunet-search.c:371 | 3367 | #: src/fs/gnunet-search.c:746 |
3342 | msgid "Search GNUnet for files that were published on GNUnet" | 3368 | msgid "" |
3369 | "create a GNUnet directory with search results at FILENAME (e.g. `gnunet-" | ||
3370 | "search --output=commons" | ||
3371 | msgstr "" | ||
3372 | |||
3373 | #: src/fs/gnunet-search.c:753 | ||
3374 | msgid "silent mode (requires the --output argument)" | ||
3375 | msgstr "" | ||
3376 | |||
3377 | #: src/fs/gnunet-search.c:759 | ||
3378 | msgid "" | ||
3379 | "automatically terminate search after DELAY; the value given must be a number " | ||
3380 | "followed by a space and a time unit, for example \"500 ms\"; without a unit " | ||
3381 | "it defaults to microseconds - 1000000 = 1 second; if 0 or omitted it means " | ||
3382 | "to wait for CTRL-C" | ||
3383 | msgstr "" | ||
3384 | |||
3385 | #: src/fs/gnunet-search.c:768 | ||
3386 | #, c-format | ||
3387 | msgid "" | ||
3388 | "be verbose (append \"%a\\n\" to the default --printf and --dir-printf " | ||
3389 | "arguments - ignored when these are provided by the user)" | ||
3390 | msgstr "" | ||
3391 | |||
3392 | #: src/fs/gnunet-search.c:781 | ||
3393 | msgid "Search for files that have been published on GNUnet\n" | ||
3343 | msgstr "" | 3394 | msgstr "" |
3344 | 3395 | ||
3345 | #: src/fs/gnunet-service-fs.c:371 src/fs/gnunet-service-fs.c:878 | 3396 | #: src/fs/gnunet-service-fs.c:371 src/fs/gnunet-service-fs.c:878 |
@@ -3691,67 +3742,72 @@ msgstr "" | |||
3691 | msgid "Expected a base32-encoded public zone key\n" | 3742 | msgid "Expected a base32-encoded public zone key\n" |
3692 | msgstr "" | 3743 | msgstr "" |
3693 | 3744 | ||
3694 | #: src/gns/gnunet-bcd.c:571 | 3745 | #: src/gns/gnunet-bcd.c:573 |
3695 | #, fuzzy, c-format | 3746 | #, fuzzy, c-format |
3696 | msgid "Invalid port number %u\n" | 3747 | msgid "Invalid port number %u\n" |
3697 | msgstr "Ungültige Parameter. Abbruch.\n" | 3748 | msgstr "Ungültige Parameter. Abbruch.\n" |
3698 | 3749 | ||
3699 | #: src/gns/gnunet-bcd.c:612 src/namestore/gnunet-namestore-fcfsd.c:1113 | 3750 | #: src/gns/gnunet-bcd.c:614 src/namestore/gnunet-namestore-fcfsd.c:1113 |
3700 | #, fuzzy | 3751 | #, fuzzy |
3701 | msgid "Unable to set up the daemon\n" | 3752 | msgid "Unable to set up the daemon\n" |
3702 | msgstr "Zustellung der Nachricht `%s' fehlgeschlagen.\n" | 3753 | msgstr "Zustellung der Nachricht `%s' fehlgeschlagen.\n" |
3703 | 3754 | ||
3704 | #: src/gns/gnunet-bcd.c:635 src/namestore/gnunet-namestore-fcfsd.c:987 | 3755 | #: src/gns/gnunet-bcd.c:637 src/namestore/gnunet-namestore-fcfsd.c:987 |
3705 | #, fuzzy | 3756 | #, fuzzy |
3706 | msgid "Failed to start HTTP server\n" | 3757 | msgid "Failed to start HTTP server\n" |
3707 | msgstr "Fehler beim Senden einer `%s' Anfrage an den SMTP Server.\n" | 3758 | msgstr "Fehler beim Senden einer `%s' Anfrage an den SMTP Server.\n" |
3708 | 3759 | ||
3709 | #: src/gns/gnunet-bcd.c:658 | 3760 | #: src/gns/gnunet-bcd.c:660 |
3710 | msgid "Run HTTP server on port PORT (default is 8888)" | 3761 | msgid "Run HTTP server on port PORT (default is 8888)" |
3711 | msgstr "" | 3762 | msgstr "" |
3712 | 3763 | ||
3713 | #: src/gns/gnunet-bcd.c:667 | 3764 | #: src/gns/gnunet-bcd.c:669 |
3714 | msgid "GNUnet HTTP server to create business cards" | 3765 | msgid "GNUnet HTTP server to create business cards" |
3715 | msgstr "" | 3766 | msgstr "" |
3716 | 3767 | ||
3717 | #: src/gns/gnunet-dns2gns.c:241 | 3768 | #: src/gns/gnunet-dns2gns.c:298 |
3718 | msgid "Failed to pack DNS response into UDP packet!\n" | 3769 | msgid "Failed to pack DNS response into UDP packet!\n" |
3719 | msgstr "" | 3770 | msgstr "" |
3720 | 3771 | ||
3721 | #: src/gns/gnunet-dns2gns.c:315 | 3772 | #: src/gns/gnunet-dns2gns.c:379 |
3722 | #, fuzzy | 3773 | #, fuzzy |
3723 | msgid "Failed to parse DNS response!\n" | 3774 | msgid "Failed to parse DNS response!\n" |
3724 | msgstr "Zustellung der Nachricht `%s' fehlgeschlagen.\n" | 3775 | msgstr "Zustellung der Nachricht `%s' fehlgeschlagen.\n" |
3725 | 3776 | ||
3726 | #: src/gns/gnunet-dns2gns.c:452 | 3777 | #: src/gns/gnunet-dns2gns.c:453 |
3778 | #, c-format | ||
3779 | msgid "VPN returned empty result for `%s'\n" | ||
3780 | msgstr "" | ||
3781 | |||
3782 | #: src/gns/gnunet-dns2gns.c:655 | ||
3727 | #, c-format | 3783 | #, c-format |
3728 | msgid "Cannot parse DNS request from %s\n" | 3784 | msgid "Cannot parse DNS request from %s\n" |
3729 | msgstr "" | 3785 | msgstr "" |
3730 | 3786 | ||
3731 | #: src/gns/gnunet-dns2gns.c:468 | 3787 | #: src/gns/gnunet-dns2gns.c:671 |
3732 | #, fuzzy, c-format | 3788 | #, fuzzy, c-format |
3733 | msgid "Received malformed DNS request from %s\n" | 3789 | msgid "Received malformed DNS request from %s\n" |
3734 | msgstr "Beschädigte Antwort auf `%s' von Knoten `%s' empfangen.\n" | 3790 | msgstr "Beschädigte Antwort auf `%s' von Knoten `%s' empfangen.\n" |
3735 | 3791 | ||
3736 | #: src/gns/gnunet-dns2gns.c:476 | 3792 | #: src/gns/gnunet-dns2gns.c:679 |
3737 | #, fuzzy, c-format | 3793 | #, fuzzy, c-format |
3738 | msgid "Received unsupported DNS request from %s\n" | 3794 | msgid "Received unsupported DNS request from %s\n" |
3739 | msgstr "Unbekannte Anfrageart %d empfangen bei %s:%d\n" | 3795 | msgstr "Unbekannte Anfrageart %d empfangen bei %s:%d\n" |
3740 | 3796 | ||
3741 | #: src/gns/gnunet-dns2gns.c:637 | 3797 | #: src/gns/gnunet-dns2gns.c:840 |
3742 | #, fuzzy | 3798 | #, fuzzy |
3743 | msgid "No DNS server specified!\n" | 3799 | msgid "No DNS server specified!\n" |
3744 | msgstr "Keine Schlüsselwörter angegeben!\n" | 3800 | msgstr "Keine Schlüsselwörter angegeben!\n" |
3745 | 3801 | ||
3746 | #: src/gns/gnunet-dns2gns.c:786 | 3802 | #: src/gns/gnunet-dns2gns.c:995 |
3747 | msgid "IP of recursive DNS resolver to use (required)" | 3803 | msgid "IP of recursive DNS resolver to use (required)" |
3748 | msgstr "" | 3804 | msgstr "" |
3749 | 3805 | ||
3750 | #: src/gns/gnunet-dns2gns.c:792 | 3806 | #: src/gns/gnunet-dns2gns.c:1001 |
3751 | msgid "UDP port to listen on for inbound DNS requests; default: 2853" | 3807 | msgid "UDP port to listen on for inbound DNS requests; default: 2853" |
3752 | msgstr "" | 3808 | msgstr "" |
3753 | 3809 | ||
3754 | #: src/gns/gnunet-dns2gns.c:809 | 3810 | #: src/gns/gnunet-dns2gns.c:1018 |
3755 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" | 3811 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" |
3756 | msgstr "" | 3812 | msgstr "" |
3757 | 3813 | ||
@@ -3933,19 +3989,19 @@ msgstr "" | |||
3933 | msgid "GNUnet GNS resolver tool" | 3989 | msgid "GNUnet GNS resolver tool" |
3934 | msgstr "GNUnet Netzwerk Topologie tracen." | 3990 | msgstr "GNUnet Netzwerk Topologie tracen." |
3935 | 3991 | ||
3936 | #: src/gns/gnunet-service-gns.c:505 | 3992 | #: src/gns/gnunet-service-gns.c:501 |
3937 | #, fuzzy | 3993 | #, fuzzy |
3938 | msgid "Properly base32-encoded public key required" | 3994 | msgid "Properly base32-encoded public key required" |
3939 | msgstr "# Bytes empfangen über TCP" | 3995 | msgstr "# Bytes empfangen über TCP" |
3940 | 3996 | ||
3941 | #: src/gns/gnunet-service-gns.c:541 | 3997 | #: src/gns/gnunet-service-gns.c:537 |
3942 | #, fuzzy | 3998 | #, fuzzy |
3943 | msgid "Failed to connect to the namecache!\n" | 3999 | msgid "Failed to connect to the namecache!\n" |
3944 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" | 4000 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" |
3945 | 4001 | ||
3946 | #: src/gns/gnunet-service-gns.c:560 | 4002 | #: src/gns/gnunet-service-gns.c:556 |
3947 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:442 | 4003 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:421 |
3948 | #: src/zonemaster/gnunet-service-zonemaster.c:885 | 4004 | #: src/zonemaster/gnunet-service-zonemaster.c:870 |
3949 | #, fuzzy | 4005 | #, fuzzy |
3950 | msgid "Could not connect to DHT!\n" | 4006 | msgid "Could not connect to DHT!\n" |
3951 | msgstr "Verbindung zu gnunetd konnte nicht hergestellt werden.\n" | 4007 | msgstr "Verbindung zu gnunetd konnte nicht hergestellt werden.\n" |
@@ -3960,95 +4016,98 @@ msgstr "Fehler beim Konvertieren von Parametern in URI!\n" | |||
3960 | msgid "Failed to connect to the DNS service!\n" | 4016 | msgid "Failed to connect to the DNS service!\n" |
3961 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" | 4017 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" |
3962 | 4018 | ||
3963 | #: src/gns/gnunet-service-gns_resolver.c:706 | 4019 | #: src/gns/gnunet-service-gns_resolver.c:659 |
3964 | #, c-format | 4020 | #, c-format |
3965 | msgid "Protocol `%s' unknown, skipping labels.\n" | 4021 | msgid "Protocol `%s' unknown, skipping labels.\n" |
3966 | msgstr "" | 4022 | msgstr "" |
3967 | 4023 | ||
3968 | #: src/gns/gnunet-service-gns_resolver.c:718 | 4024 | #: src/gns/gnunet-service-gns_resolver.c:671 |
3969 | #, c-format | 4025 | #, c-format |
3970 | msgid "Service `%s' unknown for protocol `%s', trying as number.\n" | 4026 | msgid "Service `%s' unknown for protocol `%s', trying as number.\n" |
3971 | msgstr "" | 4027 | msgstr "" |
3972 | 4028 | ||
3973 | #: src/gns/gnunet-service-gns_resolver.c:724 | 4029 | #: src/gns/gnunet-service-gns_resolver.c:677 |
3974 | #, fuzzy, c-format | 4030 | #, fuzzy, c-format |
3975 | msgid "Service `%s' not a port, skipping service labels.\n" | 4031 | msgid "Service `%s' not a port, skipping service labels.\n" |
3976 | msgstr "Kommando `%s' wurde nicht gefunden!\n" | 4032 | msgstr "Kommando `%s' wurde nicht gefunden!\n" |
3977 | 4033 | ||
3978 | #: src/gns/gnunet-service-gns_resolver.c:938 | 4034 | #: src/gns/gnunet-service-gns_resolver.c:891 |
3979 | #, fuzzy | 4035 | #, fuzzy |
3980 | msgid "Failed to parse DNS response\n" | 4036 | msgid "Failed to parse DNS response\n" |
3981 | msgstr "Zustellung der Nachricht `%s' fehlgeschlagen.\n" | 4037 | msgstr "Zustellung der Nachricht `%s' fehlgeschlagen.\n" |
3982 | 4038 | ||
3983 | #: src/gns/gnunet-service-gns_resolver.c:1129 | 4039 | #: src/gns/gnunet-service-gns_resolver.c:1082 |
3984 | #, c-format | 4040 | #, c-format |
3985 | msgid "Skipping record of unsupported type %d\n" | 4041 | msgid "Skipping record of unsupported type %d\n" |
3986 | msgstr "" | 4042 | msgstr "" |
3987 | 4043 | ||
3988 | #: src/gns/gnunet-service-gns_resolver.c:1447 | 4044 | #: src/gns/gnunet-service-gns_resolver.c:1859 |
3989 | #, c-format | ||
3990 | msgid "VPN returned empty result for `%s'\n" | ||
3991 | msgstr "" | ||
3992 | |||
3993 | #: src/gns/gnunet-service-gns_resolver.c:1919 | ||
3994 | #, c-format | 4045 | #, c-format |
3995 | msgid "Name `%s' cannot be converted to IDNA." | 4046 | msgid "Name `%s' cannot be converted to IDNA." |
3996 | msgstr "" | 4047 | msgstr "" |
3997 | 4048 | ||
3998 | #: src/gns/gnunet-service-gns_resolver.c:1934 | 4049 | #: src/gns/gnunet-service-gns_resolver.c:1874 |
3999 | #, c-format | 4050 | #, c-format |
4000 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" | 4051 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" |
4001 | msgstr "" | 4052 | msgstr "" |
4002 | 4053 | ||
4003 | #: src/gns/gnunet-service-gns_resolver.c:1979 | 4054 | #: src/gns/gnunet-service-gns_resolver.c:1914 |
4004 | #, fuzzy, c-format | 4055 | #, fuzzy, c-format |
4005 | msgid "GNS lookup failed (zero records found for `%s')\n" | 4056 | msgid "GNS lookup failed (zero records found for `%s')\n" |
4006 | msgstr "Dienst `%s' konnte nicht ordentlich entladen werden!\n" | 4057 | msgstr "Dienst `%s' konnte nicht ordentlich entladen werden!\n" |
4007 | 4058 | ||
4008 | #: src/gns/gnunet-service-gns_resolver.c:2406 | 4059 | #: src/gns/gnunet-service-gns_resolver.c:2312 |
4060 | msgid "Unable to process critical delegation record\n" | ||
4061 | msgstr "" | ||
4062 | |||
4063 | #: src/gns/gnunet-service-gns_resolver.c:2317 | ||
4009 | msgid "GNS lookup recursion failed (no delegation record found)\n" | 4064 | msgid "GNS lookup recursion failed (no delegation record found)\n" |
4010 | msgstr "" | 4065 | msgstr "" |
4011 | 4066 | ||
4012 | #: src/gns/gnunet-service-gns_resolver.c:2429 | 4067 | #: src/gns/gnunet-service-gns_resolver.c:2340 |
4013 | #, fuzzy, c-format | 4068 | #, fuzzy, c-format |
4014 | msgid "Failed to cache GNS resolution: %s\n" | 4069 | msgid "Failed to cache GNS resolution: %s\n" |
4015 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" | 4070 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" |
4016 | 4071 | ||
4017 | #: src/gns/gnunet-service-gns_resolver.c:2594 | 4072 | #: src/gns/gnunet-service-gns_resolver.c:2505 |
4018 | #, c-format | 4073 | #, c-format |
4019 | msgid "GNS namecache returned empty result for `%s'\n" | 4074 | msgid "GNS namecache returned empty result for `%s'\n" |
4020 | msgstr "" | 4075 | msgstr "" |
4021 | 4076 | ||
4022 | #: src/gns/gnunet-service-gns_resolver.c:2734 | 4077 | #: src/gns/gnunet-service-gns_resolver.c:2652 |
4023 | #, c-format | 4078 | #, c-format |
4024 | msgid "Zone %s was revoked, resolution fails\n" | 4079 | msgid "Zone %s was revoked, resolution fails\n" |
4025 | msgstr "" | 4080 | msgstr "" |
4026 | 4081 | ||
4027 | #: src/gns/plugin_gnsrecord_gns.c:174 | 4082 | #: src/gns/plugin_gnsrecord_gns.c:136 |
4083 | msgid "This is a memento of an older block for internal maintenance." | ||
4084 | msgstr "" | ||
4085 | |||
4086 | #: src/gns/plugin_gnsrecord_gns.c:175 | ||
4028 | #, fuzzy, c-format | 4087 | #, fuzzy, c-format |
4029 | msgid "Unable to parse zone key record `%s'\n" | 4088 | msgid "Unable to parse zone key record `%s'\n" |
4030 | msgstr "Dateiformat fehlerhaft (kein GNUnet Verzeichnis?)\n" | 4089 | msgstr "Dateiformat fehlerhaft (kein GNUnet Verzeichnis?)\n" |
4031 | 4090 | ||
4032 | #: src/gns/plugin_gnsrecord_gns.c:187 | 4091 | #: src/gns/plugin_gnsrecord_gns.c:188 |
4033 | msgid "Record type does not match parsed record type\n" | 4092 | msgid "Record type does not match parsed record type\n" |
4034 | msgstr "" | 4093 | msgstr "" |
4035 | 4094 | ||
4036 | #: src/gns/plugin_gnsrecord_gns.c:213 | 4095 | #: src/gns/plugin_gnsrecord_gns.c:211 |
4037 | #, fuzzy, c-format | 4096 | #, fuzzy, c-format |
4038 | msgid "Unable to parse GNS2DNS record `%s'\n" | 4097 | msgid "Unable to parse GNS2DNS record `%s'\n" |
4039 | msgstr "Dateiformat fehlerhaft (kein GNUnet Verzeichnis?)\n" | 4098 | msgstr "Dateiformat fehlerhaft (kein GNUnet Verzeichnis?)\n" |
4040 | 4099 | ||
4041 | #: src/gns/plugin_gnsrecord_gns.c:229 | 4100 | #: src/gns/plugin_gnsrecord_gns.c:227 |
4042 | #, fuzzy, c-format | 4101 | #, fuzzy, c-format |
4043 | msgid "Failed to serialize GNS2DNS record with value `%s': Not a DNS name.\n" | 4102 | msgid "Failed to serialize GNS2DNS record with value `%s': Not a DNS name.\n" |
4044 | msgstr "Fehler beim Lesen der Freunde-Liste von `%s'\n" | 4103 | msgstr "Fehler beim Lesen der Freunde-Liste von `%s'\n" |
4045 | 4104 | ||
4046 | #: src/gns/plugin_gnsrecord_gns.c:253 | 4105 | #: src/gns/plugin_gnsrecord_gns.c:251 |
4047 | #, fuzzy, c-format | 4106 | #, fuzzy, c-format |
4048 | msgid "Unable to parse VPN record string `%s'\n" | 4107 | msgid "Unable to parse VPN record string `%s'\n" |
4049 | msgstr "Fehler beim Speichern der Konfigurationsdatei `%s':" | 4108 | msgstr "Fehler beim Speichern der Konfigurationsdatei `%s':" |
4050 | 4109 | ||
4051 | #: src/gns/plugin_gnsrecord_gns.c:285 | 4110 | #: src/gns/plugin_gnsrecord_gns.c:283 |
4052 | #, fuzzy, c-format | 4111 | #, fuzzy, c-format |
4053 | msgid "Unable to parse BOX record string `%s'\n" | 4112 | msgid "Unable to parse BOX record string `%s'\n" |
4054 | msgstr "Fehler beim Speichern der Konfigurationsdatei `%s':" | 4113 | msgstr "Fehler beim Speichern der Konfigurationsdatei `%s':" |
@@ -4058,6 +4117,34 @@ msgstr "Fehler beim Speichern der Konfigurationsdatei `%s':" | |||
4058 | msgid "Gns REST API initialized\n" | 4117 | msgid "Gns REST API initialized\n" |
4059 | msgstr " Verbindung fehlgeschlagen\n" | 4118 | msgstr " Verbindung fehlgeschlagen\n" |
4060 | 4119 | ||
4120 | #: src/gnsrecord/gnsrecord_misc.c:448 | ||
4121 | msgid "Zone delegation record not allowed in apex." | ||
4122 | msgstr "" | ||
4123 | |||
4124 | #: src/gnsrecord/gnsrecord_misc.c:456 | ||
4125 | msgid "Zone delegation record set contains mutually exclusive records." | ||
4126 | msgstr "" | ||
4127 | |||
4128 | #: src/gnsrecord/gnsrecord_misc.c:466 | ||
4129 | msgid "Multiple REDIRECT records." | ||
4130 | msgstr "" | ||
4131 | |||
4132 | #: src/gnsrecord/gnsrecord_misc.c:475 src/gnsrecord/gnsrecord_misc.c:501 | ||
4133 | msgid "Redirection record set conains mutually exclusive records." | ||
4134 | msgstr "" | ||
4135 | |||
4136 | #: src/gnsrecord/gnsrecord_misc.c:482 | ||
4137 | msgid "Redirection records not allowed in apex." | ||
4138 | msgstr "" | ||
4139 | |||
4140 | #: src/gnsrecord/gnsrecord_misc.c:493 | ||
4141 | msgid "Redirection records not allowed in apex.." | ||
4142 | msgstr "" | ||
4143 | |||
4144 | #: src/gnsrecord/gnsrecord_misc.c:515 | ||
4145 | msgid "Mutually exclusive records." | ||
4146 | msgstr "" | ||
4147 | |||
4061 | #: src/gnsrecord/plugin_gnsrecord_dns.c:367 | 4148 | #: src/gnsrecord/plugin_gnsrecord_dns.c:367 |
4062 | #, c-format | 4149 | #, c-format |
4063 | msgid "Unable to parse IPv4 address `%s'\n" | 4150 | msgid "Unable to parse IPv4 address `%s'\n" |
@@ -4303,7 +4390,7 @@ msgid "# hostlist downloads initiated" | |||
4303 | msgstr "" | 4390 | msgstr "" |
4304 | 4391 | ||
4305 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1144 | 4392 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1144 |
4306 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1728 | 4393 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1732 |
4307 | msgid "# milliseconds between hostlist downloads" | 4394 | msgid "# milliseconds between hostlist downloads" |
4308 | msgstr "" | 4395 | msgstr "" |
4309 | 4396 | ||
@@ -4364,21 +4451,21 @@ msgstr "" | |||
4364 | msgid "# hostlist URIs written to file" | 4451 | msgid "# hostlist URIs written to file" |
4365 | msgstr "" | 4452 | msgstr "" |
4366 | 4453 | ||
4367 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1657 | 4454 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1661 |
4368 | #: src/transport/plugin_transport_http_client.c:2300 | 4455 | #: src/transport/plugin_transport_http_client.c:2300 |
4369 | #, c-format | 4456 | #, c-format |
4370 | msgid "Invalid proxy type: `%s', disabling proxy! Check configuration!\n" | 4457 | msgid "Invalid proxy type: `%s', disabling proxy! Check configuration!\n" |
4371 | msgstr "" | 4458 | msgstr "" |
4372 | 4459 | ||
4373 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1686 | 4460 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1690 |
4374 | msgid "Learning is enabled on this peer\n" | 4461 | msgid "Learning is enabled on this peer\n" |
4375 | msgstr "" | 4462 | msgstr "" |
4376 | 4463 | ||
4377 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1699 | 4464 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1703 |
4378 | msgid "Learning is not enabled on this peer\n" | 4465 | msgid "Learning is not enabled on this peer\n" |
4379 | msgstr "" | 4466 | msgstr "" |
4380 | 4467 | ||
4381 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1713 | 4468 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1717 |
4382 | #, c-format | 4469 | #, c-format |
4383 | msgid "" | 4470 | msgid "" |
4384 | "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" | 4471 | "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" |
@@ -4570,49 +4657,49 @@ msgstr "" | |||
4570 | msgid "Maintain egos" | 4657 | msgid "Maintain egos" |
4571 | msgstr "" | 4658 | msgstr "" |
4572 | 4659 | ||
4573 | #: src/identity/gnunet-service-identity.c:503 | 4660 | #: src/identity/gnunet-service-identity.c:502 |
4574 | msgid "no default known" | 4661 | msgid "no default known" |
4575 | msgstr "" | 4662 | msgstr "" |
4576 | 4663 | ||
4577 | #: src/identity/gnunet-service-identity.c:528 | 4664 | #: src/identity/gnunet-service-identity.c:527 |
4578 | msgid "default configured, but ego unknown (internal error)" | 4665 | msgid "default configured, but ego unknown (internal error)" |
4579 | msgstr "" | 4666 | msgstr "" |
4580 | 4667 | ||
4581 | #: src/identity/gnunet-service-identity.c:621 | 4668 | #: src/identity/gnunet-service-identity.c:620 |
4582 | #: src/identity/gnunet-service-identity.c:896 | 4669 | #: src/identity/gnunet-service-identity.c:895 |
4583 | #: src/identity/gnunet-service-identity.c:1016 | 4670 | #: src/identity/gnunet-service-identity.c:1015 |
4584 | #, fuzzy, c-format | 4671 | #, fuzzy, c-format |
4585 | msgid "Failed to write subsystem default identifier map to `%s'.\n" | 4672 | msgid "Failed to write subsystem default identifier map to `%s'.\n" |
4586 | msgstr "Fehler beim Aktualisieren der Daten des Moduls `%s'\n" | 4673 | msgstr "Fehler beim Aktualisieren der Daten des Moduls `%s'\n" |
4587 | 4674 | ||
4588 | #: src/identity/gnunet-service-identity.c:631 | 4675 | #: src/identity/gnunet-service-identity.c:630 |
4589 | msgid "Unknown ego specified for service (internal error)" | 4676 | msgid "Unknown ego specified for service (internal error)" |
4590 | msgstr "" | 4677 | msgstr "" |
4591 | 4678 | ||
4592 | #: src/identity/gnunet-service-identity.c:725 | 4679 | #: src/identity/gnunet-service-identity.c:724 |
4593 | msgid "identifier already in use for another ego" | 4680 | msgid "identifier already in use for another ego" |
4594 | msgstr "" | 4681 | msgstr "" |
4595 | 4682 | ||
4596 | #: src/identity/gnunet-service-identity.c:872 | 4683 | #: src/identity/gnunet-service-identity.c:871 |
4597 | msgid "target name already exists" | 4684 | msgid "target name already exists" |
4598 | msgstr "" | 4685 | msgstr "" |
4599 | 4686 | ||
4600 | #: src/identity/gnunet-service-identity.c:914 | 4687 | #: src/identity/gnunet-service-identity.c:913 |
4601 | #: src/identity/gnunet-service-identity.c:1033 | 4688 | #: src/identity/gnunet-service-identity.c:1032 |
4602 | msgid "no matching ego found" | 4689 | msgid "no matching ego found" |
4603 | msgstr "" | 4690 | msgstr "" |
4604 | 4691 | ||
4605 | #: src/identity/gnunet-service-identity.c:1131 | 4692 | #: src/identity/gnunet-service-identity.c:1130 |
4606 | #, fuzzy, c-format | 4693 | #, fuzzy, c-format |
4607 | msgid "Failed to parse ego information in `%s'\n" | 4694 | msgid "Failed to parse ego information in `%s'\n" |
4608 | msgstr "Fehler beim Parsen der Gerätedaten von `%s' bei %s:%d.\n" | 4695 | msgstr "Fehler beim Parsen der Gerätedaten von `%s' bei %s:%d.\n" |
4609 | 4696 | ||
4610 | #: src/identity/gnunet-service-identity.c:1189 | 4697 | #: src/identity/gnunet-service-identity.c:1188 |
4611 | #, fuzzy, c-format | 4698 | #, fuzzy, c-format |
4612 | msgid "Failed to parse subsystem identity configuration file `%s'\n" | 4699 | msgid "Failed to parse subsystem identity configuration file `%s'\n" |
4613 | msgstr "Fehler beim Speichern der Konfigurationsdatei `%s':" | 4700 | msgstr "Fehler beim Speichern der Konfigurationsdatei `%s':" |
4614 | 4701 | ||
4615 | #: src/identity/gnunet-service-identity.c:1198 | 4702 | #: src/identity/gnunet-service-identity.c:1197 |
4616 | #, fuzzy, c-format | 4703 | #, fuzzy, c-format |
4617 | msgid "Failed to create directory `%s' for storing egos\n" | 4704 | msgid "Failed to create directory `%s' for storing egos\n" |
4618 | msgstr "Dateiformat fehlerhaft (kein GNUnet Verzeichnis?)\n" | 4705 | msgstr "Dateiformat fehlerhaft (kein GNUnet Verzeichnis?)\n" |
@@ -4652,7 +4739,7 @@ msgstr "`%s' konnte nicht aufgelöst werden: %s\n" | |||
4652 | msgid "No records found for `%s'" | 4739 | msgid "No records found for `%s'" |
4653 | msgstr "Dienst `%s' konnte nicht ordentlich entladen werden!\n" | 4740 | msgstr "Dienst `%s' konnte nicht ordentlich entladen werden!\n" |
4654 | 4741 | ||
4655 | #: src/namecache/gnunet-namecache.c:119 src/namestore/gnunet-namestore.c:459 | 4742 | #: src/namecache/gnunet-namecache.c:119 src/namestore/gnunet-namestore.c:469 |
4656 | #, c-format | 4743 | #, c-format |
4657 | msgid "\tCorrupt or unsupported record of type %u\n" | 4744 | msgid "\tCorrupt or unsupported record of type %u\n" |
4658 | msgstr "" | 4745 | msgstr "" |
@@ -4672,7 +4759,7 @@ msgstr "Ungültiger Parameter: `%s'\n" | |||
4672 | msgid "You must specify a name\n" | 4759 | msgid "You must specify a name\n" |
4673 | msgstr "Sie müssen einen Empfänger angeben!\n" | 4760 | msgstr "Sie müssen einen Empfänger angeben!\n" |
4674 | 4761 | ||
4675 | #: src/namecache/gnunet-namecache.c:214 src/namestore/gnunet-namestore.c:1641 | 4762 | #: src/namecache/gnunet-namecache.c:214 src/namestore/gnunet-namestore.c:1591 |
4676 | msgid "name of the record to add/delete/display" | 4763 | msgid "name of the record to add/delete/display" |
4677 | msgstr "" | 4764 | msgstr "" |
4678 | 4765 | ||
@@ -4681,7 +4768,7 @@ msgstr "" | |||
4681 | msgid "specifies the public key of the zone to look in" | 4768 | msgid "specifies the public key of the zone to look in" |
4682 | msgstr "Die Priorität des Inhalts angeben" | 4769 | msgstr "Die Priorität des Inhalts angeben" |
4683 | 4770 | ||
4684 | #: src/namecache/gnunet-namecache.c:233 src/namestore/gnunet-namestore.c:1702 | 4771 | #: src/namecache/gnunet-namecache.c:233 src/namestore/gnunet-namestore.c:1652 |
4685 | #, fuzzy | 4772 | #, fuzzy |
4686 | msgid "GNUnet zone manipulation tool" | 4773 | msgid "GNUnet zone manipulation tool" |
4687 | msgstr "GNUnet Konfiguration" | 4774 | msgstr "GNUnet Konfiguration" |
@@ -4829,140 +4916,113 @@ msgstr "" | |||
4829 | msgid "GNU Name System First-Come-First-Served name registration service" | 4916 | msgid "GNU Name System First-Come-First-Served name registration service" |
4830 | msgstr "" | 4917 | msgstr "" |
4831 | 4918 | ||
4832 | #: src/namestore/gnunet-namestore.c:334 | 4919 | #: src/namestore/gnunet-namestore.c:340 |
4833 | #, c-format | 4920 | #, c-format |
4834 | msgid "Adding record failed: %s\n" | 4921 | msgid "Adding record failed: %s\n" |
4835 | msgstr "" | 4922 | msgstr "" |
4836 | 4923 | ||
4837 | #: src/namestore/gnunet-namestore.c:362 | 4924 | #: src/namestore/gnunet-namestore.c:368 |
4838 | #, c-format | 4925 | #, c-format |
4839 | msgid "Deleting record failed, record does not exist%s%s\n" | 4926 | msgid "Deleting record failed, record does not exist%s%s\n" |
4840 | msgstr "" | 4927 | msgstr "" |
4841 | 4928 | ||
4842 | #: src/namestore/gnunet-namestore.c:369 | 4929 | #: src/namestore/gnunet-namestore.c:375 |
4843 | #, c-format | 4930 | #, c-format |
4844 | msgid "Deleting record failed%s%s\n" | 4931 | msgid "Deleting record failed%s%s\n" |
4845 | msgstr "" | 4932 | msgstr "" |
4846 | 4933 | ||
4847 | #: src/namestore/gnunet-namestore.c:656 | ||
4848 | #, c-format | ||
4849 | msgid "A %s record exists already under `%s', no other records can be added.\n" | ||
4850 | msgstr "" | ||
4851 | |||
4852 | #: src/namestore/gnunet-namestore.c:668 | 4934 | #: src/namestore/gnunet-namestore.c:668 |
4853 | #, c-format | 4935 | #, c-format |
4854 | msgid "" | 4936 | msgid "" |
4855 | "A zone key record exists already under `%s', no other records can be added.\n" | ||
4856 | msgstr "" | ||
4857 | |||
4858 | #: src/namestore/gnunet-namestore.c:680 | ||
4859 | #, c-format | ||
4860 | msgid "" | ||
4861 | "A SOA record exists already under `%s', cannot add a second SOA to the same " | 4937 | "A SOA record exists already under `%s', cannot add a second SOA to the same " |
4862 | "zone.\n" | 4938 | "zone.\n" |
4863 | msgstr "" | 4939 | msgstr "" |
4864 | 4940 | ||
4865 | #: src/namestore/gnunet-namestore.c:696 | 4941 | #: src/namestore/gnunet-namestore.c:789 |
4866 | #, c-format | ||
4867 | msgid "Records already exist under `%s', cannot add `%s' record.\n" | ||
4868 | msgstr "" | ||
4869 | |||
4870 | #: src/namestore/gnunet-namestore.c:711 | ||
4871 | #, c-format | ||
4872 | msgid "Records already exist under `%s', cannot add record.\n" | ||
4873 | msgstr "" | ||
4874 | |||
4875 | #: src/namestore/gnunet-namestore.c:726 | ||
4876 | #, c-format | ||
4877 | msgid "" | ||
4878 | "Non-GNS2DNS records already exist under `%s', cannot add GNS2DNS record.\n" | ||
4879 | msgstr "" | ||
4880 | |||
4881 | #: src/namestore/gnunet-namestore.c:846 | ||
4882 | #, c-format | 4942 | #, c-format |
4883 | msgid "There are no records under label `%s' that could be deleted.\n" | 4943 | msgid "There are no records under label `%s' that could be deleted.\n" |
4884 | msgstr "" | 4944 | msgstr "" |
4885 | 4945 | ||
4886 | #: src/namestore/gnunet-namestore.c:889 | 4946 | #: src/namestore/gnunet-namestore.c:832 |
4887 | #, c-format | 4947 | #, c-format |
4888 | msgid "" | 4948 | msgid "" |
4889 | "There are no records under label `%s' that match the request for deletion.\n" | 4949 | "There are no records under label `%s' that match the request for deletion.\n" |
4890 | msgstr "" | 4950 | msgstr "" |
4891 | 4951 | ||
4892 | #: src/namestore/gnunet-namestore.c:970 | 4952 | #: src/namestore/gnunet-namestore.c:920 |
4893 | #, fuzzy, c-format | 4953 | #, fuzzy, c-format |
4894 | msgid "Failed to replace records: %s\n" | 4954 | msgid "Failed to replace records: %s\n" |
4895 | msgstr "Dateiformat fehlerhaft (kein GNUnet Verzeichnis?)\n" | 4955 | msgstr "Dateiformat fehlerhaft (kein GNUnet Verzeichnis?)\n" |
4896 | 4956 | ||
4897 | #: src/namestore/gnunet-namestore.c:993 | 4957 | #: src/namestore/gnunet-namestore.c:943 |
4898 | #, c-format | 4958 | #, c-format |
4899 | msgid "No options given\n" | 4959 | msgid "No options given\n" |
4900 | msgstr "" | 4960 | msgstr "" |
4901 | 4961 | ||
4902 | #: src/namestore/gnunet-namestore.c:1014 src/namestore/gnunet-namestore.c:1066 | 4962 | #: src/namestore/gnunet-namestore.c:964 src/namestore/gnunet-namestore.c:1016 |
4903 | #: src/namestore/gnunet-namestore.c:1076 src/namestore/gnunet-namestore.c:1105 | 4963 | #: src/namestore/gnunet-namestore.c:1026 src/namestore/gnunet-namestore.c:1055 |
4904 | #: src/namestore/gnunet-namestore.c:1126 src/namestore/gnunet-namestore.c:1153 | 4964 | #: src/namestore/gnunet-namestore.c:1076 src/namestore/gnunet-namestore.c:1103 |
4905 | #: src/namestore/gnunet-namestore.c:1230 | 4965 | #: src/namestore/gnunet-namestore.c:1180 |
4906 | #, fuzzy, c-format | 4966 | #, fuzzy, c-format |
4907 | msgid "Missing option `%s' for operation `%s'\n" | 4967 | msgid "Missing option `%s' for operation `%s'\n" |
4908 | msgstr "Unbekannte Operation `%s'\n" | 4968 | msgstr "Unbekannte Operation `%s'\n" |
4909 | 4969 | ||
4910 | #: src/namestore/gnunet-namestore.c:1016 | 4970 | #: src/namestore/gnunet-namestore.c:966 |
4911 | msgid "replace" | 4971 | msgid "replace" |
4912 | msgstr "" | 4972 | msgstr "" |
4913 | 4973 | ||
4914 | #: src/namestore/gnunet-namestore.c:1045 | 4974 | #: src/namestore/gnunet-namestore.c:995 |
4915 | #, fuzzy, c-format | 4975 | #, fuzzy, c-format |
4916 | msgid "Invalid nick `%s'\n" | 4976 | msgid "Invalid nick `%s'\n" |
4917 | msgstr "Ungültiger Parameter: `%s'\n" | 4977 | msgstr "Ungültiger Parameter: `%s'\n" |
4918 | 4978 | ||
4919 | #: src/namestore/gnunet-namestore.c:1068 src/namestore/gnunet-namestore.c:1078 | 4979 | #: src/namestore/gnunet-namestore.c:1018 src/namestore/gnunet-namestore.c:1028 |
4920 | #: src/namestore/gnunet-namestore.c:1107 src/namestore/gnunet-namestore.c:1128 | 4980 | #: src/namestore/gnunet-namestore.c:1057 src/namestore/gnunet-namestore.c:1078 |
4921 | #: src/namestore/gnunet-namestore.c:1232 | 4981 | #: src/namestore/gnunet-namestore.c:1182 |
4922 | msgid "add" | 4982 | msgid "add" |
4923 | msgstr "" | 4983 | msgstr "" |
4924 | 4984 | ||
4925 | #: src/namestore/gnunet-namestore.c:1086 | 4985 | #: src/namestore/gnunet-namestore.c:1036 |
4926 | #, fuzzy, c-format | 4986 | #, fuzzy, c-format |
4927 | msgid "Unsupported type `%s'\n" | 4987 | msgid "Unsupported type `%s'\n" |
4928 | msgstr "Kommando `%s' wird nicht unterstützt. Vorgang wird abgebrochen.\n" | 4988 | msgstr "Kommando `%s' wird nicht unterstützt. Vorgang wird abgebrochen.\n" |
4929 | 4989 | ||
4930 | #: src/namestore/gnunet-namestore.c:1096 | 4990 | #: src/namestore/gnunet-namestore.c:1046 |
4931 | #, c-format | 4991 | #, c-format |
4932 | msgid "For DNS record types `SRV', `TLSA' and `OPENPGPKEY'" | 4992 | msgid "For DNS record types `SRV', `TLSA' and `OPENPGPKEY'" |
4933 | msgstr "" | 4993 | msgstr "" |
4934 | 4994 | ||
4935 | #: src/namestore/gnunet-namestore.c:1116 | 4995 | #: src/namestore/gnunet-namestore.c:1066 |
4936 | #, fuzzy, c-format | 4996 | #, fuzzy, c-format |
4937 | msgid "Value `%s' invalid for record type `%s'\n" | 4997 | msgid "Value `%s' invalid for record type `%s'\n" |
4938 | msgstr "%s: Symbolwert `%s' ist ungültig für %s\n" | 4998 | msgstr "%s: Symbolwert `%s' ist ungültig für %s\n" |
4939 | 4999 | ||
4940 | #: src/namestore/gnunet-namestore.c:1135 src/namestore/gnunet-namestore.c:1239 | 5000 | #: src/namestore/gnunet-namestore.c:1085 src/namestore/gnunet-namestore.c:1189 |
4941 | #, fuzzy, c-format | 5001 | #, fuzzy, c-format |
4942 | msgid "Invalid time format `%s'\n" | 5002 | msgid "Invalid time format `%s'\n" |
4943 | msgstr "Ungültiger Parameter: `%s'\n" | 5003 | msgstr "Ungültiger Parameter: `%s'\n" |
4944 | 5004 | ||
4945 | #: src/namestore/gnunet-namestore.c:1155 | 5005 | #: src/namestore/gnunet-namestore.c:1105 |
4946 | msgid "del" | 5006 | msgid "del" |
4947 | msgstr "" | 5007 | msgstr "" |
4948 | 5008 | ||
4949 | #: src/namestore/gnunet-namestore.c:1197 | 5009 | #: src/namestore/gnunet-namestore.c:1147 |
4950 | #, c-format | 5010 | #, c-format |
4951 | msgid "Invalid public key for reverse lookup `%s'\n" | 5011 | msgid "Invalid public key for reverse lookup `%s'\n" |
4952 | msgstr "" | 5012 | msgstr "" |
4953 | 5013 | ||
4954 | #: src/namestore/gnunet-namestore.c:1222 | 5014 | #: src/namestore/gnunet-namestore.c:1172 |
4955 | #: src/peerinfo-tool/gnunet-peerinfo.c:737 | 5015 | #: src/peerinfo-tool/gnunet-peerinfo.c:737 |
4956 | #, fuzzy, c-format | 5016 | #, fuzzy, c-format |
4957 | msgid "Invalid URI `%s'\n" | 5017 | msgid "Invalid URI `%s'\n" |
4958 | msgstr "Ungültiger Parameter: `%s'\n" | 5018 | msgstr "Ungültiger Parameter: `%s'\n" |
4959 | 5019 | ||
4960 | #: src/namestore/gnunet-namestore.c:1292 | 5020 | #: src/namestore/gnunet-namestore.c:1242 |
4961 | #, c-format | 5021 | #, c-format |
4962 | msgid "Label `%s' contains `.' which is not allowed\n" | 5022 | msgid "Label `%s' contains `.' which is not allowed\n" |
4963 | msgstr "" | 5023 | msgstr "" |
4964 | 5024 | ||
4965 | #: src/namestore/gnunet-namestore.c:1342 | 5025 | #: src/namestore/gnunet-namestore.c:1292 |
4966 | #, c-format | 5026 | #, c-format |
4967 | msgid "" | 5027 | msgid "" |
4968 | "No default identity configured for `namestore' subsystem\n" | 5028 | "No default identity configured for `namestore' subsystem\n" |
@@ -4970,107 +5030,112 @@ msgid "" | |||
4970 | "Run gnunet-identity -d to get a list of choices for $NAME\n" | 5030 | "Run gnunet-identity -d to get a list of choices for $NAME\n" |
4971 | msgstr "" | 5031 | msgstr "" |
4972 | 5032 | ||
4973 | #: src/namestore/gnunet-namestore.c:1407 | 5033 | #: src/namestore/gnunet-namestore.c:1357 |
4974 | #, c-format | 5034 | #, c-format |
4975 | msgid "Superfluous command line arguments (starting with `%s') ignored\n" | 5035 | msgid "Superfluous command line arguments (starting with `%s') ignored\n" |
4976 | msgstr "" | 5036 | msgstr "" |
4977 | 5037 | ||
4978 | #: src/namestore/gnunet-namestore.c:1436 | 5038 | #: src/namestore/gnunet-namestore.c:1386 |
4979 | #, fuzzy, c-format | 5039 | #, fuzzy, c-format |
4980 | msgid "Cannot connect to identity service\n" | 5040 | msgid "Cannot connect to identity service\n" |
4981 | msgstr "Verbindung zu %u.%u.%u.%u:%u fehlgeschlagen: %s\n" | 5041 | msgstr "Verbindung zu %u.%u.%u.%u:%u fehlgeschlagen: %s\n" |
4982 | 5042 | ||
4983 | #: src/namestore/gnunet-namestore.c:1483 | 5043 | #: src/namestore/gnunet-namestore.c:1433 |
4984 | msgid "Empty record line argument is not allowed.\n" | 5044 | msgid "Empty record line argument is not allowed.\n" |
4985 | msgstr "" | 5045 | msgstr "" |
4986 | 5046 | ||
4987 | #: src/namestore/gnunet-namestore.c:1495 | 5047 | #: src/namestore/gnunet-namestore.c:1445 |
4988 | #, c-format | 5048 | #, c-format |
4989 | msgid "Invalid expiration time `%s' (must be without unit)\n" | 5049 | msgid "Invalid expiration time `%s' (must be without unit)\n" |
4990 | msgstr "" | 5050 | msgstr "" |
4991 | 5051 | ||
4992 | #: src/namestore/gnunet-namestore.c:1507 src/namestore/gnunet-namestore.c:1523 | 5052 | #: src/namestore/gnunet-namestore.c:1457 src/namestore/gnunet-namestore.c:1473 |
4993 | #: src/namestore/gnunet-namestore.c:1540 | 5053 | #: src/namestore/gnunet-namestore.c:1490 |
4994 | #, fuzzy, c-format | 5054 | #, fuzzy, c-format |
4995 | msgid "Missing entries in record line `%s'.\n" | 5055 | msgid "Missing entries in record line `%s'.\n" |
4996 | msgstr "Anwendung `%s' konnte nicht initialisiert werden.\n" | 5056 | msgstr "Anwendung `%s' konnte nicht initialisiert werden.\n" |
4997 | 5057 | ||
4998 | #: src/namestore/gnunet-namestore.c:1515 | 5058 | #: src/namestore/gnunet-namestore.c:1465 |
4999 | #, fuzzy, c-format | 5059 | #, fuzzy, c-format |
5000 | msgid "Unknown record type `%s'\n" | 5060 | msgid "Unknown record type `%s'\n" |
5001 | msgstr "Unbekannter Befehl »%s«\n" | 5061 | msgstr "Unbekannter Befehl »%s«\n" |
5002 | 5062 | ||
5003 | #: src/namestore/gnunet-namestore.c:1553 | 5063 | #: src/namestore/gnunet-namestore.c:1503 |
5004 | #, fuzzy, c-format | 5064 | #, fuzzy, c-format |
5005 | msgid "Invalid record data for type %s: `%s'.\n" | 5065 | msgid "Invalid record data for type %s: `%s'.\n" |
5006 | msgstr "Ungültiges Format für IP: »%s«\n" | 5066 | msgstr "Ungültiges Format für IP: »%s«\n" |
5007 | 5067 | ||
5008 | #: src/namestore/gnunet-namestore.c:1610 | 5068 | #: src/namestore/gnunet-namestore.c:1560 |
5009 | msgid "add record" | 5069 | msgid "add record" |
5010 | msgstr "" | 5070 | msgstr "" |
5011 | 5071 | ||
5012 | #: src/namestore/gnunet-namestore.c:1613 | 5072 | #: src/namestore/gnunet-namestore.c:1563 |
5013 | msgid "delete record" | 5073 | msgid "delete record" |
5014 | msgstr "" | 5074 | msgstr "" |
5015 | 5075 | ||
5016 | #: src/namestore/gnunet-namestore.c:1617 | 5076 | #: src/namestore/gnunet-namestore.c:1567 |
5017 | msgid "display records" | 5077 | msgid "display records" |
5018 | msgstr "" | 5078 | msgstr "" |
5019 | 5079 | ||
5020 | #: src/namestore/gnunet-namestore.c:1624 | 5080 | #: src/namestore/gnunet-namestore.c:1574 |
5021 | msgid "" | 5081 | msgid "" |
5022 | "expiration time for record to use (for adding only), \"never\" is possible" | 5082 | "expiration time for record to use (for adding only), \"never\" is possible" |
5023 | msgstr "" | 5083 | msgstr "" |
5024 | 5084 | ||
5025 | #: src/namestore/gnunet-namestore.c:1630 | 5085 | #: src/namestore/gnunet-namestore.c:1580 |
5026 | msgid "set the desired nick name for the zone" | 5086 | msgid "set the desired nick name for the zone" |
5027 | msgstr "" | 5087 | msgstr "" |
5028 | 5088 | ||
5029 | #: src/namestore/gnunet-namestore.c:1635 | 5089 | #: src/namestore/gnunet-namestore.c:1585 |
5030 | msgid "monitor changes in the namestore" | 5090 | msgid "monitor changes in the namestore" |
5031 | msgstr "" | 5091 | msgstr "" |
5032 | 5092 | ||
5033 | #: src/namestore/gnunet-namestore.c:1647 | 5093 | #: src/namestore/gnunet-namestore.c:1597 |
5034 | msgid "determine our name for the given PKEY" | 5094 | msgid "determine our name for the given PKEY" |
5035 | msgstr "" | 5095 | msgstr "" |
5036 | 5096 | ||
5037 | #: src/namestore/gnunet-namestore.c:1654 | 5097 | #: src/namestore/gnunet-namestore.c:1604 |
5038 | msgid "" | 5098 | msgid "" |
5039 | "set record set to values given by (possibly multiple) RECORDLINES; can be " | 5099 | "set record set to values given by (possibly multiple) RECORDLINES; can be " |
5040 | "specified multiple times" | 5100 | "specified multiple times" |
5041 | msgstr "" | 5101 | msgstr "" |
5042 | 5102 | ||
5043 | #: src/namestore/gnunet-namestore.c:1660 | 5103 | #: src/namestore/gnunet-namestore.c:1610 |
5044 | msgid "type of the record to add/delete/display" | 5104 | msgid "type of the record to add/delete/display" |
5045 | msgstr "" | 5105 | msgstr "" |
5046 | 5106 | ||
5047 | #: src/namestore/gnunet-namestore.c:1665 | 5107 | #: src/namestore/gnunet-namestore.c:1615 |
5048 | msgid "URI to import into our zone" | 5108 | msgid "URI to import into our zone" |
5049 | msgstr "" | 5109 | msgstr "" |
5050 | 5110 | ||
5051 | #: src/namestore/gnunet-namestore.c:1671 | 5111 | #: src/namestore/gnunet-namestore.c:1621 |
5052 | msgid "value of the record to add/delete" | 5112 | msgid "value of the record to add/delete" |
5053 | msgstr "" | 5113 | msgstr "" |
5054 | 5114 | ||
5055 | #: src/namestore/gnunet-namestore.c:1675 | 5115 | #: src/namestore/gnunet-namestore.c:1625 |
5056 | msgid "create or list public record" | 5116 | msgid "create or list public record" |
5057 | msgstr "" | 5117 | msgstr "" |
5058 | 5118 | ||
5059 | #: src/namestore/gnunet-namestore.c:1681 | 5119 | #: src/namestore/gnunet-namestore.c:1631 |
5060 | msgid "" | 5120 | msgid "" |
5061 | "create shadow record (only valid if all other records of the same type have " | 5121 | "create shadow record (only valid if all other records of the same type have " |
5062 | "expired" | 5122 | "expired" |
5063 | msgstr "" | 5123 | msgstr "" |
5064 | 5124 | ||
5065 | #: src/namestore/gnunet-namestore.c:1687 | 5125 | #: src/namestore/gnunet-namestore.c:1637 |
5066 | msgid "name of the ego controlling the zone" | 5126 | msgid "name of the ego controlling the zone" |
5067 | msgstr "" | 5127 | msgstr "" |
5068 | 5128 | ||
5069 | #: src/namestore/gnunet-service-namestore.c:871 | 5129 | #: src/namestore/gnunet-service-namestore.c:879 |
5070 | #, c-format | 5130 | #, c-format |
5071 | msgid "Failed to replicate block in namecache: %s\n" | 5131 | msgid "Failed to replicate block in namecache: %s\n" |
5072 | msgstr "" | 5132 | msgstr "" |
5073 | 5133 | ||
5134 | #: src/namestore/gnunet-service-namestore.c:1668 | ||
5135 | #, fuzzy | ||
5136 | msgid "Store failed" | ||
5137 | msgstr "Verbindung fehlgeschlagen: %s\n" | ||
5138 | |||
5074 | #: src/namestore/gnunet-zoneimport.c:1847 | 5139 | #: src/namestore/gnunet-zoneimport.c:1847 |
5075 | msgid "size to use for the main hash map" | 5140 | msgid "size to use for the main hash map" |
5076 | msgstr "" | 5141 | msgstr "" |
@@ -5079,10 +5144,6 @@ msgstr "" | |||
5079 | msgid "minimum expiration time we assume for imported records" | 5144 | msgid "minimum expiration time we assume for imported records" |
5080 | msgstr "" | 5145 | msgstr "" |
5081 | 5146 | ||
5082 | #: src/namestore/namestore_api.c:373 | ||
5083 | msgid "Namestore failed to store record\n" | ||
5084 | msgstr "" | ||
5085 | |||
5086 | #: src/namestore/plugin_namestore_flat.c:195 | 5147 | #: src/namestore/plugin_namestore_flat.c:195 |
5087 | #, c-format | 5148 | #, c-format |
5088 | msgid "File too big to map: %llu bytes.\n" | 5149 | msgid "File too big to map: %llu bytes.\n" |
@@ -5678,6 +5739,51 @@ msgstr "" | |||
5678 | msgid "Daemon to run to perform IP protocol translation to GNUnet" | 5739 | msgid "Daemon to run to perform IP protocol translation to GNUnet" |
5679 | msgstr "" | 5740 | msgstr "" |
5680 | 5741 | ||
5742 | #: src/reclaim/gnunet-did.c:209 | ||
5743 | #, fuzzy, c-format | ||
5744 | msgid "Invalid DID `%s'\n" | ||
5745 | msgstr "Ungültiger Parameter: `%s'\n" | ||
5746 | |||
5747 | #: src/reclaim/gnunet-did.c:835 | ||
5748 | msgid "Create a DID Document and display its DID" | ||
5749 | msgstr "" | ||
5750 | |||
5751 | #: src/reclaim/gnunet-did.c:840 | ||
5752 | msgid "Get the DID Document associated with the given DID" | ||
5753 | msgstr "" | ||
5754 | |||
5755 | #: src/reclaim/gnunet-did.c:844 | ||
5756 | msgid "Show the DID for a given ego" | ||
5757 | msgstr "" | ||
5758 | |||
5759 | #: src/reclaim/gnunet-did.c:849 | ||
5760 | msgid "Remove the DID" | ||
5761 | msgstr "" | ||
5762 | |||
5763 | #: src/reclaim/gnunet-did.c:853 src/reclaim/gnunet-did.c:857 | ||
5764 | msgid "Replace the DID Document." | ||
5765 | msgstr "" | ||
5766 | |||
5767 | #: src/reclaim/gnunet-did.c:863 | ||
5768 | msgid "The Decentralized Identity (DID)" | ||
5769 | msgstr "" | ||
5770 | |||
5771 | #: src/reclaim/gnunet-did.c:869 | ||
5772 | msgid "The DID Document to store in GNUNET" | ||
5773 | msgstr "" | ||
5774 | |||
5775 | #: src/reclaim/gnunet-did.c:874 | ||
5776 | msgid "The name of the EGO" | ||
5777 | msgstr "" | ||
5778 | |||
5779 | #: src/reclaim/gnunet-did.c:880 | ||
5780 | msgid "The time until the DID Document is going to expire (e.g. 5d)" | ||
5781 | msgstr "" | ||
5782 | |||
5783 | #: src/reclaim/gnunet-did.c:889 | ||
5784 | msgid "Manage Decentralized Identities (DIDs)" | ||
5785 | msgstr "" | ||
5786 | |||
5681 | #: src/reclaim/gnunet-reclaim.c:802 | 5787 | #: src/reclaim/gnunet-reclaim.c:802 |
5682 | #, fuzzy, c-format | 5788 | #, fuzzy, c-format |
5683 | msgid "Ego is required\n" | 5789 | msgid "Ego is required\n" |
@@ -6563,17 +6669,17 @@ msgid "" | |||
6563 | "free topology cannot be more than %u. Given `%s = %llu'" | 6669 | "free topology cannot be more than %u. Given `%s = %llu'" |
6564 | msgstr "" | 6670 | msgstr "" |
6565 | 6671 | ||
6566 | #: src/testbed/testbed_api_topology.c:1033 src/testing/testing.c:2643 | 6672 | #: src/testbed/testbed_api_topology.c:1033 src/testing/testing.c:2657 |
6567 | #, c-format | 6673 | #, c-format |
6568 | msgid "Topology file %s not found\n" | 6674 | msgid "Topology file %s not found\n" |
6569 | msgstr "" | 6675 | msgstr "" |
6570 | 6676 | ||
6571 | #: src/testbed/testbed_api_topology.c:1041 src/testing/testing.c:2651 | 6677 | #: src/testbed/testbed_api_topology.c:1041 src/testing/testing.c:2665 |
6572 | #, c-format | 6678 | #, c-format |
6573 | msgid "Topology file %s has no data\n" | 6679 | msgid "Topology file %s has no data\n" |
6574 | msgstr "" | 6680 | msgstr "" |
6575 | 6681 | ||
6576 | #: src/testbed/testbed_api_topology.c:1049 src/testing/testing.c:2659 | 6682 | #: src/testbed/testbed_api_topology.c:1049 src/testing/testing.c:2673 |
6577 | #, c-format | 6683 | #, c-format |
6578 | msgid "Topology file %s cannot be read\n" | 6684 | msgid "Topology file %s cannot be read\n" |
6579 | msgstr "" | 6685 | msgstr "" |
@@ -6775,7 +6881,7 @@ msgstr "" | |||
6775 | 6881 | ||
6776 | #: src/transport/gnunet-communicator-tcp.c:3338 | 6882 | #: src/transport/gnunet-communicator-tcp.c:3338 |
6777 | #: src/transport/gnunet-communicator-udp.c:3856 | 6883 | #: src/transport/gnunet-communicator-udp.c:3856 |
6778 | #: src/transport/gnunet-service-tng.c:10512 | 6884 | #: src/transport/gnunet-service-tng.c:10623 |
6779 | #: src/transport/gnunet-service-transport.c:2627 | 6885 | #: src/transport/gnunet-service-transport.c:2627 |
6780 | msgid "Transport service is lacking key configuration settings. Exiting.\n" | 6886 | msgid "Transport service is lacking key configuration settings. Exiting.\n" |
6781 | msgstr "" | 6887 | msgstr "" |
@@ -7978,60 +8084,60 @@ msgstr "" | |||
7978 | msgid "Need a non-empty hostname for service `%s'.\n" | 8084 | msgid "Need a non-empty hostname for service `%s'.\n" |
7979 | msgstr "" | 8085 | msgstr "" |
7980 | 8086 | ||
7981 | #: src/util/common_logging.c:626 src/util/common_logging.c:665 | 8087 | #: src/util/common_logging.c:648 src/util/common_logging.c:687 |
7982 | #, c-format | 8088 | #, c-format |
7983 | msgid "ERROR: Unable to parse log definition: Syntax error at `%s'.\n" | 8089 | msgid "ERROR: Unable to parse log definition: Syntax error at `%s'.\n" |
7984 | msgstr "" | 8090 | msgstr "" |
7985 | 8091 | ||
7986 | #: src/util/common_logging.c:904 | 8092 | #: src/util/common_logging.c:926 |
7987 | #, c-format | 8093 | #, c-format |
7988 | msgid "Message `%.*s' repeated %u times in the last %s\n" | 8094 | msgid "Message `%.*s' repeated %u times in the last %s\n" |
7989 | msgstr "" | 8095 | msgstr "" |
7990 | 8096 | ||
7991 | #: src/util/common_logging.c:1108 | 8097 | #: src/util/common_logging.c:1131 |
7992 | msgid "ERROR" | 8098 | msgid "ERROR" |
7993 | msgstr "FEHLER" | 8099 | msgstr "FEHLER" |
7994 | 8100 | ||
7995 | #: src/util/common_logging.c:1110 | 8101 | #: src/util/common_logging.c:1133 |
7996 | msgid "WARNING" | 8102 | msgid "WARNING" |
7997 | msgstr "WARNUNG" | 8103 | msgstr "WARNUNG" |
7998 | 8104 | ||
7999 | #: src/util/common_logging.c:1112 | 8105 | #: src/util/common_logging.c:1135 |
8000 | msgid "MESSAGE" | 8106 | msgid "MESSAGE" |
8001 | msgstr "" | 8107 | msgstr "" |
8002 | 8108 | ||
8003 | #: src/util/common_logging.c:1114 | 8109 | #: src/util/common_logging.c:1137 |
8004 | msgid "INFO" | 8110 | msgid "INFO" |
8005 | msgstr "INFO" | 8111 | msgstr "INFO" |
8006 | 8112 | ||
8007 | #: src/util/common_logging.c:1116 | 8113 | #: src/util/common_logging.c:1139 |
8008 | msgid "DEBUG" | 8114 | msgid "DEBUG" |
8009 | msgstr "DEBUG" | 8115 | msgstr "DEBUG" |
8010 | 8116 | ||
8011 | #: src/util/common_logging.c:1118 | 8117 | #: src/util/common_logging.c:1141 |
8012 | msgid "NONE" | 8118 | msgid "NONE" |
8013 | msgstr "" | 8119 | msgstr "" |
8014 | 8120 | ||
8015 | #: src/util/common_logging.c:1119 | 8121 | #: src/util/common_logging.c:1142 |
8016 | msgid "INVALID" | 8122 | msgid "INVALID" |
8017 | msgstr "" | 8123 | msgstr "" |
8018 | 8124 | ||
8019 | #: src/util/common_logging.c:1400 | 8125 | #: src/util/common_logging.c:1423 |
8020 | msgid "unknown address" | 8126 | msgid "unknown address" |
8021 | msgstr "Unbekannte Adresse" | 8127 | msgstr "Unbekannte Adresse" |
8022 | 8128 | ||
8023 | #: src/util/common_logging.c:1445 | 8129 | #: src/util/common_logging.c:1468 |
8024 | msgid "invalid address" | 8130 | msgid "invalid address" |
8025 | msgstr "Ungültige Adresse" | 8131 | msgstr "Ungültige Adresse" |
8026 | 8132 | ||
8027 | #: src/util/common_logging.c:1464 | 8133 | #: src/util/common_logging.c:1487 |
8028 | #, fuzzy, c-format | 8134 | #, fuzzy, c-format |
8029 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" | 8135 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" |
8030 | msgstr "" | 8136 | msgstr "" |
8031 | "Die Konfigurationsdatei muss in der Sektion `%s' unter `%s' ein Verzeichnis " | 8137 | "Die Konfigurationsdatei muss in der Sektion `%s' unter `%s' ein Verzeichnis " |
8032 | "angeben, in dem FS Daten gespeichert werden.\n" | 8138 | "angeben, in dem FS Daten gespeichert werden.\n" |
8033 | 8139 | ||
8034 | #: src/util/common_logging.c:1487 | 8140 | #: src/util/common_logging.c:1510 |
8035 | #, fuzzy, c-format | 8141 | #, fuzzy, c-format |
8036 | msgid "" | 8142 | msgid "" |
8037 | "Configuration specifies invalid value for option `%s' in section `%s': %s\n" | 8143 | "Configuration specifies invalid value for option `%s' in section `%s': %s\n" |
@@ -8180,17 +8286,17 @@ msgstr "" | |||
8180 | msgid "Could not bind to any port: %s\n" | 8286 | msgid "Could not bind to any port: %s\n" |
8181 | msgstr "IP des Hosts `%s' konnte nicht ermittelt werden: %s\n" | 8287 | msgstr "IP des Hosts `%s' konnte nicht ermittelt werden: %s\n" |
8182 | 8288 | ||
8183 | #: src/util/dnsstub.c:344 | 8289 | #: src/util/dnsstub.c:370 |
8184 | #, c-format | 8290 | #, c-format |
8185 | msgid "Received DNS response that is too small (%u bytes)" | 8291 | msgid "Received DNS response that is too small (%u bytes)\n" |
8186 | msgstr "" | 8292 | msgstr "" |
8187 | 8293 | ||
8188 | #: src/util/dnsstub.c:482 | 8294 | #: src/util/dnsstub.c:508 |
8189 | #, fuzzy, c-format | 8295 | #, fuzzy, c-format |
8190 | msgid "Failed to send DNS request to %s: %s\n" | 8296 | msgid "Failed to send DNS request to %s: %s\n" |
8191 | msgstr "HTTP Anfrage konnte nicht an Host `%s' gesendet werden: %s\n" | 8297 | msgstr "HTTP Anfrage konnte nicht an Host `%s' gesendet werden: %s\n" |
8192 | 8298 | ||
8193 | #: src/util/dnsstub.c:487 | 8299 | #: src/util/dnsstub.c:513 |
8194 | #, c-format | 8300 | #, c-format |
8195 | msgid "Sent DNS request to %s\n" | 8301 | msgid "Sent DNS request to %s\n" |
8196 | msgstr "" | 8302 | msgstr "" |
@@ -8277,84 +8383,84 @@ msgstr "" | |||
8277 | "Argumente, die für lange Optionen zwingend sind, sind auch für kurze " | 8383 | "Argumente, die für lange Optionen zwingend sind, sind auch für kurze " |
8278 | "Optionen zwingend.\n" | 8384 | "Optionen zwingend.\n" |
8279 | 8385 | ||
8280 | #: src/util/getopt_helpers.c:196 | 8386 | #: src/util/getopt_helpers.c:197 |
8281 | msgid "print this help" | 8387 | msgid "print this help" |
8282 | msgstr "" | 8388 | msgstr "" |
8283 | 8389 | ||
8284 | #: src/util/getopt_helpers.c:261 | 8390 | #: src/util/getopt_helpers.c:262 |
8285 | msgid "be verbose" | 8391 | msgid "be verbose" |
8286 | msgstr "" | 8392 | msgstr "" |
8287 | 8393 | ||
8288 | #: src/util/getopt_helpers.c:377 | 8394 | #: src/util/getopt_helpers.c:378 |
8289 | msgid "configure logging to use LOGLEVEL" | 8395 | msgid "configure logging to use LOGLEVEL" |
8290 | msgstr "" | 8396 | msgstr "" |
8291 | 8397 | ||
8292 | #: src/util/getopt_helpers.c:444 | 8398 | #: src/util/getopt_helpers.c:445 |
8293 | msgid "configure logging to write logs to FILENAME" | 8399 | msgid "configure logging to write logs to FILENAME" |
8294 | msgstr "" | 8400 | msgstr "" |
8295 | 8401 | ||
8296 | #: src/util/getopt_helpers.c:461 | 8402 | #: src/util/getopt_helpers.c:462 |
8297 | #, fuzzy | 8403 | #, fuzzy |
8298 | msgid "use configuration file FILENAME" | 8404 | msgid "use configuration file FILENAME" |
8299 | msgstr "" | 8405 | msgstr "" |
8300 | "Einen Wert aus der Konfigurationsdatei auf der Standardausgabe ausgeben" | 8406 | "Einen Wert aus der Konfigurationsdatei auf der Standardausgabe ausgeben" |
8301 | 8407 | ||
8302 | #: src/util/getopt_helpers.c:497 src/util/getopt_helpers.c:811 | 8408 | #: src/util/getopt_helpers.c:498 src/util/getopt_helpers.c:812 |
8303 | #: src/util/getopt_helpers.c:867 | 8409 | #: src/util/getopt_helpers.c:868 |
8304 | #, c-format | 8410 | #, c-format |
8305 | msgid "You must pass a number to the `%s' option.\n" | 8411 | msgid "You must pass a number to the `%s' option.\n" |
8306 | msgstr "Sie müssen für die Option »%s« zusätzlich eine Zahl angeben.\n" | 8412 | msgstr "Sie müssen für die Option »%s« zusätzlich eine Zahl angeben.\n" |
8307 | 8413 | ||
8308 | #: src/util/getopt_helpers.c:569 | 8414 | #: src/util/getopt_helpers.c:570 |
8309 | #, fuzzy, c-format | 8415 | #, fuzzy, c-format |
8310 | msgid "" | 8416 | msgid "" |
8311 | "You must pass a relative time (optionally with sign) to the `%s' option.\n" | 8417 | "You must pass a relative time (optionally with sign) to the `%s' option.\n" |
8312 | msgstr "Sie müssen eine relative Zeit zu der Option »%s« übergeben.\n" | 8418 | msgstr "Sie müssen eine relative Zeit zu der Option »%s« übergeben.\n" |
8313 | 8419 | ||
8314 | #: src/util/getopt_helpers.c:576 | 8420 | #: src/util/getopt_helpers.c:577 |
8315 | #, c-format | 8421 | #, c-format |
8316 | msgid "Value given for time travel `%s' option is too big.\n" | 8422 | msgid "Value given for time travel `%s' option is too big.\n" |
8317 | msgstr "" | 8423 | msgstr "" |
8318 | 8424 | ||
8319 | #: src/util/getopt_helpers.c:594 | 8425 | #: src/util/getopt_helpers.c:595 |
8320 | msgid "[+/-]MICROSECONDS" | 8426 | msgid "[+/-]MICROSECONDS" |
8321 | msgstr "" | 8427 | msgstr "" |
8322 | 8428 | ||
8323 | #: src/util/getopt_helpers.c:596 | 8429 | #: src/util/getopt_helpers.c:597 |
8324 | msgid "modify system time by given offset (for debugging/testing only)" | 8430 | msgid "modify system time by given offset (for debugging/testing only)" |
8325 | msgstr "" | 8431 | msgstr "" |
8326 | 8432 | ||
8327 | #: src/util/getopt_helpers.c:630 | 8433 | #: src/util/getopt_helpers.c:631 |
8328 | #, c-format | 8434 | #, c-format |
8329 | msgid "You must pass relative time to the `%s' option.\n" | 8435 | msgid "You must pass relative time to the `%s' option.\n" |
8330 | msgstr "Sie müssen eine relative Zeit zu der Option »%s« übergeben.\n" | 8436 | msgstr "Sie müssen eine relative Zeit zu der Option »%s« übergeben.\n" |
8331 | 8437 | ||
8332 | #: src/util/getopt_helpers.c:684 | 8438 | #: src/util/getopt_helpers.c:685 |
8333 | #, fuzzy, c-format | 8439 | #, fuzzy, c-format |
8334 | msgid "You must pass absolute time to the `%s' option.\n" | 8440 | msgid "You must pass absolute time to the `%s' option.\n" |
8335 | msgstr "Sie müssen eine relative Zeit zu der Option »%s« übergeben.\n" | 8441 | msgstr "Sie müssen eine relative Zeit zu der Option »%s« übergeben.\n" |
8336 | 8442 | ||
8337 | #: src/util/getopt_helpers.c:741 | 8443 | #: src/util/getopt_helpers.c:742 |
8338 | #, fuzzy, c-format | 8444 | #, fuzzy, c-format |
8339 | msgid "You must pass a timestamp to the `%s' option.\n" | 8445 | msgid "You must pass a timestamp to the `%s' option.\n" |
8340 | msgstr "Sie müssen für die Option »%s« zusätzlich eine Zahl angeben.\n" | 8446 | msgstr "Sie müssen für die Option »%s« zusätzlich eine Zahl angeben.\n" |
8341 | 8447 | ||
8342 | #: src/util/getopt_helpers.c:748 | 8448 | #: src/util/getopt_helpers.c:749 |
8343 | #, c-format | 8449 | #, c-format |
8344 | msgid "The maximum precision allowed for timestamps is seconds.\n" | 8450 | msgid "The maximum precision allowed for timestamps is seconds.\n" |
8345 | msgstr "" | 8451 | msgstr "" |
8346 | 8452 | ||
8347 | #: src/util/getopt_helpers.c:804 | 8453 | #: src/util/getopt_helpers.c:805 |
8348 | #, c-format | 8454 | #, c-format |
8349 | msgid "Your input for the '%s' option has to be a non negative number\n" | 8455 | msgid "Your input for the '%s' option has to be a non negative number\n" |
8350 | msgstr "" | 8456 | msgstr "" |
8351 | 8457 | ||
8352 | #: src/util/getopt_helpers.c:874 | 8458 | #: src/util/getopt_helpers.c:875 |
8353 | #, fuzzy, c-format | 8459 | #, fuzzy, c-format |
8354 | msgid "You must pass a number below %u to the `%s' option.\n" | 8460 | msgid "You must pass a number below %u to the `%s' option.\n" |
8355 | msgstr "Sie müssen für die Option »%s« zusätzlich eine Zahl angeben.\n" | 8461 | msgstr "Sie müssen für die Option »%s« zusätzlich eine Zahl angeben.\n" |
8356 | 8462 | ||
8357 | #: src/util/getopt_helpers.c:952 | 8463 | #: src/util/getopt_helpers.c:953 |
8358 | #, c-format | 8464 | #, c-format |
8359 | msgid "Argument `%s' malformed. Expected base32 (Crockford) encoded value.\n" | 8465 | msgid "Argument `%s' malformed. Expected base32 (Crockford) encoded value.\n" |
8360 | msgstr "" | 8466 | msgstr "" |
@@ -8387,7 +8493,7 @@ msgstr "" | |||
8387 | msgid "Manipulate GNUnet configuration files" | 8493 | msgid "Manipulate GNUnet configuration files" |
8388 | msgstr "GNUnet-Konfigurationsdateien bearbeiten" | 8494 | msgstr "GNUnet-Konfigurationsdateien bearbeiten" |
8389 | 8495 | ||
8390 | #: src/util/gnunet-crypto-tvg.c:1072 | 8496 | #: src/util/gnunet-crypto-tvg.c:1483 |
8391 | msgid "verify a test vector from stdin" | 8497 | msgid "verify a test vector from stdin" |
8392 | msgstr "" | 8498 | msgstr "" |
8393 | 8499 | ||
@@ -8643,7 +8749,7 @@ msgstr "Verbindung zu %u.%u.%u.%u:%u fehlgeschlagen: %s\n" | |||
8643 | msgid "Unable to shorten unix path `%s' while keeping name unique\n" | 8749 | msgid "Unable to shorten unix path `%s' while keeping name unique\n" |
8644 | msgstr "" | 8750 | msgstr "" |
8645 | 8751 | ||
8646 | #: src/util/network.c:1306 | 8752 | #: src/util/network.c:1307 |
8647 | #, c-format | 8753 | #, c-format |
8648 | msgid "" | 8754 | msgid "" |
8649 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" | 8755 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" |
@@ -8775,77 +8881,77 @@ msgstr "" | |||
8775 | msgid "Character sets requested were `%s'->`%s'\n" | 8881 | msgid "Character sets requested were `%s'->`%s'\n" |
8776 | msgstr "" | 8882 | msgstr "" |
8777 | 8883 | ||
8778 | #: src/util/strings.c:487 | 8884 | #: src/util/strings.c:514 |
8779 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" | 8885 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" |
8780 | msgstr "" | 8886 | msgstr "" |
8781 | 8887 | ||
8782 | #: src/util/strings.c:1023 | 8888 | #: src/util/strings.c:1050 |
8783 | msgid "IPv6 address did not start with `['\n" | 8889 | msgid "IPv6 address did not start with `['\n" |
8784 | msgstr "IPv6-Adresse beginnt nicht mit »[«\n" | 8890 | msgstr "IPv6-Adresse beginnt nicht mit »[«\n" |
8785 | 8891 | ||
8786 | #: src/util/strings.c:1031 | 8892 | #: src/util/strings.c:1058 |
8787 | msgid "IPv6 address did contain ':' to separate port number\n" | 8893 | msgid "IPv6 address did contain ':' to separate port number\n" |
8788 | msgstr "IPv6-Adresse enthält kein »:« zur Abtrennung der Portnummer\n" | 8894 | msgstr "IPv6-Adresse enthält kein »:« zur Abtrennung der Portnummer\n" |
8789 | 8895 | ||
8790 | #: src/util/strings.c:1038 | 8896 | #: src/util/strings.c:1065 |
8791 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" | 8897 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" |
8792 | msgstr "IPv6-Adresse enthält kein »]« vor »:« zur Abtrennung der Portnummer\n" | 8898 | msgstr "IPv6-Adresse enthält kein »]« vor »:« zur Abtrennung der Portnummer\n" |
8793 | 8899 | ||
8794 | #: src/util/strings.c:1046 | 8900 | #: src/util/strings.c:1073 |
8795 | msgid "IPv6 address did contain a valid port number after the last ':'\n" | 8901 | msgid "IPv6 address did contain a valid port number after the last ':'\n" |
8796 | msgstr "IPv6-Adresse enthält keine gültige Portnummer nach dem letzten »:«\n" | 8902 | msgstr "IPv6-Adresse enthält keine gültige Portnummer nach dem letzten »:«\n" |
8797 | 8903 | ||
8798 | #: src/util/strings.c:1055 | 8904 | #: src/util/strings.c:1082 |
8799 | #, fuzzy, c-format | 8905 | #, fuzzy, c-format |
8800 | msgid "Invalid IPv6 address `%s': %s\n" | 8906 | msgid "Invalid IPv6 address `%s': %s\n" |
8801 | msgstr "Ungültige Antwort auf `%s' von `%s'\n" | 8907 | msgstr "Ungültige Antwort auf `%s' von `%s'\n" |
8802 | 8908 | ||
8803 | #: src/util/strings.c:1237 src/util/strings.c:1248 | 8909 | #: src/util/strings.c:1264 src/util/strings.c:1275 |
8804 | msgid "Port not in range\n" | 8910 | msgid "Port not in range\n" |
8805 | msgstr "Port außerhalb des Bereichs\n" | 8911 | msgstr "Port außerhalb des Bereichs\n" |
8806 | 8912 | ||
8807 | #: src/util/strings.c:1257 | 8913 | #: src/util/strings.c:1284 |
8808 | #, c-format | 8914 | #, c-format |
8809 | msgid "Malformed port policy `%s'\n" | 8915 | msgid "Malformed port policy `%s'\n" |
8810 | msgstr "" | 8916 | msgstr "" |
8811 | 8917 | ||
8812 | #: src/util/strings.c:1328 src/util/strings.c:1357 src/util/strings.c:1404 | 8918 | #: src/util/strings.c:1355 src/util/strings.c:1384 src/util/strings.c:1431 |
8813 | #: src/util/strings.c:1424 | 8919 | #: src/util/strings.c:1451 |
8814 | #, c-format | 8920 | #, c-format |
8815 | msgid "Invalid format for IP: `%s'\n" | 8921 | msgid "Invalid format for IP: `%s'\n" |
8816 | msgstr "Ungültiges Format für IP: »%s«\n" | 8922 | msgstr "Ungültiges Format für IP: »%s«\n" |
8817 | 8923 | ||
8818 | #: src/util/strings.c:1382 | 8924 | #: src/util/strings.c:1409 |
8819 | #, c-format | 8925 | #, c-format |
8820 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." | 8926 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." |
8821 | msgstr "Ungültige Netzwerk-Notation ('/%d ist nicht gültig in IPv4 CIDR)." | 8927 | msgstr "Ungültige Netzwerk-Notation ('/%d ist nicht gültig in IPv4 CIDR)." |
8822 | 8928 | ||
8823 | #: src/util/strings.c:1433 | 8929 | #: src/util/strings.c:1460 |
8824 | #, fuzzy, c-format | 8930 | #, fuzzy, c-format |
8825 | msgid "Invalid format: `%s'\n" | 8931 | msgid "Invalid format: `%s'\n" |
8826 | msgstr "Ungültiges Format für IP: `%s'\n" | 8932 | msgstr "Ungültiges Format für IP: `%s'\n" |
8827 | 8933 | ||
8828 | #: src/util/strings.c:1475 | 8934 | #: src/util/strings.c:1502 |
8829 | #, c-format | 8935 | #, c-format |
8830 | msgid "Invalid network notation (does not end with ';': `%s')\n" | 8936 | msgid "Invalid network notation (does not end with ';': `%s')\n" |
8831 | msgstr "Ungültige Netzwerk-Notation (endet nicht mit »;«: »%s«)\n" | 8937 | msgstr "Ungültige Netzwerk-Notation (endet nicht mit »;«: »%s«)\n" |
8832 | 8938 | ||
8833 | #: src/util/strings.c:1525 | 8939 | #: src/util/strings.c:1552 |
8834 | #, fuzzy, c-format | 8940 | #, fuzzy, c-format |
8835 | msgid "Wrong format `%s' for netmask\n" | 8941 | msgid "Wrong format `%s' for netmask\n" |
8836 | msgstr "Falsches Format `%s' für Netzmaske: %s\n" | 8942 | msgstr "Falsches Format `%s' für Netzmaske: %s\n" |
8837 | 8943 | ||
8838 | #: src/util/strings.c:1556 | 8944 | #: src/util/strings.c:1583 |
8839 | #, fuzzy, c-format | 8945 | #, fuzzy, c-format |
8840 | msgid "Wrong format `%s' for network\n" | 8946 | msgid "Wrong format `%s' for network\n" |
8841 | msgstr "Falsches Format `%s' für Netzwerk: %s\n" | 8947 | msgstr "Falsches Format `%s' für Netzwerk: %s\n" |
8842 | 8948 | ||
8843 | #: src/util/time.c:863 src/util/time.c:891 | 8949 | #: src/util/time.c:870 src/util/time.c:898 |
8844 | #, c-format | 8950 | #, c-format |
8845 | msgid "Failed to map `%s', cannot assure monotonic time!\n" | 8951 | msgid "Failed to map `%s', cannot assure monotonic time!\n" |
8846 | msgstr "" | 8952 | msgstr "" |
8847 | 8953 | ||
8848 | #: src/util/time.c:899 | 8954 | #: src/util/time.c:906 |
8849 | #, c-format | 8955 | #, c-format |
8850 | msgid "" | 8956 | msgid "" |
8851 | "Failed to setup monotonic time file `%s', cannot assure monotonic time!\n" | 8957 | "Failed to setup monotonic time file `%s', cannot assure monotonic time!\n" |
@@ -9025,12 +9131,26 @@ msgstr "Dienst wird über UDP angeboten" | |||
9025 | msgid "Setup tunnels via VPN." | 9131 | msgid "Setup tunnels via VPN." |
9026 | msgstr "Tunnel über VPN einrichten." | 9132 | msgstr "Tunnel über VPN einrichten." |
9027 | 9133 | ||
9028 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:418 | 9134 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:397 |
9029 | #: src/zonemaster/gnunet-service-zonemaster.c:847 | 9135 | #: src/zonemaster/gnunet-service-zonemaster.c:832 |
9030 | #, fuzzy | 9136 | #, fuzzy |
9031 | msgid "Failed to connect to the namestore!\n" | 9137 | msgid "Failed to connect to the namestore!\n" |
9032 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" | 9138 | msgstr "Es konnte keine Verbindung mit gnunetd hergestellt werden.\n" |
9033 | 9139 | ||
9140 | #~ msgid "# items stored" | ||
9141 | #~ msgstr "# gespeicherte Objekte" | ||
9142 | |||
9143 | #, fuzzy, c-format | ||
9144 | #~ msgid "Failed to load datacache plugin for `%s'\n" | ||
9145 | #~ msgstr "Fehler beim Aktualisieren der Daten des Moduls `%s'\n" | ||
9146 | |||
9147 | #~ msgid "# requests received" | ||
9148 | #~ msgstr "# Anfragen empfangen" | ||
9149 | |||
9150 | #, fuzzy | ||
9151 | #~ msgid "# proximity search requests received" | ||
9152 | #~ msgstr "# Klartext PONG Nachrichten empfangen" | ||
9153 | |||
9034 | #, fuzzy | 9154 | #, fuzzy |
9035 | #~ msgid "# requests for random value received" | 9155 | #~ msgid "# requests for random value received" |
9036 | #~ msgstr "# Anfragen empfangen" | 9156 | #~ msgstr "# Anfragen empfangen" |
@@ -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: 2022-01-10 15:13+0100\n" | 11 | "POT-Creation-Date: 2022-03-04 22:23+0100\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" |
@@ -18,7 +18,7 @@ msgstr "" | |||
18 | "Content-Transfer-Encoding: 8bit\n" | 18 | "Content-Transfer-Encoding: 8bit\n" |
19 | "Plural-Forms: nplurals=2; plural=(n != 1);\n" | 19 | "Plural-Forms: nplurals=2; plural=(n != 1);\n" |
20 | 20 | ||
21 | #: src/abd/gnunet-abd.c:392 src/namestore/gnunet-namestore.c:1304 | 21 | #: src/abd/gnunet-abd.c:392 src/namestore/gnunet-namestore.c:1254 |
22 | #, fuzzy, c-format | 22 | #, fuzzy, c-format |
23 | msgid "Ego `%s' not known to identity service\n" | 23 | msgid "Ego `%s' not known to identity service\n" |
24 | msgstr "'%s': servicio desconocido: %s\n" | 24 | msgstr "'%s': servicio desconocido: %s\n" |
@@ -30,7 +30,7 @@ msgstr "El bloque del tipo %u está mal formado\n" | |||
30 | 30 | ||
31 | #: src/abd/gnunet-abd.c:558 src/abd/gnunet-service-abd.c:1751 | 31 | #: src/abd/gnunet-abd.c:558 src/abd/gnunet-service-abd.c:1751 |
32 | #: src/namestore/gnunet-namestore-fcfsd.c:1080 | 32 | #: src/namestore/gnunet-namestore-fcfsd.c:1080 |
33 | #: src/namestore/gnunet-namestore.c:1001 | 33 | #: src/namestore/gnunet-namestore.c:951 |
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" |
@@ -664,7 +664,7 @@ msgstr "salida prolija (incluye las propiedades de direcciones del ATS)" | |||
664 | msgid "Print information about ATS state" | 664 | msgid "Print information about ATS state" |
665 | msgstr "Imprime información acerca del estado del ATS" | 665 | msgstr "Imprime información acerca del estado del ATS" |
666 | 666 | ||
667 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | 667 | #: src/ats/gnunet-ats-solver-eval.c:2993 src/ats/gnunet-ats-solver-eval.c:3045 |
668 | #, c-format | 668 | #, c-format |
669 | msgid "" | 669 | msgid "" |
670 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | 670 | "Could not load quota for network `%s': `%s', assigning default bandwidth " |
@@ -673,7 +673,7 @@ msgstr "" | |||
673 | "No se pudieron cargar las cuotas para la red «%s»: «%s», asignando el ancho " | 673 | "No se pudieron cargar las cuotas para la red «%s»: «%s», asignando el ancho " |
674 | "de banda predeterminado %llu\n" | 674 | "de banda predeterminado %llu\n" |
675 | 675 | ||
676 | #: src/ats/gnunet-ats-solver-eval.c:3011 | 676 | #: src/ats/gnunet-ats-solver-eval.c:3012 |
677 | #, c-format | 677 | #, c-format |
678 | msgid "" | 678 | msgid "" |
679 | "No outbound quota configured for network `%s', assigning default bandwidth " | 679 | "No outbound quota configured for network `%s', assigning default bandwidth " |
@@ -682,7 +682,7 @@ msgstr "" | |||
682 | "No hay configurada una cuota de salida para la red «%s», asignando el ancho " | 682 | "No hay configurada una cuota de salida para la red «%s», asignando el ancho " |
683 | "de banda predeterminado %llu\n" | 683 | "de banda predeterminado %llu\n" |
684 | 684 | ||
685 | #: src/ats/gnunet-ats-solver-eval.c:3063 | 685 | #: src/ats/gnunet-ats-solver-eval.c:3064 |
686 | #, c-format | 686 | #, c-format |
687 | msgid "" | 687 | msgid "" |
688 | "No outbound quota configure for network `%s', assigning default bandwidth " | 688 | "No outbound quota configure for network `%s', assigning default bandwidth " |
@@ -691,25 +691,25 @@ msgstr "" | |||
691 | "No hay configurada una cuota de salida para la red «%s», asignando el ancho " | 691 | "No hay configurada una cuota de salida para la red «%s», asignando el ancho " |
692 | "de banda predeterminado %llu\n" | 692 | "de banda predeterminado %llu\n" |
693 | 693 | ||
694 | #: src/ats/gnunet-ats-solver-eval.c:3552 | 694 | #: src/ats/gnunet-ats-solver-eval.c:3553 |
695 | #, fuzzy | 695 | #, fuzzy |
696 | msgid "solver to use" | 696 | msgid "solver to use" |
697 | msgstr "valor a establecer" | 697 | msgstr "valor a establecer" |
698 | 698 | ||
699 | #: src/ats/gnunet-ats-solver-eval.c:3557 | 699 | #: src/ats/gnunet-ats-solver-eval.c:3558 |
700 | msgid "experiment to use" | 700 | msgid "experiment to use" |
701 | msgstr "experimento para usar" | 701 | msgstr "experimento para usar" |
702 | 702 | ||
703 | #: src/ats/gnunet-ats-solver-eval.c:3564 | 703 | #: src/ats/gnunet-ats-solver-eval.c:3565 |
704 | #, fuzzy | 704 | #, fuzzy |
705 | msgid "print logging" | 705 | msgid "print logging" |
706 | msgstr "Iniciando descarga «%s».\n" | 706 | msgstr "Iniciando descarga «%s».\n" |
707 | 707 | ||
708 | #: src/ats/gnunet-ats-solver-eval.c:3569 | 708 | #: src/ats/gnunet-ats-solver-eval.c:3570 |
709 | msgid "save logging to disk" | 709 | msgid "save logging to disk" |
710 | msgstr "guarda protocolo al fichero en disco" | 710 | msgstr "guarda protocolo al fichero en disco" |
711 | 711 | ||
712 | #: src/ats/gnunet-ats-solver-eval.c:3574 | 712 | #: src/ats/gnunet-ats-solver-eval.c:3575 |
713 | msgid "disable normalization" | 713 | msgid "disable normalization" |
714 | msgstr "deshabilita normalización" | 714 | msgstr "deshabilita normalización" |
715 | 715 | ||
@@ -1608,40 +1608,7 @@ msgstr "# mapas de tipos recibidos" | |||
1608 | msgid "# updates to my type map" | 1608 | msgid "# updates to my type map" |
1609 | msgstr "# actualizaciones de mi mapa de tipos" | 1609 | msgstr "# actualizaciones de mi mapa de tipos" |
1610 | 1610 | ||
1611 | #: src/datacache/datacache.c:117 src/datacache/datacache.c:275 | 1611 | #: src/datacache/plugin_datacache_heap.c:555 |
1612 | #: src/datastore/gnunet-service-datastore.c:743 | ||
1613 | msgid "# bytes stored" | ||
1614 | msgstr "# bytes almacenados" | ||
1615 | |||
1616 | #: src/datacache/datacache.c:121 src/datacache/datacache.c:279 | ||
1617 | msgid "# items stored" | ||
1618 | msgstr "# elementos almacenados" | ||
1619 | |||
1620 | #: src/datacache/datacache.c:185 | ||
1621 | #, c-format | ||
1622 | msgid "Loading `%s' datacache plugin\n" | ||
1623 | msgstr "Cargando el módulo de la cache de datos «%s»\n" | ||
1624 | |||
1625 | #: src/datacache/datacache.c:203 | ||
1626 | #, c-format | ||
1627 | msgid "Failed to load datacache plugin for `%s'\n" | ||
1628 | msgstr "" | ||
1629 | "Se produjo un fallo al cargar el módulo de la cache de datos para «%s»\n" | ||
1630 | |||
1631 | #: src/datacache/datacache.c:297 | ||
1632 | msgid "# requests received" | ||
1633 | msgstr "# peticiones recibidas" | ||
1634 | |||
1635 | #: src/datacache/datacache.c:308 | ||
1636 | msgid "# requests filtered by bloom filter" | ||
1637 | msgstr "# peticiones filtradas por el «bloomfilter»" | ||
1638 | |||
1639 | #: src/datacache/datacache.c:329 | ||
1640 | #, fuzzy | ||
1641 | msgid "# proximity search requests received" | ||
1642 | msgstr "# búsquedas de clientes recibidas" | ||
1643 | |||
1644 | #: src/datacache/plugin_datacache_heap.c:527 | ||
1645 | msgid "Heap datacache running\n" | 1612 | msgid "Heap datacache running\n" |
1646 | msgstr "Caché de datos de montÃculo (heap) ejecutándose\n" | 1613 | msgstr "Caché de datos de montÃculo (heap) ejecutándose\n" |
1647 | 1614 | ||
@@ -1663,7 +1630,7 @@ msgstr "Caché de datos de montÃculo (heap) ejecutándose\n" | |||
1663 | msgid "`%s' failed at %s:%d with error: %s\n" | 1630 | msgid "`%s' failed at %s:%d with error: %s\n" |
1664 | msgstr "«%s» falló en %s: %d con el error: %s\n" | 1631 | msgstr "«%s» falló en %s: %d con el error: %s\n" |
1665 | 1632 | ||
1666 | #: src/datacache/plugin_datacache_sqlite.c:693 | 1633 | #: src/datacache/plugin_datacache_sqlite.c:723 |
1667 | #: src/datastore/plugin_datastore_sqlite.c:531 | 1634 | #: src/datastore/plugin_datastore_sqlite.c:531 |
1668 | #: src/namecache/plugin_namecache_sqlite.c:237 | 1635 | #: src/namecache/plugin_namecache_sqlite.c:237 |
1669 | #: src/namestore/plugin_namestore_sqlite.c:273 | 1636 | #: src/namestore/plugin_namestore_sqlite.c:273 |
@@ -1856,6 +1823,10 @@ msgstr "# reservado" | |||
1856 | msgid "Could not find matching reservation" | 1823 | msgid "Could not find matching reservation" |
1857 | msgstr "No se pudo encontrar una reserva coincidente" | 1824 | msgstr "No se pudo encontrar una reserva coincidente" |
1858 | 1825 | ||
1826 | #: src/datastore/gnunet-service-datastore.c:743 | ||
1827 | msgid "# bytes stored" | ||
1828 | msgstr "# bytes almacenados" | ||
1829 | |||
1859 | #: src/datastore/gnunet-service-datastore.c:758 | 1830 | #: src/datastore/gnunet-service-datastore.c:758 |
1860 | #, c-format | 1831 | #, c-format |
1861 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" | 1832 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" |
@@ -2051,7 +2022,7 @@ msgstr "" | |||
2051 | 2022 | ||
2052 | #: src/datastore/plugin_datastore_sqlite.c:1337 | 2023 | #: src/datastore/plugin_datastore_sqlite.c:1337 |
2053 | #: src/namecache/plugin_namecache_sqlite.c:564 | 2024 | #: src/namecache/plugin_namecache_sqlite.c:564 |
2054 | #: src/namestore/plugin_namestore_sqlite.c:765 | 2025 | #: src/namestore/plugin_namestore_sqlite.c:775 |
2055 | msgid "Sqlite database running\n" | 2026 | msgid "Sqlite database running\n" |
2056 | msgstr "Base de datos sqlite ejecutándose\n" | 2027 | msgstr "Base de datos sqlite ejecutándose\n" |
2057 | 2028 | ||
@@ -2059,7 +2030,7 @@ msgstr "Base de datos sqlite ejecutándose\n" | |||
2059 | msgid "Template database running\n" | 2030 | msgid "Template database running\n" |
2060 | msgstr "Base de datos de plantilla ejecutándose\n" | 2031 | msgstr "Base de datos de plantilla ejecutándose\n" |
2061 | 2032 | ||
2062 | #: src/dht/gnunet-dht-get.c:159 | 2033 | #: src/dht/gnunet-dht-get.c:164 |
2063 | #, c-format | 2034 | #, c-format |
2064 | msgid "" | 2035 | msgid "" |
2065 | "Result %d, type %d:\n" | 2036 | "Result %d, type %d:\n" |
@@ -2068,52 +2039,63 @@ msgstr "" | |||
2068 | "Resultado %d, tipo %d:\n" | 2039 | "Resultado %d, tipo %d:\n" |
2069 | "%.*s\n" | 2040 | "%.*s\n" |
2070 | 2041 | ||
2071 | #: src/dht/gnunet-dht-get.c:160 | 2042 | #: src/dht/gnunet-dht-get.c:165 |
2072 | #, fuzzy, c-format | 2043 | #, fuzzy, c-format |
2073 | msgid "Result %d, type %d:\n" | 2044 | msgid "Result %d, type %d:\n" |
2074 | msgstr "" | 2045 | msgstr "" |
2075 | "Resultado %d, tipo %d:\n" | 2046 | "Resultado %d, tipo %d:\n" |
2076 | "%.*s\n" | 2047 | "%.*s\n" |
2077 | 2048 | ||
2078 | #: src/dht/gnunet-dht-get.c:209 | 2049 | #: src/dht/gnunet-dht-get.c:215 |
2079 | msgid "Must provide key for DHT GET!\n" | 2050 | msgid "Must provide key for DHT GET!\n" |
2080 | msgstr "¡Se debe proveer una clave para el «GET» DHT!\n" | 2051 | msgstr "¡Se debe proveer una clave para el «GET» DHT!\n" |
2081 | 2052 | ||
2082 | #: src/dht/gnunet-dht-get.c:217 src/dht/gnunet-dht-monitor.c:255 | 2053 | #: src/dht/gnunet-dht-get.c:223 src/dht/gnunet-dht-hello.c:119 |
2054 | #: src/dht/gnunet-dht-monitor.c:255 | ||
2055 | #, c-format | ||
2083 | msgid "Failed to connect to DHT service!\n" | 2056 | msgid "Failed to connect to DHT service!\n" |
2084 | msgstr "¡Se produjo un fallo al conectar con el servicio DHT!\n" | 2057 | msgstr "¡Se produjo un fallo al conectar con el servicio DHT!\n" |
2085 | 2058 | ||
2086 | #: src/dht/gnunet-dht-get.c:227 | 2059 | #: src/dht/gnunet-dht-get.c:233 |
2087 | #, fuzzy | 2060 | #, fuzzy |
2088 | msgid "Issuing DHT GET with key" | 2061 | msgid "Issuing DHT GET with key" |
2089 | msgstr "Enviando un «GET» DHT con clave" | 2062 | msgstr "Enviando un «GET» DHT con clave" |
2090 | 2063 | ||
2091 | #: src/dht/gnunet-dht-get.c:260 src/dht/gnunet-dht-monitor.c:302 | 2064 | #: src/dht/gnunet-dht-get.c:269 src/dht/gnunet-dht-monitor.c:302 |
2092 | #: src/dht/gnunet-dht-put.c:200 | 2065 | #: src/dht/gnunet-dht-put.c:200 |
2093 | msgid "the query key" | 2066 | msgid "the query key" |
2094 | msgstr "la clave de búsqueda" | 2067 | msgstr "la clave de búsqueda" |
2095 | 2068 | ||
2096 | #: src/dht/gnunet-dht-get.c:266 | 2069 | #: src/dht/gnunet-dht-get.c:275 |
2097 | msgid "how many parallel requests (replicas) to create" | 2070 | msgid "how many parallel requests (replicas) to create" |
2098 | msgstr "cuantas peticiones paralelas (réplicas) crear" | 2071 | msgstr "cuantas peticiones paralelas (réplicas) crear" |
2099 | 2072 | ||
2100 | #: src/dht/gnunet-dht-get.c:272 src/dht/gnunet-dht-monitor.c:308 | 2073 | #: src/dht/gnunet-dht-get.c:280 src/dht/gnunet-dht-put.c:217 |
2074 | #, fuzzy | ||
2075 | msgid "use DHT's record route option" | ||
2076 | msgstr "opción para usar el demultiplexado de la DHT siempre" | ||
2077 | |||
2078 | #: src/dht/gnunet-dht-get.c:286 src/dht/gnunet-dht-monitor.c:308 | ||
2101 | msgid "the type of data to look for" | 2079 | msgid "the type of data to look for" |
2102 | msgstr "el tipo de datos a buscar" | 2080 | msgstr "el tipo de datos a buscar" |
2103 | 2081 | ||
2104 | #: src/dht/gnunet-dht-get.c:278 | 2082 | #: src/dht/gnunet-dht-get.c:292 |
2105 | msgid "how long to execute this query before giving up?" | 2083 | msgid "how long to execute this query before giving up?" |
2106 | msgstr "¿cuánto tiempo se debe ejecutar esta consulta antes de abandonar?" | 2084 | msgstr "¿cuánto tiempo se debe ejecutar esta consulta antes de abandonar?" |
2107 | 2085 | ||
2108 | #: src/dht/gnunet-dht-get.c:284 src/dht/gnunet-dht-put.c:206 | 2086 | #: src/dht/gnunet-dht-get.c:298 src/dht/gnunet-dht-put.c:206 |
2109 | msgid "use DHT's demultiplex everywhere option" | 2087 | msgid "use DHT's demultiplex everywhere option" |
2110 | msgstr "opción para usar el demultiplexado de la DHT siempre" | 2088 | msgstr "opción para usar el demultiplexado de la DHT siempre" |
2111 | 2089 | ||
2112 | #: src/dht/gnunet-dht-get.c:301 | 2090 | #: src/dht/gnunet-dht-get.c:315 |
2113 | msgid "Issue a GET request to the GNUnet DHT, prints results." | 2091 | msgid "Issue a GET request to the GNUnet DHT, prints results." |
2114 | msgstr "" | 2092 | msgstr "" |
2115 | "Iniciando una peticion «GET» a la DHT de GNUnet, imprimiendo resultados." | 2093 | "Iniciando una peticion «GET» a la DHT de GNUnet, imprimiendo resultados." |
2116 | 2094 | ||
2095 | #: src/dht/gnunet-dht-hello.c:166 | ||
2096 | msgid "Obtain HELLO from DHT or provide HELLO to DHT for bootstrapping" | ||
2097 | msgstr "" | ||
2098 | |||
2117 | #: src/dht/gnunet-dht-monitor.c:315 | 2099 | #: src/dht/gnunet-dht-monitor.c:315 |
2118 | msgid "how long should the monitor command run" | 2100 | msgid "how long should the monitor command run" |
2119 | msgstr "cuanto tiempo debe ejecutarse el comando de monitorización" | 2101 | msgstr "cuanto tiempo debe ejecutarse el comando de monitorización" |
@@ -2153,11 +2135,6 @@ msgstr "cuanto tiempo almacenar esta entrada en la DHT (en segundos)" | |||
2153 | msgid "how many replicas to create" | 2135 | msgid "how many replicas to create" |
2154 | msgstr "cuantas réplicas crear" | 2136 | msgstr "cuantas réplicas crear" |
2155 | 2137 | ||
2156 | #: src/dht/gnunet-dht-put.c:217 | ||
2157 | #, fuzzy | ||
2158 | msgid "use DHT's record route option" | ||
2159 | msgstr "opción para usar el demultiplexado de la DHT siempre" | ||
2160 | |||
2161 | #: src/dht/gnunet-dht-put.c:223 | 2138 | #: src/dht/gnunet-dht-put.c:223 |
2162 | msgid "the type to insert data as" | 2139 | msgid "the type to insert data as" |
2163 | msgstr "el tipo de datos a insertar" | 2140 | msgstr "el tipo de datos a insertar" |
@@ -2217,17 +2194,17 @@ msgstr "" | |||
2217 | msgid "Measure quality and performance of the DHT service." | 2194 | msgid "Measure quality and performance of the DHT service." |
2218 | msgstr "Medir la calidad y rendimiento del servicio NSE." | 2195 | msgstr "Medir la calidad y rendimiento del servicio NSE." |
2219 | 2196 | ||
2220 | #: src/dht/plugin_block_dht.c:328 | 2197 | #: src/dht/plugin_block_dht.c:404 |
2221 | #, c-format | 2198 | #, c-format |
2222 | msgid "Block not of type %u\n" | 2199 | msgid "Block not of type %u\n" |
2223 | msgstr "El bloque no es del tipo %u\n" | 2200 | msgstr "El bloque no es del tipo %u\n" |
2224 | 2201 | ||
2225 | #: src/dht/plugin_block_dht.c:337 | 2202 | #: src/dht/plugin_block_dht.c:413 |
2226 | #, fuzzy, c-format | 2203 | #, fuzzy, c-format |
2227 | msgid "Size mismatch for block with type %u\n" | 2204 | msgid "Size mismatch for block with type %u\n" |
2228 | msgstr "Discrepancias de tamaños para el bloque\n" | 2205 | msgstr "Discrepancias de tamaños para el bloque\n" |
2229 | 2206 | ||
2230 | #: src/dht/plugin_block_dht.c:348 | 2207 | #: src/dht/plugin_block_dht.c:424 |
2231 | #, c-format | 2208 | #, c-format |
2232 | msgid "Block of type %u is malformed\n" | 2209 | msgid "Block of type %u is malformed\n" |
2233 | msgstr "El bloque del tipo %u está mal formado\n" | 2210 | msgstr "El bloque del tipo %u está mal formado\n" |
@@ -2995,20 +2972,20 @@ msgstr "URI SKS mal formada (no se encuentra el tiempo de expiración)" | |||
2995 | msgid "LOC URI malformed (signature failed validation)" | 2972 | msgid "LOC URI malformed (signature failed validation)" |
2996 | msgstr "URI SKS mal formada (se produjo un fallo al validar la firma)" | 2973 | msgstr "URI SKS mal formada (se produjo un fallo al validar la firma)" |
2997 | 2974 | ||
2998 | #: src/fs/fs_uri.c:653 | 2975 | #: src/fs/fs_uri.c:652 |
2999 | #, fuzzy | 2976 | #, fuzzy |
3000 | msgid "invalid argument" | 2977 | msgid "invalid argument" |
3001 | msgstr "Parámetro no válido «%s»\n" | 2978 | msgstr "Parámetro no válido «%s»\n" |
3002 | 2979 | ||
3003 | #: src/fs/fs_uri.c:665 | 2980 | #: src/fs/fs_uri.c:671 |
3004 | msgid "Unrecognized URI type" | 2981 | msgid "Unrecognized URI type" |
3005 | msgstr "Tipo de URI no reconocido" | 2982 | msgstr "Tipo de URI no reconocido" |
3006 | 2983 | ||
3007 | #: src/fs/fs_uri.c:1071 src/fs/fs_uri.c:1098 | 2984 | #: src/fs/fs_uri.c:1075 src/fs/fs_uri.c:1102 |
3008 | msgid "No keywords specified!\n" | 2985 | msgid "No keywords specified!\n" |
3009 | msgstr "¡Ninguna palabra clave especificada!\n" | 2986 | msgstr "¡Ninguna palabra clave especificada!\n" |
3010 | 2987 | ||
3011 | #: src/fs/fs_uri.c:1104 | 2988 | #: src/fs/fs_uri.c:1108 |
3012 | msgid "Number of double-quotes not balanced!\n" | 2989 | msgid "Number of double-quotes not balanced!\n" |
3013 | msgstr "¡Número de comillas dobles no balanceado!\n" | 2990 | msgstr "¡Número de comillas dobles no balanceado!\n" |
3014 | 2991 | ||
@@ -3137,7 +3114,7 @@ msgid "Downloading `%s' done (%s/s).\n" | |||
3137 | msgstr "Finalizada descarga «%s» (%s/s).\n" | 3114 | msgstr "Finalizada descarga «%s» (%s/s).\n" |
3138 | 3115 | ||
3139 | #: src/fs/gnunet-download.c:206 src/fs/gnunet-publish.c:299 | 3116 | #: src/fs/gnunet-download.c:206 src/fs/gnunet-publish.c:299 |
3140 | #: src/fs/gnunet-search.c:229 src/fs/gnunet-unindex.c:117 | 3117 | #: src/fs/gnunet-search.c:538 src/fs/gnunet-unindex.c:117 |
3141 | #, c-format | 3118 | #, c-format |
3142 | msgid "Unexpected status: %d\n" | 3119 | msgid "Unexpected status: %d\n" |
3143 | msgstr "Estado inesperado: %d\n" | 3120 | msgstr "Estado inesperado: %d\n" |
@@ -3160,12 +3137,12 @@ msgid "Target filename must be specified.\n" | |||
3160 | msgstr "El nombre de fichero de destino debe ser especificado.\n" | 3137 | msgstr "El nombre de fichero de destino debe ser especificado.\n" |
3161 | 3138 | ||
3162 | #: src/fs/gnunet-download.c:271 src/fs/gnunet-publish.c:869 | 3139 | #: src/fs/gnunet-download.c:271 src/fs/gnunet-publish.c:869 |
3163 | #: src/fs/gnunet-search.c:294 src/fs/gnunet-unindex.c:154 | 3140 | #: src/fs/gnunet-unindex.c:154 |
3164 | #, c-format | 3141 | #, c-format |
3165 | msgid "Could not initialize `%s' subsystem.\n" | 3142 | msgid "Could not initialize `%s' subsystem.\n" |
3166 | msgstr "No se pudo inicializar el subsistema «%s».\n" | 3143 | msgstr "No se pudo inicializar el subsistema «%s».\n" |
3167 | 3144 | ||
3168 | #: src/fs/gnunet-download.c:318 src/fs/gnunet-search.c:334 | 3145 | #: src/fs/gnunet-download.c:318 |
3169 | msgid "set the desired LEVEL of receiver-anonymity" | 3146 | msgid "set the desired LEVEL of receiver-anonymity" |
3170 | msgstr "establece el nivel LEVEL deseado de anonimato del receptor" | 3147 | msgstr "establece el nivel LEVEL deseado de anonimato del receptor" |
3171 | 3148 | ||
@@ -3173,7 +3150,7 @@ msgstr "establece el nivel LEVEL deseado de anonimato del receptor" | |||
3173 | msgid "delete incomplete downloads (when aborted with CTRL-C)" | 3150 | msgid "delete incomplete downloads (when aborted with CTRL-C)" |
3174 | msgstr "borra descargas incompletas (cuando fueron abortadas con CTRL-C=" | 3151 | msgstr "borra descargas incompletas (cuando fueron abortadas con CTRL-C=" |
3175 | 3152 | ||
3176 | #: src/fs/gnunet-download.c:330 src/fs/gnunet-search.c:339 | 3153 | #: src/fs/gnunet-download.c:330 src/fs/gnunet-search.c:740 |
3177 | msgid "only search the local peer (no P2P network search)" | 3154 | msgid "only search the local peer (no P2P network search)" |
3178 | msgstr "únicamente buscar en el par local (no buscar en la red P2P)" | 3155 | msgstr "únicamente buscar en el par local (no buscar en la red P2P)" |
3179 | 3156 | ||
@@ -3439,40 +3416,114 @@ msgstr "" | |||
3439 | msgid "Publish a file or directory on GNUnet" | 3416 | msgid "Publish a file or directory on GNUnet" |
3440 | msgstr "Publicar un fichero o un directorio en GNUnet" | 3417 | msgstr "Publicar un fichero o un directorio en GNUnet" |
3441 | 3418 | ||
3442 | #: src/fs/gnunet-search.c:130 | 3419 | #: src/fs/gnunet-search.c:441 |
3443 | #, c-format | 3420 | #, c-format |
3444 | msgid "Failed to write directory with search results to `%s'\n" | 3421 | msgid "Failed to write directory with search results to `%s'\n" |
3445 | msgstr "" | 3422 | msgstr "" |
3446 | "Se produjo un fallo al escribir el directorio con los resultados de búsqueda " | 3423 | "Se produjo un fallo al escribir el directorio con los resultados de búsqueda " |
3447 | "de «%s»\n" | 3424 | "de «%s»\n" |
3448 | 3425 | ||
3449 | #: src/fs/gnunet-search.c:219 | 3426 | #: src/fs/gnunet-search.c:527 |
3450 | #, c-format | 3427 | #, c-format |
3451 | msgid "Error searching: %s.\n" | 3428 | msgid "Error searching: %s.\n" |
3452 | msgstr "Error buscando: %s.\n" | 3429 | msgstr "Error buscando: %s.\n" |
3453 | 3430 | ||
3454 | #: src/fs/gnunet-search.c:281 | 3431 | #: src/fs/gnunet-search.c:587 |
3432 | #, c-format | ||
3433 | msgid "Conflicting options --bookmark-only and --silent.\n" | ||
3434 | msgstr "" | ||
3435 | |||
3436 | #: src/fs/gnunet-search.c:594 | ||
3437 | #, c-format | ||
3438 | msgid "Conflicting options --bookmark-only and --output.\n" | ||
3439 | msgstr "" | ||
3440 | |||
3441 | #: src/fs/gnunet-search.c:600 | ||
3442 | #, c-format | ||
3443 | msgid "An output file is mandatory for silent mode.\n" | ||
3444 | msgstr "" | ||
3445 | |||
3446 | #: src/fs/gnunet-search.c:621 | ||
3455 | msgid "Could not create keyword URI from arguments.\n" | 3447 | msgid "Could not create keyword URI from arguments.\n" |
3456 | msgstr "No se pudo crear URI de palabra clave a partir de los parámetros.\n" | 3448 | msgstr "No se pudo crear URI de palabra clave a partir de los parámetros.\n" |
3457 | 3449 | ||
3458 | #: src/fs/gnunet-search.c:308 | 3450 | #: src/fs/gnunet-search.c:629 |
3451 | msgid "" | ||
3452 | "Invalid URI. Valid URIs for searching are keyword query URIs\n" | ||
3453 | "(\"gnunet://fs/ksk/...\") and namespace content URIs (\"gnunet://fs/sks/..." | ||
3454 | "\").\n" | ||
3455 | msgstr "" | ||
3456 | |||
3457 | #: src/fs/gnunet-search.c:654 | ||
3458 | #, fuzzy, c-format | ||
3459 | msgid "Could not initialize the `%s` subsystem.\n" | ||
3460 | msgstr "No se pudo inicializar el subsistema «%s».\n" | ||
3461 | |||
3462 | #: src/fs/gnunet-search.c:668 | ||
3459 | msgid "Could not start searching.\n" | 3463 | msgid "Could not start searching.\n" |
3460 | msgstr "No se pudo empezar a buscar.\n" | 3464 | msgstr "No se pudo empezar a buscar.\n" |
3461 | 3465 | ||
3462 | #: src/fs/gnunet-search.c:345 | 3466 | #: src/fs/gnunet-search.c:694 |
3463 | msgid "write search results to file starting with PREFIX" | 3467 | #, fuzzy |
3464 | msgstr "escribir resultados de búsqueda al fichero que empiecen por «PREFIX»" | 3468 | msgid "set the desired LEVEL of receiver-anonymity (default: 1)" |
3469 | msgstr "establece el nivel LEVEL deseado de anonimato del receptor" | ||
3470 | |||
3471 | #: src/fs/gnunet-search.c:700 | ||
3472 | msgid "do not search, print only the URI that points to this search" | ||
3473 | msgstr "" | ||
3465 | 3474 | ||
3466 | #: src/fs/gnunet-search.c:351 | 3475 | #: src/fs/gnunet-search.c:707 |
3467 | msgid "automatically terminate search after DELAY" | 3476 | msgid "" |
3468 | msgstr "terminar búsqueda automáticamente después de «DELAY»" | 3477 | "write search results for directories according to FORMAT; accepted " |
3478 | "placeholders are: %a, %f, %j, %l, %m, %n, %s; defaults to the value of --" | ||
3479 | "printf when omitted or to `" | ||
3480 | msgstr "" | ||
3469 | 3481 | ||
3470 | #: src/fs/gnunet-search.c:357 | 3482 | #: src/fs/gnunet-search.c:717 |
3483 | msgid "" | ||
3484 | "write search results according to FORMAT; accepted placeholders are: %a, %f, " | ||
3485 | "%j, %l, %m, %n, %s; defaults to `" | ||
3486 | msgstr "" | ||
3487 | |||
3488 | #: src/fs/gnunet-search.c:725 | ||
3489 | msgid "" | ||
3490 | "when the %a or %j placeholders appear in --printf or --dir-printf, list each " | ||
3491 | "metadata property according to FORMAT; accepted placeholders are: %i, %l, " | ||
3492 | "%n, %p" | ||
3493 | msgstr "" | ||
3494 | |||
3495 | #: src/fs/gnunet-search.c:734 | ||
3471 | msgid "automatically terminate search after VALUE results are found" | 3496 | msgid "automatically terminate search after VALUE results are found" |
3472 | msgstr "terminar búsqueda después de «VALUE» resultados encontrados" | 3497 | msgstr "terminar búsqueda después de «VALUE» resultados encontrados" |
3473 | 3498 | ||
3474 | #: src/fs/gnunet-search.c:371 | 3499 | #: src/fs/gnunet-search.c:746 |
3475 | msgid "Search GNUnet for files that were published on GNUnet" | 3500 | msgid "" |
3501 | "create a GNUnet directory with search results at FILENAME (e.g. `gnunet-" | ||
3502 | "search --output=commons" | ||
3503 | msgstr "" | ||
3504 | |||
3505 | #: src/fs/gnunet-search.c:753 | ||
3506 | msgid "silent mode (requires the --output argument)" | ||
3507 | msgstr "" | ||
3508 | |||
3509 | #: src/fs/gnunet-search.c:759 | ||
3510 | msgid "" | ||
3511 | "automatically terminate search after DELAY; the value given must be a number " | ||
3512 | "followed by a space and a time unit, for example \"500 ms\"; without a unit " | ||
3513 | "it defaults to microseconds - 1000000 = 1 second; if 0 or omitted it means " | ||
3514 | "to wait for CTRL-C" | ||
3515 | msgstr "" | ||
3516 | |||
3517 | #: src/fs/gnunet-search.c:768 | ||
3518 | #, c-format | ||
3519 | msgid "" | ||
3520 | "be verbose (append \"%a\\n\" to the default --printf and --dir-printf " | ||
3521 | "arguments - ignored when these are provided by the user)" | ||
3522 | msgstr "" | ||
3523 | |||
3524 | #: src/fs/gnunet-search.c:781 | ||
3525 | #, fuzzy | ||
3526 | msgid "Search for files that have been published on GNUnet\n" | ||
3476 | msgstr "Buscar en GNUnet ficheros que han sido publicados en GNUnet" | 3527 | msgstr "Buscar en GNUnet ficheros que han sido publicados en GNUnet" |
3477 | 3528 | ||
3478 | #: src/fs/gnunet-service-fs.c:371 src/fs/gnunet-service-fs.c:878 | 3529 | #: src/fs/gnunet-service-fs.c:371 src/fs/gnunet-service-fs.c:878 |
@@ -3816,70 +3867,75 @@ msgstr "Desindexa un fichero previamente indexado con «gnunet-publish»." | |||
3816 | msgid "Expected a base32-encoded public zone key\n" | 3867 | msgid "Expected a base32-encoded public zone key\n" |
3817 | msgstr "" | 3868 | msgstr "" |
3818 | 3869 | ||
3819 | #: src/gns/gnunet-bcd.c:571 | 3870 | #: src/gns/gnunet-bcd.c:573 |
3820 | #, fuzzy, c-format | 3871 | #, fuzzy, c-format |
3821 | msgid "Invalid port number %u\n" | 3872 | msgid "Invalid port number %u\n" |
3822 | msgstr "Número de puerto %llu no válido. Saliendo.\n" | 3873 | msgstr "Número de puerto %llu no válido. Saliendo.\n" |
3823 | 3874 | ||
3824 | #: src/gns/gnunet-bcd.c:612 src/namestore/gnunet-namestore-fcfsd.c:1113 | 3875 | #: src/gns/gnunet-bcd.c:614 src/namestore/gnunet-namestore-fcfsd.c:1113 |
3825 | #, fuzzy | 3876 | #, fuzzy |
3826 | msgid "Unable to set up the daemon\n" | 3877 | msgid "Unable to set up the daemon\n" |
3827 | msgstr "Imposible crear la cuenta de usuario:" | 3878 | msgstr "Imposible crear la cuenta de usuario:" |
3828 | 3879 | ||
3829 | #: src/gns/gnunet-bcd.c:635 src/namestore/gnunet-namestore-fcfsd.c:987 | 3880 | #: src/gns/gnunet-bcd.c:637 src/namestore/gnunet-namestore-fcfsd.c:987 |
3830 | msgid "Failed to start HTTP server\n" | 3881 | msgid "Failed to start HTTP server\n" |
3831 | msgstr "Se produjo un fallo al iniciar el servidor HTTP\n" | 3882 | msgstr "Se produjo un fallo al iniciar el servidor HTTP\n" |
3832 | 3883 | ||
3833 | #: src/gns/gnunet-bcd.c:658 | 3884 | #: src/gns/gnunet-bcd.c:660 |
3834 | msgid "Run HTTP server on port PORT (default is 8888)" | 3885 | msgid "Run HTTP server on port PORT (default is 8888)" |
3835 | msgstr "" | 3886 | msgstr "" |
3836 | 3887 | ||
3837 | #: src/gns/gnunet-bcd.c:667 | 3888 | #: src/gns/gnunet-bcd.c:669 |
3838 | msgid "GNUnet HTTP server to create business cards" | 3889 | msgid "GNUnet HTTP server to create business cards" |
3839 | msgstr "" | 3890 | msgstr "" |
3840 | 3891 | ||
3841 | #: src/gns/gnunet-dns2gns.c:241 | 3892 | #: src/gns/gnunet-dns2gns.c:298 |
3842 | msgid "Failed to pack DNS response into UDP packet!\n" | 3893 | msgid "Failed to pack DNS response into UDP packet!\n" |
3843 | msgstr "" | 3894 | msgstr "" |
3844 | "¡Se produjo un fallo al empaquetar una respuesta DNS en un paquete UDP!\n" | 3895 | "¡Se produjo un fallo al empaquetar una respuesta DNS en un paquete UDP!\n" |
3845 | 3896 | ||
3846 | #: src/gns/gnunet-dns2gns.c:315 | 3897 | #: src/gns/gnunet-dns2gns.c:379 |
3847 | #, fuzzy | 3898 | #, fuzzy |
3848 | msgid "Failed to parse DNS response!\n" | 3899 | msgid "Failed to parse DNS response!\n" |
3849 | msgstr "Se produjo un fallo al procesar la petición DNS. Omitiendo.\n" | 3900 | msgstr "Se produjo un fallo al procesar la petición DNS. Omitiendo.\n" |
3850 | 3901 | ||
3851 | #: src/gns/gnunet-dns2gns.c:452 | 3902 | #: src/gns/gnunet-dns2gns.c:453 |
3903 | #, fuzzy, c-format | ||
3904 | msgid "VPN returned empty result for `%s'\n" | ||
3905 | msgstr "El ATS devolvió resultados para %u direcciones\n" | ||
3906 | |||
3907 | #: src/gns/gnunet-dns2gns.c:655 | ||
3852 | #, c-format | 3908 | #, c-format |
3853 | msgid "Cannot parse DNS request from %s\n" | 3909 | msgid "Cannot parse DNS request from %s\n" |
3854 | msgstr "No se puede procesar la petición DNS de %s\n" | 3910 | msgstr "No se puede procesar la petición DNS de %s\n" |
3855 | 3911 | ||
3856 | #: src/gns/gnunet-dns2gns.c:468 | 3912 | #: src/gns/gnunet-dns2gns.c:671 |
3857 | #, c-format | 3913 | #, c-format |
3858 | msgid "Received malformed DNS request from %s\n" | 3914 | msgid "Received malformed DNS request from %s\n" |
3859 | msgstr "Recibida petición DNS mal formada de %s\n" | 3915 | msgstr "Recibida petición DNS mal formada de %s\n" |
3860 | 3916 | ||
3861 | #: src/gns/gnunet-dns2gns.c:476 | 3917 | #: src/gns/gnunet-dns2gns.c:679 |
3862 | #, c-format | 3918 | #, c-format |
3863 | msgid "Received unsupported DNS request from %s\n" | 3919 | msgid "Received unsupported DNS request from %s\n" |
3864 | msgstr "Recibida petición DNS no soportada de %s\n" | 3920 | msgstr "Recibida petición DNS no soportada de %s\n" |
3865 | 3921 | ||
3866 | #: src/gns/gnunet-dns2gns.c:637 | 3922 | #: src/gns/gnunet-dns2gns.c:840 |
3867 | #, fuzzy | 3923 | #, fuzzy |
3868 | msgid "No DNS server specified!\n" | 3924 | msgid "No DNS server specified!\n" |
3869 | msgstr "¡Ninguna palabra clave especificada!\n" | 3925 | msgstr "¡Ninguna palabra clave especificada!\n" |
3870 | 3926 | ||
3871 | #: src/gns/gnunet-dns2gns.c:786 | 3927 | #: src/gns/gnunet-dns2gns.c:995 |
3872 | msgid "IP of recursive DNS resolver to use (required)" | 3928 | msgid "IP of recursive DNS resolver to use (required)" |
3873 | msgstr "IP del resolvedor recursivo DNS a usar (requerido)" | 3929 | msgstr "IP del resolvedor recursivo DNS a usar (requerido)" |
3874 | 3930 | ||
3875 | #: src/gns/gnunet-dns2gns.c:792 | 3931 | #: src/gns/gnunet-dns2gns.c:1001 |
3876 | #, fuzzy | 3932 | #, fuzzy |
3877 | msgid "UDP port to listen on for inbound DNS requests; default: 2853" | 3933 | msgid "UDP port to listen on for inbound DNS requests; default: 2853" |
3878 | msgstr "" | 3934 | msgstr "" |
3879 | "Puerto UDP en el que escuchar para peticiones DNS entrantes; predeterminado: " | 3935 | "Puerto UDP en el que escuchar para peticiones DNS entrantes; predeterminado: " |
3880 | "53" | 3936 | "53" |
3881 | 3937 | ||
3882 | #: src/gns/gnunet-dns2gns.c:809 | 3938 | #: src/gns/gnunet-dns2gns.c:1018 |
3883 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" | 3939 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" |
3884 | msgstr "Pasarela GNUnet DNS-a-GNS (un servidor DNS)" | 3940 | msgstr "Pasarela GNUnet DNS-a-GNS (un servidor DNS)" |
3885 | 3941 | ||
@@ -4063,19 +4119,19 @@ msgstr "" | |||
4063 | msgid "GNUnet GNS resolver tool" | 4119 | msgid "GNUnet GNS resolver tool" |
4064 | msgstr "Herramienta de acceso GNUnet GNS" | 4120 | msgstr "Herramienta de acceso GNUnet GNS" |
4065 | 4121 | ||
4066 | #: src/gns/gnunet-service-gns.c:505 | 4122 | #: src/gns/gnunet-service-gns.c:501 |
4067 | #, fuzzy | 4123 | #, fuzzy |
4068 | msgid "Properly base32-encoded public key required" | 4124 | msgid "Properly base32-encoded public key required" |
4069 | msgstr "Tipo requerido\n" | 4125 | msgstr "Tipo requerido\n" |
4070 | 4126 | ||
4071 | #: src/gns/gnunet-service-gns.c:541 | 4127 | #: src/gns/gnunet-service-gns.c:537 |
4072 | #, fuzzy | 4128 | #, fuzzy |
4073 | msgid "Failed to connect to the namecache!\n" | 4129 | msgid "Failed to connect to the namecache!\n" |
4074 | msgstr "¡Se produjo un fallo al conectar con el almacén de nombres!\n" | 4130 | msgstr "¡Se produjo un fallo al conectar con el almacén de nombres!\n" |
4075 | 4131 | ||
4076 | #: src/gns/gnunet-service-gns.c:560 | 4132 | #: src/gns/gnunet-service-gns.c:556 |
4077 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:442 | 4133 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:421 |
4078 | #: src/zonemaster/gnunet-service-zonemaster.c:885 | 4134 | #: src/zonemaster/gnunet-service-zonemaster.c:870 |
4079 | msgid "Could not connect to DHT!\n" | 4135 | msgid "Could not connect to DHT!\n" |
4080 | msgstr "¡No se pudo conectar a la DHT!\n" | 4136 | msgstr "¡No se pudo conectar a la DHT!\n" |
4081 | 4137 | ||
@@ -4089,97 +4145,100 @@ msgstr "¡Se produjo un error al convertir los argumentos a una URI!\n" | |||
4089 | msgid "Failed to connect to the DNS service!\n" | 4145 | msgid "Failed to connect to the DNS service!\n" |
4090 | msgstr "¡Se produjo un fallo al conectar con el servicio GNS!\n" | 4146 | msgstr "¡Se produjo un fallo al conectar con el servicio GNS!\n" |
4091 | 4147 | ||
4092 | #: src/gns/gnunet-service-gns_resolver.c:706 | 4148 | #: src/gns/gnunet-service-gns_resolver.c:659 |
4093 | #, fuzzy, c-format | 4149 | #, fuzzy, c-format |
4094 | msgid "Protocol `%s' unknown, skipping labels.\n" | 4150 | msgid "Protocol `%s' unknown, skipping labels.\n" |
4095 | msgstr "Módulo «%s» no encontrado\n" | 4151 | msgstr "Módulo «%s» no encontrado\n" |
4096 | 4152 | ||
4097 | #: src/gns/gnunet-service-gns_resolver.c:718 | 4153 | #: src/gns/gnunet-service-gns_resolver.c:671 |
4098 | #, c-format | 4154 | #, c-format |
4099 | msgid "Service `%s' unknown for protocol `%s', trying as number.\n" | 4155 | msgid "Service `%s' unknown for protocol `%s', trying as number.\n" |
4100 | msgstr "" | 4156 | msgstr "" |
4101 | 4157 | ||
4102 | #: src/gns/gnunet-service-gns_resolver.c:724 | 4158 | #: src/gns/gnunet-service-gns_resolver.c:677 |
4103 | #, fuzzy, c-format | 4159 | #, fuzzy, c-format |
4104 | msgid "Service `%s' not a port, skipping service labels.\n" | 4160 | msgid "Service `%s' not a port, skipping service labels.\n" |
4105 | msgstr "Módulo «%s» no encontrado\n" | 4161 | msgstr "Módulo «%s» no encontrado\n" |
4106 | 4162 | ||
4107 | #: src/gns/gnunet-service-gns_resolver.c:938 | 4163 | #: src/gns/gnunet-service-gns_resolver.c:891 |
4108 | #, fuzzy | 4164 | #, fuzzy |
4109 | msgid "Failed to parse DNS response\n" | 4165 | msgid "Failed to parse DNS response\n" |
4110 | msgstr "Se produjo un fallo al procesar la petición DNS. Omitiendo.\n" | 4166 | msgstr "Se produjo un fallo al procesar la petición DNS. Omitiendo.\n" |
4111 | 4167 | ||
4112 | #: src/gns/gnunet-service-gns_resolver.c:1129 | 4168 | #: src/gns/gnunet-service-gns_resolver.c:1082 |
4113 | #, c-format | 4169 | #, c-format |
4114 | msgid "Skipping record of unsupported type %d\n" | 4170 | msgid "Skipping record of unsupported type %d\n" |
4115 | msgstr "" | 4171 | msgstr "" |
4116 | 4172 | ||
4117 | #: src/gns/gnunet-service-gns_resolver.c:1447 | 4173 | #: src/gns/gnunet-service-gns_resolver.c:1859 |
4118 | #, fuzzy, c-format | ||
4119 | msgid "VPN returned empty result for `%s'\n" | ||
4120 | msgstr "El ATS devolvió resultados para %u direcciones\n" | ||
4121 | |||
4122 | #: src/gns/gnunet-service-gns_resolver.c:1919 | ||
4123 | #, c-format | 4174 | #, c-format |
4124 | msgid "Name `%s' cannot be converted to IDNA." | 4175 | msgid "Name `%s' cannot be converted to IDNA." |
4125 | msgstr "" | 4176 | msgstr "" |
4126 | 4177 | ||
4127 | #: src/gns/gnunet-service-gns_resolver.c:1934 | 4178 | #: src/gns/gnunet-service-gns_resolver.c:1874 |
4128 | #, c-format | 4179 | #, c-format |
4129 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" | 4180 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" |
4130 | msgstr "" | 4181 | msgstr "" |
4131 | 4182 | ||
4132 | #: src/gns/gnunet-service-gns_resolver.c:1979 | 4183 | #: src/gns/gnunet-service-gns_resolver.c:1914 |
4133 | #, fuzzy, c-format | 4184 | #, fuzzy, c-format |
4134 | msgid "GNS lookup failed (zero records found for `%s')\n" | 4185 | msgid "GNS lookup failed (zero records found for `%s')\n" |
4135 | msgstr "No se han encontrado ficheros en «%s»\n" | 4186 | msgstr "No se han encontrado ficheros en «%s»\n" |
4136 | 4187 | ||
4137 | #: src/gns/gnunet-service-gns_resolver.c:2406 | 4188 | #: src/gns/gnunet-service-gns_resolver.c:2312 |
4189 | msgid "Unable to process critical delegation record\n" | ||
4190 | msgstr "" | ||
4191 | |||
4192 | #: src/gns/gnunet-service-gns_resolver.c:2317 | ||
4138 | msgid "GNS lookup recursion failed (no delegation record found)\n" | 4193 | msgid "GNS lookup recursion failed (no delegation record found)\n" |
4139 | msgstr "" | 4194 | msgstr "" |
4140 | 4195 | ||
4141 | #: src/gns/gnunet-service-gns_resolver.c:2429 | 4196 | #: src/gns/gnunet-service-gns_resolver.c:2340 |
4142 | #, fuzzy, c-format | 4197 | #, fuzzy, c-format |
4143 | msgid "Failed to cache GNS resolution: %s\n" | 4198 | msgid "Failed to cache GNS resolution: %s\n" |
4144 | msgstr "Se produjo un fallo al mandar la petición DNS a %s\n" | 4199 | msgstr "Se produjo un fallo al mandar la petición DNS a %s\n" |
4145 | 4200 | ||
4146 | #: src/gns/gnunet-service-gns_resolver.c:2594 | 4201 | #: src/gns/gnunet-service-gns_resolver.c:2505 |
4147 | #, c-format | 4202 | #, c-format |
4148 | msgid "GNS namecache returned empty result for `%s'\n" | 4203 | msgid "GNS namecache returned empty result for `%s'\n" |
4149 | msgstr "" | 4204 | msgstr "" |
4150 | 4205 | ||
4151 | #: src/gns/gnunet-service-gns_resolver.c:2734 | 4206 | #: src/gns/gnunet-service-gns_resolver.c:2652 |
4152 | #, c-format | 4207 | #, c-format |
4153 | msgid "Zone %s was revoked, resolution fails\n" | 4208 | msgid "Zone %s was revoked, resolution fails\n" |
4154 | msgstr "" | 4209 | msgstr "" |
4155 | 4210 | ||
4156 | #: src/gns/plugin_gnsrecord_gns.c:174 | 4211 | #: src/gns/plugin_gnsrecord_gns.c:136 |
4212 | msgid "This is a memento of an older block for internal maintenance." | ||
4213 | msgstr "" | ||
4214 | |||
4215 | #: src/gns/plugin_gnsrecord_gns.c:175 | ||
4157 | #, fuzzy, c-format | 4216 | #, fuzzy, c-format |
4158 | msgid "Unable to parse zone key record `%s'\n" | 4217 | msgid "Unable to parse zone key record `%s'\n" |
4159 | msgstr "No se pudo procesar el registro MX «%s»\n" | 4218 | msgstr "No se pudo procesar el registro MX «%s»\n" |
4160 | 4219 | ||
4161 | #: src/gns/plugin_gnsrecord_gns.c:187 | 4220 | #: src/gns/plugin_gnsrecord_gns.c:188 |
4162 | msgid "Record type does not match parsed record type\n" | 4221 | msgid "Record type does not match parsed record type\n" |
4163 | msgstr "" | 4222 | msgstr "" |
4164 | 4223 | ||
4165 | #: src/gns/plugin_gnsrecord_gns.c:213 | 4224 | #: src/gns/plugin_gnsrecord_gns.c:211 |
4166 | #, fuzzy, c-format | 4225 | #, fuzzy, c-format |
4167 | msgid "Unable to parse GNS2DNS record `%s'\n" | 4226 | msgid "Unable to parse GNS2DNS record `%s'\n" |
4168 | msgstr "No se pudo procesar el registro SOA «%s»\n" | 4227 | msgstr "No se pudo procesar el registro SOA «%s»\n" |
4169 | 4228 | ||
4170 | #: src/gns/plugin_gnsrecord_gns.c:229 | 4229 | #: src/gns/plugin_gnsrecord_gns.c:227 |
4171 | #, fuzzy, c-format | 4230 | #, fuzzy, c-format |
4172 | msgid "Failed to serialize GNS2DNS record with value `%s': Not a DNS name.\n" | 4231 | msgid "Failed to serialize GNS2DNS record with value `%s': Not a DNS name.\n" |
4173 | msgstr "" | 4232 | msgstr "" |
4174 | "Se produjo un fallo al escribir el directorio con los resultados de búsqueda " | 4233 | "Se produjo un fallo al escribir el directorio con los resultados de búsqueda " |
4175 | "de «%s»\n" | 4234 | "de «%s»\n" |
4176 | 4235 | ||
4177 | #: src/gns/plugin_gnsrecord_gns.c:253 | 4236 | #: src/gns/plugin_gnsrecord_gns.c:251 |
4178 | #, c-format | 4237 | #, c-format |
4179 | msgid "Unable to parse VPN record string `%s'\n" | 4238 | msgid "Unable to parse VPN record string `%s'\n" |
4180 | msgstr "No se pudo procesar la cadena de registro VPN «%s»\n" | 4239 | msgstr "No se pudo procesar la cadena de registro VPN «%s»\n" |
4181 | 4240 | ||
4182 | #: src/gns/plugin_gnsrecord_gns.c:285 | 4241 | #: src/gns/plugin_gnsrecord_gns.c:283 |
4183 | #, fuzzy, c-format | 4242 | #, fuzzy, c-format |
4184 | msgid "Unable to parse BOX record string `%s'\n" | 4243 | msgid "Unable to parse BOX record string `%s'\n" |
4185 | msgstr "No se pudo procesar la cadena de registro VPN «%s»\n" | 4244 | msgstr "No se pudo procesar la cadena de registro VPN «%s»\n" |
@@ -4189,6 +4248,34 @@ msgstr "No se pudo procesar la cadena de registro VPN «%s»\n" | |||
4189 | msgid "Gns REST API initialized\n" | 4248 | msgid "Gns REST API initialized\n" |
4190 | msgstr "Conexión fallida\n" | 4249 | msgstr "Conexión fallida\n" |
4191 | 4250 | ||
4251 | #: src/gnsrecord/gnsrecord_misc.c:448 | ||
4252 | msgid "Zone delegation record not allowed in apex." | ||
4253 | msgstr "" | ||
4254 | |||
4255 | #: src/gnsrecord/gnsrecord_misc.c:456 | ||
4256 | msgid "Zone delegation record set contains mutually exclusive records." | ||
4257 | msgstr "" | ||
4258 | |||
4259 | #: src/gnsrecord/gnsrecord_misc.c:466 | ||
4260 | msgid "Multiple REDIRECT records." | ||
4261 | msgstr "" | ||
4262 | |||
4263 | #: src/gnsrecord/gnsrecord_misc.c:475 src/gnsrecord/gnsrecord_misc.c:501 | ||
4264 | msgid "Redirection record set conains mutually exclusive records." | ||
4265 | msgstr "" | ||
4266 | |||
4267 | #: src/gnsrecord/gnsrecord_misc.c:482 | ||
4268 | msgid "Redirection records not allowed in apex." | ||
4269 | msgstr "" | ||
4270 | |||
4271 | #: src/gnsrecord/gnsrecord_misc.c:493 | ||
4272 | msgid "Redirection records not allowed in apex.." | ||
4273 | msgstr "" | ||
4274 | |||
4275 | #: src/gnsrecord/gnsrecord_misc.c:515 | ||
4276 | msgid "Mutually exclusive records." | ||
4277 | msgstr "" | ||
4278 | |||
4192 | #: src/gnsrecord/plugin_gnsrecord_dns.c:367 | 4279 | #: src/gnsrecord/plugin_gnsrecord_dns.c:367 |
4193 | #, c-format | 4280 | #, c-format |
4194 | msgid "Unable to parse IPv4 address `%s'\n" | 4281 | msgid "Unable to parse IPv4 address `%s'\n" |
@@ -4456,7 +4543,7 @@ msgid "# hostlist downloads initiated" | |||
4456 | msgstr "# descargas de listas de máquinas iniciadas" | 4543 | msgstr "# descargas de listas de máquinas iniciadas" |
4457 | 4544 | ||
4458 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1144 | 4545 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1144 |
4459 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1728 | 4546 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1732 |
4460 | msgid "# milliseconds between hostlist downloads" | 4547 | msgid "# milliseconds between hostlist downloads" |
4461 | msgstr "# milisegundos entre descargas de listas de máquinas" | 4548 | msgstr "# milisegundos entre descargas de listas de máquinas" |
4462 | 4549 | ||
@@ -4519,21 +4606,21 @@ msgstr "Error escribiendo URI de listas de máquinas al fichero «%s»\n" | |||
4519 | msgid "# hostlist URIs written to file" | 4606 | msgid "# hostlist URIs written to file" |
4520 | msgstr "# URI de listas de máquinas escritas a fichero" | 4607 | msgstr "# URI de listas de máquinas escritas a fichero" |
4521 | 4608 | ||
4522 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1657 | 4609 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1661 |
4523 | #: src/transport/plugin_transport_http_client.c:2300 | 4610 | #: src/transport/plugin_transport_http_client.c:2300 |
4524 | #, c-format | 4611 | #, c-format |
4525 | msgid "Invalid proxy type: `%s', disabling proxy! Check configuration!\n" | 4612 | msgid "Invalid proxy type: `%s', disabling proxy! Check configuration!\n" |
4526 | msgstr "" | 4613 | msgstr "" |
4527 | 4614 | ||
4528 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1686 | 4615 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1690 |
4529 | msgid "Learning is enabled on this peer\n" | 4616 | msgid "Learning is enabled on this peer\n" |
4530 | msgstr "El aprendizaje está habilitado en este par\n" | 4617 | msgstr "El aprendizaje está habilitado en este par\n" |
4531 | 4618 | ||
4532 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1699 | 4619 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1703 |
4533 | msgid "Learning is not enabled on this peer\n" | 4620 | msgid "Learning is not enabled on this peer\n" |
4534 | msgstr "El aprendizaje no está habilitado en este par\n" | 4621 | msgstr "El aprendizaje no está habilitado en este par\n" |
4535 | 4622 | ||
4536 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1713 | 4623 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1717 |
4537 | #, c-format | 4624 | #, c-format |
4538 | msgid "" | 4625 | msgid "" |
4539 | "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" | 4626 | "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" |
@@ -4737,51 +4824,51 @@ msgstr "" | |||
4737 | msgid "Maintain egos" | 4824 | msgid "Maintain egos" |
4738 | msgstr "" | 4825 | msgstr "" |
4739 | 4826 | ||
4740 | #: src/identity/gnunet-service-identity.c:503 | 4827 | #: src/identity/gnunet-service-identity.c:502 |
4741 | msgid "no default known" | 4828 | msgid "no default known" |
4742 | msgstr "" | 4829 | msgstr "" |
4743 | 4830 | ||
4744 | #: src/identity/gnunet-service-identity.c:528 | 4831 | #: src/identity/gnunet-service-identity.c:527 |
4745 | msgid "default configured, but ego unknown (internal error)" | 4832 | msgid "default configured, but ego unknown (internal error)" |
4746 | msgstr "" | 4833 | msgstr "" |
4747 | 4834 | ||
4748 | #: src/identity/gnunet-service-identity.c:621 | 4835 | #: src/identity/gnunet-service-identity.c:620 |
4749 | #: src/identity/gnunet-service-identity.c:896 | 4836 | #: src/identity/gnunet-service-identity.c:895 |
4750 | #: src/identity/gnunet-service-identity.c:1016 | 4837 | #: src/identity/gnunet-service-identity.c:1015 |
4751 | #, fuzzy, c-format | 4838 | #, fuzzy, c-format |
4752 | msgid "Failed to write subsystem default identifier map to `%s'.\n" | 4839 | msgid "Failed to write subsystem default identifier map to `%s'.\n" |
4753 | msgstr "" | 4840 | msgstr "" |
4754 | "Se produjo un fallo al obtener los identificadores de fichero para «%s»\n" | 4841 | "Se produjo un fallo al obtener los identificadores de fichero para «%s»\n" |
4755 | 4842 | ||
4756 | #: src/identity/gnunet-service-identity.c:631 | 4843 | #: src/identity/gnunet-service-identity.c:630 |
4757 | msgid "Unknown ego specified for service (internal error)" | 4844 | msgid "Unknown ego specified for service (internal error)" |
4758 | msgstr "" | 4845 | msgstr "" |
4759 | 4846 | ||
4760 | #: src/identity/gnunet-service-identity.c:725 | 4847 | #: src/identity/gnunet-service-identity.c:724 |
4761 | msgid "identifier already in use for another ego" | 4848 | msgid "identifier already in use for another ego" |
4762 | msgstr "" | 4849 | msgstr "" |
4763 | 4850 | ||
4764 | #: src/identity/gnunet-service-identity.c:872 | 4851 | #: src/identity/gnunet-service-identity.c:871 |
4765 | #, fuzzy | 4852 | #, fuzzy |
4766 | msgid "target name already exists" | 4853 | msgid "target name already exists" |
4767 | msgstr "El registro ya existÃa en el almacén de nombres" | 4854 | msgstr "El registro ya existÃa en el almacén de nombres" |
4768 | 4855 | ||
4769 | #: src/identity/gnunet-service-identity.c:914 | 4856 | #: src/identity/gnunet-service-identity.c:913 |
4770 | #: src/identity/gnunet-service-identity.c:1033 | 4857 | #: src/identity/gnunet-service-identity.c:1032 |
4771 | msgid "no matching ego found" | 4858 | msgid "no matching ego found" |
4772 | msgstr "" | 4859 | msgstr "" |
4773 | 4860 | ||
4774 | #: src/identity/gnunet-service-identity.c:1131 | 4861 | #: src/identity/gnunet-service-identity.c:1130 |
4775 | #, fuzzy, c-format | 4862 | #, fuzzy, c-format |
4776 | msgid "Failed to parse ego information in `%s'\n" | 4863 | msgid "Failed to parse ego information in `%s'\n" |
4777 | msgstr "Se produjo un fallo al procesar la identidad del par «%s»\n" | 4864 | msgstr "Se produjo un fallo al procesar la identidad del par «%s»\n" |
4778 | 4865 | ||
4779 | #: src/identity/gnunet-service-identity.c:1189 | 4866 | #: src/identity/gnunet-service-identity.c:1188 |
4780 | #, fuzzy, c-format | 4867 | #, fuzzy, c-format |
4781 | msgid "Failed to parse subsystem identity configuration file `%s'\n" | 4868 | msgid "Failed to parse subsystem identity configuration file `%s'\n" |
4782 | msgstr "Se produjo un fallo al borrar el fichero de configuración %s\n" | 4869 | msgstr "Se produjo un fallo al borrar el fichero de configuración %s\n" |
4783 | 4870 | ||
4784 | #: src/identity/gnunet-service-identity.c:1198 | 4871 | #: src/identity/gnunet-service-identity.c:1197 |
4785 | #, fuzzy, c-format | 4872 | #, fuzzy, c-format |
4786 | msgid "Failed to create directory `%s' for storing egos\n" | 4873 | msgid "Failed to create directory `%s' for storing egos\n" |
4787 | msgstr "Se produjo un fallo al leer el directorio «%s»\n" | 4874 | msgstr "Se produjo un fallo al leer el directorio «%s»\n" |
@@ -4822,7 +4909,7 @@ msgstr "No se pudo acceder al fichero «%s»: %s\n" | |||
4822 | msgid "No records found for `%s'" | 4909 | msgid "No records found for `%s'" |
4823 | msgstr "No se han encontrado ficheros en «%s»\n" | 4910 | msgstr "No se han encontrado ficheros en «%s»\n" |
4824 | 4911 | ||
4825 | #: src/namecache/gnunet-namecache.c:119 src/namestore/gnunet-namestore.c:459 | 4912 | #: src/namecache/gnunet-namecache.c:119 src/namestore/gnunet-namestore.c:469 |
4826 | #, c-format | 4913 | #, c-format |
4827 | msgid "\tCorrupt or unsupported record of type %u\n" | 4914 | msgid "\tCorrupt or unsupported record of type %u\n" |
4828 | msgstr "\tRegistro corrupto o no soportado del tipo %u\n" | 4915 | msgstr "\tRegistro corrupto o no soportado del tipo %u\n" |
@@ -4842,7 +4929,7 @@ msgstr "Parámetro no válido «%s»\n" | |||
4842 | msgid "You must specify a name\n" | 4929 | msgid "You must specify a name\n" |
4843 | msgstr "¡Debes especificar un receptor!\n" | 4930 | msgstr "¡Debes especificar un receptor!\n" |
4844 | 4931 | ||
4845 | #: src/namecache/gnunet-namecache.c:214 src/namestore/gnunet-namestore.c:1641 | 4932 | #: src/namecache/gnunet-namecache.c:214 src/namestore/gnunet-namestore.c:1591 |
4846 | msgid "name of the record to add/delete/display" | 4933 | msgid "name of the record to add/delete/display" |
4847 | msgstr "nombre del registro a añadir/borrar/mostrar" | 4934 | msgstr "nombre del registro a añadir/borrar/mostrar" |
4848 | 4935 | ||
@@ -4851,7 +4938,7 @@ msgstr "nombre del registro a añadir/borrar/mostrar" | |||
4851 | msgid "specifies the public key of the zone to look in" | 4938 | msgid "specifies the public key of the zone to look in" |
4852 | msgstr "Especificar el tipo del registro a buscar" | 4939 | msgstr "Especificar el tipo del registro a buscar" |
4853 | 4940 | ||
4854 | #: src/namecache/gnunet-namecache.c:233 src/namestore/gnunet-namestore.c:1702 | 4941 | #: src/namecache/gnunet-namecache.c:233 src/namestore/gnunet-namestore.c:1652 |
4855 | msgid "GNUnet zone manipulation tool" | 4942 | msgid "GNUnet zone manipulation tool" |
4856 | msgstr "Herramienta de manipulación de zona de GNUnet" | 4943 | msgstr "Herramienta de manipulación de zona de GNUnet" |
4857 | 4944 | ||
@@ -5003,140 +5090,113 @@ msgstr "" | |||
5003 | msgid "GNU Name System First-Come-First-Served name registration service" | 5090 | msgid "GNU Name System First-Come-First-Served name registration service" |
5004 | msgstr "Servicio de registro GNUnet GNS primero en llegar, primero en servirse" | 5091 | msgstr "Servicio de registro GNUnet GNS primero en llegar, primero en servirse" |
5005 | 5092 | ||
5006 | #: src/namestore/gnunet-namestore.c:334 | 5093 | #: src/namestore/gnunet-namestore.c:340 |
5007 | #, c-format | 5094 | #, c-format |
5008 | msgid "Adding record failed: %s\n" | 5095 | msgid "Adding record failed: %s\n" |
5009 | msgstr "No se pudo añadir el registro: %s\n" | 5096 | msgstr "No se pudo añadir el registro: %s\n" |
5010 | 5097 | ||
5011 | #: src/namestore/gnunet-namestore.c:362 | 5098 | #: src/namestore/gnunet-namestore.c:368 |
5012 | #, fuzzy, c-format | 5099 | #, fuzzy, c-format |
5013 | msgid "Deleting record failed, record does not exist%s%s\n" | 5100 | msgid "Deleting record failed, record does not exist%s%s\n" |
5014 | msgstr "No se pudo borrar el registro: %s\n" | 5101 | msgstr "No se pudo borrar el registro: %s\n" |
5015 | 5102 | ||
5016 | #: src/namestore/gnunet-namestore.c:369 | 5103 | #: src/namestore/gnunet-namestore.c:375 |
5017 | #, fuzzy, c-format | 5104 | #, fuzzy, c-format |
5018 | msgid "Deleting record failed%s%s\n" | 5105 | msgid "Deleting record failed%s%s\n" |
5019 | msgstr "No se pudo borrar el registro: %s\n" | 5106 | msgstr "No se pudo borrar el registro: %s\n" |
5020 | 5107 | ||
5021 | #: src/namestore/gnunet-namestore.c:656 | ||
5022 | #, c-format | ||
5023 | msgid "A %s record exists already under `%s', no other records can be added.\n" | ||
5024 | msgstr "" | ||
5025 | |||
5026 | #: src/namestore/gnunet-namestore.c:668 | 5108 | #: src/namestore/gnunet-namestore.c:668 |
5027 | #, c-format | 5109 | #, c-format |
5028 | msgid "" | 5110 | msgid "" |
5029 | "A zone key record exists already under `%s', no other records can be added.\n" | ||
5030 | msgstr "" | ||
5031 | |||
5032 | #: src/namestore/gnunet-namestore.c:680 | ||
5033 | #, c-format | ||
5034 | msgid "" | ||
5035 | "A SOA record exists already under `%s', cannot add a second SOA to the same " | 5111 | "A SOA record exists already under `%s', cannot add a second SOA to the same " |
5036 | "zone.\n" | 5112 | "zone.\n" |
5037 | msgstr "" | 5113 | msgstr "" |
5038 | 5114 | ||
5039 | #: src/namestore/gnunet-namestore.c:696 | 5115 | #: src/namestore/gnunet-namestore.c:789 |
5040 | #, c-format | ||
5041 | msgid "Records already exist under `%s', cannot add `%s' record.\n" | ||
5042 | msgstr "" | ||
5043 | |||
5044 | #: src/namestore/gnunet-namestore.c:711 | ||
5045 | #, c-format | ||
5046 | msgid "Records already exist under `%s', cannot add record.\n" | ||
5047 | msgstr "" | ||
5048 | |||
5049 | #: src/namestore/gnunet-namestore.c:726 | ||
5050 | #, c-format | ||
5051 | msgid "" | ||
5052 | "Non-GNS2DNS records already exist under `%s', cannot add GNS2DNS record.\n" | ||
5053 | msgstr "" | ||
5054 | |||
5055 | #: src/namestore/gnunet-namestore.c:846 | ||
5056 | #, c-format | 5116 | #, c-format |
5057 | msgid "There are no records under label `%s' that could be deleted.\n" | 5117 | msgid "There are no records under label `%s' that could be deleted.\n" |
5058 | msgstr "" | 5118 | msgstr "" |
5059 | 5119 | ||
5060 | #: src/namestore/gnunet-namestore.c:889 | 5120 | #: src/namestore/gnunet-namestore.c:832 |
5061 | #, c-format | 5121 | #, c-format |
5062 | msgid "" | 5122 | msgid "" |
5063 | "There are no records under label `%s' that match the request for deletion.\n" | 5123 | "There are no records under label `%s' that match the request for deletion.\n" |
5064 | msgstr "" | 5124 | msgstr "" |
5065 | 5125 | ||
5066 | #: src/namestore/gnunet-namestore.c:970 | 5126 | #: src/namestore/gnunet-namestore.c:920 |
5067 | #, fuzzy, c-format | 5127 | #, fuzzy, c-format |
5068 | msgid "Failed to replace records: %s\n" | 5128 | msgid "Failed to replace records: %s\n" |
5069 | msgstr "Se produjo un fallo al procesar la petición DNS. Omitiendo.\n" | 5129 | msgstr "Se produjo un fallo al procesar la petición DNS. Omitiendo.\n" |
5070 | 5130 | ||
5071 | #: src/namestore/gnunet-namestore.c:993 | 5131 | #: src/namestore/gnunet-namestore.c:943 |
5072 | #, c-format | 5132 | #, c-format |
5073 | msgid "No options given\n" | 5133 | msgid "No options given\n" |
5074 | msgstr "No se han proporcionado opciones\n" | 5134 | msgstr "No se han proporcionado opciones\n" |
5075 | 5135 | ||
5076 | #: src/namestore/gnunet-namestore.c:1014 src/namestore/gnunet-namestore.c:1066 | 5136 | #: src/namestore/gnunet-namestore.c:964 src/namestore/gnunet-namestore.c:1016 |
5077 | #: src/namestore/gnunet-namestore.c:1076 src/namestore/gnunet-namestore.c:1105 | 5137 | #: src/namestore/gnunet-namestore.c:1026 src/namestore/gnunet-namestore.c:1055 |
5078 | #: src/namestore/gnunet-namestore.c:1126 src/namestore/gnunet-namestore.c:1153 | 5138 | #: src/namestore/gnunet-namestore.c:1076 src/namestore/gnunet-namestore.c:1103 |
5079 | #: src/namestore/gnunet-namestore.c:1230 | 5139 | #: src/namestore/gnunet-namestore.c:1180 |
5080 | #, c-format | 5140 | #, c-format |
5081 | msgid "Missing option `%s' for operation `%s'\n" | 5141 | msgid "Missing option `%s' for operation `%s'\n" |
5082 | msgstr "Falta la opción «%s» para la operación «%s»\n" | 5142 | msgstr "Falta la opción «%s» para la operación «%s»\n" |
5083 | 5143 | ||
5084 | #: src/namestore/gnunet-namestore.c:1016 | 5144 | #: src/namestore/gnunet-namestore.c:966 |
5085 | msgid "replace" | 5145 | msgid "replace" |
5086 | msgstr "" | 5146 | msgstr "" |
5087 | 5147 | ||
5088 | #: src/namestore/gnunet-namestore.c:1045 | 5148 | #: src/namestore/gnunet-namestore.c:995 |
5089 | #, fuzzy, c-format | 5149 | #, fuzzy, c-format |
5090 | msgid "Invalid nick `%s'\n" | 5150 | msgid "Invalid nick `%s'\n" |
5091 | msgstr "URI no válida: «%s»\n" | 5151 | msgstr "URI no válida: «%s»\n" |
5092 | 5152 | ||
5093 | #: src/namestore/gnunet-namestore.c:1068 src/namestore/gnunet-namestore.c:1078 | 5153 | #: src/namestore/gnunet-namestore.c:1018 src/namestore/gnunet-namestore.c:1028 |
5094 | #: src/namestore/gnunet-namestore.c:1107 src/namestore/gnunet-namestore.c:1128 | 5154 | #: src/namestore/gnunet-namestore.c:1057 src/namestore/gnunet-namestore.c:1078 |
5095 | #: src/namestore/gnunet-namestore.c:1232 | 5155 | #: src/namestore/gnunet-namestore.c:1182 |
5096 | msgid "add" | 5156 | msgid "add" |
5097 | msgstr "añadir" | 5157 | msgstr "añadir" |
5098 | 5158 | ||
5099 | #: src/namestore/gnunet-namestore.c:1086 | 5159 | #: src/namestore/gnunet-namestore.c:1036 |
5100 | #, c-format | 5160 | #, c-format |
5101 | msgid "Unsupported type `%s'\n" | 5161 | msgid "Unsupported type `%s'\n" |
5102 | msgstr "Tipo no soportado «%s»\n" | 5162 | msgstr "Tipo no soportado «%s»\n" |
5103 | 5163 | ||
5104 | #: src/namestore/gnunet-namestore.c:1096 | 5164 | #: src/namestore/gnunet-namestore.c:1046 |
5105 | #, c-format | 5165 | #, c-format |
5106 | msgid "For DNS record types `SRV', `TLSA' and `OPENPGPKEY'" | 5166 | msgid "For DNS record types `SRV', `TLSA' and `OPENPGPKEY'" |
5107 | msgstr "" | 5167 | msgstr "" |
5108 | 5168 | ||
5109 | #: src/namestore/gnunet-namestore.c:1116 | 5169 | #: src/namestore/gnunet-namestore.c:1066 |
5110 | #, c-format | 5170 | #, c-format |
5111 | msgid "Value `%s' invalid for record type `%s'\n" | 5171 | msgid "Value `%s' invalid for record type `%s'\n" |
5112 | msgstr "Valor «%s» no válido para el tipo de registro «%s»\n" | 5172 | msgstr "Valor «%s» no válido para el tipo de registro «%s»\n" |
5113 | 5173 | ||
5114 | #: src/namestore/gnunet-namestore.c:1135 src/namestore/gnunet-namestore.c:1239 | 5174 | #: src/namestore/gnunet-namestore.c:1085 src/namestore/gnunet-namestore.c:1189 |
5115 | #, c-format | 5175 | #, c-format |
5116 | msgid "Invalid time format `%s'\n" | 5176 | msgid "Invalid time format `%s'\n" |
5117 | msgstr "Formato de tiempo no válido «%s»\n" | 5177 | msgstr "Formato de tiempo no válido «%s»\n" |
5118 | 5178 | ||
5119 | #: src/namestore/gnunet-namestore.c:1155 | 5179 | #: src/namestore/gnunet-namestore.c:1105 |
5120 | msgid "del" | 5180 | msgid "del" |
5121 | msgstr "borrar" | 5181 | msgstr "borrar" |
5122 | 5182 | ||
5123 | #: src/namestore/gnunet-namestore.c:1197 | 5183 | #: src/namestore/gnunet-namestore.c:1147 |
5124 | #, fuzzy, c-format | 5184 | #, fuzzy, c-format |
5125 | msgid "Invalid public key for reverse lookup `%s'\n" | 5185 | msgid "Invalid public key for reverse lookup `%s'\n" |
5126 | msgstr "Parámetro no válido «%s»\n" | 5186 | msgstr "Parámetro no válido «%s»\n" |
5127 | 5187 | ||
5128 | #: src/namestore/gnunet-namestore.c:1222 | 5188 | #: src/namestore/gnunet-namestore.c:1172 |
5129 | #: src/peerinfo-tool/gnunet-peerinfo.c:737 | 5189 | #: src/peerinfo-tool/gnunet-peerinfo.c:737 |
5130 | #, c-format | 5190 | #, c-format |
5131 | msgid "Invalid URI `%s'\n" | 5191 | msgid "Invalid URI `%s'\n" |
5132 | msgstr "URI no válida: «%s»\n" | 5192 | msgstr "URI no válida: «%s»\n" |
5133 | 5193 | ||
5134 | #: src/namestore/gnunet-namestore.c:1292 | 5194 | #: src/namestore/gnunet-namestore.c:1242 |
5135 | #, c-format | 5195 | #, c-format |
5136 | msgid "Label `%s' contains `.' which is not allowed\n" | 5196 | msgid "Label `%s' contains `.' which is not allowed\n" |
5137 | msgstr "" | 5197 | msgstr "" |
5138 | 5198 | ||
5139 | #: src/namestore/gnunet-namestore.c:1342 | 5199 | #: src/namestore/gnunet-namestore.c:1292 |
5140 | #, c-format | 5200 | #, c-format |
5141 | msgid "" | 5201 | msgid "" |
5142 | "No default identity configured for `namestore' subsystem\n" | 5202 | "No default identity configured for `namestore' subsystem\n" |
@@ -5144,113 +5204,118 @@ msgid "" | |||
5144 | "Run gnunet-identity -d to get a list of choices for $NAME\n" | 5204 | "Run gnunet-identity -d to get a list of choices for $NAME\n" |
5145 | msgstr "" | 5205 | msgstr "" |
5146 | 5206 | ||
5147 | #: src/namestore/gnunet-namestore.c:1407 | 5207 | #: src/namestore/gnunet-namestore.c:1357 |
5148 | #, fuzzy, c-format | 5208 | #, fuzzy, c-format |
5149 | msgid "Superfluous command line arguments (starting with `%s') ignored\n" | 5209 | msgid "Superfluous command line arguments (starting with `%s') ignored\n" |
5150 | msgstr "Argumentos superfluos (ignorados).\n" | 5210 | msgstr "Argumentos superfluos (ignorados).\n" |
5151 | 5211 | ||
5152 | #: src/namestore/gnunet-namestore.c:1436 | 5212 | #: src/namestore/gnunet-namestore.c:1386 |
5153 | #, fuzzy, c-format | 5213 | #, fuzzy, c-format |
5154 | msgid "Cannot connect to identity service\n" | 5214 | msgid "Cannot connect to identity service\n" |
5155 | msgstr "¡No se pudo conectar al servicio %s!\n" | 5215 | msgstr "¡No se pudo conectar al servicio %s!\n" |
5156 | 5216 | ||
5157 | #: src/namestore/gnunet-namestore.c:1483 | 5217 | #: src/namestore/gnunet-namestore.c:1433 |
5158 | msgid "Empty record line argument is not allowed.\n" | 5218 | msgid "Empty record line argument is not allowed.\n" |
5159 | msgstr "" | 5219 | msgstr "" |
5160 | 5220 | ||
5161 | #: src/namestore/gnunet-namestore.c:1495 | 5221 | #: src/namestore/gnunet-namestore.c:1445 |
5162 | #, c-format | 5222 | #, c-format |
5163 | msgid "Invalid expiration time `%s' (must be without unit)\n" | 5223 | msgid "Invalid expiration time `%s' (must be without unit)\n" |
5164 | msgstr "" | 5224 | msgstr "" |
5165 | 5225 | ||
5166 | #: src/namestore/gnunet-namestore.c:1507 src/namestore/gnunet-namestore.c:1523 | 5226 | #: src/namestore/gnunet-namestore.c:1457 src/namestore/gnunet-namestore.c:1473 |
5167 | #: src/namestore/gnunet-namestore.c:1540 | 5227 | #: src/namestore/gnunet-namestore.c:1490 |
5168 | #, fuzzy, c-format | 5228 | #, fuzzy, c-format |
5169 | msgid "Missing entries in record line `%s'.\n" | 5229 | msgid "Missing entries in record line `%s'.\n" |
5170 | msgstr "Se produjo un fallo al cargar el módulo del transporte para «%s»\n" | 5230 | msgstr "Se produjo un fallo al cargar el módulo del transporte para «%s»\n" |
5171 | 5231 | ||
5172 | #: src/namestore/gnunet-namestore.c:1515 | 5232 | #: src/namestore/gnunet-namestore.c:1465 |
5173 | #, fuzzy, c-format | 5233 | #, fuzzy, c-format |
5174 | msgid "Unknown record type `%s'\n" | 5234 | msgid "Unknown record type `%s'\n" |
5175 | msgstr "Comando desconocido «%s»\n" | 5235 | msgstr "Comando desconocido «%s»\n" |
5176 | 5236 | ||
5177 | #: src/namestore/gnunet-namestore.c:1553 | 5237 | #: src/namestore/gnunet-namestore.c:1503 |
5178 | #, fuzzy, c-format | 5238 | #, fuzzy, c-format |
5179 | msgid "Invalid record data for type %s: `%s'.\n" | 5239 | msgid "Invalid record data for type %s: `%s'.\n" |
5180 | msgstr "Formato no válido para la IP: «%s»\n" | 5240 | msgstr "Formato no válido para la IP: «%s»\n" |
5181 | 5241 | ||
5182 | #: src/namestore/gnunet-namestore.c:1610 | 5242 | #: src/namestore/gnunet-namestore.c:1560 |
5183 | msgid "add record" | 5243 | msgid "add record" |
5184 | msgstr "añadir registro" | 5244 | msgstr "añadir registro" |
5185 | 5245 | ||
5186 | #: src/namestore/gnunet-namestore.c:1613 | 5246 | #: src/namestore/gnunet-namestore.c:1563 |
5187 | msgid "delete record" | 5247 | msgid "delete record" |
5188 | msgstr "borrar registro" | 5248 | msgstr "borrar registro" |
5189 | 5249 | ||
5190 | #: src/namestore/gnunet-namestore.c:1617 | 5250 | #: src/namestore/gnunet-namestore.c:1567 |
5191 | msgid "display records" | 5251 | msgid "display records" |
5192 | msgstr "mostrar registros" | 5252 | msgstr "mostrar registros" |
5193 | 5253 | ||
5194 | #: src/namestore/gnunet-namestore.c:1624 | 5254 | #: src/namestore/gnunet-namestore.c:1574 |
5195 | msgid "" | 5255 | msgid "" |
5196 | "expiration time for record to use (for adding only), \"never\" is possible" | 5256 | "expiration time for record to use (for adding only), \"never\" is possible" |
5197 | msgstr "" | 5257 | msgstr "" |
5198 | "tiempo de expiración del registro a usar (únicamente para añadir), nunca " | 5258 | "tiempo de expiración del registro a usar (únicamente para añadir), nunca " |
5199 | "(\"never\") es posible" | 5259 | "(\"never\") es posible" |
5200 | 5260 | ||
5201 | #: src/namestore/gnunet-namestore.c:1630 | 5261 | #: src/namestore/gnunet-namestore.c:1580 |
5202 | #, fuzzy | 5262 | #, fuzzy |
5203 | msgid "set the desired nick name for the zone" | 5263 | msgid "set the desired nick name for the zone" |
5204 | msgstr "establece el nivel LEVEL deseado de replicación" | 5264 | msgstr "establece el nivel LEVEL deseado de replicación" |
5205 | 5265 | ||
5206 | #: src/namestore/gnunet-namestore.c:1635 | 5266 | #: src/namestore/gnunet-namestore.c:1585 |
5207 | #, fuzzy | 5267 | #, fuzzy |
5208 | msgid "monitor changes in the namestore" | 5268 | msgid "monitor changes in the namestore" |
5209 | msgstr "¡Se produjo un fallo al conectar con el almacén de nombres!\n" | 5269 | msgstr "¡Se produjo un fallo al conectar con el almacén de nombres!\n" |
5210 | 5270 | ||
5211 | #: src/namestore/gnunet-namestore.c:1647 | 5271 | #: src/namestore/gnunet-namestore.c:1597 |
5212 | #, fuzzy | 5272 | #, fuzzy |
5213 | msgid "determine our name for the given PKEY" | 5273 | msgid "determine our name for the given PKEY" |
5214 | msgstr "establece las preferencias para el par dado" | 5274 | msgstr "establece las preferencias para el par dado" |
5215 | 5275 | ||
5216 | #: src/namestore/gnunet-namestore.c:1654 | 5276 | #: src/namestore/gnunet-namestore.c:1604 |
5217 | msgid "" | 5277 | msgid "" |
5218 | "set record set to values given by (possibly multiple) RECORDLINES; can be " | 5278 | "set record set to values given by (possibly multiple) RECORDLINES; can be " |
5219 | "specified multiple times" | 5279 | "specified multiple times" |
5220 | msgstr "" | 5280 | msgstr "" |
5221 | 5281 | ||
5222 | #: src/namestore/gnunet-namestore.c:1660 | 5282 | #: src/namestore/gnunet-namestore.c:1610 |
5223 | msgid "type of the record to add/delete/display" | 5283 | msgid "type of the record to add/delete/display" |
5224 | msgstr "tipo del registro a añadir/borrar/mostrar" | 5284 | msgstr "tipo del registro a añadir/borrar/mostrar" |
5225 | 5285 | ||
5226 | #: src/namestore/gnunet-namestore.c:1665 | 5286 | #: src/namestore/gnunet-namestore.c:1615 |
5227 | msgid "URI to import into our zone" | 5287 | msgid "URI to import into our zone" |
5228 | msgstr "URI a importar a nuestra zona" | 5288 | msgstr "URI a importar a nuestra zona" |
5229 | 5289 | ||
5230 | #: src/namestore/gnunet-namestore.c:1671 | 5290 | #: src/namestore/gnunet-namestore.c:1621 |
5231 | msgid "value of the record to add/delete" | 5291 | msgid "value of the record to add/delete" |
5232 | msgstr "valor del registro a añadir/borrar" | 5292 | msgstr "valor del registro a añadir/borrar" |
5233 | 5293 | ||
5234 | #: src/namestore/gnunet-namestore.c:1675 | 5294 | #: src/namestore/gnunet-namestore.c:1625 |
5235 | msgid "create or list public record" | 5295 | msgid "create or list public record" |
5236 | msgstr "crear o listar registros públicos" | 5296 | msgstr "crear o listar registros públicos" |
5237 | 5297 | ||
5238 | #: src/namestore/gnunet-namestore.c:1681 | 5298 | #: src/namestore/gnunet-namestore.c:1631 |
5239 | msgid "" | 5299 | msgid "" |
5240 | "create shadow record (only valid if all other records of the same type have " | 5300 | "create shadow record (only valid if all other records of the same type have " |
5241 | "expired" | 5301 | "expired" |
5242 | msgstr "" | 5302 | msgstr "" |
5243 | 5303 | ||
5244 | #: src/namestore/gnunet-namestore.c:1687 | 5304 | #: src/namestore/gnunet-namestore.c:1637 |
5245 | #, fuzzy | 5305 | #, fuzzy |
5246 | msgid "name of the ego controlling the zone" | 5306 | msgid "name of the ego controlling the zone" |
5247 | msgstr "nombre de la sección a la que acceder" | 5307 | msgstr "nombre de la sección a la que acceder" |
5248 | 5308 | ||
5249 | #: src/namestore/gnunet-service-namestore.c:871 | 5309 | #: src/namestore/gnunet-service-namestore.c:879 |
5250 | #, fuzzy, c-format | 5310 | #, fuzzy, c-format |
5251 | msgid "Failed to replicate block in namecache: %s\n" | 5311 | msgid "Failed to replicate block in namecache: %s\n" |
5252 | msgstr "Se produjo un fallo al crear el espacio de nombres «%s»\n" | 5312 | msgstr "Se produjo un fallo al crear el espacio de nombres «%s»\n" |
5253 | 5313 | ||
5314 | #: src/namestore/gnunet-service-namestore.c:1668 | ||
5315 | #, fuzzy | ||
5316 | msgid "Store failed" | ||
5317 | msgstr "«gnunet-ecc» falló" | ||
5318 | |||
5254 | #: src/namestore/gnunet-zoneimport.c:1847 | 5319 | #: src/namestore/gnunet-zoneimport.c:1847 |
5255 | msgid "size to use for the main hash map" | 5320 | msgid "size to use for the main hash map" |
5256 | msgstr "" | 5321 | msgstr "" |
@@ -5259,11 +5324,6 @@ msgstr "" | |||
5259 | msgid "minimum expiration time we assume for imported records" | 5324 | msgid "minimum expiration time we assume for imported records" |
5260 | msgstr "" | 5325 | msgstr "" |
5261 | 5326 | ||
5262 | #: src/namestore/namestore_api.c:373 | ||
5263 | #, fuzzy | ||
5264 | msgid "Namestore failed to store record\n" | ||
5265 | msgstr "El almacén de nombres no pudo añadir el registro\n" | ||
5266 | |||
5267 | #: src/namestore/plugin_namestore_flat.c:195 | 5327 | #: src/namestore/plugin_namestore_flat.c:195 |
5268 | #, c-format | 5328 | #, c-format |
5269 | msgid "File too big to map: %llu bytes.\n" | 5329 | msgid "File too big to map: %llu bytes.\n" |
@@ -5867,6 +5927,51 @@ msgid "Daemon to run to perform IP protocol translation to GNUnet" | |||
5867 | msgstr "" | 5927 | msgstr "" |
5868 | "Demonio a ejecutar para realizar la traducción de protocolo IP a GNUnet" | 5928 | "Demonio a ejecutar para realizar la traducción de protocolo IP a GNUnet" |
5869 | 5929 | ||
5930 | #: src/reclaim/gnunet-did.c:209 | ||
5931 | #, fuzzy, c-format | ||
5932 | msgid "Invalid DID `%s'\n" | ||
5933 | msgstr "URI no válida: «%s»\n" | ||
5934 | |||
5935 | #: src/reclaim/gnunet-did.c:835 | ||
5936 | msgid "Create a DID Document and display its DID" | ||
5937 | msgstr "" | ||
5938 | |||
5939 | #: src/reclaim/gnunet-did.c:840 | ||
5940 | msgid "Get the DID Document associated with the given DID" | ||
5941 | msgstr "" | ||
5942 | |||
5943 | #: src/reclaim/gnunet-did.c:844 | ||
5944 | msgid "Show the DID for a given ego" | ||
5945 | msgstr "" | ||
5946 | |||
5947 | #: src/reclaim/gnunet-did.c:849 | ||
5948 | msgid "Remove the DID" | ||
5949 | msgstr "" | ||
5950 | |||
5951 | #: src/reclaim/gnunet-did.c:853 src/reclaim/gnunet-did.c:857 | ||
5952 | msgid "Replace the DID Document." | ||
5953 | msgstr "" | ||
5954 | |||
5955 | #: src/reclaim/gnunet-did.c:863 | ||
5956 | msgid "The Decentralized Identity (DID)" | ||
5957 | msgstr "" | ||
5958 | |||
5959 | #: src/reclaim/gnunet-did.c:869 | ||
5960 | msgid "The DID Document to store in GNUNET" | ||
5961 | msgstr "" | ||
5962 | |||
5963 | #: src/reclaim/gnunet-did.c:874 | ||
5964 | msgid "The name of the EGO" | ||
5965 | msgstr "" | ||
5966 | |||
5967 | #: src/reclaim/gnunet-did.c:880 | ||
5968 | msgid "The time until the DID Document is going to expire (e.g. 5d)" | ||
5969 | msgstr "" | ||
5970 | |||
5971 | #: src/reclaim/gnunet-did.c:889 | ||
5972 | msgid "Manage Decentralized Identities (DIDs)" | ||
5973 | msgstr "" | ||
5974 | |||
5870 | #: src/reclaim/gnunet-reclaim.c:802 | 5975 | #: src/reclaim/gnunet-reclaim.c:802 |
5871 | #, fuzzy, c-format | 5976 | #, fuzzy, c-format |
5872 | msgid "Ego is required\n" | 5977 | msgid "Ego is required\n" |
@@ -6780,17 +6885,17 @@ msgid "" | |||
6780 | "free topology cannot be more than %u. Given `%s = %llu'" | 6885 | "free topology cannot be more than %u. Given `%s = %llu'" |
6781 | msgstr "" | 6886 | msgstr "" |
6782 | 6887 | ||
6783 | #: src/testbed/testbed_api_topology.c:1033 src/testing/testing.c:2643 | 6888 | #: src/testbed/testbed_api_topology.c:1033 src/testing/testing.c:2657 |
6784 | #, c-format | 6889 | #, c-format |
6785 | msgid "Topology file %s not found\n" | 6890 | msgid "Topology file %s not found\n" |
6786 | msgstr "El fichero de topologÃa %s no fue encontrado\n" | 6891 | msgstr "El fichero de topologÃa %s no fue encontrado\n" |
6787 | 6892 | ||
6788 | #: src/testbed/testbed_api_topology.c:1041 src/testing/testing.c:2651 | 6893 | #: src/testbed/testbed_api_topology.c:1041 src/testing/testing.c:2665 |
6789 | #, c-format | 6894 | #, c-format |
6790 | msgid "Topology file %s has no data\n" | 6895 | msgid "Topology file %s has no data\n" |
6791 | msgstr "El fichero de topologÃa %s no tiene datos\n" | 6896 | msgstr "El fichero de topologÃa %s no tiene datos\n" |
6792 | 6897 | ||
6793 | #: src/testbed/testbed_api_topology.c:1049 src/testing/testing.c:2659 | 6898 | #: src/testbed/testbed_api_topology.c:1049 src/testing/testing.c:2673 |
6794 | #, c-format | 6899 | #, c-format |
6795 | msgid "Topology file %s cannot be read\n" | 6900 | msgid "Topology file %s cannot be read\n" |
6796 | msgstr "El fichero de topologÃa %s no puede ser leido\n" | 6901 | msgstr "El fichero de topologÃa %s no puede ser leido\n" |
@@ -7019,7 +7124,7 @@ msgstr "" | |||
7019 | 7124 | ||
7020 | #: src/transport/gnunet-communicator-tcp.c:3338 | 7125 | #: src/transport/gnunet-communicator-tcp.c:3338 |
7021 | #: src/transport/gnunet-communicator-udp.c:3856 | 7126 | #: src/transport/gnunet-communicator-udp.c:3856 |
7022 | #: src/transport/gnunet-service-tng.c:10512 | 7127 | #: src/transport/gnunet-service-tng.c:10623 |
7023 | #: src/transport/gnunet-service-transport.c:2627 | 7128 | #: src/transport/gnunet-service-transport.c:2627 |
7024 | #, fuzzy | 7129 | #, fuzzy |
7025 | msgid "Transport service is lacking key configuration settings. Exiting.\n" | 7130 | msgid "Transport service is lacking key configuration settings. Exiting.\n" |
@@ -8290,58 +8395,58 @@ msgstr "" | |||
8290 | msgid "Need a non-empty hostname for service `%s'.\n" | 8395 | msgid "Need a non-empty hostname for service `%s'.\n" |
8291 | msgstr "Se necesita un nombre de máquina no vacÃo para el servicio «%s».\n" | 8396 | msgstr "Se necesita un nombre de máquina no vacÃo para el servicio «%s».\n" |
8292 | 8397 | ||
8293 | #: src/util/common_logging.c:626 src/util/common_logging.c:665 | 8398 | #: src/util/common_logging.c:648 src/util/common_logging.c:687 |
8294 | #, c-format | 8399 | #, c-format |
8295 | msgid "ERROR: Unable to parse log definition: Syntax error at `%s'.\n" | 8400 | msgid "ERROR: Unable to parse log definition: Syntax error at `%s'.\n" |
8296 | msgstr "" | 8401 | msgstr "" |
8297 | 8402 | ||
8298 | #: src/util/common_logging.c:904 | 8403 | #: src/util/common_logging.c:926 |
8299 | #, c-format | 8404 | #, c-format |
8300 | msgid "Message `%.*s' repeated %u times in the last %s\n" | 8405 | msgid "Message `%.*s' repeated %u times in the last %s\n" |
8301 | msgstr "Mensaje `%.*s» repetido %u veces en el último %s\n" | 8406 | msgstr "Mensaje `%.*s» repetido %u veces en el último %s\n" |
8302 | 8407 | ||
8303 | #: src/util/common_logging.c:1108 | 8408 | #: src/util/common_logging.c:1131 |
8304 | msgid "ERROR" | 8409 | msgid "ERROR" |
8305 | msgstr "ERROR" | 8410 | msgstr "ERROR" |
8306 | 8411 | ||
8307 | #: src/util/common_logging.c:1110 | 8412 | #: src/util/common_logging.c:1133 |
8308 | msgid "WARNING" | 8413 | msgid "WARNING" |
8309 | msgstr "PELIGRO" | 8414 | msgstr "PELIGRO" |
8310 | 8415 | ||
8311 | #: src/util/common_logging.c:1112 | 8416 | #: src/util/common_logging.c:1135 |
8312 | msgid "MESSAGE" | 8417 | msgid "MESSAGE" |
8313 | msgstr "MENSAJE" | 8418 | msgstr "MENSAJE" |
8314 | 8419 | ||
8315 | #: src/util/common_logging.c:1114 | 8420 | #: src/util/common_logging.c:1137 |
8316 | msgid "INFO" | 8421 | msgid "INFO" |
8317 | msgstr "INFORMACIÓN" | 8422 | msgstr "INFORMACIÓN" |
8318 | 8423 | ||
8319 | #: src/util/common_logging.c:1116 | 8424 | #: src/util/common_logging.c:1139 |
8320 | msgid "DEBUG" | 8425 | msgid "DEBUG" |
8321 | msgstr "DEPURACIÓN" | 8426 | msgstr "DEPURACIÓN" |
8322 | 8427 | ||
8323 | #: src/util/common_logging.c:1118 | 8428 | #: src/util/common_logging.c:1141 |
8324 | msgid "NONE" | 8429 | msgid "NONE" |
8325 | msgstr "NINGUNO" | 8430 | msgstr "NINGUNO" |
8326 | 8431 | ||
8327 | #: src/util/common_logging.c:1119 | 8432 | #: src/util/common_logging.c:1142 |
8328 | msgid "INVALID" | 8433 | msgid "INVALID" |
8329 | msgstr "NO VÃLIDO" | 8434 | msgstr "NO VÃLIDO" |
8330 | 8435 | ||
8331 | #: src/util/common_logging.c:1400 | 8436 | #: src/util/common_logging.c:1423 |
8332 | msgid "unknown address" | 8437 | msgid "unknown address" |
8333 | msgstr "dirección desconocida" | 8438 | msgstr "dirección desconocida" |
8334 | 8439 | ||
8335 | #: src/util/common_logging.c:1445 | 8440 | #: src/util/common_logging.c:1468 |
8336 | msgid "invalid address" | 8441 | msgid "invalid address" |
8337 | msgstr "dirección no válida" | 8442 | msgstr "dirección no válida" |
8338 | 8443 | ||
8339 | #: src/util/common_logging.c:1464 | 8444 | #: src/util/common_logging.c:1487 |
8340 | #, c-format | 8445 | #, c-format |
8341 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" | 8446 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" |
8342 | msgstr "¡La configuración no especifica la opción «%s» en la sección «%s»!\n" | 8447 | msgstr "¡La configuración no especifica la opción «%s» en la sección «%s»!\n" |
8343 | 8448 | ||
8344 | #: src/util/common_logging.c:1487 | 8449 | #: src/util/common_logging.c:1510 |
8345 | #, c-format | 8450 | #, c-format |
8346 | msgid "" | 8451 | msgid "" |
8347 | "Configuration specifies invalid value for option `%s' in section `%s': %s\n" | 8452 | "Configuration specifies invalid value for option `%s' in section `%s': %s\n" |
@@ -8496,17 +8601,17 @@ msgstr "" | |||
8496 | msgid "Could not bind to any port: %s\n" | 8601 | msgid "Could not bind to any port: %s\n" |
8497 | msgstr "No se pudo asociar con ningún puerto: %s\n" | 8602 | msgstr "No se pudo asociar con ningún puerto: %s\n" |
8498 | 8603 | ||
8499 | #: src/util/dnsstub.c:344 | 8604 | #: src/util/dnsstub.c:370 |
8500 | #, c-format | 8605 | #, fuzzy, c-format |
8501 | msgid "Received DNS response that is too small (%u bytes)" | 8606 | msgid "Received DNS response that is too small (%u bytes)\n" |
8502 | msgstr "Recibida respuesta DNS demasiado pequeña (%u bytes)" | 8607 | msgstr "Recibida respuesta DNS demasiado pequeña (%u bytes)" |
8503 | 8608 | ||
8504 | #: src/util/dnsstub.c:482 | 8609 | #: src/util/dnsstub.c:508 |
8505 | #, fuzzy, c-format | 8610 | #, fuzzy, c-format |
8506 | msgid "Failed to send DNS request to %s: %s\n" | 8611 | msgid "Failed to send DNS request to %s: %s\n" |
8507 | msgstr "Se produjo un fallo al mandar la petición DNS a %s\n" | 8612 | msgstr "Se produjo un fallo al mandar la petición DNS a %s\n" |
8508 | 8613 | ||
8509 | #: src/util/dnsstub.c:487 | 8614 | #: src/util/dnsstub.c:513 |
8510 | #, c-format | 8615 | #, c-format |
8511 | msgid "Sent DNS request to %s\n" | 8616 | msgid "Sent DNS request to %s\n" |
8512 | msgstr "Petición DNS enviada a %s\n" | 8617 | msgstr "Petición DNS enviada a %s\n" |
@@ -8593,83 +8698,83 @@ msgstr "" | |||
8593 | "Los parámetros obligatorios para las opciones largas también lo son para sus " | 8698 | "Los parámetros obligatorios para las opciones largas también lo son para sus " |
8594 | "versiones cortas.\n" | 8699 | "versiones cortas.\n" |
8595 | 8700 | ||
8596 | #: src/util/getopt_helpers.c:196 | 8701 | #: src/util/getopt_helpers.c:197 |
8597 | msgid "print this help" | 8702 | msgid "print this help" |
8598 | msgstr "imprime esta ayuda" | 8703 | msgstr "imprime esta ayuda" |
8599 | 8704 | ||
8600 | #: src/util/getopt_helpers.c:261 | 8705 | #: src/util/getopt_helpers.c:262 |
8601 | msgid "be verbose" | 8706 | msgid "be verbose" |
8602 | msgstr "" | 8707 | msgstr "" |
8603 | 8708 | ||
8604 | #: src/util/getopt_helpers.c:377 | 8709 | #: src/util/getopt_helpers.c:378 |
8605 | msgid "configure logging to use LOGLEVEL" | 8710 | msgid "configure logging to use LOGLEVEL" |
8606 | msgstr "" | 8711 | msgstr "" |
8607 | 8712 | ||
8608 | #: src/util/getopt_helpers.c:444 | 8713 | #: src/util/getopt_helpers.c:445 |
8609 | msgid "configure logging to write logs to FILENAME" | 8714 | msgid "configure logging to write logs to FILENAME" |
8610 | msgstr "" | 8715 | msgstr "" |
8611 | 8716 | ||
8612 | #: src/util/getopt_helpers.c:461 | 8717 | #: src/util/getopt_helpers.c:462 |
8613 | #, fuzzy | 8718 | #, fuzzy |
8614 | msgid "use configuration file FILENAME" | 8719 | msgid "use configuration file FILENAME" |
8615 | msgstr "crear ficheros de configuración únicos" | 8720 | msgstr "crear ficheros de configuración únicos" |
8616 | 8721 | ||
8617 | #: src/util/getopt_helpers.c:497 src/util/getopt_helpers.c:811 | 8722 | #: src/util/getopt_helpers.c:498 src/util/getopt_helpers.c:812 |
8618 | #: src/util/getopt_helpers.c:867 | 8723 | #: src/util/getopt_helpers.c:868 |
8619 | #, c-format | 8724 | #, c-format |
8620 | msgid "You must pass a number to the `%s' option.\n" | 8725 | msgid "You must pass a number to the `%s' option.\n" |
8621 | msgstr "Tienes que introducir un número en la opción «%s».\n" | 8726 | msgstr "Tienes que introducir un número en la opción «%s».\n" |
8622 | 8727 | ||
8623 | #: src/util/getopt_helpers.c:569 | 8728 | #: src/util/getopt_helpers.c:570 |
8624 | #, fuzzy, c-format | 8729 | #, fuzzy, c-format |
8625 | msgid "" | 8730 | msgid "" |
8626 | "You must pass a relative time (optionally with sign) to the `%s' option.\n" | 8731 | "You must pass a relative time (optionally with sign) to the `%s' option.\n" |
8627 | msgstr "Debes introducir un tiempo relativo en la opción «%s».\n" | 8732 | msgstr "Debes introducir un tiempo relativo en la opción «%s».\n" |
8628 | 8733 | ||
8629 | #: src/util/getopt_helpers.c:576 | 8734 | #: src/util/getopt_helpers.c:577 |
8630 | #, c-format | 8735 | #, c-format |
8631 | msgid "Value given for time travel `%s' option is too big.\n" | 8736 | msgid "Value given for time travel `%s' option is too big.\n" |
8632 | msgstr "" | 8737 | msgstr "" |
8633 | 8738 | ||
8634 | #: src/util/getopt_helpers.c:594 | 8739 | #: src/util/getopt_helpers.c:595 |
8635 | msgid "[+/-]MICROSECONDS" | 8740 | msgid "[+/-]MICROSECONDS" |
8636 | msgstr "" | 8741 | msgstr "" |
8637 | 8742 | ||
8638 | #: src/util/getopt_helpers.c:596 | 8743 | #: src/util/getopt_helpers.c:597 |
8639 | msgid "modify system time by given offset (for debugging/testing only)" | 8744 | msgid "modify system time by given offset (for debugging/testing only)" |
8640 | msgstr "" | 8745 | msgstr "" |
8641 | 8746 | ||
8642 | #: src/util/getopt_helpers.c:630 | 8747 | #: src/util/getopt_helpers.c:631 |
8643 | #, c-format | 8748 | #, c-format |
8644 | msgid "You must pass relative time to the `%s' option.\n" | 8749 | msgid "You must pass relative time to the `%s' option.\n" |
8645 | msgstr "Debes introducir un tiempo relativo en la opción «%s».\n" | 8750 | msgstr "Debes introducir un tiempo relativo en la opción «%s».\n" |
8646 | 8751 | ||
8647 | #: src/util/getopt_helpers.c:684 | 8752 | #: src/util/getopt_helpers.c:685 |
8648 | #, fuzzy, c-format | 8753 | #, fuzzy, c-format |
8649 | msgid "You must pass absolute time to the `%s' option.\n" | 8754 | msgid "You must pass absolute time to the `%s' option.\n" |
8650 | msgstr "Debes introducir un tiempo relativo en la opción «%s».\n" | 8755 | msgstr "Debes introducir un tiempo relativo en la opción «%s».\n" |
8651 | 8756 | ||
8652 | #: src/util/getopt_helpers.c:741 | 8757 | #: src/util/getopt_helpers.c:742 |
8653 | #, fuzzy, c-format | 8758 | #, fuzzy, c-format |
8654 | msgid "You must pass a timestamp to the `%s' option.\n" | 8759 | msgid "You must pass a timestamp to the `%s' option.\n" |
8655 | msgstr "Tienes que introducir un número en la opción «%s».\n" | 8760 | msgstr "Tienes que introducir un número en la opción «%s».\n" |
8656 | 8761 | ||
8657 | #: src/util/getopt_helpers.c:748 | 8762 | #: src/util/getopt_helpers.c:749 |
8658 | #, c-format | 8763 | #, c-format |
8659 | msgid "The maximum precision allowed for timestamps is seconds.\n" | 8764 | msgid "The maximum precision allowed for timestamps is seconds.\n" |
8660 | msgstr "" | 8765 | msgstr "" |
8661 | 8766 | ||
8662 | #: src/util/getopt_helpers.c:804 | 8767 | #: src/util/getopt_helpers.c:805 |
8663 | #, c-format | 8768 | #, c-format |
8664 | msgid "Your input for the '%s' option has to be a non negative number\n" | 8769 | msgid "Your input for the '%s' option has to be a non negative number\n" |
8665 | msgstr "" | 8770 | msgstr "" |
8666 | 8771 | ||
8667 | #: src/util/getopt_helpers.c:874 | 8772 | #: src/util/getopt_helpers.c:875 |
8668 | #, fuzzy, c-format | 8773 | #, fuzzy, c-format |
8669 | msgid "You must pass a number below %u to the `%s' option.\n" | 8774 | msgid "You must pass a number below %u to the `%s' option.\n" |
8670 | msgstr "Tienes que introducir un número en la opción «%s».\n" | 8775 | msgstr "Tienes que introducir un número en la opción «%s».\n" |
8671 | 8776 | ||
8672 | #: src/util/getopt_helpers.c:952 | 8777 | #: src/util/getopt_helpers.c:953 |
8673 | #, c-format | 8778 | #, c-format |
8674 | msgid "Argument `%s' malformed. Expected base32 (Crockford) encoded value.\n" | 8779 | msgid "Argument `%s' malformed. Expected base32 (Crockford) encoded value.\n" |
8675 | msgstr "" | 8780 | msgstr "" |
@@ -8702,7 +8807,7 @@ msgstr "" | |||
8702 | msgid "Manipulate GNUnet configuration files" | 8807 | msgid "Manipulate GNUnet configuration files" |
8703 | msgstr "Manipular ficheros de configuración de GNUnet" | 8808 | msgstr "Manipular ficheros de configuración de GNUnet" |
8704 | 8809 | ||
8705 | #: src/util/gnunet-crypto-tvg.c:1072 | 8810 | #: src/util/gnunet-crypto-tvg.c:1483 |
8706 | msgid "verify a test vector from stdin" | 8811 | msgid "verify a test vector from stdin" |
8707 | msgstr "" | 8812 | msgstr "" |
8708 | 8813 | ||
@@ -8962,7 +9067,7 @@ msgstr "Error escribiendo a «%s»: %s\n" | |||
8962 | msgid "Unable to shorten unix path `%s' while keeping name unique\n" | 9067 | msgid "Unable to shorten unix path `%s' while keeping name unique\n" |
8963 | msgstr "Imposible acortar la ruta unix «%s» manteniendo el nombre único\n" | 9068 | msgstr "Imposible acortar la ruta unix «%s» manteniendo el nombre único\n" |
8964 | 9069 | ||
8965 | #: src/util/network.c:1306 | 9070 | #: src/util/network.c:1307 |
8966 | #, c-format | 9071 | #, c-format |
8967 | msgid "" | 9072 | msgid "" |
8968 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" | 9073 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" |
@@ -9102,85 +9207,85 @@ msgstr "" | |||
9102 | msgid "Character sets requested were `%s'->`%s'\n" | 9207 | msgid "Character sets requested were `%s'->`%s'\n" |
9103 | msgstr "Los conjuntos de caracteres pedidos fueron «%s»->«%s»\n" | 9208 | msgstr "Los conjuntos de caracteres pedidos fueron «%s»->«%s»\n" |
9104 | 9209 | ||
9105 | #: src/util/strings.c:487 | 9210 | #: src/util/strings.c:514 |
9106 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" | 9211 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" |
9107 | msgstr "" | 9212 | msgstr "" |
9108 | "Se produjo un fallo al expandir «$HOME»: variable de entorno «HOME» no " | 9213 | "Se produjo un fallo al expandir «$HOME»: variable de entorno «HOME» no " |
9109 | "establecida" | 9214 | "establecida" |
9110 | 9215 | ||
9111 | #: src/util/strings.c:1023 | 9216 | #: src/util/strings.c:1050 |
9112 | msgid "IPv6 address did not start with `['\n" | 9217 | msgid "IPv6 address did not start with `['\n" |
9113 | msgstr "La dirección IPv6 no empezaba con «[»\n" | 9218 | msgstr "La dirección IPv6 no empezaba con «[»\n" |
9114 | 9219 | ||
9115 | #: src/util/strings.c:1031 | 9220 | #: src/util/strings.c:1058 |
9116 | msgid "IPv6 address did contain ':' to separate port number\n" | 9221 | msgid "IPv6 address did contain ':' to separate port number\n" |
9117 | msgstr "La dirección IPv6 contenÃa «:» para separar el número de puerto\n" | 9222 | msgstr "La dirección IPv6 contenÃa «:» para separar el número de puerto\n" |
9118 | 9223 | ||
9119 | #: src/util/strings.c:1038 | 9224 | #: src/util/strings.c:1065 |
9120 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" | 9225 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" |
9121 | msgstr "" | 9226 | msgstr "" |
9122 | "La dirección IPv6 contenÃa «]» antes de «:» para separar el número de " | 9227 | "La dirección IPv6 contenÃa «]» antes de «:» para separar el número de " |
9123 | "puerto\n" | 9228 | "puerto\n" |
9124 | 9229 | ||
9125 | #: src/util/strings.c:1046 | 9230 | #: src/util/strings.c:1073 |
9126 | msgid "IPv6 address did contain a valid port number after the last ':'\n" | 9231 | msgid "IPv6 address did contain a valid port number after the last ':'\n" |
9127 | msgstr "" | 9232 | msgstr "" |
9128 | "La dirección IPv6 contenÃa un número de puerto válido después del último " | 9233 | "La dirección IPv6 contenÃa un número de puerto válido después del último " |
9129 | "«:»\n" | 9234 | "«:»\n" |
9130 | 9235 | ||
9131 | #: src/util/strings.c:1055 | 9236 | #: src/util/strings.c:1082 |
9132 | #, c-format | 9237 | #, c-format |
9133 | msgid "Invalid IPv6 address `%s': %s\n" | 9238 | msgid "Invalid IPv6 address `%s': %s\n" |
9134 | msgstr "Dirección IPv6 «%s» no válida: %s\n" | 9239 | msgstr "Dirección IPv6 «%s» no válida: %s\n" |
9135 | 9240 | ||
9136 | #: src/util/strings.c:1237 src/util/strings.c:1248 | 9241 | #: src/util/strings.c:1264 src/util/strings.c:1275 |
9137 | msgid "Port not in range\n" | 9242 | msgid "Port not in range\n" |
9138 | msgstr "" | 9243 | msgstr "" |
9139 | 9244 | ||
9140 | #: src/util/strings.c:1257 | 9245 | #: src/util/strings.c:1284 |
9141 | #, fuzzy, c-format | 9246 | #, fuzzy, c-format |
9142 | msgid "Malformed port policy `%s'\n" | 9247 | msgid "Malformed port policy `%s'\n" |
9143 | msgstr "Se produjo un fallo al iniciar el servicio «%s»\n" | 9248 | msgstr "Se produjo un fallo al iniciar el servicio «%s»\n" |
9144 | 9249 | ||
9145 | #: src/util/strings.c:1328 src/util/strings.c:1357 src/util/strings.c:1404 | 9250 | #: src/util/strings.c:1355 src/util/strings.c:1384 src/util/strings.c:1431 |
9146 | #: src/util/strings.c:1424 | 9251 | #: src/util/strings.c:1451 |
9147 | #, c-format | 9252 | #, c-format |
9148 | msgid "Invalid format for IP: `%s'\n" | 9253 | msgid "Invalid format for IP: `%s'\n" |
9149 | msgstr "Formato no válido para la IP: «%s»\n" | 9254 | msgstr "Formato no válido para la IP: «%s»\n" |
9150 | 9255 | ||
9151 | #: src/util/strings.c:1382 | 9256 | #: src/util/strings.c:1409 |
9152 | #, c-format | 9257 | #, c-format |
9153 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." | 9258 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." |
9154 | msgstr "Notación de red no válida («/%d» no es válido en IPv4 CIDR)." | 9259 | msgstr "Notación de red no válida («/%d» no es válido en IPv4 CIDR)." |
9155 | 9260 | ||
9156 | #: src/util/strings.c:1433 | 9261 | #: src/util/strings.c:1460 |
9157 | #, fuzzy, c-format | 9262 | #, fuzzy, c-format |
9158 | msgid "Invalid format: `%s'\n" | 9263 | msgid "Invalid format: `%s'\n" |
9159 | msgstr "Formato de tiempo no válido «%s»\n" | 9264 | msgstr "Formato de tiempo no válido «%s»\n" |
9160 | 9265 | ||
9161 | #: src/util/strings.c:1475 | 9266 | #: src/util/strings.c:1502 |
9162 | #, c-format | 9267 | #, c-format |
9163 | msgid "Invalid network notation (does not end with ';': `%s')\n" | 9268 | msgid "Invalid network notation (does not end with ';': `%s')\n" |
9164 | msgstr "Notación de red no válida (no termina con «;»: «%s»)\n" | 9269 | msgstr "Notación de red no válida (no termina con «;»: «%s»)\n" |
9165 | 9270 | ||
9166 | #: src/util/strings.c:1525 | 9271 | #: src/util/strings.c:1552 |
9167 | #, c-format | 9272 | #, c-format |
9168 | msgid "Wrong format `%s' for netmask\n" | 9273 | msgid "Wrong format `%s' for netmask\n" |
9169 | msgstr "Formato «%s» erroneo para máscara de red\n" | 9274 | msgstr "Formato «%s» erroneo para máscara de red\n" |
9170 | 9275 | ||
9171 | #: src/util/strings.c:1556 | 9276 | #: src/util/strings.c:1583 |
9172 | #, c-format | 9277 | #, c-format |
9173 | msgid "Wrong format `%s' for network\n" | 9278 | msgid "Wrong format `%s' for network\n" |
9174 | msgstr "Formato «%s» erroneo para red\n" | 9279 | msgstr "Formato «%s» erroneo para red\n" |
9175 | 9280 | ||
9176 | #: src/util/time.c:863 src/util/time.c:891 | 9281 | #: src/util/time.c:870 src/util/time.c:898 |
9177 | #, fuzzy, c-format | 9282 | #, fuzzy, c-format |
9178 | msgid "Failed to map `%s', cannot assure monotonic time!\n" | 9283 | msgid "Failed to map `%s', cannot assure monotonic time!\n" |
9179 | msgstr "" | 9284 | msgstr "" |
9180 | "Se produjo un fallo al recuperar el espacio de nombres «%s», no se pudo " | 9285 | "Se produjo un fallo al recuperar el espacio de nombres «%s», no se pudo " |
9181 | "retomar la operación de publicación.\n" | 9286 | "retomar la operación de publicación.\n" |
9182 | 9287 | ||
9183 | #: src/util/time.c:899 | 9288 | #: src/util/time.c:906 |
9184 | #, c-format | 9289 | #, c-format |
9185 | msgid "" | 9290 | msgid "" |
9186 | "Failed to setup monotonic time file `%s', cannot assure monotonic time!\n" | 9291 | "Failed to setup monotonic time file `%s', cannot assure monotonic time!\n" |
@@ -9362,11 +9467,44 @@ msgstr "el servicio es ofrecido vÃa UDP" | |||
9362 | msgid "Setup tunnels via VPN." | 9467 | msgid "Setup tunnels via VPN." |
9363 | msgstr "Configurar túneles vÃa VPN." | 9468 | msgstr "Configurar túneles vÃa VPN." |
9364 | 9469 | ||
9365 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:418 | 9470 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:397 |
9366 | #: src/zonemaster/gnunet-service-zonemaster.c:847 | 9471 | #: src/zonemaster/gnunet-service-zonemaster.c:832 |
9367 | msgid "Failed to connect to the namestore!\n" | 9472 | msgid "Failed to connect to the namestore!\n" |
9368 | msgstr "¡Se produjo un fallo al conectar con el almacén de nombres!\n" | 9473 | msgstr "¡Se produjo un fallo al conectar con el almacén de nombres!\n" |
9369 | 9474 | ||
9475 | #~ msgid "# items stored" | ||
9476 | #~ msgstr "# elementos almacenados" | ||
9477 | |||
9478 | #, c-format | ||
9479 | #~ msgid "Loading `%s' datacache plugin\n" | ||
9480 | #~ msgstr "Cargando el módulo de la cache de datos «%s»\n" | ||
9481 | |||
9482 | #, c-format | ||
9483 | #~ msgid "Failed to load datacache plugin for `%s'\n" | ||
9484 | #~ msgstr "" | ||
9485 | #~ "Se produjo un fallo al cargar el módulo de la cache de datos para «%s»\n" | ||
9486 | |||
9487 | #~ msgid "# requests received" | ||
9488 | #~ msgstr "# peticiones recibidas" | ||
9489 | |||
9490 | #~ msgid "# requests filtered by bloom filter" | ||
9491 | #~ msgstr "# peticiones filtradas por el «bloomfilter»" | ||
9492 | |||
9493 | #, fuzzy | ||
9494 | #~ msgid "# proximity search requests received" | ||
9495 | #~ msgstr "# búsquedas de clientes recibidas" | ||
9496 | |||
9497 | #~ msgid "write search results to file starting with PREFIX" | ||
9498 | #~ msgstr "" | ||
9499 | #~ "escribir resultados de búsqueda al fichero que empiecen por «PREFIX»" | ||
9500 | |||
9501 | #~ msgid "automatically terminate search after DELAY" | ||
9502 | #~ msgstr "terminar búsqueda automáticamente después de «DELAY»" | ||
9503 | |||
9504 | #, fuzzy | ||
9505 | #~ msgid "Namestore failed to store record\n" | ||
9506 | #~ msgstr "El almacén de nombres no pudo añadir el registro\n" | ||
9507 | |||
9370 | #, fuzzy | 9508 | #, fuzzy |
9371 | #~ msgid "# requests for random value received" | 9509 | #~ msgid "# requests for random value received" |
9372 | #~ msgstr "# peticiones recibidas" | 9510 | #~ msgstr "# peticiones recibidas" |
@@ -11531,9 +11669,6 @@ msgstr "¡Se produjo un fallo al conectar con el almacén de nombres!\n" | |||
11531 | #~ msgid "interrupted by shutdown" | 11669 | #~ msgid "interrupted by shutdown" |
11532 | #~ msgstr "interrumpido por apagado" | 11670 | #~ msgstr "interrumpido por apagado" |
11533 | 11671 | ||
11534 | #~ msgid "gnunet-ecc failed" | ||
11535 | #~ msgstr "«gnunet-ecc» falló" | ||
11536 | |||
11537 | #~ msgid "" | 11672 | #~ msgid "" |
11538 | #~ "File `%s' does not contain a valid private key (too long, %llu bytes). " | 11673 | #~ "File `%s' does not contain a valid private key (too long, %llu bytes). " |
11539 | #~ "Renaming it.\n" | 11674 | #~ "Renaming it.\n" |
@@ -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: 2022-01-10 15:13+0100\n" | 10 | "POT-Creation-Date: 2022-03-04 22:23+0100\n" |
11 | "PO-Revision-Date: 2021-11-21 00:53+0100\n" | 11 | "PO-Revision-Date: 2021-11-21 00:53+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" |
@@ -17,7 +17,7 @@ msgstr "" | |||
17 | "Content-Transfer-Encoding: 8bit\n" | 17 | "Content-Transfer-Encoding: 8bit\n" |
18 | "X-Bugs: Report translation errors to the Language-Team address.\n" | 18 | "X-Bugs: Report translation errors to the Language-Team address.\n" |
19 | 19 | ||
20 | #: src/abd/gnunet-abd.c:392 src/namestore/gnunet-namestore.c:1304 | 20 | #: src/abd/gnunet-abd.c:392 src/namestore/gnunet-namestore.c:1254 |
21 | #, c-format | 21 | #, c-format |
22 | msgid "Ego `%s' not known to identity service\n" | 22 | msgid "Ego `%s' not known to identity service\n" |
23 | msgstr "" | 23 | msgstr "" |
@@ -29,7 +29,7 @@ msgstr "" | |||
29 | 29 | ||
30 | #: src/abd/gnunet-abd.c:558 src/abd/gnunet-service-abd.c:1751 | 30 | #: src/abd/gnunet-abd.c:558 src/abd/gnunet-service-abd.c:1751 |
31 | #: src/namestore/gnunet-namestore-fcfsd.c:1080 | 31 | #: src/namestore/gnunet-namestore-fcfsd.c:1080 |
32 | #: src/namestore/gnunet-namestore.c:1001 | 32 | #: src/namestore/gnunet-namestore.c:951 |
33 | #, c-format | 33 | #, c-format |
34 | msgid "Failed to connect to namestore\n" | 34 | msgid "Failed to connect to namestore\n" |
35 | msgstr "" | 35 | msgstr "" |
@@ -611,44 +611,44 @@ msgstr "" | |||
611 | msgid "Print information about ATS state" | 611 | msgid "Print information about ATS state" |
612 | msgstr "" | 612 | msgstr "" |
613 | 613 | ||
614 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | 614 | #: src/ats/gnunet-ats-solver-eval.c:2993 src/ats/gnunet-ats-solver-eval.c:3045 |
615 | #, c-format | 615 | #, c-format |
616 | msgid "" | 616 | msgid "" |
617 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | 617 | "Could not load quota for network `%s': `%s', assigning default bandwidth " |
618 | "%llu\n" | 618 | "%llu\n" |
619 | msgstr "" | 619 | msgstr "" |
620 | 620 | ||
621 | #: src/ats/gnunet-ats-solver-eval.c:3011 | 621 | #: src/ats/gnunet-ats-solver-eval.c:3012 |
622 | #, c-format | 622 | #, c-format |
623 | msgid "" | 623 | msgid "" |
624 | "No outbound quota configured for network `%s', assigning default bandwidth " | 624 | "No outbound quota configured for network `%s', assigning default bandwidth " |
625 | "%llu\n" | 625 | "%llu\n" |
626 | msgstr "" | 626 | msgstr "" |
627 | 627 | ||
628 | #: src/ats/gnunet-ats-solver-eval.c:3063 | 628 | #: src/ats/gnunet-ats-solver-eval.c:3064 |
629 | #, c-format | 629 | #, c-format |
630 | msgid "" | 630 | msgid "" |
631 | "No outbound quota configure for network `%s', assigning default bandwidth " | 631 | "No outbound quota configure for network `%s', assigning default bandwidth " |
632 | "%llu\n" | 632 | "%llu\n" |
633 | msgstr "" | 633 | msgstr "" |
634 | 634 | ||
635 | #: src/ats/gnunet-ats-solver-eval.c:3552 | 635 | #: src/ats/gnunet-ats-solver-eval.c:3553 |
636 | msgid "solver to use" | 636 | msgid "solver to use" |
637 | msgstr "solveur utilisé" | 637 | msgstr "solveur utilisé" |
638 | 638 | ||
639 | #: src/ats/gnunet-ats-solver-eval.c:3557 | 639 | #: src/ats/gnunet-ats-solver-eval.c:3558 |
640 | msgid "experiment to use" | 640 | msgid "experiment to use" |
641 | msgstr "" | 641 | msgstr "" |
642 | 642 | ||
643 | #: src/ats/gnunet-ats-solver-eval.c:3564 | 643 | #: src/ats/gnunet-ats-solver-eval.c:3565 |
644 | msgid "print logging" | 644 | msgid "print logging" |
645 | msgstr "afficher le journal" | 645 | msgstr "afficher le journal" |
646 | 646 | ||
647 | #: src/ats/gnunet-ats-solver-eval.c:3569 | 647 | #: src/ats/gnunet-ats-solver-eval.c:3570 |
648 | msgid "save logging to disk" | 648 | msgid "save logging to disk" |
649 | msgstr "" | 649 | msgstr "" |
650 | 650 | ||
651 | #: src/ats/gnunet-ats-solver-eval.c:3574 | 651 | #: src/ats/gnunet-ats-solver-eval.c:3575 |
652 | msgid "disable normalization" | 652 | msgid "disable normalization" |
653 | msgstr "" | 653 | msgstr "" |
654 | 654 | ||
@@ -1492,38 +1492,7 @@ msgstr "" | |||
1492 | msgid "# updates to my type map" | 1492 | msgid "# updates to my type map" |
1493 | msgstr "" | 1493 | msgstr "" |
1494 | 1494 | ||
1495 | #: src/datacache/datacache.c:117 src/datacache/datacache.c:275 | 1495 | #: src/datacache/plugin_datacache_heap.c:555 |
1496 | #: src/datastore/gnunet-service-datastore.c:743 | ||
1497 | msgid "# bytes stored" | ||
1498 | msgstr "" | ||
1499 | |||
1500 | #: src/datacache/datacache.c:121 src/datacache/datacache.c:279 | ||
1501 | msgid "# items stored" | ||
1502 | msgstr "" | ||
1503 | |||
1504 | #: src/datacache/datacache.c:185 | ||
1505 | #, c-format | ||
1506 | msgid "Loading `%s' datacache plugin\n" | ||
1507 | msgstr "" | ||
1508 | |||
1509 | #: src/datacache/datacache.c:203 | ||
1510 | #, c-format | ||
1511 | msgid "Failed to load datacache plugin for `%s'\n" | ||
1512 | msgstr "" | ||
1513 | |||
1514 | #: src/datacache/datacache.c:297 | ||
1515 | msgid "# requests received" | ||
1516 | msgstr "" | ||
1517 | |||
1518 | #: src/datacache/datacache.c:308 | ||
1519 | msgid "# requests filtered by bloom filter" | ||
1520 | msgstr "" | ||
1521 | |||
1522 | #: src/datacache/datacache.c:329 | ||
1523 | msgid "# proximity search requests received" | ||
1524 | msgstr "" | ||
1525 | |||
1526 | #: src/datacache/plugin_datacache_heap.c:527 | ||
1527 | msgid "Heap datacache running\n" | 1496 | msgid "Heap datacache running\n" |
1528 | msgstr "" | 1497 | msgstr "" |
1529 | 1498 | ||
@@ -1545,7 +1514,7 @@ msgstr "" | |||
1545 | msgid "`%s' failed at %s:%d with error: %s\n" | 1514 | msgid "`%s' failed at %s:%d with error: %s\n" |
1546 | msgstr "" | 1515 | msgstr "" |
1547 | 1516 | ||
1548 | #: src/datacache/plugin_datacache_sqlite.c:693 | 1517 | #: src/datacache/plugin_datacache_sqlite.c:723 |
1549 | #: src/datastore/plugin_datastore_sqlite.c:531 | 1518 | #: src/datastore/plugin_datastore_sqlite.c:531 |
1550 | #: src/namecache/plugin_namecache_sqlite.c:237 | 1519 | #: src/namecache/plugin_namecache_sqlite.c:237 |
1551 | #: src/namestore/plugin_namestore_sqlite.c:273 | 1520 | #: src/namestore/plugin_namestore_sqlite.c:273 |
@@ -1728,6 +1697,10 @@ msgstr "# réservé" | |||
1728 | msgid "Could not find matching reservation" | 1697 | msgid "Could not find matching reservation" |
1729 | msgstr "" | 1698 | msgstr "" |
1730 | 1699 | ||
1700 | #: src/datastore/gnunet-service-datastore.c:743 | ||
1701 | msgid "# bytes stored" | ||
1702 | msgstr "" | ||
1703 | |||
1731 | #: src/datastore/gnunet-service-datastore.c:758 | 1704 | #: src/datastore/gnunet-service-datastore.c:758 |
1732 | #, c-format | 1705 | #, c-format |
1733 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" | 1706 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" |
@@ -1907,7 +1880,7 @@ msgstr "" | |||
1907 | 1880 | ||
1908 | #: src/datastore/plugin_datastore_sqlite.c:1337 | 1881 | #: src/datastore/plugin_datastore_sqlite.c:1337 |
1909 | #: src/namecache/plugin_namecache_sqlite.c:564 | 1882 | #: src/namecache/plugin_namecache_sqlite.c:564 |
1910 | #: src/namestore/plugin_namestore_sqlite.c:765 | 1883 | #: src/namestore/plugin_namestore_sqlite.c:775 |
1911 | msgid "Sqlite database running\n" | 1884 | msgid "Sqlite database running\n" |
1912 | msgstr "" | 1885 | msgstr "" |
1913 | 1886 | ||
@@ -1915,7 +1888,7 @@ msgstr "" | |||
1915 | msgid "Template database running\n" | 1888 | msgid "Template database running\n" |
1916 | msgstr "" | 1889 | msgstr "" |
1917 | 1890 | ||
1918 | #: src/dht/gnunet-dht-get.c:159 | 1891 | #: src/dht/gnunet-dht-get.c:164 |
1919 | #, c-format | 1892 | #, c-format |
1920 | msgid "" | 1893 | msgid "" |
1921 | "Result %d, type %d:\n" | 1894 | "Result %d, type %d:\n" |
@@ -1924,50 +1897,60 @@ msgstr "" | |||
1924 | "Resultat %d, type %d :\n" | 1897 | "Resultat %d, type %d :\n" |
1925 | "%.*s\n" | 1898 | "%.*s\n" |
1926 | 1899 | ||
1927 | #: src/dht/gnunet-dht-get.c:160 | 1900 | #: src/dht/gnunet-dht-get.c:165 |
1928 | #, fuzzy, c-format | 1901 | #, fuzzy, c-format |
1929 | msgid "Result %d, type %d:\n" | 1902 | msgid "Result %d, type %d:\n" |
1930 | msgstr "" | 1903 | msgstr "" |
1931 | "Resultat %d, type %d :\n" | 1904 | "Resultat %d, type %d :\n" |
1932 | "%.*s\n" | 1905 | "%.*s\n" |
1933 | 1906 | ||
1934 | #: src/dht/gnunet-dht-get.c:209 | 1907 | #: src/dht/gnunet-dht-get.c:215 |
1935 | msgid "Must provide key for DHT GET!\n" | 1908 | msgid "Must provide key for DHT GET!\n" |
1936 | msgstr "" | 1909 | msgstr "" |
1937 | 1910 | ||
1938 | #: src/dht/gnunet-dht-get.c:217 src/dht/gnunet-dht-monitor.c:255 | 1911 | #: src/dht/gnunet-dht-get.c:223 src/dht/gnunet-dht-hello.c:119 |
1912 | #: src/dht/gnunet-dht-monitor.c:255 | ||
1913 | #, c-format | ||
1939 | msgid "Failed to connect to DHT service!\n" | 1914 | msgid "Failed to connect to DHT service!\n" |
1940 | msgstr "" | 1915 | msgstr "" |
1941 | 1916 | ||
1942 | #: src/dht/gnunet-dht-get.c:227 | 1917 | #: src/dht/gnunet-dht-get.c:233 |
1943 | msgid "Issuing DHT GET with key" | 1918 | msgid "Issuing DHT GET with key" |
1944 | msgstr "" | 1919 | msgstr "" |
1945 | 1920 | ||
1946 | #: src/dht/gnunet-dht-get.c:260 src/dht/gnunet-dht-monitor.c:302 | 1921 | #: src/dht/gnunet-dht-get.c:269 src/dht/gnunet-dht-monitor.c:302 |
1947 | #: src/dht/gnunet-dht-put.c:200 | 1922 | #: src/dht/gnunet-dht-put.c:200 |
1948 | msgid "the query key" | 1923 | msgid "the query key" |
1949 | msgstr "" | 1924 | msgstr "" |
1950 | 1925 | ||
1951 | #: src/dht/gnunet-dht-get.c:266 | 1926 | #: src/dht/gnunet-dht-get.c:275 |
1952 | msgid "how many parallel requests (replicas) to create" | 1927 | msgid "how many parallel requests (replicas) to create" |
1953 | msgstr "" | 1928 | msgstr "" |
1954 | 1929 | ||
1955 | #: src/dht/gnunet-dht-get.c:272 src/dht/gnunet-dht-monitor.c:308 | 1930 | #: src/dht/gnunet-dht-get.c:280 src/dht/gnunet-dht-put.c:217 |
1931 | msgid "use DHT's record route option" | ||
1932 | msgstr "" | ||
1933 | |||
1934 | #: src/dht/gnunet-dht-get.c:286 src/dht/gnunet-dht-monitor.c:308 | ||
1956 | msgid "the type of data to look for" | 1935 | msgid "the type of data to look for" |
1957 | msgstr "" | 1936 | msgstr "" |
1958 | 1937 | ||
1959 | #: src/dht/gnunet-dht-get.c:278 | 1938 | #: src/dht/gnunet-dht-get.c:292 |
1960 | msgid "how long to execute this query before giving up?" | 1939 | msgid "how long to execute this query before giving up?" |
1961 | msgstr "" | 1940 | msgstr "" |
1962 | 1941 | ||
1963 | #: src/dht/gnunet-dht-get.c:284 src/dht/gnunet-dht-put.c:206 | 1942 | #: src/dht/gnunet-dht-get.c:298 src/dht/gnunet-dht-put.c:206 |
1964 | msgid "use DHT's demultiplex everywhere option" | 1943 | msgid "use DHT's demultiplex everywhere option" |
1965 | msgstr "" | 1944 | msgstr "" |
1966 | 1945 | ||
1967 | #: src/dht/gnunet-dht-get.c:301 | 1946 | #: src/dht/gnunet-dht-get.c:315 |
1968 | msgid "Issue a GET request to the GNUnet DHT, prints results." | 1947 | msgid "Issue a GET request to the GNUnet DHT, prints results." |
1969 | msgstr "" | 1948 | msgstr "" |
1970 | 1949 | ||
1950 | #: src/dht/gnunet-dht-hello.c:166 | ||
1951 | msgid "Obtain HELLO from DHT or provide HELLO to DHT for bootstrapping" | ||
1952 | msgstr "" | ||
1953 | |||
1971 | #: src/dht/gnunet-dht-monitor.c:315 | 1954 | #: src/dht/gnunet-dht-monitor.c:315 |
1972 | msgid "how long should the monitor command run" | 1955 | msgid "how long should the monitor command run" |
1973 | msgstr "" | 1956 | msgstr "" |
@@ -2007,10 +1990,6 @@ msgstr "" | |||
2007 | msgid "how many replicas to create" | 1990 | msgid "how many replicas to create" |
2008 | msgstr "" | 1991 | msgstr "" |
2009 | 1992 | ||
2010 | #: src/dht/gnunet-dht-put.c:217 | ||
2011 | msgid "use DHT's record route option" | ||
2012 | msgstr "" | ||
2013 | |||
2014 | #: src/dht/gnunet-dht-put.c:223 | 1993 | #: src/dht/gnunet-dht-put.c:223 |
2015 | msgid "the type to insert data as" | 1994 | msgid "the type to insert data as" |
2016 | msgstr "" | 1995 | msgstr "" |
@@ -2066,17 +2045,17 @@ msgstr "" | |||
2066 | msgid "Measure quality and performance of the DHT service." | 2045 | msgid "Measure quality and performance of the DHT service." |
2067 | msgstr "" | 2046 | msgstr "" |
2068 | 2047 | ||
2069 | #: src/dht/plugin_block_dht.c:328 | 2048 | #: src/dht/plugin_block_dht.c:404 |
2070 | #, c-format | 2049 | #, c-format |
2071 | msgid "Block not of type %u\n" | 2050 | msgid "Block not of type %u\n" |
2072 | msgstr "" | 2051 | msgstr "" |
2073 | 2052 | ||
2074 | #: src/dht/plugin_block_dht.c:337 | 2053 | #: src/dht/plugin_block_dht.c:413 |
2075 | #, c-format | 2054 | #, c-format |
2076 | msgid "Size mismatch for block with type %u\n" | 2055 | msgid "Size mismatch for block with type %u\n" |
2077 | msgstr "" | 2056 | msgstr "" |
2078 | 2057 | ||
2079 | #: src/dht/plugin_block_dht.c:348 | 2058 | #: src/dht/plugin_block_dht.c:424 |
2080 | #, c-format | 2059 | #, c-format |
2081 | msgid "Block of type %u is malformed\n" | 2060 | msgid "Block of type %u is malformed\n" |
2082 | msgstr "" | 2061 | msgstr "" |
@@ -2767,20 +2746,20 @@ msgstr "" | |||
2767 | msgid "LOC URI malformed (signature failed validation)" | 2746 | msgid "LOC URI malformed (signature failed validation)" |
2768 | msgstr "" | 2747 | msgstr "" |
2769 | 2748 | ||
2770 | #: src/fs/fs_uri.c:653 | 2749 | #: src/fs/fs_uri.c:652 |
2771 | #, fuzzy | 2750 | #, fuzzy |
2772 | msgid "invalid argument" | 2751 | msgid "invalid argument" |
2773 | msgstr "Argument invalide « %s »\n" | 2752 | msgstr "Argument invalide « %s »\n" |
2774 | 2753 | ||
2775 | #: src/fs/fs_uri.c:665 | 2754 | #: src/fs/fs_uri.c:671 |
2776 | msgid "Unrecognized URI type" | 2755 | msgid "Unrecognized URI type" |
2777 | msgstr "Type d’URI non reconnu" | 2756 | msgstr "Type d’URI non reconnu" |
2778 | 2757 | ||
2779 | #: src/fs/fs_uri.c:1071 src/fs/fs_uri.c:1098 | 2758 | #: src/fs/fs_uri.c:1075 src/fs/fs_uri.c:1102 |
2780 | msgid "No keywords specified!\n" | 2759 | msgid "No keywords specified!\n" |
2781 | msgstr "" | 2760 | msgstr "" |
2782 | 2761 | ||
2783 | #: src/fs/fs_uri.c:1104 | 2762 | #: src/fs/fs_uri.c:1108 |
2784 | msgid "Number of double-quotes not balanced!\n" | 2763 | msgid "Number of double-quotes not balanced!\n" |
2785 | msgstr "" | 2764 | msgstr "" |
2786 | 2765 | ||
@@ -2904,7 +2883,7 @@ msgid "Downloading `%s' done (%s/s).\n" | |||
2904 | msgstr "" | 2883 | msgstr "" |
2905 | 2884 | ||
2906 | #: src/fs/gnunet-download.c:206 src/fs/gnunet-publish.c:299 | 2885 | #: src/fs/gnunet-download.c:206 src/fs/gnunet-publish.c:299 |
2907 | #: src/fs/gnunet-search.c:229 src/fs/gnunet-unindex.c:117 | 2886 | #: src/fs/gnunet-search.c:538 src/fs/gnunet-unindex.c:117 |
2908 | #, c-format | 2887 | #, c-format |
2909 | msgid "Unexpected status: %d\n" | 2888 | msgid "Unexpected status: %d\n" |
2910 | msgstr "" | 2889 | msgstr "" |
@@ -2927,12 +2906,12 @@ msgid "Target filename must be specified.\n" | |||
2927 | msgstr "" | 2906 | msgstr "" |
2928 | 2907 | ||
2929 | #: src/fs/gnunet-download.c:271 src/fs/gnunet-publish.c:869 | 2908 | #: src/fs/gnunet-download.c:271 src/fs/gnunet-publish.c:869 |
2930 | #: src/fs/gnunet-search.c:294 src/fs/gnunet-unindex.c:154 | 2909 | #: src/fs/gnunet-unindex.c:154 |
2931 | #, c-format | 2910 | #, c-format |
2932 | msgid "Could not initialize `%s' subsystem.\n" | 2911 | msgid "Could not initialize `%s' subsystem.\n" |
2933 | msgstr "" | 2912 | msgstr "" |
2934 | 2913 | ||
2935 | #: src/fs/gnunet-download.c:318 src/fs/gnunet-search.c:334 | 2914 | #: src/fs/gnunet-download.c:318 |
2936 | msgid "set the desired LEVEL of receiver-anonymity" | 2915 | msgid "set the desired LEVEL of receiver-anonymity" |
2937 | msgstr "" | 2916 | msgstr "" |
2938 | 2917 | ||
@@ -2940,7 +2919,7 @@ msgstr "" | |||
2940 | msgid "delete incomplete downloads (when aborted with CTRL-C)" | 2919 | msgid "delete incomplete downloads (when aborted with CTRL-C)" |
2941 | msgstr "" | 2920 | msgstr "" |
2942 | 2921 | ||
2943 | #: src/fs/gnunet-download.c:330 src/fs/gnunet-search.c:339 | 2922 | #: src/fs/gnunet-download.c:330 src/fs/gnunet-search.c:740 |
2944 | msgid "only search the local peer (no P2P network search)" | 2923 | msgid "only search the local peer (no P2P network search)" |
2945 | msgstr "" | 2924 | msgstr "" |
2946 | 2925 | ||
@@ -3176,38 +3155,110 @@ msgstr "" | |||
3176 | msgid "Publish a file or directory on GNUnet" | 3155 | msgid "Publish a file or directory on GNUnet" |
3177 | msgstr "" | 3156 | msgstr "" |
3178 | 3157 | ||
3179 | #: src/fs/gnunet-search.c:130 | 3158 | #: src/fs/gnunet-search.c:441 |
3180 | #, c-format | 3159 | #, c-format |
3181 | msgid "Failed to write directory with search results to `%s'\n" | 3160 | msgid "Failed to write directory with search results to `%s'\n" |
3182 | msgstr "" | 3161 | msgstr "" |
3183 | 3162 | ||
3184 | #: src/fs/gnunet-search.c:219 | 3163 | #: src/fs/gnunet-search.c:527 |
3185 | #, c-format | 3164 | #, c-format |
3186 | msgid "Error searching: %s.\n" | 3165 | msgid "Error searching: %s.\n" |
3187 | msgstr "" | 3166 | msgstr "" |
3188 | 3167 | ||
3189 | #: src/fs/gnunet-search.c:281 | 3168 | #: src/fs/gnunet-search.c:587 |
3169 | #, c-format | ||
3170 | msgid "Conflicting options --bookmark-only and --silent.\n" | ||
3171 | msgstr "" | ||
3172 | |||
3173 | #: src/fs/gnunet-search.c:594 | ||
3174 | #, c-format | ||
3175 | msgid "Conflicting options --bookmark-only and --output.\n" | ||
3176 | msgstr "" | ||
3177 | |||
3178 | #: src/fs/gnunet-search.c:600 | ||
3179 | #, c-format | ||
3180 | msgid "An output file is mandatory for silent mode.\n" | ||
3181 | msgstr "" | ||
3182 | |||
3183 | #: src/fs/gnunet-search.c:621 | ||
3190 | msgid "Could not create keyword URI from arguments.\n" | 3184 | msgid "Could not create keyword URI from arguments.\n" |
3191 | msgstr "" | 3185 | msgstr "" |
3192 | 3186 | ||
3193 | #: src/fs/gnunet-search.c:308 | 3187 | #: src/fs/gnunet-search.c:629 |
3188 | msgid "" | ||
3189 | "Invalid URI. Valid URIs for searching are keyword query URIs\n" | ||
3190 | "(\"gnunet://fs/ksk/...\") and namespace content URIs (\"gnunet://fs/sks/..." | ||
3191 | "\").\n" | ||
3192 | msgstr "" | ||
3193 | |||
3194 | #: src/fs/gnunet-search.c:654 | ||
3195 | #, c-format | ||
3196 | msgid "Could not initialize the `%s` subsystem.\n" | ||
3197 | msgstr "" | ||
3198 | |||
3199 | #: src/fs/gnunet-search.c:668 | ||
3194 | msgid "Could not start searching.\n" | 3200 | msgid "Could not start searching.\n" |
3195 | msgstr "" | 3201 | msgstr "" |
3196 | 3202 | ||
3197 | #: src/fs/gnunet-search.c:345 | 3203 | #: src/fs/gnunet-search.c:694 |
3198 | msgid "write search results to file starting with PREFIX" | 3204 | msgid "set the desired LEVEL of receiver-anonymity (default: 1)" |
3205 | msgstr "" | ||
3206 | |||
3207 | #: src/fs/gnunet-search.c:700 | ||
3208 | msgid "do not search, print only the URI that points to this search" | ||
3209 | msgstr "" | ||
3210 | |||
3211 | #: src/fs/gnunet-search.c:707 | ||
3212 | msgid "" | ||
3213 | "write search results for directories according to FORMAT; accepted " | ||
3214 | "placeholders are: %a, %f, %j, %l, %m, %n, %s; defaults to the value of --" | ||
3215 | "printf when omitted or to `" | ||
3216 | msgstr "" | ||
3217 | |||
3218 | #: src/fs/gnunet-search.c:717 | ||
3219 | msgid "" | ||
3220 | "write search results according to FORMAT; accepted placeholders are: %a, %f, " | ||
3221 | "%j, %l, %m, %n, %s; defaults to `" | ||
3199 | msgstr "" | 3222 | msgstr "" |
3200 | 3223 | ||
3201 | #: src/fs/gnunet-search.c:351 | 3224 | #: src/fs/gnunet-search.c:725 |
3202 | msgid "automatically terminate search after DELAY" | 3225 | msgid "" |
3226 | "when the %a or %j placeholders appear in --printf or --dir-printf, list each " | ||
3227 | "metadata property according to FORMAT; accepted placeholders are: %i, %l, " | ||
3228 | "%n, %p" | ||
3203 | msgstr "" | 3229 | msgstr "" |
3204 | 3230 | ||
3205 | #: src/fs/gnunet-search.c:357 | 3231 | #: src/fs/gnunet-search.c:734 |
3206 | msgid "automatically terminate search after VALUE results are found" | 3232 | msgid "automatically terminate search after VALUE results are found" |
3207 | msgstr "" | 3233 | msgstr "" |
3208 | 3234 | ||
3209 | #: src/fs/gnunet-search.c:371 | 3235 | #: src/fs/gnunet-search.c:746 |
3210 | msgid "Search GNUnet for files that were published on GNUnet" | 3236 | msgid "" |
3237 | "create a GNUnet directory with search results at FILENAME (e.g. `gnunet-" | ||
3238 | "search --output=commons" | ||
3239 | msgstr "" | ||
3240 | |||
3241 | #: src/fs/gnunet-search.c:753 | ||
3242 | msgid "silent mode (requires the --output argument)" | ||
3243 | msgstr "" | ||
3244 | |||
3245 | #: src/fs/gnunet-search.c:759 | ||
3246 | msgid "" | ||
3247 | "automatically terminate search after DELAY; the value given must be a number " | ||
3248 | "followed by a space and a time unit, for example \"500 ms\"; without a unit " | ||
3249 | "it defaults to microseconds - 1000000 = 1 second; if 0 or omitted it means " | ||
3250 | "to wait for CTRL-C" | ||
3251 | msgstr "" | ||
3252 | |||
3253 | #: src/fs/gnunet-search.c:768 | ||
3254 | #, c-format | ||
3255 | msgid "" | ||
3256 | "be verbose (append \"%a\\n\" to the default --printf and --dir-printf " | ||
3257 | "arguments - ignored when these are provided by the user)" | ||
3258 | msgstr "" | ||
3259 | |||
3260 | #: src/fs/gnunet-search.c:781 | ||
3261 | msgid "Search for files that have been published on GNUnet\n" | ||
3211 | msgstr "" | 3262 | msgstr "" |
3212 | 3263 | ||
3213 | #: src/fs/gnunet-service-fs.c:371 src/fs/gnunet-service-fs.c:878 | 3264 | #: src/fs/gnunet-service-fs.c:371 src/fs/gnunet-service-fs.c:878 |
@@ -3531,64 +3582,69 @@ msgstr "" | |||
3531 | msgid "Expected a base32-encoded public zone key\n" | 3582 | msgid "Expected a base32-encoded public zone key\n" |
3532 | msgstr "" | 3583 | msgstr "" |
3533 | 3584 | ||
3534 | #: src/gns/gnunet-bcd.c:571 | 3585 | #: src/gns/gnunet-bcd.c:573 |
3535 | #, fuzzy, c-format | 3586 | #, fuzzy, c-format |
3536 | msgid "Invalid port number %u\n" | 3587 | msgid "Invalid port number %u\n" |
3537 | msgstr "Argument invalide « %s »\n" | 3588 | msgstr "Argument invalide « %s »\n" |
3538 | 3589 | ||
3539 | #: src/gns/gnunet-bcd.c:612 src/namestore/gnunet-namestore-fcfsd.c:1113 | 3590 | #: src/gns/gnunet-bcd.c:614 src/namestore/gnunet-namestore-fcfsd.c:1113 |
3540 | msgid "Unable to set up the daemon\n" | 3591 | msgid "Unable to set up the daemon\n" |
3541 | msgstr "" | 3592 | msgstr "" |
3542 | 3593 | ||
3543 | #: src/gns/gnunet-bcd.c:635 src/namestore/gnunet-namestore-fcfsd.c:987 | 3594 | #: src/gns/gnunet-bcd.c:637 src/namestore/gnunet-namestore-fcfsd.c:987 |
3544 | msgid "Failed to start HTTP server\n" | 3595 | msgid "Failed to start HTTP server\n" |
3545 | msgstr "" | 3596 | msgstr "" |
3546 | 3597 | ||
3547 | #: src/gns/gnunet-bcd.c:658 | 3598 | #: src/gns/gnunet-bcd.c:660 |
3548 | msgid "Run HTTP server on port PORT (default is 8888)" | 3599 | msgid "Run HTTP server on port PORT (default is 8888)" |
3549 | msgstr "" | 3600 | msgstr "" |
3550 | 3601 | ||
3551 | #: src/gns/gnunet-bcd.c:667 | 3602 | #: src/gns/gnunet-bcd.c:669 |
3552 | msgid "GNUnet HTTP server to create business cards" | 3603 | msgid "GNUnet HTTP server to create business cards" |
3553 | msgstr "" | 3604 | msgstr "" |
3554 | 3605 | ||
3555 | #: src/gns/gnunet-dns2gns.c:241 | 3606 | #: src/gns/gnunet-dns2gns.c:298 |
3556 | msgid "Failed to pack DNS response into UDP packet!\n" | 3607 | msgid "Failed to pack DNS response into UDP packet!\n" |
3557 | msgstr "" | 3608 | msgstr "" |
3558 | 3609 | ||
3559 | #: src/gns/gnunet-dns2gns.c:315 | 3610 | #: src/gns/gnunet-dns2gns.c:379 |
3560 | #, fuzzy | 3611 | #, fuzzy |
3561 | msgid "Failed to parse DNS response!\n" | 3612 | msgid "Failed to parse DNS response!\n" |
3562 | msgstr "Échec du démarrage de %s\n" | 3613 | msgstr "Échec du démarrage de %s\n" |
3563 | 3614 | ||
3564 | #: src/gns/gnunet-dns2gns.c:452 | 3615 | #: src/gns/gnunet-dns2gns.c:453 |
3616 | #, c-format | ||
3617 | msgid "VPN returned empty result for `%s'\n" | ||
3618 | msgstr "" | ||
3619 | |||
3620 | #: src/gns/gnunet-dns2gns.c:655 | ||
3565 | #, c-format | 3621 | #, c-format |
3566 | msgid "Cannot parse DNS request from %s\n" | 3622 | msgid "Cannot parse DNS request from %s\n" |
3567 | msgstr "" | 3623 | msgstr "" |
3568 | 3624 | ||
3569 | #: src/gns/gnunet-dns2gns.c:468 | 3625 | #: src/gns/gnunet-dns2gns.c:671 |
3570 | #, c-format | 3626 | #, c-format |
3571 | msgid "Received malformed DNS request from %s\n" | 3627 | msgid "Received malformed DNS request from %s\n" |
3572 | msgstr "" | 3628 | msgstr "" |
3573 | 3629 | ||
3574 | #: src/gns/gnunet-dns2gns.c:476 | 3630 | #: src/gns/gnunet-dns2gns.c:679 |
3575 | #, c-format | 3631 | #, c-format |
3576 | msgid "Received unsupported DNS request from %s\n" | 3632 | msgid "Received unsupported DNS request from %s\n" |
3577 | msgstr "" | 3633 | msgstr "" |
3578 | 3634 | ||
3579 | #: src/gns/gnunet-dns2gns.c:637 | 3635 | #: src/gns/gnunet-dns2gns.c:840 |
3580 | msgid "No DNS server specified!\n" | 3636 | msgid "No DNS server specified!\n" |
3581 | msgstr "" | 3637 | msgstr "" |
3582 | 3638 | ||
3583 | #: src/gns/gnunet-dns2gns.c:786 | 3639 | #: src/gns/gnunet-dns2gns.c:995 |
3584 | msgid "IP of recursive DNS resolver to use (required)" | 3640 | msgid "IP of recursive DNS resolver to use (required)" |
3585 | msgstr "" | 3641 | msgstr "" |
3586 | 3642 | ||
3587 | #: src/gns/gnunet-dns2gns.c:792 | 3643 | #: src/gns/gnunet-dns2gns.c:1001 |
3588 | msgid "UDP port to listen on for inbound DNS requests; default: 2853" | 3644 | msgid "UDP port to listen on for inbound DNS requests; default: 2853" |
3589 | msgstr "" | 3645 | msgstr "" |
3590 | 3646 | ||
3591 | #: src/gns/gnunet-dns2gns.c:809 | 3647 | #: src/gns/gnunet-dns2gns.c:1018 |
3592 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" | 3648 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" |
3593 | msgstr "" | 3649 | msgstr "" |
3594 | 3650 | ||
@@ -3766,17 +3822,17 @@ msgstr "" | |||
3766 | msgid "GNUnet GNS resolver tool" | 3822 | msgid "GNUnet GNS resolver tool" |
3767 | msgstr "" | 3823 | msgstr "" |
3768 | 3824 | ||
3769 | #: src/gns/gnunet-service-gns.c:505 | 3825 | #: src/gns/gnunet-service-gns.c:501 |
3770 | msgid "Properly base32-encoded public key required" | 3826 | msgid "Properly base32-encoded public key required" |
3771 | msgstr "" | 3827 | msgstr "" |
3772 | 3828 | ||
3773 | #: src/gns/gnunet-service-gns.c:541 | 3829 | #: src/gns/gnunet-service-gns.c:537 |
3774 | msgid "Failed to connect to the namecache!\n" | 3830 | msgid "Failed to connect to the namecache!\n" |
3775 | msgstr "" | 3831 | msgstr "" |
3776 | 3832 | ||
3777 | #: src/gns/gnunet-service-gns.c:560 | 3833 | #: src/gns/gnunet-service-gns.c:556 |
3778 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:442 | 3834 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:421 |
3779 | #: src/zonemaster/gnunet-service-zonemaster.c:885 | 3835 | #: src/zonemaster/gnunet-service-zonemaster.c:870 |
3780 | msgid "Could not connect to DHT!\n" | 3836 | msgid "Could not connect to DHT!\n" |
3781 | msgstr "" | 3837 | msgstr "" |
3782 | 3838 | ||
@@ -3788,94 +3844,97 @@ msgstr "" | |||
3788 | msgid "Failed to connect to the DNS service!\n" | 3844 | msgid "Failed to connect to the DNS service!\n" |
3789 | msgstr "" | 3845 | msgstr "" |
3790 | 3846 | ||
3791 | #: src/gns/gnunet-service-gns_resolver.c:706 | 3847 | #: src/gns/gnunet-service-gns_resolver.c:659 |
3792 | #, c-format | 3848 | #, c-format |
3793 | msgid "Protocol `%s' unknown, skipping labels.\n" | 3849 | msgid "Protocol `%s' unknown, skipping labels.\n" |
3794 | msgstr "" | 3850 | msgstr "" |
3795 | 3851 | ||
3796 | #: src/gns/gnunet-service-gns_resolver.c:718 | 3852 | #: src/gns/gnunet-service-gns_resolver.c:671 |
3797 | #, c-format | 3853 | #, c-format |
3798 | msgid "Service `%s' unknown for protocol `%s', trying as number.\n" | 3854 | msgid "Service `%s' unknown for protocol `%s', trying as number.\n" |
3799 | msgstr "" | 3855 | msgstr "" |
3800 | 3856 | ||
3801 | #: src/gns/gnunet-service-gns_resolver.c:724 | 3857 | #: src/gns/gnunet-service-gns_resolver.c:677 |
3802 | #, c-format | 3858 | #, c-format |
3803 | msgid "Service `%s' not a port, skipping service labels.\n" | 3859 | msgid "Service `%s' not a port, skipping service labels.\n" |
3804 | msgstr "" | 3860 | msgstr "" |
3805 | 3861 | ||
3806 | #: src/gns/gnunet-service-gns_resolver.c:938 | 3862 | #: src/gns/gnunet-service-gns_resolver.c:891 |
3807 | msgid "Failed to parse DNS response\n" | 3863 | msgid "Failed to parse DNS response\n" |
3808 | msgstr "" | 3864 | msgstr "" |
3809 | 3865 | ||
3810 | #: src/gns/gnunet-service-gns_resolver.c:1129 | 3866 | #: src/gns/gnunet-service-gns_resolver.c:1082 |
3811 | #, c-format | 3867 | #, c-format |
3812 | msgid "Skipping record of unsupported type %d\n" | 3868 | msgid "Skipping record of unsupported type %d\n" |
3813 | msgstr "" | 3869 | msgstr "" |
3814 | 3870 | ||
3815 | #: src/gns/gnunet-service-gns_resolver.c:1447 | 3871 | #: src/gns/gnunet-service-gns_resolver.c:1859 |
3816 | #, c-format | ||
3817 | msgid "VPN returned empty result for `%s'\n" | ||
3818 | msgstr "" | ||
3819 | |||
3820 | #: src/gns/gnunet-service-gns_resolver.c:1919 | ||
3821 | #, c-format | 3872 | #, c-format |
3822 | msgid "Name `%s' cannot be converted to IDNA." | 3873 | msgid "Name `%s' cannot be converted to IDNA." |
3823 | msgstr "" | 3874 | msgstr "" |
3824 | 3875 | ||
3825 | #: src/gns/gnunet-service-gns_resolver.c:1934 | 3876 | #: src/gns/gnunet-service-gns_resolver.c:1874 |
3826 | #, c-format | 3877 | #, c-format |
3827 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" | 3878 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" |
3828 | msgstr "" | 3879 | msgstr "" |
3829 | 3880 | ||
3830 | #: src/gns/gnunet-service-gns_resolver.c:1979 | 3881 | #: src/gns/gnunet-service-gns_resolver.c:1914 |
3831 | #, c-format | 3882 | #, c-format |
3832 | msgid "GNS lookup failed (zero records found for `%s')\n" | 3883 | msgid "GNS lookup failed (zero records found for `%s')\n" |
3833 | msgstr "" | 3884 | msgstr "" |
3834 | 3885 | ||
3835 | #: src/gns/gnunet-service-gns_resolver.c:2406 | 3886 | #: src/gns/gnunet-service-gns_resolver.c:2312 |
3887 | msgid "Unable to process critical delegation record\n" | ||
3888 | msgstr "" | ||
3889 | |||
3890 | #: src/gns/gnunet-service-gns_resolver.c:2317 | ||
3836 | msgid "GNS lookup recursion failed (no delegation record found)\n" | 3891 | msgid "GNS lookup recursion failed (no delegation record found)\n" |
3837 | msgstr "" | 3892 | msgstr "" |
3838 | 3893 | ||
3839 | #: src/gns/gnunet-service-gns_resolver.c:2429 | 3894 | #: src/gns/gnunet-service-gns_resolver.c:2340 |
3840 | #, c-format | 3895 | #, c-format |
3841 | msgid "Failed to cache GNS resolution: %s\n" | 3896 | msgid "Failed to cache GNS resolution: %s\n" |
3842 | msgstr "" | 3897 | msgstr "" |
3843 | 3898 | ||
3844 | #: src/gns/gnunet-service-gns_resolver.c:2594 | 3899 | #: src/gns/gnunet-service-gns_resolver.c:2505 |
3845 | #, c-format | 3900 | #, c-format |
3846 | msgid "GNS namecache returned empty result for `%s'\n" | 3901 | msgid "GNS namecache returned empty result for `%s'\n" |
3847 | msgstr "" | 3902 | msgstr "" |
3848 | 3903 | ||
3849 | #: src/gns/gnunet-service-gns_resolver.c:2734 | 3904 | #: src/gns/gnunet-service-gns_resolver.c:2652 |
3850 | #, c-format | 3905 | #, c-format |
3851 | msgid "Zone %s was revoked, resolution fails\n" | 3906 | msgid "Zone %s was revoked, resolution fails\n" |
3852 | msgstr "" | 3907 | msgstr "" |
3853 | 3908 | ||
3854 | #: src/gns/plugin_gnsrecord_gns.c:174 | 3909 | #: src/gns/plugin_gnsrecord_gns.c:136 |
3910 | msgid "This is a memento of an older block for internal maintenance." | ||
3911 | msgstr "" | ||
3912 | |||
3913 | #: src/gns/plugin_gnsrecord_gns.c:175 | ||
3855 | #, c-format | 3914 | #, c-format |
3856 | msgid "Unable to parse zone key record `%s'\n" | 3915 | msgid "Unable to parse zone key record `%s'\n" |
3857 | msgstr "" | 3916 | msgstr "" |
3858 | 3917 | ||
3859 | #: src/gns/plugin_gnsrecord_gns.c:187 | 3918 | #: src/gns/plugin_gnsrecord_gns.c:188 |
3860 | msgid "Record type does not match parsed record type\n" | 3919 | msgid "Record type does not match parsed record type\n" |
3861 | msgstr "" | 3920 | msgstr "" |
3862 | 3921 | ||
3863 | #: src/gns/plugin_gnsrecord_gns.c:213 | 3922 | #: src/gns/plugin_gnsrecord_gns.c:211 |
3864 | #, c-format | 3923 | #, c-format |
3865 | msgid "Unable to parse GNS2DNS record `%s'\n" | 3924 | msgid "Unable to parse GNS2DNS record `%s'\n" |
3866 | msgstr "" | 3925 | msgstr "" |
3867 | 3926 | ||
3868 | #: src/gns/plugin_gnsrecord_gns.c:229 | 3927 | #: src/gns/plugin_gnsrecord_gns.c:227 |
3869 | #, c-format | 3928 | #, c-format |
3870 | msgid "Failed to serialize GNS2DNS record with value `%s': Not a DNS name.\n" | 3929 | msgid "Failed to serialize GNS2DNS record with value `%s': Not a DNS name.\n" |
3871 | msgstr "" | 3930 | msgstr "" |
3872 | 3931 | ||
3873 | #: src/gns/plugin_gnsrecord_gns.c:253 | 3932 | #: src/gns/plugin_gnsrecord_gns.c:251 |
3874 | #, c-format | 3933 | #, c-format |
3875 | msgid "Unable to parse VPN record string `%s'\n" | 3934 | msgid "Unable to parse VPN record string `%s'\n" |
3876 | msgstr "" | 3935 | msgstr "" |
3877 | 3936 | ||
3878 | #: src/gns/plugin_gnsrecord_gns.c:285 | 3937 | #: src/gns/plugin_gnsrecord_gns.c:283 |
3879 | #, c-format | 3938 | #, c-format |
3880 | msgid "Unable to parse BOX record string `%s'\n" | 3939 | msgid "Unable to parse BOX record string `%s'\n" |
3881 | msgstr "" | 3940 | msgstr "" |
@@ -3884,6 +3943,34 @@ msgstr "" | |||
3884 | msgid "Gns REST API initialized\n" | 3943 | msgid "Gns REST API initialized\n" |
3885 | msgstr "" | 3944 | msgstr "" |
3886 | 3945 | ||
3946 | #: src/gnsrecord/gnsrecord_misc.c:448 | ||
3947 | msgid "Zone delegation record not allowed in apex." | ||
3948 | msgstr "" | ||
3949 | |||
3950 | #: src/gnsrecord/gnsrecord_misc.c:456 | ||
3951 | msgid "Zone delegation record set contains mutually exclusive records." | ||
3952 | msgstr "" | ||
3953 | |||
3954 | #: src/gnsrecord/gnsrecord_misc.c:466 | ||
3955 | msgid "Multiple REDIRECT records." | ||
3956 | msgstr "" | ||
3957 | |||
3958 | #: src/gnsrecord/gnsrecord_misc.c:475 src/gnsrecord/gnsrecord_misc.c:501 | ||
3959 | msgid "Redirection record set conains mutually exclusive records." | ||
3960 | msgstr "" | ||
3961 | |||
3962 | #: src/gnsrecord/gnsrecord_misc.c:482 | ||
3963 | msgid "Redirection records not allowed in apex." | ||
3964 | msgstr "" | ||
3965 | |||
3966 | #: src/gnsrecord/gnsrecord_misc.c:493 | ||
3967 | msgid "Redirection records not allowed in apex.." | ||
3968 | msgstr "" | ||
3969 | |||
3970 | #: src/gnsrecord/gnsrecord_misc.c:515 | ||
3971 | msgid "Mutually exclusive records." | ||
3972 | msgstr "" | ||
3973 | |||
3887 | #: src/gnsrecord/plugin_gnsrecord_dns.c:367 | 3974 | #: src/gnsrecord/plugin_gnsrecord_dns.c:367 |
3888 | #, c-format | 3975 | #, c-format |
3889 | msgid "Unable to parse IPv4 address `%s'\n" | 3976 | msgid "Unable to parse IPv4 address `%s'\n" |
@@ -4124,7 +4211,7 @@ msgid "# hostlist downloads initiated" | |||
4124 | msgstr "" | 4211 | msgstr "" |
4125 | 4212 | ||
4126 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1144 | 4213 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1144 |
4127 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1728 | 4214 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1732 |
4128 | msgid "# milliseconds between hostlist downloads" | 4215 | msgid "# milliseconds between hostlist downloads" |
4129 | msgstr "" | 4216 | msgstr "" |
4130 | 4217 | ||
@@ -4182,21 +4269,21 @@ msgstr "" | |||
4182 | msgid "# hostlist URIs written to file" | 4269 | msgid "# hostlist URIs written to file" |
4183 | msgstr "" | 4270 | msgstr "" |
4184 | 4271 | ||
4185 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1657 | 4272 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1661 |
4186 | #: src/transport/plugin_transport_http_client.c:2300 | 4273 | #: src/transport/plugin_transport_http_client.c:2300 |
4187 | #, c-format | 4274 | #, c-format |
4188 | msgid "Invalid proxy type: `%s', disabling proxy! Check configuration!\n" | 4275 | msgid "Invalid proxy type: `%s', disabling proxy! Check configuration!\n" |
4189 | msgstr "" | 4276 | msgstr "" |
4190 | 4277 | ||
4191 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1686 | 4278 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1690 |
4192 | msgid "Learning is enabled on this peer\n" | 4279 | msgid "Learning is enabled on this peer\n" |
4193 | msgstr "" | 4280 | msgstr "" |
4194 | 4281 | ||
4195 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1699 | 4282 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1703 |
4196 | msgid "Learning is not enabled on this peer\n" | 4283 | msgid "Learning is not enabled on this peer\n" |
4197 | msgstr "" | 4284 | msgstr "" |
4198 | 4285 | ||
4199 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1713 | 4286 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1717 |
4200 | #, c-format | 4287 | #, c-format |
4201 | msgid "" | 4288 | msgid "" |
4202 | "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" | 4289 | "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" |
@@ -4384,49 +4471,49 @@ msgstr "" | |||
4384 | msgid "Maintain egos" | 4471 | msgid "Maintain egos" |
4385 | msgstr "" | 4472 | msgstr "" |
4386 | 4473 | ||
4387 | #: src/identity/gnunet-service-identity.c:503 | 4474 | #: src/identity/gnunet-service-identity.c:502 |
4388 | msgid "no default known" | 4475 | msgid "no default known" |
4389 | msgstr "" | 4476 | msgstr "" |
4390 | 4477 | ||
4391 | #: src/identity/gnunet-service-identity.c:528 | 4478 | #: src/identity/gnunet-service-identity.c:527 |
4392 | msgid "default configured, but ego unknown (internal error)" | 4479 | msgid "default configured, but ego unknown (internal error)" |
4393 | msgstr "" | 4480 | msgstr "" |
4394 | 4481 | ||
4395 | #: src/identity/gnunet-service-identity.c:621 | 4482 | #: src/identity/gnunet-service-identity.c:620 |
4396 | #: src/identity/gnunet-service-identity.c:896 | 4483 | #: src/identity/gnunet-service-identity.c:895 |
4397 | #: src/identity/gnunet-service-identity.c:1016 | 4484 | #: src/identity/gnunet-service-identity.c:1015 |
4398 | #, c-format | 4485 | #, c-format |
4399 | msgid "Failed to write subsystem default identifier map to `%s'.\n" | 4486 | msgid "Failed to write subsystem default identifier map to `%s'.\n" |
4400 | msgstr "" | 4487 | msgstr "" |
4401 | 4488 | ||
4402 | #: src/identity/gnunet-service-identity.c:631 | 4489 | #: src/identity/gnunet-service-identity.c:630 |
4403 | msgid "Unknown ego specified for service (internal error)" | 4490 | msgid "Unknown ego specified for service (internal error)" |
4404 | msgstr "" | 4491 | msgstr "" |
4405 | 4492 | ||
4406 | #: src/identity/gnunet-service-identity.c:725 | 4493 | #: src/identity/gnunet-service-identity.c:724 |
4407 | msgid "identifier already in use for another ego" | 4494 | msgid "identifier already in use for another ego" |
4408 | msgstr "" | 4495 | msgstr "" |
4409 | 4496 | ||
4410 | #: src/identity/gnunet-service-identity.c:872 | 4497 | #: src/identity/gnunet-service-identity.c:871 |
4411 | msgid "target name already exists" | 4498 | msgid "target name already exists" |
4412 | msgstr "" | 4499 | msgstr "" |
4413 | 4500 | ||
4414 | #: src/identity/gnunet-service-identity.c:914 | 4501 | #: src/identity/gnunet-service-identity.c:913 |
4415 | #: src/identity/gnunet-service-identity.c:1033 | 4502 | #: src/identity/gnunet-service-identity.c:1032 |
4416 | msgid "no matching ego found" | 4503 | msgid "no matching ego found" |
4417 | msgstr "" | 4504 | msgstr "" |
4418 | 4505 | ||
4419 | #: src/identity/gnunet-service-identity.c:1131 | 4506 | #: src/identity/gnunet-service-identity.c:1130 |
4420 | #, c-format | 4507 | #, c-format |
4421 | msgid "Failed to parse ego information in `%s'\n" | 4508 | msgid "Failed to parse ego information in `%s'\n" |
4422 | msgstr "" | 4509 | msgstr "" |
4423 | 4510 | ||
4424 | #: src/identity/gnunet-service-identity.c:1189 | 4511 | #: src/identity/gnunet-service-identity.c:1188 |
4425 | #, c-format | 4512 | #, c-format |
4426 | msgid "Failed to parse subsystem identity configuration file `%s'\n" | 4513 | msgid "Failed to parse subsystem identity configuration file `%s'\n" |
4427 | msgstr "" | 4514 | msgstr "" |
4428 | 4515 | ||
4429 | #: src/identity/gnunet-service-identity.c:1198 | 4516 | #: src/identity/gnunet-service-identity.c:1197 |
4430 | #, c-format | 4517 | #, c-format |
4431 | msgid "Failed to create directory `%s' for storing egos\n" | 4518 | msgid "Failed to create directory `%s' for storing egos\n" |
4432 | msgstr "" | 4519 | msgstr "" |
@@ -4466,7 +4553,7 @@ msgstr "" | |||
4466 | msgid "No records found for `%s'" | 4553 | msgid "No records found for `%s'" |
4467 | msgstr "" | 4554 | msgstr "" |
4468 | 4555 | ||
4469 | #: src/namecache/gnunet-namecache.c:119 src/namestore/gnunet-namestore.c:459 | 4556 | #: src/namecache/gnunet-namecache.c:119 src/namestore/gnunet-namestore.c:469 |
4470 | #, c-format | 4557 | #, c-format |
4471 | msgid "\tCorrupt or unsupported record of type %u\n" | 4558 | msgid "\tCorrupt or unsupported record of type %u\n" |
4472 | msgstr "" | 4559 | msgstr "" |
@@ -4486,7 +4573,7 @@ msgstr "fornat invalide : « %s »\n" | |||
4486 | msgid "You must specify a name\n" | 4573 | msgid "You must specify a name\n" |
4487 | msgstr "" | 4574 | msgstr "" |
4488 | 4575 | ||
4489 | #: src/namecache/gnunet-namecache.c:214 src/namestore/gnunet-namestore.c:1641 | 4576 | #: src/namecache/gnunet-namecache.c:214 src/namestore/gnunet-namestore.c:1591 |
4490 | msgid "name of the record to add/delete/display" | 4577 | msgid "name of the record to add/delete/display" |
4491 | msgstr "" | 4578 | msgstr "" |
4492 | 4579 | ||
@@ -4494,7 +4581,7 @@ msgstr "" | |||
4494 | msgid "specifies the public key of the zone to look in" | 4581 | msgid "specifies the public key of the zone to look in" |
4495 | msgstr "" | 4582 | msgstr "" |
4496 | 4583 | ||
4497 | #: src/namecache/gnunet-namecache.c:233 src/namestore/gnunet-namestore.c:1702 | 4584 | #: src/namecache/gnunet-namecache.c:233 src/namestore/gnunet-namestore.c:1652 |
4498 | msgid "GNUnet zone manipulation tool" | 4585 | msgid "GNUnet zone manipulation tool" |
4499 | msgstr "" | 4586 | msgstr "" |
4500 | 4587 | ||
@@ -4635,140 +4722,113 @@ msgstr "" | |||
4635 | msgid "GNU Name System First-Come-First-Served name registration service" | 4722 | msgid "GNU Name System First-Come-First-Served name registration service" |
4636 | msgstr "" | 4723 | msgstr "" |
4637 | 4724 | ||
4638 | #: src/namestore/gnunet-namestore.c:334 | 4725 | #: src/namestore/gnunet-namestore.c:340 |
4639 | #, c-format | 4726 | #, c-format |
4640 | msgid "Adding record failed: %s\n" | 4727 | msgid "Adding record failed: %s\n" |
4641 | msgstr "" | 4728 | msgstr "" |
4642 | 4729 | ||
4643 | #: src/namestore/gnunet-namestore.c:362 | 4730 | #: src/namestore/gnunet-namestore.c:368 |
4644 | #, c-format | 4731 | #, c-format |
4645 | msgid "Deleting record failed, record does not exist%s%s\n" | 4732 | msgid "Deleting record failed, record does not exist%s%s\n" |
4646 | msgstr "" | 4733 | msgstr "" |
4647 | 4734 | ||
4648 | #: src/namestore/gnunet-namestore.c:369 | 4735 | #: src/namestore/gnunet-namestore.c:375 |
4649 | #, c-format | 4736 | #, c-format |
4650 | msgid "Deleting record failed%s%s\n" | 4737 | msgid "Deleting record failed%s%s\n" |
4651 | msgstr "" | 4738 | msgstr "" |
4652 | 4739 | ||
4653 | #: src/namestore/gnunet-namestore.c:656 | ||
4654 | #, c-format | ||
4655 | msgid "A %s record exists already under `%s', no other records can be added.\n" | ||
4656 | msgstr "" | ||
4657 | |||
4658 | #: src/namestore/gnunet-namestore.c:668 | 4740 | #: src/namestore/gnunet-namestore.c:668 |
4659 | #, c-format | 4741 | #, c-format |
4660 | msgid "" | 4742 | msgid "" |
4661 | "A zone key record exists already under `%s', no other records can be added.\n" | ||
4662 | msgstr "" | ||
4663 | |||
4664 | #: src/namestore/gnunet-namestore.c:680 | ||
4665 | #, c-format | ||
4666 | msgid "" | ||
4667 | "A SOA record exists already under `%s', cannot add a second SOA to the same " | 4743 | "A SOA record exists already under `%s', cannot add a second SOA to the same " |
4668 | "zone.\n" | 4744 | "zone.\n" |
4669 | msgstr "" | 4745 | msgstr "" |
4670 | 4746 | ||
4671 | #: src/namestore/gnunet-namestore.c:696 | 4747 | #: src/namestore/gnunet-namestore.c:789 |
4672 | #, c-format | ||
4673 | msgid "Records already exist under `%s', cannot add `%s' record.\n" | ||
4674 | msgstr "" | ||
4675 | |||
4676 | #: src/namestore/gnunet-namestore.c:711 | ||
4677 | #, c-format | ||
4678 | msgid "Records already exist under `%s', cannot add record.\n" | ||
4679 | msgstr "" | ||
4680 | |||
4681 | #: src/namestore/gnunet-namestore.c:726 | ||
4682 | #, c-format | ||
4683 | msgid "" | ||
4684 | "Non-GNS2DNS records already exist under `%s', cannot add GNS2DNS record.\n" | ||
4685 | msgstr "" | ||
4686 | |||
4687 | #: src/namestore/gnunet-namestore.c:846 | ||
4688 | #, c-format | 4748 | #, c-format |
4689 | msgid "There are no records under label `%s' that could be deleted.\n" | 4749 | msgid "There are no records under label `%s' that could be deleted.\n" |
4690 | msgstr "" | 4750 | msgstr "" |
4691 | 4751 | ||
4692 | #: src/namestore/gnunet-namestore.c:889 | 4752 | #: src/namestore/gnunet-namestore.c:832 |
4693 | #, c-format | 4753 | #, c-format |
4694 | msgid "" | 4754 | msgid "" |
4695 | "There are no records under label `%s' that match the request for deletion.\n" | 4755 | "There are no records under label `%s' that match the request for deletion.\n" |
4696 | msgstr "" | 4756 | msgstr "" |
4697 | 4757 | ||
4698 | #: src/namestore/gnunet-namestore.c:970 | 4758 | #: src/namestore/gnunet-namestore.c:920 |
4699 | #, fuzzy, c-format | 4759 | #, fuzzy, c-format |
4700 | msgid "Failed to replace records: %s\n" | 4760 | msgid "Failed to replace records: %s\n" |
4701 | msgstr "Résolution de « %s » échouée : %s\n" | 4761 | msgstr "Résolution de « %s » échouée : %s\n" |
4702 | 4762 | ||
4703 | #: src/namestore/gnunet-namestore.c:993 | 4763 | #: src/namestore/gnunet-namestore.c:943 |
4704 | #, c-format | 4764 | #, c-format |
4705 | msgid "No options given\n" | 4765 | msgid "No options given\n" |
4706 | msgstr "" | 4766 | msgstr "" |
4707 | 4767 | ||
4708 | #: src/namestore/gnunet-namestore.c:1014 src/namestore/gnunet-namestore.c:1066 | 4768 | #: src/namestore/gnunet-namestore.c:964 src/namestore/gnunet-namestore.c:1016 |
4709 | #: src/namestore/gnunet-namestore.c:1076 src/namestore/gnunet-namestore.c:1105 | 4769 | #: src/namestore/gnunet-namestore.c:1026 src/namestore/gnunet-namestore.c:1055 |
4710 | #: src/namestore/gnunet-namestore.c:1126 src/namestore/gnunet-namestore.c:1153 | 4770 | #: src/namestore/gnunet-namestore.c:1076 src/namestore/gnunet-namestore.c:1103 |
4711 | #: src/namestore/gnunet-namestore.c:1230 | 4771 | #: src/namestore/gnunet-namestore.c:1180 |
4712 | #, c-format | 4772 | #, c-format |
4713 | msgid "Missing option `%s' for operation `%s'\n" | 4773 | msgid "Missing option `%s' for operation `%s'\n" |
4714 | msgstr "" | 4774 | msgstr "" |
4715 | 4775 | ||
4716 | #: src/namestore/gnunet-namestore.c:1016 | 4776 | #: src/namestore/gnunet-namestore.c:966 |
4717 | msgid "replace" | 4777 | msgid "replace" |
4718 | msgstr "" | 4778 | msgstr "" |
4719 | 4779 | ||
4720 | #: src/namestore/gnunet-namestore.c:1045 | 4780 | #: src/namestore/gnunet-namestore.c:995 |
4721 | #, c-format | 4781 | #, c-format |
4722 | msgid "Invalid nick `%s'\n" | 4782 | msgid "Invalid nick `%s'\n" |
4723 | msgstr "" | 4783 | msgstr "" |
4724 | 4784 | ||
4725 | #: src/namestore/gnunet-namestore.c:1068 src/namestore/gnunet-namestore.c:1078 | 4785 | #: src/namestore/gnunet-namestore.c:1018 src/namestore/gnunet-namestore.c:1028 |
4726 | #: src/namestore/gnunet-namestore.c:1107 src/namestore/gnunet-namestore.c:1128 | 4786 | #: src/namestore/gnunet-namestore.c:1057 src/namestore/gnunet-namestore.c:1078 |
4727 | #: src/namestore/gnunet-namestore.c:1232 | 4787 | #: src/namestore/gnunet-namestore.c:1182 |
4728 | msgid "add" | 4788 | msgid "add" |
4729 | msgstr "ajouter" | 4789 | msgstr "ajouter" |
4730 | 4790 | ||
4731 | #: src/namestore/gnunet-namestore.c:1086 | 4791 | #: src/namestore/gnunet-namestore.c:1036 |
4732 | #, c-format | 4792 | #, c-format |
4733 | msgid "Unsupported type `%s'\n" | 4793 | msgid "Unsupported type `%s'\n" |
4734 | msgstr "" | 4794 | msgstr "" |
4735 | 4795 | ||
4736 | #: src/namestore/gnunet-namestore.c:1096 | 4796 | #: src/namestore/gnunet-namestore.c:1046 |
4737 | #, c-format | 4797 | #, c-format |
4738 | msgid "For DNS record types `SRV', `TLSA' and `OPENPGPKEY'" | 4798 | msgid "For DNS record types `SRV', `TLSA' and `OPENPGPKEY'" |
4739 | msgstr "" | 4799 | msgstr "" |
4740 | 4800 | ||
4741 | #: src/namestore/gnunet-namestore.c:1116 | 4801 | #: src/namestore/gnunet-namestore.c:1066 |
4742 | #, c-format | 4802 | #, c-format |
4743 | msgid "Value `%s' invalid for record type `%s'\n" | 4803 | msgid "Value `%s' invalid for record type `%s'\n" |
4744 | msgstr "" | 4804 | msgstr "" |
4745 | 4805 | ||
4746 | #: src/namestore/gnunet-namestore.c:1135 src/namestore/gnunet-namestore.c:1239 | 4806 | #: src/namestore/gnunet-namestore.c:1085 src/namestore/gnunet-namestore.c:1189 |
4747 | #, c-format | 4807 | #, c-format |
4748 | msgid "Invalid time format `%s'\n" | 4808 | msgid "Invalid time format `%s'\n" |
4749 | msgstr "" | 4809 | msgstr "" |
4750 | 4810 | ||
4751 | #: src/namestore/gnunet-namestore.c:1155 | 4811 | #: src/namestore/gnunet-namestore.c:1105 |
4752 | msgid "del" | 4812 | msgid "del" |
4753 | msgstr "supprimer" | 4813 | msgstr "supprimer" |
4754 | 4814 | ||
4755 | #: src/namestore/gnunet-namestore.c:1197 | 4815 | #: src/namestore/gnunet-namestore.c:1147 |
4756 | #, c-format | 4816 | #, c-format |
4757 | msgid "Invalid public key for reverse lookup `%s'\n" | 4817 | msgid "Invalid public key for reverse lookup `%s'\n" |
4758 | msgstr "" | 4818 | msgstr "" |
4759 | 4819 | ||
4760 | #: src/namestore/gnunet-namestore.c:1222 | 4820 | #: src/namestore/gnunet-namestore.c:1172 |
4761 | #: src/peerinfo-tool/gnunet-peerinfo.c:737 | 4821 | #: src/peerinfo-tool/gnunet-peerinfo.c:737 |
4762 | #, c-format | 4822 | #, c-format |
4763 | msgid "Invalid URI `%s'\n" | 4823 | msgid "Invalid URI `%s'\n" |
4764 | msgstr "URI invalide « %s »\n" | 4824 | msgstr "URI invalide « %s »\n" |
4765 | 4825 | ||
4766 | #: src/namestore/gnunet-namestore.c:1292 | 4826 | #: src/namestore/gnunet-namestore.c:1242 |
4767 | #, c-format | 4827 | #, c-format |
4768 | msgid "Label `%s' contains `.' which is not allowed\n" | 4828 | msgid "Label `%s' contains `.' which is not allowed\n" |
4769 | msgstr "" | 4829 | msgstr "" |
4770 | 4830 | ||
4771 | #: src/namestore/gnunet-namestore.c:1342 | 4831 | #: src/namestore/gnunet-namestore.c:1292 |
4772 | #, c-format | 4832 | #, c-format |
4773 | msgid "" | 4833 | msgid "" |
4774 | "No default identity configured for `namestore' subsystem\n" | 4834 | "No default identity configured for `namestore' subsystem\n" |
@@ -4776,107 +4836,112 @@ msgid "" | |||
4776 | "Run gnunet-identity -d to get a list of choices for $NAME\n" | 4836 | "Run gnunet-identity -d to get a list of choices for $NAME\n" |
4777 | msgstr "" | 4837 | msgstr "" |
4778 | 4838 | ||
4779 | #: src/namestore/gnunet-namestore.c:1407 | 4839 | #: src/namestore/gnunet-namestore.c:1357 |
4780 | #, c-format | 4840 | #, c-format |
4781 | msgid "Superfluous command line arguments (starting with `%s') ignored\n" | 4841 | msgid "Superfluous command line arguments (starting with `%s') ignored\n" |
4782 | msgstr "" | 4842 | msgstr "" |
4783 | 4843 | ||
4784 | #: src/namestore/gnunet-namestore.c:1436 | 4844 | #: src/namestore/gnunet-namestore.c:1386 |
4785 | #, c-format | 4845 | #, c-format |
4786 | msgid "Cannot connect to identity service\n" | 4846 | msgid "Cannot connect to identity service\n" |
4787 | msgstr "" | 4847 | msgstr "" |
4788 | 4848 | ||
4789 | #: src/namestore/gnunet-namestore.c:1483 | 4849 | #: src/namestore/gnunet-namestore.c:1433 |
4790 | msgid "Empty record line argument is not allowed.\n" | 4850 | msgid "Empty record line argument is not allowed.\n" |
4791 | msgstr "" | 4851 | msgstr "" |
4792 | 4852 | ||
4793 | #: src/namestore/gnunet-namestore.c:1495 | 4853 | #: src/namestore/gnunet-namestore.c:1445 |
4794 | #, c-format | 4854 | #, c-format |
4795 | msgid "Invalid expiration time `%s' (must be without unit)\n" | 4855 | msgid "Invalid expiration time `%s' (must be without unit)\n" |
4796 | msgstr "" | 4856 | msgstr "" |
4797 | 4857 | ||
4798 | #: src/namestore/gnunet-namestore.c:1507 src/namestore/gnunet-namestore.c:1523 | 4858 | #: src/namestore/gnunet-namestore.c:1457 src/namestore/gnunet-namestore.c:1473 |
4799 | #: src/namestore/gnunet-namestore.c:1540 | 4859 | #: src/namestore/gnunet-namestore.c:1490 |
4800 | #, c-format | 4860 | #, c-format |
4801 | msgid "Missing entries in record line `%s'.\n" | 4861 | msgid "Missing entries in record line `%s'.\n" |
4802 | msgstr "" | 4862 | msgstr "" |
4803 | 4863 | ||
4804 | #: src/namestore/gnunet-namestore.c:1515 | 4864 | #: src/namestore/gnunet-namestore.c:1465 |
4805 | #, fuzzy, c-format | 4865 | #, fuzzy, c-format |
4806 | msgid "Unknown record type `%s'\n" | 4866 | msgid "Unknown record type `%s'\n" |
4807 | msgstr "Commande « %s » inconnue\n" | 4867 | msgstr "Commande « %s » inconnue\n" |
4808 | 4868 | ||
4809 | #: src/namestore/gnunet-namestore.c:1553 | 4869 | #: src/namestore/gnunet-namestore.c:1503 |
4810 | #, fuzzy, c-format | 4870 | #, fuzzy, c-format |
4811 | msgid "Invalid record data for type %s: `%s'.\n" | 4871 | msgid "Invalid record data for type %s: `%s'.\n" |
4812 | msgstr "fornat invalide : « %s »\n" | 4872 | msgstr "fornat invalide : « %s »\n" |
4813 | 4873 | ||
4814 | #: src/namestore/gnunet-namestore.c:1610 | 4874 | #: src/namestore/gnunet-namestore.c:1560 |
4815 | msgid "add record" | 4875 | msgid "add record" |
4816 | msgstr "ajouter un enregistrement" | 4876 | msgstr "ajouter un enregistrement" |
4817 | 4877 | ||
4818 | #: src/namestore/gnunet-namestore.c:1613 | 4878 | #: src/namestore/gnunet-namestore.c:1563 |
4819 | msgid "delete record" | 4879 | msgid "delete record" |
4820 | msgstr "suprimer un enregistrement" | 4880 | msgstr "suprimer un enregistrement" |
4821 | 4881 | ||
4822 | #: src/namestore/gnunet-namestore.c:1617 | 4882 | #: src/namestore/gnunet-namestore.c:1567 |
4823 | msgid "display records" | 4883 | msgid "display records" |
4824 | msgstr "afficher les enregistrements" | 4884 | msgstr "afficher les enregistrements" |
4825 | 4885 | ||
4826 | #: src/namestore/gnunet-namestore.c:1624 | 4886 | #: src/namestore/gnunet-namestore.c:1574 |
4827 | msgid "" | 4887 | msgid "" |
4828 | "expiration time for record to use (for adding only), \"never\" is possible" | 4888 | "expiration time for record to use (for adding only), \"never\" is possible" |
4829 | msgstr "" | 4889 | msgstr "" |
4830 | 4890 | ||
4831 | #: src/namestore/gnunet-namestore.c:1630 | 4891 | #: src/namestore/gnunet-namestore.c:1580 |
4832 | msgid "set the desired nick name for the zone" | 4892 | msgid "set the desired nick name for the zone" |
4833 | msgstr "" | 4893 | msgstr "" |
4834 | 4894 | ||
4835 | #: src/namestore/gnunet-namestore.c:1635 | 4895 | #: src/namestore/gnunet-namestore.c:1585 |
4836 | msgid "monitor changes in the namestore" | 4896 | msgid "monitor changes in the namestore" |
4837 | msgstr "" | 4897 | msgstr "" |
4838 | 4898 | ||
4839 | #: src/namestore/gnunet-namestore.c:1647 | 4899 | #: src/namestore/gnunet-namestore.c:1597 |
4840 | msgid "determine our name for the given PKEY" | 4900 | msgid "determine our name for the given PKEY" |
4841 | msgstr "" | 4901 | msgstr "" |
4842 | 4902 | ||
4843 | #: src/namestore/gnunet-namestore.c:1654 | 4903 | #: src/namestore/gnunet-namestore.c:1604 |
4844 | msgid "" | 4904 | msgid "" |
4845 | "set record set to values given by (possibly multiple) RECORDLINES; can be " | 4905 | "set record set to values given by (possibly multiple) RECORDLINES; can be " |
4846 | "specified multiple times" | 4906 | "specified multiple times" |
4847 | msgstr "" | 4907 | msgstr "" |
4848 | 4908 | ||
4849 | #: src/namestore/gnunet-namestore.c:1660 | 4909 | #: src/namestore/gnunet-namestore.c:1610 |
4850 | msgid "type of the record to add/delete/display" | 4910 | msgid "type of the record to add/delete/display" |
4851 | msgstr "" | 4911 | msgstr "" |
4852 | 4912 | ||
4853 | #: src/namestore/gnunet-namestore.c:1665 | 4913 | #: src/namestore/gnunet-namestore.c:1615 |
4854 | msgid "URI to import into our zone" | 4914 | msgid "URI to import into our zone" |
4855 | msgstr "" | 4915 | msgstr "" |
4856 | 4916 | ||
4857 | #: src/namestore/gnunet-namestore.c:1671 | 4917 | #: src/namestore/gnunet-namestore.c:1621 |
4858 | msgid "value of the record to add/delete" | 4918 | msgid "value of the record to add/delete" |
4859 | msgstr "" | 4919 | msgstr "" |
4860 | 4920 | ||
4861 | #: src/namestore/gnunet-namestore.c:1675 | 4921 | #: src/namestore/gnunet-namestore.c:1625 |
4862 | msgid "create or list public record" | 4922 | msgid "create or list public record" |
4863 | msgstr "" | 4923 | msgstr "" |
4864 | 4924 | ||
4865 | #: src/namestore/gnunet-namestore.c:1681 | 4925 | #: src/namestore/gnunet-namestore.c:1631 |
4866 | msgid "" | 4926 | msgid "" |
4867 | "create shadow record (only valid if all other records of the same type have " | 4927 | "create shadow record (only valid if all other records of the same type have " |
4868 | "expired" | 4928 | "expired" |
4869 | msgstr "" | 4929 | msgstr "" |
4870 | 4930 | ||
4871 | #: src/namestore/gnunet-namestore.c:1687 | 4931 | #: src/namestore/gnunet-namestore.c:1637 |
4872 | msgid "name of the ego controlling the zone" | 4932 | msgid "name of the ego controlling the zone" |
4873 | msgstr "" | 4933 | msgstr "" |
4874 | 4934 | ||
4875 | #: src/namestore/gnunet-service-namestore.c:871 | 4935 | #: src/namestore/gnunet-service-namestore.c:879 |
4876 | #, c-format | 4936 | #, c-format |
4877 | msgid "Failed to replicate block in namecache: %s\n" | 4937 | msgid "Failed to replicate block in namecache: %s\n" |
4878 | msgstr "" | 4938 | msgstr "" |
4879 | 4939 | ||
4940 | #: src/namestore/gnunet-service-namestore.c:1668 | ||
4941 | #, fuzzy | ||
4942 | msgid "Store failed" | ||
4943 | msgstr "pa_stream_new() échoué : %s\n" | ||
4944 | |||
4880 | #: src/namestore/gnunet-zoneimport.c:1847 | 4945 | #: src/namestore/gnunet-zoneimport.c:1847 |
4881 | msgid "size to use for the main hash map" | 4946 | msgid "size to use for the main hash map" |
4882 | msgstr "" | 4947 | msgstr "" |
@@ -4885,10 +4950,6 @@ msgstr "" | |||
4885 | msgid "minimum expiration time we assume for imported records" | 4950 | msgid "minimum expiration time we assume for imported records" |
4886 | msgstr "" | 4951 | msgstr "" |
4887 | 4952 | ||
4888 | #: src/namestore/namestore_api.c:373 | ||
4889 | msgid "Namestore failed to store record\n" | ||
4890 | msgstr "" | ||
4891 | |||
4892 | #: src/namestore/plugin_namestore_flat.c:195 | 4953 | #: src/namestore/plugin_namestore_flat.c:195 |
4893 | #, c-format | 4954 | #, c-format |
4894 | msgid "File too big to map: %llu bytes.\n" | 4955 | msgid "File too big to map: %llu bytes.\n" |
@@ -5453,6 +5514,51 @@ msgstr "" | |||
5453 | msgid "Daemon to run to perform IP protocol translation to GNUnet" | 5514 | msgid "Daemon to run to perform IP protocol translation to GNUnet" |
5454 | msgstr "" | 5515 | msgstr "" |
5455 | 5516 | ||
5517 | #: src/reclaim/gnunet-did.c:209 | ||
5518 | #, fuzzy, c-format | ||
5519 | msgid "Invalid DID `%s'\n" | ||
5520 | msgstr "URI invalide « %s »\n" | ||
5521 | |||
5522 | #: src/reclaim/gnunet-did.c:835 | ||
5523 | msgid "Create a DID Document and display its DID" | ||
5524 | msgstr "" | ||
5525 | |||
5526 | #: src/reclaim/gnunet-did.c:840 | ||
5527 | msgid "Get the DID Document associated with the given DID" | ||
5528 | msgstr "" | ||
5529 | |||
5530 | #: src/reclaim/gnunet-did.c:844 | ||
5531 | msgid "Show the DID for a given ego" | ||
5532 | msgstr "" | ||
5533 | |||
5534 | #: src/reclaim/gnunet-did.c:849 | ||
5535 | msgid "Remove the DID" | ||
5536 | msgstr "" | ||
5537 | |||
5538 | #: src/reclaim/gnunet-did.c:853 src/reclaim/gnunet-did.c:857 | ||
5539 | msgid "Replace the DID Document." | ||
5540 | msgstr "" | ||
5541 | |||
5542 | #: src/reclaim/gnunet-did.c:863 | ||
5543 | msgid "The Decentralized Identity (DID)" | ||
5544 | msgstr "" | ||
5545 | |||
5546 | #: src/reclaim/gnunet-did.c:869 | ||
5547 | msgid "The DID Document to store in GNUNET" | ||
5548 | msgstr "" | ||
5549 | |||
5550 | #: src/reclaim/gnunet-did.c:874 | ||
5551 | msgid "The name of the EGO" | ||
5552 | msgstr "" | ||
5553 | |||
5554 | #: src/reclaim/gnunet-did.c:880 | ||
5555 | msgid "The time until the DID Document is going to expire (e.g. 5d)" | ||
5556 | msgstr "" | ||
5557 | |||
5558 | #: src/reclaim/gnunet-did.c:889 | ||
5559 | msgid "Manage Decentralized Identities (DIDs)" | ||
5560 | msgstr "" | ||
5561 | |||
5456 | #: src/reclaim/gnunet-reclaim.c:802 | 5562 | #: src/reclaim/gnunet-reclaim.c:802 |
5457 | #, c-format | 5563 | #, c-format |
5458 | msgid "Ego is required\n" | 5564 | msgid "Ego is required\n" |
@@ -6317,17 +6423,17 @@ msgid "" | |||
6317 | "free topology cannot be more than %u. Given `%s = %llu'" | 6423 | "free topology cannot be more than %u. Given `%s = %llu'" |
6318 | msgstr "" | 6424 | msgstr "" |
6319 | 6425 | ||
6320 | #: src/testbed/testbed_api_topology.c:1033 src/testing/testing.c:2643 | 6426 | #: src/testbed/testbed_api_topology.c:1033 src/testing/testing.c:2657 |
6321 | #, c-format | 6427 | #, c-format |
6322 | msgid "Topology file %s not found\n" | 6428 | msgid "Topology file %s not found\n" |
6323 | msgstr "" | 6429 | msgstr "" |
6324 | 6430 | ||
6325 | #: src/testbed/testbed_api_topology.c:1041 src/testing/testing.c:2651 | 6431 | #: src/testbed/testbed_api_topology.c:1041 src/testing/testing.c:2665 |
6326 | #, c-format | 6432 | #, c-format |
6327 | msgid "Topology file %s has no data\n" | 6433 | msgid "Topology file %s has no data\n" |
6328 | msgstr "" | 6434 | msgstr "" |
6329 | 6435 | ||
6330 | #: src/testbed/testbed_api_topology.c:1049 src/testing/testing.c:2659 | 6436 | #: src/testbed/testbed_api_topology.c:1049 src/testing/testing.c:2673 |
6331 | #, c-format | 6437 | #, c-format |
6332 | msgid "Topology file %s cannot be read\n" | 6438 | msgid "Topology file %s cannot be read\n" |
6333 | msgstr "" | 6439 | msgstr "" |
@@ -6525,7 +6631,7 @@ msgstr "" | |||
6525 | 6631 | ||
6526 | #: src/transport/gnunet-communicator-tcp.c:3338 | 6632 | #: src/transport/gnunet-communicator-tcp.c:3338 |
6527 | #: src/transport/gnunet-communicator-udp.c:3856 | 6633 | #: src/transport/gnunet-communicator-udp.c:3856 |
6528 | #: src/transport/gnunet-service-tng.c:10512 | 6634 | #: src/transport/gnunet-service-tng.c:10623 |
6529 | #: src/transport/gnunet-service-transport.c:2627 | 6635 | #: src/transport/gnunet-service-transport.c:2627 |
6530 | msgid "Transport service is lacking key configuration settings. Exiting.\n" | 6636 | msgid "Transport service is lacking key configuration settings. Exiting.\n" |
6531 | msgstr "" | 6637 | msgstr "" |
@@ -7683,58 +7789,58 @@ msgstr "" | |||
7683 | msgid "Need a non-empty hostname for service `%s'.\n" | 7789 | msgid "Need a non-empty hostname for service `%s'.\n" |
7684 | msgstr "" | 7790 | msgstr "" |
7685 | 7791 | ||
7686 | #: src/util/common_logging.c:626 src/util/common_logging.c:665 | 7792 | #: src/util/common_logging.c:648 src/util/common_logging.c:687 |
7687 | #, c-format | 7793 | #, c-format |
7688 | msgid "ERROR: Unable to parse log definition: Syntax error at `%s'.\n" | 7794 | msgid "ERROR: Unable to parse log definition: Syntax error at `%s'.\n" |
7689 | msgstr "" | 7795 | msgstr "" |
7690 | 7796 | ||
7691 | #: src/util/common_logging.c:904 | 7797 | #: src/util/common_logging.c:926 |
7692 | #, c-format | 7798 | #, c-format |
7693 | msgid "Message `%.*s' repeated %u times in the last %s\n" | 7799 | msgid "Message `%.*s' repeated %u times in the last %s\n" |
7694 | msgstr "" | 7800 | msgstr "" |
7695 | 7801 | ||
7696 | #: src/util/common_logging.c:1108 | 7802 | #: src/util/common_logging.c:1131 |
7697 | msgid "ERROR" | 7803 | msgid "ERROR" |
7698 | msgstr "ERREUR" | 7804 | msgstr "ERREUR" |
7699 | 7805 | ||
7700 | #: src/util/common_logging.c:1110 | 7806 | #: src/util/common_logging.c:1133 |
7701 | msgid "WARNING" | 7807 | msgid "WARNING" |
7702 | msgstr "AVERTISSEMENT" | 7808 | msgstr "AVERTISSEMENT" |
7703 | 7809 | ||
7704 | #: src/util/common_logging.c:1112 | 7810 | #: src/util/common_logging.c:1135 |
7705 | msgid "MESSAGE" | 7811 | msgid "MESSAGE" |
7706 | msgstr "" | 7812 | msgstr "" |
7707 | 7813 | ||
7708 | #: src/util/common_logging.c:1114 | 7814 | #: src/util/common_logging.c:1137 |
7709 | msgid "INFO" | 7815 | msgid "INFO" |
7710 | msgstr "INFO" | 7816 | msgstr "INFO" |
7711 | 7817 | ||
7712 | #: src/util/common_logging.c:1116 | 7818 | #: src/util/common_logging.c:1139 |
7713 | msgid "DEBUG" | 7819 | msgid "DEBUG" |
7714 | msgstr "DEBUG" | 7820 | msgstr "DEBUG" |
7715 | 7821 | ||
7716 | #: src/util/common_logging.c:1118 | 7822 | #: src/util/common_logging.c:1141 |
7717 | msgid "NONE" | 7823 | msgid "NONE" |
7718 | msgstr "AUCUN" | 7824 | msgstr "AUCUN" |
7719 | 7825 | ||
7720 | #: src/util/common_logging.c:1119 | 7826 | #: src/util/common_logging.c:1142 |
7721 | msgid "INVALID" | 7827 | msgid "INVALID" |
7722 | msgstr "INVALIDE" | 7828 | msgstr "INVALIDE" |
7723 | 7829 | ||
7724 | #: src/util/common_logging.c:1400 | 7830 | #: src/util/common_logging.c:1423 |
7725 | msgid "unknown address" | 7831 | msgid "unknown address" |
7726 | msgstr "adresse inconnue" | 7832 | msgstr "adresse inconnue" |
7727 | 7833 | ||
7728 | #: src/util/common_logging.c:1445 | 7834 | #: src/util/common_logging.c:1468 |
7729 | msgid "invalid address" | 7835 | msgid "invalid address" |
7730 | msgstr "adresse invalide" | 7836 | msgstr "adresse invalide" |
7731 | 7837 | ||
7732 | #: src/util/common_logging.c:1464 | 7838 | #: src/util/common_logging.c:1487 |
7733 | #, c-format | 7839 | #, c-format |
7734 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" | 7840 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" |
7735 | msgstr "" | 7841 | msgstr "" |
7736 | 7842 | ||
7737 | #: src/util/common_logging.c:1487 | 7843 | #: src/util/common_logging.c:1510 |
7738 | #, c-format | 7844 | #, c-format |
7739 | msgid "" | 7845 | msgid "" |
7740 | "Configuration specifies invalid value for option `%s' in section `%s': %s\n" | 7846 | "Configuration specifies invalid value for option `%s' in section `%s': %s\n" |
@@ -7879,17 +7985,17 @@ msgstr "" | |||
7879 | msgid "Could not bind to any port: %s\n" | 7985 | msgid "Could not bind to any port: %s\n" |
7880 | msgstr "" | 7986 | msgstr "" |
7881 | 7987 | ||
7882 | #: src/util/dnsstub.c:344 | 7988 | #: src/util/dnsstub.c:370 |
7883 | #, c-format | 7989 | #, c-format |
7884 | msgid "Received DNS response that is too small (%u bytes)" | 7990 | msgid "Received DNS response that is too small (%u bytes)\n" |
7885 | msgstr "" | 7991 | msgstr "" |
7886 | 7992 | ||
7887 | #: src/util/dnsstub.c:482 | 7993 | #: src/util/dnsstub.c:508 |
7888 | #, fuzzy, c-format | 7994 | #, fuzzy, c-format |
7889 | msgid "Failed to send DNS request to %s: %s\n" | 7995 | msgid "Failed to send DNS request to %s: %s\n" |
7890 | msgstr "Résolution de « %s » échouée : %s\n" | 7996 | msgstr "Résolution de « %s » échouée : %s\n" |
7891 | 7997 | ||
7892 | #: src/util/dnsstub.c:487 | 7998 | #: src/util/dnsstub.c:513 |
7893 | #, c-format | 7999 | #, c-format |
7894 | msgid "Sent DNS request to %s\n" | 8000 | msgid "Sent DNS request to %s\n" |
7895 | msgstr "" | 8001 | msgstr "" |
@@ -7974,82 +8080,82 @@ msgid "" | |||
7974 | "Arguments mandatory for long options are also mandatory for short options.\n" | 8080 | "Arguments mandatory for long options are also mandatory for short options.\n" |
7975 | msgstr "" | 8081 | msgstr "" |
7976 | 8082 | ||
7977 | #: src/util/getopt_helpers.c:196 | 8083 | #: src/util/getopt_helpers.c:197 |
7978 | msgid "print this help" | 8084 | msgid "print this help" |
7979 | msgstr "" | 8085 | msgstr "" |
7980 | 8086 | ||
7981 | #: src/util/getopt_helpers.c:261 | 8087 | #: src/util/getopt_helpers.c:262 |
7982 | msgid "be verbose" | 8088 | msgid "be verbose" |
7983 | msgstr "" | 8089 | msgstr "" |
7984 | 8090 | ||
7985 | #: src/util/getopt_helpers.c:377 | 8091 | #: src/util/getopt_helpers.c:378 |
7986 | msgid "configure logging to use LOGLEVEL" | 8092 | msgid "configure logging to use LOGLEVEL" |
7987 | msgstr "" | 8093 | msgstr "" |
7988 | 8094 | ||
7989 | #: src/util/getopt_helpers.c:444 | 8095 | #: src/util/getopt_helpers.c:445 |
7990 | msgid "configure logging to write logs to FILENAME" | 8096 | msgid "configure logging to write logs to FILENAME" |
7991 | msgstr "" | 8097 | msgstr "" |
7992 | 8098 | ||
7993 | #: src/util/getopt_helpers.c:461 | 8099 | #: src/util/getopt_helpers.c:462 |
7994 | msgid "use configuration file FILENAME" | 8100 | msgid "use configuration file FILENAME" |
7995 | msgstr "" | 8101 | msgstr "" |
7996 | 8102 | ||
7997 | #: src/util/getopt_helpers.c:497 src/util/getopt_helpers.c:811 | 8103 | #: src/util/getopt_helpers.c:498 src/util/getopt_helpers.c:812 |
7998 | #: src/util/getopt_helpers.c:867 | 8104 | #: src/util/getopt_helpers.c:868 |
7999 | #, c-format | 8105 | #, c-format |
8000 | msgid "You must pass a number to the `%s' option.\n" | 8106 | msgid "You must pass a number to the `%s' option.\n" |
8001 | msgstr "" | 8107 | msgstr "" |
8002 | 8108 | ||
8003 | #: src/util/getopt_helpers.c:569 | 8109 | #: src/util/getopt_helpers.c:570 |
8004 | #, c-format | 8110 | #, c-format |
8005 | msgid "" | 8111 | msgid "" |
8006 | "You must pass a relative time (optionally with sign) to the `%s' option.\n" | 8112 | "You must pass a relative time (optionally with sign) to the `%s' option.\n" |
8007 | msgstr "" | 8113 | msgstr "" |
8008 | 8114 | ||
8009 | #: src/util/getopt_helpers.c:576 | 8115 | #: src/util/getopt_helpers.c:577 |
8010 | #, c-format | 8116 | #, c-format |
8011 | msgid "Value given for time travel `%s' option is too big.\n" | 8117 | msgid "Value given for time travel `%s' option is too big.\n" |
8012 | msgstr "" | 8118 | msgstr "" |
8013 | 8119 | ||
8014 | #: src/util/getopt_helpers.c:594 | 8120 | #: src/util/getopt_helpers.c:595 |
8015 | msgid "[+/-]MICROSECONDS" | 8121 | msgid "[+/-]MICROSECONDS" |
8016 | msgstr "" | 8122 | msgstr "" |
8017 | 8123 | ||
8018 | #: src/util/getopt_helpers.c:596 | 8124 | #: src/util/getopt_helpers.c:597 |
8019 | msgid "modify system time by given offset (for debugging/testing only)" | 8125 | msgid "modify system time by given offset (for debugging/testing only)" |
8020 | msgstr "" | 8126 | msgstr "" |
8021 | 8127 | ||
8022 | #: src/util/getopt_helpers.c:630 | 8128 | #: src/util/getopt_helpers.c:631 |
8023 | #, c-format | 8129 | #, c-format |
8024 | msgid "You must pass relative time to the `%s' option.\n" | 8130 | msgid "You must pass relative time to the `%s' option.\n" |
8025 | msgstr "" | 8131 | msgstr "" |
8026 | 8132 | ||
8027 | #: src/util/getopt_helpers.c:684 | 8133 | #: src/util/getopt_helpers.c:685 |
8028 | #, c-format | 8134 | #, c-format |
8029 | msgid "You must pass absolute time to the `%s' option.\n" | 8135 | msgid "You must pass absolute time to the `%s' option.\n" |
8030 | msgstr "" | 8136 | msgstr "" |
8031 | 8137 | ||
8032 | #: src/util/getopt_helpers.c:741 | 8138 | #: src/util/getopt_helpers.c:742 |
8033 | #, c-format | 8139 | #, c-format |
8034 | msgid "You must pass a timestamp to the `%s' option.\n" | 8140 | msgid "You must pass a timestamp to the `%s' option.\n" |
8035 | msgstr "" | 8141 | msgstr "" |
8036 | 8142 | ||
8037 | #: src/util/getopt_helpers.c:748 | 8143 | #: src/util/getopt_helpers.c:749 |
8038 | #, c-format | 8144 | #, c-format |
8039 | msgid "The maximum precision allowed for timestamps is seconds.\n" | 8145 | msgid "The maximum precision allowed for timestamps is seconds.\n" |
8040 | msgstr "" | 8146 | msgstr "" |
8041 | 8147 | ||
8042 | #: src/util/getopt_helpers.c:804 | 8148 | #: src/util/getopt_helpers.c:805 |
8043 | #, c-format | 8149 | #, c-format |
8044 | msgid "Your input for the '%s' option has to be a non negative number\n" | 8150 | msgid "Your input for the '%s' option has to be a non negative number\n" |
8045 | msgstr "" | 8151 | msgstr "" |
8046 | 8152 | ||
8047 | #: src/util/getopt_helpers.c:874 | 8153 | #: src/util/getopt_helpers.c:875 |
8048 | #, c-format | 8154 | #, c-format |
8049 | msgid "You must pass a number below %u to the `%s' option.\n" | 8155 | msgid "You must pass a number below %u to the `%s' option.\n" |
8050 | msgstr "" | 8156 | msgstr "" |
8051 | 8157 | ||
8052 | #: src/util/getopt_helpers.c:952 | 8158 | #: src/util/getopt_helpers.c:953 |
8053 | #, c-format | 8159 | #, c-format |
8054 | msgid "Argument `%s' malformed. Expected base32 (Crockford) encoded value.\n" | 8160 | msgid "Argument `%s' malformed. Expected base32 (Crockford) encoded value.\n" |
8055 | msgstr "" | 8161 | msgstr "" |
@@ -8082,7 +8188,7 @@ msgstr "" | |||
8082 | msgid "Manipulate GNUnet configuration files" | 8188 | msgid "Manipulate GNUnet configuration files" |
8083 | msgstr "" | 8189 | msgstr "" |
8084 | 8190 | ||
8085 | #: src/util/gnunet-crypto-tvg.c:1072 | 8191 | #: src/util/gnunet-crypto-tvg.c:1483 |
8086 | msgid "verify a test vector from stdin" | 8192 | msgid "verify a test vector from stdin" |
8087 | msgstr "" | 8193 | msgstr "" |
8088 | 8194 | ||
@@ -8336,7 +8442,7 @@ msgstr "" | |||
8336 | msgid "Unable to shorten unix path `%s' while keeping name unique\n" | 8442 | msgid "Unable to shorten unix path `%s' while keeping name unique\n" |
8337 | msgstr "" | 8443 | msgstr "" |
8338 | 8444 | ||
8339 | #: src/util/network.c:1306 | 8445 | #: src/util/network.c:1307 |
8340 | #, c-format | 8446 | #, c-format |
8341 | msgid "" | 8447 | msgid "" |
8342 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" | 8448 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" |
@@ -8462,77 +8568,77 @@ msgstr "" | |||
8462 | msgid "Character sets requested were `%s'->`%s'\n" | 8568 | msgid "Character sets requested were `%s'->`%s'\n" |
8463 | msgstr "" | 8569 | msgstr "" |
8464 | 8570 | ||
8465 | #: src/util/strings.c:487 | 8571 | #: src/util/strings.c:514 |
8466 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" | 8572 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" |
8467 | msgstr "" | 8573 | msgstr "" |
8468 | 8574 | ||
8469 | #: src/util/strings.c:1023 | 8575 | #: src/util/strings.c:1050 |
8470 | msgid "IPv6 address did not start with `['\n" | 8576 | msgid "IPv6 address did not start with `['\n" |
8471 | msgstr "" | 8577 | msgstr "" |
8472 | 8578 | ||
8473 | #: src/util/strings.c:1031 | 8579 | #: src/util/strings.c:1058 |
8474 | msgid "IPv6 address did contain ':' to separate port number\n" | 8580 | msgid "IPv6 address did contain ':' to separate port number\n" |
8475 | msgstr "" | 8581 | msgstr "" |
8476 | 8582 | ||
8477 | #: src/util/strings.c:1038 | 8583 | #: src/util/strings.c:1065 |
8478 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" | 8584 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" |
8479 | msgstr "" | 8585 | msgstr "" |
8480 | 8586 | ||
8481 | #: src/util/strings.c:1046 | 8587 | #: src/util/strings.c:1073 |
8482 | msgid "IPv6 address did contain a valid port number after the last ':'\n" | 8588 | msgid "IPv6 address did contain a valid port number after the last ':'\n" |
8483 | msgstr "" | 8589 | msgstr "" |
8484 | 8590 | ||
8485 | #: src/util/strings.c:1055 | 8591 | #: src/util/strings.c:1082 |
8486 | #, c-format | 8592 | #, c-format |
8487 | msgid "Invalid IPv6 address `%s': %s\n" | 8593 | msgid "Invalid IPv6 address `%s': %s\n" |
8488 | msgstr "" | 8594 | msgstr "" |
8489 | 8595 | ||
8490 | #: src/util/strings.c:1237 src/util/strings.c:1248 | 8596 | #: src/util/strings.c:1264 src/util/strings.c:1275 |
8491 | msgid "Port not in range\n" | 8597 | msgid "Port not in range\n" |
8492 | msgstr "" | 8598 | msgstr "" |
8493 | 8599 | ||
8494 | #: src/util/strings.c:1257 | 8600 | #: src/util/strings.c:1284 |
8495 | #, c-format | 8601 | #, c-format |
8496 | msgid "Malformed port policy `%s'\n" | 8602 | msgid "Malformed port policy `%s'\n" |
8497 | msgstr "" | 8603 | msgstr "" |
8498 | 8604 | ||
8499 | #: src/util/strings.c:1328 src/util/strings.c:1357 src/util/strings.c:1404 | 8605 | #: src/util/strings.c:1355 src/util/strings.c:1384 src/util/strings.c:1431 |
8500 | #: src/util/strings.c:1424 | 8606 | #: src/util/strings.c:1451 |
8501 | #, c-format | 8607 | #, c-format |
8502 | msgid "Invalid format for IP: `%s'\n" | 8608 | msgid "Invalid format for IP: `%s'\n" |
8503 | msgstr "" | 8609 | msgstr "" |
8504 | 8610 | ||
8505 | #: src/util/strings.c:1382 | 8611 | #: src/util/strings.c:1409 |
8506 | #, c-format | 8612 | #, c-format |
8507 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." | 8613 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." |
8508 | msgstr "" | 8614 | msgstr "" |
8509 | 8615 | ||
8510 | #: src/util/strings.c:1433 | 8616 | #: src/util/strings.c:1460 |
8511 | #, c-format | 8617 | #, c-format |
8512 | msgid "Invalid format: `%s'\n" | 8618 | msgid "Invalid format: `%s'\n" |
8513 | msgstr "fornat invalide : « %s »\n" | 8619 | msgstr "fornat invalide : « %s »\n" |
8514 | 8620 | ||
8515 | #: src/util/strings.c:1475 | 8621 | #: src/util/strings.c:1502 |
8516 | #, c-format | 8622 | #, c-format |
8517 | msgid "Invalid network notation (does not end with ';': `%s')\n" | 8623 | msgid "Invalid network notation (does not end with ';': `%s')\n" |
8518 | msgstr "" | 8624 | msgstr "" |
8519 | 8625 | ||
8520 | #: src/util/strings.c:1525 | 8626 | #: src/util/strings.c:1552 |
8521 | #, c-format | 8627 | #, c-format |
8522 | msgid "Wrong format `%s' for netmask\n" | 8628 | msgid "Wrong format `%s' for netmask\n" |
8523 | msgstr "" | 8629 | msgstr "" |
8524 | 8630 | ||
8525 | #: src/util/strings.c:1556 | 8631 | #: src/util/strings.c:1583 |
8526 | #, c-format | 8632 | #, c-format |
8527 | msgid "Wrong format `%s' for network\n" | 8633 | msgid "Wrong format `%s' for network\n" |
8528 | msgstr "" | 8634 | msgstr "" |
8529 | 8635 | ||
8530 | #: src/util/time.c:863 src/util/time.c:891 | 8636 | #: src/util/time.c:870 src/util/time.c:898 |
8531 | #, c-format | 8637 | #, c-format |
8532 | msgid "Failed to map `%s', cannot assure monotonic time!\n" | 8638 | msgid "Failed to map `%s', cannot assure monotonic time!\n" |
8533 | msgstr "" | 8639 | msgstr "" |
8534 | 8640 | ||
8535 | #: src/util/time.c:899 | 8641 | #: src/util/time.c:906 |
8536 | #, c-format | 8642 | #, c-format |
8537 | msgid "" | 8643 | msgid "" |
8538 | "Failed to setup monotonic time file `%s', cannot assure monotonic time!\n" | 8644 | "Failed to setup monotonic time file `%s', cannot assure monotonic time!\n" |
@@ -8702,8 +8808,8 @@ msgstr "" | |||
8702 | msgid "Setup tunnels via VPN." | 8808 | msgid "Setup tunnels via VPN." |
8703 | msgstr "Configurer des tunnels via VPN." | 8809 | msgstr "Configurer des tunnels via VPN." |
8704 | 8810 | ||
8705 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:418 | 8811 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:397 |
8706 | #: src/zonemaster/gnunet-service-zonemaster.c:847 | 8812 | #: src/zonemaster/gnunet-service-zonemaster.c:832 |
8707 | msgid "Failed to connect to the namestore!\n" | 8813 | msgid "Failed to connect to the namestore!\n" |
8708 | msgstr "" | 8814 | msgstr "" |
8709 | 8815 | ||
@@ -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: 2022-01-10 15:13+0100\n" | 11 | "POT-Creation-Date: 2022-03-04 22:23+0100\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" |
@@ -20,7 +20,7 @@ msgstr "" | |||
20 | "X-Generator: Poedit 2.2.3\n" | 20 | "X-Generator: Poedit 2.2.3\n" |
21 | "Plural-Forms: nplurals=2; plural=(n != 1);\n" | 21 | "Plural-Forms: nplurals=2; plural=(n != 1);\n" |
22 | 22 | ||
23 | #: src/abd/gnunet-abd.c:392 src/namestore/gnunet-namestore.c:1304 | 23 | #: src/abd/gnunet-abd.c:392 src/namestore/gnunet-namestore.c:1254 |
24 | #, c-format | 24 | #, c-format |
25 | msgid "Ego `%s' not known to identity service\n" | 25 | msgid "Ego `%s' not known to identity service\n" |
26 | msgstr "" | 26 | msgstr "" |
@@ -32,7 +32,7 @@ msgstr "" | |||
32 | 32 | ||
33 | #: src/abd/gnunet-abd.c:558 src/abd/gnunet-service-abd.c:1751 | 33 | #: src/abd/gnunet-abd.c:558 src/abd/gnunet-service-abd.c:1751 |
34 | #: src/namestore/gnunet-namestore-fcfsd.c:1080 | 34 | #: src/namestore/gnunet-namestore-fcfsd.c:1080 |
35 | #: src/namestore/gnunet-namestore.c:1001 | 35 | #: src/namestore/gnunet-namestore.c:951 |
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 "" |
@@ -612,44 +612,44 @@ msgstr "" | |||
612 | msgid "Print information about ATS state" | 612 | msgid "Print information about ATS state" |
613 | msgstr "" | 613 | msgstr "" |
614 | 614 | ||
615 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | 615 | #: src/ats/gnunet-ats-solver-eval.c:2993 src/ats/gnunet-ats-solver-eval.c:3045 |
616 | #, c-format | 616 | #, c-format |
617 | msgid "" | 617 | msgid "" |
618 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | 618 | "Could not load quota for network `%s': `%s', assigning default bandwidth " |
619 | "%llu\n" | 619 | "%llu\n" |
620 | msgstr "" | 620 | msgstr "" |
621 | 621 | ||
622 | #: src/ats/gnunet-ats-solver-eval.c:3011 | 622 | #: src/ats/gnunet-ats-solver-eval.c:3012 |
623 | #, c-format | 623 | #, c-format |
624 | msgid "" | 624 | msgid "" |
625 | "No outbound quota configured for network `%s', assigning default bandwidth " | 625 | "No outbound quota configured for network `%s', assigning default bandwidth " |
626 | "%llu\n" | 626 | "%llu\n" |
627 | msgstr "" | 627 | msgstr "" |
628 | 628 | ||
629 | #: src/ats/gnunet-ats-solver-eval.c:3063 | 629 | #: src/ats/gnunet-ats-solver-eval.c:3064 |
630 | #, c-format | 630 | #, c-format |
631 | msgid "" | 631 | msgid "" |
632 | "No outbound quota configure for network `%s', assigning default bandwidth " | 632 | "No outbound quota configure for network `%s', assigning default bandwidth " |
633 | "%llu\n" | 633 | "%llu\n" |
634 | msgstr "" | 634 | msgstr "" |
635 | 635 | ||
636 | #: src/ats/gnunet-ats-solver-eval.c:3552 | 636 | #: src/ats/gnunet-ats-solver-eval.c:3553 |
637 | msgid "solver to use" | 637 | msgid "solver to use" |
638 | msgstr "" | 638 | msgstr "" |
639 | 639 | ||
640 | #: src/ats/gnunet-ats-solver-eval.c:3557 | 640 | #: src/ats/gnunet-ats-solver-eval.c:3558 |
641 | msgid "experiment to use" | 641 | msgid "experiment to use" |
642 | msgstr "" | 642 | msgstr "" |
643 | 643 | ||
644 | #: src/ats/gnunet-ats-solver-eval.c:3564 | 644 | #: src/ats/gnunet-ats-solver-eval.c:3565 |
645 | msgid "print logging" | 645 | msgid "print logging" |
646 | msgstr "" | 646 | msgstr "" |
647 | 647 | ||
648 | #: src/ats/gnunet-ats-solver-eval.c:3569 | 648 | #: src/ats/gnunet-ats-solver-eval.c:3570 |
649 | msgid "save logging to disk" | 649 | msgid "save logging to disk" |
650 | msgstr "" | 650 | msgstr "" |
651 | 651 | ||
652 | #: src/ats/gnunet-ats-solver-eval.c:3574 | 652 | #: src/ats/gnunet-ats-solver-eval.c:3575 |
653 | msgid "disable normalization" | 653 | msgid "disable normalization" |
654 | msgstr "" | 654 | msgstr "" |
655 | 655 | ||
@@ -1498,39 +1498,7 @@ msgstr "" | |||
1498 | msgid "# updates to my type map" | 1498 | msgid "# updates to my type map" |
1499 | msgstr "" | 1499 | msgstr "" |
1500 | 1500 | ||
1501 | #: src/datacache/datacache.c:117 src/datacache/datacache.c:275 | 1501 | #: src/datacache/plugin_datacache_heap.c:555 |
1502 | #: src/datastore/gnunet-service-datastore.c:743 | ||
1503 | msgid "# bytes stored" | ||
1504 | msgstr "" | ||
1505 | |||
1506 | #: src/datacache/datacache.c:121 src/datacache/datacache.c:279 | ||
1507 | msgid "# items stored" | ||
1508 | msgstr "# elementi memorizzati" | ||
1509 | |||
1510 | #: src/datacache/datacache.c:185 | ||
1511 | #, c-format | ||
1512 | msgid "Loading `%s' datacache plugin\n" | ||
1513 | msgstr "" | ||
1514 | |||
1515 | #: src/datacache/datacache.c:203 | ||
1516 | #, c-format | ||
1517 | msgid "Failed to load datacache plugin for `%s'\n" | ||
1518 | msgstr "" | ||
1519 | |||
1520 | #: src/datacache/datacache.c:297 | ||
1521 | msgid "# requests received" | ||
1522 | msgstr "" | ||
1523 | |||
1524 | #: src/datacache/datacache.c:308 | ||
1525 | msgid "# requests filtered by bloom filter" | ||
1526 | msgstr "" | ||
1527 | |||
1528 | #: src/datacache/datacache.c:329 | ||
1529 | #, fuzzy | ||
1530 | msgid "# proximity search requests received" | ||
1531 | msgstr "# richieste GET ricevute" | ||
1532 | |||
1533 | #: src/datacache/plugin_datacache_heap.c:527 | ||
1534 | msgid "Heap datacache running\n" | 1502 | msgid "Heap datacache running\n" |
1535 | msgstr "" | 1503 | msgstr "" |
1536 | 1504 | ||
@@ -1552,7 +1520,7 @@ msgstr "" | |||
1552 | msgid "`%s' failed at %s:%d with error: %s\n" | 1520 | msgid "`%s' failed at %s:%d with error: %s\n" |
1553 | msgstr "" | 1521 | msgstr "" |
1554 | 1522 | ||
1555 | #: src/datacache/plugin_datacache_sqlite.c:693 | 1523 | #: src/datacache/plugin_datacache_sqlite.c:723 |
1556 | #: src/datastore/plugin_datastore_sqlite.c:531 | 1524 | #: src/datastore/plugin_datastore_sqlite.c:531 |
1557 | #: src/namecache/plugin_namecache_sqlite.c:237 | 1525 | #: src/namecache/plugin_namecache_sqlite.c:237 |
1558 | #: src/namestore/plugin_namestore_sqlite.c:273 | 1526 | #: src/namestore/plugin_namestore_sqlite.c:273 |
@@ -1736,6 +1704,10 @@ msgstr "" | |||
1736 | msgid "Could not find matching reservation" | 1704 | msgid "Could not find matching reservation" |
1737 | msgstr "" | 1705 | msgstr "" |
1738 | 1706 | ||
1707 | #: src/datastore/gnunet-service-datastore.c:743 | ||
1708 | msgid "# bytes stored" | ||
1709 | msgstr "" | ||
1710 | |||
1739 | #: src/datastore/gnunet-service-datastore.c:758 | 1711 | #: src/datastore/gnunet-service-datastore.c:758 |
1740 | #, c-format | 1712 | #, c-format |
1741 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" | 1713 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" |
@@ -1916,7 +1888,7 @@ msgstr "" | |||
1916 | 1888 | ||
1917 | #: src/datastore/plugin_datastore_sqlite.c:1337 | 1889 | #: src/datastore/plugin_datastore_sqlite.c:1337 |
1918 | #: src/namecache/plugin_namecache_sqlite.c:564 | 1890 | #: src/namecache/plugin_namecache_sqlite.c:564 |
1919 | #: src/namestore/plugin_namestore_sqlite.c:765 | 1891 | #: src/namestore/plugin_namestore_sqlite.c:775 |
1920 | msgid "Sqlite database running\n" | 1892 | msgid "Sqlite database running\n" |
1921 | msgstr "" | 1893 | msgstr "" |
1922 | 1894 | ||
@@ -1924,55 +1896,65 @@ msgstr "" | |||
1924 | msgid "Template database running\n" | 1896 | msgid "Template database running\n" |
1925 | msgstr "" | 1897 | msgstr "" |
1926 | 1898 | ||
1927 | #: src/dht/gnunet-dht-get.c:159 | 1899 | #: src/dht/gnunet-dht-get.c:164 |
1928 | #, c-format | 1900 | #, c-format |
1929 | msgid "" | 1901 | msgid "" |
1930 | "Result %d, type %d:\n" | 1902 | "Result %d, type %d:\n" |
1931 | "%.*s\n" | 1903 | "%.*s\n" |
1932 | msgstr "" | 1904 | msgstr "" |
1933 | 1905 | ||
1934 | #: src/dht/gnunet-dht-get.c:160 | 1906 | #: src/dht/gnunet-dht-get.c:165 |
1935 | #, c-format | 1907 | #, c-format |
1936 | msgid "Result %d, type %d:\n" | 1908 | msgid "Result %d, type %d:\n" |
1937 | msgstr "" | 1909 | msgstr "" |
1938 | 1910 | ||
1939 | #: src/dht/gnunet-dht-get.c:209 | 1911 | #: src/dht/gnunet-dht-get.c:215 |
1940 | msgid "Must provide key for DHT GET!\n" | 1912 | msgid "Must provide key for DHT GET!\n" |
1941 | msgstr "" | 1913 | msgstr "" |
1942 | 1914 | ||
1943 | #: src/dht/gnunet-dht-get.c:217 src/dht/gnunet-dht-monitor.c:255 | 1915 | #: src/dht/gnunet-dht-get.c:223 src/dht/gnunet-dht-hello.c:119 |
1916 | #: src/dht/gnunet-dht-monitor.c:255 | ||
1917 | #, c-format | ||
1944 | msgid "Failed to connect to DHT service!\n" | 1918 | msgid "Failed to connect to DHT service!\n" |
1945 | msgstr "" | 1919 | msgstr "" |
1946 | 1920 | ||
1947 | #: src/dht/gnunet-dht-get.c:227 | 1921 | #: src/dht/gnunet-dht-get.c:233 |
1948 | msgid "Issuing DHT GET with key" | 1922 | msgid "Issuing DHT GET with key" |
1949 | msgstr "" | 1923 | msgstr "" |
1950 | 1924 | ||
1951 | #: src/dht/gnunet-dht-get.c:260 src/dht/gnunet-dht-monitor.c:302 | 1925 | #: src/dht/gnunet-dht-get.c:269 src/dht/gnunet-dht-monitor.c:302 |
1952 | #: src/dht/gnunet-dht-put.c:200 | 1926 | #: src/dht/gnunet-dht-put.c:200 |
1953 | msgid "the query key" | 1927 | msgid "the query key" |
1954 | msgstr "" | 1928 | msgstr "" |
1955 | 1929 | ||
1956 | #: src/dht/gnunet-dht-get.c:266 | 1930 | #: src/dht/gnunet-dht-get.c:275 |
1957 | msgid "how many parallel requests (replicas) to create" | 1931 | msgid "how many parallel requests (replicas) to create" |
1958 | msgstr "" | 1932 | msgstr "" |
1959 | 1933 | ||
1960 | #: src/dht/gnunet-dht-get.c:272 src/dht/gnunet-dht-monitor.c:308 | 1934 | #: src/dht/gnunet-dht-get.c:280 src/dht/gnunet-dht-put.c:217 |
1935 | msgid "use DHT's record route option" | ||
1936 | msgstr "" | ||
1937 | |||
1938 | #: src/dht/gnunet-dht-get.c:286 src/dht/gnunet-dht-monitor.c:308 | ||
1961 | msgid "the type of data to look for" | 1939 | msgid "the type of data to look for" |
1962 | msgstr "" | 1940 | msgstr "" |
1963 | 1941 | ||
1964 | #: src/dht/gnunet-dht-get.c:278 | 1942 | #: src/dht/gnunet-dht-get.c:292 |
1965 | msgid "how long to execute this query before giving up?" | 1943 | msgid "how long to execute this query before giving up?" |
1966 | msgstr "" | 1944 | msgstr "" |
1967 | 1945 | ||
1968 | #: src/dht/gnunet-dht-get.c:284 src/dht/gnunet-dht-put.c:206 | 1946 | #: src/dht/gnunet-dht-get.c:298 src/dht/gnunet-dht-put.c:206 |
1969 | msgid "use DHT's demultiplex everywhere option" | 1947 | msgid "use DHT's demultiplex everywhere option" |
1970 | msgstr "" | 1948 | msgstr "" |
1971 | 1949 | ||
1972 | #: src/dht/gnunet-dht-get.c:301 | 1950 | #: src/dht/gnunet-dht-get.c:315 |
1973 | msgid "Issue a GET request to the GNUnet DHT, prints results." | 1951 | msgid "Issue a GET request to the GNUnet DHT, prints results." |
1974 | msgstr "" | 1952 | msgstr "" |
1975 | 1953 | ||
1954 | #: src/dht/gnunet-dht-hello.c:166 | ||
1955 | msgid "Obtain HELLO from DHT or provide HELLO to DHT for bootstrapping" | ||
1956 | msgstr "" | ||
1957 | |||
1976 | #: src/dht/gnunet-dht-monitor.c:315 | 1958 | #: src/dht/gnunet-dht-monitor.c:315 |
1977 | msgid "how long should the monitor command run" | 1959 | msgid "how long should the monitor command run" |
1978 | msgstr "" | 1960 | msgstr "" |
@@ -2012,10 +1994,6 @@ msgstr "" | |||
2012 | msgid "how many replicas to create" | 1994 | msgid "how many replicas to create" |
2013 | msgstr "" | 1995 | msgstr "" |
2014 | 1996 | ||
2015 | #: src/dht/gnunet-dht-put.c:217 | ||
2016 | msgid "use DHT's record route option" | ||
2017 | msgstr "" | ||
2018 | |||
2019 | #: src/dht/gnunet-dht-put.c:223 | 1997 | #: src/dht/gnunet-dht-put.c:223 |
2020 | msgid "the type to insert data as" | 1998 | msgid "the type to insert data as" |
2021 | msgstr "" | 1999 | msgstr "" |
@@ -2070,17 +2048,17 @@ msgstr "" | |||
2070 | msgid "Measure quality and performance of the DHT service." | 2048 | msgid "Measure quality and performance of the DHT service." |
2071 | msgstr "" | 2049 | msgstr "" |
2072 | 2050 | ||
2073 | #: src/dht/plugin_block_dht.c:328 | 2051 | #: src/dht/plugin_block_dht.c:404 |
2074 | #, c-format | 2052 | #, c-format |
2075 | msgid "Block not of type %u\n" | 2053 | msgid "Block not of type %u\n" |
2076 | msgstr "" | 2054 | msgstr "" |
2077 | 2055 | ||
2078 | #: src/dht/plugin_block_dht.c:337 | 2056 | #: src/dht/plugin_block_dht.c:413 |
2079 | #, c-format | 2057 | #, c-format |
2080 | msgid "Size mismatch for block with type %u\n" | 2058 | msgid "Size mismatch for block with type %u\n" |
2081 | msgstr "" | 2059 | msgstr "" |
2082 | 2060 | ||
2083 | #: src/dht/plugin_block_dht.c:348 | 2061 | #: src/dht/plugin_block_dht.c:424 |
2084 | #, c-format | 2062 | #, c-format |
2085 | msgid "Block of type %u is malformed\n" | 2063 | msgid "Block of type %u is malformed\n" |
2086 | msgstr "" | 2064 | msgstr "" |
@@ -2782,19 +2760,19 @@ msgstr "" | |||
2782 | msgid "LOC URI malformed (signature failed validation)" | 2760 | msgid "LOC URI malformed (signature failed validation)" |
2783 | msgstr "" | 2761 | msgstr "" |
2784 | 2762 | ||
2785 | #: src/fs/fs_uri.c:653 | 2763 | #: src/fs/fs_uri.c:652 |
2786 | msgid "invalid argument" | 2764 | msgid "invalid argument" |
2787 | msgstr "argomento non valido" | 2765 | msgstr "argomento non valido" |
2788 | 2766 | ||
2789 | #: src/fs/fs_uri.c:665 | 2767 | #: src/fs/fs_uri.c:671 |
2790 | msgid "Unrecognized URI type" | 2768 | msgid "Unrecognized URI type" |
2791 | msgstr "" | 2769 | msgstr "" |
2792 | 2770 | ||
2793 | #: src/fs/fs_uri.c:1071 src/fs/fs_uri.c:1098 | 2771 | #: src/fs/fs_uri.c:1075 src/fs/fs_uri.c:1102 |
2794 | msgid "No keywords specified!\n" | 2772 | msgid "No keywords specified!\n" |
2795 | msgstr "" | 2773 | msgstr "" |
2796 | 2774 | ||
2797 | #: src/fs/fs_uri.c:1104 | 2775 | #: src/fs/fs_uri.c:1108 |
2798 | msgid "Number of double-quotes not balanced!\n" | 2776 | msgid "Number of double-quotes not balanced!\n" |
2799 | msgstr "" | 2777 | msgstr "" |
2800 | 2778 | ||
@@ -2918,7 +2896,7 @@ msgid "Downloading `%s' done (%s/s).\n" | |||
2918 | msgstr "" | 2896 | msgstr "" |
2919 | 2897 | ||
2920 | #: src/fs/gnunet-download.c:206 src/fs/gnunet-publish.c:299 | 2898 | #: src/fs/gnunet-download.c:206 src/fs/gnunet-publish.c:299 |
2921 | #: src/fs/gnunet-search.c:229 src/fs/gnunet-unindex.c:117 | 2899 | #: src/fs/gnunet-search.c:538 src/fs/gnunet-unindex.c:117 |
2922 | #, c-format | 2900 | #, c-format |
2923 | msgid "Unexpected status: %d\n" | 2901 | msgid "Unexpected status: %d\n" |
2924 | msgstr "" | 2902 | msgstr "" |
@@ -2941,12 +2919,12 @@ msgid "Target filename must be specified.\n" | |||
2941 | msgstr "" | 2919 | msgstr "" |
2942 | 2920 | ||
2943 | #: src/fs/gnunet-download.c:271 src/fs/gnunet-publish.c:869 | 2921 | #: src/fs/gnunet-download.c:271 src/fs/gnunet-publish.c:869 |
2944 | #: src/fs/gnunet-search.c:294 src/fs/gnunet-unindex.c:154 | 2922 | #: src/fs/gnunet-unindex.c:154 |
2945 | #, c-format | 2923 | #, c-format |
2946 | msgid "Could not initialize `%s' subsystem.\n" | 2924 | msgid "Could not initialize `%s' subsystem.\n" |
2947 | msgstr "" | 2925 | msgstr "" |
2948 | 2926 | ||
2949 | #: src/fs/gnunet-download.c:318 src/fs/gnunet-search.c:334 | 2927 | #: src/fs/gnunet-download.c:318 |
2950 | msgid "set the desired LEVEL of receiver-anonymity" | 2928 | msgid "set the desired LEVEL of receiver-anonymity" |
2951 | msgstr "" | 2929 | msgstr "" |
2952 | 2930 | ||
@@ -2954,7 +2932,7 @@ msgstr "" | |||
2954 | msgid "delete incomplete downloads (when aborted with CTRL-C)" | 2932 | msgid "delete incomplete downloads (when aborted with CTRL-C)" |
2955 | msgstr "" | 2933 | msgstr "" |
2956 | 2934 | ||
2957 | #: src/fs/gnunet-download.c:330 src/fs/gnunet-search.c:339 | 2935 | #: src/fs/gnunet-download.c:330 src/fs/gnunet-search.c:740 |
2958 | msgid "only search the local peer (no P2P network search)" | 2936 | msgid "only search the local peer (no P2P network search)" |
2959 | msgstr "" | 2937 | msgstr "" |
2960 | 2938 | ||
@@ -3195,38 +3173,110 @@ msgstr "" | |||
3195 | msgid "Publish a file or directory on GNUnet" | 3173 | msgid "Publish a file or directory on GNUnet" |
3196 | msgstr "" | 3174 | msgstr "" |
3197 | 3175 | ||
3198 | #: src/fs/gnunet-search.c:130 | 3176 | #: src/fs/gnunet-search.c:441 |
3199 | #, c-format | 3177 | #, c-format |
3200 | msgid "Failed to write directory with search results to `%s'\n" | 3178 | msgid "Failed to write directory with search results to `%s'\n" |
3201 | msgstr "" | 3179 | msgstr "" |
3202 | 3180 | ||
3203 | #: src/fs/gnunet-search.c:219 | 3181 | #: src/fs/gnunet-search.c:527 |
3204 | #, c-format | 3182 | #, c-format |
3205 | msgid "Error searching: %s.\n" | 3183 | msgid "Error searching: %s.\n" |
3206 | msgstr "" | 3184 | msgstr "" |
3207 | 3185 | ||
3208 | #: src/fs/gnunet-search.c:281 | 3186 | #: src/fs/gnunet-search.c:587 |
3187 | #, c-format | ||
3188 | msgid "Conflicting options --bookmark-only and --silent.\n" | ||
3189 | msgstr "" | ||
3190 | |||
3191 | #: src/fs/gnunet-search.c:594 | ||
3192 | #, c-format | ||
3193 | msgid "Conflicting options --bookmark-only and --output.\n" | ||
3194 | msgstr "" | ||
3195 | |||
3196 | #: src/fs/gnunet-search.c:600 | ||
3197 | #, c-format | ||
3198 | msgid "An output file is mandatory for silent mode.\n" | ||
3199 | msgstr "" | ||
3200 | |||
3201 | #: src/fs/gnunet-search.c:621 | ||
3209 | msgid "Could not create keyword URI from arguments.\n" | 3202 | msgid "Could not create keyword URI from arguments.\n" |
3210 | msgstr "" | 3203 | msgstr "" |
3211 | 3204 | ||
3212 | #: src/fs/gnunet-search.c:308 | 3205 | #: src/fs/gnunet-search.c:629 |
3206 | msgid "" | ||
3207 | "Invalid URI. Valid URIs for searching are keyword query URIs\n" | ||
3208 | "(\"gnunet://fs/ksk/...\") and namespace content URIs (\"gnunet://fs/sks/..." | ||
3209 | "\").\n" | ||
3210 | msgstr "" | ||
3211 | |||
3212 | #: src/fs/gnunet-search.c:654 | ||
3213 | #, c-format | ||
3214 | msgid "Could not initialize the `%s` subsystem.\n" | ||
3215 | msgstr "" | ||
3216 | |||
3217 | #: src/fs/gnunet-search.c:668 | ||
3213 | msgid "Could not start searching.\n" | 3218 | msgid "Could not start searching.\n" |
3214 | msgstr "" | 3219 | msgstr "" |
3215 | 3220 | ||
3216 | #: src/fs/gnunet-search.c:345 | 3221 | #: src/fs/gnunet-search.c:694 |
3217 | msgid "write search results to file starting with PREFIX" | 3222 | msgid "set the desired LEVEL of receiver-anonymity (default: 1)" |
3218 | msgstr "" | 3223 | msgstr "" |
3219 | 3224 | ||
3220 | #: src/fs/gnunet-search.c:351 | 3225 | #: src/fs/gnunet-search.c:700 |
3221 | msgid "automatically terminate search after DELAY" | 3226 | msgid "do not search, print only the URI that points to this search" |
3227 | msgstr "" | ||
3228 | |||
3229 | #: src/fs/gnunet-search.c:707 | ||
3230 | msgid "" | ||
3231 | "write search results for directories according to FORMAT; accepted " | ||
3232 | "placeholders are: %a, %f, %j, %l, %m, %n, %s; defaults to the value of --" | ||
3233 | "printf when omitted or to `" | ||
3234 | msgstr "" | ||
3235 | |||
3236 | #: src/fs/gnunet-search.c:717 | ||
3237 | msgid "" | ||
3238 | "write search results according to FORMAT; accepted placeholders are: %a, %f, " | ||
3239 | "%j, %l, %m, %n, %s; defaults to `" | ||
3240 | msgstr "" | ||
3241 | |||
3242 | #: src/fs/gnunet-search.c:725 | ||
3243 | msgid "" | ||
3244 | "when the %a or %j placeholders appear in --printf or --dir-printf, list each " | ||
3245 | "metadata property according to FORMAT; accepted placeholders are: %i, %l, " | ||
3246 | "%n, %p" | ||
3222 | msgstr "" | 3247 | msgstr "" |
3223 | 3248 | ||
3224 | #: src/fs/gnunet-search.c:357 | 3249 | #: src/fs/gnunet-search.c:734 |
3225 | msgid "automatically terminate search after VALUE results are found" | 3250 | msgid "automatically terminate search after VALUE results are found" |
3226 | msgstr "" | 3251 | msgstr "" |
3227 | 3252 | ||
3228 | #: src/fs/gnunet-search.c:371 | 3253 | #: src/fs/gnunet-search.c:746 |
3229 | msgid "Search GNUnet for files that were published on GNUnet" | 3254 | msgid "" |
3255 | "create a GNUnet directory with search results at FILENAME (e.g. `gnunet-" | ||
3256 | "search --output=commons" | ||
3257 | msgstr "" | ||
3258 | |||
3259 | #: src/fs/gnunet-search.c:753 | ||
3260 | msgid "silent mode (requires the --output argument)" | ||
3261 | msgstr "" | ||
3262 | |||
3263 | #: src/fs/gnunet-search.c:759 | ||
3264 | msgid "" | ||
3265 | "automatically terminate search after DELAY; the value given must be a number " | ||
3266 | "followed by a space and a time unit, for example \"500 ms\"; without a unit " | ||
3267 | "it defaults to microseconds - 1000000 = 1 second; if 0 or omitted it means " | ||
3268 | "to wait for CTRL-C" | ||
3269 | msgstr "" | ||
3270 | |||
3271 | #: src/fs/gnunet-search.c:768 | ||
3272 | #, c-format | ||
3273 | msgid "" | ||
3274 | "be verbose (append \"%a\\n\" to the default --printf and --dir-printf " | ||
3275 | "arguments - ignored when these are provided by the user)" | ||
3276 | msgstr "" | ||
3277 | |||
3278 | #: src/fs/gnunet-search.c:781 | ||
3279 | msgid "Search for files that have been published on GNUnet\n" | ||
3230 | msgstr "" | 3280 | msgstr "" |
3231 | 3281 | ||
3232 | #: src/fs/gnunet-service-fs.c:371 src/fs/gnunet-service-fs.c:878 | 3282 | #: src/fs/gnunet-service-fs.c:371 src/fs/gnunet-service-fs.c:878 |
@@ -3554,65 +3604,70 @@ msgstr "" | |||
3554 | msgid "Expected a base32-encoded public zone key\n" | 3604 | msgid "Expected a base32-encoded public zone key\n" |
3555 | msgstr "" | 3605 | msgstr "" |
3556 | 3606 | ||
3557 | #: src/gns/gnunet-bcd.c:571 | 3607 | #: src/gns/gnunet-bcd.c:573 |
3558 | #, fuzzy, c-format | 3608 | #, fuzzy, c-format |
3559 | msgid "Invalid port number %u\n" | 3609 | msgid "Invalid port number %u\n" |
3560 | msgstr "# messaggi PONG ricevuti" | 3610 | msgstr "# messaggi PONG ricevuti" |
3561 | 3611 | ||
3562 | #: src/gns/gnunet-bcd.c:612 src/namestore/gnunet-namestore-fcfsd.c:1113 | 3612 | #: src/gns/gnunet-bcd.c:614 src/namestore/gnunet-namestore-fcfsd.c:1113 |
3563 | #, fuzzy | 3613 | #, fuzzy |
3564 | msgid "Unable to set up the daemon\n" | 3614 | msgid "Unable to set up the daemon\n" |
3565 | msgstr "Generazione statistiche fallita\n" | 3615 | msgstr "Generazione statistiche fallita\n" |
3566 | 3616 | ||
3567 | #: src/gns/gnunet-bcd.c:635 src/namestore/gnunet-namestore-fcfsd.c:987 | 3617 | #: src/gns/gnunet-bcd.c:637 src/namestore/gnunet-namestore-fcfsd.c:987 |
3568 | msgid "Failed to start HTTP server\n" | 3618 | msgid "Failed to start HTTP server\n" |
3569 | msgstr "Impossibile avviare il server HTTP\n" | 3619 | msgstr "Impossibile avviare il server HTTP\n" |
3570 | 3620 | ||
3571 | #: src/gns/gnunet-bcd.c:658 | 3621 | #: src/gns/gnunet-bcd.c:660 |
3572 | msgid "Run HTTP server on port PORT (default is 8888)" | 3622 | msgid "Run HTTP server on port PORT (default is 8888)" |
3573 | msgstr "" | 3623 | msgstr "" |
3574 | 3624 | ||
3575 | #: src/gns/gnunet-bcd.c:667 | 3625 | #: src/gns/gnunet-bcd.c:669 |
3576 | msgid "GNUnet HTTP server to create business cards" | 3626 | msgid "GNUnet HTTP server to create business cards" |
3577 | msgstr "" | 3627 | msgstr "" |
3578 | 3628 | ||
3579 | #: src/gns/gnunet-dns2gns.c:241 | 3629 | #: src/gns/gnunet-dns2gns.c:298 |
3580 | msgid "Failed to pack DNS response into UDP packet!\n" | 3630 | msgid "Failed to pack DNS response into UDP packet!\n" |
3581 | msgstr "" | 3631 | msgstr "" |
3582 | 3632 | ||
3583 | #: src/gns/gnunet-dns2gns.c:315 | 3633 | #: src/gns/gnunet-dns2gns.c:379 |
3584 | #, fuzzy | 3634 | #, fuzzy |
3585 | msgid "Failed to parse DNS response!\n" | 3635 | msgid "Failed to parse DNS response!\n" |
3586 | msgstr "Generazione statistiche fallita\n" | 3636 | msgstr "Generazione statistiche fallita\n" |
3587 | 3637 | ||
3588 | #: src/gns/gnunet-dns2gns.c:452 | 3638 | #: src/gns/gnunet-dns2gns.c:453 |
3639 | #, c-format | ||
3640 | msgid "VPN returned empty result for `%s'\n" | ||
3641 | msgstr "" | ||
3642 | |||
3643 | #: src/gns/gnunet-dns2gns.c:655 | ||
3589 | #, c-format | 3644 | #, c-format |
3590 | msgid "Cannot parse DNS request from %s\n" | 3645 | msgid "Cannot parse DNS request from %s\n" |
3591 | msgstr "" | 3646 | msgstr "" |
3592 | 3647 | ||
3593 | #: src/gns/gnunet-dns2gns.c:468 | 3648 | #: src/gns/gnunet-dns2gns.c:671 |
3594 | #, c-format | 3649 | #, c-format |
3595 | msgid "Received malformed DNS request from %s\n" | 3650 | msgid "Received malformed DNS request from %s\n" |
3596 | msgstr "" | 3651 | msgstr "" |
3597 | 3652 | ||
3598 | #: src/gns/gnunet-dns2gns.c:476 | 3653 | #: src/gns/gnunet-dns2gns.c:679 |
3599 | #, c-format | 3654 | #, c-format |
3600 | msgid "Received unsupported DNS request from %s\n" | 3655 | msgid "Received unsupported DNS request from %s\n" |
3601 | msgstr "" | 3656 | msgstr "" |
3602 | 3657 | ||
3603 | #: src/gns/gnunet-dns2gns.c:637 | 3658 | #: src/gns/gnunet-dns2gns.c:840 |
3604 | msgid "No DNS server specified!\n" | 3659 | msgid "No DNS server specified!\n" |
3605 | msgstr "" | 3660 | msgstr "" |
3606 | 3661 | ||
3607 | #: src/gns/gnunet-dns2gns.c:786 | 3662 | #: src/gns/gnunet-dns2gns.c:995 |
3608 | msgid "IP of recursive DNS resolver to use (required)" | 3663 | msgid "IP of recursive DNS resolver to use (required)" |
3609 | msgstr "" | 3664 | msgstr "" |
3610 | 3665 | ||
3611 | #: src/gns/gnunet-dns2gns.c:792 | 3666 | #: src/gns/gnunet-dns2gns.c:1001 |
3612 | msgid "UDP port to listen on for inbound DNS requests; default: 2853" | 3667 | msgid "UDP port to listen on for inbound DNS requests; default: 2853" |
3613 | msgstr "" | 3668 | msgstr "" |
3614 | 3669 | ||
3615 | #: src/gns/gnunet-dns2gns.c:809 | 3670 | #: src/gns/gnunet-dns2gns.c:1018 |
3616 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" | 3671 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" |
3617 | msgstr "" | 3672 | msgstr "" |
3618 | 3673 | ||
@@ -3790,18 +3845,18 @@ msgstr "" | |||
3790 | msgid "GNUnet GNS resolver tool" | 3845 | msgid "GNUnet GNS resolver tool" |
3791 | msgstr "" | 3846 | msgstr "" |
3792 | 3847 | ||
3793 | #: src/gns/gnunet-service-gns.c:505 | 3848 | #: src/gns/gnunet-service-gns.c:501 |
3794 | #, fuzzy | 3849 | #, fuzzy |
3795 | msgid "Properly base32-encoded public key required" | 3850 | msgid "Properly base32-encoded public key required" |
3796 | msgstr "# messaggi PONG ricevuti" | 3851 | msgstr "# messaggi PONG ricevuti" |
3797 | 3852 | ||
3798 | #: src/gns/gnunet-service-gns.c:541 | 3853 | #: src/gns/gnunet-service-gns.c:537 |
3799 | msgid "Failed to connect to the namecache!\n" | 3854 | msgid "Failed to connect to the namecache!\n" |
3800 | msgstr "" | 3855 | msgstr "" |
3801 | 3856 | ||
3802 | #: src/gns/gnunet-service-gns.c:560 | 3857 | #: src/gns/gnunet-service-gns.c:556 |
3803 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:442 | 3858 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:421 |
3804 | #: src/zonemaster/gnunet-service-zonemaster.c:885 | 3859 | #: src/zonemaster/gnunet-service-zonemaster.c:870 |
3805 | msgid "Could not connect to DHT!\n" | 3860 | msgid "Could not connect to DHT!\n" |
3806 | msgstr "" | 3861 | msgstr "" |
3807 | 3862 | ||
@@ -3813,94 +3868,97 @@ msgstr "" | |||
3813 | msgid "Failed to connect to the DNS service!\n" | 3868 | msgid "Failed to connect to the DNS service!\n" |
3814 | msgstr "" | 3869 | msgstr "" |
3815 | 3870 | ||
3816 | #: src/gns/gnunet-service-gns_resolver.c:706 | 3871 | #: src/gns/gnunet-service-gns_resolver.c:659 |
3817 | #, c-format | 3872 | #, c-format |
3818 | msgid "Protocol `%s' unknown, skipping labels.\n" | 3873 | msgid "Protocol `%s' unknown, skipping labels.\n" |
3819 | msgstr "" | 3874 | msgstr "" |
3820 | 3875 | ||
3821 | #: src/gns/gnunet-service-gns_resolver.c:718 | 3876 | #: src/gns/gnunet-service-gns_resolver.c:671 |
3822 | #, c-format | 3877 | #, c-format |
3823 | msgid "Service `%s' unknown for protocol `%s', trying as number.\n" | 3878 | msgid "Service `%s' unknown for protocol `%s', trying as number.\n" |
3824 | msgstr "" | 3879 | msgstr "" |
3825 | 3880 | ||
3826 | #: src/gns/gnunet-service-gns_resolver.c:724 | 3881 | #: src/gns/gnunet-service-gns_resolver.c:677 |
3827 | #, c-format | 3882 | #, c-format |
3828 | msgid "Service `%s' not a port, skipping service labels.\n" | 3883 | msgid "Service `%s' not a port, skipping service labels.\n" |
3829 | msgstr "" | 3884 | msgstr "" |
3830 | 3885 | ||
3831 | #: src/gns/gnunet-service-gns_resolver.c:938 | 3886 | #: src/gns/gnunet-service-gns_resolver.c:891 |
3832 | msgid "Failed to parse DNS response\n" | 3887 | msgid "Failed to parse DNS response\n" |
3833 | msgstr "" | 3888 | msgstr "" |
3834 | 3889 | ||
3835 | #: src/gns/gnunet-service-gns_resolver.c:1129 | 3890 | #: src/gns/gnunet-service-gns_resolver.c:1082 |
3836 | #, c-format | 3891 | #, c-format |
3837 | msgid "Skipping record of unsupported type %d\n" | 3892 | msgid "Skipping record of unsupported type %d\n" |
3838 | msgstr "" | 3893 | msgstr "" |
3839 | 3894 | ||
3840 | #: src/gns/gnunet-service-gns_resolver.c:1447 | 3895 | #: src/gns/gnunet-service-gns_resolver.c:1859 |
3841 | #, c-format | ||
3842 | msgid "VPN returned empty result for `%s'\n" | ||
3843 | msgstr "" | ||
3844 | |||
3845 | #: src/gns/gnunet-service-gns_resolver.c:1919 | ||
3846 | #, c-format | 3896 | #, c-format |
3847 | msgid "Name `%s' cannot be converted to IDNA." | 3897 | msgid "Name `%s' cannot be converted to IDNA." |
3848 | msgstr "" | 3898 | msgstr "" |
3849 | 3899 | ||
3850 | #: src/gns/gnunet-service-gns_resolver.c:1934 | 3900 | #: src/gns/gnunet-service-gns_resolver.c:1874 |
3851 | #, c-format | 3901 | #, c-format |
3852 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" | 3902 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" |
3853 | msgstr "" | 3903 | msgstr "" |
3854 | 3904 | ||
3855 | #: src/gns/gnunet-service-gns_resolver.c:1979 | 3905 | #: src/gns/gnunet-service-gns_resolver.c:1914 |
3856 | #, c-format | 3906 | #, c-format |
3857 | msgid "GNS lookup failed (zero records found for `%s')\n" | 3907 | msgid "GNS lookup failed (zero records found for `%s')\n" |
3858 | msgstr "" | 3908 | msgstr "" |
3859 | 3909 | ||
3860 | #: src/gns/gnunet-service-gns_resolver.c:2406 | 3910 | #: src/gns/gnunet-service-gns_resolver.c:2312 |
3911 | msgid "Unable to process critical delegation record\n" | ||
3912 | msgstr "" | ||
3913 | |||
3914 | #: src/gns/gnunet-service-gns_resolver.c:2317 | ||
3861 | msgid "GNS lookup recursion failed (no delegation record found)\n" | 3915 | msgid "GNS lookup recursion failed (no delegation record found)\n" |
3862 | msgstr "" | 3916 | msgstr "" |
3863 | 3917 | ||
3864 | #: src/gns/gnunet-service-gns_resolver.c:2429 | 3918 | #: src/gns/gnunet-service-gns_resolver.c:2340 |
3865 | #, c-format | 3919 | #, c-format |
3866 | msgid "Failed to cache GNS resolution: %s\n" | 3920 | msgid "Failed to cache GNS resolution: %s\n" |
3867 | msgstr "" | 3921 | msgstr "" |
3868 | 3922 | ||
3869 | #: src/gns/gnunet-service-gns_resolver.c:2594 | 3923 | #: src/gns/gnunet-service-gns_resolver.c:2505 |
3870 | #, c-format | 3924 | #, c-format |
3871 | msgid "GNS namecache returned empty result for `%s'\n" | 3925 | msgid "GNS namecache returned empty result for `%s'\n" |
3872 | msgstr "" | 3926 | msgstr "" |
3873 | 3927 | ||
3874 | #: src/gns/gnunet-service-gns_resolver.c:2734 | 3928 | #: src/gns/gnunet-service-gns_resolver.c:2652 |
3875 | #, c-format | 3929 | #, c-format |
3876 | msgid "Zone %s was revoked, resolution fails\n" | 3930 | msgid "Zone %s was revoked, resolution fails\n" |
3877 | msgstr "" | 3931 | msgstr "" |
3878 | 3932 | ||
3879 | #: src/gns/plugin_gnsrecord_gns.c:174 | 3933 | #: src/gns/plugin_gnsrecord_gns.c:136 |
3934 | msgid "This is a memento of an older block for internal maintenance." | ||
3935 | msgstr "" | ||
3936 | |||
3937 | #: src/gns/plugin_gnsrecord_gns.c:175 | ||
3880 | #, fuzzy, c-format | 3938 | #, fuzzy, c-format |
3881 | msgid "Unable to parse zone key record `%s'\n" | 3939 | msgid "Unable to parse zone key record `%s'\n" |
3882 | msgstr "Impossibile avviare il servizio ' %s'\n" | 3940 | msgstr "Impossibile avviare il servizio ' %s'\n" |
3883 | 3941 | ||
3884 | #: src/gns/plugin_gnsrecord_gns.c:187 | 3942 | #: src/gns/plugin_gnsrecord_gns.c:188 |
3885 | msgid "Record type does not match parsed record type\n" | 3943 | msgid "Record type does not match parsed record type\n" |
3886 | msgstr "" | 3944 | msgstr "" |
3887 | 3945 | ||
3888 | #: src/gns/plugin_gnsrecord_gns.c:213 | 3946 | #: src/gns/plugin_gnsrecord_gns.c:211 |
3889 | #, c-format | 3947 | #, c-format |
3890 | msgid "Unable to parse GNS2DNS record `%s'\n" | 3948 | msgid "Unable to parse GNS2DNS record `%s'\n" |
3891 | msgstr "" | 3949 | msgstr "" |
3892 | 3950 | ||
3893 | #: src/gns/plugin_gnsrecord_gns.c:229 | 3951 | #: src/gns/plugin_gnsrecord_gns.c:227 |
3894 | #, c-format | 3952 | #, c-format |
3895 | msgid "Failed to serialize GNS2DNS record with value `%s': Not a DNS name.\n" | 3953 | msgid "Failed to serialize GNS2DNS record with value `%s': Not a DNS name.\n" |
3896 | msgstr "" | 3954 | msgstr "" |
3897 | 3955 | ||
3898 | #: src/gns/plugin_gnsrecord_gns.c:253 | 3956 | #: src/gns/plugin_gnsrecord_gns.c:251 |
3899 | #, c-format | 3957 | #, c-format |
3900 | msgid "Unable to parse VPN record string `%s'\n" | 3958 | msgid "Unable to parse VPN record string `%s'\n" |
3901 | msgstr "" | 3959 | msgstr "" |
3902 | 3960 | ||
3903 | #: src/gns/plugin_gnsrecord_gns.c:285 | 3961 | #: src/gns/plugin_gnsrecord_gns.c:283 |
3904 | #, fuzzy, c-format | 3962 | #, fuzzy, c-format |
3905 | msgid "Unable to parse BOX record string `%s'\n" | 3963 | msgid "Unable to parse BOX record string `%s'\n" |
3906 | msgstr "Impossibile avviare il servizio ' %s'\n" | 3964 | msgstr "Impossibile avviare il servizio ' %s'\n" |
@@ -3909,6 +3967,34 @@ msgstr "Impossibile avviare il servizio ' %s'\n" | |||
3909 | msgid "Gns REST API initialized\n" | 3967 | msgid "Gns REST API initialized\n" |
3910 | msgstr "" | 3968 | msgstr "" |
3911 | 3969 | ||
3970 | #: src/gnsrecord/gnsrecord_misc.c:448 | ||
3971 | msgid "Zone delegation record not allowed in apex." | ||
3972 | msgstr "" | ||
3973 | |||
3974 | #: src/gnsrecord/gnsrecord_misc.c:456 | ||
3975 | msgid "Zone delegation record set contains mutually exclusive records." | ||
3976 | msgstr "" | ||
3977 | |||
3978 | #: src/gnsrecord/gnsrecord_misc.c:466 | ||
3979 | msgid "Multiple REDIRECT records." | ||
3980 | msgstr "" | ||
3981 | |||
3982 | #: src/gnsrecord/gnsrecord_misc.c:475 src/gnsrecord/gnsrecord_misc.c:501 | ||
3983 | msgid "Redirection record set conains mutually exclusive records." | ||
3984 | msgstr "" | ||
3985 | |||
3986 | #: src/gnsrecord/gnsrecord_misc.c:482 | ||
3987 | msgid "Redirection records not allowed in apex." | ||
3988 | msgstr "" | ||
3989 | |||
3990 | #: src/gnsrecord/gnsrecord_misc.c:493 | ||
3991 | msgid "Redirection records not allowed in apex.." | ||
3992 | msgstr "" | ||
3993 | |||
3994 | #: src/gnsrecord/gnsrecord_misc.c:515 | ||
3995 | msgid "Mutually exclusive records." | ||
3996 | msgstr "" | ||
3997 | |||
3912 | #: src/gnsrecord/plugin_gnsrecord_dns.c:367 | 3998 | #: src/gnsrecord/plugin_gnsrecord_dns.c:367 |
3913 | #, c-format | 3999 | #, c-format |
3914 | msgid "Unable to parse IPv4 address `%s'\n" | 4000 | msgid "Unable to parse IPv4 address `%s'\n" |
@@ -4149,7 +4235,7 @@ msgid "# hostlist downloads initiated" | |||
4149 | msgstr "" | 4235 | msgstr "" |
4150 | 4236 | ||
4151 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1144 | 4237 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1144 |
4152 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1728 | 4238 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1732 |
4153 | msgid "# milliseconds between hostlist downloads" | 4239 | msgid "# milliseconds between hostlist downloads" |
4154 | msgstr "" | 4240 | msgstr "" |
4155 | 4241 | ||
@@ -4207,21 +4293,21 @@ msgstr "" | |||
4207 | msgid "# hostlist URIs written to file" | 4293 | msgid "# hostlist URIs written to file" |
4208 | msgstr "" | 4294 | msgstr "" |
4209 | 4295 | ||
4210 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1657 | 4296 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1661 |
4211 | #: src/transport/plugin_transport_http_client.c:2300 | 4297 | #: src/transport/plugin_transport_http_client.c:2300 |
4212 | #, c-format | 4298 | #, c-format |
4213 | msgid "Invalid proxy type: `%s', disabling proxy! Check configuration!\n" | 4299 | msgid "Invalid proxy type: `%s', disabling proxy! Check configuration!\n" |
4214 | msgstr "" | 4300 | msgstr "" |
4215 | 4301 | ||
4216 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1686 | 4302 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1690 |
4217 | msgid "Learning is enabled on this peer\n" | 4303 | msgid "Learning is enabled on this peer\n" |
4218 | msgstr "" | 4304 | msgstr "" |
4219 | 4305 | ||
4220 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1699 | 4306 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1703 |
4221 | msgid "Learning is not enabled on this peer\n" | 4307 | msgid "Learning is not enabled on this peer\n" |
4222 | msgstr "" | 4308 | msgstr "" |
4223 | 4309 | ||
4224 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1713 | 4310 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1717 |
4225 | #, c-format | 4311 | #, c-format |
4226 | msgid "" | 4312 | msgid "" |
4227 | "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" | 4313 | "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" |
@@ -4410,49 +4496,49 @@ msgstr "" | |||
4410 | msgid "Maintain egos" | 4496 | msgid "Maintain egos" |
4411 | msgstr "" | 4497 | msgstr "" |
4412 | 4498 | ||
4413 | #: src/identity/gnunet-service-identity.c:503 | 4499 | #: src/identity/gnunet-service-identity.c:502 |
4414 | msgid "no default known" | 4500 | msgid "no default known" |
4415 | msgstr "" | 4501 | msgstr "" |
4416 | 4502 | ||
4417 | #: src/identity/gnunet-service-identity.c:528 | 4503 | #: src/identity/gnunet-service-identity.c:527 |
4418 | msgid "default configured, but ego unknown (internal error)" | 4504 | msgid "default configured, but ego unknown (internal error)" |
4419 | msgstr "" | 4505 | msgstr "" |
4420 | 4506 | ||
4421 | #: src/identity/gnunet-service-identity.c:621 | 4507 | #: src/identity/gnunet-service-identity.c:620 |
4422 | #: src/identity/gnunet-service-identity.c:896 | 4508 | #: src/identity/gnunet-service-identity.c:895 |
4423 | #: src/identity/gnunet-service-identity.c:1016 | 4509 | #: src/identity/gnunet-service-identity.c:1015 |
4424 | #, c-format | 4510 | #, c-format |
4425 | msgid "Failed to write subsystem default identifier map to `%s'.\n" | 4511 | msgid "Failed to write subsystem default identifier map to `%s'.\n" |
4426 | msgstr "" | 4512 | msgstr "" |
4427 | 4513 | ||
4428 | #: src/identity/gnunet-service-identity.c:631 | 4514 | #: src/identity/gnunet-service-identity.c:630 |
4429 | msgid "Unknown ego specified for service (internal error)" | 4515 | msgid "Unknown ego specified for service (internal error)" |
4430 | msgstr "" | 4516 | msgstr "" |
4431 | 4517 | ||
4432 | #: src/identity/gnunet-service-identity.c:725 | 4518 | #: src/identity/gnunet-service-identity.c:724 |
4433 | msgid "identifier already in use for another ego" | 4519 | msgid "identifier already in use for another ego" |
4434 | msgstr "" | 4520 | msgstr "" |
4435 | 4521 | ||
4436 | #: src/identity/gnunet-service-identity.c:872 | 4522 | #: src/identity/gnunet-service-identity.c:871 |
4437 | msgid "target name already exists" | 4523 | msgid "target name already exists" |
4438 | msgstr "" | 4524 | msgstr "" |
4439 | 4525 | ||
4440 | #: src/identity/gnunet-service-identity.c:914 | 4526 | #: src/identity/gnunet-service-identity.c:913 |
4441 | #: src/identity/gnunet-service-identity.c:1033 | 4527 | #: src/identity/gnunet-service-identity.c:1032 |
4442 | msgid "no matching ego found" | 4528 | msgid "no matching ego found" |
4443 | msgstr "" | 4529 | msgstr "" |
4444 | 4530 | ||
4445 | #: src/identity/gnunet-service-identity.c:1131 | 4531 | #: src/identity/gnunet-service-identity.c:1130 |
4446 | #, c-format | 4532 | #, c-format |
4447 | msgid "Failed to parse ego information in `%s'\n" | 4533 | msgid "Failed to parse ego information in `%s'\n" |
4448 | msgstr "" | 4534 | msgstr "" |
4449 | 4535 | ||
4450 | #: src/identity/gnunet-service-identity.c:1189 | 4536 | #: src/identity/gnunet-service-identity.c:1188 |
4451 | #, c-format | 4537 | #, c-format |
4452 | msgid "Failed to parse subsystem identity configuration file `%s'\n" | 4538 | msgid "Failed to parse subsystem identity configuration file `%s'\n" |
4453 | msgstr "" | 4539 | msgstr "" |
4454 | 4540 | ||
4455 | #: src/identity/gnunet-service-identity.c:1198 | 4541 | #: src/identity/gnunet-service-identity.c:1197 |
4456 | #, c-format | 4542 | #, c-format |
4457 | msgid "Failed to create directory `%s' for storing egos\n" | 4543 | msgid "Failed to create directory `%s' for storing egos\n" |
4458 | msgstr "" | 4544 | msgstr "" |
@@ -4492,7 +4578,7 @@ msgstr "" | |||
4492 | msgid "No records found for `%s'" | 4578 | msgid "No records found for `%s'" |
4493 | msgstr "" | 4579 | msgstr "" |
4494 | 4580 | ||
4495 | #: src/namecache/gnunet-namecache.c:119 src/namestore/gnunet-namestore.c:459 | 4581 | #: src/namecache/gnunet-namecache.c:119 src/namestore/gnunet-namestore.c:469 |
4496 | #, c-format | 4582 | #, c-format |
4497 | msgid "\tCorrupt or unsupported record of type %u\n" | 4583 | msgid "\tCorrupt or unsupported record of type %u\n" |
4498 | msgstr "" | 4584 | msgstr "" |
@@ -4512,7 +4598,7 @@ msgstr "# messaggi PONG ricevuti" | |||
4512 | msgid "You must specify a name\n" | 4598 | msgid "You must specify a name\n" |
4513 | msgstr "È necessario specificare un nome\n" | 4599 | msgstr "È necessario specificare un nome\n" |
4514 | 4600 | ||
4515 | #: src/namecache/gnunet-namecache.c:214 src/namestore/gnunet-namestore.c:1641 | 4601 | #: src/namecache/gnunet-namecache.c:214 src/namestore/gnunet-namestore.c:1591 |
4516 | msgid "name of the record to add/delete/display" | 4602 | msgid "name of the record to add/delete/display" |
4517 | msgstr "" | 4603 | msgstr "" |
4518 | 4604 | ||
@@ -4520,7 +4606,7 @@ msgstr "" | |||
4520 | msgid "specifies the public key of the zone to look in" | 4606 | msgid "specifies the public key of the zone to look in" |
4521 | msgstr "" | 4607 | msgstr "" |
4522 | 4608 | ||
4523 | #: src/namecache/gnunet-namecache.c:233 src/namestore/gnunet-namestore.c:1702 | 4609 | #: src/namecache/gnunet-namecache.c:233 src/namestore/gnunet-namestore.c:1652 |
4524 | msgid "GNUnet zone manipulation tool" | 4610 | msgid "GNUnet zone manipulation tool" |
4525 | msgstr "" | 4611 | msgstr "" |
4526 | 4612 | ||
@@ -4662,140 +4748,113 @@ msgstr "" | |||
4662 | msgid "GNU Name System First-Come-First-Served name registration service" | 4748 | msgid "GNU Name System First-Come-First-Served name registration service" |
4663 | msgstr "" | 4749 | msgstr "" |
4664 | 4750 | ||
4665 | #: src/namestore/gnunet-namestore.c:334 | 4751 | #: src/namestore/gnunet-namestore.c:340 |
4666 | #, c-format | 4752 | #, c-format |
4667 | msgid "Adding record failed: %s\n" | 4753 | msgid "Adding record failed: %s\n" |
4668 | msgstr "" | 4754 | msgstr "" |
4669 | 4755 | ||
4670 | #: src/namestore/gnunet-namestore.c:362 | 4756 | #: src/namestore/gnunet-namestore.c:368 |
4671 | #, c-format | 4757 | #, c-format |
4672 | msgid "Deleting record failed, record does not exist%s%s\n" | 4758 | msgid "Deleting record failed, record does not exist%s%s\n" |
4673 | msgstr "" | 4759 | msgstr "" |
4674 | 4760 | ||
4675 | #: src/namestore/gnunet-namestore.c:369 | 4761 | #: src/namestore/gnunet-namestore.c:375 |
4676 | #, c-format | 4762 | #, c-format |
4677 | msgid "Deleting record failed%s%s\n" | 4763 | msgid "Deleting record failed%s%s\n" |
4678 | msgstr "" | 4764 | msgstr "" |
4679 | 4765 | ||
4680 | #: src/namestore/gnunet-namestore.c:656 | ||
4681 | #, c-format | ||
4682 | msgid "A %s record exists already under `%s', no other records can be added.\n" | ||
4683 | msgstr "" | ||
4684 | |||
4685 | #: src/namestore/gnunet-namestore.c:668 | 4766 | #: src/namestore/gnunet-namestore.c:668 |
4686 | #, c-format | 4767 | #, c-format |
4687 | msgid "" | 4768 | msgid "" |
4688 | "A zone key record exists already under `%s', no other records can be added.\n" | ||
4689 | msgstr "" | ||
4690 | |||
4691 | #: src/namestore/gnunet-namestore.c:680 | ||
4692 | #, c-format | ||
4693 | msgid "" | ||
4694 | "A SOA record exists already under `%s', cannot add a second SOA to the same " | 4769 | "A SOA record exists already under `%s', cannot add a second SOA to the same " |
4695 | "zone.\n" | 4770 | "zone.\n" |
4696 | msgstr "" | 4771 | msgstr "" |
4697 | 4772 | ||
4698 | #: src/namestore/gnunet-namestore.c:696 | 4773 | #: src/namestore/gnunet-namestore.c:789 |
4699 | #, c-format | ||
4700 | msgid "Records already exist under `%s', cannot add `%s' record.\n" | ||
4701 | msgstr "" | ||
4702 | |||
4703 | #: src/namestore/gnunet-namestore.c:711 | ||
4704 | #, c-format | ||
4705 | msgid "Records already exist under `%s', cannot add record.\n" | ||
4706 | msgstr "" | ||
4707 | |||
4708 | #: src/namestore/gnunet-namestore.c:726 | ||
4709 | #, c-format | ||
4710 | msgid "" | ||
4711 | "Non-GNS2DNS records already exist under `%s', cannot add GNS2DNS record.\n" | ||
4712 | msgstr "" | ||
4713 | |||
4714 | #: src/namestore/gnunet-namestore.c:846 | ||
4715 | #, c-format | 4774 | #, c-format |
4716 | msgid "There are no records under label `%s' that could be deleted.\n" | 4775 | msgid "There are no records under label `%s' that could be deleted.\n" |
4717 | msgstr "" | 4776 | msgstr "" |
4718 | 4777 | ||
4719 | #: src/namestore/gnunet-namestore.c:889 | 4778 | #: src/namestore/gnunet-namestore.c:832 |
4720 | #, c-format | 4779 | #, c-format |
4721 | msgid "" | 4780 | msgid "" |
4722 | "There are no records under label `%s' that match the request for deletion.\n" | 4781 | "There are no records under label `%s' that match the request for deletion.\n" |
4723 | msgstr "" | 4782 | msgstr "" |
4724 | 4783 | ||
4725 | #: src/namestore/gnunet-namestore.c:970 | 4784 | #: src/namestore/gnunet-namestore.c:920 |
4726 | #, fuzzy, c-format | 4785 | #, fuzzy, c-format |
4727 | msgid "Failed to replace records: %s\n" | 4786 | msgid "Failed to replace records: %s\n" |
4728 | msgstr "Impossibile avviare il servizio ' %s'\n" | 4787 | msgstr "Impossibile avviare il servizio ' %s'\n" |
4729 | 4788 | ||
4730 | #: src/namestore/gnunet-namestore.c:993 | 4789 | #: src/namestore/gnunet-namestore.c:943 |
4731 | #, c-format | 4790 | #, c-format |
4732 | msgid "No options given\n" | 4791 | msgid "No options given\n" |
4733 | msgstr "" | 4792 | msgstr "" |
4734 | 4793 | ||
4735 | #: src/namestore/gnunet-namestore.c:1014 src/namestore/gnunet-namestore.c:1066 | 4794 | #: src/namestore/gnunet-namestore.c:964 src/namestore/gnunet-namestore.c:1016 |
4736 | #: src/namestore/gnunet-namestore.c:1076 src/namestore/gnunet-namestore.c:1105 | 4795 | #: src/namestore/gnunet-namestore.c:1026 src/namestore/gnunet-namestore.c:1055 |
4737 | #: src/namestore/gnunet-namestore.c:1126 src/namestore/gnunet-namestore.c:1153 | 4796 | #: src/namestore/gnunet-namestore.c:1076 src/namestore/gnunet-namestore.c:1103 |
4738 | #: src/namestore/gnunet-namestore.c:1230 | 4797 | #: src/namestore/gnunet-namestore.c:1180 |
4739 | #, c-format | 4798 | #, c-format |
4740 | msgid "Missing option `%s' for operation `%s'\n" | 4799 | msgid "Missing option `%s' for operation `%s'\n" |
4741 | msgstr "" | 4800 | msgstr "" |
4742 | 4801 | ||
4743 | #: src/namestore/gnunet-namestore.c:1016 | 4802 | #: src/namestore/gnunet-namestore.c:966 |
4744 | msgid "replace" | 4803 | msgid "replace" |
4745 | msgstr "" | 4804 | msgstr "" |
4746 | 4805 | ||
4747 | #: src/namestore/gnunet-namestore.c:1045 | 4806 | #: src/namestore/gnunet-namestore.c:995 |
4748 | #, c-format | 4807 | #, c-format |
4749 | msgid "Invalid nick `%s'\n" | 4808 | msgid "Invalid nick `%s'\n" |
4750 | msgstr "" | 4809 | msgstr "" |
4751 | 4810 | ||
4752 | #: src/namestore/gnunet-namestore.c:1068 src/namestore/gnunet-namestore.c:1078 | 4811 | #: src/namestore/gnunet-namestore.c:1018 src/namestore/gnunet-namestore.c:1028 |
4753 | #: src/namestore/gnunet-namestore.c:1107 src/namestore/gnunet-namestore.c:1128 | 4812 | #: src/namestore/gnunet-namestore.c:1057 src/namestore/gnunet-namestore.c:1078 |
4754 | #: src/namestore/gnunet-namestore.c:1232 | 4813 | #: src/namestore/gnunet-namestore.c:1182 |
4755 | msgid "add" | 4814 | msgid "add" |
4756 | msgstr "" | 4815 | msgstr "" |
4757 | 4816 | ||
4758 | #: src/namestore/gnunet-namestore.c:1086 | 4817 | #: src/namestore/gnunet-namestore.c:1036 |
4759 | #, c-format | 4818 | #, c-format |
4760 | msgid "Unsupported type `%s'\n" | 4819 | msgid "Unsupported type `%s'\n" |
4761 | msgstr "" | 4820 | msgstr "" |
4762 | 4821 | ||
4763 | #: src/namestore/gnunet-namestore.c:1096 | 4822 | #: src/namestore/gnunet-namestore.c:1046 |
4764 | #, c-format | 4823 | #, c-format |
4765 | msgid "For DNS record types `SRV', `TLSA' and `OPENPGPKEY'" | 4824 | msgid "For DNS record types `SRV', `TLSA' and `OPENPGPKEY'" |
4766 | msgstr "" | 4825 | msgstr "" |
4767 | 4826 | ||
4768 | #: src/namestore/gnunet-namestore.c:1116 | 4827 | #: src/namestore/gnunet-namestore.c:1066 |
4769 | #, c-format | 4828 | #, c-format |
4770 | msgid "Value `%s' invalid for record type `%s'\n" | 4829 | msgid "Value `%s' invalid for record type `%s'\n" |
4771 | msgstr "" | 4830 | msgstr "" |
4772 | 4831 | ||
4773 | #: src/namestore/gnunet-namestore.c:1135 src/namestore/gnunet-namestore.c:1239 | 4832 | #: src/namestore/gnunet-namestore.c:1085 src/namestore/gnunet-namestore.c:1189 |
4774 | #, c-format | 4833 | #, c-format |
4775 | msgid "Invalid time format `%s'\n" | 4834 | msgid "Invalid time format `%s'\n" |
4776 | msgstr "" | 4835 | msgstr "" |
4777 | 4836 | ||
4778 | #: src/namestore/gnunet-namestore.c:1155 | 4837 | #: src/namestore/gnunet-namestore.c:1105 |
4779 | msgid "del" | 4838 | msgid "del" |
4780 | msgstr "" | 4839 | msgstr "" |
4781 | 4840 | ||
4782 | #: src/namestore/gnunet-namestore.c:1197 | 4841 | #: src/namestore/gnunet-namestore.c:1147 |
4783 | #, c-format | 4842 | #, c-format |
4784 | msgid "Invalid public key for reverse lookup `%s'\n" | 4843 | msgid "Invalid public key for reverse lookup `%s'\n" |
4785 | msgstr "" | 4844 | msgstr "" |
4786 | 4845 | ||
4787 | #: src/namestore/gnunet-namestore.c:1222 | 4846 | #: src/namestore/gnunet-namestore.c:1172 |
4788 | #: src/peerinfo-tool/gnunet-peerinfo.c:737 | 4847 | #: src/peerinfo-tool/gnunet-peerinfo.c:737 |
4789 | #, c-format | 4848 | #, c-format |
4790 | msgid "Invalid URI `%s'\n" | 4849 | msgid "Invalid URI `%s'\n" |
4791 | msgstr "" | 4850 | msgstr "" |
4792 | 4851 | ||
4793 | #: src/namestore/gnunet-namestore.c:1292 | 4852 | #: src/namestore/gnunet-namestore.c:1242 |
4794 | #, c-format | 4853 | #, c-format |
4795 | msgid "Label `%s' contains `.' which is not allowed\n" | 4854 | msgid "Label `%s' contains `.' which is not allowed\n" |
4796 | msgstr "" | 4855 | msgstr "" |
4797 | 4856 | ||
4798 | #: src/namestore/gnunet-namestore.c:1342 | 4857 | #: src/namestore/gnunet-namestore.c:1292 |
4799 | #, c-format | 4858 | #, c-format |
4800 | msgid "" | 4859 | msgid "" |
4801 | "No default identity configured for `namestore' subsystem\n" | 4860 | "No default identity configured for `namestore' subsystem\n" |
@@ -4803,107 +4862,111 @@ msgid "" | |||
4803 | "Run gnunet-identity -d to get a list of choices for $NAME\n" | 4862 | "Run gnunet-identity -d to get a list of choices for $NAME\n" |
4804 | msgstr "" | 4863 | msgstr "" |
4805 | 4864 | ||
4806 | #: src/namestore/gnunet-namestore.c:1407 | 4865 | #: src/namestore/gnunet-namestore.c:1357 |
4807 | #, c-format | 4866 | #, c-format |
4808 | msgid "Superfluous command line arguments (starting with `%s') ignored\n" | 4867 | msgid "Superfluous command line arguments (starting with `%s') ignored\n" |
4809 | msgstr "" | 4868 | msgstr "" |
4810 | 4869 | ||
4811 | #: src/namestore/gnunet-namestore.c:1436 | 4870 | #: src/namestore/gnunet-namestore.c:1386 |
4812 | #, c-format | 4871 | #, c-format |
4813 | msgid "Cannot connect to identity service\n" | 4872 | msgid "Cannot connect to identity service\n" |
4814 | msgstr "" | 4873 | msgstr "" |
4815 | 4874 | ||
4816 | #: src/namestore/gnunet-namestore.c:1483 | 4875 | #: src/namestore/gnunet-namestore.c:1433 |
4817 | msgid "Empty record line argument is not allowed.\n" | 4876 | msgid "Empty record line argument is not allowed.\n" |
4818 | msgstr "" | 4877 | msgstr "" |
4819 | 4878 | ||
4820 | #: src/namestore/gnunet-namestore.c:1495 | 4879 | #: src/namestore/gnunet-namestore.c:1445 |
4821 | #, c-format | 4880 | #, c-format |
4822 | msgid "Invalid expiration time `%s' (must be without unit)\n" | 4881 | msgid "Invalid expiration time `%s' (must be without unit)\n" |
4823 | msgstr "" | 4882 | msgstr "" |
4824 | 4883 | ||
4825 | #: src/namestore/gnunet-namestore.c:1507 src/namestore/gnunet-namestore.c:1523 | 4884 | #: src/namestore/gnunet-namestore.c:1457 src/namestore/gnunet-namestore.c:1473 |
4826 | #: src/namestore/gnunet-namestore.c:1540 | 4885 | #: src/namestore/gnunet-namestore.c:1490 |
4827 | #, c-format | 4886 | #, c-format |
4828 | msgid "Missing entries in record line `%s'.\n" | 4887 | msgid "Missing entries in record line `%s'.\n" |
4829 | msgstr "" | 4888 | msgstr "" |
4830 | 4889 | ||
4831 | #: src/namestore/gnunet-namestore.c:1515 | 4890 | #: src/namestore/gnunet-namestore.c:1465 |
4832 | #, fuzzy, c-format | 4891 | #, fuzzy, c-format |
4833 | msgid "Unknown record type `%s'\n" | 4892 | msgid "Unknown record type `%s'\n" |
4834 | msgstr "Comando `%s' sconosciuto.\n" | 4893 | msgstr "Comando `%s' sconosciuto.\n" |
4835 | 4894 | ||
4836 | #: src/namestore/gnunet-namestore.c:1553 | 4895 | #: src/namestore/gnunet-namestore.c:1503 |
4837 | #, fuzzy, c-format | 4896 | #, fuzzy, c-format |
4838 | msgid "Invalid record data for type %s: `%s'.\n" | 4897 | msgid "Invalid record data for type %s: `%s'.\n" |
4839 | msgstr "Indirizzo IPv6 non valido: `%s'\n" | 4898 | msgstr "Indirizzo IPv6 non valido: `%s'\n" |
4840 | 4899 | ||
4841 | #: src/namestore/gnunet-namestore.c:1610 | 4900 | #: src/namestore/gnunet-namestore.c:1560 |
4842 | msgid "add record" | 4901 | msgid "add record" |
4843 | msgstr "" | 4902 | msgstr "" |
4844 | 4903 | ||
4845 | #: src/namestore/gnunet-namestore.c:1613 | 4904 | #: src/namestore/gnunet-namestore.c:1563 |
4846 | msgid "delete record" | 4905 | msgid "delete record" |
4847 | msgstr "" | 4906 | msgstr "" |
4848 | 4907 | ||
4849 | #: src/namestore/gnunet-namestore.c:1617 | 4908 | #: src/namestore/gnunet-namestore.c:1567 |
4850 | msgid "display records" | 4909 | msgid "display records" |
4851 | msgstr "" | 4910 | msgstr "" |
4852 | 4911 | ||
4853 | #: src/namestore/gnunet-namestore.c:1624 | 4912 | #: src/namestore/gnunet-namestore.c:1574 |
4854 | msgid "" | 4913 | msgid "" |
4855 | "expiration time for record to use (for adding only), \"never\" is possible" | 4914 | "expiration time for record to use (for adding only), \"never\" is possible" |
4856 | msgstr "" | 4915 | msgstr "" |
4857 | 4916 | ||
4858 | #: src/namestore/gnunet-namestore.c:1630 | 4917 | #: src/namestore/gnunet-namestore.c:1580 |
4859 | msgid "set the desired nick name for the zone" | 4918 | msgid "set the desired nick name for the zone" |
4860 | msgstr "" | 4919 | msgstr "" |
4861 | 4920 | ||
4862 | #: src/namestore/gnunet-namestore.c:1635 | 4921 | #: src/namestore/gnunet-namestore.c:1585 |
4863 | msgid "monitor changes in the namestore" | 4922 | msgid "monitor changes in the namestore" |
4864 | msgstr "" | 4923 | msgstr "" |
4865 | 4924 | ||
4866 | #: src/namestore/gnunet-namestore.c:1647 | 4925 | #: src/namestore/gnunet-namestore.c:1597 |
4867 | msgid "determine our name for the given PKEY" | 4926 | msgid "determine our name for the given PKEY" |
4868 | msgstr "" | 4927 | msgstr "" |
4869 | 4928 | ||
4870 | #: src/namestore/gnunet-namestore.c:1654 | 4929 | #: src/namestore/gnunet-namestore.c:1604 |
4871 | msgid "" | 4930 | msgid "" |
4872 | "set record set to values given by (possibly multiple) RECORDLINES; can be " | 4931 | "set record set to values given by (possibly multiple) RECORDLINES; can be " |
4873 | "specified multiple times" | 4932 | "specified multiple times" |
4874 | msgstr "" | 4933 | msgstr "" |
4875 | 4934 | ||
4876 | #: src/namestore/gnunet-namestore.c:1660 | 4935 | #: src/namestore/gnunet-namestore.c:1610 |
4877 | msgid "type of the record to add/delete/display" | 4936 | msgid "type of the record to add/delete/display" |
4878 | msgstr "" | 4937 | msgstr "" |
4879 | 4938 | ||
4880 | #: src/namestore/gnunet-namestore.c:1665 | 4939 | #: src/namestore/gnunet-namestore.c:1615 |
4881 | msgid "URI to import into our zone" | 4940 | msgid "URI to import into our zone" |
4882 | msgstr "" | 4941 | msgstr "" |
4883 | 4942 | ||
4884 | #: src/namestore/gnunet-namestore.c:1671 | 4943 | #: src/namestore/gnunet-namestore.c:1621 |
4885 | msgid "value of the record to add/delete" | 4944 | msgid "value of the record to add/delete" |
4886 | msgstr "" | 4945 | msgstr "" |
4887 | 4946 | ||
4888 | #: src/namestore/gnunet-namestore.c:1675 | 4947 | #: src/namestore/gnunet-namestore.c:1625 |
4889 | msgid "create or list public record" | 4948 | msgid "create or list public record" |
4890 | msgstr "" | 4949 | msgstr "" |
4891 | 4950 | ||
4892 | #: src/namestore/gnunet-namestore.c:1681 | 4951 | #: src/namestore/gnunet-namestore.c:1631 |
4893 | msgid "" | 4952 | msgid "" |
4894 | "create shadow record (only valid if all other records of the same type have " | 4953 | "create shadow record (only valid if all other records of the same type have " |
4895 | "expired" | 4954 | "expired" |
4896 | msgstr "" | 4955 | msgstr "" |
4897 | 4956 | ||
4898 | #: src/namestore/gnunet-namestore.c:1687 | 4957 | #: src/namestore/gnunet-namestore.c:1637 |
4899 | msgid "name of the ego controlling the zone" | 4958 | msgid "name of the ego controlling the zone" |
4900 | msgstr "" | 4959 | msgstr "" |
4901 | 4960 | ||
4902 | #: src/namestore/gnunet-service-namestore.c:871 | 4961 | #: src/namestore/gnunet-service-namestore.c:879 |
4903 | #, c-format | 4962 | #, c-format |
4904 | msgid "Failed to replicate block in namecache: %s\n" | 4963 | msgid "Failed to replicate block in namecache: %s\n" |
4905 | msgstr "" | 4964 | msgstr "" |
4906 | 4965 | ||
4966 | #: src/namestore/gnunet-service-namestore.c:1668 | ||
4967 | msgid "Store failed" | ||
4968 | msgstr "" | ||
4969 | |||
4907 | #: src/namestore/gnunet-zoneimport.c:1847 | 4970 | #: src/namestore/gnunet-zoneimport.c:1847 |
4908 | msgid "size to use for the main hash map" | 4971 | msgid "size to use for the main hash map" |
4909 | msgstr "" | 4972 | msgstr "" |
@@ -4912,10 +4975,6 @@ msgstr "" | |||
4912 | msgid "minimum expiration time we assume for imported records" | 4975 | msgid "minimum expiration time we assume for imported records" |
4913 | msgstr "" | 4976 | msgstr "" |
4914 | 4977 | ||
4915 | #: src/namestore/namestore_api.c:373 | ||
4916 | msgid "Namestore failed to store record\n" | ||
4917 | msgstr "" | ||
4918 | |||
4919 | #: src/namestore/plugin_namestore_flat.c:195 | 4978 | #: src/namestore/plugin_namestore_flat.c:195 |
4920 | #, c-format | 4979 | #, c-format |
4921 | msgid "File too big to map: %llu bytes.\n" | 4980 | msgid "File too big to map: %llu bytes.\n" |
@@ -5481,6 +5540,51 @@ msgstr "" | |||
5481 | msgid "Daemon to run to perform IP protocol translation to GNUnet" | 5540 | msgid "Daemon to run to perform IP protocol translation to GNUnet" |
5482 | msgstr "" | 5541 | msgstr "" |
5483 | 5542 | ||
5543 | #: src/reclaim/gnunet-did.c:209 | ||
5544 | #, c-format | ||
5545 | msgid "Invalid DID `%s'\n" | ||
5546 | msgstr "" | ||
5547 | |||
5548 | #: src/reclaim/gnunet-did.c:835 | ||
5549 | msgid "Create a DID Document and display its DID" | ||
5550 | msgstr "" | ||
5551 | |||
5552 | #: src/reclaim/gnunet-did.c:840 | ||
5553 | msgid "Get the DID Document associated with the given DID" | ||
5554 | msgstr "" | ||
5555 | |||
5556 | #: src/reclaim/gnunet-did.c:844 | ||
5557 | msgid "Show the DID for a given ego" | ||
5558 | msgstr "" | ||
5559 | |||
5560 | #: src/reclaim/gnunet-did.c:849 | ||
5561 | msgid "Remove the DID" | ||
5562 | msgstr "" | ||
5563 | |||
5564 | #: src/reclaim/gnunet-did.c:853 src/reclaim/gnunet-did.c:857 | ||
5565 | msgid "Replace the DID Document." | ||
5566 | msgstr "" | ||
5567 | |||
5568 | #: src/reclaim/gnunet-did.c:863 | ||
5569 | msgid "The Decentralized Identity (DID)" | ||
5570 | msgstr "" | ||
5571 | |||
5572 | #: src/reclaim/gnunet-did.c:869 | ||
5573 | msgid "The DID Document to store in GNUNET" | ||
5574 | msgstr "" | ||
5575 | |||
5576 | #: src/reclaim/gnunet-did.c:874 | ||
5577 | msgid "The name of the EGO" | ||
5578 | msgstr "" | ||
5579 | |||
5580 | #: src/reclaim/gnunet-did.c:880 | ||
5581 | msgid "The time until the DID Document is going to expire (e.g. 5d)" | ||
5582 | msgstr "" | ||
5583 | |||
5584 | #: src/reclaim/gnunet-did.c:889 | ||
5585 | msgid "Manage Decentralized Identities (DIDs)" | ||
5586 | msgstr "" | ||
5587 | |||
5484 | #: src/reclaim/gnunet-reclaim.c:802 | 5588 | #: src/reclaim/gnunet-reclaim.c:802 |
5485 | #, c-format | 5589 | #, c-format |
5486 | msgid "Ego is required\n" | 5590 | msgid "Ego is required\n" |
@@ -6348,17 +6452,17 @@ msgid "" | |||
6348 | "free topology cannot be more than %u. Given `%s = %llu'" | 6452 | "free topology cannot be more than %u. Given `%s = %llu'" |
6349 | msgstr "" | 6453 | msgstr "" |
6350 | 6454 | ||
6351 | #: src/testbed/testbed_api_topology.c:1033 src/testing/testing.c:2643 | 6455 | #: src/testbed/testbed_api_topology.c:1033 src/testing/testing.c:2657 |
6352 | #, c-format | 6456 | #, c-format |
6353 | msgid "Topology file %s not found\n" | 6457 | msgid "Topology file %s not found\n" |
6354 | msgstr "" | 6458 | msgstr "" |
6355 | 6459 | ||
6356 | #: src/testbed/testbed_api_topology.c:1041 src/testing/testing.c:2651 | 6460 | #: src/testbed/testbed_api_topology.c:1041 src/testing/testing.c:2665 |
6357 | #, c-format | 6461 | #, c-format |
6358 | msgid "Topology file %s has no data\n" | 6462 | msgid "Topology file %s has no data\n" |
6359 | msgstr "" | 6463 | msgstr "" |
6360 | 6464 | ||
6361 | #: src/testbed/testbed_api_topology.c:1049 src/testing/testing.c:2659 | 6465 | #: src/testbed/testbed_api_topology.c:1049 src/testing/testing.c:2673 |
6362 | #, c-format | 6466 | #, c-format |
6363 | msgid "Topology file %s cannot be read\n" | 6467 | msgid "Topology file %s cannot be read\n" |
6364 | msgstr "" | 6468 | msgstr "" |
@@ -6556,7 +6660,7 @@ msgstr "" | |||
6556 | 6660 | ||
6557 | #: src/transport/gnunet-communicator-tcp.c:3338 | 6661 | #: src/transport/gnunet-communicator-tcp.c:3338 |
6558 | #: src/transport/gnunet-communicator-udp.c:3856 | 6662 | #: src/transport/gnunet-communicator-udp.c:3856 |
6559 | #: src/transport/gnunet-service-tng.c:10512 | 6663 | #: src/transport/gnunet-service-tng.c:10623 |
6560 | #: src/transport/gnunet-service-transport.c:2627 | 6664 | #: src/transport/gnunet-service-transport.c:2627 |
6561 | msgid "Transport service is lacking key configuration settings. Exiting.\n" | 6665 | msgid "Transport service is lacking key configuration settings. Exiting.\n" |
6562 | msgstr "" | 6666 | msgstr "" |
@@ -7736,58 +7840,58 @@ msgstr "" | |||
7736 | msgid "Need a non-empty hostname for service `%s'.\n" | 7840 | msgid "Need a non-empty hostname for service `%s'.\n" |
7737 | msgstr "" | 7841 | msgstr "" |
7738 | 7842 | ||
7739 | #: src/util/common_logging.c:626 src/util/common_logging.c:665 | 7843 | #: src/util/common_logging.c:648 src/util/common_logging.c:687 |
7740 | #, c-format | 7844 | #, c-format |
7741 | msgid "ERROR: Unable to parse log definition: Syntax error at `%s'.\n" | 7845 | msgid "ERROR: Unable to parse log definition: Syntax error at `%s'.\n" |
7742 | msgstr "" | 7846 | msgstr "" |
7743 | 7847 | ||
7744 | #: src/util/common_logging.c:904 | 7848 | #: src/util/common_logging.c:926 |
7745 | #, c-format | 7849 | #, c-format |
7746 | msgid "Message `%.*s' repeated %u times in the last %s\n" | 7850 | msgid "Message `%.*s' repeated %u times in the last %s\n" |
7747 | msgstr "" | 7851 | msgstr "" |
7748 | 7852 | ||
7749 | #: src/util/common_logging.c:1108 | 7853 | #: src/util/common_logging.c:1131 |
7750 | msgid "ERROR" | 7854 | msgid "ERROR" |
7751 | msgstr "ERRORE" | 7855 | msgstr "ERRORE" |
7752 | 7856 | ||
7753 | #: src/util/common_logging.c:1110 | 7857 | #: src/util/common_logging.c:1133 |
7754 | msgid "WARNING" | 7858 | msgid "WARNING" |
7755 | msgstr "ATTENZIONE" | 7859 | msgstr "ATTENZIONE" |
7756 | 7860 | ||
7757 | #: src/util/common_logging.c:1112 | 7861 | #: src/util/common_logging.c:1135 |
7758 | msgid "MESSAGE" | 7862 | msgid "MESSAGE" |
7759 | msgstr "" | 7863 | msgstr "" |
7760 | 7864 | ||
7761 | #: src/util/common_logging.c:1114 | 7865 | #: src/util/common_logging.c:1137 |
7762 | msgid "INFO" | 7866 | msgid "INFO" |
7763 | msgstr "INFO" | 7867 | msgstr "INFO" |
7764 | 7868 | ||
7765 | #: src/util/common_logging.c:1116 | 7869 | #: src/util/common_logging.c:1139 |
7766 | msgid "DEBUG" | 7870 | msgid "DEBUG" |
7767 | msgstr "DEBUG" | 7871 | msgstr "DEBUG" |
7768 | 7872 | ||
7769 | #: src/util/common_logging.c:1118 | 7873 | #: src/util/common_logging.c:1141 |
7770 | msgid "NONE" | 7874 | msgid "NONE" |
7771 | msgstr "NESSUNA" | 7875 | msgstr "NESSUNA" |
7772 | 7876 | ||
7773 | #: src/util/common_logging.c:1119 | 7877 | #: src/util/common_logging.c:1142 |
7774 | msgid "INVALID" | 7878 | msgid "INVALID" |
7775 | msgstr "NON VALIDO" | 7879 | msgstr "NON VALIDO" |
7776 | 7880 | ||
7777 | #: src/util/common_logging.c:1400 | 7881 | #: src/util/common_logging.c:1423 |
7778 | msgid "unknown address" | 7882 | msgid "unknown address" |
7779 | msgstr "indirizzo sconosciuto" | 7883 | msgstr "indirizzo sconosciuto" |
7780 | 7884 | ||
7781 | #: src/util/common_logging.c:1445 | 7885 | #: src/util/common_logging.c:1468 |
7782 | msgid "invalid address" | 7886 | msgid "invalid address" |
7783 | msgstr "indirizzo non valido" | 7887 | msgstr "indirizzo non valido" |
7784 | 7888 | ||
7785 | #: src/util/common_logging.c:1464 | 7889 | #: src/util/common_logging.c:1487 |
7786 | #, c-format | 7890 | #, c-format |
7787 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" | 7891 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" |
7788 | msgstr "" | 7892 | msgstr "" |
7789 | 7893 | ||
7790 | #: src/util/common_logging.c:1487 | 7894 | #: src/util/common_logging.c:1510 |
7791 | #, c-format | 7895 | #, c-format |
7792 | msgid "" | 7896 | msgid "" |
7793 | "Configuration specifies invalid value for option `%s' in section `%s': %s\n" | 7897 | "Configuration specifies invalid value for option `%s' in section `%s': %s\n" |
@@ -7932,17 +8036,17 @@ msgstr "" | |||
7932 | msgid "Could not bind to any port: %s\n" | 8036 | msgid "Could not bind to any port: %s\n" |
7933 | msgstr "" | 8037 | msgstr "" |
7934 | 8038 | ||
7935 | #: src/util/dnsstub.c:344 | 8039 | #: src/util/dnsstub.c:370 |
7936 | #, c-format | 8040 | #, c-format |
7937 | msgid "Received DNS response that is too small (%u bytes)" | 8041 | msgid "Received DNS response that is too small (%u bytes)\n" |
7938 | msgstr "" | 8042 | msgstr "" |
7939 | 8043 | ||
7940 | #: src/util/dnsstub.c:482 | 8044 | #: src/util/dnsstub.c:508 |
7941 | #, fuzzy, c-format | 8045 | #, fuzzy, c-format |
7942 | msgid "Failed to send DNS request to %s: %s\n" | 8046 | msgid "Failed to send DNS request to %s: %s\n" |
7943 | msgstr "Generazione statistiche fallita\n" | 8047 | msgstr "Generazione statistiche fallita\n" |
7944 | 8048 | ||
7945 | #: src/util/dnsstub.c:487 | 8049 | #: src/util/dnsstub.c:513 |
7946 | #, c-format | 8050 | #, c-format |
7947 | msgid "Sent DNS request to %s\n" | 8051 | msgid "Sent DNS request to %s\n" |
7948 | msgstr "" | 8052 | msgstr "" |
@@ -8027,82 +8131,82 @@ msgid "" | |||
8027 | "Arguments mandatory for long options are also mandatory for short options.\n" | 8131 | "Arguments mandatory for long options are also mandatory for short options.\n" |
8028 | msgstr "" | 8132 | msgstr "" |
8029 | 8133 | ||
8030 | #: src/util/getopt_helpers.c:196 | 8134 | #: src/util/getopt_helpers.c:197 |
8031 | msgid "print this help" | 8135 | msgid "print this help" |
8032 | msgstr "" | 8136 | msgstr "" |
8033 | 8137 | ||
8034 | #: src/util/getopt_helpers.c:261 | 8138 | #: src/util/getopt_helpers.c:262 |
8035 | msgid "be verbose" | 8139 | msgid "be verbose" |
8036 | msgstr "" | 8140 | msgstr "" |
8037 | 8141 | ||
8038 | #: src/util/getopt_helpers.c:377 | 8142 | #: src/util/getopt_helpers.c:378 |
8039 | msgid "configure logging to use LOGLEVEL" | 8143 | msgid "configure logging to use LOGLEVEL" |
8040 | msgstr "" | 8144 | msgstr "" |
8041 | 8145 | ||
8042 | #: src/util/getopt_helpers.c:444 | 8146 | #: src/util/getopt_helpers.c:445 |
8043 | msgid "configure logging to write logs to FILENAME" | 8147 | msgid "configure logging to write logs to FILENAME" |
8044 | msgstr "" | 8148 | msgstr "" |
8045 | 8149 | ||
8046 | #: src/util/getopt_helpers.c:461 | 8150 | #: src/util/getopt_helpers.c:462 |
8047 | msgid "use configuration file FILENAME" | 8151 | msgid "use configuration file FILENAME" |
8048 | msgstr "" | 8152 | msgstr "" |
8049 | 8153 | ||
8050 | #: src/util/getopt_helpers.c:497 src/util/getopt_helpers.c:811 | 8154 | #: src/util/getopt_helpers.c:498 src/util/getopt_helpers.c:812 |
8051 | #: src/util/getopt_helpers.c:867 | 8155 | #: src/util/getopt_helpers.c:868 |
8052 | #, c-format | 8156 | #, c-format |
8053 | msgid "You must pass a number to the `%s' option.\n" | 8157 | msgid "You must pass a number to the `%s' option.\n" |
8054 | msgstr "" | 8158 | msgstr "" |
8055 | 8159 | ||
8056 | #: src/util/getopt_helpers.c:569 | 8160 | #: src/util/getopt_helpers.c:570 |
8057 | #, c-format | 8161 | #, c-format |
8058 | msgid "" | 8162 | msgid "" |
8059 | "You must pass a relative time (optionally with sign) to the `%s' option.\n" | 8163 | "You must pass a relative time (optionally with sign) to the `%s' option.\n" |
8060 | msgstr "" | 8164 | msgstr "" |
8061 | 8165 | ||
8062 | #: src/util/getopt_helpers.c:576 | 8166 | #: src/util/getopt_helpers.c:577 |
8063 | #, c-format | 8167 | #, c-format |
8064 | msgid "Value given for time travel `%s' option is too big.\n" | 8168 | msgid "Value given for time travel `%s' option is too big.\n" |
8065 | msgstr "" | 8169 | msgstr "" |
8066 | 8170 | ||
8067 | #: src/util/getopt_helpers.c:594 | 8171 | #: src/util/getopt_helpers.c:595 |
8068 | msgid "[+/-]MICROSECONDS" | 8172 | msgid "[+/-]MICROSECONDS" |
8069 | msgstr "" | 8173 | msgstr "" |
8070 | 8174 | ||
8071 | #: src/util/getopt_helpers.c:596 | 8175 | #: src/util/getopt_helpers.c:597 |
8072 | msgid "modify system time by given offset (for debugging/testing only)" | 8176 | msgid "modify system time by given offset (for debugging/testing only)" |
8073 | msgstr "" | 8177 | msgstr "" |
8074 | 8178 | ||
8075 | #: src/util/getopt_helpers.c:630 | 8179 | #: src/util/getopt_helpers.c:631 |
8076 | #, c-format | 8180 | #, c-format |
8077 | msgid "You must pass relative time to the `%s' option.\n" | 8181 | msgid "You must pass relative time to the `%s' option.\n" |
8078 | msgstr "" | 8182 | msgstr "" |
8079 | 8183 | ||
8080 | #: src/util/getopt_helpers.c:684 | 8184 | #: src/util/getopt_helpers.c:685 |
8081 | #, c-format | 8185 | #, c-format |
8082 | msgid "You must pass absolute time to the `%s' option.\n" | 8186 | msgid "You must pass absolute time to the `%s' option.\n" |
8083 | msgstr "" | 8187 | msgstr "" |
8084 | 8188 | ||
8085 | #: src/util/getopt_helpers.c:741 | 8189 | #: src/util/getopt_helpers.c:742 |
8086 | #, c-format | 8190 | #, c-format |
8087 | msgid "You must pass a timestamp to the `%s' option.\n" | 8191 | msgid "You must pass a timestamp to the `%s' option.\n" |
8088 | msgstr "" | 8192 | msgstr "" |
8089 | 8193 | ||
8090 | #: src/util/getopt_helpers.c:748 | 8194 | #: src/util/getopt_helpers.c:749 |
8091 | #, c-format | 8195 | #, c-format |
8092 | msgid "The maximum precision allowed for timestamps is seconds.\n" | 8196 | msgid "The maximum precision allowed for timestamps is seconds.\n" |
8093 | msgstr "" | 8197 | msgstr "" |
8094 | 8198 | ||
8095 | #: src/util/getopt_helpers.c:804 | 8199 | #: src/util/getopt_helpers.c:805 |
8096 | #, c-format | 8200 | #, c-format |
8097 | msgid "Your input for the '%s' option has to be a non negative number\n" | 8201 | msgid "Your input for the '%s' option has to be a non negative number\n" |
8098 | msgstr "" | 8202 | msgstr "" |
8099 | 8203 | ||
8100 | #: src/util/getopt_helpers.c:874 | 8204 | #: src/util/getopt_helpers.c:875 |
8101 | #, c-format | 8205 | #, c-format |
8102 | msgid "You must pass a number below %u to the `%s' option.\n" | 8206 | msgid "You must pass a number below %u to the `%s' option.\n" |
8103 | msgstr "" | 8207 | msgstr "" |
8104 | 8208 | ||
8105 | #: src/util/getopt_helpers.c:952 | 8209 | #: src/util/getopt_helpers.c:953 |
8106 | #, c-format | 8210 | #, c-format |
8107 | msgid "Argument `%s' malformed. Expected base32 (Crockford) encoded value.\n" | 8211 | msgid "Argument `%s' malformed. Expected base32 (Crockford) encoded value.\n" |
8108 | msgstr "" | 8212 | msgstr "" |
@@ -8135,7 +8239,7 @@ msgstr "" | |||
8135 | msgid "Manipulate GNUnet configuration files" | 8239 | msgid "Manipulate GNUnet configuration files" |
8136 | msgstr "" | 8240 | msgstr "" |
8137 | 8241 | ||
8138 | #: src/util/gnunet-crypto-tvg.c:1072 | 8242 | #: src/util/gnunet-crypto-tvg.c:1483 |
8139 | msgid "verify a test vector from stdin" | 8243 | msgid "verify a test vector from stdin" |
8140 | msgstr "" | 8244 | msgstr "" |
8141 | 8245 | ||
@@ -8389,7 +8493,7 @@ msgstr "" | |||
8389 | msgid "Unable to shorten unix path `%s' while keeping name unique\n" | 8493 | msgid "Unable to shorten unix path `%s' while keeping name unique\n" |
8390 | msgstr "" | 8494 | msgstr "" |
8391 | 8495 | ||
8392 | #: src/util/network.c:1306 | 8496 | #: src/util/network.c:1307 |
8393 | #, c-format | 8497 | #, c-format |
8394 | msgid "" | 8498 | msgid "" |
8395 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" | 8499 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" |
@@ -8516,77 +8620,77 @@ msgstr "" | |||
8516 | msgid "Character sets requested were `%s'->`%s'\n" | 8620 | msgid "Character sets requested were `%s'->`%s'\n" |
8517 | msgstr "" | 8621 | msgstr "" |
8518 | 8622 | ||
8519 | #: src/util/strings.c:487 | 8623 | #: src/util/strings.c:514 |
8520 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" | 8624 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" |
8521 | msgstr "" | 8625 | msgstr "" |
8522 | 8626 | ||
8523 | #: src/util/strings.c:1023 | 8627 | #: src/util/strings.c:1050 |
8524 | msgid "IPv6 address did not start with `['\n" | 8628 | msgid "IPv6 address did not start with `['\n" |
8525 | msgstr "" | 8629 | msgstr "" |
8526 | 8630 | ||
8527 | #: src/util/strings.c:1031 | 8631 | #: src/util/strings.c:1058 |
8528 | msgid "IPv6 address did contain ':' to separate port number\n" | 8632 | msgid "IPv6 address did contain ':' to separate port number\n" |
8529 | msgstr "" | 8633 | msgstr "" |
8530 | 8634 | ||
8531 | #: src/util/strings.c:1038 | 8635 | #: src/util/strings.c:1065 |
8532 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" | 8636 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" |
8533 | msgstr "" | 8637 | msgstr "" |
8534 | 8638 | ||
8535 | #: src/util/strings.c:1046 | 8639 | #: src/util/strings.c:1073 |
8536 | msgid "IPv6 address did contain a valid port number after the last ':'\n" | 8640 | msgid "IPv6 address did contain a valid port number after the last ':'\n" |
8537 | msgstr "" | 8641 | msgstr "" |
8538 | 8642 | ||
8539 | #: src/util/strings.c:1055 | 8643 | #: src/util/strings.c:1082 |
8540 | #, c-format | 8644 | #, c-format |
8541 | msgid "Invalid IPv6 address `%s': %s\n" | 8645 | msgid "Invalid IPv6 address `%s': %s\n" |
8542 | msgstr "" | 8646 | msgstr "" |
8543 | 8647 | ||
8544 | #: src/util/strings.c:1237 src/util/strings.c:1248 | 8648 | #: src/util/strings.c:1264 src/util/strings.c:1275 |
8545 | msgid "Port not in range\n" | 8649 | msgid "Port not in range\n" |
8546 | msgstr "" | 8650 | msgstr "" |
8547 | 8651 | ||
8548 | #: src/util/strings.c:1257 | 8652 | #: src/util/strings.c:1284 |
8549 | #, c-format | 8653 | #, c-format |
8550 | msgid "Malformed port policy `%s'\n" | 8654 | msgid "Malformed port policy `%s'\n" |
8551 | msgstr "" | 8655 | msgstr "" |
8552 | 8656 | ||
8553 | #: src/util/strings.c:1328 src/util/strings.c:1357 src/util/strings.c:1404 | 8657 | #: src/util/strings.c:1355 src/util/strings.c:1384 src/util/strings.c:1431 |
8554 | #: src/util/strings.c:1424 | 8658 | #: src/util/strings.c:1451 |
8555 | #, c-format | 8659 | #, c-format |
8556 | msgid "Invalid format for IP: `%s'\n" | 8660 | msgid "Invalid format for IP: `%s'\n" |
8557 | msgstr "" | 8661 | msgstr "" |
8558 | 8662 | ||
8559 | #: src/util/strings.c:1382 | 8663 | #: src/util/strings.c:1409 |
8560 | #, c-format | 8664 | #, c-format |
8561 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." | 8665 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." |
8562 | msgstr "" | 8666 | msgstr "" |
8563 | 8667 | ||
8564 | #: src/util/strings.c:1433 | 8668 | #: src/util/strings.c:1460 |
8565 | #, c-format | 8669 | #, c-format |
8566 | msgid "Invalid format: `%s'\n" | 8670 | msgid "Invalid format: `%s'\n" |
8567 | msgstr "" | 8671 | msgstr "" |
8568 | 8672 | ||
8569 | #: src/util/strings.c:1475 | 8673 | #: src/util/strings.c:1502 |
8570 | #, c-format | 8674 | #, c-format |
8571 | msgid "Invalid network notation (does not end with ';': `%s')\n" | 8675 | msgid "Invalid network notation (does not end with ';': `%s')\n" |
8572 | msgstr "" | 8676 | msgstr "" |
8573 | 8677 | ||
8574 | #: src/util/strings.c:1525 | 8678 | #: src/util/strings.c:1552 |
8575 | #, c-format | 8679 | #, c-format |
8576 | msgid "Wrong format `%s' for netmask\n" | 8680 | msgid "Wrong format `%s' for netmask\n" |
8577 | msgstr "" | 8681 | msgstr "" |
8578 | 8682 | ||
8579 | #: src/util/strings.c:1556 | 8683 | #: src/util/strings.c:1583 |
8580 | #, c-format | 8684 | #, c-format |
8581 | msgid "Wrong format `%s' for network\n" | 8685 | msgid "Wrong format `%s' for network\n" |
8582 | msgstr "" | 8686 | msgstr "" |
8583 | 8687 | ||
8584 | #: src/util/time.c:863 src/util/time.c:891 | 8688 | #: src/util/time.c:870 src/util/time.c:898 |
8585 | #, c-format | 8689 | #, c-format |
8586 | msgid "Failed to map `%s', cannot assure monotonic time!\n" | 8690 | msgid "Failed to map `%s', cannot assure monotonic time!\n" |
8587 | msgstr "" | 8691 | msgstr "" |
8588 | 8692 | ||
8589 | #: src/util/time.c:899 | 8693 | #: src/util/time.c:906 |
8590 | #, c-format | 8694 | #, c-format |
8591 | msgid "" | 8695 | msgid "" |
8592 | "Failed to setup monotonic time file `%s', cannot assure monotonic time!\n" | 8696 | "Failed to setup monotonic time file `%s', cannot assure monotonic time!\n" |
@@ -8760,11 +8864,18 @@ msgstr "" | |||
8760 | msgid "Setup tunnels via VPN." | 8864 | msgid "Setup tunnels via VPN." |
8761 | msgstr "" | 8865 | msgstr "" |
8762 | 8866 | ||
8763 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:418 | 8867 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:397 |
8764 | #: src/zonemaster/gnunet-service-zonemaster.c:847 | 8868 | #: src/zonemaster/gnunet-service-zonemaster.c:832 |
8765 | msgid "Failed to connect to the namestore!\n" | 8869 | msgid "Failed to connect to the namestore!\n" |
8766 | msgstr "" | 8870 | msgstr "" |
8767 | 8871 | ||
8872 | #~ msgid "# items stored" | ||
8873 | #~ msgstr "# elementi memorizzati" | ||
8874 | |||
8875 | #, fuzzy | ||
8876 | #~ msgid "# proximity search requests received" | ||
8877 | #~ msgstr "# richieste GET ricevute" | ||
8878 | |||
8768 | #, fuzzy | 8879 | #, fuzzy |
8769 | #~ msgid "# requests for random value received" | 8880 | #~ msgid "# requests for random value received" |
8770 | #~ msgstr "# richieste GET ricevute" | 8881 | #~ msgstr "# richieste GET ricevute" |
@@ -6,7 +6,7 @@ msgid "" | |||
6 | msgstr "" | 6 | msgstr "" |
7 | "Project-Id-Version: gnunet-0.10.1\n" | 7 | "Project-Id-Version: gnunet-0.10.1\n" |
8 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" | 8 | "Report-Msgid-Bugs-To: gnunet-developers@mail.gnu.org\n" |
9 | "POT-Creation-Date: 2022-01-10 15:13+0100\n" | 9 | "POT-Creation-Date: 2022-03-04 22:23+0100\n" |
10 | "PO-Revision-Date: 2020-10-23 18:39+0200\n" | 10 | "PO-Revision-Date: 2020-10-23 18:39+0200\n" |
11 | "Last-Translator: МироÑлав Ðиколић <miroslavnikolic@rocketmail.com>\n" | 11 | "Last-Translator: МироÑлав Ðиколић <miroslavnikolic@rocketmail.com>\n" |
12 | "Language-Team: Serbian <(nothing)>\n" | 12 | "Language-Team: Serbian <(nothing)>\n" |
@@ -18,7 +18,7 @@ msgstr "" | |||
18 | "%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n" | 18 | "%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2);\n" |
19 | "X-Bugs: Report translation errors to the Language-Team address.\n" | 19 | "X-Bugs: Report translation errors to the Language-Team address.\n" |
20 | 20 | ||
21 | #: src/abd/gnunet-abd.c:392 src/namestore/gnunet-namestore.c:1304 | 21 | #: src/abd/gnunet-abd.c:392 src/namestore/gnunet-namestore.c:1254 |
22 | #, c-format | 22 | #, c-format |
23 | msgid "Ego `%s' not known to identity service\n" | 23 | msgid "Ego `%s' not known to identity service\n" |
24 | msgstr "Его „%s“ није познат уÑлузи идентитета\n" | 24 | msgstr "Его „%s“ није познат уÑлузи идентитета\n" |
@@ -30,7 +30,7 @@ msgstr "Јавни кључ „%s“ није добро оформљен\n" | |||
30 | 30 | ||
31 | #: src/abd/gnunet-abd.c:558 src/abd/gnunet-service-abd.c:1751 | 31 | #: src/abd/gnunet-abd.c:558 src/abd/gnunet-service-abd.c:1751 |
32 | #: src/namestore/gnunet-namestore-fcfsd.c:1080 | 32 | #: src/namestore/gnunet-namestore-fcfsd.c:1080 |
33 | #: src/namestore/gnunet-namestore.c:1001 | 33 | #: src/namestore/gnunet-namestore.c:951 |
34 | #, c-format | 34 | #, c-format |
35 | msgid "Failed to connect to namestore\n" | 35 | msgid "Failed to connect to namestore\n" |
36 | msgstr "ÐиÑам уÑпео да Ñе повежем Ñа Ñмештајем назива\n" | 36 | msgstr "ÐиÑам уÑпео да Ñе повежем Ñа Ñмештајем назива\n" |
@@ -628,7 +628,7 @@ msgstr "опширан излаз (укључује ÑвојÑтва ÐТС ад | |||
628 | msgid "Print information about ATS state" | 628 | msgid "Print information about ATS state" |
629 | msgstr "ИÑпиÑује податке о ÐТС Ñтању" | 629 | msgstr "ИÑпиÑује податке о ÐТС Ñтању" |
630 | 630 | ||
631 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | 631 | #: src/ats/gnunet-ats-solver-eval.c:2993 src/ats/gnunet-ats-solver-eval.c:3045 |
632 | #, c-format | 632 | #, c-format |
633 | msgid "" | 633 | msgid "" |
634 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | 634 | "Could not load quota for network `%s': `%s', assigning default bandwidth " |
@@ -637,7 +637,7 @@ msgstr "" | |||
637 | "Ðе могу да учитам квоту за мрежу „%s“: „%s“, додељујем оÑновни пропуÑни " | 637 | "Ðе могу да учитам квоту за мрежу „%s“: „%s“, додељујем оÑновни пропуÑни " |
638 | "опÑег %llu\n" | 638 | "опÑег %llu\n" |
639 | 639 | ||
640 | #: src/ats/gnunet-ats-solver-eval.c:3011 | 640 | #: src/ats/gnunet-ats-solver-eval.c:3012 |
641 | #, c-format | 641 | #, c-format |
642 | msgid "" | 642 | msgid "" |
643 | "No outbound quota configured for network `%s', assigning default bandwidth " | 643 | "No outbound quota configured for network `%s', assigning default bandwidth " |
@@ -646,7 +646,7 @@ msgstr "" | |||
646 | "Ðема подешене одлазне квоте за мрежу „%s“, додељујем оÑновни пропуÑни опÑег " | 646 | "Ðема подешене одлазне квоте за мрежу „%s“, додељујем оÑновни пропуÑни опÑег " |
647 | "%llu\n" | 647 | "%llu\n" |
648 | 648 | ||
649 | #: src/ats/gnunet-ats-solver-eval.c:3063 | 649 | #: src/ats/gnunet-ats-solver-eval.c:3064 |
650 | #, c-format | 650 | #, c-format |
651 | msgid "" | 651 | msgid "" |
652 | "No outbound quota configure for network `%s', assigning default bandwidth " | 652 | "No outbound quota configure for network `%s', assigning default bandwidth " |
@@ -655,23 +655,23 @@ msgstr "" | |||
655 | "Ðије подешена одлазна квота за мрежу „%s“, додељујем оÑновни пропуÑни опÑег " | 655 | "Ðије подешена одлазна квота за мрежу „%s“, додељујем оÑновни пропуÑни опÑег " |
656 | "%llu\n" | 656 | "%llu\n" |
657 | 657 | ||
658 | #: src/ats/gnunet-ats-solver-eval.c:3552 | 658 | #: src/ats/gnunet-ats-solver-eval.c:3553 |
659 | msgid "solver to use" | 659 | msgid "solver to use" |
660 | msgstr "решавач за коришћење" | 660 | msgstr "решавач за коришћење" |
661 | 661 | ||
662 | #: src/ats/gnunet-ats-solver-eval.c:3557 | 662 | #: src/ats/gnunet-ats-solver-eval.c:3558 |
663 | msgid "experiment to use" | 663 | msgid "experiment to use" |
664 | msgstr "екÑперимент за коришћење" | 664 | msgstr "екÑперимент за коришћење" |
665 | 665 | ||
666 | #: src/ats/gnunet-ats-solver-eval.c:3564 | 666 | #: src/ats/gnunet-ats-solver-eval.c:3565 |
667 | msgid "print logging" | 667 | msgid "print logging" |
668 | msgstr "иÑпиÑује дневничење" | 668 | msgstr "иÑпиÑује дневничење" |
669 | 669 | ||
670 | #: src/ats/gnunet-ats-solver-eval.c:3569 | 670 | #: src/ats/gnunet-ats-solver-eval.c:3570 |
671 | msgid "save logging to disk" | 671 | msgid "save logging to disk" |
672 | msgstr "" | 672 | msgstr "" |
673 | 673 | ||
674 | #: src/ats/gnunet-ats-solver-eval.c:3574 | 674 | #: src/ats/gnunet-ats-solver-eval.c:3575 |
675 | msgid "disable normalization" | 675 | msgid "disable normalization" |
676 | msgstr "" | 676 | msgstr "" |
677 | 677 | ||
@@ -1560,39 +1560,7 @@ msgstr "# мапе врÑте Ñу примљене" | |||
1560 | msgid "# updates to my type map" | 1560 | msgid "# updates to my type map" |
1561 | msgstr "# ажурирања за моју мапу врÑте" | 1561 | msgstr "# ажурирања за моју мапу врÑте" |
1562 | 1562 | ||
1563 | #: src/datacache/datacache.c:117 src/datacache/datacache.c:275 | 1563 | #: src/datacache/plugin_datacache_heap.c:555 |
1564 | #: src/datastore/gnunet-service-datastore.c:743 | ||
1565 | msgid "# bytes stored" | ||
1566 | msgstr "# бајтови Ñу Ñмештени" | ||
1567 | |||
1568 | #: src/datacache/datacache.c:121 src/datacache/datacache.c:279 | ||
1569 | msgid "# items stored" | ||
1570 | msgstr "# Ñтавке Ñу Ñмештене" | ||
1571 | |||
1572 | #: src/datacache/datacache.c:185 | ||
1573 | #, c-format | ||
1574 | msgid "Loading `%s' datacache plugin\n" | ||
1575 | msgstr "Учитавам прикључак „%s“ оÑтаве података\n" | ||
1576 | |||
1577 | #: src/datacache/datacache.c:203 | ||
1578 | #, c-format | ||
1579 | msgid "Failed to load datacache plugin for `%s'\n" | ||
1580 | msgstr "ÐиÑам уÑпео да учитам прикључак оÑтаве података за „%s“\n" | ||
1581 | |||
1582 | #: src/datacache/datacache.c:297 | ||
1583 | msgid "# requests received" | ||
1584 | msgstr "# захтеви Ñу примљени" | ||
1585 | |||
1586 | #: src/datacache/datacache.c:308 | ||
1587 | msgid "# requests filtered by bloom filter" | ||
1588 | msgstr "# захтеви Ñу филтрирани блум филтером" | ||
1589 | |||
1590 | #: src/datacache/datacache.c:329 | ||
1591 | #, fuzzy | ||
1592 | msgid "# proximity search requests received" | ||
1593 | msgstr "# претраге клијента Ñу примљене" | ||
1594 | |||
1595 | #: src/datacache/plugin_datacache_heap.c:527 | ||
1596 | msgid "Heap datacache running\n" | 1564 | msgid "Heap datacache running\n" |
1597 | msgstr "ОÑтава података Ñкупине ради\n" | 1565 | msgstr "ОÑтава података Ñкупине ради\n" |
1598 | 1566 | ||
@@ -1614,7 +1582,7 @@ msgstr "ОÑтава података Ñкупине ради\n" | |||
1614 | msgid "`%s' failed at %s:%d with error: %s\n" | 1582 | msgid "`%s' failed at %s:%d with error: %s\n" |
1615 | msgstr "„%s“ није уÑпело на %s:%d Ñа грешком: %s\n" | 1583 | msgstr "„%s“ није уÑпело на %s:%d Ñа грешком: %s\n" |
1616 | 1584 | ||
1617 | #: src/datacache/plugin_datacache_sqlite.c:693 | 1585 | #: src/datacache/plugin_datacache_sqlite.c:723 |
1618 | #: src/datastore/plugin_datastore_sqlite.c:531 | 1586 | #: src/datastore/plugin_datastore_sqlite.c:531 |
1619 | #: src/namecache/plugin_namecache_sqlite.c:237 | 1587 | #: src/namecache/plugin_namecache_sqlite.c:237 |
1620 | #: src/namestore/plugin_namestore_sqlite.c:273 | 1588 | #: src/namestore/plugin_namestore_sqlite.c:273 |
@@ -1804,6 +1772,10 @@ msgstr "# је резервиÑано" | |||
1804 | msgid "Could not find matching reservation" | 1772 | msgid "Could not find matching reservation" |
1805 | msgstr "Ðе могу да нађем одговарајућу резервацију" | 1773 | msgstr "Ðе могу да нађем одговарајућу резервацију" |
1806 | 1774 | ||
1775 | #: src/datastore/gnunet-service-datastore.c:743 | ||
1776 | msgid "# bytes stored" | ||
1777 | msgstr "# бајтови Ñу Ñмештени" | ||
1778 | |||
1807 | #: src/datastore/gnunet-service-datastore.c:758 | 1779 | #: src/datastore/gnunet-service-datastore.c:758 |
1808 | #, c-format | 1780 | #, c-format |
1809 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" | 1781 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" |
@@ -1990,7 +1962,7 @@ msgstr "" | |||
1990 | 1962 | ||
1991 | #: src/datastore/plugin_datastore_sqlite.c:1337 | 1963 | #: src/datastore/plugin_datastore_sqlite.c:1337 |
1992 | #: src/namecache/plugin_namecache_sqlite.c:564 | 1964 | #: src/namecache/plugin_namecache_sqlite.c:564 |
1993 | #: src/namestore/plugin_namestore_sqlite.c:765 | 1965 | #: src/namestore/plugin_namestore_sqlite.c:775 |
1994 | msgid "Sqlite database running\n" | 1966 | msgid "Sqlite database running\n" |
1995 | msgstr "База података Скулајта ради\n" | 1967 | msgstr "База података Скулајта ради\n" |
1996 | 1968 | ||
@@ -1998,7 +1970,7 @@ msgstr "База података Скулајта ради\n" | |||
1998 | msgid "Template database running\n" | 1970 | msgid "Template database running\n" |
1999 | msgstr "База података шаблона ради\n" | 1971 | msgstr "База података шаблона ради\n" |
2000 | 1972 | ||
2001 | #: src/dht/gnunet-dht-get.c:159 | 1973 | #: src/dht/gnunet-dht-get.c:164 |
2002 | #, c-format | 1974 | #, c-format |
2003 | msgid "" | 1975 | msgid "" |
2004 | "Result %d, type %d:\n" | 1976 | "Result %d, type %d:\n" |
@@ -2007,51 +1979,62 @@ msgstr "" | |||
2007 | "Резултат %d, врÑта %d:\n" | 1979 | "Резултат %d, врÑта %d:\n" |
2008 | "%.*s\n" | 1980 | "%.*s\n" |
2009 | 1981 | ||
2010 | #: src/dht/gnunet-dht-get.c:160 | 1982 | #: src/dht/gnunet-dht-get.c:165 |
2011 | #, fuzzy, c-format | 1983 | #, fuzzy, c-format |
2012 | msgid "Result %d, type %d:\n" | 1984 | msgid "Result %d, type %d:\n" |
2013 | msgstr "" | 1985 | msgstr "" |
2014 | "Резултат %d, врÑта %d:\n" | 1986 | "Резултат %d, врÑта %d:\n" |
2015 | "%.*s\n" | 1987 | "%.*s\n" |
2016 | 1988 | ||
2017 | #: src/dht/gnunet-dht-get.c:209 | 1989 | #: src/dht/gnunet-dht-get.c:215 |
2018 | msgid "Must provide key for DHT GET!\n" | 1990 | msgid "Must provide key for DHT GET!\n" |
2019 | msgstr "Морате доÑтавити кључ за ДХТ ДОБÐВИ!\n" | 1991 | msgstr "Морате доÑтавити кључ за ДХТ ДОБÐВИ!\n" |
2020 | 1992 | ||
2021 | #: src/dht/gnunet-dht-get.c:217 src/dht/gnunet-dht-monitor.c:255 | 1993 | #: src/dht/gnunet-dht-get.c:223 src/dht/gnunet-dht-hello.c:119 |
1994 | #: src/dht/gnunet-dht-monitor.c:255 | ||
1995 | #, c-format | ||
2022 | msgid "Failed to connect to DHT service!\n" | 1996 | msgid "Failed to connect to DHT service!\n" |
2023 | msgstr "ÐиÑам уÑпео да Ñе повежем Ñа „DHT“ уÑлугом!\n" | 1997 | msgstr "ÐиÑам уÑпео да Ñе повежем Ñа „DHT“ уÑлугом!\n" |
2024 | 1998 | ||
2025 | #: src/dht/gnunet-dht-get.c:227 | 1999 | #: src/dht/gnunet-dht-get.c:233 |
2026 | #, fuzzy | 2000 | #, fuzzy |
2027 | msgid "Issuing DHT GET with key" | 2001 | msgid "Issuing DHT GET with key" |
2028 | msgstr "Издајем ДХТ ДОБÐВИ Ñа кључем" | 2002 | msgstr "Издајем ДХТ ДОБÐВИ Ñа кључем" |
2029 | 2003 | ||
2030 | #: src/dht/gnunet-dht-get.c:260 src/dht/gnunet-dht-monitor.c:302 | 2004 | #: src/dht/gnunet-dht-get.c:269 src/dht/gnunet-dht-monitor.c:302 |
2031 | #: src/dht/gnunet-dht-put.c:200 | 2005 | #: src/dht/gnunet-dht-put.c:200 |
2032 | msgid "the query key" | 2006 | msgid "the query key" |
2033 | msgstr "кључ упита" | 2007 | msgstr "кључ упита" |
2034 | 2008 | ||
2035 | #: src/dht/gnunet-dht-get.c:266 | 2009 | #: src/dht/gnunet-dht-get.c:275 |
2036 | msgid "how many parallel requests (replicas) to create" | 2010 | msgid "how many parallel requests (replicas) to create" |
2037 | msgstr "колико паралелних захтева (реплика) да направи" | 2011 | msgstr "колико паралелних захтева (реплика) да направи" |
2038 | 2012 | ||
2039 | #: src/dht/gnunet-dht-get.c:272 src/dht/gnunet-dht-monitor.c:308 | 2013 | #: src/dht/gnunet-dht-get.c:280 src/dht/gnunet-dht-put.c:217 |
2014 | #, fuzzy | ||
2015 | msgid "use DHT's record route option" | ||
2016 | msgstr "кориÑти опцију ДХТ-а демултиплекÑирај Ñвуда" | ||
2017 | |||
2018 | #: src/dht/gnunet-dht-get.c:286 src/dht/gnunet-dht-monitor.c:308 | ||
2040 | msgid "the type of data to look for" | 2019 | msgid "the type of data to look for" |
2041 | msgstr "врÑта података за тражење" | 2020 | msgstr "врÑта података за тражење" |
2042 | 2021 | ||
2043 | #: src/dht/gnunet-dht-get.c:278 | 2022 | #: src/dht/gnunet-dht-get.c:292 |
2044 | msgid "how long to execute this query before giving up?" | 2023 | msgid "how long to execute this query before giving up?" |
2045 | msgstr "колико дуго да извршава овај упит пре одуÑтајања?" | 2024 | msgstr "колико дуго да извршава овај упит пре одуÑтајања?" |
2046 | 2025 | ||
2047 | #: src/dht/gnunet-dht-get.c:284 src/dht/gnunet-dht-put.c:206 | 2026 | #: src/dht/gnunet-dht-get.c:298 src/dht/gnunet-dht-put.c:206 |
2048 | msgid "use DHT's demultiplex everywhere option" | 2027 | msgid "use DHT's demultiplex everywhere option" |
2049 | msgstr "кориÑти опцију ДХТ-а демултиплекÑирај Ñвуда" | 2028 | msgstr "кориÑти опцију ДХТ-а демултиплекÑирај Ñвуда" |
2050 | 2029 | ||
2051 | #: src/dht/gnunet-dht-get.c:301 | 2030 | #: src/dht/gnunet-dht-get.c:315 |
2052 | msgid "Issue a GET request to the GNUnet DHT, prints results." | 2031 | msgid "Issue a GET request to the GNUnet DHT, prints results." |
2053 | msgstr "Издаје ДОБÐВИ захтев ГÐУнет ДХТ-у, иÑпиÑује резултате." | 2032 | msgstr "Издаје ДОБÐВИ захтев ГÐУнет ДХТ-у, иÑпиÑује резултате." |
2054 | 2033 | ||
2034 | #: src/dht/gnunet-dht-hello.c:166 | ||
2035 | msgid "Obtain HELLO from DHT or provide HELLO to DHT for bootstrapping" | ||
2036 | msgstr "" | ||
2037 | |||
2055 | #: src/dht/gnunet-dht-monitor.c:315 | 2038 | #: src/dht/gnunet-dht-monitor.c:315 |
2056 | msgid "how long should the monitor command run" | 2039 | msgid "how long should the monitor command run" |
2057 | msgstr "колико дуго треба да ради наредба праћења" | 2040 | msgstr "колико дуго треба да ради наредба праћења" |
@@ -2091,11 +2074,6 @@ msgstr "колико ће дуго да држи овај ÑƒÐ½Ð¾Ñ Ñƒ дхт-у | |||
2091 | msgid "how many replicas to create" | 2074 | msgid "how many replicas to create" |
2092 | msgstr "број реплика за Ñтварање" | 2075 | msgstr "број реплика за Ñтварање" |
2093 | 2076 | ||
2094 | #: src/dht/gnunet-dht-put.c:217 | ||
2095 | #, fuzzy | ||
2096 | msgid "use DHT's record route option" | ||
2097 | msgstr "кориÑти опцију ДХТ-а демултиплекÑирај Ñвуда" | ||
2098 | |||
2099 | #: src/dht/gnunet-dht-put.c:223 | 2077 | #: src/dht/gnunet-dht-put.c:223 |
2100 | msgid "the type to insert data as" | 2078 | msgid "the type to insert data as" |
2101 | msgstr "врÑта за уметање података" | 2079 | msgstr "врÑта за уметање података" |
@@ -2153,17 +2131,17 @@ msgstr "" | |||
2153 | msgid "Measure quality and performance of the DHT service." | 2131 | msgid "Measure quality and performance of the DHT service." |
2154 | msgstr "Мери квалитет и учинковитоÑÑ‚ ÐСЕ уÑлуге." | 2132 | msgstr "Мери квалитет и учинковитоÑÑ‚ ÐСЕ уÑлуге." |
2155 | 2133 | ||
2156 | #: src/dht/plugin_block_dht.c:328 | 2134 | #: src/dht/plugin_block_dht.c:404 |
2157 | #, c-format | 2135 | #, c-format |
2158 | msgid "Block not of type %u\n" | 2136 | msgid "Block not of type %u\n" |
2159 | msgstr "Блок није врÑте %u\n" | 2137 | msgstr "Блок није врÑте %u\n" |
2160 | 2138 | ||
2161 | #: src/dht/plugin_block_dht.c:337 | 2139 | #: src/dht/plugin_block_dht.c:413 |
2162 | #, fuzzy, c-format | 2140 | #, fuzzy, c-format |
2163 | msgid "Size mismatch for block with type %u\n" | 2141 | msgid "Size mismatch for block with type %u\n" |
2164 | msgstr "Величин не одговара за блок\n" | 2142 | msgstr "Величин не одговара за блок\n" |
2165 | 2143 | ||
2166 | #: src/dht/plugin_block_dht.c:348 | 2144 | #: src/dht/plugin_block_dht.c:424 |
2167 | #, c-format | 2145 | #, c-format |
2168 | msgid "Block of type %u is malformed\n" | 2146 | msgid "Block of type %u is malformed\n" |
2169 | msgstr "Блок врÑте %u је лош\n" | 2147 | msgstr "Блок врÑте %u је лош\n" |
@@ -2902,20 +2880,20 @@ msgstr "SKS УРИ је лоше (не могу да обрадим време Р| |||
2902 | msgid "LOC URI malformed (signature failed validation)" | 2880 | msgid "LOC URI malformed (signature failed validation)" |
2903 | msgstr "SKS УРИ је лоше (потврђивање потпиÑа није уÑпело)" | 2881 | msgstr "SKS УРИ је лоше (потврђивање потпиÑа није уÑпело)" |
2904 | 2882 | ||
2905 | #: src/fs/fs_uri.c:653 | 2883 | #: src/fs/fs_uri.c:652 |
2906 | #, fuzzy | 2884 | #, fuzzy |
2907 | msgid "invalid argument" | 2885 | msgid "invalid argument" |
2908 | msgstr "ÐеиÑправан аргумент „%s“\n" | 2886 | msgstr "ÐеиÑправан аргумент „%s“\n" |
2909 | 2887 | ||
2910 | #: src/fs/fs_uri.c:665 | 2888 | #: src/fs/fs_uri.c:671 |
2911 | msgid "Unrecognized URI type" | 2889 | msgid "Unrecognized URI type" |
2912 | msgstr "Ðепозната УРИ врÑта" | 2890 | msgstr "Ðепозната УРИ врÑта" |
2913 | 2891 | ||
2914 | #: src/fs/fs_uri.c:1071 src/fs/fs_uri.c:1098 | 2892 | #: src/fs/fs_uri.c:1075 src/fs/fs_uri.c:1102 |
2915 | msgid "No keywords specified!\n" | 2893 | msgid "No keywords specified!\n" |
2916 | msgstr "ÐиÑу наведене речи кључа!\n" | 2894 | msgstr "ÐиÑу наведене речи кључа!\n" |
2917 | 2895 | ||
2918 | #: src/fs/fs_uri.c:1104 | 2896 | #: src/fs/fs_uri.c:1108 |
2919 | msgid "Number of double-quotes not balanced!\n" | 2897 | msgid "Number of double-quotes not balanced!\n" |
2920 | msgstr "Број двоÑтруких квота које ниÑу уравнотежене!\n" | 2898 | msgstr "Број двоÑтруких квота које ниÑу уравнотежене!\n" |
2921 | 2899 | ||
@@ -3043,7 +3021,7 @@ msgid "Downloading `%s' done (%s/s).\n" | |||
3043 | msgstr "Преузимање „%s“ је готово (%s/Ñек).\n" | 3021 | msgstr "Преузимање „%s“ је готово (%s/Ñек).\n" |
3044 | 3022 | ||
3045 | #: src/fs/gnunet-download.c:206 src/fs/gnunet-publish.c:299 | 3023 | #: src/fs/gnunet-download.c:206 src/fs/gnunet-publish.c:299 |
3046 | #: src/fs/gnunet-search.c:229 src/fs/gnunet-unindex.c:117 | 3024 | #: src/fs/gnunet-search.c:538 src/fs/gnunet-unindex.c:117 |
3047 | #, c-format | 3025 | #, c-format |
3048 | msgid "Unexpected status: %d\n" | 3026 | msgid "Unexpected status: %d\n" |
3049 | msgstr "Ðеочекивано Ñтање: %d\n" | 3027 | msgstr "Ðеочекивано Ñтање: %d\n" |
@@ -3066,12 +3044,12 @@ msgid "Target filename must be specified.\n" | |||
3066 | msgstr "Ðазив циљне датотеке мора бити наведен.\n" | 3044 | msgstr "Ðазив циљне датотеке мора бити наведен.\n" |
3067 | 3045 | ||
3068 | #: src/fs/gnunet-download.c:271 src/fs/gnunet-publish.c:869 | 3046 | #: src/fs/gnunet-download.c:271 src/fs/gnunet-publish.c:869 |
3069 | #: src/fs/gnunet-search.c:294 src/fs/gnunet-unindex.c:154 | 3047 | #: src/fs/gnunet-unindex.c:154 |
3070 | #, c-format | 3048 | #, c-format |
3071 | msgid "Could not initialize `%s' subsystem.\n" | 3049 | msgid "Could not initialize `%s' subsystem.\n" |
3072 | msgstr "Ðе могу да покренем „%s“ ÑубÑиÑтем.\n" | 3050 | msgstr "Ðе могу да покренем „%s“ ÑубÑиÑтем.\n" |
3073 | 3051 | ||
3074 | #: src/fs/gnunet-download.c:318 src/fs/gnunet-search.c:334 | 3052 | #: src/fs/gnunet-download.c:318 |
3075 | msgid "set the desired LEVEL of receiver-anonymity" | 3053 | msgid "set the desired LEVEL of receiver-anonymity" |
3076 | msgstr "поÑтавља жељени ÐИВО анонимноÑти примаоца" | 3054 | msgstr "поÑтавља жељени ÐИВО анонимноÑти примаоца" |
3077 | 3055 | ||
@@ -3079,7 +3057,7 @@ msgstr "поÑтавља жељени ÐИВО анонимноÑти прима | |||
3079 | msgid "delete incomplete downloads (when aborted with CTRL-C)" | 3057 | msgid "delete incomplete downloads (when aborted with CTRL-C)" |
3080 | msgstr "брише недовршена преузимања (када Ñе прекине Ñа КТРЛ-Ц)" | 3058 | msgstr "брише недовршена преузимања (када Ñе прекине Ñа КТРЛ-Ц)" |
3081 | 3059 | ||
3082 | #: src/fs/gnunet-download.c:330 src/fs/gnunet-search.c:339 | 3060 | #: src/fs/gnunet-download.c:330 src/fs/gnunet-search.c:740 |
3083 | msgid "only search the local peer (no P2P network search)" | 3061 | msgid "only search the local peer (no P2P network search)" |
3084 | msgstr "тражи Ñамо локалног парњака (без претраге П2П мреже)" | 3062 | msgstr "тражи Ñамо локалног парњака (без претраге П2П мреже)" |
3085 | 3063 | ||
@@ -3338,38 +3316,112 @@ msgstr "" | |||
3338 | msgid "Publish a file or directory on GNUnet" | 3316 | msgid "Publish a file or directory on GNUnet" |
3339 | msgstr "Објављује датотеку или директоријум на ГÐУнет-у" | 3317 | msgstr "Објављује датотеку или директоријум на ГÐУнет-у" |
3340 | 3318 | ||
3341 | #: src/fs/gnunet-search.c:130 | 3319 | #: src/fs/gnunet-search.c:441 |
3342 | #, c-format | 3320 | #, c-format |
3343 | msgid "Failed to write directory with search results to `%s'\n" | 3321 | msgid "Failed to write directory with search results to `%s'\n" |
3344 | msgstr "ÐиÑам уÑпео да пишем директоријум Ñа резултатима претраге за „%s“\n" | 3322 | msgstr "ÐиÑам уÑпео да пишем директоријум Ñа резултатима претраге за „%s“\n" |
3345 | 3323 | ||
3346 | #: src/fs/gnunet-search.c:219 | 3324 | #: src/fs/gnunet-search.c:527 |
3347 | #, c-format | 3325 | #, c-format |
3348 | msgid "Error searching: %s.\n" | 3326 | msgid "Error searching: %s.\n" |
3349 | msgstr "Грешка претраге: %s.\n" | 3327 | msgstr "Грешка претраге: %s.\n" |
3350 | 3328 | ||
3351 | #: src/fs/gnunet-search.c:281 | 3329 | #: src/fs/gnunet-search.c:587 |
3330 | #, c-format | ||
3331 | msgid "Conflicting options --bookmark-only and --silent.\n" | ||
3332 | msgstr "" | ||
3333 | |||
3334 | #: src/fs/gnunet-search.c:594 | ||
3335 | #, c-format | ||
3336 | msgid "Conflicting options --bookmark-only and --output.\n" | ||
3337 | msgstr "" | ||
3338 | |||
3339 | #: src/fs/gnunet-search.c:600 | ||
3340 | #, c-format | ||
3341 | msgid "An output file is mandatory for silent mode.\n" | ||
3342 | msgstr "" | ||
3343 | |||
3344 | #: src/fs/gnunet-search.c:621 | ||
3352 | msgid "Could not create keyword URI from arguments.\n" | 3345 | msgid "Could not create keyword URI from arguments.\n" |
3353 | msgstr "Ðе могу да Ñтворим УРИ кључне речи из аргумената.\n" | 3346 | msgstr "Ðе могу да Ñтворим УРИ кључне речи из аргумената.\n" |
3354 | 3347 | ||
3355 | #: src/fs/gnunet-search.c:308 | 3348 | #: src/fs/gnunet-search.c:629 |
3349 | msgid "" | ||
3350 | "Invalid URI. Valid URIs for searching are keyword query URIs\n" | ||
3351 | "(\"gnunet://fs/ksk/...\") and namespace content URIs (\"gnunet://fs/sks/..." | ||
3352 | "\").\n" | ||
3353 | msgstr "" | ||
3354 | |||
3355 | #: src/fs/gnunet-search.c:654 | ||
3356 | #, fuzzy, c-format | ||
3357 | msgid "Could not initialize the `%s` subsystem.\n" | ||
3358 | msgstr "Ðе могу да покренем „%s“ ÑубÑиÑтем.\n" | ||
3359 | |||
3360 | #: src/fs/gnunet-search.c:668 | ||
3356 | msgid "Could not start searching.\n" | 3361 | msgid "Could not start searching.\n" |
3357 | msgstr "Ðе могу да покренем претрагу.\n" | 3362 | msgstr "Ðе могу да покренем претрагу.\n" |
3358 | 3363 | ||
3359 | #: src/fs/gnunet-search.c:345 | 3364 | #: src/fs/gnunet-search.c:694 |
3360 | msgid "write search results to file starting with PREFIX" | 3365 | #, fuzzy |
3361 | msgstr "пише резултате претраге у датотеку која почиње Ñа ПРЕФИКСОМ" | 3366 | msgid "set the desired LEVEL of receiver-anonymity (default: 1)" |
3367 | msgstr "поÑтавља жељени ÐИВО анонимноÑти примаоца" | ||
3368 | |||
3369 | #: src/fs/gnunet-search.c:700 | ||
3370 | msgid "do not search, print only the URI that points to this search" | ||
3371 | msgstr "" | ||
3372 | |||
3373 | #: src/fs/gnunet-search.c:707 | ||
3374 | msgid "" | ||
3375 | "write search results for directories according to FORMAT; accepted " | ||
3376 | "placeholders are: %a, %f, %j, %l, %m, %n, %s; defaults to the value of --" | ||
3377 | "printf when omitted or to `" | ||
3378 | msgstr "" | ||
3379 | |||
3380 | #: src/fs/gnunet-search.c:717 | ||
3381 | msgid "" | ||
3382 | "write search results according to FORMAT; accepted placeholders are: %a, %f, " | ||
3383 | "%j, %l, %m, %n, %s; defaults to `" | ||
3384 | msgstr "" | ||
3362 | 3385 | ||
3363 | #: src/fs/gnunet-search.c:351 | 3386 | #: src/fs/gnunet-search.c:725 |
3364 | msgid "automatically terminate search after DELAY" | 3387 | msgid "" |
3365 | msgstr "ÑамоÑтално окончава претрагу након ЗÐСТОЈÐ" | 3388 | "when the %a or %j placeholders appear in --printf or --dir-printf, list each " |
3389 | "metadata property according to FORMAT; accepted placeholders are: %i, %l, " | ||
3390 | "%n, %p" | ||
3391 | msgstr "" | ||
3366 | 3392 | ||
3367 | #: src/fs/gnunet-search.c:357 | 3393 | #: src/fs/gnunet-search.c:734 |
3368 | msgid "automatically terminate search after VALUE results are found" | 3394 | msgid "automatically terminate search after VALUE results are found" |
3369 | msgstr "ÑамоÑтално окончава претрагу након што Ñу пронађени резултати ВРЕДÐОСТ" | 3395 | msgstr "ÑамоÑтално окончава претрагу након што Ñу пронађени резултати ВРЕДÐОСТ" |
3370 | 3396 | ||
3371 | #: src/fs/gnunet-search.c:371 | 3397 | #: src/fs/gnunet-search.c:746 |
3372 | msgid "Search GNUnet for files that were published on GNUnet" | 3398 | msgid "" |
3399 | "create a GNUnet directory with search results at FILENAME (e.g. `gnunet-" | ||
3400 | "search --output=commons" | ||
3401 | msgstr "" | ||
3402 | |||
3403 | #: src/fs/gnunet-search.c:753 | ||
3404 | msgid "silent mode (requires the --output argument)" | ||
3405 | msgstr "" | ||
3406 | |||
3407 | #: src/fs/gnunet-search.c:759 | ||
3408 | msgid "" | ||
3409 | "automatically terminate search after DELAY; the value given must be a number " | ||
3410 | "followed by a space and a time unit, for example \"500 ms\"; without a unit " | ||
3411 | "it defaults to microseconds - 1000000 = 1 second; if 0 or omitted it means " | ||
3412 | "to wait for CTRL-C" | ||
3413 | msgstr "" | ||
3414 | |||
3415 | #: src/fs/gnunet-search.c:768 | ||
3416 | #, c-format | ||
3417 | msgid "" | ||
3418 | "be verbose (append \"%a\\n\" to the default --printf and --dir-printf " | ||
3419 | "arguments - ignored when these are provided by the user)" | ||
3420 | msgstr "" | ||
3421 | |||
3422 | #: src/fs/gnunet-search.c:781 | ||
3423 | #, fuzzy | ||
3424 | msgid "Search for files that have been published on GNUnet\n" | ||
3373 | msgstr "Претражује ГÐУнет за датотекама које Ñу објављене на ГÐУнет-у" | 3425 | msgstr "Претражује ГÐУнет за датотекама које Ñу објављене на ГÐУнет-у" |
3374 | 3426 | ||
3375 | #: src/fs/gnunet-service-fs.c:371 src/fs/gnunet-service-fs.c:878 | 3427 | #: src/fs/gnunet-service-fs.c:371 src/fs/gnunet-service-fs.c:878 |
@@ -3712,68 +3764,73 @@ msgstr "" | |||
3712 | msgid "Expected a base32-encoded public zone key\n" | 3764 | msgid "Expected a base32-encoded public zone key\n" |
3713 | msgstr "" | 3765 | msgstr "" |
3714 | 3766 | ||
3715 | #: src/gns/gnunet-bcd.c:571 | 3767 | #: src/gns/gnunet-bcd.c:573 |
3716 | #, fuzzy, c-format | 3768 | #, fuzzy, c-format |
3717 | msgid "Invalid port number %u\n" | 3769 | msgid "Invalid port number %u\n" |
3718 | msgstr "ÐеиÑправан број прикључника %llu. Излазим.\n" | 3770 | msgstr "ÐеиÑправан број прикључника %llu. Излазим.\n" |
3719 | 3771 | ||
3720 | #: src/gns/gnunet-bcd.c:612 src/namestore/gnunet-namestore-fcfsd.c:1113 | 3772 | #: src/gns/gnunet-bcd.c:614 src/namestore/gnunet-namestore-fcfsd.c:1113 |
3721 | #, fuzzy | 3773 | #, fuzzy |
3722 | msgid "Unable to set up the daemon\n" | 3774 | msgid "Unable to set up the daemon\n" |
3723 | msgstr "Ðе могу да увезем приватни кључ из датотеке „%s“\n" | 3775 | msgstr "Ðе могу да увезем приватни кључ из датотеке „%s“\n" |
3724 | 3776 | ||
3725 | #: src/gns/gnunet-bcd.c:635 src/namestore/gnunet-namestore-fcfsd.c:987 | 3777 | #: src/gns/gnunet-bcd.c:637 src/namestore/gnunet-namestore-fcfsd.c:987 |
3726 | msgid "Failed to start HTTP server\n" | 3778 | msgid "Failed to start HTTP server\n" |
3727 | msgstr "ÐиÑам уÑпео да покренем ХТТП Ñервер\n" | 3779 | msgstr "ÐиÑам уÑпео да покренем ХТТП Ñервер\n" |
3728 | 3780 | ||
3729 | #: src/gns/gnunet-bcd.c:658 | 3781 | #: src/gns/gnunet-bcd.c:660 |
3730 | #, fuzzy | 3782 | #, fuzzy |
3731 | msgid "Run HTTP server on port PORT (default is 8888)" | 3783 | msgid "Run HTTP server on port PORT (default is 8888)" |
3732 | msgstr "Покрећем ХТТП Ñервер на прикључнику ПРИКЉУЧÐИК (оÑновно је 8888)" | 3784 | msgstr "Покрећем ХТТП Ñервер на прикључнику ПРИКЉУЧÐИК (оÑновно је 8888)" |
3733 | 3785 | ||
3734 | #: src/gns/gnunet-bcd.c:667 | 3786 | #: src/gns/gnunet-bcd.c:669 |
3735 | msgid "GNUnet HTTP server to create business cards" | 3787 | msgid "GNUnet HTTP server to create business cards" |
3736 | msgstr "ГÐУнет ХТТП Ñервер за Ñтварање Ð±Ð¸Ð·Ð½Ð¸Ñ ÐºÐ°Ñ€Ñ‚Ð¸Ñ†Ð°" | 3788 | msgstr "ГÐУнет ХТТП Ñервер за Ñтварање Ð±Ð¸Ð·Ð½Ð¸Ñ ÐºÐ°Ñ€Ñ‚Ð¸Ñ†Ð°" |
3737 | 3789 | ||
3738 | #: src/gns/gnunet-dns2gns.c:241 | 3790 | #: src/gns/gnunet-dns2gns.c:298 |
3739 | msgid "Failed to pack DNS response into UDP packet!\n" | 3791 | msgid "Failed to pack DNS response into UDP packet!\n" |
3740 | msgstr "ÐиÑам уÑпео да упакујем ДÐС одговор у УДП пакет!\n" | 3792 | msgstr "ÐиÑам уÑпео да упакујем ДÐС одговор у УДП пакет!\n" |
3741 | 3793 | ||
3742 | #: src/gns/gnunet-dns2gns.c:315 | 3794 | #: src/gns/gnunet-dns2gns.c:379 |
3743 | #, fuzzy | 3795 | #, fuzzy |
3744 | msgid "Failed to parse DNS response!\n" | 3796 | msgid "Failed to parse DNS response!\n" |
3745 | msgstr "ÐиÑам уÑпео да обрадим ДÐС одговор\n" | 3797 | msgstr "ÐиÑам уÑпео да обрадим ДÐС одговор\n" |
3746 | 3798 | ||
3747 | #: src/gns/gnunet-dns2gns.c:452 | 3799 | #: src/gns/gnunet-dns2gns.c:453 |
3800 | #, fuzzy, c-format | ||
3801 | msgid "VPN returned empty result for `%s'\n" | ||
3802 | msgstr "ÐТС је вратио резултате за %u адреÑе\n" | ||
3803 | |||
3804 | #: src/gns/gnunet-dns2gns.c:655 | ||
3748 | #, c-format | 3805 | #, c-format |
3749 | msgid "Cannot parse DNS request from %s\n" | 3806 | msgid "Cannot parse DNS request from %s\n" |
3750 | msgstr "Ðе могу да обрадим ДÐС захтев од „%s“\n" | 3807 | msgstr "Ðе могу да обрадим ДÐС захтев од „%s“\n" |
3751 | 3808 | ||
3752 | #: src/gns/gnunet-dns2gns.c:468 | 3809 | #: src/gns/gnunet-dns2gns.c:671 |
3753 | #, c-format | 3810 | #, c-format |
3754 | msgid "Received malformed DNS request from %s\n" | 3811 | msgid "Received malformed DNS request from %s\n" |
3755 | msgstr "Примих лош ДÐС захтев од „%s“\n" | 3812 | msgstr "Примих лош ДÐС захтев од „%s“\n" |
3756 | 3813 | ||
3757 | #: src/gns/gnunet-dns2gns.c:476 | 3814 | #: src/gns/gnunet-dns2gns.c:679 |
3758 | #, c-format | 3815 | #, c-format |
3759 | msgid "Received unsupported DNS request from %s\n" | 3816 | msgid "Received unsupported DNS request from %s\n" |
3760 | msgstr "Примих неподржан ДÐС захтев од „%s“\n" | 3817 | msgstr "Примих неподржан ДÐС захтев од „%s“\n" |
3761 | 3818 | ||
3762 | #: src/gns/gnunet-dns2gns.c:637 | 3819 | #: src/gns/gnunet-dns2gns.c:840 |
3763 | msgid "No DNS server specified!\n" | 3820 | msgid "No DNS server specified!\n" |
3764 | msgstr "Ðије наведен ДÐС Ñервер!\n" | 3821 | msgstr "Ðије наведен ДÐС Ñервер!\n" |
3765 | 3822 | ||
3766 | #: src/gns/gnunet-dns2gns.c:786 | 3823 | #: src/gns/gnunet-dns2gns.c:995 |
3767 | msgid "IP of recursive DNS resolver to use (required)" | 3824 | msgid "IP of recursive DNS resolver to use (required)" |
3768 | msgstr "ИП дубинÑког ДÐС решавача за коришћење (потребно)" | 3825 | msgstr "ИП дубинÑког ДÐС решавача за коришћење (потребно)" |
3769 | 3826 | ||
3770 | #: src/gns/gnunet-dns2gns.c:792 | 3827 | #: src/gns/gnunet-dns2gns.c:1001 |
3771 | #, fuzzy | 3828 | #, fuzzy |
3772 | msgid "UDP port to listen on for inbound DNS requests; default: 2853" | 3829 | msgid "UDP port to listen on for inbound DNS requests; default: 2853" |
3773 | msgstr "" | 3830 | msgstr "" |
3774 | "УДП прикључник на коме ће оÑлушкивати за долазним ДÐС захтевима; оÑновно: 53" | 3831 | "УДП прикључник на коме ће оÑлушкивати за долазним ДÐС захтевима; оÑновно: 53" |
3775 | 3832 | ||
3776 | #: src/gns/gnunet-dns2gns.c:809 | 3833 | #: src/gns/gnunet-dns2gns.c:1018 |
3777 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" | 3834 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" |
3778 | msgstr "ПоÑредник ДÐС-до-ГÐС ГÐУнет-а (ДÐС Ñервер)" | 3835 | msgstr "ПоÑредник ДÐС-до-ГÐС ГÐУнет-а (ДÐС Ñервер)" |
3779 | 3836 | ||
@@ -3953,18 +4010,18 @@ msgstr "" | |||
3953 | msgid "GNUnet GNS resolver tool" | 4010 | msgid "GNUnet GNS resolver tool" |
3954 | msgstr "Ðлат ГÐУнет ГÐС решавача" | 4011 | msgstr "Ðлат ГÐУнет ГÐС решавача" |
3955 | 4012 | ||
3956 | #: src/gns/gnunet-service-gns.c:505 | 4013 | #: src/gns/gnunet-service-gns.c:501 |
3957 | #, fuzzy | 4014 | #, fuzzy |
3958 | msgid "Properly base32-encoded public key required" | 4015 | msgid "Properly base32-encoded public key required" |
3959 | msgstr "иÑправан јавни кључ Ñе захтева" | 4016 | msgstr "иÑправан јавни кључ Ñе захтева" |
3960 | 4017 | ||
3961 | #: src/gns/gnunet-service-gns.c:541 | 4018 | #: src/gns/gnunet-service-gns.c:537 |
3962 | msgid "Failed to connect to the namecache!\n" | 4019 | msgid "Failed to connect to the namecache!\n" |
3963 | msgstr "ÐиÑам уÑпео да Ñе повежем Ñа оÑтавом назива!\n" | 4020 | msgstr "ÐиÑам уÑпео да Ñе повежем Ñа оÑтавом назива!\n" |
3964 | 4021 | ||
3965 | #: src/gns/gnunet-service-gns.c:560 | 4022 | #: src/gns/gnunet-service-gns.c:556 |
3966 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:442 | 4023 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:421 |
3967 | #: src/zonemaster/gnunet-service-zonemaster.c:885 | 4024 | #: src/zonemaster/gnunet-service-zonemaster.c:870 |
3968 | msgid "Could not connect to DHT!\n" | 4025 | msgid "Could not connect to DHT!\n" |
3969 | msgstr "Ðе могу да Ñе повежем на ДХТ!\n" | 4026 | msgstr "Ðе могу да Ñе повежем на ДХТ!\n" |
3970 | 4027 | ||
@@ -3976,94 +4033,97 @@ msgstr "Грешка претварања ГÐС одговора у ДÐС од | |||
3976 | msgid "Failed to connect to the DNS service!\n" | 4033 | msgid "Failed to connect to the DNS service!\n" |
3977 | msgstr "ÐиÑам уÑпео да Ñе повежем Ñа ДÐС уÑлугом!\n" | 4034 | msgstr "ÐиÑам уÑпео да Ñе повежем Ñа ДÐС уÑлугом!\n" |
3978 | 4035 | ||
3979 | #: src/gns/gnunet-service-gns_resolver.c:706 | 4036 | #: src/gns/gnunet-service-gns_resolver.c:659 |
3980 | #, c-format | 4037 | #, c-format |
3981 | msgid "Protocol `%s' unknown, skipping labels.\n" | 4038 | msgid "Protocol `%s' unknown, skipping labels.\n" |
3982 | msgstr "" | 4039 | msgstr "" |
3983 | 4040 | ||
3984 | #: src/gns/gnunet-service-gns_resolver.c:718 | 4041 | #: src/gns/gnunet-service-gns_resolver.c:671 |
3985 | #, c-format | 4042 | #, c-format |
3986 | msgid "Service `%s' unknown for protocol `%s', trying as number.\n" | 4043 | msgid "Service `%s' unknown for protocol `%s', trying as number.\n" |
3987 | msgstr "" | 4044 | msgstr "" |
3988 | 4045 | ||
3989 | #: src/gns/gnunet-service-gns_resolver.c:724 | 4046 | #: src/gns/gnunet-service-gns_resolver.c:677 |
3990 | #, c-format | 4047 | #, c-format |
3991 | msgid "Service `%s' not a port, skipping service labels.\n" | 4048 | msgid "Service `%s' not a port, skipping service labels.\n" |
3992 | msgstr "" | 4049 | msgstr "" |
3993 | 4050 | ||
3994 | #: src/gns/gnunet-service-gns_resolver.c:938 | 4051 | #: src/gns/gnunet-service-gns_resolver.c:891 |
3995 | msgid "Failed to parse DNS response\n" | 4052 | msgid "Failed to parse DNS response\n" |
3996 | msgstr "ÐиÑам уÑпео да обрадим ДÐС одговор\n" | 4053 | msgstr "ÐиÑам уÑпео да обрадим ДÐС одговор\n" |
3997 | 4054 | ||
3998 | #: src/gns/gnunet-service-gns_resolver.c:1129 | 4055 | #: src/gns/gnunet-service-gns_resolver.c:1082 |
3999 | #, c-format | 4056 | #, c-format |
4000 | msgid "Skipping record of unsupported type %d\n" | 4057 | msgid "Skipping record of unsupported type %d\n" |
4001 | msgstr "ПреÑкачем Ð·Ð°Ð¿Ð¸Ñ Ð½ÐµÐ¿Ð¾Ð´Ñ€Ð¶Ð°Ð½Ðµ врÑте %d\n" | 4058 | msgstr "ПреÑкачем Ð·Ð°Ð¿Ð¸Ñ Ð½ÐµÐ¿Ð¾Ð´Ñ€Ð¶Ð°Ð½Ðµ врÑте %d\n" |
4002 | 4059 | ||
4003 | #: src/gns/gnunet-service-gns_resolver.c:1447 | 4060 | #: src/gns/gnunet-service-gns_resolver.c:1859 |
4004 | #, fuzzy, c-format | ||
4005 | msgid "VPN returned empty result for `%s'\n" | ||
4006 | msgstr "ÐТС је вратио резултате за %u адреÑе\n" | ||
4007 | |||
4008 | #: src/gns/gnunet-service-gns_resolver.c:1919 | ||
4009 | #, c-format | 4061 | #, c-format |
4010 | msgid "Name `%s' cannot be converted to IDNA." | 4062 | msgid "Name `%s' cannot be converted to IDNA." |
4011 | msgstr "" | 4063 | msgstr "" |
4012 | 4064 | ||
4013 | #: src/gns/gnunet-service-gns_resolver.c:1934 | 4065 | #: src/gns/gnunet-service-gns_resolver.c:1874 |
4014 | #, c-format | 4066 | #, c-format |
4015 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" | 4067 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" |
4016 | msgstr "ГÐС претраживање је резултирало ДÐС називом који је предуг („%s“)\n" | 4068 | msgstr "ГÐС претраживање је резултирало ДÐС називом који је предуг („%s“)\n" |
4017 | 4069 | ||
4018 | #: src/gns/gnunet-service-gns_resolver.c:1979 | 4070 | #: src/gns/gnunet-service-gns_resolver.c:1914 |
4019 | #, fuzzy, c-format | 4071 | #, fuzzy, c-format |
4020 | msgid "GNS lookup failed (zero records found for `%s')\n" | 4072 | msgid "GNS lookup failed (zero records found for `%s')\n" |
4021 | msgstr "Дубачење ГÐС претраге није уÑпело (ниÑам нашао Ð·Ð°Ð¿Ð¸Ñ Ð¸Ð·Ð°ÑланÑтва)\n" | 4073 | msgstr "Дубачење ГÐС претраге није уÑпело (ниÑам нашао Ð·Ð°Ð¿Ð¸Ñ Ð¸Ð·Ð°ÑланÑтва)\n" |
4022 | 4074 | ||
4023 | #: src/gns/gnunet-service-gns_resolver.c:2406 | 4075 | #: src/gns/gnunet-service-gns_resolver.c:2312 |
4076 | msgid "Unable to process critical delegation record\n" | ||
4077 | msgstr "" | ||
4078 | |||
4079 | #: src/gns/gnunet-service-gns_resolver.c:2317 | ||
4024 | msgid "GNS lookup recursion failed (no delegation record found)\n" | 4080 | msgid "GNS lookup recursion failed (no delegation record found)\n" |
4025 | msgstr "Дубачење ГÐС претраге није уÑпело (ниÑам нашао Ð·Ð°Ð¿Ð¸Ñ Ð¸Ð·Ð°ÑланÑтва)\n" | 4081 | msgstr "Дубачење ГÐС претраге није уÑпело (ниÑам нашао Ð·Ð°Ð¿Ð¸Ñ Ð¸Ð·Ð°ÑланÑтва)\n" |
4026 | 4082 | ||
4027 | #: src/gns/gnunet-service-gns_resolver.c:2429 | 4083 | #: src/gns/gnunet-service-gns_resolver.c:2340 |
4028 | #, c-format | 4084 | #, c-format |
4029 | msgid "Failed to cache GNS resolution: %s\n" | 4085 | msgid "Failed to cache GNS resolution: %s\n" |
4030 | msgstr "ÐиÑам уÑпео да ÑмеÑтим у оÑтаву ГÐС резолуцију: %s\n" | 4086 | msgstr "ÐиÑам уÑпео да ÑмеÑтим у оÑтаву ГÐС резолуцију: %s\n" |
4031 | 4087 | ||
4032 | #: src/gns/gnunet-service-gns_resolver.c:2594 | 4088 | #: src/gns/gnunet-service-gns_resolver.c:2505 |
4033 | #, fuzzy, c-format | 4089 | #, fuzzy, c-format |
4034 | msgid "GNS namecache returned empty result for `%s'\n" | 4090 | msgid "GNS namecache returned empty result for `%s'\n" |
4035 | msgstr "ÐТС је вратио резултате за %u адреÑе\n" | 4091 | msgstr "ÐТС је вратио резултате за %u адреÑе\n" |
4036 | 4092 | ||
4037 | #: src/gns/gnunet-service-gns_resolver.c:2734 | 4093 | #: src/gns/gnunet-service-gns_resolver.c:2652 |
4038 | #, c-format | 4094 | #, c-format |
4039 | msgid "Zone %s was revoked, resolution fails\n" | 4095 | msgid "Zone %s was revoked, resolution fails\n" |
4040 | msgstr "Зона %s је опозвана, резолуција није уÑпела\n" | 4096 | msgstr "Зона %s је опозвана, резолуција није уÑпела\n" |
4041 | 4097 | ||
4042 | #: src/gns/plugin_gnsrecord_gns.c:174 | 4098 | #: src/gns/plugin_gnsrecord_gns.c:136 |
4099 | msgid "This is a memento of an older block for internal maintenance." | ||
4100 | msgstr "" | ||
4101 | |||
4102 | #: src/gns/plugin_gnsrecord_gns.c:175 | ||
4043 | #, fuzzy, c-format | 4103 | #, fuzzy, c-format |
4044 | msgid "Unable to parse zone key record `%s'\n" | 4104 | msgid "Unable to parse zone key record `%s'\n" |
4045 | msgstr "Ðе могу да обрадим „MX“ Ð·Ð°Ð¿Ð¸Ñ â€ž%s“\n" | 4105 | msgstr "Ðе могу да обрадим „MX“ Ð·Ð°Ð¿Ð¸Ñ â€ž%s“\n" |
4046 | 4106 | ||
4047 | #: src/gns/plugin_gnsrecord_gns.c:187 | 4107 | #: src/gns/plugin_gnsrecord_gns.c:188 |
4048 | msgid "Record type does not match parsed record type\n" | 4108 | msgid "Record type does not match parsed record type\n" |
4049 | msgstr "" | 4109 | msgstr "" |
4050 | 4110 | ||
4051 | #: src/gns/plugin_gnsrecord_gns.c:213 | 4111 | #: src/gns/plugin_gnsrecord_gns.c:211 |
4052 | #, c-format | 4112 | #, c-format |
4053 | msgid "Unable to parse GNS2DNS record `%s'\n" | 4113 | msgid "Unable to parse GNS2DNS record `%s'\n" |
4054 | msgstr "Ðе могу да обрадим „GNS2DNS“ Ð·Ð°Ð¿Ð¸Ñ â€ž%s“\n" | 4114 | msgstr "Ðе могу да обрадим „GNS2DNS“ Ð·Ð°Ð¿Ð¸Ñ â€ž%s“\n" |
4055 | 4115 | ||
4056 | #: src/gns/plugin_gnsrecord_gns.c:229 | 4116 | #: src/gns/plugin_gnsrecord_gns.c:227 |
4057 | #, fuzzy, c-format | 4117 | #, fuzzy, c-format |
4058 | msgid "Failed to serialize GNS2DNS record with value `%s': Not a DNS name.\n" | 4118 | msgid "Failed to serialize GNS2DNS record with value `%s': Not a DNS name.\n" |
4059 | msgstr "ÐиÑам уÑпео да Ñеријализујем ГÐС2ДÐС Ð·Ð°Ð¿Ð¸Ñ Ñа вредношћу „%s“\n" | 4119 | msgstr "ÐиÑам уÑпео да Ñеријализујем ГÐС2ДÐС Ð·Ð°Ð¿Ð¸Ñ Ñа вредношћу „%s“\n" |
4060 | 4120 | ||
4061 | #: src/gns/plugin_gnsrecord_gns.c:253 | 4121 | #: src/gns/plugin_gnsrecord_gns.c:251 |
4062 | #, c-format | 4122 | #, c-format |
4063 | msgid "Unable to parse VPN record string `%s'\n" | 4123 | msgid "Unable to parse VPN record string `%s'\n" |
4064 | msgstr "Ðе могу да обрадим ниÑку ВПРзапиÑа „%s“\n" | 4124 | msgstr "Ðе могу да обрадим ниÑку ВПРзапиÑа „%s“\n" |
4065 | 4125 | ||
4066 | #: src/gns/plugin_gnsrecord_gns.c:285 | 4126 | #: src/gns/plugin_gnsrecord_gns.c:283 |
4067 | #, fuzzy, c-format | 4127 | #, fuzzy, c-format |
4068 | msgid "Unable to parse BOX record string `%s'\n" | 4128 | msgid "Unable to parse BOX record string `%s'\n" |
4069 | msgstr "Ðе могу да обрадим ниÑку ВПРзапиÑа „%s“\n" | 4129 | msgstr "Ðе могу да обрадим ниÑку ВПРзапиÑа „%s“\n" |
@@ -4073,6 +4133,34 @@ msgstr "Ðе могу да обрадим ниÑку ВПРзапиÑа „%s†| |||
4073 | msgid "Gns REST API initialized\n" | 4133 | msgid "Gns REST API initialized\n" |
4074 | msgstr "Меш је покренут\n" | 4134 | msgstr "Меш је покренут\n" |
4075 | 4135 | ||
4136 | #: src/gnsrecord/gnsrecord_misc.c:448 | ||
4137 | msgid "Zone delegation record not allowed in apex." | ||
4138 | msgstr "" | ||
4139 | |||
4140 | #: src/gnsrecord/gnsrecord_misc.c:456 | ||
4141 | msgid "Zone delegation record set contains mutually exclusive records." | ||
4142 | msgstr "" | ||
4143 | |||
4144 | #: src/gnsrecord/gnsrecord_misc.c:466 | ||
4145 | msgid "Multiple REDIRECT records." | ||
4146 | msgstr "" | ||
4147 | |||
4148 | #: src/gnsrecord/gnsrecord_misc.c:475 src/gnsrecord/gnsrecord_misc.c:501 | ||
4149 | msgid "Redirection record set conains mutually exclusive records." | ||
4150 | msgstr "" | ||
4151 | |||
4152 | #: src/gnsrecord/gnsrecord_misc.c:482 | ||
4153 | msgid "Redirection records not allowed in apex." | ||
4154 | msgstr "" | ||
4155 | |||
4156 | #: src/gnsrecord/gnsrecord_misc.c:493 | ||
4157 | msgid "Redirection records not allowed in apex.." | ||
4158 | msgstr "" | ||
4159 | |||
4160 | #: src/gnsrecord/gnsrecord_misc.c:515 | ||
4161 | msgid "Mutually exclusive records." | ||
4162 | msgstr "" | ||
4163 | |||
4076 | #: src/gnsrecord/plugin_gnsrecord_dns.c:367 | 4164 | #: src/gnsrecord/plugin_gnsrecord_dns.c:367 |
4077 | #, c-format | 4165 | #, c-format |
4078 | msgid "Unable to parse IPv4 address `%s'\n" | 4166 | msgid "Unable to parse IPv4 address `%s'\n" |
@@ -4321,7 +4409,7 @@ msgid "# hostlist downloads initiated" | |||
4321 | msgstr "# преузимања ÑпиÑка домаћина Ñу започета" | 4409 | msgstr "# преузимања ÑпиÑка домаћина Ñу започета" |
4322 | 4410 | ||
4323 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1144 | 4411 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1144 |
4324 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1728 | 4412 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1732 |
4325 | msgid "# milliseconds between hostlist downloads" | 4413 | msgid "# milliseconds between hostlist downloads" |
4326 | msgstr "# милиÑекунди између преузимања ÑпиÑка домаћина" | 4414 | msgstr "# милиÑекунди између преузимања ÑпиÑка домаћина" |
4327 | 4415 | ||
@@ -4382,21 +4470,21 @@ msgstr "Грешка пиÑања УРИ-а ÑпиÑка домаћина у дР| |||
4382 | msgid "# hostlist URIs written to file" | 4470 | msgid "# hostlist URIs written to file" |
4383 | msgstr "# УРИ-и ÑпиÑка домаћина Ñу запиÑани у датотеку" | 4471 | msgstr "# УРИ-и ÑпиÑка домаћина Ñу запиÑани у датотеку" |
4384 | 4472 | ||
4385 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1657 | 4473 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1661 |
4386 | #: src/transport/plugin_transport_http_client.c:2300 | 4474 | #: src/transport/plugin_transport_http_client.c:2300 |
4387 | #, c-format | 4475 | #, c-format |
4388 | msgid "Invalid proxy type: `%s', disabling proxy! Check configuration!\n" | 4476 | msgid "Invalid proxy type: `%s', disabling proxy! Check configuration!\n" |
4389 | msgstr "" | 4477 | msgstr "" |
4390 | 4478 | ||
4391 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1686 | 4479 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1690 |
4392 | msgid "Learning is enabled on this peer\n" | 4480 | msgid "Learning is enabled on this peer\n" |
4393 | msgstr "Учење је укључено на овом парњаку\n" | 4481 | msgstr "Учење је укључено на овом парњаку\n" |
4394 | 4482 | ||
4395 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1699 | 4483 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1703 |
4396 | msgid "Learning is not enabled on this peer\n" | 4484 | msgid "Learning is not enabled on this peer\n" |
4397 | msgstr "Учење није укључено на овом парњаку\n" | 4485 | msgstr "Учење није укључено на овом парњаку\n" |
4398 | 4486 | ||
4399 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1713 | 4487 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1717 |
4400 | #, c-format | 4488 | #, c-format |
4401 | msgid "" | 4489 | msgid "" |
4402 | "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" | 4490 | "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" |
@@ -4595,50 +4683,50 @@ msgstr "" | |||
4595 | msgid "Maintain egos" | 4683 | msgid "Maintain egos" |
4596 | msgstr "Одржава егое" | 4684 | msgstr "Одржава егое" |
4597 | 4685 | ||
4598 | #: src/identity/gnunet-service-identity.c:503 | 4686 | #: src/identity/gnunet-service-identity.c:502 |
4599 | msgid "no default known" | 4687 | msgid "no default known" |
4600 | msgstr "оÑновнÑÑ‚ није позната" | 4688 | msgstr "оÑновнÑÑ‚ није позната" |
4601 | 4689 | ||
4602 | #: src/identity/gnunet-service-identity.c:528 | 4690 | #: src/identity/gnunet-service-identity.c:527 |
4603 | msgid "default configured, but ego unknown (internal error)" | 4691 | msgid "default configured, but ego unknown (internal error)" |
4604 | msgstr "оÑновни је подешен, али его није познат (унутрашња грешка)" | 4692 | msgstr "оÑновни је подешен, али его није познат (унутрашња грешка)" |
4605 | 4693 | ||
4606 | #: src/identity/gnunet-service-identity.c:621 | 4694 | #: src/identity/gnunet-service-identity.c:620 |
4607 | #: src/identity/gnunet-service-identity.c:896 | 4695 | #: src/identity/gnunet-service-identity.c:895 |
4608 | #: src/identity/gnunet-service-identity.c:1016 | 4696 | #: src/identity/gnunet-service-identity.c:1015 |
4609 | #, c-format | 4697 | #, c-format |
4610 | msgid "Failed to write subsystem default identifier map to `%s'.\n" | 4698 | msgid "Failed to write subsystem default identifier map to `%s'.\n" |
4611 | msgstr "ÐиÑам уÑпео да запишем оÑновну мапу одредника подÑиÑтема у „%s“.\n" | 4699 | msgstr "ÐиÑам уÑпео да запишем оÑновну мапу одредника подÑиÑтема у „%s“.\n" |
4612 | 4700 | ||
4613 | #: src/identity/gnunet-service-identity.c:631 | 4701 | #: src/identity/gnunet-service-identity.c:630 |
4614 | msgid "Unknown ego specified for service (internal error)" | 4702 | msgid "Unknown ego specified for service (internal error)" |
4615 | msgstr "Ðепознат его је наведен за уÑлугу (унутрашња грешка)" | 4703 | msgstr "Ðепознат его је наведен за уÑлугу (унутрашња грешка)" |
4616 | 4704 | ||
4617 | #: src/identity/gnunet-service-identity.c:725 | 4705 | #: src/identity/gnunet-service-identity.c:724 |
4618 | msgid "identifier already in use for another ego" | 4706 | msgid "identifier already in use for another ego" |
4619 | msgstr "одредник Ñе већ кориÑти за други его" | 4707 | msgstr "одредник Ñе већ кориÑти за други его" |
4620 | 4708 | ||
4621 | #: src/identity/gnunet-service-identity.c:872 | 4709 | #: src/identity/gnunet-service-identity.c:871 |
4622 | msgid "target name already exists" | 4710 | msgid "target name already exists" |
4623 | msgstr "назив мете већ поÑтоји" | 4711 | msgstr "назив мете већ поÑтоји" |
4624 | 4712 | ||
4625 | #: src/identity/gnunet-service-identity.c:914 | 4713 | #: src/identity/gnunet-service-identity.c:913 |
4626 | #: src/identity/gnunet-service-identity.c:1033 | 4714 | #: src/identity/gnunet-service-identity.c:1032 |
4627 | msgid "no matching ego found" | 4715 | msgid "no matching ego found" |
4628 | msgstr "ниÑам нашао одговарајући его" | 4716 | msgstr "ниÑам нашао одговарајући его" |
4629 | 4717 | ||
4630 | #: src/identity/gnunet-service-identity.c:1131 | 4718 | #: src/identity/gnunet-service-identity.c:1130 |
4631 | #, c-format | 4719 | #, c-format |
4632 | msgid "Failed to parse ego information in `%s'\n" | 4720 | msgid "Failed to parse ego information in `%s'\n" |
4633 | msgstr "ÐиÑам уÑпео да обрадим податке егоа у „%s“\n" | 4721 | msgstr "ÐиÑам уÑпео да обрадим податке егоа у „%s“\n" |
4634 | 4722 | ||
4635 | #: src/identity/gnunet-service-identity.c:1189 | 4723 | #: src/identity/gnunet-service-identity.c:1188 |
4636 | #, c-format | 4724 | #, c-format |
4637 | msgid "Failed to parse subsystem identity configuration file `%s'\n" | 4725 | msgid "Failed to parse subsystem identity configuration file `%s'\n" |
4638 | msgstr "" | 4726 | msgstr "" |
4639 | "ÐиÑам уÑпео да обрадим датотеку подешавања идентитета ÑубÑиÑтема „%s“\n" | 4727 | "ÐиÑам уÑпео да обрадим датотеку подешавања идентитета ÑубÑиÑтема „%s“\n" |
4640 | 4728 | ||
4641 | #: src/identity/gnunet-service-identity.c:1198 | 4729 | #: src/identity/gnunet-service-identity.c:1197 |
4642 | #, c-format | 4730 | #, c-format |
4643 | msgid "Failed to create directory `%s' for storing egos\n" | 4731 | msgid "Failed to create directory `%s' for storing egos\n" |
4644 | msgstr "ÐиÑам уÑпео да направим директоријум „%s“ за Ñмештајне егое\n" | 4732 | msgstr "ÐиÑам уÑпео да направим директоријум „%s“ за Ñмештајне егое\n" |
@@ -4678,7 +4766,7 @@ msgstr "Ðе могу да приÑтупим датотеци „%s“: %s\n" | |||
4678 | msgid "No records found for `%s'" | 4766 | msgid "No records found for `%s'" |
4679 | msgstr "ÐиÑам нашао запиÑе за „%s“" | 4767 | msgstr "ÐиÑам нашао запиÑе за „%s“" |
4680 | 4768 | ||
4681 | #: src/namecache/gnunet-namecache.c:119 src/namestore/gnunet-namestore.c:459 | 4769 | #: src/namecache/gnunet-namecache.c:119 src/namestore/gnunet-namestore.c:469 |
4682 | #, c-format | 4770 | #, c-format |
4683 | msgid "\tCorrupt or unsupported record of type %u\n" | 4771 | msgid "\tCorrupt or unsupported record of type %u\n" |
4684 | msgstr "\tОштећен или неподржан Ð·Ð°Ð¿Ð¸Ñ Ð²Ñ€Ñте %u\n" | 4772 | msgstr "\tОштећен или неподржан Ð·Ð°Ð¿Ð¸Ñ Ð²Ñ€Ñте %u\n" |
@@ -4698,7 +4786,7 @@ msgstr "ÐеиÑправан јавни кључ за обратну претрР| |||
4698 | msgid "You must specify a name\n" | 4786 | msgid "You must specify a name\n" |
4699 | msgstr "Морате навеÑти назив\n" | 4787 | msgstr "Морате навеÑти назив\n" |
4700 | 4788 | ||
4701 | #: src/namecache/gnunet-namecache.c:214 src/namestore/gnunet-namestore.c:1641 | 4789 | #: src/namecache/gnunet-namecache.c:214 src/namestore/gnunet-namestore.c:1591 |
4702 | msgid "name of the record to add/delete/display" | 4790 | msgid "name of the record to add/delete/display" |
4703 | msgstr "назив запиÑа за додавање/бриÑање/приказ" | 4791 | msgstr "назив запиÑа за додавање/бриÑање/приказ" |
4704 | 4792 | ||
@@ -4707,7 +4795,7 @@ msgstr "назив запиÑа за додавање/бриÑање/прикаР| |||
4707 | msgid "specifies the public key of the zone to look in" | 4795 | msgid "specifies the public key of the zone to look in" |
4708 | msgstr "наводи јавни кључ зоне за претраживање" | 4796 | msgstr "наводи јавни кључ зоне за претраживање" |
4709 | 4797 | ||
4710 | #: src/namecache/gnunet-namecache.c:233 src/namestore/gnunet-namestore.c:1702 | 4798 | #: src/namecache/gnunet-namecache.c:233 src/namestore/gnunet-namestore.c:1652 |
4711 | msgid "GNUnet zone manipulation tool" | 4799 | msgid "GNUnet zone manipulation tool" |
4712 | msgstr "Ðлат манипуÑлиÑања ГÐУнет зоном" | 4800 | msgstr "Ðлат манипуÑлиÑања ГÐУнет зоном" |
4713 | 4801 | ||
@@ -4853,140 +4941,113 @@ msgstr "" | |||
4853 | msgid "GNU Name System First-Come-First-Served name registration service" | 4941 | msgid "GNU Name System First-Come-First-Served name registration service" |
4854 | msgstr "УÑлуга региÑтрације назива Први Стиже Први Служи ГÐУ СиÑтема Ðазива" | 4942 | msgstr "УÑлуга региÑтрације назива Први Стиже Први Служи ГÐУ СиÑтема Ðазива" |
4855 | 4943 | ||
4856 | #: src/namestore/gnunet-namestore.c:334 | 4944 | #: src/namestore/gnunet-namestore.c:340 |
4857 | #, c-format | 4945 | #, c-format |
4858 | msgid "Adding record failed: %s\n" | 4946 | msgid "Adding record failed: %s\n" |
4859 | msgstr "Додавање запиÑа није уÑпело: %s\n" | 4947 | msgstr "Додавање запиÑа није уÑпело: %s\n" |
4860 | 4948 | ||
4861 | #: src/namestore/gnunet-namestore.c:362 | 4949 | #: src/namestore/gnunet-namestore.c:368 |
4862 | #, c-format | 4950 | #, c-format |
4863 | msgid "Deleting record failed, record does not exist%s%s\n" | 4951 | msgid "Deleting record failed, record does not exist%s%s\n" |
4864 | msgstr "БриÑање запиÑа није уÑпело, Ð·Ð°Ð¿Ð¸Ñ Ð½Ðµ поÑтоји%s%s\n" | 4952 | msgstr "БриÑање запиÑа није уÑпело, Ð·Ð°Ð¿Ð¸Ñ Ð½Ðµ поÑтоји%s%s\n" |
4865 | 4953 | ||
4866 | #: src/namestore/gnunet-namestore.c:369 | 4954 | #: src/namestore/gnunet-namestore.c:375 |
4867 | #, c-format | 4955 | #, c-format |
4868 | msgid "Deleting record failed%s%s\n" | 4956 | msgid "Deleting record failed%s%s\n" |
4869 | msgstr "БриÑање запиÑа није уÑпело%s%s\n" | 4957 | msgstr "БриÑање запиÑа није уÑпело%s%s\n" |
4870 | 4958 | ||
4871 | #: src/namestore/gnunet-namestore.c:656 | ||
4872 | #, c-format | ||
4873 | msgid "A %s record exists already under `%s', no other records can be added.\n" | ||
4874 | msgstr "" | ||
4875 | |||
4876 | #: src/namestore/gnunet-namestore.c:668 | 4959 | #: src/namestore/gnunet-namestore.c:668 |
4877 | #, c-format | 4960 | #, c-format |
4878 | msgid "" | 4961 | msgid "" |
4879 | "A zone key record exists already under `%s', no other records can be added.\n" | ||
4880 | msgstr "" | ||
4881 | |||
4882 | #: src/namestore/gnunet-namestore.c:680 | ||
4883 | #, c-format | ||
4884 | msgid "" | ||
4885 | "A SOA record exists already under `%s', cannot add a second SOA to the same " | 4962 | "A SOA record exists already under `%s', cannot add a second SOA to the same " |
4886 | "zone.\n" | 4963 | "zone.\n" |
4887 | msgstr "" | 4964 | msgstr "" |
4888 | 4965 | ||
4889 | #: src/namestore/gnunet-namestore.c:696 | 4966 | #: src/namestore/gnunet-namestore.c:789 |
4890 | #, c-format | ||
4891 | msgid "Records already exist under `%s', cannot add `%s' record.\n" | ||
4892 | msgstr "" | ||
4893 | |||
4894 | #: src/namestore/gnunet-namestore.c:711 | ||
4895 | #, c-format | ||
4896 | msgid "Records already exist under `%s', cannot add record.\n" | ||
4897 | msgstr "" | ||
4898 | |||
4899 | #: src/namestore/gnunet-namestore.c:726 | ||
4900 | #, c-format | ||
4901 | msgid "" | ||
4902 | "Non-GNS2DNS records already exist under `%s', cannot add GNS2DNS record.\n" | ||
4903 | msgstr "" | ||
4904 | |||
4905 | #: src/namestore/gnunet-namestore.c:846 | ||
4906 | #, fuzzy, c-format | 4967 | #, fuzzy, c-format |
4907 | msgid "There are no records under label `%s' that could be deleted.\n" | 4968 | msgid "There are no records under label `%s' that could be deleted.\n" |
4908 | msgstr "Ðема позива који би могао бити отказан управо Ñада.\n" | 4969 | msgstr "Ðема позива који би могао бити отказан управо Ñада.\n" |
4909 | 4970 | ||
4910 | #: src/namestore/gnunet-namestore.c:889 | 4971 | #: src/namestore/gnunet-namestore.c:832 |
4911 | #, c-format | 4972 | #, c-format |
4912 | msgid "" | 4973 | msgid "" |
4913 | "There are no records under label `%s' that match the request for deletion.\n" | 4974 | "There are no records under label `%s' that match the request for deletion.\n" |
4914 | msgstr "" | 4975 | msgstr "" |
4915 | 4976 | ||
4916 | #: src/namestore/gnunet-namestore.c:970 | 4977 | #: src/namestore/gnunet-namestore.c:920 |
4917 | #, fuzzy, c-format | 4978 | #, fuzzy, c-format |
4918 | msgid "Failed to replace records: %s\n" | 4979 | msgid "Failed to replace records: %s\n" |
4919 | msgstr "ÐиÑам уÑпео да обрадим ДÐÐЕ запиÑ: %s\n" | 4980 | msgstr "ÐиÑам уÑпео да обрадим ДÐÐЕ запиÑ: %s\n" |
4920 | 4981 | ||
4921 | #: src/namestore/gnunet-namestore.c:993 | 4982 | #: src/namestore/gnunet-namestore.c:943 |
4922 | #, c-format | 4983 | #, c-format |
4923 | msgid "No options given\n" | 4984 | msgid "No options given\n" |
4924 | msgstr "ÐиÑу дате опције\n" | 4985 | msgstr "ÐиÑу дате опције\n" |
4925 | 4986 | ||
4926 | #: src/namestore/gnunet-namestore.c:1014 src/namestore/gnunet-namestore.c:1066 | 4987 | #: src/namestore/gnunet-namestore.c:964 src/namestore/gnunet-namestore.c:1016 |
4927 | #: src/namestore/gnunet-namestore.c:1076 src/namestore/gnunet-namestore.c:1105 | 4988 | #: src/namestore/gnunet-namestore.c:1026 src/namestore/gnunet-namestore.c:1055 |
4928 | #: src/namestore/gnunet-namestore.c:1126 src/namestore/gnunet-namestore.c:1153 | 4989 | #: src/namestore/gnunet-namestore.c:1076 src/namestore/gnunet-namestore.c:1103 |
4929 | #: src/namestore/gnunet-namestore.c:1230 | 4990 | #: src/namestore/gnunet-namestore.c:1180 |
4930 | #, c-format | 4991 | #, c-format |
4931 | msgid "Missing option `%s' for operation `%s'\n" | 4992 | msgid "Missing option `%s' for operation `%s'\n" |
4932 | msgstr "ÐедоÑтаје опција „%s“ за радњу „%s“\n" | 4993 | msgstr "ÐедоÑтаје опција „%s“ за радњу „%s“\n" |
4933 | 4994 | ||
4934 | #: src/namestore/gnunet-namestore.c:1016 | 4995 | #: src/namestore/gnunet-namestore.c:966 |
4935 | msgid "replace" | 4996 | msgid "replace" |
4936 | msgstr "" | 4997 | msgstr "" |
4937 | 4998 | ||
4938 | #: src/namestore/gnunet-namestore.c:1045 | 4999 | #: src/namestore/gnunet-namestore.c:995 |
4939 | #, c-format | 5000 | #, c-format |
4940 | msgid "Invalid nick `%s'\n" | 5001 | msgid "Invalid nick `%s'\n" |
4941 | msgstr "ÐеиÑправан надимак „%s“\n" | 5002 | msgstr "ÐеиÑправан надимак „%s“\n" |
4942 | 5003 | ||
4943 | #: src/namestore/gnunet-namestore.c:1068 src/namestore/gnunet-namestore.c:1078 | 5004 | #: src/namestore/gnunet-namestore.c:1018 src/namestore/gnunet-namestore.c:1028 |
4944 | #: src/namestore/gnunet-namestore.c:1107 src/namestore/gnunet-namestore.c:1128 | 5005 | #: src/namestore/gnunet-namestore.c:1057 src/namestore/gnunet-namestore.c:1078 |
4945 | #: src/namestore/gnunet-namestore.c:1232 | 5006 | #: src/namestore/gnunet-namestore.c:1182 |
4946 | msgid "add" | 5007 | msgid "add" |
4947 | msgstr "додај" | 5008 | msgstr "додај" |
4948 | 5009 | ||
4949 | #: src/namestore/gnunet-namestore.c:1086 | 5010 | #: src/namestore/gnunet-namestore.c:1036 |
4950 | #, c-format | 5011 | #, c-format |
4951 | msgid "Unsupported type `%s'\n" | 5012 | msgid "Unsupported type `%s'\n" |
4952 | msgstr "Ðеподржана врÑта „%s“\n" | 5013 | msgstr "Ðеподржана врÑта „%s“\n" |
4953 | 5014 | ||
4954 | #: src/namestore/gnunet-namestore.c:1096 | 5015 | #: src/namestore/gnunet-namestore.c:1046 |
4955 | #, c-format | 5016 | #, c-format |
4956 | msgid "For DNS record types `SRV', `TLSA' and `OPENPGPKEY'" | 5017 | msgid "For DNS record types `SRV', `TLSA' and `OPENPGPKEY'" |
4957 | msgstr "" | 5018 | msgstr "" |
4958 | 5019 | ||
4959 | #: src/namestore/gnunet-namestore.c:1116 | 5020 | #: src/namestore/gnunet-namestore.c:1066 |
4960 | #, c-format | 5021 | #, c-format |
4961 | msgid "Value `%s' invalid for record type `%s'\n" | 5022 | msgid "Value `%s' invalid for record type `%s'\n" |
4962 | msgstr "ВредноÑÑ‚ „%s“ је неиÑправна за врÑту запиÑа „%s“\n" | 5023 | msgstr "ВредноÑÑ‚ „%s“ је неиÑправна за врÑту запиÑа „%s“\n" |
4963 | 5024 | ||
4964 | #: src/namestore/gnunet-namestore.c:1135 src/namestore/gnunet-namestore.c:1239 | 5025 | #: src/namestore/gnunet-namestore.c:1085 src/namestore/gnunet-namestore.c:1189 |
4965 | #, c-format | 5026 | #, c-format |
4966 | msgid "Invalid time format `%s'\n" | 5027 | msgid "Invalid time format `%s'\n" |
4967 | msgstr "ÐеиÑправан формат времена „%s“\n" | 5028 | msgstr "ÐеиÑправан формат времена „%s“\n" |
4968 | 5029 | ||
4969 | #: src/namestore/gnunet-namestore.c:1155 | 5030 | #: src/namestore/gnunet-namestore.c:1105 |
4970 | msgid "del" | 5031 | msgid "del" |
4971 | msgstr "обриши" | 5032 | msgstr "обриши" |
4972 | 5033 | ||
4973 | #: src/namestore/gnunet-namestore.c:1197 | 5034 | #: src/namestore/gnunet-namestore.c:1147 |
4974 | #, c-format | 5035 | #, c-format |
4975 | msgid "Invalid public key for reverse lookup `%s'\n" | 5036 | msgid "Invalid public key for reverse lookup `%s'\n" |
4976 | msgstr "ÐеиÑправан јавни кључ за обратну претрагу „%s“\n" | 5037 | msgstr "ÐеиÑправан јавни кључ за обратну претрагу „%s“\n" |
4977 | 5038 | ||
4978 | #: src/namestore/gnunet-namestore.c:1222 | 5039 | #: src/namestore/gnunet-namestore.c:1172 |
4979 | #: src/peerinfo-tool/gnunet-peerinfo.c:737 | 5040 | #: src/peerinfo-tool/gnunet-peerinfo.c:737 |
4980 | #, c-format | 5041 | #, c-format |
4981 | msgid "Invalid URI `%s'\n" | 5042 | msgid "Invalid URI `%s'\n" |
4982 | msgstr "ÐеиÑправан УРИ „%s“\n" | 5043 | msgstr "ÐеиÑправан УРИ „%s“\n" |
4983 | 5044 | ||
4984 | #: src/namestore/gnunet-namestore.c:1292 | 5045 | #: src/namestore/gnunet-namestore.c:1242 |
4985 | #, c-format | 5046 | #, c-format |
4986 | msgid "Label `%s' contains `.' which is not allowed\n" | 5047 | msgid "Label `%s' contains `.' which is not allowed\n" |
4987 | msgstr "" | 5048 | msgstr "" |
4988 | 5049 | ||
4989 | #: src/namestore/gnunet-namestore.c:1342 | 5050 | #: src/namestore/gnunet-namestore.c:1292 |
4990 | #, c-format | 5051 | #, c-format |
4991 | msgid "" | 5052 | msgid "" |
4992 | "No default identity configured for `namestore' subsystem\n" | 5053 | "No default identity configured for `namestore' subsystem\n" |
@@ -4994,108 +5055,113 @@ msgid "" | |||
4994 | "Run gnunet-identity -d to get a list of choices for $NAME\n" | 5055 | "Run gnunet-identity -d to get a list of choices for $NAME\n" |
4995 | msgstr "" | 5056 | msgstr "" |
4996 | 5057 | ||
4997 | #: src/namestore/gnunet-namestore.c:1407 | 5058 | #: src/namestore/gnunet-namestore.c:1357 |
4998 | #, c-format | 5059 | #, c-format |
4999 | msgid "Superfluous command line arguments (starting with `%s') ignored\n" | 5060 | msgid "Superfluous command line arguments (starting with `%s') ignored\n" |
5000 | msgstr "" | 5061 | msgstr "" |
5001 | 5062 | ||
5002 | #: src/namestore/gnunet-namestore.c:1436 | 5063 | #: src/namestore/gnunet-namestore.c:1386 |
5003 | #, c-format | 5064 | #, c-format |
5004 | msgid "Cannot connect to identity service\n" | 5065 | msgid "Cannot connect to identity service\n" |
5005 | msgstr "Ðе могу да Ñе повежем Ñа уÑлугом идентитета\n" | 5066 | msgstr "Ðе могу да Ñе повежем Ñа уÑлугом идентитета\n" |
5006 | 5067 | ||
5007 | #: src/namestore/gnunet-namestore.c:1483 | 5068 | #: src/namestore/gnunet-namestore.c:1433 |
5008 | msgid "Empty record line argument is not allowed.\n" | 5069 | msgid "Empty record line argument is not allowed.\n" |
5009 | msgstr "" | 5070 | msgstr "" |
5010 | 5071 | ||
5011 | #: src/namestore/gnunet-namestore.c:1495 | 5072 | #: src/namestore/gnunet-namestore.c:1445 |
5012 | #, c-format | 5073 | #, c-format |
5013 | msgid "Invalid expiration time `%s' (must be without unit)\n" | 5074 | msgid "Invalid expiration time `%s' (must be without unit)\n" |
5014 | msgstr "" | 5075 | msgstr "" |
5015 | 5076 | ||
5016 | #: src/namestore/gnunet-namestore.c:1507 src/namestore/gnunet-namestore.c:1523 | 5077 | #: src/namestore/gnunet-namestore.c:1457 src/namestore/gnunet-namestore.c:1473 |
5017 | #: src/namestore/gnunet-namestore.c:1540 | 5078 | #: src/namestore/gnunet-namestore.c:1490 |
5018 | #, fuzzy, c-format | 5079 | #, fuzzy, c-format |
5019 | msgid "Missing entries in record line `%s'.\n" | 5080 | msgid "Missing entries in record line `%s'.\n" |
5020 | msgstr "ÐедоÑтаје функција „%s“ у прикључку преноÑа за „%s“\n" | 5081 | msgstr "ÐедоÑтаје функција „%s“ у прикључку преноÑа за „%s“\n" |
5021 | 5082 | ||
5022 | #: src/namestore/gnunet-namestore.c:1515 | 5083 | #: src/namestore/gnunet-namestore.c:1465 |
5023 | #, fuzzy, c-format | 5084 | #, fuzzy, c-format |
5024 | msgid "Unknown record type `%s'\n" | 5085 | msgid "Unknown record type `%s'\n" |
5025 | msgstr "Ðепозната наредба „%s“\n" | 5086 | msgstr "Ðепозната наредба „%s“\n" |
5026 | 5087 | ||
5027 | #: src/namestore/gnunet-namestore.c:1553 | 5088 | #: src/namestore/gnunet-namestore.c:1503 |
5028 | #, fuzzy, c-format | 5089 | #, fuzzy, c-format |
5029 | msgid "Invalid record data for type %s: `%s'.\n" | 5090 | msgid "Invalid record data for type %s: `%s'.\n" |
5030 | msgstr "ÐеиÑправан формат за ИП: „%s“\n" | 5091 | msgstr "ÐеиÑправан формат за ИП: „%s“\n" |
5031 | 5092 | ||
5032 | #: src/namestore/gnunet-namestore.c:1610 | 5093 | #: src/namestore/gnunet-namestore.c:1560 |
5033 | msgid "add record" | 5094 | msgid "add record" |
5034 | msgstr "додаје запиÑ" | 5095 | msgstr "додаје запиÑ" |
5035 | 5096 | ||
5036 | #: src/namestore/gnunet-namestore.c:1613 | 5097 | #: src/namestore/gnunet-namestore.c:1563 |
5037 | msgid "delete record" | 5098 | msgid "delete record" |
5038 | msgstr "брише запиÑ" | 5099 | msgstr "брише запиÑ" |
5039 | 5100 | ||
5040 | #: src/namestore/gnunet-namestore.c:1617 | 5101 | #: src/namestore/gnunet-namestore.c:1567 |
5041 | msgid "display records" | 5102 | msgid "display records" |
5042 | msgstr "приказује запиÑе" | 5103 | msgstr "приказује запиÑе" |
5043 | 5104 | ||
5044 | #: src/namestore/gnunet-namestore.c:1624 | 5105 | #: src/namestore/gnunet-namestore.c:1574 |
5045 | msgid "" | 5106 | msgid "" |
5046 | "expiration time for record to use (for adding only), \"never\" is possible" | 5107 | "expiration time for record to use (for adding only), \"never\" is possible" |
5047 | msgstr "време иÑтека запиÑа за коришћење (Ñамо за додавање), „never“ је могуће" | 5108 | msgstr "време иÑтека запиÑа за коришћење (Ñамо за додавање), „never“ је могуће" |
5048 | 5109 | ||
5049 | #: src/namestore/gnunet-namestore.c:1630 | 5110 | #: src/namestore/gnunet-namestore.c:1580 |
5050 | msgid "set the desired nick name for the zone" | 5111 | msgid "set the desired nick name for the zone" |
5051 | msgstr "поÑтавља жељени назив надимка за зону" | 5112 | msgstr "поÑтавља жељени назив надимка за зону" |
5052 | 5113 | ||
5053 | #: src/namestore/gnunet-namestore.c:1635 | 5114 | #: src/namestore/gnunet-namestore.c:1585 |
5054 | msgid "monitor changes in the namestore" | 5115 | msgid "monitor changes in the namestore" |
5055 | msgstr "прати измене у Ñмештају назива" | 5116 | msgstr "прати измене у Ñмештају назива" |
5056 | 5117 | ||
5057 | #: src/namestore/gnunet-namestore.c:1647 | 5118 | #: src/namestore/gnunet-namestore.c:1597 |
5058 | msgid "determine our name for the given PKEY" | 5119 | msgid "determine our name for the given PKEY" |
5059 | msgstr "одређује наш назив за дати „PKEY“" | 5120 | msgstr "одређује наш назив за дати „PKEY“" |
5060 | 5121 | ||
5061 | #: src/namestore/gnunet-namestore.c:1654 | 5122 | #: src/namestore/gnunet-namestore.c:1604 |
5062 | msgid "" | 5123 | msgid "" |
5063 | "set record set to values given by (possibly multiple) RECORDLINES; can be " | 5124 | "set record set to values given by (possibly multiple) RECORDLINES; can be " |
5064 | "specified multiple times" | 5125 | "specified multiple times" |
5065 | msgstr "" | 5126 | msgstr "" |
5066 | 5127 | ||
5067 | #: src/namestore/gnunet-namestore.c:1660 | 5128 | #: src/namestore/gnunet-namestore.c:1610 |
5068 | msgid "type of the record to add/delete/display" | 5129 | msgid "type of the record to add/delete/display" |
5069 | msgstr "врÑта запиÑа за додавање/бриÑање/приказ" | 5130 | msgstr "врÑта запиÑа за додавање/бриÑање/приказ" |
5070 | 5131 | ||
5071 | #: src/namestore/gnunet-namestore.c:1665 | 5132 | #: src/namestore/gnunet-namestore.c:1615 |
5072 | msgid "URI to import into our zone" | 5133 | msgid "URI to import into our zone" |
5073 | msgstr "УРИ за увоз у нашу зону" | 5134 | msgstr "УРИ за увоз у нашу зону" |
5074 | 5135 | ||
5075 | #: src/namestore/gnunet-namestore.c:1671 | 5136 | #: src/namestore/gnunet-namestore.c:1621 |
5076 | msgid "value of the record to add/delete" | 5137 | msgid "value of the record to add/delete" |
5077 | msgstr "вредноÑÑ‚ запиÑа за додавање/бриÑање" | 5138 | msgstr "вредноÑÑ‚ запиÑа за додавање/бриÑање" |
5078 | 5139 | ||
5079 | #: src/namestore/gnunet-namestore.c:1675 | 5140 | #: src/namestore/gnunet-namestore.c:1625 |
5080 | msgid "create or list public record" | 5141 | msgid "create or list public record" |
5081 | msgstr "Ñтвара или иÑпиÑује јавни запиÑ" | 5142 | msgstr "Ñтвара или иÑпиÑује јавни запиÑ" |
5082 | 5143 | ||
5083 | #: src/namestore/gnunet-namestore.c:1681 | 5144 | #: src/namestore/gnunet-namestore.c:1631 |
5084 | msgid "" | 5145 | msgid "" |
5085 | "create shadow record (only valid if all other records of the same type have " | 5146 | "create shadow record (only valid if all other records of the same type have " |
5086 | "expired" | 5147 | "expired" |
5087 | msgstr "" | 5148 | msgstr "" |
5088 | "прави Ñеновити Ð·Ð°Ð¿Ð¸Ñ (важи Ñамо ако Ñу Ñви оÑтали запиÑи иÑте врÑте иÑтекли" | 5149 | "прави Ñеновити Ð·Ð°Ð¿Ð¸Ñ (важи Ñамо ако Ñу Ñви оÑтали запиÑи иÑте врÑте иÑтекли" |
5089 | 5150 | ||
5090 | #: src/namestore/gnunet-namestore.c:1687 | 5151 | #: src/namestore/gnunet-namestore.c:1637 |
5091 | msgid "name of the ego controlling the zone" | 5152 | msgid "name of the ego controlling the zone" |
5092 | msgstr "назив егоа који контролише зону" | 5153 | msgstr "назив егоа који контролише зону" |
5093 | 5154 | ||
5094 | #: src/namestore/gnunet-service-namestore.c:871 | 5155 | #: src/namestore/gnunet-service-namestore.c:879 |
5095 | #, c-format | 5156 | #, c-format |
5096 | msgid "Failed to replicate block in namecache: %s\n" | 5157 | msgid "Failed to replicate block in namecache: %s\n" |
5097 | msgstr "ÐиÑам уÑпео да реплицирам блок у оÑтави назива: %s\n" | 5158 | msgstr "ÐиÑам уÑпео да реплицирам блок у оÑтави назива: %s\n" |
5098 | 5159 | ||
5160 | #: src/namestore/gnunet-service-namestore.c:1668 | ||
5161 | #, fuzzy | ||
5162 | msgid "Store failed" | ||
5163 | msgstr "# ÐеуÑпеÑи „СТÐВИ“ Ñмештаја података" | ||
5164 | |||
5099 | #: src/namestore/gnunet-zoneimport.c:1847 | 5165 | #: src/namestore/gnunet-zoneimport.c:1847 |
5100 | msgid "size to use for the main hash map" | 5166 | msgid "size to use for the main hash map" |
5101 | msgstr "" | 5167 | msgstr "" |
@@ -5104,10 +5170,6 @@ msgstr "" | |||
5104 | msgid "minimum expiration time we assume for imported records" | 5170 | msgid "minimum expiration time we assume for imported records" |
5105 | msgstr "" | 5171 | msgstr "" |
5106 | 5172 | ||
5107 | #: src/namestore/namestore_api.c:373 | ||
5108 | msgid "Namestore failed to store record\n" | ||
5109 | msgstr "Смештај назива није уÑпео да ÑмеÑти запиÑ\n" | ||
5110 | |||
5111 | #: src/namestore/plugin_namestore_flat.c:195 | 5173 | #: src/namestore/plugin_namestore_flat.c:195 |
5112 | #, c-format | 5174 | #, c-format |
5113 | msgid "File too big to map: %llu bytes.\n" | 5175 | msgid "File too big to map: %llu bytes.\n" |
@@ -5699,6 +5761,51 @@ msgstr "ÐиÑам уÑпео да Ñе повежем Ñа „%s“ уÑлугР| |||
5699 | msgid "Daemon to run to perform IP protocol translation to GNUnet" | 5761 | msgid "Daemon to run to perform IP protocol translation to GNUnet" |
5700 | msgstr "Демон за покретање за обављање превода ИП протокола у ГÐУнет" | 5762 | msgstr "Демон за покретање за обављање превода ИП протокола у ГÐУнет" |
5701 | 5763 | ||
5764 | #: src/reclaim/gnunet-did.c:209 | ||
5765 | #, fuzzy, c-format | ||
5766 | msgid "Invalid DID `%s'\n" | ||
5767 | msgstr "ÐеиÑправан УРИ „%s“\n" | ||
5768 | |||
5769 | #: src/reclaim/gnunet-did.c:835 | ||
5770 | msgid "Create a DID Document and display its DID" | ||
5771 | msgstr "" | ||
5772 | |||
5773 | #: src/reclaim/gnunet-did.c:840 | ||
5774 | msgid "Get the DID Document associated with the given DID" | ||
5775 | msgstr "" | ||
5776 | |||
5777 | #: src/reclaim/gnunet-did.c:844 | ||
5778 | msgid "Show the DID for a given ego" | ||
5779 | msgstr "" | ||
5780 | |||
5781 | #: src/reclaim/gnunet-did.c:849 | ||
5782 | msgid "Remove the DID" | ||
5783 | msgstr "" | ||
5784 | |||
5785 | #: src/reclaim/gnunet-did.c:853 src/reclaim/gnunet-did.c:857 | ||
5786 | msgid "Replace the DID Document." | ||
5787 | msgstr "" | ||
5788 | |||
5789 | #: src/reclaim/gnunet-did.c:863 | ||
5790 | msgid "The Decentralized Identity (DID)" | ||
5791 | msgstr "" | ||
5792 | |||
5793 | #: src/reclaim/gnunet-did.c:869 | ||
5794 | msgid "The DID Document to store in GNUNET" | ||
5795 | msgstr "" | ||
5796 | |||
5797 | #: src/reclaim/gnunet-did.c:874 | ||
5798 | msgid "The name of the EGO" | ||
5799 | msgstr "" | ||
5800 | |||
5801 | #: src/reclaim/gnunet-did.c:880 | ||
5802 | msgid "The time until the DID Document is going to expire (e.g. 5d)" | ||
5803 | msgstr "" | ||
5804 | |||
5805 | #: src/reclaim/gnunet-did.c:889 | ||
5806 | msgid "Manage Decentralized Identities (DIDs)" | ||
5807 | msgstr "" | ||
5808 | |||
5702 | #: src/reclaim/gnunet-reclaim.c:802 | 5809 | #: src/reclaim/gnunet-reclaim.c:802 |
5703 | #, fuzzy, c-format | 5810 | #, fuzzy, c-format |
5704 | msgid "Ego is required\n" | 5811 | msgid "Ego is required\n" |
@@ -6622,17 +6729,17 @@ msgstr "" | |||
6622 | "Број ивица које Ñе могу уÑпоÑтавити приликом додавања новог чвора у " | 6729 | "Број ивица које Ñе могу уÑпоÑтавити приликом додавања новог чвора у " |
6623 | "Ñлободном размештају леÑтвице не може бити већи од %u. Дато је „%s = %llu“" | 6730 | "Ñлободном размештају леÑтвице не може бити већи од %u. Дато је „%s = %llu“" |
6624 | 6731 | ||
6625 | #: src/testbed/testbed_api_topology.c:1033 src/testing/testing.c:2643 | 6732 | #: src/testbed/testbed_api_topology.c:1033 src/testing/testing.c:2657 |
6626 | #, c-format | 6733 | #, c-format |
6627 | msgid "Topology file %s not found\n" | 6734 | msgid "Topology file %s not found\n" |
6628 | msgstr "ÐиÑам нашао датотеку размештаја „%s“\n" | 6735 | msgstr "ÐиÑам нашао датотеку размештаја „%s“\n" |
6629 | 6736 | ||
6630 | #: src/testbed/testbed_api_topology.c:1041 src/testing/testing.c:2651 | 6737 | #: src/testbed/testbed_api_topology.c:1041 src/testing/testing.c:2665 |
6631 | #, c-format | 6738 | #, c-format |
6632 | msgid "Topology file %s has no data\n" | 6739 | msgid "Topology file %s has no data\n" |
6633 | msgstr "Датотека размештаја „%s“ нема података\n" | 6740 | msgstr "Датотека размештаја „%s“ нема података\n" |
6634 | 6741 | ||
6635 | #: src/testbed/testbed_api_topology.c:1049 src/testing/testing.c:2659 | 6742 | #: src/testbed/testbed_api_topology.c:1049 src/testing/testing.c:2673 |
6636 | #, c-format | 6743 | #, c-format |
6637 | msgid "Topology file %s cannot be read\n" | 6744 | msgid "Topology file %s cannot be read\n" |
6638 | msgstr "Ðе могу да прочитам датотеку размештаја „%s“\n" | 6745 | msgstr "Ðе могу да прочитам датотеку размештаја „%s“\n" |
@@ -6847,7 +6954,7 @@ msgstr "" | |||
6847 | 6954 | ||
6848 | #: src/transport/gnunet-communicator-tcp.c:3338 | 6955 | #: src/transport/gnunet-communicator-tcp.c:3338 |
6849 | #: src/transport/gnunet-communicator-udp.c:3856 | 6956 | #: src/transport/gnunet-communicator-udp.c:3856 |
6850 | #: src/transport/gnunet-service-tng.c:10512 | 6957 | #: src/transport/gnunet-service-tng.c:10623 |
6851 | #: src/transport/gnunet-service-transport.c:2627 | 6958 | #: src/transport/gnunet-service-transport.c:2627 |
6852 | msgid "Transport service is lacking key configuration settings. Exiting.\n" | 6959 | msgid "Transport service is lacking key configuration settings. Exiting.\n" |
6853 | msgstr "УÑлузи преноÑа недоÑтају поÑтавке подешавања кључа. Излазим.\n" | 6960 | msgstr "УÑлузи преноÑа недоÑтају поÑтавке подешавања кључа. Излазим.\n" |
@@ -8085,58 +8192,58 @@ msgstr "" | |||
8085 | msgid "Need a non-empty hostname for service `%s'.\n" | 8192 | msgid "Need a non-empty hostname for service `%s'.\n" |
8086 | msgstr "Потребан је не-празан назив домаћина за уÑлугу „%s“.\n" | 8193 | msgstr "Потребан је не-празан назив домаћина за уÑлугу „%s“.\n" |
8087 | 8194 | ||
8088 | #: src/util/common_logging.c:626 src/util/common_logging.c:665 | 8195 | #: src/util/common_logging.c:648 src/util/common_logging.c:687 |
8089 | #, c-format | 8196 | #, c-format |
8090 | msgid "ERROR: Unable to parse log definition: Syntax error at `%s'.\n" | 8197 | msgid "ERROR: Unable to parse log definition: Syntax error at `%s'.\n" |
8091 | msgstr "" | 8198 | msgstr "" |
8092 | 8199 | ||
8093 | #: src/util/common_logging.c:904 | 8200 | #: src/util/common_logging.c:926 |
8094 | #, c-format | 8201 | #, c-format |
8095 | msgid "Message `%.*s' repeated %u times in the last %s\n" | 8202 | msgid "Message `%.*s' repeated %u times in the last %s\n" |
8096 | msgstr "Порука „%.*s“ је поновљена %u пута у прошлоÑти %s\n" | 8203 | msgstr "Порука „%.*s“ је поновљена %u пута у прошлоÑти %s\n" |
8097 | 8204 | ||
8098 | #: src/util/common_logging.c:1108 | 8205 | #: src/util/common_logging.c:1131 |
8099 | msgid "ERROR" | 8206 | msgid "ERROR" |
8100 | msgstr "ГРЕШКÐ" | 8207 | msgstr "ГРЕШКÐ" |
8101 | 8208 | ||
8102 | #: src/util/common_logging.c:1110 | 8209 | #: src/util/common_logging.c:1133 |
8103 | msgid "WARNING" | 8210 | msgid "WARNING" |
8104 | msgstr "УПОЗОРЕЊЕ" | 8211 | msgstr "УПОЗОРЕЊЕ" |
8105 | 8212 | ||
8106 | #: src/util/common_logging.c:1112 | 8213 | #: src/util/common_logging.c:1135 |
8107 | msgid "MESSAGE" | 8214 | msgid "MESSAGE" |
8108 | msgstr "" | 8215 | msgstr "" |
8109 | 8216 | ||
8110 | #: src/util/common_logging.c:1114 | 8217 | #: src/util/common_logging.c:1137 |
8111 | msgid "INFO" | 8218 | msgid "INFO" |
8112 | msgstr "ПОДÐЦИ" | 8219 | msgstr "ПОДÐЦИ" |
8113 | 8220 | ||
8114 | #: src/util/common_logging.c:1116 | 8221 | #: src/util/common_logging.c:1139 |
8115 | msgid "DEBUG" | 8222 | msgid "DEBUG" |
8116 | msgstr "ПРОЧИШЋÐÐ’ÐЊЕ" | 8223 | msgstr "ПРОЧИШЋÐÐ’ÐЊЕ" |
8117 | 8224 | ||
8118 | #: src/util/common_logging.c:1118 | 8225 | #: src/util/common_logging.c:1141 |
8119 | msgid "NONE" | 8226 | msgid "NONE" |
8120 | msgstr "ÐИШТÐ" | 8227 | msgstr "ÐИШТÐ" |
8121 | 8228 | ||
8122 | #: src/util/common_logging.c:1119 | 8229 | #: src/util/common_logging.c:1142 |
8123 | msgid "INVALID" | 8230 | msgid "INVALID" |
8124 | msgstr "ÐЕИСПРÐÐ’ÐО" | 8231 | msgstr "ÐЕИСПРÐÐ’ÐО" |
8125 | 8232 | ||
8126 | #: src/util/common_logging.c:1400 | 8233 | #: src/util/common_logging.c:1423 |
8127 | msgid "unknown address" | 8234 | msgid "unknown address" |
8128 | msgstr "непозната адреÑа" | 8235 | msgstr "непозната адреÑа" |
8129 | 8236 | ||
8130 | #: src/util/common_logging.c:1445 | 8237 | #: src/util/common_logging.c:1468 |
8131 | msgid "invalid address" | 8238 | msgid "invalid address" |
8132 | msgstr "неиÑправна адреÑа" | 8239 | msgstr "неиÑправна адреÑа" |
8133 | 8240 | ||
8134 | #: src/util/common_logging.c:1464 | 8241 | #: src/util/common_logging.c:1487 |
8135 | #, c-format | 8242 | #, c-format |
8136 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" | 8243 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" |
8137 | msgstr "Подешавање није уÑпело да наведе опцију „%s“ у одељку „%s“!\n" | 8244 | msgstr "Подешавање није уÑпело да наведе опцију „%s“ у одељку „%s“!\n" |
8138 | 8245 | ||
8139 | #: src/util/common_logging.c:1487 | 8246 | #: src/util/common_logging.c:1510 |
8140 | #, c-format | 8247 | #, c-format |
8141 | msgid "" | 8248 | msgid "" |
8142 | "Configuration specifies invalid value for option `%s' in section `%s': %s\n" | 8249 | "Configuration specifies invalid value for option `%s' in section `%s': %s\n" |
@@ -8288,17 +8395,17 @@ msgstr "ÐиÑам уÑпео да претворим УТФ-8 назив „%sâ | |||
8288 | msgid "Could not bind to any port: %s\n" | 8395 | msgid "Could not bind to any port: %s\n" |
8289 | msgstr "Ðе могу да Ñе вежем ни за један прикључник: %s\n" | 8396 | msgstr "Ðе могу да Ñе вежем ни за један прикључник: %s\n" |
8290 | 8397 | ||
8291 | #: src/util/dnsstub.c:344 | 8398 | #: src/util/dnsstub.c:370 |
8292 | #, c-format | 8399 | #, fuzzy, c-format |
8293 | msgid "Received DNS response that is too small (%u bytes)" | 8400 | msgid "Received DNS response that is too small (%u bytes)\n" |
8294 | msgstr "Примих ДÐС одговор који је премали (%u бајта)" | 8401 | msgstr "Примих ДÐС одговор који је премали (%u бајта)" |
8295 | 8402 | ||
8296 | #: src/util/dnsstub.c:482 | 8403 | #: src/util/dnsstub.c:508 |
8297 | #, fuzzy, c-format | 8404 | #, fuzzy, c-format |
8298 | msgid "Failed to send DNS request to %s: %s\n" | 8405 | msgid "Failed to send DNS request to %s: %s\n" |
8299 | msgstr "ÐиÑам уÑпео да пошаљем ДÐС захтев за %s\n" | 8406 | msgstr "ÐиÑам уÑпео да пошаљем ДÐС захтев за %s\n" |
8300 | 8407 | ||
8301 | #: src/util/dnsstub.c:487 | 8408 | #: src/util/dnsstub.c:513 |
8302 | #, c-format | 8409 | #, c-format |
8303 | msgid "Sent DNS request to %s\n" | 8410 | msgid "Sent DNS request to %s\n" |
8304 | msgstr "ПоÑлао Ñам ДÐС захтев за %s\n" | 8411 | msgstr "ПоÑлао Ñам ДÐС захтев за %s\n" |
@@ -8384,83 +8491,83 @@ msgid "" | |||
8384 | msgstr "" | 8491 | msgstr "" |
8385 | "Ðргументи обавезни за дуге опције Ñу такође обавезни за кратке опције.\n" | 8492 | "Ðргументи обавезни за дуге опције Ñу такође обавезни за кратке опције.\n" |
8386 | 8493 | ||
8387 | #: src/util/getopt_helpers.c:196 | 8494 | #: src/util/getopt_helpers.c:197 |
8388 | msgid "print this help" | 8495 | msgid "print this help" |
8389 | msgstr "" | 8496 | msgstr "" |
8390 | 8497 | ||
8391 | #: src/util/getopt_helpers.c:261 | 8498 | #: src/util/getopt_helpers.c:262 |
8392 | msgid "be verbose" | 8499 | msgid "be verbose" |
8393 | msgstr "" | 8500 | msgstr "" |
8394 | 8501 | ||
8395 | #: src/util/getopt_helpers.c:377 | 8502 | #: src/util/getopt_helpers.c:378 |
8396 | msgid "configure logging to use LOGLEVEL" | 8503 | msgid "configure logging to use LOGLEVEL" |
8397 | msgstr "" | 8504 | msgstr "" |
8398 | 8505 | ||
8399 | #: src/util/getopt_helpers.c:444 | 8506 | #: src/util/getopt_helpers.c:445 |
8400 | msgid "configure logging to write logs to FILENAME" | 8507 | msgid "configure logging to write logs to FILENAME" |
8401 | msgstr "" | 8508 | msgstr "" |
8402 | 8509 | ||
8403 | #: src/util/getopt_helpers.c:461 | 8510 | #: src/util/getopt_helpers.c:462 |
8404 | #, fuzzy | 8511 | #, fuzzy |
8405 | msgid "use configuration file FILENAME" | 8512 | msgid "use configuration file FILENAME" |
8406 | msgstr "Ñтвара јединÑтвене датотеке подешавања" | 8513 | msgstr "Ñтвара јединÑтвене датотеке подешавања" |
8407 | 8514 | ||
8408 | #: src/util/getopt_helpers.c:497 src/util/getopt_helpers.c:811 | 8515 | #: src/util/getopt_helpers.c:498 src/util/getopt_helpers.c:812 |
8409 | #: src/util/getopt_helpers.c:867 | 8516 | #: src/util/getopt_helpers.c:868 |
8410 | #, c-format | 8517 | #, c-format |
8411 | msgid "You must pass a number to the `%s' option.\n" | 8518 | msgid "You must pass a number to the `%s' option.\n" |
8412 | msgstr "Морате да проÑледите број опцији „%s“.\n" | 8519 | msgstr "Морате да проÑледите број опцији „%s“.\n" |
8413 | 8520 | ||
8414 | #: src/util/getopt_helpers.c:569 | 8521 | #: src/util/getopt_helpers.c:570 |
8415 | #, fuzzy, c-format | 8522 | #, fuzzy, c-format |
8416 | msgid "" | 8523 | msgid "" |
8417 | "You must pass a relative time (optionally with sign) to the `%s' option.\n" | 8524 | "You must pass a relative time (optionally with sign) to the `%s' option.\n" |
8418 | msgstr "Морате да проÑледите релативно време опцији „%s“.\n" | 8525 | msgstr "Морате да проÑледите релативно време опцији „%s“.\n" |
8419 | 8526 | ||
8420 | #: src/util/getopt_helpers.c:576 | 8527 | #: src/util/getopt_helpers.c:577 |
8421 | #, c-format | 8528 | #, c-format |
8422 | msgid "Value given for time travel `%s' option is too big.\n" | 8529 | msgid "Value given for time travel `%s' option is too big.\n" |
8423 | msgstr "" | 8530 | msgstr "" |
8424 | 8531 | ||
8425 | #: src/util/getopt_helpers.c:594 | 8532 | #: src/util/getopt_helpers.c:595 |
8426 | msgid "[+/-]MICROSECONDS" | 8533 | msgid "[+/-]MICROSECONDS" |
8427 | msgstr "" | 8534 | msgstr "" |
8428 | 8535 | ||
8429 | #: src/util/getopt_helpers.c:596 | 8536 | #: src/util/getopt_helpers.c:597 |
8430 | msgid "modify system time by given offset (for debugging/testing only)" | 8537 | msgid "modify system time by given offset (for debugging/testing only)" |
8431 | msgstr "" | 8538 | msgstr "" |
8432 | 8539 | ||
8433 | #: src/util/getopt_helpers.c:630 | 8540 | #: src/util/getopt_helpers.c:631 |
8434 | #, c-format | 8541 | #, c-format |
8435 | msgid "You must pass relative time to the `%s' option.\n" | 8542 | msgid "You must pass relative time to the `%s' option.\n" |
8436 | msgstr "Морате да проÑледите релативно време опцији „%s“.\n" | 8543 | msgstr "Морате да проÑледите релативно време опцији „%s“.\n" |
8437 | 8544 | ||
8438 | #: src/util/getopt_helpers.c:684 | 8545 | #: src/util/getopt_helpers.c:685 |
8439 | #, fuzzy, c-format | 8546 | #, fuzzy, c-format |
8440 | msgid "You must pass absolute time to the `%s' option.\n" | 8547 | msgid "You must pass absolute time to the `%s' option.\n" |
8441 | msgstr "Морате да проÑледите релативно време опцији „%s“.\n" | 8548 | msgstr "Морате да проÑледите релативно време опцији „%s“.\n" |
8442 | 8549 | ||
8443 | #: src/util/getopt_helpers.c:741 | 8550 | #: src/util/getopt_helpers.c:742 |
8444 | #, fuzzy, c-format | 8551 | #, fuzzy, c-format |
8445 | msgid "You must pass a timestamp to the `%s' option.\n" | 8552 | msgid "You must pass a timestamp to the `%s' option.\n" |
8446 | msgstr "Морате да проÑледите број опцији „%s“.\n" | 8553 | msgstr "Морате да проÑледите број опцији „%s“.\n" |
8447 | 8554 | ||
8448 | #: src/util/getopt_helpers.c:748 | 8555 | #: src/util/getopt_helpers.c:749 |
8449 | #, c-format | 8556 | #, c-format |
8450 | msgid "The maximum precision allowed for timestamps is seconds.\n" | 8557 | msgid "The maximum precision allowed for timestamps is seconds.\n" |
8451 | msgstr "" | 8558 | msgstr "" |
8452 | 8559 | ||
8453 | #: src/util/getopt_helpers.c:804 | 8560 | #: src/util/getopt_helpers.c:805 |
8454 | #, c-format | 8561 | #, c-format |
8455 | msgid "Your input for the '%s' option has to be a non negative number\n" | 8562 | msgid "Your input for the '%s' option has to be a non negative number\n" |
8456 | msgstr "" | 8563 | msgstr "" |
8457 | 8564 | ||
8458 | #: src/util/getopt_helpers.c:874 | 8565 | #: src/util/getopt_helpers.c:875 |
8459 | #, fuzzy, c-format | 8566 | #, fuzzy, c-format |
8460 | msgid "You must pass a number below %u to the `%s' option.\n" | 8567 | msgid "You must pass a number below %u to the `%s' option.\n" |
8461 | msgstr "Морате да проÑледите број опцији „%s“.\n" | 8568 | msgstr "Морате да проÑледите број опцији „%s“.\n" |
8462 | 8569 | ||
8463 | #: src/util/getopt_helpers.c:952 | 8570 | #: src/util/getopt_helpers.c:953 |
8464 | #, c-format | 8571 | #, c-format |
8465 | msgid "Argument `%s' malformed. Expected base32 (Crockford) encoded value.\n" | 8572 | msgid "Argument `%s' malformed. Expected base32 (Crockford) encoded value.\n" |
8466 | msgstr "" | 8573 | msgstr "" |
@@ -8493,7 +8600,7 @@ msgstr "" | |||
8493 | msgid "Manipulate GNUnet configuration files" | 8600 | msgid "Manipulate GNUnet configuration files" |
8494 | msgstr "Управља ГÐУнет датотекама подешавања" | 8601 | msgstr "Управља ГÐУнет датотекама подешавања" |
8495 | 8602 | ||
8496 | #: src/util/gnunet-crypto-tvg.c:1072 | 8603 | #: src/util/gnunet-crypto-tvg.c:1483 |
8497 | msgid "verify a test vector from stdin" | 8604 | msgid "verify a test vector from stdin" |
8498 | msgstr "" | 8605 | msgstr "" |
8499 | 8606 | ||
@@ -8755,7 +8862,7 @@ msgid "Unable to shorten unix path `%s' while keeping name unique\n" | |||
8755 | msgstr "" | 8862 | msgstr "" |
8756 | "Ðе могу да Ñкратим Ñ˜ÑƒÐ½Ð¸ÐºÑ Ð¿ÑƒÑ‚Ð°ÑšÑƒ „%s“ док задржавам назив јединÑтвеним\n" | 8863 | "Ðе могу да Ñкратим Ñ˜ÑƒÐ½Ð¸ÐºÑ Ð¿ÑƒÑ‚Ð°ÑšÑƒ „%s“ док задржавам назив јединÑтвеним\n" |
8757 | 8864 | ||
8758 | #: src/util/network.c:1306 | 8865 | #: src/util/network.c:1307 |
8759 | #, c-format | 8866 | #, c-format |
8760 | msgid "" | 8867 | msgid "" |
8761 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" | 8868 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" |
@@ -8890,78 +8997,78 @@ msgstr "" | |||
8890 | msgid "Character sets requested were `%s'->`%s'\n" | 8997 | msgid "Character sets requested were `%s'->`%s'\n" |
8891 | msgstr "Скупови знакова Ñе захтевају где је „%s“–>„%s“\n" | 8998 | msgstr "Скупови знакова Ñе захтевају где је „%s“–>„%s“\n" |
8892 | 8999 | ||
8893 | #: src/util/strings.c:487 | 9000 | #: src/util/strings.c:514 |
8894 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" | 9001 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" |
8895 | msgstr "" | 9002 | msgstr "" |
8896 | "ÐиÑам уÑпео да раширим „$HOME“: променљива окружења „HOME“ није поÑтављена" | 9003 | "ÐиÑам уÑпео да раширим „$HOME“: променљива окружења „HOME“ није поÑтављена" |
8897 | 9004 | ||
8898 | #: src/util/strings.c:1023 | 9005 | #: src/util/strings.c:1050 |
8899 | msgid "IPv6 address did not start with `['\n" | 9006 | msgid "IPv6 address did not start with `['\n" |
8900 | msgstr "ИПв6 адреÑа не почиње Ñа [\n" | 9007 | msgstr "ИПв6 адреÑа не почиње Ñа [\n" |
8901 | 9008 | ||
8902 | #: src/util/strings.c:1031 | 9009 | #: src/util/strings.c:1058 |
8903 | msgid "IPv6 address did contain ':' to separate port number\n" | 9010 | msgid "IPv6 address did contain ':' to separate port number\n" |
8904 | msgstr "ИПв6 адреÑа Ñадржи : за раздвајање броја прикључника\n" | 9011 | msgstr "ИПв6 адреÑа Ñадржи : за раздвајање броја прикључника\n" |
8905 | 9012 | ||
8906 | #: src/util/strings.c:1038 | 9013 | #: src/util/strings.c:1065 |
8907 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" | 9014 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" |
8908 | msgstr "ИПв6 адреÑа Ñадржи ] пре : за раздвајање броја прикључника\n" | 9015 | msgstr "ИПв6 адреÑа Ñадржи ] пре : за раздвајање броја прикључника\n" |
8909 | 9016 | ||
8910 | #: src/util/strings.c:1046 | 9017 | #: src/util/strings.c:1073 |
8911 | msgid "IPv6 address did contain a valid port number after the last ':'\n" | 9018 | msgid "IPv6 address did contain a valid port number after the last ':'\n" |
8912 | msgstr "ИПв6 адреÑа Ñадржи иÑправан број прикључника након поÑледње „:“\n" | 9019 | msgstr "ИПв6 адреÑа Ñадржи иÑправан број прикључника након поÑледње „:“\n" |
8913 | 9020 | ||
8914 | #: src/util/strings.c:1055 | 9021 | #: src/util/strings.c:1082 |
8915 | #, c-format | 9022 | #, c-format |
8916 | msgid "Invalid IPv6 address `%s': %s\n" | 9023 | msgid "Invalid IPv6 address `%s': %s\n" |
8917 | msgstr "ÐеиÑправна ИПв6 адреÑа „%s“: %s\n" | 9024 | msgstr "ÐеиÑправна ИПв6 адреÑа „%s“: %s\n" |
8918 | 9025 | ||
8919 | #: src/util/strings.c:1237 src/util/strings.c:1248 | 9026 | #: src/util/strings.c:1264 src/util/strings.c:1275 |
8920 | msgid "Port not in range\n" | 9027 | msgid "Port not in range\n" |
8921 | msgstr "Прикључник није у опÑегу\n" | 9028 | msgstr "Прикључник није у опÑегу\n" |
8922 | 9029 | ||
8923 | #: src/util/strings.c:1257 | 9030 | #: src/util/strings.c:1284 |
8924 | #, c-format | 9031 | #, c-format |
8925 | msgid "Malformed port policy `%s'\n" | 9032 | msgid "Malformed port policy `%s'\n" |
8926 | msgstr "Лоша политика прикључника „%s“\n" | 9033 | msgstr "Лоша политика прикључника „%s“\n" |
8927 | 9034 | ||
8928 | #: src/util/strings.c:1328 src/util/strings.c:1357 src/util/strings.c:1404 | 9035 | #: src/util/strings.c:1355 src/util/strings.c:1384 src/util/strings.c:1431 |
8929 | #: src/util/strings.c:1424 | 9036 | #: src/util/strings.c:1451 |
8930 | #, c-format | 9037 | #, c-format |
8931 | msgid "Invalid format for IP: `%s'\n" | 9038 | msgid "Invalid format for IP: `%s'\n" |
8932 | msgstr "ÐеиÑправан формат за ИП: „%s“\n" | 9039 | msgstr "ÐеиÑправан формат за ИП: „%s“\n" |
8933 | 9040 | ||
8934 | #: src/util/strings.c:1382 | 9041 | #: src/util/strings.c:1409 |
8935 | #, c-format | 9042 | #, c-format |
8936 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." | 9043 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." |
8937 | msgstr "ÐеиÑправна напомена мреже („/%d“ није иÑправно у ИПв4 ЦИДР-у)." | 9044 | msgstr "ÐеиÑправна напомена мреже („/%d“ није иÑправно у ИПв4 ЦИДР-у)." |
8938 | 9045 | ||
8939 | #: src/util/strings.c:1433 | 9046 | #: src/util/strings.c:1460 |
8940 | #, c-format | 9047 | #, c-format |
8941 | msgid "Invalid format: `%s'\n" | 9048 | msgid "Invalid format: `%s'\n" |
8942 | msgstr "ÐеиÑправан формат: „%s“\n" | 9049 | msgstr "ÐеиÑправан формат: „%s“\n" |
8943 | 9050 | ||
8944 | #: src/util/strings.c:1475 | 9051 | #: src/util/strings.c:1502 |
8945 | #, c-format | 9052 | #, c-format |
8946 | msgid "Invalid network notation (does not end with ';': `%s')\n" | 9053 | msgid "Invalid network notation (does not end with ';': `%s')\n" |
8947 | msgstr "ÐеиÑправна напомена мреже (не завршава Ñе Ñа „;“: „%s“)\n" | 9054 | msgstr "ÐеиÑправна напомена мреже (не завршава Ñе Ñа „;“: „%s“)\n" |
8948 | 9055 | ||
8949 | #: src/util/strings.c:1525 | 9056 | #: src/util/strings.c:1552 |
8950 | #, c-format | 9057 | #, c-format |
8951 | msgid "Wrong format `%s' for netmask\n" | 9058 | msgid "Wrong format `%s' for netmask\n" |
8952 | msgstr "Погрешан формат „%s“ за мрежну маÑку\n" | 9059 | msgstr "Погрешан формат „%s“ за мрежну маÑку\n" |
8953 | 9060 | ||
8954 | #: src/util/strings.c:1556 | 9061 | #: src/util/strings.c:1583 |
8955 | #, c-format | 9062 | #, c-format |
8956 | msgid "Wrong format `%s' for network\n" | 9063 | msgid "Wrong format `%s' for network\n" |
8957 | msgstr "Погрешан формат „%s“ за мрежу\n" | 9064 | msgstr "Погрешан формат „%s“ за мрежу\n" |
8958 | 9065 | ||
8959 | #: src/util/time.c:863 src/util/time.c:891 | 9066 | #: src/util/time.c:870 src/util/time.c:898 |
8960 | #, c-format | 9067 | #, c-format |
8961 | msgid "Failed to map `%s', cannot assure monotonic time!\n" | 9068 | msgid "Failed to map `%s', cannot assure monotonic time!\n" |
8962 | msgstr "" | 9069 | msgstr "" |
8963 | 9070 | ||
8964 | #: src/util/time.c:899 | 9071 | #: src/util/time.c:906 |
8965 | #, c-format | 9072 | #, c-format |
8966 | msgid "" | 9073 | msgid "" |
8967 | "Failed to setup monotonic time file `%s', cannot assure monotonic time!\n" | 9074 | "Failed to setup monotonic time file `%s', cannot assure monotonic time!\n" |
@@ -9137,11 +9244,41 @@ msgstr "уÑлуга Ñе нуди путем УДП-ом" | |||
9137 | msgid "Setup tunnels via VPN." | 9244 | msgid "Setup tunnels via VPN." |
9138 | msgstr "ПоÑтавља тунеле путем ВПÐ-а." | 9245 | msgstr "ПоÑтавља тунеле путем ВПÐ-а." |
9139 | 9246 | ||
9140 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:418 | 9247 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:397 |
9141 | #: src/zonemaster/gnunet-service-zonemaster.c:847 | 9248 | #: src/zonemaster/gnunet-service-zonemaster.c:832 |
9142 | msgid "Failed to connect to the namestore!\n" | 9249 | msgid "Failed to connect to the namestore!\n" |
9143 | msgstr "ÐиÑам уÑпео да Ñе повежем Ñа Ñмештајем назива!\n" | 9250 | msgstr "ÐиÑам уÑпео да Ñе повежем Ñа Ñмештајем назива!\n" |
9144 | 9251 | ||
9252 | #~ msgid "# items stored" | ||
9253 | #~ msgstr "# Ñтавке Ñу Ñмештене" | ||
9254 | |||
9255 | #, c-format | ||
9256 | #~ msgid "Loading `%s' datacache plugin\n" | ||
9257 | #~ msgstr "Учитавам прикључак „%s“ оÑтаве података\n" | ||
9258 | |||
9259 | #, c-format | ||
9260 | #~ msgid "Failed to load datacache plugin for `%s'\n" | ||
9261 | #~ msgstr "ÐиÑам уÑпео да учитам прикључак оÑтаве података за „%s“\n" | ||
9262 | |||
9263 | #~ msgid "# requests received" | ||
9264 | #~ msgstr "# захтеви Ñу примљени" | ||
9265 | |||
9266 | #~ msgid "# requests filtered by bloom filter" | ||
9267 | #~ msgstr "# захтеви Ñу филтрирани блум филтером" | ||
9268 | |||
9269 | #, fuzzy | ||
9270 | #~ msgid "# proximity search requests received" | ||
9271 | #~ msgstr "# претраге клијента Ñу примљене" | ||
9272 | |||
9273 | #~ msgid "write search results to file starting with PREFIX" | ||
9274 | #~ msgstr "пише резултате претраге у датотеку која почиње Ñа ПРЕФИКСОМ" | ||
9275 | |||
9276 | #~ msgid "automatically terminate search after DELAY" | ||
9277 | #~ msgstr "ÑамоÑтално окончава претрагу након ЗÐСТОЈÐ" | ||
9278 | |||
9279 | #~ msgid "Namestore failed to store record\n" | ||
9280 | #~ msgstr "Смештај назива није уÑпео да ÑмеÑти запиÑ\n" | ||
9281 | |||
9145 | #, fuzzy | 9282 | #, fuzzy |
9146 | #~ msgid "# requests for random value received" | 9283 | #~ msgid "# requests for random value received" |
9147 | #~ msgstr "# захтеви Ñу примљени" | 9284 | #~ msgstr "# захтеви Ñу примљени" |
@@ -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: 2022-01-10 15:13+0100\n" | 10 | "POT-Creation-Date: 2022-03-04 22:23+0100\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" |
@@ -16,7 +16,7 @@ msgstr "" | |||
16 | "Content-Type: text/plain; charset=UTF-8\n" | 16 | "Content-Type: text/plain; charset=UTF-8\n" |
17 | "Content-Transfer-Encoding: 8bit\n" | 17 | "Content-Transfer-Encoding: 8bit\n" |
18 | 18 | ||
19 | #: src/abd/gnunet-abd.c:392 src/namestore/gnunet-namestore.c:1304 | 19 | #: src/abd/gnunet-abd.c:392 src/namestore/gnunet-namestore.c:1254 |
20 | #, fuzzy, c-format | 20 | #, fuzzy, c-format |
21 | msgid "Ego `%s' not known to identity service\n" | 21 | msgid "Ego `%s' not known to identity service\n" |
22 | msgstr "\"%s\": okänd tjänst: %s\n" | 22 | msgstr "\"%s\": okänd tjänst: %s\n" |
@@ -28,7 +28,7 @@ msgstr "Ogiltigt argument: \"%s\"\n" | |||
28 | 28 | ||
29 | #: src/abd/gnunet-abd.c:558 src/abd/gnunet-service-abd.c:1751 | 29 | #: src/abd/gnunet-abd.c:558 src/abd/gnunet-service-abd.c:1751 |
30 | #: src/namestore/gnunet-namestore-fcfsd.c:1080 | 30 | #: src/namestore/gnunet-namestore-fcfsd.c:1080 |
31 | #: src/namestore/gnunet-namestore.c:1001 | 31 | #: src/namestore/gnunet-namestore.c:951 |
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" |
@@ -628,45 +628,45 @@ msgstr "" | |||
628 | msgid "Print information about ATS state" | 628 | msgid "Print information about ATS state" |
629 | msgstr "Skriv ut information om GNUnets motparter." | 629 | msgstr "Skriv ut information om GNUnets motparter." |
630 | 630 | ||
631 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | 631 | #: src/ats/gnunet-ats-solver-eval.c:2993 src/ats/gnunet-ats-solver-eval.c:3045 |
632 | #, c-format | 632 | #, c-format |
633 | msgid "" | 633 | msgid "" |
634 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | 634 | "Could not load quota for network `%s': `%s', assigning default bandwidth " |
635 | "%llu\n" | 635 | "%llu\n" |
636 | msgstr "" | 636 | msgstr "" |
637 | 637 | ||
638 | #: src/ats/gnunet-ats-solver-eval.c:3011 | 638 | #: src/ats/gnunet-ats-solver-eval.c:3012 |
639 | #, c-format | 639 | #, c-format |
640 | msgid "" | 640 | msgid "" |
641 | "No outbound quota configured for network `%s', assigning default bandwidth " | 641 | "No outbound quota configured for network `%s', assigning default bandwidth " |
642 | "%llu\n" | 642 | "%llu\n" |
643 | msgstr "" | 643 | msgstr "" |
644 | 644 | ||
645 | #: src/ats/gnunet-ats-solver-eval.c:3063 | 645 | #: src/ats/gnunet-ats-solver-eval.c:3064 |
646 | #, c-format | 646 | #, c-format |
647 | msgid "" | 647 | msgid "" |
648 | "No outbound quota configure for network `%s', assigning default bandwidth " | 648 | "No outbound quota configure for network `%s', assigning default bandwidth " |
649 | "%llu\n" | 649 | "%llu\n" |
650 | msgstr "" | 650 | msgstr "" |
651 | 651 | ||
652 | #: src/ats/gnunet-ats-solver-eval.c:3552 | 652 | #: src/ats/gnunet-ats-solver-eval.c:3553 |
653 | msgid "solver to use" | 653 | msgid "solver to use" |
654 | msgstr "" | 654 | msgstr "" |
655 | 655 | ||
656 | #: src/ats/gnunet-ats-solver-eval.c:3557 | 656 | #: src/ats/gnunet-ats-solver-eval.c:3558 |
657 | msgid "experiment to use" | 657 | msgid "experiment to use" |
658 | msgstr "" | 658 | msgstr "" |
659 | 659 | ||
660 | #: src/ats/gnunet-ats-solver-eval.c:3564 | 660 | #: src/ats/gnunet-ats-solver-eval.c:3565 |
661 | #, fuzzy | 661 | #, fuzzy |
662 | msgid "print logging" | 662 | msgid "print logging" |
663 | msgstr "Startade samling \"%s\".\n" | 663 | msgstr "Startade samling \"%s\".\n" |
664 | 664 | ||
665 | #: src/ats/gnunet-ats-solver-eval.c:3569 | 665 | #: src/ats/gnunet-ats-solver-eval.c:3570 |
666 | msgid "save logging to disk" | 666 | msgid "save logging to disk" |
667 | msgstr "" | 667 | msgstr "" |
668 | 668 | ||
669 | #: src/ats/gnunet-ats-solver-eval.c:3574 | 669 | #: src/ats/gnunet-ats-solver-eval.c:3575 |
670 | msgid "disable normalization" | 670 | msgid "disable normalization" |
671 | msgstr "" | 671 | msgstr "" |
672 | 672 | ||
@@ -1568,42 +1568,7 @@ msgstr "# krypterade PONG-meddelanden mottagna" | |||
1568 | msgid "# updates to my type map" | 1568 | msgid "# updates to my type map" |
1569 | msgstr "" | 1569 | msgstr "" |
1570 | 1570 | ||
1571 | #: src/datacache/datacache.c:117 src/datacache/datacache.c:275 | 1571 | #: src/datacache/plugin_datacache_heap.c:555 |
1572 | #: src/datastore/gnunet-service-datastore.c:743 | ||
1573 | #, fuzzy | ||
1574 | msgid "# bytes stored" | ||
1575 | msgstr "# byte krypterade" | ||
1576 | |||
1577 | #: src/datacache/datacache.c:121 src/datacache/datacache.c:279 | ||
1578 | #, fuzzy | ||
1579 | msgid "# items stored" | ||
1580 | msgstr "# byte krypterade" | ||
1581 | |||
1582 | #: src/datacache/datacache.c:185 | ||
1583 | #, c-format | ||
1584 | msgid "Loading `%s' datacache plugin\n" | ||
1585 | msgstr "" | ||
1586 | |||
1587 | #: src/datacache/datacache.c:203 | ||
1588 | #, fuzzy, c-format | ||
1589 | msgid "Failed to load datacache plugin for `%s'\n" | ||
1590 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | ||
1591 | |||
1592 | #: src/datacache/datacache.c:297 | ||
1593 | #, fuzzy | ||
1594 | msgid "# requests received" | ||
1595 | msgstr "# byte mottogs via TCP" | ||
1596 | |||
1597 | #: src/datacache/datacache.c:308 | ||
1598 | msgid "# requests filtered by bloom filter" | ||
1599 | msgstr "" | ||
1600 | |||
1601 | #: src/datacache/datacache.c:329 | ||
1602 | #, fuzzy | ||
1603 | msgid "# proximity search requests received" | ||
1604 | msgstr "# klartext PONG-meddelanden mottagna" | ||
1605 | |||
1606 | #: src/datacache/plugin_datacache_heap.c:527 | ||
1607 | msgid "Heap datacache running\n" | 1572 | msgid "Heap datacache running\n" |
1608 | msgstr "" | 1573 | msgstr "" |
1609 | 1574 | ||
@@ -1625,7 +1590,7 @@ msgstr "" | |||
1625 | msgid "`%s' failed at %s:%d with error: %s\n" | 1590 | msgid "`%s' failed at %s:%d with error: %s\n" |
1626 | msgstr "\"%s\" misslyckades vid %s:%d med fel: %s\n" | 1591 | msgstr "\"%s\" misslyckades vid %s:%d med fel: %s\n" |
1627 | 1592 | ||
1628 | #: src/datacache/plugin_datacache_sqlite.c:693 | 1593 | #: src/datacache/plugin_datacache_sqlite.c:723 |
1629 | #: src/datastore/plugin_datastore_sqlite.c:531 | 1594 | #: src/datastore/plugin_datastore_sqlite.c:531 |
1630 | #: src/namecache/plugin_namecache_sqlite.c:237 | 1595 | #: src/namecache/plugin_namecache_sqlite.c:237 |
1631 | #: src/namestore/plugin_namestore_sqlite.c:273 | 1596 | #: src/namestore/plugin_namestore_sqlite.c:273 |
@@ -1816,6 +1781,11 @@ msgstr "" | |||
1816 | msgid "Could not find matching reservation" | 1781 | msgid "Could not find matching reservation" |
1817 | msgstr "" | 1782 | msgstr "" |
1818 | 1783 | ||
1784 | #: src/datastore/gnunet-service-datastore.c:743 | ||
1785 | #, fuzzy | ||
1786 | msgid "# bytes stored" | ||
1787 | msgstr "# byte krypterade" | ||
1788 | |||
1819 | #: src/datastore/gnunet-service-datastore.c:758 | 1789 | #: src/datastore/gnunet-service-datastore.c:758 |
1820 | #, c-format | 1790 | #, c-format |
1821 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" | 1791 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" |
@@ -2003,7 +1973,7 @@ msgstr "" | |||
2003 | 1973 | ||
2004 | #: src/datastore/plugin_datastore_sqlite.c:1337 | 1974 | #: src/datastore/plugin_datastore_sqlite.c:1337 |
2005 | #: src/namecache/plugin_namecache_sqlite.c:564 | 1975 | #: src/namecache/plugin_namecache_sqlite.c:564 |
2006 | #: src/namestore/plugin_namestore_sqlite.c:765 | 1976 | #: src/namestore/plugin_namestore_sqlite.c:775 |
2007 | msgid "Sqlite database running\n" | 1977 | msgid "Sqlite database running\n" |
2008 | msgstr "" | 1978 | msgstr "" |
2009 | 1979 | ||
@@ -2011,56 +1981,65 @@ msgstr "" | |||
2011 | msgid "Template database running\n" | 1981 | msgid "Template database running\n" |
2012 | msgstr "" | 1982 | msgstr "" |
2013 | 1983 | ||
2014 | #: src/dht/gnunet-dht-get.c:159 | 1984 | #: src/dht/gnunet-dht-get.c:164 |
2015 | #, c-format | 1985 | #, c-format |
2016 | msgid "" | 1986 | msgid "" |
2017 | "Result %d, type %d:\n" | 1987 | "Result %d, type %d:\n" |
2018 | "%.*s\n" | 1988 | "%.*s\n" |
2019 | msgstr "" | 1989 | msgstr "" |
2020 | 1990 | ||
2021 | #: src/dht/gnunet-dht-get.c:160 | 1991 | #: src/dht/gnunet-dht-get.c:165 |
2022 | #, c-format | 1992 | #, c-format |
2023 | msgid "Result %d, type %d:\n" | 1993 | msgid "Result %d, type %d:\n" |
2024 | msgstr "" | 1994 | msgstr "" |
2025 | 1995 | ||
2026 | #: src/dht/gnunet-dht-get.c:209 | 1996 | #: src/dht/gnunet-dht-get.c:215 |
2027 | msgid "Must provide key for DHT GET!\n" | 1997 | msgid "Must provide key for DHT GET!\n" |
2028 | msgstr "" | 1998 | msgstr "" |
2029 | 1999 | ||
2030 | #: src/dht/gnunet-dht-get.c:217 src/dht/gnunet-dht-monitor.c:255 | 2000 | #: src/dht/gnunet-dht-get.c:223 src/dht/gnunet-dht-hello.c:119 |
2031 | #, fuzzy | 2001 | #: src/dht/gnunet-dht-monitor.c:255 |
2002 | #, fuzzy, c-format | ||
2032 | msgid "Failed to connect to DHT service!\n" | 2003 | msgid "Failed to connect to DHT service!\n" |
2033 | msgstr "Misslyckades att ansluta till gnunetd.\n" | 2004 | msgstr "Misslyckades att ansluta till gnunetd.\n" |
2034 | 2005 | ||
2035 | #: src/dht/gnunet-dht-get.c:227 | 2006 | #: src/dht/gnunet-dht-get.c:233 |
2036 | msgid "Issuing DHT GET with key" | 2007 | msgid "Issuing DHT GET with key" |
2037 | msgstr "" | 2008 | msgstr "" |
2038 | 2009 | ||
2039 | #: src/dht/gnunet-dht-get.c:260 src/dht/gnunet-dht-monitor.c:302 | 2010 | #: src/dht/gnunet-dht-get.c:269 src/dht/gnunet-dht-monitor.c:302 |
2040 | #: src/dht/gnunet-dht-put.c:200 | 2011 | #: src/dht/gnunet-dht-put.c:200 |
2041 | msgid "the query key" | 2012 | msgid "the query key" |
2042 | msgstr "" | 2013 | msgstr "" |
2043 | 2014 | ||
2044 | #: src/dht/gnunet-dht-get.c:266 | 2015 | #: src/dht/gnunet-dht-get.c:275 |
2045 | msgid "how many parallel requests (replicas) to create" | 2016 | msgid "how many parallel requests (replicas) to create" |
2046 | msgstr "" | 2017 | msgstr "" |
2047 | 2018 | ||
2048 | #: src/dht/gnunet-dht-get.c:272 src/dht/gnunet-dht-monitor.c:308 | 2019 | #: src/dht/gnunet-dht-get.c:280 src/dht/gnunet-dht-put.c:217 |
2020 | msgid "use DHT's record route option" | ||
2021 | msgstr "" | ||
2022 | |||
2023 | #: src/dht/gnunet-dht-get.c:286 src/dht/gnunet-dht-monitor.c:308 | ||
2049 | msgid "the type of data to look for" | 2024 | msgid "the type of data to look for" |
2050 | msgstr "" | 2025 | msgstr "" |
2051 | 2026 | ||
2052 | #: src/dht/gnunet-dht-get.c:278 | 2027 | #: src/dht/gnunet-dht-get.c:292 |
2053 | msgid "how long to execute this query before giving up?" | 2028 | msgid "how long to execute this query before giving up?" |
2054 | msgstr "" | 2029 | msgstr "" |
2055 | 2030 | ||
2056 | #: src/dht/gnunet-dht-get.c:284 src/dht/gnunet-dht-put.c:206 | 2031 | #: src/dht/gnunet-dht-get.c:298 src/dht/gnunet-dht-put.c:206 |
2057 | msgid "use DHT's demultiplex everywhere option" | 2032 | msgid "use DHT's demultiplex everywhere option" |
2058 | msgstr "" | 2033 | msgstr "" |
2059 | 2034 | ||
2060 | #: src/dht/gnunet-dht-get.c:301 | 2035 | #: src/dht/gnunet-dht-get.c:315 |
2061 | msgid "Issue a GET request to the GNUnet DHT, prints results." | 2036 | msgid "Issue a GET request to the GNUnet DHT, prints results." |
2062 | msgstr "" | 2037 | msgstr "" |
2063 | 2038 | ||
2039 | #: src/dht/gnunet-dht-hello.c:166 | ||
2040 | msgid "Obtain HELLO from DHT or provide HELLO to DHT for bootstrapping" | ||
2041 | msgstr "" | ||
2042 | |||
2064 | #: src/dht/gnunet-dht-monitor.c:315 | 2043 | #: src/dht/gnunet-dht-monitor.c:315 |
2065 | msgid "how long should the monitor command run" | 2044 | msgid "how long should the monitor command run" |
2066 | msgstr "" | 2045 | msgstr "" |
@@ -2100,10 +2079,6 @@ msgstr "" | |||
2100 | msgid "how many replicas to create" | 2079 | msgid "how many replicas to create" |
2101 | msgstr "" | 2080 | msgstr "" |
2102 | 2081 | ||
2103 | #: src/dht/gnunet-dht-put.c:217 | ||
2104 | msgid "use DHT's record route option" | ||
2105 | msgstr "" | ||
2106 | |||
2107 | #: src/dht/gnunet-dht-put.c:223 | 2082 | #: src/dht/gnunet-dht-put.c:223 |
2108 | msgid "the type to insert data as" | 2083 | msgid "the type to insert data as" |
2109 | msgstr "" | 2084 | msgstr "" |
@@ -2160,17 +2135,17 @@ msgstr "" | |||
2160 | msgid "Measure quality and performance of the DHT service." | 2135 | msgid "Measure quality and performance of the DHT service." |
2161 | msgstr "Kan inte tillgå tjänsten" | 2136 | msgstr "Kan inte tillgå tjänsten" |
2162 | 2137 | ||
2163 | #: src/dht/plugin_block_dht.c:328 | 2138 | #: src/dht/plugin_block_dht.c:404 |
2164 | #, fuzzy, c-format | 2139 | #, fuzzy, c-format |
2165 | msgid "Block not of type %u\n" | 2140 | msgid "Block not of type %u\n" |
2166 | msgstr "Ingen transport av typ %d är känd.\n" | 2141 | msgstr "Ingen transport av typ %d är känd.\n" |
2167 | 2142 | ||
2168 | #: src/dht/plugin_block_dht.c:337 | 2143 | #: src/dht/plugin_block_dht.c:413 |
2169 | #, c-format | 2144 | #, c-format |
2170 | msgid "Size mismatch for block with type %u\n" | 2145 | msgid "Size mismatch for block with type %u\n" |
2171 | msgstr "" | 2146 | msgstr "" |
2172 | 2147 | ||
2173 | #: src/dht/plugin_block_dht.c:348 | 2148 | #: src/dht/plugin_block_dht.c:424 |
2174 | #, c-format | 2149 | #, c-format |
2175 | msgid "Block of type %u is malformed\n" | 2150 | msgid "Block of type %u is malformed\n" |
2176 | msgstr "" | 2151 | msgstr "" |
@@ -2907,20 +2882,20 @@ msgstr "" | |||
2907 | msgid "LOC URI malformed (signature failed validation)" | 2882 | msgid "LOC URI malformed (signature failed validation)" |
2908 | msgstr "" | 2883 | msgstr "" |
2909 | 2884 | ||
2910 | #: src/fs/fs_uri.c:653 | 2885 | #: src/fs/fs_uri.c:652 |
2911 | #, fuzzy | 2886 | #, fuzzy |
2912 | msgid "invalid argument" | 2887 | msgid "invalid argument" |
2913 | msgstr "Ogiltigt argument: \"%s\"\n" | 2888 | msgstr "Ogiltigt argument: \"%s\"\n" |
2914 | 2889 | ||
2915 | #: src/fs/fs_uri.c:665 | 2890 | #: src/fs/fs_uri.c:671 |
2916 | msgid "Unrecognized URI type" | 2891 | msgid "Unrecognized URI type" |
2917 | msgstr "" | 2892 | msgstr "" |
2918 | 2893 | ||
2919 | #: src/fs/fs_uri.c:1071 src/fs/fs_uri.c:1098 | 2894 | #: src/fs/fs_uri.c:1075 src/fs/fs_uri.c:1102 |
2920 | msgid "No keywords specified!\n" | 2895 | msgid "No keywords specified!\n" |
2921 | msgstr "Inga nyckelord angivna!\n" | 2896 | msgstr "Inga nyckelord angivna!\n" |
2922 | 2897 | ||
2923 | #: src/fs/fs_uri.c:1104 | 2898 | #: src/fs/fs_uri.c:1108 |
2924 | msgid "Number of double-quotes not balanced!\n" | 2899 | msgid "Number of double-quotes not balanced!\n" |
2925 | msgstr "" | 2900 | msgstr "" |
2926 | 2901 | ||
@@ -3049,7 +3024,7 @@ msgid "Downloading `%s' done (%s/s).\n" | |||
3049 | msgstr "Uppladdning vägrades!" | 3024 | msgstr "Uppladdning vägrades!" |
3050 | 3025 | ||
3051 | #: src/fs/gnunet-download.c:206 src/fs/gnunet-publish.c:299 | 3026 | #: src/fs/gnunet-download.c:206 src/fs/gnunet-publish.c:299 |
3052 | #: src/fs/gnunet-search.c:229 src/fs/gnunet-unindex.c:117 | 3027 | #: src/fs/gnunet-search.c:538 src/fs/gnunet-unindex.c:117 |
3053 | #, c-format | 3028 | #, c-format |
3054 | msgid "Unexpected status: %d\n" | 3029 | msgid "Unexpected status: %d\n" |
3055 | msgstr "" | 3030 | msgstr "" |
@@ -3073,12 +3048,12 @@ msgid "Target filename must be specified.\n" | |||
3073 | msgstr "" | 3048 | msgstr "" |
3074 | 3049 | ||
3075 | #: src/fs/gnunet-download.c:271 src/fs/gnunet-publish.c:869 | 3050 | #: src/fs/gnunet-download.c:271 src/fs/gnunet-publish.c:869 |
3076 | #: src/fs/gnunet-search.c:294 src/fs/gnunet-unindex.c:154 | 3051 | #: src/fs/gnunet-unindex.c:154 |
3077 | #, fuzzy, c-format | 3052 | #, fuzzy, c-format |
3078 | msgid "Could not initialize `%s' subsystem.\n" | 3053 | msgid "Could not initialize `%s' subsystem.\n" |
3079 | msgstr "Misslyckades att initiera tjänsten \"%s\".\n" | 3054 | msgstr "Misslyckades att initiera tjänsten \"%s\".\n" |
3080 | 3055 | ||
3081 | #: src/fs/gnunet-download.c:318 src/fs/gnunet-search.c:334 | 3056 | #: src/fs/gnunet-download.c:318 |
3082 | msgid "set the desired LEVEL of receiver-anonymity" | 3057 | msgid "set the desired LEVEL of receiver-anonymity" |
3083 | msgstr "" | 3058 | msgstr "" |
3084 | 3059 | ||
@@ -3086,7 +3061,7 @@ msgstr "" | |||
3086 | msgid "delete incomplete downloads (when aborted with CTRL-C)" | 3061 | msgid "delete incomplete downloads (when aborted with CTRL-C)" |
3087 | msgstr "" | 3062 | msgstr "" |
3088 | 3063 | ||
3089 | #: src/fs/gnunet-download.c:330 src/fs/gnunet-search.c:339 | 3064 | #: src/fs/gnunet-download.c:330 src/fs/gnunet-search.c:740 |
3090 | msgid "only search the local peer (no P2P network search)" | 3065 | msgid "only search the local peer (no P2P network search)" |
3091 | msgstr "" | 3066 | msgstr "" |
3092 | 3067 | ||
@@ -3330,40 +3305,112 @@ msgstr "" | |||
3330 | msgid "Publish a file or directory on GNUnet" | 3305 | msgid "Publish a file or directory on GNUnet" |
3331 | msgstr "" | 3306 | msgstr "" |
3332 | 3307 | ||
3333 | #: src/fs/gnunet-search.c:130 | 3308 | #: src/fs/gnunet-search.c:441 |
3334 | #, c-format | 3309 | #, c-format |
3335 | msgid "Failed to write directory with search results to `%s'\n" | 3310 | msgid "Failed to write directory with search results to `%s'\n" |
3336 | msgstr "" | 3311 | msgstr "" |
3337 | 3312 | ||
3338 | #: src/fs/gnunet-search.c:219 | 3313 | #: src/fs/gnunet-search.c:527 |
3339 | #, fuzzy, c-format | 3314 | #, fuzzy, c-format |
3340 | msgid "Error searching: %s.\n" | 3315 | msgid "Error searching: %s.\n" |
3341 | msgstr "Fel vid lämning av DHT.\n" | 3316 | msgstr "Fel vid lämning av DHT.\n" |
3342 | 3317 | ||
3343 | #: src/fs/gnunet-search.c:281 | 3318 | #: src/fs/gnunet-search.c:587 |
3319 | #, c-format | ||
3320 | msgid "Conflicting options --bookmark-only and --silent.\n" | ||
3321 | msgstr "" | ||
3322 | |||
3323 | #: src/fs/gnunet-search.c:594 | ||
3324 | #, c-format | ||
3325 | msgid "Conflicting options --bookmark-only and --output.\n" | ||
3326 | msgstr "" | ||
3327 | |||
3328 | #: src/fs/gnunet-search.c:600 | ||
3329 | #, c-format | ||
3330 | msgid "An output file is mandatory for silent mode.\n" | ||
3331 | msgstr "" | ||
3332 | |||
3333 | #: src/fs/gnunet-search.c:621 | ||
3344 | #, fuzzy | 3334 | #, fuzzy |
3345 | msgid "Could not create keyword URI from arguments.\n" | 3335 | msgid "Could not create keyword URI from arguments.\n" |
3346 | msgstr "Kunde inte skapa namnrymd \"%s\" (existerar?).\n" | 3336 | msgstr "Kunde inte skapa namnrymd \"%s\" (existerar?).\n" |
3347 | 3337 | ||
3348 | #: src/fs/gnunet-search.c:308 | 3338 | #: src/fs/gnunet-search.c:629 |
3339 | msgid "" | ||
3340 | "Invalid URI. Valid URIs for searching are keyword query URIs\n" | ||
3341 | "(\"gnunet://fs/ksk/...\") and namespace content URIs (\"gnunet://fs/sks/..." | ||
3342 | "\").\n" | ||
3343 | msgstr "" | ||
3344 | |||
3345 | #: src/fs/gnunet-search.c:654 | ||
3346 | #, fuzzy, c-format | ||
3347 | msgid "Could not initialize the `%s` subsystem.\n" | ||
3348 | msgstr "Misslyckades att initiera tjänsten \"%s\".\n" | ||
3349 | |||
3350 | #: src/fs/gnunet-search.c:668 | ||
3349 | #, fuzzy | 3351 | #, fuzzy |
3350 | msgid "Could not start searching.\n" | 3352 | msgid "Could not start searching.\n" |
3351 | msgstr "Kunde inte skapa namnrymd \"%s\" (existerar?).\n" | 3353 | msgstr "Kunde inte skapa namnrymd \"%s\" (existerar?).\n" |
3352 | 3354 | ||
3353 | #: src/fs/gnunet-search.c:345 | 3355 | #: src/fs/gnunet-search.c:694 |
3354 | msgid "write search results to file starting with PREFIX" | 3356 | msgid "set the desired LEVEL of receiver-anonymity (default: 1)" |
3355 | msgstr "" | 3357 | msgstr "" |
3356 | 3358 | ||
3357 | #: src/fs/gnunet-search.c:351 | 3359 | #: src/fs/gnunet-search.c:700 |
3358 | msgid "automatically terminate search after DELAY" | 3360 | msgid "do not search, print only the URI that points to this search" |
3359 | msgstr "" | 3361 | msgstr "" |
3360 | 3362 | ||
3361 | #: src/fs/gnunet-search.c:357 | 3363 | #: src/fs/gnunet-search.c:707 |
3364 | msgid "" | ||
3365 | "write search results for directories according to FORMAT; accepted " | ||
3366 | "placeholders are: %a, %f, %j, %l, %m, %n, %s; defaults to the value of --" | ||
3367 | "printf when omitted or to `" | ||
3368 | msgstr "" | ||
3369 | |||
3370 | #: src/fs/gnunet-search.c:717 | ||
3371 | msgid "" | ||
3372 | "write search results according to FORMAT; accepted placeholders are: %a, %f, " | ||
3373 | "%j, %l, %m, %n, %s; defaults to `" | ||
3374 | msgstr "" | ||
3375 | |||
3376 | #: src/fs/gnunet-search.c:725 | ||
3377 | msgid "" | ||
3378 | "when the %a or %j placeholders appear in --printf or --dir-printf, list each " | ||
3379 | "metadata property according to FORMAT; accepted placeholders are: %i, %l, " | ||
3380 | "%n, %p" | ||
3381 | msgstr "" | ||
3382 | |||
3383 | #: src/fs/gnunet-search.c:734 | ||
3362 | msgid "automatically terminate search after VALUE results are found" | 3384 | msgid "automatically terminate search after VALUE results are found" |
3363 | msgstr "" | 3385 | msgstr "" |
3364 | 3386 | ||
3365 | #: src/fs/gnunet-search.c:371 | 3387 | #: src/fs/gnunet-search.c:746 |
3366 | msgid "Search GNUnet for files that were published on GNUnet" | 3388 | msgid "" |
3389 | "create a GNUnet directory with search results at FILENAME (e.g. `gnunet-" | ||
3390 | "search --output=commons" | ||
3391 | msgstr "" | ||
3392 | |||
3393 | #: src/fs/gnunet-search.c:753 | ||
3394 | msgid "silent mode (requires the --output argument)" | ||
3395 | msgstr "" | ||
3396 | |||
3397 | #: src/fs/gnunet-search.c:759 | ||
3398 | msgid "" | ||
3399 | "automatically terminate search after DELAY; the value given must be a number " | ||
3400 | "followed by a space and a time unit, for example \"500 ms\"; without a unit " | ||
3401 | "it defaults to microseconds - 1000000 = 1 second; if 0 or omitted it means " | ||
3402 | "to wait for CTRL-C" | ||
3403 | msgstr "" | ||
3404 | |||
3405 | #: src/fs/gnunet-search.c:768 | ||
3406 | #, c-format | ||
3407 | msgid "" | ||
3408 | "be verbose (append \"%a\\n\" to the default --printf and --dir-printf " | ||
3409 | "arguments - ignored when these are provided by the user)" | ||
3410 | msgstr "" | ||
3411 | |||
3412 | #: src/fs/gnunet-search.c:781 | ||
3413 | msgid "Search for files that have been published on GNUnet\n" | ||
3367 | msgstr "" | 3414 | msgstr "" |
3368 | 3415 | ||
3369 | #: src/fs/gnunet-service-fs.c:371 src/fs/gnunet-service-fs.c:878 | 3416 | #: src/fs/gnunet-service-fs.c:371 src/fs/gnunet-service-fs.c:878 |
@@ -3715,68 +3762,73 @@ msgstr "" | |||
3715 | msgid "Expected a base32-encoded public zone key\n" | 3762 | msgid "Expected a base32-encoded public zone key\n" |
3716 | msgstr "" | 3763 | msgstr "" |
3717 | 3764 | ||
3718 | #: src/gns/gnunet-bcd.c:571 | 3765 | #: src/gns/gnunet-bcd.c:573 |
3719 | #, fuzzy, c-format | 3766 | #, fuzzy, c-format |
3720 | msgid "Invalid port number %u\n" | 3767 | msgid "Invalid port number %u\n" |
3721 | msgstr "Ogiltiga argument. Avslutar.\n" | 3768 | msgstr "Ogiltiga argument. Avslutar.\n" |
3722 | 3769 | ||
3723 | #: src/gns/gnunet-bcd.c:612 src/namestore/gnunet-namestore-fcfsd.c:1113 | 3770 | #: src/gns/gnunet-bcd.c:614 src/namestore/gnunet-namestore-fcfsd.c:1113 |
3724 | #, fuzzy | 3771 | #, fuzzy |
3725 | msgid "Unable to set up the daemon\n" | 3772 | msgid "Unable to set up the daemon\n" |
3726 | msgstr "Kunde inte skapa namnrymd \"%s\" (existerar?).\n" | 3773 | msgstr "Kunde inte skapa namnrymd \"%s\" (existerar?).\n" |
3727 | 3774 | ||
3728 | #: src/gns/gnunet-bcd.c:635 src/namestore/gnunet-namestore-fcfsd.c:987 | 3775 | #: src/gns/gnunet-bcd.c:637 src/namestore/gnunet-namestore-fcfsd.c:987 |
3729 | #, fuzzy | 3776 | #, fuzzy |
3730 | msgid "Failed to start HTTP server\n" | 3777 | msgid "Failed to start HTTP server\n" |
3731 | msgstr "Misslyckades att starta samling.\n" | 3778 | msgstr "Misslyckades att starta samling.\n" |
3732 | 3779 | ||
3733 | #: src/gns/gnunet-bcd.c:658 | 3780 | #: src/gns/gnunet-bcd.c:660 |
3734 | msgid "Run HTTP server on port PORT (default is 8888)" | 3781 | msgid "Run HTTP server on port PORT (default is 8888)" |
3735 | msgstr "" | 3782 | msgstr "" |
3736 | 3783 | ||
3737 | #: src/gns/gnunet-bcd.c:667 | 3784 | #: src/gns/gnunet-bcd.c:669 |
3738 | msgid "GNUnet HTTP server to create business cards" | 3785 | msgid "GNUnet HTTP server to create business cards" |
3739 | msgstr "" | 3786 | msgstr "" |
3740 | 3787 | ||
3741 | #: src/gns/gnunet-dns2gns.c:241 | 3788 | #: src/gns/gnunet-dns2gns.c:298 |
3742 | #, fuzzy | 3789 | #, fuzzy |
3743 | msgid "Failed to pack DNS response into UDP packet!\n" | 3790 | msgid "Failed to pack DNS response into UDP packet!\n" |
3744 | msgstr "Misslyckades att skicka HTTP-begäran till värd \"%s\": %s\n" | 3791 | msgstr "Misslyckades att skicka HTTP-begäran till värd \"%s\": %s\n" |
3745 | 3792 | ||
3746 | #: src/gns/gnunet-dns2gns.c:315 | 3793 | #: src/gns/gnunet-dns2gns.c:379 |
3747 | #, fuzzy | 3794 | #, fuzzy |
3748 | msgid "Failed to parse DNS response!\n" | 3795 | msgid "Failed to parse DNS response!\n" |
3749 | msgstr "Misslyckades att skicka HTTP-begäran till värd \"%s\": %s\n" | 3796 | msgstr "Misslyckades att skicka HTTP-begäran till värd \"%s\": %s\n" |
3750 | 3797 | ||
3751 | #: src/gns/gnunet-dns2gns.c:452 | 3798 | #: src/gns/gnunet-dns2gns.c:453 |
3799 | #, c-format | ||
3800 | msgid "VPN returned empty result for `%s'\n" | ||
3801 | msgstr "" | ||
3802 | |||
3803 | #: src/gns/gnunet-dns2gns.c:655 | ||
3752 | #, fuzzy, c-format | 3804 | #, fuzzy, c-format |
3753 | msgid "Cannot parse DNS request from %s\n" | 3805 | msgid "Cannot parse DNS request from %s\n" |
3754 | msgstr "Misslyckades att skicka HTTP-begäran till värd \"%s\": %s\n" | 3806 | msgstr "Misslyckades att skicka HTTP-begäran till värd \"%s\": %s\n" |
3755 | 3807 | ||
3756 | #: src/gns/gnunet-dns2gns.c:468 | 3808 | #: src/gns/gnunet-dns2gns.c:671 |
3757 | #, fuzzy, c-format | 3809 | #, fuzzy, c-format |
3758 | msgid "Received malformed DNS request from %s\n" | 3810 | msgid "Received malformed DNS request from %s\n" |
3759 | msgstr "Mottog ogiltig \"%s\" begäran (storlek %d)\n" | 3811 | msgstr "Mottog ogiltig \"%s\" begäran (storlek %d)\n" |
3760 | 3812 | ||
3761 | #: src/gns/gnunet-dns2gns.c:476 | 3813 | #: src/gns/gnunet-dns2gns.c:679 |
3762 | #, fuzzy, c-format | 3814 | #, fuzzy, c-format |
3763 | msgid "Received unsupported DNS request from %s\n" | 3815 | msgid "Received unsupported DNS request from %s\n" |
3764 | msgstr "Mottog okänd typ av begäran %d vid %s:%d\n" | 3816 | msgstr "Mottog okänd typ av begäran %d vid %s:%d\n" |
3765 | 3817 | ||
3766 | #: src/gns/gnunet-dns2gns.c:637 | 3818 | #: src/gns/gnunet-dns2gns.c:840 |
3767 | #, fuzzy | 3819 | #, fuzzy |
3768 | msgid "No DNS server specified!\n" | 3820 | msgid "No DNS server specified!\n" |
3769 | msgstr "Inga nyckelord angivna!\n" | 3821 | msgstr "Inga nyckelord angivna!\n" |
3770 | 3822 | ||
3771 | #: src/gns/gnunet-dns2gns.c:786 | 3823 | #: src/gns/gnunet-dns2gns.c:995 |
3772 | msgid "IP of recursive DNS resolver to use (required)" | 3824 | msgid "IP of recursive DNS resolver to use (required)" |
3773 | msgstr "" | 3825 | msgstr "" |
3774 | 3826 | ||
3775 | #: src/gns/gnunet-dns2gns.c:792 | 3827 | #: src/gns/gnunet-dns2gns.c:1001 |
3776 | msgid "UDP port to listen on for inbound DNS requests; default: 2853" | 3828 | msgid "UDP port to listen on for inbound DNS requests; default: 2853" |
3777 | msgstr "" | 3829 | msgstr "" |
3778 | 3830 | ||
3779 | #: src/gns/gnunet-dns2gns.c:809 | 3831 | #: src/gns/gnunet-dns2gns.c:1018 |
3780 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" | 3832 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" |
3781 | msgstr "" | 3833 | msgstr "" |
3782 | 3834 | ||
@@ -3958,19 +4010,19 @@ msgstr "" | |||
3958 | msgid "GNUnet GNS resolver tool" | 4010 | msgid "GNUnet GNS resolver tool" |
3959 | msgstr "Spåra GNUnets nätverkstopologi." | 4011 | msgstr "Spåra GNUnets nätverkstopologi." |
3960 | 4012 | ||
3961 | #: src/gns/gnunet-service-gns.c:505 | 4013 | #: src/gns/gnunet-service-gns.c:501 |
3962 | #, fuzzy | 4014 | #, fuzzy |
3963 | msgid "Properly base32-encoded public key required" | 4015 | msgid "Properly base32-encoded public key required" |
3964 | msgstr "Ogiltigt argument: \"%s\"\n" | 4016 | msgstr "Ogiltigt argument: \"%s\"\n" |
3965 | 4017 | ||
3966 | #: src/gns/gnunet-service-gns.c:541 | 4018 | #: src/gns/gnunet-service-gns.c:537 |
3967 | #, fuzzy | 4019 | #, fuzzy |
3968 | msgid "Failed to connect to the namecache!\n" | 4020 | msgid "Failed to connect to the namecache!\n" |
3969 | msgstr "Misslyckades att ansluta till gnunetd.\n" | 4021 | msgstr "Misslyckades att ansluta till gnunetd.\n" |
3970 | 4022 | ||
3971 | #: src/gns/gnunet-service-gns.c:560 | 4023 | #: src/gns/gnunet-service-gns.c:556 |
3972 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:442 | 4024 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:421 |
3973 | #: src/zonemaster/gnunet-service-zonemaster.c:885 | 4025 | #: src/zonemaster/gnunet-service-zonemaster.c:870 |
3974 | #, fuzzy | 4026 | #, fuzzy |
3975 | msgid "Could not connect to DHT!\n" | 4027 | msgid "Could not connect to DHT!\n" |
3976 | msgstr "Kunde inte ansluta till gnunetd.\n" | 4028 | msgstr "Kunde inte ansluta till gnunetd.\n" |
@@ -3984,95 +4036,98 @@ msgstr "" | |||
3984 | msgid "Failed to connect to the DNS service!\n" | 4036 | msgid "Failed to connect to the DNS service!\n" |
3985 | msgstr "Misslyckades att ansluta till gnunetd.\n" | 4037 | msgstr "Misslyckades att ansluta till gnunetd.\n" |
3986 | 4038 | ||
3987 | #: src/gns/gnunet-service-gns_resolver.c:706 | 4039 | #: src/gns/gnunet-service-gns_resolver.c:659 |
3988 | #, c-format | 4040 | #, c-format |
3989 | msgid "Protocol `%s' unknown, skipping labels.\n" | 4041 | msgid "Protocol `%s' unknown, skipping labels.\n" |
3990 | msgstr "" | 4042 | msgstr "" |
3991 | 4043 | ||
3992 | #: src/gns/gnunet-service-gns_resolver.c:718 | 4044 | #: src/gns/gnunet-service-gns_resolver.c:671 |
3993 | #, c-format | 4045 | #, c-format |
3994 | msgid "Service `%s' unknown for protocol `%s', trying as number.\n" | 4046 | msgid "Service `%s' unknown for protocol `%s', trying as number.\n" |
3995 | msgstr "" | 4047 | msgstr "" |
3996 | 4048 | ||
3997 | #: src/gns/gnunet-service-gns_resolver.c:724 | 4049 | #: src/gns/gnunet-service-gns_resolver.c:677 |
3998 | #, c-format | 4050 | #, c-format |
3999 | msgid "Service `%s' not a port, skipping service labels.\n" | 4051 | msgid "Service `%s' not a port, skipping service labels.\n" |
4000 | msgstr "" | 4052 | msgstr "" |
4001 | 4053 | ||
4002 | #: src/gns/gnunet-service-gns_resolver.c:938 | 4054 | #: src/gns/gnunet-service-gns_resolver.c:891 |
4003 | #, fuzzy | 4055 | #, fuzzy |
4004 | msgid "Failed to parse DNS response\n" | 4056 | msgid "Failed to parse DNS response\n" |
4005 | msgstr "Misslyckades att skicka HTTP-begäran till värd \"%s\": %s\n" | 4057 | msgstr "Misslyckades att skicka HTTP-begäran till värd \"%s\": %s\n" |
4006 | 4058 | ||
4007 | #: src/gns/gnunet-service-gns_resolver.c:1129 | 4059 | #: src/gns/gnunet-service-gns_resolver.c:1082 |
4008 | #, c-format | 4060 | #, c-format |
4009 | msgid "Skipping record of unsupported type %d\n" | 4061 | msgid "Skipping record of unsupported type %d\n" |
4010 | msgstr "" | 4062 | msgstr "" |
4011 | 4063 | ||
4012 | #: src/gns/gnunet-service-gns_resolver.c:1447 | 4064 | #: src/gns/gnunet-service-gns_resolver.c:1859 |
4013 | #, c-format | ||
4014 | msgid "VPN returned empty result for `%s'\n" | ||
4015 | msgstr "" | ||
4016 | |||
4017 | #: src/gns/gnunet-service-gns_resolver.c:1919 | ||
4018 | #, c-format | 4065 | #, c-format |
4019 | msgid "Name `%s' cannot be converted to IDNA." | 4066 | msgid "Name `%s' cannot be converted to IDNA." |
4020 | msgstr "" | 4067 | msgstr "" |
4021 | 4068 | ||
4022 | #: src/gns/gnunet-service-gns_resolver.c:1934 | 4069 | #: src/gns/gnunet-service-gns_resolver.c:1874 |
4023 | #, c-format | 4070 | #, c-format |
4024 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" | 4071 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" |
4025 | msgstr "" | 4072 | msgstr "" |
4026 | 4073 | ||
4027 | #: src/gns/gnunet-service-gns_resolver.c:1979 | 4074 | #: src/gns/gnunet-service-gns_resolver.c:1914 |
4028 | #, fuzzy, c-format | 4075 | #, fuzzy, c-format |
4029 | msgid "GNS lookup failed (zero records found for `%s')\n" | 4076 | msgid "GNS lookup failed (zero records found for `%s')\n" |
4030 | msgstr "%d filer hittades i katalog.\n" | 4077 | msgstr "%d filer hittades i katalog.\n" |
4031 | 4078 | ||
4032 | #: src/gns/gnunet-service-gns_resolver.c:2406 | 4079 | #: src/gns/gnunet-service-gns_resolver.c:2312 |
4080 | msgid "Unable to process critical delegation record\n" | ||
4081 | msgstr "" | ||
4082 | |||
4083 | #: src/gns/gnunet-service-gns_resolver.c:2317 | ||
4033 | msgid "GNS lookup recursion failed (no delegation record found)\n" | 4084 | msgid "GNS lookup recursion failed (no delegation record found)\n" |
4034 | msgstr "" | 4085 | msgstr "" |
4035 | 4086 | ||
4036 | #: src/gns/gnunet-service-gns_resolver.c:2429 | 4087 | #: src/gns/gnunet-service-gns_resolver.c:2340 |
4037 | #, fuzzy, c-format | 4088 | #, fuzzy, c-format |
4038 | msgid "Failed to cache GNS resolution: %s\n" | 4089 | msgid "Failed to cache GNS resolution: %s\n" |
4039 | msgstr "Misslyckades att skicka HTTP-begäran till värd \"%s\": %s\n" | 4090 | msgstr "Misslyckades att skicka HTTP-begäran till värd \"%s\": %s\n" |
4040 | 4091 | ||
4041 | #: src/gns/gnunet-service-gns_resolver.c:2594 | 4092 | #: src/gns/gnunet-service-gns_resolver.c:2505 |
4042 | #, c-format | 4093 | #, c-format |
4043 | msgid "GNS namecache returned empty result for `%s'\n" | 4094 | msgid "GNS namecache returned empty result for `%s'\n" |
4044 | msgstr "" | 4095 | msgstr "" |
4045 | 4096 | ||
4046 | #: src/gns/gnunet-service-gns_resolver.c:2734 | 4097 | #: src/gns/gnunet-service-gns_resolver.c:2652 |
4047 | #, c-format | 4098 | #, c-format |
4048 | msgid "Zone %s was revoked, resolution fails\n" | 4099 | msgid "Zone %s was revoked, resolution fails\n" |
4049 | msgstr "" | 4100 | msgstr "" |
4050 | 4101 | ||
4051 | #: src/gns/plugin_gnsrecord_gns.c:174 | 4102 | #: src/gns/plugin_gnsrecord_gns.c:136 |
4103 | msgid "This is a memento of an older block for internal maintenance." | ||
4104 | msgstr "" | ||
4105 | |||
4106 | #: src/gns/plugin_gnsrecord_gns.c:175 | ||
4052 | #, fuzzy, c-format | 4107 | #, fuzzy, c-format |
4053 | msgid "Unable to parse zone key record `%s'\n" | 4108 | msgid "Unable to parse zone key record `%s'\n" |
4054 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | 4109 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" |
4055 | 4110 | ||
4056 | #: src/gns/plugin_gnsrecord_gns.c:187 | 4111 | #: src/gns/plugin_gnsrecord_gns.c:188 |
4057 | msgid "Record type does not match parsed record type\n" | 4112 | msgid "Record type does not match parsed record type\n" |
4058 | msgstr "" | 4113 | msgstr "" |
4059 | 4114 | ||
4060 | #: src/gns/plugin_gnsrecord_gns.c:213 | 4115 | #: src/gns/plugin_gnsrecord_gns.c:211 |
4061 | #, fuzzy, c-format | 4116 | #, fuzzy, c-format |
4062 | msgid "Unable to parse GNS2DNS record `%s'\n" | 4117 | msgid "Unable to parse GNS2DNS record `%s'\n" |
4063 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | 4118 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" |
4064 | 4119 | ||
4065 | #: src/gns/plugin_gnsrecord_gns.c:229 | 4120 | #: src/gns/plugin_gnsrecord_gns.c:227 |
4066 | #, fuzzy, c-format | 4121 | #, fuzzy, c-format |
4067 | msgid "Failed to serialize GNS2DNS record with value `%s': Not a DNS name.\n" | 4122 | msgid "Failed to serialize GNS2DNS record with value `%s': Not a DNS name.\n" |
4068 | msgstr "Kunde inte tolka konfigurationsfil \"%s\".\n" | 4123 | msgstr "Kunde inte tolka konfigurationsfil \"%s\".\n" |
4069 | 4124 | ||
4070 | #: src/gns/plugin_gnsrecord_gns.c:253 | 4125 | #: src/gns/plugin_gnsrecord_gns.c:251 |
4071 | #, fuzzy, c-format | 4126 | #, fuzzy, c-format |
4072 | msgid "Unable to parse VPN record string `%s'\n" | 4127 | msgid "Unable to parse VPN record string `%s'\n" |
4073 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | 4128 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" |
4074 | 4129 | ||
4075 | #: src/gns/plugin_gnsrecord_gns.c:285 | 4130 | #: src/gns/plugin_gnsrecord_gns.c:283 |
4076 | #, fuzzy, c-format | 4131 | #, fuzzy, c-format |
4077 | msgid "Unable to parse BOX record string `%s'\n" | 4132 | msgid "Unable to parse BOX record string `%s'\n" |
4078 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | 4133 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" |
@@ -4082,6 +4137,34 @@ msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | |||
4082 | msgid "Gns REST API initialized\n" | 4137 | msgid "Gns REST API initialized\n" |
4083 | msgstr " Anslutning misslyckades\n" | 4138 | msgstr " Anslutning misslyckades\n" |
4084 | 4139 | ||
4140 | #: src/gnsrecord/gnsrecord_misc.c:448 | ||
4141 | msgid "Zone delegation record not allowed in apex." | ||
4142 | msgstr "" | ||
4143 | |||
4144 | #: src/gnsrecord/gnsrecord_misc.c:456 | ||
4145 | msgid "Zone delegation record set contains mutually exclusive records." | ||
4146 | msgstr "" | ||
4147 | |||
4148 | #: src/gnsrecord/gnsrecord_misc.c:466 | ||
4149 | msgid "Multiple REDIRECT records." | ||
4150 | msgstr "" | ||
4151 | |||
4152 | #: src/gnsrecord/gnsrecord_misc.c:475 src/gnsrecord/gnsrecord_misc.c:501 | ||
4153 | msgid "Redirection record set conains mutually exclusive records." | ||
4154 | msgstr "" | ||
4155 | |||
4156 | #: src/gnsrecord/gnsrecord_misc.c:482 | ||
4157 | msgid "Redirection records not allowed in apex." | ||
4158 | msgstr "" | ||
4159 | |||
4160 | #: src/gnsrecord/gnsrecord_misc.c:493 | ||
4161 | msgid "Redirection records not allowed in apex.." | ||
4162 | msgstr "" | ||
4163 | |||
4164 | #: src/gnsrecord/gnsrecord_misc.c:515 | ||
4165 | msgid "Mutually exclusive records." | ||
4166 | msgstr "" | ||
4167 | |||
4085 | #: src/gnsrecord/plugin_gnsrecord_dns.c:367 | 4168 | #: src/gnsrecord/plugin_gnsrecord_dns.c:367 |
4086 | #, fuzzy, c-format | 4169 | #, fuzzy, c-format |
4087 | msgid "Unable to parse IPv4 address `%s'\n" | 4170 | msgid "Unable to parse IPv4 address `%s'\n" |
@@ -4328,7 +4411,7 @@ msgid "# hostlist downloads initiated" | |||
4328 | msgstr "" | 4411 | msgstr "" |
4329 | 4412 | ||
4330 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1144 | 4413 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1144 |
4331 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1728 | 4414 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1732 |
4332 | msgid "# milliseconds between hostlist downloads" | 4415 | msgid "# milliseconds between hostlist downloads" |
4333 | msgstr "" | 4416 | msgstr "" |
4334 | 4417 | ||
@@ -4387,21 +4470,21 @@ msgstr "" | |||
4387 | msgid "# hostlist URIs written to file" | 4470 | msgid "# hostlist URIs written to file" |
4388 | msgstr "" | 4471 | msgstr "" |
4389 | 4472 | ||
4390 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1657 | 4473 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1661 |
4391 | #: src/transport/plugin_transport_http_client.c:2300 | 4474 | #: src/transport/plugin_transport_http_client.c:2300 |
4392 | #, c-format | 4475 | #, c-format |
4393 | msgid "Invalid proxy type: `%s', disabling proxy! Check configuration!\n" | 4476 | msgid "Invalid proxy type: `%s', disabling proxy! Check configuration!\n" |
4394 | msgstr "" | 4477 | msgstr "" |
4395 | 4478 | ||
4396 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1686 | 4479 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1690 |
4397 | msgid "Learning is enabled on this peer\n" | 4480 | msgid "Learning is enabled on this peer\n" |
4398 | msgstr "" | 4481 | msgstr "" |
4399 | 4482 | ||
4400 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1699 | 4483 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1703 |
4401 | msgid "Learning is not enabled on this peer\n" | 4484 | msgid "Learning is not enabled on this peer\n" |
4402 | msgstr "" | 4485 | msgstr "" |
4403 | 4486 | ||
4404 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1713 | 4487 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1717 |
4405 | #, c-format | 4488 | #, c-format |
4406 | msgid "" | 4489 | msgid "" |
4407 | "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" | 4490 | "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" |
@@ -4592,49 +4675,49 @@ msgstr "" | |||
4592 | msgid "Maintain egos" | 4675 | msgid "Maintain egos" |
4593 | msgstr "" | 4676 | msgstr "" |
4594 | 4677 | ||
4595 | #: src/identity/gnunet-service-identity.c:503 | 4678 | #: src/identity/gnunet-service-identity.c:502 |
4596 | msgid "no default known" | 4679 | msgid "no default known" |
4597 | msgstr "" | 4680 | msgstr "" |
4598 | 4681 | ||
4599 | #: src/identity/gnunet-service-identity.c:528 | 4682 | #: src/identity/gnunet-service-identity.c:527 |
4600 | msgid "default configured, but ego unknown (internal error)" | 4683 | msgid "default configured, but ego unknown (internal error)" |
4601 | msgstr "" | 4684 | msgstr "" |
4602 | 4685 | ||
4603 | #: src/identity/gnunet-service-identity.c:621 | 4686 | #: src/identity/gnunet-service-identity.c:620 |
4604 | #: src/identity/gnunet-service-identity.c:896 | 4687 | #: src/identity/gnunet-service-identity.c:895 |
4605 | #: src/identity/gnunet-service-identity.c:1016 | 4688 | #: src/identity/gnunet-service-identity.c:1015 |
4606 | #, fuzzy, c-format | 4689 | #, fuzzy, c-format |
4607 | msgid "Failed to write subsystem default identifier map to `%s'.\n" | 4690 | msgid "Failed to write subsystem default identifier map to `%s'.\n" |
4608 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | 4691 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" |
4609 | 4692 | ||
4610 | #: src/identity/gnunet-service-identity.c:631 | 4693 | #: src/identity/gnunet-service-identity.c:630 |
4611 | msgid "Unknown ego specified for service (internal error)" | 4694 | msgid "Unknown ego specified for service (internal error)" |
4612 | msgstr "" | 4695 | msgstr "" |
4613 | 4696 | ||
4614 | #: src/identity/gnunet-service-identity.c:725 | 4697 | #: src/identity/gnunet-service-identity.c:724 |
4615 | msgid "identifier already in use for another ego" | 4698 | msgid "identifier already in use for another ego" |
4616 | msgstr "" | 4699 | msgstr "" |
4617 | 4700 | ||
4618 | #: src/identity/gnunet-service-identity.c:872 | 4701 | #: src/identity/gnunet-service-identity.c:871 |
4619 | msgid "target name already exists" | 4702 | msgid "target name already exists" |
4620 | msgstr "" | 4703 | msgstr "" |
4621 | 4704 | ||
4622 | #: src/identity/gnunet-service-identity.c:914 | 4705 | #: src/identity/gnunet-service-identity.c:913 |
4623 | #: src/identity/gnunet-service-identity.c:1033 | 4706 | #: src/identity/gnunet-service-identity.c:1032 |
4624 | msgid "no matching ego found" | 4707 | msgid "no matching ego found" |
4625 | msgstr "" | 4708 | msgstr "" |
4626 | 4709 | ||
4627 | #: src/identity/gnunet-service-identity.c:1131 | 4710 | #: src/identity/gnunet-service-identity.c:1130 |
4628 | #, fuzzy, c-format | 4711 | #, fuzzy, c-format |
4629 | msgid "Failed to parse ego information in `%s'\n" | 4712 | msgid "Failed to parse ego information in `%s'\n" |
4630 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | 4713 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" |
4631 | 4714 | ||
4632 | #: src/identity/gnunet-service-identity.c:1189 | 4715 | #: src/identity/gnunet-service-identity.c:1188 |
4633 | #, fuzzy, c-format | 4716 | #, fuzzy, c-format |
4634 | msgid "Failed to parse subsystem identity configuration file `%s'\n" | 4717 | msgid "Failed to parse subsystem identity configuration file `%s'\n" |
4635 | msgstr "Kunde inte spara konfigurationsfil \"%s\":" | 4718 | msgstr "Kunde inte spara konfigurationsfil \"%s\":" |
4636 | 4719 | ||
4637 | #: src/identity/gnunet-service-identity.c:1198 | 4720 | #: src/identity/gnunet-service-identity.c:1197 |
4638 | #, fuzzy, c-format | 4721 | #, fuzzy, c-format |
4639 | msgid "Failed to create directory `%s' for storing egos\n" | 4722 | msgid "Failed to create directory `%s' for storing egos\n" |
4640 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | 4723 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" |
@@ -4675,7 +4758,7 @@ msgstr "Kunde inte köra \"%s\": %s\n" | |||
4675 | msgid "No records found for `%s'" | 4758 | msgid "No records found for `%s'" |
4676 | msgstr "%d filer hittades i katalog.\n" | 4759 | msgstr "%d filer hittades i katalog.\n" |
4677 | 4760 | ||
4678 | #: src/namecache/gnunet-namecache.c:119 src/namestore/gnunet-namestore.c:459 | 4761 | #: src/namecache/gnunet-namecache.c:119 src/namestore/gnunet-namestore.c:469 |
4679 | #, c-format | 4762 | #, c-format |
4680 | msgid "\tCorrupt or unsupported record of type %u\n" | 4763 | msgid "\tCorrupt or unsupported record of type %u\n" |
4681 | msgstr "" | 4764 | msgstr "" |
@@ -4695,7 +4778,7 @@ msgstr "Ogiltigt argument: \"%s\"\n" | |||
4695 | msgid "You must specify a name\n" | 4778 | msgid "You must specify a name\n" |
4696 | msgstr "Du måste ange en mottagare!\n" | 4779 | msgstr "Du måste ange en mottagare!\n" |
4697 | 4780 | ||
4698 | #: src/namecache/gnunet-namecache.c:214 src/namestore/gnunet-namestore.c:1641 | 4781 | #: src/namecache/gnunet-namecache.c:214 src/namestore/gnunet-namestore.c:1591 |
4699 | msgid "name of the record to add/delete/display" | 4782 | msgid "name of the record to add/delete/display" |
4700 | msgstr "" | 4783 | msgstr "" |
4701 | 4784 | ||
@@ -4704,7 +4787,7 @@ msgstr "" | |||
4704 | msgid "specifies the public key of the zone to look in" | 4787 | msgid "specifies the public key of the zone to look in" |
4705 | msgstr "ange prioritet för innehållet" | 4788 | msgstr "ange prioritet för innehållet" |
4706 | 4789 | ||
4707 | #: src/namecache/gnunet-namecache.c:233 src/namestore/gnunet-namestore.c:1702 | 4790 | #: src/namecache/gnunet-namecache.c:233 src/namestore/gnunet-namestore.c:1652 |
4708 | #, fuzzy | 4791 | #, fuzzy |
4709 | msgid "GNUnet zone manipulation tool" | 4792 | msgid "GNUnet zone manipulation tool" |
4710 | msgstr "GNUnet-konfiguration" | 4793 | msgstr "GNUnet-konfiguration" |
@@ -4852,146 +4935,119 @@ msgstr "" | |||
4852 | msgid "GNU Name System First-Come-First-Served name registration service" | 4935 | msgid "GNU Name System First-Come-First-Served name registration service" |
4853 | msgstr "" | 4936 | msgstr "" |
4854 | 4937 | ||
4855 | #: src/namestore/gnunet-namestore.c:334 | 4938 | #: src/namestore/gnunet-namestore.c:340 |
4856 | #, fuzzy, c-format | 4939 | #, fuzzy, c-format |
4857 | msgid "Adding record failed: %s\n" | 4940 | msgid "Adding record failed: %s\n" |
4858 | msgstr "" | 4941 | msgstr "" |
4859 | "\n" | 4942 | "\n" |
4860 | "Fel vid uppladdning av fil: %s\n" | 4943 | "Fel vid uppladdning av fil: %s\n" |
4861 | 4944 | ||
4862 | #: src/namestore/gnunet-namestore.c:362 | 4945 | #: src/namestore/gnunet-namestore.c:368 |
4863 | #, fuzzy, c-format | 4946 | #, fuzzy, c-format |
4864 | msgid "Deleting record failed, record does not exist%s%s\n" | 4947 | msgid "Deleting record failed, record does not exist%s%s\n" |
4865 | msgstr "" | 4948 | msgstr "" |
4866 | "\n" | 4949 | "\n" |
4867 | "Fel vid uppladdning av fil: %s\n" | 4950 | "Fel vid uppladdning av fil: %s\n" |
4868 | 4951 | ||
4869 | #: src/namestore/gnunet-namestore.c:369 | 4952 | #: src/namestore/gnunet-namestore.c:375 |
4870 | #, fuzzy, c-format | 4953 | #, fuzzy, c-format |
4871 | msgid "Deleting record failed%s%s\n" | 4954 | msgid "Deleting record failed%s%s\n" |
4872 | msgstr "" | 4955 | msgstr "" |
4873 | "\n" | 4956 | "\n" |
4874 | "Fel vid uppladdning av fil: %s\n" | 4957 | "Fel vid uppladdning av fil: %s\n" |
4875 | 4958 | ||
4876 | #: src/namestore/gnunet-namestore.c:656 | ||
4877 | #, c-format | ||
4878 | msgid "A %s record exists already under `%s', no other records can be added.\n" | ||
4879 | msgstr "" | ||
4880 | |||
4881 | #: src/namestore/gnunet-namestore.c:668 | 4959 | #: src/namestore/gnunet-namestore.c:668 |
4882 | #, c-format | 4960 | #, c-format |
4883 | msgid "" | 4961 | msgid "" |
4884 | "A zone key record exists already under `%s', no other records can be added.\n" | ||
4885 | msgstr "" | ||
4886 | |||
4887 | #: src/namestore/gnunet-namestore.c:680 | ||
4888 | #, c-format | ||
4889 | msgid "" | ||
4890 | "A SOA record exists already under `%s', cannot add a second SOA to the same " | 4962 | "A SOA record exists already under `%s', cannot add a second SOA to the same " |
4891 | "zone.\n" | 4963 | "zone.\n" |
4892 | msgstr "" | 4964 | msgstr "" |
4893 | 4965 | ||
4894 | #: src/namestore/gnunet-namestore.c:696 | 4966 | #: src/namestore/gnunet-namestore.c:789 |
4895 | #, c-format | ||
4896 | msgid "Records already exist under `%s', cannot add `%s' record.\n" | ||
4897 | msgstr "" | ||
4898 | |||
4899 | #: src/namestore/gnunet-namestore.c:711 | ||
4900 | #, c-format | ||
4901 | msgid "Records already exist under `%s', cannot add record.\n" | ||
4902 | msgstr "" | ||
4903 | |||
4904 | #: src/namestore/gnunet-namestore.c:726 | ||
4905 | #, c-format | ||
4906 | msgid "" | ||
4907 | "Non-GNS2DNS records already exist under `%s', cannot add GNS2DNS record.\n" | ||
4908 | msgstr "" | ||
4909 | |||
4910 | #: src/namestore/gnunet-namestore.c:846 | ||
4911 | #, c-format | 4967 | #, c-format |
4912 | msgid "There are no records under label `%s' that could be deleted.\n" | 4968 | msgid "There are no records under label `%s' that could be deleted.\n" |
4913 | msgstr "" | 4969 | msgstr "" |
4914 | 4970 | ||
4915 | #: src/namestore/gnunet-namestore.c:889 | 4971 | #: src/namestore/gnunet-namestore.c:832 |
4916 | #, c-format | 4972 | #, c-format |
4917 | msgid "" | 4973 | msgid "" |
4918 | "There are no records under label `%s' that match the request for deletion.\n" | 4974 | "There are no records under label `%s' that match the request for deletion.\n" |
4919 | msgstr "" | 4975 | msgstr "" |
4920 | 4976 | ||
4921 | #: src/namestore/gnunet-namestore.c:970 | 4977 | #: src/namestore/gnunet-namestore.c:920 |
4922 | #, fuzzy, c-format | 4978 | #, fuzzy, c-format |
4923 | msgid "Failed to replace records: %s\n" | 4979 | msgid "Failed to replace records: %s\n" |
4924 | msgstr "Misslyckades att skicka HTTP-begäran till värd \"%s\": %s\n" | 4980 | msgstr "Misslyckades att skicka HTTP-begäran till värd \"%s\": %s\n" |
4925 | 4981 | ||
4926 | #: src/namestore/gnunet-namestore.c:993 | 4982 | #: src/namestore/gnunet-namestore.c:943 |
4927 | #, c-format | 4983 | #, c-format |
4928 | msgid "No options given\n" | 4984 | msgid "No options given\n" |
4929 | msgstr "" | 4985 | msgstr "" |
4930 | 4986 | ||
4931 | #: src/namestore/gnunet-namestore.c:1014 src/namestore/gnunet-namestore.c:1066 | 4987 | #: src/namestore/gnunet-namestore.c:964 src/namestore/gnunet-namestore.c:1016 |
4932 | #: src/namestore/gnunet-namestore.c:1076 src/namestore/gnunet-namestore.c:1105 | 4988 | #: src/namestore/gnunet-namestore.c:1026 src/namestore/gnunet-namestore.c:1055 |
4933 | #: src/namestore/gnunet-namestore.c:1126 src/namestore/gnunet-namestore.c:1153 | 4989 | #: src/namestore/gnunet-namestore.c:1076 src/namestore/gnunet-namestore.c:1103 |
4934 | #: src/namestore/gnunet-namestore.c:1230 | 4990 | #: src/namestore/gnunet-namestore.c:1180 |
4935 | #, fuzzy, c-format | 4991 | #, fuzzy, c-format |
4936 | msgid "Missing option `%s' for operation `%s'\n" | 4992 | msgid "Missing option `%s' for operation `%s'\n" |
4937 | msgstr "Konfigurationsfil \"%s\" skapad.\n" | 4993 | msgstr "Konfigurationsfil \"%s\" skapad.\n" |
4938 | 4994 | ||
4939 | #: src/namestore/gnunet-namestore.c:1016 | 4995 | #: src/namestore/gnunet-namestore.c:966 |
4940 | msgid "replace" | 4996 | msgid "replace" |
4941 | msgstr "" | 4997 | msgstr "" |
4942 | 4998 | ||
4943 | #: src/namestore/gnunet-namestore.c:1045 | 4999 | #: src/namestore/gnunet-namestore.c:995 |
4944 | #, fuzzy, c-format | 5000 | #, fuzzy, c-format |
4945 | msgid "Invalid nick `%s'\n" | 5001 | msgid "Invalid nick `%s'\n" |
4946 | msgstr "Ogiltiga argument: " | 5002 | msgstr "Ogiltiga argument: " |
4947 | 5003 | ||
4948 | #: src/namestore/gnunet-namestore.c:1068 src/namestore/gnunet-namestore.c:1078 | 5004 | #: src/namestore/gnunet-namestore.c:1018 src/namestore/gnunet-namestore.c:1028 |
4949 | #: src/namestore/gnunet-namestore.c:1107 src/namestore/gnunet-namestore.c:1128 | 5005 | #: src/namestore/gnunet-namestore.c:1057 src/namestore/gnunet-namestore.c:1078 |
4950 | #: src/namestore/gnunet-namestore.c:1232 | 5006 | #: src/namestore/gnunet-namestore.c:1182 |
4951 | msgid "add" | 5007 | msgid "add" |
4952 | msgstr "" | 5008 | msgstr "" |
4953 | 5009 | ||
4954 | #: src/namestore/gnunet-namestore.c:1086 | 5010 | #: src/namestore/gnunet-namestore.c:1036 |
4955 | #, fuzzy, c-format | 5011 | #, fuzzy, c-format |
4956 | msgid "Unsupported type `%s'\n" | 5012 | msgid "Unsupported type `%s'\n" |
4957 | msgstr "Kommando \"%s\" stöds ej. Avbryter.\n" | 5013 | msgstr "Kommando \"%s\" stöds ej. Avbryter.\n" |
4958 | 5014 | ||
4959 | #: src/namestore/gnunet-namestore.c:1096 | 5015 | #: src/namestore/gnunet-namestore.c:1046 |
4960 | #, c-format | 5016 | #, c-format |
4961 | msgid "For DNS record types `SRV', `TLSA' and `OPENPGPKEY'" | 5017 | msgid "For DNS record types `SRV', `TLSA' and `OPENPGPKEY'" |
4962 | msgstr "" | 5018 | msgstr "" |
4963 | 5019 | ||
4964 | #: src/namestore/gnunet-namestore.c:1116 | 5020 | #: src/namestore/gnunet-namestore.c:1066 |
4965 | #, fuzzy, c-format | 5021 | #, fuzzy, c-format |
4966 | msgid "Value `%s' invalid for record type `%s'\n" | 5022 | msgid "Value `%s' invalid for record type `%s'\n" |
4967 | msgstr "%s: symbolvärde \"%s\" ogiltigt för %s\n" | 5023 | msgstr "%s: symbolvärde \"%s\" ogiltigt för %s\n" |
4968 | 5024 | ||
4969 | #: src/namestore/gnunet-namestore.c:1135 src/namestore/gnunet-namestore.c:1239 | 5025 | #: src/namestore/gnunet-namestore.c:1085 src/namestore/gnunet-namestore.c:1189 |
4970 | #, fuzzy, c-format | 5026 | #, fuzzy, c-format |
4971 | msgid "Invalid time format `%s'\n" | 5027 | msgid "Invalid time format `%s'\n" |
4972 | msgstr "Ogiltigt format för IP: \"%s\"\n" | 5028 | msgstr "Ogiltigt format för IP: \"%s\"\n" |
4973 | 5029 | ||
4974 | #: src/namestore/gnunet-namestore.c:1155 | 5030 | #: src/namestore/gnunet-namestore.c:1105 |
4975 | msgid "del" | 5031 | msgid "del" |
4976 | msgstr "" | 5032 | msgstr "" |
4977 | 5033 | ||
4978 | #: src/namestore/gnunet-namestore.c:1197 | 5034 | #: src/namestore/gnunet-namestore.c:1147 |
4979 | #, fuzzy, c-format | 5035 | #, fuzzy, c-format |
4980 | msgid "Invalid public key for reverse lookup `%s'\n" | 5036 | msgid "Invalid public key for reverse lookup `%s'\n" |
4981 | msgstr "Ogiltigt argument: \"%s\"\n" | 5037 | msgstr "Ogiltigt argument: \"%s\"\n" |
4982 | 5038 | ||
4983 | #: src/namestore/gnunet-namestore.c:1222 | 5039 | #: src/namestore/gnunet-namestore.c:1172 |
4984 | #: src/peerinfo-tool/gnunet-peerinfo.c:737 | 5040 | #: src/peerinfo-tool/gnunet-peerinfo.c:737 |
4985 | #, fuzzy, c-format | 5041 | #, fuzzy, c-format |
4986 | msgid "Invalid URI `%s'\n" | 5042 | msgid "Invalid URI `%s'\n" |
4987 | msgstr "Ogiltiga argument: " | 5043 | msgstr "Ogiltiga argument: " |
4988 | 5044 | ||
4989 | #: src/namestore/gnunet-namestore.c:1292 | 5045 | #: src/namestore/gnunet-namestore.c:1242 |
4990 | #, c-format | 5046 | #, c-format |
4991 | msgid "Label `%s' contains `.' which is not allowed\n" | 5047 | msgid "Label `%s' contains `.' which is not allowed\n" |
4992 | msgstr "" | 5048 | msgstr "" |
4993 | 5049 | ||
4994 | #: src/namestore/gnunet-namestore.c:1342 | 5050 | #: src/namestore/gnunet-namestore.c:1292 |
4995 | #, c-format | 5051 | #, c-format |
4996 | msgid "" | 5052 | msgid "" |
4997 | "No default identity configured for `namestore' subsystem\n" | 5053 | "No default identity configured for `namestore' subsystem\n" |
@@ -4999,111 +5055,116 @@ msgid "" | |||
4999 | "Run gnunet-identity -d to get a list of choices for $NAME\n" | 5055 | "Run gnunet-identity -d to get a list of choices for $NAME\n" |
5000 | msgstr "" | 5056 | msgstr "" |
5001 | 5057 | ||
5002 | #: src/namestore/gnunet-namestore.c:1407 | 5058 | #: src/namestore/gnunet-namestore.c:1357 |
5003 | #, fuzzy, c-format | 5059 | #, fuzzy, c-format |
5004 | msgid "Superfluous command line arguments (starting with `%s') ignored\n" | 5060 | msgid "Superfluous command line arguments (starting with `%s') ignored\n" |
5005 | msgstr "Onödiga argument (ignorerade).\n" | 5061 | msgstr "Onödiga argument (ignorerade).\n" |
5006 | 5062 | ||
5007 | #: src/namestore/gnunet-namestore.c:1436 | 5063 | #: src/namestore/gnunet-namestore.c:1386 |
5008 | #, fuzzy, c-format | 5064 | #, fuzzy, c-format |
5009 | msgid "Cannot connect to identity service\n" | 5065 | msgid "Cannot connect to identity service\n" |
5010 | msgstr "Kunde inte ansluta till gnunetd.\n" | 5066 | msgstr "Kunde inte ansluta till gnunetd.\n" |
5011 | 5067 | ||
5012 | #: src/namestore/gnunet-namestore.c:1483 | 5068 | #: src/namestore/gnunet-namestore.c:1433 |
5013 | msgid "Empty record line argument is not allowed.\n" | 5069 | msgid "Empty record line argument is not allowed.\n" |
5014 | msgstr "" | 5070 | msgstr "" |
5015 | 5071 | ||
5016 | #: src/namestore/gnunet-namestore.c:1495 | 5072 | #: src/namestore/gnunet-namestore.c:1445 |
5017 | #, c-format | 5073 | #, c-format |
5018 | msgid "Invalid expiration time `%s' (must be without unit)\n" | 5074 | msgid "Invalid expiration time `%s' (must be without unit)\n" |
5019 | msgstr "" | 5075 | msgstr "" |
5020 | 5076 | ||
5021 | #: src/namestore/gnunet-namestore.c:1507 src/namestore/gnunet-namestore.c:1523 | 5077 | #: src/namestore/gnunet-namestore.c:1457 src/namestore/gnunet-namestore.c:1473 |
5022 | #: src/namestore/gnunet-namestore.c:1540 | 5078 | #: src/namestore/gnunet-namestore.c:1490 |
5023 | #, fuzzy, c-format | 5079 | #, fuzzy, c-format |
5024 | msgid "Missing entries in record line `%s'.\n" | 5080 | msgid "Missing entries in record line `%s'.\n" |
5025 | msgstr "Kunde inte slå upp \"%s\": %s\n" | 5081 | msgstr "Kunde inte slå upp \"%s\": %s\n" |
5026 | 5082 | ||
5027 | #: src/namestore/gnunet-namestore.c:1515 | 5083 | #: src/namestore/gnunet-namestore.c:1465 |
5028 | #, fuzzy, c-format | 5084 | #, fuzzy, c-format |
5029 | msgid "Unknown record type `%s'\n" | 5085 | msgid "Unknown record type `%s'\n" |
5030 | msgstr "Okänd operation \"%s\"\n" | 5086 | msgstr "Okänd operation \"%s\"\n" |
5031 | 5087 | ||
5032 | #: src/namestore/gnunet-namestore.c:1553 | 5088 | #: src/namestore/gnunet-namestore.c:1503 |
5033 | #, fuzzy, c-format | 5089 | #, fuzzy, c-format |
5034 | msgid "Invalid record data for type %s: `%s'.\n" | 5090 | msgid "Invalid record data for type %s: `%s'.\n" |
5035 | msgstr "Ogiltigt format för IP: \"%s\"\n" | 5091 | msgstr "Ogiltigt format för IP: \"%s\"\n" |
5036 | 5092 | ||
5037 | #: src/namestore/gnunet-namestore.c:1610 | 5093 | #: src/namestore/gnunet-namestore.c:1560 |
5038 | msgid "add record" | 5094 | msgid "add record" |
5039 | msgstr "" | 5095 | msgstr "" |
5040 | 5096 | ||
5041 | #: src/namestore/gnunet-namestore.c:1613 | 5097 | #: src/namestore/gnunet-namestore.c:1563 |
5042 | msgid "delete record" | 5098 | msgid "delete record" |
5043 | msgstr "" | 5099 | msgstr "" |
5044 | 5100 | ||
5045 | #: src/namestore/gnunet-namestore.c:1617 | 5101 | #: src/namestore/gnunet-namestore.c:1567 |
5046 | msgid "display records" | 5102 | msgid "display records" |
5047 | msgstr "" | 5103 | msgstr "" |
5048 | 5104 | ||
5049 | #: src/namestore/gnunet-namestore.c:1624 | 5105 | #: src/namestore/gnunet-namestore.c:1574 |
5050 | msgid "" | 5106 | msgid "" |
5051 | "expiration time for record to use (for adding only), \"never\" is possible" | 5107 | "expiration time for record to use (for adding only), \"never\" is possible" |
5052 | msgstr "" | 5108 | msgstr "" |
5053 | 5109 | ||
5054 | #: src/namestore/gnunet-namestore.c:1630 | 5110 | #: src/namestore/gnunet-namestore.c:1580 |
5055 | #, fuzzy | 5111 | #, fuzzy |
5056 | msgid "set the desired nick name for the zone" | 5112 | msgid "set the desired nick name for the zone" |
5057 | msgstr "Skriv ut information om GNUnets motparter." | 5113 | msgstr "Skriv ut information om GNUnets motparter." |
5058 | 5114 | ||
5059 | #: src/namestore/gnunet-namestore.c:1635 | 5115 | #: src/namestore/gnunet-namestore.c:1585 |
5060 | #, fuzzy | 5116 | #, fuzzy |
5061 | msgid "monitor changes in the namestore" | 5117 | msgid "monitor changes in the namestore" |
5062 | msgstr "Misslyckades att ansluta till gnunetd.\n" | 5118 | msgstr "Misslyckades att ansluta till gnunetd.\n" |
5063 | 5119 | ||
5064 | #: src/namestore/gnunet-namestore.c:1647 | 5120 | #: src/namestore/gnunet-namestore.c:1597 |
5065 | #, fuzzy | 5121 | #, fuzzy |
5066 | msgid "determine our name for the given PKEY" | 5122 | msgid "determine our name for the given PKEY" |
5067 | msgstr "Skriv ut information om GNUnets motparter." | 5123 | msgstr "Skriv ut information om GNUnets motparter." |
5068 | 5124 | ||
5069 | #: src/namestore/gnunet-namestore.c:1654 | 5125 | #: src/namestore/gnunet-namestore.c:1604 |
5070 | msgid "" | 5126 | msgid "" |
5071 | "set record set to values given by (possibly multiple) RECORDLINES; can be " | 5127 | "set record set to values given by (possibly multiple) RECORDLINES; can be " |
5072 | "specified multiple times" | 5128 | "specified multiple times" |
5073 | msgstr "" | 5129 | msgstr "" |
5074 | 5130 | ||
5075 | #: src/namestore/gnunet-namestore.c:1660 | 5131 | #: src/namestore/gnunet-namestore.c:1610 |
5076 | msgid "type of the record to add/delete/display" | 5132 | msgid "type of the record to add/delete/display" |
5077 | msgstr "" | 5133 | msgstr "" |
5078 | 5134 | ||
5079 | #: src/namestore/gnunet-namestore.c:1665 | 5135 | #: src/namestore/gnunet-namestore.c:1615 |
5080 | msgid "URI to import into our zone" | 5136 | msgid "URI to import into our zone" |
5081 | msgstr "" | 5137 | msgstr "" |
5082 | 5138 | ||
5083 | #: src/namestore/gnunet-namestore.c:1671 | 5139 | #: src/namestore/gnunet-namestore.c:1621 |
5084 | msgid "value of the record to add/delete" | 5140 | msgid "value of the record to add/delete" |
5085 | msgstr "" | 5141 | msgstr "" |
5086 | 5142 | ||
5087 | #: src/namestore/gnunet-namestore.c:1675 | 5143 | #: src/namestore/gnunet-namestore.c:1625 |
5088 | msgid "create or list public record" | 5144 | msgid "create or list public record" |
5089 | msgstr "" | 5145 | msgstr "" |
5090 | 5146 | ||
5091 | #: src/namestore/gnunet-namestore.c:1681 | 5147 | #: src/namestore/gnunet-namestore.c:1631 |
5092 | msgid "" | 5148 | msgid "" |
5093 | "create shadow record (only valid if all other records of the same type have " | 5149 | "create shadow record (only valid if all other records of the same type have " |
5094 | "expired" | 5150 | "expired" |
5095 | msgstr "" | 5151 | msgstr "" |
5096 | 5152 | ||
5097 | #: src/namestore/gnunet-namestore.c:1687 | 5153 | #: src/namestore/gnunet-namestore.c:1637 |
5098 | #, fuzzy | 5154 | #, fuzzy |
5099 | msgid "name of the ego controlling the zone" | 5155 | msgid "name of the ego controlling the zone" |
5100 | msgstr "Visa värde av alternativet" | 5156 | msgstr "Visa värde av alternativet" |
5101 | 5157 | ||
5102 | #: src/namestore/gnunet-service-namestore.c:871 | 5158 | #: src/namestore/gnunet-service-namestore.c:879 |
5103 | #, fuzzy, c-format | 5159 | #, fuzzy, c-format |
5104 | msgid "Failed to replicate block in namecache: %s\n" | 5160 | msgid "Failed to replicate block in namecache: %s\n" |
5105 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | 5161 | msgstr "Misslyckades att läsa kompislista från \"%s\"\n" |
5106 | 5162 | ||
5163 | #: src/namestore/gnunet-service-namestore.c:1668 | ||
5164 | #, fuzzy | ||
5165 | msgid "Store failed" | ||
5166 | msgstr "gnunet-update misslyckades!" | ||
5167 | |||
5107 | #: src/namestore/gnunet-zoneimport.c:1847 | 5168 | #: src/namestore/gnunet-zoneimport.c:1847 |
5108 | msgid "size to use for the main hash map" | 5169 | msgid "size to use for the main hash map" |
5109 | msgstr "" | 5170 | msgstr "" |
@@ -5112,10 +5173,6 @@ msgstr "" | |||
5112 | msgid "minimum expiration time we assume for imported records" | 5173 | msgid "minimum expiration time we assume for imported records" |
5113 | msgstr "" | 5174 | msgstr "" |
5114 | 5175 | ||
5115 | #: src/namestore/namestore_api.c:373 | ||
5116 | msgid "Namestore failed to store record\n" | ||
5117 | msgstr "" | ||
5118 | |||
5119 | #: src/namestore/plugin_namestore_flat.c:195 | 5176 | #: src/namestore/plugin_namestore_flat.c:195 |
5120 | #, c-format | 5177 | #, c-format |
5121 | msgid "File too big to map: %llu bytes.\n" | 5178 | msgid "File too big to map: %llu bytes.\n" |
@@ -5714,6 +5771,51 @@ msgstr "Misslyckades att initiera tjänsten \"%s\".\n" | |||
5714 | msgid "Daemon to run to perform IP protocol translation to GNUnet" | 5771 | msgid "Daemon to run to perform IP protocol translation to GNUnet" |
5715 | msgstr "" | 5772 | msgstr "" |
5716 | 5773 | ||
5774 | #: src/reclaim/gnunet-did.c:209 | ||
5775 | #, fuzzy, c-format | ||
5776 | msgid "Invalid DID `%s'\n" | ||
5777 | msgstr "Ogiltiga argument: " | ||
5778 | |||
5779 | #: src/reclaim/gnunet-did.c:835 | ||
5780 | msgid "Create a DID Document and display its DID" | ||
5781 | msgstr "" | ||
5782 | |||
5783 | #: src/reclaim/gnunet-did.c:840 | ||
5784 | msgid "Get the DID Document associated with the given DID" | ||
5785 | msgstr "" | ||
5786 | |||
5787 | #: src/reclaim/gnunet-did.c:844 | ||
5788 | msgid "Show the DID for a given ego" | ||
5789 | msgstr "" | ||
5790 | |||
5791 | #: src/reclaim/gnunet-did.c:849 | ||
5792 | msgid "Remove the DID" | ||
5793 | msgstr "" | ||
5794 | |||
5795 | #: src/reclaim/gnunet-did.c:853 src/reclaim/gnunet-did.c:857 | ||
5796 | msgid "Replace the DID Document." | ||
5797 | msgstr "" | ||
5798 | |||
5799 | #: src/reclaim/gnunet-did.c:863 | ||
5800 | msgid "The Decentralized Identity (DID)" | ||
5801 | msgstr "" | ||
5802 | |||
5803 | #: src/reclaim/gnunet-did.c:869 | ||
5804 | msgid "The DID Document to store in GNUNET" | ||
5805 | msgstr "" | ||
5806 | |||
5807 | #: src/reclaim/gnunet-did.c:874 | ||
5808 | msgid "The name of the EGO" | ||
5809 | msgstr "" | ||
5810 | |||
5811 | #: src/reclaim/gnunet-did.c:880 | ||
5812 | msgid "The time until the DID Document is going to expire (e.g. 5d)" | ||
5813 | msgstr "" | ||
5814 | |||
5815 | #: src/reclaim/gnunet-did.c:889 | ||
5816 | msgid "Manage Decentralized Identities (DIDs)" | ||
5817 | msgstr "" | ||
5818 | |||
5717 | #: src/reclaim/gnunet-reclaim.c:802 | 5819 | #: src/reclaim/gnunet-reclaim.c:802 |
5718 | #, fuzzy, c-format | 5820 | #, fuzzy, c-format |
5719 | msgid "Ego is required\n" | 5821 | msgid "Ego is required\n" |
@@ -6611,17 +6713,17 @@ msgid "" | |||
6611 | "free topology cannot be more than %u. Given `%s = %llu'" | 6713 | "free topology cannot be more than %u. Given `%s = %llu'" |
6612 | msgstr "" | 6714 | msgstr "" |
6613 | 6715 | ||
6614 | #: src/testbed/testbed_api_topology.c:1033 src/testing/testing.c:2643 | 6716 | #: src/testbed/testbed_api_topology.c:1033 src/testing/testing.c:2657 |
6615 | #, fuzzy, c-format | 6717 | #, fuzzy, c-format |
6616 | msgid "Topology file %s not found\n" | 6718 | msgid "Topology file %s not found\n" |
6617 | msgstr "\"%s\" misslyckades: tabell hittades inte!\n" | 6719 | msgstr "\"%s\" misslyckades: tabell hittades inte!\n" |
6618 | 6720 | ||
6619 | #: src/testbed/testbed_api_topology.c:1041 src/testing/testing.c:2651 | 6721 | #: src/testbed/testbed_api_topology.c:1041 src/testing/testing.c:2665 |
6620 | #, c-format | 6722 | #, c-format |
6621 | msgid "Topology file %s has no data\n" | 6723 | msgid "Topology file %s has no data\n" |
6622 | msgstr "" | 6724 | msgstr "" |
6623 | 6725 | ||
6624 | #: src/testbed/testbed_api_topology.c:1049 src/testing/testing.c:2659 | 6726 | #: src/testbed/testbed_api_topology.c:1049 src/testing/testing.c:2673 |
6625 | #, c-format | 6727 | #, c-format |
6626 | msgid "Topology file %s cannot be read\n" | 6728 | msgid "Topology file %s cannot be read\n" |
6627 | msgstr "" | 6729 | msgstr "" |
@@ -6828,7 +6930,7 @@ msgstr "" | |||
6828 | 6930 | ||
6829 | #: src/transport/gnunet-communicator-tcp.c:3338 | 6931 | #: src/transport/gnunet-communicator-tcp.c:3338 |
6830 | #: src/transport/gnunet-communicator-udp.c:3856 | 6932 | #: src/transport/gnunet-communicator-udp.c:3856 |
6831 | #: src/transport/gnunet-service-tng.c:10512 | 6933 | #: src/transport/gnunet-service-tng.c:10623 |
6832 | #: src/transport/gnunet-service-transport.c:2627 | 6934 | #: src/transport/gnunet-service-transport.c:2627 |
6833 | #, fuzzy | 6935 | #, fuzzy |
6834 | msgid "Transport service is lacking key configuration settings. Exiting.\n" | 6936 | msgid "Transport service is lacking key configuration settings. Exiting.\n" |
@@ -8075,58 +8177,58 @@ msgstr "" | |||
8075 | msgid "Need a non-empty hostname for service `%s'.\n" | 8177 | msgid "Need a non-empty hostname for service `%s'.\n" |
8076 | msgstr "" | 8178 | msgstr "" |
8077 | 8179 | ||
8078 | #: src/util/common_logging.c:626 src/util/common_logging.c:665 | 8180 | #: src/util/common_logging.c:648 src/util/common_logging.c:687 |
8079 | #, c-format | 8181 | #, c-format |
8080 | msgid "ERROR: Unable to parse log definition: Syntax error at `%s'.\n" | 8182 | msgid "ERROR: Unable to parse log definition: Syntax error at `%s'.\n" |
8081 | msgstr "" | 8183 | msgstr "" |
8082 | 8184 | ||
8083 | #: src/util/common_logging.c:904 | 8185 | #: src/util/common_logging.c:926 |
8084 | #, c-format | 8186 | #, c-format |
8085 | msgid "Message `%.*s' repeated %u times in the last %s\n" | 8187 | msgid "Message `%.*s' repeated %u times in the last %s\n" |
8086 | msgstr "" | 8188 | msgstr "" |
8087 | 8189 | ||
8088 | #: src/util/common_logging.c:1108 | 8190 | #: src/util/common_logging.c:1131 |
8089 | msgid "ERROR" | 8191 | msgid "ERROR" |
8090 | msgstr "FEL" | 8192 | msgstr "FEL" |
8091 | 8193 | ||
8092 | #: src/util/common_logging.c:1110 | 8194 | #: src/util/common_logging.c:1133 |
8093 | msgid "WARNING" | 8195 | msgid "WARNING" |
8094 | msgstr "VARNING" | 8196 | msgstr "VARNING" |
8095 | 8197 | ||
8096 | #: src/util/common_logging.c:1112 | 8198 | #: src/util/common_logging.c:1135 |
8097 | msgid "MESSAGE" | 8199 | msgid "MESSAGE" |
8098 | msgstr "MEDDELANDE" | 8200 | msgstr "MEDDELANDE" |
8099 | 8201 | ||
8100 | #: src/util/common_logging.c:1114 | 8202 | #: src/util/common_logging.c:1137 |
8101 | msgid "INFO" | 8203 | msgid "INFO" |
8102 | msgstr "INFO" | 8204 | msgstr "INFO" |
8103 | 8205 | ||
8104 | #: src/util/common_logging.c:1116 | 8206 | #: src/util/common_logging.c:1139 |
8105 | msgid "DEBUG" | 8207 | msgid "DEBUG" |
8106 | msgstr "FELSÖKNING" | 8208 | msgstr "FELSÖKNING" |
8107 | 8209 | ||
8108 | #: src/util/common_logging.c:1118 | 8210 | #: src/util/common_logging.c:1141 |
8109 | msgid "NONE" | 8211 | msgid "NONE" |
8110 | msgstr "" | 8212 | msgstr "" |
8111 | 8213 | ||
8112 | #: src/util/common_logging.c:1119 | 8214 | #: src/util/common_logging.c:1142 |
8113 | msgid "INVALID" | 8215 | msgid "INVALID" |
8114 | msgstr "" | 8216 | msgstr "" |
8115 | 8217 | ||
8116 | #: src/util/common_logging.c:1400 | 8218 | #: src/util/common_logging.c:1423 |
8117 | msgid "unknown address" | 8219 | msgid "unknown address" |
8118 | msgstr "" | 8220 | msgstr "" |
8119 | 8221 | ||
8120 | #: src/util/common_logging.c:1445 | 8222 | #: src/util/common_logging.c:1468 |
8121 | msgid "invalid address" | 8223 | msgid "invalid address" |
8122 | msgstr "" | 8224 | msgstr "" |
8123 | 8225 | ||
8124 | #: src/util/common_logging.c:1464 | 8226 | #: src/util/common_logging.c:1487 |
8125 | #, fuzzy, c-format | 8227 | #, fuzzy, c-format |
8126 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" | 8228 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" |
8127 | msgstr "Konfigurationsfil \"%s\" skapad.\n" | 8229 | msgstr "Konfigurationsfil \"%s\" skapad.\n" |
8128 | 8230 | ||
8129 | #: src/util/common_logging.c:1487 | 8231 | #: src/util/common_logging.c:1510 |
8130 | #, fuzzy, c-format | 8232 | #, fuzzy, c-format |
8131 | msgid "" | 8233 | msgid "" |
8132 | "Configuration specifies invalid value for option `%s' in section `%s': %s\n" | 8234 | "Configuration specifies invalid value for option `%s' in section `%s': %s\n" |
@@ -8273,17 +8375,17 @@ msgstr "Misslyckades att leverera \"%s\" meddelande.\n" | |||
8273 | msgid "Could not bind to any port: %s\n" | 8375 | msgid "Could not bind to any port: %s\n" |
8274 | msgstr "Kunde inte köra \"%s\": %s\n" | 8376 | msgstr "Kunde inte köra \"%s\": %s\n" |
8275 | 8377 | ||
8276 | #: src/util/dnsstub.c:344 | 8378 | #: src/util/dnsstub.c:370 |
8277 | #, c-format | 8379 | #, c-format |
8278 | msgid "Received DNS response that is too small (%u bytes)" | 8380 | msgid "Received DNS response that is too small (%u bytes)\n" |
8279 | msgstr "" | 8381 | msgstr "" |
8280 | 8382 | ||
8281 | #: src/util/dnsstub.c:482 | 8383 | #: src/util/dnsstub.c:508 |
8282 | #, fuzzy, c-format | 8384 | #, fuzzy, c-format |
8283 | msgid "Failed to send DNS request to %s: %s\n" | 8385 | msgid "Failed to send DNS request to %s: %s\n" |
8284 | msgstr "Misslyckades att skicka HTTP-begäran till värd \"%s\": %s\n" | 8386 | msgstr "Misslyckades att skicka HTTP-begäran till värd \"%s\": %s\n" |
8285 | 8387 | ||
8286 | #: src/util/dnsstub.c:487 | 8388 | #: src/util/dnsstub.c:513 |
8287 | #, fuzzy, c-format | 8389 | #, fuzzy, c-format |
8288 | msgid "Sent DNS request to %s\n" | 8390 | msgid "Sent DNS request to %s\n" |
8289 | msgstr "Misslyckades att skicka HTTP-begäran till värd \"%s\": %s\n" | 8391 | msgstr "Misslyckades att skicka HTTP-begäran till värd \"%s\": %s\n" |
@@ -8370,83 +8472,83 @@ msgstr "" | |||
8370 | "Argument som är obligatoriska för långa flaggor är också obligatoriska för " | 8472 | "Argument som är obligatoriska för långa flaggor är också obligatoriska för " |
8371 | "korta flaggor.\n" | 8473 | "korta flaggor.\n" |
8372 | 8474 | ||
8373 | #: src/util/getopt_helpers.c:196 | 8475 | #: src/util/getopt_helpers.c:197 |
8374 | msgid "print this help" | 8476 | msgid "print this help" |
8375 | msgstr "skriv ut denna hjälp" | 8477 | msgstr "skriv ut denna hjälp" |
8376 | 8478 | ||
8377 | #: src/util/getopt_helpers.c:261 | 8479 | #: src/util/getopt_helpers.c:262 |
8378 | msgid "be verbose" | 8480 | msgid "be verbose" |
8379 | msgstr "var informativ" | 8481 | msgstr "var informativ" |
8380 | 8482 | ||
8381 | #: src/util/getopt_helpers.c:377 | 8483 | #: src/util/getopt_helpers.c:378 |
8382 | msgid "configure logging to use LOGLEVEL" | 8484 | msgid "configure logging to use LOGLEVEL" |
8383 | msgstr "" | 8485 | msgstr "" |
8384 | 8486 | ||
8385 | #: src/util/getopt_helpers.c:444 | 8487 | #: src/util/getopt_helpers.c:445 |
8386 | msgid "configure logging to write logs to FILENAME" | 8488 | msgid "configure logging to write logs to FILENAME" |
8387 | msgstr "" | 8489 | msgstr "" |
8388 | 8490 | ||
8389 | #: src/util/getopt_helpers.c:461 | 8491 | #: src/util/getopt_helpers.c:462 |
8390 | #, fuzzy | 8492 | #, fuzzy |
8391 | msgid "use configuration file FILENAME" | 8493 | msgid "use configuration file FILENAME" |
8392 | msgstr "skriv ut ett värde från konfigurationsfilen till standard ut" | 8494 | msgstr "skriv ut ett värde från konfigurationsfilen till standard ut" |
8393 | 8495 | ||
8394 | #: src/util/getopt_helpers.c:497 src/util/getopt_helpers.c:811 | 8496 | #: src/util/getopt_helpers.c:498 src/util/getopt_helpers.c:812 |
8395 | #: src/util/getopt_helpers.c:867 | 8497 | #: src/util/getopt_helpers.c:868 |
8396 | #, c-format | 8498 | #, c-format |
8397 | msgid "You must pass a number to the `%s' option.\n" | 8499 | msgid "You must pass a number to the `%s' option.\n" |
8398 | msgstr "Du måste skicka med ett nummer till flaggan \"%s\".\n" | 8500 | msgstr "Du måste skicka med ett nummer till flaggan \"%s\".\n" |
8399 | 8501 | ||
8400 | #: src/util/getopt_helpers.c:569 | 8502 | #: src/util/getopt_helpers.c:570 |
8401 | #, fuzzy, c-format | 8503 | #, fuzzy, c-format |
8402 | msgid "" | 8504 | msgid "" |
8403 | "You must pass a relative time (optionally with sign) to the `%s' option.\n" | 8505 | "You must pass a relative time (optionally with sign) to the `%s' option.\n" |
8404 | msgstr "Du måste skicka med ett nummer till flaggan \"%s\".\n" | 8506 | msgstr "Du måste skicka med ett nummer till flaggan \"%s\".\n" |
8405 | 8507 | ||
8406 | #: src/util/getopt_helpers.c:576 | 8508 | #: src/util/getopt_helpers.c:577 |
8407 | #, c-format | 8509 | #, c-format |
8408 | msgid "Value given for time travel `%s' option is too big.\n" | 8510 | msgid "Value given for time travel `%s' option is too big.\n" |
8409 | msgstr "" | 8511 | msgstr "" |
8410 | 8512 | ||
8411 | #: src/util/getopt_helpers.c:594 | 8513 | #: src/util/getopt_helpers.c:595 |
8412 | msgid "[+/-]MICROSECONDS" | 8514 | msgid "[+/-]MICROSECONDS" |
8413 | msgstr "" | 8515 | msgstr "" |
8414 | 8516 | ||
8415 | #: src/util/getopt_helpers.c:596 | 8517 | #: src/util/getopt_helpers.c:597 |
8416 | msgid "modify system time by given offset (for debugging/testing only)" | 8518 | msgid "modify system time by given offset (for debugging/testing only)" |
8417 | msgstr "" | 8519 | msgstr "" |
8418 | 8520 | ||
8419 | #: src/util/getopt_helpers.c:630 | 8521 | #: src/util/getopt_helpers.c:631 |
8420 | #, fuzzy, c-format | 8522 | #, fuzzy, c-format |
8421 | msgid "You must pass relative time to the `%s' option.\n" | 8523 | msgid "You must pass relative time to the `%s' option.\n" |
8422 | msgstr "Du måste skicka med ett nummer till flaggan \"%s\".\n" | 8524 | msgstr "Du måste skicka med ett nummer till flaggan \"%s\".\n" |
8423 | 8525 | ||
8424 | #: src/util/getopt_helpers.c:684 | 8526 | #: src/util/getopt_helpers.c:685 |
8425 | #, fuzzy, c-format | 8527 | #, fuzzy, c-format |
8426 | msgid "You must pass absolute time to the `%s' option.\n" | 8528 | msgid "You must pass absolute time to the `%s' option.\n" |
8427 | msgstr "Du måste skicka med ett nummer till flaggan \"%s\".\n" | 8529 | msgstr "Du måste skicka med ett nummer till flaggan \"%s\".\n" |
8428 | 8530 | ||
8429 | #: src/util/getopt_helpers.c:741 | 8531 | #: src/util/getopt_helpers.c:742 |
8430 | #, fuzzy, c-format | 8532 | #, fuzzy, c-format |
8431 | msgid "You must pass a timestamp to the `%s' option.\n" | 8533 | msgid "You must pass a timestamp to the `%s' option.\n" |
8432 | msgstr "Du måste skicka med ett nummer till flaggan \"%s\".\n" | 8534 | msgstr "Du måste skicka med ett nummer till flaggan \"%s\".\n" |
8433 | 8535 | ||
8434 | #: src/util/getopt_helpers.c:748 | 8536 | #: src/util/getopt_helpers.c:749 |
8435 | #, c-format | 8537 | #, c-format |
8436 | msgid "The maximum precision allowed for timestamps is seconds.\n" | 8538 | msgid "The maximum precision allowed for timestamps is seconds.\n" |
8437 | msgstr "" | 8539 | msgstr "" |
8438 | 8540 | ||
8439 | #: src/util/getopt_helpers.c:804 | 8541 | #: src/util/getopt_helpers.c:805 |
8440 | #, c-format | 8542 | #, c-format |
8441 | msgid "Your input for the '%s' option has to be a non negative number\n" | 8543 | msgid "Your input for the '%s' option has to be a non negative number\n" |
8442 | msgstr "" | 8544 | msgstr "" |
8443 | 8545 | ||
8444 | #: src/util/getopt_helpers.c:874 | 8546 | #: src/util/getopt_helpers.c:875 |
8445 | #, fuzzy, c-format | 8547 | #, fuzzy, c-format |
8446 | msgid "You must pass a number below %u to the `%s' option.\n" | 8548 | msgid "You must pass a number below %u to the `%s' option.\n" |
8447 | msgstr "Du måste skicka med ett nummer till flaggan \"%s\".\n" | 8549 | msgstr "Du måste skicka med ett nummer till flaggan \"%s\".\n" |
8448 | 8550 | ||
8449 | #: src/util/getopt_helpers.c:952 | 8551 | #: src/util/getopt_helpers.c:953 |
8450 | #, c-format | 8552 | #, c-format |
8451 | msgid "Argument `%s' malformed. Expected base32 (Crockford) encoded value.\n" | 8553 | msgid "Argument `%s' malformed. Expected base32 (Crockford) encoded value.\n" |
8452 | msgstr "" | 8554 | msgstr "" |
@@ -8480,7 +8582,7 @@ msgstr "" | |||
8480 | msgid "Manipulate GNUnet configuration files" | 8582 | msgid "Manipulate GNUnet configuration files" |
8481 | msgstr "skriv ut ett värde från konfigurationsfilen till standard ut" | 8583 | msgstr "skriv ut ett värde från konfigurationsfilen till standard ut" |
8482 | 8584 | ||
8483 | #: src/util/gnunet-crypto-tvg.c:1072 | 8585 | #: src/util/gnunet-crypto-tvg.c:1483 |
8484 | msgid "verify a test vector from stdin" | 8586 | msgid "verify a test vector from stdin" |
8485 | msgstr "" | 8587 | msgstr "" |
8486 | 8588 | ||
@@ -8734,7 +8836,7 @@ msgstr "Fel vid skapandet av användare" | |||
8734 | msgid "Unable to shorten unix path `%s' while keeping name unique\n" | 8836 | msgid "Unable to shorten unix path `%s' while keeping name unique\n" |
8735 | msgstr "" | 8837 | msgstr "" |
8736 | 8838 | ||
8737 | #: src/util/network.c:1306 | 8839 | #: src/util/network.c:1307 |
8738 | #, c-format | 8840 | #, c-format |
8739 | msgid "" | 8841 | msgid "" |
8740 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" | 8842 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" |
@@ -8864,77 +8966,77 @@ msgstr "" | |||
8864 | msgid "Character sets requested were `%s'->`%s'\n" | 8966 | msgid "Character sets requested were `%s'->`%s'\n" |
8865 | msgstr "" | 8967 | msgstr "" |
8866 | 8968 | ||
8867 | #: src/util/strings.c:487 | 8969 | #: src/util/strings.c:514 |
8868 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" | 8970 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" |
8869 | msgstr "" | 8971 | msgstr "" |
8870 | 8972 | ||
8871 | #: src/util/strings.c:1023 | 8973 | #: src/util/strings.c:1050 |
8872 | msgid "IPv6 address did not start with `['\n" | 8974 | msgid "IPv6 address did not start with `['\n" |
8873 | msgstr "" | 8975 | msgstr "" |
8874 | 8976 | ||
8875 | #: src/util/strings.c:1031 | 8977 | #: src/util/strings.c:1058 |
8876 | msgid "IPv6 address did contain ':' to separate port number\n" | 8978 | msgid "IPv6 address did contain ':' to separate port number\n" |
8877 | msgstr "" | 8979 | msgstr "" |
8878 | 8980 | ||
8879 | #: src/util/strings.c:1038 | 8981 | #: src/util/strings.c:1065 |
8880 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" | 8982 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" |
8881 | msgstr "" | 8983 | msgstr "" |
8882 | 8984 | ||
8883 | #: src/util/strings.c:1046 | 8985 | #: src/util/strings.c:1073 |
8884 | msgid "IPv6 address did contain a valid port number after the last ':'\n" | 8986 | msgid "IPv6 address did contain a valid port number after the last ':'\n" |
8885 | msgstr "" | 8987 | msgstr "" |
8886 | 8988 | ||
8887 | #: src/util/strings.c:1055 | 8989 | #: src/util/strings.c:1082 |
8888 | #, fuzzy, c-format | 8990 | #, fuzzy, c-format |
8889 | msgid "Invalid IPv6 address `%s': %s\n" | 8991 | msgid "Invalid IPv6 address `%s': %s\n" |
8890 | msgstr "Ogiltigt svar på \"%s\".\n" | 8992 | msgstr "Ogiltigt svar på \"%s\".\n" |
8891 | 8993 | ||
8892 | #: src/util/strings.c:1237 src/util/strings.c:1248 | 8994 | #: src/util/strings.c:1264 src/util/strings.c:1275 |
8893 | msgid "Port not in range\n" | 8995 | msgid "Port not in range\n" |
8894 | msgstr "" | 8996 | msgstr "" |
8895 | 8997 | ||
8896 | #: src/util/strings.c:1257 | 8998 | #: src/util/strings.c:1284 |
8897 | #, fuzzy, c-format | 8999 | #, fuzzy, c-format |
8898 | msgid "Malformed port policy `%s'\n" | 9000 | msgid "Malformed port policy `%s'\n" |
8899 | msgstr "Misslyckades att starta samling.\n" | 9001 | msgstr "Misslyckades att starta samling.\n" |
8900 | 9002 | ||
8901 | #: src/util/strings.c:1328 src/util/strings.c:1357 src/util/strings.c:1404 | 9003 | #: src/util/strings.c:1355 src/util/strings.c:1384 src/util/strings.c:1431 |
8902 | #: src/util/strings.c:1424 | 9004 | #: src/util/strings.c:1451 |
8903 | #, c-format | 9005 | #, c-format |
8904 | msgid "Invalid format for IP: `%s'\n" | 9006 | msgid "Invalid format for IP: `%s'\n" |
8905 | msgstr "Ogiltigt format för IP: \"%s\"\n" | 9007 | msgstr "Ogiltigt format för IP: \"%s\"\n" |
8906 | 9008 | ||
8907 | #: src/util/strings.c:1382 | 9009 | #: src/util/strings.c:1409 |
8908 | #, c-format | 9010 | #, c-format |
8909 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." | 9011 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." |
8910 | msgstr "Ogiltig nätverksnotation (\"/%d\" är inte giltig i IPv4 CIDR)." | 9012 | msgstr "Ogiltig nätverksnotation (\"/%d\" är inte giltig i IPv4 CIDR)." |
8911 | 9013 | ||
8912 | #: src/util/strings.c:1433 | 9014 | #: src/util/strings.c:1460 |
8913 | #, fuzzy, c-format | 9015 | #, fuzzy, c-format |
8914 | msgid "Invalid format: `%s'\n" | 9016 | msgid "Invalid format: `%s'\n" |
8915 | msgstr "Ogiltigt format för IP: \"%s\"\n" | 9017 | msgstr "Ogiltigt format för IP: \"%s\"\n" |
8916 | 9018 | ||
8917 | #: src/util/strings.c:1475 | 9019 | #: src/util/strings.c:1502 |
8918 | #, c-format | 9020 | #, c-format |
8919 | msgid "Invalid network notation (does not end with ';': `%s')\n" | 9021 | msgid "Invalid network notation (does not end with ';': `%s')\n" |
8920 | msgstr "Ogiltig nätverksnotation (slutar inte med \";\": \"%s\")\n" | 9022 | msgstr "Ogiltig nätverksnotation (slutar inte med \";\": \"%s\")\n" |
8921 | 9023 | ||
8922 | #: src/util/strings.c:1525 | 9024 | #: src/util/strings.c:1552 |
8923 | #, fuzzy, c-format | 9025 | #, fuzzy, c-format |
8924 | msgid "Wrong format `%s' for netmask\n" | 9026 | msgid "Wrong format `%s' for netmask\n" |
8925 | msgstr "Fel format \"%s\" för nätmask: %s\n" | 9027 | msgstr "Fel format \"%s\" för nätmask: %s\n" |
8926 | 9028 | ||
8927 | #: src/util/strings.c:1556 | 9029 | #: src/util/strings.c:1583 |
8928 | #, fuzzy, c-format | 9030 | #, fuzzy, c-format |
8929 | msgid "Wrong format `%s' for network\n" | 9031 | msgid "Wrong format `%s' for network\n" |
8930 | msgstr "Fel format \"%s\" för nätverk: %s\n" | 9032 | msgstr "Fel format \"%s\" för nätverk: %s\n" |
8931 | 9033 | ||
8932 | #: src/util/time.c:863 src/util/time.c:891 | 9034 | #: src/util/time.c:870 src/util/time.c:898 |
8933 | #, c-format | 9035 | #, c-format |
8934 | msgid "Failed to map `%s', cannot assure monotonic time!\n" | 9036 | msgid "Failed to map `%s', cannot assure monotonic time!\n" |
8935 | msgstr "" | 9037 | msgstr "" |
8936 | 9038 | ||
8937 | #: src/util/time.c:899 | 9039 | #: src/util/time.c:906 |
8938 | #, c-format | 9040 | #, c-format |
8939 | msgid "" | 9041 | msgid "" |
8940 | "Failed to setup monotonic time file `%s', cannot assure monotonic time!\n" | 9042 | "Failed to setup monotonic time file `%s', cannot assure monotonic time!\n" |
@@ -9118,13 +9220,29 @@ msgstr "# byte mottagna via UDP" | |||
9118 | msgid "Setup tunnels via VPN." | 9220 | msgid "Setup tunnels via VPN." |
9119 | msgstr "" | 9221 | msgstr "" |
9120 | 9222 | ||
9121 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:418 | 9223 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:397 |
9122 | #: src/zonemaster/gnunet-service-zonemaster.c:847 | 9224 | #: src/zonemaster/gnunet-service-zonemaster.c:832 |
9123 | #, fuzzy | 9225 | #, fuzzy |
9124 | msgid "Failed to connect to the namestore!\n" | 9226 | msgid "Failed to connect to the namestore!\n" |
9125 | msgstr "Misslyckades att ansluta till gnunetd.\n" | 9227 | msgstr "Misslyckades att ansluta till gnunetd.\n" |
9126 | 9228 | ||
9127 | #, fuzzy | 9229 | #, fuzzy |
9230 | #~ msgid "# items stored" | ||
9231 | #~ msgstr "# byte krypterade" | ||
9232 | |||
9233 | #, fuzzy, c-format | ||
9234 | #~ msgid "Failed to load datacache plugin for `%s'\n" | ||
9235 | #~ msgstr "Misslyckades att läsa kompislista från \"%s\"\n" | ||
9236 | |||
9237 | #, fuzzy | ||
9238 | #~ msgid "# requests received" | ||
9239 | #~ msgstr "# byte mottogs via TCP" | ||
9240 | |||
9241 | #, fuzzy | ||
9242 | #~ msgid "# proximity search requests received" | ||
9243 | #~ msgstr "# klartext PONG-meddelanden mottagna" | ||
9244 | |||
9245 | #, fuzzy | ||
9128 | #~ msgid "# requests for random value received" | 9246 | #~ msgid "# requests for random value received" |
9129 | #~ msgstr "# byte mottogs via TCP" | 9247 | #~ msgstr "# byte mottogs via TCP" |
9130 | 9248 | ||
@@ -10546,10 +10664,6 @@ msgstr "Misslyckades att ansluta till gnunetd.\n" | |||
10546 | #~ msgstr "Filen \"%s\" innehåller ingen pseudonym.\n" | 10664 | #~ msgstr "Filen \"%s\" innehåller ingen pseudonym.\n" |
10547 | 10665 | ||
10548 | #, fuzzy | 10666 | #, fuzzy |
10549 | #~ msgid "gnunet-ecc failed" | ||
10550 | #~ msgstr "gnunet-update misslyckades!" | ||
10551 | |||
10552 | #, fuzzy | ||
10553 | #~ msgid "" | 10667 | #~ msgid "" |
10554 | #~ "File `%s' does not contain a valid private key (too long, %llu bytes). " | 10668 | #~ "File `%s' does not contain a valid private key (too long, %llu bytes). " |
10555 | #~ "Renaming it.\n" | 10669 | #~ "Renaming it.\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: 2022-01-10 15:13+0100\n" | 11 | "POT-Creation-Date: 2022-03-04 22:23+0100\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" |
@@ -19,7 +19,7 @@ msgstr "" | |||
19 | "Plural-Forms: nplurals=1; plural=0;\n" | 19 | "Plural-Forms: nplurals=1; plural=0;\n" |
20 | "X-Generator: LocFactoryEditor 1.7b3\n" | 20 | "X-Generator: LocFactoryEditor 1.7b3\n" |
21 | 21 | ||
22 | #: src/abd/gnunet-abd.c:392 src/namestore/gnunet-namestore.c:1304 | 22 | #: src/abd/gnunet-abd.c:392 src/namestore/gnunet-namestore.c:1254 |
23 | #, c-format | 23 | #, c-format |
24 | msgid "Ego `%s' not known to identity service\n" | 24 | msgid "Ego `%s' not known to identity service\n" |
25 | msgstr "" | 25 | msgstr "" |
@@ -31,7 +31,7 @@ msgstr "Äối số không hợp lệ cho « %s ».\n" | |||
31 | 31 | ||
32 | #: src/abd/gnunet-abd.c:558 src/abd/gnunet-service-abd.c:1751 | 32 | #: src/abd/gnunet-abd.c:558 src/abd/gnunet-service-abd.c:1751 |
33 | #: src/namestore/gnunet-namestore-fcfsd.c:1080 | 33 | #: src/namestore/gnunet-namestore-fcfsd.c:1080 |
34 | #: src/namestore/gnunet-namestore.c:1001 | 34 | #: src/namestore/gnunet-namestore.c:951 |
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." |
@@ -636,45 +636,45 @@ msgstr "" | |||
636 | msgid "Print information about ATS state" | 636 | msgid "Print information about ATS state" |
637 | msgstr "In ra thông tin vỠcác đồng đẳng GNUnet." | 637 | msgstr "In ra thông tin vỠcác đồng đẳng GNUnet." |
638 | 638 | ||
639 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | 639 | #: src/ats/gnunet-ats-solver-eval.c:2993 src/ats/gnunet-ats-solver-eval.c:3045 |
640 | #, c-format | 640 | #, c-format |
641 | msgid "" | 641 | msgid "" |
642 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | 642 | "Could not load quota for network `%s': `%s', assigning default bandwidth " |
643 | "%llu\n" | 643 | "%llu\n" |
644 | msgstr "" | 644 | msgstr "" |
645 | 645 | ||
646 | #: src/ats/gnunet-ats-solver-eval.c:3011 | 646 | #: src/ats/gnunet-ats-solver-eval.c:3012 |
647 | #, c-format | 647 | #, c-format |
648 | msgid "" | 648 | msgid "" |
649 | "No outbound quota configured for network `%s', assigning default bandwidth " | 649 | "No outbound quota configured for network `%s', assigning default bandwidth " |
650 | "%llu\n" | 650 | "%llu\n" |
651 | msgstr "" | 651 | msgstr "" |
652 | 652 | ||
653 | #: src/ats/gnunet-ats-solver-eval.c:3063 | 653 | #: src/ats/gnunet-ats-solver-eval.c:3064 |
654 | #, c-format | 654 | #, c-format |
655 | msgid "" | 655 | msgid "" |
656 | "No outbound quota configure for network `%s', assigning default bandwidth " | 656 | "No outbound quota configure for network `%s', assigning default bandwidth " |
657 | "%llu\n" | 657 | "%llu\n" |
658 | msgstr "" | 658 | msgstr "" |
659 | 659 | ||
660 | #: src/ats/gnunet-ats-solver-eval.c:3552 | 660 | #: src/ats/gnunet-ats-solver-eval.c:3553 |
661 | msgid "solver to use" | 661 | msgid "solver to use" |
662 | msgstr "" | 662 | msgstr "" |
663 | 663 | ||
664 | #: src/ats/gnunet-ats-solver-eval.c:3557 | 664 | #: src/ats/gnunet-ats-solver-eval.c:3558 |
665 | msgid "experiment to use" | 665 | msgid "experiment to use" |
666 | msgstr "" | 666 | msgstr "" |
667 | 667 | ||
668 | #: src/ats/gnunet-ats-solver-eval.c:3564 | 668 | #: src/ats/gnunet-ats-solver-eval.c:3565 |
669 | #, fuzzy | 669 | #, fuzzy |
670 | msgid "print logging" | 670 | msgid "print logging" |
671 | msgstr "Theo dõi" | 671 | msgstr "Theo dõi" |
672 | 672 | ||
673 | #: src/ats/gnunet-ats-solver-eval.c:3569 | 673 | #: src/ats/gnunet-ats-solver-eval.c:3570 |
674 | msgid "save logging to disk" | 674 | msgid "save logging to disk" |
675 | msgstr "" | 675 | msgstr "" |
676 | 676 | ||
677 | #: src/ats/gnunet-ats-solver-eval.c:3574 | 677 | #: src/ats/gnunet-ats-solver-eval.c:3575 |
678 | msgid "disable normalization" | 678 | msgid "disable normalization" |
679 | msgstr "" | 679 | msgstr "" |
680 | 680 | ||
@@ -1576,42 +1576,7 @@ msgstr "# các thông báo phát hiện dht được nháºn" | |||
1576 | msgid "# updates to my type map" | 1576 | msgid "# updates to my type map" |
1577 | msgstr "" | 1577 | msgstr "" |
1578 | 1578 | ||
1579 | #: src/datacache/datacache.c:117 src/datacache/datacache.c:275 | 1579 | #: src/datacache/plugin_datacache_heap.c:555 |
1580 | #: src/datastore/gnunet-service-datastore.c:743 | ||
1581 | #, fuzzy | ||
1582 | msgid "# bytes stored" | ||
1583 | msgstr "# các byte trong kho dữ liệu" | ||
1584 | |||
1585 | #: src/datacache/datacache.c:121 src/datacache/datacache.c:279 | ||
1586 | #, fuzzy | ||
1587 | msgid "# items stored" | ||
1588 | msgstr "# các byte trong kho dữ liệu" | ||
1589 | |||
1590 | #: src/datacache/datacache.c:185 | ||
1591 | #, c-format | ||
1592 | msgid "Loading `%s' datacache plugin\n" | ||
1593 | msgstr "" | ||
1594 | |||
1595 | #: src/datacache/datacache.c:203 | ||
1596 | #, fuzzy, c-format | ||
1597 | msgid "Failed to load datacache plugin for `%s'\n" | ||
1598 | msgstr "Lá»—i cáºp nháºt dữ liệu cho mô-Ä‘un « %s »\n" | ||
1599 | |||
1600 | #: src/datacache/datacache.c:297 | ||
1601 | #, fuzzy | ||
1602 | msgid "# requests received" | ||
1603 | msgstr "# các yêu cầu get (lấy) dht được nháºn" | ||
1604 | |||
1605 | #: src/datacache/datacache.c:308 | ||
1606 | msgid "# requests filtered by bloom filter" | ||
1607 | msgstr "# các yêu cầu được lá»c theo bá»™ lá»c bloom" | ||
1608 | |||
1609 | #: src/datacache/datacache.c:329 | ||
1610 | #, fuzzy | ||
1611 | msgid "# proximity search requests received" | ||
1612 | msgstr "# các yêu cầu khách lá»— hổng được nháºn" | ||
1613 | |||
1614 | #: src/datacache/plugin_datacache_heap.c:527 | ||
1615 | #, fuzzy | 1580 | #, fuzzy |
1616 | msgid "Heap datacache running\n" | 1581 | msgid "Heap datacache running\n" |
1617 | msgstr "kho dữ liệu sqlite" | 1582 | msgstr "kho dữ liệu sqlite" |
@@ -1634,7 +1599,7 @@ msgstr "kho dữ liệu sqlite" | |||
1634 | msgid "`%s' failed at %s:%d with error: %s\n" | 1599 | msgid "`%s' failed at %s:%d with error: %s\n" |
1635 | msgstr "« %s » bị lỗi tại %s:%d với lỗi: %s\n" | 1600 | msgstr "« %s » bị lỗi tại %s:%d với lỗi: %s\n" |
1636 | 1601 | ||
1637 | #: src/datacache/plugin_datacache_sqlite.c:693 | 1602 | #: src/datacache/plugin_datacache_sqlite.c:723 |
1638 | #: src/datastore/plugin_datastore_sqlite.c:531 | 1603 | #: src/datastore/plugin_datastore_sqlite.c:531 |
1639 | #: src/namecache/plugin_namecache_sqlite.c:237 | 1604 | #: src/namecache/plugin_namecache_sqlite.c:237 |
1640 | #: src/namestore/plugin_namestore_sqlite.c:273 | 1605 | #: src/namestore/plugin_namestore_sqlite.c:273 |
@@ -1831,6 +1796,11 @@ msgstr "" | |||
1831 | msgid "Could not find matching reservation" | 1796 | msgid "Could not find matching reservation" |
1832 | msgstr "" | 1797 | msgstr "" |
1833 | 1798 | ||
1799 | #: src/datastore/gnunet-service-datastore.c:743 | ||
1800 | #, fuzzy | ||
1801 | msgid "# bytes stored" | ||
1802 | msgstr "# các byte trong kho dữ liệu" | ||
1803 | |||
1834 | #: src/datastore/gnunet-service-datastore.c:758 | 1804 | #: src/datastore/gnunet-service-datastore.c:758 |
1835 | #, c-format | 1805 | #, c-format |
1836 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" | 1806 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" |
@@ -2023,7 +1993,7 @@ msgstr "" | |||
2023 | 1993 | ||
2024 | #: src/datastore/plugin_datastore_sqlite.c:1337 | 1994 | #: src/datastore/plugin_datastore_sqlite.c:1337 |
2025 | #: src/namecache/plugin_namecache_sqlite.c:564 | 1995 | #: src/namecache/plugin_namecache_sqlite.c:564 |
2026 | #: src/namestore/plugin_namestore_sqlite.c:765 | 1996 | #: src/namestore/plugin_namestore_sqlite.c:775 |
2027 | #, fuzzy | 1997 | #, fuzzy |
2028 | msgid "Sqlite database running\n" | 1998 | msgid "Sqlite database running\n" |
2029 | msgstr "kho dữ liệu sqlite" | 1999 | msgstr "kho dữ liệu sqlite" |
@@ -2032,56 +2002,65 @@ msgstr "kho dữ liệu sqlite" | |||
2032 | msgid "Template database running\n" | 2002 | msgid "Template database running\n" |
2033 | msgstr "" | 2003 | msgstr "" |
2034 | 2004 | ||
2035 | #: src/dht/gnunet-dht-get.c:159 | 2005 | #: src/dht/gnunet-dht-get.c:164 |
2036 | #, c-format | 2006 | #, c-format |
2037 | msgid "" | 2007 | msgid "" |
2038 | "Result %d, type %d:\n" | 2008 | "Result %d, type %d:\n" |
2039 | "%.*s\n" | 2009 | "%.*s\n" |
2040 | msgstr "" | 2010 | msgstr "" |
2041 | 2011 | ||
2042 | #: src/dht/gnunet-dht-get.c:160 | 2012 | #: src/dht/gnunet-dht-get.c:165 |
2043 | #, c-format | 2013 | #, c-format |
2044 | msgid "Result %d, type %d:\n" | 2014 | msgid "Result %d, type %d:\n" |
2045 | msgstr "" | 2015 | msgstr "" |
2046 | 2016 | ||
2047 | #: src/dht/gnunet-dht-get.c:209 | 2017 | #: src/dht/gnunet-dht-get.c:215 |
2048 | msgid "Must provide key for DHT GET!\n" | 2018 | msgid "Must provide key for DHT GET!\n" |
2049 | msgstr "" | 2019 | msgstr "" |
2050 | 2020 | ||
2051 | #: src/dht/gnunet-dht-get.c:217 src/dht/gnunet-dht-monitor.c:255 | 2021 | #: src/dht/gnunet-dht-get.c:223 src/dht/gnunet-dht-hello.c:119 |
2052 | #, fuzzy | 2022 | #: src/dht/gnunet-dht-monitor.c:255 |
2023 | #, fuzzy, c-format | ||
2053 | msgid "Failed to connect to DHT service!\n" | 2024 | msgid "Failed to connect to DHT service!\n" |
2054 | msgstr "Lỗi kết nối đến gnunetd.\n" | 2025 | msgstr "Lỗi kết nối đến gnunetd.\n" |
2055 | 2026 | ||
2056 | #: src/dht/gnunet-dht-get.c:227 | 2027 | #: src/dht/gnunet-dht-get.c:233 |
2057 | msgid "Issuing DHT GET with key" | 2028 | msgid "Issuing DHT GET with key" |
2058 | msgstr "" | 2029 | msgstr "" |
2059 | 2030 | ||
2060 | #: src/dht/gnunet-dht-get.c:260 src/dht/gnunet-dht-monitor.c:302 | 2031 | #: src/dht/gnunet-dht-get.c:269 src/dht/gnunet-dht-monitor.c:302 |
2061 | #: src/dht/gnunet-dht-put.c:200 | 2032 | #: src/dht/gnunet-dht-put.c:200 |
2062 | msgid "the query key" | 2033 | msgid "the query key" |
2063 | msgstr "" | 2034 | msgstr "" |
2064 | 2035 | ||
2065 | #: src/dht/gnunet-dht-get.c:266 | 2036 | #: src/dht/gnunet-dht-get.c:275 |
2066 | msgid "how many parallel requests (replicas) to create" | 2037 | msgid "how many parallel requests (replicas) to create" |
2067 | msgstr "" | 2038 | msgstr "" |
2068 | 2039 | ||
2069 | #: src/dht/gnunet-dht-get.c:272 src/dht/gnunet-dht-monitor.c:308 | 2040 | #: src/dht/gnunet-dht-get.c:280 src/dht/gnunet-dht-put.c:217 |
2041 | msgid "use DHT's record route option" | ||
2042 | msgstr "" | ||
2043 | |||
2044 | #: src/dht/gnunet-dht-get.c:286 src/dht/gnunet-dht-monitor.c:308 | ||
2070 | msgid "the type of data to look for" | 2045 | msgid "the type of data to look for" |
2071 | msgstr "" | 2046 | msgstr "" |
2072 | 2047 | ||
2073 | #: src/dht/gnunet-dht-get.c:278 | 2048 | #: src/dht/gnunet-dht-get.c:292 |
2074 | msgid "how long to execute this query before giving up?" | 2049 | msgid "how long to execute this query before giving up?" |
2075 | msgstr "" | 2050 | msgstr "" |
2076 | 2051 | ||
2077 | #: src/dht/gnunet-dht-get.c:284 src/dht/gnunet-dht-put.c:206 | 2052 | #: src/dht/gnunet-dht-get.c:298 src/dht/gnunet-dht-put.c:206 |
2078 | msgid "use DHT's demultiplex everywhere option" | 2053 | msgid "use DHT's demultiplex everywhere option" |
2079 | msgstr "" | 2054 | msgstr "" |
2080 | 2055 | ||
2081 | #: src/dht/gnunet-dht-get.c:301 | 2056 | #: src/dht/gnunet-dht-get.c:315 |
2082 | msgid "Issue a GET request to the GNUnet DHT, prints results." | 2057 | msgid "Issue a GET request to the GNUnet DHT, prints results." |
2083 | msgstr "" | 2058 | msgstr "" |
2084 | 2059 | ||
2060 | #: src/dht/gnunet-dht-hello.c:166 | ||
2061 | msgid "Obtain HELLO from DHT or provide HELLO to DHT for bootstrapping" | ||
2062 | msgstr "" | ||
2063 | |||
2085 | #: src/dht/gnunet-dht-monitor.c:315 | 2064 | #: src/dht/gnunet-dht-monitor.c:315 |
2086 | msgid "how long should the monitor command run" | 2065 | msgid "how long should the monitor command run" |
2087 | msgstr "" | 2066 | msgstr "" |
@@ -2121,10 +2100,6 @@ msgstr "" | |||
2121 | msgid "how many replicas to create" | 2100 | msgid "how many replicas to create" |
2122 | msgstr "" | 2101 | msgstr "" |
2123 | 2102 | ||
2124 | #: src/dht/gnunet-dht-put.c:217 | ||
2125 | msgid "use DHT's record route option" | ||
2126 | msgstr "" | ||
2127 | |||
2128 | #: src/dht/gnunet-dht-put.c:223 | 2103 | #: src/dht/gnunet-dht-put.c:223 |
2129 | msgid "the type to insert data as" | 2104 | msgid "the type to insert data as" |
2130 | msgstr "" | 2105 | msgstr "" |
@@ -2181,17 +2156,17 @@ msgstr "" | |||
2181 | msgid "Measure quality and performance of the DHT service." | 2156 | msgid "Measure quality and performance of the DHT service." |
2182 | msgstr "Không thể truy cáºp đến dịch vụ" | 2157 | msgstr "Không thể truy cáºp đến dịch vụ" |
2183 | 2158 | ||
2184 | #: src/dht/plugin_block_dht.c:328 | 2159 | #: src/dht/plugin_block_dht.c:404 |
2185 | #, fuzzy, c-format | 2160 | #, fuzzy, c-format |
2186 | msgid "Block not of type %u\n" | 2161 | msgid "Block not of type %u\n" |
2187 | msgstr "Không biết truyá»n tải nà o kiểu %d.\n" | 2162 | msgstr "Không biết truyá»n tải nà o kiểu %d.\n" |
2188 | 2163 | ||
2189 | #: src/dht/plugin_block_dht.c:337 | 2164 | #: src/dht/plugin_block_dht.c:413 |
2190 | #, c-format | 2165 | #, c-format |
2191 | msgid "Size mismatch for block with type %u\n" | 2166 | msgid "Size mismatch for block with type %u\n" |
2192 | msgstr "" | 2167 | msgstr "" |
2193 | 2168 | ||
2194 | #: src/dht/plugin_block_dht.c:348 | 2169 | #: src/dht/plugin_block_dht.c:424 |
2195 | #, c-format | 2170 | #, c-format |
2196 | msgid "Block of type %u is malformed\n" | 2171 | msgid "Block of type %u is malformed\n" |
2197 | msgstr "" | 2172 | msgstr "" |
@@ -2926,20 +2901,20 @@ msgstr "" | |||
2926 | msgid "LOC URI malformed (signature failed validation)" | 2901 | msgid "LOC URI malformed (signature failed validation)" |
2927 | msgstr "" | 2902 | msgstr "" |
2928 | 2903 | ||
2929 | #: src/fs/fs_uri.c:653 | 2904 | #: src/fs/fs_uri.c:652 |
2930 | #, fuzzy | 2905 | #, fuzzy |
2931 | msgid "invalid argument" | 2906 | msgid "invalid argument" |
2932 | msgstr "Äối số không hợp lệ cho « %s ».\n" | 2907 | msgstr "Äối số không hợp lệ cho « %s ».\n" |
2933 | 2908 | ||
2934 | #: src/fs/fs_uri.c:665 | 2909 | #: src/fs/fs_uri.c:671 |
2935 | msgid "Unrecognized URI type" | 2910 | msgid "Unrecognized URI type" |
2936 | msgstr "" | 2911 | msgstr "" |
2937 | 2912 | ||
2938 | #: src/fs/fs_uri.c:1071 src/fs/fs_uri.c:1098 | 2913 | #: src/fs/fs_uri.c:1075 src/fs/fs_uri.c:1102 |
2939 | msgid "No keywords specified!\n" | 2914 | msgid "No keywords specified!\n" |
2940 | msgstr "Chưa ghi rõ từ khoá.\n" | 2915 | msgstr "Chưa ghi rõ từ khoá.\n" |
2941 | 2916 | ||
2942 | #: src/fs/fs_uri.c:1104 | 2917 | #: src/fs/fs_uri.c:1108 |
2943 | msgid "Number of double-quotes not balanced!\n" | 2918 | msgid "Number of double-quotes not balanced!\n" |
2944 | msgstr "Có dấu nháy kép thừa hay thiếu.\n" | 2919 | msgstr "Có dấu nháy kép thừa hay thiếu.\n" |
2945 | 2920 | ||
@@ -3067,7 +3042,7 @@ msgid "Downloading `%s' done (%s/s).\n" | |||
3067 | msgstr "Tiến trình tải lên « %s » đã tiếp tục lại.\n" | 3042 | msgstr "Tiến trình tải lên « %s » đã tiếp tục lại.\n" |
3068 | 3043 | ||
3069 | #: src/fs/gnunet-download.c:206 src/fs/gnunet-publish.c:299 | 3044 | #: src/fs/gnunet-download.c:206 src/fs/gnunet-publish.c:299 |
3070 | #: src/fs/gnunet-search.c:229 src/fs/gnunet-unindex.c:117 | 3045 | #: src/fs/gnunet-search.c:538 src/fs/gnunet-unindex.c:117 |
3071 | #, fuzzy, c-format | 3046 | #, fuzzy, c-format |
3072 | msgid "Unexpected status: %d\n" | 3047 | msgid "Unexpected status: %d\n" |
3073 | msgstr "Gặp sá»± kiện bất thÆ°á»ng: %d\n" | 3048 | msgstr "Gặp sá»± kiện bất thÆ°á»ng: %d\n" |
@@ -3091,12 +3066,12 @@ msgid "Target filename must be specified.\n" | |||
3091 | msgstr "" | 3066 | msgstr "" |
3092 | 3067 | ||
3093 | #: src/fs/gnunet-download.c:271 src/fs/gnunet-publish.c:869 | 3068 | #: src/fs/gnunet-download.c:271 src/fs/gnunet-publish.c:869 |
3094 | #: src/fs/gnunet-search.c:294 src/fs/gnunet-unindex.c:154 | 3069 | #: src/fs/gnunet-unindex.c:154 |
3095 | #, fuzzy, c-format | 3070 | #, fuzzy, c-format |
3096 | msgid "Could not initialize `%s' subsystem.\n" | 3071 | msgid "Could not initialize `%s' subsystem.\n" |
3097 | msgstr "Lỗi sơ khởi dịch vụ « %s ».\n" | 3072 | msgstr "Lỗi sơ khởi dịch vụ « %s ».\n" |
3098 | 3073 | ||
3099 | #: src/fs/gnunet-download.c:318 src/fs/gnunet-search.c:334 | 3074 | #: src/fs/gnunet-download.c:318 |
3100 | #, fuzzy | 3075 | #, fuzzy |
3101 | msgid "set the desired LEVEL of receiver-anonymity" | 3076 | msgid "set the desired LEVEL of receiver-anonymity" |
3102 | msgstr "đặt CẤP mong muốn của tình trạng nặc danh của ngÆ°á»i gá»i" | 3077 | msgstr "đặt CẤP mong muốn của tình trạng nặc danh của ngÆ°á»i gá»i" |
@@ -3105,7 +3080,7 @@ msgstr "đặt CẤP mong muốn của tình trạng nặc danh của ngÆ°á»i g | |||
3105 | msgid "delete incomplete downloads (when aborted with CTRL-C)" | 3080 | msgid "delete incomplete downloads (when aborted with CTRL-C)" |
3106 | msgstr "xoá việc tải vỠkhông hoà n thà nh (khi hủy bở dùng CTRL-C)" | 3081 | msgstr "xoá việc tải vỠkhông hoà n thà nh (khi hủy bở dùng CTRL-C)" |
3107 | 3082 | ||
3108 | #: src/fs/gnunet-download.c:330 src/fs/gnunet-search.c:339 | 3083 | #: src/fs/gnunet-download.c:330 src/fs/gnunet-search.c:740 |
3109 | msgid "only search the local peer (no P2P network search)" | 3084 | msgid "only search the local peer (no P2P network search)" |
3110 | msgstr "" | 3085 | msgstr "" |
3111 | 3086 | ||
@@ -3365,41 +3340,114 @@ msgstr "" | |||
3365 | msgid "Publish a file or directory on GNUnet" | 3340 | msgid "Publish a file or directory on GNUnet" |
3366 | msgstr "" | 3341 | msgstr "" |
3367 | 3342 | ||
3368 | #: src/fs/gnunet-search.c:130 | 3343 | #: src/fs/gnunet-search.c:441 |
3369 | #, c-format | 3344 | #, c-format |
3370 | msgid "Failed to write directory with search results to `%s'\n" | 3345 | msgid "Failed to write directory with search results to `%s'\n" |
3371 | msgstr "" | 3346 | msgstr "" |
3372 | 3347 | ||
3373 | #: src/fs/gnunet-search.c:219 | 3348 | #: src/fs/gnunet-search.c:527 |
3374 | #, fuzzy, c-format | 3349 | #, fuzzy, c-format |
3375 | msgid "Error searching: %s.\n" | 3350 | msgid "Error searching: %s.\n" |
3376 | msgstr "Gặp lỗi khi tải xuống: %s\n" | 3351 | msgstr "Gặp lỗi khi tải xuống: %s\n" |
3377 | 3352 | ||
3378 | #: src/fs/gnunet-search.c:281 | 3353 | #: src/fs/gnunet-search.c:587 |
3354 | #, c-format | ||
3355 | msgid "Conflicting options --bookmark-only and --silent.\n" | ||
3356 | msgstr "" | ||
3357 | |||
3358 | #: src/fs/gnunet-search.c:594 | ||
3359 | #, c-format | ||
3360 | msgid "Conflicting options --bookmark-only and --output.\n" | ||
3361 | msgstr "" | ||
3362 | |||
3363 | #: src/fs/gnunet-search.c:600 | ||
3364 | #, c-format | ||
3365 | msgid "An output file is mandatory for silent mode.\n" | ||
3366 | msgstr "" | ||
3367 | |||
3368 | #: src/fs/gnunet-search.c:621 | ||
3379 | #, fuzzy | 3369 | #, fuzzy |
3380 | msgid "Could not create keyword URI from arguments.\n" | 3370 | msgid "Could not create keyword URI from arguments.\n" |
3381 | msgstr "Không thể tạo miá»n tên.\n" | 3371 | msgstr "Không thể tạo miá»n tên.\n" |
3382 | 3372 | ||
3383 | #: src/fs/gnunet-search.c:308 | 3373 | #: src/fs/gnunet-search.c:629 |
3374 | msgid "" | ||
3375 | "Invalid URI. Valid URIs for searching are keyword query URIs\n" | ||
3376 | "(\"gnunet://fs/ksk/...\") and namespace content URIs (\"gnunet://fs/sks/..." | ||
3377 | "\").\n" | ||
3378 | msgstr "" | ||
3379 | |||
3380 | #: src/fs/gnunet-search.c:654 | ||
3381 | #, fuzzy, c-format | ||
3382 | msgid "Could not initialize the `%s` subsystem.\n" | ||
3383 | msgstr "Lỗi sơ khởi dịch vụ « %s ».\n" | ||
3384 | |||
3385 | #: src/fs/gnunet-search.c:668 | ||
3384 | #, fuzzy | 3386 | #, fuzzy |
3385 | msgid "Could not start searching.\n" | 3387 | msgid "Could not start searching.\n" |
3386 | msgstr "Không thể tạo miá»n tên.\n" | 3388 | msgstr "Không thể tạo miá»n tên.\n" |
3387 | 3389 | ||
3388 | #: src/fs/gnunet-search.c:345 | 3390 | #: src/fs/gnunet-search.c:694 |
3389 | msgid "write search results to file starting with PREFIX" | 3391 | #, fuzzy |
3392 | msgid "set the desired LEVEL of receiver-anonymity (default: 1)" | ||
3393 | msgstr "đặt CẤP mong muốn của tình trạng nặc danh của ngÆ°á»i gá»i" | ||
3394 | |||
3395 | #: src/fs/gnunet-search.c:700 | ||
3396 | msgid "do not search, print only the URI that points to this search" | ||
3397 | msgstr "" | ||
3398 | |||
3399 | #: src/fs/gnunet-search.c:707 | ||
3400 | msgid "" | ||
3401 | "write search results for directories according to FORMAT; accepted " | ||
3402 | "placeholders are: %a, %f, %j, %l, %m, %n, %s; defaults to the value of --" | ||
3403 | "printf when omitted or to `" | ||
3390 | msgstr "" | 3404 | msgstr "" |
3391 | 3405 | ||
3392 | #: src/fs/gnunet-search.c:351 | 3406 | #: src/fs/gnunet-search.c:717 |
3393 | msgid "automatically terminate search after DELAY" | 3407 | msgid "" |
3408 | "write search results according to FORMAT; accepted placeholders are: %a, %f, " | ||
3409 | "%j, %l, %m, %n, %s; defaults to `" | ||
3394 | msgstr "" | 3410 | msgstr "" |
3395 | 3411 | ||
3396 | #: src/fs/gnunet-search.c:357 | 3412 | #: src/fs/gnunet-search.c:725 |
3413 | msgid "" | ||
3414 | "when the %a or %j placeholders appear in --printf or --dir-printf, list each " | ||
3415 | "metadata property according to FORMAT; accepted placeholders are: %i, %l, " | ||
3416 | "%n, %p" | ||
3417 | msgstr "" | ||
3418 | |||
3419 | #: src/fs/gnunet-search.c:734 | ||
3397 | msgid "automatically terminate search after VALUE results are found" | 3420 | msgid "automatically terminate search after VALUE results are found" |
3398 | msgstr "" | 3421 | msgstr "" |
3399 | 3422 | ||
3400 | #: src/fs/gnunet-search.c:371 | 3423 | #: src/fs/gnunet-search.c:746 |
3424 | msgid "" | ||
3425 | "create a GNUnet directory with search results at FILENAME (e.g. `gnunet-" | ||
3426 | "search --output=commons" | ||
3427 | msgstr "" | ||
3428 | |||
3429 | #: src/fs/gnunet-search.c:753 | ||
3430 | msgid "silent mode (requires the --output argument)" | ||
3431 | msgstr "" | ||
3432 | |||
3433 | #: src/fs/gnunet-search.c:759 | ||
3434 | msgid "" | ||
3435 | "automatically terminate search after DELAY; the value given must be a number " | ||
3436 | "followed by a space and a time unit, for example \"500 ms\"; without a unit " | ||
3437 | "it defaults to microseconds - 1000000 = 1 second; if 0 or omitted it means " | ||
3438 | "to wait for CTRL-C" | ||
3439 | msgstr "" | ||
3440 | |||
3441 | #: src/fs/gnunet-search.c:768 | ||
3442 | #, c-format | ||
3443 | msgid "" | ||
3444 | "be verbose (append \"%a\\n\" to the default --printf and --dir-printf " | ||
3445 | "arguments - ignored when these are provided by the user)" | ||
3446 | msgstr "" | ||
3447 | |||
3448 | #: src/fs/gnunet-search.c:781 | ||
3401 | #, fuzzy | 3449 | #, fuzzy |
3402 | msgid "Search GNUnet for files that were published on GNUnet" | 3450 | msgid "Search for files that have been published on GNUnet\n" |
3403 | msgstr "Không hiển thị kết quả tìm kiếm cho táºp tin được chúng ta tải lên" | 3451 | msgstr "Không hiển thị kết quả tìm kiếm cho táºp tin được chúng ta tải lên" |
3404 | 3452 | ||
3405 | #: src/fs/gnunet-service-fs.c:371 src/fs/gnunet-service-fs.c:878 | 3453 | #: src/fs/gnunet-service-fs.c:371 src/fs/gnunet-service-fs.c:878 |
@@ -3760,68 +3808,73 @@ msgstr "" | |||
3760 | msgid "Expected a base32-encoded public zone key\n" | 3808 | msgid "Expected a base32-encoded public zone key\n" |
3761 | msgstr "" | 3809 | msgstr "" |
3762 | 3810 | ||
3763 | #: src/gns/gnunet-bcd.c:571 | 3811 | #: src/gns/gnunet-bcd.c:573 |
3764 | #, fuzzy, c-format | 3812 | #, fuzzy, c-format |
3765 | msgid "Invalid port number %u\n" | 3813 | msgid "Invalid port number %u\n" |
3766 | msgstr "Äối số không hợp lệ cho « %s ».\n" | 3814 | msgstr "Äối số không hợp lệ cho « %s ».\n" |
3767 | 3815 | ||
3768 | #: src/gns/gnunet-bcd.c:612 src/namestore/gnunet-namestore-fcfsd.c:1113 | 3816 | #: src/gns/gnunet-bcd.c:614 src/namestore/gnunet-namestore-fcfsd.c:1113 |
3769 | #, fuzzy | 3817 | #, fuzzy |
3770 | msgid "Unable to set up the daemon\n" | 3818 | msgid "Unable to set up the daemon\n" |
3771 | msgstr "Không thể tạo tà i khoản ngÆ°á»i dùng cho trình ná»n." | 3819 | msgstr "Không thể tạo tà i khoản ngÆ°á»i dùng cho trình ná»n." |
3772 | 3820 | ||
3773 | #: src/gns/gnunet-bcd.c:635 src/namestore/gnunet-namestore-fcfsd.c:987 | 3821 | #: src/gns/gnunet-bcd.c:637 src/namestore/gnunet-namestore-fcfsd.c:987 |
3774 | #, fuzzy | 3822 | #, fuzzy |
3775 | msgid "Failed to start HTTP server\n" | 3823 | msgid "Failed to start HTTP server\n" |
3776 | msgstr "Lá»—i bắt đầu thu tháºp.\n" | 3824 | msgstr "Lá»—i bắt đầu thu tháºp.\n" |
3777 | 3825 | ||
3778 | #: src/gns/gnunet-bcd.c:658 | 3826 | #: src/gns/gnunet-bcd.c:660 |
3779 | msgid "Run HTTP server on port PORT (default is 8888)" | 3827 | msgid "Run HTTP server on port PORT (default is 8888)" |
3780 | msgstr "" | 3828 | msgstr "" |
3781 | 3829 | ||
3782 | #: src/gns/gnunet-bcd.c:667 | 3830 | #: src/gns/gnunet-bcd.c:669 |
3783 | msgid "GNUnet HTTP server to create business cards" | 3831 | msgid "GNUnet HTTP server to create business cards" |
3784 | msgstr "" | 3832 | msgstr "" |
3785 | 3833 | ||
3786 | #: src/gns/gnunet-dns2gns.c:241 | 3834 | #: src/gns/gnunet-dns2gns.c:298 |
3787 | #, fuzzy | 3835 | #, fuzzy |
3788 | msgid "Failed to pack DNS response into UDP packet!\n" | 3836 | msgid "Failed to pack DNS response into UDP packet!\n" |
3789 | msgstr "Lá»—i mở táºp tin ghi sá»± kiện « %s »: %s\n" | 3837 | msgstr "Lá»—i mở táºp tin ghi sá»± kiện « %s »: %s\n" |
3790 | 3838 | ||
3791 | #: src/gns/gnunet-dns2gns.c:315 | 3839 | #: src/gns/gnunet-dns2gns.c:379 |
3792 | #, fuzzy | 3840 | #, fuzzy |
3793 | msgid "Failed to parse DNS response!\n" | 3841 | msgid "Failed to parse DNS response!\n" |
3794 | msgstr "Lá»—i mở táºp tin ghi sá»± kiện « %s »: %s\n" | 3842 | msgstr "Lá»—i mở táºp tin ghi sá»± kiện « %s »: %s\n" |
3795 | 3843 | ||
3796 | #: src/gns/gnunet-dns2gns.c:452 | 3844 | #: src/gns/gnunet-dns2gns.c:453 |
3845 | #, c-format | ||
3846 | msgid "VPN returned empty result for `%s'\n" | ||
3847 | msgstr "" | ||
3848 | |||
3849 | #: src/gns/gnunet-dns2gns.c:655 | ||
3797 | #, c-format | 3850 | #, c-format |
3798 | msgid "Cannot parse DNS request from %s\n" | 3851 | msgid "Cannot parse DNS request from %s\n" |
3799 | msgstr "" | 3852 | msgstr "" |
3800 | 3853 | ||
3801 | #: src/gns/gnunet-dns2gns.c:468 | 3854 | #: src/gns/gnunet-dns2gns.c:671 |
3802 | #, fuzzy, c-format | 3855 | #, fuzzy, c-format |
3803 | msgid "Received malformed DNS request from %s\n" | 3856 | msgid "Received malformed DNS request from %s\n" |
3804 | msgstr "Nháºn yêu cầu định tuyến\n" | 3857 | msgstr "Nháºn yêu cầu định tuyến\n" |
3805 | 3858 | ||
3806 | #: src/gns/gnunet-dns2gns.c:476 | 3859 | #: src/gns/gnunet-dns2gns.c:679 |
3807 | #, fuzzy, c-format | 3860 | #, fuzzy, c-format |
3808 | msgid "Received unsupported DNS request from %s\n" | 3861 | msgid "Received unsupported DNS request from %s\n" |
3809 | msgstr "Nháºn yêu cầu định tuyến\n" | 3862 | msgstr "Nháºn yêu cầu định tuyến\n" |
3810 | 3863 | ||
3811 | #: src/gns/gnunet-dns2gns.c:637 | 3864 | #: src/gns/gnunet-dns2gns.c:840 |
3812 | #, fuzzy | 3865 | #, fuzzy |
3813 | msgid "No DNS server specified!\n" | 3866 | msgid "No DNS server specified!\n" |
3814 | msgstr "Chưa ghi rõ từ khoá.\n" | 3867 | msgstr "Chưa ghi rõ từ khoá.\n" |
3815 | 3868 | ||
3816 | #: src/gns/gnunet-dns2gns.c:786 | 3869 | #: src/gns/gnunet-dns2gns.c:995 |
3817 | msgid "IP of recursive DNS resolver to use (required)" | 3870 | msgid "IP of recursive DNS resolver to use (required)" |
3818 | msgstr "" | 3871 | msgstr "" |
3819 | 3872 | ||
3820 | #: src/gns/gnunet-dns2gns.c:792 | 3873 | #: src/gns/gnunet-dns2gns.c:1001 |
3821 | msgid "UDP port to listen on for inbound DNS requests; default: 2853" | 3874 | msgid "UDP port to listen on for inbound DNS requests; default: 2853" |
3822 | msgstr "" | 3875 | msgstr "" |
3823 | 3876 | ||
3824 | #: src/gns/gnunet-dns2gns.c:809 | 3877 | #: src/gns/gnunet-dns2gns.c:1018 |
3825 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" | 3878 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" |
3826 | msgstr "" | 3879 | msgstr "" |
3827 | 3880 | ||
@@ -4003,19 +4056,19 @@ msgstr "" | |||
4003 | msgid "GNUnet GNS resolver tool" | 4056 | msgid "GNUnet GNS resolver tool" |
4004 | msgstr "Bản ghi lỗi GNUnet" | 4057 | msgstr "Bản ghi lỗi GNUnet" |
4005 | 4058 | ||
4006 | #: src/gns/gnunet-service-gns.c:505 | 4059 | #: src/gns/gnunet-service-gns.c:501 |
4007 | #, fuzzy | 4060 | #, fuzzy |
4008 | msgid "Properly base32-encoded public key required" | 4061 | msgid "Properly base32-encoded public key required" |
4009 | msgstr "Äối số không hợp lệ cho « %s ».\n" | 4062 | msgstr "Äối số không hợp lệ cho « %s ».\n" |
4010 | 4063 | ||
4011 | #: src/gns/gnunet-service-gns.c:541 | 4064 | #: src/gns/gnunet-service-gns.c:537 |
4012 | #, fuzzy | 4065 | #, fuzzy |
4013 | msgid "Failed to connect to the namecache!\n" | 4066 | msgid "Failed to connect to the namecache!\n" |
4014 | msgstr "Không kết nối được đến trình ná»n gnunetd." | 4067 | msgstr "Không kết nối được đến trình ná»n gnunetd." |
4015 | 4068 | ||
4016 | #: src/gns/gnunet-service-gns.c:560 | 4069 | #: src/gns/gnunet-service-gns.c:556 |
4017 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:442 | 4070 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:421 |
4018 | #: src/zonemaster/gnunet-service-zonemaster.c:885 | 4071 | #: src/zonemaster/gnunet-service-zonemaster.c:870 |
4019 | #, fuzzy | 4072 | #, fuzzy |
4020 | msgid "Could not connect to DHT!\n" | 4073 | msgid "Could not connect to DHT!\n" |
4021 | msgstr "Không thể kết nối tới %s:%u: %s\n" | 4074 | msgstr "Không thể kết nối tới %s:%u: %s\n" |
@@ -4030,95 +4083,98 @@ msgstr "Gặp lỗi khi chuyển đổi các đối số sang URI.\n" | |||
4030 | msgid "Failed to connect to the DNS service!\n" | 4083 | msgid "Failed to connect to the DNS service!\n" |
4031 | msgstr "Lỗi kết nối đến gnunetd.\n" | 4084 | msgstr "Lỗi kết nối đến gnunetd.\n" |
4032 | 4085 | ||
4033 | #: src/gns/gnunet-service-gns_resolver.c:706 | 4086 | #: src/gns/gnunet-service-gns_resolver.c:659 |
4034 | #, c-format | 4087 | #, c-format |
4035 | msgid "Protocol `%s' unknown, skipping labels.\n" | 4088 | msgid "Protocol `%s' unknown, skipping labels.\n" |
4036 | msgstr "" | 4089 | msgstr "" |
4037 | 4090 | ||
4038 | #: src/gns/gnunet-service-gns_resolver.c:718 | 4091 | #: src/gns/gnunet-service-gns_resolver.c:671 |
4039 | #, c-format | 4092 | #, c-format |
4040 | msgid "Service `%s' unknown for protocol `%s', trying as number.\n" | 4093 | msgid "Service `%s' unknown for protocol `%s', trying as number.\n" |
4041 | msgstr "" | 4094 | msgstr "" |
4042 | 4095 | ||
4043 | #: src/gns/gnunet-service-gns_resolver.c:724 | 4096 | #: src/gns/gnunet-service-gns_resolver.c:677 |
4044 | #, c-format | 4097 | #, c-format |
4045 | msgid "Service `%s' not a port, skipping service labels.\n" | 4098 | msgid "Service `%s' not a port, skipping service labels.\n" |
4046 | msgstr "" | 4099 | msgstr "" |
4047 | 4100 | ||
4048 | #: src/gns/gnunet-service-gns_resolver.c:938 | 4101 | #: src/gns/gnunet-service-gns_resolver.c:891 |
4049 | #, fuzzy | 4102 | #, fuzzy |
4050 | msgid "Failed to parse DNS response\n" | 4103 | msgid "Failed to parse DNS response\n" |
4051 | msgstr "Lá»—i mở táºp tin ghi sá»± kiện « %s »: %s\n" | 4104 | msgstr "Lá»—i mở táºp tin ghi sá»± kiện « %s »: %s\n" |
4052 | 4105 | ||
4053 | #: src/gns/gnunet-service-gns_resolver.c:1129 | 4106 | #: src/gns/gnunet-service-gns_resolver.c:1082 |
4054 | #, c-format | 4107 | #, c-format |
4055 | msgid "Skipping record of unsupported type %d\n" | 4108 | msgid "Skipping record of unsupported type %d\n" |
4056 | msgstr "" | 4109 | msgstr "" |
4057 | 4110 | ||
4058 | #: src/gns/gnunet-service-gns_resolver.c:1447 | 4111 | #: src/gns/gnunet-service-gns_resolver.c:1859 |
4059 | #, c-format | ||
4060 | msgid "VPN returned empty result for `%s'\n" | ||
4061 | msgstr "" | ||
4062 | |||
4063 | #: src/gns/gnunet-service-gns_resolver.c:1919 | ||
4064 | #, c-format | 4112 | #, c-format |
4065 | msgid "Name `%s' cannot be converted to IDNA." | 4113 | msgid "Name `%s' cannot be converted to IDNA." |
4066 | msgstr "" | 4114 | msgstr "" |
4067 | 4115 | ||
4068 | #: src/gns/gnunet-service-gns_resolver.c:1934 | 4116 | #: src/gns/gnunet-service-gns_resolver.c:1874 |
4069 | #, c-format | 4117 | #, c-format |
4070 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" | 4118 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" |
4071 | msgstr "" | 4119 | msgstr "" |
4072 | 4120 | ||
4073 | #: src/gns/gnunet-service-gns_resolver.c:1979 | 4121 | #: src/gns/gnunet-service-gns_resolver.c:1914 |
4074 | #, fuzzy, c-format | 4122 | #, fuzzy, c-format |
4075 | msgid "GNS lookup failed (zero records found for `%s')\n" | 4123 | msgid "GNS lookup failed (zero records found for `%s')\n" |
4076 | msgstr "Vẫn còn không tìm thấy đồng đẳng trong « %s ».\n" | 4124 | msgstr "Vẫn còn không tìm thấy đồng đẳng trong « %s ».\n" |
4077 | 4125 | ||
4078 | #: src/gns/gnunet-service-gns_resolver.c:2406 | 4126 | #: src/gns/gnunet-service-gns_resolver.c:2312 |
4127 | msgid "Unable to process critical delegation record\n" | ||
4128 | msgstr "" | ||
4129 | |||
4130 | #: src/gns/gnunet-service-gns_resolver.c:2317 | ||
4079 | msgid "GNS lookup recursion failed (no delegation record found)\n" | 4131 | msgid "GNS lookup recursion failed (no delegation record found)\n" |
4080 | msgstr "" | 4132 | msgstr "" |
4081 | 4133 | ||
4082 | #: src/gns/gnunet-service-gns_resolver.c:2429 | 4134 | #: src/gns/gnunet-service-gns_resolver.c:2340 |
4083 | #, fuzzy, c-format | 4135 | #, fuzzy, c-format |
4084 | msgid "Failed to cache GNS resolution: %s\n" | 4136 | msgid "Failed to cache GNS resolution: %s\n" |
4085 | msgstr "Lá»—i mở táºp tin ghi sá»± kiện « %s »: %s\n" | 4137 | msgstr "Lá»—i mở táºp tin ghi sá»± kiện « %s »: %s\n" |
4086 | 4138 | ||
4087 | #: src/gns/gnunet-service-gns_resolver.c:2594 | 4139 | #: src/gns/gnunet-service-gns_resolver.c:2505 |
4088 | #, c-format | 4140 | #, c-format |
4089 | msgid "GNS namecache returned empty result for `%s'\n" | 4141 | msgid "GNS namecache returned empty result for `%s'\n" |
4090 | msgstr "" | 4142 | msgstr "" |
4091 | 4143 | ||
4092 | #: src/gns/gnunet-service-gns_resolver.c:2734 | 4144 | #: src/gns/gnunet-service-gns_resolver.c:2652 |
4093 | #, c-format | 4145 | #, c-format |
4094 | msgid "Zone %s was revoked, resolution fails\n" | 4146 | msgid "Zone %s was revoked, resolution fails\n" |
4095 | msgstr "" | 4147 | msgstr "" |
4096 | 4148 | ||
4097 | #: src/gns/plugin_gnsrecord_gns.c:174 | 4149 | #: src/gns/plugin_gnsrecord_gns.c:136 |
4150 | msgid "This is a memento of an older block for internal maintenance." | ||
4151 | msgstr "" | ||
4152 | |||
4153 | #: src/gns/plugin_gnsrecord_gns.c:175 | ||
4098 | #, fuzzy, c-format | 4154 | #, fuzzy, c-format |
4099 | msgid "Unable to parse zone key record `%s'\n" | 4155 | msgid "Unable to parse zone key record `%s'\n" |
4100 | msgstr "Lá»—i Ä‘á»c danh sách bạn bè từ « %s »\n" | 4156 | msgstr "Lá»—i Ä‘á»c danh sách bạn bè từ « %s »\n" |
4101 | 4157 | ||
4102 | #: src/gns/plugin_gnsrecord_gns.c:187 | 4158 | #: src/gns/plugin_gnsrecord_gns.c:188 |
4103 | msgid "Record type does not match parsed record type\n" | 4159 | msgid "Record type does not match parsed record type\n" |
4104 | msgstr "" | 4160 | msgstr "" |
4105 | 4161 | ||
4106 | #: src/gns/plugin_gnsrecord_gns.c:213 | 4162 | #: src/gns/plugin_gnsrecord_gns.c:211 |
4107 | #, fuzzy, c-format | 4163 | #, fuzzy, c-format |
4108 | msgid "Unable to parse GNS2DNS record `%s'\n" | 4164 | msgid "Unable to parse GNS2DNS record `%s'\n" |
4109 | msgstr "Lá»—i Ä‘á»c danh sách bạn bè từ « %s »\n" | 4165 | msgstr "Lá»—i Ä‘á»c danh sách bạn bè từ « %s »\n" |
4110 | 4166 | ||
4111 | #: src/gns/plugin_gnsrecord_gns.c:229 | 4167 | #: src/gns/plugin_gnsrecord_gns.c:227 |
4112 | #, fuzzy, c-format | 4168 | #, fuzzy, c-format |
4113 | msgid "Failed to serialize GNS2DNS record with value `%s': Not a DNS name.\n" | 4169 | msgid "Failed to serialize GNS2DNS record with value `%s': Not a DNS name.\n" |
4114 | msgstr "Không thể truy cáºp đến táºp tin gnunet-directory « %s »\n" | 4170 | msgstr "Không thể truy cáºp đến táºp tin gnunet-directory « %s »\n" |
4115 | 4171 | ||
4116 | #: src/gns/plugin_gnsrecord_gns.c:253 | 4172 | #: src/gns/plugin_gnsrecord_gns.c:251 |
4117 | #, fuzzy, c-format | 4173 | #, fuzzy, c-format |
4118 | msgid "Unable to parse VPN record string `%s'\n" | 4174 | msgid "Unable to parse VPN record string `%s'\n" |
4119 | msgstr "Lá»—i Ä‘á»c danh sách bạn bè từ « %s »\n" | 4175 | msgstr "Lá»—i Ä‘á»c danh sách bạn bè từ « %s »\n" |
4120 | 4176 | ||
4121 | #: src/gns/plugin_gnsrecord_gns.c:285 | 4177 | #: src/gns/plugin_gnsrecord_gns.c:283 |
4122 | #, fuzzy, c-format | 4178 | #, fuzzy, c-format |
4123 | msgid "Unable to parse BOX record string `%s'\n" | 4179 | msgid "Unable to parse BOX record string `%s'\n" |
4124 | msgstr "Lá»—i Ä‘á»c danh sách bạn bè từ « %s »\n" | 4180 | msgstr "Lá»—i Ä‘á»c danh sách bạn bè từ « %s »\n" |
@@ -4128,6 +4184,34 @@ msgstr "Lá»—i Ä‘á»c danh sách bạn bè từ « %s »\n" | |||
4128 | msgid "Gns REST API initialized\n" | 4184 | msgid "Gns REST API initialized\n" |
4129 | msgstr "Lỗi sơ khởi lõi.\n" | 4185 | msgstr "Lỗi sơ khởi lõi.\n" |
4130 | 4186 | ||
4187 | #: src/gnsrecord/gnsrecord_misc.c:448 | ||
4188 | msgid "Zone delegation record not allowed in apex." | ||
4189 | msgstr "" | ||
4190 | |||
4191 | #: src/gnsrecord/gnsrecord_misc.c:456 | ||
4192 | msgid "Zone delegation record set contains mutually exclusive records." | ||
4193 | msgstr "" | ||
4194 | |||
4195 | #: src/gnsrecord/gnsrecord_misc.c:466 | ||
4196 | msgid "Multiple REDIRECT records." | ||
4197 | msgstr "" | ||
4198 | |||
4199 | #: src/gnsrecord/gnsrecord_misc.c:475 src/gnsrecord/gnsrecord_misc.c:501 | ||
4200 | msgid "Redirection record set conains mutually exclusive records." | ||
4201 | msgstr "" | ||
4202 | |||
4203 | #: src/gnsrecord/gnsrecord_misc.c:482 | ||
4204 | msgid "Redirection records not allowed in apex." | ||
4205 | msgstr "" | ||
4206 | |||
4207 | #: src/gnsrecord/gnsrecord_misc.c:493 | ||
4208 | msgid "Redirection records not allowed in apex.." | ||
4209 | msgstr "" | ||
4210 | |||
4211 | #: src/gnsrecord/gnsrecord_misc.c:515 | ||
4212 | msgid "Mutually exclusive records." | ||
4213 | msgstr "" | ||
4214 | |||
4131 | #: src/gnsrecord/plugin_gnsrecord_dns.c:367 | 4215 | #: src/gnsrecord/plugin_gnsrecord_dns.c:367 |
4132 | #, fuzzy, c-format | 4216 | #, fuzzy, c-format |
4133 | msgid "Unable to parse IPv4 address `%s'\n" | 4217 | msgid "Unable to parse IPv4 address `%s'\n" |
@@ -4378,7 +4462,7 @@ msgid "# hostlist downloads initiated" | |||
4378 | msgstr "" | 4462 | msgstr "" |
4379 | 4463 | ||
4380 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1144 | 4464 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1144 |
4381 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1728 | 4465 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1732 |
4382 | msgid "# milliseconds between hostlist downloads" | 4466 | msgid "# milliseconds between hostlist downloads" |
4383 | msgstr "" | 4467 | msgstr "" |
4384 | 4468 | ||
@@ -4439,21 +4523,21 @@ msgstr "" | |||
4439 | msgid "# hostlist URIs written to file" | 4523 | msgid "# hostlist URIs written to file" |
4440 | msgstr "# các byte danh sách máy được trả vá»" | 4524 | msgstr "# các byte danh sách máy được trả vá»" |
4441 | 4525 | ||
4442 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1657 | 4526 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1661 |
4443 | #: src/transport/plugin_transport_http_client.c:2300 | 4527 | #: src/transport/plugin_transport_http_client.c:2300 |
4444 | #, c-format | 4528 | #, c-format |
4445 | msgid "Invalid proxy type: `%s', disabling proxy! Check configuration!\n" | 4529 | msgid "Invalid proxy type: `%s', disabling proxy! Check configuration!\n" |
4446 | msgstr "" | 4530 | msgstr "" |
4447 | 4531 | ||
4448 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1686 | 4532 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1690 |
4449 | msgid "Learning is enabled on this peer\n" | 4533 | msgid "Learning is enabled on this peer\n" |
4450 | msgstr "" | 4534 | msgstr "" |
4451 | 4535 | ||
4452 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1699 | 4536 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1703 |
4453 | msgid "Learning is not enabled on this peer\n" | 4537 | msgid "Learning is not enabled on this peer\n" |
4454 | msgstr "" | 4538 | msgstr "" |
4455 | 4539 | ||
4456 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1713 | 4540 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1717 |
4457 | #, c-format | 4541 | #, c-format |
4458 | msgid "" | 4542 | msgid "" |
4459 | "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" | 4543 | "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" |
@@ -4651,49 +4735,49 @@ msgstr "" | |||
4651 | msgid "Maintain egos" | 4735 | msgid "Maintain egos" |
4652 | msgstr "" | 4736 | msgstr "" |
4653 | 4737 | ||
4654 | #: src/identity/gnunet-service-identity.c:503 | 4738 | #: src/identity/gnunet-service-identity.c:502 |
4655 | msgid "no default known" | 4739 | msgid "no default known" |
4656 | msgstr "" | 4740 | msgstr "" |
4657 | 4741 | ||
4658 | #: src/identity/gnunet-service-identity.c:528 | 4742 | #: src/identity/gnunet-service-identity.c:527 |
4659 | msgid "default configured, but ego unknown (internal error)" | 4743 | msgid "default configured, but ego unknown (internal error)" |
4660 | msgstr "" | 4744 | msgstr "" |
4661 | 4745 | ||
4662 | #: src/identity/gnunet-service-identity.c:621 | 4746 | #: src/identity/gnunet-service-identity.c:620 |
4663 | #: src/identity/gnunet-service-identity.c:896 | 4747 | #: src/identity/gnunet-service-identity.c:895 |
4664 | #: src/identity/gnunet-service-identity.c:1016 | 4748 | #: src/identity/gnunet-service-identity.c:1015 |
4665 | #, fuzzy, c-format | 4749 | #, fuzzy, c-format |
4666 | msgid "Failed to write subsystem default identifier map to `%s'.\n" | 4750 | msgid "Failed to write subsystem default identifier map to `%s'.\n" |
4667 | msgstr "Lá»—i Ä‘á»c danh sách bạn bè từ « %s »\n" | 4751 | msgstr "Lá»—i Ä‘á»c danh sách bạn bè từ « %s »\n" |
4668 | 4752 | ||
4669 | #: src/identity/gnunet-service-identity.c:631 | 4753 | #: src/identity/gnunet-service-identity.c:630 |
4670 | msgid "Unknown ego specified for service (internal error)" | 4754 | msgid "Unknown ego specified for service (internal error)" |
4671 | msgstr "" | 4755 | msgstr "" |
4672 | 4756 | ||
4673 | #: src/identity/gnunet-service-identity.c:725 | 4757 | #: src/identity/gnunet-service-identity.c:724 |
4674 | msgid "identifier already in use for another ego" | 4758 | msgid "identifier already in use for another ego" |
4675 | msgstr "" | 4759 | msgstr "" |
4676 | 4760 | ||
4677 | #: src/identity/gnunet-service-identity.c:872 | 4761 | #: src/identity/gnunet-service-identity.c:871 |
4678 | msgid "target name already exists" | 4762 | msgid "target name already exists" |
4679 | msgstr "" | 4763 | msgstr "" |
4680 | 4764 | ||
4681 | #: src/identity/gnunet-service-identity.c:914 | 4765 | #: src/identity/gnunet-service-identity.c:913 |
4682 | #: src/identity/gnunet-service-identity.c:1033 | 4766 | #: src/identity/gnunet-service-identity.c:1032 |
4683 | msgid "no matching ego found" | 4767 | msgid "no matching ego found" |
4684 | msgstr "" | 4768 | msgstr "" |
4685 | 4769 | ||
4686 | #: src/identity/gnunet-service-identity.c:1131 | 4770 | #: src/identity/gnunet-service-identity.c:1130 |
4687 | #, fuzzy, c-format | 4771 | #, fuzzy, c-format |
4688 | msgid "Failed to parse ego information in `%s'\n" | 4772 | msgid "Failed to parse ego information in `%s'\n" |
4689 | msgstr "Lá»—i Ä‘á»c danh sách bạn bè từ « %s »\n" | 4773 | msgstr "Lá»—i Ä‘á»c danh sách bạn bè từ « %s »\n" |
4690 | 4774 | ||
4691 | #: src/identity/gnunet-service-identity.c:1189 | 4775 | #: src/identity/gnunet-service-identity.c:1188 |
4692 | #, fuzzy, c-format | 4776 | #, fuzzy, c-format |
4693 | msgid "Failed to parse subsystem identity configuration file `%s'\n" | 4777 | msgid "Failed to parse subsystem identity configuration file `%s'\n" |
4694 | msgstr "Không thể lÆ°u táºp tin cấu hình « %s »:" | 4778 | msgstr "Không thể lÆ°u táºp tin cấu hình « %s »:" |
4695 | 4779 | ||
4696 | #: src/identity/gnunet-service-identity.c:1198 | 4780 | #: src/identity/gnunet-service-identity.c:1197 |
4697 | #, fuzzy, c-format | 4781 | #, fuzzy, c-format |
4698 | msgid "Failed to create directory `%s' for storing egos\n" | 4782 | msgid "Failed to create directory `%s' for storing egos\n" |
4699 | msgstr "Lá»—i Ä‘á»c danh sách bạn bè từ « %s »\n" | 4783 | msgstr "Lá»—i Ä‘á»c danh sách bạn bè từ « %s »\n" |
@@ -4734,7 +4818,7 @@ msgstr "Không thể truy cáºp đến « %s »: %s\n" | |||
4734 | msgid "No records found for `%s'" | 4818 | msgid "No records found for `%s'" |
4735 | msgstr "Vẫn còn không tìm thấy đồng đẳng trong « %s ».\n" | 4819 | msgstr "Vẫn còn không tìm thấy đồng đẳng trong « %s ».\n" |
4736 | 4820 | ||
4737 | #: src/namecache/gnunet-namecache.c:119 src/namestore/gnunet-namestore.c:459 | 4821 | #: src/namecache/gnunet-namecache.c:119 src/namestore/gnunet-namestore.c:469 |
4738 | #, c-format | 4822 | #, c-format |
4739 | msgid "\tCorrupt or unsupported record of type %u\n" | 4823 | msgid "\tCorrupt or unsupported record of type %u\n" |
4740 | msgstr "" | 4824 | msgstr "" |
@@ -4754,7 +4838,7 @@ msgstr "Äối số không hợp lệ cho « %s ».\n" | |||
4754 | msgid "You must specify a name\n" | 4838 | msgid "You must specify a name\n" |
4755 | msgstr "Phải ghi rõ tên hiệu\n" | 4839 | msgstr "Phải ghi rõ tên hiệu\n" |
4756 | 4840 | ||
4757 | #: src/namecache/gnunet-namecache.c:214 src/namestore/gnunet-namestore.c:1641 | 4841 | #: src/namecache/gnunet-namecache.c:214 src/namestore/gnunet-namestore.c:1591 |
4758 | msgid "name of the record to add/delete/display" | 4842 | msgid "name of the record to add/delete/display" |
4759 | msgstr "" | 4843 | msgstr "" |
4760 | 4844 | ||
@@ -4763,7 +4847,7 @@ msgstr "" | |||
4763 | msgid "specifies the public key of the zone to look in" | 4847 | msgid "specifies the public key of the zone to look in" |
4764 | msgstr "xác định mức ưu tiên của nội dung" | 4848 | msgstr "xác định mức ưu tiên của nội dung" |
4765 | 4849 | ||
4766 | #: src/namecache/gnunet-namecache.c:233 src/namestore/gnunet-namestore.c:1702 | 4850 | #: src/namecache/gnunet-namecache.c:233 src/namestore/gnunet-namestore.c:1652 |
4767 | #, fuzzy | 4851 | #, fuzzy |
4768 | msgid "GNUnet zone manipulation tool" | 4852 | msgid "GNUnet zone manipulation tool" |
4769 | msgstr "Cấu hình GNUnet" | 4853 | msgstr "Cấu hình GNUnet" |
@@ -4912,140 +4996,113 @@ msgstr "" | |||
4912 | msgid "GNU Name System First-Come-First-Served name registration service" | 4996 | msgid "GNU Name System First-Come-First-Served name registration service" |
4913 | msgstr "" | 4997 | msgstr "" |
4914 | 4998 | ||
4915 | #: src/namestore/gnunet-namestore.c:334 | 4999 | #: src/namestore/gnunet-namestore.c:340 |
4916 | #, fuzzy, c-format | 5000 | #, fuzzy, c-format |
4917 | msgid "Adding record failed: %s\n" | 5001 | msgid "Adding record failed: %s\n" |
4918 | msgstr "Gặp lá»—i khi tải lên táºp tin: %s\n" | 5002 | msgstr "Gặp lá»—i khi tải lên táºp tin: %s\n" |
4919 | 5003 | ||
4920 | #: src/namestore/gnunet-namestore.c:362 | 5004 | #: src/namestore/gnunet-namestore.c:368 |
4921 | #, fuzzy, c-format | 5005 | #, fuzzy, c-format |
4922 | msgid "Deleting record failed, record does not exist%s%s\n" | 5006 | msgid "Deleting record failed, record does not exist%s%s\n" |
4923 | msgstr "Gặp lá»—i khi tải lên táºp tin: %s\n" | 5007 | msgstr "Gặp lá»—i khi tải lên táºp tin: %s\n" |
4924 | 5008 | ||
4925 | #: src/namestore/gnunet-namestore.c:369 | 5009 | #: src/namestore/gnunet-namestore.c:375 |
4926 | #, fuzzy, c-format | 5010 | #, fuzzy, c-format |
4927 | msgid "Deleting record failed%s%s\n" | 5011 | msgid "Deleting record failed%s%s\n" |
4928 | msgstr "Gặp lá»—i khi tải lên táºp tin: %s\n" | 5012 | msgstr "Gặp lá»—i khi tải lên táºp tin: %s\n" |
4929 | 5013 | ||
4930 | #: src/namestore/gnunet-namestore.c:656 | ||
4931 | #, c-format | ||
4932 | msgid "A %s record exists already under `%s', no other records can be added.\n" | ||
4933 | msgstr "" | ||
4934 | |||
4935 | #: src/namestore/gnunet-namestore.c:668 | 5014 | #: src/namestore/gnunet-namestore.c:668 |
4936 | #, c-format | 5015 | #, c-format |
4937 | msgid "" | 5016 | msgid "" |
4938 | "A zone key record exists already under `%s', no other records can be added.\n" | ||
4939 | msgstr "" | ||
4940 | |||
4941 | #: src/namestore/gnunet-namestore.c:680 | ||
4942 | #, c-format | ||
4943 | msgid "" | ||
4944 | "A SOA record exists already under `%s', cannot add a second SOA to the same " | 5017 | "A SOA record exists already under `%s', cannot add a second SOA to the same " |
4945 | "zone.\n" | 5018 | "zone.\n" |
4946 | msgstr "" | 5019 | msgstr "" |
4947 | 5020 | ||
4948 | #: src/namestore/gnunet-namestore.c:696 | 5021 | #: src/namestore/gnunet-namestore.c:789 |
4949 | #, c-format | ||
4950 | msgid "Records already exist under `%s', cannot add `%s' record.\n" | ||
4951 | msgstr "" | ||
4952 | |||
4953 | #: src/namestore/gnunet-namestore.c:711 | ||
4954 | #, c-format | ||
4955 | msgid "Records already exist under `%s', cannot add record.\n" | ||
4956 | msgstr "" | ||
4957 | |||
4958 | #: src/namestore/gnunet-namestore.c:726 | ||
4959 | #, c-format | ||
4960 | msgid "" | ||
4961 | "Non-GNS2DNS records already exist under `%s', cannot add GNS2DNS record.\n" | ||
4962 | msgstr "" | ||
4963 | |||
4964 | #: src/namestore/gnunet-namestore.c:846 | ||
4965 | #, c-format | 5022 | #, c-format |
4966 | msgid "There are no records under label `%s' that could be deleted.\n" | 5023 | msgid "There are no records under label `%s' that could be deleted.\n" |
4967 | msgstr "" | 5024 | msgstr "" |
4968 | 5025 | ||
4969 | #: src/namestore/gnunet-namestore.c:889 | 5026 | #: src/namestore/gnunet-namestore.c:832 |
4970 | #, c-format | 5027 | #, c-format |
4971 | msgid "" | 5028 | msgid "" |
4972 | "There are no records under label `%s' that match the request for deletion.\n" | 5029 | "There are no records under label `%s' that match the request for deletion.\n" |
4973 | msgstr "" | 5030 | msgstr "" |
4974 | 5031 | ||
4975 | #: src/namestore/gnunet-namestore.c:970 | 5032 | #: src/namestore/gnunet-namestore.c:920 |
4976 | #, fuzzy, c-format | 5033 | #, fuzzy, c-format |
4977 | msgid "Failed to replace records: %s\n" | 5034 | msgid "Failed to replace records: %s\n" |
4978 | msgstr "Lá»—i mở táºp tin ghi sá»± kiện « %s »: %s\n" | 5035 | msgstr "Lá»—i mở táºp tin ghi sá»± kiện « %s »: %s\n" |
4979 | 5036 | ||
4980 | #: src/namestore/gnunet-namestore.c:993 | 5037 | #: src/namestore/gnunet-namestore.c:943 |
4981 | #, fuzzy, c-format | 5038 | #, fuzzy, c-format |
4982 | msgid "No options given\n" | 5039 | msgid "No options given\n" |
4983 | msgstr "chưa đưa ra tên" | 5040 | msgstr "chưa đưa ra tên" |
4984 | 5041 | ||
4985 | #: src/namestore/gnunet-namestore.c:1014 src/namestore/gnunet-namestore.c:1066 | 5042 | #: src/namestore/gnunet-namestore.c:964 src/namestore/gnunet-namestore.c:1016 |
4986 | #: src/namestore/gnunet-namestore.c:1076 src/namestore/gnunet-namestore.c:1105 | 5043 | #: src/namestore/gnunet-namestore.c:1026 src/namestore/gnunet-namestore.c:1055 |
4987 | #: src/namestore/gnunet-namestore.c:1126 src/namestore/gnunet-namestore.c:1153 | 5044 | #: src/namestore/gnunet-namestore.c:1076 src/namestore/gnunet-namestore.c:1103 |
4988 | #: src/namestore/gnunet-namestore.c:1230 | 5045 | #: src/namestore/gnunet-namestore.c:1180 |
4989 | #, fuzzy, c-format | 5046 | #, fuzzy, c-format |
4990 | msgid "Missing option `%s' for operation `%s'\n" | 5047 | msgid "Missing option `%s' for operation `%s'\n" |
4991 | msgstr "Giá trị cấu hình « %s » cho « %s » trong phần « %s » nên là con số\n" | 5048 | msgstr "Giá trị cấu hình « %s » cho « %s » trong phần « %s » nên là con số\n" |
4992 | 5049 | ||
4993 | #: src/namestore/gnunet-namestore.c:1016 | 5050 | #: src/namestore/gnunet-namestore.c:966 |
4994 | msgid "replace" | 5051 | msgid "replace" |
4995 | msgstr "" | 5052 | msgstr "" |
4996 | 5053 | ||
4997 | #: src/namestore/gnunet-namestore.c:1045 | 5054 | #: src/namestore/gnunet-namestore.c:995 |
4998 | #, fuzzy, c-format | 5055 | #, fuzzy, c-format |
4999 | msgid "Invalid nick `%s'\n" | 5056 | msgid "Invalid nick `%s'\n" |
5000 | msgstr "Dữ liệu nháºp không hợp lệ.\n" | 5057 | msgstr "Dữ liệu nháºp không hợp lệ.\n" |
5001 | 5058 | ||
5002 | #: src/namestore/gnunet-namestore.c:1068 src/namestore/gnunet-namestore.c:1078 | 5059 | #: src/namestore/gnunet-namestore.c:1018 src/namestore/gnunet-namestore.c:1028 |
5003 | #: src/namestore/gnunet-namestore.c:1107 src/namestore/gnunet-namestore.c:1128 | 5060 | #: src/namestore/gnunet-namestore.c:1057 src/namestore/gnunet-namestore.c:1078 |
5004 | #: src/namestore/gnunet-namestore.c:1232 | 5061 | #: src/namestore/gnunet-namestore.c:1182 |
5005 | msgid "add" | 5062 | msgid "add" |
5006 | msgstr "" | 5063 | msgstr "" |
5007 | 5064 | ||
5008 | #: src/namestore/gnunet-namestore.c:1086 | 5065 | #: src/namestore/gnunet-namestore.c:1036 |
5009 | #, fuzzy, c-format | 5066 | #, fuzzy, c-format |
5010 | msgid "Unsupported type `%s'\n" | 5067 | msgid "Unsupported type `%s'\n" |
5011 | msgstr "Lệnh không được há»— trợ « %s ». Äang hủy bá».\n" | 5068 | msgstr "Lệnh không được há»— trợ « %s ». Äang hủy bá».\n" |
5012 | 5069 | ||
5013 | #: src/namestore/gnunet-namestore.c:1096 | 5070 | #: src/namestore/gnunet-namestore.c:1046 |
5014 | #, c-format | 5071 | #, c-format |
5015 | msgid "For DNS record types `SRV', `TLSA' and `OPENPGPKEY'" | 5072 | msgid "For DNS record types `SRV', `TLSA' and `OPENPGPKEY'" |
5016 | msgstr "" | 5073 | msgstr "" |
5017 | 5074 | ||
5018 | #: src/namestore/gnunet-namestore.c:1116 | 5075 | #: src/namestore/gnunet-namestore.c:1066 |
5019 | #, c-format | 5076 | #, c-format |
5020 | msgid "Value `%s' invalid for record type `%s'\n" | 5077 | msgid "Value `%s' invalid for record type `%s'\n" |
5021 | msgstr "" | 5078 | msgstr "" |
5022 | 5079 | ||
5023 | #: src/namestore/gnunet-namestore.c:1135 src/namestore/gnunet-namestore.c:1239 | 5080 | #: src/namestore/gnunet-namestore.c:1085 src/namestore/gnunet-namestore.c:1189 |
5024 | #, fuzzy, c-format | 5081 | #, fuzzy, c-format |
5025 | msgid "Invalid time format `%s'\n" | 5082 | msgid "Invalid time format `%s'\n" |
5026 | msgstr "Äịa chỉ IP định dạng sai: %s\n" | 5083 | msgstr "Äịa chỉ IP định dạng sai: %s\n" |
5027 | 5084 | ||
5028 | #: src/namestore/gnunet-namestore.c:1155 | 5085 | #: src/namestore/gnunet-namestore.c:1105 |
5029 | msgid "del" | 5086 | msgid "del" |
5030 | msgstr "" | 5087 | msgstr "" |
5031 | 5088 | ||
5032 | #: src/namestore/gnunet-namestore.c:1197 | 5089 | #: src/namestore/gnunet-namestore.c:1147 |
5033 | #, fuzzy, c-format | 5090 | #, fuzzy, c-format |
5034 | msgid "Invalid public key for reverse lookup `%s'\n" | 5091 | msgid "Invalid public key for reverse lookup `%s'\n" |
5035 | msgstr "Äối số không hợp lệ cho « %s ».\n" | 5092 | msgstr "Äối số không hợp lệ cho « %s ».\n" |
5036 | 5093 | ||
5037 | #: src/namestore/gnunet-namestore.c:1222 | 5094 | #: src/namestore/gnunet-namestore.c:1172 |
5038 | #: src/peerinfo-tool/gnunet-peerinfo.c:737 | 5095 | #: src/peerinfo-tool/gnunet-peerinfo.c:737 |
5039 | #, fuzzy, c-format | 5096 | #, fuzzy, c-format |
5040 | msgid "Invalid URI `%s'\n" | 5097 | msgid "Invalid URI `%s'\n" |
5041 | msgstr "Dữ liệu nháºp không hợp lệ.\n" | 5098 | msgstr "Dữ liệu nháºp không hợp lệ.\n" |
5042 | 5099 | ||
5043 | #: src/namestore/gnunet-namestore.c:1292 | 5100 | #: src/namestore/gnunet-namestore.c:1242 |
5044 | #, c-format | 5101 | #, c-format |
5045 | msgid "Label `%s' contains `.' which is not allowed\n" | 5102 | msgid "Label `%s' contains `.' which is not allowed\n" |
5046 | msgstr "" | 5103 | msgstr "" |
5047 | 5104 | ||
5048 | #: src/namestore/gnunet-namestore.c:1342 | 5105 | #: src/namestore/gnunet-namestore.c:1292 |
5049 | #, c-format | 5106 | #, c-format |
5050 | msgid "" | 5107 | msgid "" |
5051 | "No default identity configured for `namestore' subsystem\n" | 5108 | "No default identity configured for `namestore' subsystem\n" |
@@ -5053,110 +5110,115 @@ msgid "" | |||
5053 | "Run gnunet-identity -d to get a list of choices for $NAME\n" | 5110 | "Run gnunet-identity -d to get a list of choices for $NAME\n" |
5054 | msgstr "" | 5111 | msgstr "" |
5055 | 5112 | ||
5056 | #: src/namestore/gnunet-namestore.c:1407 | 5113 | #: src/namestore/gnunet-namestore.c:1357 |
5057 | #, c-format | 5114 | #, c-format |
5058 | msgid "Superfluous command line arguments (starting with `%s') ignored\n" | 5115 | msgid "Superfluous command line arguments (starting with `%s') ignored\n" |
5059 | msgstr "" | 5116 | msgstr "" |
5060 | 5117 | ||
5061 | #: src/namestore/gnunet-namestore.c:1436 | 5118 | #: src/namestore/gnunet-namestore.c:1386 |
5062 | #, fuzzy, c-format | 5119 | #, fuzzy, c-format |
5063 | msgid "Cannot connect to identity service\n" | 5120 | msgid "Cannot connect to identity service\n" |
5064 | msgstr "Không thể kết nối tới %s:%u: %s\n" | 5121 | msgstr "Không thể kết nối tới %s:%u: %s\n" |
5065 | 5122 | ||
5066 | #: src/namestore/gnunet-namestore.c:1483 | 5123 | #: src/namestore/gnunet-namestore.c:1433 |
5067 | msgid "Empty record line argument is not allowed.\n" | 5124 | msgid "Empty record line argument is not allowed.\n" |
5068 | msgstr "" | 5125 | msgstr "" |
5069 | 5126 | ||
5070 | #: src/namestore/gnunet-namestore.c:1495 | 5127 | #: src/namestore/gnunet-namestore.c:1445 |
5071 | #, c-format | 5128 | #, c-format |
5072 | msgid "Invalid expiration time `%s' (must be without unit)\n" | 5129 | msgid "Invalid expiration time `%s' (must be without unit)\n" |
5073 | msgstr "" | 5130 | msgstr "" |
5074 | 5131 | ||
5075 | #: src/namestore/gnunet-namestore.c:1507 src/namestore/gnunet-namestore.c:1523 | 5132 | #: src/namestore/gnunet-namestore.c:1457 src/namestore/gnunet-namestore.c:1473 |
5076 | #: src/namestore/gnunet-namestore.c:1540 | 5133 | #: src/namestore/gnunet-namestore.c:1490 |
5077 | #, fuzzy, c-format | 5134 | #, fuzzy, c-format |
5078 | msgid "Missing entries in record line `%s'.\n" | 5135 | msgid "Missing entries in record line `%s'.\n" |
5079 | msgstr "Không thể nạp phần bổ sung truyá»n tải « %s »\n" | 5136 | msgstr "Không thể nạp phần bổ sung truyá»n tải « %s »\n" |
5080 | 5137 | ||
5081 | #: src/namestore/gnunet-namestore.c:1515 | 5138 | #: src/namestore/gnunet-namestore.c:1465 |
5082 | #, fuzzy, c-format | 5139 | #, fuzzy, c-format |
5083 | msgid "Unknown record type `%s'\n" | 5140 | msgid "Unknown record type `%s'\n" |
5084 | msgstr "Không rõ câu lệnh « %s ».\n" | 5141 | msgstr "Không rõ câu lệnh « %s ».\n" |
5085 | 5142 | ||
5086 | #: src/namestore/gnunet-namestore.c:1553 | 5143 | #: src/namestore/gnunet-namestore.c:1503 |
5087 | #, fuzzy, c-format | 5144 | #, fuzzy, c-format |
5088 | msgid "Invalid record data for type %s: `%s'.\n" | 5145 | msgid "Invalid record data for type %s: `%s'.\n" |
5089 | msgstr "Äịa chỉ IP định dạng sai: %s\n" | 5146 | msgstr "Äịa chỉ IP định dạng sai: %s\n" |
5090 | 5147 | ||
5091 | #: src/namestore/gnunet-namestore.c:1610 | 5148 | #: src/namestore/gnunet-namestore.c:1560 |
5092 | msgid "add record" | 5149 | msgid "add record" |
5093 | msgstr "" | 5150 | msgstr "" |
5094 | 5151 | ||
5095 | #: src/namestore/gnunet-namestore.c:1613 | 5152 | #: src/namestore/gnunet-namestore.c:1563 |
5096 | msgid "delete record" | 5153 | msgid "delete record" |
5097 | msgstr "" | 5154 | msgstr "" |
5098 | 5155 | ||
5099 | #: src/namestore/gnunet-namestore.c:1617 | 5156 | #: src/namestore/gnunet-namestore.c:1567 |
5100 | msgid "display records" | 5157 | msgid "display records" |
5101 | msgstr "" | 5158 | msgstr "" |
5102 | 5159 | ||
5103 | #: src/namestore/gnunet-namestore.c:1624 | 5160 | #: src/namestore/gnunet-namestore.c:1574 |
5104 | msgid "" | 5161 | msgid "" |
5105 | "expiration time for record to use (for adding only), \"never\" is possible" | 5162 | "expiration time for record to use (for adding only), \"never\" is possible" |
5106 | msgstr "" | 5163 | msgstr "" |
5107 | 5164 | ||
5108 | #: src/namestore/gnunet-namestore.c:1630 | 5165 | #: src/namestore/gnunet-namestore.c:1580 |
5109 | #, fuzzy | 5166 | #, fuzzy |
5110 | msgid "set the desired nick name for the zone" | 5167 | msgid "set the desired nick name for the zone" |
5111 | msgstr "In ra thông tin vỠcác đồng đẳng GNUnet." | 5168 | msgstr "In ra thông tin vỠcác đồng đẳng GNUnet." |
5112 | 5169 | ||
5113 | #: src/namestore/gnunet-namestore.c:1635 | 5170 | #: src/namestore/gnunet-namestore.c:1585 |
5114 | #, fuzzy | 5171 | #, fuzzy |
5115 | msgid "monitor changes in the namestore" | 5172 | msgid "monitor changes in the namestore" |
5116 | msgstr "Không kết nối được đến trình ná»n gnunetd." | 5173 | msgstr "Không kết nối được đến trình ná»n gnunetd." |
5117 | 5174 | ||
5118 | #: src/namestore/gnunet-namestore.c:1647 | 5175 | #: src/namestore/gnunet-namestore.c:1597 |
5119 | #, fuzzy | 5176 | #, fuzzy |
5120 | msgid "determine our name for the given PKEY" | 5177 | msgid "determine our name for the given PKEY" |
5121 | msgstr "In ra thông tin vỠcác đồng đẳng GNUnet." | 5178 | msgstr "In ra thông tin vỠcác đồng đẳng GNUnet." |
5122 | 5179 | ||
5123 | #: src/namestore/gnunet-namestore.c:1654 | 5180 | #: src/namestore/gnunet-namestore.c:1604 |
5124 | msgid "" | 5181 | msgid "" |
5125 | "set record set to values given by (possibly multiple) RECORDLINES; can be " | 5182 | "set record set to values given by (possibly multiple) RECORDLINES; can be " |
5126 | "specified multiple times" | 5183 | "specified multiple times" |
5127 | msgstr "" | 5184 | msgstr "" |
5128 | 5185 | ||
5129 | #: src/namestore/gnunet-namestore.c:1660 | 5186 | #: src/namestore/gnunet-namestore.c:1610 |
5130 | msgid "type of the record to add/delete/display" | 5187 | msgid "type of the record to add/delete/display" |
5131 | msgstr "" | 5188 | msgstr "" |
5132 | 5189 | ||
5133 | #: src/namestore/gnunet-namestore.c:1665 | 5190 | #: src/namestore/gnunet-namestore.c:1615 |
5134 | msgid "URI to import into our zone" | 5191 | msgid "URI to import into our zone" |
5135 | msgstr "" | 5192 | msgstr "" |
5136 | 5193 | ||
5137 | #: src/namestore/gnunet-namestore.c:1671 | 5194 | #: src/namestore/gnunet-namestore.c:1621 |
5138 | msgid "value of the record to add/delete" | 5195 | msgid "value of the record to add/delete" |
5139 | msgstr "" | 5196 | msgstr "" |
5140 | 5197 | ||
5141 | #: src/namestore/gnunet-namestore.c:1675 | 5198 | #: src/namestore/gnunet-namestore.c:1625 |
5142 | msgid "create or list public record" | 5199 | msgid "create or list public record" |
5143 | msgstr "" | 5200 | msgstr "" |
5144 | 5201 | ||
5145 | #: src/namestore/gnunet-namestore.c:1681 | 5202 | #: src/namestore/gnunet-namestore.c:1631 |
5146 | msgid "" | 5203 | msgid "" |
5147 | "create shadow record (only valid if all other records of the same type have " | 5204 | "create shadow record (only valid if all other records of the same type have " |
5148 | "expired" | 5205 | "expired" |
5149 | msgstr "" | 5206 | msgstr "" |
5150 | 5207 | ||
5151 | #: src/namestore/gnunet-namestore.c:1687 | 5208 | #: src/namestore/gnunet-namestore.c:1637 |
5152 | msgid "name of the ego controlling the zone" | 5209 | msgid "name of the ego controlling the zone" |
5153 | msgstr "" | 5210 | msgstr "" |
5154 | 5211 | ||
5155 | #: src/namestore/gnunet-service-namestore.c:871 | 5212 | #: src/namestore/gnunet-service-namestore.c:879 |
5156 | #, fuzzy, c-format | 5213 | #, fuzzy, c-format |
5157 | msgid "Failed to replicate block in namecache: %s\n" | 5214 | msgid "Failed to replicate block in namecache: %s\n" |
5158 | msgstr "Lá»—i cáºp nháºt dữ liệu cho mô-Ä‘un « %s »\n" | 5215 | msgstr "Lá»—i cáºp nháºt dữ liệu cho mô-Ä‘un « %s »\n" |
5159 | 5216 | ||
5217 | #: src/namestore/gnunet-service-namestore.c:1668 | ||
5218 | #, fuzzy | ||
5219 | msgid "Store failed" | ||
5220 | msgstr "Kho dữ liệu đầy.\n" | ||
5221 | |||
5160 | #: src/namestore/gnunet-zoneimport.c:1847 | 5222 | #: src/namestore/gnunet-zoneimport.c:1847 |
5161 | msgid "size to use for the main hash map" | 5223 | msgid "size to use for the main hash map" |
5162 | msgstr "" | 5224 | msgstr "" |
@@ -5165,10 +5227,6 @@ msgstr "" | |||
5165 | msgid "minimum expiration time we assume for imported records" | 5227 | msgid "minimum expiration time we assume for imported records" |
5166 | msgstr "" | 5228 | msgstr "" |
5167 | 5229 | ||
5168 | #: src/namestore/namestore_api.c:373 | ||
5169 | msgid "Namestore failed to store record\n" | ||
5170 | msgstr "" | ||
5171 | |||
5172 | #: src/namestore/plugin_namestore_flat.c:195 | 5230 | #: src/namestore/plugin_namestore_flat.c:195 |
5173 | #, c-format | 5231 | #, c-format |
5174 | msgid "File too big to map: %llu bytes.\n" | 5232 | msgid "File too big to map: %llu bytes.\n" |
@@ -5769,6 +5827,51 @@ msgstr "Lỗi sơ khởi dịch vụ « %s ».\n" | |||
5769 | msgid "Daemon to run to perform IP protocol translation to GNUnet" | 5827 | msgid "Daemon to run to perform IP protocol translation to GNUnet" |
5770 | msgstr "" | 5828 | msgstr "" |
5771 | 5829 | ||
5830 | #: src/reclaim/gnunet-did.c:209 | ||
5831 | #, fuzzy, c-format | ||
5832 | msgid "Invalid DID `%s'\n" | ||
5833 | msgstr "Dữ liệu nháºp không hợp lệ.\n" | ||
5834 | |||
5835 | #: src/reclaim/gnunet-did.c:835 | ||
5836 | msgid "Create a DID Document and display its DID" | ||
5837 | msgstr "" | ||
5838 | |||
5839 | #: src/reclaim/gnunet-did.c:840 | ||
5840 | msgid "Get the DID Document associated with the given DID" | ||
5841 | msgstr "" | ||
5842 | |||
5843 | #: src/reclaim/gnunet-did.c:844 | ||
5844 | msgid "Show the DID for a given ego" | ||
5845 | msgstr "" | ||
5846 | |||
5847 | #: src/reclaim/gnunet-did.c:849 | ||
5848 | msgid "Remove the DID" | ||
5849 | msgstr "" | ||
5850 | |||
5851 | #: src/reclaim/gnunet-did.c:853 src/reclaim/gnunet-did.c:857 | ||
5852 | msgid "Replace the DID Document." | ||
5853 | msgstr "" | ||
5854 | |||
5855 | #: src/reclaim/gnunet-did.c:863 | ||
5856 | msgid "The Decentralized Identity (DID)" | ||
5857 | msgstr "" | ||
5858 | |||
5859 | #: src/reclaim/gnunet-did.c:869 | ||
5860 | msgid "The DID Document to store in GNUNET" | ||
5861 | msgstr "" | ||
5862 | |||
5863 | #: src/reclaim/gnunet-did.c:874 | ||
5864 | msgid "The name of the EGO" | ||
5865 | msgstr "" | ||
5866 | |||
5867 | #: src/reclaim/gnunet-did.c:880 | ||
5868 | msgid "The time until the DID Document is going to expire (e.g. 5d)" | ||
5869 | msgstr "" | ||
5870 | |||
5871 | #: src/reclaim/gnunet-did.c:889 | ||
5872 | msgid "Manage Decentralized Identities (DIDs)" | ||
5873 | msgstr "" | ||
5874 | |||
5772 | #: src/reclaim/gnunet-reclaim.c:802 | 5875 | #: src/reclaim/gnunet-reclaim.c:802 |
5773 | #, fuzzy, c-format | 5876 | #, fuzzy, c-format |
5774 | msgid "Ego is required\n" | 5877 | msgid "Ego is required\n" |
@@ -6665,17 +6768,17 @@ msgid "" | |||
6665 | "free topology cannot be more than %u. Given `%s = %llu'" | 6768 | "free topology cannot be more than %u. Given `%s = %llu'" |
6666 | msgstr "" | 6769 | msgstr "" |
6667 | 6770 | ||
6668 | #: src/testbed/testbed_api_topology.c:1033 src/testing/testing.c:2643 | 6771 | #: src/testbed/testbed_api_topology.c:1033 src/testing/testing.c:2657 |
6669 | #, fuzzy, c-format | 6772 | #, fuzzy, c-format |
6670 | msgid "Topology file %s not found\n" | 6773 | msgid "Topology file %s not found\n" |
6671 | msgstr "Khoá phiên chạy từ đồng đẳng « %s » không thể được thẩm tra.\n" | 6774 | msgstr "Khoá phiên chạy từ đồng đẳng « %s » không thể được thẩm tra.\n" |
6672 | 6775 | ||
6673 | #: src/testbed/testbed_api_topology.c:1041 src/testing/testing.c:2651 | 6776 | #: src/testbed/testbed_api_topology.c:1041 src/testing/testing.c:2665 |
6674 | #, fuzzy, c-format | 6777 | #, fuzzy, c-format |
6675 | msgid "Topology file %s has no data\n" | 6778 | msgid "Topology file %s has no data\n" |
6676 | msgstr "Khoá phiên chạy từ đồng đẳng « %s » không thể được thẩm tra.\n" | 6779 | msgstr "Khoá phiên chạy từ đồng đẳng « %s » không thể được thẩm tra.\n" |
6677 | 6780 | ||
6678 | #: src/testbed/testbed_api_topology.c:1049 src/testing/testing.c:2659 | 6781 | #: src/testbed/testbed_api_topology.c:1049 src/testing/testing.c:2673 |
6679 | #, fuzzy, c-format | 6782 | #, fuzzy, c-format |
6680 | msgid "Topology file %s cannot be read\n" | 6783 | msgid "Topology file %s cannot be read\n" |
6681 | msgstr "Khoá phiên chạy từ đồng đẳng « %s » không thể được thẩm tra.\n" | 6784 | msgstr "Khoá phiên chạy từ đồng đẳng « %s » không thể được thẩm tra.\n" |
@@ -6888,7 +6991,7 @@ msgstr "" | |||
6888 | 6991 | ||
6889 | #: src/transport/gnunet-communicator-tcp.c:3338 | 6992 | #: src/transport/gnunet-communicator-tcp.c:3338 |
6890 | #: src/transport/gnunet-communicator-udp.c:3856 | 6993 | #: src/transport/gnunet-communicator-udp.c:3856 |
6891 | #: src/transport/gnunet-service-tng.c:10512 | 6994 | #: src/transport/gnunet-service-tng.c:10623 |
6892 | #: src/transport/gnunet-service-transport.c:2627 | 6995 | #: src/transport/gnunet-service-transport.c:2627 |
6893 | #, fuzzy | 6996 | #, fuzzy |
6894 | msgid "Transport service is lacking key configuration settings. Exiting.\n" | 6997 | msgid "Transport service is lacking key configuration settings. Exiting.\n" |
@@ -8128,59 +8231,59 @@ msgstr "" | |||
8128 | msgid "Need a non-empty hostname for service `%s'.\n" | 8231 | msgid "Need a non-empty hostname for service `%s'.\n" |
8129 | msgstr "" | 8232 | msgstr "" |
8130 | 8233 | ||
8131 | #: src/util/common_logging.c:626 src/util/common_logging.c:665 | 8234 | #: src/util/common_logging.c:648 src/util/common_logging.c:687 |
8132 | #, c-format | 8235 | #, c-format |
8133 | msgid "ERROR: Unable to parse log definition: Syntax error at `%s'.\n" | 8236 | msgid "ERROR: Unable to parse log definition: Syntax error at `%s'.\n" |
8134 | msgstr "" | 8237 | msgstr "" |
8135 | 8238 | ||
8136 | #: src/util/common_logging.c:904 | 8239 | #: src/util/common_logging.c:926 |
8137 | #, fuzzy, c-format | 8240 | #, fuzzy, c-format |
8138 | msgid "Message `%.*s' repeated %u times in the last %s\n" | 8241 | msgid "Message `%.*s' repeated %u times in the last %s\n" |
8139 | msgstr "Thông điệp « %.*s » đã lặp lại %u lần trong %llu giây trước\n" | 8242 | msgstr "Thông điệp « %.*s » đã lặp lại %u lần trong %llu giây trước\n" |
8140 | 8243 | ||
8141 | #: src/util/common_logging.c:1108 | 8244 | #: src/util/common_logging.c:1131 |
8142 | msgid "ERROR" | 8245 | msgid "ERROR" |
8143 | msgstr "Lá»–I" | 8246 | msgstr "Lá»–I" |
8144 | 8247 | ||
8145 | #: src/util/common_logging.c:1110 | 8248 | #: src/util/common_logging.c:1133 |
8146 | msgid "WARNING" | 8249 | msgid "WARNING" |
8147 | msgstr "CẢNH BÃO" | 8250 | msgstr "CẢNH BÃO" |
8148 | 8251 | ||
8149 | #: src/util/common_logging.c:1112 | 8252 | #: src/util/common_logging.c:1135 |
8150 | msgid "MESSAGE" | 8253 | msgid "MESSAGE" |
8151 | msgstr "" | 8254 | msgstr "" |
8152 | 8255 | ||
8153 | #: src/util/common_logging.c:1114 | 8256 | #: src/util/common_logging.c:1137 |
8154 | msgid "INFO" | 8257 | msgid "INFO" |
8155 | msgstr "TIN" | 8258 | msgstr "TIN" |
8156 | 8259 | ||
8157 | #: src/util/common_logging.c:1116 | 8260 | #: src/util/common_logging.c:1139 |
8158 | msgid "DEBUG" | 8261 | msgid "DEBUG" |
8159 | msgstr "Gá» Lá»–I" | 8262 | msgstr "Gá» Lá»–I" |
8160 | 8263 | ||
8161 | #: src/util/common_logging.c:1118 | 8264 | #: src/util/common_logging.c:1141 |
8162 | msgid "NONE" | 8265 | msgid "NONE" |
8163 | msgstr "" | 8266 | msgstr "" |
8164 | 8267 | ||
8165 | #: src/util/common_logging.c:1119 | 8268 | #: src/util/common_logging.c:1142 |
8166 | msgid "INVALID" | 8269 | msgid "INVALID" |
8167 | msgstr "" | 8270 | msgstr "" |
8168 | 8271 | ||
8169 | #: src/util/common_logging.c:1400 | 8272 | #: src/util/common_logging.c:1423 |
8170 | msgid "unknown address" | 8273 | msgid "unknown address" |
8171 | msgstr "" | 8274 | msgstr "" |
8172 | 8275 | ||
8173 | #: src/util/common_logging.c:1445 | 8276 | #: src/util/common_logging.c:1468 |
8174 | msgid "invalid address" | 8277 | msgid "invalid address" |
8175 | msgstr "" | 8278 | msgstr "" |
8176 | 8279 | ||
8177 | #: src/util/common_logging.c:1464 | 8280 | #: src/util/common_logging.c:1487 |
8178 | #, fuzzy, c-format | 8281 | #, fuzzy, c-format |
8179 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" | 8282 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" |
8180 | msgstr "" | 8283 | msgstr "" |
8181 | "Cấu hình không thá»a mãn các rà ng buá»™c của táºp tin đặc tả cấu hình « %s ».\n" | 8284 | "Cấu hình không thá»a mãn các rà ng buá»™c của táºp tin đặc tả cấu hình « %s ».\n" |
8182 | 8285 | ||
8183 | #: src/util/common_logging.c:1487 | 8286 | #: src/util/common_logging.c:1510 |
8184 | #, fuzzy, c-format | 8287 | #, fuzzy, c-format |
8185 | msgid "" | 8288 | msgid "" |
8186 | "Configuration specifies invalid value for option `%s' in section `%s': %s\n" | 8289 | "Configuration specifies invalid value for option `%s' in section `%s': %s\n" |
@@ -8330,17 +8433,17 @@ msgstr "Lá»—i mở táºp tin ghi sá»± kiện « %s »: %s\n" | |||
8330 | msgid "Could not bind to any port: %s\n" | 8433 | msgid "Could not bind to any port: %s\n" |
8331 | msgstr "Không tìm thấy địa chỉ IP của máy « %s »: %s\n" | 8434 | msgstr "Không tìm thấy địa chỉ IP của máy « %s »: %s\n" |
8332 | 8435 | ||
8333 | #: src/util/dnsstub.c:344 | 8436 | #: src/util/dnsstub.c:370 |
8334 | #, c-format | 8437 | #, c-format |
8335 | msgid "Received DNS response that is too small (%u bytes)" | 8438 | msgid "Received DNS response that is too small (%u bytes)\n" |
8336 | msgstr "" | 8439 | msgstr "" |
8337 | 8440 | ||
8338 | #: src/util/dnsstub.c:482 | 8441 | #: src/util/dnsstub.c:508 |
8339 | #, fuzzy, c-format | 8442 | #, fuzzy, c-format |
8340 | msgid "Failed to send DNS request to %s: %s\n" | 8443 | msgid "Failed to send DNS request to %s: %s\n" |
8341 | msgstr "Lá»—i mở táºp tin ghi sá»± kiện « %s »: %s\n" | 8444 | msgstr "Lá»—i mở táºp tin ghi sá»± kiện « %s »: %s\n" |
8342 | 8445 | ||
8343 | #: src/util/dnsstub.c:487 | 8446 | #: src/util/dnsstub.c:513 |
8344 | #, fuzzy, c-format | 8447 | #, fuzzy, c-format |
8345 | msgid "Sent DNS request to %s\n" | 8448 | msgid "Sent DNS request to %s\n" |
8346 | msgstr "Lá»—i mở táºp tin ghi sá»± kiện « %s »: %s\n" | 8449 | msgstr "Lá»—i mở táºp tin ghi sá»± kiện « %s »: %s\n" |
@@ -8428,84 +8531,84 @@ msgstr "" | |||
8428 | "Má»i đối số bắt buá»™c phải sá» dụng vá»›i tùy chá»n dà i cÅ©ng bắt buá»™c vá»›i tùy chá»n " | 8531 | "Má»i đối số bắt buá»™c phải sá» dụng vá»›i tùy chá»n dà i cÅ©ng bắt buá»™c vá»›i tùy chá»n " |
8429 | "ngắn.\n" | 8532 | "ngắn.\n" |
8430 | 8533 | ||
8431 | #: src/util/getopt_helpers.c:196 | 8534 | #: src/util/getopt_helpers.c:197 |
8432 | msgid "print this help" | 8535 | msgid "print this help" |
8433 | msgstr "hiển thị trợ giúp nà y" | 8536 | msgstr "hiển thị trợ giúp nà y" |
8434 | 8537 | ||
8435 | #: src/util/getopt_helpers.c:261 | 8538 | #: src/util/getopt_helpers.c:262 |
8436 | msgid "be verbose" | 8539 | msgid "be verbose" |
8437 | msgstr "xuất chi tiết" | 8540 | msgstr "xuất chi tiết" |
8438 | 8541 | ||
8439 | #: src/util/getopt_helpers.c:377 | 8542 | #: src/util/getopt_helpers.c:378 |
8440 | msgid "configure logging to use LOGLEVEL" | 8543 | msgid "configure logging to use LOGLEVEL" |
8441 | msgstr "cấu hình chức năng ghi sự kiện để dùng CẤP_GHI_LƯU" | 8544 | msgstr "cấu hình chức năng ghi sự kiện để dùng CẤP_GHI_LƯU" |
8442 | 8545 | ||
8443 | #: src/util/getopt_helpers.c:444 | 8546 | #: src/util/getopt_helpers.c:445 |
8444 | #, fuzzy | 8547 | #, fuzzy |
8445 | msgid "configure logging to write logs to FILENAME" | 8548 | msgid "configure logging to write logs to FILENAME" |
8446 | msgstr "cấu hình chức năng ghi sự kiện để dùng CẤP_GHI_LƯU" | 8549 | msgstr "cấu hình chức năng ghi sự kiện để dùng CẤP_GHI_LƯU" |
8447 | 8550 | ||
8448 | #: src/util/getopt_helpers.c:461 | 8551 | #: src/util/getopt_helpers.c:462 |
8449 | #, fuzzy | 8552 | #, fuzzy |
8450 | msgid "use configuration file FILENAME" | 8553 | msgid "use configuration file FILENAME" |
8451 | msgstr "cáºp nháºt má»™t giá trị trong táºp tin cấu hình" | 8554 | msgstr "cáºp nháºt má»™t giá trị trong táºp tin cấu hình" |
8452 | 8555 | ||
8453 | #: src/util/getopt_helpers.c:497 src/util/getopt_helpers.c:811 | 8556 | #: src/util/getopt_helpers.c:498 src/util/getopt_helpers.c:812 |
8454 | #: src/util/getopt_helpers.c:867 | 8557 | #: src/util/getopt_helpers.c:868 |
8455 | #, c-format | 8558 | #, c-format |
8456 | msgid "You must pass a number to the `%s' option.\n" | 8559 | msgid "You must pass a number to the `%s' option.\n" |
8457 | msgstr "Phải gá»i má»™t con số cho tùy chá»n « %s ».\n" | 8560 | msgstr "Phải gá»i má»™t con số cho tùy chá»n « %s ».\n" |
8458 | 8561 | ||
8459 | #: src/util/getopt_helpers.c:569 | 8562 | #: src/util/getopt_helpers.c:570 |
8460 | #, fuzzy, c-format | 8563 | #, fuzzy, c-format |
8461 | msgid "" | 8564 | msgid "" |
8462 | "You must pass a relative time (optionally with sign) to the `%s' option.\n" | 8565 | "You must pass a relative time (optionally with sign) to the `%s' option.\n" |
8463 | msgstr "Phải gá»i má»™t con số cho tùy chá»n « %s ».\n" | 8566 | msgstr "Phải gá»i má»™t con số cho tùy chá»n « %s ».\n" |
8464 | 8567 | ||
8465 | #: src/util/getopt_helpers.c:576 | 8568 | #: src/util/getopt_helpers.c:577 |
8466 | #, c-format | 8569 | #, c-format |
8467 | msgid "Value given for time travel `%s' option is too big.\n" | 8570 | msgid "Value given for time travel `%s' option is too big.\n" |
8468 | msgstr "" | 8571 | msgstr "" |
8469 | 8572 | ||
8470 | #: src/util/getopt_helpers.c:594 | 8573 | #: src/util/getopt_helpers.c:595 |
8471 | msgid "[+/-]MICROSECONDS" | 8574 | msgid "[+/-]MICROSECONDS" |
8472 | msgstr "" | 8575 | msgstr "" |
8473 | 8576 | ||
8474 | #: src/util/getopt_helpers.c:596 | 8577 | #: src/util/getopt_helpers.c:597 |
8475 | msgid "modify system time by given offset (for debugging/testing only)" | 8578 | msgid "modify system time by given offset (for debugging/testing only)" |
8476 | msgstr "" | 8579 | msgstr "" |
8477 | 8580 | ||
8478 | #: src/util/getopt_helpers.c:630 | 8581 | #: src/util/getopt_helpers.c:631 |
8479 | #, fuzzy, c-format | 8582 | #, fuzzy, c-format |
8480 | msgid "You must pass relative time to the `%s' option.\n" | 8583 | msgid "You must pass relative time to the `%s' option.\n" |
8481 | msgstr "Phải gá»i má»™t con số cho tùy chá»n « %s ».\n" | 8584 | msgstr "Phải gá»i má»™t con số cho tùy chá»n « %s ».\n" |
8482 | 8585 | ||
8483 | #: src/util/getopt_helpers.c:684 | 8586 | #: src/util/getopt_helpers.c:685 |
8484 | #, fuzzy, c-format | 8587 | #, fuzzy, c-format |
8485 | msgid "You must pass absolute time to the `%s' option.\n" | 8588 | msgid "You must pass absolute time to the `%s' option.\n" |
8486 | msgstr "Phải gá»i má»™t con số cho tùy chá»n « %s ».\n" | 8589 | msgstr "Phải gá»i má»™t con số cho tùy chá»n « %s ».\n" |
8487 | 8590 | ||
8488 | #: src/util/getopt_helpers.c:741 | 8591 | #: src/util/getopt_helpers.c:742 |
8489 | #, fuzzy, c-format | 8592 | #, fuzzy, c-format |
8490 | msgid "You must pass a timestamp to the `%s' option.\n" | 8593 | msgid "You must pass a timestamp to the `%s' option.\n" |
8491 | msgstr "Phải gá»i má»™t con số cho tùy chá»n « %s ».\n" | 8594 | msgstr "Phải gá»i má»™t con số cho tùy chá»n « %s ».\n" |
8492 | 8595 | ||
8493 | #: src/util/getopt_helpers.c:748 | 8596 | #: src/util/getopt_helpers.c:749 |
8494 | #, c-format | 8597 | #, c-format |
8495 | msgid "The maximum precision allowed for timestamps is seconds.\n" | 8598 | msgid "The maximum precision allowed for timestamps is seconds.\n" |
8496 | msgstr "" | 8599 | msgstr "" |
8497 | 8600 | ||
8498 | #: src/util/getopt_helpers.c:804 | 8601 | #: src/util/getopt_helpers.c:805 |
8499 | #, c-format | 8602 | #, c-format |
8500 | msgid "Your input for the '%s' option has to be a non negative number\n" | 8603 | msgid "Your input for the '%s' option has to be a non negative number\n" |
8501 | msgstr "" | 8604 | msgstr "" |
8502 | 8605 | ||
8503 | #: src/util/getopt_helpers.c:874 | 8606 | #: src/util/getopt_helpers.c:875 |
8504 | #, fuzzy, c-format | 8607 | #, fuzzy, c-format |
8505 | msgid "You must pass a number below %u to the `%s' option.\n" | 8608 | msgid "You must pass a number below %u to the `%s' option.\n" |
8506 | msgstr "Phải gá»i má»™t con số cho tùy chá»n « %s ».\n" | 8609 | msgstr "Phải gá»i má»™t con số cho tùy chá»n « %s ».\n" |
8507 | 8610 | ||
8508 | #: src/util/getopt_helpers.c:952 | 8611 | #: src/util/getopt_helpers.c:953 |
8509 | #, c-format | 8612 | #, c-format |
8510 | msgid "Argument `%s' malformed. Expected base32 (Crockford) encoded value.\n" | 8613 | msgid "Argument `%s' malformed. Expected base32 (Crockford) encoded value.\n" |
8511 | msgstr "" | 8614 | msgstr "" |
@@ -8539,7 +8642,7 @@ msgstr "" | |||
8539 | msgid "Manipulate GNUnet configuration files" | 8642 | msgid "Manipulate GNUnet configuration files" |
8540 | msgstr "cáºp nháºt má»™t giá trị trong táºp tin cấu hình" | 8643 | msgstr "cáºp nháºt má»™t giá trị trong táºp tin cấu hình" |
8541 | 8644 | ||
8542 | #: src/util/gnunet-crypto-tvg.c:1072 | 8645 | #: src/util/gnunet-crypto-tvg.c:1483 |
8543 | msgid "verify a test vector from stdin" | 8646 | msgid "verify a test vector from stdin" |
8544 | msgstr "" | 8647 | msgstr "" |
8545 | 8648 | ||
@@ -8792,7 +8895,7 @@ msgstr "Gặp lá»—i khi tạo ngÆ°á»i dùng" | |||
8792 | msgid "Unable to shorten unix path `%s' while keeping name unique\n" | 8895 | msgid "Unable to shorten unix path `%s' while keeping name unique\n" |
8793 | msgstr "" | 8896 | msgstr "" |
8794 | 8897 | ||
8795 | #: src/util/network.c:1306 | 8898 | #: src/util/network.c:1307 |
8796 | #, c-format | 8899 | #, c-format |
8797 | msgid "" | 8900 | msgid "" |
8798 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" | 8901 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" |
@@ -8920,78 +9023,78 @@ msgstr "" | |||
8920 | msgid "Character sets requested were `%s'->`%s'\n" | 9023 | msgid "Character sets requested were `%s'->`%s'\n" |
8921 | msgstr "" | 9024 | msgstr "" |
8922 | 9025 | ||
8923 | #: src/util/strings.c:487 | 9026 | #: src/util/strings.c:514 |
8924 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" | 9027 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" |
8925 | msgstr "" | 9028 | msgstr "" |
8926 | "Lá»—i mở rá»™ng biến môi trÆ°á»ng « $HOME »: chÆ°a đặt biến môi trÆ°á»ng « HOME »" | 9029 | "Lá»—i mở rá»™ng biến môi trÆ°á»ng « $HOME »: chÆ°a đặt biến môi trÆ°á»ng « HOME »" |
8927 | 9030 | ||
8928 | #: src/util/strings.c:1023 | 9031 | #: src/util/strings.c:1050 |
8929 | msgid "IPv6 address did not start with `['\n" | 9032 | msgid "IPv6 address did not start with `['\n" |
8930 | msgstr "" | 9033 | msgstr "" |
8931 | 9034 | ||
8932 | #: src/util/strings.c:1031 | 9035 | #: src/util/strings.c:1058 |
8933 | msgid "IPv6 address did contain ':' to separate port number\n" | 9036 | msgid "IPv6 address did contain ':' to separate port number\n" |
8934 | msgstr "" | 9037 | msgstr "" |
8935 | 9038 | ||
8936 | #: src/util/strings.c:1038 | 9039 | #: src/util/strings.c:1065 |
8937 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" | 9040 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" |
8938 | msgstr "" | 9041 | msgstr "" |
8939 | 9042 | ||
8940 | #: src/util/strings.c:1046 | 9043 | #: src/util/strings.c:1073 |
8941 | msgid "IPv6 address did contain a valid port number after the last ':'\n" | 9044 | msgid "IPv6 address did contain a valid port number after the last ':'\n" |
8942 | msgstr "" | 9045 | msgstr "" |
8943 | 9046 | ||
8944 | #: src/util/strings.c:1055 | 9047 | #: src/util/strings.c:1082 |
8945 | #, fuzzy, c-format | 9048 | #, fuzzy, c-format |
8946 | msgid "Invalid IPv6 address `%s': %s\n" | 9049 | msgid "Invalid IPv6 address `%s': %s\n" |
8947 | msgstr "Mức ưu tiên tiến trình không hợp lê « %s ».\n" | 9050 | msgstr "Mức ưu tiên tiến trình không hợp lê « %s ».\n" |
8948 | 9051 | ||
8949 | #: src/util/strings.c:1237 src/util/strings.c:1248 | 9052 | #: src/util/strings.c:1264 src/util/strings.c:1275 |
8950 | msgid "Port not in range\n" | 9053 | msgid "Port not in range\n" |
8951 | msgstr "" | 9054 | msgstr "" |
8952 | 9055 | ||
8953 | #: src/util/strings.c:1257 | 9056 | #: src/util/strings.c:1284 |
8954 | #, fuzzy, c-format | 9057 | #, fuzzy, c-format |
8955 | msgid "Malformed port policy `%s'\n" | 9058 | msgid "Malformed port policy `%s'\n" |
8956 | msgstr "Lá»—i bắt đầu thu tháºp.\n" | 9059 | msgstr "Lá»—i bắt đầu thu tháºp.\n" |
8957 | 9060 | ||
8958 | #: src/util/strings.c:1328 src/util/strings.c:1357 src/util/strings.c:1404 | 9061 | #: src/util/strings.c:1355 src/util/strings.c:1384 src/util/strings.c:1431 |
8959 | #: src/util/strings.c:1424 | 9062 | #: src/util/strings.c:1451 |
8960 | #, c-format | 9063 | #, c-format |
8961 | msgid "Invalid format for IP: `%s'\n" | 9064 | msgid "Invalid format for IP: `%s'\n" |
8962 | msgstr "Äịa chỉ IP định dạng sai: %s\n" | 9065 | msgstr "Äịa chỉ IP định dạng sai: %s\n" |
8963 | 9066 | ||
8964 | #: src/util/strings.c:1382 | 9067 | #: src/util/strings.c:1409 |
8965 | #, c-format | 9068 | #, c-format |
8966 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." | 9069 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." |
8967 | msgstr "Ký hiệu mạng sai (« /%d » không hợp lệ trong CIDR IPv4)." | 9070 | msgstr "Ký hiệu mạng sai (« /%d » không hợp lệ trong CIDR IPv4)." |
8968 | 9071 | ||
8969 | #: src/util/strings.c:1433 | 9072 | #: src/util/strings.c:1460 |
8970 | #, fuzzy, c-format | 9073 | #, fuzzy, c-format |
8971 | msgid "Invalid format: `%s'\n" | 9074 | msgid "Invalid format: `%s'\n" |
8972 | msgstr "Äịa chỉ IP định dạng sai: %s\n" | 9075 | msgstr "Äịa chỉ IP định dạng sai: %s\n" |
8973 | 9076 | ||
8974 | #: src/util/strings.c:1475 | 9077 | #: src/util/strings.c:1502 |
8975 | #, c-format | 9078 | #, c-format |
8976 | msgid "Invalid network notation (does not end with ';': `%s')\n" | 9079 | msgid "Invalid network notation (does not end with ';': `%s')\n" |
8977 | msgstr "Ký hiệu mạng sai (không kết thúc với « ; »: « %s »)\n" | 9080 | msgstr "Ký hiệu mạng sai (không kết thúc với « ; »: « %s »)\n" |
8978 | 9081 | ||
8979 | #: src/util/strings.c:1525 | 9082 | #: src/util/strings.c:1552 |
8980 | #, fuzzy, c-format | 9083 | #, fuzzy, c-format |
8981 | msgid "Wrong format `%s' for netmask\n" | 9084 | msgid "Wrong format `%s' for netmask\n" |
8982 | msgstr "Mặt nạ mạng có định dạng sai « %s »: %s\n" | 9085 | msgstr "Mặt nạ mạng có định dạng sai « %s »: %s\n" |
8983 | 9086 | ||
8984 | #: src/util/strings.c:1556 | 9087 | #: src/util/strings.c:1583 |
8985 | #, fuzzy, c-format | 9088 | #, fuzzy, c-format |
8986 | msgid "Wrong format `%s' for network\n" | 9089 | msgid "Wrong format `%s' for network\n" |
8987 | msgstr "Mạng có định dạng sai « %s »: %s\n" | 9090 | msgstr "Mạng có định dạng sai « %s »: %s\n" |
8988 | 9091 | ||
8989 | #: src/util/time.c:863 src/util/time.c:891 | 9092 | #: src/util/time.c:870 src/util/time.c:898 |
8990 | #, c-format | 9093 | #, c-format |
8991 | msgid "Failed to map `%s', cannot assure monotonic time!\n" | 9094 | msgid "Failed to map `%s', cannot assure monotonic time!\n" |
8992 | msgstr "" | 9095 | msgstr "" |
8993 | 9096 | ||
8994 | #: src/util/time.c:899 | 9097 | #: src/util/time.c:906 |
8995 | #, c-format | 9098 | #, c-format |
8996 | msgid "" | 9099 | msgid "" |
8997 | "Failed to setup monotonic time file `%s', cannot assure monotonic time!\n" | 9100 | "Failed to setup monotonic time file `%s', cannot assure monotonic time!\n" |
@@ -9175,13 +9278,32 @@ msgstr "# các byte đã nháºn qua UDP" | |||
9175 | msgid "Setup tunnels via VPN." | 9278 | msgid "Setup tunnels via VPN." |
9176 | msgstr "" | 9279 | msgstr "" |
9177 | 9280 | ||
9178 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:418 | 9281 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:397 |
9179 | #: src/zonemaster/gnunet-service-zonemaster.c:847 | 9282 | #: src/zonemaster/gnunet-service-zonemaster.c:832 |
9180 | #, fuzzy | 9283 | #, fuzzy |
9181 | msgid "Failed to connect to the namestore!\n" | 9284 | msgid "Failed to connect to the namestore!\n" |
9182 | msgstr "Không kết nối được đến trình ná»n gnunetd." | 9285 | msgstr "Không kết nối được đến trình ná»n gnunetd." |
9183 | 9286 | ||
9184 | #, fuzzy | 9287 | #, fuzzy |
9288 | #~ msgid "# items stored" | ||
9289 | #~ msgstr "# các byte trong kho dữ liệu" | ||
9290 | |||
9291 | #, fuzzy, c-format | ||
9292 | #~ msgid "Failed to load datacache plugin for `%s'\n" | ||
9293 | #~ msgstr "Lá»—i cáºp nháºt dữ liệu cho mô-Ä‘un « %s »\n" | ||
9294 | |||
9295 | #, fuzzy | ||
9296 | #~ msgid "# requests received" | ||
9297 | #~ msgstr "# các yêu cầu get (lấy) dht được nháºn" | ||
9298 | |||
9299 | #~ msgid "# requests filtered by bloom filter" | ||
9300 | #~ msgstr "# các yêu cầu được lá»c theo bá»™ lá»c bloom" | ||
9301 | |||
9302 | #, fuzzy | ||
9303 | #~ msgid "# proximity search requests received" | ||
9304 | #~ msgstr "# các yêu cầu khách lá»— hổng được nháºn" | ||
9305 | |||
9306 | #, fuzzy | ||
9185 | #~ msgid "# requests for random value received" | 9307 | #~ msgid "# requests for random value received" |
9186 | #~ msgstr "# tổng số yêu cầu lá»— hổng được nháºn" | 9308 | #~ msgstr "# tổng số yêu cầu lá»— hổng được nháºn" |
9187 | 9309 | ||
diff --git a/po/zh_CN.po b/po/zh_CN.po index a7784f73d..dedd6914a 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: 2022-01-10 15:13+0100\n" | 10 | "POT-Creation-Date: 2022-03-04 22:23+0100\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" |
@@ -16,7 +16,7 @@ msgstr "" | |||
16 | "Content-Type: text/plain; charset=UTF-8\n" | 16 | "Content-Type: text/plain; charset=UTF-8\n" |
17 | "Content-Transfer-Encoding: 8bit\n" | 17 | "Content-Transfer-Encoding: 8bit\n" |
18 | 18 | ||
19 | #: src/abd/gnunet-abd.c:392 src/namestore/gnunet-namestore.c:1304 | 19 | #: src/abd/gnunet-abd.c:392 src/namestore/gnunet-namestore.c:1254 |
20 | #, c-format | 20 | #, c-format |
21 | msgid "Ego `%s' not known to identity service\n" | 21 | msgid "Ego `%s' not known to identity service\n" |
22 | msgstr "" | 22 | msgstr "" |
@@ -28,7 +28,7 @@ msgstr "“%sâ€çš„å‚æ•°æ— æ•ˆã€‚\n" | |||
28 | 28 | ||
29 | #: src/abd/gnunet-abd.c:558 src/abd/gnunet-service-abd.c:1751 | 29 | #: src/abd/gnunet-abd.c:558 src/abd/gnunet-service-abd.c:1751 |
30 | #: src/namestore/gnunet-namestore-fcfsd.c:1080 | 30 | #: src/namestore/gnunet-namestore-fcfsd.c:1080 |
31 | #: src/namestore/gnunet-namestore.c:1001 | 31 | #: src/namestore/gnunet-namestore.c:951 |
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" |
@@ -619,45 +619,45 @@ msgstr "" | |||
619 | msgid "Print information about ATS state" | 619 | msgid "Print information about ATS state" |
620 | msgstr "æ— æ³•èŽ·å–有关用户“%sâ€çš„ä¿¡æ¯ï¼š%s\n" | 620 | msgstr "æ— æ³•èŽ·å–有关用户“%sâ€çš„ä¿¡æ¯ï¼š%s\n" |
621 | 621 | ||
622 | #: src/ats/gnunet-ats-solver-eval.c:2992 src/ats/gnunet-ats-solver-eval.c:3044 | 622 | #: src/ats/gnunet-ats-solver-eval.c:2993 src/ats/gnunet-ats-solver-eval.c:3045 |
623 | #, c-format | 623 | #, c-format |
624 | msgid "" | 624 | msgid "" |
625 | "Could not load quota for network `%s': `%s', assigning default bandwidth " | 625 | "Could not load quota for network `%s': `%s', assigning default bandwidth " |
626 | "%llu\n" | 626 | "%llu\n" |
627 | msgstr "" | 627 | msgstr "" |
628 | 628 | ||
629 | #: src/ats/gnunet-ats-solver-eval.c:3011 | 629 | #: src/ats/gnunet-ats-solver-eval.c:3012 |
630 | #, c-format | 630 | #, c-format |
631 | msgid "" | 631 | msgid "" |
632 | "No outbound quota configured for network `%s', assigning default bandwidth " | 632 | "No outbound quota configured for network `%s', assigning default bandwidth " |
633 | "%llu\n" | 633 | "%llu\n" |
634 | msgstr "" | 634 | msgstr "" |
635 | 635 | ||
636 | #: src/ats/gnunet-ats-solver-eval.c:3063 | 636 | #: src/ats/gnunet-ats-solver-eval.c:3064 |
637 | #, c-format | 637 | #, c-format |
638 | msgid "" | 638 | msgid "" |
639 | "No outbound quota configure for network `%s', assigning default bandwidth " | 639 | "No outbound quota configure for network `%s', assigning default bandwidth " |
640 | "%llu\n" | 640 | "%llu\n" |
641 | msgstr "" | 641 | msgstr "" |
642 | 642 | ||
643 | #: src/ats/gnunet-ats-solver-eval.c:3552 | 643 | #: src/ats/gnunet-ats-solver-eval.c:3553 |
644 | msgid "solver to use" | 644 | msgid "solver to use" |
645 | msgstr "" | 645 | msgstr "" |
646 | 646 | ||
647 | #: src/ats/gnunet-ats-solver-eval.c:3557 | 647 | #: src/ats/gnunet-ats-solver-eval.c:3558 |
648 | msgid "experiment to use" | 648 | msgid "experiment to use" |
649 | msgstr "" | 649 | msgstr "" |
650 | 650 | ||
651 | #: src/ats/gnunet-ats-solver-eval.c:3564 | 651 | #: src/ats/gnunet-ats-solver-eval.c:3565 |
652 | #, fuzzy | 652 | #, fuzzy |
653 | msgid "print logging" | 653 | msgid "print logging" |
654 | msgstr "未知的命令“%sâ€ã€‚\n" | 654 | msgstr "未知的命令“%sâ€ã€‚\n" |
655 | 655 | ||
656 | #: src/ats/gnunet-ats-solver-eval.c:3569 | 656 | #: src/ats/gnunet-ats-solver-eval.c:3570 |
657 | msgid "save logging to disk" | 657 | msgid "save logging to disk" |
658 | msgstr "" | 658 | msgstr "" |
659 | 659 | ||
660 | #: src/ats/gnunet-ats-solver-eval.c:3574 | 660 | #: src/ats/gnunet-ats-solver-eval.c:3575 |
661 | msgid "disable normalization" | 661 | msgid "disable normalization" |
662 | msgstr "" | 662 | msgstr "" |
663 | 663 | ||
@@ -1522,38 +1522,7 @@ msgstr "" | |||
1522 | msgid "# updates to my type map" | 1522 | msgid "# updates to my type map" |
1523 | msgstr "" | 1523 | msgstr "" |
1524 | 1524 | ||
1525 | #: src/datacache/datacache.c:117 src/datacache/datacache.c:275 | 1525 | #: src/datacache/plugin_datacache_heap.c:555 |
1526 | #: src/datastore/gnunet-service-datastore.c:743 | ||
1527 | msgid "# bytes stored" | ||
1528 | msgstr "" | ||
1529 | |||
1530 | #: src/datacache/datacache.c:121 src/datacache/datacache.c:279 | ||
1531 | msgid "# items stored" | ||
1532 | msgstr "" | ||
1533 | |||
1534 | #: src/datacache/datacache.c:185 | ||
1535 | #, c-format | ||
1536 | msgid "Loading `%s' datacache plugin\n" | ||
1537 | msgstr "" | ||
1538 | |||
1539 | #: src/datacache/datacache.c:203 | ||
1540 | #, c-format | ||
1541 | msgid "Failed to load datacache plugin for `%s'\n" | ||
1542 | msgstr "" | ||
1543 | |||
1544 | #: src/datacache/datacache.c:297 | ||
1545 | msgid "# requests received" | ||
1546 | msgstr "" | ||
1547 | |||
1548 | #: src/datacache/datacache.c:308 | ||
1549 | msgid "# requests filtered by bloom filter" | ||
1550 | msgstr "" | ||
1551 | |||
1552 | #: src/datacache/datacache.c:329 | ||
1553 | msgid "# proximity search requests received" | ||
1554 | msgstr "" | ||
1555 | |||
1556 | #: src/datacache/plugin_datacache_heap.c:527 | ||
1557 | #, fuzzy | 1526 | #, fuzzy |
1558 | msgid "Heap datacache running\n" | 1527 | msgid "Heap datacache running\n" |
1559 | msgstr "sqlite æ•°æ®ä»“库" | 1528 | msgstr "sqlite æ•°æ®ä»“库" |
@@ -1576,7 +1545,7 @@ msgstr "sqlite æ•°æ®ä»“库" | |||
1576 | msgid "`%s' failed at %s:%d with error: %s\n" | 1545 | msgid "`%s' failed at %s:%d with error: %s\n" |
1577 | msgstr "“%sâ€äºŽ %s:%d 处失败,错误为:%s\n" | 1546 | msgstr "“%sâ€äºŽ %s:%d 处失败,错误为:%s\n" |
1578 | 1547 | ||
1579 | #: src/datacache/plugin_datacache_sqlite.c:693 | 1548 | #: src/datacache/plugin_datacache_sqlite.c:723 |
1580 | #: src/datastore/plugin_datastore_sqlite.c:531 | 1549 | #: src/datastore/plugin_datastore_sqlite.c:531 |
1581 | #: src/namecache/plugin_namecache_sqlite.c:237 | 1550 | #: src/namecache/plugin_namecache_sqlite.c:237 |
1582 | #: src/namestore/plugin_namestore_sqlite.c:273 | 1551 | #: src/namestore/plugin_namestore_sqlite.c:273 |
@@ -1761,6 +1730,10 @@ msgstr "" | |||
1761 | msgid "Could not find matching reservation" | 1730 | msgid "Could not find matching reservation" |
1762 | msgstr "" | 1731 | msgstr "" |
1763 | 1732 | ||
1733 | #: src/datastore/gnunet-service-datastore.c:743 | ||
1734 | msgid "# bytes stored" | ||
1735 | msgstr "" | ||
1736 | |||
1764 | #: src/datastore/gnunet-service-datastore.c:758 | 1737 | #: src/datastore/gnunet-service-datastore.c:758 |
1765 | #, c-format | 1738 | #, c-format |
1766 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" | 1739 | msgid "Need %llu bytes more space (%llu allowed, using %llu)\n" |
@@ -1945,7 +1918,7 @@ msgstr "" | |||
1945 | 1918 | ||
1946 | #: src/datastore/plugin_datastore_sqlite.c:1337 | 1919 | #: src/datastore/plugin_datastore_sqlite.c:1337 |
1947 | #: src/namecache/plugin_namecache_sqlite.c:564 | 1920 | #: src/namecache/plugin_namecache_sqlite.c:564 |
1948 | #: src/namestore/plugin_namestore_sqlite.c:765 | 1921 | #: src/namestore/plugin_namestore_sqlite.c:775 |
1949 | #, fuzzy | 1922 | #, fuzzy |
1950 | msgid "Sqlite database running\n" | 1923 | msgid "Sqlite database running\n" |
1951 | msgstr "sqlite æ•°æ®ä»“库" | 1924 | msgstr "sqlite æ•°æ®ä»“库" |
@@ -1954,56 +1927,65 @@ msgstr "sqlite æ•°æ®ä»“库" | |||
1954 | msgid "Template database running\n" | 1927 | msgid "Template database running\n" |
1955 | msgstr "" | 1928 | msgstr "" |
1956 | 1929 | ||
1957 | #: src/dht/gnunet-dht-get.c:159 | 1930 | #: src/dht/gnunet-dht-get.c:164 |
1958 | #, c-format | 1931 | #, c-format |
1959 | msgid "" | 1932 | msgid "" |
1960 | "Result %d, type %d:\n" | 1933 | "Result %d, type %d:\n" |
1961 | "%.*s\n" | 1934 | "%.*s\n" |
1962 | msgstr "" | 1935 | msgstr "" |
1963 | 1936 | ||
1964 | #: src/dht/gnunet-dht-get.c:160 | 1937 | #: src/dht/gnunet-dht-get.c:165 |
1965 | #, c-format | 1938 | #, c-format |
1966 | msgid "Result %d, type %d:\n" | 1939 | msgid "Result %d, type %d:\n" |
1967 | msgstr "" | 1940 | msgstr "" |
1968 | 1941 | ||
1969 | #: src/dht/gnunet-dht-get.c:209 | 1942 | #: src/dht/gnunet-dht-get.c:215 |
1970 | msgid "Must provide key for DHT GET!\n" | 1943 | msgid "Must provide key for DHT GET!\n" |
1971 | msgstr "" | 1944 | msgstr "" |
1972 | 1945 | ||
1973 | #: src/dht/gnunet-dht-get.c:217 src/dht/gnunet-dht-monitor.c:255 | 1946 | #: src/dht/gnunet-dht-get.c:223 src/dht/gnunet-dht-hello.c:119 |
1974 | #, fuzzy | 1947 | #: src/dht/gnunet-dht-monitor.c:255 |
1948 | #, fuzzy, c-format | ||
1975 | msgid "Failed to connect to DHT service!\n" | 1949 | msgid "Failed to connect to DHT service!\n" |
1976 | msgstr "åˆå§‹åŒ–“%sâ€æœåŠ¡å¤±è´¥ã€‚\n" | 1950 | msgstr "åˆå§‹åŒ–“%sâ€æœåŠ¡å¤±è´¥ã€‚\n" |
1977 | 1951 | ||
1978 | #: src/dht/gnunet-dht-get.c:227 | 1952 | #: src/dht/gnunet-dht-get.c:233 |
1979 | msgid "Issuing DHT GET with key" | 1953 | msgid "Issuing DHT GET with key" |
1980 | msgstr "" | 1954 | msgstr "" |
1981 | 1955 | ||
1982 | #: src/dht/gnunet-dht-get.c:260 src/dht/gnunet-dht-monitor.c:302 | 1956 | #: src/dht/gnunet-dht-get.c:269 src/dht/gnunet-dht-monitor.c:302 |
1983 | #: src/dht/gnunet-dht-put.c:200 | 1957 | #: src/dht/gnunet-dht-put.c:200 |
1984 | msgid "the query key" | 1958 | msgid "the query key" |
1985 | msgstr "" | 1959 | msgstr "" |
1986 | 1960 | ||
1987 | #: src/dht/gnunet-dht-get.c:266 | 1961 | #: src/dht/gnunet-dht-get.c:275 |
1988 | msgid "how many parallel requests (replicas) to create" | 1962 | msgid "how many parallel requests (replicas) to create" |
1989 | msgstr "" | 1963 | msgstr "" |
1990 | 1964 | ||
1991 | #: src/dht/gnunet-dht-get.c:272 src/dht/gnunet-dht-monitor.c:308 | 1965 | #: src/dht/gnunet-dht-get.c:280 src/dht/gnunet-dht-put.c:217 |
1966 | msgid "use DHT's record route option" | ||
1967 | msgstr "" | ||
1968 | |||
1969 | #: src/dht/gnunet-dht-get.c:286 src/dht/gnunet-dht-monitor.c:308 | ||
1992 | msgid "the type of data to look for" | 1970 | msgid "the type of data to look for" |
1993 | msgstr "" | 1971 | msgstr "" |
1994 | 1972 | ||
1995 | #: src/dht/gnunet-dht-get.c:278 | 1973 | #: src/dht/gnunet-dht-get.c:292 |
1996 | msgid "how long to execute this query before giving up?" | 1974 | msgid "how long to execute this query before giving up?" |
1997 | msgstr "" | 1975 | msgstr "" |
1998 | 1976 | ||
1999 | #: src/dht/gnunet-dht-get.c:284 src/dht/gnunet-dht-put.c:206 | 1977 | #: src/dht/gnunet-dht-get.c:298 src/dht/gnunet-dht-put.c:206 |
2000 | msgid "use DHT's demultiplex everywhere option" | 1978 | msgid "use DHT's demultiplex everywhere option" |
2001 | msgstr "" | 1979 | msgstr "" |
2002 | 1980 | ||
2003 | #: src/dht/gnunet-dht-get.c:301 | 1981 | #: src/dht/gnunet-dht-get.c:315 |
2004 | msgid "Issue a GET request to the GNUnet DHT, prints results." | 1982 | msgid "Issue a GET request to the GNUnet DHT, prints results." |
2005 | msgstr "" | 1983 | msgstr "" |
2006 | 1984 | ||
1985 | #: src/dht/gnunet-dht-hello.c:166 | ||
1986 | msgid "Obtain HELLO from DHT or provide HELLO to DHT for bootstrapping" | ||
1987 | msgstr "" | ||
1988 | |||
2007 | #: src/dht/gnunet-dht-monitor.c:315 | 1989 | #: src/dht/gnunet-dht-monitor.c:315 |
2008 | msgid "how long should the monitor command run" | 1990 | msgid "how long should the monitor command run" |
2009 | msgstr "" | 1991 | msgstr "" |
@@ -2043,10 +2025,6 @@ msgstr "" | |||
2043 | msgid "how many replicas to create" | 2025 | msgid "how many replicas to create" |
2044 | msgstr "" | 2026 | msgstr "" |
2045 | 2027 | ||
2046 | #: src/dht/gnunet-dht-put.c:217 | ||
2047 | msgid "use DHT's record route option" | ||
2048 | msgstr "" | ||
2049 | |||
2050 | #: src/dht/gnunet-dht-put.c:223 | 2028 | #: src/dht/gnunet-dht-put.c:223 |
2051 | msgid "the type to insert data as" | 2029 | msgid "the type to insert data as" |
2052 | msgstr "" | 2030 | msgstr "" |
@@ -2103,17 +2081,17 @@ msgstr "" | |||
2103 | msgid "Measure quality and performance of the DHT service." | 2081 | msgid "Measure quality and performance of the DHT service." |
2104 | msgstr "æ— æ³•è®¿é—®è¯¥æœåŠ¡" | 2082 | msgstr "æ— æ³•è®¿é—®è¯¥æœåŠ¡" |
2105 | 2083 | ||
2106 | #: src/dht/plugin_block_dht.c:328 | 2084 | #: src/dht/plugin_block_dht.c:404 |
2107 | #, c-format | 2085 | #, c-format |
2108 | msgid "Block not of type %u\n" | 2086 | msgid "Block not of type %u\n" |
2109 | msgstr "" | 2087 | msgstr "" |
2110 | 2088 | ||
2111 | #: src/dht/plugin_block_dht.c:337 | 2089 | #: src/dht/plugin_block_dht.c:413 |
2112 | #, c-format | 2090 | #, c-format |
2113 | msgid "Size mismatch for block with type %u\n" | 2091 | msgid "Size mismatch for block with type %u\n" |
2114 | msgstr "" | 2092 | msgstr "" |
2115 | 2093 | ||
2116 | #: src/dht/plugin_block_dht.c:348 | 2094 | #: src/dht/plugin_block_dht.c:424 |
2117 | #, c-format | 2095 | #, c-format |
2118 | msgid "Block of type %u is malformed\n" | 2096 | msgid "Block of type %u is malformed\n" |
2119 | msgstr "" | 2097 | msgstr "" |
@@ -2820,20 +2798,20 @@ msgstr "" | |||
2820 | msgid "LOC URI malformed (signature failed validation)" | 2798 | msgid "LOC URI malformed (signature failed validation)" |
2821 | msgstr "" | 2799 | msgstr "" |
2822 | 2800 | ||
2823 | #: src/fs/fs_uri.c:653 | 2801 | #: src/fs/fs_uri.c:652 |
2824 | #, fuzzy | 2802 | #, fuzzy |
2825 | msgid "invalid argument" | 2803 | msgid "invalid argument" |
2826 | msgstr "“%sâ€çš„å‚æ•°æ— æ•ˆã€‚\n" | 2804 | msgstr "“%sâ€çš„å‚æ•°æ— æ•ˆã€‚\n" |
2827 | 2805 | ||
2828 | #: src/fs/fs_uri.c:665 | 2806 | #: src/fs/fs_uri.c:671 |
2829 | msgid "Unrecognized URI type" | 2807 | msgid "Unrecognized URI type" |
2830 | msgstr "" | 2808 | msgstr "" |
2831 | 2809 | ||
2832 | #: src/fs/fs_uri.c:1071 src/fs/fs_uri.c:1098 | 2810 | #: src/fs/fs_uri.c:1075 src/fs/fs_uri.c:1102 |
2833 | msgid "No keywords specified!\n" | 2811 | msgid "No keywords specified!\n" |
2834 | msgstr "" | 2812 | msgstr "" |
2835 | 2813 | ||
2836 | #: src/fs/fs_uri.c:1104 | 2814 | #: src/fs/fs_uri.c:1108 |
2837 | msgid "Number of double-quotes not balanced!\n" | 2815 | msgid "Number of double-quotes not balanced!\n" |
2838 | msgstr "" | 2816 | msgstr "" |
2839 | 2817 | ||
@@ -2960,7 +2938,7 @@ msgid "Downloading `%s' done (%s/s).\n" | |||
2960 | msgstr "" | 2938 | msgstr "" |
2961 | 2939 | ||
2962 | #: src/fs/gnunet-download.c:206 src/fs/gnunet-publish.c:299 | 2940 | #: src/fs/gnunet-download.c:206 src/fs/gnunet-publish.c:299 |
2963 | #: src/fs/gnunet-search.c:229 src/fs/gnunet-unindex.c:117 | 2941 | #: src/fs/gnunet-search.c:538 src/fs/gnunet-unindex.c:117 |
2964 | #, c-format | 2942 | #, c-format |
2965 | msgid "Unexpected status: %d\n" | 2943 | msgid "Unexpected status: %d\n" |
2966 | msgstr "" | 2944 | msgstr "" |
@@ -2984,12 +2962,12 @@ msgid "Target filename must be specified.\n" | |||
2984 | msgstr "" | 2962 | msgstr "" |
2985 | 2963 | ||
2986 | #: src/fs/gnunet-download.c:271 src/fs/gnunet-publish.c:869 | 2964 | #: src/fs/gnunet-download.c:271 src/fs/gnunet-publish.c:869 |
2987 | #: src/fs/gnunet-search.c:294 src/fs/gnunet-unindex.c:154 | 2965 | #: src/fs/gnunet-unindex.c:154 |
2988 | #, fuzzy, c-format | 2966 | #, fuzzy, c-format |
2989 | msgid "Could not initialize `%s' subsystem.\n" | 2967 | msgid "Could not initialize `%s' subsystem.\n" |
2990 | msgstr "åˆå§‹åŒ–“%sâ€æœåŠ¡å¤±è´¥ã€‚\n" | 2968 | msgstr "åˆå§‹åŒ–“%sâ€æœåŠ¡å¤±è´¥ã€‚\n" |
2991 | 2969 | ||
2992 | #: src/fs/gnunet-download.c:318 src/fs/gnunet-search.c:334 | 2970 | #: src/fs/gnunet-download.c:318 |
2993 | msgid "set the desired LEVEL of receiver-anonymity" | 2971 | msgid "set the desired LEVEL of receiver-anonymity" |
2994 | msgstr "" | 2972 | msgstr "" |
2995 | 2973 | ||
@@ -2997,7 +2975,7 @@ msgstr "" | |||
2997 | msgid "delete incomplete downloads (when aborted with CTRL-C)" | 2975 | msgid "delete incomplete downloads (when aborted with CTRL-C)" |
2998 | msgstr "" | 2976 | msgstr "" |
2999 | 2977 | ||
3000 | #: src/fs/gnunet-download.c:330 src/fs/gnunet-search.c:339 | 2978 | #: src/fs/gnunet-download.c:330 src/fs/gnunet-search.c:740 |
3001 | msgid "only search the local peer (no P2P network search)" | 2979 | msgid "only search the local peer (no P2P network search)" |
3002 | msgstr "" | 2980 | msgstr "" |
3003 | 2981 | ||
@@ -3235,38 +3213,110 @@ msgstr "" | |||
3235 | msgid "Publish a file or directory on GNUnet" | 3213 | msgid "Publish a file or directory on GNUnet" |
3236 | msgstr "" | 3214 | msgstr "" |
3237 | 3215 | ||
3238 | #: src/fs/gnunet-search.c:130 | 3216 | #: src/fs/gnunet-search.c:441 |
3239 | #, c-format | 3217 | #, c-format |
3240 | msgid "Failed to write directory with search results to `%s'\n" | 3218 | msgid "Failed to write directory with search results to `%s'\n" |
3241 | msgstr "" | 3219 | msgstr "" |
3242 | 3220 | ||
3243 | #: src/fs/gnunet-search.c:219 | 3221 | #: src/fs/gnunet-search.c:527 |
3244 | #, fuzzy, c-format | 3222 | #, fuzzy, c-format |
3245 | msgid "Error searching: %s.\n" | 3223 | msgid "Error searching: %s.\n" |
3246 | msgstr "创建用户出错" | 3224 | msgstr "创建用户出错" |
3247 | 3225 | ||
3248 | #: src/fs/gnunet-search.c:281 | 3226 | #: src/fs/gnunet-search.c:587 |
3227 | #, c-format | ||
3228 | msgid "Conflicting options --bookmark-only and --silent.\n" | ||
3229 | msgstr "" | ||
3230 | |||
3231 | #: src/fs/gnunet-search.c:594 | ||
3232 | #, c-format | ||
3233 | msgid "Conflicting options --bookmark-only and --output.\n" | ||
3234 | msgstr "" | ||
3235 | |||
3236 | #: src/fs/gnunet-search.c:600 | ||
3237 | #, c-format | ||
3238 | msgid "An output file is mandatory for silent mode.\n" | ||
3239 | msgstr "" | ||
3240 | |||
3241 | #: src/fs/gnunet-search.c:621 | ||
3249 | msgid "Could not create keyword URI from arguments.\n" | 3242 | msgid "Could not create keyword URI from arguments.\n" |
3250 | msgstr "" | 3243 | msgstr "" |
3251 | 3244 | ||
3252 | #: src/fs/gnunet-search.c:308 | 3245 | #: src/fs/gnunet-search.c:629 |
3246 | msgid "" | ||
3247 | "Invalid URI. Valid URIs for searching are keyword query URIs\n" | ||
3248 | "(\"gnunet://fs/ksk/...\") and namespace content URIs (\"gnunet://fs/sks/..." | ||
3249 | "\").\n" | ||
3250 | msgstr "" | ||
3251 | |||
3252 | #: src/fs/gnunet-search.c:654 | ||
3253 | #, fuzzy, c-format | ||
3254 | msgid "Could not initialize the `%s` subsystem.\n" | ||
3255 | msgstr "åˆå§‹åŒ–“%sâ€æœåŠ¡å¤±è´¥ã€‚\n" | ||
3256 | |||
3257 | #: src/fs/gnunet-search.c:668 | ||
3253 | msgid "Could not start searching.\n" | 3258 | msgid "Could not start searching.\n" |
3254 | msgstr "" | 3259 | msgstr "" |
3255 | 3260 | ||
3256 | #: src/fs/gnunet-search.c:345 | 3261 | #: src/fs/gnunet-search.c:694 |
3257 | msgid "write search results to file starting with PREFIX" | 3262 | msgid "set the desired LEVEL of receiver-anonymity (default: 1)" |
3263 | msgstr "" | ||
3264 | |||
3265 | #: src/fs/gnunet-search.c:700 | ||
3266 | msgid "do not search, print only the URI that points to this search" | ||
3267 | msgstr "" | ||
3268 | |||
3269 | #: src/fs/gnunet-search.c:707 | ||
3270 | msgid "" | ||
3271 | "write search results for directories according to FORMAT; accepted " | ||
3272 | "placeholders are: %a, %f, %j, %l, %m, %n, %s; defaults to the value of --" | ||
3273 | "printf when omitted or to `" | ||
3274 | msgstr "" | ||
3275 | |||
3276 | #: src/fs/gnunet-search.c:717 | ||
3277 | msgid "" | ||
3278 | "write search results according to FORMAT; accepted placeholders are: %a, %f, " | ||
3279 | "%j, %l, %m, %n, %s; defaults to `" | ||
3258 | msgstr "" | 3280 | msgstr "" |
3259 | 3281 | ||
3260 | #: src/fs/gnunet-search.c:351 | 3282 | #: src/fs/gnunet-search.c:725 |
3261 | msgid "automatically terminate search after DELAY" | 3283 | msgid "" |
3284 | "when the %a or %j placeholders appear in --printf or --dir-printf, list each " | ||
3285 | "metadata property according to FORMAT; accepted placeholders are: %i, %l, " | ||
3286 | "%n, %p" | ||
3262 | msgstr "" | 3287 | msgstr "" |
3263 | 3288 | ||
3264 | #: src/fs/gnunet-search.c:357 | 3289 | #: src/fs/gnunet-search.c:734 |
3265 | msgid "automatically terminate search after VALUE results are found" | 3290 | msgid "automatically terminate search after VALUE results are found" |
3266 | msgstr "" | 3291 | msgstr "" |
3267 | 3292 | ||
3268 | #: src/fs/gnunet-search.c:371 | 3293 | #: src/fs/gnunet-search.c:746 |
3269 | msgid "Search GNUnet for files that were published on GNUnet" | 3294 | msgid "" |
3295 | "create a GNUnet directory with search results at FILENAME (e.g. `gnunet-" | ||
3296 | "search --output=commons" | ||
3297 | msgstr "" | ||
3298 | |||
3299 | #: src/fs/gnunet-search.c:753 | ||
3300 | msgid "silent mode (requires the --output argument)" | ||
3301 | msgstr "" | ||
3302 | |||
3303 | #: src/fs/gnunet-search.c:759 | ||
3304 | msgid "" | ||
3305 | "automatically terminate search after DELAY; the value given must be a number " | ||
3306 | "followed by a space and a time unit, for example \"500 ms\"; without a unit " | ||
3307 | "it defaults to microseconds - 1000000 = 1 second; if 0 or omitted it means " | ||
3308 | "to wait for CTRL-C" | ||
3309 | msgstr "" | ||
3310 | |||
3311 | #: src/fs/gnunet-search.c:768 | ||
3312 | #, c-format | ||
3313 | msgid "" | ||
3314 | "be verbose (append \"%a\\n\" to the default --printf and --dir-printf " | ||
3315 | "arguments - ignored when these are provided by the user)" | ||
3316 | msgstr "" | ||
3317 | |||
3318 | #: src/fs/gnunet-search.c:781 | ||
3319 | msgid "Search for files that have been published on GNUnet\n" | ||
3270 | msgstr "" | 3320 | msgstr "" |
3271 | 3321 | ||
3272 | #: src/fs/gnunet-service-fs.c:371 src/fs/gnunet-service-fs.c:878 | 3322 | #: src/fs/gnunet-service-fs.c:371 src/fs/gnunet-service-fs.c:878 |
@@ -3596,67 +3646,72 @@ msgstr "" | |||
3596 | msgid "Expected a base32-encoded public zone key\n" | 3646 | msgid "Expected a base32-encoded public zone key\n" |
3597 | msgstr "" | 3647 | msgstr "" |
3598 | 3648 | ||
3599 | #: src/gns/gnunet-bcd.c:571 | 3649 | #: src/gns/gnunet-bcd.c:573 |
3600 | #, fuzzy, c-format | 3650 | #, fuzzy, c-format |
3601 | msgid "Invalid port number %u\n" | 3651 | msgid "Invalid port number %u\n" |
3602 | msgstr "“%sâ€çš„å‚æ•°æ— æ•ˆã€‚\n" | 3652 | msgstr "“%sâ€çš„å‚æ•°æ— æ•ˆã€‚\n" |
3603 | 3653 | ||
3604 | #: src/gns/gnunet-bcd.c:612 src/namestore/gnunet-namestore-fcfsd.c:1113 | 3654 | #: src/gns/gnunet-bcd.c:614 src/namestore/gnunet-namestore-fcfsd.c:1113 |
3605 | #, fuzzy | 3655 | #, fuzzy |
3606 | msgid "Unable to set up the daemon\n" | 3656 | msgid "Unable to set up the daemon\n" |
3607 | msgstr "å‘é€æ¶ˆæ¯å¤±è´¥ã€‚\n" | 3657 | msgstr "å‘é€æ¶ˆæ¯å¤±è´¥ã€‚\n" |
3608 | 3658 | ||
3609 | #: src/gns/gnunet-bcd.c:635 src/namestore/gnunet-namestore-fcfsd.c:987 | 3659 | #: src/gns/gnunet-bcd.c:637 src/namestore/gnunet-namestore-fcfsd.c:987 |
3610 | #, fuzzy | 3660 | #, fuzzy |
3611 | msgid "Failed to start HTTP server\n" | 3661 | msgid "Failed to start HTTP server\n" |
3612 | msgstr "åˆå§‹åŒ–“%sâ€æœåŠ¡å¤±è´¥ã€‚\n" | 3662 | msgstr "åˆå§‹åŒ–“%sâ€æœåŠ¡å¤±è´¥ã€‚\n" |
3613 | 3663 | ||
3614 | #: src/gns/gnunet-bcd.c:658 | 3664 | #: src/gns/gnunet-bcd.c:660 |
3615 | msgid "Run HTTP server on port PORT (default is 8888)" | 3665 | msgid "Run HTTP server on port PORT (default is 8888)" |
3616 | msgstr "" | 3666 | msgstr "" |
3617 | 3667 | ||
3618 | #: src/gns/gnunet-bcd.c:667 | 3668 | #: src/gns/gnunet-bcd.c:669 |
3619 | msgid "GNUnet HTTP server to create business cards" | 3669 | msgid "GNUnet HTTP server to create business cards" |
3620 | msgstr "" | 3670 | msgstr "" |
3621 | 3671 | ||
3622 | #: src/gns/gnunet-dns2gns.c:241 | 3672 | #: src/gns/gnunet-dns2gns.c:298 |
3623 | #, fuzzy | 3673 | #, fuzzy |
3624 | msgid "Failed to pack DNS response into UDP packet!\n" | 3674 | msgid "Failed to pack DNS response into UDP packet!\n" |
3625 | msgstr "打开日志文件“%sâ€å¤±è´¥ï¼š%s\n" | 3675 | msgstr "打开日志文件“%sâ€å¤±è´¥ï¼š%s\n" |
3626 | 3676 | ||
3627 | #: src/gns/gnunet-dns2gns.c:315 | 3677 | #: src/gns/gnunet-dns2gns.c:379 |
3628 | #, fuzzy | 3678 | #, fuzzy |
3629 | msgid "Failed to parse DNS response!\n" | 3679 | msgid "Failed to parse DNS response!\n" |
3630 | msgstr "打开日志文件“%sâ€å¤±è´¥ï¼š%s\n" | 3680 | msgstr "打开日志文件“%sâ€å¤±è´¥ï¼š%s\n" |
3631 | 3681 | ||
3632 | #: src/gns/gnunet-dns2gns.c:452 | 3682 | #: src/gns/gnunet-dns2gns.c:453 |
3683 | #, c-format | ||
3684 | msgid "VPN returned empty result for `%s'\n" | ||
3685 | msgstr "" | ||
3686 | |||
3687 | #: src/gns/gnunet-dns2gns.c:655 | ||
3633 | #, c-format | 3688 | #, c-format |
3634 | msgid "Cannot parse DNS request from %s\n" | 3689 | msgid "Cannot parse DNS request from %s\n" |
3635 | msgstr "" | 3690 | msgstr "" |
3636 | 3691 | ||
3637 | #: src/gns/gnunet-dns2gns.c:468 | 3692 | #: src/gns/gnunet-dns2gns.c:671 |
3638 | #, c-format | 3693 | #, c-format |
3639 | msgid "Received malformed DNS request from %s\n" | 3694 | msgid "Received malformed DNS request from %s\n" |
3640 | msgstr "" | 3695 | msgstr "" |
3641 | 3696 | ||
3642 | #: src/gns/gnunet-dns2gns.c:476 | 3697 | #: src/gns/gnunet-dns2gns.c:679 |
3643 | #, c-format | 3698 | #, c-format |
3644 | msgid "Received unsupported DNS request from %s\n" | 3699 | msgid "Received unsupported DNS request from %s\n" |
3645 | msgstr "" | 3700 | msgstr "" |
3646 | 3701 | ||
3647 | #: src/gns/gnunet-dns2gns.c:637 | 3702 | #: src/gns/gnunet-dns2gns.c:840 |
3648 | msgid "No DNS server specified!\n" | 3703 | msgid "No DNS server specified!\n" |
3649 | msgstr "" | 3704 | msgstr "" |
3650 | 3705 | ||
3651 | #: src/gns/gnunet-dns2gns.c:786 | 3706 | #: src/gns/gnunet-dns2gns.c:995 |
3652 | msgid "IP of recursive DNS resolver to use (required)" | 3707 | msgid "IP of recursive DNS resolver to use (required)" |
3653 | msgstr "" | 3708 | msgstr "" |
3654 | 3709 | ||
3655 | #: src/gns/gnunet-dns2gns.c:792 | 3710 | #: src/gns/gnunet-dns2gns.c:1001 |
3656 | msgid "UDP port to listen on for inbound DNS requests; default: 2853" | 3711 | msgid "UDP port to listen on for inbound DNS requests; default: 2853" |
3657 | msgstr "" | 3712 | msgstr "" |
3658 | 3713 | ||
3659 | #: src/gns/gnunet-dns2gns.c:809 | 3714 | #: src/gns/gnunet-dns2gns.c:1018 |
3660 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" | 3715 | msgid "GNUnet DNS-to-GNS proxy (a DNS server)" |
3661 | msgstr "" | 3716 | msgstr "" |
3662 | 3717 | ||
@@ -3836,19 +3891,19 @@ msgstr "" | |||
3836 | msgid "GNUnet GNS resolver tool" | 3891 | msgid "GNUnet GNS resolver tool" |
3837 | msgstr "GNUnet 错误日志" | 3892 | msgstr "GNUnet 错误日志" |
3838 | 3893 | ||
3839 | #: src/gns/gnunet-service-gns.c:505 | 3894 | #: src/gns/gnunet-service-gns.c:501 |
3840 | #, fuzzy | 3895 | #, fuzzy |
3841 | msgid "Properly base32-encoded public key required" | 3896 | msgid "Properly base32-encoded public key required" |
3842 | msgstr "“%sâ€çš„å‚æ•°æ— æ•ˆã€‚\n" | 3897 | msgstr "“%sâ€çš„å‚æ•°æ— æ•ˆã€‚\n" |
3843 | 3898 | ||
3844 | #: src/gns/gnunet-service-gns.c:541 | 3899 | #: src/gns/gnunet-service-gns.c:537 |
3845 | #, fuzzy | 3900 | #, fuzzy |
3846 | msgid "Failed to connect to the namecache!\n" | 3901 | msgid "Failed to connect to the namecache!\n" |
3847 | msgstr "åˆå§‹åŒ–“%sâ€æœåŠ¡å¤±è´¥ã€‚\n" | 3902 | msgstr "åˆå§‹åŒ–“%sâ€æœåŠ¡å¤±è´¥ã€‚\n" |
3848 | 3903 | ||
3849 | #: src/gns/gnunet-service-gns.c:560 | 3904 | #: src/gns/gnunet-service-gns.c:556 |
3850 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:442 | 3905 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:421 |
3851 | #: src/zonemaster/gnunet-service-zonemaster.c:885 | 3906 | #: src/zonemaster/gnunet-service-zonemaster.c:870 |
3852 | #, fuzzy | 3907 | #, fuzzy |
3853 | msgid "Could not connect to DHT!\n" | 3908 | msgid "Could not connect to DHT!\n" |
3854 | msgstr "æ— æ³•è¿žæŽ¥åˆ° %s:%u:%s\n" | 3909 | msgstr "æ— æ³•è¿žæŽ¥åˆ° %s:%u:%s\n" |
@@ -3862,95 +3917,98 @@ msgstr "" | |||
3862 | msgid "Failed to connect to the DNS service!\n" | 3917 | msgid "Failed to connect to the DNS service!\n" |
3863 | msgstr "åˆå§‹åŒ–“%sâ€æœåŠ¡å¤±è´¥ã€‚\n" | 3918 | msgstr "åˆå§‹åŒ–“%sâ€æœåŠ¡å¤±è´¥ã€‚\n" |
3864 | 3919 | ||
3865 | #: src/gns/gnunet-service-gns_resolver.c:706 | 3920 | #: src/gns/gnunet-service-gns_resolver.c:659 |
3866 | #, c-format | 3921 | #, c-format |
3867 | msgid "Protocol `%s' unknown, skipping labels.\n" | 3922 | msgid "Protocol `%s' unknown, skipping labels.\n" |
3868 | msgstr "" | 3923 | msgstr "" |
3869 | 3924 | ||
3870 | #: src/gns/gnunet-service-gns_resolver.c:718 | 3925 | #: src/gns/gnunet-service-gns_resolver.c:671 |
3871 | #, c-format | 3926 | #, c-format |
3872 | msgid "Service `%s' unknown for protocol `%s', trying as number.\n" | 3927 | msgid "Service `%s' unknown for protocol `%s', trying as number.\n" |
3873 | msgstr "" | 3928 | msgstr "" |
3874 | 3929 | ||
3875 | #: src/gns/gnunet-service-gns_resolver.c:724 | 3930 | #: src/gns/gnunet-service-gns_resolver.c:677 |
3876 | #, c-format | 3931 | #, c-format |
3877 | msgid "Service `%s' not a port, skipping service labels.\n" | 3932 | msgid "Service `%s' not a port, skipping service labels.\n" |
3878 | msgstr "" | 3933 | msgstr "" |
3879 | 3934 | ||
3880 | #: src/gns/gnunet-service-gns_resolver.c:938 | 3935 | #: src/gns/gnunet-service-gns_resolver.c:891 |
3881 | #, fuzzy | 3936 | #, fuzzy |
3882 | msgid "Failed to parse DNS response\n" | 3937 | msgid "Failed to parse DNS response\n" |
3883 | msgstr "打开日志文件“%sâ€å¤±è´¥ï¼š%s\n" | 3938 | msgstr "打开日志文件“%sâ€å¤±è´¥ï¼š%s\n" |
3884 | 3939 | ||
3885 | #: src/gns/gnunet-service-gns_resolver.c:1129 | 3940 | #: src/gns/gnunet-service-gns_resolver.c:1082 |
3886 | #, c-format | 3941 | #, c-format |
3887 | msgid "Skipping record of unsupported type %d\n" | 3942 | msgid "Skipping record of unsupported type %d\n" |
3888 | msgstr "" | 3943 | msgstr "" |
3889 | 3944 | ||
3890 | #: src/gns/gnunet-service-gns_resolver.c:1447 | 3945 | #: src/gns/gnunet-service-gns_resolver.c:1859 |
3891 | #, c-format | ||
3892 | msgid "VPN returned empty result for `%s'\n" | ||
3893 | msgstr "" | ||
3894 | |||
3895 | #: src/gns/gnunet-service-gns_resolver.c:1919 | ||
3896 | #, c-format | 3946 | #, c-format |
3897 | msgid "Name `%s' cannot be converted to IDNA." | 3947 | msgid "Name `%s' cannot be converted to IDNA." |
3898 | msgstr "" | 3948 | msgstr "" |
3899 | 3949 | ||
3900 | #: src/gns/gnunet-service-gns_resolver.c:1934 | 3950 | #: src/gns/gnunet-service-gns_resolver.c:1874 |
3901 | #, c-format | 3951 | #, c-format |
3902 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" | 3952 | msgid "GNS lookup resulted in DNS name that is too long (`%s')\n" |
3903 | msgstr "" | 3953 | msgstr "" |
3904 | 3954 | ||
3905 | #: src/gns/gnunet-service-gns_resolver.c:1979 | 3955 | #: src/gns/gnunet-service-gns_resolver.c:1914 |
3906 | #, fuzzy, c-format | 3956 | #, fuzzy, c-format |
3907 | msgid "GNS lookup failed (zero records found for `%s')\n" | 3957 | msgid "GNS lookup failed (zero records found for `%s')\n" |
3908 | msgstr "è¿è¡Œ %s失败:%s %d\n" | 3958 | msgstr "è¿è¡Œ %s失败:%s %d\n" |
3909 | 3959 | ||
3910 | #: src/gns/gnunet-service-gns_resolver.c:2406 | 3960 | #: src/gns/gnunet-service-gns_resolver.c:2312 |
3961 | msgid "Unable to process critical delegation record\n" | ||
3962 | msgstr "" | ||
3963 | |||
3964 | #: src/gns/gnunet-service-gns_resolver.c:2317 | ||
3911 | msgid "GNS lookup recursion failed (no delegation record found)\n" | 3965 | msgid "GNS lookup recursion failed (no delegation record found)\n" |
3912 | msgstr "" | 3966 | msgstr "" |
3913 | 3967 | ||
3914 | #: src/gns/gnunet-service-gns_resolver.c:2429 | 3968 | #: src/gns/gnunet-service-gns_resolver.c:2340 |
3915 | #, fuzzy, c-format | 3969 | #, fuzzy, c-format |
3916 | msgid "Failed to cache GNS resolution: %s\n" | 3970 | msgid "Failed to cache GNS resolution: %s\n" |
3917 | msgstr "打开日志文件“%sâ€å¤±è´¥ï¼š%s\n" | 3971 | msgstr "打开日志文件“%sâ€å¤±è´¥ï¼š%s\n" |
3918 | 3972 | ||
3919 | #: src/gns/gnunet-service-gns_resolver.c:2594 | 3973 | #: src/gns/gnunet-service-gns_resolver.c:2505 |
3920 | #, c-format | 3974 | #, c-format |
3921 | msgid "GNS namecache returned empty result for `%s'\n" | 3975 | msgid "GNS namecache returned empty result for `%s'\n" |
3922 | msgstr "" | 3976 | msgstr "" |
3923 | 3977 | ||
3924 | #: src/gns/gnunet-service-gns_resolver.c:2734 | 3978 | #: src/gns/gnunet-service-gns_resolver.c:2652 |
3925 | #, c-format | 3979 | #, c-format |
3926 | msgid "Zone %s was revoked, resolution fails\n" | 3980 | msgid "Zone %s was revoked, resolution fails\n" |
3927 | msgstr "" | 3981 | msgstr "" |
3928 | 3982 | ||
3929 | #: src/gns/plugin_gnsrecord_gns.c:174 | 3983 | #: src/gns/plugin_gnsrecord_gns.c:136 |
3984 | msgid "This is a memento of an older block for internal maintenance." | ||
3985 | msgstr "" | ||
3986 | |||
3987 | #: src/gns/plugin_gnsrecord_gns.c:175 | ||
3930 | #, fuzzy, c-format | 3988 | #, fuzzy, c-format |
3931 | msgid "Unable to parse zone key record `%s'\n" | 3989 | msgid "Unable to parse zone key record `%s'\n" |
3932 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" | 3990 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" |
3933 | 3991 | ||
3934 | #: src/gns/plugin_gnsrecord_gns.c:187 | 3992 | #: src/gns/plugin_gnsrecord_gns.c:188 |
3935 | msgid "Record type does not match parsed record type\n" | 3993 | msgid "Record type does not match parsed record type\n" |
3936 | msgstr "" | 3994 | msgstr "" |
3937 | 3995 | ||
3938 | #: src/gns/plugin_gnsrecord_gns.c:213 | 3996 | #: src/gns/plugin_gnsrecord_gns.c:211 |
3939 | #, fuzzy, c-format | 3997 | #, fuzzy, c-format |
3940 | msgid "Unable to parse GNS2DNS record `%s'\n" | 3998 | msgid "Unable to parse GNS2DNS record `%s'\n" |
3941 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" | 3999 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" |
3942 | 4000 | ||
3943 | #: src/gns/plugin_gnsrecord_gns.c:229 | 4001 | #: src/gns/plugin_gnsrecord_gns.c:227 |
3944 | #, fuzzy, c-format | 4002 | #, fuzzy, c-format |
3945 | msgid "Failed to serialize GNS2DNS record with value `%s': Not a DNS name.\n" | 4003 | msgid "Failed to serialize GNS2DNS record with value `%s': Not a DNS name.\n" |
3946 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" | 4004 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" |
3947 | 4005 | ||
3948 | #: src/gns/plugin_gnsrecord_gns.c:253 | 4006 | #: src/gns/plugin_gnsrecord_gns.c:251 |
3949 | #, fuzzy, c-format | 4007 | #, fuzzy, c-format |
3950 | msgid "Unable to parse VPN record string `%s'\n" | 4008 | msgid "Unable to parse VPN record string `%s'\n" |
3951 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" | 4009 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" |
3952 | 4010 | ||
3953 | #: src/gns/plugin_gnsrecord_gns.c:285 | 4011 | #: src/gns/plugin_gnsrecord_gns.c:283 |
3954 | #, fuzzy, c-format | 4012 | #, fuzzy, c-format |
3955 | msgid "Unable to parse BOX record string `%s'\n" | 4013 | msgid "Unable to parse BOX record string `%s'\n" |
3956 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" | 4014 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" |
@@ -3959,6 +4017,34 @@ msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" | |||
3959 | msgid "Gns REST API initialized\n" | 4017 | msgid "Gns REST API initialized\n" |
3960 | msgstr "" | 4018 | msgstr "" |
3961 | 4019 | ||
4020 | #: src/gnsrecord/gnsrecord_misc.c:448 | ||
4021 | msgid "Zone delegation record not allowed in apex." | ||
4022 | msgstr "" | ||
4023 | |||
4024 | #: src/gnsrecord/gnsrecord_misc.c:456 | ||
4025 | msgid "Zone delegation record set contains mutually exclusive records." | ||
4026 | msgstr "" | ||
4027 | |||
4028 | #: src/gnsrecord/gnsrecord_misc.c:466 | ||
4029 | msgid "Multiple REDIRECT records." | ||
4030 | msgstr "" | ||
4031 | |||
4032 | #: src/gnsrecord/gnsrecord_misc.c:475 src/gnsrecord/gnsrecord_misc.c:501 | ||
4033 | msgid "Redirection record set conains mutually exclusive records." | ||
4034 | msgstr "" | ||
4035 | |||
4036 | #: src/gnsrecord/gnsrecord_misc.c:482 | ||
4037 | msgid "Redirection records not allowed in apex." | ||
4038 | msgstr "" | ||
4039 | |||
4040 | #: src/gnsrecord/gnsrecord_misc.c:493 | ||
4041 | msgid "Redirection records not allowed in apex.." | ||
4042 | msgstr "" | ||
4043 | |||
4044 | #: src/gnsrecord/gnsrecord_misc.c:515 | ||
4045 | msgid "Mutually exclusive records." | ||
4046 | msgstr "" | ||
4047 | |||
3962 | #: src/gnsrecord/plugin_gnsrecord_dns.c:367 | 4048 | #: src/gnsrecord/plugin_gnsrecord_dns.c:367 |
3963 | #, fuzzy, c-format | 4049 | #, fuzzy, c-format |
3964 | msgid "Unable to parse IPv4 address `%s'\n" | 4050 | msgid "Unable to parse IPv4 address `%s'\n" |
@@ -4202,7 +4288,7 @@ msgid "# hostlist downloads initiated" | |||
4202 | msgstr "" | 4288 | msgstr "" |
4203 | 4289 | ||
4204 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1144 | 4290 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1144 |
4205 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1728 | 4291 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1732 |
4206 | msgid "# milliseconds between hostlist downloads" | 4292 | msgid "# milliseconds between hostlist downloads" |
4207 | msgstr "" | 4293 | msgstr "" |
4208 | 4294 | ||
@@ -4260,21 +4346,21 @@ msgstr "" | |||
4260 | msgid "# hostlist URIs written to file" | 4346 | msgid "# hostlist URIs written to file" |
4261 | msgstr "" | 4347 | msgstr "" |
4262 | 4348 | ||
4263 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1657 | 4349 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1661 |
4264 | #: src/transport/plugin_transport_http_client.c:2300 | 4350 | #: src/transport/plugin_transport_http_client.c:2300 |
4265 | #, c-format | 4351 | #, c-format |
4266 | msgid "Invalid proxy type: `%s', disabling proxy! Check configuration!\n" | 4352 | msgid "Invalid proxy type: `%s', disabling proxy! Check configuration!\n" |
4267 | msgstr "" | 4353 | msgstr "" |
4268 | 4354 | ||
4269 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1686 | 4355 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1690 |
4270 | msgid "Learning is enabled on this peer\n" | 4356 | msgid "Learning is enabled on this peer\n" |
4271 | msgstr "" | 4357 | msgstr "" |
4272 | 4358 | ||
4273 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1699 | 4359 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1703 |
4274 | msgid "Learning is not enabled on this peer\n" | 4360 | msgid "Learning is not enabled on this peer\n" |
4275 | msgstr "" | 4361 | msgstr "" |
4276 | 4362 | ||
4277 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1713 | 4363 | #: src/hostlist/gnunet-daemon-hostlist_client.c:1717 |
4278 | #, c-format | 4364 | #, c-format |
4279 | msgid "" | 4365 | msgid "" |
4280 | "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" | 4366 | "Since learning is not enabled on this peer, hostlist file `%s' was removed\n" |
@@ -4464,49 +4550,49 @@ msgstr "" | |||
4464 | msgid "Maintain egos" | 4550 | msgid "Maintain egos" |
4465 | msgstr "" | 4551 | msgstr "" |
4466 | 4552 | ||
4467 | #: src/identity/gnunet-service-identity.c:503 | 4553 | #: src/identity/gnunet-service-identity.c:502 |
4468 | msgid "no default known" | 4554 | msgid "no default known" |
4469 | msgstr "" | 4555 | msgstr "" |
4470 | 4556 | ||
4471 | #: src/identity/gnunet-service-identity.c:528 | 4557 | #: src/identity/gnunet-service-identity.c:527 |
4472 | msgid "default configured, but ego unknown (internal error)" | 4558 | msgid "default configured, but ego unknown (internal error)" |
4473 | msgstr "" | 4559 | msgstr "" |
4474 | 4560 | ||
4475 | #: src/identity/gnunet-service-identity.c:621 | 4561 | #: src/identity/gnunet-service-identity.c:620 |
4476 | #: src/identity/gnunet-service-identity.c:896 | 4562 | #: src/identity/gnunet-service-identity.c:895 |
4477 | #: src/identity/gnunet-service-identity.c:1016 | 4563 | #: src/identity/gnunet-service-identity.c:1015 |
4478 | #, fuzzy, c-format | 4564 | #, fuzzy, c-format |
4479 | msgid "Failed to write subsystem default identifier map to `%s'.\n" | 4565 | msgid "Failed to write subsystem default identifier map to `%s'.\n" |
4480 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" | 4566 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" |
4481 | 4567 | ||
4482 | #: src/identity/gnunet-service-identity.c:631 | 4568 | #: src/identity/gnunet-service-identity.c:630 |
4483 | msgid "Unknown ego specified for service (internal error)" | 4569 | msgid "Unknown ego specified for service (internal error)" |
4484 | msgstr "" | 4570 | msgstr "" |
4485 | 4571 | ||
4486 | #: src/identity/gnunet-service-identity.c:725 | 4572 | #: src/identity/gnunet-service-identity.c:724 |
4487 | msgid "identifier already in use for another ego" | 4573 | msgid "identifier already in use for another ego" |
4488 | msgstr "" | 4574 | msgstr "" |
4489 | 4575 | ||
4490 | #: src/identity/gnunet-service-identity.c:872 | 4576 | #: src/identity/gnunet-service-identity.c:871 |
4491 | msgid "target name already exists" | 4577 | msgid "target name already exists" |
4492 | msgstr "" | 4578 | msgstr "" |
4493 | 4579 | ||
4494 | #: src/identity/gnunet-service-identity.c:914 | 4580 | #: src/identity/gnunet-service-identity.c:913 |
4495 | #: src/identity/gnunet-service-identity.c:1033 | 4581 | #: src/identity/gnunet-service-identity.c:1032 |
4496 | msgid "no matching ego found" | 4582 | msgid "no matching ego found" |
4497 | msgstr "" | 4583 | msgstr "" |
4498 | 4584 | ||
4499 | #: src/identity/gnunet-service-identity.c:1131 | 4585 | #: src/identity/gnunet-service-identity.c:1130 |
4500 | #, fuzzy, c-format | 4586 | #, fuzzy, c-format |
4501 | msgid "Failed to parse ego information in `%s'\n" | 4587 | msgid "Failed to parse ego information in `%s'\n" |
4502 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" | 4588 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" |
4503 | 4589 | ||
4504 | #: src/identity/gnunet-service-identity.c:1189 | 4590 | #: src/identity/gnunet-service-identity.c:1188 |
4505 | #, fuzzy, c-format | 4591 | #, fuzzy, c-format |
4506 | msgid "Failed to parse subsystem identity configuration file `%s'\n" | 4592 | msgid "Failed to parse subsystem identity configuration file `%s'\n" |
4507 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" | 4593 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" |
4508 | 4594 | ||
4509 | #: src/identity/gnunet-service-identity.c:1198 | 4595 | #: src/identity/gnunet-service-identity.c:1197 |
4510 | #, fuzzy, c-format | 4596 | #, fuzzy, c-format |
4511 | msgid "Failed to create directory `%s' for storing egos\n" | 4597 | msgid "Failed to create directory `%s' for storing egos\n" |
4512 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" | 4598 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" |
@@ -4546,7 +4632,7 @@ msgstr "æ— æ³•è§£æžâ€œ%sâ€(%s):%s\n" | |||
4546 | msgid "No records found for `%s'" | 4632 | msgid "No records found for `%s'" |
4547 | msgstr "è¿è¡Œ %s失败:%s %d\n" | 4633 | msgstr "è¿è¡Œ %s失败:%s %d\n" |
4548 | 4634 | ||
4549 | #: src/namecache/gnunet-namecache.c:119 src/namestore/gnunet-namestore.c:459 | 4635 | #: src/namecache/gnunet-namecache.c:119 src/namestore/gnunet-namestore.c:469 |
4550 | #, c-format | 4636 | #, c-format |
4551 | msgid "\tCorrupt or unsupported record of type %u\n" | 4637 | msgid "\tCorrupt or unsupported record of type %u\n" |
4552 | msgstr "" | 4638 | msgstr "" |
@@ -4566,7 +4652,7 @@ msgstr "“%sâ€çš„å‚æ•°æ— æ•ˆã€‚\n" | |||
4566 | msgid "You must specify a name\n" | 4652 | msgid "You must specify a name\n" |
4567 | msgstr "您必须指定一个接收方ï¼\n" | 4653 | msgstr "您必须指定一个接收方ï¼\n" |
4568 | 4654 | ||
4569 | #: src/namecache/gnunet-namecache.c:214 src/namestore/gnunet-namestore.c:1641 | 4655 | #: src/namecache/gnunet-namecache.c:214 src/namestore/gnunet-namestore.c:1591 |
4570 | msgid "name of the record to add/delete/display" | 4656 | msgid "name of the record to add/delete/display" |
4571 | msgstr "" | 4657 | msgstr "" |
4572 | 4658 | ||
@@ -4574,7 +4660,7 @@ msgstr "" | |||
4574 | msgid "specifies the public key of the zone to look in" | 4660 | msgid "specifies the public key of the zone to look in" |
4575 | msgstr "" | 4661 | msgstr "" |
4576 | 4662 | ||
4577 | #: src/namecache/gnunet-namecache.c:233 src/namestore/gnunet-namestore.c:1702 | 4663 | #: src/namecache/gnunet-namecache.c:233 src/namestore/gnunet-namestore.c:1652 |
4578 | #, fuzzy | 4664 | #, fuzzy |
4579 | msgid "GNUnet zone manipulation tool" | 4665 | msgid "GNUnet zone manipulation tool" |
4580 | msgstr "GNUnet é…ç½®" | 4666 | msgstr "GNUnet é…ç½®" |
@@ -4723,140 +4809,113 @@ msgstr "" | |||
4723 | msgid "GNU Name System First-Come-First-Served name registration service" | 4809 | msgid "GNU Name System First-Come-First-Served name registration service" |
4724 | msgstr "" | 4810 | msgstr "" |
4725 | 4811 | ||
4726 | #: src/namestore/gnunet-namestore.c:334 | 4812 | #: src/namestore/gnunet-namestore.c:340 |
4727 | #, c-format | 4813 | #, c-format |
4728 | msgid "Adding record failed: %s\n" | 4814 | msgid "Adding record failed: %s\n" |
4729 | msgstr "" | 4815 | msgstr "" |
4730 | 4816 | ||
4731 | #: src/namestore/gnunet-namestore.c:362 | 4817 | #: src/namestore/gnunet-namestore.c:368 |
4732 | #, c-format | 4818 | #, c-format |
4733 | msgid "Deleting record failed, record does not exist%s%s\n" | 4819 | msgid "Deleting record failed, record does not exist%s%s\n" |
4734 | msgstr "" | 4820 | msgstr "" |
4735 | 4821 | ||
4736 | #: src/namestore/gnunet-namestore.c:369 | 4822 | #: src/namestore/gnunet-namestore.c:375 |
4737 | #, c-format | 4823 | #, c-format |
4738 | msgid "Deleting record failed%s%s\n" | 4824 | msgid "Deleting record failed%s%s\n" |
4739 | msgstr "" | 4825 | msgstr "" |
4740 | 4826 | ||
4741 | #: src/namestore/gnunet-namestore.c:656 | ||
4742 | #, c-format | ||
4743 | msgid "A %s record exists already under `%s', no other records can be added.\n" | ||
4744 | msgstr "" | ||
4745 | |||
4746 | #: src/namestore/gnunet-namestore.c:668 | 4827 | #: src/namestore/gnunet-namestore.c:668 |
4747 | #, c-format | 4828 | #, c-format |
4748 | msgid "" | 4829 | msgid "" |
4749 | "A zone key record exists already under `%s', no other records can be added.\n" | ||
4750 | msgstr "" | ||
4751 | |||
4752 | #: src/namestore/gnunet-namestore.c:680 | ||
4753 | #, c-format | ||
4754 | msgid "" | ||
4755 | "A SOA record exists already under `%s', cannot add a second SOA to the same " | 4830 | "A SOA record exists already under `%s', cannot add a second SOA to the same " |
4756 | "zone.\n" | 4831 | "zone.\n" |
4757 | msgstr "" | 4832 | msgstr "" |
4758 | 4833 | ||
4759 | #: src/namestore/gnunet-namestore.c:696 | 4834 | #: src/namestore/gnunet-namestore.c:789 |
4760 | #, c-format | ||
4761 | msgid "Records already exist under `%s', cannot add `%s' record.\n" | ||
4762 | msgstr "" | ||
4763 | |||
4764 | #: src/namestore/gnunet-namestore.c:711 | ||
4765 | #, c-format | ||
4766 | msgid "Records already exist under `%s', cannot add record.\n" | ||
4767 | msgstr "" | ||
4768 | |||
4769 | #: src/namestore/gnunet-namestore.c:726 | ||
4770 | #, c-format | ||
4771 | msgid "" | ||
4772 | "Non-GNS2DNS records already exist under `%s', cannot add GNS2DNS record.\n" | ||
4773 | msgstr "" | ||
4774 | |||
4775 | #: src/namestore/gnunet-namestore.c:846 | ||
4776 | #, c-format | 4835 | #, c-format |
4777 | msgid "There are no records under label `%s' that could be deleted.\n" | 4836 | msgid "There are no records under label `%s' that could be deleted.\n" |
4778 | msgstr "" | 4837 | msgstr "" |
4779 | 4838 | ||
4780 | #: src/namestore/gnunet-namestore.c:889 | 4839 | #: src/namestore/gnunet-namestore.c:832 |
4781 | #, c-format | 4840 | #, c-format |
4782 | msgid "" | 4841 | msgid "" |
4783 | "There are no records under label `%s' that match the request for deletion.\n" | 4842 | "There are no records under label `%s' that match the request for deletion.\n" |
4784 | msgstr "" | 4843 | msgstr "" |
4785 | 4844 | ||
4786 | #: src/namestore/gnunet-namestore.c:970 | 4845 | #: src/namestore/gnunet-namestore.c:920 |
4787 | #, fuzzy, c-format | 4846 | #, fuzzy, c-format |
4788 | msgid "Failed to replace records: %s\n" | 4847 | msgid "Failed to replace records: %s\n" |
4789 | msgstr "打开日志文件“%sâ€å¤±è´¥ï¼š%s\n" | 4848 | msgstr "打开日志文件“%sâ€å¤±è´¥ï¼š%s\n" |
4790 | 4849 | ||
4791 | #: src/namestore/gnunet-namestore.c:993 | 4850 | #: src/namestore/gnunet-namestore.c:943 |
4792 | #, c-format | 4851 | #, c-format |
4793 | msgid "No options given\n" | 4852 | msgid "No options given\n" |
4794 | msgstr "" | 4853 | msgstr "" |
4795 | 4854 | ||
4796 | #: src/namestore/gnunet-namestore.c:1014 src/namestore/gnunet-namestore.c:1066 | 4855 | #: src/namestore/gnunet-namestore.c:964 src/namestore/gnunet-namestore.c:1016 |
4797 | #: src/namestore/gnunet-namestore.c:1076 src/namestore/gnunet-namestore.c:1105 | 4856 | #: src/namestore/gnunet-namestore.c:1026 src/namestore/gnunet-namestore.c:1055 |
4798 | #: src/namestore/gnunet-namestore.c:1126 src/namestore/gnunet-namestore.c:1153 | 4857 | #: src/namestore/gnunet-namestore.c:1076 src/namestore/gnunet-namestore.c:1103 |
4799 | #: src/namestore/gnunet-namestore.c:1230 | 4858 | #: src/namestore/gnunet-namestore.c:1180 |
4800 | #, fuzzy, c-format | 4859 | #, fuzzy, c-format |
4801 | msgid "Missing option `%s' for operation `%s'\n" | 4860 | msgid "Missing option `%s' for operation `%s'\n" |
4802 | msgstr "é…置文件“%sâ€å·²å†™å…¥ã€‚\n" | 4861 | msgstr "é…置文件“%sâ€å·²å†™å…¥ã€‚\n" |
4803 | 4862 | ||
4804 | #: src/namestore/gnunet-namestore.c:1016 | 4863 | #: src/namestore/gnunet-namestore.c:966 |
4805 | msgid "replace" | 4864 | msgid "replace" |
4806 | msgstr "" | 4865 | msgstr "" |
4807 | 4866 | ||
4808 | #: src/namestore/gnunet-namestore.c:1045 | 4867 | #: src/namestore/gnunet-namestore.c:995 |
4809 | #, fuzzy, c-format | 4868 | #, fuzzy, c-format |
4810 | msgid "Invalid nick `%s'\n" | 4869 | msgid "Invalid nick `%s'\n" |
4811 | msgstr "æ— æ•ˆæ¡ç›®ã€‚\n" | 4870 | msgstr "æ— æ•ˆæ¡ç›®ã€‚\n" |
4812 | 4871 | ||
4813 | #: src/namestore/gnunet-namestore.c:1068 src/namestore/gnunet-namestore.c:1078 | 4872 | #: src/namestore/gnunet-namestore.c:1018 src/namestore/gnunet-namestore.c:1028 |
4814 | #: src/namestore/gnunet-namestore.c:1107 src/namestore/gnunet-namestore.c:1128 | 4873 | #: src/namestore/gnunet-namestore.c:1057 src/namestore/gnunet-namestore.c:1078 |
4815 | #: src/namestore/gnunet-namestore.c:1232 | 4874 | #: src/namestore/gnunet-namestore.c:1182 |
4816 | msgid "add" | 4875 | msgid "add" |
4817 | msgstr "" | 4876 | msgstr "" |
4818 | 4877 | ||
4819 | #: src/namestore/gnunet-namestore.c:1086 | 4878 | #: src/namestore/gnunet-namestore.c:1036 |
4820 | #, fuzzy, c-format | 4879 | #, fuzzy, c-format |
4821 | msgid "Unsupported type `%s'\n" | 4880 | msgid "Unsupported type `%s'\n" |
4822 | msgstr "未知的命令“%sâ€ã€‚\n" | 4881 | msgstr "未知的命令“%sâ€ã€‚\n" |
4823 | 4882 | ||
4824 | #: src/namestore/gnunet-namestore.c:1096 | 4883 | #: src/namestore/gnunet-namestore.c:1046 |
4825 | #, c-format | 4884 | #, c-format |
4826 | msgid "For DNS record types `SRV', `TLSA' and `OPENPGPKEY'" | 4885 | msgid "For DNS record types `SRV', `TLSA' and `OPENPGPKEY'" |
4827 | msgstr "" | 4886 | msgstr "" |
4828 | 4887 | ||
4829 | #: src/namestore/gnunet-namestore.c:1116 | 4888 | #: src/namestore/gnunet-namestore.c:1066 |
4830 | #, c-format | 4889 | #, c-format |
4831 | msgid "Value `%s' invalid for record type `%s'\n" | 4890 | msgid "Value `%s' invalid for record type `%s'\n" |
4832 | msgstr "" | 4891 | msgstr "" |
4833 | 4892 | ||
4834 | #: src/namestore/gnunet-namestore.c:1135 src/namestore/gnunet-namestore.c:1239 | 4893 | #: src/namestore/gnunet-namestore.c:1085 src/namestore/gnunet-namestore.c:1189 |
4835 | #, fuzzy, c-format | 4894 | #, fuzzy, c-format |
4836 | msgid "Invalid time format `%s'\n" | 4895 | msgid "Invalid time format `%s'\n" |
4837 | msgstr "IP æ ¼å¼æ— 效:“%sâ€\n" | 4896 | msgstr "IP æ ¼å¼æ— 效:“%sâ€\n" |
4838 | 4897 | ||
4839 | #: src/namestore/gnunet-namestore.c:1155 | 4898 | #: src/namestore/gnunet-namestore.c:1105 |
4840 | msgid "del" | 4899 | msgid "del" |
4841 | msgstr "" | 4900 | msgstr "" |
4842 | 4901 | ||
4843 | #: src/namestore/gnunet-namestore.c:1197 | 4902 | #: src/namestore/gnunet-namestore.c:1147 |
4844 | #, fuzzy, c-format | 4903 | #, fuzzy, c-format |
4845 | msgid "Invalid public key for reverse lookup `%s'\n" | 4904 | msgid "Invalid public key for reverse lookup `%s'\n" |
4846 | msgstr "“%sâ€çš„å‚æ•°æ— æ•ˆã€‚\n" | 4905 | msgstr "“%sâ€çš„å‚æ•°æ— æ•ˆã€‚\n" |
4847 | 4906 | ||
4848 | #: src/namestore/gnunet-namestore.c:1222 | 4907 | #: src/namestore/gnunet-namestore.c:1172 |
4849 | #: src/peerinfo-tool/gnunet-peerinfo.c:737 | 4908 | #: src/peerinfo-tool/gnunet-peerinfo.c:737 |
4850 | #, fuzzy, c-format | 4909 | #, fuzzy, c-format |
4851 | msgid "Invalid URI `%s'\n" | 4910 | msgid "Invalid URI `%s'\n" |
4852 | msgstr "æ— æ•ˆæ¡ç›®ã€‚\n" | 4911 | msgstr "æ— æ•ˆæ¡ç›®ã€‚\n" |
4853 | 4912 | ||
4854 | #: src/namestore/gnunet-namestore.c:1292 | 4913 | #: src/namestore/gnunet-namestore.c:1242 |
4855 | #, c-format | 4914 | #, c-format |
4856 | msgid "Label `%s' contains `.' which is not allowed\n" | 4915 | msgid "Label `%s' contains `.' which is not allowed\n" |
4857 | msgstr "" | 4916 | msgstr "" |
4858 | 4917 | ||
4859 | #: src/namestore/gnunet-namestore.c:1342 | 4918 | #: src/namestore/gnunet-namestore.c:1292 |
4860 | #, c-format | 4919 | #, c-format |
4861 | msgid "" | 4920 | msgid "" |
4862 | "No default identity configured for `namestore' subsystem\n" | 4921 | "No default identity configured for `namestore' subsystem\n" |
@@ -4864,110 +4923,115 @@ msgid "" | |||
4864 | "Run gnunet-identity -d to get a list of choices for $NAME\n" | 4923 | "Run gnunet-identity -d to get a list of choices for $NAME\n" |
4865 | msgstr "" | 4924 | msgstr "" |
4866 | 4925 | ||
4867 | #: src/namestore/gnunet-namestore.c:1407 | 4926 | #: src/namestore/gnunet-namestore.c:1357 |
4868 | #, c-format | 4927 | #, c-format |
4869 | msgid "Superfluous command line arguments (starting with `%s') ignored\n" | 4928 | msgid "Superfluous command line arguments (starting with `%s') ignored\n" |
4870 | msgstr "" | 4929 | msgstr "" |
4871 | 4930 | ||
4872 | #: src/namestore/gnunet-namestore.c:1436 | 4931 | #: src/namestore/gnunet-namestore.c:1386 |
4873 | #, fuzzy, c-format | 4932 | #, fuzzy, c-format |
4874 | msgid "Cannot connect to identity service\n" | 4933 | msgid "Cannot connect to identity service\n" |
4875 | msgstr "æ— æ³•è¿žæŽ¥åˆ° %s:%u:%s\n" | 4934 | msgstr "æ— æ³•è¿žæŽ¥åˆ° %s:%u:%s\n" |
4876 | 4935 | ||
4877 | #: src/namestore/gnunet-namestore.c:1483 | 4936 | #: src/namestore/gnunet-namestore.c:1433 |
4878 | msgid "Empty record line argument is not allowed.\n" | 4937 | msgid "Empty record line argument is not allowed.\n" |
4879 | msgstr "" | 4938 | msgstr "" |
4880 | 4939 | ||
4881 | #: src/namestore/gnunet-namestore.c:1495 | 4940 | #: src/namestore/gnunet-namestore.c:1445 |
4882 | #, c-format | 4941 | #, c-format |
4883 | msgid "Invalid expiration time `%s' (must be without unit)\n" | 4942 | msgid "Invalid expiration time `%s' (must be without unit)\n" |
4884 | msgstr "" | 4943 | msgstr "" |
4885 | 4944 | ||
4886 | #: src/namestore/gnunet-namestore.c:1507 src/namestore/gnunet-namestore.c:1523 | 4945 | #: src/namestore/gnunet-namestore.c:1457 src/namestore/gnunet-namestore.c:1473 |
4887 | #: src/namestore/gnunet-namestore.c:1540 | 4946 | #: src/namestore/gnunet-namestore.c:1490 |
4888 | #, fuzzy, c-format | 4947 | #, fuzzy, c-format |
4889 | msgid "Missing entries in record line `%s'.\n" | 4948 | msgid "Missing entries in record line `%s'.\n" |
4890 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" | 4949 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" |
4891 | 4950 | ||
4892 | #: src/namestore/gnunet-namestore.c:1515 | 4951 | #: src/namestore/gnunet-namestore.c:1465 |
4893 | #, fuzzy, c-format | 4952 | #, fuzzy, c-format |
4894 | msgid "Unknown record type `%s'\n" | 4953 | msgid "Unknown record type `%s'\n" |
4895 | msgstr "未知的命令“%sâ€ã€‚\n" | 4954 | msgstr "未知的命令“%sâ€ã€‚\n" |
4896 | 4955 | ||
4897 | #: src/namestore/gnunet-namestore.c:1553 | 4956 | #: src/namestore/gnunet-namestore.c:1503 |
4898 | #, fuzzy, c-format | 4957 | #, fuzzy, c-format |
4899 | msgid "Invalid record data for type %s: `%s'.\n" | 4958 | msgid "Invalid record data for type %s: `%s'.\n" |
4900 | msgstr "IP æ ¼å¼æ— 效:“%sâ€\n" | 4959 | msgstr "IP æ ¼å¼æ— 效:“%sâ€\n" |
4901 | 4960 | ||
4902 | #: src/namestore/gnunet-namestore.c:1610 | 4961 | #: src/namestore/gnunet-namestore.c:1560 |
4903 | msgid "add record" | 4962 | msgid "add record" |
4904 | msgstr "" | 4963 | msgstr "" |
4905 | 4964 | ||
4906 | #: src/namestore/gnunet-namestore.c:1613 | 4965 | #: src/namestore/gnunet-namestore.c:1563 |
4907 | msgid "delete record" | 4966 | msgid "delete record" |
4908 | msgstr "" | 4967 | msgstr "" |
4909 | 4968 | ||
4910 | #: src/namestore/gnunet-namestore.c:1617 | 4969 | #: src/namestore/gnunet-namestore.c:1567 |
4911 | msgid "display records" | 4970 | msgid "display records" |
4912 | msgstr "" | 4971 | msgstr "" |
4913 | 4972 | ||
4914 | #: src/namestore/gnunet-namestore.c:1624 | 4973 | #: src/namestore/gnunet-namestore.c:1574 |
4915 | msgid "" | 4974 | msgid "" |
4916 | "expiration time for record to use (for adding only), \"never\" is possible" | 4975 | "expiration time for record to use (for adding only), \"never\" is possible" |
4917 | msgstr "" | 4976 | msgstr "" |
4918 | 4977 | ||
4919 | #: src/namestore/gnunet-namestore.c:1630 | 4978 | #: src/namestore/gnunet-namestore.c:1580 |
4920 | #, fuzzy | 4979 | #, fuzzy |
4921 | msgid "set the desired nick name for the zone" | 4980 | msgid "set the desired nick name for the zone" |
4922 | msgstr "æ— æ³•èŽ·å–有关用户“%sâ€çš„ä¿¡æ¯ï¼š%s\n" | 4981 | msgstr "æ— æ³•èŽ·å–有关用户“%sâ€çš„ä¿¡æ¯ï¼š%s\n" |
4923 | 4982 | ||
4924 | #: src/namestore/gnunet-namestore.c:1635 | 4983 | #: src/namestore/gnunet-namestore.c:1585 |
4925 | #, fuzzy | 4984 | #, fuzzy |
4926 | msgid "monitor changes in the namestore" | 4985 | msgid "monitor changes in the namestore" |
4927 | msgstr "åˆå§‹åŒ–“%sâ€æœåŠ¡å¤±è´¥ã€‚\n" | 4986 | msgstr "åˆå§‹åŒ–“%sâ€æœåŠ¡å¤±è´¥ã€‚\n" |
4928 | 4987 | ||
4929 | #: src/namestore/gnunet-namestore.c:1647 | 4988 | #: src/namestore/gnunet-namestore.c:1597 |
4930 | #, fuzzy | 4989 | #, fuzzy |
4931 | msgid "determine our name for the given PKEY" | 4990 | msgid "determine our name for the given PKEY" |
4932 | msgstr "æ— æ³•èŽ·å–有关用户“%sâ€çš„ä¿¡æ¯ï¼š%s\n" | 4991 | msgstr "æ— æ³•èŽ·å–有关用户“%sâ€çš„ä¿¡æ¯ï¼š%s\n" |
4933 | 4992 | ||
4934 | #: src/namestore/gnunet-namestore.c:1654 | 4993 | #: src/namestore/gnunet-namestore.c:1604 |
4935 | msgid "" | 4994 | msgid "" |
4936 | "set record set to values given by (possibly multiple) RECORDLINES; can be " | 4995 | "set record set to values given by (possibly multiple) RECORDLINES; can be " |
4937 | "specified multiple times" | 4996 | "specified multiple times" |
4938 | msgstr "" | 4997 | msgstr "" |
4939 | 4998 | ||
4940 | #: src/namestore/gnunet-namestore.c:1660 | 4999 | #: src/namestore/gnunet-namestore.c:1610 |
4941 | msgid "type of the record to add/delete/display" | 5000 | msgid "type of the record to add/delete/display" |
4942 | msgstr "" | 5001 | msgstr "" |
4943 | 5002 | ||
4944 | #: src/namestore/gnunet-namestore.c:1665 | 5003 | #: src/namestore/gnunet-namestore.c:1615 |
4945 | msgid "URI to import into our zone" | 5004 | msgid "URI to import into our zone" |
4946 | msgstr "" | 5005 | msgstr "" |
4947 | 5006 | ||
4948 | #: src/namestore/gnunet-namestore.c:1671 | 5007 | #: src/namestore/gnunet-namestore.c:1621 |
4949 | msgid "value of the record to add/delete" | 5008 | msgid "value of the record to add/delete" |
4950 | msgstr "" | 5009 | msgstr "" |
4951 | 5010 | ||
4952 | #: src/namestore/gnunet-namestore.c:1675 | 5011 | #: src/namestore/gnunet-namestore.c:1625 |
4953 | msgid "create or list public record" | 5012 | msgid "create or list public record" |
4954 | msgstr "" | 5013 | msgstr "" |
4955 | 5014 | ||
4956 | #: src/namestore/gnunet-namestore.c:1681 | 5015 | #: src/namestore/gnunet-namestore.c:1631 |
4957 | msgid "" | 5016 | msgid "" |
4958 | "create shadow record (only valid if all other records of the same type have " | 5017 | "create shadow record (only valid if all other records of the same type have " |
4959 | "expired" | 5018 | "expired" |
4960 | msgstr "" | 5019 | msgstr "" |
4961 | 5020 | ||
4962 | #: src/namestore/gnunet-namestore.c:1687 | 5021 | #: src/namestore/gnunet-namestore.c:1637 |
4963 | msgid "name of the ego controlling the zone" | 5022 | msgid "name of the ego controlling the zone" |
4964 | msgstr "" | 5023 | msgstr "" |
4965 | 5024 | ||
4966 | #: src/namestore/gnunet-service-namestore.c:871 | 5025 | #: src/namestore/gnunet-service-namestore.c:879 |
4967 | #, fuzzy, c-format | 5026 | #, fuzzy, c-format |
4968 | msgid "Failed to replicate block in namecache: %s\n" | 5027 | msgid "Failed to replicate block in namecache: %s\n" |
4969 | msgstr "å‘é€æ¶ˆæ¯å¤±è´¥ã€‚\n" | 5028 | msgstr "å‘é€æ¶ˆæ¯å¤±è´¥ã€‚\n" |
4970 | 5029 | ||
5030 | #: src/namestore/gnunet-service-namestore.c:1668 | ||
5031 | #, fuzzy | ||
5032 | msgid "Store failed" | ||
5033 | msgstr "“%sâ€å·²è¿žæŽ¥åˆ°â€œ%sâ€ã€‚\n" | ||
5034 | |||
4971 | #: src/namestore/gnunet-zoneimport.c:1847 | 5035 | #: src/namestore/gnunet-zoneimport.c:1847 |
4972 | msgid "size to use for the main hash map" | 5036 | msgid "size to use for the main hash map" |
4973 | msgstr "" | 5037 | msgstr "" |
@@ -4976,10 +5040,6 @@ msgstr "" | |||
4976 | msgid "minimum expiration time we assume for imported records" | 5040 | msgid "minimum expiration time we assume for imported records" |
4977 | msgstr "" | 5041 | msgstr "" |
4978 | 5042 | ||
4979 | #: src/namestore/namestore_api.c:373 | ||
4980 | msgid "Namestore failed to store record\n" | ||
4981 | msgstr "" | ||
4982 | |||
4983 | #: src/namestore/plugin_namestore_flat.c:195 | 5043 | #: src/namestore/plugin_namestore_flat.c:195 |
4984 | #, c-format | 5044 | #, c-format |
4985 | msgid "File too big to map: %llu bytes.\n" | 5045 | msgid "File too big to map: %llu bytes.\n" |
@@ -5560,6 +5620,51 @@ msgstr "åˆå§‹åŒ–“%sâ€æœåŠ¡å¤±è´¥ã€‚\n" | |||
5560 | msgid "Daemon to run to perform IP protocol translation to GNUnet" | 5620 | msgid "Daemon to run to perform IP protocol translation to GNUnet" |
5561 | msgstr "" | 5621 | msgstr "" |
5562 | 5622 | ||
5623 | #: src/reclaim/gnunet-did.c:209 | ||
5624 | #, fuzzy, c-format | ||
5625 | msgid "Invalid DID `%s'\n" | ||
5626 | msgstr "æ— æ•ˆæ¡ç›®ã€‚\n" | ||
5627 | |||
5628 | #: src/reclaim/gnunet-did.c:835 | ||
5629 | msgid "Create a DID Document and display its DID" | ||
5630 | msgstr "" | ||
5631 | |||
5632 | #: src/reclaim/gnunet-did.c:840 | ||
5633 | msgid "Get the DID Document associated with the given DID" | ||
5634 | msgstr "" | ||
5635 | |||
5636 | #: src/reclaim/gnunet-did.c:844 | ||
5637 | msgid "Show the DID for a given ego" | ||
5638 | msgstr "" | ||
5639 | |||
5640 | #: src/reclaim/gnunet-did.c:849 | ||
5641 | msgid "Remove the DID" | ||
5642 | msgstr "" | ||
5643 | |||
5644 | #: src/reclaim/gnunet-did.c:853 src/reclaim/gnunet-did.c:857 | ||
5645 | msgid "Replace the DID Document." | ||
5646 | msgstr "" | ||
5647 | |||
5648 | #: src/reclaim/gnunet-did.c:863 | ||
5649 | msgid "The Decentralized Identity (DID)" | ||
5650 | msgstr "" | ||
5651 | |||
5652 | #: src/reclaim/gnunet-did.c:869 | ||
5653 | msgid "The DID Document to store in GNUNET" | ||
5654 | msgstr "" | ||
5655 | |||
5656 | #: src/reclaim/gnunet-did.c:874 | ||
5657 | msgid "The name of the EGO" | ||
5658 | msgstr "" | ||
5659 | |||
5660 | #: src/reclaim/gnunet-did.c:880 | ||
5661 | msgid "The time until the DID Document is going to expire (e.g. 5d)" | ||
5662 | msgstr "" | ||
5663 | |||
5664 | #: src/reclaim/gnunet-did.c:889 | ||
5665 | msgid "Manage Decentralized Identities (DIDs)" | ||
5666 | msgstr "" | ||
5667 | |||
5563 | #: src/reclaim/gnunet-reclaim.c:802 | 5668 | #: src/reclaim/gnunet-reclaim.c:802 |
5564 | #, fuzzy, c-format | 5669 | #, fuzzy, c-format |
5565 | msgid "Ego is required\n" | 5670 | msgid "Ego is required\n" |
@@ -6448,17 +6553,17 @@ msgid "" | |||
6448 | "free topology cannot be more than %u. Given `%s = %llu'" | 6553 | "free topology cannot be more than %u. Given `%s = %llu'" |
6449 | msgstr "" | 6554 | msgstr "" |
6450 | 6555 | ||
6451 | #: src/testbed/testbed_api_topology.c:1033 src/testing/testing.c:2643 | 6556 | #: src/testbed/testbed_api_topology.c:1033 src/testing/testing.c:2657 |
6452 | #, c-format | 6557 | #, c-format |
6453 | msgid "Topology file %s not found\n" | 6558 | msgid "Topology file %s not found\n" |
6454 | msgstr "" | 6559 | msgstr "" |
6455 | 6560 | ||
6456 | #: src/testbed/testbed_api_topology.c:1041 src/testing/testing.c:2651 | 6561 | #: src/testbed/testbed_api_topology.c:1041 src/testing/testing.c:2665 |
6457 | #, c-format | 6562 | #, c-format |
6458 | msgid "Topology file %s has no data\n" | 6563 | msgid "Topology file %s has no data\n" |
6459 | msgstr "" | 6564 | msgstr "" |
6460 | 6565 | ||
6461 | #: src/testbed/testbed_api_topology.c:1049 src/testing/testing.c:2659 | 6566 | #: src/testbed/testbed_api_topology.c:1049 src/testing/testing.c:2673 |
6462 | #, c-format | 6567 | #, c-format |
6463 | msgid "Topology file %s cannot be read\n" | 6568 | msgid "Topology file %s cannot be read\n" |
6464 | msgstr "" | 6569 | msgstr "" |
@@ -6665,7 +6770,7 @@ msgstr "" | |||
6665 | 6770 | ||
6666 | #: src/transport/gnunet-communicator-tcp.c:3338 | 6771 | #: src/transport/gnunet-communicator-tcp.c:3338 |
6667 | #: src/transport/gnunet-communicator-udp.c:3856 | 6772 | #: src/transport/gnunet-communicator-udp.c:3856 |
6668 | #: src/transport/gnunet-service-tng.c:10512 | 6773 | #: src/transport/gnunet-service-tng.c:10623 |
6669 | #: src/transport/gnunet-service-transport.c:2627 | 6774 | #: src/transport/gnunet-service-transport.c:2627 |
6670 | #, fuzzy | 6775 | #, fuzzy |
6671 | msgid "Transport service is lacking key configuration settings. Exiting.\n" | 6776 | msgid "Transport service is lacking key configuration settings. Exiting.\n" |
@@ -7852,58 +7957,58 @@ msgstr "" | |||
7852 | msgid "Need a non-empty hostname for service `%s'.\n" | 7957 | msgid "Need a non-empty hostname for service `%s'.\n" |
7853 | msgstr "" | 7958 | msgstr "" |
7854 | 7959 | ||
7855 | #: src/util/common_logging.c:626 src/util/common_logging.c:665 | 7960 | #: src/util/common_logging.c:648 src/util/common_logging.c:687 |
7856 | #, c-format | 7961 | #, c-format |
7857 | msgid "ERROR: Unable to parse log definition: Syntax error at `%s'.\n" | 7962 | msgid "ERROR: Unable to parse log definition: Syntax error at `%s'.\n" |
7858 | msgstr "" | 7963 | msgstr "" |
7859 | 7964 | ||
7860 | #: src/util/common_logging.c:904 | 7965 | #: src/util/common_logging.c:926 |
7861 | #, fuzzy, c-format | 7966 | #, fuzzy, c-format |
7862 | msgid "Message `%.*s' repeated %u times in the last %s\n" | 7967 | msgid "Message `%.*s' repeated %u times in the last %s\n" |
7863 | msgstr "消æ¯â€œ%.*sâ€é‡å¤äº† %u 次,在最近 %llu 秒内\n" | 7968 | msgstr "消æ¯â€œ%.*sâ€é‡å¤äº† %u 次,在最近 %llu 秒内\n" |
7864 | 7969 | ||
7865 | #: src/util/common_logging.c:1108 | 7970 | #: src/util/common_logging.c:1131 |
7866 | msgid "ERROR" | 7971 | msgid "ERROR" |
7867 | msgstr "错误" | 7972 | msgstr "错误" |
7868 | 7973 | ||
7869 | #: src/util/common_logging.c:1110 | 7974 | #: src/util/common_logging.c:1133 |
7870 | msgid "WARNING" | 7975 | msgid "WARNING" |
7871 | msgstr "è¦å‘Š" | 7976 | msgstr "è¦å‘Š" |
7872 | 7977 | ||
7873 | #: src/util/common_logging.c:1112 | 7978 | #: src/util/common_logging.c:1135 |
7874 | msgid "MESSAGE" | 7979 | msgid "MESSAGE" |
7875 | msgstr "" | 7980 | msgstr "" |
7876 | 7981 | ||
7877 | #: src/util/common_logging.c:1114 | 7982 | #: src/util/common_logging.c:1137 |
7878 | msgid "INFO" | 7983 | msgid "INFO" |
7879 | msgstr "ä¿¡æ¯" | 7984 | msgstr "ä¿¡æ¯" |
7880 | 7985 | ||
7881 | #: src/util/common_logging.c:1116 | 7986 | #: src/util/common_logging.c:1139 |
7882 | msgid "DEBUG" | 7987 | msgid "DEBUG" |
7883 | msgstr "调试" | 7988 | msgstr "调试" |
7884 | 7989 | ||
7885 | #: src/util/common_logging.c:1118 | 7990 | #: src/util/common_logging.c:1141 |
7886 | msgid "NONE" | 7991 | msgid "NONE" |
7887 | msgstr "" | 7992 | msgstr "" |
7888 | 7993 | ||
7889 | #: src/util/common_logging.c:1119 | 7994 | #: src/util/common_logging.c:1142 |
7890 | msgid "INVALID" | 7995 | msgid "INVALID" |
7891 | msgstr "" | 7996 | msgstr "" |
7892 | 7997 | ||
7893 | #: src/util/common_logging.c:1400 | 7998 | #: src/util/common_logging.c:1423 |
7894 | msgid "unknown address" | 7999 | msgid "unknown address" |
7895 | msgstr "" | 8000 | msgstr "" |
7896 | 8001 | ||
7897 | #: src/util/common_logging.c:1445 | 8002 | #: src/util/common_logging.c:1468 |
7898 | msgid "invalid address" | 8003 | msgid "invalid address" |
7899 | msgstr "" | 8004 | msgstr "" |
7900 | 8005 | ||
7901 | #: src/util/common_logging.c:1464 | 8006 | #: src/util/common_logging.c:1487 |
7902 | #, fuzzy, c-format | 8007 | #, fuzzy, c-format |
7903 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" | 8008 | msgid "Configuration fails to specify option `%s' in section `%s'!\n" |
7904 | msgstr "é…ç½®ä¸æ»¡è¶³é…置规范文件“%sâ€çš„约æŸï¼\n" | 8009 | msgstr "é…ç½®ä¸æ»¡è¶³é…置规范文件“%sâ€çš„约æŸï¼\n" |
7905 | 8010 | ||
7906 | #: src/util/common_logging.c:1487 | 8011 | #: src/util/common_logging.c:1510 |
7907 | #, fuzzy, c-format | 8012 | #, fuzzy, c-format |
7908 | msgid "" | 8013 | msgid "" |
7909 | "Configuration specifies invalid value for option `%s' in section `%s': %s\n" | 8014 | "Configuration specifies invalid value for option `%s' in section `%s': %s\n" |
@@ -8050,17 +8155,17 @@ msgstr "打开日志文件“%sâ€å¤±è´¥ï¼š%s\n" | |||
8050 | msgid "Could not bind to any port: %s\n" | 8155 | msgid "Could not bind to any port: %s\n" |
8051 | msgstr "找ä¸åˆ°ä¸»æœºâ€œ%sâ€çš„ IP:%s\n" | 8156 | msgstr "找ä¸åˆ°ä¸»æœºâ€œ%sâ€çš„ IP:%s\n" |
8052 | 8157 | ||
8053 | #: src/util/dnsstub.c:344 | 8158 | #: src/util/dnsstub.c:370 |
8054 | #, c-format | 8159 | #, c-format |
8055 | msgid "Received DNS response that is too small (%u bytes)" | 8160 | msgid "Received DNS response that is too small (%u bytes)\n" |
8056 | msgstr "" | 8161 | msgstr "" |
8057 | 8162 | ||
8058 | #: src/util/dnsstub.c:482 | 8163 | #: src/util/dnsstub.c:508 |
8059 | #, fuzzy, c-format | 8164 | #, fuzzy, c-format |
8060 | msgid "Failed to send DNS request to %s: %s\n" | 8165 | msgid "Failed to send DNS request to %s: %s\n" |
8061 | msgstr "打开日志文件“%sâ€å¤±è´¥ï¼š%s\n" | 8166 | msgstr "打开日志文件“%sâ€å¤±è´¥ï¼š%s\n" |
8062 | 8167 | ||
8063 | #: src/util/dnsstub.c:487 | 8168 | #: src/util/dnsstub.c:513 |
8064 | #, fuzzy, c-format | 8169 | #, fuzzy, c-format |
8065 | msgid "Sent DNS request to %s\n" | 8170 | msgid "Sent DNS request to %s\n" |
8066 | msgstr "打开日志文件“%sâ€å¤±è´¥ï¼š%s\n" | 8171 | msgstr "打开日志文件“%sâ€å¤±è´¥ï¼š%s\n" |
@@ -8145,83 +8250,83 @@ msgid "" | |||
8145 | "Arguments mandatory for long options are also mandatory for short options.\n" | 8250 | "Arguments mandatory for long options are also mandatory for short options.\n" |
8146 | msgstr "长选项的必选å‚数对çŸé€‰é¡¹ä¹Ÿæ˜¯å¿…选的。\n" | 8251 | msgstr "长选项的必选å‚数对çŸé€‰é¡¹ä¹Ÿæ˜¯å¿…选的。\n" |
8147 | 8252 | ||
8148 | #: src/util/getopt_helpers.c:196 | 8253 | #: src/util/getopt_helpers.c:197 |
8149 | msgid "print this help" | 8254 | msgid "print this help" |
8150 | msgstr "" | 8255 | msgstr "" |
8151 | 8256 | ||
8152 | #: src/util/getopt_helpers.c:261 | 8257 | #: src/util/getopt_helpers.c:262 |
8153 | msgid "be verbose" | 8258 | msgid "be verbose" |
8154 | msgstr "" | 8259 | msgstr "" |
8155 | 8260 | ||
8156 | #: src/util/getopt_helpers.c:377 | 8261 | #: src/util/getopt_helpers.c:378 |
8157 | msgid "configure logging to use LOGLEVEL" | 8262 | msgid "configure logging to use LOGLEVEL" |
8158 | msgstr "" | 8263 | msgstr "" |
8159 | 8264 | ||
8160 | #: src/util/getopt_helpers.c:444 | 8265 | #: src/util/getopt_helpers.c:445 |
8161 | msgid "configure logging to write logs to FILENAME" | 8266 | msgid "configure logging to write logs to FILENAME" |
8162 | msgstr "" | 8267 | msgstr "" |
8163 | 8268 | ||
8164 | #: src/util/getopt_helpers.c:461 | 8269 | #: src/util/getopt_helpers.c:462 |
8165 | #, fuzzy | 8270 | #, fuzzy |
8166 | msgid "use configuration file FILENAME" | 8271 | msgid "use configuration file FILENAME" |
8167 | msgstr "更改é…置文件ä¸çš„一个值" | 8272 | msgstr "更改é…置文件ä¸çš„一个值" |
8168 | 8273 | ||
8169 | #: src/util/getopt_helpers.c:497 src/util/getopt_helpers.c:811 | 8274 | #: src/util/getopt_helpers.c:498 src/util/getopt_helpers.c:812 |
8170 | #: src/util/getopt_helpers.c:867 | 8275 | #: src/util/getopt_helpers.c:868 |
8171 | #, c-format | 8276 | #, c-format |
8172 | msgid "You must pass a number to the `%s' option.\n" | 8277 | msgid "You must pass a number to the `%s' option.\n" |
8173 | msgstr "您必须å‘“%sâ€é€‰é¡¹ä¼ 递一个数å—。\n" | 8278 | msgstr "您必须å‘“%sâ€é€‰é¡¹ä¼ 递一个数å—。\n" |
8174 | 8279 | ||
8175 | #: src/util/getopt_helpers.c:569 | 8280 | #: src/util/getopt_helpers.c:570 |
8176 | #, fuzzy, c-format | 8281 | #, fuzzy, c-format |
8177 | msgid "" | 8282 | msgid "" |
8178 | "You must pass a relative time (optionally with sign) to the `%s' option.\n" | 8283 | "You must pass a relative time (optionally with sign) to the `%s' option.\n" |
8179 | msgstr "您必须å‘“%sâ€é€‰é¡¹ä¼ 递一个数å—。\n" | 8284 | msgstr "您必须å‘“%sâ€é€‰é¡¹ä¼ 递一个数å—。\n" |
8180 | 8285 | ||
8181 | #: src/util/getopt_helpers.c:576 | 8286 | #: src/util/getopt_helpers.c:577 |
8182 | #, c-format | 8287 | #, c-format |
8183 | msgid "Value given for time travel `%s' option is too big.\n" | 8288 | msgid "Value given for time travel `%s' option is too big.\n" |
8184 | msgstr "" | 8289 | msgstr "" |
8185 | 8290 | ||
8186 | #: src/util/getopt_helpers.c:594 | 8291 | #: src/util/getopt_helpers.c:595 |
8187 | msgid "[+/-]MICROSECONDS" | 8292 | msgid "[+/-]MICROSECONDS" |
8188 | msgstr "" | 8293 | msgstr "" |
8189 | 8294 | ||
8190 | #: src/util/getopt_helpers.c:596 | 8295 | #: src/util/getopt_helpers.c:597 |
8191 | msgid "modify system time by given offset (for debugging/testing only)" | 8296 | msgid "modify system time by given offset (for debugging/testing only)" |
8192 | msgstr "" | 8297 | msgstr "" |
8193 | 8298 | ||
8194 | #: src/util/getopt_helpers.c:630 | 8299 | #: src/util/getopt_helpers.c:631 |
8195 | #, fuzzy, c-format | 8300 | #, fuzzy, c-format |
8196 | msgid "You must pass relative time to the `%s' option.\n" | 8301 | msgid "You must pass relative time to the `%s' option.\n" |
8197 | msgstr "您必须å‘“%sâ€é€‰é¡¹ä¼ 递一个数å—。\n" | 8302 | msgstr "您必须å‘“%sâ€é€‰é¡¹ä¼ 递一个数å—。\n" |
8198 | 8303 | ||
8199 | #: src/util/getopt_helpers.c:684 | 8304 | #: src/util/getopt_helpers.c:685 |
8200 | #, fuzzy, c-format | 8305 | #, fuzzy, c-format |
8201 | msgid "You must pass absolute time to the `%s' option.\n" | 8306 | msgid "You must pass absolute time to the `%s' option.\n" |
8202 | msgstr "您必须å‘“%sâ€é€‰é¡¹ä¼ 递一个数å—。\n" | 8307 | msgstr "您必须å‘“%sâ€é€‰é¡¹ä¼ 递一个数å—。\n" |
8203 | 8308 | ||
8204 | #: src/util/getopt_helpers.c:741 | 8309 | #: src/util/getopt_helpers.c:742 |
8205 | #, fuzzy, c-format | 8310 | #, fuzzy, c-format |
8206 | msgid "You must pass a timestamp to the `%s' option.\n" | 8311 | msgid "You must pass a timestamp to the `%s' option.\n" |
8207 | msgstr "您必须å‘“%sâ€é€‰é¡¹ä¼ 递一个数å—。\n" | 8312 | msgstr "您必须å‘“%sâ€é€‰é¡¹ä¼ 递一个数å—。\n" |
8208 | 8313 | ||
8209 | #: src/util/getopt_helpers.c:748 | 8314 | #: src/util/getopt_helpers.c:749 |
8210 | #, c-format | 8315 | #, c-format |
8211 | msgid "The maximum precision allowed for timestamps is seconds.\n" | 8316 | msgid "The maximum precision allowed for timestamps is seconds.\n" |
8212 | msgstr "" | 8317 | msgstr "" |
8213 | 8318 | ||
8214 | #: src/util/getopt_helpers.c:804 | 8319 | #: src/util/getopt_helpers.c:805 |
8215 | #, c-format | 8320 | #, c-format |
8216 | msgid "Your input for the '%s' option has to be a non negative number\n" | 8321 | msgid "Your input for the '%s' option has to be a non negative number\n" |
8217 | msgstr "" | 8322 | msgstr "" |
8218 | 8323 | ||
8219 | #: src/util/getopt_helpers.c:874 | 8324 | #: src/util/getopt_helpers.c:875 |
8220 | #, fuzzy, c-format | 8325 | #, fuzzy, c-format |
8221 | msgid "You must pass a number below %u to the `%s' option.\n" | 8326 | msgid "You must pass a number below %u to the `%s' option.\n" |
8222 | msgstr "您必须å‘“%sâ€é€‰é¡¹ä¼ 递一个数å—。\n" | 8327 | msgstr "您必须å‘“%sâ€é€‰é¡¹ä¼ 递一个数å—。\n" |
8223 | 8328 | ||
8224 | #: src/util/getopt_helpers.c:952 | 8329 | #: src/util/getopt_helpers.c:953 |
8225 | #, c-format | 8330 | #, c-format |
8226 | msgid "Argument `%s' malformed. Expected base32 (Crockford) encoded value.\n" | 8331 | msgid "Argument `%s' malformed. Expected base32 (Crockford) encoded value.\n" |
8227 | msgstr "" | 8332 | msgstr "" |
@@ -8255,7 +8360,7 @@ msgstr "" | |||
8255 | msgid "Manipulate GNUnet configuration files" | 8360 | msgid "Manipulate GNUnet configuration files" |
8256 | msgstr "更改é…置文件ä¸çš„一个值" | 8361 | msgstr "更改é…置文件ä¸çš„一个值" |
8257 | 8362 | ||
8258 | #: src/util/gnunet-crypto-tvg.c:1072 | 8363 | #: src/util/gnunet-crypto-tvg.c:1483 |
8259 | msgid "verify a test vector from stdin" | 8364 | msgid "verify a test vector from stdin" |
8260 | msgstr "" | 8365 | msgstr "" |
8261 | 8366 | ||
@@ -8508,7 +8613,7 @@ msgstr "创建用户出错" | |||
8508 | msgid "Unable to shorten unix path `%s' while keeping name unique\n" | 8613 | msgid "Unable to shorten unix path `%s' while keeping name unique\n" |
8509 | msgstr "" | 8614 | msgstr "" |
8510 | 8615 | ||
8511 | #: src/util/network.c:1306 | 8616 | #: src/util/network.c:1307 |
8512 | #, c-format | 8617 | #, c-format |
8513 | msgid "" | 8618 | msgid "" |
8514 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" | 8619 | "Fatal internal logic error, process hangs in `%s' (abort with CTRL-C)!\n" |
@@ -8636,77 +8741,77 @@ msgstr "" | |||
8636 | msgid "Character sets requested were `%s'->`%s'\n" | 8741 | msgid "Character sets requested were `%s'->`%s'\n" |
8637 | msgstr "" | 8742 | msgstr "" |
8638 | 8743 | ||
8639 | #: src/util/strings.c:487 | 8744 | #: src/util/strings.c:514 |
8640 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" | 8745 | msgid "Failed to expand `$HOME': environment variable `HOME' not set" |
8641 | msgstr "扩展“$HOMEâ€å¤±è´¥ï¼šæ²¡æœ‰è®¾ç½®çŽ¯å¢ƒå˜é‡â€œHOMEâ€" | 8746 | msgstr "扩展“$HOMEâ€å¤±è´¥ï¼šæ²¡æœ‰è®¾ç½®çŽ¯å¢ƒå˜é‡â€œHOMEâ€" |
8642 | 8747 | ||
8643 | #: src/util/strings.c:1023 | 8748 | #: src/util/strings.c:1050 |
8644 | msgid "IPv6 address did not start with `['\n" | 8749 | msgid "IPv6 address did not start with `['\n" |
8645 | msgstr "" | 8750 | msgstr "" |
8646 | 8751 | ||
8647 | #: src/util/strings.c:1031 | 8752 | #: src/util/strings.c:1058 |
8648 | msgid "IPv6 address did contain ':' to separate port number\n" | 8753 | msgid "IPv6 address did contain ':' to separate port number\n" |
8649 | msgstr "" | 8754 | msgstr "" |
8650 | 8755 | ||
8651 | #: src/util/strings.c:1038 | 8756 | #: src/util/strings.c:1065 |
8652 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" | 8757 | msgid "IPv6 address did contain ']' before ':' to separate port number\n" |
8653 | msgstr "" | 8758 | msgstr "" |
8654 | 8759 | ||
8655 | #: src/util/strings.c:1046 | 8760 | #: src/util/strings.c:1073 |
8656 | msgid "IPv6 address did contain a valid port number after the last ':'\n" | 8761 | msgid "IPv6 address did contain a valid port number after the last ':'\n" |
8657 | msgstr "" | 8762 | msgstr "" |
8658 | 8763 | ||
8659 | #: src/util/strings.c:1055 | 8764 | #: src/util/strings.c:1082 |
8660 | #, fuzzy, c-format | 8765 | #, fuzzy, c-format |
8661 | msgid "Invalid IPv6 address `%s': %s\n" | 8766 | msgid "Invalid IPv6 address `%s': %s\n" |
8662 | msgstr "æ— æ•ˆçš„è¿›ç¨‹ä¼˜å…ˆçº§â€œ%sâ€\n" | 8767 | msgstr "æ— æ•ˆçš„è¿›ç¨‹ä¼˜å…ˆçº§â€œ%sâ€\n" |
8663 | 8768 | ||
8664 | #: src/util/strings.c:1237 src/util/strings.c:1248 | 8769 | #: src/util/strings.c:1264 src/util/strings.c:1275 |
8665 | msgid "Port not in range\n" | 8770 | msgid "Port not in range\n" |
8666 | msgstr "" | 8771 | msgstr "" |
8667 | 8772 | ||
8668 | #: src/util/strings.c:1257 | 8773 | #: src/util/strings.c:1284 |
8669 | #, fuzzy, c-format | 8774 | #, fuzzy, c-format |
8670 | msgid "Malformed port policy `%s'\n" | 8775 | msgid "Malformed port policy `%s'\n" |
8671 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" | 8776 | msgstr "解æžé…置文件“%sâ€å¤±è´¥\n" |
8672 | 8777 | ||
8673 | #: src/util/strings.c:1328 src/util/strings.c:1357 src/util/strings.c:1404 | 8778 | #: src/util/strings.c:1355 src/util/strings.c:1384 src/util/strings.c:1431 |
8674 | #: src/util/strings.c:1424 | 8779 | #: src/util/strings.c:1451 |
8675 | #, c-format | 8780 | #, c-format |
8676 | msgid "Invalid format for IP: `%s'\n" | 8781 | msgid "Invalid format for IP: `%s'\n" |
8677 | msgstr "IP æ ¼å¼æ— 效:“%sâ€\n" | 8782 | msgstr "IP æ ¼å¼æ— 效:“%sâ€\n" |
8678 | 8783 | ||
8679 | #: src/util/strings.c:1382 | 8784 | #: src/util/strings.c:1409 |
8680 | #, c-format | 8785 | #, c-format |
8681 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." | 8786 | msgid "Invalid network notation ('/%d' is not legal in IPv4 CIDR)." |
8682 | msgstr "ç½‘ç»œè¡¨ç¤ºæ³•æ— æ•ˆ(“/%d†在 IPv4 CIDR ä¸æ˜¯éžæ³•çš„)。" | 8787 | msgstr "ç½‘ç»œè¡¨ç¤ºæ³•æ— æ•ˆ(“/%d†在 IPv4 CIDR ä¸æ˜¯éžæ³•çš„)。" |
8683 | 8788 | ||
8684 | #: src/util/strings.c:1433 | 8789 | #: src/util/strings.c:1460 |
8685 | #, fuzzy, c-format | 8790 | #, fuzzy, c-format |
8686 | msgid "Invalid format: `%s'\n" | 8791 | msgid "Invalid format: `%s'\n" |
8687 | msgstr "IP æ ¼å¼æ— 效:“%sâ€\n" | 8792 | msgstr "IP æ ¼å¼æ— 效:“%sâ€\n" |
8688 | 8793 | ||
8689 | #: src/util/strings.c:1475 | 8794 | #: src/util/strings.c:1502 |
8690 | #, c-format | 8795 | #, c-format |
8691 | msgid "Invalid network notation (does not end with ';': `%s')\n" | 8796 | msgid "Invalid network notation (does not end with ';': `%s')\n" |
8692 | msgstr "æ— æ•ˆçš„ç½‘ç»œè¡¨ç¤ºæ³•(没有以“;â€ç»“尾:“%sâ€)\n" | 8797 | msgstr "æ— æ•ˆçš„ç½‘ç»œè¡¨ç¤ºæ³•(没有以“;â€ç»“尾:“%sâ€)\n" |
8693 | 8798 | ||
8694 | #: src/util/strings.c:1525 | 8799 | #: src/util/strings.c:1552 |
8695 | #, c-format | 8800 | #, c-format |
8696 | msgid "Wrong format `%s' for netmask\n" | 8801 | msgid "Wrong format `%s' for netmask\n" |
8697 | msgstr "网络掩ç çš„æ ¼å¼â€œ%sâ€é”™è¯¯\n" | 8802 | msgstr "网络掩ç çš„æ ¼å¼â€œ%sâ€é”™è¯¯\n" |
8698 | 8803 | ||
8699 | #: src/util/strings.c:1556 | 8804 | #: src/util/strings.c:1583 |
8700 | #, c-format | 8805 | #, c-format |
8701 | msgid "Wrong format `%s' for network\n" | 8806 | msgid "Wrong format `%s' for network\n" |
8702 | msgstr "ç½‘ç»œçš„æ ¼å¼â€œ%sâ€é”™è¯¯\n" | 8807 | msgstr "ç½‘ç»œçš„æ ¼å¼â€œ%sâ€é”™è¯¯\n" |
8703 | 8808 | ||
8704 | #: src/util/time.c:863 src/util/time.c:891 | 8809 | #: src/util/time.c:870 src/util/time.c:898 |
8705 | #, c-format | 8810 | #, c-format |
8706 | msgid "Failed to map `%s', cannot assure monotonic time!\n" | 8811 | msgid "Failed to map `%s', cannot assure monotonic time!\n" |
8707 | msgstr "" | 8812 | msgstr "" |
8708 | 8813 | ||
8709 | #: src/util/time.c:899 | 8814 | #: src/util/time.c:906 |
8710 | #, c-format | 8815 | #, c-format |
8711 | msgid "" | 8816 | msgid "" |
8712 | "Failed to setup monotonic time file `%s', cannot assure monotonic time!\n" | 8817 | "Failed to setup monotonic time file `%s', cannot assure monotonic time!\n" |
@@ -8882,8 +8987,8 @@ msgstr "" | |||
8882 | msgid "Setup tunnels via VPN." | 8987 | msgid "Setup tunnels via VPN." |
8883 | msgstr "" | 8988 | msgstr "" |
8884 | 8989 | ||
8885 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:418 | 8990 | #: src/zonemaster/gnunet-service-zonemaster-monitor.c:397 |
8886 | #: src/zonemaster/gnunet-service-zonemaster.c:847 | 8991 | #: src/zonemaster/gnunet-service-zonemaster.c:832 |
8887 | #, fuzzy | 8992 | #, fuzzy |
8888 | msgid "Failed to connect to the namestore!\n" | 8993 | msgid "Failed to connect to the namestore!\n" |
8889 | msgstr "åˆå§‹åŒ–“%sâ€æœåŠ¡å¤±è´¥ã€‚\n" | 8994 | msgstr "åˆå§‹åŒ–“%sâ€æœåŠ¡å¤±è´¥ã€‚\n" |
diff --git a/src/ats/ats.conf.in b/src/ats/ats.conf.in index 4abddd99c..2c65869dd 100644 --- a/src/ats/ats.conf.in +++ b/src/ats/ats.conf.in | |||
@@ -15,8 +15,8 @@ MODE = proportional | |||
15 | # IMPORTANT: Do not lower those quotas below 10 MiB | 15 | # IMPORTANT: Do not lower those quotas below 10 MiB |
16 | # Or your peer may not bootstrap correctly. | 16 | # Or your peer may not bootstrap correctly. |
17 | # Network specific inbound/outbound quotas | 17 | # Network specific inbound/outbound quotas |
18 | UNSPECIFIED_QUOTA_IN = 10 MiB | 18 | UNSPECIFIED_QUOTA_IN = unlimited |
19 | UNSPECIFIED_QUOTA_OUT = 10 MiB | 19 | UNSPECIFIED_QUOTA_OUT = unlimited |
20 | # LOOPBACK | 20 | # LOOPBACK |
21 | LOOPBACK_QUOTA_IN = unlimited | 21 | LOOPBACK_QUOTA_IN = unlimited |
22 | LOOPBACK_QUOTA_OUT = unlimited | 22 | LOOPBACK_QUOTA_OUT = unlimited |
@@ -27,8 +27,8 @@ LAN_QUOTA_OUT = unlimited | |||
27 | WAN_QUOTA_IN = 10 MiB | 27 | WAN_QUOTA_IN = 10 MiB |
28 | WAN_QUOTA_OUT = 10 MiB | 28 | WAN_QUOTA_OUT = 10 MiB |
29 | # WLAN | 29 | # WLAN |
30 | WLAN_QUOTA_IN = 10 MiB | 30 | WLAN_QUOTA_IN = unlimited |
31 | WLAN_QUOTA_OUT = 10 MiB | 31 | WLAN_QUOTA_OUT = unlimited |
32 | # BLUETOOTH | 32 | # BLUETOOTH |
33 | BLUETOOTH_QUOTA_IN = 10 MiB | 33 | BLUETOOTH_QUOTA_IN = 10 MiB |
34 | BLUETOOTH_QUOTA_OUT = 10 MiB | 34 | BLUETOOTH_QUOTA_OUT = 10 MiB |
@@ -38,7 +38,7 @@ BLUETOOTH_QUOTA_OUT = 10 MiB | |||
38 | # How proportional to preferences is bandwidth distribution in a network | 38 | # How proportional to preferences is bandwidth distribution in a network |
39 | # 1.0: Fair with respect to addresses without preferences | 39 | # 1.0: Fair with respect to addresses without preferences |
40 | # > 1.0: The bigger, the more respect is paid to preferences | 40 | # > 1.0: The bigger, the more respect is paid to preferences |
41 | PROP_PROPORTIONALITY_FACTOR = 2.00 | 41 | PROP_PROPORTIONALITY_FACTOR = 10.00 |
42 | # Should we stick to existing connections are prefer to switch? | 42 | # Should we stick to existing connections or prefer to switch? |
43 | # [1.0...2.0], lower value prefers to switch, bigger value is more tolerant | 43 | # [1.0...2.0], lower value prefers to switch, bigger value is more tolerant |
44 | PROP_STABILITY_FACTOR = 1.25 | 44 | PROP_STABILITY_FACTOR = 1.25 |
diff --git a/src/ats/gnunet-ats-solver-eval.c b/src/ats/gnunet-ats-solver-eval.c index 25b963532..ba7994686 100644 --- a/src/ats/gnunet-ats-solver-eval.c +++ b/src/ats/gnunet-ats-solver-eval.c | |||
@@ -442,7 +442,7 @@ GNUNET_ATS_solver_logging_write_to_disk (struct LoggingHandle *l, int | |||
442 | } | 442 | } |
443 | } | 443 | } |
444 | 444 | ||
445 | cleanup: | 445 | cleanup: |
446 | next = lf_head; | 446 | next = lf_head; |
447 | for (cur = next; NULL != cur; cur = next) | 447 | for (cur = next; NULL != cur; cur = next) |
448 | { | 448 | { |
@@ -1414,7 +1414,8 @@ load_op_add_address (struct GNUNET_ATS_TEST_Operation *o, | |||
1414 | } | 1414 | } |
1415 | else | 1415 | else |
1416 | { | 1416 | { |
1417 | GNUNET_STRINGS_utf8_toupper (op_network, op_network); | 1417 | GNUNET_break (GNUNET_OK == GNUNET_STRINGS_utf8_toupper (op_network, |
1418 | op_network)); | ||
1418 | if (0 == strcmp (op_network, "UNSPECIFIED")) | 1419 | if (0 == strcmp (op_network, "UNSPECIFIED")) |
1419 | { | 1420 | { |
1420 | o->address_network = GNUNET_NT_UNSPECIFIED; | 1421 | o->address_network = GNUNET_NT_UNSPECIFIED; |
diff --git a/src/block/bg_bf.c b/src/block/bg_bf.c index ae8ee0e51..601f605a2 100644 --- a/src/block/bg_bf.c +++ b/src/block/bg_bf.c | |||
@@ -61,7 +61,7 @@ struct BfGroupInternals | |||
61 | * @return #GNUNET_OK on success, #GNUNET_NO if serialization is not | 61 | * @return #GNUNET_OK on success, #GNUNET_NO if serialization is not |
62 | * supported, #GNUNET_SYSERR on error | 62 | * supported, #GNUNET_SYSERR on error |
63 | */ | 63 | */ |
64 | static int | 64 | static enum GNUNET_GenericReturnValue |
65 | bf_group_serialize_cb (struct GNUNET_BLOCK_Group *bg, | 65 | bf_group_serialize_cb (struct GNUNET_BLOCK_Group *bg, |
66 | uint32_t *nonce, | 66 | uint32_t *nonce, |
67 | void **raw_data, | 67 | void **raw_data, |
@@ -124,7 +124,7 @@ bf_group_mark_seen_cb (struct GNUNET_BLOCK_Group *bg, | |||
124 | * @return #GNUNET_OK on success, #GNUNET_NO if the nonces were different and thus | 124 | * @return #GNUNET_OK on success, #GNUNET_NO if the nonces were different and thus |
125 | * we failed. | 125 | * we failed. |
126 | */ | 126 | */ |
127 | static int | 127 | static enum GNUNET_GenericReturnValue |
128 | bf_group_merge_cb (struct GNUNET_BLOCK_Group *bg1, | 128 | bf_group_merge_cb (struct GNUNET_BLOCK_Group *bg1, |
129 | const struct GNUNET_BLOCK_Group *bg2) | 129 | const struct GNUNET_BLOCK_Group *bg2) |
130 | { | 130 | { |
diff --git a/src/block/block.c b/src/block/block.c index 5824946f7..2e3c1dc70 100644 --- a/src/block/block.c +++ b/src/block/block.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet. | 2 | This file is part of GNUnet. |
3 | Copyright (C) 2010, 2017, 2021 GNUnet e.V. | 3 | Copyright (C) 2010, 2017, 2021, 2022 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 |
@@ -255,35 +255,6 @@ GNUNET_BLOCK_group_create (struct GNUNET_BLOCK_Context *ctx, | |||
255 | } | 255 | } |
256 | 256 | ||
257 | 257 | ||
258 | enum GNUNET_BLOCK_EvaluationResult | ||
259 | GNUNET_BLOCK_evaluate (struct GNUNET_BLOCK_Context *ctx, | ||
260 | enum GNUNET_BLOCK_Type type, | ||
261 | struct GNUNET_BLOCK_Group *group, | ||
262 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
263 | const struct GNUNET_HashCode *query, | ||
264 | const void *xquery, | ||
265 | size_t xquery_size, | ||
266 | const void *reply_block, | ||
267 | size_t reply_block_size) | ||
268 | { | ||
269 | struct GNUNET_BLOCK_PluginFunctions *plugin = find_plugin (ctx, | ||
270 | type); | ||
271 | |||
272 | if (NULL == plugin) | ||
273 | return GNUNET_BLOCK_EVALUATION_TYPE_NOT_SUPPORTED; | ||
274 | return plugin->evaluate (plugin->cls, | ||
275 | ctx, | ||
276 | type, | ||
277 | group, | ||
278 | eo, | ||
279 | query, | ||
280 | xquery, | ||
281 | xquery_size, | ||
282 | reply_block, | ||
283 | reply_block_size); | ||
284 | } | ||
285 | |||
286 | |||
287 | enum GNUNET_GenericReturnValue | 258 | enum GNUNET_GenericReturnValue |
288 | GNUNET_BLOCK_get_key (struct GNUNET_BLOCK_Context *ctx, | 259 | GNUNET_BLOCK_get_key (struct GNUNET_BLOCK_Context *ctx, |
289 | enum GNUNET_BLOCK_Type type, | 260 | enum GNUNET_BLOCK_Type type, |
@@ -327,7 +298,6 @@ GNUNET_BLOCK_check_query (struct GNUNET_BLOCK_Context *ctx, | |||
327 | enum GNUNET_GenericReturnValue | 298 | enum GNUNET_GenericReturnValue |
328 | GNUNET_BLOCK_check_block (struct GNUNET_BLOCK_Context *ctx, | 299 | GNUNET_BLOCK_check_block (struct GNUNET_BLOCK_Context *ctx, |
329 | enum GNUNET_BLOCK_Type type, | 300 | enum GNUNET_BLOCK_Type type, |
330 | const struct GNUNET_HashCode *query, | ||
331 | const void *block, | 301 | const void *block, |
332 | size_t block_size) | 302 | size_t block_size) |
333 | { | 303 | { |
@@ -338,7 +308,6 @@ GNUNET_BLOCK_check_block (struct GNUNET_BLOCK_Context *ctx, | |||
338 | return GNUNET_SYSERR; | 308 | return GNUNET_SYSERR; |
339 | return plugin->check_block (plugin->cls, | 309 | return plugin->check_block (plugin->cls, |
340 | type, | 310 | type, |
341 | query, | ||
342 | block, | 311 | block, |
343 | block_size); | 312 | block_size); |
344 | } | 313 | } |
diff --git a/src/block/plugin_block_template.c b/src/block/plugin_block_template.c index 13d9adfda..dcaf1afaa 100644 --- a/src/block/plugin_block_template.c +++ b/src/block/plugin_block_template.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet | 2 | This file is part of GNUnet |
3 | Copyright (C) 2010 GNUnet e.V. | 3 | Copyright (C) 2010, 2021, 2022 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 |
@@ -92,49 +92,6 @@ block_plugin_template_create_group (void *cls, | |||
92 | 92 | ||
93 | 93 | ||
94 | /** | 94 | /** |
95 | * Function called to validate a reply or a request. For | ||
96 | * request evaluation, simply pass "NULL" for the reply_block. | ||
97 | * | ||
98 | * @param cls closure | ||
99 | * @param ctx context | ||
100 | * @param type block type | ||
101 | * @param group block group to use | ||
102 | * @param eo control flags | ||
103 | * @param query original query (hash) | ||
104 | * @param xquery extrended query data (can be NULL, depending on type) | ||
105 | * @param xquery_size number of bytes in xquery | ||
106 | * @param reply_block response to validate | ||
107 | * @param reply_block_size number of bytes in reply block | ||
108 | * @return characterization of result | ||
109 | */ | ||
110 | static enum GNUNET_BLOCK_EvaluationResult | ||
111 | block_plugin_template_evaluate (void *cls, | ||
112 | struct GNUNET_BLOCK_Context *ctx, | ||
113 | enum GNUNET_BLOCK_Type type, | ||
114 | struct GNUNET_BLOCK_Group *group, | ||
115 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
116 | const struct GNUNET_HashCode *query, | ||
117 | const void *xquery, | ||
118 | size_t xquery_size, | ||
119 | const void *reply_block, | ||
120 | size_t reply_block_size) | ||
121 | { | ||
122 | struct GNUNET_HashCode chash; | ||
123 | |||
124 | if (NULL == reply_block) | ||
125 | return GNUNET_BLOCK_EVALUATION_REQUEST_VALID; | ||
126 | GNUNET_CRYPTO_hash (reply_block, | ||
127 | reply_block_size, | ||
128 | &chash); | ||
129 | if (GNUNET_YES == | ||
130 | GNUNET_BLOCK_GROUP_bf_test_and_set (group, | ||
131 | &chash)) | ||
132 | return GNUNET_BLOCK_EVALUATION_OK_DUPLICATE; | ||
133 | return GNUNET_BLOCK_EVALUATION_TYPE_NOT_SUPPORTED; | ||
134 | } | ||
135 | |||
136 | |||
137 | /** | ||
138 | * Function called to validate a query. | 95 | * Function called to validate a query. |
139 | * | 96 | * |
140 | * @param cls closure | 97 | * @param cls closure |
@@ -143,16 +100,16 @@ block_plugin_template_evaluate (void *cls, | |||
143 | * @param query original query (hash) | 100 | * @param query original query (hash) |
144 | * @param xquery extrended query data (can be NULL, depending on type) | 101 | * @param xquery extrended query data (can be NULL, depending on type) |
145 | * @param xquery_size number of bytes in @a xquery | 102 | * @param xquery_size number of bytes in @a xquery |
146 | * @return #GNUNET_OK if the query is fine, #GNUNET_NO if not | 103 | * @return #GNUNET_OK if the query is fine, #GNUNET_NO if not, #GNUNET_SYSERR if not supported |
147 | */ | 104 | */ |
148 | static enum GNUNET_GenericReturnValue | 105 | static enum GNUNET_GenericReturnValue |
149 | block_plugin_template_check_query (void *cls, | 106 | block_plugin_template_check_query (void *cls, |
150 | enum GNUNET_BLOCK_Type type, | 107 | enum GNUNET_BLOCK_Type type, |
151 | const struct GNUNET_HashCode *query, | 108 | const struct GNUNET_HashCode *query, |
152 | const void *xquery, | 109 | const void *xquery, |
153 | size_t xquery_size) | 110 | size_t xquery_size) |
154 | { | 111 | { |
155 | return GNUNET_OK; | 112 | return GNUNET_SYSERR; |
156 | } | 113 | } |
157 | 114 | ||
158 | 115 | ||
@@ -161,19 +118,17 @@ block_plugin_template_check_query (void *cls, | |||
161 | * | 118 | * |
162 | * @param cls closure | 119 | * @param cls closure |
163 | * @param type block type | 120 | * @param type block type |
164 | * @param query key for the block (hash), must match exactly | ||
165 | * @param block block data to validate | 121 | * @param block block data to validate |
166 | * @param block_size number of bytes in @a block | 122 | * @param block_size number of bytes in @a block |
167 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not | 123 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not, #GNUNET_SYSERR if not supported |
168 | */ | 124 | */ |
169 | static enum GNUNET_GenericReturnValue | 125 | static enum GNUNET_GenericReturnValue |
170 | block_plugin_template_check_block (void *cls, | 126 | block_plugin_template_check_block (void *cls, |
171 | enum GNUNET_BLOCK_Type type, | 127 | enum GNUNET_BLOCK_Type type, |
172 | const struct GNUNET_HashCode *query, | ||
173 | const void *block, | 128 | const void *block, |
174 | size_t block_size) | 129 | size_t block_size) |
175 | { | 130 | { |
176 | return GNUNET_OK; | 131 | return GNUNET_SYSERR; |
177 | } | 132 | } |
178 | 133 | ||
179 | 134 | ||
@@ -195,16 +150,16 @@ block_plugin_template_check_block (void *cls, | |||
195 | */ | 150 | */ |
196 | static enum GNUNET_BLOCK_ReplyEvaluationResult | 151 | static enum GNUNET_BLOCK_ReplyEvaluationResult |
197 | block_plugin_template_check_reply ( | 152 | block_plugin_template_check_reply ( |
198 | void *cls, | 153 | void *cls, |
199 | enum GNUNET_BLOCK_Type type, | 154 | enum GNUNET_BLOCK_Type type, |
200 | struct GNUNET_BLOCK_Group *group, | 155 | struct GNUNET_BLOCK_Group *group, |
201 | const struct GNUNET_HashCode *query, | 156 | const struct GNUNET_HashCode *query, |
202 | const void *xquery, | 157 | const void *xquery, |
203 | size_t xquery_size, | 158 | size_t xquery_size, |
204 | const void *reply_block, | 159 | const void *reply_block, |
205 | size_t reply_block_size) | 160 | size_t reply_block_size) |
206 | { | 161 | { |
207 | return GNUNET_BLOCK_REPLY_OK_MORE; | 162 | return GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED; |
208 | } | 163 | } |
209 | 164 | ||
210 | 165 | ||
@@ -245,7 +200,6 @@ libgnunet_plugin_block_template_init (void *cls) | |||
245 | struct GNUNET_BLOCK_PluginFunctions *api; | 200 | struct GNUNET_BLOCK_PluginFunctions *api; |
246 | 201 | ||
247 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); | 202 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); |
248 | api->evaluate = &block_plugin_template_evaluate; | ||
249 | api->get_key = &block_plugin_template_get_key; | 203 | api->get_key = &block_plugin_template_get_key; |
250 | api->check_query = &block_plugin_template_check_query; | 204 | api->check_query = &block_plugin_template_check_query; |
251 | api->check_block = &block_plugin_template_check_block; | 205 | api->check_block = &block_plugin_template_check_block; |
diff --git a/src/block/plugin_block_test.c b/src/block/plugin_block_test.c index fd643c4dc..05d379387 100644 --- a/src/block/plugin_block_test.c +++ b/src/block/plugin_block_test.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet | 2 | This file is part of GNUnet |
3 | Copyright (C) 2010 GNUnet e.V. | 3 | Copyright (C) 2010, 2021, 2022 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 |
@@ -90,59 +90,6 @@ block_plugin_test_create_group (void *cls, | |||
90 | 90 | ||
91 | 91 | ||
92 | /** | 92 | /** |
93 | * Function called to validate a reply or a request. For | ||
94 | * request evaluation, simply pass "NULL" for the reply_block. | ||
95 | * | ||
96 | * @param cls closure | ||
97 | * @param ctx block context | ||
98 | * @param type block type | ||
99 | * @param group group to check against | ||
100 | * @param eo control flags | ||
101 | * @param query original query (hash) | ||
102 | * @param xquery extrended query data (can be NULL, depending on type) | ||
103 | * @param xquery_size number of bytes in @a xquery | ||
104 | * @param reply_block response to validate | ||
105 | * @param reply_block_size number of bytes in @a reply_block | ||
106 | * @return characterization of result | ||
107 | */ | ||
108 | static enum GNUNET_BLOCK_EvaluationResult | ||
109 | block_plugin_test_evaluate (void *cls, | ||
110 | struct GNUNET_BLOCK_Context *ctx, | ||
111 | enum GNUNET_BLOCK_Type type, | ||
112 | struct GNUNET_BLOCK_Group *group, | ||
113 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
114 | const struct GNUNET_HashCode *query, | ||
115 | const void *xquery, | ||
116 | size_t xquery_size, | ||
117 | const void *reply_block, | ||
118 | size_t reply_block_size) | ||
119 | { | ||
120 | struct GNUNET_HashCode chash; | ||
121 | |||
122 | if (GNUNET_BLOCK_TYPE_TEST != type) | ||
123 | { | ||
124 | GNUNET_break (0); | ||
125 | return GNUNET_BLOCK_EVALUATION_TYPE_NOT_SUPPORTED; | ||
126 | } | ||
127 | if (0 != xquery_size) | ||
128 | { | ||
129 | GNUNET_break_op (0); | ||
130 | return GNUNET_BLOCK_EVALUATION_REQUEST_INVALID; | ||
131 | } | ||
132 | if (NULL == reply_block) | ||
133 | return GNUNET_BLOCK_EVALUATION_REQUEST_VALID; | ||
134 | GNUNET_CRYPTO_hash (reply_block, | ||
135 | reply_block_size, | ||
136 | &chash); | ||
137 | if (GNUNET_YES == | ||
138 | GNUNET_BLOCK_GROUP_bf_test_and_set (group, | ||
139 | &chash)) | ||
140 | return GNUNET_BLOCK_EVALUATION_OK_DUPLICATE; | ||
141 | return GNUNET_BLOCK_EVALUATION_OK_MORE; | ||
142 | } | ||
143 | |||
144 | |||
145 | /** | ||
146 | * Function called to validate a query. | 93 | * Function called to validate a query. |
147 | * | 94 | * |
148 | * @param cls closure | 95 | * @param cls closure |
@@ -151,15 +98,18 @@ block_plugin_test_evaluate (void *cls, | |||
151 | * @param query original query (hash) | 98 | * @param query original query (hash) |
152 | * @param xquery extrended query data (can be NULL, depending on type) | 99 | * @param xquery extrended query data (can be NULL, depending on type) |
153 | * @param xquery_size number of bytes in @a xquery | 100 | * @param xquery_size number of bytes in @a xquery |
154 | * @return #GNUNET_OK if the query is fine, #GNUNET_NO if not | 101 | * @return #GNUNET_OK if the query is fine, #GNUNET_NO if not, #GNUNET_SYSERR if @a type is not supported |
155 | */ | 102 | */ |
156 | static enum GNUNET_GenericReturnValue | 103 | static enum GNUNET_GenericReturnValue |
157 | block_plugin_test_check_query (void *cls, | 104 | block_plugin_test_check_query (void *cls, |
158 | enum GNUNET_BLOCK_Type type, | 105 | enum GNUNET_BLOCK_Type type, |
159 | const struct GNUNET_HashCode *query, | 106 | const struct GNUNET_HashCode *query, |
160 | const void *xquery, | 107 | const void *xquery, |
161 | size_t xquery_size) | 108 | size_t xquery_size) |
162 | { | 109 | { |
110 | (void) cls; | ||
111 | (void) query; | ||
112 | (void) xquery; | ||
163 | if (GNUNET_BLOCK_TYPE_TEST != type) | 113 | if (GNUNET_BLOCK_TYPE_TEST != type) |
164 | { | 114 | { |
165 | GNUNET_break (0); | 115 | GNUNET_break (0); |
@@ -168,9 +118,9 @@ block_plugin_test_check_query (void *cls, | |||
168 | if (0 != xquery_size) | 118 | if (0 != xquery_size) |
169 | { | 119 | { |
170 | GNUNET_break_op (0); | 120 | GNUNET_break_op (0); |
171 | return GNUNET_SYSERR; | 121 | return GNUNET_NO; |
172 | } | 122 | } |
173 | return GNUNET_BLOCK_EVALUATION_REQUEST_VALID; | 123 | return GNUNET_OK; |
174 | } | 124 | } |
175 | 125 | ||
176 | 126 | ||
@@ -179,18 +129,19 @@ block_plugin_test_check_query (void *cls, | |||
179 | * | 129 | * |
180 | * @param cls closure | 130 | * @param cls closure |
181 | * @param type block type | 131 | * @param type block type |
182 | * @param query key for the block (hash), must match exactly | ||
183 | * @param block block data to validate | 132 | * @param block block data to validate |
184 | * @param block_size number of bytes in @a block | 133 | * @param block_size number of bytes in @a block |
185 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not | 134 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not, #GNUNET_SYSERR if @a type is not supported |
186 | */ | 135 | */ |
187 | static enum GNUNET_GenericReturnValue | 136 | static enum GNUNET_GenericReturnValue |
188 | block_plugin_test_check_block (void *cls, | 137 | block_plugin_test_check_block (void *cls, |
189 | enum GNUNET_BLOCK_Type type, | 138 | enum GNUNET_BLOCK_Type type, |
190 | const struct GNUNET_HashCode *query, | 139 | const void *block, |
191 | const void *block, | 140 | size_t block_size) |
192 | size_t block_size) | ||
193 | { | 141 | { |
142 | (void) cls; | ||
143 | (void) block; | ||
144 | (void) block_size; | ||
194 | if (GNUNET_BLOCK_TYPE_TEST != type) | 145 | if (GNUNET_BLOCK_TYPE_TEST != type) |
195 | { | 146 | { |
196 | GNUNET_break (0); | 147 | GNUNET_break (0); |
@@ -218,16 +169,20 @@ block_plugin_test_check_block (void *cls, | |||
218 | */ | 169 | */ |
219 | static enum GNUNET_BLOCK_ReplyEvaluationResult | 170 | static enum GNUNET_BLOCK_ReplyEvaluationResult |
220 | block_plugin_test_check_reply (void *cls, | 171 | block_plugin_test_check_reply (void *cls, |
221 | enum GNUNET_BLOCK_Type type, | 172 | enum GNUNET_BLOCK_Type type, |
222 | struct GNUNET_BLOCK_Group *group, | 173 | struct GNUNET_BLOCK_Group *group, |
223 | const struct GNUNET_HashCode *query, | 174 | const struct GNUNET_HashCode *query, |
224 | const void *xquery, | 175 | const void *xquery, |
225 | size_t xquery_size, | 176 | size_t xquery_size, |
226 | const void *reply_block, | 177 | const void *reply_block, |
227 | size_t reply_block_size) | 178 | size_t reply_block_size) |
228 | { | 179 | { |
229 | struct GNUNET_HashCode chash; | 180 | struct GNUNET_HashCode chash; |
230 | 181 | ||
182 | (void) cls; | ||
183 | (void) query; | ||
184 | (void) xquery; | ||
185 | (void) xquery_size; | ||
231 | if (GNUNET_BLOCK_TYPE_TEST != type) | 186 | if (GNUNET_BLOCK_TYPE_TEST != type) |
232 | { | 187 | { |
233 | GNUNET_break (0); | 188 | GNUNET_break (0); |
@@ -252,8 +207,7 @@ block_plugin_test_check_reply (void *cls, | |||
252 | * @param block block to get the key for | 207 | * @param block block to get the key for |
253 | * @param block_size number of bytes in @a block | 208 | * @param block_size number of bytes in @a block |
254 | * @param key set to the key (query) for the given block | 209 | * @param key set to the key (query) for the given block |
255 | * @return #GNUNET_OK on success, #GNUNET_SYSERR if type not supported | 210 | * @return #GNUNET_OK on success, #GNUNET_SYSERR if type not supported, #GNUNET_NO if extracting a key from a block of this type does not work |
256 | * (or if extracting a key from a block of this type does not work) | ||
257 | */ | 211 | */ |
258 | static enum GNUNET_GenericReturnValue | 212 | static enum GNUNET_GenericReturnValue |
259 | block_plugin_test_get_key (void *cls, | 213 | block_plugin_test_get_key (void *cls, |
@@ -262,9 +216,16 @@ block_plugin_test_get_key (void *cls, | |||
262 | size_t block_size, | 216 | size_t block_size, |
263 | struct GNUNET_HashCode *key) | 217 | struct GNUNET_HashCode *key) |
264 | { | 218 | { |
265 | /* always fails since there is no fixed relationship between | 219 | (void) cls; |
266 | * keys and values for test values */ | 220 | (void) block; |
267 | return GNUNET_SYSERR; | 221 | (void) block_size; |
222 | (void) key; | ||
223 | if (GNUNET_BLOCK_TYPE_TEST != type) | ||
224 | { | ||
225 | GNUNET_break (0); | ||
226 | return GNUNET_SYSERR; | ||
227 | } | ||
228 | return GNUNET_NO; | ||
268 | } | 229 | } |
269 | 230 | ||
270 | 231 | ||
@@ -284,7 +245,6 @@ libgnunet_plugin_block_test_init (void *cls) | |||
284 | struct GNUNET_BLOCK_PluginFunctions *api; | 245 | struct GNUNET_BLOCK_PluginFunctions *api; |
285 | 246 | ||
286 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); | 247 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); |
287 | api->evaluate = &block_plugin_test_evaluate; | ||
288 | api->get_key = &block_plugin_test_get_key; | 248 | api->get_key = &block_plugin_test_get_key; |
289 | api->check_query = &block_plugin_test_check_query; | 249 | api->check_query = &block_plugin_test_check_query; |
290 | api->check_block = &block_plugin_test_check_block; | 250 | api->check_block = &block_plugin_test_check_block; |
diff --git a/src/consensus/plugin_block_consensus.c b/src/consensus/plugin_block_consensus.c index 430a2c0cb..f30b9b0d7 100644 --- a/src/consensus/plugin_block_consensus.c +++ b/src/consensus/plugin_block_consensus.c | |||
@@ -47,57 +47,6 @@ struct BlockContext | |||
47 | }; | 47 | }; |
48 | 48 | ||
49 | 49 | ||
50 | /** | ||
51 | * Function called to validate a reply or a request. For | ||
52 | * request evaluation, simply pass "NULL" for the reply_block. | ||
53 | * | ||
54 | * @param cls closure | ||
55 | * @param ctx context | ||
56 | * @param type block type | ||
57 | * @param group block group to use | ||
58 | * @param eo control flags | ||
59 | * @param query original query (hash) | ||
60 | * @param xquery extrended query data (can be NULL, depending on type) | ||
61 | * @param xquery_size number of bytes in xquery | ||
62 | * @param reply_block response to validate | ||
63 | * @param reply_block_size number of bytes in reply block | ||
64 | * @return characterization of result | ||
65 | */ | ||
66 | static enum GNUNET_BLOCK_EvaluationResult | ||
67 | block_plugin_consensus_evaluate (void *cls, | ||
68 | struct GNUNET_BLOCK_Context *ctx, | ||
69 | enum GNUNET_BLOCK_Type type, | ||
70 | struct GNUNET_BLOCK_Group *group, | ||
71 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
72 | const struct GNUNET_HashCode *query, | ||
73 | const void *xquery, | ||
74 | size_t xquery_size, | ||
75 | const void *reply_block, | ||
76 | size_t reply_block_size) | ||
77 | { | ||
78 | struct BlockContext *bctx = cls; | ||
79 | const struct ConsensusElement *ce = reply_block; | ||
80 | |||
81 | if (reply_block_size < sizeof(struct ConsensusElement)) | ||
82 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
83 | if ( (0 != ce->marker) || | ||
84 | (0 == ce->payload_type) ) | ||
85 | return GNUNET_BLOCK_EVALUATION_OK_MORE; | ||
86 | |||
87 | if (NULL == bctx->bc) | ||
88 | bctx->bc = GNUNET_BLOCK_context_create (bctx->cfg); | ||
89 | return GNUNET_BLOCK_evaluate (bctx->bc, | ||
90 | type, | ||
91 | group, | ||
92 | eo, | ||
93 | query, | ||
94 | xquery, | ||
95 | xquery_size, | ||
96 | &ce[1], | ||
97 | reply_block_size | ||
98 | - sizeof(struct ConsensusElement)); | ||
99 | } | ||
100 | |||
101 | 50 | ||
102 | /** | 51 | /** |
103 | * Function called to validate a query. | 52 | * Function called to validate a query. |
@@ -128,7 +77,6 @@ block_plugin_consensus_check_query (void *cls, | |||
128 | * | 77 | * |
129 | * @param cls closure | 78 | * @param cls closure |
130 | * @param type block type | 79 | * @param type block type |
131 | * @param query key for the block (hash), must match exactly | ||
132 | * @param block block data to validate | 80 | * @param block block data to validate |
133 | * @param block_size number of bytes in @a block | 81 | * @param block_size number of bytes in @a block |
134 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not | 82 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not |
@@ -136,7 +84,6 @@ block_plugin_consensus_check_query (void *cls, | |||
136 | static enum GNUNET_GenericReturnValue | 84 | static enum GNUNET_GenericReturnValue |
137 | block_plugin_consensus_check_block (void *cls, | 85 | block_plugin_consensus_check_block (void *cls, |
138 | enum GNUNET_BLOCK_Type type, | 86 | enum GNUNET_BLOCK_Type type, |
139 | const struct GNUNET_HashCode *query, | ||
140 | const void *block, | 87 | const void *block, |
141 | size_t block_size) | 88 | size_t block_size) |
142 | { | 89 | { |
@@ -144,7 +91,10 @@ block_plugin_consensus_check_block (void *cls, | |||
144 | const struct ConsensusElement *ce = block; | 91 | const struct ConsensusElement *ce = block; |
145 | 92 | ||
146 | if (block_size < sizeof(*ce)) | 93 | if (block_size < sizeof(*ce)) |
94 | { | ||
95 | GNUNET_break_op (0); | ||
147 | return GNUNET_NO; | 96 | return GNUNET_NO; |
97 | } | ||
148 | if ( (0 != ce->marker) || | 98 | if ( (0 != ce->marker) || |
149 | (0 == ce->payload_type) ) | 99 | (0 == ce->payload_type) ) |
150 | return GNUNET_OK; | 100 | return GNUNET_OK; |
@@ -152,7 +102,6 @@ block_plugin_consensus_check_block (void *cls, | |||
152 | ctx->bc = GNUNET_BLOCK_context_create (ctx->cfg); | 102 | ctx->bc = GNUNET_BLOCK_context_create (ctx->cfg); |
153 | return GNUNET_BLOCK_check_block (ctx->bc, | 103 | return GNUNET_BLOCK_check_block (ctx->bc, |
154 | ntohl (ce->payload_type), | 104 | ntohl (ce->payload_type), |
155 | query, | ||
156 | &ce[1], | 105 | &ce[1], |
157 | block_size - sizeof(*ce)); | 106 | block_size - sizeof(*ce)); |
158 | } | 107 | } |
@@ -188,8 +137,7 @@ block_plugin_consensus_check_reply ( | |||
188 | struct BlockContext *ctx = cls; | 137 | struct BlockContext *ctx = cls; |
189 | const struct ConsensusElement *ce = reply_block; | 138 | const struct ConsensusElement *ce = reply_block; |
190 | 139 | ||
191 | if (reply_block_size < sizeof(struct ConsensusElement)) | 140 | GNUNET_assert (reply_block_size >= sizeof(struct ConsensusElement)); |
192 | return GNUNET_NO; | ||
193 | if ( (0 != ce->marker) || | 141 | if ( (0 != ce->marker) || |
194 | (0 == ce->payload_type) ) | 142 | (0 == ce->payload_type) ) |
195 | return GNUNET_BLOCK_REPLY_OK_MORE; | 143 | return GNUNET_BLOCK_REPLY_OK_MORE; |
@@ -246,7 +194,6 @@ libgnunet_plugin_block_consensus_init (void *cls) | |||
246 | ctx->cfg = cfg; | 194 | ctx->cfg = cfg; |
247 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); | 195 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); |
248 | api->cls = ctx; | 196 | api->cls = ctx; |
249 | api->evaluate = &block_plugin_consensus_evaluate; | ||
250 | api->get_key = &block_plugin_consensus_get_key; | 197 | api->get_key = &block_plugin_consensus_get_key; |
251 | api->check_query = &block_plugin_consensus_check_query; | 198 | api->check_query = &block_plugin_consensus_check_query; |
252 | api->check_block = &block_plugin_consensus_check_block; | 199 | api->check_block = &block_plugin_consensus_check_block; |
diff --git a/src/consensus/test_consensus.conf b/src/consensus/test_consensus.conf index 67b366405..df7fb6861 100644 --- a/src/consensus/test_consensus.conf +++ b/src/consensus/test_consensus.conf | |||
@@ -3,7 +3,7 @@ GNUNET_TEST_HOME = $GNUNET_TMP/test-consensus/ | |||
3 | 3 | ||
4 | [consensus] | 4 | [consensus] |
5 | #OPTIONS = -L INFO | 5 | #OPTIONS = -L INFO |
6 | BINARY = gnunet-service-evil-consensus | 6 | BINARY = gnunet-service-consensus |
7 | 7 | ||
8 | #PREFIX = valgrind | 8 | #PREFIX = valgrind |
9 | 9 | ||
diff --git a/src/datacache/datacache.c b/src/datacache/datacache.c index 944a99aad..761ab801f 100644 --- a/src/datacache/datacache.c +++ b/src/datacache/datacache.c | |||
@@ -114,11 +114,11 @@ env_delete_notify (void *cls, | |||
114 | h->utilization -= size; | 114 | h->utilization -= size; |
115 | GNUNET_CONTAINER_bloomfilter_remove (h->filter, key); | 115 | GNUNET_CONTAINER_bloomfilter_remove (h->filter, key); |
116 | GNUNET_STATISTICS_update (h->stats, | 116 | GNUNET_STATISTICS_update (h->stats, |
117 | gettext_noop ("# bytes stored"), | 117 | "# bytes stored", |
118 | -(long long) size, | 118 | -(long long) size, |
119 | GNUNET_NO); | 119 | GNUNET_NO); |
120 | GNUNET_STATISTICS_update (h->stats, | 120 | GNUNET_STATISTICS_update (h->stats, |
121 | gettext_noop ("# items stored"), | 121 | "# items stored", |
122 | -1, | 122 | -1, |
123 | GNUNET_NO); | 123 | GNUNET_NO); |
124 | } | 124 | } |
@@ -136,15 +136,25 @@ GNUNET_DATACACHE_create (const struct GNUNET_CONFIGURATION_Handle *cfg, | |||
136 | const struct GNUNET_OS_ProjectData *pd; | 136 | const struct GNUNET_OS_ProjectData *pd; |
137 | 137 | ||
138 | if (GNUNET_OK != | 138 | if (GNUNET_OK != |
139 | GNUNET_CONFIGURATION_get_value_size (cfg, section, "QUOTA", "a)) | 139 | GNUNET_CONFIGURATION_get_value_size (cfg, |
140 | section, | ||
141 | "QUOTA", | ||
142 | "a)) | ||
140 | { | 143 | { |
141 | GNUNET_log_config_missing (GNUNET_ERROR_TYPE_ERROR, section, "QUOTA"); | 144 | GNUNET_log_config_missing (GNUNET_ERROR_TYPE_ERROR, |
145 | section, | ||
146 | "QUOTA"); | ||
142 | return NULL; | 147 | return NULL; |
143 | } | 148 | } |
144 | if (GNUNET_OK != | 149 | if (GNUNET_OK != |
145 | GNUNET_CONFIGURATION_get_value_string (cfg, section, "DATABASE", &name)) | 150 | GNUNET_CONFIGURATION_get_value_string (cfg, |
151 | section, | ||
152 | "DATABASE", | ||
153 | &name)) | ||
146 | { | 154 | { |
147 | GNUNET_log_config_missing (GNUNET_ERROR_TYPE_ERROR, section, "DATABASE"); | 155 | GNUNET_log_config_missing (GNUNET_ERROR_TYPE_ERROR, |
156 | section, | ||
157 | "DATABASE"); | ||
148 | return NULL; | 158 | return NULL; |
149 | } | 159 | } |
150 | bf_size = quota / 32; /* 8 bit per entry, 1 bit per 32 kb in DB */ | 160 | bf_size = quota / 32; /* 8 bit per entry, 1 bit per 32 kb in DB */ |
@@ -152,10 +162,14 @@ GNUNET_DATACACHE_create (const struct GNUNET_CONFIGURATION_Handle *cfg, | |||
152 | ret = GNUNET_new (struct GNUNET_DATACACHE_Handle); | 162 | ret = GNUNET_new (struct GNUNET_DATACACHE_Handle); |
153 | 163 | ||
154 | if (GNUNET_YES != | 164 | if (GNUNET_YES != |
155 | GNUNET_CONFIGURATION_get_value_yesno (cfg, section, "DISABLE_BF")) | 165 | GNUNET_CONFIGURATION_get_value_yesno (cfg, |
166 | section, | ||
167 | "DISABLE_BF")) | ||
156 | { | 168 | { |
157 | if (GNUNET_YES != | 169 | if (GNUNET_YES != |
158 | GNUNET_CONFIGURATION_get_value_yesno (cfg, section, "DISABLE_BF_RC")) | 170 | GNUNET_CONFIGURATION_get_value_yesno (cfg, |
171 | section, | ||
172 | "DISABLE_BF_RC")) | ||
159 | { | 173 | { |
160 | ret->bloom_name = GNUNET_DISK_mktemp ("gnunet-datacachebloom"); | 174 | ret->bloom_name = GNUNET_DISK_mktemp ("gnunet-datacachebloom"); |
161 | } | 175 | } |
@@ -174,7 +188,8 @@ GNUNET_DATACACHE_create (const struct GNUNET_CONFIGURATION_Handle *cfg, | |||
174 | 5); /* approx. 3% false positives at max use */ | 188 | 5); /* approx. 3% false positives at max use */ |
175 | } | 189 | } |
176 | } | 190 | } |
177 | ret->stats = GNUNET_STATISTICS_create ("datacache", cfg); | 191 | ret->stats = GNUNET_STATISTICS_create ("datacache", |
192 | cfg); | ||
178 | ret->section = GNUNET_strdup (section); | 193 | ret->section = GNUNET_strdup (section); |
179 | ret->env.cfg = cfg; | 194 | ret->env.cfg = cfg; |
180 | ret->env.delete_notify = &env_delete_notify; | 195 | ret->env.delete_notify = &env_delete_notify; |
@@ -182,25 +197,31 @@ GNUNET_DATACACHE_create (const struct GNUNET_CONFIGURATION_Handle *cfg, | |||
182 | ret->env.cls = ret; | 197 | ret->env.cls = ret; |
183 | ret->env.delete_notify = &env_delete_notify; | 198 | ret->env.delete_notify = &env_delete_notify; |
184 | ret->env.quota = quota; | 199 | ret->env.quota = quota; |
185 | LOG (GNUNET_ERROR_TYPE_INFO, _ ("Loading `%s' datacache plugin\n"), name); | 200 | LOG (GNUNET_ERROR_TYPE_INFO, |
186 | GNUNET_asprintf (&libname, "libgnunet_plugin_datacache_%s", name); | 201 | "Loading `%s' datacache plugin\n", |
202 | name); | ||
203 | GNUNET_asprintf (&libname, | ||
204 | "libgnunet_plugin_datacache_%s", | ||
205 | name); | ||
187 | ret->short_name = name; | 206 | ret->short_name = name; |
188 | ret->lib_name = libname; | 207 | ret->lib_name = libname; |
189 | /* Load the plugin within GNUnet's default context */ | 208 | /* Load the plugin within GNUnet's default context */ |
190 | pd = GNUNET_OS_project_data_get (); | 209 | pd = GNUNET_OS_project_data_get (); |
191 | GNUNET_OS_init (GNUNET_OS_project_data_default ()); | 210 | GNUNET_OS_init (GNUNET_OS_project_data_default ()); |
192 | ret->api = GNUNET_PLUGIN_load (libname, &ret->env); | 211 | ret->api = GNUNET_PLUGIN_load (libname, |
212 | &ret->env); | ||
193 | GNUNET_OS_init (pd); | 213 | GNUNET_OS_init (pd); |
194 | if (NULL == ret->api) | 214 | if (NULL == ret->api) |
195 | { | 215 | { |
196 | /* Try to load the plugin within the application's context | 216 | /* Try to load the plugin within the application's context |
197 | This normally happens when the application is not GNUnet itself but a | 217 | This normally happens when the application is not GNUnet itself but a |
198 | third party; inside GNUnet this is effectively a double failure. */ | 218 | third party; inside GNUnet this is effectively a double failure. */ |
199 | ret->api = GNUNET_PLUGIN_load (libname, &ret->env); | 219 | ret->api = GNUNET_PLUGIN_load (libname, |
220 | &ret->env); | ||
200 | if (NULL == ret->api) | 221 | if (NULL == ret->api) |
201 | { | 222 | { |
202 | LOG (GNUNET_ERROR_TYPE_ERROR, | 223 | LOG (GNUNET_ERROR_TYPE_ERROR, |
203 | _ ("Failed to load datacache plugin for `%s'\n"), | 224 | "Failed to load datacache plugin for `%s'\n", |
204 | name); | 225 | name); |
205 | GNUNET_DATACACHE_destroy (ret); | 226 | GNUNET_DATACACHE_destroy (ret); |
206 | return NULL; | 227 | return NULL; |
@@ -216,7 +237,9 @@ GNUNET_DATACACHE_destroy (struct GNUNET_DATACACHE_Handle *h) | |||
216 | if (NULL != h->filter) | 237 | if (NULL != h->filter) |
217 | GNUNET_CONTAINER_bloomfilter_free (h->filter); | 238 | GNUNET_CONTAINER_bloomfilter_free (h->filter); |
218 | if (NULL != h->api) | 239 | if (NULL != h->api) |
219 | GNUNET_break (NULL == GNUNET_PLUGIN_unload (h->lib_name, h->api)); | 240 | GNUNET_break (NULL == |
241 | GNUNET_PLUGIN_unload (h->lib_name, | ||
242 | h->api)); | ||
220 | GNUNET_free (h->lib_name); | 243 | GNUNET_free (h->lib_name); |
221 | GNUNET_free (h->short_name); | 244 | GNUNET_free (h->short_name); |
222 | GNUNET_free (h->section); | 245 | GNUNET_free (h->section); |
@@ -270,17 +293,19 @@ GNUNET_DATACACHE_put (struct GNUNET_DATACACHE_Handle *h, | |||
270 | "Stored data under key `%s' in cache\n", | 293 | "Stored data under key `%s' in cache\n", |
271 | GNUNET_h2s (key)); | 294 | GNUNET_h2s (key)); |
272 | if (NULL != h->filter) | 295 | if (NULL != h->filter) |
273 | GNUNET_CONTAINER_bloomfilter_add (h->filter, key); | 296 | GNUNET_CONTAINER_bloomfilter_add (h->filter, |
297 | key); | ||
274 | GNUNET_STATISTICS_update (h->stats, | 298 | GNUNET_STATISTICS_update (h->stats, |
275 | gettext_noop ("# bytes stored"), | 299 | "# bytes stored", |
276 | used, | 300 | used, |
277 | GNUNET_NO); | 301 | GNUNET_NO); |
278 | GNUNET_STATISTICS_update (h->stats, | 302 | GNUNET_STATISTICS_update (h->stats, |
279 | gettext_noop ("# items stored"), | 303 | "# items stored", |
280 | 1, | 304 | 1, |
281 | GNUNET_NO); | 305 | GNUNET_NO); |
282 | while (h->utilization + used > h->env.quota) | 306 | while (h->utilization + used > h->env.quota) |
283 | GNUNET_assert (GNUNET_OK == h->api->del (h->api->cls)); | 307 | GNUNET_assert (GNUNET_OK == |
308 | h->api->del (h->api->cls)); | ||
284 | h->utilization += used; | 309 | h->utilization += used; |
285 | return GNUNET_OK; | 310 | return GNUNET_OK; |
286 | } | 311 | } |
@@ -294,18 +319,18 @@ GNUNET_DATACACHE_get (struct GNUNET_DATACACHE_Handle *h, | |||
294 | void *iter_cls) | 319 | void *iter_cls) |
295 | { | 320 | { |
296 | GNUNET_STATISTICS_update (h->stats, | 321 | GNUNET_STATISTICS_update (h->stats, |
297 | gettext_noop ("# requests received"), | 322 | "# requests received", |
298 | 1, | 323 | 1, |
299 | GNUNET_NO); | 324 | GNUNET_NO); |
300 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 325 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
301 | "Processing request for key `%s'\n", | 326 | "Processing request for key `%s'\n", |
302 | GNUNET_h2s (key)); | 327 | GNUNET_h2s (key)); |
303 | if ((NULL != h->filter) && | 328 | if ((NULL != h->filter) && |
304 | (GNUNET_OK != GNUNET_CONTAINER_bloomfilter_test (h->filter, key))) | 329 | (GNUNET_OK != |
330 | GNUNET_CONTAINER_bloomfilter_test (h->filter, key))) | ||
305 | { | 331 | { |
306 | GNUNET_STATISTICS_update (h->stats, | 332 | GNUNET_STATISTICS_update (h->stats, |
307 | gettext_noop ( | 333 | "# requests filtered by bloom filter", |
308 | "# requests filtered by bloom filter"), | ||
309 | 1, | 334 | 1, |
310 | GNUNET_NO); | 335 | GNUNET_NO); |
311 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 336 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
@@ -313,26 +338,33 @@ GNUNET_DATACACHE_get (struct GNUNET_DATACACHE_Handle *h, | |||
313 | GNUNET_h2s (key)); | 338 | GNUNET_h2s (key)); |
314 | return 0; /* can not be present */ | 339 | return 0; /* can not be present */ |
315 | } | 340 | } |
316 | return h->api->get (h->api->cls, key, type, iter, iter_cls); | 341 | return h->api->get (h->api->cls, |
342 | key, | ||
343 | type, | ||
344 | iter, iter_cls); | ||
317 | } | 345 | } |
318 | 346 | ||
319 | 347 | ||
320 | unsigned int | 348 | unsigned int |
321 | GNUNET_DATACACHE_get_closest (struct GNUNET_DATACACHE_Handle *h, | 349 | GNUNET_DATACACHE_get_closest (struct GNUNET_DATACACHE_Handle *h, |
322 | const struct GNUNET_HashCode *key, | 350 | const struct GNUNET_HashCode *key, |
351 | enum GNUNET_BLOCK_Type type, | ||
323 | unsigned int num_results, | 352 | unsigned int num_results, |
324 | GNUNET_DATACACHE_Iterator iter, | 353 | GNUNET_DATACACHE_Iterator iter, |
325 | void *iter_cls) | 354 | void *iter_cls) |
326 | { | 355 | { |
327 | GNUNET_STATISTICS_update (h->stats, | 356 | GNUNET_STATISTICS_update (h->stats, |
328 | gettext_noop ( | 357 | "# proximity search requests received", |
329 | "# proximity search requests received"), | ||
330 | 1, | 358 | 1, |
331 | GNUNET_NO); | 359 | GNUNET_NO); |
332 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 360 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
333 | "Processing proximity search at `%s'\n", | 361 | "Processing proximity search at `%s'\n", |
334 | GNUNET_h2s (key)); | 362 | GNUNET_h2s (key)); |
335 | return h->api->get_closest (h->api->cls, key, num_results, iter, iter_cls); | 363 | return h->api->get_closest (h->api->cls, |
364 | key, | ||
365 | type, | ||
366 | num_results, | ||
367 | iter, iter_cls); | ||
336 | } | 368 | } |
337 | 369 | ||
338 | 370 | ||
diff --git a/src/datacache/plugin_datacache_heap.c b/src/datacache/plugin_datacache_heap.c index fbd3aea9a..5b50468a5 100644 --- a/src/datacache/plugin_datacache_heap.c +++ b/src/datacache/plugin_datacache_heap.c | |||
@@ -158,7 +158,7 @@ struct PutContext | |||
158 | * @param value an existing value | 158 | * @param value an existing value |
159 | * @return #GNUNET_YES if not found (to continue to iterate) | 159 | * @return #GNUNET_YES if not found (to continue to iterate) |
160 | */ | 160 | */ |
161 | static int | 161 | static enum GNUNET_GenericReturnValue |
162 | put_cb (void *cls, | 162 | put_cb (void *cls, |
163 | const struct GNUNET_HashCode *key, | 163 | const struct GNUNET_HashCode *key, |
164 | void *value) | 164 | void *value) |
@@ -224,15 +224,20 @@ heap_plugin_put (void *cls, | |||
224 | { | 224 | { |
225 | struct Plugin *plugin = cls; | 225 | struct Plugin *plugin = cls; |
226 | struct Value *val; | 226 | struct Value *val; |
227 | struct PutContext put_ctx; | 227 | struct PutContext put_ctx = { |
228 | 228 | .data = data, | |
229 | put_ctx.found = GNUNET_NO; | 229 | .size = size, |
230 | put_ctx.data = data; | 230 | .path_info = path_info, |
231 | put_ctx.size = size; | 231 | .path_info_len = path_info_len, |
232 | put_ctx.path_info = path_info; | 232 | .discard_time = discard_time, |
233 | put_ctx.path_info_len = path_info_len; | 233 | .type = type |
234 | put_ctx.discard_time = discard_time; | 234 | }; |
235 | put_ctx.type = type; | 235 | |
236 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
237 | "Storing %u bytes under key %s with path length %u\n", | ||
238 | (unsigned int) size, | ||
239 | GNUNET_h2s (key), | ||
240 | path_info_len); | ||
236 | GNUNET_CONTAINER_multihashmap_get_multiple (plugin->map, | 241 | GNUNET_CONTAINER_multihashmap_get_multiple (plugin->map, |
237 | key, | 242 | key, |
238 | &put_cb, | 243 | &put_cb, |
@@ -313,12 +318,25 @@ get_cb (void *cls, | |||
313 | struct Value *val = value; | 318 | struct Value *val = value; |
314 | int ret; | 319 | int ret; |
315 | 320 | ||
316 | if ((get_ctx->type != val->type) && | 321 | if ( (get_ctx->type != val->type) && |
317 | (GNUNET_BLOCK_TYPE_ANY != get_ctx->type)) | 322 | (GNUNET_BLOCK_TYPE_ANY != get_ctx->type) ) |
323 | { | ||
324 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
325 | "Result for key %s does not match block type %d\n", | ||
326 | GNUNET_h2s (key), | ||
327 | get_ctx->type); | ||
318 | return GNUNET_OK; | 328 | return GNUNET_OK; |
319 | if (0 == | 329 | } |
320 | GNUNET_TIME_absolute_get_remaining (val->discard_time).rel_value_us) | 330 | if (GNUNET_TIME_absolute_is_past (val->discard_time)) |
331 | { | ||
332 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
333 | "Result for key %s is expired\n", | ||
334 | GNUNET_h2s (key)); | ||
321 | return GNUNET_OK; | 335 | return GNUNET_OK; |
336 | } | ||
337 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
338 | "Found result for key %s\n", | ||
339 | GNUNET_h2s (key)); | ||
322 | if (NULL != get_ctx->iter) | 340 | if (NULL != get_ctx->iter) |
323 | ret = get_ctx->iter (get_ctx->iter_cls, | 341 | ret = get_ctx->iter (get_ctx->iter_cls, |
324 | key, | 342 | key, |
@@ -409,13 +427,16 @@ struct GetClosestContext | |||
409 | { | 427 | { |
410 | struct Value **values; | 428 | struct Value **values; |
411 | 429 | ||
430 | const struct GNUNET_HashCode *key; | ||
431 | |||
432 | enum GNUNET_BLOCK_Type type; | ||
433 | |||
412 | unsigned int num_results; | 434 | unsigned int num_results; |
413 | 435 | ||
414 | const struct GNUNET_HashCode *key; | ||
415 | }; | 436 | }; |
416 | 437 | ||
417 | 438 | ||
418 | static int | 439 | static enum GNUNET_GenericReturnValue |
419 | find_closest (void *cls, | 440 | find_closest (void *cls, |
420 | const struct GNUNET_HashCode *key, | 441 | const struct GNUNET_HashCode *key, |
421 | void *value) | 442 | void *value) |
@@ -427,6 +448,9 @@ find_closest (void *cls, | |||
427 | if (1 != GNUNET_CRYPTO_hash_cmp (key, | 448 | if (1 != GNUNET_CRYPTO_hash_cmp (key, |
428 | gcc->key)) | 449 | gcc->key)) |
429 | return GNUNET_OK; /* useless */ | 450 | return GNUNET_OK; /* useless */ |
451 | if ( (val->type != gcc->type) && | ||
452 | (GNUNET_BLOCK_TYPE_ANY != gcc->type) ) | ||
453 | return GNUNET_OK; /* useless */ | ||
430 | j = gcc->num_results; | 454 | j = gcc->num_results; |
431 | for (unsigned int i = 0; i < gcc->num_results; i++) | 455 | for (unsigned int i = 0; i < gcc->num_results; i++) |
432 | { | 456 | { |
@@ -435,8 +459,9 @@ find_closest (void *cls, | |||
435 | j = i; | 459 | j = i; |
436 | break; | 460 | break; |
437 | } | 461 | } |
438 | if (1 == GNUNET_CRYPTO_hash_cmp (&gcc->values[i]->key, | 462 | if (1 == |
439 | key)) | 463 | GNUNET_CRYPTO_hash_cmp (&gcc->values[i]->key, |
464 | key)) | ||
440 | { | 465 | { |
441 | j = i; | 466 | j = i; |
442 | break; | 467 | break; |
@@ -457,6 +482,7 @@ find_closest (void *cls, | |||
457 | * | 482 | * |
458 | * @param cls closure (internal context for the plugin) | 483 | * @param cls closure (internal context for the plugin) |
459 | * @param key area of the keyspace to look into | 484 | * @param key area of the keyspace to look into |
485 | * @param type desired block type for the replies | ||
460 | * @param num_results number of results that should be returned to @a iter | 486 | * @param num_results number of results that should be returned to @a iter |
461 | * @param iter maybe NULL (to just count) | 487 | * @param iter maybe NULL (to just count) |
462 | * @param iter_cls closure for @a iter | 488 | * @param iter_cls closure for @a iter |
@@ -465,6 +491,7 @@ find_closest (void *cls, | |||
465 | static unsigned int | 491 | static unsigned int |
466 | heap_plugin_get_closest (void *cls, | 492 | heap_plugin_get_closest (void *cls, |
467 | const struct GNUNET_HashCode *key, | 493 | const struct GNUNET_HashCode *key, |
494 | enum GNUNET_BLOCK_Type type, | ||
468 | unsigned int num_results, | 495 | unsigned int num_results, |
469 | GNUNET_DATACACHE_Iterator iter, | 496 | GNUNET_DATACACHE_Iterator iter, |
470 | void *iter_cls) | 497 | void *iter_cls) |
@@ -473,14 +500,15 @@ heap_plugin_get_closest (void *cls, | |||
473 | struct Value *values[num_results]; | 500 | struct Value *values[num_results]; |
474 | struct GetClosestContext gcc = { | 501 | struct GetClosestContext gcc = { |
475 | .values = values, | 502 | .values = values, |
476 | .num_results = num_results, | 503 | .type = type, |
504 | .num_results = num_results * 2, | ||
477 | .key = key | 505 | .key = key |
478 | }; | 506 | }; |
479 | 507 | ||
480 | GNUNET_CONTAINER_multihashmap_iterate (plugin->map, | 508 | GNUNET_CONTAINER_multihashmap_iterate (plugin->map, |
481 | &find_closest, | 509 | &find_closest, |
482 | &gcc); | 510 | &gcc); |
483 | for (unsigned int i = 0; i < num_results; i++) | 511 | for (unsigned int i = 0; i < num_results * 2; i++) |
484 | { | 512 | { |
485 | if (NULL == values[i]) | 513 | if (NULL == values[i]) |
486 | return i; | 514 | return i; |
@@ -493,7 +521,7 @@ heap_plugin_get_closest (void *cls, | |||
493 | values[i]->path_info_len, | 521 | values[i]->path_info_len, |
494 | values[i]->path_info); | 522 | values[i]->path_info); |
495 | } | 523 | } |
496 | return num_results; | 524 | return num_results * 2; |
497 | } | 525 | } |
498 | 526 | ||
499 | 527 | ||
diff --git a/src/datacache/plugin_datacache_postgres.c b/src/datacache/plugin_datacache_postgres.c index 6a44c44a5..1a83cda86 100644 --- a/src/datacache/plugin_datacache_postgres.c +++ b/src/datacache/plugin_datacache_postgres.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet | 2 | This file is part of GNUnet |
3 | Copyright (C) 2006, 2009, 2010, 2012, 2015, 2017, 2018 GNUnet e.V. | 3 | Copyright (C) 2006, 2009, 2010, 2012, 2015, 2017, 2018, 2022 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 |
@@ -109,9 +109,20 @@ init_connection (struct Plugin *plugin) | |||
109 | " ORDER BY prox ASC, discard_time ASC LIMIT 1", | 109 | " ORDER BY prox ASC, discard_time ASC LIMIT 1", |
110 | 0), | 110 | 0), |
111 | GNUNET_PQ_make_prepare ("get_closest", | 111 | GNUNET_PQ_make_prepare ("get_closest", |
112 | "SELECT discard_time,type,value,path,key FROM gn011dc " | 112 | "(SELECT discard_time,type,value,path,key FROM gn011dc" |
113 | "WHERE key>=$1 AND discard_time >= $2 ORDER BY key ASC LIMIT $3", | 113 | " WHERE key >= $1" |
114 | 3), | 114 | " AND discard_time >= $2" |
115 | " AND ( (type = $3) OR ( 0 = $3) )" | ||
116 | " ORDER BY key ASC" | ||
117 | " LIMIT $4)" | ||
118 | " UNION " | ||
119 | "(SELECT discard_time,type,value,path,key FROM gn011dc" | ||
120 | " WHERE key <= $1" | ||
121 | " AND discard_time >= $2" | ||
122 | " AND ( (type = $3) OR ( 0 = $3) )" | ||
123 | " ORDER BY key DESC" | ||
124 | " LIMIT $4)", | ||
125 | 4), | ||
115 | GNUNET_PQ_make_prepare ("delrow", | 126 | GNUNET_PQ_make_prepare ("delrow", |
116 | "DELETE FROM gn011dc WHERE oid=$1", | 127 | "DELETE FROM gn011dc WHERE oid=$1", |
117 | 1), | 128 | 1), |
@@ -511,6 +522,7 @@ extract_result_cb (void *cls, | |||
511 | * | 522 | * |
512 | * @param cls closure (internal context for the plugin) | 523 | * @param cls closure (internal context for the plugin) |
513 | * @param key area of the keyspace to look into | 524 | * @param key area of the keyspace to look into |
525 | * @param type desired block type for the replies | ||
514 | * @param num_results number of results that should be returned to @a iter | 526 | * @param num_results number of results that should be returned to @a iter |
515 | * @param iter maybe NULL (to just count) | 527 | * @param iter maybe NULL (to just count) |
516 | * @param iter_cls closure for @a iter | 528 | * @param iter_cls closure for @a iter |
@@ -519,16 +531,19 @@ extract_result_cb (void *cls, | |||
519 | static unsigned int | 531 | static unsigned int |
520 | postgres_plugin_get_closest (void *cls, | 532 | postgres_plugin_get_closest (void *cls, |
521 | const struct GNUNET_HashCode *key, | 533 | const struct GNUNET_HashCode *key, |
534 | enum GNUNET_BLOCK_Type type, | ||
522 | unsigned int num_results, | 535 | unsigned int num_results, |
523 | GNUNET_DATACACHE_Iterator iter, | 536 | GNUNET_DATACACHE_Iterator iter, |
524 | void *iter_cls) | 537 | void *iter_cls) |
525 | { | 538 | { |
526 | struct Plugin *plugin = cls; | 539 | struct Plugin *plugin = cls; |
527 | uint32_t num_results32 = (uint32_t) num_results; | 540 | uint32_t num_results32 = (uint32_t) num_results; |
541 | uint32_t type32 = (uint32_t) type; | ||
528 | struct GNUNET_TIME_Absolute now; | 542 | struct GNUNET_TIME_Absolute now; |
529 | struct GNUNET_PQ_QueryParam params[] = { | 543 | struct GNUNET_PQ_QueryParam params[] = { |
530 | GNUNET_PQ_query_param_auto_from_type (key), | 544 | GNUNET_PQ_query_param_auto_from_type (key), |
531 | GNUNET_PQ_query_param_absolute_time (&now), | 545 | GNUNET_PQ_query_param_absolute_time (&now), |
546 | GNUNET_PQ_query_param_uint32 (&type32), | ||
532 | GNUNET_PQ_query_param_uint32 (&num_results32), | 547 | GNUNET_PQ_query_param_uint32 (&num_results32), |
533 | GNUNET_PQ_query_param_end | 548 | GNUNET_PQ_query_param_end |
534 | }; | 549 | }; |
diff --git a/src/datacache/plugin_datacache_sqlite.c b/src/datacache/plugin_datacache_sqlite.c index d08b32caf..6f2165433 100644 --- a/src/datacache/plugin_datacache_sqlite.c +++ b/src/datacache/plugin_datacache_sqlite.c | |||
@@ -454,6 +454,7 @@ sqlite_plugin_del (void *cls) | |||
454 | * | 454 | * |
455 | * @param cls closure (internal context for the plugin) | 455 | * @param cls closure (internal context for the plugin) |
456 | * @param key area of the keyspace to look into | 456 | * @param key area of the keyspace to look into |
457 | * @param type desired block type for the replies | ||
457 | * @param num_results number of results that should be returned to @a iter | 458 | * @param num_results number of results that should be returned to @a iter |
458 | * @param iter maybe NULL (to just count) | 459 | * @param iter maybe NULL (to just count) |
459 | * @param iter_cls closure for @a iter | 460 | * @param iter_cls closure for @a iter |
@@ -462,11 +463,13 @@ sqlite_plugin_del (void *cls) | |||
462 | static unsigned int | 463 | static unsigned int |
463 | sqlite_plugin_get_closest (void *cls, | 464 | sqlite_plugin_get_closest (void *cls, |
464 | const struct GNUNET_HashCode *key, | 465 | const struct GNUNET_HashCode *key, |
466 | enum GNUNET_BLOCK_Type type, | ||
465 | unsigned int num_results, | 467 | unsigned int num_results, |
466 | GNUNET_DATACACHE_Iterator iter, | 468 | GNUNET_DATACACHE_Iterator iter, |
467 | void *iter_cls) | 469 | void *iter_cls) |
468 | { | 470 | { |
469 | struct Plugin *plugin = cls; | 471 | struct Plugin *plugin = cls; |
472 | uint32_t type32 = type; | ||
470 | uint32_t num_results32 = num_results; | 473 | uint32_t num_results32 = num_results; |
471 | struct GNUNET_TIME_Absolute now; | 474 | struct GNUNET_TIME_Absolute now; |
472 | struct GNUNET_TIME_Absolute exp; | 475 | struct GNUNET_TIME_Absolute exp; |
@@ -474,38 +477,46 @@ sqlite_plugin_get_closest (void *cls, | |||
474 | void *dat; | 477 | void *dat; |
475 | unsigned int cnt; | 478 | unsigned int cnt; |
476 | size_t psize; | 479 | size_t psize; |
477 | uint32_t type; | 480 | uint32_t rtype; |
478 | struct GNUNET_HashCode hc; | 481 | struct GNUNET_HashCode hc; |
479 | struct GNUNET_DHT_PathElement *path; | 482 | struct GNUNET_DHT_PathElement *path; |
480 | struct GNUNET_SQ_QueryParam params[] = | 483 | struct GNUNET_SQ_QueryParam params[] = { |
481 | { GNUNET_SQ_query_param_auto_from_type (key), | 484 | GNUNET_SQ_query_param_auto_from_type (key), |
482 | GNUNET_SQ_query_param_absolute_time (&now), | 485 | GNUNET_SQ_query_param_absolute_time (&now), |
486 | GNUNET_SQ_query_param_uint32 (&type32), | ||
483 | GNUNET_SQ_query_param_uint32 (&num_results32), | 487 | GNUNET_SQ_query_param_uint32 (&num_results32), |
484 | GNUNET_SQ_query_param_end }; | 488 | GNUNET_SQ_query_param_end |
485 | struct GNUNET_SQ_ResultSpec rs[] = | 489 | }; |
486 | { GNUNET_SQ_result_spec_variable_size (&dat, &size), | 490 | struct GNUNET_SQ_ResultSpec rs[] = { |
491 | GNUNET_SQ_result_spec_variable_size (&dat, &size), | ||
487 | GNUNET_SQ_result_spec_absolute_time (&exp), | 492 | GNUNET_SQ_result_spec_absolute_time (&exp), |
488 | GNUNET_SQ_result_spec_variable_size ((void **) &path, &psize), | 493 | GNUNET_SQ_result_spec_variable_size ((void **) &path, &psize), |
489 | GNUNET_SQ_result_spec_uint32 (&type), | 494 | GNUNET_SQ_result_spec_uint32 (&rtype), |
490 | GNUNET_SQ_result_spec_auto_from_type (&hc), | 495 | GNUNET_SQ_result_spec_auto_from_type (&hc), |
491 | GNUNET_SQ_result_spec_end }; | 496 | GNUNET_SQ_result_spec_end |
497 | }; | ||
492 | 498 | ||
493 | now = GNUNET_TIME_absolute_get (); | 499 | now = GNUNET_TIME_absolute_get (); |
494 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 500 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
495 | "Processing GET_CLOSEST for key `%s'\n", | 501 | "Processing GET_CLOSEST for key `%s'\n", |
496 | GNUNET_h2s (key)); | 502 | GNUNET_h2s (key)); |
497 | if (GNUNET_OK != GNUNET_SQ_bind (plugin->get_closest_stmt, params)) | 503 | if (GNUNET_OK != |
504 | GNUNET_SQ_bind (plugin->get_closest_stmt, | ||
505 | params)) | ||
498 | { | 506 | { |
499 | LOG_SQLITE (plugin->dbh, | 507 | LOG_SQLITE (plugin->dbh, |
500 | GNUNET_ERROR_TYPE_ERROR | GNUNET_ERROR_TYPE_BULK, | 508 | GNUNET_ERROR_TYPE_ERROR | GNUNET_ERROR_TYPE_BULK, |
501 | "sqlite3_bind_xxx"); | 509 | "sqlite3_bind_xxx"); |
502 | GNUNET_SQ_reset (plugin->dbh, plugin->get_closest_stmt); | 510 | GNUNET_SQ_reset (plugin->dbh, |
511 | plugin->get_closest_stmt); | ||
503 | return 0; | 512 | return 0; |
504 | } | 513 | } |
505 | cnt = 0; | 514 | cnt = 0; |
506 | while (SQLITE_ROW == sqlite3_step (plugin->get_closest_stmt)) | 515 | while (SQLITE_ROW == sqlite3_step (plugin->get_closest_stmt)) |
507 | { | 516 | { |
508 | if (GNUNET_OK != GNUNET_SQ_extract_result (plugin->get_closest_stmt, rs)) | 517 | if (GNUNET_OK != |
518 | GNUNET_SQ_extract_result (plugin->get_closest_stmt, | ||
519 | rs)) | ||
509 | { | 520 | { |
510 | GNUNET_break (0); | 521 | GNUNET_break (0); |
511 | break; | 522 | break; |
@@ -522,14 +533,22 @@ sqlite_plugin_get_closest (void *cls, | |||
522 | "Found %u-byte result at %s when processing GET_CLOSE\n", | 533 | "Found %u-byte result at %s when processing GET_CLOSE\n", |
523 | (unsigned int) size, | 534 | (unsigned int) size, |
524 | GNUNET_h2s (&hc)); | 535 | GNUNET_h2s (&hc)); |
525 | if (GNUNET_OK != iter (iter_cls, &hc, size, dat, type, exp, psize, path)) | 536 | if (GNUNET_OK != iter (iter_cls, |
537 | &hc, | ||
538 | size, | ||
539 | dat, | ||
540 | rtype, | ||
541 | exp, | ||
542 | psize, | ||
543 | path)) | ||
526 | { | 544 | { |
527 | GNUNET_SQ_cleanup_result (rs); | 545 | GNUNET_SQ_cleanup_result (rs); |
528 | break; | 546 | break; |
529 | } | 547 | } |
530 | GNUNET_SQ_cleanup_result (rs); | 548 | GNUNET_SQ_cleanup_result (rs); |
531 | } | 549 | } |
532 | GNUNET_SQ_reset (plugin->dbh, plugin->get_closest_stmt); | 550 | GNUNET_SQ_reset (plugin->dbh, |
551 | plugin->get_closest_stmt); | ||
533 | return cnt; | 552 | return cnt; |
534 | } | 553 | } |
535 | 554 | ||
@@ -620,7 +639,7 @@ libgnunet_plugin_datacache_sqlite_init (void *cls) | |||
620 | &plugin->get_stmt)) || | 639 | &plugin->get_stmt)) || |
621 | (SQLITE_OK != sq_prepare (plugin->dbh, | 640 | (SQLITE_OK != sq_prepare (plugin->dbh, |
622 | "SELECT _ROWID_,key,value FROM ds091" | 641 | "SELECT _ROWID_,key,value FROM ds091" |
623 | " WHERE expire < ?" | 642 | " WHERE expire < ?1" |
624 | " ORDER BY expire ASC LIMIT 1", | 643 | " ORDER BY expire ASC LIMIT 1", |
625 | &plugin->del_expired_stmt)) || | 644 | &plugin->del_expired_stmt)) || |
626 | (SQLITE_OK != sq_prepare (plugin->dbh, | 645 | (SQLITE_OK != sq_prepare (plugin->dbh, |
@@ -632,8 +651,19 @@ libgnunet_plugin_datacache_sqlite_init (void *cls) | |||
632 | &plugin->del_stmt)) || | 651 | &plugin->del_stmt)) || |
633 | (SQLITE_OK != | 652 | (SQLITE_OK != |
634 | sq_prepare (plugin->dbh, | 653 | sq_prepare (plugin->dbh, |
635 | "SELECT value,expire,path,type,key FROM ds091 " | 654 | "SELECT * FROM (" |
636 | "WHERE key>=? AND expire >= ? ORDER BY KEY ASC LIMIT ?", | 655 | " SELECT value,expire,path,type,key FROM ds091 " |
656 | " WHERE key>=?1 " | ||
657 | " AND expire >= ?2" | ||
658 | " AND ( (type=?3) or (0 == ?3) )" | ||
659 | " ORDER BY KEY ASC LIMIT ?4)" | ||
660 | "UNION " | ||
661 | "SELECT * FROM (" | ||
662 | " SELECT value,expire,path,type,key FROM ds091 " | ||
663 | " WHERE key<=?1 " | ||
664 | " AND expire >= ?2" | ||
665 | " AND ( (type=?3) or (0 == ?3) )" | ||
666 | " ORDER BY KEY DESC LIMIT ?4)", | ||
637 | &plugin->get_closest_stmt))) | 667 | &plugin->get_closest_stmt))) |
638 | { | 668 | { |
639 | LOG_SQLITE (plugin->dbh, | 669 | LOG_SQLITE (plugin->dbh, |
diff --git a/src/datacache/plugin_datacache_template.c b/src/datacache/plugin_datacache_template.c index 231413ce9..2f7b41dbe 100644 --- a/src/datacache/plugin_datacache_template.c +++ b/src/datacache/plugin_datacache_template.c | |||
@@ -116,6 +116,7 @@ template_plugin_del (void *cls) | |||
116 | * | 116 | * |
117 | * @param cls closure (internal context for the plugin) | 117 | * @param cls closure (internal context for the plugin) |
118 | * @param key area of the keyspace to look into | 118 | * @param key area of the keyspace to look into |
119 | * @param type desired block type for the replies | ||
119 | * @param num_results number of results that should be returned to @a iter | 120 | * @param num_results number of results that should be returned to @a iter |
120 | * @param iter maybe NULL (to just count) | 121 | * @param iter maybe NULL (to just count) |
121 | * @param iter_cls closure for @a iter | 122 | * @param iter_cls closure for @a iter |
@@ -124,6 +125,7 @@ template_plugin_del (void *cls) | |||
124 | static unsigned int | 125 | static unsigned int |
125 | template_plugin_get_closest (void *cls, | 126 | template_plugin_get_closest (void *cls, |
126 | const struct GNUNET_HashCode *key, | 127 | const struct GNUNET_HashCode *key, |
128 | enum GNUNET_BLOCK_Type type, | ||
127 | unsigned int num_results, | 129 | unsigned int num_results, |
128 | GNUNET_DATACACHE_Iterator iter, | 130 | GNUNET_DATACACHE_Iterator iter, |
129 | void *iter_cls) | 131 | void *iter_cls) |
diff --git a/src/dht/.gitignore b/src/dht/.gitignore index 25b1daf28..bd8af1217 100644 --- a/src/dht/.gitignore +++ b/src/dht/.gitignore | |||
@@ -10,3 +10,4 @@ test_dht_monitor | |||
10 | test_dht_multipeer | 10 | test_dht_multipeer |
11 | test_dht_tools.py | 11 | test_dht_tools.py |
12 | test_dht_twopeer | 12 | test_dht_twopeer |
13 | gnunet-dht-hello | ||
diff --git a/src/dht/Makefile.am b/src/dht/Makefile.am index be48fab02..68a17723d 100644 --- a/src/dht/Makefile.am +++ b/src/dht/Makefile.am | |||
@@ -50,7 +50,8 @@ libexec_PROGRAMS = \ | |||
50 | bin_PROGRAMS = \ | 50 | bin_PROGRAMS = \ |
51 | gnunet-dht-monitor \ | 51 | gnunet-dht-monitor \ |
52 | gnunet-dht-get \ | 52 | gnunet-dht-get \ |
53 | gnunet-dht-put | 53 | gnunet-dht-put \ |
54 | gnunet-dht-hello | ||
54 | 55 | ||
55 | noinst_PROGRAMS = \ | 56 | noinst_PROGRAMS = \ |
56 | gnunet-dht-profiler | 57 | gnunet-dht-profiler |
@@ -58,8 +59,6 @@ noinst_PROGRAMS = \ | |||
58 | gnunet_service_dht_SOURCES = \ | 59 | gnunet_service_dht_SOURCES = \ |
59 | gnunet-service-dht.c gnunet-service-dht.h \ | 60 | gnunet-service-dht.c gnunet-service-dht.h \ |
60 | gnunet-service-dht_datacache.c gnunet-service-dht_datacache.h \ | 61 | gnunet-service-dht_datacache.c gnunet-service-dht_datacache.h \ |
61 | gnunet-service-dht_hello.c gnunet-service-dht_hello.h \ | ||
62 | gnunet-service-dht_nse.c gnunet-service-dht_nse.h \ | ||
63 | gnunet-service-dht_neighbours.c gnunet-service-dht_neighbours.h \ | 62 | gnunet-service-dht_neighbours.c gnunet-service-dht_neighbours.h \ |
64 | gnunet-service-dht_routing.c gnunet-service-dht_routing.h | 63 | gnunet-service-dht_routing.c gnunet-service-dht_routing.h |
65 | gnunet_service_dht_LDADD = \ | 64 | gnunet_service_dht_LDADD = \ |
@@ -72,6 +71,7 @@ gnunet_service_dht_LDADD = \ | |||
72 | $(top_builddir)/src/peerinfo/libgnunetpeerinfo.la \ | 71 | $(top_builddir)/src/peerinfo/libgnunetpeerinfo.la \ |
73 | $(top_builddir)/src/hello/libgnunethello.la \ | 72 | $(top_builddir)/src/hello/libgnunethello.la \ |
74 | $(top_builddir)/src/block/libgnunetblock.la \ | 73 | $(top_builddir)/src/block/libgnunetblock.la \ |
74 | $(top_builddir)/src/block/libgnunetblockgroup.la \ | ||
75 | $(top_builddir)/src/datacache/libgnunetdatacache.la \ | 75 | $(top_builddir)/src/datacache/libgnunetdatacache.la \ |
76 | $(top_builddir)/src/util/libgnunetutil.la \ | 76 | $(top_builddir)/src/util/libgnunetutil.la \ |
77 | -lm | 77 | -lm |
@@ -82,16 +82,22 @@ gnunet_dht_get_SOURCES = \ | |||
82 | gnunet-dht-get.c | 82 | gnunet-dht-get.c |
83 | gnunet_dht_get_LDADD = \ | 83 | gnunet_dht_get_LDADD = \ |
84 | libgnunetdht.la \ | 84 | libgnunetdht.la \ |
85 | $(top_builddir)/src/core/libgnunetcore.la \ | ||
86 | $(top_builddir)/src/util/libgnunetutil.la | 85 | $(top_builddir)/src/util/libgnunetutil.la |
87 | gnunet_dht_get_LDFLAGS = \ | 86 | gnunet_dht_get_LDFLAGS = \ |
88 | $(GN_LIBINTL) | 87 | $(GN_LIBINTL) |
89 | 88 | ||
89 | gnunet_dht_hello_SOURCES = \ | ||
90 | gnunet-dht-hello.c | ||
91 | gnunet_dht_hello_LDADD = \ | ||
92 | libgnunetdht.la \ | ||
93 | $(top_builddir)/src/util/libgnunetutil.la | ||
94 | gnunet_dht_hello_LDFLAGS = \ | ||
95 | $(GN_LIBINTL) | ||
96 | |||
90 | gnunet_dht_put_SOURCES = \ | 97 | gnunet_dht_put_SOURCES = \ |
91 | gnunet-dht-put.c | 98 | gnunet-dht-put.c |
92 | gnunet_dht_put_LDADD = \ | 99 | gnunet_dht_put_LDADD = \ |
93 | libgnunetdht.la \ | 100 | libgnunetdht.la \ |
94 | $(top_builddir)/src/core/libgnunetcore.la \ | ||
95 | $(top_builddir)/src/util/libgnunetutil.la | 101 | $(top_builddir)/src/util/libgnunetutil.la |
96 | gnunet_dht_put_LDFLAGS = \ | 102 | gnunet_dht_put_LDFLAGS = \ |
97 | $(GN_LIBINTL) | 103 | $(GN_LIBINTL) |
@@ -100,7 +106,6 @@ gnunet_dht_monitor_SOURCES = \ | |||
100 | gnunet-dht-monitor.c | 106 | gnunet-dht-monitor.c |
101 | gnunet_dht_monitor_LDADD = \ | 107 | gnunet_dht_monitor_LDADD = \ |
102 | libgnunetdht.la \ | 108 | libgnunetdht.la \ |
103 | $(top_builddir)/src/core/libgnunetcore.la \ | ||
104 | $(top_builddir)/src/util/libgnunetutil.la | 109 | $(top_builddir)/src/util/libgnunetutil.la |
105 | gnunet_dht_monitor_LDFLAGS = \ | 110 | gnunet_dht_monitor_LDFLAGS = \ |
106 | $(GN_LIBINTL) | 111 | $(GN_LIBINTL) |
@@ -199,7 +204,6 @@ test_dht_monitor_LDADD = \ | |||
199 | libgnunetdht.la | 204 | libgnunetdht.la |
200 | 205 | ||
201 | EXTRA_DIST = \ | 206 | EXTRA_DIST = \ |
202 | $(check_SCRIPTS) \ | ||
203 | gnunet-service-dht_clients.c \ | 207 | gnunet-service-dht_clients.c \ |
204 | test_dht_api_data.conf \ | 208 | test_dht_api_data.conf \ |
205 | test_dht_api_peer1.conf \ | 209 | test_dht_api_peer1.conf \ |
@@ -209,7 +213,10 @@ EXTRA_DIST = \ | |||
209 | test_dht_line.conf \ | 213 | test_dht_line.conf \ |
210 | test_dht_tools.conf \ | 214 | test_dht_tools.conf \ |
211 | test_dht_tools.py.in \ | 215 | test_dht_tools.py.in \ |
212 | test_dht_multipeer_topology.dat | 216 | test_dht_multipeer_topology.dat \ |
217 | dhtu_testbed_connect.sh \ | ||
218 | dhtu_testbed_deploy.conf \ | ||
219 | dhtu_testbed_deploy.sh | ||
213 | 220 | ||
214 | if HAVE_PYTHON | 221 | if HAVE_PYTHON |
215 | check_SCRIPTS = \ | 222 | check_SCRIPTS = \ |
diff --git a/src/dht/dht_api.c b/src/dht/dht_api.c index 8389bbb95..474198004 100644 --- a/src/dht/dht_api.c +++ b/src/dht/dht_api.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet. | 2 | This file is part of GNUnet. |
3 | Copyright (C) 2009, 2010, 2011, 2012, 2016, 2018 GNUnet e.V. | 3 | Copyright (C) 2009-2012, 2016, 2018, 2022 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 |
@@ -197,6 +197,40 @@ struct GNUNET_DHT_MonitorHandle | |||
197 | 197 | ||
198 | 198 | ||
199 | /** | 199 | /** |
200 | * Handle to get a HELLO URL from the DHT for manual bootstrapping. | ||
201 | */ | ||
202 | struct GNUNET_DHT_HelloGetHandle | ||
203 | { | ||
204 | |||
205 | /** | ||
206 | * DLL. | ||
207 | */ | ||
208 | struct GNUNET_DHT_HelloGetHandle *next; | ||
209 | |||
210 | /** | ||
211 | * DLL. | ||
212 | */ | ||
213 | struct GNUNET_DHT_HelloGetHandle *prev; | ||
214 | |||
215 | /** | ||
216 | * Function to call with the result. | ||
217 | */ | ||
218 | GNUNET_DHT_HelloGetCallback cb; | ||
219 | |||
220 | /** | ||
221 | * Closure for @a cb. | ||
222 | */ | ||
223 | void *cb_cls; | ||
224 | |||
225 | /** | ||
226 | * Connection to the DHT service. | ||
227 | */ | ||
228 | struct GNUNET_DHT_Handle *dht_handle; | ||
229 | |||
230 | }; | ||
231 | |||
232 | |||
233 | /** | ||
200 | * Connection to the DHT service. | 234 | * Connection to the DHT service. |
201 | */ | 235 | */ |
202 | struct GNUNET_DHT_Handle | 236 | struct GNUNET_DHT_Handle |
@@ -232,6 +266,16 @@ struct GNUNET_DHT_Handle | |||
232 | struct GNUNET_DHT_PutHandle *put_tail; | 266 | struct GNUNET_DHT_PutHandle *put_tail; |
233 | 267 | ||
234 | /** | 268 | /** |
269 | * DLL. | ||
270 | */ | ||
271 | struct GNUNET_DHT_HelloGetHandle *hgh_head; | ||
272 | |||
273 | /** | ||
274 | * DLL. | ||
275 | */ | ||
276 | struct GNUNET_DHT_HelloGetHandle *hgh_tail; | ||
277 | |||
278 | /** | ||
235 | * Hash map containing the current outstanding unique GET requests | 279 | * Hash map containing the current outstanding unique GET requests |
236 | * (values are of type `struct GNUNET_DHT_GetHandle`). | 280 | * (values are of type `struct GNUNET_DHT_GetHandle`). |
237 | */ | 281 | */ |
@@ -517,9 +561,10 @@ handle_monitor_get (void *cls, | |||
517 | const struct GNUNET_DHT_MonitorGetMessage *msg) | 561 | const struct GNUNET_DHT_MonitorGetMessage *msg) |
518 | { | 562 | { |
519 | struct GNUNET_DHT_Handle *handle = cls; | 563 | struct GNUNET_DHT_Handle *handle = cls; |
520 | struct GNUNET_DHT_MonitorHandle *mh; | ||
521 | 564 | ||
522 | for (mh = handle->monitor_head; NULL != mh; mh = mh->next) | 565 | for (struct GNUNET_DHT_MonitorHandle *mh = handle->monitor_head; |
566 | NULL != mh; | ||
567 | mh = mh->next) | ||
523 | { | 568 | { |
524 | if (NULL == mh->get_cb) | 569 | if (NULL == mh->get_cb) |
525 | continue; | 570 | continue; |
@@ -582,10 +627,12 @@ handle_monitor_get_resp (void *cls, | |||
582 | const struct GNUNET_DHT_PathElement *path; | 627 | const struct GNUNET_DHT_PathElement *path; |
583 | uint32_t getl = ntohl (msg->get_path_length); | 628 | uint32_t getl = ntohl (msg->get_path_length); |
584 | uint32_t putl = ntohl (msg->put_path_length); | 629 | uint32_t putl = ntohl (msg->put_path_length); |
585 | struct GNUNET_DHT_MonitorHandle *mh; | 630 | |
586 | 631 | ||
587 | path = (const struct GNUNET_DHT_PathElement *) &msg[1]; | 632 | path = (const struct GNUNET_DHT_PathElement *) &msg[1]; |
588 | for (mh = handle->monitor_head; NULL != mh; mh = mh->next) | 633 | for (struct GNUNET_DHT_MonitorHandle *mh = handle->monitor_head; |
634 | NULL != mh; | ||
635 | mh = mh->next) | ||
589 | { | 636 | { |
590 | if (NULL == mh->get_resp_cb) | 637 | if (NULL == mh->get_resp_cb) |
591 | continue; | 638 | continue; |
@@ -597,9 +644,9 @@ handle_monitor_get_resp (void *cls, | |||
597 | sizeof(struct GNUNET_HashCode))))) | 644 | sizeof(struct GNUNET_HashCode))))) |
598 | mh->get_resp_cb (mh->cb_cls, | 645 | mh->get_resp_cb (mh->cb_cls, |
599 | (enum GNUNET_BLOCK_Type) ntohl (msg->type), | 646 | (enum GNUNET_BLOCK_Type) ntohl (msg->type), |
600 | path, | 647 | &path[putl], |
601 | getl, | 648 | getl, |
602 | &path[getl], | 649 | path, |
603 | putl, | 650 | putl, |
604 | GNUNET_TIME_absolute_ntoh (msg->expiration_time), | 651 | GNUNET_TIME_absolute_ntoh (msg->expiration_time), |
605 | &msg->key, | 652 | &msg->key, |
@@ -726,14 +773,21 @@ process_client_result (void *cls, | |||
726 | const struct GNUNET_DHT_ClientResultMessage *crm = cls; | 773 | const struct GNUNET_DHT_ClientResultMessage *crm = cls; |
727 | struct GNUNET_DHT_GetHandle *get_handle = value; | 774 | struct GNUNET_DHT_GetHandle *get_handle = value; |
728 | size_t msize = ntohs (crm->header.size) - sizeof(*crm); | 775 | size_t msize = ntohs (crm->header.size) - sizeof(*crm); |
776 | uint16_t type = ntohl (crm->type); | ||
729 | uint32_t put_path_length = ntohl (crm->put_path_length); | 777 | uint32_t put_path_length = ntohl (crm->put_path_length); |
730 | uint32_t get_path_length = ntohl (crm->get_path_length); | 778 | uint32_t get_path_length = ntohl (crm->get_path_length); |
731 | const struct GNUNET_DHT_PathElement *put_path; | 779 | const struct GNUNET_DHT_PathElement *put_path |
732 | const struct GNUNET_DHT_PathElement *get_path; | 780 | = (const struct GNUNET_DHT_PathElement *) &crm[1]; |
781 | const struct GNUNET_DHT_PathElement *get_path | ||
782 | = &put_path[put_path_length]; | ||
783 | const void *data | ||
784 | = &get_path[get_path_length]; | ||
785 | size_t meta_length | ||
786 | = sizeof(struct GNUNET_DHT_PathElement) * (get_path_length | ||
787 | + put_path_length); | ||
788 | size_t data_length | ||
789 | = msize - meta_length; | ||
733 | struct GNUNET_HashCode hc; | 790 | struct GNUNET_HashCode hc; |
734 | size_t data_length; | ||
735 | size_t meta_length; | ||
736 | const void *data; | ||
737 | 791 | ||
738 | if (crm->unique_id != get_handle->unique_id) | 792 | if (crm->unique_id != get_handle->unique_id) |
739 | { | 793 | { |
@@ -745,12 +799,14 @@ process_client_result (void *cls, | |||
745 | (unsigned long long) get_handle->unique_id); | 799 | (unsigned long long) get_handle->unique_id); |
746 | return GNUNET_YES; | 800 | return GNUNET_YES; |
747 | } | 801 | } |
748 | /* FIXME: might want to check that type matches */ | 802 | if ( (get_handle->type != GNUNET_BLOCK_TYPE_ANY) && |
749 | meta_length = | 803 | (get_handle->type != type) ) |
750 | sizeof(struct GNUNET_DHT_PathElement) * (get_path_length + put_path_length); | 804 | { |
751 | data_length = msize - meta_length; | 805 | /* type mismatch */ |
752 | put_path = (const struct GNUNET_DHT_PathElement *) &crm[1]; | 806 | GNUNET_break (0); |
753 | get_path = &put_path[put_path_length]; | 807 | return GNUNET_YES; |
808 | } | ||
809 | |||
754 | { | 810 | { |
755 | char *pp; | 811 | char *pp; |
756 | char *gp; | 812 | char *gp; |
@@ -768,7 +824,6 @@ process_client_result (void *cls, | |||
768 | GNUNET_free (gp); | 824 | GNUNET_free (gp); |
769 | GNUNET_free (pp); | 825 | GNUNET_free (pp); |
770 | } | 826 | } |
771 | data = &get_path[get_path_length]; | ||
772 | /* remember that we've seen this result */ | 827 | /* remember that we've seen this result */ |
773 | GNUNET_CRYPTO_hash (data, | 828 | GNUNET_CRYPTO_hash (data, |
774 | data_length, | 829 | data_length, |
@@ -786,7 +841,7 @@ process_client_result (void *cls, | |||
786 | get_path_length, | 841 | get_path_length, |
787 | put_path, | 842 | put_path, |
788 | put_path_length, | 843 | put_path_length, |
789 | ntohl (crm->type), | 844 | type, |
790 | data_length, | 845 | data_length, |
791 | data); | 846 | data); |
792 | return GNUNET_YES; | 847 | return GNUNET_YES; |
@@ -813,6 +868,53 @@ handle_client_result (void *cls, | |||
813 | 868 | ||
814 | 869 | ||
815 | /** | 870 | /** |
871 | * Process a client HELLO message received from the service. | ||
872 | * | ||
873 | * @param cls The DHT handle. | ||
874 | * @param hdr HELLO URL message from the service. | ||
875 | * @return #GNUNET_OK if @a hdr is well-formed | ||
876 | */ | ||
877 | static enum GNUNET_GenericReturnValue | ||
878 | check_client_hello (void *cls, | ||
879 | const struct GNUNET_MessageHeader *hdr) | ||
880 | { | ||
881 | uint16_t len = ntohs (hdr->size); | ||
882 | const char *buf = (const char *) &hdr[1]; | ||
883 | |||
884 | (void) cls; | ||
885 | if ('\0' != buf[len - sizeof (*hdr) - 1]) | ||
886 | { | ||
887 | GNUNET_break (0); | ||
888 | return GNUNET_SYSERR; | ||
889 | } | ||
890 | return GNUNET_OK; | ||
891 | } | ||
892 | |||
893 | |||
894 | /** | ||
895 | * Process a client HELLO message received from the service. | ||
896 | * | ||
897 | * @param cls The DHT handle. | ||
898 | * @param hdr HELLO URL message from the service. | ||
899 | */ | ||
900 | static void | ||
901 | handle_client_hello (void *cls, | ||
902 | const struct GNUNET_MessageHeader *hdr) | ||
903 | { | ||
904 | struct GNUNET_DHT_Handle *handle = cls; | ||
905 | const char *url = (const char *) &hdr[1]; | ||
906 | struct GNUNET_DHT_HelloGetHandle *hgh; | ||
907 | |||
908 | while (NULL != (hgh = handle->hgh_head)) | ||
909 | { | ||
910 | hgh->cb (hgh->cb_cls, | ||
911 | url); | ||
912 | GNUNET_DHT_hello_get_cancel (hgh); | ||
913 | } | ||
914 | } | ||
915 | |||
916 | |||
917 | /** | ||
816 | * Process a MQ PUT transmission notification. | 918 | * Process a MQ PUT transmission notification. |
817 | * | 919 | * |
818 | * @param cls The DHT handle. | 920 | * @param cls The DHT handle. |
@@ -859,6 +961,10 @@ try_connect (struct GNUNET_DHT_Handle *h) | |||
859 | GNUNET_MESSAGE_TYPE_DHT_CLIENT_RESULT, | 961 | GNUNET_MESSAGE_TYPE_DHT_CLIENT_RESULT, |
860 | struct GNUNET_DHT_ClientResultMessage, | 962 | struct GNUNET_DHT_ClientResultMessage, |
861 | h), | 963 | h), |
964 | GNUNET_MQ_hd_var_size (client_hello, | ||
965 | GNUNET_MESSAGE_TYPE_DHT_CLIENT_HELLO_URL, | ||
966 | struct GNUNET_MessageHeader, | ||
967 | h), | ||
862 | GNUNET_MQ_handler_end () | 968 | GNUNET_MQ_handler_end () |
863 | }; | 969 | }; |
864 | 970 | ||
@@ -1194,8 +1300,7 @@ GNUNET_DHT_pp2s (const struct GNUNET_DHT_PathElement *path, | |||
1194 | 1300 | ||
1195 | 1301 | ||
1196 | unsigned int | 1302 | unsigned int |
1197 | GNUNET_DHT_verify_path (const struct GNUNET_HashCode *key, | 1303 | GNUNET_DHT_verify_path (const void *data, |
1198 | const void *data, | ||
1199 | size_t data_size, | 1304 | size_t data_size, |
1200 | struct GNUNET_TIME_Absolute exp_time, | 1305 | struct GNUNET_TIME_Absolute exp_time, |
1201 | const struct GNUNET_DHT_PathElement *put_path, | 1306 | const struct GNUNET_DHT_PathElement *put_path, |
@@ -1207,47 +1312,125 @@ GNUNET_DHT_verify_path (const struct GNUNET_HashCode *key, | |||
1207 | struct GNUNET_DHT_HopSignature hs = { | 1312 | struct GNUNET_DHT_HopSignature hs = { |
1208 | .purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_DHT_HOP), | 1313 | .purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_DHT_HOP), |
1209 | .purpose.size = htonl (sizeof (hs)), | 1314 | .purpose.size = htonl (sizeof (hs)), |
1210 | .expiration_time = GNUNET_TIME_absolute_hton (exp_time), | 1315 | .expiration_time = GNUNET_TIME_absolute_hton (exp_time) |
1211 | .key = *key, | ||
1212 | }; | 1316 | }; |
1317 | const struct GNUNET_PeerIdentity *pred; | ||
1318 | const struct GNUNET_PeerIdentity *succ; | ||
1213 | unsigned int i; | 1319 | unsigned int i; |
1214 | 1320 | ||
1215 | if (0 == get_path_len + put_path_len) | 1321 | if (0 == get_path_len + put_path_len) |
1216 | return 0; | 1322 | return 0; |
1217 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, | 1323 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1218 | "Verifying signatures with GPL: %u PPL: %u!\n", | 1324 | "%s is verifying signatures with GPL: %u PPL: %u!\n", |
1325 | GNUNET_i2s (me), | ||
1219 | get_path_len, | 1326 | get_path_len, |
1220 | put_path_len); | 1327 | put_path_len); |
1328 | for (unsigned int j = 0; j<put_path_len; j++) | ||
1329 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1330 | "PP%u=%s\n", | ||
1331 | j, | ||
1332 | GNUNET_i2s (&put_path[j].pred)); | ||
1333 | for (unsigned int j = 0; j<get_path_len; j++) | ||
1334 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1335 | "GP%u=%s\n", | ||
1336 | j, | ||
1337 | GNUNET_i2s (&get_path[j].pred)); | ||
1338 | |||
1221 | i = put_path_len + get_path_len - 1; | 1339 | i = put_path_len + get_path_len - 1; |
1222 | GNUNET_CRYPTO_hash (data, | 1340 | GNUNET_CRYPTO_hash (data, |
1223 | data_size, | 1341 | data_size, |
1224 | &hs.h_data); | 1342 | &hs.h_data); |
1225 | while (i > 0) | 1343 | while (i > 0) |
1226 | { | 1344 | { |
1227 | hs.pred = (i - 1 >= put_path_len) | 1345 | pred = (i - 1 >= put_path_len) |
1228 | ? get_path[i - put_path_len - 1].pred | 1346 | ? &get_path[i - put_path_len - 1].pred |
1229 | : put_path[i - 1].pred; | 1347 | : &put_path[i - 1].pred; |
1230 | if (i + 1 == get_path_len + put_path_len) | 1348 | if (i + 1 == get_path_len + put_path_len) |
1231 | hs.succ = *me; | 1349 | succ = me; |
1232 | else | 1350 | else |
1233 | hs.succ = (i + 1 >= put_path_len) | 1351 | succ = (i + 1 >= put_path_len) |
1234 | ? get_path[i + 1 - put_path_len].pred | 1352 | ? &get_path[i + 1 - put_path_len].pred |
1235 | : put_path[i + 1].pred; | 1353 | : &put_path[i + 1].pred; |
1354 | hs.pred = *pred; | ||
1355 | hs.succ = *succ; | ||
1236 | if (GNUNET_OK != | 1356 | if (GNUNET_OK != |
1237 | GNUNET_CRYPTO_eddsa_verify ( | 1357 | GNUNET_CRYPTO_eddsa_verify ( |
1238 | GNUNET_SIGNATURE_PURPOSE_DHT_HOP, | 1358 | GNUNET_SIGNATURE_PURPOSE_DHT_HOP, |
1239 | &hs, | 1359 | &hs, |
1240 | (i - 1 >= put_path_len) | 1360 | (i - 1 >= put_path_len) |
1241 | ? &get_path[i - put_path_len - 1].sig | 1361 | ? &get_path[i - put_path_len - 1].sig |
1242 | : &put_path[i - 1].sig, | 1362 | : &put_path[i - 1].sig, |
1243 | (i >= put_path_len) | 1363 | (i >= put_path_len) |
1244 | ? &get_path[i - put_path_len].pred.public_key | 1364 | ? &get_path[i - put_path_len].pred.public_key |
1245 | : &put_path[i].pred.public_key)) | 1365 | : &put_path[i].pred.public_key)) |
1366 | { | ||
1367 | GNUNET_break_op (0); | ||
1246 | return i; | 1368 | return i; |
1369 | } | ||
1247 | i--; | 1370 | i--; |
1248 | } | 1371 | } |
1249 | return i; | 1372 | return i; |
1250 | } | 1373 | } |
1251 | 1374 | ||
1252 | 1375 | ||
1376 | struct GNUNET_DHT_HelloGetHandle * | ||
1377 | GNUNET_DHT_hello_get (struct GNUNET_DHT_Handle *dht_handle, | ||
1378 | GNUNET_DHT_HelloGetCallback cb, | ||
1379 | void *cb_cls) | ||
1380 | { | ||
1381 | struct GNUNET_DHT_HelloGetHandle *hgh; | ||
1382 | struct GNUNET_MessageHeader *hdr; | ||
1383 | struct GNUNET_MQ_Envelope *env; | ||
1384 | |||
1385 | hgh = GNUNET_new (struct GNUNET_DHT_HelloGetHandle); | ||
1386 | hgh->cb = cb; | ||
1387 | hgh->cb_cls = cb_cls; | ||
1388 | hgh->dht_handle = dht_handle; | ||
1389 | GNUNET_CONTAINER_DLL_insert (dht_handle->hgh_head, | ||
1390 | dht_handle->hgh_tail, | ||
1391 | hgh); | ||
1392 | env = GNUNET_MQ_msg (hdr, | ||
1393 | GNUNET_MESSAGE_TYPE_DHT_CLIENT_HELLO_GET); | ||
1394 | GNUNET_MQ_send (dht_handle->mq, | ||
1395 | env); | ||
1396 | return hgh; | ||
1397 | } | ||
1398 | |||
1399 | |||
1400 | void | ||
1401 | GNUNET_DHT_hello_get_cancel (struct GNUNET_DHT_HelloGetHandle *hgh) | ||
1402 | { | ||
1403 | struct GNUNET_DHT_Handle *dht_handle = hgh->dht_handle; | ||
1404 | |||
1405 | GNUNET_CONTAINER_DLL_remove (dht_handle->hgh_head, | ||
1406 | dht_handle->hgh_tail, | ||
1407 | hgh); | ||
1408 | GNUNET_free (hgh); | ||
1409 | } | ||
1410 | |||
1411 | |||
1412 | void | ||
1413 | GNUNET_DHT_hello_offer (struct GNUNET_DHT_Handle *dht_handle, | ||
1414 | const char *url, | ||
1415 | GNUNET_SCHEDULER_TaskCallback cb, | ||
1416 | void *cb_cls) | ||
1417 | { | ||
1418 | struct GNUNET_MessageHeader *hdr; | ||
1419 | size_t slen = strlen (url) + 1; | ||
1420 | struct GNUNET_MQ_Envelope *env; | ||
1421 | |||
1422 | env = GNUNET_MQ_msg_extra (hdr, | ||
1423 | slen, | ||
1424 | GNUNET_MESSAGE_TYPE_DHT_CLIENT_HELLO_URL); | ||
1425 | memcpy (&hdr[1], | ||
1426 | url, | ||
1427 | slen); | ||
1428 | GNUNET_MQ_notify_sent (env, | ||
1429 | cb, | ||
1430 | cb_cls); | ||
1431 | GNUNET_MQ_send (dht_handle->mq, | ||
1432 | env); | ||
1433 | } | ||
1434 | |||
1435 | |||
1253 | /* end of dht_api.c */ | 1436 | /* end of dht_api.c */ |
diff --git a/src/dht/dhtu_testbed_connect.sh b/src/dht/dhtu_testbed_connect.sh new file mode 100755 index 000000000..871e9eb1b --- /dev/null +++ b/src/dht/dhtu_testbed_connect.sh | |||
@@ -0,0 +1,31 @@ | |||
1 | #!/bin/bash | ||
2 | # This file is in the public domain. | ||
3 | |||
4 | # Helper script for dhtu_testbed_deploy.sh. | ||
5 | # Do not invoke directly. | ||
6 | |||
7 | n=$1 | ||
8 | CFG="/tmp/deployment/${n}.conf" | ||
9 | HELLO=`gnunet-dht-hello -c $CFG` | ||
10 | |||
11 | # Create dense topology: | ||
12 | #for OFF in `seq 1 $MAX` | ||
13 | #do | ||
14 | # TCFG="/tmp/deployment/${OFF}.conf" | ||
15 | # gnunet-dht-hello -c $TCFG $HELLO | ||
16 | #done | ||
17 | #exit 0 | ||
18 | |||
19 | # Create sparse topology: | ||
20 | R=1 | ||
21 | while test `expr $R \* $R \* $R` -lt $MAX | ||
22 | do | ||
23 | END=`expr $R \* $R` | ||
24 | for M in `seq $R $R $END` | ||
25 | do | ||
26 | OFF=`expr \( $n + $M \) % $MAX` | ||
27 | TCFG="/tmp/deployment/${OFF}.conf" | ||
28 | gnunet-dht-hello -c $TCFG $HELLO | ||
29 | done | ||
30 | R=`expr $R + 1` | ||
31 | done | ||
diff --git a/src/dht/dhtu_testbed_deploy.conf b/src/dht/dhtu_testbed_deploy.conf new file mode 100644 index 000000000..59d69894a --- /dev/null +++ b/src/dht/dhtu_testbed_deploy.conf | |||
@@ -0,0 +1,26 @@ | |||
1 | # This file is in the public domain. | ||
2 | |||
3 | # Simple configuration template to deploy a DHT testbed | ||
4 | # with peers using the IP underlay. | ||
5 | |||
6 | [paths] | ||
7 | GNUNET_DATA_HOME=/tmp/%N% | ||
8 | |||
9 | [dht] | ||
10 | UNIXPATH = $GNUNET_RUNTIME_DIR/gnunet-service-dht-%N%.sock | ||
11 | |||
12 | [dhtu-ip] | ||
13 | ENABLED = YES | ||
14 | NSE = 10 | ||
15 | UDP_PORT = %N% | ||
16 | |||
17 | [dhtu-gnunet] | ||
18 | ENABLED = NO | ||
19 | |||
20 | [statistics] | ||
21 | DISABLE = YES | ||
22 | |||
23 | [dhtcache] | ||
24 | DATABASE = heap | ||
25 | QUOTA = 50 MB | ||
26 | DISABLE_BF_RC = YES | ||
diff --git a/src/dht/dhtu_testbed_deploy.sh b/src/dht/dhtu_testbed_deploy.sh new file mode 100755 index 000000000..908bbf685 --- /dev/null +++ b/src/dht/dhtu_testbed_deploy.sh | |||
@@ -0,0 +1,84 @@ | |||
1 | #!/bin/bash | ||
2 | # This file is in the public domain. | ||
3 | |||
4 | # We will use UDP ports above this number. | ||
5 | MINPORT=10000 | ||
6 | |||
7 | # Cleanup to run whenever we exit | ||
8 | function cleanup() | ||
9 | { | ||
10 | for n in `jobs -p` | ||
11 | do | ||
12 | kill $n 2> /dev/null || true | ||
13 | done | ||
14 | wait | ||
15 | } | ||
16 | |||
17 | # Install cleanup handler (except for kill -9) | ||
18 | trap cleanup EXIT | ||
19 | |||
20 | if test -z "$1" | ||
21 | then | ||
22 | echo "Call with the number of peers to launch." | ||
23 | exit 1 | ||
24 | fi | ||
25 | |||
26 | if test ! -x `which parallel` | ||
27 | then | ||
28 | echo "This script requires GNU parallel" | ||
29 | exit 1 | ||
30 | fi | ||
31 | |||
32 | if test ! -x `which gnunet-service-dht` | ||
33 | then | ||
34 | echo "This script requires gnunet-service-dht in \$PATH" | ||
35 | exit 1 | ||
36 | fi | ||
37 | |||
38 | if test ! -x `which gnunet-dht-hello` | ||
39 | then | ||
40 | echo "This script requires gnunet-dht-hello in \$PATH" | ||
41 | exit 1 | ||
42 | fi | ||
43 | |||
44 | MAX=`expr $1 - 1` | ||
45 | |||
46 | # export GNUNET_FORCE_LOG="dht*;;;;DEBUG" | ||
47 | |||
48 | echo -n "Starting $1 peers " | ||
49 | mkdir -p /tmp/deployment | ||
50 | for n in `seq 0 $MAX` | ||
51 | do | ||
52 | PORT=`expr $MINPORT + $n` | ||
53 | CFG="/tmp/deployment/${n}.conf" | ||
54 | cat dhtu_testbed_deploy.conf | sed -e "s/%N%/$PORT/" > $CFG | ||
55 | gnunet-service-dht -c $CFG &> /tmp/deployment/$n.log & | ||
56 | echo -n "." | ||
57 | done | ||
58 | |||
59 | echo "" | ||
60 | echo "$1 peers ready". | ||
61 | |||
62 | unset GNUNET_FORCE_LOG | ||
63 | |||
64 | function connect() | ||
65 | { | ||
66 | n=$1 | ||
67 | } | ||
68 | |||
69 | echo -n "Connecting peers ..." | ||
70 | |||
71 | export MAX | ||
72 | if test 0 != $MAX | ||
73 | then | ||
74 | seq 0 $MAX | parallel ./dhtu_testbed_connect.sh ::: | ||
75 | fi | ||
76 | |||
77 | |||
78 | echo "" | ||
79 | echo "Network ready. Press ENTER to terminate the testbed!" | ||
80 | echo "Interact with peers using '-c /tmp/deployment/\$N.conf'" | ||
81 | |||
82 | read | ||
83 | |||
84 | exit 0 | ||
diff --git a/src/dht/gnunet-dht-get.c b/src/dht/gnunet-dht-get.c index f1076490b..42ffe75ba 100644 --- a/src/dht/gnunet-dht-get.c +++ b/src/dht/gnunet-dht-get.c | |||
@@ -58,6 +58,11 @@ static unsigned int verbose; | |||
58 | static int demultixplex_everywhere; | 58 | static int demultixplex_everywhere; |
59 | 59 | ||
60 | /** | 60 | /** |
61 | * Use #GNUNET_DHT_RO_RECORD_ROUTE. | ||
62 | */ | ||
63 | static int record_route; | ||
64 | |||
65 | /** | ||
61 | * Handle to the DHT | 66 | * Handle to the DHT |
62 | */ | 67 | */ |
63 | static struct GNUNET_DHT_Handle *dht_handle; | 68 | static struct GNUNET_DHT_Handle *dht_handle; |
@@ -160,9 +165,9 @@ get_result_iterator (void *cls, | |||
160 | : _ ("Result %d, type %d:\n"), | 165 | : _ ("Result %d, type %d:\n"), |
161 | result_count, | 166 | result_count, |
162 | type, | 167 | type, |
163 | (unsigned int) size, | 168 | (int) size, |
164 | (char *) data); | 169 | (char *) data); |
165 | if (verbose) | 170 | if (record_route && verbose) |
166 | { | 171 | { |
167 | fprintf (stdout, | 172 | fprintf (stdout, |
168 | " GET path: "); | 173 | " GET path: "); |
@@ -200,6 +205,7 @@ run (void *cls, | |||
200 | const struct GNUNET_CONFIGURATION_Handle *c) | 205 | const struct GNUNET_CONFIGURATION_Handle *c) |
201 | { | 206 | { |
202 | struct GNUNET_HashCode key; | 207 | struct GNUNET_HashCode key; |
208 | enum GNUNET_DHT_RouteOption ro; | ||
203 | 209 | ||
204 | cfg = c; | 210 | cfg = c; |
205 | if (NULL == query_key) | 211 | if (NULL == query_key) |
@@ -228,13 +234,16 @@ run (void *cls, | |||
228 | GNUNET_h2s_full (&key)); | 234 | GNUNET_h2s_full (&key)); |
229 | GNUNET_SCHEDULER_add_shutdown (&cleanup_task, NULL); | 235 | GNUNET_SCHEDULER_add_shutdown (&cleanup_task, NULL); |
230 | tt = GNUNET_SCHEDULER_add_delayed (timeout_request, &timeout_task, NULL); | 236 | tt = GNUNET_SCHEDULER_add_delayed (timeout_request, &timeout_task, NULL); |
237 | ro = GNUNET_DHT_RO_NONE; | ||
238 | if (demultixplex_everywhere) | ||
239 | ro |= GNUNET_DHT_RO_DEMULTIPLEX_EVERYWHERE; | ||
240 | if (record_route) | ||
241 | ro |= GNUNET_DHT_RO_RECORD_ROUTE; | ||
231 | get_handle = GNUNET_DHT_get_start (dht_handle, | 242 | get_handle = GNUNET_DHT_get_start (dht_handle, |
232 | query_type, | 243 | query_type, |
233 | &key, | 244 | &key, |
234 | replication, | 245 | replication, |
235 | (demultixplex_everywhere) | 246 | ro, |
236 | ? GNUNET_DHT_RO_DEMULTIPLEX_EVERYWHERE | ||
237 | : GNUNET_DHT_RO_NONE, | ||
238 | NULL, | 247 | NULL, |
239 | 0, | 248 | 0, |
240 | &get_result_iterator, | 249 | &get_result_iterator, |
@@ -265,6 +274,11 @@ main (int argc, char *const *argv) | |||
265 | "LEVEL", | 274 | "LEVEL", |
266 | gettext_noop ("how many parallel requests (replicas) to create"), | 275 | gettext_noop ("how many parallel requests (replicas) to create"), |
267 | &replication), | 276 | &replication), |
277 | GNUNET_GETOPT_option_flag ( | ||
278 | 'R', | ||
279 | "record", | ||
280 | gettext_noop ("use DHT's record route option"), | ||
281 | &record_route), | ||
268 | GNUNET_GETOPT_option_uint ( | 282 | GNUNET_GETOPT_option_uint ( |
269 | 't', | 283 | 't', |
270 | "type", | 284 | "type", |
diff --git a/src/dht/gnunet-dht-hello.c b/src/dht/gnunet-dht-hello.c new file mode 100644 index 000000000..369ed5643 --- /dev/null +++ b/src/dht/gnunet-dht-hello.c | |||
@@ -0,0 +1,178 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2022 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 dht/gnunet-dht-hello.c | ||
22 | * @brief Obtain HELLO from DHT for bootstrapping | ||
23 | * @author Christian Grothoff | ||
24 | */ | ||
25 | #include "platform.h" | ||
26 | #include "gnunet_dht_service.h" | ||
27 | |||
28 | #define LOG(kind, ...) GNUNET_log_from (kind, "dht-clients", __VA_ARGS__) | ||
29 | |||
30 | /** | ||
31 | * Handle to the DHT | ||
32 | */ | ||
33 | static struct GNUNET_DHT_Handle *dht_handle; | ||
34 | |||
35 | /** | ||
36 | * Handle to the DHT hello get operation. | ||
37 | */ | ||
38 | static struct GNUNET_DHT_HelloGetHandle *get_hello_handle; | ||
39 | |||
40 | /** | ||
41 | * Global status value | ||
42 | */ | ||
43 | static int global_ret; | ||
44 | |||
45 | |||
46 | /** | ||
47 | * Task run to clean up on shutdown. | ||
48 | * | ||
49 | * @param cls unused | ||
50 | */ | ||
51 | static void | ||
52 | cleanup_task (void *cls) | ||
53 | { | ||
54 | if (NULL != get_hello_handle) | ||
55 | { | ||
56 | GNUNET_DHT_hello_get_cancel (get_hello_handle); | ||
57 | get_hello_handle = NULL; | ||
58 | } | ||
59 | if (NULL != dht_handle) | ||
60 | { | ||
61 | GNUNET_DHT_disconnect (dht_handle); | ||
62 | dht_handle = NULL; | ||
63 | } | ||
64 | } | ||
65 | |||
66 | |||
67 | /** | ||
68 | * Task run when we are finished. Triggers shutdown. | ||
69 | * | ||
70 | * @param cls unused | ||
71 | */ | ||
72 | static void | ||
73 | hello_done_cb (void *cls) | ||
74 | { | ||
75 | GNUNET_SCHEDULER_shutdown (); | ||
76 | } | ||
77 | |||
78 | |||
79 | /** | ||
80 | * Function called on our HELLO. | ||
81 | * | ||
82 | * @param cls closure | ||
83 | * @param url the HELLO URL | ||
84 | */ | ||
85 | static void | ||
86 | hello_result_cb (void *cls, | ||
87 | const char *url) | ||
88 | { | ||
89 | get_hello_handle = NULL; | ||
90 | fprintf (stdout, | ||
91 | "%s\n", | ||
92 | url); | ||
93 | GNUNET_SCHEDULER_shutdown (); | ||
94 | } | ||
95 | |||
96 | |||
97 | /** | ||
98 | * Main function that will be run by the scheduler. | ||
99 | * | ||
100 | * @param cls closure, NULL | ||
101 | * @param args remaining command-line arguments | ||
102 | * @param cfgfile name of the configuration file used (for saving, can be NULL!) | ||
103 | * @param cfg configuration | ||
104 | */ | ||
105 | static void | ||
106 | run (void *cls, | ||
107 | char *const *args, | ||
108 | const char *cfgfile, | ||
109 | const struct GNUNET_CONFIGURATION_Handle *cfg) | ||
110 | { | ||
111 | (void) cls; | ||
112 | (void) cfgfile; | ||
113 | GNUNET_SCHEDULER_add_shutdown (&cleanup_task, | ||
114 | NULL); | ||
115 | if (NULL == (dht_handle = GNUNET_DHT_connect (cfg, | ||
116 | 1))) | ||
117 | { | ||
118 | fprintf (stderr, | ||
119 | _ ("Failed to connect to DHT service!\n")); | ||
120 | global_ret = EXIT_NOTCONFIGURED; | ||
121 | GNUNET_SCHEDULER_shutdown (); | ||
122 | return; | ||
123 | } | ||
124 | if (NULL == args[0]) | ||
125 | { | ||
126 | get_hello_handle = GNUNET_DHT_hello_get (dht_handle, | ||
127 | &hello_result_cb, | ||
128 | NULL); | ||
129 | GNUNET_break (NULL != get_hello_handle); | ||
130 | } | ||
131 | else | ||
132 | { | ||
133 | GNUNET_DHT_hello_offer (dht_handle, | ||
134 | args[0], | ||
135 | &hello_done_cb, | ||
136 | NULL); | ||
137 | } | ||
138 | } | ||
139 | |||
140 | |||
141 | /** | ||
142 | * Entry point for gnunet-dht-hello | ||
143 | * | ||
144 | * @param argc number of arguments from the command line | ||
145 | * @param argv command line arguments | ||
146 | * @return 0 ok, 1 on error | ||
147 | */ | ||
148 | int | ||
149 | main (int argc, | ||
150 | char *const *argv) | ||
151 | { | ||
152 | struct GNUNET_GETOPT_CommandLineOption options[] = { | ||
153 | GNUNET_GETOPT_OPTION_END | ||
154 | }; | ||
155 | enum GNUNET_GenericReturnValue iret; | ||
156 | |||
157 | if (GNUNET_OK != | ||
158 | GNUNET_STRINGS_get_utf8_args (argc, argv, | ||
159 | &argc, &argv)) | ||
160 | return 2; | ||
161 | iret = GNUNET_PROGRAM_run ( | ||
162 | argc, | ||
163 | argv, | ||
164 | "gnunet-dht-hello [URL]", | ||
165 | gettext_noop ( | ||
166 | "Obtain HELLO from DHT or provide HELLO to DHT for bootstrapping"), | ||
167 | options, | ||
168 | &run, | ||
169 | NULL); | ||
170 | if (GNUNET_SYSERR == iret) | ||
171 | return EXIT_FAILURE; | ||
172 | if (GNUNET_NO == iret) | ||
173 | return EXIT_SUCCESS; | ||
174 | return global_ret; | ||
175 | } | ||
176 | |||
177 | |||
178 | /* end of gnunet-dht-hello.c */ | ||
diff --git a/src/dht/gnunet-service-dht.c b/src/dht/gnunet-service-dht.c index da46dcfee..39433791d 100644 --- a/src/dht/gnunet-service-dht.c +++ b/src/dht/gnunet-service-dht.c | |||
@@ -27,53 +27,335 @@ | |||
27 | #include "platform.h" | 27 | #include "platform.h" |
28 | #include "gnunet_block_lib.h" | 28 | #include "gnunet_block_lib.h" |
29 | #include "gnunet_util_lib.h" | 29 | #include "gnunet_util_lib.h" |
30 | #include "gnunet_transport_service.h" | ||
31 | #include "gnunet_transport_hello_service.h" | ||
32 | #include "gnunet_hello_lib.h" | 30 | #include "gnunet_hello_lib.h" |
31 | #include "gnunet_hello_uri_lib.h" | ||
33 | #include "gnunet_dht_service.h" | 32 | #include "gnunet_dht_service.h" |
34 | #include "gnunet_statistics_service.h" | 33 | #include "gnunet_statistics_service.h" |
35 | #include "gnunet-service-dht.h" | 34 | #include "gnunet-service-dht.h" |
36 | #include "gnunet-service-dht_datacache.h" | 35 | #include "gnunet-service-dht_datacache.h" |
37 | #include "gnunet-service-dht_hello.h" | ||
38 | #include "gnunet-service-dht_neighbours.h" | 36 | #include "gnunet-service-dht_neighbours.h" |
39 | #include "gnunet-service-dht_nse.h" | ||
40 | #include "gnunet-service-dht_routing.h" | 37 | #include "gnunet-service-dht_routing.h" |
41 | 38 | ||
42 | /** | 39 | /** |
40 | * How often do we broadcast our HELLO to neighbours if | ||
41 | * nothing special happens? | ||
42 | */ | ||
43 | #define HELLO_FREQUENCY GNUNET_TIME_UNIT_HOURS | ||
44 | |||
45 | |||
46 | /** | ||
47 | * Information we keep per underlay. | ||
48 | */ | ||
49 | struct GDS_Underlay | ||
50 | { | ||
51 | |||
52 | /** | ||
53 | * Kept in a DLL. | ||
54 | */ | ||
55 | struct GDS_Underlay *next; | ||
56 | |||
57 | /** | ||
58 | * Kept in a DLL. | ||
59 | */ | ||
60 | struct GDS_Underlay *prev; | ||
61 | |||
62 | /** | ||
63 | * Environment for this underlay. | ||
64 | */ | ||
65 | struct GNUNET_DHTU_PluginEnvironment env; | ||
66 | |||
67 | /** | ||
68 | * Underlay API handle. | ||
69 | */ | ||
70 | struct GNUNET_DHTU_PluginFunctions *dhtu; | ||
71 | |||
72 | /** | ||
73 | * current network size estimate for this underlay. | ||
74 | */ | ||
75 | double network_size_estimate; | ||
76 | |||
77 | /** | ||
78 | * Name of the underlay (i.e. "gnunet" or "ip"). | ||
79 | */ | ||
80 | char *name; | ||
81 | |||
82 | /** | ||
83 | * Name of the library providing the underlay. | ||
84 | */ | ||
85 | char *libname; | ||
86 | }; | ||
87 | |||
88 | |||
89 | /** | ||
90 | * An address of this peer. | ||
91 | */ | ||
92 | struct MyAddress | ||
93 | { | ||
94 | /** | ||
95 | * Kept in a DLL. | ||
96 | */ | ||
97 | struct MyAddress *next; | ||
98 | |||
99 | /** | ||
100 | * Kept in a DLL. | ||
101 | */ | ||
102 | struct MyAddress *prev; | ||
103 | |||
104 | /** | ||
105 | * Underlay handle for the address. | ||
106 | */ | ||
107 | struct GNUNET_DHTU_Source *source; | ||
108 | |||
109 | /** | ||
110 | * Textual representation of the address. | ||
111 | */ | ||
112 | char *url; | ||
113 | |||
114 | /** | ||
115 | * Underlay of this address. | ||
116 | */ | ||
117 | struct GDS_Underlay *u; | ||
118 | }; | ||
119 | |||
120 | |||
121 | /** | ||
43 | * Our HELLO | 122 | * Our HELLO |
44 | */ | 123 | */ |
45 | struct GNUNET_MessageHeader *GDS_my_hello; | 124 | struct GNUNET_HELLO_Builder *GDS_my_hello; |
46 | 125 | ||
47 | /** | 126 | /** |
48 | * Handle to get our current HELLO. | 127 | * Identity of this peer. |
49 | */ | 128 | */ |
50 | static struct GNUNET_TRANSPORT_HelloGetHandle *ghh; | 129 | struct GNUNET_PeerIdentity GDS_my_identity; |
51 | 130 | ||
52 | /** | 131 | /** |
53 | * Hello address expiration | 132 | * Hash of the identity of this peer. |
54 | */ | 133 | */ |
55 | struct GNUNET_TIME_Relative hello_expiration; | 134 | struct GNUNET_HashCode GDS_my_identity_hash; |
135 | |||
136 | /** | ||
137 | * Our private key. | ||
138 | */ | ||
139 | struct GNUNET_CRYPTO_EddsaPrivateKey GDS_my_private_key; | ||
140 | |||
141 | /** | ||
142 | * Task broadcasting our HELLO. | ||
143 | */ | ||
144 | static struct GNUNET_SCHEDULER_Task *hello_task; | ||
145 | |||
146 | /** | ||
147 | * Handles for the DHT underlays. | ||
148 | */ | ||
149 | static struct GDS_Underlay *u_head; | ||
150 | |||
151 | /** | ||
152 | * Handles for the DHT underlays. | ||
153 | */ | ||
154 | static struct GDS_Underlay *u_tail; | ||
155 | |||
156 | /** | ||
157 | * Head of addresses of this peer. | ||
158 | */ | ||
159 | static struct MyAddress *a_head; | ||
160 | |||
161 | /** | ||
162 | * Tail of addresses of this peer. | ||
163 | */ | ||
164 | static struct MyAddress *a_tail; | ||
165 | |||
166 | /** | ||
167 | * log of the current network size estimate, used as the point where | ||
168 | * we switch between random and deterministic routing. | ||
169 | */ | ||
170 | static double log_of_network_size_estimate; | ||
171 | |||
172 | |||
173 | /** | ||
174 | * Callback that is called when network size estimate is updated. | ||
175 | * | ||
176 | * @param cls a `struct GDS_Underlay` | ||
177 | * @param timestamp time when the estimate was received from the server (or created by the server) | ||
178 | * @param logestimate the log(Base 2) value of the current network size estimate | ||
179 | * @param std_dev standard deviation for the estimate | ||
180 | * | ||
181 | */ | ||
182 | static void | ||
183 | update_network_size_estimate (void *cls, | ||
184 | struct GNUNET_TIME_Absolute timestamp, | ||
185 | double logestimate, | ||
186 | double std_dev) | ||
187 | { | ||
188 | struct GDS_Underlay *u = cls; | ||
189 | double sum = 0.0; | ||
190 | |||
191 | GNUNET_STATISTICS_update (GDS_stats, | ||
192 | "# Network size estimates received", | ||
193 | 1, | ||
194 | GNUNET_NO); | ||
195 | /* do not allow estimates < 0.5 */ | ||
196 | u->network_size_estimate = pow (2.0, | ||
197 | GNUNET_MAX (0.5, | ||
198 | logestimate)); | ||
199 | for (struct GDS_Underlay *p = u_head; NULL != p; p = p->next) | ||
200 | sum += p->network_size_estimate; | ||
201 | if (sum <= 2.0) | ||
202 | log_of_network_size_estimate = 0.5; | ||
203 | else | ||
204 | log_of_network_size_estimate = log2 (sum); | ||
205 | } | ||
206 | |||
207 | |||
208 | /** | ||
209 | * Return the current NSE | ||
210 | * | ||
211 | * @return the current NSE as a logarithm | ||
212 | */ | ||
213 | double | ||
214 | GDS_NSE_get (void) | ||
215 | { | ||
216 | return log_of_network_size_estimate; | ||
217 | } | ||
56 | 218 | ||
57 | 219 | ||
58 | #include "gnunet-service-dht_clients.c" | 220 | #include "gnunet-service-dht_clients.c" |
59 | 221 | ||
60 | 222 | ||
61 | /** | 223 | /** |
62 | * Receive the HELLO from transport service, free current and replace | 224 | * Task run periodically to broadcast our HELLO. |
63 | * if necessary. | ||
64 | * | 225 | * |
65 | * @param cls NULL | 226 | * @param cls NULL |
66 | * @param message HELLO message of peer | ||
67 | */ | 227 | */ |
68 | static void | 228 | static void |
69 | process_hello (void *cls, | 229 | broadcast_hello (void *cls) |
70 | const struct GNUNET_MessageHeader *message) | ||
71 | { | 230 | { |
72 | GNUNET_free (GDS_my_hello); | 231 | struct GNUNET_MessageHeader *hello; |
73 | GDS_my_hello = GNUNET_malloc (ntohs (message->size)); | 232 | |
74 | GNUNET_memcpy (GDS_my_hello, | 233 | (void) cls; |
75 | message, | 234 | /* TODO: randomize! */ |
76 | ntohs (message->size)); | 235 | hello_task = GNUNET_SCHEDULER_add_delayed (HELLO_FREQUENCY, |
236 | &broadcast_hello, | ||
237 | NULL); | ||
238 | hello = GNUNET_HELLO_builder_to_dht_hello_msg (GDS_my_hello, | ||
239 | &GDS_my_private_key); | ||
240 | if (NULL == hello) | ||
241 | { | ||
242 | GNUNET_break (0); | ||
243 | return; | ||
244 | } | ||
245 | GDS_NEIGHBOURS_broadcast (hello); | ||
246 | GNUNET_free (hello); | ||
247 | } | ||
248 | |||
249 | |||
250 | /** | ||
251 | * Function to call with new addresses of this peer. | ||
252 | * | ||
253 | * @param cls the closure | ||
254 | * @param address address under which we are likely reachable, | ||
255 | * pointer will remain valid until @e address_del_cb is called; to be used for HELLOs. Example: "ip+udp://$PID/1.1.1.1:2086/" | ||
256 | * @param source handle for sending from this address, NULL if we can only receive | ||
257 | * @param[out] ctx storage space for DHT to use in association with this address | ||
258 | */ | ||
259 | static void | ||
260 | u_address_add (void *cls, | ||
261 | const char *address, | ||
262 | struct GNUNET_DHTU_Source *source, | ||
263 | void **ctx) | ||
264 | { | ||
265 | struct GDS_Underlay *u = cls; | ||
266 | struct MyAddress *a; | ||
267 | |||
268 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, | ||
269 | "Underlay adds address %s for this peer\n", | ||
270 | address); | ||
271 | a = GNUNET_new (struct MyAddress); | ||
272 | a->source = source; | ||
273 | a->url = GNUNET_strdup (address); | ||
274 | a->u = u; | ||
275 | GNUNET_CONTAINER_DLL_insert (a_head, | ||
276 | a_tail, | ||
277 | a); | ||
278 | *ctx = a; | ||
279 | GNUNET_HELLO_builder_add_address (GDS_my_hello, | ||
280 | address); | ||
281 | if (NULL != hello_task) | ||
282 | GNUNET_SCHEDULER_cancel (hello_task); | ||
283 | hello_task = GNUNET_SCHEDULER_add_now (&broadcast_hello, | ||
284 | NULL); | ||
285 | } | ||
286 | |||
287 | |||
288 | /** | ||
289 | * Function to call with expired addresses of this peer. | ||
290 | * | ||
291 | * @param[in] ctx storage space used by the DHT in association with this address | ||
292 | */ | ||
293 | static void | ||
294 | u_address_del (void *ctx) | ||
295 | { | ||
296 | struct MyAddress *a = ctx; | ||
297 | |||
298 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, | ||
299 | "Underlay deletes address %s for this peer\n", | ||
300 | a->url); | ||
301 | GNUNET_HELLO_builder_del_address (GDS_my_hello, | ||
302 | a->url); | ||
303 | GNUNET_CONTAINER_DLL_remove (a_head, | ||
304 | a_tail, | ||
305 | a); | ||
306 | GNUNET_free (a->url); | ||
307 | GNUNET_free (a); | ||
308 | if (NULL != hello_task) | ||
309 | GNUNET_SCHEDULER_cancel (hello_task); | ||
310 | hello_task = GNUNET_SCHEDULER_add_now (&broadcast_hello, | ||
311 | NULL); | ||
312 | } | ||
313 | |||
314 | |||
315 | void | ||
316 | GDS_u_try_connect (const struct GNUNET_PeerIdentity *pid, | ||
317 | const char *address) | ||
318 | { | ||
319 | for (struct GDS_Underlay *u = u_head; | ||
320 | NULL != u; | ||
321 | u = u->next) | ||
322 | u->dhtu->try_connect (u->dhtu->cls, | ||
323 | pid, | ||
324 | address); | ||
325 | } | ||
326 | |||
327 | |||
328 | void | ||
329 | GDS_u_send (struct GDS_Underlay *u, | ||
330 | struct GNUNET_DHTU_Target *target, | ||
331 | const void *msg, | ||
332 | size_t msg_size, | ||
333 | GNUNET_SCHEDULER_TaskCallback finished_cb, | ||
334 | void *finished_cb_cls) | ||
335 | { | ||
336 | u->dhtu->send (u->dhtu->cls, | ||
337 | target, | ||
338 | msg, | ||
339 | msg_size, | ||
340 | finished_cb, | ||
341 | finished_cb_cls); | ||
342 | } | ||
343 | |||
344 | |||
345 | void | ||
346 | GDS_u_drop (struct GDS_Underlay *u, | ||
347 | struct GNUNET_DHTU_PreferenceHandle *ph) | ||
348 | { | ||
349 | u->dhtu->drop (ph); | ||
350 | } | ||
351 | |||
352 | |||
353 | struct GNUNET_DHTU_PreferenceHandle * | ||
354 | GDS_u_hold (struct GDS_Underlay *u, | ||
355 | struct GNUNET_DHTU_Target *target) | ||
356 | { | ||
357 | return u->dhtu->hold (u->dhtu->cls, | ||
358 | target); | ||
77 | } | 359 | } |
78 | 360 | ||
79 | 361 | ||
@@ -85,30 +367,97 @@ process_hello (void *cls, | |||
85 | static void | 367 | static void |
86 | shutdown_task (void *cls) | 368 | shutdown_task (void *cls) |
87 | { | 369 | { |
88 | if (NULL != ghh) | 370 | struct GDS_Underlay *u; |
371 | |||
372 | while (NULL != (u = u_head)) | ||
89 | { | 373 | { |
90 | GNUNET_TRANSPORT_hello_get_cancel (ghh); | 374 | GNUNET_PLUGIN_unload (u->libname, |
91 | ghh = NULL; | 375 | u->dhtu); |
376 | GNUNET_CONTAINER_DLL_remove (u_head, | ||
377 | u_tail, | ||
378 | u); | ||
379 | GNUNET_free (u->name); | ||
380 | GNUNET_free (u->libname); | ||
381 | GNUNET_free (u); | ||
92 | } | 382 | } |
93 | GDS_NEIGHBOURS_done (); | 383 | GDS_NEIGHBOURS_done (); |
94 | GDS_DATACACHE_done (); | 384 | GDS_DATACACHE_done (); |
95 | GDS_ROUTING_done (); | 385 | GDS_ROUTING_done (); |
96 | GDS_HELLO_done (); | ||
97 | GDS_NSE_done (); | ||
98 | if (NULL != GDS_block_context) | 386 | if (NULL != GDS_block_context) |
99 | { | 387 | { |
100 | GNUNET_BLOCK_context_destroy (GDS_block_context); | 388 | GNUNET_BLOCK_context_destroy (GDS_block_context); |
101 | GDS_block_context = NULL; | 389 | GDS_block_context = NULL; |
102 | } | 390 | } |
391 | GDS_CLIENTS_stop (); | ||
103 | if (NULL != GDS_stats) | 392 | if (NULL != GDS_stats) |
104 | { | 393 | { |
105 | GNUNET_STATISTICS_destroy (GDS_stats, | 394 | GNUNET_STATISTICS_destroy (GDS_stats, |
106 | GNUNET_YES); | 395 | GNUNET_YES); |
107 | GDS_stats = NULL; | 396 | GDS_stats = NULL; |
108 | } | 397 | } |
109 | GNUNET_free (GDS_my_hello); | 398 | if (NULL != GDS_my_hello) |
110 | GDS_my_hello = NULL; | 399 | { |
111 | GDS_CLIENTS_stop (); | 400 | GNUNET_HELLO_builder_free (GDS_my_hello); |
401 | GDS_my_hello = NULL; | ||
402 | } | ||
403 | if (NULL != hello_task) | ||
404 | { | ||
405 | GNUNET_SCHEDULER_cancel (hello_task); | ||
406 | hello_task = NULL; | ||
407 | } | ||
408 | } | ||
409 | |||
410 | |||
411 | /** | ||
412 | * Function iterating over all configuration sections. | ||
413 | * Loads plugins for enabled DHT underlays. | ||
414 | * | ||
415 | * @param cls NULL | ||
416 | * @param section configuration section to inspect | ||
417 | */ | ||
418 | static void | ||
419 | load_underlay (void *cls, | ||
420 | const char *section) | ||
421 | { | ||
422 | struct GDS_Underlay *u; | ||
423 | char *libname; | ||
424 | |||
425 | (void) cls; | ||
426 | if (0 != strncasecmp (section, | ||
427 | "dhtu-", | ||
428 | strlen ("dhtu-"))) | ||
429 | return; | ||
430 | if (GNUNET_YES != | ||
431 | GNUNET_CONFIGURATION_get_value_yesno (GDS_cfg, | ||
432 | section, | ||
433 | "ENABLED")) | ||
434 | return; | ||
435 | section += strlen ("dhtu-"); | ||
436 | u = GNUNET_new (struct GDS_Underlay); | ||
437 | u->env.cls = u; | ||
438 | u->env.cfg = GDS_cfg; | ||
439 | u->env.address_add_cb = &u_address_add; | ||
440 | u->env.address_del_cb = &u_address_del; | ||
441 | u->env.network_size_cb = &update_network_size_estimate; | ||
442 | u->env.connect_cb = &GDS_u_connect; | ||
443 | u->env.disconnect_cb = &GDS_u_disconnect; | ||
444 | u->env.receive_cb = &GDS_u_receive; | ||
445 | GNUNET_asprintf (&libname, | ||
446 | "libgnunet_plugin_dhtu_%s", | ||
447 | section); | ||
448 | u->dhtu = GNUNET_PLUGIN_load (libname, | ||
449 | &u->env); | ||
450 | if (NULL == u->dhtu) | ||
451 | { | ||
452 | GNUNET_free (libname); | ||
453 | GNUNET_free (u); | ||
454 | return; | ||
455 | } | ||
456 | u->libname = libname; | ||
457 | u->name = GNUNET_strdup (section); | ||
458 | GNUNET_CONTAINER_DLL_insert (u_head, | ||
459 | u_tail, | ||
460 | u); | ||
112 | } | 461 | } |
113 | 462 | ||
114 | 463 | ||
@@ -126,34 +475,64 @@ run (void *cls, | |||
126 | { | 475 | { |
127 | GDS_cfg = c; | 476 | GDS_cfg = c; |
128 | GDS_service = service; | 477 | GDS_service = service; |
129 | if (GNUNET_OK != | ||
130 | GNUNET_CONFIGURATION_get_value_time (c, | ||
131 | "transport", | ||
132 | "HELLO_EXPIRATION", | ||
133 | &hello_expiration)) | ||
134 | { | 478 | { |
135 | hello_expiration = GNUNET_CONSTANTS_HELLO_ADDRESS_EXPIRATION; | 479 | char *keyfile; |
480 | |||
481 | if (GNUNET_OK != | ||
482 | GNUNET_CONFIGURATION_get_value_filename (GDS_cfg, | ||
483 | "PEER", | ||
484 | "PRIVATE_KEY", | ||
485 | &keyfile)) | ||
486 | { | ||
487 | GNUNET_log_config_missing (GNUNET_ERROR_TYPE_ERROR, | ||
488 | "PEER", | ||
489 | "PRIVATE_KEY"); | ||
490 | GNUNET_SCHEDULER_shutdown (); | ||
491 | return; | ||
492 | } | ||
493 | if (GNUNET_SYSERR == | ||
494 | GNUNET_CRYPTO_eddsa_key_from_file (keyfile, | ||
495 | GNUNET_YES, | ||
496 | &GDS_my_private_key)) | ||
497 | { | ||
498 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | ||
499 | "Failed to setup peer's private key\n"); | ||
500 | GNUNET_free (keyfile); | ||
501 | GNUNET_SCHEDULER_shutdown (); | ||
502 | return; | ||
503 | } | ||
504 | GNUNET_free (keyfile); | ||
136 | } | 505 | } |
506 | GNUNET_CRYPTO_eddsa_key_get_public (&GDS_my_private_key, | ||
507 | &GDS_my_identity.public_key); | ||
508 | GDS_my_hello = GNUNET_HELLO_builder_new (&GDS_my_identity); | ||
509 | GNUNET_CRYPTO_hash (&GDS_my_identity, | ||
510 | sizeof(struct GNUNET_PeerIdentity), | ||
511 | &GDS_my_identity_hash); | ||
137 | GDS_block_context = GNUNET_BLOCK_context_create (GDS_cfg); | 512 | GDS_block_context = GNUNET_BLOCK_context_create (GDS_cfg); |
138 | GDS_stats = GNUNET_STATISTICS_create ("dht", | 513 | GDS_stats = GNUNET_STATISTICS_create ("dht", |
139 | GDS_cfg); | 514 | GDS_cfg); |
140 | GNUNET_SERVICE_suspend (GDS_service); | ||
141 | GDS_CLIENTS_init (); | 515 | GDS_CLIENTS_init (); |
142 | GDS_ROUTING_init (); | 516 | GDS_ROUTING_init (); |
143 | GDS_NSE_init (); | ||
144 | GDS_DATACACHE_init (); | 517 | GDS_DATACACHE_init (); |
145 | GDS_HELLO_init (); | 518 | GNUNET_SCHEDULER_add_shutdown (&shutdown_task, |
146 | if (GNUNET_OK != GDS_NEIGHBOURS_init ()) | 519 | NULL); |
520 | if (GNUNET_OK != | ||
521 | GDS_NEIGHBOURS_init ()) | ||
147 | { | 522 | { |
148 | shutdown_task (NULL); | 523 | GNUNET_SCHEDULER_shutdown (); |
524 | return; | ||
525 | } | ||
526 | GNUNET_CONFIGURATION_iterate_sections (GDS_cfg, | ||
527 | &load_underlay, | ||
528 | NULL); | ||
529 | if (NULL == u_head) | ||
530 | { | ||
531 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | ||
532 | "No DHT underlays configured!\n"); | ||
533 | GNUNET_SCHEDULER_shutdown (); | ||
149 | return; | 534 | return; |
150 | } | 535 | } |
151 | GNUNET_SCHEDULER_add_shutdown (&shutdown_task, | ||
152 | NULL); | ||
153 | ghh = GNUNET_TRANSPORT_hello_get (GDS_cfg, | ||
154 | GNUNET_TRANSPORT_AC_GLOBAL, | ||
155 | &process_hello, | ||
156 | NULL); | ||
157 | } | 536 | } |
158 | 537 | ||
159 | 538 | ||
diff --git a/src/dht/gnunet-service-dht.h b/src/dht/gnunet-service-dht.h index 367ff426e..a1513fcce 100644 --- a/src/dht/gnunet-service-dht.h +++ b/src/dht/gnunet-service-dht.h | |||
@@ -27,6 +27,7 @@ | |||
27 | #define GNUNET_SERVICE_DHT_H | 27 | #define GNUNET_SERVICE_DHT_H |
28 | 28 | ||
29 | #include "gnunet-service-dht_datacache.h" | 29 | #include "gnunet-service-dht_datacache.h" |
30 | #include "gnunet-service-dht_neighbours.h" | ||
30 | #include "gnunet_statistics_service.h" | 31 | #include "gnunet_statistics_service.h" |
31 | #include "gnunet_transport_service.h" | 32 | #include "gnunet_transport_service.h" |
32 | 33 | ||
@@ -34,6 +35,11 @@ | |||
34 | #define DEBUG_DHT GNUNET_EXTRA_LOGGING | 35 | #define DEBUG_DHT GNUNET_EXTRA_LOGGING |
35 | 36 | ||
36 | /** | 37 | /** |
38 | * Information we keep per underlay. | ||
39 | */ | ||
40 | struct GDS_Underlay; | ||
41 | |||
42 | /** | ||
37 | * Configuration we use. | 43 | * Configuration we use. |
38 | */ | 44 | */ |
39 | extern const struct GNUNET_CONFIGURATION_Handle *GDS_cfg; | 45 | extern const struct GNUNET_CONFIGURATION_Handle *GDS_cfg; |
@@ -54,9 +60,81 @@ extern struct GNUNET_BLOCK_Context *GDS_block_context; | |||
54 | extern struct GNUNET_STATISTICS_Handle *GDS_stats; | 60 | extern struct GNUNET_STATISTICS_Handle *GDS_stats; |
55 | 61 | ||
56 | /** | 62 | /** |
57 | * Our HELLO | 63 | * Our HELLO builder. |
64 | */ | ||
65 | extern struct GNUNET_HELLO_Builder *GDS_my_hello; | ||
66 | |||
67 | /** | ||
68 | * Identity of this peer. | ||
69 | */ | ||
70 | extern struct GNUNET_PeerIdentity GDS_my_identity; | ||
71 | |||
72 | /** | ||
73 | * Hash of the identity of this peer. | ||
74 | */ | ||
75 | extern struct GNUNET_HashCode GDS_my_identity_hash; | ||
76 | |||
77 | /** | ||
78 | * Our private key. | ||
79 | */ | ||
80 | extern struct GNUNET_CRYPTO_EddsaPrivateKey GDS_my_private_key; | ||
81 | |||
82 | |||
83 | /** | ||
84 | * Ask all underlays to connect to peer @a pid at @a address. | ||
85 | * | ||
86 | * @param pid identity of the peer we would connect to | ||
87 | * @param address an address of @a pid | ||
88 | */ | ||
89 | void | ||
90 | GDS_u_try_connect (const struct GNUNET_PeerIdentity *pid, | ||
91 | const char *address); | ||
92 | |||
93 | |||
94 | /** | ||
95 | * Send message to some other participant over the network. Note that | ||
96 | * sending is not guaranteeing that the other peer actually received the | ||
97 | * message. For any given @a target, the DHT must wait for the @a | ||
98 | * finished_cb to be called before calling send() again. | ||
99 | * | ||
100 | * @param u underlay to use for transmission | ||
101 | * @param target receiver identification | ||
102 | * @param msg message | ||
103 | * @param msg_size number of bytes in @a msg | ||
104 | * @param finished_cb function called once transmission is done | ||
105 | * (not called if @a target disconnects, then only the | ||
106 | * disconnect_cb is called). | ||
107 | * @param finished_cb_cls closure for @a finished_cb | ||
108 | */ | ||
109 | void | ||
110 | GDS_u_send (struct GDS_Underlay *u, | ||
111 | struct GNUNET_DHTU_Target *target, | ||
112 | const void *msg, | ||
113 | size_t msg_size, | ||
114 | GNUNET_SCHEDULER_TaskCallback finished_cb, | ||
115 | void *finished_cb_cls); | ||
116 | |||
117 | |||
118 | /** | ||
119 | * Drop a hold @a ph from underlay @a u. | ||
120 | * | ||
121 | * @param u the underlay controlling the hold | ||
122 | * @param ph the preference handle | ||
123 | */ | ||
124 | void | ||
125 | GDS_u_drop (struct GDS_Underlay *u, | ||
126 | struct GNUNET_DHTU_PreferenceHandle *ph); | ||
127 | |||
128 | |||
129 | /** | ||
130 | * Create a hold on @a target at underlay @a u. | ||
131 | * | ||
132 | * @param u the underlay controlling the target | ||
133 | * @param target the peer to hold the connection to | ||
58 | */ | 134 | */ |
59 | extern struct GNUNET_MessageHeader *GDS_my_hello; | 135 | struct GNUNET_DHTU_PreferenceHandle * |
136 | GDS_u_hold (struct GDS_Underlay *u, | ||
137 | struct GNUNET_DHTU_Target *target); | ||
60 | 138 | ||
61 | 139 | ||
62 | /** | 140 | /** |
@@ -68,8 +146,9 @@ extern struct GNUNET_MessageHeader *GDS_my_hello; | |||
68 | * @param query_hash hash of the original query, might not match key in @a bd | 146 | * @param query_hash hash of the original query, might not match key in @a bd |
69 | * @param get_path_length number of entries in @a get_path | 147 | * @param get_path_length number of entries in @a get_path |
70 | * @param get_path path the reply has taken | 148 | * @param get_path path the reply has taken |
149 | * @return true on success, false on failures | ||
71 | */ | 150 | */ |
72 | void | 151 | bool |
73 | GDS_CLIENTS_handle_reply (const struct GDS_DATACACHE_BlockData *bd, | 152 | GDS_CLIENTS_handle_reply (const struct GDS_DATACACHE_BlockData *bd, |
74 | const struct GNUNET_HashCode *query_hash, | 153 | const struct GNUNET_HashCode *query_hash, |
75 | unsigned int get_path_length, | 154 | unsigned int get_path_length, |
@@ -128,4 +207,12 @@ GDS_CLIENTS_process_put (enum GNUNET_DHT_RouteOption options, | |||
128 | uint32_t hop_count, | 207 | uint32_t hop_count, |
129 | uint32_t desired_replication_level); | 208 | uint32_t desired_replication_level); |
130 | 209 | ||
210 | /** | ||
211 | * Return the current NSE | ||
212 | * | ||
213 | * @return the current NSE as a logarithm | ||
214 | */ | ||
215 | double | ||
216 | GDS_NSE_get (void); | ||
217 | |||
131 | #endif | 218 | #endif |
diff --git a/src/dht/gnunet-service-dht_clients.c b/src/dht/gnunet-service-dht_clients.c index a1c3024de..6a4f58d1f 100644 --- a/src/dht/gnunet-service-dht_clients.c +++ b/src/dht/gnunet-service-dht_clients.c | |||
@@ -24,7 +24,6 @@ | |||
24 | * @author Christian Grothoff | 24 | * @author Christian Grothoff |
25 | * @author Nathan Evans | 25 | * @author Nathan Evans |
26 | */ | 26 | */ |
27 | |||
28 | #include "platform.h" | 27 | #include "platform.h" |
29 | #include "gnunet_constants.h" | 28 | #include "gnunet_constants.h" |
30 | #include "gnunet_protocols.h" | 29 | #include "gnunet_protocols.h" |
@@ -36,6 +35,14 @@ | |||
36 | 35 | ||
37 | 36 | ||
38 | /** | 37 | /** |
38 | * Enable slow sanity checks to debug issues. | ||
39 | * 0: do not check | ||
40 | * 1: check all external inputs | ||
41 | * 2: check internal computations as well | ||
42 | */ | ||
43 | #define SANITY_CHECKS 2 | ||
44 | |||
45 | /** | ||
39 | * Should routing details be logged to stderr (for debugging)? | 46 | * Should routing details be logged to stderr (for debugging)? |
40 | */ | 47 | */ |
41 | #define LOG_TRAFFIC(kind, ...) GNUNET_log_from (kind, "dht-traffic", \ | 48 | #define LOG_TRAFFIC(kind, ...) GNUNET_log_from (kind, "dht-traffic", \ |
@@ -503,6 +510,15 @@ handle_dht_local_put (void *cls, | |||
503 | (unsigned long) (size - sizeof(struct GNUNET_DHT_ClientPutMessage)), | 510 | (unsigned long) (size - sizeof(struct GNUNET_DHT_ClientPutMessage)), |
504 | GNUNET_h2s (&dht_msg->key), | 511 | GNUNET_h2s (&dht_msg->key), |
505 | (unsigned int) bd.type); | 512 | (unsigned int) bd.type); |
513 | if (GNUNET_OK != | ||
514 | GNUNET_BLOCK_check_block (GDS_block_context, | ||
515 | bd.type, | ||
516 | bd.data, | ||
517 | bd.data_size)) | ||
518 | { | ||
519 | GNUNET_break (0); | ||
520 | return; | ||
521 | } | ||
506 | GNUNET_STATISTICS_update (GDS_stats, | 522 | GNUNET_STATISTICS_update (GDS_stats, |
507 | "# PUT requests received from clients", | 523 | "# PUT requests received from clients", |
508 | 1, | 524 | 1, |
@@ -511,9 +527,9 @@ handle_dht_local_put (void *cls, | |||
511 | "CLIENT-PUT %s\n", | 527 | "CLIENT-PUT %s\n", |
512 | GNUNET_h2s_full (&dht_msg->key)); | 528 | GNUNET_h2s_full (&dht_msg->key)); |
513 | /* give to local clients */ | 529 | /* give to local clients */ |
514 | GDS_CLIENTS_handle_reply (&bd, | 530 | GNUNET_break (GDS_CLIENTS_handle_reply (&bd, |
515 | &bd.key, | 531 | &bd.key, |
516 | 0, NULL /* get path */); | 532 | 0, NULL /* get path */)); |
517 | 533 | ||
518 | { | 534 | { |
519 | struct GNUNET_CONTAINER_BloomFilter *peer_bf; | 535 | struct GNUNET_CONTAINER_BloomFilter *peer_bf; |
@@ -561,10 +577,12 @@ static void | |||
561 | handle_local_result (void *cls, | 577 | handle_local_result (void *cls, |
562 | const struct GDS_DATACACHE_BlockData *bd) | 578 | const struct GDS_DATACACHE_BlockData *bd) |
563 | { | 579 | { |
564 | /* FIXME: use 'cls' instead of looking up the client? */ | 580 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, |
565 | GDS_CLIENTS_handle_reply (bd, | 581 | "Datacache provided result for query key %s\n", |
566 | &bd->key, | 582 | GNUNET_h2s (&bd->key)); |
567 | 0, NULL /* get_path */); | 583 | GNUNET_break (GDS_CLIENTS_handle_reply (bd, |
584 | &bd->key, | ||
585 | 0, NULL /* get_path */)); | ||
568 | } | 586 | } |
569 | 587 | ||
570 | 588 | ||
@@ -917,7 +935,7 @@ forward_reply (void *cls, | |||
917 | GNUNET_NO); | 935 | GNUNET_NO); |
918 | return GNUNET_YES; /* type mismatch */ | 936 | return GNUNET_YES; /* type mismatch */ |
919 | } | 937 | } |
920 | if ( (0 == (record->msg_options & GNUNET_DHT_RO_FIND_PEER)) && | 938 | if ( (0 == (record->msg_options & GNUNET_DHT_RO_FIND_APPROXIMATE)) && |
921 | (0 != GNUNET_memcmp (&frc->bd->key, | 939 | (0 != GNUNET_memcmp (&frc->bd->key, |
922 | query_hash)) ) | 940 | query_hash)) ) |
923 | { | 941 | { |
@@ -973,9 +991,6 @@ forward_reply (void *cls, | |||
973 | /* should be impossible to encounter here */ | 991 | /* should be impossible to encounter here */ |
974 | GNUNET_break (0); | 992 | GNUNET_break (0); |
975 | return GNUNET_YES; | 993 | return GNUNET_YES; |
976 | case GNUNET_BLOCK_REPLY_INVALID: | ||
977 | GNUNET_break_op (0); | ||
978 | return GNUNET_NO; | ||
979 | case GNUNET_BLOCK_REPLY_IRRELEVANT: | 994 | case GNUNET_BLOCK_REPLY_IRRELEVANT: |
980 | return GNUNET_YES; | 995 | return GNUNET_YES; |
981 | default: | 996 | default: |
@@ -996,7 +1011,7 @@ forward_reply (void *cls, | |||
996 | reply->put_path_length = htonl (frc->bd->put_path_length); | 1011 | reply->put_path_length = htonl (frc->bd->put_path_length); |
997 | reply->unique_id = record->unique_id; | 1012 | reply->unique_id = record->unique_id; |
998 | reply->expiration = GNUNET_TIME_absolute_hton (frc->bd->expiration_time); | 1013 | reply->expiration = GNUNET_TIME_absolute_hton (frc->bd->expiration_time); |
999 | reply->key = frc->bd->key; | 1014 | reply->key = *query_hash; |
1000 | paths = (struct GNUNET_DHT_PathElement *) &reply[1]; | 1015 | paths = (struct GNUNET_DHT_PathElement *) &reply[1]; |
1001 | GNUNET_memcpy (paths, | 1016 | GNUNET_memcpy (paths, |
1002 | frc->bd->put_path, | 1017 | frc->bd->put_path, |
@@ -1004,7 +1019,8 @@ forward_reply (void *cls, | |||
1004 | * frc->bd->put_path_length); | 1019 | * frc->bd->put_path_length); |
1005 | GNUNET_memcpy (&paths[frc->bd->put_path_length], | 1020 | GNUNET_memcpy (&paths[frc->bd->put_path_length], |
1006 | frc->get_path, | 1021 | frc->get_path, |
1007 | sizeof(struct GNUNET_DHT_PathElement) * frc->get_path_length); | 1022 | sizeof(struct GNUNET_DHT_PathElement) |
1023 | * frc->get_path_length); | ||
1008 | GNUNET_memcpy (&paths[frc->get_path_length + frc->bd->put_path_length], | 1024 | GNUNET_memcpy (&paths[frc->get_path_length + frc->bd->put_path_length], |
1009 | frc->bd->data, | 1025 | frc->bd->data, |
1010 | frc->bd->data_size); | 1026 | frc->bd->data_size); |
@@ -1020,7 +1036,7 @@ forward_reply (void *cls, | |||
1020 | } | 1036 | } |
1021 | 1037 | ||
1022 | 1038 | ||
1023 | void | 1039 | bool |
1024 | GDS_CLIENTS_handle_reply (const struct GDS_DATACACHE_BlockData *bd, | 1040 | GDS_CLIENTS_handle_reply (const struct GDS_DATACACHE_BlockData *bd, |
1025 | const struct GNUNET_HashCode *query_hash, | 1041 | const struct GNUNET_HashCode *query_hash, |
1026 | unsigned int get_path_length, | 1042 | unsigned int get_path_length, |
@@ -1035,14 +1051,31 @@ GDS_CLIENTS_handle_reply (const struct GDS_DATACACHE_BlockData *bd, | |||
1035 | if (msize >= GNUNET_MAX_MESSAGE_SIZE) | 1051 | if (msize >= GNUNET_MAX_MESSAGE_SIZE) |
1036 | { | 1052 | { |
1037 | GNUNET_break (0); | 1053 | GNUNET_break (0); |
1038 | return; | 1054 | return false; |
1039 | } | 1055 | } |
1056 | #if SANITY_CHECKS > 1 | ||
1057 | if (0 != | ||
1058 | GNUNET_DHT_verify_path (bd->data, | ||
1059 | bd->data_size, | ||
1060 | bd->expiration_time, | ||
1061 | bd->put_path, | ||
1062 | bd->put_path_length, | ||
1063 | get_path, | ||
1064 | get_path_length, | ||
1065 | &GDS_my_identity)) | ||
1066 | { | ||
1067 | GNUNET_break (0); | ||
1068 | return false; | ||
1069 | } | ||
1070 | #endif | ||
1040 | frc.bd = bd; | 1071 | frc.bd = bd; |
1041 | frc.get_path = get_path; | 1072 | frc.get_path = get_path; |
1042 | frc.get_path_length = get_path_length; | 1073 | frc.get_path_length = get_path_length; |
1043 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 1074 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
1044 | "Forwarding reply for query hash %s to client\n", | 1075 | "Forwarding reply for query hash %s with GPL %u and PPL %u to client\n", |
1045 | GNUNET_h2s (query_hash)); | 1076 | GNUNET_h2s (query_hash), |
1077 | get_path_length, | ||
1078 | bd->put_path_length); | ||
1046 | if (0 == | 1079 | if (0 == |
1047 | GNUNET_CONTAINER_multihashmap_get_multiple (forward_map, | 1080 | GNUNET_CONTAINER_multihashmap_get_multiple (forward_map, |
1048 | query_hash, | 1081 | query_hash, |
@@ -1057,6 +1090,102 @@ GDS_CLIENTS_handle_reply (const struct GDS_DATACACHE_BlockData *bd, | |||
1057 | 1, | 1090 | 1, |
1058 | GNUNET_NO); | 1091 | GNUNET_NO); |
1059 | } | 1092 | } |
1093 | return true; | ||
1094 | } | ||
1095 | |||
1096 | |||
1097 | /* **************** HELLO logic ***************** */ | ||
1098 | |||
1099 | /** | ||
1100 | * Handler for HELLO GET message. Reply to client | ||
1101 | * with a URL of our HELLO. | ||
1102 | * | ||
1103 | * @param cls the client we received this message from | ||
1104 | * @param msg the actual message received | ||
1105 | * | ||
1106 | */ | ||
1107 | static void | ||
1108 | handle_dht_local_hello_get (void *cls, | ||
1109 | const struct GNUNET_MessageHeader *msg) | ||
1110 | { | ||
1111 | struct ClientHandle *ch = cls; | ||
1112 | char *url = GNUNET_HELLO_builder_to_url (GDS_my_hello, | ||
1113 | &GDS_my_private_key); | ||
1114 | size_t slen = strlen (url) + 1; | ||
1115 | struct GNUNET_MessageHeader *hdr; | ||
1116 | struct GNUNET_MQ_Envelope *env; | ||
1117 | |||
1118 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1119 | "Handling request from local client for my HELLO\n"); | ||
1120 | env = GNUNET_MQ_msg_extra (hdr, | ||
1121 | slen, | ||
1122 | GNUNET_MESSAGE_TYPE_DHT_CLIENT_HELLO_URL); | ||
1123 | memcpy (&hdr[1], | ||
1124 | url, | ||
1125 | slen); | ||
1126 | GNUNET_free (url); | ||
1127 | GNUNET_MQ_send (ch->mq, | ||
1128 | env); | ||
1129 | GNUNET_SERVICE_client_continue (ch->client); | ||
1130 | } | ||
1131 | |||
1132 | |||
1133 | /** | ||
1134 | * Process a client HELLO message received from the service. | ||
1135 | * | ||
1136 | * @param cls the client we received this message from | ||
1137 | * @param hdr HELLO URL message from the service. | ||
1138 | * @return #GNUNET_OK if @a hdr is well-formed | ||
1139 | */ | ||
1140 | static enum GNUNET_GenericReturnValue | ||
1141 | check_dht_local_hello_offer (void *cls, | ||
1142 | const struct GNUNET_MessageHeader *hdr) | ||
1143 | { | ||
1144 | uint16_t len = ntohs (hdr->size); | ||
1145 | const char *buf = (const char *) &hdr[1]; | ||
1146 | |||
1147 | (void) cls; | ||
1148 | if ('\0' != buf[len - sizeof (*hdr) - 1]) | ||
1149 | { | ||
1150 | GNUNET_break (0); | ||
1151 | return GNUNET_SYSERR; | ||
1152 | } | ||
1153 | return GNUNET_OK; | ||
1154 | } | ||
1155 | |||
1156 | |||
1157 | /** | ||
1158 | * Handler for HELLO OFFER message. Try to use the | ||
1159 | * HELLO to connect to another peer. | ||
1160 | * | ||
1161 | * @param cls the client we received this message from | ||
1162 | * @param msg the actual message received | ||
1163 | */ | ||
1164 | static void | ||
1165 | handle_dht_local_hello_offer (void *cls, | ||
1166 | const struct GNUNET_MessageHeader *msg) | ||
1167 | { | ||
1168 | struct ClientHandle *ch = cls; | ||
1169 | const char *url = (const char *) &msg[1]; | ||
1170 | struct GNUNET_HELLO_Builder *b; | ||
1171 | struct GNUNET_PeerIdentity pid; | ||
1172 | |||
1173 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1174 | "Local client provided HELLO URL %s\n", | ||
1175 | url); | ||
1176 | b = GNUNET_HELLO_builder_from_url (url); | ||
1177 | if (NULL == b) | ||
1178 | { | ||
1179 | GNUNET_break (0); | ||
1180 | GNUNET_SERVICE_client_drop (ch->client); | ||
1181 | return; | ||
1182 | } | ||
1183 | GNUNET_SERVICE_client_continue (ch->client); | ||
1184 | GNUNET_HELLO_builder_iterate (b, | ||
1185 | &pid, | ||
1186 | &GDS_try_connect, | ||
1187 | &pid); | ||
1188 | GNUNET_HELLO_builder_free (b); | ||
1060 | } | 1189 | } |
1061 | 1190 | ||
1062 | 1191 | ||
@@ -1330,8 +1459,8 @@ response_action (void *cls, | |||
1330 | bd->put_path_length * sizeof(struct GNUNET_DHT_PathElement)); | 1459 | bd->put_path_length * sizeof(struct GNUNET_DHT_PathElement)); |
1331 | GNUNET_memcpy (path, | 1460 | GNUNET_memcpy (path, |
1332 | resp_ctx->get_path, | 1461 | resp_ctx->get_path, |
1333 | resp_ctx->get_path_length * sizeof(struct | 1462 | resp_ctx->get_path_length |
1334 | GNUNET_DHT_PathElement)); | 1463 | * sizeof(struct GNUNET_DHT_PathElement)); |
1335 | GNUNET_memcpy (&path[resp_ctx->get_path_length], | 1464 | GNUNET_memcpy (&path[resp_ctx->get_path_length], |
1336 | bd->data, | 1465 | bd->data, |
1337 | bd->data_size); | 1466 | bd->data_size); |
@@ -1504,6 +1633,14 @@ GDS_CLIENTS_stop (void) | |||
1504 | GNUNET_MESSAGE_TYPE_DHT_CLIENT_GET_RESULTS_KNOWN, \ | 1633 | GNUNET_MESSAGE_TYPE_DHT_CLIENT_GET_RESULTS_KNOWN, \ |
1505 | struct GNUNET_DHT_ClientGetResultSeenMessage, \ | 1634 | struct GNUNET_DHT_ClientGetResultSeenMessage, \ |
1506 | NULL), \ | 1635 | NULL), \ |
1636 | GNUNET_MQ_hd_fixed_size (dht_local_hello_get, \ | ||
1637 | GNUNET_MESSAGE_TYPE_DHT_CLIENT_HELLO_GET, \ | ||
1638 | struct GNUNET_MessageHeader, \ | ||
1639 | NULL), \ | ||
1640 | GNUNET_MQ_hd_var_size (dht_local_hello_offer, \ | ||
1641 | GNUNET_MESSAGE_TYPE_DHT_CLIENT_HELLO_URL, \ | ||
1642 | struct GNUNET_MessageHeader, \ | ||
1643 | NULL), \ | ||
1507 | GNUNET_MQ_handler_end ()) | 1644 | GNUNET_MQ_handler_end ()) |
1508 | 1645 | ||
1509 | 1646 | ||
diff --git a/src/dht/gnunet-service-dht_datacache.c b/src/dht/gnunet-service-dht_datacache.c index cb778717b..be0a6db81 100644 --- a/src/dht/gnunet-service-dht_datacache.c +++ b/src/dht/gnunet-service-dht_datacache.c | |||
@@ -36,7 +36,7 @@ | |||
36 | * How many "closest" results to we return for migration when | 36 | * How many "closest" results to we return for migration when |
37 | * asked (at most)? | 37 | * asked (at most)? |
38 | */ | 38 | */ |
39 | #define NUM_CLOSEST 42 | 39 | #define NUM_CLOSEST 4 |
40 | 40 | ||
41 | 41 | ||
42 | /** | 42 | /** |
@@ -68,7 +68,7 @@ GDS_DATACACHE_handle_put (const struct GDS_DATACACHE_BlockData *bd) | |||
68 | 1, | 68 | 1, |
69 | GNUNET_NO); | 69 | GNUNET_NO); |
70 | GNUNET_CRYPTO_hash_xor (&bd->key, | 70 | GNUNET_CRYPTO_hash_xor (&bd->key, |
71 | &my_identity_hash, | 71 | &GDS_my_identity_hash, |
72 | &xor); | 72 | &xor); |
73 | r = GNUNET_DATACACHE_put (datacache, | 73 | r = GNUNET_DATACACHE_put (datacache, |
74 | &bd->key, | 74 | &bd->key, |
@@ -126,7 +126,7 @@ struct GetRequestContext | |||
126 | /** | 126 | /** |
127 | * Return value to give back. | 127 | * Return value to give back. |
128 | */ | 128 | */ |
129 | enum GNUNET_BLOCK_EvaluationResult eval; | 129 | enum GNUNET_BLOCK_ReplyEvaluationResult eval; |
130 | }; | 130 | }; |
131 | 131 | ||
132 | 132 | ||
@@ -204,13 +204,6 @@ datacache_get_iterator (void *cls, | |||
204 | 1, | 204 | 1, |
205 | GNUNET_NO); | 205 | GNUNET_NO); |
206 | break; | 206 | break; |
207 | case GNUNET_BLOCK_REPLY_INVALID: | ||
208 | /* maybe it expired? */ | ||
209 | GNUNET_STATISTICS_update (GDS_stats, | ||
210 | "# Invalid RESULTS found in datacache", | ||
211 | 1, | ||
212 | GNUNET_NO); | ||
213 | break; | ||
214 | case GNUNET_BLOCK_REPLY_IRRELEVANT: | 207 | case GNUNET_BLOCK_REPLY_IRRELEVANT: |
215 | GNUNET_STATISTICS_update (GDS_stats, | 208 | GNUNET_STATISTICS_update (GDS_stats, |
216 | "# Irrelevant RESULTS found in datacache", | 209 | "# Irrelevant RESULTS found in datacache", |
@@ -222,7 +215,7 @@ datacache_get_iterator (void *cls, | |||
222 | } | 215 | } |
223 | 216 | ||
224 | 217 | ||
225 | enum GNUNET_BLOCK_EvaluationResult | 218 | enum GNUNET_BLOCK_ReplyEvaluationResult |
226 | GDS_DATACACHE_handle_get (const struct GNUNET_HashCode *key, | 219 | GDS_DATACACHE_handle_get (const struct GNUNET_HashCode *key, |
227 | enum GNUNET_BLOCK_Type type, | 220 | enum GNUNET_BLOCK_Type type, |
228 | const void *xquery, | 221 | const void *xquery, |
@@ -231,22 +224,23 @@ GDS_DATACACHE_handle_get (const struct GNUNET_HashCode *key, | |||
231 | GDS_DATACACHE_GetCallback gc, | 224 | GDS_DATACACHE_GetCallback gc, |
232 | void *gc_cls) | 225 | void *gc_cls) |
233 | { | 226 | { |
234 | struct GetRequestContext ctx; | 227 | struct GetRequestContext ctx = { |
228 | .eval = GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED, | ||
229 | .key = *key, | ||
230 | .xquery = xquery, | ||
231 | .xquery_size = xquery_size, | ||
232 | .bg = bg, | ||
233 | .gc = gc, | ||
234 | .gc_cls = gc_cls | ||
235 | }; | ||
235 | unsigned int r; | 236 | unsigned int r; |
236 | 237 | ||
237 | if (NULL == datacache) | 238 | if (NULL == datacache) |
238 | return GNUNET_BLOCK_EVALUATION_REQUEST_VALID; | 239 | return GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED; |
239 | GNUNET_STATISTICS_update (GDS_stats, | 240 | GNUNET_STATISTICS_update (GDS_stats, |
240 | "# GET requests given to datacache", | 241 | "# GET requests given to datacache", |
241 | 1, | 242 | 1, |
242 | GNUNET_NO); | 243 | GNUNET_NO); |
243 | ctx.eval = GNUNET_BLOCK_EVALUATION_REQUEST_VALID; | ||
244 | ctx.key = *key; | ||
245 | ctx.xquery = xquery; | ||
246 | ctx.xquery_size = xquery_size; | ||
247 | ctx.bg = bg; | ||
248 | ctx.gc = gc; | ||
249 | ctx.gc_cls = gc_cls; | ||
250 | r = GNUNET_DATACACHE_get (datacache, | 244 | r = GNUNET_DATACACHE_get (datacache, |
251 | key, | 245 | key, |
252 | type, | 246 | type, |
@@ -261,85 +255,44 @@ GDS_DATACACHE_handle_get (const struct GNUNET_HashCode *key, | |||
261 | } | 255 | } |
262 | 256 | ||
263 | 257 | ||
264 | /** | 258 | enum GNUNET_BLOCK_ReplyEvaluationResult |
265 | * Closure for #datacache_get_successors_iterator(). | ||
266 | */ | ||
267 | struct SuccContext | ||
268 | { | ||
269 | /** | ||
270 | * Function to call on the result | ||
271 | */ | ||
272 | GDS_DATACACHE_GetCallback cb; | ||
273 | |||
274 | /** | ||
275 | * Closure for @e cb. | ||
276 | */ | ||
277 | void *cb_cls; | ||
278 | |||
279 | }; | ||
280 | |||
281 | |||
282 | /** | ||
283 | * Iterator for local get request results, | ||
284 | * | ||
285 | * @param cls closure with the `struct GNUNET_HashCode *` with the trail ID | ||
286 | * @param key the key this data is stored under | ||
287 | * @param size the size of the data identified by key | ||
288 | * @param data the actual data | ||
289 | * @param type the type of the data | ||
290 | * @param exp when does this value expire? | ||
291 | * @param put_path_length number of peers in @a put_path | ||
292 | * @param put_path path the reply took on put | ||
293 | * @return #GNUNET_OK to continue iteration, anything else | ||
294 | * to stop iteration. | ||
295 | */ | ||
296 | static enum GNUNET_GenericReturnValue | ||
297 | datacache_get_successors_iterator (void *cls, | ||
298 | const struct GNUNET_HashCode *key, | ||
299 | size_t size, | ||
300 | const char *data, | ||
301 | enum GNUNET_BLOCK_Type type, | ||
302 | struct GNUNET_TIME_Absolute exp, | ||
303 | unsigned int put_path_length, | ||
304 | const struct | ||
305 | GNUNET_DHT_PathElement *put_path) | ||
306 | { | ||
307 | const struct SuccContext *sc = cls; | ||
308 | struct GDS_DATACACHE_BlockData bd = { | ||
309 | .key = *key, | ||
310 | .expiration_time = exp, | ||
311 | .put_path = put_path, | ||
312 | .data = data, | ||
313 | .data_size = size, | ||
314 | .put_path_length = put_path_length, | ||
315 | .type = type | ||
316 | }; | ||
317 | |||
318 | /* NOTE: The datacache currently does not store the RO from | ||
319 | the original 'put', so we don't know the 'correct' option | ||
320 | at this point anymore. Thus, we conservatively assume | ||
321 | that recording is desired (for now). */ | ||
322 | sc->cb (sc->cb_cls, | ||
323 | &bd); | ||
324 | return GNUNET_OK; | ||
325 | } | ||
326 | |||
327 | |||
328 | void | ||
329 | GDS_DATACACHE_get_closest (const struct GNUNET_HashCode *key, | 259 | GDS_DATACACHE_get_closest (const struct GNUNET_HashCode *key, |
260 | enum GNUNET_BLOCK_Type type, | ||
261 | const void *xquery, | ||
262 | size_t xquery_size, | ||
263 | struct GNUNET_BLOCK_Group *bg, | ||
330 | GDS_DATACACHE_GetCallback cb, | 264 | GDS_DATACACHE_GetCallback cb, |
331 | void *cb_cls) | 265 | void *cb_cls) |
332 | { | 266 | { |
333 | struct SuccContext sc = { | 267 | struct GetRequestContext ctx = { |
334 | .cb = cb, | 268 | .eval = GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED, |
335 | .cb_cls = cb_cls | 269 | .key = *key, |
270 | .xquery = xquery, | ||
271 | .xquery_size = xquery_size, | ||
272 | .bg = bg, | ||
273 | .gc = cb, | ||
274 | .gc_cls = cb_cls | ||
336 | }; | 275 | }; |
276 | unsigned int r; | ||
337 | 277 | ||
338 | (void) GNUNET_DATACACHE_get_closest (datacache, | 278 | if (NULL == datacache) |
339 | key, | 279 | return GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED; |
340 | NUM_CLOSEST, | 280 | GNUNET_STATISTICS_update (GDS_stats, |
341 | &datacache_get_successors_iterator, | 281 | "# GET closest requests given to datacache", |
342 | &sc); | 282 | 1, |
283 | GNUNET_NO); | ||
284 | r = GNUNET_DATACACHE_get_closest (datacache, | ||
285 | key, | ||
286 | type, | ||
287 | NUM_CLOSEST, | ||
288 | &datacache_get_iterator, | ||
289 | &ctx); | ||
290 | LOG (GNUNET_ERROR_TYPE_DEBUG, | ||
291 | "DATACACHE approximate GET for key %s completed (%d). %u results found.\n", | ||
292 | GNUNET_h2s (key), | ||
293 | ctx.eval, | ||
294 | r); | ||
295 | return ctx.eval; | ||
343 | } | 296 | } |
344 | 297 | ||
345 | 298 | ||
diff --git a/src/dht/gnunet-service-dht_datacache.h b/src/dht/gnunet-service-dht_datacache.h index 691a51e0e..d860139f5 100644 --- a/src/dht/gnunet-service-dht_datacache.h +++ b/src/dht/gnunet-service-dht_datacache.h | |||
@@ -107,7 +107,7 @@ typedef void | |||
107 | * @param gc_cls closure for @a gc | 107 | * @param gc_cls closure for @a gc |
108 | * @return evaluation result for the local replies | 108 | * @return evaluation result for the local replies |
109 | */ | 109 | */ |
110 | enum GNUNET_BLOCK_EvaluationResult | 110 | enum GNUNET_BLOCK_ReplyEvaluationResult |
111 | GDS_DATACACHE_handle_get (const struct GNUNET_HashCode *key, | 111 | GDS_DATACACHE_handle_get (const struct GNUNET_HashCode *key, |
112 | enum GNUNET_BLOCK_Type type, | 112 | enum GNUNET_BLOCK_Type type, |
113 | const void *xquery, | 113 | const void *xquery, |
@@ -122,11 +122,20 @@ GDS_DATACACHE_handle_get (const struct GNUNET_HashCode *key, | |||
122 | * another peer. | 122 | * another peer. |
123 | * | 123 | * |
124 | * @param key the location at which the peer is looking for data that is close | 124 | * @param key the location at which the peer is looking for data that is close |
125 | * @param type requested data type | ||
126 | * @param xquery extended query | ||
127 | * @param xquery_size number of bytes in xquery | ||
128 | * @param bg block group to use for evaluation of replies | ||
125 | * @param cb function to call with the result | 129 | * @param cb function to call with the result |
126 | * @param cb_cls closure for @a cb | 130 | * @param cb_cls closure for @a cb |
131 | * @return evaluation result for the local replies | ||
127 | */ | 132 | */ |
128 | void | 133 | enum GNUNET_BLOCK_ReplyEvaluationResult |
129 | GDS_DATACACHE_get_closest (const struct GNUNET_HashCode *key, | 134 | GDS_DATACACHE_get_closest (const struct GNUNET_HashCode *key, |
135 | enum GNUNET_BLOCK_Type type, | ||
136 | const void *xquery, | ||
137 | size_t xquery_size, | ||
138 | struct GNUNET_BLOCK_Group *bg, | ||
130 | GDS_DATACACHE_GetCallback cb, | 139 | GDS_DATACACHE_GetCallback cb, |
131 | void *cb_cls); | 140 | void *cb_cls); |
132 | 141 | ||
diff --git a/src/dht/gnunet-service-dht_hello.c b/src/dht/gnunet-service-dht_hello.c deleted file mode 100644 index 949456575..000000000 --- a/src/dht/gnunet-service-dht_hello.c +++ /dev/null | |||
@@ -1,154 +0,0 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2011 GNUnet e.V. | ||
4 | |||
5 | GNUnet is free software: you can redistribute it and/or modify it | ||
6 | under the terms of the GNU Affero General Public License as published | ||
7 | by the Free Software Foundation, either version 3 of the License, | ||
8 | or (at your option) any later version. | ||
9 | |||
10 | GNUnet is distributed in the hope that it will be useful, but | ||
11 | WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
13 | Affero General Public License for more details. | ||
14 | |||
15 | You should have received a copy of the GNU Affero General Public License | ||
16 | along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
17 | |||
18 | SPDX-License-Identifier: AGPL3.0-or-later | ||
19 | */ | ||
20 | |||
21 | /** | ||
22 | * @file dht/gnunet-service-dht_hello.c | ||
23 | * @brief GNUnet DHT integration with peerinfo | ||
24 | * @author Christian Grothoff | ||
25 | * | ||
26 | * TODO: | ||
27 | * - consider adding mechanism to remove expired HELLOs | ||
28 | */ | ||
29 | #include "platform.h" | ||
30 | #include "gnunet-service-dht.h" | ||
31 | #include "gnunet-service-dht_hello.h" | ||
32 | #include "gnunet_peerinfo_service.h" | ||
33 | |||
34 | |||
35 | /** | ||
36 | * Handle for peerinfo notifications. | ||
37 | */ | ||
38 | static struct GNUNET_PEERINFO_NotifyContext *pnc; | ||
39 | |||
40 | /** | ||
41 | * Hash map of peers to HELLOs. | ||
42 | */ | ||
43 | static struct GNUNET_CONTAINER_MultiPeerMap *peer_to_hello; | ||
44 | |||
45 | |||
46 | /** | ||
47 | * Obtain a peer's HELLO if available | ||
48 | * | ||
49 | * @param peer peer to look for a HELLO from | ||
50 | * @return HELLO for the given peer | ||
51 | */ | ||
52 | const struct GNUNET_HELLO_Message * | ||
53 | GDS_HELLO_get (const struct GNUNET_PeerIdentity *peer) | ||
54 | { | ||
55 | if (NULL == peer_to_hello) | ||
56 | return NULL; | ||
57 | return GNUNET_CONTAINER_multipeermap_get (peer_to_hello, | ||
58 | peer); | ||
59 | } | ||
60 | |||
61 | |||
62 | /** | ||
63 | * Function called for each HELLO known to PEERINFO. | ||
64 | * | ||
65 | * @param cls closure | ||
66 | * @param peer id of the peer, NULL for last call | ||
67 | * @param hello hello message for the peer (can be NULL) | ||
68 | * @param err_msg error message (not used) | ||
69 | * | ||
70 | * FIXME this is called once per address. Merge instead of replacing? | ||
71 | */ | ||
72 | static void | ||
73 | process_hello (void *cls, | ||
74 | const struct GNUNET_PeerIdentity *peer, | ||
75 | const struct GNUNET_HELLO_Message *hello, | ||
76 | const char *err_msg) | ||
77 | { | ||
78 | struct GNUNET_TIME_Absolute ex; | ||
79 | struct GNUNET_HELLO_Message *hm; | ||
80 | |||
81 | if (NULL == hello) | ||
82 | return; | ||
83 | ex = GNUNET_HELLO_get_last_expiration (hello); | ||
84 | if (0 == GNUNET_TIME_absolute_get_remaining (ex).rel_value_us) | ||
85 | return; | ||
86 | GNUNET_STATISTICS_update (GDS_stats, | ||
87 | "# HELLOs obtained from peerinfo", | ||
88 | 1, | ||
89 | GNUNET_NO); | ||
90 | hm = GNUNET_CONTAINER_multipeermap_get (peer_to_hello, | ||
91 | peer); | ||
92 | GNUNET_free (hm); | ||
93 | hm = GNUNET_malloc (GNUNET_HELLO_size (hello)); | ||
94 | GNUNET_memcpy (hm, | ||
95 | hello, | ||
96 | GNUNET_HELLO_size (hello)); | ||
97 | GNUNET_assert (GNUNET_SYSERR != | ||
98 | GNUNET_CONTAINER_multipeermap_put (peer_to_hello, | ||
99 | peer, | ||
100 | hm, | ||
101 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_REPLACE)); | ||
102 | } | ||
103 | |||
104 | |||
105 | /** | ||
106 | * Initialize HELLO subsystem. | ||
107 | */ | ||
108 | void | ||
109 | GDS_HELLO_init () | ||
110 | { | ||
111 | pnc = GNUNET_PEERINFO_notify (GDS_cfg, | ||
112 | GNUNET_NO, | ||
113 | &process_hello, | ||
114 | NULL); | ||
115 | peer_to_hello = GNUNET_CONTAINER_multipeermap_create (256, | ||
116 | GNUNET_NO); | ||
117 | } | ||
118 | |||
119 | |||
120 | /** | ||
121 | * Free memory occopied by the HELLO. | ||
122 | */ | ||
123 | static enum GNUNET_GenericReturnValue | ||
124 | free_hello (void *cls, | ||
125 | const struct GNUNET_PeerIdentity *key, | ||
126 | void *hello) | ||
127 | { | ||
128 | GNUNET_free (hello); | ||
129 | return GNUNET_OK; | ||
130 | } | ||
131 | |||
132 | |||
133 | /** | ||
134 | * Shutdown HELLO subsystem. | ||
135 | */ | ||
136 | void | ||
137 | GDS_HELLO_done () | ||
138 | { | ||
139 | if (NULL != pnc) | ||
140 | { | ||
141 | GNUNET_PEERINFO_notify_cancel (pnc); | ||
142 | pnc = NULL; | ||
143 | } | ||
144 | if (NULL != peer_to_hello) | ||
145 | { | ||
146 | GNUNET_CONTAINER_multipeermap_iterate (peer_to_hello, | ||
147 | &free_hello, | ||
148 | NULL); | ||
149 | GNUNET_CONTAINER_multipeermap_destroy (peer_to_hello); | ||
150 | } | ||
151 | } | ||
152 | |||
153 | |||
154 | /* end of gnunet-service-dht_hello.c */ | ||
diff --git a/src/dht/gnunet-service-dht_hello.h b/src/dht/gnunet-service-dht_hello.h deleted file mode 100644 index f8b90862d..000000000 --- a/src/dht/gnunet-service-dht_hello.h +++ /dev/null | |||
@@ -1,55 +0,0 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2011 GNUnet e.V. | ||
4 | |||
5 | GNUnet is free software: you can redistribute it and/or modify it | ||
6 | under the terms of the GNU Affero General Public License as published | ||
7 | by the Free Software Foundation, either version 3 of the License, | ||
8 | or (at your option) any later version. | ||
9 | |||
10 | GNUnet is distributed in the hope that it will be useful, but | ||
11 | WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
13 | Affero General Public License for more details. | ||
14 | |||
15 | You should have received a copy of the GNU Affero General Public License | ||
16 | along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
17 | |||
18 | SPDX-License-Identifier: AGPL3.0-or-later | ||
19 | */ | ||
20 | |||
21 | /** | ||
22 | * @file dht/gnunet-service-dht_hello.h | ||
23 | * @brief GNUnet DHT integration with peerinfo | ||
24 | * @author Christian Grothoff | ||
25 | */ | ||
26 | #ifndef GNUNET_SERVICE_DHT_HELLO_H | ||
27 | #define GNUNET_SERVICE_DHT_HELLO_H | ||
28 | |||
29 | #include "gnunet_util_lib.h" | ||
30 | #include "gnunet_hello_lib.h" | ||
31 | |||
32 | /** | ||
33 | * Obtain a peer's HELLO if available | ||
34 | * | ||
35 | * @param peer peer to look for a HELLO from | ||
36 | * @return HELLO for the given peer | ||
37 | */ | ||
38 | const struct GNUNET_HELLO_Message * | ||
39 | GDS_HELLO_get (const struct GNUNET_PeerIdentity *peer); | ||
40 | |||
41 | |||
42 | /** | ||
43 | * Initialize HELLO subsystem. | ||
44 | */ | ||
45 | void | ||
46 | GDS_HELLO_init (void); | ||
47 | |||
48 | |||
49 | /** | ||
50 | * Shutdown HELLO subsystem. | ||
51 | */ | ||
52 | void | ||
53 | GDS_HELLO_done (void); | ||
54 | |||
55 | #endif | ||
diff --git a/src/dht/gnunet-service-dht_neighbours.c b/src/dht/gnunet-service-dht_neighbours.c index cf150ea0c..2f9cbab84 100644 --- a/src/dht/gnunet-service-dht_neighbours.c +++ b/src/dht/gnunet-service-dht_neighbours.c | |||
@@ -28,13 +28,10 @@ | |||
28 | #include "gnunet_constants.h" | 28 | #include "gnunet_constants.h" |
29 | #include "gnunet_protocols.h" | 29 | #include "gnunet_protocols.h" |
30 | #include "gnunet_signatures.h" | 30 | #include "gnunet_signatures.h" |
31 | #include "gnunet_ats_service.h" | ||
32 | #include "gnunet_core_service.h" | ||
33 | #include "gnunet_hello_lib.h" | 31 | #include "gnunet_hello_lib.h" |
32 | #include "gnunet_hello_uri_lib.h" | ||
34 | #include "gnunet-service-dht.h" | 33 | #include "gnunet-service-dht.h" |
35 | #include "gnunet-service-dht_hello.h" | ||
36 | #include "gnunet-service-dht_neighbours.h" | 34 | #include "gnunet-service-dht_neighbours.h" |
37 | #include "gnunet-service-dht_nse.h" | ||
38 | #include "gnunet-service-dht_routing.h" | 35 | #include "gnunet-service-dht_routing.h" |
39 | #include "dht.h" | 36 | #include "dht.h" |
40 | 37 | ||
@@ -42,9 +39,17 @@ | |||
42 | __VA_ARGS__) | 39 | __VA_ARGS__) |
43 | 40 | ||
44 | /** | 41 | /** |
45 | * Enable slow sanity checks to debug issues. | 42 | * Enable slow sanity checks to debug issues. |
43 | * | ||
44 | * TODO: might want to eventually implement probabilistic | ||
45 | * load-based path verification, but for now it is all or nothing | ||
46 | * based on this define. | ||
47 | * | ||
48 | * 0: do not check -- if signatures become performance critical | ||
49 | * 1: check all external inputs -- normal production for now | ||
50 | * 2: check internal computations as well -- for debugging | ||
46 | */ | 51 | */ |
47 | #define SANITY_CHECKS 1 | 52 | #define SANITY_CHECKS 2 |
48 | 53 | ||
49 | /** | 54 | /** |
50 | * How many buckets will we allow in total. | 55 | * How many buckets will we allow in total. |
@@ -74,6 +79,7 @@ | |||
74 | #define DHT_MINIMUM_FIND_PEER_INTERVAL GNUNET_TIME_relative_multiply ( \ | 79 | #define DHT_MINIMUM_FIND_PEER_INTERVAL GNUNET_TIME_relative_multiply ( \ |
75 | GNUNET_TIME_UNIT_MINUTES, 2) | 80 | GNUNET_TIME_UNIT_MINUTES, 2) |
76 | 81 | ||
82 | |||
77 | /** | 83 | /** |
78 | * How long to additionally wait on average per #bucket_size to send out the | 84 | * How long to additionally wait on average per #bucket_size to send out the |
79 | * FIND PEER requests if we did successfully connect (!) to a a new peer and | 85 | * FIND PEER requests if we did successfully connect (!) to a a new peer and |
@@ -83,7 +89,7 @@ | |||
83 | * top). Also the range in which we randomize, so the effective value | 89 | * top). Also the range in which we randomize, so the effective value |
84 | * is half of the number given here. | 90 | * is half of the number given here. |
85 | */ | 91 | */ |
86 | #define DHT_AVG_FIND_PEER_INTERVAL GNUNET_TIME_relative_multiply ( \ | 92 | #define DHT_AVG_FIND_PEER_INTERVAL GNUNET_TIME_relative_multiply ( \ |
87 | GNUNET_TIME_UNIT_SECONDS, 6) | 93 | GNUNET_TIME_UNIT_SECONDS, 6) |
88 | 94 | ||
89 | /** | 95 | /** |
@@ -91,11 +97,6 @@ | |||
91 | */ | 97 | */ |
92 | #define GET_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 2) | 98 | #define GET_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 2) |
93 | 99 | ||
94 | /** | ||
95 | * Hello address expiration | ||
96 | */ | ||
97 | extern struct GNUNET_TIME_Relative hello_expiration; | ||
98 | |||
99 | 100 | ||
100 | GNUNET_NETWORK_STRUCT_BEGIN | 101 | GNUNET_NETWORK_STRUCT_BEGIN |
101 | 102 | ||
@@ -263,81 +264,134 @@ GNUNET_NETWORK_STRUCT_END | |||
263 | /** | 264 | /** |
264 | * Entry for a peer in a bucket. | 265 | * Entry for a peer in a bucket. |
265 | */ | 266 | */ |
266 | struct PeerInfo | 267 | struct PeerInfo; |
268 | |||
269 | |||
270 | /** | ||
271 | * List of targets that we can use to reach this peer. | ||
272 | */ | ||
273 | struct Target | ||
267 | { | 274 | { |
268 | /** | 275 | /** |
269 | * Next peer entry (DLL) | 276 | * Kept in a DLL. |
270 | */ | 277 | */ |
271 | struct PeerInfo *next; | 278 | struct Target *next; |
272 | 279 | ||
273 | /** | 280 | /** |
274 | * Prev peer entry (DLL) | 281 | * Kept in a DLL. |
275 | */ | 282 | */ |
276 | struct PeerInfo *prev; | 283 | struct Target *prev; |
277 | 284 | ||
278 | /** | 285 | /** |
279 | * Handle for sending messages to this peer. | 286 | * Handle for sending messages to this peer. |
280 | */ | 287 | */ |
281 | struct GNUNET_MQ_Handle *mq; | 288 | struct GNUNET_DHTU_Target *utarget; |
282 | 289 | ||
283 | /** | 290 | /** |
284 | * What is the identity of the peer? | 291 | * Underlay providing this target. |
285 | */ | 292 | */ |
286 | const struct GNUNET_PeerIdentity *id; | 293 | struct GDS_Underlay *u; |
287 | 294 | ||
288 | /** | 295 | /** |
289 | * Hash of @e id. | 296 | * Peer this is a target for. |
290 | */ | 297 | */ |
291 | struct GNUNET_HashCode phash; | 298 | struct PeerInfo *pi; |
292 | 299 | ||
293 | /** | 300 | /** |
294 | * Which bucket is this peer in? | 301 | * Handle used to 'hold' the connection to this peer. |
295 | */ | 302 | */ |
296 | int peer_bucket; | 303 | struct GNUNET_DHTU_PreferenceHandle *ph; |
304 | |||
305 | /** | ||
306 | * Set to number of messages are waiting for the transmission to finish. | ||
307 | */ | ||
308 | unsigned int load; | ||
309 | |||
310 | /** | ||
311 | * Set to @a true if the target was dropped, but we could not clean | ||
312 | * up yet because @e busy was also true. | ||
313 | */ | ||
314 | bool dropped; | ||
315 | |||
297 | }; | 316 | }; |
298 | 317 | ||
299 | 318 | ||
300 | /** | 319 | /** |
301 | * Peers are grouped into buckets. | 320 | * Entry for a peer in a bucket. |
302 | */ | 321 | */ |
303 | struct PeerBucket | 322 | struct PeerInfo |
304 | { | 323 | { |
305 | /** | 324 | /** |
306 | * Head of DLL | 325 | * What is the identity of the peer? |
307 | */ | 326 | */ |
308 | struct PeerInfo *head; | 327 | struct GNUNET_PeerIdentity id; |
309 | 328 | ||
310 | /** | 329 | /** |
311 | * Tail of DLL | 330 | * Hash of @e id. |
312 | */ | 331 | */ |
313 | struct PeerInfo *tail; | 332 | struct GNUNET_HashCode phash; |
314 | 333 | ||
315 | /** | 334 | /** |
316 | * Number of peers in the bucket. | 335 | * When does our HELLO from this peer expire? |
317 | */ | 336 | */ |
318 | unsigned int peers_size; | 337 | struct GNUNET_TIME_Absolute hello_expiration; |
338 | |||
339 | /** | ||
340 | * Next peer entry (DLL) | ||
341 | */ | ||
342 | struct PeerInfo *next; | ||
343 | |||
344 | /** | ||
345 | * Prev peer entry (DLL) | ||
346 | */ | ||
347 | struct PeerInfo *prev; | ||
348 | |||
349 | /** | ||
350 | * Head of DLL of targets for this peer. | ||
351 | */ | ||
352 | struct Target *t_head; | ||
353 | |||
354 | /** | ||
355 | * Tail of DLL of targets for this peer. | ||
356 | */ | ||
357 | struct Target *t_tail; | ||
358 | |||
359 | /** | ||
360 | * Block with a HELLO of this peer. | ||
361 | */ | ||
362 | void *hello; | ||
363 | |||
364 | /** | ||
365 | * Number of bytes in @e hello. | ||
366 | */ | ||
367 | size_t hello_size; | ||
368 | |||
369 | /** | ||
370 | * Which bucket is this peer in? | ||
371 | */ | ||
372 | int peer_bucket; | ||
319 | }; | 373 | }; |
320 | 374 | ||
321 | 375 | ||
322 | /** | 376 | /** |
323 | * Information about a peer that we would like to connect to. | 377 | * Peers are grouped into buckets. |
324 | */ | 378 | */ |
325 | struct ConnectInfo | 379 | struct PeerBucket |
326 | { | 380 | { |
327 | /** | 381 | /** |
328 | * Handle to active HELLO offer operation, or NULL. | 382 | * Head of DLL |
329 | */ | 383 | */ |
330 | struct GNUNET_TRANSPORT_OfferHelloHandle *oh; | 384 | struct PeerInfo *head; |
331 | 385 | ||
332 | /** | 386 | /** |
333 | * Handle to active connectivity suggestion operation, or NULL. | 387 | * Tail of DLL |
334 | */ | 388 | */ |
335 | struct GNUNET_ATS_ConnectivitySuggestHandle *sh; | 389 | struct PeerInfo *tail; |
336 | 390 | ||
337 | /** | 391 | /** |
338 | * How much would we like to connect to this peer? | 392 | * Number of peers in the bucket. |
339 | */ | 393 | */ |
340 | uint32_t strength; | 394 | unsigned int peers_size; |
341 | }; | 395 | }; |
342 | 396 | ||
343 | 397 | ||
@@ -374,12 +428,6 @@ static struct PeerBucket k_buckets[MAX_BUCKETS]; | |||
374 | static struct GNUNET_CONTAINER_MultiPeerMap *all_connected_peers; | 428 | static struct GNUNET_CONTAINER_MultiPeerMap *all_connected_peers; |
375 | 429 | ||
376 | /** | 430 | /** |
377 | * Hash map of all peers we would like to be connected to. | ||
378 | * Values are of type `struct ConnectInfo`. | ||
379 | */ | ||
380 | static struct GNUNET_CONTAINER_MultiPeerMap *all_desired_peers; | ||
381 | |||
382 | /** | ||
383 | * Maximum size for each bucket. | 431 | * Maximum size for each bucket. |
384 | */ | 432 | */ |
385 | static unsigned int bucket_size = DEFAULT_BUCKET_SIZE; | 433 | static unsigned int bucket_size = DEFAULT_BUCKET_SIZE; |
@@ -389,30 +437,83 @@ static unsigned int bucket_size = DEFAULT_BUCKET_SIZE; | |||
389 | */ | 437 | */ |
390 | static struct GNUNET_SCHEDULER_Task *find_peer_task; | 438 | static struct GNUNET_SCHEDULER_Task *find_peer_task; |
391 | 439 | ||
392 | /** | ||
393 | * Identity of this peer. | ||
394 | */ | ||
395 | static struct GNUNET_PeerIdentity my_identity; | ||
396 | 440 | ||
397 | /** | 441 | /** |
398 | * Hash of the identity of this peer. | 442 | * Function called whenever we finished sending to a target. |
443 | * Marks the transmission as finished (and the target as ready | ||
444 | * for the next message). | ||
445 | * | ||
446 | * @param cls a `struct Target *` | ||
399 | */ | 447 | */ |
400 | struct GNUNET_HashCode my_identity_hash; | 448 | static void |
449 | send_done_cb (void *cls) | ||
450 | { | ||
451 | struct Target *t = cls; | ||
452 | struct PeerInfo *pi = t->pi; /* NULL if t->dropped! */ | ||
401 | 453 | ||
402 | /** | 454 | GNUNET_assert (t->load > 0); |
403 | * Handle to CORE. | 455 | t->load--; |
404 | */ | 456 | if (0 < t->load) |
405 | static struct GNUNET_CORE_Handle *core_api; | 457 | return; |
458 | if (t->dropped) | ||
459 | { | ||
460 | GNUNET_free (t); | ||
461 | return; | ||
462 | } | ||
463 | /* move target back to the front */ | ||
464 | GNUNET_CONTAINER_DLL_remove (pi->t_head, | ||
465 | pi->t_tail, | ||
466 | t); | ||
467 | GNUNET_CONTAINER_DLL_insert (pi->t_head, | ||
468 | pi->t_tail, | ||
469 | t); | ||
470 | } | ||
406 | 471 | ||
407 | /** | ||
408 | * Handle to ATS connectivity. | ||
409 | */ | ||
410 | static struct GNUNET_ATS_ConnectivityHandle *ats_ch; | ||
411 | 472 | ||
412 | /** | 473 | /** |
413 | * Our private key. | 474 | * Send @a msg to @a pi. |
475 | * | ||
476 | * @param pi where to send the message | ||
477 | * @param msg message to send | ||
414 | */ | 478 | */ |
415 | static struct GNUNET_CRYPTO_EddsaPrivateKey my_private_key; | 479 | static void |
480 | do_send (struct PeerInfo *pi, | ||
481 | const struct GNUNET_MessageHeader *msg) | ||
482 | { | ||
483 | struct Target *t; | ||
484 | |||
485 | for (t = pi->t_head; | ||
486 | NULL != t; | ||
487 | t = t->next) | ||
488 | if (t->load < MAXIMUM_PENDING_PER_PEER) | ||
489 | break; | ||
490 | if (NULL == t) | ||
491 | { | ||
492 | /* all targets busy, drop message */ | ||
493 | GNUNET_STATISTICS_update (GDS_stats, | ||
494 | "# messages dropped (underlays busy)", | ||
495 | 1, | ||
496 | GNUNET_NO); | ||
497 | return; | ||
498 | } | ||
499 | t->load++; | ||
500 | /* rotate busy targets to the end */ | ||
501 | if (MAXIMUM_PENDING_PER_PEER == t->load) | ||
502 | { | ||
503 | GNUNET_CONTAINER_DLL_remove (pi->t_head, | ||
504 | pi->t_tail, | ||
505 | t); | ||
506 | GNUNET_CONTAINER_DLL_insert_tail (pi->t_head, | ||
507 | pi->t_tail, | ||
508 | t); | ||
509 | } | ||
510 | GDS_u_send (t->u, | ||
511 | t->utarget, | ||
512 | msg, | ||
513 | ntohs (msg->size), | ||
514 | &send_done_cb, | ||
515 | t); | ||
516 | } | ||
416 | 517 | ||
417 | 518 | ||
418 | /** | 519 | /** |
@@ -426,11 +527,10 @@ static struct GNUNET_CRYPTO_EddsaPrivateKey my_private_key; | |||
426 | * @param pred predecessor peer ID | 527 | * @param pred predecessor peer ID |
427 | * @param succ successor peer ID | 528 | * @param succ successor peer ID |
428 | * @param[out] sig where to write the signature | 529 | * @param[out] sig where to write the signature |
429 | * (of purpose #GNUNET_SIGNATURE_PURPOSE_DHT_HOP) | 530 | * (of purpose #GNUNET_SIGNATURE_PURPOSE_DHT_PUT_HOP) |
430 | */ | 531 | */ |
431 | static void | 532 | static void |
432 | sign_path (const struct GNUNET_HashCode *key, | 533 | sign_path (const void *data, |
433 | const void *data, | ||
434 | size_t data_size, | 534 | size_t data_size, |
435 | struct GNUNET_TIME_Absolute exp_time, | 535 | struct GNUNET_TIME_Absolute exp_time, |
436 | const struct GNUNET_PeerIdentity *pred, | 536 | const struct GNUNET_PeerIdentity *pred, |
@@ -441,7 +541,6 @@ sign_path (const struct GNUNET_HashCode *key, | |||
441 | .purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_DHT_HOP), | 541 | .purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_DHT_HOP), |
442 | .purpose.size = htonl (sizeof (hs)), | 542 | .purpose.size = htonl (sizeof (hs)), |
443 | .expiration_time = GNUNET_TIME_absolute_hton (exp_time), | 543 | .expiration_time = GNUNET_TIME_absolute_hton (exp_time), |
444 | .key = *key, | ||
445 | .pred = *pred, | 544 | .pred = *pred, |
446 | .succ = *succ | 545 | .succ = *succ |
447 | }; | 546 | }; |
@@ -449,7 +548,7 @@ sign_path (const struct GNUNET_HashCode *key, | |||
449 | GNUNET_CRYPTO_hash (data, | 548 | GNUNET_CRYPTO_hash (data, |
450 | data_size, | 549 | data_size, |
451 | &hs.h_data); | 550 | &hs.h_data); |
452 | GNUNET_CRYPTO_eddsa_sign (&my_private_key, | 551 | GNUNET_CRYPTO_eddsa_sign (&GDS_my_private_key, |
453 | &hs, | 552 | &hs, |
454 | sig); | 553 | sig); |
455 | } | 554 | } |
@@ -469,7 +568,7 @@ find_bucket (const struct GNUNET_HashCode *hc) | |||
469 | unsigned int bits; | 568 | unsigned int bits; |
470 | 569 | ||
471 | GNUNET_CRYPTO_hash_xor (hc, | 570 | GNUNET_CRYPTO_hash_xor (hc, |
472 | &my_identity_hash, | 571 | &GDS_my_identity_hash, |
473 | &xor); | 572 | &xor); |
474 | bits = GNUNET_CRYPTO_hash_count_leading_zeros (&xor); | 573 | bits = GNUNET_CRYPTO_hash_count_leading_zeros (&xor); |
475 | if (bits == MAX_BUCKETS) | 574 | if (bits == MAX_BUCKETS) |
@@ -483,171 +582,6 @@ find_bucket (const struct GNUNET_HashCode *hc) | |||
483 | 582 | ||
484 | 583 | ||
485 | /** | 584 | /** |
486 | * Function called when #GNUNET_TRANSPORT_offer_hello() is done. | ||
487 | * Clean up the "oh" field in the @a cls | ||
488 | * | ||
489 | * @param cls a `struct ConnectInfo` | ||
490 | */ | ||
491 | static void | ||
492 | offer_hello_done (void *cls) | ||
493 | { | ||
494 | struct ConnectInfo *ci = cls; | ||
495 | |||
496 | ci->oh = NULL; | ||
497 | } | ||
498 | |||
499 | |||
500 | /** | ||
501 | * Function called for all entries in #all_desired_peers to clean up. | ||
502 | * | ||
503 | * @param cls NULL | ||
504 | * @param peer peer the entry is for | ||
505 | * @param value the value to remove | ||
506 | * @return #GNUNET_YES | ||
507 | */ | ||
508 | static enum GNUNET_GenericReturnValue | ||
509 | free_connect_info (void *cls, | ||
510 | const struct GNUNET_PeerIdentity *peer, | ||
511 | void *value) | ||
512 | { | ||
513 | struct ConnectInfo *ci = value; | ||
514 | |||
515 | (void) cls; | ||
516 | GNUNET_assert (GNUNET_YES == | ||
517 | GNUNET_CONTAINER_multipeermap_remove (all_desired_peers, | ||
518 | peer, | ||
519 | ci)); | ||
520 | if (NULL != ci->sh) | ||
521 | { | ||
522 | GNUNET_ATS_connectivity_suggest_cancel (ci->sh); | ||
523 | ci->sh = NULL; | ||
524 | } | ||
525 | if (NULL != ci->oh) | ||
526 | { | ||
527 | GNUNET_TRANSPORT_offer_hello_cancel (ci->oh); | ||
528 | ci->oh = NULL; | ||
529 | } | ||
530 | GNUNET_free (ci); | ||
531 | return GNUNET_YES; | ||
532 | } | ||
533 | |||
534 | |||
535 | /** | ||
536 | * Consider if we want to connect to a given peer, and if so | ||
537 | * let ATS know. If applicable, the HELLO is offered to the | ||
538 | * TRANSPORT service. | ||
539 | * | ||
540 | * @param pid peer to consider connectivity requirements for | ||
541 | * @param h a HELLO message, or NULL | ||
542 | */ | ||
543 | static void | ||
544 | try_connect (const struct GNUNET_PeerIdentity *pid, | ||
545 | const struct GNUNET_MessageHeader *h) | ||
546 | { | ||
547 | int bucket_idx; | ||
548 | struct GNUNET_HashCode pid_hash; | ||
549 | struct ConnectInfo *ci; | ||
550 | uint32_t strength; | ||
551 | struct PeerBucket *bucket; | ||
552 | |||
553 | GNUNET_CRYPTO_hash (pid, | ||
554 | sizeof(struct GNUNET_PeerIdentity), | ||
555 | &pid_hash); | ||
556 | bucket_idx = find_bucket (&pid_hash); | ||
557 | if (bucket_idx < 0) | ||
558 | { | ||
559 | GNUNET_break (0); | ||
560 | return; /* self!? */ | ||
561 | } | ||
562 | bucket = &k_buckets[bucket_idx]; | ||
563 | ci = GNUNET_CONTAINER_multipeermap_get (all_desired_peers, | ||
564 | pid); | ||
565 | if (bucket->peers_size < bucket_size) | ||
566 | strength = (bucket_size - bucket->peers_size) * bucket_idx; | ||
567 | else | ||
568 | strength = 0; | ||
569 | if (GNUNET_YES == | ||
570 | GNUNET_CONTAINER_multipeermap_contains (all_connected_peers, | ||
571 | pid)) | ||
572 | strength *= 2; /* double for connected peers */ | ||
573 | if ( (0 == strength) && | ||
574 | (NULL != ci) ) | ||
575 | { | ||
576 | /* release request */ | ||
577 | GNUNET_assert (GNUNET_YES == | ||
578 | free_connect_info (NULL, | ||
579 | pid, | ||
580 | ci)); | ||
581 | return; | ||
582 | } | ||
583 | if (NULL == ci) | ||
584 | { | ||
585 | ci = GNUNET_new (struct ConnectInfo); | ||
586 | GNUNET_assert (GNUNET_OK == | ||
587 | GNUNET_CONTAINER_multipeermap_put (all_desired_peers, | ||
588 | pid, | ||
589 | ci, | ||
590 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_ONLY)); | ||
591 | } | ||
592 | if ( (NULL != ci->oh) && | ||
593 | (NULL != h) ) | ||
594 | GNUNET_TRANSPORT_offer_hello_cancel (ci->oh); | ||
595 | if (NULL != h) | ||
596 | ci->oh = GNUNET_TRANSPORT_offer_hello (GDS_cfg, | ||
597 | h, | ||
598 | &offer_hello_done, | ||
599 | ci); | ||
600 | if ( (NULL != ci->sh) && | ||
601 | (ci->strength != strength) ) | ||
602 | GNUNET_ATS_connectivity_suggest_cancel (ci->sh); | ||
603 | if (ci->strength != strength) | ||
604 | { | ||
605 | ci->sh = GNUNET_ATS_connectivity_suggest (ats_ch, | ||
606 | pid, | ||
607 | strength); | ||
608 | ci->strength = strength; | ||
609 | } | ||
610 | } | ||
611 | |||
612 | |||
613 | /** | ||
614 | * Function called for each peer in #all_desired_peers during | ||
615 | * #update_connect_preferences() if we have reason to adjust | ||
616 | * the strength of our desire to keep connections to certain | ||
617 | * peers. Calls #try_connect() to update the calculations for | ||
618 | * the given @a pid. | ||
619 | * | ||
620 | * @param cls NULL | ||
621 | * @param pid peer to update | ||
622 | * @param value unused | ||
623 | * @return #GNUNET_YES (continue to iterate) | ||
624 | */ | ||
625 | static enum GNUNET_GenericReturnValue | ||
626 | update_desire_strength (void *cls, | ||
627 | const struct GNUNET_PeerIdentity *pid, | ||
628 | void *value) | ||
629 | { | ||
630 | (void) cls; | ||
631 | (void) value; | ||
632 | try_connect (pid, | ||
633 | NULL); | ||
634 | return GNUNET_YES; | ||
635 | } | ||
636 | |||
637 | |||
638 | /** | ||
639 | * Update our preferences for connectivity as given to ATS. | ||
640 | */ | ||
641 | static void | ||
642 | update_connect_preferences (void) | ||
643 | { | ||
644 | GNUNET_CONTAINER_multipeermap_iterate (all_desired_peers, | ||
645 | &update_desire_strength, | ||
646 | NULL); | ||
647 | } | ||
648 | |||
649 | |||
650 | /** | ||
651 | * Add each of the peers we already know to the Bloom filter of | 585 | * Add each of the peers we already know to the Bloom filter of |
652 | * the request so that we don't get duplicate HELLOs. | 586 | * the request so that we don't get duplicate HELLOs. |
653 | * | 587 | * |
@@ -702,7 +636,7 @@ send_find_peer_message (void *cls) | |||
702 | GNUNET_CRYPTO_QUALITY_WEAK, | 636 | GNUNET_CRYPTO_QUALITY_WEAK, |
703 | GNUNET_TIME_relative_multiply ( | 637 | GNUNET_TIME_relative_multiply ( |
704 | DHT_AVG_FIND_PEER_INTERVAL, | 638 | DHT_AVG_FIND_PEER_INTERVAL, |
705 | 100 * (1 + newly_found_peers) / bucket_size).rel_value_us); | 639 | 1 + 100 * (1 + newly_found_peers) / bucket_size).rel_value_us); |
706 | newly_found_peers = 0; | 640 | newly_found_peers = 0; |
707 | GNUNET_assert (NULL == find_peer_task); | 641 | GNUNET_assert (NULL == find_peer_task); |
708 | find_peer_task = | 642 | find_peer_task = |
@@ -719,7 +653,7 @@ send_find_peer_message (void *cls) | |||
719 | struct GNUNET_CONTAINER_BloomFilter *peer_bf; | 653 | struct GNUNET_CONTAINER_BloomFilter *peer_bf; |
720 | 654 | ||
721 | bg = GNUNET_BLOCK_group_create (GDS_block_context, | 655 | bg = GNUNET_BLOCK_group_create (GDS_block_context, |
722 | GNUNET_BLOCK_TYPE_DHT_HELLO, | 656 | GNUNET_BLOCK_TYPE_DHT_URL_HELLO, |
723 | GNUNET_CRYPTO_random_u32 ( | 657 | GNUNET_CRYPTO_random_u32 ( |
724 | GNUNET_CRYPTO_QUALITY_WEAK, | 658 | GNUNET_CRYPTO_QUALITY_WEAK, |
725 | UINT32_MAX), | 659 | UINT32_MAX), |
@@ -736,12 +670,12 @@ send_find_peer_message (void *cls) | |||
736 | DHT_BLOOM_SIZE, | 670 | DHT_BLOOM_SIZE, |
737 | GNUNET_CONSTANTS_BLOOMFILTER_K); | 671 | GNUNET_CONSTANTS_BLOOMFILTER_K); |
738 | if (GNUNET_OK != | 672 | if (GNUNET_OK != |
739 | GDS_NEIGHBOURS_handle_get (GNUNET_BLOCK_TYPE_DHT_HELLO, | 673 | GDS_NEIGHBOURS_handle_get (GNUNET_BLOCK_TYPE_DHT_URL_HELLO, |
740 | GNUNET_DHT_RO_FIND_PEER | 674 | GNUNET_DHT_RO_FIND_APPROXIMATE |
741 | | GNUNET_DHT_RO_RECORD_ROUTE, | 675 | | GNUNET_DHT_RO_RECORD_ROUTE, |
742 | FIND_PEER_REPLICATION_LEVEL, | 676 | FIND_PEER_REPLICATION_LEVEL, |
743 | 0, /* hop count */ | 677 | 0, /* hop count */ |
744 | &my_identity_hash, | 678 | &GDS_my_identity_hash, |
745 | NULL, 0, /* xquery */ | 679 | NULL, 0, /* xquery */ |
746 | bg, | 680 | bg, |
747 | peer_bf)) | 681 | peer_bf)) |
@@ -765,123 +699,180 @@ send_find_peer_message (void *cls) | |||
765 | 699 | ||
766 | 700 | ||
767 | /** | 701 | /** |
768 | * Method called whenever a peer connects. | 702 | * The list of the first #bucket_size peers of @a bucket |
703 | * changed. We should thus make sure we have called 'hold' | ||
704 | * all of the first bucket_size peers! | ||
769 | * | 705 | * |
770 | * @param cls closure | 706 | * @param[in,out] bucket the bucket where the peer set changed |
771 | * @param peer peer identity this notification is about | ||
772 | * @param mq message queue for sending messages to @a peer | ||
773 | * @return our `struct PeerInfo` for @a peer | ||
774 | */ | 707 | */ |
775 | static void * | 708 | static void |
776 | handle_core_connect (void *cls, | 709 | update_hold (struct PeerBucket *bucket) |
777 | const struct GNUNET_PeerIdentity *peer, | ||
778 | struct GNUNET_MQ_Handle *mq) | ||
779 | { | 710 | { |
711 | unsigned int off = 0; | ||
712 | |||
713 | /* find the peer -- we just go over all of them, should | ||
714 | be hardly any more expensive than just finding the 'right' | ||
715 | one. */ | ||
716 | for (struct PeerInfo *pos = bucket->head; | ||
717 | NULL != pos; | ||
718 | pos = pos->next) | ||
719 | { | ||
720 | if (off > bucket_size) | ||
721 | break; /* We only hold up to #bucket_size peers per bucket */ | ||
722 | off++; | ||
723 | for (struct Target *tp = pos->t_head; | ||
724 | NULL != tp; | ||
725 | tp = tp->next) | ||
726 | if (NULL == tp->ph) | ||
727 | tp->ph = GDS_u_hold (tp->u, | ||
728 | tp->utarget); | ||
729 | } | ||
730 | } | ||
731 | |||
732 | |||
733 | void | ||
734 | GDS_u_connect (void *cls, | ||
735 | struct GNUNET_DHTU_Target *target, | ||
736 | const struct GNUNET_PeerIdentity *pid, | ||
737 | void **ctx) | ||
738 | { | ||
739 | struct GDS_Underlay *u = cls; | ||
780 | struct PeerInfo *pi; | 740 | struct PeerInfo *pi; |
781 | struct PeerBucket *bucket; | 741 | struct PeerBucket *bucket; |
742 | bool do_hold = false; | ||
782 | 743 | ||
783 | (void) cls; | ||
784 | /* Check for connect to self message */ | 744 | /* Check for connect to self message */ |
785 | if (0 == GNUNET_memcmp (&my_identity, | 745 | if (0 == GNUNET_memcmp (&GDS_my_identity, |
786 | peer)) | 746 | pid)) |
787 | return NULL; | 747 | return; |
788 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 748 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
789 | "Connected to peer %s\n", | 749 | "Connected to peer %s\n", |
790 | GNUNET_i2s (peer)); | 750 | GNUNET_i2s (pid)); |
791 | GNUNET_assert (NULL == | 751 | pi = GNUNET_CONTAINER_multipeermap_get (all_connected_peers, |
792 | GNUNET_CONTAINER_multipeermap_get (all_connected_peers, | 752 | pid); |
793 | peer)); | 753 | if (NULL == pi) |
794 | GNUNET_STATISTICS_update (GDS_stats, | ||
795 | "# peers connected", | ||
796 | 1, | ||
797 | GNUNET_NO); | ||
798 | pi = GNUNET_new (struct PeerInfo); | ||
799 | pi->id = peer; | ||
800 | pi->mq = mq; | ||
801 | GNUNET_CRYPTO_hash (peer, | ||
802 | sizeof(struct GNUNET_PeerIdentity), | ||
803 | &pi->phash); | ||
804 | pi->peer_bucket = find_bucket (&pi->phash); | ||
805 | GNUNET_assert ( (pi->peer_bucket >= 0) && | ||
806 | ((unsigned int) pi->peer_bucket < MAX_BUCKETS)); | ||
807 | bucket = &k_buckets[pi->peer_bucket]; | ||
808 | GNUNET_CONTAINER_DLL_insert_tail (bucket->head, | ||
809 | bucket->tail, | ||
810 | pi); | ||
811 | bucket->peers_size++; | ||
812 | closest_bucket = GNUNET_MAX (closest_bucket, | ||
813 | (unsigned int) pi->peer_bucket + 1); | ||
814 | GNUNET_assert (GNUNET_OK == | ||
815 | GNUNET_CONTAINER_multipeermap_put (all_connected_peers, | ||
816 | pi->id, | ||
817 | pi, | ||
818 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_ONLY)); | ||
819 | if (bucket->peers_size <= bucket_size) | ||
820 | { | 754 | { |
821 | update_connect_preferences (); | 755 | GNUNET_STATISTICS_update (GDS_stats, |
822 | newly_found_peers++; | 756 | "# peers connected", |
757 | 1, | ||
758 | GNUNET_NO); | ||
759 | pi = GNUNET_new (struct PeerInfo); | ||
760 | pi->id = *pid; | ||
761 | GNUNET_CRYPTO_hash (pid, | ||
762 | sizeof(*pid), | ||
763 | &pi->phash); | ||
764 | pi->peer_bucket = find_bucket (&pi->phash); | ||
765 | GNUNET_assert ( (pi->peer_bucket >= 0) && | ||
766 | ((unsigned int) pi->peer_bucket < MAX_BUCKETS)); | ||
767 | bucket = &k_buckets[pi->peer_bucket]; | ||
768 | GNUNET_CONTAINER_DLL_insert_tail (bucket->head, | ||
769 | bucket->tail, | ||
770 | pi); | ||
771 | bucket->peers_size++; | ||
772 | closest_bucket = GNUNET_MAX (closest_bucket, | ||
773 | (unsigned int) pi->peer_bucket + 1); | ||
774 | GNUNET_assert (GNUNET_OK == | ||
775 | GNUNET_CONTAINER_multipeermap_put (all_connected_peers, | ||
776 | &pi->id, | ||
777 | pi, | ||
778 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_ONLY)); | ||
779 | if (bucket->peers_size <= bucket_size) | ||
780 | { | ||
781 | newly_found_peers++; | ||
782 | do_hold = true; | ||
783 | } | ||
784 | if ( (1 == GNUNET_CONTAINER_multipeermap_size (all_connected_peers)) && | ||
785 | (GNUNET_YES != disable_try_connect) ) | ||
786 | { | ||
787 | /* got a first connection, good time to start with FIND PEER requests... */ | ||
788 | GNUNET_assert (NULL == find_peer_task); | ||
789 | find_peer_task = GNUNET_SCHEDULER_add_now (&send_find_peer_message, | ||
790 | NULL); | ||
791 | } | ||
823 | } | 792 | } |
824 | if ( (1 == GNUNET_CONTAINER_multipeermap_size (all_connected_peers)) && | ||
825 | (GNUNET_YES != disable_try_connect) ) | ||
826 | { | 793 | { |
827 | /* got a first connection, good time to start with FIND PEER requests... */ | 794 | struct Target *t; |
828 | GNUNET_assert (NULL == find_peer_task); | 795 | |
829 | find_peer_task = GNUNET_SCHEDULER_add_now (&send_find_peer_message, | 796 | t = GNUNET_new (struct Target); |
830 | NULL); | 797 | t->u = u; |
798 | t->utarget = target; | ||
799 | t->pi = pi; | ||
800 | GNUNET_CONTAINER_DLL_insert (pi->t_head, | ||
801 | pi->t_tail, | ||
802 | t); | ||
803 | *ctx = t; | ||
804 | |||
831 | } | 805 | } |
832 | return pi; | 806 | if (do_hold) |
807 | update_hold (bucket); | ||
833 | } | 808 | } |
834 | 809 | ||
835 | 810 | ||
836 | /** | 811 | void |
837 | * Method called whenever a peer disconnects. | 812 | GDS_u_disconnect (void *ctx) |
838 | * | ||
839 | * @param cls closure | ||
840 | * @param peer peer identity this notification is about | ||
841 | * @param internal_cls our `struct PeerInfo` for @a peer | ||
842 | */ | ||
843 | static void | ||
844 | handle_core_disconnect (void *cls, | ||
845 | const struct GNUNET_PeerIdentity *peer, | ||
846 | void *internal_cls) | ||
847 | { | 813 | { |
848 | struct PeerInfo *to_remove = internal_cls; | 814 | struct Target *t = ctx; |
815 | struct PeerInfo *pi; | ||
849 | struct PeerBucket *bucket; | 816 | struct PeerBucket *bucket; |
817 | bool was_held = false; | ||
850 | 818 | ||
851 | (void) cls; | ||
852 | /* Check for disconnect from self message (on shutdown) */ | 819 | /* Check for disconnect from self message (on shutdown) */ |
853 | if (NULL == to_remove) | 820 | if (NULL == t) |
854 | return; | 821 | return; |
822 | pi = t->pi; | ||
823 | GNUNET_CONTAINER_DLL_remove (pi->t_head, | ||
824 | pi->t_tail, | ||
825 | t); | ||
826 | if (NULL != t->ph) | ||
827 | { | ||
828 | GDS_u_drop (t->u, | ||
829 | t->ph); | ||
830 | t->ph = NULL; | ||
831 | was_held = true; | ||
832 | } | ||
833 | if (t->load > 0) | ||
834 | { | ||
835 | t->dropped = true; | ||
836 | t->pi = NULL; | ||
837 | } | ||
838 | else | ||
839 | { | ||
840 | GNUNET_free (t); | ||
841 | } | ||
842 | if (NULL != pi->t_head) | ||
843 | return; /* got other connections still */ | ||
855 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 844 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
856 | "Disconnected from peer %s\n", | 845 | "Disconnected from peer %s\n", |
857 | GNUNET_i2s (peer)); | 846 | GNUNET_i2s (&pi->id)); |
858 | GNUNET_STATISTICS_update (GDS_stats, | 847 | GNUNET_STATISTICS_update (GDS_stats, |
859 | "# peers connected", | 848 | "# peers connected", |
860 | -1, | 849 | -1, |
861 | GNUNET_NO); | 850 | GNUNET_NO); |
862 | GNUNET_assert (GNUNET_YES == | 851 | GNUNET_assert (GNUNET_YES == |
863 | GNUNET_CONTAINER_multipeermap_remove (all_connected_peers, | 852 | GNUNET_CONTAINER_multipeermap_remove (all_connected_peers, |
864 | peer, | 853 | &pi->id, |
865 | to_remove)); | 854 | pi)); |
866 | if ( (0 == GNUNET_CONTAINER_multipeermap_size (all_connected_peers)) && | 855 | if ( (0 == GNUNET_CONTAINER_multipeermap_size (all_connected_peers)) && |
867 | (GNUNET_YES != disable_try_connect)) | 856 | (GNUNET_YES != disable_try_connect)) |
868 | { | 857 | { |
869 | GNUNET_SCHEDULER_cancel (find_peer_task); | 858 | GNUNET_SCHEDULER_cancel (find_peer_task); |
870 | find_peer_task = NULL; | 859 | find_peer_task = NULL; |
871 | } | 860 | } |
872 | GNUNET_assert (to_remove->peer_bucket >= 0); | 861 | GNUNET_assert (pi->peer_bucket >= 0); |
873 | bucket = &k_buckets[to_remove->peer_bucket]; | 862 | bucket = &k_buckets[pi->peer_bucket]; |
874 | GNUNET_CONTAINER_DLL_remove (bucket->head, | 863 | GNUNET_CONTAINER_DLL_remove (bucket->head, |
875 | bucket->tail, | 864 | bucket->tail, |
876 | to_remove); | 865 | pi); |
877 | GNUNET_assert (bucket->peers_size > 0); | 866 | GNUNET_assert (bucket->peers_size > 0); |
878 | bucket->peers_size--; | 867 | bucket->peers_size--; |
868 | if ( (was_held) && | ||
869 | (bucket->peers_size >= bucket_size - 1) ) | ||
870 | update_hold (bucket); | ||
879 | while ( (closest_bucket > 0) && | 871 | while ( (closest_bucket > 0) && |
880 | (0 == k_buckets[closest_bucket - 1].peers_size)) | 872 | (0 == k_buckets[closest_bucket - 1].peers_size)) |
881 | closest_bucket--; | 873 | closest_bucket--; |
882 | if (bucket->peers_size < bucket_size) | 874 | GNUNET_free (pi->hello); |
883 | update_connect_preferences (); | 875 | GNUNET_free (pi); |
884 | GNUNET_free (to_remove); | ||
885 | } | 876 | } |
886 | 877 | ||
887 | 878 | ||
@@ -894,17 +885,14 @@ handle_core_disconnect (void *cls, | |||
894 | * @return Some number of peers to forward the message to | 885 | * @return Some number of peers to forward the message to |
895 | */ | 886 | */ |
896 | static unsigned int | 887 | static unsigned int |
897 | get_forward_count (uint32_t hop_count, | 888 | get_forward_count (uint16_t hop_count, |
898 | uint32_t target_replication) | 889 | uint16_t target_replication) |
899 | { | 890 | { |
900 | uint32_t random_value; | 891 | uint32_t random_value; |
901 | uint32_t forward_count; | 892 | uint32_t forward_count; |
902 | float target_value; | 893 | float target_value; |
894 | float rm1; | ||
903 | 895 | ||
904 | if (0 == target_replication) | ||
905 | target_replication = 1; /* 0 is verboten */ | ||
906 | if (target_replication > GNUNET_DHT_MAXIMUM_REPLICATION_LEVEL) | ||
907 | target_replication = GNUNET_DHT_MAXIMUM_REPLICATION_LEVEL; | ||
908 | if (hop_count > GDS_NSE_get () * 4.0) | 896 | if (hop_count > GDS_NSE_get () * 4.0) |
909 | { | 897 | { |
910 | /* forcefully terminate */ | 898 | /* forcefully terminate */ |
@@ -919,15 +907,15 @@ get_forward_count (uint32_t hop_count, | |||
919 | /* Once we have reached our ideal number of hops, only forward to 1 peer */ | 907 | /* Once we have reached our ideal number of hops, only forward to 1 peer */ |
920 | return 1; | 908 | return 1; |
921 | } | 909 | } |
922 | /* bound by system-wide maximum */ | 910 | /* bound by system-wide maximum and minimum */ |
911 | if (0 == target_replication) | ||
912 | target_replication = 1; /* 0 is verboten */ | ||
923 | target_replication = | 913 | target_replication = |
924 | GNUNET_MIN (GNUNET_DHT_MAXIMUM_REPLICATION_LEVEL, | 914 | GNUNET_MIN (GNUNET_DHT_MAXIMUM_REPLICATION_LEVEL, |
925 | target_replication); | 915 | target_replication); |
916 | rm1 = target_replication - 1.0; | ||
926 | target_value = | 917 | target_value = |
927 | 1 + (target_replication - 1.0) / (GDS_NSE_get () | 918 | 1 + (rm1) / (GDS_NSE_get () + (rm1 * hop_count)); |
928 | + ((float) (target_replication - 1.0) | ||
929 | * hop_count)); | ||
930 | |||
931 | 919 | ||
932 | /* Set forward count to floor of target_value */ | 920 | /* Set forward count to floor of target_value */ |
933 | forward_count = (uint32_t) target_value; | 921 | forward_count = (uint32_t) target_value; |
@@ -956,7 +944,7 @@ enum GNUNET_GenericReturnValue | |||
956 | GDS_am_closest_peer (const struct GNUNET_HashCode *key, | 944 | GDS_am_closest_peer (const struct GNUNET_HashCode *key, |
957 | const struct GNUNET_CONTAINER_BloomFilter *bloom) | 945 | const struct GNUNET_CONTAINER_BloomFilter *bloom) |
958 | { | 946 | { |
959 | if (0 == GNUNET_memcmp (&my_identity_hash, | 947 | if (0 == GNUNET_memcmp (&GDS_my_identity_hash, |
960 | key)) | 948 | key)) |
961 | return GNUNET_YES; | 949 | return GNUNET_YES; |
962 | for (int bucket_num = find_bucket (key); | 950 | for (int bucket_num = find_bucket (key); |
@@ -983,7 +971,7 @@ GDS_am_closest_peer (const struct GNUNET_HashCode *key, | |||
983 | because an unfiltered peer exists, we are not the | 971 | because an unfiltered peer exists, we are not the |
984 | closest. */ | 972 | closest. */ |
985 | int delta = GNUNET_CRYPTO_hash_xorcmp (&pos->phash, | 973 | int delta = GNUNET_CRYPTO_hash_xorcmp (&pos->phash, |
986 | &my_identity_hash, | 974 | &GDS_my_identity_hash, |
987 | key); | 975 | key); |
988 | switch (delta) | 976 | switch (delta) |
989 | { | 977 | { |
@@ -1047,7 +1035,7 @@ select_peer (const struct GNUNET_HashCode *key, | |||
1047 | struct GNUNET_HashCode xor; | 1035 | struct GNUNET_HashCode xor; |
1048 | 1036 | ||
1049 | GNUNET_CRYPTO_hash_xor (key, | 1037 | GNUNET_CRYPTO_hash_xor (key, |
1050 | &my_identity_hash, | 1038 | &GDS_my_identity_hash, |
1051 | &xor); | 1039 | &xor); |
1052 | best_bucket = GNUNET_CRYPTO_hash_count_leading_zeros (&xor); | 1040 | best_bucket = GNUNET_CRYPTO_hash_count_leading_zeros (&xor); |
1053 | } | 1041 | } |
@@ -1067,13 +1055,14 @@ select_peer (const struct GNUNET_HashCode *key, | |||
1067 | if (count >= bucket_size) | 1055 | if (count >= bucket_size) |
1068 | break; /* we only consider first #bucket_size entries per bucket */ | 1056 | break; /* we only consider first #bucket_size entries per bucket */ |
1069 | count++; | 1057 | count++; |
1070 | if (GNUNET_YES == | 1058 | if ( (NULL != bloom) && |
1071 | GNUNET_CONTAINER_bloomfilter_test (bloom, | 1059 | (GNUNET_YES == |
1072 | &pos->phash)) | 1060 | GNUNET_CONTAINER_bloomfilter_test (bloom, |
1061 | &pos->phash)) ) | ||
1073 | { | 1062 | { |
1074 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1063 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1075 | "Excluded peer `%s' due to BF match in greedy routing for %s\n", | 1064 | "Excluded peer `%s' due to BF match in greedy routing for %s\n", |
1076 | GNUNET_i2s (pos->id), | 1065 | GNUNET_i2s (&pos->id), |
1077 | GNUNET_h2s (key)); | 1066 | GNUNET_h2s (key)); |
1078 | continue; | 1067 | continue; |
1079 | } | 1068 | } |
@@ -1140,7 +1129,7 @@ select_peer (const struct GNUNET_HashCode *key, | |||
1140 | } | 1129 | } |
1141 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1130 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1142 | "Selected peer `%s' in greedy routing for %s\n", | 1131 | "Selected peer `%s' in greedy routing for %s\n", |
1143 | GNUNET_i2s (chosen->id), | 1132 | GNUNET_i2s (&chosen->id), |
1144 | GNUNET_h2s (key)); | 1133 | GNUNET_h2s (key)); |
1145 | return chosen; | 1134 | return chosen; |
1146 | } /* end of 'greedy' peer selection */ | 1135 | } /* end of 'greedy' peer selection */ |
@@ -1155,22 +1144,24 @@ select_peer (const struct GNUNET_HashCode *key, | |||
1155 | 1144 | ||
1156 | for (unsigned int bc = 0; bc < closest_bucket; bc++) | 1145 | for (unsigned int bc = 0; bc < closest_bucket; bc++) |
1157 | { | 1146 | { |
1147 | struct PeerBucket *bucket = &k_buckets[bc]; | ||
1158 | unsigned int count = 0; | 1148 | unsigned int count = 0; |
1159 | 1149 | ||
1160 | for (struct PeerInfo *pos = k_buckets[bc].head; | 1150 | for (struct PeerInfo *pos = bucket->head; |
1161 | NULL != pos; | 1151 | NULL != pos; |
1162 | pos = pos->next) | 1152 | pos = pos->next) |
1163 | { | 1153 | { |
1164 | count++; | 1154 | count++; |
1165 | if (count > bucket_size) | 1155 | if (count > bucket_size) |
1166 | break; /* limits search to #bucket_size peers per bucket */ | 1156 | break; /* limits search to #bucket_size peers per bucket */ |
1167 | if (GNUNET_YES == | 1157 | if ( (NULL != bloom) && |
1168 | GNUNET_CONTAINER_bloomfilter_test (bloom, | 1158 | (GNUNET_YES == |
1169 | &pos->phash)) | 1159 | GNUNET_CONTAINER_bloomfilter_test (bloom, |
1160 | &pos->phash)) ) | ||
1170 | { | 1161 | { |
1171 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1162 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1172 | "Excluded peer `%s' due to BF match in random routing for %s\n", | 1163 | "Excluded peer `%s' due to BF match in random routing for %s\n", |
1173 | GNUNET_i2s (pos->id), | 1164 | GNUNET_i2s (&pos->id), |
1174 | GNUNET_h2s (key)); | 1165 | GNUNET_h2s (key)); |
1175 | continue; /* Ignore filtered peers */ | 1166 | continue; /* Ignore filtered peers */ |
1176 | } | 1167 | } |
@@ -1201,15 +1192,16 @@ select_peer (const struct GNUNET_HashCode *key, | |||
1201 | if (count > bucket_size) | 1192 | if (count > bucket_size) |
1202 | break; /* limits search to #bucket_size peers per bucket */ | 1193 | break; /* limits search to #bucket_size peers per bucket */ |
1203 | 1194 | ||
1204 | if (GNUNET_YES == | 1195 | if ( (NULL != bloom) && |
1205 | GNUNET_CONTAINER_bloomfilter_test (bloom, | 1196 | (GNUNET_YES == |
1206 | &pos->phash)) | 1197 | GNUNET_CONTAINER_bloomfilter_test (bloom, |
1198 | &pos->phash)) ) | ||
1207 | continue; /* Ignore bloomfiltered peers */ | 1199 | continue; /* Ignore bloomfiltered peers */ |
1208 | if (0 == selected--) | 1200 | if (0 == selected--) |
1209 | { | 1201 | { |
1210 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1202 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1211 | "Selected peer `%s' in random routing for %s\n", | 1203 | "Selected peer `%s' in random routing for %s\n", |
1212 | GNUNET_i2s (pos->id), | 1204 | GNUNET_i2s (&pos->id), |
1213 | GNUNET_h2s (key)); | 1205 | GNUNET_h2s (key)); |
1214 | return pos; | 1206 | return pos; |
1215 | } | 1207 | } |
@@ -1237,8 +1229,8 @@ select_peer (const struct GNUNET_HashCode *key, | |||
1237 | static unsigned int | 1229 | static unsigned int |
1238 | get_target_peers (const struct GNUNET_HashCode *key, | 1230 | get_target_peers (const struct GNUNET_HashCode *key, |
1239 | struct GNUNET_CONTAINER_BloomFilter *bloom, | 1231 | struct GNUNET_CONTAINER_BloomFilter *bloom, |
1240 | uint32_t hop_count, | 1232 | uint16_t hop_count, |
1241 | uint32_t target_replication, | 1233 | uint16_t target_replication, |
1242 | struct PeerInfo ***targets) | 1234 | struct PeerInfo ***targets) |
1243 | { | 1235 | { |
1244 | unsigned int target; | 1236 | unsigned int target; |
@@ -1294,11 +1286,36 @@ get_target_peers (const struct GNUNET_HashCode *key, | |||
1294 | } | 1286 | } |
1295 | 1287 | ||
1296 | 1288 | ||
1289 | /** | ||
1290 | * If we got a HELLO, consider it for our own routing table | ||
1291 | * | ||
1292 | * @param bd block data we got | ||
1293 | */ | ||
1294 | static void | ||
1295 | hello_check (const struct GDS_DATACACHE_BlockData *bd) | ||
1296 | { | ||
1297 | struct GNUNET_PeerIdentity pid; | ||
1298 | struct GNUNET_HELLO_Builder *b; | ||
1299 | |||
1300 | if (GNUNET_BLOCK_TYPE_DHT_URL_HELLO != bd->type) | ||
1301 | return; | ||
1302 | |||
1303 | b = GNUNET_HELLO_builder_from_block (bd->data, | ||
1304 | bd->data_size); | ||
1305 | if (GNUNET_YES != disable_try_connect) | ||
1306 | GNUNET_HELLO_builder_iterate (b, | ||
1307 | &pid, | ||
1308 | &GDS_try_connect, | ||
1309 | &pid); | ||
1310 | GNUNET_HELLO_builder_free (b); | ||
1311 | } | ||
1312 | |||
1313 | |||
1297 | enum GNUNET_GenericReturnValue | 1314 | enum GNUNET_GenericReturnValue |
1298 | GDS_NEIGHBOURS_handle_put (const struct GDS_DATACACHE_BlockData *bd, | 1315 | GDS_NEIGHBOURS_handle_put (const struct GDS_DATACACHE_BlockData *bd, |
1299 | enum GNUNET_DHT_RouteOption options, | 1316 | enum GNUNET_DHT_RouteOption options, |
1300 | uint32_t desired_replication_level, | 1317 | uint16_t desired_replication_level, |
1301 | uint32_t hop_count, | 1318 | uint16_t hop_count, |
1302 | struct GNUNET_CONTAINER_BloomFilter *bf) | 1319 | struct GNUNET_CONTAINER_BloomFilter *bf) |
1303 | { | 1320 | { |
1304 | unsigned int target_count; | 1321 | unsigned int target_count; |
@@ -1308,27 +1325,31 @@ GDS_NEIGHBOURS_handle_put (const struct GDS_DATACACHE_BlockData *bd, | |||
1308 | unsigned int put_path_length = bd->put_path_length; | 1325 | unsigned int put_path_length = bd->put_path_length; |
1309 | 1326 | ||
1310 | GNUNET_assert (NULL != bf); | 1327 | GNUNET_assert (NULL != bf); |
1311 | #if SANITY_CHECKS | 1328 | #if SANITY_CHECKS > 1 |
1312 | if (0 != | 1329 | if (0 != |
1313 | GNUNET_DHT_verify_path (&bd->key, | 1330 | GNUNET_DHT_verify_path (bd->data, |
1314 | bd->data, | ||
1315 | bd->data_size, | 1331 | bd->data_size, |
1316 | bd->expiration_time, | 1332 | bd->expiration_time, |
1317 | bd->put_path, | 1333 | bd->put_path, |
1318 | bd->put_path_length, | 1334 | bd->put_path_length, |
1319 | NULL, 0, /* get_path */ | 1335 | NULL, 0, /* get_path */ |
1320 | &my_identity)) | 1336 | &GDS_my_identity)) |
1321 | { | 1337 | { |
1322 | GNUNET_break_op (0); | 1338 | GNUNET_break_op (0); |
1323 | put_path_length = 0; | 1339 | put_path_length = 0; |
1324 | } | 1340 | } |
1325 | #endif | 1341 | #endif |
1326 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1342 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1327 | "Adding myself (%s) to PUT bloomfilter for %s\n", | 1343 | "Adding myself (%s) to PUT bloomfilter for %s with RO(%s/%s)\n", |
1328 | GNUNET_i2s (&my_identity), | 1344 | GNUNET_i2s (&GDS_my_identity), |
1329 | GNUNET_h2s (&bd->key)); | 1345 | GNUNET_h2s (&bd->key), |
1346 | (options & GNUNET_DHT_RO_DEMULTIPLEX_EVERYWHERE) ? "x" : "-", | ||
1347 | (options & GNUNET_DHT_RO_RECORD_ROUTE) ? "R" : "-"); | ||
1348 | |||
1349 | /* if we got a HELLO, consider it for our own routing table */ | ||
1350 | hello_check (bd); | ||
1330 | GNUNET_CONTAINER_bloomfilter_add (bf, | 1351 | GNUNET_CONTAINER_bloomfilter_add (bf, |
1331 | &my_identity_hash); | 1352 | &GDS_my_identity_hash); |
1332 | GNUNET_STATISTICS_update (GDS_stats, | 1353 | GNUNET_STATISTICS_update (GDS_stats, |
1333 | "# PUT requests routed", | 1354 | "# PUT requests routed", |
1334 | 1, | 1355 | 1, |
@@ -1345,7 +1366,7 @@ GDS_NEIGHBOURS_handle_put (const struct GDS_DATACACHE_BlockData *bd, | |||
1345 | "Routing PUT for %s terminates after %u hops at %s\n", | 1366 | "Routing PUT for %s terminates after %u hops at %s\n", |
1346 | GNUNET_h2s (&bd->key), | 1367 | GNUNET_h2s (&bd->key), |
1347 | (unsigned int) hop_count, | 1368 | (unsigned int) hop_count, |
1348 | GNUNET_i2s (&my_identity)); | 1369 | GNUNET_i2s (&GDS_my_identity)); |
1349 | return GNUNET_NO; | 1370 | return GNUNET_NO; |
1350 | } | 1371 | } |
1351 | msize = bd->put_path_length * sizeof(struct GNUNET_DHT_PathElement) | 1372 | msize = bd->put_path_length * sizeof(struct GNUNET_DHT_PathElement) |
@@ -1367,33 +1388,23 @@ GDS_NEIGHBOURS_handle_put (const struct GDS_DATACACHE_BlockData *bd, | |||
1367 | for (unsigned int i = 0; i < target_count; i++) | 1388 | for (unsigned int i = 0; i < target_count; i++) |
1368 | { | 1389 | { |
1369 | struct PeerInfo *target = targets[i]; | 1390 | struct PeerInfo *target = targets[i]; |
1370 | struct GNUNET_MQ_Envelope *env; | ||
1371 | struct PeerPutMessage *ppm; | 1391 | struct PeerPutMessage *ppm; |
1392 | char buf[sizeof (*ppm) + msize] GNUNET_ALIGN; | ||
1372 | struct GNUNET_DHT_PathElement *pp; | 1393 | struct GNUNET_DHT_PathElement *pp; |
1373 | 1394 | ||
1374 | if (GNUNET_MQ_get_length (target->mq) >= MAXIMUM_PENDING_PER_PEER) | ||
1375 | { | ||
1376 | /* skip */ | ||
1377 | GNUNET_STATISTICS_update (GDS_stats, | ||
1378 | "# P2P messages dropped due to full queue", | ||
1379 | 1, | ||
1380 | GNUNET_NO); | ||
1381 | skip_count++; | ||
1382 | continue; | ||
1383 | } | ||
1384 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1395 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1385 | "Routing PUT for %s after %u hops to %s\n", | 1396 | "Routing PUT for %s after %u hops to %s\n", |
1386 | GNUNET_h2s (&bd->key), | 1397 | GNUNET_h2s (&bd->key), |
1387 | (unsigned int) hop_count, | 1398 | (unsigned int) hop_count, |
1388 | GNUNET_i2s (target->id)); | 1399 | GNUNET_i2s (&target->id)); |
1389 | env = GNUNET_MQ_msg_extra (ppm, | 1400 | ppm = (struct PeerPutMessage *) buf; |
1390 | msize, | 1401 | ppm->header.type = htons (GNUNET_MESSAGE_TYPE_DHT_P2P_PUT); |
1391 | GNUNET_MESSAGE_TYPE_DHT_P2P_PUT); | 1402 | ppm->header.size = htons (sizeof (buf)); |
1392 | ppm->options = htonl (options); | ||
1393 | ppm->type = htonl (bd->type); | 1403 | ppm->type = htonl (bd->type); |
1394 | ppm->hop_count = htonl (hop_count + 1); | 1404 | ppm->options = htons (options); |
1395 | ppm->desired_replication_level = htonl (desired_replication_level); | 1405 | ppm->hop_count = htons (hop_count + 1); |
1396 | ppm->put_path_length = htonl (put_path_length); | 1406 | ppm->desired_replication_level = htons (desired_replication_level); |
1407 | ppm->put_path_length = htons (put_path_length); | ||
1397 | ppm->expiration_time = GNUNET_TIME_absolute_hton (bd->expiration_time); | 1408 | ppm->expiration_time = GNUNET_TIME_absolute_hton (bd->expiration_time); |
1398 | GNUNET_break (GNUNET_YES == | 1409 | GNUNET_break (GNUNET_YES == |
1399 | GNUNET_CONTAINER_bloomfilter_test (bf, | 1410 | GNUNET_CONTAINER_bloomfilter_test (bf, |
@@ -1412,20 +1423,23 @@ GDS_NEIGHBOURS_handle_put (const struct GDS_DATACACHE_BlockData *bd, | |||
1412 | { | 1423 | { |
1413 | /* Note that the signature in 'put_path' was not initialized before, | 1424 | /* Note that the signature in 'put_path' was not initialized before, |
1414 | so this is crucial to avoid sending garbage. */ | 1425 | so this is crucial to avoid sending garbage. */ |
1415 | sign_path (&bd->key, | 1426 | sign_path (bd->data, |
1416 | bd->data, | ||
1417 | bd->data_size, | 1427 | bd->data_size, |
1418 | bd->expiration_time, | 1428 | bd->expiration_time, |
1419 | &pp[put_path_length - 1].pred, | 1429 | &pp[put_path_length - 1].pred, |
1420 | target->id, | 1430 | &target->id, |
1421 | &pp[put_path_length - 1].sig); | 1431 | &pp[put_path_length - 1].sig); |
1432 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1433 | "Signing PUT PATH %u => %s\n", | ||
1434 | put_path_length, | ||
1435 | GNUNET_B2S (&pp[put_path_length - 1].sig)); | ||
1422 | } | 1436 | } |
1423 | 1437 | ||
1424 | GNUNET_memcpy (&pp[put_path_length], | 1438 | GNUNET_memcpy (&pp[put_path_length], |
1425 | bd->data, | 1439 | bd->data, |
1426 | bd->data_size); | 1440 | bd->data_size); |
1427 | GNUNET_MQ_send (target->mq, | 1441 | do_send (target, |
1428 | env); | 1442 | &ppm->header); |
1429 | } | 1443 | } |
1430 | GNUNET_free (targets); | 1444 | GNUNET_free (targets); |
1431 | GNUNET_STATISTICS_update (GDS_stats, | 1445 | GNUNET_STATISTICS_update (GDS_stats, |
@@ -1439,8 +1453,8 @@ GDS_NEIGHBOURS_handle_put (const struct GDS_DATACACHE_BlockData *bd, | |||
1439 | enum GNUNET_GenericReturnValue | 1453 | enum GNUNET_GenericReturnValue |
1440 | GDS_NEIGHBOURS_handle_get (enum GNUNET_BLOCK_Type type, | 1454 | GDS_NEIGHBOURS_handle_get (enum GNUNET_BLOCK_Type type, |
1441 | enum GNUNET_DHT_RouteOption options, | 1455 | enum GNUNET_DHT_RouteOption options, |
1442 | uint32_t desired_replication_level, | 1456 | uint16_t desired_replication_level, |
1443 | uint32_t hop_count, | 1457 | uint16_t hop_count, |
1444 | const struct GNUNET_HashCode *key, | 1458 | const struct GNUNET_HashCode *key, |
1445 | const void *xquery, | 1459 | const void *xquery, |
1446 | size_t xquery_size, | 1460 | size_t xquery_size, |
@@ -1466,18 +1480,21 @@ GDS_NEIGHBOURS_handle_get (enum GNUNET_BLOCK_Type type, | |||
1466 | desired_replication_level, | 1480 | desired_replication_level, |
1467 | &targets); | 1481 | &targets); |
1468 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1482 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1469 | "Adding myself (%s) to GET bloomfilter for %s\n", | 1483 | "Adding myself (%s) to GET bloomfilter for %s with RO(%s/%s)\n", |
1470 | GNUNET_i2s (&my_identity), | 1484 | GNUNET_i2s (&GDS_my_identity), |
1471 | GNUNET_h2s (key)); | 1485 | GNUNET_h2s (key), |
1486 | (options & GNUNET_DHT_RO_DEMULTIPLEX_EVERYWHERE) ? "x" : "-", | ||
1487 | (options & GNUNET_DHT_RO_RECORD_ROUTE) ? "R" : "-"); | ||
1488 | |||
1472 | GNUNET_CONTAINER_bloomfilter_add (peer_bf, | 1489 | GNUNET_CONTAINER_bloomfilter_add (peer_bf, |
1473 | &my_identity_hash); | 1490 | &GDS_my_identity_hash); |
1474 | if (0 == target_count) | 1491 | if (0 == target_count) |
1475 | { | 1492 | { |
1476 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1493 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1477 | "Routing GET for %s terminates after %u hops at %s\n", | 1494 | "Routing GET for %s terminates after %u hops at %s\n", |
1478 | GNUNET_h2s (key), | 1495 | GNUNET_h2s (key), |
1479 | (unsigned int) hop_count, | 1496 | (unsigned int) hop_count, |
1480 | GNUNET_i2s (&my_identity)); | 1497 | GNUNET_i2s (&GDS_my_identity)); |
1481 | return GNUNET_NO; | 1498 | return GNUNET_NO; |
1482 | } | 1499 | } |
1483 | if (GNUNET_OK != | 1500 | if (GNUNET_OK != |
@@ -1504,32 +1521,22 @@ GDS_NEIGHBOURS_handle_get (enum GNUNET_BLOCK_Type type, | |||
1504 | for (unsigned int i = 0; i < target_count; i++) | 1521 | for (unsigned int i = 0; i < target_count; i++) |
1505 | { | 1522 | { |
1506 | struct PeerInfo *target = targets[i]; | 1523 | struct PeerInfo *target = targets[i]; |
1507 | struct GNUNET_MQ_Envelope *env; | ||
1508 | struct PeerGetMessage *pgm; | 1524 | struct PeerGetMessage *pgm; |
1525 | char buf[sizeof (*pgm) + msize] GNUNET_ALIGN; | ||
1509 | char *xq; | 1526 | char *xq; |
1510 | 1527 | ||
1511 | if (GNUNET_MQ_get_length (target->mq) >= MAXIMUM_PENDING_PER_PEER) | ||
1512 | { | ||
1513 | /* skip */ | ||
1514 | GNUNET_STATISTICS_update (GDS_stats, | ||
1515 | "# P2P messages dropped due to full queue", | ||
1516 | 1, | ||
1517 | GNUNET_NO); | ||
1518 | skip_count++; | ||
1519 | continue; | ||
1520 | } | ||
1521 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1528 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1522 | "Routing GET for %s after %u hops to %s\n", | 1529 | "Routing GET for %s after %u hops to %s\n", |
1523 | GNUNET_h2s (key), | 1530 | GNUNET_h2s (key), |
1524 | (unsigned int) hop_count, | 1531 | (unsigned int) hop_count, |
1525 | GNUNET_i2s (target->id)); | 1532 | GNUNET_i2s (&target->id)); |
1526 | env = GNUNET_MQ_msg_extra (pgm, | 1533 | pgm = (struct PeerGetMessage *) buf; |
1527 | msize, | 1534 | pgm->header.type = htons (GNUNET_MESSAGE_TYPE_DHT_P2P_GET); |
1528 | GNUNET_MESSAGE_TYPE_DHT_P2P_GET); | 1535 | pgm->header.size = htons (sizeof (buf)); |
1529 | pgm->options = htonl (options); | ||
1530 | pgm->type = htonl (type); | 1536 | pgm->type = htonl (type); |
1531 | pgm->hop_count = htonl (hop_count + 1); | 1537 | pgm->options = htons (options); |
1532 | pgm->desired_replication_level = htonl (desired_replication_level); | 1538 | pgm->hop_count = htons (hop_count + 1); |
1539 | pgm->desired_replication_level = htons (desired_replication_level); | ||
1533 | pgm->xquery_size = htonl (xquery_size); | 1540 | pgm->xquery_size = htonl (xquery_size); |
1534 | pgm->bf_mutator = bf_nonce; | 1541 | pgm->bf_mutator = bf_nonce; |
1535 | GNUNET_break (GNUNET_YES == | 1542 | GNUNET_break (GNUNET_YES == |
@@ -1547,8 +1554,8 @@ GDS_NEIGHBOURS_handle_get (enum GNUNET_BLOCK_Type type, | |||
1547 | GNUNET_memcpy (&xq[xquery_size], | 1554 | GNUNET_memcpy (&xq[xquery_size], |
1548 | reply_bf, | 1555 | reply_bf, |
1549 | reply_bf_size); | 1556 | reply_bf_size); |
1550 | GNUNET_MQ_send (target->mq, | 1557 | do_send (target, |
1551 | env); | 1558 | &pgm->header); |
1552 | } | 1559 | } |
1553 | GNUNET_STATISTICS_update (GDS_stats, | 1560 | GNUNET_STATISTICS_update (GDS_stats, |
1554 | "# GET messages queued for transmission", | 1561 | "# GET messages queued for transmission", |
@@ -1568,34 +1575,30 @@ GDS_NEIGHBOURS_lookup_peer (const struct GNUNET_PeerIdentity *target) | |||
1568 | } | 1575 | } |
1569 | 1576 | ||
1570 | 1577 | ||
1571 | void | 1578 | bool |
1572 | GDS_NEIGHBOURS_handle_reply (struct PeerInfo *pi, | 1579 | GDS_NEIGHBOURS_handle_reply (struct PeerInfo *pi, |
1573 | const struct GDS_DATACACHE_BlockData *bd, | 1580 | const struct GDS_DATACACHE_BlockData *bd, |
1574 | const struct GNUNET_HashCode *query_hash, | 1581 | const struct GNUNET_HashCode *query_hash, |
1575 | unsigned int get_path_length, | 1582 | unsigned int get_path_length, |
1576 | const struct GNUNET_DHT_PathElement *get_path) | 1583 | const struct GNUNET_DHT_PathElement *get_path) |
1577 | { | 1584 | { |
1578 | struct GNUNET_MQ_Envelope *env; | ||
1579 | struct PeerResultMessage *prm; | ||
1580 | struct GNUNET_DHT_PathElement *paths; | 1585 | struct GNUNET_DHT_PathElement *paths; |
1581 | size_t msize; | 1586 | size_t msize; |
1582 | unsigned int ppl = bd->put_path_length; | 1587 | unsigned int ppl = bd->put_path_length; |
1583 | 1588 | ||
1584 | #if SANITY_CHECKS | 1589 | #if SANITY_CHECKS > 1 |
1585 | if (0 != | 1590 | if (0 != |
1586 | GNUNET_DHT_verify_path (&bd->key, | 1591 | GNUNET_DHT_verify_path (bd->data, |
1587 | bd->data, | ||
1588 | bd->data_size, | 1592 | bd->data_size, |
1589 | bd->expiration_time, | 1593 | bd->expiration_time, |
1590 | bd->put_path, | 1594 | bd->put_path, |
1591 | bd->put_path_length, | 1595 | bd->put_path_length, |
1592 | get_path, | 1596 | get_path, |
1593 | get_path_length, | 1597 | get_path_length, |
1594 | &my_identity)) | 1598 | &GDS_my_identity)) |
1595 | { | 1599 | { |
1596 | GNUNET_break_op (0); | 1600 | GNUNET_break_op (0); |
1597 | get_path_length = 0; | 1601 | return false; |
1598 | ppl = 0; | ||
1599 | } | 1602 | } |
1600 | #endif | 1603 | #endif |
1601 | msize = bd->data_size + (get_path_length + ppl) | 1604 | msize = bd->data_size + (get_path_length + ppl) |
@@ -1620,84 +1623,99 @@ GDS_NEIGHBOURS_handle_reply (struct PeerInfo *pi, | |||
1620 | (bd->data_size > GNUNET_MAX_MESSAGE_SIZE)) | 1623 | (bd->data_size > GNUNET_MAX_MESSAGE_SIZE)) |
1621 | { | 1624 | { |
1622 | GNUNET_break (0); | 1625 | GNUNET_break (0); |
1623 | return; | 1626 | return false; |
1624 | } | ||
1625 | if (GNUNET_MQ_get_length (pi->mq) >= MAXIMUM_PENDING_PER_PEER) | ||
1626 | { | ||
1627 | /* skip */ | ||
1628 | GNUNET_STATISTICS_update (GDS_stats, | ||
1629 | "# P2P messages dropped due to full queue", | ||
1630 | 1, | ||
1631 | GNUNET_NO); | ||
1632 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1633 | "Peer queue full, ignoring reply for key %s\n", | ||
1634 | GNUNET_h2s (&bd->key)); | ||
1635 | return; | ||
1636 | } | 1627 | } |
1637 | |||
1638 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1628 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1639 | "Forwarding reply for key %s to peer %s\n", | 1629 | "Forwarding reply for key %s to peer %s\n", |
1640 | GNUNET_h2s (query_hash), | 1630 | GNUNET_h2s (query_hash), |
1641 | GNUNET_i2s (pi->id)); | 1631 | GNUNET_i2s (&pi->id)); |
1642 | GNUNET_STATISTICS_update (GDS_stats, | 1632 | GNUNET_STATISTICS_update (GDS_stats, |
1643 | "# RESULT messages queued for transmission", | 1633 | "# RESULT messages queued for transmission", |
1644 | 1, | 1634 | 1, |
1645 | GNUNET_NO); | 1635 | GNUNET_NO); |
1646 | env = GNUNET_MQ_msg_extra (prm, | ||
1647 | msize, | ||
1648 | GNUNET_MESSAGE_TYPE_DHT_P2P_RESULT); | ||
1649 | prm->type = htonl (bd->type); | ||
1650 | prm->put_path_length = htonl (ppl); | ||
1651 | prm->get_path_length = htonl (get_path_length); | ||
1652 | prm->expiration_time = GNUNET_TIME_absolute_hton (bd->expiration_time); | ||
1653 | prm->key = *query_hash; | ||
1654 | paths = (struct GNUNET_DHT_PathElement *) &prm[1]; | ||
1655 | GNUNET_memcpy (paths, | ||
1656 | bd->put_path, | ||
1657 | ppl * sizeof(struct GNUNET_DHT_PathElement)); | ||
1658 | GNUNET_memcpy (&paths[ppl], | ||
1659 | get_path, | ||
1660 | get_path_length * sizeof(struct GNUNET_DHT_PathElement)); | ||
1661 | /* 0 == get_path_length means path is not being tracked */ | ||
1662 | if (0 != get_path_length) | ||
1663 | { | 1636 | { |
1664 | /* Note that the signature in 'get_path' was not initialized before, | 1637 | struct PeerResultMessage *prm; |
1665 | so this is crucial to avoid sending garbage. */ | 1638 | char buf[sizeof (*prm) + msize] GNUNET_ALIGN; |
1666 | sign_path (&bd->key, | 1639 | |
1667 | bd->data, | 1640 | prm = (struct PeerResultMessage *) buf; |
1668 | bd->data_size, | 1641 | prm->header.type = htons (GNUNET_MESSAGE_TYPE_DHT_P2P_RESULT); |
1669 | bd->expiration_time, | 1642 | prm->header.size = htons (sizeof (buf)); |
1670 | &paths[ppl + get_path_length - 1].pred, | 1643 | prm->type = htonl (bd->type); |
1671 | pi->id, | 1644 | prm->reserved = htonl (0); |
1672 | &paths[ppl + get_path_length - 1].sig); | 1645 | prm->put_path_length = htons (ppl); |
1673 | } | 1646 | prm->get_path_length = htons (get_path_length); |
1674 | GNUNET_memcpy (&paths[ppl + get_path_length], | 1647 | prm->expiration_time = GNUNET_TIME_absolute_hton (bd->expiration_time); |
1675 | bd->data, | 1648 | prm->key = *query_hash; |
1676 | bd->data_size); | 1649 | paths = (struct GNUNET_DHT_PathElement *) &prm[1]; |
1677 | GNUNET_MQ_send (pi->mq, | 1650 | if (NULL != bd->put_path) |
1678 | env); | 1651 | { |
1679 | } | 1652 | GNUNET_memcpy (paths, |
1653 | bd->put_path, | ||
1654 | ppl * sizeof(struct GNUNET_DHT_PathElement)); | ||
1655 | } | ||
1656 | else | ||
1657 | { | ||
1658 | GNUNET_assert (0 == ppl); | ||
1659 | } | ||
1660 | if (NULL != get_path) | ||
1661 | { | ||
1662 | GNUNET_memcpy (&paths[ppl], | ||
1663 | get_path, | ||
1664 | get_path_length * sizeof(struct GNUNET_DHT_PathElement)); | ||
1665 | } | ||
1666 | else | ||
1667 | { | ||
1668 | GNUNET_assert (0 == get_path_length); | ||
1669 | } | ||
1670 | /* 0 == get_path_length+ppl means path is not being tracked */ | ||
1671 | if (0 != (get_path_length + ppl)) | ||
1672 | { | ||
1673 | /* Note that the last signature in 'paths' was not initialized before, | ||
1674 | so this is crucial to avoid sending garbage. */ | ||
1675 | sign_path (bd->data, | ||
1676 | bd->data_size, | ||
1677 | bd->expiration_time, | ||
1678 | &paths[ppl + get_path_length - 1].pred, | ||
1679 | &pi->id, | ||
1680 | &paths[ppl + get_path_length - 1].sig); | ||
1681 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1682 | "Signing GET PATH %u/%u of %s => %s\n", | ||
1683 | ppl, | ||
1684 | get_path_length, | ||
1685 | GNUNET_h2s (query_hash), | ||
1686 | GNUNET_B2S (&paths[ppl + get_path_length - 1].sig)); | ||
1687 | } | ||
1688 | GNUNET_memcpy (&paths[ppl + get_path_length], | ||
1689 | bd->data, | ||
1690 | bd->data_size); | ||
1680 | 1691 | ||
1692 | #if SANITY_CHECKS > 1 | ||
1693 | { | ||
1694 | struct GNUNET_DHT_PathElement xpaths[get_path_length + 1]; | ||
1681 | 1695 | ||
1682 | /** | 1696 | memcpy (xpaths, |
1683 | * To be called on core init. | 1697 | &paths[ppl], |
1684 | * | 1698 | get_path_length * sizeof (struct GNUNET_DHT_PathElement)); |
1685 | * @param cls service closure | 1699 | xpaths[get_path_length].pred = GDS_my_identity; |
1686 | * @param identity the public identity of this peer | 1700 | if (0 != |
1687 | */ | 1701 | GNUNET_DHT_verify_path (bd->data, |
1688 | static void | 1702 | bd->data_size, |
1689 | core_init (void *cls, | 1703 | bd->expiration_time, |
1690 | const struct GNUNET_PeerIdentity *identity) | 1704 | paths, |
1691 | { | 1705 | ppl, |
1692 | (void) cls; | 1706 | xpaths, |
1693 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, | 1707 | get_path_length + 1, |
1694 | "CORE called, I am %s\n", | 1708 | &pi->id)) |
1695 | GNUNET_i2s (identity)); | 1709 | { |
1696 | my_identity = *identity; | 1710 | GNUNET_break (0); |
1697 | GNUNET_CRYPTO_hash (identity, | 1711 | return false; |
1698 | sizeof(struct GNUNET_PeerIdentity), | 1712 | } |
1699 | &my_identity_hash); | 1713 | } |
1700 | GNUNET_SERVICE_resume (GDS_service); | 1714 | #endif |
1715 | do_send (pi, | ||
1716 | &prm->header); | ||
1717 | } | ||
1718 | return true; | ||
1701 | } | 1719 | } |
1702 | 1720 | ||
1703 | 1721 | ||
@@ -1713,7 +1731,7 @@ check_dht_p2p_put (void *cls, | |||
1713 | const struct PeerPutMessage *put) | 1731 | const struct PeerPutMessage *put) |
1714 | { | 1732 | { |
1715 | uint16_t msize = ntohs (put->header.size); | 1733 | uint16_t msize = ntohs (put->header.size); |
1716 | uint32_t putlen = ntohl (put->put_path_length); | 1734 | uint16_t putlen = ntohs (put->put_path_length); |
1717 | 1735 | ||
1718 | (void) cls; | 1736 | (void) cls; |
1719 | if ( (msize < | 1737 | if ( (msize < |
@@ -1732,34 +1750,37 @@ check_dht_p2p_put (void *cls, | |||
1732 | /** | 1750 | /** |
1733 | * Core handler for p2p put requests. | 1751 | * Core handler for p2p put requests. |
1734 | * | 1752 | * |
1735 | * @param cls closure with the `struct PeerInfo` of the sender | 1753 | * @param cls closure with the `struct Target` of the sender |
1736 | * @param message message | 1754 | * @param message message |
1737 | */ | 1755 | */ |
1738 | static void | 1756 | static void |
1739 | handle_dht_p2p_put (void *cls, | 1757 | handle_dht_p2p_put (void *cls, |
1740 | const struct PeerPutMessage *put) | 1758 | const struct PeerPutMessage *put) |
1741 | { | 1759 | { |
1742 | struct PeerInfo *peer = cls; | 1760 | struct Target *t = cls; |
1761 | struct PeerInfo *peer = t->pi; | ||
1743 | uint16_t msize = ntohs (put->header.size); | 1762 | uint16_t msize = ntohs (put->header.size); |
1744 | enum GNUNET_DHT_RouteOption options | 1763 | enum GNUNET_DHT_RouteOption options |
1745 | = (enum GNUNET_DHT_RouteOption) ntohl (put->options); | 1764 | = (enum GNUNET_DHT_RouteOption) ntohs (put->options); |
1765 | const struct GNUNET_DHT_PathElement *put_path | ||
1766 | = (const struct GNUNET_DHT_PathElement *) &put[1]; | ||
1767 | uint16_t putlen | ||
1768 | = ntohs (put->put_path_length); | ||
1746 | struct GDS_DATACACHE_BlockData bd = { | 1769 | struct GDS_DATACACHE_BlockData bd = { |
1747 | .key = put->key, | 1770 | .key = put->key, |
1748 | .expiration_time = GNUNET_TIME_absolute_ntoh (put->expiration_time), | 1771 | .expiration_time = GNUNET_TIME_absolute_ntoh (put->expiration_time), |
1749 | .type = ntohl (put->type) | 1772 | .type = ntohl (put->type), |
1773 | .data_size = msize - (sizeof(*put) | ||
1774 | + putlen * sizeof(struct GNUNET_DHT_PathElement)), | ||
1775 | .data = &put_path[putlen] | ||
1750 | }; | 1776 | }; |
1751 | const struct GNUNET_DHT_PathElement *put_path | ||
1752 | = (const struct GNUNET_DHT_PathElement *) &put[1]; | ||
1753 | uint32_t putlen | ||
1754 | = ntohl (put->put_path_length); | ||
1755 | 1777 | ||
1756 | bd.data_size = msize - (sizeof(*put) | ||
1757 | + putlen * sizeof(struct GNUNET_DHT_PathElement)); | ||
1758 | bd.data = &put_path[putlen]; | ||
1759 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1778 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1760 | "PUT for `%s' from %s\n", | 1779 | "PUT for `%s' from %s with RO (%s/%s)\n", |
1761 | GNUNET_h2s (&put->key), | 1780 | GNUNET_h2s (&put->key), |
1762 | GNUNET_i2s (peer->id)); | 1781 | GNUNET_i2s (&peer->id), |
1782 | (options & GNUNET_DHT_RO_DEMULTIPLEX_EVERYWHERE) ? "x" : "-", | ||
1783 | (options & GNUNET_DHT_RO_RECORD_ROUTE) ? "R" : "-"); | ||
1763 | if (GNUNET_TIME_absolute_is_past (bd.expiration_time)) | 1784 | if (GNUNET_TIME_absolute_is_past (bd.expiration_time)) |
1764 | { | 1785 | { |
1765 | GNUNET_STATISTICS_update (GDS_stats, | 1786 | GNUNET_STATISTICS_update (GDS_stats, |
@@ -1768,6 +1789,17 @@ handle_dht_p2p_put (void *cls, | |||
1768 | GNUNET_NO); | 1789 | GNUNET_NO); |
1769 | return; | 1790 | return; |
1770 | } | 1791 | } |
1792 | if (GNUNET_NO == | ||
1793 | GNUNET_BLOCK_check_block (GDS_block_context, | ||
1794 | bd.type, | ||
1795 | bd.data, | ||
1796 | bd.data_size)) | ||
1797 | { | ||
1798 | GNUNET_break_op (0); | ||
1799 | return; | ||
1800 | } | ||
1801 | if (0 == (options & GNUNET_DHT_RO_RECORD_ROUTE)) | ||
1802 | putlen = 0; | ||
1771 | GNUNET_STATISTICS_update (GDS_stats, | 1803 | GNUNET_STATISTICS_update (GDS_stats, |
1772 | "# P2P PUT requests received", | 1804 | "# P2P PUT requests received", |
1773 | 1, | 1805 | 1, |
@@ -1796,25 +1828,14 @@ handle_dht_p2p_put (void *cls, | |||
1796 | } | 1828 | } |
1797 | break; | 1829 | break; |
1798 | case GNUNET_NO: | 1830 | case GNUNET_NO: |
1799 | GNUNET_break_op (0); | ||
1800 | return; | ||
1801 | case GNUNET_SYSERR: | ||
1802 | /* cannot verify, good luck */ | 1831 | /* cannot verify, good luck */ |
1803 | break; | 1832 | break; |
1833 | case GNUNET_SYSERR: | ||
1834 | /* block type not supported, good luck */ | ||
1835 | break; | ||
1804 | } | 1836 | } |
1805 | } | 1837 | } |
1806 | 1838 | ||
1807 | if (GNUNET_NO == | ||
1808 | GNUNET_BLOCK_check_block (GDS_block_context, | ||
1809 | bd.type, | ||
1810 | &bd.key, | ||
1811 | bd.data, | ||
1812 | bd.data_size)) | ||
1813 | { | ||
1814 | GNUNET_break_op (0); | ||
1815 | return; | ||
1816 | } | ||
1817 | |||
1818 | { | 1839 | { |
1819 | struct GNUNET_CONTAINER_BloomFilter *bf; | 1840 | struct GNUNET_CONTAINER_BloomFilter *bf; |
1820 | struct GNUNET_DHT_PathElement pp[putlen + 1]; | 1841 | struct GNUNET_DHT_PathElement pp[putlen + 1]; |
@@ -1830,42 +1851,39 @@ handle_dht_p2p_put (void *cls, | |||
1830 | bd.put_path_length = putlen + 1; | 1851 | bd.put_path_length = putlen + 1; |
1831 | if (0 != (options & GNUNET_DHT_RO_RECORD_ROUTE)) | 1852 | if (0 != (options & GNUNET_DHT_RO_RECORD_ROUTE)) |
1832 | { | 1853 | { |
1833 | #if SANITY_CHECKS | 1854 | unsigned int failure_offset; |
1834 | for (unsigned int i = 0; i <= putlen; i++) | 1855 | |
1835 | { | ||
1836 | for (unsigned int j = 0; j < i; j++) | ||
1837 | { | ||
1838 | GNUNET_break (0 != | ||
1839 | GNUNET_memcmp (&pp[i].pred, | ||
1840 | &pp[j].pred)); | ||
1841 | } | ||
1842 | GNUNET_break (0 != | ||
1843 | GNUNET_memcmp (&pp[i].pred, | ||
1844 | peer->id)); | ||
1845 | } | ||
1846 | if (0 != | ||
1847 | GNUNET_DHT_verify_path (&bd.key, | ||
1848 | bd.data, | ||
1849 | bd.data_size, | ||
1850 | bd.expiration_time, | ||
1851 | bd.put_path, | ||
1852 | putlen, | ||
1853 | NULL, 0, /* get_path */ | ||
1854 | &my_identity)) | ||
1855 | { | ||
1856 | GNUNET_break_op (0); | ||
1857 | putlen = 0; | ||
1858 | } | ||
1859 | #endif | ||
1860 | GNUNET_memcpy (pp, | 1856 | GNUNET_memcpy (pp, |
1861 | put_path, | 1857 | put_path, |
1862 | putlen * sizeof(struct GNUNET_DHT_PathElement)); | 1858 | putlen * sizeof(struct GNUNET_DHT_PathElement)); |
1863 | pp[putlen].pred = *peer->id; | 1859 | pp[putlen].pred = peer->id; |
1864 | /* zero-out signature, not valid until we actually do forward! */ | 1860 | /* zero-out signature, not valid until we actually do forward! */ |
1865 | memset (&pp[putlen].sig, | 1861 | memset (&pp[putlen].sig, |
1866 | 0, | 1862 | 0, |
1867 | sizeof (pp[putlen].sig)); | 1863 | sizeof (pp[putlen].sig)); |
1868 | putlen++; | 1864 | #if SANITY_CHECKS |
1865 | /* TODO: might want to eventually implement probabilistic | ||
1866 | load-based path verification, but for now it is all or nothing */ | ||
1867 | failure_offset | ||
1868 | = GNUNET_DHT_verify_path (bd.data, | ||
1869 | bd.data_size, | ||
1870 | bd.expiration_time, | ||
1871 | pp, | ||
1872 | putlen + 1, | ||
1873 | NULL, 0, /* get_path */ | ||
1874 | &GDS_my_identity); | ||
1875 | #else | ||
1876 | failure_offset = 0; | ||
1877 | #endif | ||
1878 | if (0 != failure_offset) | ||
1879 | { | ||
1880 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | ||
1881 | "Recorded put path invalid at offset %u, truncating\n", | ||
1882 | failure_offset); | ||
1883 | GNUNET_assert (failure_offset <= putlen); | ||
1884 | bd.put_path = &pp[failure_offset]; | ||
1885 | bd.put_path_length = putlen - failure_offset; | ||
1886 | } | ||
1869 | } | 1887 | } |
1870 | else | 1888 | else |
1871 | { | 1889 | { |
@@ -1873,9 +1891,9 @@ handle_dht_p2p_put (void *cls, | |||
1873 | } | 1891 | } |
1874 | 1892 | ||
1875 | /* give to local clients */ | 1893 | /* give to local clients */ |
1876 | GDS_CLIENTS_handle_reply (&bd, | 1894 | GNUNET_break (GDS_CLIENTS_handle_reply (&bd, |
1877 | &bd.key, | 1895 | &bd.key, |
1878 | 0, NULL /* get path */); | 1896 | 0, NULL /* get path */)); |
1879 | 1897 | ||
1880 | /* store locally */ | 1898 | /* store locally */ |
1881 | if ( (0 != (options & GNUNET_DHT_RO_DEMULTIPLEX_EVERYWHERE)) || | 1899 | if ( (0 != (options & GNUNET_DHT_RO_DEMULTIPLEX_EVERYWHERE)) || |
@@ -1889,8 +1907,8 @@ handle_dht_p2p_put (void *cls, | |||
1889 | forwarded | 1907 | forwarded |
1890 | = GDS_NEIGHBOURS_handle_put (&bd, | 1908 | = GDS_NEIGHBOURS_handle_put (&bd, |
1891 | options, | 1909 | options, |
1892 | ntohl (put->desired_replication_level), | 1910 | ntohs (put->desired_replication_level), |
1893 | ntohl (put->hop_count), | 1911 | ntohs (put->hop_count), |
1894 | bf); | 1912 | bf); |
1895 | /* notify monitoring clients */ | 1913 | /* notify monitoring clients */ |
1896 | GDS_CLIENTS_process_put (options | 1914 | GDS_CLIENTS_process_put (options |
@@ -1898,8 +1916,8 @@ handle_dht_p2p_put (void *cls, | |||
1898 | ? GNUNET_DHT_RO_LAST_HOP | 1916 | ? GNUNET_DHT_RO_LAST_HOP |
1899 | : 0), | 1917 | : 0), |
1900 | &bd, | 1918 | &bd, |
1901 | ntohl (put->hop_count), | 1919 | ntohs (put->hop_count), |
1902 | ntohl (put->desired_replication_level)); | 1920 | ntohs (put->desired_replication_level)); |
1903 | } | 1921 | } |
1904 | GNUNET_CONTAINER_bloomfilter_free (bf); | 1922 | GNUNET_CONTAINER_bloomfilter_free (bf); |
1905 | } | 1923 | } |
@@ -1907,49 +1925,64 @@ handle_dht_p2p_put (void *cls, | |||
1907 | 1925 | ||
1908 | 1926 | ||
1909 | /** | 1927 | /** |
1910 | * We have received a FIND PEER request. Send matching | 1928 | * We have received a request for a HELLO. Sends our |
1911 | * HELLOs back. | 1929 | * HELLO back. |
1912 | * | 1930 | * |
1913 | * @param pi sender of the FIND PEER request | 1931 | * @param pi sender of the request |
1914 | * @param key peers close to this key are desired | 1932 | * @param key peers close to this key are desired |
1915 | * @param bg group for filtering peers | 1933 | * @param bg group for filtering peers |
1916 | */ | 1934 | */ |
1917 | static void | 1935 | static void |
1918 | handle_find_peer (struct PeerInfo *pi, | 1936 | handle_find_my_hello (struct PeerInfo *pi, |
1919 | const struct GNUNET_HashCode *query_hash, | 1937 | const struct GNUNET_HashCode *query_hash, |
1920 | struct GNUNET_BLOCK_Group *bg) | 1938 | struct GNUNET_BLOCK_Group *bg) |
1921 | { | 1939 | { |
1922 | int bucket_idx; | 1940 | size_t block_size = 0; |
1923 | struct PeerBucket *bucket; | 1941 | |
1924 | struct PeerInfo *peer; | 1942 | /* TODO: consider caching our HELLO block for a bit, to |
1925 | unsigned int choice; | 1943 | avoid signing too often here... */ |
1926 | struct GDS_DATACACHE_BlockData bd = { | 1944 | GNUNET_break (GNUNET_NO == |
1927 | .type = GNUNET_BLOCK_TYPE_DHT_HELLO | 1945 | GNUNET_HELLO_builder_to_block (GDS_my_hello, |
1928 | }; | 1946 | &GDS_my_private_key, |
1929 | 1947 | NULL, | |
1930 | /* first, check about our own HELLO */ | 1948 | &block_size)); |
1931 | if (NULL != GDS_my_hello) | ||
1932 | { | 1949 | { |
1933 | bd.expiration_time = GNUNET_TIME_relative_to_absolute ( | 1950 | char block[block_size]; |
1934 | hello_expiration), | 1951 | |
1935 | bd.key = my_identity_hash, | 1952 | if (GNUNET_OK != |
1936 | bd.data = GDS_my_hello; | 1953 | GNUNET_HELLO_builder_to_block (GDS_my_hello, |
1937 | bd.data_size = GNUNET_HELLO_size ( | 1954 | &GDS_my_private_key, |
1938 | (const struct GNUNET_HELLO_Message *) GDS_my_hello); | 1955 | block, |
1939 | GNUNET_break (bd.data_size >= sizeof(struct GNUNET_MessageHeader)); | 1956 | &block_size)) |
1940 | if (GNUNET_BLOCK_REPLY_OK_MORE == | ||
1941 | GNUNET_BLOCK_check_reply (GDS_block_context, | ||
1942 | GNUNET_BLOCK_TYPE_DHT_HELLO, | ||
1943 | bg, | ||
1944 | &my_identity_hash, | ||
1945 | NULL, 0, | ||
1946 | bd.data, | ||
1947 | bd.data_size)) | ||
1948 | { | 1957 | { |
1949 | GDS_NEIGHBOURS_handle_reply (pi, | 1958 | GNUNET_STATISTICS_update (GDS_stats, |
1950 | &bd, | 1959 | "# FIND PEER requests ignored due to lack of HELLO", |
1951 | query_hash, | 1960 | 1, |
1952 | 0, NULL /* get path */); | 1961 | GNUNET_NO); |
1962 | } | ||
1963 | else if (GNUNET_BLOCK_REPLY_OK_MORE == | ||
1964 | GNUNET_BLOCK_check_reply (GDS_block_context, | ||
1965 | GNUNET_BLOCK_TYPE_DHT_URL_HELLO, | ||
1966 | bg, | ||
1967 | &GDS_my_identity_hash, | ||
1968 | NULL, 0, | ||
1969 | block, | ||
1970 | block_size)) | ||
1971 | { | ||
1972 | struct GDS_DATACACHE_BlockData bd = { | ||
1973 | .type = GNUNET_BLOCK_TYPE_DHT_URL_HELLO, | ||
1974 | .expiration_time | ||
1975 | = GNUNET_TIME_relative_to_absolute ( | ||
1976 | GNUNET_HELLO_ADDRESS_EXPIRATION), | ||
1977 | .key = GDS_my_identity_hash, | ||
1978 | .data = block, | ||
1979 | .data_size = block_size | ||
1980 | }; | ||
1981 | |||
1982 | GNUNET_break (GDS_NEIGHBOURS_handle_reply (pi, | ||
1983 | &bd, | ||
1984 | query_hash, | ||
1985 | 0, NULL /* get path */)); | ||
1953 | } | 1986 | } |
1954 | else | 1987 | else |
1955 | { | 1988 | { |
@@ -1959,70 +1992,52 @@ handle_find_peer (struct PeerInfo *pi, | |||
1959 | GNUNET_NO); | 1992 | GNUNET_NO); |
1960 | } | 1993 | } |
1961 | } | 1994 | } |
1962 | else | 1995 | } |
1963 | { | ||
1964 | GNUNET_STATISTICS_update (GDS_stats, | ||
1965 | "# FIND PEER requests ignored due to lack of HELLO", | ||
1966 | 1, | ||
1967 | GNUNET_NO); | ||
1968 | } | ||
1969 | 1996 | ||
1970 | /* then, also consider sending a random HELLO from the closest bucket */ | ||
1971 | /* FIXME: How can this be true? Shouldnt we just do find_bucket() ? */ | ||
1972 | if (0 == | ||
1973 | GNUNET_memcmp (&my_identity_hash, | ||
1974 | query_hash)) | ||
1975 | bucket_idx = closest_bucket - 1; | ||
1976 | else | ||
1977 | bucket_idx = GNUNET_MIN ((int) closest_bucket - 1, | ||
1978 | find_bucket (query_hash)); | ||
1979 | if (bucket_idx < 0) | ||
1980 | return; | ||
1981 | bucket = &k_buckets[bucket_idx]; | ||
1982 | if (bucket->peers_size == 0) | ||
1983 | return; | ||
1984 | choice = GNUNET_CRYPTO_random_u32 (GNUNET_CRYPTO_QUALITY_WEAK, | ||
1985 | bucket->peers_size); | ||
1986 | peer = bucket->head; | ||
1987 | while (choice > 0) | ||
1988 | { | ||
1989 | GNUNET_assert (NULL != peer); | ||
1990 | peer = peer->next; | ||
1991 | choice--; | ||
1992 | } | ||
1993 | choice = bucket->peers_size; | ||
1994 | 1997 | ||
1995 | { | 1998 | /** |
1996 | const struct GNUNET_HELLO_Message *hello; | 1999 | * We have received a request for nearby HELLOs. Sends matching |
1997 | size_t hello_size; | 2000 | * HELLOs back. |
2001 | * | ||
2002 | * @param pi sender of the request | ||
2003 | * @param key peers close to this key are desired | ||
2004 | * @param bg group for filtering peers | ||
2005 | */ | ||
2006 | static void | ||
2007 | handle_find_local_hello (struct PeerInfo *pi, | ||
2008 | const struct GNUNET_HashCode *query_hash, | ||
2009 | struct GNUNET_BLOCK_Group *bg) | ||
2010 | { | ||
2011 | /* Force non-random selection by hop count */ | ||
2012 | struct PeerInfo *peer; | ||
1998 | 2013 | ||
1999 | do | 2014 | peer = select_peer (query_hash, |
2000 | { | 2015 | NULL, |
2001 | peer = peer->next; | 2016 | GDS_NSE_get () + 1); |
2002 | if (0 == choice--) | 2017 | if ( (NULL != peer->hello) && |
2003 | return; /* no non-masked peer available */ | 2018 | (! GNUNET_TIME_absolute_is_past (peer->hello_expiration)) && |
2004 | if (NULL == peer) | 2019 | (GNUNET_BLOCK_REPLY_OK_MORE == |
2005 | peer = bucket->head; | 2020 | GNUNET_BLOCK_check_reply ( |
2006 | hello = GDS_HELLO_get (peer->id); | 2021 | GDS_block_context, |
2007 | } while ( (NULL == hello) || | 2022 | GNUNET_BLOCK_TYPE_DHT_URL_HELLO, |
2008 | (GNUNET_BLOCK_REPLY_OK_MORE != | 2023 | bg, |
2009 | GNUNET_BLOCK_check_reply ( | 2024 | &peer->phash, |
2010 | GDS_block_context, | 2025 | NULL, 0, /* xquery */ |
2011 | GNUNET_BLOCK_TYPE_DHT_HELLO, | 2026 | peer->hello, |
2012 | bg, | 2027 | peer->hello_size)) ) |
2013 | &peer->phash, | 2028 | { |
2014 | NULL, 0, /* xquery */ | 2029 | struct GDS_DATACACHE_BlockData bd = { |
2015 | hello, | 2030 | .type = GNUNET_BLOCK_TYPE_DHT_URL_HELLO, |
2016 | (hello_size = GNUNET_HELLO_size (hello))))); | 2031 | .expiration_time = peer->hello_expiration, |
2017 | bd.expiration_time = GNUNET_TIME_relative_to_absolute ( | 2032 | .key = peer->phash, |
2018 | GNUNET_CONSTANTS_HELLO_ADDRESS_EXPIRATION); | 2033 | .data = peer->hello, |
2019 | bd.key = peer->phash; | 2034 | .data_size = peer->hello_size |
2020 | bd.data = hello; | 2035 | }; |
2021 | bd.data_size = hello_size; | 2036 | |
2022 | GDS_NEIGHBOURS_handle_reply (pi, | 2037 | GNUNET_break (GDS_NEIGHBOURS_handle_reply (pi, |
2023 | &bd, | 2038 | &bd, |
2024 | query_hash, | 2039 | query_hash, |
2025 | 0, NULL /* get path */); | 2040 | 0, NULL /* get path */)); |
2026 | } | 2041 | } |
2027 | } | 2042 | } |
2028 | 2043 | ||
@@ -2039,17 +2054,17 @@ handle_local_result (void *cls, | |||
2039 | { | 2054 | { |
2040 | struct PeerInfo *peer = cls; | 2055 | struct PeerInfo *peer = cls; |
2041 | 2056 | ||
2042 | GDS_NEIGHBOURS_handle_reply (peer, | 2057 | GNUNET_break (GDS_NEIGHBOURS_handle_reply (peer, |
2043 | bd, | 2058 | bd, |
2044 | &bd->key, | 2059 | &bd->key, |
2045 | 0, NULL /* get path */); | 2060 | 0, NULL /* get path */)); |
2046 | } | 2061 | } |
2047 | 2062 | ||
2048 | 2063 | ||
2049 | /** | 2064 | /** |
2050 | * Check validity of p2p get request. | 2065 | * Check validity of p2p get request. |
2051 | * | 2066 | * |
2052 | * @param cls closure with the `struct PeerInfo` of the sender | 2067 | * @param cls closure with the `struct Target` of the sender |
2053 | * @param get the message | 2068 | * @param get the message |
2054 | * @return #GNUNET_OK if the message is well-formed | 2069 | * @return #GNUNET_OK if the message is well-formed |
2055 | */ | 2070 | */ |
@@ -2073,20 +2088,21 @@ check_dht_p2p_get (void *cls, | |||
2073 | /** | 2088 | /** |
2074 | * Core handler for p2p get requests. | 2089 | * Core handler for p2p get requests. |
2075 | * | 2090 | * |
2076 | * @param cls closure with the `struct PeerInfo` of the sender | 2091 | * @param cls closure with the `struct Target` of the sender |
2077 | * @param get the message | 2092 | * @param get the message |
2078 | */ | 2093 | */ |
2079 | static void | 2094 | static void |
2080 | handle_dht_p2p_get (void *cls, | 2095 | handle_dht_p2p_get (void *cls, |
2081 | const struct PeerGetMessage *get) | 2096 | const struct PeerGetMessage *get) |
2082 | { | 2097 | { |
2083 | struct PeerInfo *peer = cls; | 2098 | struct Target *t = cls; |
2099 | struct PeerInfo *peer = t->pi; | ||
2084 | uint16_t msize = ntohs (get->header.size); | 2100 | uint16_t msize = ntohs (get->header.size); |
2085 | uint32_t xquery_size = ntohl (get->xquery_size); | 2101 | uint32_t xquery_size = ntohl (get->xquery_size); |
2086 | uint32_t hop_count = ntohl (get->hop_count); | 2102 | uint32_t hop_count = ntohs (get->hop_count); |
2087 | size_t reply_bf_size = msize - (sizeof(*get) + xquery_size); | 2103 | size_t reply_bf_size = msize - (sizeof(*get) + xquery_size); |
2088 | enum GNUNET_BLOCK_Type type = (enum GNUNET_BLOCK_Type) ntohl (get->type); | 2104 | enum GNUNET_BLOCK_Type type = (enum GNUNET_BLOCK_Type) ntohl (get->type); |
2089 | enum GNUNET_DHT_RouteOption options = (enum GNUNET_DHT_RouteOption) ntohl ( | 2105 | enum GNUNET_DHT_RouteOption options = (enum GNUNET_DHT_RouteOption) ntohs ( |
2090 | get->options); | 2106 | get->options); |
2091 | enum GNUNET_BLOCK_ReplyEvaluationResult eval = GNUNET_BLOCK_REPLY_OK_MORE; | 2107 | enum GNUNET_BLOCK_ReplyEvaluationResult eval = GNUNET_BLOCK_REPLY_OK_MORE; |
2092 | const void *xquery = (const void *) &get[1]; | 2108 | const void *xquery = (const void *) &get[1]; |
@@ -2133,32 +2149,45 @@ handle_dht_p2p_get (void *cls, | |||
2133 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 2149 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
2134 | "GET for %s at %s after %u hops\n", | 2150 | "GET for %s at %s after %u hops\n", |
2135 | GNUNET_h2s (&get->key), | 2151 | GNUNET_h2s (&get->key), |
2136 | GNUNET_i2s (&my_identity), | 2152 | GNUNET_i2s (&GDS_my_identity), |
2137 | (unsigned int) hop_count); | 2153 | (unsigned int) hop_count); |
2138 | /* local lookup (this may update the reply_bf) */ | 2154 | /* local lookup (this may update the bg) */ |
2139 | if ( (0 != (options & GNUNET_DHT_RO_DEMULTIPLEX_EVERYWHERE)) || | 2155 | if ( (0 != (options & GNUNET_DHT_RO_DEMULTIPLEX_EVERYWHERE)) || |
2140 | (GDS_am_closest_peer (&get->key, | 2156 | (GDS_am_closest_peer (&get->key, |
2141 | peer_bf)) ) | 2157 | peer_bf)) ) |
2142 | { | 2158 | { |
2143 | if ((0 != (options & GNUNET_DHT_RO_FIND_PEER))) | 2159 | if (GNUNET_BLOCK_TYPE_DHT_URL_HELLO == type) |
2144 | { | 2160 | { |
2145 | GNUNET_STATISTICS_update (GDS_stats, | 2161 | GNUNET_STATISTICS_update (GDS_stats, |
2146 | "# P2P FIND PEER requests processed", | 2162 | "# P2P HELLO lookup requests processed", |
2147 | 1, | 2163 | 1, |
2148 | GNUNET_NO); | 2164 | GNUNET_NO); |
2149 | handle_find_peer (peer, | 2165 | handle_find_my_hello (peer, |
2150 | &get->key, | 2166 | &get->key, |
2151 | bg); | 2167 | bg); |
2168 | if (0 != (options & GNUNET_DHT_RO_FIND_APPROXIMATE)) | ||
2169 | handle_find_local_hello (peer, | ||
2170 | &get->key, | ||
2171 | bg); | ||
2152 | } | 2172 | } |
2153 | else | 2173 | else |
2154 | { | 2174 | { |
2155 | eval = GDS_DATACACHE_handle_get (&get->key, | 2175 | if (0 != (options & GNUNET_DHT_RO_FIND_APPROXIMATE)) |
2156 | type, | 2176 | eval = GDS_DATACACHE_get_closest (&get->key, |
2157 | xquery, | 2177 | type, |
2158 | xquery_size, | 2178 | xquery, |
2159 | bg, | 2179 | xquery_size, |
2160 | &handle_local_result, | 2180 | bg, |
2161 | peer); | 2181 | &handle_local_result, |
2182 | peer); | ||
2183 | else | ||
2184 | eval = GDS_DATACACHE_handle_get (&get->key, | ||
2185 | type, | ||
2186 | xquery, | ||
2187 | xquery_size, | ||
2188 | bg, | ||
2189 | &handle_local_result, | ||
2190 | peer); | ||
2162 | } | 2191 | } |
2163 | } | 2192 | } |
2164 | else | 2193 | else |
@@ -2169,8 +2198,10 @@ handle_dht_p2p_get (void *cls, | |||
2169 | GNUNET_NO); | 2198 | GNUNET_NO); |
2170 | } | 2199 | } |
2171 | 2200 | ||
2172 | /* remember request for routing replies */ | 2201 | /* remember request for routing replies |
2173 | GDS_ROUTING_add (peer->id, | 2202 | TODO: why should we do this if GNUNET_BLOCK_REPLY_OK_LAST == eval? |
2203 | */ | ||
2204 | GDS_ROUTING_add (&peer->id, | ||
2174 | type, | 2205 | type, |
2175 | bg, /* bg now owned by routing, but valid at least until end of this function! */ | 2206 | bg, /* bg now owned by routing, but valid at least until end of this function! */ |
2176 | options, | 2207 | options, |
@@ -2181,7 +2212,7 @@ handle_dht_p2p_get (void *cls, | |||
2181 | /* P2P forwarding */ | 2212 | /* P2P forwarding */ |
2182 | { | 2213 | { |
2183 | bool forwarded = false; | 2214 | bool forwarded = false; |
2184 | uint32_t desired_replication_level = ntohl ( | 2215 | uint16_t desired_replication_level = ntohs ( |
2185 | get->desired_replication_level); | 2216 | get->desired_replication_level); |
2186 | 2217 | ||
2187 | if (eval != GNUNET_BLOCK_REPLY_OK_LAST) | 2218 | if (eval != GNUNET_BLOCK_REPLY_OK_LAST) |
@@ -2220,18 +2251,25 @@ handle_dht_p2p_get (void *cls, | |||
2220 | * @param query_hash hash of the original query, might not match key in @a bd | 2251 | * @param query_hash hash of the original query, might not match key in @a bd |
2221 | * @param get_path_length number of entries in @a get_path | 2252 | * @param get_path_length number of entries in @a get_path |
2222 | * @param get_path path the reply has taken | 2253 | * @param get_path path the reply has taken |
2254 | * @return true on success | ||
2223 | */ | 2255 | */ |
2224 | static void | 2256 | static bool |
2225 | process_reply_with_path (const struct GDS_DATACACHE_BlockData *bd, | 2257 | process_reply_with_path (const struct GDS_DATACACHE_BlockData *bd, |
2226 | const struct GNUNET_HashCode *query_hash, | 2258 | const struct GNUNET_HashCode *query_hash, |
2227 | unsigned int get_path_length, | 2259 | unsigned int get_path_length, |
2228 | const struct GNUNET_DHT_PathElement *get_path) | 2260 | const struct GNUNET_DHT_PathElement *get_path) |
2229 | { | 2261 | { |
2230 | /* forward to local clients */ | 2262 | /* forward to local clients */ |
2231 | GDS_CLIENTS_handle_reply (bd, | 2263 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
2232 | query_hash, | 2264 | "Forwarding reply to local clients\n"); |
2233 | get_path_length, | 2265 | if (! GDS_CLIENTS_handle_reply (bd, |
2234 | get_path); | 2266 | query_hash, |
2267 | get_path_length, | ||
2268 | get_path)) | ||
2269 | { | ||
2270 | GNUNET_break (0); | ||
2271 | return false; | ||
2272 | } | ||
2235 | GDS_CLIENTS_process_get_resp (bd, | 2273 | GDS_CLIENTS_process_get_resp (bd, |
2236 | get_path, | 2274 | get_path, |
2237 | get_path_length); | 2275 | get_path_length); |
@@ -2256,6 +2294,7 @@ process_reply_with_path (const struct GDS_DATACACHE_BlockData *bd, | |||
2256 | query_hash, | 2294 | query_hash, |
2257 | get_path_length, | 2295 | get_path_length, |
2258 | get_path); | 2296 | get_path); |
2297 | return true; | ||
2259 | } | 2298 | } |
2260 | 2299 | ||
2261 | 2300 | ||
@@ -2270,8 +2309,8 @@ static enum GNUNET_GenericReturnValue | |||
2270 | check_dht_p2p_result (void *cls, | 2309 | check_dht_p2p_result (void *cls, |
2271 | const struct PeerResultMessage *prm) | 2310 | const struct PeerResultMessage *prm) |
2272 | { | 2311 | { |
2273 | uint32_t get_path_length = ntohl (prm->get_path_length); | 2312 | uint16_t get_path_length = ntohs (prm->get_path_length); |
2274 | uint32_t put_path_length = ntohl (prm->put_path_length); | 2313 | uint16_t put_path_length = ntohs (prm->put_path_length); |
2275 | uint16_t msize = ntohs (prm->header.size); | 2314 | uint16_t msize = ntohs (prm->header.size); |
2276 | 2315 | ||
2277 | (void) cls; | 2316 | (void) cls; |
@@ -2301,18 +2340,20 @@ static void | |||
2301 | handle_dht_p2p_result (void *cls, | 2340 | handle_dht_p2p_result (void *cls, |
2302 | const struct PeerResultMessage *prm) | 2341 | const struct PeerResultMessage *prm) |
2303 | { | 2342 | { |
2304 | struct PeerInfo *peer = cls; | 2343 | struct Target *t = cls; |
2344 | struct PeerInfo *peer = t->pi; | ||
2305 | uint16_t msize = ntohs (prm->header.size); | 2345 | uint16_t msize = ntohs (prm->header.size); |
2306 | uint32_t get_path_length = ntohl (prm->get_path_length); | 2346 | uint16_t get_path_length = ntohs (prm->get_path_length); |
2307 | struct GDS_DATACACHE_BlockData bd = { | 2347 | struct GDS_DATACACHE_BlockData bd = { |
2308 | .expiration_time = GNUNET_TIME_absolute_ntoh (prm->expiration_time), | 2348 | .expiration_time = GNUNET_TIME_absolute_ntoh (prm->expiration_time), |
2309 | .put_path = (const struct GNUNET_DHT_PathElement *) &prm[1], | 2349 | .put_path = (const struct GNUNET_DHT_PathElement *) &prm[1], |
2310 | .put_path_length = ntohl (prm->put_path_length), | 2350 | .put_path_length = ntohs (prm->put_path_length), |
2351 | .key = prm->key, | ||
2311 | .type = ntohl (prm->type) | 2352 | .type = ntohl (prm->type) |
2312 | }; | 2353 | }; |
2313 | const struct GNUNET_DHT_PathElement *get_path | 2354 | const struct GNUNET_DHT_PathElement *get_path |
2314 | = &bd.put_path[bd.put_path_length]; | 2355 | = &bd.put_path[bd.put_path_length]; |
2315 | 2356 | ||
2316 | /* parse and validate message */ | 2357 | /* parse and validate message */ |
2317 | if (GNUNET_TIME_absolute_is_past (bd.expiration_time)) | 2358 | if (GNUNET_TIME_absolute_is_past (bd.expiration_time)) |
2318 | { | 2359 | { |
@@ -2327,6 +2368,15 @@ handle_dht_p2p_result (void *cls, | |||
2327 | bd.data_size = msize - (sizeof(struct PeerResultMessage) | 2368 | bd.data_size = msize - (sizeof(struct PeerResultMessage) |
2328 | + (get_path_length + bd.put_path_length) | 2369 | + (get_path_length + bd.put_path_length) |
2329 | * sizeof(struct GNUNET_DHT_PathElement)); | 2370 | * sizeof(struct GNUNET_DHT_PathElement)); |
2371 | if (GNUNET_OK != | ||
2372 | GNUNET_BLOCK_check_block (GDS_block_context, | ||
2373 | bd.type, | ||
2374 | bd.data, | ||
2375 | bd.data_size)) | ||
2376 | { | ||
2377 | GNUNET_break_op (0); | ||
2378 | return; | ||
2379 | } | ||
2330 | GNUNET_STATISTICS_update (GDS_stats, | 2380 | GNUNET_STATISTICS_update (GDS_stats, |
2331 | "# P2P RESULTS received", | 2381 | "# P2P RESULTS received", |
2332 | 1, | 2382 | 1, |
@@ -2337,7 +2387,6 @@ handle_dht_p2p_result (void *cls, | |||
2337 | GNUNET_NO); | 2387 | GNUNET_NO); |
2338 | { | 2388 | { |
2339 | enum GNUNET_GenericReturnValue ret; | 2389 | enum GNUNET_GenericReturnValue ret; |
2340 | const struct GNUNET_HashCode *pquery; | ||
2341 | 2390 | ||
2342 | ret = GNUNET_BLOCK_get_key (GDS_block_context, | 2391 | ret = GNUNET_BLOCK_get_key (GDS_block_context, |
2343 | bd.type, | 2392 | bd.type, |
@@ -2345,102 +2394,274 @@ handle_dht_p2p_result (void *cls, | |||
2345 | bd.data_size, | 2394 | bd.data_size, |
2346 | &bd.key); | 2395 | &bd.key); |
2347 | if (GNUNET_NO == ret) | 2396 | if (GNUNET_NO == ret) |
2348 | { | 2397 | bd.key = prm->key; |
2349 | GNUNET_break_op (0); | ||
2350 | return; | ||
2351 | } | ||
2352 | pquery = (GNUNET_OK == ret) ? &bd.key : &prm->key; | ||
2353 | if (GNUNET_OK != | ||
2354 | GNUNET_BLOCK_check_block (GDS_block_context, | ||
2355 | bd.type, | ||
2356 | pquery, | ||
2357 | bd.data, | ||
2358 | bd.data_size)) | ||
2359 | { | ||
2360 | GNUNET_break_op (0); | ||
2361 | return; | ||
2362 | } | ||
2363 | } | 2398 | } |
2364 | 2399 | ||
2365 | /* if we got a HELLO, consider it for our own routing table */ | 2400 | /* if we got a HELLO, consider it for our own routing table */ |
2366 | if (GNUNET_BLOCK_TYPE_DHT_HELLO == bd.type) | 2401 | hello_check (&bd); |
2367 | { | ||
2368 | const struct GNUNET_MessageHeader *h = bd.data; | ||
2369 | struct GNUNET_PeerIdentity pid; | ||
2370 | |||
2371 | /* Should be a HELLO, validate and consider using it! */ | ||
2372 | if (bd.data_size < sizeof(struct GNUNET_HELLO_Message)) | ||
2373 | { | ||
2374 | GNUNET_break (0); | ||
2375 | return; | ||
2376 | } | ||
2377 | if (bd.data_size != ntohs (h->size)) | ||
2378 | { | ||
2379 | GNUNET_break (0); | ||
2380 | return; | ||
2381 | } | ||
2382 | if (GNUNET_OK != | ||
2383 | GNUNET_HELLO_get_id ((const struct GNUNET_HELLO_Message *) h, | ||
2384 | &pid)) | ||
2385 | { | ||
2386 | GNUNET_break_op (0); | ||
2387 | return; | ||
2388 | } | ||
2389 | if ( (GNUNET_YES != disable_try_connect) && | ||
2390 | (0 != GNUNET_memcmp (&my_identity, | ||
2391 | &pid)) ) | ||
2392 | try_connect (&pid, | ||
2393 | h); | ||
2394 | } | ||
2395 | 2402 | ||
2396 | /* First, check if 'peer' is already on the path, and if | 2403 | /* Need to append 'peer' to 'get_path' */ |
2397 | so, truncate it instead of expanding. */ | ||
2398 | for (unsigned int i = 0; i <= get_path_length; i++) | ||
2399 | if (0 == GNUNET_memcmp (&get_path[i].pred, | ||
2400 | peer->id)) | ||
2401 | { | ||
2402 | process_reply_with_path (&bd, | ||
2403 | &prm->key, | ||
2404 | i, get_path); | ||
2405 | return; | ||
2406 | } | ||
2407 | |||
2408 | /* Need to append 'peer' to 'get_path' (normal case) */ | ||
2409 | { | 2404 | { |
2410 | struct GNUNET_DHT_PathElement xget_path[get_path_length + 1]; | 2405 | struct GNUNET_DHT_PathElement xget_path[get_path_length + 1]; |
2406 | struct GNUNET_DHT_PathElement *gp = xget_path; | ||
2407 | unsigned int failure_offset; | ||
2411 | 2408 | ||
2412 | GNUNET_memcpy (xget_path, | 2409 | GNUNET_memcpy (xget_path, |
2413 | get_path, | 2410 | get_path, |
2414 | get_path_length * sizeof(struct GNUNET_DHT_PathElement)); | 2411 | get_path_length * sizeof(struct GNUNET_DHT_PathElement)); |
2415 | xget_path[get_path_length].pred = *peer->id; | 2412 | xget_path[get_path_length].pred = peer->id; |
2416 | memset (&xget_path[get_path_length].sig, | 2413 | memset (&xget_path[get_path_length].sig, |
2417 | 0, | 2414 | 0, |
2418 | sizeof (xget_path[get_path_length].sig)); | 2415 | sizeof (xget_path[get_path_length].sig)); |
2419 | process_reply_with_path (&bd, | 2416 | #if SANITY_CHECKS |
2420 | &prm->key, | 2417 | /* TODO: might want to eventually implement probabilistic |
2421 | get_path_length + 1, xget_path); | 2418 | load-based path verification, but for now it is all or nothing */ |
2419 | failure_offset | ||
2420 | = GNUNET_DHT_verify_path (bd.data, | ||
2421 | bd.data_size, | ||
2422 | bd.expiration_time, | ||
2423 | bd.put_path, | ||
2424 | bd.put_path_length, | ||
2425 | xget_path, | ||
2426 | get_path_length + 1, | ||
2427 | &GDS_my_identity); | ||
2428 | #else | ||
2429 | failure_offset = 0; | ||
2430 | #endif | ||
2431 | if (0 != failure_offset) | ||
2432 | { | ||
2433 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | ||
2434 | "Recorded path invalid at offset %u, truncating\n", | ||
2435 | failure_offset); | ||
2436 | GNUNET_assert (failure_offset <= bd.put_path_length + get_path_length); | ||
2437 | if (failure_offset >= bd.put_path_length) | ||
2438 | { | ||
2439 | /* failure on get path */ | ||
2440 | get_path_length -= (failure_offset - bd.put_path_length); | ||
2441 | gp = &xget_path[failure_offset - bd.put_path_length]; | ||
2442 | bd.put_path_length = 0; | ||
2443 | } | ||
2444 | else | ||
2445 | { | ||
2446 | /* failure on put path */ | ||
2447 | bd.put_path = &bd.put_path[failure_offset]; | ||
2448 | bd.put_path_length -= failure_offset; | ||
2449 | } | ||
2450 | } | ||
2451 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
2452 | "Extending GET path of length %u with %s\n", | ||
2453 | get_path_length, | ||
2454 | GNUNET_i2s (&peer->id)); | ||
2455 | GNUNET_break (process_reply_with_path (&bd, | ||
2456 | &prm->key, | ||
2457 | get_path_length + 1, | ||
2458 | gp)); | ||
2422 | } | 2459 | } |
2423 | } | 2460 | } |
2424 | 2461 | ||
2425 | 2462 | ||
2426 | enum GNUNET_GenericReturnValue | 2463 | /** |
2427 | GDS_NEIGHBOURS_init () | 2464 | * Check validity of a p2p hello message. |
2465 | * | ||
2466 | * @param cls closure | ||
2467 | * @param hello message | ||
2468 | * @return #GNUNET_YES if the message is well-formed | ||
2469 | */ | ||
2470 | static enum GNUNET_GenericReturnValue | ||
2471 | check_dht_p2p_hello (void *cls, | ||
2472 | const struct GNUNET_MessageHeader *hello) | ||
2428 | { | 2473 | { |
2474 | struct Target *t = cls; | ||
2475 | struct PeerInfo *peer = t->pi; | ||
2476 | enum GNUNET_GenericReturnValue ret; | ||
2477 | size_t hellob_size; | ||
2478 | void *hellob; | ||
2479 | struct GNUNET_TIME_Absolute expiration; | ||
2480 | |||
2481 | ret = GNUNET_HELLO_dht_msg_to_block (hello, | ||
2482 | &peer->id, | ||
2483 | &hellob, | ||
2484 | &hellob_size, | ||
2485 | &expiration); | ||
2486 | GNUNET_free (hellob); | ||
2487 | return ret; | ||
2488 | } | ||
2489 | |||
2490 | |||
2491 | /** | ||
2492 | * Core handler for p2p HELLO messages. | ||
2493 | * | ||
2494 | * @param cls closure | ||
2495 | * @param message message | ||
2496 | */ | ||
2497 | static void | ||
2498 | handle_dht_p2p_hello (void *cls, | ||
2499 | const struct GNUNET_MessageHeader *hello) | ||
2500 | { | ||
2501 | struct Target *t = cls; | ||
2502 | struct PeerInfo *peer = t->pi; | ||
2503 | |||
2504 | GNUNET_free (peer->hello); | ||
2505 | peer->hello_size = 0; | ||
2506 | GNUNET_break (GNUNET_OK == | ||
2507 | GNUNET_HELLO_dht_msg_to_block (hello, | ||
2508 | &peer->id, | ||
2509 | &peer->hello, | ||
2510 | &peer->hello_size, | ||
2511 | &peer->hello_expiration)); | ||
2512 | } | ||
2513 | |||
2514 | |||
2515 | void | ||
2516 | GDS_u_receive (void *cls, | ||
2517 | void **tctx, | ||
2518 | void **sctx, | ||
2519 | const void *message, | ||
2520 | size_t message_size) | ||
2521 | { | ||
2522 | struct Target *t = *tctx; | ||
2429 | struct GNUNET_MQ_MessageHandler core_handlers[] = { | 2523 | struct GNUNET_MQ_MessageHandler core_handlers[] = { |
2430 | GNUNET_MQ_hd_var_size (dht_p2p_get, | 2524 | GNUNET_MQ_hd_var_size (dht_p2p_get, |
2431 | GNUNET_MESSAGE_TYPE_DHT_P2P_GET, | 2525 | GNUNET_MESSAGE_TYPE_DHT_P2P_GET, |
2432 | struct PeerGetMessage, | 2526 | struct PeerGetMessage, |
2433 | NULL), | 2527 | t), |
2434 | GNUNET_MQ_hd_var_size (dht_p2p_put, | 2528 | GNUNET_MQ_hd_var_size (dht_p2p_put, |
2435 | GNUNET_MESSAGE_TYPE_DHT_P2P_PUT, | 2529 | GNUNET_MESSAGE_TYPE_DHT_P2P_PUT, |
2436 | struct PeerPutMessage, | 2530 | struct PeerPutMessage, |
2437 | NULL), | 2531 | t), |
2438 | GNUNET_MQ_hd_var_size (dht_p2p_result, | 2532 | GNUNET_MQ_hd_var_size (dht_p2p_result, |
2439 | GNUNET_MESSAGE_TYPE_DHT_P2P_RESULT, | 2533 | GNUNET_MESSAGE_TYPE_DHT_P2P_RESULT, |
2440 | struct PeerResultMessage, | 2534 | struct PeerResultMessage, |
2441 | NULL), | 2535 | t), |
2536 | GNUNET_MQ_hd_var_size (dht_p2p_hello, | ||
2537 | GNUNET_MESSAGE_TYPE_DHT_P2P_HELLO, | ||
2538 | struct GNUNET_MessageHeader, | ||
2539 | t), | ||
2442 | GNUNET_MQ_handler_end () | 2540 | GNUNET_MQ_handler_end () |
2443 | }; | 2541 | }; |
2542 | const struct GNUNET_MessageHeader *mh = message; | ||
2543 | |||
2544 | (void) cls; /* the 'struct GDS_Underlay' */ | ||
2545 | (void) sctx; /* our receiver address */ | ||
2546 | if (NULL == t) | ||
2547 | { | ||
2548 | /* Received message claiming to originate from myself? | ||
2549 | Ignore! */ | ||
2550 | GNUNET_break_op (0); | ||
2551 | return; | ||
2552 | } | ||
2553 | if (message_size < sizeof (*mh)) | ||
2554 | { | ||
2555 | GNUNET_break_op (0); | ||
2556 | return; | ||
2557 | } | ||
2558 | if (message_size != ntohs (mh->size)) | ||
2559 | { | ||
2560 | GNUNET_break_op (0); | ||
2561 | return; | ||
2562 | } | ||
2563 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
2564 | "Handling message of type %u from peer %s\n", | ||
2565 | ntohs (mh->type), | ||
2566 | GNUNET_i2s (&t->pi->id)); | ||
2567 | if (GNUNET_OK != | ||
2568 | GNUNET_MQ_handle_message (core_handlers, | ||
2569 | mh)) | ||
2570 | { | ||
2571 | GNUNET_break_op (0); | ||
2572 | return; | ||
2573 | } | ||
2574 | } | ||
2575 | |||
2576 | |||
2577 | /** | ||
2578 | * Callback function used to extract URIs from a builder. | ||
2579 | * Called when we should consider connecting to a peer. | ||
2580 | * | ||
2581 | * @param cls closure pointing to a `struct GNUNET_PeerIdentity *` | ||
2582 | * @param uri one of the URIs | ||
2583 | */ | ||
2584 | void | ||
2585 | GDS_try_connect (void *cls, | ||
2586 | const char *uri) | ||
2587 | { | ||
2588 | const struct GNUNET_PeerIdentity *pid = cls; | ||
2589 | struct GNUNET_HashCode phash; | ||
2590 | int peer_bucket; | ||
2591 | struct PeerBucket *bucket; | ||
2592 | |||
2593 | if (0 == GNUNET_memcmp (&GDS_my_identity, | ||
2594 | pid)) | ||
2595 | { | ||
2596 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
2597 | "Got a HELLO for my own PID, ignoring it\n"); | ||
2598 | return; /* that's us! */ | ||
2599 | } | ||
2600 | GNUNET_CRYPTO_hash (pid, | ||
2601 | sizeof(*pid), | ||
2602 | &phash); | ||
2603 | peer_bucket = find_bucket (&phash); | ||
2604 | GNUNET_assert ( (peer_bucket >= 0) && | ||
2605 | ((unsigned int) peer_bucket < MAX_BUCKETS)); | ||
2606 | bucket = &k_buckets[peer_bucket]; | ||
2607 | if (bucket->peers_size >= bucket_size) | ||
2608 | return; /* do not care */ | ||
2609 | for (struct PeerInfo *pi = bucket->head; | ||
2610 | NULL != pi; | ||
2611 | pi = pi->next) | ||
2612 | if (0 == | ||
2613 | GNUNET_memcmp (&pi->id, | ||
2614 | pid)) | ||
2615 | { | ||
2616 | /* already connected */ | ||
2617 | /* TODO: maybe consider 'uri' anyway as an additional | ||
2618 | alternative address??? */ | ||
2619 | return; | ||
2620 | } | ||
2621 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, | ||
2622 | "Discovered peer %s at %s suitable for bucket %d (%u/%u), trying to connect\n", | ||
2623 | GNUNET_i2s (pid), | ||
2624 | uri, | ||
2625 | peer_bucket, | ||
2626 | bucket->peers_size, | ||
2627 | bucket_size); | ||
2628 | /* new peer that we like! */ | ||
2629 | GDS_u_try_connect (pid, | ||
2630 | uri); | ||
2631 | } | ||
2632 | |||
2633 | |||
2634 | /** | ||
2635 | * Send @a msg to all peers in our buckets. | ||
2636 | * | ||
2637 | * @param msg message to broadcast | ||
2638 | */ | ||
2639 | void | ||
2640 | GDS_NEIGHBOURS_broadcast (const struct GNUNET_MessageHeader *msg) | ||
2641 | { | ||
2642 | for (unsigned int bc = 0; bc<closest_bucket; bc++) | ||
2643 | { | ||
2644 | struct PeerBucket *bucket = &k_buckets[bc]; | ||
2645 | unsigned int count = 0; | ||
2646 | |||
2647 | for (struct PeerInfo *pos = bucket->head; | ||
2648 | NULL != pos; | ||
2649 | pos = pos->next) | ||
2650 | { | ||
2651 | if (count >= bucket_size) | ||
2652 | break; /* we only consider first #bucket_size entries per bucket */ | ||
2653 | count++; | ||
2654 | do_send (pos, | ||
2655 | msg); | ||
2656 | } | ||
2657 | } | ||
2658 | } | ||
2659 | |||
2660 | |||
2661 | enum GNUNET_GenericReturnValue | ||
2662 | GDS_NEIGHBOURS_init () | ||
2663 | { | ||
2664 | |||
2444 | unsigned long long temp_config_num; | 2665 | unsigned long long temp_config_num; |
2445 | 2666 | ||
2446 | disable_try_connect | 2667 | disable_try_connect |
@@ -2457,45 +2678,8 @@ GDS_NEIGHBOURS_init () | |||
2457 | = GNUNET_CONFIGURATION_get_value_yesno (GDS_cfg, | 2678 | = GNUNET_CONFIGURATION_get_value_yesno (GDS_cfg, |
2458 | "DHT", | 2679 | "DHT", |
2459 | "CACHE_RESULTS"); | 2680 | "CACHE_RESULTS"); |
2460 | { | ||
2461 | char *keyfile; | ||
2462 | |||
2463 | if (GNUNET_OK != | ||
2464 | GNUNET_CONFIGURATION_get_value_filename (GDS_cfg, | ||
2465 | "PEER", | ||
2466 | "PRIVATE_KEY", | ||
2467 | &keyfile)) | ||
2468 | { | ||
2469 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | ||
2470 | "Core service is lacking HOSTKEY configuration setting. Exiting.\n"); | ||
2471 | return GNUNET_SYSERR; | ||
2472 | } | ||
2473 | if (GNUNET_SYSERR == | ||
2474 | GNUNET_CRYPTO_eddsa_key_from_file (keyfile, | ||
2475 | GNUNET_YES, | ||
2476 | &my_private_key)) | ||
2477 | { | ||
2478 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | ||
2479 | "Failed to setup peer's private key\n"); | ||
2480 | GNUNET_free (keyfile); | ||
2481 | return GNUNET_SYSERR; | ||
2482 | } | ||
2483 | GNUNET_free (keyfile); | ||
2484 | } | ||
2485 | |||
2486 | ats_ch = GNUNET_ATS_connectivity_init (GDS_cfg); | ||
2487 | core_api = GNUNET_CORE_connect (GDS_cfg, | ||
2488 | NULL, | ||
2489 | &core_init, | ||
2490 | &handle_core_connect, | ||
2491 | &handle_core_disconnect, | ||
2492 | core_handlers); | ||
2493 | if (NULL == core_api) | ||
2494 | return GNUNET_SYSERR; | ||
2495 | all_connected_peers = GNUNET_CONTAINER_multipeermap_create (256, | 2681 | all_connected_peers = GNUNET_CONTAINER_multipeermap_create (256, |
2496 | GNUNET_YES); | 2682 | GNUNET_YES); |
2497 | all_desired_peers = GNUNET_CONTAINER_multipeermap_create (256, | ||
2498 | GNUNET_NO); | ||
2499 | return GNUNET_OK; | 2683 | return GNUNET_OK; |
2500 | } | 2684 | } |
2501 | 2685 | ||
@@ -2503,21 +2687,12 @@ GDS_NEIGHBOURS_init () | |||
2503 | void | 2687 | void |
2504 | GDS_NEIGHBOURS_done () | 2688 | GDS_NEIGHBOURS_done () |
2505 | { | 2689 | { |
2506 | if (NULL == core_api) | 2690 | if (NULL == all_connected_peers) |
2507 | return; | 2691 | return; |
2508 | GNUNET_CORE_disconnect (core_api); | ||
2509 | core_api = NULL; | ||
2510 | GNUNET_assert (0 == | 2692 | GNUNET_assert (0 == |
2511 | GNUNET_CONTAINER_multipeermap_size (all_connected_peers)); | 2693 | GNUNET_CONTAINER_multipeermap_size (all_connected_peers)); |
2512 | GNUNET_CONTAINER_multipeermap_destroy (all_connected_peers); | 2694 | GNUNET_CONTAINER_multipeermap_destroy (all_connected_peers); |
2513 | all_connected_peers = NULL; | 2695 | all_connected_peers = NULL; |
2514 | GNUNET_CONTAINER_multipeermap_iterate (all_desired_peers, | ||
2515 | &free_connect_info, | ||
2516 | NULL); | ||
2517 | GNUNET_CONTAINER_multipeermap_destroy (all_desired_peers); | ||
2518 | all_desired_peers = NULL; | ||
2519 | GNUNET_ATS_connectivity_done (ats_ch); | ||
2520 | ats_ch = NULL; | ||
2521 | GNUNET_assert (NULL == find_peer_task); | 2696 | GNUNET_assert (NULL == find_peer_task); |
2522 | } | 2697 | } |
2523 | 2698 | ||
@@ -2525,7 +2700,7 @@ GDS_NEIGHBOURS_done () | |||
2525 | struct GNUNET_PeerIdentity * | 2700 | struct GNUNET_PeerIdentity * |
2526 | GDS_NEIGHBOURS_get_id () | 2701 | GDS_NEIGHBOURS_get_id () |
2527 | { | 2702 | { |
2528 | return &my_identity; | 2703 | return &GDS_my_identity; |
2529 | } | 2704 | } |
2530 | 2705 | ||
2531 | 2706 | ||
diff --git a/src/dht/gnunet-service-dht_neighbours.h b/src/dht/gnunet-service-dht_neighbours.h index 35bbb125d..4f4172f71 100644 --- a/src/dht/gnunet-service-dht_neighbours.h +++ b/src/dht/gnunet-service-dht_neighbours.h | |||
@@ -30,13 +30,9 @@ | |||
30 | #include "gnunet_util_lib.h" | 30 | #include "gnunet_util_lib.h" |
31 | #include "gnunet_block_lib.h" | 31 | #include "gnunet_block_lib.h" |
32 | #include "gnunet_dht_service.h" | 32 | #include "gnunet_dht_service.h" |
33 | #include "gnunet_dhtu_plugin.h" | ||
33 | #include "gnunet-service-dht_datacache.h" | 34 | #include "gnunet-service-dht_datacache.h" |
34 | 35 | ||
35 | /** | ||
36 | * Hash of the identity of this peer. | ||
37 | */ | ||
38 | extern struct GNUNET_HashCode my_identity_hash; | ||
39 | |||
40 | 36 | ||
41 | struct PeerInfo; | 37 | struct PeerInfo; |
42 | 38 | ||
@@ -67,8 +63,8 @@ GDS_NEIGHBOURS_lookup_peer (const struct GNUNET_PeerIdentity *target); | |||
67 | enum GNUNET_GenericReturnValue | 63 | enum GNUNET_GenericReturnValue |
68 | GDS_NEIGHBOURS_handle_put (const struct GDS_DATACACHE_BlockData *bd, | 64 | GDS_NEIGHBOURS_handle_put (const struct GDS_DATACACHE_BlockData *bd, |
69 | enum GNUNET_DHT_RouteOption options, | 65 | enum GNUNET_DHT_RouteOption options, |
70 | uint32_t desired_replication_level, | 66 | uint16_t desired_replication_level, |
71 | uint32_t hop_count, | 67 | uint16_t hop_count, |
72 | struct GNUNET_CONTAINER_BloomFilter *bf); | 68 | struct GNUNET_CONTAINER_BloomFilter *bf); |
73 | 69 | ||
74 | 70 | ||
@@ -92,8 +88,8 @@ GDS_NEIGHBOURS_handle_put (const struct GDS_DATACACHE_BlockData *bd, | |||
92 | enum GNUNET_GenericReturnValue | 88 | enum GNUNET_GenericReturnValue |
93 | GDS_NEIGHBOURS_handle_get (enum GNUNET_BLOCK_Type type, | 89 | GDS_NEIGHBOURS_handle_get (enum GNUNET_BLOCK_Type type, |
94 | enum GNUNET_DHT_RouteOption options, | 90 | enum GNUNET_DHT_RouteOption options, |
95 | uint32_t desired_replication_level, | 91 | uint16_t desired_replication_level, |
96 | uint32_t hop_count, | 92 | uint16_t hop_count, |
97 | const struct GNUNET_HashCode *key, | 93 | const struct GNUNET_HashCode *key, |
98 | const void *xquery, | 94 | const void *xquery, |
99 | size_t xquery_size, | 95 | size_t xquery_size, |
@@ -112,8 +108,9 @@ GDS_NEIGHBOURS_handle_get (enum GNUNET_BLOCK_Type type, | |||
112 | * @param query_hash query that was used for the request | 108 | * @param query_hash query that was used for the request |
113 | * @param get_path_length number of entries in put_path | 109 | * @param get_path_length number of entries in put_path |
114 | * @param get_path peers this reply has traversed so far (if tracked) | 110 | * @param get_path peers this reply has traversed so far (if tracked) |
111 | * @return true on success | ||
115 | */ | 112 | */ |
116 | void | 113 | bool |
117 | GDS_NEIGHBOURS_handle_reply (struct PeerInfo *pi, | 114 | GDS_NEIGHBOURS_handle_reply (struct PeerInfo *pi, |
118 | const struct GDS_DATACACHE_BlockData *bd, | 115 | const struct GDS_DATACACHE_BlockData *bd, |
119 | const struct GNUNET_HashCode *query_hash, | 116 | const struct GNUNET_HashCode *query_hash, |
@@ -137,6 +134,73 @@ GDS_am_closest_peer (const struct GNUNET_HashCode *key, | |||
137 | 134 | ||
138 | 135 | ||
139 | /** | 136 | /** |
137 | * Callback function used to extract URIs from a builder. | ||
138 | * Called when we should consider connecting to a peer. | ||
139 | * | ||
140 | * @param cls closure pointing to a `struct GNUNET_PeerIdentity *` | ||
141 | * @param uri one of the URIs | ||
142 | */ | ||
143 | void | ||
144 | GDS_try_connect (void *cls, | ||
145 | const char *uri); | ||
146 | |||
147 | |||
148 | /** | ||
149 | * Function to call when we connect to a peer and can henceforth transmit to | ||
150 | * that peer. | ||
151 | * | ||
152 | * @param cls the closure, must be a `struct GDS_Underlay` | ||
153 | * @param target handle to the target, | ||
154 | * pointer will remain valid until @e disconnect_cb is called | ||
155 | * @para pid peer identity, | ||
156 | * pointer will remain valid until @e disconnect_cb is called | ||
157 | * @param[out] ctx storage space for DHT to use in association with this target | ||
158 | */ | ||
159 | void | ||
160 | GDS_u_connect (void *cls, | ||
161 | struct GNUNET_DHTU_Target *target, | ||
162 | const struct GNUNET_PeerIdentity *pid, | ||
163 | void **ctx); | ||
164 | |||
165 | |||
166 | /** | ||
167 | * Function to call when we disconnected from a peer and can henceforth | ||
168 | * cannot transmit to that peer anymore. | ||
169 | * | ||
170 | * @param[in] ctx storage space used by the DHT in association with this target | ||
171 | */ | ||
172 | void | ||
173 | GDS_u_disconnect (void *ctx); | ||
174 | |||
175 | |||
176 | /** | ||
177 | * Function to call when we receive a message. | ||
178 | * | ||
179 | * @param cls the closure | ||
180 | * @param origin where the message originated from | ||
181 | * @param[in,out] tctx ctx of target address where we received the message from | ||
182 | * @param[in,out] sctx ctx of our own source address at which we received the message | ||
183 | * @param message the message we received @param message_size number of | ||
184 | * bytes in @a message | ||
185 | */ | ||
186 | void | ||
187 | GDS_u_receive (void *cls, | ||
188 | void **tctx, | ||
189 | void **sctx, | ||
190 | const void *message, | ||
191 | size_t message_size); | ||
192 | |||
193 | |||
194 | /** | ||
195 | * Send @a msg to all peers in our buckets. | ||
196 | * | ||
197 | * @param msg message to broadcast | ||
198 | */ | ||
199 | void | ||
200 | GDS_NEIGHBOURS_broadcast (const struct GNUNET_MessageHeader *msg); | ||
201 | |||
202 | |||
203 | /** | ||
140 | * Initialize neighbours subsystem. | 204 | * Initialize neighbours subsystem. |
141 | * | 205 | * |
142 | * @return #GNUNET_OK on success, #GNUNET_SYSERR on error | 206 | * @return #GNUNET_OK on success, #GNUNET_SYSERR on error |
diff --git a/src/dht/gnunet-service-dht_nse.c b/src/dht/gnunet-service-dht_nse.c deleted file mode 100644 index 58f18816a..000000000 --- a/src/dht/gnunet-service-dht_nse.c +++ /dev/null | |||
@@ -1,121 +0,0 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2009, 2010, 2011 GNUnet e.V. | ||
4 | |||
5 | GNUnet is free software: you can redistribute it and/or modify it | ||
6 | under the terms of the GNU Affero General Public License as published | ||
7 | by the Free Software Foundation, either version 3 of the License, | ||
8 | or (at your option) any later version. | ||
9 | |||
10 | GNUnet is distributed in the hope that it will be useful, but | ||
11 | WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
13 | Affero General Public License for more details. | ||
14 | |||
15 | You should have received a copy of the GNU Affero General Public License | ||
16 | along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
17 | |||
18 | SPDX-License-Identifier: AGPL3.0-or-later | ||
19 | */ | ||
20 | |||
21 | /** | ||
22 | * @file dht/gnunet-service-dht_nse.c | ||
23 | * @brief GNUnet DHT integration with NSE | ||
24 | * @author Christian Grothoff | ||
25 | */ | ||
26 | #include "platform.h" | ||
27 | #include "gnunet_nse_service.h" | ||
28 | #include "gnunet-service-dht.h" | ||
29 | #include "gnunet-service-dht_nse.h" | ||
30 | |||
31 | /** | ||
32 | * log of the current network size estimate, used as the point where | ||
33 | * we switch between random and deterministic routing. Default | ||
34 | * value of 4.0 is used if NSE module is not available (i.e. not | ||
35 | * configured). | ||
36 | */ | ||
37 | static double log_of_network_size_estimate = 4.0; | ||
38 | |||
39 | /** | ||
40 | * Network size estimation handle. | ||
41 | */ | ||
42 | static struct GNUNET_NSE_Handle *nse; | ||
43 | |||
44 | |||
45 | /** | ||
46 | * Callback that is called when network size estimate is updated. | ||
47 | * | ||
48 | * @param cls closure | ||
49 | * @param timestamp time when the estimate was received from the server (or created by the server) | ||
50 | * @param logestimate the log(Base 2) value of the current network size estimate | ||
51 | * @param std_dev standard deviation for the estimate | ||
52 | * | ||
53 | */ | ||
54 | static void | ||
55 | update_network_size_estimate (void *cls, | ||
56 | struct GNUNET_TIME_Absolute timestamp, | ||
57 | double logestimate, | ||
58 | double std_dev) | ||
59 | { | ||
60 | GNUNET_STATISTICS_update (GDS_stats, | ||
61 | "# Network size estimates received", | ||
62 | 1, GNUNET_NO); | ||
63 | /* do not allow estimates < 0.5 */ | ||
64 | log_of_network_size_estimate = GNUNET_MAX (0.5, logestimate); | ||
65 | } | ||
66 | |||
67 | |||
68 | /** | ||
69 | * Return the log of the current network size estimate. | ||
70 | * | ||
71 | * @return log of NSE | ||
72 | */ | ||
73 | double | ||
74 | GDS_NSE_get () | ||
75 | { | ||
76 | return log_of_network_size_estimate; | ||
77 | } | ||
78 | |||
79 | |||
80 | /** | ||
81 | * Initialize NSE subsystem. | ||
82 | */ | ||
83 | void | ||
84 | GDS_NSE_init () | ||
85 | { | ||
86 | unsigned long long hops; | ||
87 | |||
88 | if ( (GNUNET_YES == | ||
89 | GNUNET_CONFIGURATION_have_value (GDS_cfg, | ||
90 | "dht", | ||
91 | "FORCE_NSE")) && | ||
92 | (GNUNET_OK == | ||
93 | GNUNET_CONFIGURATION_get_value_number (GDS_cfg, | ||
94 | "dht", | ||
95 | "FORCE_NSE", | ||
96 | &hops)) ) | ||
97 | { | ||
98 | log_of_network_size_estimate = (double) hops; | ||
99 | return; | ||
100 | } | ||
101 | nse = GNUNET_NSE_connect (GDS_cfg, | ||
102 | &update_network_size_estimate, | ||
103 | NULL); | ||
104 | } | ||
105 | |||
106 | |||
107 | /** | ||
108 | * Shutdown NSE subsystem. | ||
109 | */ | ||
110 | void | ||
111 | GDS_NSE_done () | ||
112 | { | ||
113 | if (NULL != nse) | ||
114 | { | ||
115 | GNUNET_NSE_disconnect (nse); | ||
116 | nse = NULL; | ||
117 | } | ||
118 | } | ||
119 | |||
120 | |||
121 | /* end of gnunet-service-dht_nse.c */ | ||
diff --git a/src/dht/gnunet-service-dht_nse.h b/src/dht/gnunet-service-dht_nse.h deleted file mode 100644 index e99389e74..000000000 --- a/src/dht/gnunet-service-dht_nse.h +++ /dev/null | |||
@@ -1,52 +0,0 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2011 GNUnet e.V. | ||
4 | |||
5 | GNUnet is free software: you can redistribute it and/or modify it | ||
6 | under the terms of the GNU Affero General Public License as published | ||
7 | by the Free Software Foundation, either version 3 of the License, | ||
8 | or (at your option) any later version. | ||
9 | |||
10 | GNUnet is distributed in the hope that it will be useful, but | ||
11 | WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
13 | Affero General Public License for more details. | ||
14 | |||
15 | You should have received a copy of the GNU Affero General Public License | ||
16 | along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
17 | |||
18 | SPDX-License-Identifier: AGPL3.0-or-later | ||
19 | */ | ||
20 | |||
21 | /** | ||
22 | * @file dht/gnunet-service-dht_nse.h | ||
23 | * @brief GNUnet DHT integration with NSE | ||
24 | * @author Christian Grothoff | ||
25 | */ | ||
26 | #ifndef GNUNET_SERVICE_DHT_NSE_H | ||
27 | #define GNUNET_SERVICE_DHT_NSE_H | ||
28 | |||
29 | |||
30 | /** | ||
31 | * Return the log of the current network size estimate. | ||
32 | * | ||
33 | * @return log of NSE | ||
34 | */ | ||
35 | double | ||
36 | GDS_NSE_get (void); | ||
37 | |||
38 | |||
39 | /** | ||
40 | * Initialize NSE subsystem. | ||
41 | */ | ||
42 | void | ||
43 | GDS_NSE_init (void); | ||
44 | |||
45 | |||
46 | /** | ||
47 | * Shutdown NSE subsystem. | ||
48 | */ | ||
49 | void | ||
50 | GDS_NSE_done (void); | ||
51 | |||
52 | #endif | ||
diff --git a/src/dht/gnunet-service-dht_routing.c b/src/dht/gnunet-service-dht_routing.c index e7b5c3571..6deb5fa16 100644 --- a/src/dht/gnunet-service-dht_routing.c +++ b/src/dht/gnunet-service-dht_routing.c | |||
@@ -27,6 +27,7 @@ | |||
27 | #include "gnunet-service-dht_neighbours.h" | 27 | #include "gnunet-service-dht_neighbours.h" |
28 | #include "gnunet-service-dht_routing.h" | 28 | #include "gnunet-service-dht_routing.h" |
29 | #include "gnunet-service-dht.h" | 29 | #include "gnunet-service-dht.h" |
30 | #include "gnunet_block_group_lib.h" | ||
30 | 31 | ||
31 | 32 | ||
32 | /** | 33 | /** |
@@ -151,7 +152,7 @@ process (void *cls, | |||
151 | bdx.put_path_length = 0; | 152 | bdx.put_path_length = 0; |
152 | bdx.put_path = NULL; | 153 | bdx.put_path = NULL; |
153 | } | 154 | } |
154 | if ( (0 == (rr->options & GNUNET_DHT_RO_FIND_PEER)) && | 155 | if ( (0 == (rr->options & GNUNET_DHT_RO_FIND_APPROXIMATE)) && |
155 | (0 != GNUNET_memcmp (query_hash, | 156 | (0 != GNUNET_memcmp (query_hash, |
156 | &bdx.key)) ) | 157 | &bdx.key)) ) |
157 | { | 158 | { |
@@ -174,6 +175,22 @@ process (void *cls, | |||
174 | GNUNET_h2s (&bdx.key), | 175 | GNUNET_h2s (&bdx.key), |
175 | bdx.type, | 176 | bdx.type, |
176 | eval); | 177 | eval); |
178 | if (GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED == eval) | ||
179 | { | ||
180 | /* If we do not know the block type, we still filter | ||
181 | exact duplicates by the block content */ | ||
182 | struct GNUNET_HashCode chash; | ||
183 | |||
184 | GNUNET_CRYPTO_hash (bdx.data, | ||
185 | bdx.data_size, | ||
186 | &chash); | ||
187 | if (GNUNET_YES == | ||
188 | GNUNET_BLOCK_GROUP_bf_test_and_set (rr->bg, | ||
189 | &chash)) | ||
190 | eval = GNUNET_BLOCK_REPLY_OK_DUPLICATE; | ||
191 | else | ||
192 | eval = GNUNET_BLOCK_REPLY_OK_MORE; | ||
193 | } | ||
177 | switch (eval) | 194 | switch (eval) |
178 | { | 195 | { |
179 | case GNUNET_BLOCK_REPLY_OK_MORE: | 196 | case GNUNET_BLOCK_REPLY_OK_MORE: |
@@ -195,10 +212,11 @@ process (void *cls, | |||
195 | GNUNET_h2s (query_hash)); | 212 | GNUNET_h2s (query_hash)); |
196 | return GNUNET_OK; | 213 | return GNUNET_OK; |
197 | } | 214 | } |
198 | GDS_NEIGHBOURS_handle_reply (pi, | 215 | GNUNET_break (GDS_NEIGHBOURS_handle_reply (pi, |
199 | &bdx, | 216 | &bdx, |
200 | query_hash, | 217 | query_hash, |
201 | get_path_length, pc->get_path); | 218 | get_path_length, |
219 | pc->get_path)); | ||
202 | } | 220 | } |
203 | break; | 221 | break; |
204 | case GNUNET_BLOCK_REPLY_OK_DUPLICATE: | 222 | case GNUNET_BLOCK_REPLY_OK_DUPLICATE: |
@@ -207,13 +225,6 @@ process (void *cls, | |||
207 | 1, | 225 | 1, |
208 | GNUNET_NO); | 226 | GNUNET_NO); |
209 | return GNUNET_OK; | 227 | return GNUNET_OK; |
210 | case GNUNET_BLOCK_REPLY_INVALID: | ||
211 | GNUNET_break (0); | ||
212 | GNUNET_STATISTICS_update (GDS_stats, | ||
213 | "# Invalid REPLIES matched against routing table", | ||
214 | 1, | ||
215 | GNUNET_NO); | ||
216 | return GNUNET_OK; | ||
217 | case GNUNET_BLOCK_REPLY_IRRELEVANT: | 228 | case GNUNET_BLOCK_REPLY_IRRELEVANT: |
218 | GNUNET_STATISTICS_update (GDS_stats, | 229 | GNUNET_STATISTICS_update (GDS_stats, |
219 | "# Irrelevant REPLIES matched against routing table", | 230 | "# Irrelevant REPLIES matched against routing table", |
@@ -325,6 +336,7 @@ try_combine_recent (void *cls, | |||
325 | * | 336 | * |
326 | * @param sender peer that originated the request | 337 | * @param sender peer that originated the request |
327 | * @param type type of the block | 338 | * @param type type of the block |
339 | * @param[in] bg block group for filtering duplicate replies | ||
328 | * @param options options for processing | 340 | * @param options options for processing |
329 | * @param key key for the content | 341 | * @param key key for the content |
330 | * @param xquery extended query | 342 | * @param xquery extended query |
diff --git a/src/dht/plugin_block_dht.c b/src/dht/plugin_block_dht.c index 7c6fb9ed6..3dd3dd792 100644 --- a/src/dht/plugin_block_dht.c +++ b/src/dht/plugin_block_dht.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet | 2 | This file is part of GNUnet |
3 | Copyright (C) 2010, 2017 GNUnet e.V. | 3 | Copyright (C) 2010, 2017, 2022 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,6 +28,7 @@ | |||
28 | #include "platform.h" | 28 | #include "platform.h" |
29 | #include "gnunet_constants.h" | 29 | #include "gnunet_constants.h" |
30 | #include "gnunet_hello_lib.h" | 30 | #include "gnunet_hello_lib.h" |
31 | #include "gnunet_hello_uri_lib.h" | ||
31 | #include "gnunet_block_plugin.h" | 32 | #include "gnunet_block_plugin.h" |
32 | #include "gnunet_block_group_lib.h" | 33 | #include "gnunet_block_group_lib.h" |
33 | 34 | ||
@@ -89,80 +90,9 @@ block_plugin_dht_create_group (void *cls, | |||
89 | 90 | ||
90 | 91 | ||
91 | /** | 92 | /** |
92 | * Function called to validate a reply or a request. For | ||
93 | * request evaluation, simply pass "NULL" for the @a reply_block. | ||
94 | * | ||
95 | * @param cls closure | ||
96 | * @param ctx context | ||
97 | * @param type block type | ||
98 | * @param group block group to check against | ||
99 | * @param eo control flags | ||
100 | * @param query original query (hash) | ||
101 | * @param xquery extended query data (can be NULL, depending on type) | ||
102 | * @param xquery_size number of bytes in @a xquery | ||
103 | * @param reply_block response to validate | ||
104 | * @param reply_block_size number of bytes in @a reply_block | ||
105 | * @return characterization of result | ||
106 | */ | ||
107 | static enum GNUNET_BLOCK_EvaluationResult | ||
108 | block_plugin_dht_evaluate (void *cls, | ||
109 | struct GNUNET_BLOCK_Context *ctx, | ||
110 | enum GNUNET_BLOCK_Type type, | ||
111 | struct GNUNET_BLOCK_Group *group, | ||
112 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
113 | const struct GNUNET_HashCode *query, | ||
114 | const void *xquery, | ||
115 | size_t xquery_size, | ||
116 | const void *reply_block, | ||
117 | size_t reply_block_size) | ||
118 | { | ||
119 | const struct GNUNET_HELLO_Message *hello; | ||
120 | struct GNUNET_PeerIdentity pid; | ||
121 | const struct GNUNET_MessageHeader *msg; | ||
122 | struct GNUNET_HashCode phash; | ||
123 | |||
124 | if (type != GNUNET_BLOCK_TYPE_DHT_HELLO) | ||
125 | return GNUNET_BLOCK_EVALUATION_TYPE_NOT_SUPPORTED; | ||
126 | if (0 != xquery_size) | ||
127 | { | ||
128 | GNUNET_break_op (0); | ||
129 | return GNUNET_BLOCK_EVALUATION_REQUEST_INVALID; | ||
130 | } | ||
131 | if (NULL == reply_block) | ||
132 | return GNUNET_BLOCK_EVALUATION_REQUEST_VALID; | ||
133 | if (reply_block_size < sizeof(struct GNUNET_MessageHeader)) | ||
134 | { | ||
135 | GNUNET_break_op (0); | ||
136 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
137 | } | ||
138 | msg = reply_block; | ||
139 | if (reply_block_size != ntohs (msg->size)) | ||
140 | { | ||
141 | GNUNET_break_op (0); | ||
142 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
143 | } | ||
144 | hello = reply_block; | ||
145 | if (GNUNET_OK != GNUNET_HELLO_get_id (hello, &pid)) | ||
146 | { | ||
147 | GNUNET_break_op (0); | ||
148 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
149 | } | ||
150 | GNUNET_CRYPTO_hash (&pid, | ||
151 | sizeof(pid), | ||
152 | &phash); | ||
153 | if (GNUNET_YES == | ||
154 | GNUNET_BLOCK_GROUP_bf_test_and_set (group, | ||
155 | &phash)) | ||
156 | return GNUNET_BLOCK_EVALUATION_OK_DUPLICATE; | ||
157 | return GNUNET_BLOCK_EVALUATION_OK_MORE; | ||
158 | } | ||
159 | |||
160 | |||
161 | /** | ||
162 | * Function called to validate a query. | 93 | * Function called to validate a query. |
163 | * | 94 | * |
164 | * @param cls closure | 95 | * @param cls closure |
165 | * @param ctx block context | ||
166 | * @param type block type | 96 | * @param type block type |
167 | * @param query original query (hash) | 97 | * @param query original query (hash) |
168 | * @param xquery extrended query data (can be NULL, depending on type) | 98 | * @param xquery extrended query data (can be NULL, depending on type) |
@@ -171,19 +101,31 @@ block_plugin_dht_evaluate (void *cls, | |||
171 | */ | 101 | */ |
172 | static enum GNUNET_GenericReturnValue | 102 | static enum GNUNET_GenericReturnValue |
173 | block_plugin_dht_check_query (void *cls, | 103 | block_plugin_dht_check_query (void *cls, |
174 | enum GNUNET_BLOCK_Type type, | 104 | enum GNUNET_BLOCK_Type type, |
175 | const struct GNUNET_HashCode *query, | 105 | const struct GNUNET_HashCode *query, |
176 | const void *xquery, | 106 | const void *xquery, |
177 | size_t xquery_size) | 107 | size_t xquery_size) |
178 | { | 108 | { |
179 | if (type != GNUNET_BLOCK_TYPE_DHT_HELLO) | 109 | switch (type) |
180 | return GNUNET_SYSERR; | ||
181 | if (0 != xquery_size) | ||
182 | { | 110 | { |
183 | GNUNET_break_op (0); | 111 | case GNUNET_BLOCK_TYPE_DHT_HELLO: |
184 | return GNUNET_NO; | 112 | if (0 != xquery_size) |
113 | { | ||
114 | GNUNET_break_op (0); | ||
115 | return GNUNET_NO; | ||
116 | } | ||
117 | return GNUNET_OK; | ||
118 | case GNUNET_BLOCK_TYPE_DHT_URL_HELLO: | ||
119 | if (0 != xquery_size) | ||
120 | { | ||
121 | GNUNET_break_op (0); | ||
122 | return GNUNET_NO; | ||
123 | } | ||
124 | return GNUNET_OK; | ||
125 | default: | ||
126 | GNUNET_break (0); | ||
127 | return GNUNET_SYSERR; | ||
185 | } | 128 | } |
186 | return GNUNET_OK; | ||
187 | } | 129 | } |
188 | 130 | ||
189 | 131 | ||
@@ -192,44 +134,71 @@ block_plugin_dht_check_query (void *cls, | |||
192 | * | 134 | * |
193 | * @param cls closure | 135 | * @param cls closure |
194 | * @param type block type | 136 | * @param type block type |
195 | * @param query key for the block (hash), must match exactly | ||
196 | * @param block block data to validate | 137 | * @param block block data to validate |
197 | * @param block_size number of bytes in @a block | 138 | * @param block_size number of bytes in @a block |
198 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not | 139 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not |
199 | */ | 140 | */ |
200 | static enum GNUNET_GenericReturnValue | 141 | static enum GNUNET_GenericReturnValue |
201 | block_plugin_dht_check_block (void *cls, | 142 | block_plugin_dht_check_block (void *cls, |
202 | enum GNUNET_BLOCK_Type type, | 143 | enum GNUNET_BLOCK_Type type, |
203 | const struct GNUNET_HashCode *query, | 144 | const void *block, |
204 | const void *block, | 145 | size_t block_size) |
205 | size_t block_size) | ||
206 | { | 146 | { |
207 | const struct GNUNET_HELLO_Message *hello; | 147 | switch (type) |
208 | struct GNUNET_PeerIdentity pid; | ||
209 | const struct GNUNET_MessageHeader *msg; | ||
210 | |||
211 | if (type != GNUNET_BLOCK_TYPE_DHT_HELLO) | ||
212 | return GNUNET_SYSERR; | ||
213 | if (block_size < sizeof(struct GNUNET_MessageHeader)) | ||
214 | { | ||
215 | GNUNET_break_op (0); | ||
216 | return GNUNET_NO; | ||
217 | } | ||
218 | msg = block; | ||
219 | if (block_size != ntohs (msg->size)) | ||
220 | { | ||
221 | GNUNET_break_op (0); | ||
222 | return GNUNET_NO; | ||
223 | } | ||
224 | hello = block; | ||
225 | if (GNUNET_OK != | ||
226 | GNUNET_HELLO_get_id (hello, | ||
227 | &pid)) | ||
228 | { | 148 | { |
229 | GNUNET_break_op (0); | 149 | case GNUNET_BLOCK_TYPE_DHT_HELLO: |
230 | return GNUNET_NO; | 150 | { |
151 | const struct GNUNET_HELLO_Message *hello; | ||
152 | struct GNUNET_PeerIdentity pid; | ||
153 | const struct GNUNET_MessageHeader *msg; | ||
154 | |||
155 | if (block_size < sizeof(struct GNUNET_MessageHeader)) | ||
156 | { | ||
157 | GNUNET_break_op (0); | ||
158 | return GNUNET_NO; | ||
159 | } | ||
160 | msg = block; | ||
161 | if (block_size != ntohs (msg->size)) | ||
162 | { | ||
163 | GNUNET_break_op (0); | ||
164 | return GNUNET_NO; | ||
165 | } | ||
166 | hello = block; | ||
167 | if (GNUNET_OK != | ||
168 | GNUNET_HELLO_get_id (hello, | ||
169 | &pid)) | ||
170 | { | ||
171 | GNUNET_break_op (0); | ||
172 | return GNUNET_NO; | ||
173 | } | ||
174 | return GNUNET_OK; | ||
175 | } | ||
176 | case GNUNET_BLOCK_TYPE_DHT_URL_HELLO: | ||
177 | { | ||
178 | struct GNUNET_HELLO_Builder *b; | ||
179 | struct GNUNET_PeerIdentity pid; | ||
180 | struct GNUNET_HashCode h_pid; | ||
181 | |||
182 | b = GNUNET_HELLO_builder_from_block (block, | ||
183 | block_size); | ||
184 | if (NULL == b) | ||
185 | { | ||
186 | GNUNET_break (0); | ||
187 | return GNUNET_NO; | ||
188 | } | ||
189 | GNUNET_HELLO_builder_iterate (b, | ||
190 | &pid, | ||
191 | NULL, NULL); | ||
192 | GNUNET_CRYPTO_hash (&pid, | ||
193 | sizeof (pid), | ||
194 | &h_pid); | ||
195 | GNUNET_HELLO_builder_free (b); | ||
196 | return GNUNET_OK; | ||
197 | } | ||
198 | default: | ||
199 | GNUNET_break (0); | ||
200 | return GNUNET_SYSERR; | ||
231 | } | 201 | } |
232 | return GNUNET_OK; | ||
233 | } | 202 | } |
234 | 203 | ||
235 | 204 | ||
@@ -251,49 +220,63 @@ block_plugin_dht_check_block (void *cls, | |||
251 | */ | 220 | */ |
252 | static enum GNUNET_BLOCK_ReplyEvaluationResult | 221 | static enum GNUNET_BLOCK_ReplyEvaluationResult |
253 | block_plugin_dht_check_reply ( | 222 | block_plugin_dht_check_reply ( |
254 | void *cls, | 223 | void *cls, |
255 | enum GNUNET_BLOCK_Type type, | 224 | enum GNUNET_BLOCK_Type type, |
256 | struct GNUNET_BLOCK_Group *group, | 225 | struct GNUNET_BLOCK_Group *group, |
257 | const struct GNUNET_HashCode *query, | 226 | const struct GNUNET_HashCode *query, |
258 | const void *xquery, | 227 | const void *xquery, |
259 | size_t xquery_size, | 228 | size_t xquery_size, |
260 | const void *reply_block, | 229 | const void *reply_block, |
261 | size_t reply_block_size) | 230 | size_t reply_block_size) |
262 | { | 231 | { |
263 | const struct GNUNET_HELLO_Message *hello; | 232 | switch (type) |
264 | struct GNUNET_PeerIdentity pid; | ||
265 | const struct GNUNET_MessageHeader *msg; | ||
266 | struct GNUNET_HashCode phash; | ||
267 | |||
268 | if (type != GNUNET_BLOCK_TYPE_DHT_HELLO) | ||
269 | return GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED; | ||
270 | if (reply_block_size < sizeof(struct GNUNET_MessageHeader)) | ||
271 | { | ||
272 | GNUNET_break_op (0); | ||
273 | return GNUNET_BLOCK_REPLY_INVALID; | ||
274 | } | ||
275 | msg = reply_block; | ||
276 | if (reply_block_size != ntohs (msg->size)) | ||
277 | { | ||
278 | GNUNET_break_op (0); | ||
279 | return GNUNET_BLOCK_REPLY_INVALID; | ||
280 | } | ||
281 | hello = reply_block; | ||
282 | if (GNUNET_OK != | ||
283 | GNUNET_HELLO_get_id (hello, | ||
284 | &pid)) | ||
285 | { | 233 | { |
286 | GNUNET_break_op (0); | 234 | case GNUNET_BLOCK_TYPE_DHT_HELLO: |
287 | return GNUNET_BLOCK_REPLY_INVALID; | 235 | { |
236 | const struct GNUNET_MessageHeader *msg = reply_block; | ||
237 | const struct GNUNET_HELLO_Message *hello = reply_block; | ||
238 | struct GNUNET_PeerIdentity pid; | ||
239 | struct GNUNET_HashCode phash; | ||
240 | |||
241 | GNUNET_assert (reply_block_size >= sizeof(struct GNUNET_MessageHeader)); | ||
242 | GNUNET_assert (reply_block_size == ntohs (msg->size)); | ||
243 | GNUNET_assert (GNUNET_OK == | ||
244 | GNUNET_HELLO_get_id (hello, | ||
245 | &pid)); | ||
246 | GNUNET_CRYPTO_hash (&pid, | ||
247 | sizeof(pid), | ||
248 | &phash); | ||
249 | if (GNUNET_YES == | ||
250 | GNUNET_BLOCK_GROUP_bf_test_and_set (group, | ||
251 | &phash)) | ||
252 | return GNUNET_BLOCK_REPLY_OK_DUPLICATE; | ||
253 | return GNUNET_BLOCK_REPLY_OK_MORE; | ||
254 | } | ||
255 | case GNUNET_BLOCK_TYPE_DHT_URL_HELLO: | ||
256 | { | ||
257 | struct GNUNET_HELLO_Builder *b; | ||
258 | struct GNUNET_PeerIdentity pid; | ||
259 | struct GNUNET_HashCode h_pid; | ||
260 | |||
261 | b = GNUNET_HELLO_builder_from_block (reply_block, | ||
262 | reply_block_size); | ||
263 | GNUNET_assert (NULL != b); | ||
264 | GNUNET_HELLO_builder_iterate (b, | ||
265 | &pid, | ||
266 | NULL, NULL); | ||
267 | GNUNET_CRYPTO_hash (&pid, | ||
268 | sizeof (pid), | ||
269 | &h_pid); | ||
270 | GNUNET_HELLO_builder_free (b); | ||
271 | if (GNUNET_YES == | ||
272 | GNUNET_BLOCK_GROUP_bf_test_and_set (group, | ||
273 | &h_pid)) | ||
274 | return GNUNET_BLOCK_REPLY_OK_DUPLICATE; | ||
275 | return GNUNET_BLOCK_REPLY_OK_MORE; | ||
276 | } | ||
277 | default: | ||
278 | return GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED; | ||
288 | } | 279 | } |
289 | GNUNET_CRYPTO_hash (&pid, | ||
290 | sizeof(pid), | ||
291 | &phash); | ||
292 | if (GNUNET_YES == | ||
293 | GNUNET_BLOCK_GROUP_bf_test_and_set (group, | ||
294 | &phash)) | ||
295 | return GNUNET_BLOCK_REPLY_OK_DUPLICATE; | ||
296 | return GNUNET_BLOCK_REPLY_OK_MORE; | ||
297 | } | 280 | } |
298 | 281 | ||
299 | 282 | ||
@@ -315,41 +298,76 @@ block_plugin_dht_get_key (void *cls, | |||
315 | size_t block_size, | 298 | size_t block_size, |
316 | struct GNUNET_HashCode *key) | 299 | struct GNUNET_HashCode *key) |
317 | { | 300 | { |
318 | const struct GNUNET_MessageHeader *msg; | 301 | switch (type) |
319 | const struct GNUNET_HELLO_Message *hello; | ||
320 | struct GNUNET_PeerIdentity *pid; | ||
321 | |||
322 | if (type != GNUNET_BLOCK_TYPE_DHT_HELLO) | ||
323 | return GNUNET_SYSERR; | ||
324 | if (block_size < sizeof(struct GNUNET_MessageHeader)) | ||
325 | { | 302 | { |
326 | GNUNET_log_from (GNUNET_ERROR_TYPE_ERROR, | 303 | case GNUNET_BLOCK_TYPE_DHT_HELLO: |
327 | "block-dht", | 304 | { |
328 | _ ("Block not of type %u\n"), | 305 | const struct GNUNET_MessageHeader *msg; |
329 | GNUNET_BLOCK_TYPE_DHT_HELLO); | 306 | const struct GNUNET_HELLO_Message *hello; |
330 | return GNUNET_NO; | 307 | struct GNUNET_PeerIdentity *pid; |
331 | } | 308 | |
332 | msg = block; | 309 | if (block_size < sizeof(struct GNUNET_MessageHeader)) |
333 | if (block_size != ntohs (msg->size)) | 310 | { |
334 | { | 311 | GNUNET_break_op (0); |
335 | GNUNET_log_from (GNUNET_ERROR_TYPE_ERROR, | 312 | memset (key, |
336 | "block-dht", | 313 | 0, |
337 | _ ("Size mismatch for block with type %u\n"), | 314 | sizeof (*key)); |
338 | GNUNET_BLOCK_TYPE_DHT_HELLO); | 315 | return GNUNET_OK; |
339 | return GNUNET_NO; | 316 | } |
340 | } | 317 | msg = block; |
341 | hello = block; | 318 | if (block_size != ntohs (msg->size)) |
342 | memset (key, 0, sizeof(*key)); | 319 | { |
343 | pid = (struct GNUNET_PeerIdentity *) key; | 320 | GNUNET_break_op (0); |
344 | if (GNUNET_OK != GNUNET_HELLO_get_id (hello, pid)) | 321 | memset (key, |
345 | { | 322 | 0, |
346 | GNUNET_log_from (GNUNET_ERROR_TYPE_ERROR, | 323 | sizeof (*key)); |
347 | "block-dht", | 324 | return GNUNET_OK; |
348 | _ ("Block of type %u is malformed\n"), | 325 | } |
349 | GNUNET_BLOCK_TYPE_DHT_HELLO); | 326 | hello = block; |
350 | return GNUNET_NO; | 327 | memset (key, |
328 | 0, | ||
329 | sizeof(*key)); | ||
330 | pid = (struct GNUNET_PeerIdentity *) key; | ||
331 | if (GNUNET_OK != | ||
332 | GNUNET_HELLO_get_id (hello, | ||
333 | pid)) | ||
334 | { | ||
335 | GNUNET_break_op (0); | ||
336 | memset (key, | ||
337 | 0, | ||
338 | sizeof (*key)); | ||
339 | return GNUNET_OK; | ||
340 | } | ||
341 | return GNUNET_OK; | ||
342 | } | ||
343 | case GNUNET_BLOCK_TYPE_DHT_URL_HELLO: | ||
344 | { | ||
345 | struct GNUNET_HELLO_Builder *b; | ||
346 | struct GNUNET_PeerIdentity pid; | ||
347 | |||
348 | b = GNUNET_HELLO_builder_from_block (block, | ||
349 | block_size); | ||
350 | if (NULL == b) | ||
351 | { | ||
352 | GNUNET_break (0); | ||
353 | memset (key, | ||
354 | 0, | ||
355 | sizeof (*key)); | ||
356 | return GNUNET_OK; | ||
357 | } | ||
358 | GNUNET_HELLO_builder_iterate (b, | ||
359 | &pid, | ||
360 | NULL, NULL); | ||
361 | GNUNET_CRYPTO_hash (&pid, | ||
362 | sizeof (pid), | ||
363 | key); | ||
364 | GNUNET_HELLO_builder_free (b); | ||
365 | return GNUNET_OK; | ||
366 | } | ||
367 | default: | ||
368 | GNUNET_break (0); | ||
369 | return GNUNET_SYSERR; | ||
351 | } | 370 | } |
352 | return GNUNET_OK; | ||
353 | } | 371 | } |
354 | 372 | ||
355 | 373 | ||
@@ -361,12 +379,12 @@ libgnunet_plugin_block_dht_init (void *cls) | |||
361 | { | 379 | { |
362 | static enum GNUNET_BLOCK_Type types[] = { | 380 | static enum GNUNET_BLOCK_Type types[] = { |
363 | GNUNET_BLOCK_TYPE_DHT_HELLO, | 381 | GNUNET_BLOCK_TYPE_DHT_HELLO, |
382 | GNUNET_BLOCK_TYPE_DHT_URL_HELLO, | ||
364 | GNUNET_BLOCK_TYPE_ANY /* end of list */ | 383 | GNUNET_BLOCK_TYPE_ANY /* end of list */ |
365 | }; | 384 | }; |
366 | struct GNUNET_BLOCK_PluginFunctions *api; | 385 | struct GNUNET_BLOCK_PluginFunctions *api; |
367 | 386 | ||
368 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); | 387 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); |
369 | api->evaluate = &block_plugin_dht_evaluate; | ||
370 | api->get_key = &block_plugin_dht_get_key; | 388 | api->get_key = &block_plugin_dht_get_key; |
371 | api->check_query = &block_plugin_dht_check_query; | 389 | api->check_query = &block_plugin_dht_check_query; |
372 | api->check_block = &block_plugin_dht_check_block; | 390 | api->check_block = &block_plugin_dht_check_block; |
diff --git a/src/dht/test_dht_topo.c b/src/dht/test_dht_topo.c index eb7e80d3b..4830ba629 100644 --- a/src/dht/test_dht_topo.c +++ b/src/dht/test_dht_topo.c | |||
@@ -326,7 +326,7 @@ timeout_cb (void *cls) | |||
326 | * | 326 | * |
327 | * @param cls closure with our 'struct GetOperation' | 327 | * @param cls closure with our 'struct GetOperation' |
328 | * @param exp when will this value expire | 328 | * @param exp when will this value expire |
329 | * @param key key of the result | 329 | * @param query query hash |
330 | * @param get_path peers on reply path (or NULL if not recorded) | 330 | * @param get_path peers on reply path (or NULL if not recorded) |
331 | * @param get_path_length number of entries in @a get_path | 331 | * @param get_path_length number of entries in @a get_path |
332 | * @param put_path peers on the PUT path (or NULL if not recorded) | 332 | * @param put_path peers on the PUT path (or NULL if not recorded) |
@@ -338,7 +338,7 @@ timeout_cb (void *cls) | |||
338 | static void | 338 | static void |
339 | dht_get_handler (void *cls, | 339 | dht_get_handler (void *cls, |
340 | struct GNUNET_TIME_Absolute exp, | 340 | struct GNUNET_TIME_Absolute exp, |
341 | const struct GNUNET_HashCode *key, | 341 | const struct GNUNET_HashCode *query, |
342 | const struct GNUNET_DHT_PathElement *get_path, | 342 | const struct GNUNET_DHT_PathElement *get_path, |
343 | unsigned int get_path_length, | 343 | unsigned int get_path_length, |
344 | const struct GNUNET_DHT_PathElement *put_path, | 344 | const struct GNUNET_DHT_PathElement *put_path, |
@@ -359,8 +359,15 @@ dht_get_handler (void *cls, | |||
359 | GNUNET_break (0); | 359 | GNUNET_break (0); |
360 | return; | 360 | return; |
361 | } | 361 | } |
362 | GNUNET_CRYPTO_hash (key, | 362 | if (0 != GNUNET_memcmp (query, |
363 | sizeof(*key), | 363 | &get_op->key)) |
364 | { | ||
365 | /* exact search should only yield exact results */ | ||
366 | GNUNET_break (0); | ||
367 | return; | ||
368 | } | ||
369 | GNUNET_CRYPTO_hash (query, | ||
370 | sizeof(*query), | ||
364 | &want); | 371 | &want); |
365 | if (0 != memcmp (&want, | 372 | if (0 != memcmp (&want, |
366 | data, | 373 | data, |
@@ -370,18 +377,21 @@ dht_get_handler (void *cls, | |||
370 | return; | 377 | return; |
371 | } | 378 | } |
372 | if (0 != | 379 | if (0 != |
373 | GNUNET_DHT_verify_path (key, | 380 | GNUNET_DHT_verify_path (data, |
374 | data, | ||
375 | size, | 381 | size, |
376 | exp, | 382 | exp, |
377 | get_path, | ||
378 | get_path_length, | ||
379 | put_path, | 383 | put_path, |
380 | put_path_length, | 384 | put_path_length, |
385 | get_path, | ||
386 | get_path_length, | ||
381 | &get_op->me)) | 387 | &get_op->me)) |
382 | { | 388 | { |
389 | GNUNET_break (0); | ||
383 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | 390 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, |
384 | "Path signature verification failed!\n"); | 391 | "Path signature (%u/%u) verification failed for peer %s!\n", |
392 | get_path_length, | ||
393 | put_path_length, | ||
394 | GNUNET_i2s (&get_op->me)); | ||
385 | } | 395 | } |
386 | else | 396 | else |
387 | { | 397 | { |
diff --git a/src/dhtu/Makefile.am b/src/dhtu/Makefile.am index 0e10721cd..ebffa9ecf 100644 --- a/src/dhtu/Makefile.am +++ b/src/dhtu/Makefile.am | |||
@@ -10,6 +10,10 @@ if USE_COVERAGE | |||
10 | XLIBS = -lgcov | 10 | XLIBS = -lgcov |
11 | endif | 11 | endif |
12 | 12 | ||
13 | pkgcfg_DATA = \ | ||
14 | dhtu.conf | ||
15 | |||
16 | |||
13 | plugin_LTLIBRARIES = \ | 17 | plugin_LTLIBRARIES = \ |
14 | libgnunet_plugin_dhtu_gnunet.la \ | 18 | libgnunet_plugin_dhtu_gnunet.la \ |
15 | libgnunet_plugin_dhtu_ip.la | 19 | libgnunet_plugin_dhtu_ip.la |
@@ -67,6 +71,9 @@ test_dhtu_ip_LDADD = \ | |||
67 | check_PROGRAMS = \ | 71 | check_PROGRAMS = \ |
68 | test_dhtu_ip | 72 | test_dhtu_ip |
69 | 73 | ||
74 | EXTRA_DIST = \ | ||
75 | dhtu.conf | ||
76 | |||
70 | if ENABLE_TEST_RUN | 77 | if ENABLE_TEST_RUN |
71 | AM_TESTS_ENVIRONMENT=export GNUNET_PREFIX=$${GNUNET_PREFIX:-@libdir@};export PATH=$${GNUNET_PREFIX:-@prefix@}/bin:$$PATH;unset XDG_DATA_HOME;unset XDG_CONFIG_HOME; | 78 | AM_TESTS_ENVIRONMENT=export GNUNET_PREFIX=$${GNUNET_PREFIX:-@libdir@};export PATH=$${GNUNET_PREFIX:-@prefix@}/bin:$$PATH;unset XDG_DATA_HOME;unset XDG_CONFIG_HOME; |
72 | TESTS = \ | 79 | TESTS = \ |
diff --git a/src/dhtu/dhtu.conf b/src/dhtu/dhtu.conf new file mode 100644 index 000000000..ea5ade752 --- /dev/null +++ b/src/dhtu/dhtu.conf | |||
@@ -0,0 +1,7 @@ | |||
1 | [dhtu-gnunet] | ||
2 | ENABLED = YES | ||
3 | |||
4 | [dhtu-ip] | ||
5 | ENABLED = NO | ||
6 | NSE = 4 | ||
7 | UDP_PORT = 6666 | ||
diff --git a/src/dhtu/plugin_dhtu_gnunet.c b/src/dhtu/plugin_dhtu_gnunet.c index 2163af941..b072be2be 100644 --- a/src/dhtu/plugin_dhtu_gnunet.c +++ b/src/dhtu/plugin_dhtu_gnunet.c | |||
@@ -70,11 +70,6 @@ struct GNUNET_DHTU_Source | |||
70 | { | 70 | { |
71 | 71 | ||
72 | /** | 72 | /** |
73 | * Hash of @e pid, position of this peer in the DHT overlay. | ||
74 | */ | ||
75 | struct GNUNET_DHTU_HashKey id; | ||
76 | |||
77 | /** | ||
78 | * Application context for this source. | 73 | * Application context for this source. |
79 | */ | 74 | */ |
80 | void *app_ctx; | 75 | void *app_ctx; |
@@ -125,11 +120,6 @@ struct GNUNET_DHTU_Target | |||
125 | struct GNUNET_PeerIdentity pid; | 120 | struct GNUNET_PeerIdentity pid; |
126 | 121 | ||
127 | /** | 122 | /** |
128 | * Hash of @e pid, position of this peer in the DHT overlay. | ||
129 | */ | ||
130 | struct GNUNET_DHTU_HashKey id; | ||
131 | |||
132 | /** | ||
133 | * Preference counter, length of the @a ph_head DLL. | 123 | * Preference counter, length of the @a ph_head DLL. |
134 | */ | 124 | */ |
135 | unsigned int ph_count; | 125 | unsigned int ph_count; |
@@ -240,27 +230,26 @@ hello_offered_cb (void *cls) | |||
240 | * Request creation of a session with a peer at the given @a address. | 230 | * Request creation of a session with a peer at the given @a address. |
241 | * | 231 | * |
242 | * @param cls closure (internal context for the plugin) | 232 | * @param cls closure (internal context for the plugin) |
233 | * @param pid target identity of the peer to connect to | ||
243 | * @param address target address to connect to | 234 | * @param address target address to connect to |
244 | */ | 235 | */ |
245 | static void | 236 | static void |
246 | ip_try_connect (void *cls, | 237 | gnunet_try_connect (void *cls, |
247 | const char *address) | 238 | const struct GNUNET_PeerIdentity *pid, |
239 | const char *address) | ||
248 | { | 240 | { |
249 | struct Plugin *plugin = cls; | 241 | struct Plugin *plugin = cls; |
250 | struct GNUNET_HELLO_Message *hello = NULL; | 242 | struct GNUNET_HELLO_Message *hello = NULL; |
251 | struct HelloHandle *hh; | 243 | struct HelloHandle *hh; |
252 | struct GNUNET_CRYPTO_EddsaPublicKey pubkey; | 244 | struct GNUNET_CRYPTO_EddsaPublicKey pubkey; |
253 | 245 | ||
246 | (void) pid; /* will be needed with future address URIs */ | ||
254 | if (GNUNET_OK != | 247 | if (GNUNET_OK != |
255 | GNUNET_HELLO_parse_uri (address, | 248 | GNUNET_HELLO_parse_uri (address, |
256 | &pubkey, | 249 | &pubkey, |
257 | &hello, | 250 | &hello, |
258 | &GPI_plugins_find)) | 251 | &GPI_plugins_find)) |
259 | { | ||
260 | GNUNET_break (0); | ||
261 | return; | 252 | return; |
262 | } | ||
263 | |||
264 | hh = GNUNET_new (struct HelloHandle); | 253 | hh = GNUNET_new (struct HelloHandle); |
265 | hh->plugin = plugin; | 254 | hh->plugin = plugin; |
266 | GNUNET_CONTAINER_DLL_insert (plugin->hh_head, | 255 | GNUNET_CONTAINER_DLL_insert (plugin->hh_head, |
@@ -283,8 +272,8 @@ ip_try_connect (void *cls, | |||
283 | * @param target connection to keep alive | 272 | * @param target connection to keep alive |
284 | */ | 273 | */ |
285 | static struct GNUNET_DHTU_PreferenceHandle * | 274 | static struct GNUNET_DHTU_PreferenceHandle * |
286 | ip_hold (void *cls, | 275 | gnunet_hold (void *cls, |
287 | struct GNUNET_DHTU_Target *target) | 276 | struct GNUNET_DHTU_Target *target) |
288 | { | 277 | { |
289 | struct Plugin *plugin = cls; | 278 | struct Plugin *plugin = cls; |
290 | struct GNUNET_DHTU_PreferenceHandle *ph; | 279 | struct GNUNET_DHTU_PreferenceHandle *ph; |
@@ -312,7 +301,7 @@ ip_hold (void *cls, | |||
312 | * @param target connection to keep alive | 301 | * @param target connection to keep alive |
313 | */ | 302 | */ |
314 | static void | 303 | static void |
315 | ip_drop (struct GNUNET_DHTU_PreferenceHandle *ph) | 304 | gnunet_drop (struct GNUNET_DHTU_PreferenceHandle *ph) |
316 | { | 305 | { |
317 | struct GNUNET_DHTU_Target *target = ph->target; | 306 | struct GNUNET_DHTU_Target *target = ph->target; |
318 | struct Plugin *plugin = target->plugin; | 307 | struct Plugin *plugin = target->plugin; |
@@ -350,12 +339,12 @@ ip_drop (struct GNUNET_DHTU_PreferenceHandle *ph) | |||
350 | * @param finished_cb_cls closure for @a finished_cb | 339 | * @param finished_cb_cls closure for @a finished_cb |
351 | */ | 340 | */ |
352 | static void | 341 | static void |
353 | ip_send (void *cls, | 342 | gnunet_send (void *cls, |
354 | struct GNUNET_DHTU_Target *target, | 343 | struct GNUNET_DHTU_Target *target, |
355 | const void *msg, | 344 | const void *msg, |
356 | size_t msg_size, | 345 | size_t msg_size, |
357 | GNUNET_SCHEDULER_TaskCallback finished_cb, | 346 | GNUNET_SCHEDULER_TaskCallback finished_cb, |
358 | void *finished_cb_cls) | 347 | void *finished_cb_cls) |
359 | { | 348 | { |
360 | struct GNUNET_MQ_Envelope *env; | 349 | struct GNUNET_MQ_Envelope *env; |
361 | struct GNUNET_MessageHeader *cmsg; | 350 | struct GNUNET_MessageHeader *cmsg; |
@@ -394,12 +383,9 @@ core_connect_cb (void *cls, | |||
394 | target->plugin = plugin; | 383 | target->plugin = plugin; |
395 | target->mq = mq; | 384 | target->mq = mq; |
396 | target->pid = *peer; | 385 | target->pid = *peer; |
397 | GNUNET_CRYPTO_hash (peer, | ||
398 | sizeof (*peer), | ||
399 | &target->id.sha512); | ||
400 | plugin->env->connect_cb (plugin->env->cls, | 386 | plugin->env->connect_cb (plugin->env->cls, |
401 | target, | 387 | target, |
402 | &target->id, | 388 | &target->pid, |
403 | &target->app_ctx); | 389 | &target->app_ctx); |
404 | return target; | 390 | return target; |
405 | } | 391 | } |
@@ -461,11 +447,7 @@ peerinfo_cb (void *cls, | |||
461 | &GPI_plugins_find); | 447 | &GPI_plugins_find); |
462 | if (NULL == addr) | 448 | if (NULL == addr) |
463 | return; | 449 | return; |
464 | GNUNET_CRYPTO_hash (peer, | ||
465 | sizeof (*peer), | ||
466 | &plugin->src.id.sha512); | ||
467 | plugin->env->address_add_cb (plugin->env->cls, | 450 | plugin->env->address_add_cb (plugin->env->cls, |
468 | &plugin->src.id, | ||
469 | addr, | 451 | addr, |
470 | &plugin->src, | 452 | &plugin->src, |
471 | &plugin->src.app_ctx); | 453 | &plugin->src.app_ctx); |
@@ -584,6 +566,10 @@ libgnunet_plugin_dhtu_gnunet_done (void *cls) | |||
584 | } | 566 | } |
585 | if (NULL != plugin->nse) | 567 | if (NULL != plugin->nse) |
586 | GNUNET_NSE_disconnect (plugin->nse); | 568 | GNUNET_NSE_disconnect (plugin->nse); |
569 | plugin->env->network_size_cb (plugin->env->cls, | ||
570 | GNUNET_TIME_UNIT_FOREVER_ABS, | ||
571 | 0.0, | ||
572 | 0.0); | ||
587 | if (NULL != plugin->core) | 573 | if (NULL != plugin->core) |
588 | GNUNET_CORE_disconnect (plugin->core); | 574 | GNUNET_CORE_disconnect (plugin->core); |
589 | if (NULL != plugin->ats) | 575 | if (NULL != plugin->ats) |
@@ -604,7 +590,7 @@ libgnunet_plugin_dhtu_gnunet_done (void *cls) | |||
604 | * @return the plugin's API | 590 | * @return the plugin's API |
605 | */ | 591 | */ |
606 | void * | 592 | void * |
607 | libgnunet_plugin_dhtu_ip_init (void *cls) | 593 | libgnunet_plugin_dhtu_gnunet_init (void *cls) |
608 | { | 594 | { |
609 | struct GNUNET_DHTU_PluginEnvironment *env = cls; | 595 | struct GNUNET_DHTU_PluginEnvironment *env = cls; |
610 | struct GNUNET_DHTU_PluginFunctions *api; | 596 | struct GNUNET_DHTU_PluginFunctions *api; |
@@ -621,10 +607,10 @@ libgnunet_plugin_dhtu_ip_init (void *cls) | |||
621 | plugin->env = env; | 607 | plugin->env = env; |
622 | api = GNUNET_new (struct GNUNET_DHTU_PluginFunctions); | 608 | api = GNUNET_new (struct GNUNET_DHTU_PluginFunctions); |
623 | api->cls = plugin; | 609 | api->cls = plugin; |
624 | api->try_connect = &ip_try_connect; | 610 | api->try_connect = &gnunet_try_connect; |
625 | api->hold = &ip_hold; | 611 | api->hold = &gnunet_hold; |
626 | api->drop = &ip_drop; | 612 | api->drop = &gnunet_drop; |
627 | api->send = &ip_send; | 613 | api->send = &gnunet_send; |
628 | plugin->ats = GNUNET_ATS_connectivity_init (env->cfg); | 614 | plugin->ats = GNUNET_ATS_connectivity_init (env->cfg); |
629 | plugin->core = GNUNET_CORE_connect (env->cfg, | 615 | plugin->core = GNUNET_CORE_connect (env->cfg, |
630 | plugin, | 616 | plugin, |
@@ -640,6 +626,7 @@ libgnunet_plugin_dhtu_ip_init (void *cls) | |||
640 | (NULL == plugin->nse) ) | 626 | (NULL == plugin->nse) ) |
641 | { | 627 | { |
642 | GNUNET_break (0); | 628 | GNUNET_break (0); |
629 | GNUNET_free (api); | ||
643 | libgnunet_plugin_dhtu_gnunet_done (plugin); | 630 | libgnunet_plugin_dhtu_gnunet_done (plugin); |
644 | return NULL; | 631 | return NULL; |
645 | } | 632 | } |
diff --git a/src/dhtu/plugin_dhtu_ip.c b/src/dhtu/plugin_dhtu_ip.c index 8eec6294b..612d2c119 100644 --- a/src/dhtu/plugin_dhtu_ip.c +++ b/src/dhtu/plugin_dhtu_ip.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet | 2 | This file is part of GNUnet |
3 | Copyright (C) 2021 GNUnet e.V. | 3 | Copyright (C) 2021, 2022 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 |
@@ -56,17 +56,12 @@ struct GNUNET_DHTU_Source | |||
56 | struct GNUNET_DHTU_Source *prev; | 56 | struct GNUNET_DHTU_Source *prev; |
57 | 57 | ||
58 | /** | 58 | /** |
59 | * Position of this peer in the DHT. | ||
60 | */ | ||
61 | struct GNUNET_DHTU_HashKey id; | ||
62 | |||
63 | /** | ||
64 | * Application context for this source. | 59 | * Application context for this source. |
65 | */ | 60 | */ |
66 | void *app_ctx; | 61 | void *app_ctx; |
67 | 62 | ||
68 | /** | 63 | /** |
69 | * Address in URL form ("ip+udp://$IP:$PORT") | 64 | * Address in URL form ("ip+udp://$PID/$IP:$PORT") |
70 | */ | 65 | */ |
71 | char *address; | 66 | char *address; |
72 | 67 | ||
@@ -121,9 +116,9 @@ struct GNUNET_DHTU_Target | |||
121 | struct GNUNET_DHTU_PreferenceHandle *ph_tail; | 116 | struct GNUNET_DHTU_PreferenceHandle *ph_tail; |
122 | 117 | ||
123 | /** | 118 | /** |
124 | * Position of this peer in the DHT. | 119 | * Peer's identity. |
125 | */ | 120 | */ |
126 | struct GNUNET_DHTU_HashKey id; | 121 | struct GNUNET_PeerIdentity pid; |
127 | 122 | ||
128 | /** | 123 | /** |
129 | * Target IP address. | 124 | * Target IP address. |
@@ -217,14 +212,24 @@ struct Plugin | |||
217 | char *port; | 212 | char *port; |
218 | 213 | ||
219 | /** | 214 | /** |
215 | * My UDP socket. | ||
216 | */ | ||
217 | struct GNUNET_NETWORK_Handle *sock; | ||
218 | |||
219 | /** | ||
220 | * My identity. | ||
221 | */ | ||
222 | struct GNUNET_PeerIdentity my_id; | ||
223 | |||
224 | /** | ||
220 | * How often have we scanned for IPs? | 225 | * How often have we scanned for IPs? |
221 | */ | 226 | */ |
222 | unsigned int scan_generation; | 227 | unsigned int scan_generation; |
223 | 228 | ||
224 | /** | 229 | /** |
225 | * My UDP socket. | 230 | * Port as a 16-bit value. |
226 | */ | 231 | */ |
227 | struct GNUNET_NETWORK_Handle *sock; | 232 | uint16_t port16; |
228 | }; | 233 | }; |
229 | 234 | ||
230 | 235 | ||
@@ -232,18 +237,20 @@ struct Plugin | |||
232 | * Create a target to which we may send traffic. | 237 | * Create a target to which we may send traffic. |
233 | * | 238 | * |
234 | * @param plugin our plugin | 239 | * @param plugin our plugin |
240 | * @param pid presumed identity of the target | ||
235 | * @param addr target address | 241 | * @param addr target address |
236 | * @param addrlen number of bytes in @a addr | 242 | * @param addrlen number of bytes in @a addr |
237 | * @return new target object | 243 | * @return new target object |
238 | */ | 244 | */ |
239 | static struct GNUNET_DHTU_Target * | 245 | static struct GNUNET_DHTU_Target * |
240 | create_target (struct Plugin *plugin, | 246 | create_target (struct Plugin *plugin, |
247 | const struct GNUNET_PeerIdentity *pid, | ||
241 | const struct sockaddr *addr, | 248 | const struct sockaddr *addr, |
242 | socklen_t addrlen) | 249 | socklen_t addrlen) |
243 | { | 250 | { |
244 | struct GNUNET_DHTU_Target *dst; | 251 | struct GNUNET_DHTU_Target *dst; |
245 | 252 | ||
246 | if (MAX_DESTS > | 253 | if (MAX_DESTS <= |
247 | GNUNET_CONTAINER_multihashmap_size (plugin->dsts)) | 254 | GNUNET_CONTAINER_multihashmap_size (plugin->dsts)) |
248 | { | 255 | { |
249 | struct GNUNET_HashCode key; | 256 | struct GNUNET_HashCode key; |
@@ -275,42 +282,16 @@ create_target (struct Plugin *plugin, | |||
275 | } | 282 | } |
276 | dst = GNUNET_new (struct GNUNET_DHTU_Target); | 283 | dst = GNUNET_new (struct GNUNET_DHTU_Target); |
277 | dst->addrlen = addrlen; | 284 | dst->addrlen = addrlen; |
285 | dst->pid = *pid; | ||
278 | memcpy (&dst->addr, | 286 | memcpy (&dst->addr, |
279 | addr, | 287 | addr, |
280 | addrlen); | 288 | addrlen); |
281 | switch (addr->sa_family) | ||
282 | { | ||
283 | case AF_INET: | ||
284 | { | ||
285 | const struct sockaddr_in *s4 = (const struct sockaddr_in *) addr; | ||
286 | |||
287 | GNUNET_assert (sizeof (struct sockaddr_in) == addrlen); | ||
288 | GNUNET_CRYPTO_hash (&s4->sin_addr, | ||
289 | sizeof (struct in_addr), | ||
290 | &dst->id.sha512); | ||
291 | } | ||
292 | break; | ||
293 | case AF_INET6: | ||
294 | { | ||
295 | const struct sockaddr_in6 *s6 = (const struct sockaddr_in6 *) addr; | ||
296 | |||
297 | GNUNET_assert (sizeof (struct sockaddr_in6) == addrlen); | ||
298 | GNUNET_CRYPTO_hash (&s6->sin6_addr, | ||
299 | sizeof (struct in6_addr), | ||
300 | &dst->id.sha512); | ||
301 | } | ||
302 | break; | ||
303 | default: | ||
304 | GNUNET_break (0); | ||
305 | GNUNET_free (dst); | ||
306 | return NULL; | ||
307 | } | ||
308 | GNUNET_CONTAINER_DLL_insert (plugin->dst_head, | 289 | GNUNET_CONTAINER_DLL_insert (plugin->dst_head, |
309 | plugin->dst_tail, | 290 | plugin->dst_tail, |
310 | dst); | 291 | dst); |
311 | plugin->env->connect_cb (plugin->env->cls, | 292 | plugin->env->connect_cb (plugin->env->cls, |
312 | dst, | 293 | dst, |
313 | &dst->id, | 294 | &dst->pid, |
314 | &dst->app_ctx); | 295 | &dst->app_ctx); |
315 | return dst; | 296 | return dst; |
316 | } | 297 | } |
@@ -321,6 +302,7 @@ create_target (struct Plugin *plugin, | |||
321 | * create one! | 302 | * create one! |
322 | * | 303 | * |
323 | * @param plugin the plugin handle | 304 | * @param plugin the plugin handle |
305 | * @param pid presumed identity of the target | ||
324 | * @param src source target is from, or NULL if unknown | 306 | * @param src source target is from, or NULL if unknown |
325 | * @param addr socket address to find | 307 | * @param addr socket address to find |
326 | * @param addrlen number of bytes in @a addr | 308 | * @param addrlen number of bytes in @a addr |
@@ -328,6 +310,7 @@ create_target (struct Plugin *plugin, | |||
328 | */ | 310 | */ |
329 | static struct GNUNET_DHTU_Target * | 311 | static struct GNUNET_DHTU_Target * |
330 | find_target (struct Plugin *plugin, | 312 | find_target (struct Plugin *plugin, |
313 | const struct GNUNET_PeerIdentity *pid, | ||
331 | const void *addr, | 314 | const void *addr, |
332 | size_t addrlen) | 315 | size_t addrlen) |
333 | { | 316 | { |
@@ -342,6 +325,7 @@ find_target (struct Plugin *plugin, | |||
342 | if (NULL == dst) | 325 | if (NULL == dst) |
343 | { | 326 | { |
344 | dst = create_target (plugin, | 327 | dst = create_target (plugin, |
328 | pid, | ||
345 | (const struct sockaddr *) addr, | 329 | (const struct sockaddr *) addr, |
346 | addrlen); | 330 | addrlen); |
347 | GNUNET_assert (GNUNET_YES == | 331 | GNUNET_assert (GNUNET_YES == |
@@ -370,10 +354,12 @@ find_target (struct Plugin *plugin, | |||
370 | * Request creation of a session with a peer at the given @a address. | 354 | * Request creation of a session with a peer at the given @a address. |
371 | * | 355 | * |
372 | * @param cls closure (internal context for the plugin) | 356 | * @param cls closure (internal context for the plugin) |
357 | * @param pid identity of the target peer | ||
373 | * @param address target address to connect to | 358 | * @param address target address to connect to |
374 | */ | 359 | */ |
375 | static void | 360 | static void |
376 | ip_try_connect (void *cls, | 361 | ip_try_connect (void *cls, |
362 | const struct GNUNET_PeerIdentity *pid, | ||
377 | const char *address) | 363 | const char *address) |
378 | { | 364 | { |
379 | struct Plugin *plugin = cls; | 365 | struct Plugin *plugin = cls; |
@@ -389,19 +375,13 @@ ip_try_connect (void *cls, | |||
389 | strncmp (address, | 375 | strncmp (address, |
390 | "ip+", | 376 | "ip+", |
391 | strlen ("ip+"))) | 377 | strlen ("ip+"))) |
392 | { | ||
393 | GNUNET_break (0); | ||
394 | return; | 378 | return; |
395 | } | ||
396 | address += strlen ("ip+"); | 379 | address += strlen ("ip+"); |
397 | if (0 != | 380 | if (0 != |
398 | strncmp (address, | 381 | strncmp (address, |
399 | "udp://", | 382 | "udp://", |
400 | strlen ("udp://"))) | 383 | strlen ("udp://"))) |
401 | { | ||
402 | GNUNET_break (0); | ||
403 | return; | 384 | return; |
404 | } | ||
405 | address += strlen ("udp://"); | 385 | address += strlen ("udp://"); |
406 | addr = GNUNET_strdup (address); | 386 | addr = GNUNET_strdup (address); |
407 | colon = strchr (addr, ':'); | 387 | colon = strchr (addr, ':'); |
@@ -426,6 +406,7 @@ ip_try_connect (void *cls, | |||
426 | } | 406 | } |
427 | GNUNET_free (addr); | 407 | GNUNET_free (addr); |
428 | (void) find_target (plugin, | 408 | (void) find_target (plugin, |
409 | pid, | ||
429 | result->ai_addr, | 410 | result->ai_addr, |
430 | result->ai_addrlen); | 411 | result->ai_addrlen); |
431 | freeaddrinfo (result); | 412 | freeaddrinfo (result); |
@@ -499,10 +480,17 @@ ip_send (void *cls, | |||
499 | void *finished_cb_cls) | 480 | void *finished_cb_cls) |
500 | { | 481 | { |
501 | struct Plugin *plugin = cls; | 482 | struct Plugin *plugin = cls; |
502 | 483 | char buf[sizeof (plugin->my_id) + msg_size]; | |
484 | |||
485 | memcpy (buf, | ||
486 | &plugin->my_id, | ||
487 | sizeof (plugin->my_id)); | ||
488 | memcpy (&buf[sizeof (plugin->my_id)], | ||
489 | msg, | ||
490 | msg_size); | ||
503 | GNUNET_NETWORK_socket_sendto (plugin->sock, | 491 | GNUNET_NETWORK_socket_sendto (plugin->sock, |
504 | msg, | 492 | buf, |
505 | msg_size, | 493 | sizeof (buf), |
506 | (const struct sockaddr *) &target->addr, | 494 | (const struct sockaddr *) &target->addr, |
507 | target->addrlen); | 495 | target->addrlen); |
508 | finished_cb (finished_cb_cls); | 496 | finished_cb (finished_cb_cls); |
@@ -538,9 +526,6 @@ create_source (struct Plugin *plugin, | |||
538 | char buf[INET_ADDRSTRLEN]; | 526 | char buf[INET_ADDRSTRLEN]; |
539 | 527 | ||
540 | GNUNET_assert (sizeof (struct sockaddr_in) == addrlen); | 528 | GNUNET_assert (sizeof (struct sockaddr_in) == addrlen); |
541 | GNUNET_CRYPTO_hash (&s4->sin_addr, | ||
542 | sizeof (struct in_addr), | ||
543 | &src->id.sha512); | ||
544 | GNUNET_asprintf (&src->address, | 529 | GNUNET_asprintf (&src->address, |
545 | "ip+udp://%s:%u", | 530 | "ip+udp://%s:%u", |
546 | inet_ntop (AF_INET, | 531 | inet_ntop (AF_INET, |
@@ -556,9 +541,6 @@ create_source (struct Plugin *plugin, | |||
556 | char buf[INET6_ADDRSTRLEN]; | 541 | char buf[INET6_ADDRSTRLEN]; |
557 | 542 | ||
558 | GNUNET_assert (sizeof (struct sockaddr_in6) == addrlen); | 543 | GNUNET_assert (sizeof (struct sockaddr_in6) == addrlen); |
559 | GNUNET_CRYPTO_hash (&s6->sin6_addr, | ||
560 | sizeof (struct in6_addr), | ||
561 | &src->id.sha512); | ||
562 | GNUNET_asprintf (&src->address, | 544 | GNUNET_asprintf (&src->address, |
563 | "ip+udp://[%s]:%u", | 545 | "ip+udp://[%s]:%u", |
564 | inet_ntop (AF_INET6, | 546 | inet_ntop (AF_INET6, |
@@ -577,7 +559,6 @@ create_source (struct Plugin *plugin, | |||
577 | plugin->src_tail, | 559 | plugin->src_tail, |
578 | src); | 560 | src); |
579 | plugin->env->address_add_cb (plugin->env->cls, | 561 | plugin->env->address_add_cb (plugin->env->cls, |
580 | &src->id, | ||
581 | src->address, | 562 | src->address, |
582 | src, | 563 | src, |
583 | &src->app_ctx); | 564 | &src->app_ctx); |
@@ -586,6 +567,101 @@ create_source (struct Plugin *plugin, | |||
586 | 567 | ||
587 | 568 | ||
588 | /** | 569 | /** |
570 | * Compare two addresses excluding the ports for equality. Only compares IP | ||
571 | * address. Must only be called on AF_INET or AF_INET6 addresses. | ||
572 | * | ||
573 | * @param a1 address to compare | ||
574 | * @param a2 address to compare | ||
575 | * @param alen number of bytes in @a a1 and @a a2 | ||
576 | * @return 0 if @a a1 == @a a2. | ||
577 | */ | ||
578 | static int | ||
579 | addrcmp_np (const struct sockaddr *a1, | ||
580 | const struct sockaddr *a2, | ||
581 | size_t alen) | ||
582 | { | ||
583 | GNUNET_assert (a1->sa_family == a2->sa_family); | ||
584 | switch (a1->sa_family) | ||
585 | { | ||
586 | case AF_INET: | ||
587 | GNUNET_assert (sizeof (struct sockaddr_in) == alen); | ||
588 | { | ||
589 | const struct sockaddr_in *s1 = (const struct sockaddr_in *) a1; | ||
590 | const struct sockaddr_in *s2 = (const struct sockaddr_in *) a2; | ||
591 | |||
592 | if (s1->sin_addr.s_addr != s2->sin_addr.s_addr) | ||
593 | return 1; | ||
594 | break; | ||
595 | } | ||
596 | case AF_INET6: | ||
597 | GNUNET_assert (sizeof (struct sockaddr_in6) == alen); | ||
598 | { | ||
599 | const struct sockaddr_in6 *s1 = (const struct sockaddr_in6 *) a1; | ||
600 | const struct sockaddr_in6 *s2 = (const struct sockaddr_in6 *) a2; | ||
601 | |||
602 | if (0 != GNUNET_memcmp (&s1->sin6_addr, | ||
603 | &s2->sin6_addr)) | ||
604 | return 1; | ||
605 | break; | ||
606 | } | ||
607 | default: | ||
608 | GNUNET_assert (0); | ||
609 | } | ||
610 | return 0; | ||
611 | } | ||
612 | |||
613 | |||
614 | /** | ||
615 | * Compare two addresses for equality. Only | ||
616 | * compares IP address and port. Must only be | ||
617 | * called on AF_INET or AF_INET6 addresses. | ||
618 | * | ||
619 | * @param a1 address to compare | ||
620 | * @param a2 address to compare | ||
621 | * @param alen number of bytes in @a a1 and @a a2 | ||
622 | * @return 0 if @a a1 == @a a2. | ||
623 | */ | ||
624 | static int | ||
625 | addrcmp (const struct sockaddr *a1, | ||
626 | const struct sockaddr *a2, | ||
627 | size_t alen) | ||
628 | { | ||
629 | GNUNET_assert (a1->sa_family == a2->sa_family); | ||
630 | switch (a1->sa_family) | ||
631 | { | ||
632 | case AF_INET: | ||
633 | GNUNET_assert (sizeof (struct sockaddr_in) == alen); | ||
634 | { | ||
635 | const struct sockaddr_in *s1 = (const struct sockaddr_in *) a1; | ||
636 | const struct sockaddr_in *s2 = (const struct sockaddr_in *) a2; | ||
637 | |||
638 | if (s1->sin_port != s2->sin_port) | ||
639 | return 1; | ||
640 | if (s1->sin_addr.s_addr != s2->sin_addr.s_addr) | ||
641 | return 1; | ||
642 | break; | ||
643 | } | ||
644 | case AF_INET6: | ||
645 | GNUNET_assert (sizeof (struct sockaddr_in6) == alen); | ||
646 | { | ||
647 | const struct sockaddr_in6 *s1 = (const struct sockaddr_in6 *) a1; | ||
648 | const struct sockaddr_in6 *s2 = (const struct sockaddr_in6 *) a2; | ||
649 | |||
650 | if (s1->sin6_port != s2->sin6_port) | ||
651 | return 1; | ||
652 | if (0 != GNUNET_memcmp (&s1->sin6_addr, | ||
653 | &s2->sin6_addr)) | ||
654 | return 1; | ||
655 | break; | ||
656 | } | ||
657 | default: | ||
658 | GNUNET_assert (0); | ||
659 | } | ||
660 | return 0; | ||
661 | } | ||
662 | |||
663 | |||
664 | /** | ||
589 | * Callback function invoked for each interface found. | 665 | * Callback function invoked for each interface found. |
590 | * | 666 | * |
591 | * @param cls closure | 667 | * @param cls closure |
@@ -597,7 +673,7 @@ create_source (struct Plugin *plugin, | |||
597 | * @param addrlen length of the address | 673 | * @param addrlen length of the address |
598 | * @return #GNUNET_OK to continue iteration, #GNUNET_SYSERR to abort | 674 | * @return #GNUNET_OK to continue iteration, #GNUNET_SYSERR to abort |
599 | */ | 675 | */ |
600 | static int | 676 | static enum GNUNET_GenericReturnValue |
601 | process_ifcs (void *cls, | 677 | process_ifcs (void *cls, |
602 | const char *name, | 678 | const char *name, |
603 | int isDefault, | 679 | int isDefault, |
@@ -614,17 +690,45 @@ process_ifcs (void *cls, | |||
614 | src = src->next) | 690 | src = src->next) |
615 | { | 691 | { |
616 | if ( (addrlen == src->addrlen) && | 692 | if ( (addrlen == src->addrlen) && |
617 | (0 == memcmp (addr, | 693 | (0 == addrcmp_np (addr, |
618 | &src->addr, | 694 | (const struct sockaddr *) &src->addr, |
619 | addrlen)) ) | 695 | addrlen)) ) |
620 | { | 696 | { |
621 | src->scan_generation = plugin->scan_generation; | 697 | src->scan_generation = plugin->scan_generation; |
622 | return GNUNET_OK; | 698 | return GNUNET_OK; |
623 | } | 699 | } |
624 | } | 700 | } |
625 | (void) create_source (plugin, | 701 | switch (addr->sa_family) |
626 | addr, | 702 | { |
627 | addrlen); | 703 | case AF_INET: |
704 | { | ||
705 | struct sockaddr_in v4; | ||
706 | |||
707 | GNUNET_assert (sizeof(v4) == addrlen); | ||
708 | memcpy (&v4, | ||
709 | addr, | ||
710 | addrlen); | ||
711 | v4.sin_port = htons (plugin->port16); | ||
712 | (void) create_source (plugin, | ||
713 | (const struct sockaddr *) &v4, | ||
714 | sizeof (v4)); | ||
715 | break; | ||
716 | } | ||
717 | case AF_INET6: | ||
718 | { | ||
719 | struct sockaddr_in6 v6; | ||
720 | |||
721 | GNUNET_assert (sizeof(v6) == addrlen); | ||
722 | memcpy (&v6, | ||
723 | addr, | ||
724 | addrlen); | ||
725 | v6.sin6_port = htons (plugin->port16); | ||
726 | (void) create_source (plugin, | ||
727 | (const struct sockaddr *) &v6, | ||
728 | sizeof (v6)); | ||
729 | break; | ||
730 | } | ||
731 | } | ||
628 | return GNUNET_OK; | 732 | return GNUNET_OK; |
629 | } | 733 | } |
630 | 734 | ||
@@ -648,7 +752,7 @@ scan (void *cls) | |||
648 | src = next) | 752 | src = next) |
649 | { | 753 | { |
650 | next = src->next; | 754 | next = src->next; |
651 | if (src->scan_generation == plugin->scan_generation) | 755 | if (src->scan_generation >= plugin->scan_generation) |
652 | continue; | 756 | continue; |
653 | GNUNET_CONTAINER_DLL_remove (plugin->src_head, | 757 | GNUNET_CONTAINER_DLL_remove (plugin->src_head, |
654 | plugin->src_tail, | 758 | plugin->src_tail, |
@@ -682,9 +786,9 @@ find_source (struct Plugin *plugin, | |||
682 | src = src->next) | 786 | src = src->next) |
683 | { | 787 | { |
684 | if ( (addrlen == src->addrlen) && | 788 | if ( (addrlen == src->addrlen) && |
685 | (0 == memcmp (addr, | 789 | (0 == addrcmp (addr, |
686 | &src->addr, | 790 | (const struct sockaddr *) &src->addr, |
687 | addrlen)) ) | 791 | addrlen)) ) |
688 | return src; | 792 | return src; |
689 | } | 793 | } |
690 | 794 | ||
@@ -704,7 +808,8 @@ read_cb (void *cls) | |||
704 | { | 808 | { |
705 | struct Plugin *plugin = cls; | 809 | struct Plugin *plugin = cls; |
706 | ssize_t ret; | 810 | ssize_t ret; |
707 | char buf[65536]; | 811 | const struct GNUNET_PeerIdentity *pid; |
812 | char buf[65536] GNUNET_ALIGN; | ||
708 | struct sockaddr_storage sa; | 813 | struct sockaddr_storage sa; |
709 | struct iovec iov = { | 814 | struct iovec iov = { |
710 | .iov_base = buf, | 815 | .iov_base = buf, |
@@ -719,98 +824,120 @@ read_cb (void *cls) | |||
719 | .msg_control = ctl, | 824 | .msg_control = ctl, |
720 | .msg_controllen = sizeof (ctl) | 825 | .msg_controllen = sizeof (ctl) |
721 | }; | 826 | }; |
827 | struct GNUNET_DHTU_Target *dst = NULL; | ||
828 | struct GNUNET_DHTU_Source *src = NULL; | ||
722 | 829 | ||
723 | ret = recvmsg (GNUNET_NETWORK_get_fd (plugin->sock), | 830 | ret = recvmsg (GNUNET_NETWORK_get_fd (plugin->sock), |
724 | &mh, | 831 | &mh, |
725 | MSG_DONTWAIT); | 832 | MSG_DONTWAIT); |
726 | if (ret >= 0) | 833 | plugin->read_task = GNUNET_SCHEDULER_add_read_net ( |
834 | GNUNET_TIME_UNIT_FOREVER_REL, | ||
835 | plugin->sock, | ||
836 | &read_cb, | ||
837 | plugin); | ||
838 | if (ret < 0) | ||
839 | return; /* read failure, hopefully EAGAIN */ | ||
840 | if (ret < sizeof (*pid)) | ||
841 | { | ||
842 | GNUNET_break_op (0); | ||
843 | return; | ||
844 | } | ||
845 | /* find IP where we received message */ | ||
846 | for (struct cmsghdr *cmsg = CMSG_FIRSTHDR (&mh); | ||
847 | NULL != cmsg; | ||
848 | cmsg = CMSG_NXTHDR (&mh, | ||
849 | cmsg)) | ||
727 | { | 850 | { |
728 | struct GNUNET_DHTU_Target *dst = NULL; | 851 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, |
729 | struct GNUNET_DHTU_Source *src = NULL; | 852 | "Got CMSG level %u (%d/%d), type %u (%d/%d)\n", |
730 | struct cmsghdr *cmsg; | 853 | cmsg->cmsg_level, |
731 | 854 | (cmsg->cmsg_level == IPPROTO_IP), | |
732 | /* find IP where we received message */ | 855 | (cmsg->cmsg_level == IPPROTO_IPV6), |
733 | for (cmsg = CMSG_FIRSTHDR (&mh); | 856 | cmsg->cmsg_type, |
734 | NULL != cmsg; | 857 | (cmsg->cmsg_type == IP_PKTINFO), |
735 | cmsg = CMSG_NXTHDR (&mh, | 858 | (cmsg->cmsg_type == IPV6_PKTINFO)); |
736 | cmsg)) | 859 | if ( (cmsg->cmsg_level == IPPROTO_IP) && |
860 | (cmsg->cmsg_type == IP_PKTINFO) ) | ||
737 | { | 861 | { |
738 | if ( (cmsg->cmsg_level == IPPROTO_IP) && | 862 | if (CMSG_LEN (sizeof (struct in_pktinfo)) == |
739 | (cmsg->cmsg_type == IP_PKTINFO) ) | 863 | cmsg->cmsg_len) |
740 | { | 864 | { |
741 | if (CMSG_LEN (sizeof (struct in_pktinfo)) == | 865 | struct in_pktinfo pi; |
742 | cmsg->cmsg_len) | 866 | |
867 | memcpy (&pi, | ||
868 | CMSG_DATA (cmsg), | ||
869 | sizeof (pi)); | ||
743 | { | 870 | { |
744 | struct in_pktinfo pi; | 871 | struct sockaddr_in sa = { |
745 | 872 | .sin_family = AF_INET, | |
746 | memcpy (&pi, | 873 | .sin_addr = pi.ipi_addr, |
747 | CMSG_DATA (cmsg), | 874 | .sin_port = htons (plugin->port16) |
748 | sizeof (pi)); | 875 | }; |
749 | { | 876 | |
750 | struct sockaddr_in sa = { | 877 | src = find_source (plugin, |
751 | .sin_family = AF_INET, | 878 | &sa, |
752 | .sin_addr = pi.ipi_addr | 879 | sizeof (sa)); |
753 | }; | 880 | /* For sources we discovered by reading, |
754 | 881 | force the generation far into the future */ | |
755 | src = find_source (plugin, | 882 | src->scan_generation = plugin->scan_generation + 60; |
756 | &sa, | ||
757 | sizeof (sa)); | ||
758 | } | ||
759 | break; | ||
760 | } | 883 | } |
761 | else | 884 | break; |
762 | GNUNET_break (0); | ||
763 | } | 885 | } |
764 | if ( (cmsg->cmsg_level == IPPROTO_IPV6) && | 886 | else |
765 | (cmsg->cmsg_type == IPV6_RECVPKTINFO) ) | 887 | GNUNET_break (0); |
888 | } | ||
889 | if ( (cmsg->cmsg_level == IPPROTO_IPV6) && | ||
890 | (cmsg->cmsg_type == IPV6_PKTINFO) ) | ||
891 | { | ||
892 | if (CMSG_LEN (sizeof (struct in6_pktinfo)) == | ||
893 | cmsg->cmsg_len) | ||
766 | { | 894 | { |
767 | if (CMSG_LEN (sizeof (struct in6_pktinfo)) == | 895 | struct in6_pktinfo pi; |
768 | cmsg->cmsg_len) | 896 | |
897 | memcpy (&pi, | ||
898 | CMSG_DATA (cmsg), | ||
899 | sizeof (pi)); | ||
769 | { | 900 | { |
770 | struct in6_pktinfo pi; | 901 | struct sockaddr_in6 sa = { |
771 | 902 | .sin6_family = AF_INET6, | |
772 | memcpy (&pi, | 903 | .sin6_addr = pi.ipi6_addr, |
773 | CMSG_DATA (cmsg), | 904 | .sin6_port = htons (plugin->port16), |
774 | sizeof (pi)); | 905 | .sin6_scope_id = pi.ipi6_ifindex |
775 | { | 906 | }; |
776 | struct sockaddr_in6 sa = { | 907 | |
777 | .sin6_family = AF_INET6, | 908 | src = find_source (plugin, |
778 | .sin6_addr = pi.ipi6_addr, | 909 | &sa, |
779 | .sin6_scope_id = pi.ipi6_ifindex | 910 | sizeof (sa)); |
780 | }; | 911 | /* For sources we discovered by reading, |
781 | 912 | force the generation far into the future */ | |
782 | src = find_source (plugin, | 913 | src->scan_generation = plugin->scan_generation + 60; |
783 | &sa, | 914 | break; |
784 | sizeof (sa)); | ||
785 | break; | ||
786 | } | ||
787 | } | 915 | } |
788 | else | ||
789 | GNUNET_break (0); | ||
790 | } | 916 | } |
791 | } | 917 | else |
792 | dst = find_target (plugin, | 918 | GNUNET_break (0); |
793 | &sa, | ||
794 | mh.msg_namelen); | ||
795 | if ( (NULL == src) || | ||
796 | (NULL == dst) ) | ||
797 | { | ||
798 | GNUNET_break (0); | ||
799 | } | ||
800 | else | ||
801 | { | ||
802 | plugin->env->receive_cb (plugin->env->cls, | ||
803 | dst->app_ctx, | ||
804 | src->app_ctx, | ||
805 | buf, | ||
806 | ret); | ||
807 | } | 919 | } |
808 | } | 920 | } |
809 | plugin->read_task = GNUNET_SCHEDULER_add_read_net ( | 921 | if (NULL == src) |
810 | GNUNET_TIME_UNIT_FOREVER_REL, | 922 | { |
811 | plugin->sock, | 923 | GNUNET_break (0); |
812 | &read_cb, | 924 | return; |
813 | plugin); | 925 | } |
926 | pid = (const struct GNUNET_PeerIdentity *) buf; | ||
927 | dst = find_target (plugin, | ||
928 | pid, | ||
929 | &sa, | ||
930 | mh.msg_namelen); | ||
931 | if (NULL == dst) | ||
932 | { | ||
933 | GNUNET_break (0); | ||
934 | return; | ||
935 | } | ||
936 | plugin->env->receive_cb (plugin->env->cls, | ||
937 | &dst->app_ctx, | ||
938 | &src->app_ctx, | ||
939 | &buf[sizeof(*pid)], | ||
940 | ret - sizeof (*pid)); | ||
814 | } | 941 | } |
815 | 942 | ||
816 | 943 | ||
@@ -874,6 +1001,14 @@ libgnunet_plugin_dhtu_ip_init (void *cls) | |||
874 | plugin = GNUNET_new (struct Plugin); | 1001 | plugin = GNUNET_new (struct Plugin); |
875 | plugin->env = env; | 1002 | plugin->env = env; |
876 | plugin->port = port; | 1003 | plugin->port = port; |
1004 | plugin->port16 = (uint16_t) nport; | ||
1005 | if (GNUNET_OK != | ||
1006 | GNUNET_CRYPTO_get_peer_identity (env->cfg, | ||
1007 | &plugin->my_id)) | ||
1008 | { | ||
1009 | GNUNET_free (plugin); | ||
1010 | return NULL; | ||
1011 | } | ||
877 | af = AF_INET6; | 1012 | af = AF_INET6; |
878 | sock = socket (af, | 1013 | sock = socket (af, |
879 | SOCK_DGRAM, | 1014 | SOCK_DGRAM, |
@@ -1017,9 +1152,18 @@ libgnunet_plugin_dhtu_ip_done (void *cls) | |||
1017 | GNUNET_free (src->address); | 1152 | GNUNET_free (src->address); |
1018 | GNUNET_free (src); | 1153 | GNUNET_free (src); |
1019 | } | 1154 | } |
1155 | plugin->env->network_size_cb (plugin->env->cls, | ||
1156 | GNUNET_TIME_UNIT_FOREVER_ABS, | ||
1157 | 0.0, | ||
1158 | 0.0); | ||
1020 | GNUNET_CONTAINER_multihashmap_destroy (plugin->dsts); | 1159 | GNUNET_CONTAINER_multihashmap_destroy (plugin->dsts); |
1160 | if (NULL != plugin->read_task) | ||
1161 | { | ||
1162 | GNUNET_SCHEDULER_cancel (plugin->read_task); | ||
1163 | plugin->read_task = NULL; | ||
1164 | } | ||
1021 | GNUNET_SCHEDULER_cancel (plugin->scan_task); | 1165 | GNUNET_SCHEDULER_cancel (plugin->scan_task); |
1022 | GNUNET_break (0 == | 1166 | GNUNET_break (GNUNET_OK == |
1023 | GNUNET_NETWORK_socket_close (plugin->sock)); | 1167 | GNUNET_NETWORK_socket_close (plugin->sock)); |
1024 | GNUNET_free (plugin->port); | 1168 | GNUNET_free (plugin->port); |
1025 | GNUNET_free (plugin); | 1169 | GNUNET_free (plugin); |
diff --git a/src/dns/plugin_block_dns.c b/src/dns/plugin_block_dns.c index d3eb7d2b9..a596beb28 100644 --- a/src/dns/plugin_block_dns.c +++ b/src/dns/plugin_block_dns.c | |||
@@ -90,93 +90,6 @@ block_plugin_dns_create_group (void *cls, | |||
90 | 90 | ||
91 | 91 | ||
92 | /** | 92 | /** |
93 | * Function called to validate a reply or a request. For | ||
94 | * request evaluation, simply pass "NULL" for the reply_block. | ||
95 | * | ||
96 | * @param cls closure | ||
97 | * @param ctx block context | ||
98 | * @param type block type | ||
99 | * @param bg group to evaluate against | ||
100 | * @param eo control flags | ||
101 | * @param query original query (hash) | ||
102 | * @param xquery extended query data (can be NULL, depending on type) | ||
103 | * @param xquery_size number of bytes in @a xquery | ||
104 | * @param reply_block response to validate | ||
105 | * @param reply_block_size number of bytes in @a reply_block | ||
106 | * @return characterization of result | ||
107 | */ | ||
108 | static enum GNUNET_BLOCK_EvaluationResult | ||
109 | block_plugin_dns_evaluate (void *cls, | ||
110 | struct GNUNET_BLOCK_Context *ctx, | ||
111 | enum GNUNET_BLOCK_Type type, | ||
112 | struct GNUNET_BLOCK_Group *bg, | ||
113 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
114 | const struct GNUNET_HashCode *query, | ||
115 | const void *xquery, | ||
116 | size_t xquery_size, | ||
117 | const void *reply_block, | ||
118 | size_t reply_block_size) | ||
119 | { | ||
120 | const struct GNUNET_DNS_Advertisement *ad; | ||
121 | struct GNUNET_HashCode phash; | ||
122 | |||
123 | switch (type) | ||
124 | { | ||
125 | case GNUNET_BLOCK_TYPE_DNS: | ||
126 | if (0 != xquery_size) | ||
127 | return GNUNET_BLOCK_EVALUATION_REQUEST_INVALID; | ||
128 | |||
129 | if (NULL == reply_block) | ||
130 | return GNUNET_BLOCK_EVALUATION_REQUEST_VALID; | ||
131 | |||
132 | if (sizeof(struct GNUNET_DNS_Advertisement) != reply_block_size) | ||
133 | { | ||
134 | GNUNET_break_op (0); | ||
135 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
136 | } | ||
137 | ad = reply_block; | ||
138 | |||
139 | if (ntohl (ad->purpose.size) != | ||
140 | sizeof(struct GNUNET_DNS_Advertisement) | ||
141 | - sizeof(struct GNUNET_CRYPTO_EddsaSignature)) | ||
142 | { | ||
143 | GNUNET_break_op (0); | ||
144 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
145 | } | ||
146 | if (0 == | ||
147 | GNUNET_TIME_absolute_get_remaining (GNUNET_TIME_absolute_ntoh | ||
148 | (ad->expiration_time)). | ||
149 | rel_value_us) | ||
150 | { | ||
151 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
152 | "DNS advertisement has expired\n"); | ||
153 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
154 | } | ||
155 | if (GNUNET_OK != | ||
156 | GNUNET_CRYPTO_eddsa_verify_ (GNUNET_SIGNATURE_PURPOSE_DNS_RECORD, | ||
157 | &ad->purpose, | ||
158 | &ad->signature, | ||
159 | &ad->peer.public_key)) | ||
160 | { | ||
161 | GNUNET_break_op (0); | ||
162 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
163 | } | ||
164 | GNUNET_CRYPTO_hash (reply_block, | ||
165 | reply_block_size, | ||
166 | &phash); | ||
167 | if (GNUNET_YES == | ||
168 | GNUNET_BLOCK_GROUP_bf_test_and_set (bg, | ||
169 | &phash)) | ||
170 | return GNUNET_BLOCK_EVALUATION_OK_DUPLICATE; | ||
171 | return GNUNET_BLOCK_EVALUATION_OK_MORE; | ||
172 | |||
173 | default: | ||
174 | return GNUNET_BLOCK_EVALUATION_TYPE_NOT_SUPPORTED; | ||
175 | } | ||
176 | } | ||
177 | |||
178 | |||
179 | /** | ||
180 | * Function called to validate a query. | 93 | * Function called to validate a query. |
181 | * | 94 | * |
182 | * @param cls closure | 95 | * @param cls closure |
@@ -198,9 +111,13 @@ block_plugin_dns_check_query (void *cls, | |||
198 | { | 111 | { |
199 | case GNUNET_BLOCK_TYPE_DNS: | 112 | case GNUNET_BLOCK_TYPE_DNS: |
200 | if (0 != xquery_size) | 113 | if (0 != xquery_size) |
201 | return GNUNET_NO; | 114 | { |
115 | GNUNET_break_op (0); | ||
116 | return GNUNET_NO; | ||
117 | } | ||
202 | return GNUNET_OK; | 118 | return GNUNET_OK; |
203 | default: | 119 | default: |
120 | GNUNET_break (0); | ||
204 | return GNUNET_SYSERR; | 121 | return GNUNET_SYSERR; |
205 | } | 122 | } |
206 | } | 123 | } |
@@ -211,17 +128,15 @@ block_plugin_dns_check_query (void *cls, | |||
211 | * | 128 | * |
212 | * @param cls closure | 129 | * @param cls closure |
213 | * @param type block type | 130 | * @param type block type |
214 | * @param query key for the block (hash), must match exactly | ||
215 | * @param block block data to validate | 131 | * @param block block data to validate |
216 | * @param block_size number of bytes in @a block | 132 | * @param block_size number of bytes in @a block |
217 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not | 133 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not |
218 | */ | 134 | */ |
219 | static enum GNUNET_GenericReturnValue | 135 | static enum GNUNET_GenericReturnValue |
220 | block_plugin_dns_check_block (void *cls, | 136 | block_plugin_dns_check_block (void *cls, |
221 | enum GNUNET_BLOCK_Type type, | 137 | enum GNUNET_BLOCK_Type type, |
222 | const struct GNUNET_HashCode *query, | 138 | const void *block, |
223 | const void *block, | 139 | size_t block_size) |
224 | size_t block_size) | ||
225 | { | 140 | { |
226 | const struct GNUNET_DNS_Advertisement *ad; | 141 | const struct GNUNET_DNS_Advertisement *ad; |
227 | 142 | ||
@@ -260,6 +175,7 @@ block_plugin_dns_check_block (void *cls, | |||
260 | } | 175 | } |
261 | return GNUNET_OK; | 176 | return GNUNET_OK; |
262 | default: | 177 | default: |
178 | GNUNET_break (0); | ||
263 | return GNUNET_SYSERR; | 179 | return GNUNET_SYSERR; |
264 | } | 180 | } |
265 | } | 181 | } |
@@ -283,14 +199,14 @@ block_plugin_dns_check_block (void *cls, | |||
283 | */ | 199 | */ |
284 | static enum GNUNET_BLOCK_ReplyEvaluationResult | 200 | static enum GNUNET_BLOCK_ReplyEvaluationResult |
285 | block_plugin_dns_check_reply ( | 201 | block_plugin_dns_check_reply ( |
286 | void *cls, | 202 | void *cls, |
287 | enum GNUNET_BLOCK_Type type, | 203 | enum GNUNET_BLOCK_Type type, |
288 | struct GNUNET_BLOCK_Group *group, | 204 | struct GNUNET_BLOCK_Group *group, |
289 | const struct GNUNET_HashCode *query, | 205 | const struct GNUNET_HashCode *query, |
290 | const void *xquery, | 206 | const void *xquery, |
291 | size_t xquery_size, | 207 | size_t xquery_size, |
292 | const void *reply_block, | 208 | const void *reply_block, |
293 | size_t reply_block_size) | 209 | size_t reply_block_size) |
294 | { | 210 | { |
295 | struct GNUNET_HashCode phash; | 211 | struct GNUNET_HashCode phash; |
296 | 212 | ||
@@ -306,6 +222,7 @@ block_plugin_dns_check_reply ( | |||
306 | return GNUNET_BLOCK_REPLY_OK_DUPLICATE; | 222 | return GNUNET_BLOCK_REPLY_OK_DUPLICATE; |
307 | return GNUNET_BLOCK_REPLY_OK_MORE; | 223 | return GNUNET_BLOCK_REPLY_OK_MORE; |
308 | default: | 224 | default: |
225 | GNUNET_break (0); | ||
309 | return GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED; | 226 | return GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED; |
310 | } | 227 | } |
311 | } | 228 | } |
@@ -329,8 +246,12 @@ block_plugin_dns_get_key (void *cls, | |||
329 | size_t block_size, | 246 | size_t block_size, |
330 | struct GNUNET_HashCode *key) | 247 | struct GNUNET_HashCode *key) |
331 | { | 248 | { |
332 | /* we cannot extract a key from a block of this type */ | 249 | if (GNUNET_BLOCK_TYPE_DNS != type) |
333 | return GNUNET_SYSERR; | 250 | { |
251 | GNUNET_break (0); | ||
252 | return GNUNET_SYSERR; | ||
253 | } | ||
254 | return GNUNET_NO; | ||
334 | } | 255 | } |
335 | 256 | ||
336 | 257 | ||
@@ -347,7 +268,6 @@ libgnunet_plugin_block_dns_init (void *cls) | |||
347 | struct GNUNET_BLOCK_PluginFunctions *api; | 268 | struct GNUNET_BLOCK_PluginFunctions *api; |
348 | 269 | ||
349 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); | 270 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); |
350 | api->evaluate = &block_plugin_dns_evaluate; | ||
351 | api->get_key = &block_plugin_dns_get_key; | 271 | api->get_key = &block_plugin_dns_get_key; |
352 | api->check_query = &block_plugin_dns_check_query; | 272 | api->check_query = &block_plugin_dns_check_query; |
353 | api->check_block = &block_plugin_dns_check_block; | 273 | api->check_block = &block_plugin_dns_check_block; |
diff --git a/src/fs/fs_file_information.c b/src/fs/fs_file_information.c index 3324abd58..c5faa14d4 100644 --- a/src/fs/fs_file_information.c +++ b/src/fs/fs_file_information.c | |||
@@ -57,7 +57,7 @@ GNUNET_FS_file_information_get_id (struct GNUNET_FS_FileInformation *s) | |||
57 | * @return "filename" field of the structure (can be NULL) | 57 | * @return "filename" field of the structure (can be NULL) |
58 | */ | 58 | */ |
59 | const char * | 59 | const char * |
60 | GNUNET_FS_file_information_get_filename (struct GNUNET_FS_FileInformation *s) | 60 | GNUNET_FS_file_information_get_filename (const struct GNUNET_FS_FileInformation *s) |
61 | { | 61 | { |
62 | return s->filename; | 62 | return s->filename; |
63 | } | 63 | } |
diff --git a/src/fs/fs_uri.c b/src/fs/fs_uri.c index 73ea5d60d..2d5566b54 100644 --- a/src/fs/fs_uri.c +++ b/src/fs/fs_uri.c | |||
@@ -653,18 +653,24 @@ GNUNET_FS_uri_parse (const char *uri, char **emsg) | |||
653 | *emsg = GNUNET_strdup (_ ("invalid argument")); | 653 | *emsg = GNUNET_strdup (_ ("invalid argument")); |
654 | return NULL; | 654 | return NULL; |
655 | } | 655 | } |
656 | if (NULL == emsg) | 656 | /** |
657 | emsg = &msg; | 657 | * FIXME: Do we want to log this? |
658 | *emsg = NULL; | 658 | */ |
659 | if ((NULL != (ret = uri_chk_parse (uri, emsg))) || | 659 | msg = NULL; |
660 | (NULL != (ret = uri_ksk_parse (uri, emsg))) || | 660 | if (NULL != (ret = uri_chk_parse (uri, &msg))) |
661 | (NULL != (ret = uri_sks_parse (uri, emsg))) || | 661 | return ret; |
662 | (NULL != (ret = uri_loc_parse (uri, emsg)))) | 662 | GNUNET_free (msg); |
663 | if (NULL != (ret = uri_ksk_parse (uri, &msg))) | ||
664 | return ret; | ||
665 | GNUNET_free (msg); | ||
666 | if (NULL != (ret = uri_sks_parse (uri, &msg))) | ||
667 | return ret; | ||
668 | GNUNET_free (msg); | ||
669 | if (NULL != (ret = uri_loc_parse (uri, &msg))) | ||
663 | return ret; | 670 | return ret; |
664 | if (NULL == *emsg) | 671 | GNUNET_free (msg); |
672 | if (NULL != emsg) | ||
665 | *emsg = GNUNET_strdup (_ ("Unrecognized URI type")); | 673 | *emsg = GNUNET_strdup (_ ("Unrecognized URI type")); |
666 | if (emsg == &msg) | ||
667 | GNUNET_free (msg); | ||
668 | return NULL; | 674 | return NULL; |
669 | } | 675 | } |
670 | 676 | ||
diff --git a/src/fs/gnunet-search.c b/src/fs/gnunet-search.c index 3bf013650..7e2e4d2a6 100644 --- a/src/fs/gnunet-search.c +++ b/src/fs/gnunet-search.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet. | 2 | This file is part of GNUnet. |
3 | Copyright (C) 2001, 2002, 2004, 2005, 2006, 2007, 2009 GNUnet e.V. | 3 | Copyright (C) 2001, 2002, 2004, 2005, 2006, 2007, 2009, 2022 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 |
@@ -24,10 +24,57 @@ | |||
24 | * @author Krista Bennett | 24 | * @author Krista Bennett |
25 | * @author James Blackwell | 25 | * @author James Blackwell |
26 | * @author Igor Wronsky | 26 | * @author Igor Wronsky |
27 | * @author madmurphy | ||
27 | */ | 28 | */ |
29 | #include <ctype.h> | ||
30 | #include <inttypes.h> | ||
31 | #include <limits.h> | ||
28 | #include "platform.h" | 32 | #include "platform.h" |
29 | #include "gnunet_fs_service.h" | 33 | #include "gnunet_fs_service.h" |
30 | 34 | ||
35 | |||
36 | #define GNUNET_SEARCH_log(kind, ...) \ | ||
37 | GNUNET_log_from(kind, "gnunet-search", __VA_ARGS__) | ||
38 | |||
39 | |||
40 | /* The default settings that we use for the printed output */ | ||
41 | |||
42 | #define DEFAULT_DIR_FORMAT "#%n:\ngnunet-download -o \"%f\" -R %u\n\n" | ||
43 | #define HELP_DEFAULT_DIR_FORMAT "#%n:\\ngnunet-download -o \"%f\" -R %u\\n\\n" | ||
44 | #define DEFAULT_FILE_FORMAT "#%n:\ngnunet-download -o \"%f\" %u\n\n" | ||
45 | #define HELP_DEFAULT_FILE_FORMAT "#%n:\\ngnunet-download -o \"%f\" %u\\n\\n" | ||
46 | #define VERB_DEFAULT_DIR_FORMAT DEFAULT_DIR_FORMAT "%a\n" | ||
47 | #define VERB_DEFAULT_FILE_FORMAT DEFAULT_FILE_FORMAT "%a\n" | ||
48 | |||
49 | #if HAVE_LIBEXTRACTOR | ||
50 | #define DEFAULT_META_FORMAT " %t: %p\n" | ||
51 | #define HELP_DEFAULT_META_FORMAT " %t: %p\\n" | ||
52 | #define HELP_EXTRACTOR_TEXTADD ", %t" | ||
53 | #else | ||
54 | #define DEFAULT_META_FORMAT " MetaType #%i: %p\n" | ||
55 | #define HELP_DEFAULT_META_FORMAT " MetaType #%i: %p\\n" | ||
56 | #define HELP_EXTRACTOR_TEXTADD "" | ||
57 | #endif | ||
58 | |||
59 | #define GENERIC_DIRECTORY_NAME "collection" | ||
60 | #define GENERIC_FILE_NAME "no-name" | ||
61 | #define GENERIC_FILE_MIMETYPE "application/octet-stream" | ||
62 | |||
63 | |||
64 | enum GNUNET_SEARCH_MetadataPrinterFlags { | ||
65 | METADATA_PRINTER_FLAG_NONE = 0, | ||
66 | METADATA_PRINTER_FLAG_ONE_RUN = 1, | ||
67 | METADATA_PRINTER_FLAG_HAVE_TYPE = 2 | ||
68 | }; | ||
69 | |||
70 | |||
71 | struct GNUNET_SEARCH_MetadataPrinterInfo { | ||
72 | unsigned int counter; | ||
73 | unsigned int flags; | ||
74 | int type; | ||
75 | }; | ||
76 | |||
77 | |||
31 | static int ret; | 78 | static int ret; |
32 | 79 | ||
33 | static const struct GNUNET_CONFIGURATION_Handle *cfg; | 80 | static const struct GNUNET_CONFIGURATION_Handle *cfg; |
@@ -38,6 +85,12 @@ static struct GNUNET_FS_SearchContext *sc; | |||
38 | 85 | ||
39 | static char *output_filename; | 86 | static char *output_filename; |
40 | 87 | ||
88 | static char *format_string; | ||
89 | |||
90 | static char *dir_format_string; | ||
91 | |||
92 | static char *meta_format_string; | ||
93 | |||
41 | static struct GNUNET_FS_DirectoryBuilder *db; | 94 | static struct GNUNET_FS_DirectoryBuilder *db; |
42 | 95 | ||
43 | static unsigned int anonymity = 1; | 96 | static unsigned int anonymity = 1; |
@@ -53,16 +106,79 @@ static unsigned int results; | |||
53 | 106 | ||
54 | static unsigned int verbose; | 107 | static unsigned int verbose; |
55 | 108 | ||
109 | static int bookmark_only; | ||
110 | |||
56 | static int local_only; | 111 | static int local_only; |
57 | 112 | ||
113 | static int silent_mode; | ||
114 | |||
58 | static struct GNUNET_SCHEDULER_Task *tt; | 115 | static struct GNUNET_SCHEDULER_Task *tt; |
59 | 116 | ||
60 | 117 | ||
61 | /** | 118 | /** |
119 | * Print the escape sequence at the beginning of a string. | ||
120 | * | ||
121 | * @param esc a string that **must** begin with a backslash (the function only | ||
122 | * assumes that it does, but does not check) | ||
123 | * @return the fragment that follows what has been printed | ||
124 | * @author madmurphy | ||
125 | * | ||
126 | * If `"\\nfoo"` is passed as argument, this function prints a new line and | ||
127 | * returns `"foo"` | ||
128 | */ | ||
129 | static const char * | ||
130 | print_escape_sequence (const char *const esc) | ||
131 | { | ||
132 | unsigned int probe; | ||
133 | const char * cursor = esc + 1; | ||
134 | char tmp; | ||
135 | switch (*cursor) | ||
136 | { | ||
137 | /* Trivia */ | ||
138 | case '\\': putchar ('\\'); return cursor + 1; | ||
139 | case 'a': putchar ('\a'); return cursor + 1; | ||
140 | case 'b': putchar ('\b'); return cursor + 1; | ||
141 | case 'e': putchar ('\x1B'); return cursor + 1; | ||
142 | case 'f': putchar ('\f'); return cursor + 1; | ||
143 | case 'n': putchar ('\n'); return cursor + 1; | ||
144 | case 'r': putchar ('\r'); return cursor + 1; | ||
145 | case 't': putchar ('\t'); return cursor + 1; | ||
146 | case 'v': putchar ('\v'); return cursor + 1; | ||
147 | |||
148 | /* Possibly hexadecimal code point */ | ||
149 | case 'x': | ||
150 | probe = 0; | ||
151 | while (probe < 256 && isxdigit((tmp = *++cursor))) | ||
152 | probe = (probe << 4) + tmp - (tmp > 96 ? 87 : tmp > 64 ? 55 : 48); | ||
153 | goto maybe_codepoint; | ||
154 | |||
155 | /* Possibly octal code point */ | ||
156 | case '0': case '1': case '2': case '3': | ||
157 | case '4': case '5': case '6': case '7': | ||
158 | probe = *cursor++ - 48; | ||
159 | do probe = (probe << 3) + *cursor++ - 48; | ||
160 | while (probe < 256 && cursor < esc + 4 && *cursor > 47 && *cursor < 56); | ||
161 | goto maybe_codepoint; | ||
162 | |||
163 | /* Boredom */ | ||
164 | case '\0': putchar ('\\'); return cursor; | ||
165 | default: printf ("\\%c", *cursor); return cursor + 1; | ||
166 | } | ||
167 | |||
168 | maybe_codepoint: | ||
169 | if (probe < 256) | ||
170 | putchar (probe); | ||
171 | else | ||
172 | fwrite (esc, 1, cursor - esc, stdout); | ||
173 | return cursor; | ||
174 | } | ||
175 | |||
176 | |||
177 | /** | ||
62 | * Type of a function that libextractor calls for each | 178 | * Type of a function that libextractor calls for each |
63 | * meta data item found. | 179 | * meta data item found. |
64 | * | 180 | * |
65 | * @param cls closure (user-defined, unused) | 181 | * @param cls closure (user-defined, used for the iteration info) |
66 | * @param plugin_name name of the plugin that produced this value; | 182 | * @param plugin_name name of the plugin that produced this value; |
67 | * special values can be used (e.g. '<zlib>' for zlib being | 183 | * special values can be used (e.g. '<zlib>' for zlib being |
68 | * used in the main libextractor library and yielding | 184 | * used in the main libextractor library and yielding |
@@ -76,33 +192,228 @@ static struct GNUNET_SCHEDULER_Task *tt; | |||
76 | * @return 0 to continue extracting, 1 to abort | 192 | * @return 0 to continue extracting, 1 to abort |
77 | */ | 193 | */ |
78 | static int | 194 | static int |
79 | item_printer (void *cls, | 195 | item_printer (void *const cls, |
80 | const char *plugin_name, | 196 | const char *const plugin_name, |
81 | enum EXTRACTOR_MetaType type, | 197 | const enum EXTRACTOR_MetaType type, |
82 | enum EXTRACTOR_MetaFormat format, | 198 | const enum EXTRACTOR_MetaFormat format, |
83 | const char *data_mime_type, | 199 | const char *const data_mime_type, |
84 | const char *data, | 200 | const char *const data, |
85 | size_t data_size) | 201 | const size_t data_size) |
86 | { | 202 | { |
87 | if ((format != EXTRACTOR_METAFORMAT_UTF8) && | 203 | #define info ((struct GNUNET_SEARCH_MetadataPrinterInfo *) cls) |
88 | (format != EXTRACTOR_METAFORMAT_C_STRING)) | 204 | if ((format != EXTRACTOR_METAFORMAT_UTF8 && |
205 | format != EXTRACTOR_METAFORMAT_C_STRING) || | ||
206 | type == EXTRACTOR_METATYPE_GNUNET_ORIGINAL_FILENAME) | ||
89 | return 0; | 207 | return 0; |
90 | if (type == EXTRACTOR_METATYPE_GNUNET_ORIGINAL_FILENAME) | 208 | info->counter++; |
209 | if ((info->flags & METADATA_PRINTER_FLAG_HAVE_TYPE) && type != info->type) | ||
91 | return 0; | 210 | return 0; |
211 | |||
212 | const char *cursor = meta_format_string; | ||
213 | const char *next_spec = strchr(cursor, '%'); | ||
214 | const char *next_esc = strchr(cursor, '\\'); | ||
215 | |||
216 | parse_format: | ||
217 | |||
218 | /* If an escape sequence exists before the next format specifier... */ | ||
219 | if (next_esc && (!next_spec || next_esc < next_spec)) | ||
220 | { | ||
221 | if (next_esc > cursor) | ||
222 | fwrite (cursor, 1, next_esc - cursor, stdout); | ||
223 | |||
224 | cursor = print_escape_sequence (next_esc); | ||
225 | next_esc = strchr(cursor, '\\'); | ||
226 | goto parse_format; | ||
227 | } | ||
228 | |||
229 | /* If a format specifier exists before the next escape sequence... */ | ||
230 | if (next_spec && (!next_esc || next_spec < next_esc)) | ||
231 | { | ||
232 | if (next_spec > cursor) | ||
233 | fwrite (cursor, 1, next_spec - cursor, stdout); | ||
234 | |||
235 | switch (*++next_spec) | ||
236 | { | ||
237 | case '%': putchar('%'); break; | ||
238 | case 'i': printf ("%d", type); break; | ||
239 | case 'l': printf ("%lu", (long unsigned int) data_size); break; | ||
240 | case 'n': printf ("%u", info->counter); break; | ||
241 | case 'p': printf ("%s", data); break; | ||
92 | #if HAVE_LIBEXTRACTOR | 242 | #if HAVE_LIBEXTRACTOR |
93 | printf ("\t%20s: %s\n", | 243 | case 't': |
94 | dgettext (LIBEXTRACTOR_GETTEXT_DOMAIN, | 244 | printf ("%s", |
95 | EXTRACTOR_metatype_to_string (type)), | 245 | dgettext (LIBEXTRACTOR_GETTEXT_DOMAIN, |
96 | data); | 246 | EXTRACTOR_metatype_to_string (type))); |
97 | #else | 247 | break; |
98 | printf ("\t%20d: %s\n", type, data); | ||
99 | #endif | 248 | #endif |
100 | return 0; | 249 | case 'w': printf ("%s", plugin_name); break; |
250 | case '\0': putchar('%'); return 0; | ||
251 | default: printf ("%%%c", *next_spec); break; | ||
252 | } | ||
253 | cursor = next_spec + 1; | ||
254 | next_spec = strchr(cursor, '%'); | ||
255 | goto parse_format; | ||
256 | } | ||
257 | |||
258 | if (*cursor) | ||
259 | printf ("%s", cursor); | ||
260 | |||
261 | return info->flags & METADATA_PRINTER_FLAG_ONE_RUN; | ||
262 | #undef info | ||
263 | } | ||
264 | |||
265 | |||
266 | /** | ||
267 | * Print a search result according to the current formats | ||
268 | * | ||
269 | * @param filename the filename for this result | ||
270 | * @param uri the `struct GNUNET_FS_Uri` this result refers to | ||
271 | * @param metadata the `struct GNUNET_CONTAINER_MetaData` associated with this | ||
272 | result | ||
273 | * @param resultnum the result number | ||
274 | * @param is_directory GNUNET_YES if this is a directory, otherwise GNUNET_NO | ||
275 | * @author madmurphy | ||
276 | */ | ||
277 | static void | ||
278 | print_search_result (const char *const filename, | ||
279 | const struct GNUNET_FS_Uri *const uri, | ||
280 | const struct GNUNET_CONTAINER_MetaData *const metadata, | ||
281 | const unsigned int resultnum, | ||
282 | const int is_directory) | ||
283 | { | ||
284 | |||
285 | const char *cursor = GNUNET_YES == is_directory ? | ||
286 | dir_format_string | ||
287 | : format_string; | ||
288 | |||
289 | const char *next_spec = strchr(cursor, '%'); | ||
290 | const char *next_esc = strchr(cursor, '\\'); | ||
291 | char *placeholder; | ||
292 | struct GNUNET_SEARCH_MetadataPrinterInfo info; | ||
293 | |||
294 | parse_format: | ||
295 | /* If an escape sequence exists before the next format specifier... */ | ||
296 | if (next_esc && (!next_spec || next_esc < next_spec)) | ||
297 | { | ||
298 | if (next_esc > cursor) | ||
299 | fwrite (cursor, 1, next_esc - cursor, stdout); | ||
300 | |||
301 | cursor = print_escape_sequence (next_esc); | ||
302 | next_esc = strchr(cursor, '\\'); | ||
303 | goto parse_format; | ||
304 | } | ||
305 | |||
306 | /* If a format specifier exists before the next escape sequence... */ | ||
307 | if (next_spec && (!next_esc || next_spec < next_esc)) | ||
308 | { | ||
309 | if (next_spec > cursor) | ||
310 | fwrite (cursor, 1, next_spec - cursor, stdout); | ||
311 | |||
312 | switch (*++next_spec) | ||
313 | { | ||
314 | /* All metadata fields */ | ||
315 | case 'a': | ||
316 | info.flags = METADATA_PRINTER_FLAG_NONE; | ||
317 | |||
318 | iterate_meta: | ||
319 | info.counter = 0; | ||
320 | GNUNET_CONTAINER_meta_data_iterate (metadata, &item_printer, &info); | ||
321 | break; | ||
322 | /* File's name */ | ||
323 | case 'f': | ||
324 | if (GNUNET_YES == is_directory) | ||
325 | { | ||
326 | printf ("%s%s", filename, GNUNET_FS_DIRECTORY_EXT); | ||
327 | break; | ||
328 | } | ||
329 | printf ("%s", filename); | ||
330 | break; | ||
331 | /* Only the first metadata field */ | ||
332 | case 'j': | ||
333 | info.flags = METADATA_PRINTER_FLAG_ONE_RUN; | ||
334 | goto iterate_meta; | ||
335 | /* File name's length */ | ||
336 | case 'l': | ||
337 | printf ("%lu", | ||
338 | (long unsigned int) ( GNUNET_YES == is_directory ? | ||
339 | strlen(filename) + | ||
340 | (sizeof(GNUNET_FS_DIRECTORY_EXT) - 1) | ||
341 | : | ||
342 | strlen(filename))); | ||
343 | break; | ||
344 | /* File's mime type */ | ||
345 | case 'm': | ||
346 | if (GNUNET_YES == is_directory) | ||
347 | { | ||
348 | printf ("%s", GNUNET_FS_DIRECTORY_MIME); | ||
349 | break; | ||
350 | } | ||
351 | placeholder = GNUNET_CONTAINER_meta_data_get_by_type ( | ||
352 | metadata, | ||
353 | EXTRACTOR_METATYPE_MIMETYPE); | ||
354 | printf ("%s", placeholder ? placeholder : GENERIC_FILE_MIMETYPE); | ||
355 | GNUNET_free (placeholder); | ||
356 | break; | ||
357 | /* Result number */ | ||
358 | case 'n': printf ("%u", resultnum); break; | ||
359 | /* File's size */ | ||
360 | case 's': | ||
361 | printf ("%" PRIu64, GNUNET_FS_uri_chk_get_file_size (uri)); | ||
362 | break; | ||
363 | /* File's URI */ | ||
364 | case 'u': | ||
365 | placeholder = GNUNET_FS_uri_to_string (uri); | ||
366 | printf ("%s", placeholder); | ||
367 | GNUNET_free (placeholder); | ||
368 | break; | ||
369 | |||
370 | /* We can add as many cases as we want here... */ | ||
371 | |||
372 | /* Handle `%123#a` and `%123#j` (e.g. `%5#j` is a book title) */ | ||
373 | case '0': case '1': case '2': case '3': case '4': | ||
374 | case '5': case '6': case '7': case '8': case '9': | ||
375 | cursor = next_spec; | ||
376 | info.type = *cursor - 48; | ||
377 | while (isdigit(*++cursor) && info.type < (INT_MAX - *cursor + 48) / 10) | ||
378 | info.type = info.type * 10 + *cursor - 48; | ||
379 | if (info.type == 0 || *cursor != '#') | ||
380 | goto not_a_specifier; | ||
381 | switch (*++cursor) | ||
382 | { | ||
383 | /* All metadata fields of type `info.type` */ | ||
384 | case 'a': | ||
385 | next_spec = cursor; | ||
386 | info.flags = METADATA_PRINTER_FLAG_HAVE_TYPE; | ||
387 | goto iterate_meta; | ||
388 | |||
389 | /* Only the first metadata field of type `info.type` */ | ||
390 | case 'j': | ||
391 | next_spec = cursor; | ||
392 | info.flags = METADATA_PRINTER_FLAG_HAVE_TYPE | | ||
393 | METADATA_PRINTER_FLAG_ONE_RUN; | ||
394 | goto iterate_meta; | ||
395 | } | ||
396 | goto not_a_specifier; | ||
397 | |||
398 | /* All other cases */ | ||
399 | case '%': putchar('%'); break; | ||
400 | case '\0': putchar('%'); return; | ||
401 | |||
402 | not_a_specifier: | ||
403 | default: printf ("%%%c", *next_spec); break; | ||
404 | } | ||
405 | cursor = next_spec + 1; | ||
406 | next_spec = strchr(cursor, '%'); | ||
407 | goto parse_format; | ||
408 | } | ||
409 | |||
410 | if (*cursor) | ||
411 | printf ("%s", cursor); | ||
101 | } | 412 | } |
102 | 413 | ||
103 | 414 | ||
104 | static void | 415 | static void |
105 | clean_task (void *cls) | 416 | clean_task (void *const cls) |
106 | { | 417 | { |
107 | size_t dsize; | 418 | size_t dsize; |
108 | void *ddata; | 419 | void *ddata; |
@@ -126,9 +437,10 @@ clean_task (void *cls) | |||
126 | GNUNET_DISK_PERM_USER_READ | 437 | GNUNET_DISK_PERM_USER_READ |
127 | | GNUNET_DISK_PERM_USER_WRITE)) | 438 | | GNUNET_DISK_PERM_USER_WRITE)) |
128 | { | 439 | { |
129 | fprintf (stderr, | 440 | GNUNET_SEARCH_log(GNUNET_ERROR_TYPE_ERROR, |
130 | _ ("Failed to write directory with search results to `%s'\n"), | 441 | _ ("Failed to write directory with search results to " |
131 | output_filename); | 442 | "`%s'\n"), |
443 | output_filename); | ||
132 | } | 444 | } |
133 | GNUNET_free (ddata); | 445 | GNUNET_free (ddata); |
134 | GNUNET_free (output_filename); | 446 | GNUNET_free (output_filename); |
@@ -149,11 +461,11 @@ clean_task (void *cls) | |||
149 | * field in the GNUNET_FS_ProgressInfo struct. | 461 | * field in the GNUNET_FS_ProgressInfo struct. |
150 | */ | 462 | */ |
151 | static void * | 463 | static void * |
152 | progress_cb (void *cls, const struct GNUNET_FS_ProgressInfo *info) | 464 | progress_cb (void *const cls, |
465 | const struct GNUNET_FS_ProgressInfo *const info) | ||
153 | { | 466 | { |
154 | static unsigned int cnt; | 467 | static unsigned int cnt; |
155 | int is_directory; | 468 | int is_directory; |
156 | char *uri; | ||
157 | char *filename; | 469 | char *filename; |
158 | 470 | ||
159 | switch (info->status) | 471 | switch (info->status) |
@@ -162,13 +474,17 @@ progress_cb (void *cls, const struct GNUNET_FS_ProgressInfo *info) | |||
162 | break; | 474 | break; |
163 | 475 | ||
164 | case GNUNET_FS_STATUS_SEARCH_RESULT: | 476 | case GNUNET_FS_STATUS_SEARCH_RESULT: |
477 | if (silent_mode) | ||
478 | break; | ||
479 | |||
165 | if (db != NULL) | 480 | if (db != NULL) |
166 | GNUNET_FS_directory_builder_add (db, | 481 | GNUNET_FS_directory_builder_add ( |
167 | info->value.search.specifics.result.uri, | 482 | db, |
168 | info->value.search.specifics.result.meta, | 483 | info->value.search.specifics.result.uri, |
169 | NULL); | 484 | info->value.search.specifics.result.meta, |
170 | uri = GNUNET_FS_uri_to_string (info->value.search.specifics.result.uri); | 485 | NULL); |
171 | printf ("#%u:\n", ++cnt); | 486 | |
487 | cnt++; | ||
172 | filename = GNUNET_CONTAINER_meta_data_get_by_type ( | 488 | filename = GNUNET_CONTAINER_meta_data_get_by_type ( |
173 | info->value.search.specifics.result.meta, | 489 | info->value.search.specifics.result.meta, |
174 | EXTRACTOR_METATYPE_GNUNET_ORIGINAL_FILENAME); | 490 | EXTRACTOR_METATYPE_GNUNET_ORIGINAL_FILENAME); |
@@ -179,45 +495,37 @@ progress_cb (void *cls, const struct GNUNET_FS_ProgressInfo *info) | |||
179 | while ((filename[0] != '\0') && ('/' == filename[strlen (filename) - 1])) | 495 | while ((filename[0] != '\0') && ('/' == filename[strlen (filename) - 1])) |
180 | filename[strlen (filename) - 1] = '\0'; | 496 | filename[strlen (filename) - 1] = '\0'; |
181 | GNUNET_DISK_filename_canonicalize (filename); | 497 | GNUNET_DISK_filename_canonicalize (filename); |
182 | if (GNUNET_YES == is_directory) | ||
183 | printf ("gnunet-download -o \"%s%s\" -R %s\n", | ||
184 | filename, | ||
185 | GNUNET_FS_DIRECTORY_EXT, | ||
186 | uri); | ||
187 | else | ||
188 | printf ("gnunet-download -o \"%s\" %s\n", filename, uri); | ||
189 | } | 498 | } |
190 | else if (GNUNET_YES == is_directory) | 499 | print_search_result ( filename ? |
191 | printf ("gnunet-download -o \"collection%s\" -R %s\n", | 500 | filename |
192 | GNUNET_FS_DIRECTORY_EXT, | 501 | : is_directory ? |
193 | uri); | 502 | GENERIC_DIRECTORY_NAME |
194 | else | 503 | : |
195 | printf ("gnunet-download %s\n", uri); | 504 | GENERIC_FILE_NAME, |
196 | if (verbose) | 505 | info->value.search.specifics.result.uri, |
197 | GNUNET_CONTAINER_meta_data_iterate (info->value.search.specifics.result | 506 | info->value.search.specifics.result.meta, |
198 | .meta, | 507 | cnt, |
199 | &item_printer, | 508 | is_directory); |
200 | NULL); | ||
201 | printf ("\n"); | ||
202 | fflush (stdout); | 509 | fflush (stdout); |
203 | GNUNET_free (filename); | 510 | GNUNET_free (filename); |
204 | GNUNET_free (uri); | ||
205 | results++; | 511 | results++; |
206 | if ((results_limit > 0) && (results >= results_limit)) | 512 | if ((results_limit > 0) && (results >= results_limit)) |
513 | { | ||
207 | GNUNET_SCHEDULER_shutdown (); | 514 | GNUNET_SCHEDULER_shutdown (); |
515 | /* otherwise the function might keep printing results for a while... */ | ||
516 | silent_mode = GNUNET_YES; | ||
517 | } | ||
208 | break; | 518 | break; |
209 | 519 | ||
210 | case GNUNET_FS_STATUS_SEARCH_UPDATE: | 520 | case GNUNET_FS_STATUS_SEARCH_UPDATE: |
211 | break; | ||
212 | |||
213 | case GNUNET_FS_STATUS_SEARCH_RESULT_STOPPED: | 521 | case GNUNET_FS_STATUS_SEARCH_RESULT_STOPPED: |
214 | /* ignore */ | 522 | /* ignore */ |
215 | break; | 523 | break; |
216 | 524 | ||
217 | case GNUNET_FS_STATUS_SEARCH_ERROR: | 525 | case GNUNET_FS_STATUS_SEARCH_ERROR: |
218 | fprintf (stderr, | 526 | GNUNET_SEARCH_log(GNUNET_ERROR_TYPE_ERROR, |
219 | _ ("Error searching: %s.\n"), | 527 | _ ("Error searching: %s.\n"), |
220 | info->value.search.specifics.error.message); | 528 | info->value.search.specifics.error.message); |
221 | GNUNET_SCHEDULER_shutdown (); | 529 | GNUNET_SCHEDULER_shutdown (); |
222 | break; | 530 | break; |
223 | 531 | ||
@@ -226,7 +534,9 @@ progress_cb (void *cls, const struct GNUNET_FS_ProgressInfo *info) | |||
226 | break; | 534 | break; |
227 | 535 | ||
228 | default: | 536 | default: |
229 | fprintf (stderr, _ ("Unexpected status: %d\n"), info->status); | 537 | GNUNET_SEARCH_log(GNUNET_ERROR_TYPE_ERROR, |
538 | _ ("Unexpected status: %d\n"), | ||
539 | info->status); | ||
230 | break; | 540 | break; |
231 | } | 541 | } |
232 | return NULL; | 542 | return NULL; |
@@ -234,7 +544,7 @@ progress_cb (void *cls, const struct GNUNET_FS_ProgressInfo *info) | |||
234 | 544 | ||
235 | 545 | ||
236 | static void | 546 | static void |
237 | shutdown_task (void *cls) | 547 | shutdown_task (void *const cls) |
238 | { | 548 | { |
239 | if (sc != NULL) | 549 | if (sc != NULL) |
240 | { | 550 | { |
@@ -245,9 +555,10 @@ shutdown_task (void *cls) | |||
245 | 555 | ||
246 | 556 | ||
247 | static void | 557 | static void |
248 | timeout_task (void *cls) | 558 | timeout_task (void *const cls) |
249 | { | 559 | { |
250 | tt = NULL; | 560 | tt = NULL; |
561 | silent_mode = GNUNET_YES; | ||
251 | GNUNET_SCHEDULER_shutdown (); | 562 | GNUNET_SCHEDULER_shutdown (); |
252 | } | 563 | } |
253 | 564 | ||
@@ -258,18 +569,47 @@ timeout_task (void *cls) | |||
258 | * @param cls closure | 569 | * @param cls closure |
259 | * @param args remaining command-line arguments | 570 | * @param args remaining command-line arguments |
260 | * @param cfgfile name of the configuration file used (for saving, can be NULL!) | 571 | * @param cfgfile name of the configuration file used (for saving, can be NULL!) |
261 | * @param c configuration | 572 | * @param cfgarg configuration |
262 | */ | 573 | */ |
263 | static void | 574 | static void |
264 | run (void *cls, | 575 | run (void *const cls, |
265 | char *const *args, | 576 | char *const *const args, |
266 | const char *cfgfile, | 577 | const char *const cfgfile, |
267 | const struct GNUNET_CONFIGURATION_Handle *c) | 578 | const struct GNUNET_CONFIGURATION_Handle *const cfgarg) |
268 | { | 579 | { |
269 | struct GNUNET_FS_Uri *uri; | 580 | struct GNUNET_FS_Uri *uri; |
270 | unsigned int argc; | 581 | unsigned int argc; |
271 | enum GNUNET_FS_SearchOptions options; | 582 | enum GNUNET_FS_SearchOptions options; |
272 | 583 | ||
584 | if (silent_mode && bookmark_only) | ||
585 | { | ||
586 | fprintf (stderr, | ||
587 | _ ("Conflicting options --bookmark-only and --silent.\n")); | ||
588 | ret = 1; | ||
589 | return; | ||
590 | } | ||
591 | if (bookmark_only && output_filename) | ||
592 | { | ||
593 | fprintf (stderr, | ||
594 | _ ("Conflicting options --bookmark-only and --output.\n")); | ||
595 | ret = 1; | ||
596 | return; | ||
597 | } | ||
598 | if (silent_mode && !output_filename) | ||
599 | { | ||
600 | fprintf (stderr, _ ("An output file is mandatory for silent mode.\n")); | ||
601 | ret = 1; | ||
602 | return; | ||
603 | } | ||
604 | if (NULL == dir_format_string) | ||
605 | dir_format_string = format_string ? format_string | ||
606 | : verbose ? VERB_DEFAULT_DIR_FORMAT | ||
607 | : DEFAULT_DIR_FORMAT; | ||
608 | if (NULL == format_string) | ||
609 | format_string = verbose ? VERB_DEFAULT_FILE_FORMAT | ||
610 | : DEFAULT_FILE_FORMAT; | ||
611 | if (NULL == meta_format_string) | ||
612 | meta_format_string = DEFAULT_META_FORMAT; | ||
273 | argc = 0; | 613 | argc = 0; |
274 | while (NULL != args[argc]) | 614 | while (NULL != args[argc]) |
275 | argc++; | 615 | argc++; |
@@ -282,7 +622,27 @@ run (void *cls, | |||
282 | ret = 1; | 622 | ret = 1; |
283 | return; | 623 | return; |
284 | } | 624 | } |
285 | cfg = c; | 625 | if (!GNUNET_FS_uri_test_ksk (uri) && !GNUNET_FS_uri_test_sks (uri)) |
626 | { | ||
627 | fprintf (stderr, | ||
628 | "%s", | ||
629 | _ ("Invalid URI. Valid URIs for searching are keyword query " | ||
630 | "URIs\n(\"gnunet://fs/ksk/...\") and namespace content URIs " | ||
631 | "(\"gnunet://fs/sks/...\").\n")); | ||
632 | GNUNET_FS_uri_destroy (uri); | ||
633 | ret = 1; | ||
634 | return; | ||
635 | } | ||
636 | if (bookmark_only) | ||
637 | { | ||
638 | char * bmstr = GNUNET_FS_uri_to_string (uri); | ||
639 | printf ("%s\n", bmstr); | ||
640 | GNUNET_free (bmstr); | ||
641 | GNUNET_FS_uri_destroy (uri); | ||
642 | ret = 0; | ||
643 | return; | ||
644 | } | ||
645 | cfg = cfgarg; | ||
286 | ctx = GNUNET_FS_start (cfg, | 646 | ctx = GNUNET_FS_start (cfg, |
287 | "gnunet-search", | 647 | "gnunet-search", |
288 | &progress_cb, | 648 | &progress_cb, |
@@ -291,7 +651,7 @@ run (void *cls, | |||
291 | GNUNET_FS_OPTIONS_END); | 651 | GNUNET_FS_OPTIONS_END); |
292 | if (NULL == ctx) | 652 | if (NULL == ctx) |
293 | { | 653 | { |
294 | fprintf (stderr, _ ("Could not initialize `%s' subsystem.\n"), "FS"); | 654 | fprintf (stderr, _ ("Could not initialize the `%s` subsystem.\n"), "FS"); |
295 | GNUNET_FS_uri_destroy (uri); | 655 | GNUNET_FS_uri_destroy (uri); |
296 | ret = 1; | 656 | ret = 1; |
297 | return; | 657 | return; |
@@ -321,18 +681,59 @@ run (void *cls, | |||
321 | * | 681 | * |
322 | * @param argc number of arguments from the command line | 682 | * @param argc number of arguments from the command line |
323 | * @param argv command line arguments | 683 | * @param argv command line arguments |
324 | * @return 0 ok, 1 on error | 684 | * @return 0 ok, an error number on error |
325 | */ | 685 | */ |
326 | int | 686 | int |
327 | main (int argc, char *const *argv) | 687 | main (int argc, char *const *argv) |
328 | { | 688 | { |
329 | struct GNUNET_GETOPT_CommandLineOption options[] = | 689 | struct GNUNET_GETOPT_CommandLineOption options[] = |
330 | { GNUNET_GETOPT_option_uint ('a', | 690 | { GNUNET_GETOPT_option_uint ( |
331 | "anonymity", | 691 | 'a', |
332 | "LEVEL", | 692 | "anonymity", |
333 | gettext_noop ( | 693 | "LEVEL", |
334 | "set the desired LEVEL of receiver-anonymity"), | 694 | gettext_noop ("set the desired LEVEL of receiver-anonymity (default: " |
335 | &anonymity), | 695 | "1)"), |
696 | &anonymity), | ||
697 | GNUNET_GETOPT_option_flag ( | ||
698 | 'b', | ||
699 | "bookmark-only", | ||
700 | gettext_noop ("do not search, print only the URI that points to this " | ||
701 | "search"), | ||
702 | &bookmark_only), | ||
703 | GNUNET_GETOPT_option_string ( | ||
704 | 'F', | ||
705 | "dir-printf", | ||
706 | "FORMAT", | ||
707 | gettext_noop ("write search results for directories according to " | ||
708 | "FORMAT; accepted placeholders are: %a, %f, %j, %l, %m, " | ||
709 | "%n, %s; defaults to the value of --printf when omitted " | ||
710 | "or to `" HELP_DEFAULT_DIR_FORMAT "` if --printf is " | ||
711 | "omitted too"), | ||
712 | &dir_format_string), | ||
713 | GNUNET_GETOPT_option_string ( | ||
714 | 'f', | ||
715 | "printf", | ||
716 | "FORMAT", | ||
717 | gettext_noop ("write search results according to FORMAT; accepted " | ||
718 | "placeholders are: %a, %f, %j, %l, %m, %n, %s; defaults " | ||
719 | "to `" HELP_DEFAULT_FILE_FORMAT "` when omitted"), | ||
720 | &format_string), | ||
721 | GNUNET_GETOPT_option_string ( | ||
722 | 'i', | ||
723 | "iter-printf", | ||
724 | "FORMAT", | ||
725 | gettext_noop ("when the %a or %j placeholders appear in --printf or " | ||
726 | "--dir-printf, list each metadata property according to " | ||
727 | "FORMAT; accepted placeholders are: %i, %l, %n, %p" | ||
728 | HELP_EXTRACTOR_TEXTADD ", %w; defaults to `" | ||
729 | HELP_DEFAULT_META_FORMAT "` when omitted"), | ||
730 | &meta_format_string), | ||
731 | GNUNET_GETOPT_option_uint ('N', | ||
732 | "results", | ||
733 | "VALUE", | ||
734 | gettext_noop ("automatically terminate search " | ||
735 | "after VALUE results are found"), | ||
736 | &results_limit), | ||
336 | GNUNET_GETOPT_option_flag ( | 737 | GNUNET_GETOPT_option_flag ( |
337 | 'n', | 738 | 'n', |
338 | "no-network", | 739 | "no-network", |
@@ -341,39 +742,49 @@ main (int argc, char *const *argv) | |||
341 | GNUNET_GETOPT_option_string ( | 742 | GNUNET_GETOPT_option_string ( |
342 | 'o', | 743 | 'o', |
343 | "output", | 744 | "output", |
344 | "PREFIX", | 745 | "FILENAME", |
345 | gettext_noop ("write search results to file starting with PREFIX"), | 746 | gettext_noop ("create a GNUnet directory with search results at " |
747 | "FILENAME (e.g. `gnunet-search --output=commons" | ||
748 | GNUNET_FS_DIRECTORY_EXT " commons`)"), | ||
346 | &output_filename), | 749 | &output_filename), |
750 | GNUNET_GETOPT_option_flag ( | ||
751 | 's', | ||
752 | "silent", | ||
753 | gettext_noop ("silent mode (requires the --output argument)"), | ||
754 | &silent_mode), | ||
347 | GNUNET_GETOPT_option_relative_time ( | 755 | GNUNET_GETOPT_option_relative_time ( |
348 | 't', | 756 | 't', |
349 | "timeout", | 757 | "timeout", |
350 | "DELAY", | 758 | "DELAY", |
351 | gettext_noop ("automatically terminate search after DELAY"), | 759 | gettext_noop ("automatically terminate search after DELAY; the value " |
760 | "given must be a number followed by a space and a time " | ||
761 | "unit, for example \"500 ms\"; without a unit it defaults " | ||
762 | "to microseconds - 1000000 = 1 second; if 0 or omitted " | ||
763 | "it means to wait for CTRL-C"), | ||
352 | &timeout), | 764 | &timeout), |
353 | GNUNET_GETOPT_option_verbose (&verbose), | 765 | GNUNET_GETOPT_option_increment_uint ( |
354 | GNUNET_GETOPT_option_uint ('N', | 766 | 'V', |
355 | "results", | 767 | "verbose", |
356 | "VALUE", | 768 | gettext_noop ("be verbose (append \"%a\\n\" to the default --printf and " |
357 | gettext_noop ("automatically terminate search " | 769 | "--dir-printf arguments - ignored when these are provided " |
358 | "after VALUE results are found"), | 770 | "by the user)"), |
359 | &results_limit), | 771 | &verbose), |
360 | GNUNET_GETOPT_OPTION_END }; | 772 | GNUNET_GETOPT_OPTION_END }; |
361 | 773 | ||
362 | if (GNUNET_OK != GNUNET_STRINGS_get_utf8_args (argc, argv, &argc, &argv)) | 774 | if (GNUNET_OK != GNUNET_STRINGS_get_utf8_args (argc, argv, &argc, &argv)) |
363 | return 2; | 775 | return 12; |
364 | 776 | ||
365 | ret = | 777 | if (GNUNET_SYSERR == |
366 | (GNUNET_OK == | 778 | GNUNET_PROGRAM_run (argc, |
367 | GNUNET_PROGRAM_run (argc, | 779 | argv, |
368 | argv, | 780 | "gnunet-search [OPTIONS] KEYWORD1 KEYWORD2 ...", |
369 | "gnunet-search [OPTIONS] KEYWORD", | 781 | gettext_noop ("Search for files that have been " |
370 | gettext_noop ( | 782 | "published on GNUnet\n"), |
371 | "Search GNUnet for files that were published on GNUnet"), | ||
372 | options, | 783 | options, |
373 | &run, | 784 | &run, |
374 | NULL)) | 785 | NULL)) |
375 | ? ret | 786 | ret = 1; |
376 | : 1; | 787 | |
377 | GNUNET_free_nz ((void *) argv); | 788 | GNUNET_free_nz ((void *) argv); |
378 | return ret; | 789 | return ret; |
379 | } | 790 | } |
diff --git a/src/fs/gnunet-service-fs_pr.c b/src/fs/gnunet-service-fs_pr.c index beb29a506..154c454ca 100644 --- a/src/fs/gnunet-service-fs_pr.c +++ b/src/fs/gnunet-service-fs_pr.c | |||
@@ -247,7 +247,8 @@ static unsigned long long max_pending_requests = (32 * 1024); | |||
247 | * @param pr request for which the BF is to be recomputed | 247 | * @param pr request for which the BF is to be recomputed |
248 | */ | 248 | */ |
249 | static void | 249 | static void |
250 | refresh_bloomfilter (enum GNUNET_BLOCK_Type type, struct GSF_PendingRequest *pr) | 250 | refresh_bloomfilter (enum GNUNET_BLOCK_Type type, |
251 | struct GSF_PendingRequest *pr) | ||
251 | { | 252 | { |
252 | if (NULL != pr->bg) | 253 | if (NULL != pr->bg) |
253 | { | 254 | { |
@@ -406,7 +407,7 @@ GSF_pending_request_create_ (enum GSF_PendingRequestOptions options, | |||
406 | break; /* let the request live briefly... */ | 407 | break; /* let the request live briefly... */ |
407 | if (NULL != dpr->rh) | 408 | if (NULL != dpr->rh) |
408 | dpr->rh (dpr->rh_cls, | 409 | dpr->rh (dpr->rh_cls, |
409 | GNUNET_BLOCK_EVALUATION_REQUEST_VALID, | 410 | GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED, |
410 | dpr, | 411 | dpr, |
411 | UINT32_MAX, | 412 | UINT32_MAX, |
412 | GNUNET_TIME_UNIT_FOREVER_ABS, | 413 | GNUNET_TIME_UNIT_FOREVER_ABS, |
@@ -557,7 +558,10 @@ GSF_pending_request_get_message_ (struct GSF_PendingRequest *pr) | |||
557 | k++; | 558 | k++; |
558 | } | 559 | } |
559 | if (GNUNET_OK != | 560 | if (GNUNET_OK != |
560 | GNUNET_BLOCK_group_serialize (pr->bg, &bf_nonce, &bf_data, &bf_size)) | 561 | GNUNET_BLOCK_group_serialize (pr->bg, |
562 | &bf_nonce, | ||
563 | &bf_data, | ||
564 | &bf_size)) | ||
561 | { | 565 | { |
562 | bf_size = 0; | 566 | bf_size = 0; |
563 | bf_data = NULL; | 567 | bf_data = NULL; |
@@ -765,11 +769,6 @@ struct ProcessReplyClosure | |||
765 | enum GNUNET_BLOCK_Type type; | 769 | enum GNUNET_BLOCK_Type type; |
766 | 770 | ||
767 | /** | 771 | /** |
768 | * Control flags for evaluation. | ||
769 | */ | ||
770 | enum GNUNET_BLOCK_EvaluationOptions eo; | ||
771 | |||
772 | /** | ||
773 | * How much was this reply worth to us? | 772 | * How much was this reply worth to us? |
774 | */ | 773 | */ |
775 | uint32_t priority; | 774 | uint32_t priority; |
@@ -850,7 +849,6 @@ process_reply (void *cls, | |||
850 | case GNUNET_BLOCK_REPLY_OK_MORE: | 849 | case GNUNET_BLOCK_REPLY_OK_MORE: |
851 | update_request_performance_data (prq, pr); | 850 | update_request_performance_data (prq, pr); |
852 | break; | 851 | break; |
853 | |||
854 | case GNUNET_BLOCK_REPLY_OK_LAST: | 852 | case GNUNET_BLOCK_REPLY_OK_LAST: |
855 | /* short cut: stop processing early, no BF-update, etc. */ | 853 | /* short cut: stop processing early, no BF-update, etc. */ |
856 | update_request_performance_data (prq, pr); | 854 | update_request_performance_data (prq, pr); |
@@ -885,7 +883,6 @@ process_reply (void *cls, | |||
885 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 883 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
886 | "Duplicate response, discarding.\n"); | 884 | "Duplicate response, discarding.\n"); |
887 | return GNUNET_YES; /* duplicate */ | 885 | return GNUNET_YES; /* duplicate */ |
888 | |||
889 | case GNUNET_BLOCK_REPLY_IRRELEVANT: | 886 | case GNUNET_BLOCK_REPLY_IRRELEVANT: |
890 | GNUNET_STATISTICS_update (GSF_stats, | 887 | GNUNET_STATISTICS_update (GSF_stats, |
891 | "# irrelevant replies discarded", | 888 | "# irrelevant replies discarded", |
@@ -894,8 +891,6 @@ process_reply (void *cls, | |||
894 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 891 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
895 | "Irrelevant response, ignoring.\n"); | 892 | "Irrelevant response, ignoring.\n"); |
896 | return GNUNET_YES; | 893 | return GNUNET_YES; |
897 | case GNUNET_BLOCK_REPLY_INVALID: | ||
898 | return GNUNET_YES; | ||
899 | case GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED: | 894 | case GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED: |
900 | GNUNET_break (0); /* bad installation? */ | 895 | GNUNET_break (0); /* bad installation? */ |
901 | return GNUNET_NO; | 896 | return GNUNET_NO; |
@@ -1127,8 +1122,9 @@ handle_dht_reply (void *cls, | |||
1127 | prq.expiration); | 1122 | prq.expiration); |
1128 | prq.size = size; | 1123 | prq.size = size; |
1129 | prq.type = type; | 1124 | prq.type = type; |
1130 | prq.eo = GNUNET_BLOCK_EO_NONE; | 1125 | process_reply (&prq, |
1131 | process_reply (&prq, key, pr); | 1126 | key, |
1127 | pr); | ||
1132 | if ((GNUNET_YES == active_to_migration) && | 1128 | if ((GNUNET_YES == active_to_migration) && |
1133 | (GNUNET_NO == test_put_load_too_high (prq.priority))) | 1129 | (GNUNET_NO == test_put_load_too_high (prq.priority))) |
1134 | { | 1130 | { |
@@ -1229,6 +1225,15 @@ cadet_reply_proc (void *cls, | |||
1229 | struct GNUNET_HashCode query; | 1225 | struct GNUNET_HashCode query; |
1230 | 1226 | ||
1231 | pr->cadet_request = NULL; | 1227 | pr->cadet_request = NULL; |
1228 | if (GNUNET_OK != | ||
1229 | GNUNET_BLOCK_check_block (GSF_block_ctx, | ||
1230 | type, | ||
1231 | data, | ||
1232 | data_size)) | ||
1233 | { | ||
1234 | GNUNET_break_op (0); | ||
1235 | return; | ||
1236 | } | ||
1232 | if (GNUNET_BLOCK_TYPE_ANY == type) | 1237 | if (GNUNET_BLOCK_TYPE_ANY == type) |
1233 | { | 1238 | { |
1234 | GNUNET_break (NULL == data); | 1239 | GNUNET_break (NULL == data); |
@@ -1247,7 +1252,11 @@ cadet_reply_proc (void *cls, | |||
1247 | return; | 1252 | return; |
1248 | } | 1253 | } |
1249 | if (GNUNET_YES != | 1254 | if (GNUNET_YES != |
1250 | GNUNET_BLOCK_get_key (GSF_block_ctx, type, data, data_size, &query)) | 1255 | GNUNET_BLOCK_get_key (GSF_block_ctx, |
1256 | type, | ||
1257 | data, | ||
1258 | data_size, | ||
1259 | &query)) | ||
1251 | { | 1260 | { |
1252 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1261 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1253 | "Failed to derive key for block of type %d\n", | 1262 | "Failed to derive key for block of type %d\n", |
@@ -1268,8 +1277,9 @@ cadet_reply_proc (void *cls, | |||
1268 | prq.expiration); | 1277 | prq.expiration); |
1269 | prq.size = data_size; | 1278 | prq.size = data_size; |
1270 | prq.type = type; | 1279 | prq.type = type; |
1271 | prq.eo = GNUNET_BLOCK_EO_NONE; | 1280 | process_reply (&prq, |
1272 | process_reply (&prq, &query, pr); | 1281 | &query, |
1282 | pr); | ||
1273 | } | 1283 | } |
1274 | 1284 | ||
1275 | 1285 | ||
@@ -1611,7 +1621,11 @@ called_from_on_demand: | |||
1611 | prq.expiration = expiration; | 1621 | prq.expiration = expiration; |
1612 | prq.size = size; | 1622 | prq.size = size; |
1613 | if (GNUNET_OK != | 1623 | if (GNUNET_OK != |
1614 | GNUNET_BLOCK_get_key (GSF_block_ctx, type, data, size, &query)) | 1624 | GNUNET_BLOCK_get_key (GSF_block_ctx, |
1625 | type, | ||
1626 | data, | ||
1627 | size, | ||
1628 | &query)) | ||
1615 | { | 1629 | { |
1616 | GNUNET_break (0); | 1630 | GNUNET_break (0); |
1617 | GNUNET_DATASTORE_remove (GSF_dsh, | 1631 | GNUNET_DATASTORE_remove (GSF_dsh, |
@@ -1631,8 +1645,9 @@ called_from_on_demand: | |||
1631 | prq.anonymity_level = anonymity; | 1645 | prq.anonymity_level = anonymity; |
1632 | if ((0 == old_rf) && (0 == pr->public_data.results_found)) | 1646 | if ((0 == old_rf) && (0 == pr->public_data.results_found)) |
1633 | GSF_update_datastore_delay_ (pr->public_data.start_time); | 1647 | GSF_update_datastore_delay_ (pr->public_data.start_time); |
1634 | prq.eo = GNUNET_BLOCK_EO_LOCAL_SKIP_CRYPTO; | 1648 | process_reply (&prq, |
1635 | process_reply (&prq, key, pr); | 1649 | key, |
1650 | pr); | ||
1636 | pr->local_result = prq.eval; | 1651 | pr->local_result = prq.eval; |
1637 | if (GNUNET_BLOCK_REPLY_OK_LAST == prq.eval) | 1652 | if (GNUNET_BLOCK_REPLY_OK_LAST == prq.eval) |
1638 | { | 1653 | { |
@@ -1720,7 +1735,8 @@ GSF_local_lookup_ (struct GSF_PendingRequest *pr, | |||
1720 | * @param put the actual message | 1735 | * @param put the actual message |
1721 | */ | 1736 | */ |
1722 | void | 1737 | void |
1723 | handle_p2p_put (void *cls, const struct PutMessage *put) | 1738 | handle_p2p_put (void *cls, |
1739 | const struct PutMessage *put) | ||
1724 | { | 1740 | { |
1725 | struct GSF_ConnectedPeer *cp = cls; | 1741 | struct GSF_ConnectedPeer *cp = cls; |
1726 | uint16_t msize; | 1742 | uint16_t msize; |
@@ -1746,7 +1762,20 @@ handle_p2p_put (void *cls, const struct PutMessage *put) | |||
1746 | GNUNET_TIME_UNIT_YEARS), | 1762 | GNUNET_TIME_UNIT_YEARS), |
1747 | expiration); | 1763 | expiration); |
1748 | if (GNUNET_OK != | 1764 | if (GNUNET_OK != |
1749 | GNUNET_BLOCK_get_key (GSF_block_ctx, type, &put[1], dsize, &query)) | 1765 | GNUNET_BLOCK_check_block (GSF_block_ctx, |
1766 | type, | ||
1767 | &put[1], | ||
1768 | dsize)) | ||
1769 | { | ||
1770 | GNUNET_break_op (0); | ||
1771 | return; | ||
1772 | } | ||
1773 | if (GNUNET_OK != | ||
1774 | GNUNET_BLOCK_get_key (GSF_block_ctx, | ||
1775 | type, | ||
1776 | &put[1], | ||
1777 | dsize, | ||
1778 | &query)) | ||
1750 | { | 1779 | { |
1751 | GNUNET_break_op (0); | 1780 | GNUNET_break_op (0); |
1752 | return; | 1781 | return; |
@@ -1764,7 +1793,6 @@ handle_p2p_put (void *cls, const struct PutMessage *put) | |||
1764 | prq.priority = 0; | 1793 | prq.priority = 0; |
1765 | prq.anonymity_level = UINT32_MAX; | 1794 | prq.anonymity_level = UINT32_MAX; |
1766 | prq.request_found = GNUNET_NO; | 1795 | prq.request_found = GNUNET_NO; |
1767 | prq.eo = GNUNET_BLOCK_EO_NONE; | ||
1768 | GNUNET_CONTAINER_multihashmap_get_multiple (pr_map, | 1796 | GNUNET_CONTAINER_multihashmap_get_multiple (pr_map, |
1769 | &query, | 1797 | &query, |
1770 | &process_reply, | 1798 | &process_reply, |
diff --git a/src/fs/plugin_block_fs.c b/src/fs/plugin_block_fs.c index 43380b3b6..029f95bc5 100644 --- a/src/fs/plugin_block_fs.c +++ b/src/fs/plugin_block_fs.c | |||
@@ -111,110 +111,6 @@ block_plugin_fs_create_group (void *cls, | |||
111 | 111 | ||
112 | 112 | ||
113 | /** | 113 | /** |
114 | * Function called to validate a reply or a request. For | ||
115 | * request evaluation, simply pass "NULL" for the reply_block. | ||
116 | * Note that it is assumed that the reply has already been | ||
117 | * matched to the key (and signatures checked) as it would | ||
118 | * be done with the #GNUNET_BLOCK_get_key() function. | ||
119 | * | ||
120 | * @param cls closure | ||
121 | * @param ctx block context | ||
122 | * @param type block type | ||
123 | * @param bg group to use for evaluation | ||
124 | * @param eo control flags | ||
125 | * @param query original query (hash) | ||
126 | * @param xquery extrended query data (can be NULL, depending on type) | ||
127 | * @param xquery_size number of bytes in @a xquery | ||
128 | * @param reply_block response to validate | ||
129 | * @param reply_block_size number of bytes in @a reply_block | ||
130 | * @return characterization of result | ||
131 | */ | ||
132 | static enum GNUNET_BLOCK_EvaluationResult | ||
133 | block_plugin_fs_evaluate (void *cls, | ||
134 | struct GNUNET_BLOCK_Context *ctx, | ||
135 | enum GNUNET_BLOCK_Type type, | ||
136 | struct GNUNET_BLOCK_Group *bg, | ||
137 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
138 | const struct GNUNET_HashCode *query, | ||
139 | const void *xquery, | ||
140 | size_t xquery_size, | ||
141 | const void *reply_block, | ||
142 | size_t reply_block_size) | ||
143 | { | ||
144 | const struct UBlock *ub; | ||
145 | struct GNUNET_HashCode hc; | ||
146 | struct GNUNET_HashCode chash; | ||
147 | |||
148 | switch (type) | ||
149 | { | ||
150 | case GNUNET_BLOCK_TYPE_FS_DBLOCK: | ||
151 | case GNUNET_BLOCK_TYPE_FS_IBLOCK: | ||
152 | if (0 != xquery_size) | ||
153 | { | ||
154 | GNUNET_break_op (0); | ||
155 | return GNUNET_BLOCK_EVALUATION_REQUEST_INVALID; | ||
156 | } | ||
157 | if (NULL == reply_block) | ||
158 | return GNUNET_BLOCK_EVALUATION_REQUEST_VALID; | ||
159 | return GNUNET_BLOCK_EVALUATION_OK_LAST; | ||
160 | |||
161 | case GNUNET_BLOCK_TYPE_FS_UBLOCK: | ||
162 | if (0 != xquery_size) | ||
163 | { | ||
164 | GNUNET_break_op (0); | ||
165 | return GNUNET_BLOCK_EVALUATION_REQUEST_INVALID; | ||
166 | } | ||
167 | if (NULL == reply_block) | ||
168 | return GNUNET_BLOCK_EVALUATION_REQUEST_VALID; | ||
169 | |||
170 | if (reply_block_size < sizeof(struct UBlock)) | ||
171 | { | ||
172 | GNUNET_break_op (0); | ||
173 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
174 | } | ||
175 | ub = reply_block; | ||
176 | GNUNET_CRYPTO_hash (&ub->verification_key, | ||
177 | sizeof(ub->verification_key), | ||
178 | &hc); | ||
179 | if (0 != memcmp (&hc, | ||
180 | query, | ||
181 | sizeof(struct GNUNET_HashCode))) | ||
182 | { | ||
183 | GNUNET_break_op (0); | ||
184 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
185 | } | ||
186 | if (reply_block_size != ntohl (ub->purpose.size) + sizeof(struct | ||
187 | GNUNET_CRYPTO_EcdsaSignature)) | ||
188 | { | ||
189 | GNUNET_break_op (0); | ||
190 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
191 | } | ||
192 | if ((0 == (eo & GNUNET_BLOCK_EO_LOCAL_SKIP_CRYPTO)) && | ||
193 | (GNUNET_OK != | ||
194 | GNUNET_CRYPTO_ecdsa_verify_ (GNUNET_SIGNATURE_PURPOSE_FS_UBLOCK, | ||
195 | &ub->purpose, | ||
196 | &ub->signature, | ||
197 | &ub->verification_key))) | ||
198 | { | ||
199 | GNUNET_break_op (0); | ||
200 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
201 | } | ||
202 | GNUNET_CRYPTO_hash (reply_block, | ||
203 | reply_block_size, | ||
204 | &chash); | ||
205 | if (GNUNET_YES == | ||
206 | GNUNET_BLOCK_GROUP_bf_test_and_set (bg, | ||
207 | &chash)) | ||
208 | return GNUNET_BLOCK_EVALUATION_OK_DUPLICATE; | ||
209 | return GNUNET_BLOCK_EVALUATION_OK_MORE; | ||
210 | |||
211 | default: | ||
212 | return GNUNET_BLOCK_EVALUATION_TYPE_NOT_SUPPORTED; | ||
213 | } | ||
214 | } | ||
215 | |||
216 | |||
217 | /** | ||
218 | * Function called to obtain the key for a block. | 114 | * Function called to obtain the key for a block. |
219 | * | 115 | * |
220 | * @param cls closure | 116 | * @param cls closure |
@@ -245,8 +141,11 @@ block_plugin_fs_get_key (void *cls, | |||
245 | case GNUNET_BLOCK_TYPE_FS_UBLOCK: | 141 | case GNUNET_BLOCK_TYPE_FS_UBLOCK: |
246 | if (block_size < sizeof(struct UBlock)) | 142 | if (block_size < sizeof(struct UBlock)) |
247 | { | 143 | { |
248 | GNUNET_break (0); | 144 | GNUNET_break_op (0); |
249 | return GNUNET_SYSERR; | 145 | memset (key, |
146 | 0, | ||
147 | sizeof (*key)); | ||
148 | return GNUNET_OK; | ||
250 | } | 149 | } |
251 | ub = block; | 150 | ub = block; |
252 | GNUNET_CRYPTO_hash (&ub->verification_key, | 151 | GNUNET_CRYPTO_hash (&ub->verification_key, |
@@ -290,6 +189,7 @@ block_plugin_fs_check_query (void *cls, | |||
290 | } | 189 | } |
291 | return GNUNET_OK; | 190 | return GNUNET_OK; |
292 | default: | 191 | default: |
192 | GNUNET_break (0); | ||
293 | return GNUNET_SYSERR; | 193 | return GNUNET_SYSERR; |
294 | } | 194 | } |
295 | } | 195 | } |
@@ -300,7 +200,6 @@ block_plugin_fs_check_query (void *cls, | |||
300 | * | 200 | * |
301 | * @param cls closure | 201 | * @param cls closure |
302 | * @param type block type | 202 | * @param type block type |
303 | * @param query key for the block (hash), must match exactly | ||
304 | * @param block block data to validate | 203 | * @param block block data to validate |
305 | * @param block_size number of bytes in @a block | 204 | * @param block_size number of bytes in @a block |
306 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not | 205 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not |
@@ -308,7 +207,6 @@ block_plugin_fs_check_query (void *cls, | |||
308 | static enum GNUNET_GenericReturnValue | 207 | static enum GNUNET_GenericReturnValue |
309 | block_plugin_fs_check_block (void *cls, | 208 | block_plugin_fs_check_block (void *cls, |
310 | enum GNUNET_BLOCK_Type type, | 209 | enum GNUNET_BLOCK_Type type, |
311 | const struct GNUNET_HashCode *query, | ||
312 | const void *block, | 210 | const void *block, |
313 | size_t block_size) | 211 | size_t block_size) |
314 | { | 212 | { |
@@ -346,6 +244,7 @@ block_plugin_fs_check_block (void *cls, | |||
346 | return GNUNET_OK; | 244 | return GNUNET_OK; |
347 | } | 245 | } |
348 | default: | 246 | default: |
247 | GNUNET_break (0); | ||
349 | return GNUNET_SYSERR; | 248 | return GNUNET_SYSERR; |
350 | } | 249 | } |
351 | } | 250 | } |
@@ -396,6 +295,7 @@ block_plugin_fs_check_reply (void *cls, | |||
396 | return GNUNET_BLOCK_REPLY_OK_MORE; | 295 | return GNUNET_BLOCK_REPLY_OK_MORE; |
397 | } | 296 | } |
398 | default: | 297 | default: |
298 | GNUNET_break (0); | ||
399 | return GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED; | 299 | return GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED; |
400 | } | 300 | } |
401 | } | 301 | } |
@@ -416,7 +316,6 @@ libgnunet_plugin_block_fs_init (void *cls) | |||
416 | struct GNUNET_BLOCK_PluginFunctions *api; | 316 | struct GNUNET_BLOCK_PluginFunctions *api; |
417 | 317 | ||
418 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); | 318 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); |
419 | api->evaluate = &block_plugin_fs_evaluate; | ||
420 | api->get_key = &block_plugin_fs_get_key; | 319 | api->get_key = &block_plugin_fs_get_key; |
421 | api->create_group = &block_plugin_fs_create_group; | 320 | api->create_group = &block_plugin_fs_create_group; |
422 | api->check_query = &block_plugin_fs_check_query; | 321 | api->check_query = &block_plugin_fs_check_query; |
diff --git a/src/gns/Makefile.am b/src/gns/Makefile.am index 315b4dbf3..d49e0c5c8 100644 --- a/src/gns/Makefile.am +++ b/src/gns/Makefile.am | |||
@@ -155,6 +155,7 @@ gnunet_dns2gns_LDADD = \ | |||
155 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | 155 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ |
156 | libgnunetgns.la \ | 156 | libgnunetgns.la \ |
157 | $(top_builddir)/src/util/libgnunetutil.la \ | 157 | $(top_builddir)/src/util/libgnunetutil.la \ |
158 | $(USE_VPN) \ | ||
158 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 159 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
159 | $(GN_LIBINTL) | 160 | $(GN_LIBINTL) |
160 | 161 | ||
@@ -218,7 +219,6 @@ gnunet_service_gns_LDADD = \ | |||
218 | $(top_builddir)/src/dht/libgnunetdht.la \ | 219 | $(top_builddir)/src/dht/libgnunetdht.la \ |
219 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ | 220 | $(top_builddir)/src/namecache/libgnunetnamecache.la \ |
220 | $(LIBIDN) $(LIBIDN2) \ | 221 | $(LIBIDN) $(LIBIDN2) \ |
221 | $(USE_VPN) \ | ||
222 | $(GN_LIBINTL) | 222 | $(GN_LIBINTL) |
223 | 223 | ||
224 | 224 | ||
@@ -270,8 +270,7 @@ check_SCRIPTS = \ | |||
270 | test_gns_rel_expiration.sh\ | 270 | test_gns_rel_expiration.sh\ |
271 | test_gns_soa_lookup.sh\ | 271 | test_gns_soa_lookup.sh\ |
272 | test_gns_revocation.sh\ | 272 | test_gns_revocation.sh\ |
273 | test_gns_cname_lookup.sh\ | 273 | test_gns_redirect_lookup.sh |
274 | test_proxy.sh | ||
275 | 274 | ||
276 | if HAVE_GNUTLS | 275 | if HAVE_GNUTLS |
277 | if HAVE_LIBGNURL | 276 | if HAVE_LIBGNURL |
@@ -292,7 +291,26 @@ EXTRA_DIST = \ | |||
292 | zonefiles/J7POEUT41A8PBFS7KVVDRF88GBOU4HK8PSU5QKVLVE3R9T91E99G.zkey \ | 291 | zonefiles/J7POEUT41A8PBFS7KVVDRF88GBOU4HK8PSU5QKVLVE3R9T91E99G.zkey \ |
293 | zonefiles/OEFL7A4VEF1B40QLEMTG5D8G1CN6EN16QUSG5R2DT71GRJN34LSG.zkey \ | 292 | zonefiles/OEFL7A4VEF1B40QLEMTG5D8G1CN6EN16QUSG5R2DT71GRJN34LSG.zkey \ |
294 | zonefiles/test_zonekey \ | 293 | zonefiles/test_zonekey \ |
295 | $(check_SCRIPTS) \ | 294 | test_gns_lookup.sh \ |
295 | test_gns_config_lookup.sh \ | ||
296 | test_gns_ipv6_lookup.sh\ | ||
297 | test_gns_txt_lookup.sh\ | ||
298 | test_gns_caa_lookup.sh\ | ||
299 | test_gns_mx_lookup.sh \ | ||
300 | test_gns_gns2dns_lookup.sh \ | ||
301 | test_gns_gns2dns_zkey_lookup.sh \ | ||
302 | test_gns_gns2dns_cname_lookup.sh \ | ||
303 | test_gns_dht_lookup.sh\ | ||
304 | test_gns_delegated_lookup.sh \ | ||
305 | test_gns_at_lookup.sh\ | ||
306 | test_gns_zkey_lookup.sh\ | ||
307 | test_gns_rel_expiration.sh\ | ||
308 | test_gns_soa_lookup.sh\ | ||
309 | test_gns_revocation.sh\ | ||
310 | test_gns_redirect_lookup.sh\ | ||
311 | test_proxy.sh\ | ||
312 | test_plugin_rest_gns.sh\ | ||
313 | test_proxy.sh \ | ||
296 | $(pkgdata_DATA) \ | 314 | $(pkgdata_DATA) \ |
297 | test_gnunet_gns.sh.in | 315 | test_gnunet_gns.sh.in |
298 | 316 | ||
diff --git a/src/gns/gnunet-bcd.c b/src/gns/gnunet-bcd.c index 83efcfba5..60fe25945 100644 --- a/src/gns/gnunet-bcd.c +++ b/src/gns/gnunet-bcd.c | |||
@@ -419,6 +419,8 @@ create_response (void *cls, | |||
419 | "\\def\\gpglineone{%s}\n\\def\\gpglinetwo{%s}\n", | 419 | "\\def\\gpglineone{%s}\n\\def\\gpglinetwo{%s}\n", |
420 | line1, | 420 | line1, |
421 | line2); | 421 | line2); |
422 | GNUNET_free (line1); | ||
423 | GNUNET_free (line2); | ||
422 | } | 424 | } |
423 | 425 | ||
424 | fprintf (deffile, | 426 | fprintf (deffile, |
diff --git a/src/gns/gnunet-dns2gns.c b/src/gns/gnunet-dns2gns.c index 06f4c9841..46659cdda 100644 --- a/src/gns/gnunet-dns2gns.c +++ b/src/gns/gnunet-dns2gns.c | |||
@@ -27,6 +27,7 @@ | |||
27 | #include <gnunet_dnsparser_lib.h> | 27 | #include <gnunet_dnsparser_lib.h> |
28 | #include <gnunet_gns_service.h> | 28 | #include <gnunet_gns_service.h> |
29 | #include <gnunet_dnsstub_lib.h> | 29 | #include <gnunet_dnsstub_lib.h> |
30 | #include "gnunet_vpn_service.h" | ||
30 | #include "gns.h" | 31 | #include "gns.h" |
31 | 32 | ||
32 | /** | 33 | /** |
@@ -35,6 +36,46 @@ | |||
35 | #define TIMEOUT GNUNET_TIME_UNIT_MINUTES | 36 | #define TIMEOUT GNUNET_TIME_UNIT_MINUTES |
36 | 37 | ||
37 | /** | 38 | /** |
39 | * Default timeout for VPN redirections. | ||
40 | */ | ||
41 | #define VPN_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 30) | ||
42 | |||
43 | |||
44 | struct Request; | ||
45 | |||
46 | /** | ||
47 | * Closure for #vpn_allocation_cb. | ||
48 | */ | ||
49 | struct VpnContext | ||
50 | { | ||
51 | /** | ||
52 | * Which resolution process are we processing. | ||
53 | */ | ||
54 | struct Request *request; | ||
55 | |||
56 | /** | ||
57 | * Handle to the VPN request that we were performing. | ||
58 | */ | ||
59 | struct GNUNET_VPN_RedirectionRequest *vpn_request; | ||
60 | |||
61 | /** | ||
62 | * Number of records serialized in @e rd_data. | ||
63 | */ | ||
64 | unsigned int rd_count; | ||
65 | |||
66 | /** | ||
67 | * Serialized records. | ||
68 | */ | ||
69 | char *rd_data; | ||
70 | |||
71 | /** | ||
72 | * Number of bytes in @e rd_data. | ||
73 | */ | ||
74 | ssize_t rd_data_size; | ||
75 | }; | ||
76 | |||
77 | |||
78 | /** | ||
38 | * Data kept per request. | 79 | * Data kept per request. |
39 | */ | 80 | */ |
40 | struct Request | 81 | struct Request |
@@ -72,6 +113,11 @@ struct Request | |||
72 | struct GNUNET_SCHEDULER_Task *timeout_task; | 113 | struct GNUNET_SCHEDULER_Task *timeout_task; |
73 | 114 | ||
74 | /** | 115 | /** |
116 | * Vpn resulution context | ||
117 | */ | ||
118 | struct VpnContext *vpn_ctx; | ||
119 | |||
120 | /** | ||
75 | * Original UDP request message. | 121 | * Original UDP request message. |
76 | */ | 122 | */ |
77 | char *udp_msg; | 123 | char *udp_msg; |
@@ -90,6 +136,7 @@ struct Request | |||
90 | * ID of the original request. | 136 | * ID of the original request. |
91 | */ | 137 | */ |
92 | uint16_t original_request_id; | 138 | uint16_t original_request_id; |
139 | |||
93 | }; | 140 | }; |
94 | 141 | ||
95 | /** | 142 | /** |
@@ -109,6 +156,11 @@ static struct in6_addr address6; | |||
109 | struct GNUNET_GNS_Handle *gns; | 156 | struct GNUNET_GNS_Handle *gns; |
110 | 157 | ||
111 | /** | 158 | /** |
159 | * Our handle to the vpn service | ||
160 | */ | ||
161 | static struct GNUNET_VPN_Handle *vpn_handle; | ||
162 | |||
163 | /** | ||
112 | * Stub resolver | 164 | * Stub resolver |
113 | */ | 165 | */ |
114 | struct GNUNET_DNSSTUB_Context *dns_stub; | 166 | struct GNUNET_DNSSTUB_Context *dns_stub; |
@@ -183,6 +235,11 @@ do_shutdown (void *cls) | |||
183 | GNUNET_GNS_disconnect (gns); | 235 | GNUNET_GNS_disconnect (gns); |
184 | gns = NULL; | 236 | gns = NULL; |
185 | } | 237 | } |
238 | if (NULL != vpn_handle) | ||
239 | { | ||
240 | GNUNET_VPN_disconnect (vpn_handle); | ||
241 | vpn_handle = NULL; | ||
242 | } | ||
186 | if (NULL != dns_stub) | 243 | if (NULL != dns_stub) |
187 | { | 244 | { |
188 | GNUNET_DNSSTUB_stop (dns_stub); | 245 | GNUNET_DNSSTUB_stop (dns_stub); |
@@ -269,6 +326,7 @@ static void | |||
269 | do_timeout (void *cls) | 326 | do_timeout (void *cls) |
270 | { | 327 | { |
271 | struct Request *request = cls; | 328 | struct Request *request = cls; |
329 | struct VpnContext *vpn_ctx; | ||
272 | 330 | ||
273 | if (NULL != request->packet) | 331 | if (NULL != request->packet) |
274 | GNUNET_DNSPARSER_free_packet (request->packet); | 332 | GNUNET_DNSPARSER_free_packet (request->packet); |
@@ -277,6 +335,12 @@ do_timeout (void *cls) | |||
277 | if (NULL != request->dns_lookup) | 335 | if (NULL != request->dns_lookup) |
278 | GNUNET_DNSSTUB_resolve_cancel (request->dns_lookup); | 336 | GNUNET_DNSSTUB_resolve_cancel (request->dns_lookup); |
279 | GNUNET_free (request->udp_msg); | 337 | GNUNET_free (request->udp_msg); |
338 | if (NULL != (vpn_ctx = request->vpn_ctx)) | ||
339 | { | ||
340 | GNUNET_VPN_cancel_request (vpn_ctx->vpn_request); | ||
341 | GNUNET_free (vpn_ctx->rd_data); | ||
342 | GNUNET_free (vpn_ctx); | ||
343 | } | ||
280 | GNUNET_free (request); | 344 | GNUNET_free (request); |
281 | } | 345 | } |
282 | 346 | ||
@@ -321,6 +385,79 @@ dns_result_processor (void *cls, | |||
321 | send_response (request); | 385 | send_response (request); |
322 | } | 386 | } |
323 | 387 | ||
388 | /** | ||
389 | * Callback invoked from the VPN service once a redirection is | ||
390 | * available. Provides the IP address that can now be used to | ||
391 | * reach the requested destination. Replaces the "VPN" record | ||
392 | * with the respective A/AAAA record and continues processing. | ||
393 | * | ||
394 | * @param cls closure | ||
395 | * @param af address family, AF_INET or AF_INET6; AF_UNSPEC on error; | ||
396 | * will match 'result_af' from the request | ||
397 | * @param address IP address (struct in_addr or struct in_addr6, depending on 'af') | ||
398 | * that the VPN allocated for the redirection; | ||
399 | * traffic to this IP will now be redirected to the | ||
400 | * specified target peer; NULL on error | ||
401 | */ | ||
402 | static void | ||
403 | vpn_allocation_cb (void *cls, | ||
404 | int af, | ||
405 | const void *address) | ||
406 | { | ||
407 | struct VpnContext *vpn_ctx = cls; | ||
408 | struct Request *request = vpn_ctx->request; | ||
409 | struct GNUNET_GNSRECORD_Data rd[vpn_ctx->rd_count]; | ||
410 | unsigned int i; | ||
411 | |||
412 | vpn_ctx->vpn_request = NULL; | ||
413 | request->vpn_ctx = NULL; | ||
414 | GNUNET_assert (GNUNET_OK == | ||
415 | GNUNET_GNSRECORD_records_deserialize ( | ||
416 | (size_t) vpn_ctx->rd_data_size, | ||
417 | vpn_ctx->rd_data, | ||
418 | vpn_ctx->rd_count, | ||
419 | rd)); | ||
420 | for (i = 0; i < vpn_ctx->rd_count; i++) | ||
421 | { | ||
422 | if (GNUNET_GNSRECORD_TYPE_VPN == rd[i].record_type) | ||
423 | { | ||
424 | switch (af) | ||
425 | { | ||
426 | case AF_INET: | ||
427 | rd[i].record_type = GNUNET_DNSPARSER_TYPE_A; | ||
428 | rd[i].data_size = sizeof(struct in_addr); | ||
429 | rd[i].expiration_time = GNUNET_TIME_relative_to_absolute ( | ||
430 | VPN_TIMEOUT).abs_value_us; | ||
431 | rd[i].flags = 0; | ||
432 | rd[i].data = address; | ||
433 | break; | ||
434 | |||
435 | case AF_INET6: | ||
436 | rd[i].record_type = GNUNET_DNSPARSER_TYPE_AAAA; | ||
437 | rd[i].expiration_time = GNUNET_TIME_relative_to_absolute ( | ||
438 | VPN_TIMEOUT).abs_value_us; | ||
439 | rd[i].flags = 0; | ||
440 | rd[i].data = address; | ||
441 | rd[i].data_size = sizeof(struct in6_addr); | ||
442 | break; | ||
443 | |||
444 | default: | ||
445 | GNUNET_assert (0); | ||
446 | } | ||
447 | break; | ||
448 | } | ||
449 | } | ||
450 | GNUNET_assert (i < vpn_ctx->rd_count); | ||
451 | if (0 == vpn_ctx->rd_count) | ||
452 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | ||
453 | _ ("VPN returned empty result for `%s'\n"), | ||
454 | request->packet->queries[0].name); | ||
455 | send_response (request); | ||
456 | GNUNET_free (vpn_ctx->rd_data); | ||
457 | GNUNET_free (vpn_ctx); | ||
458 | } | ||
459 | |||
460 | |||
324 | 461 | ||
325 | /** | 462 | /** |
326 | * Iterator called on obtained result for a GNS lookup. | 463 | * Iterator called on obtained result for a GNS lookup. |
@@ -339,6 +476,11 @@ result_processor (void *cls, | |||
339 | struct Request *request = cls; | 476 | struct Request *request = cls; |
340 | struct GNUNET_DNSPARSER_Packet *packet; | 477 | struct GNUNET_DNSPARSER_Packet *packet; |
341 | struct GNUNET_DNSPARSER_Record rec; | 478 | struct GNUNET_DNSPARSER_Record rec; |
479 | struct VpnContext *vpn_ctx; | ||
480 | const struct GNUNET_TUN_GnsVpnRecord *vpn; | ||
481 | const char *vname; | ||
482 | struct GNUNET_HashCode vhash; | ||
483 | int af; | ||
342 | 484 | ||
343 | request->lookup = NULL; | 485 | request->lookup = NULL; |
344 | if (GNUNET_NO == was_gns) | 486 | if (GNUNET_NO == was_gns) |
@@ -415,6 +557,67 @@ result_processor (void *cls, | |||
415 | packet->num_answers, | 557 | packet->num_answers, |
416 | rec); | 558 | rec); |
417 | break; | 559 | break; |
560 | case GNUNET_GNSRECORD_TYPE_VPN: | ||
561 | if ((GNUNET_DNSPARSER_TYPE_A != request->packet->queries[0].type) && | ||
562 | (GNUNET_DNSPARSER_TYPE_AAAA != request->packet->queries[0].type)) | ||
563 | break; | ||
564 | af = (GNUNET_DNSPARSER_TYPE_A == request->packet->queries[0].type) ? AF_INET : | ||
565 | AF_INET6; | ||
566 | if (sizeof(struct GNUNET_TUN_GnsVpnRecord) > | ||
567 | rd[i].data_size) | ||
568 | { | ||
569 | GNUNET_break_op (0); | ||
570 | break; | ||
571 | } | ||
572 | vpn = (const struct GNUNET_TUN_GnsVpnRecord *) rd[i].data; | ||
573 | vname = (const char *) &vpn[1]; | ||
574 | if ('\0' != vname[rd[i].data_size - 1 - sizeof(struct | ||
575 | GNUNET_TUN_GnsVpnRecord) | ||
576 | ]) | ||
577 | { | ||
578 | GNUNET_break_op (0); | ||
579 | break; | ||
580 | } | ||
581 | GNUNET_TUN_service_name_to_hash (vname, | ||
582 | &vhash); | ||
583 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
584 | "Attempting VPN allocation for %s-%s (AF: %d, proto %d)\n", | ||
585 | GNUNET_i2s (&vpn->peer), | ||
586 | vname, | ||
587 | (int) af, | ||
588 | (int) ntohs (vpn->proto)); | ||
589 | vpn_ctx = GNUNET_new (struct VpnContext); | ||
590 | request->vpn_ctx = vpn_ctx; | ||
591 | vpn_ctx->request = request; | ||
592 | vpn_ctx->rd_data_size = GNUNET_GNSRECORD_records_get_size (rd_count, | ||
593 | rd); | ||
594 | if (vpn_ctx->rd_data_size < 0) | ||
595 | { | ||
596 | GNUNET_break_op (0); | ||
597 | GNUNET_free (vpn_ctx); | ||
598 | break; | ||
599 | } | ||
600 | vpn_ctx->rd_data = GNUNET_malloc ((size_t) vpn_ctx->rd_data_size); | ||
601 | vpn_ctx->rd_count = rd_count; | ||
602 | GNUNET_assert (vpn_ctx->rd_data_size == | ||
603 | GNUNET_GNSRECORD_records_serialize (rd_count, | ||
604 | rd, | ||
605 | (size_t) vpn_ctx | ||
606 | ->rd_data_size, | ||
607 | vpn_ctx->rd_data)); | ||
608 | vpn_ctx->vpn_request = GNUNET_VPN_redirect_to_peer (vpn_handle, | ||
609 | af, | ||
610 | ntohs ( | ||
611 | vpn->proto), | ||
612 | &vpn->peer, | ||
613 | &vhash, | ||
614 | GNUNET_TIME_relative_to_absolute ( | ||
615 | VPN_TIMEOUT), | ||
616 | & | ||
617 | vpn_allocation_cb, | ||
618 | vpn_ctx); | ||
619 | return; | ||
620 | |||
418 | 621 | ||
419 | default: | 622 | default: |
420 | /* skip */ | 623 | /* skip */ |
@@ -641,6 +844,8 @@ run (void *cls, | |||
641 | NULL); | 844 | NULL); |
642 | if (NULL == (gns = GNUNET_GNS_connect (cfg))) | 845 | if (NULL == (gns = GNUNET_GNS_connect (cfg))) |
643 | return; | 846 | return; |
847 | if (NULL == (vpn_handle = GNUNET_VPN_connect (cfg))) | ||
848 | return; | ||
644 | GNUNET_assert (NULL != (dns_stub = GNUNET_DNSSTUB_start (128))); | 849 | GNUNET_assert (NULL != (dns_stub = GNUNET_DNSSTUB_start (128))); |
645 | if (GNUNET_OK != | 850 | if (GNUNET_OK != |
646 | GNUNET_DNSSTUB_add_dns_ip (dns_stub, | 851 | GNUNET_DNSSTUB_add_dns_ip (dns_stub, |
@@ -649,6 +854,8 @@ run (void *cls, | |||
649 | GNUNET_DNSSTUB_stop (dns_stub); | 854 | GNUNET_DNSSTUB_stop (dns_stub); |
650 | GNUNET_GNS_disconnect (gns); | 855 | GNUNET_GNS_disconnect (gns); |
651 | gns = NULL; | 856 | gns = NULL; |
857 | GNUNET_VPN_disconnect (vpn_handle); | ||
858 | vpn_handle = NULL; | ||
652 | return; | 859 | return; |
653 | } | 860 | } |
654 | 861 | ||
@@ -750,6 +957,8 @@ run (void *cls, | |||
750 | { | 957 | { |
751 | GNUNET_GNS_disconnect (gns); | 958 | GNUNET_GNS_disconnect (gns); |
752 | gns = NULL; | 959 | gns = NULL; |
960 | GNUNET_VPN_disconnect (vpn_handle); | ||
961 | vpn_handle = NULL; | ||
753 | GNUNET_DNSSTUB_stop (dns_stub); | 962 | GNUNET_DNSSTUB_stop (dns_stub); |
754 | dns_stub = NULL; | 963 | dns_stub = NULL; |
755 | return; | 964 | return; |
diff --git a/src/gns/gnunet-service-gns.c b/src/gns/gnunet-service-gns.c index 5833f4d0b..b28236fed 100644 --- a/src/gns/gnunet-service-gns.c +++ b/src/gns/gnunet-service-gns.c | |||
@@ -420,15 +420,11 @@ handle_lookup (void *cls, | |||
420 | const struct LookupMessage *sh_msg) | 420 | const struct LookupMessage *sh_msg) |
421 | { | 421 | { |
422 | struct GnsClient *gc = cls; | 422 | struct GnsClient *gc = cls; |
423 | char name[GNUNET_DNSPARSER_MAX_NAME_LENGTH + 1]; | ||
424 | struct ClientLookupHandle *clh; | 423 | struct ClientLookupHandle *clh; |
425 | char *nameptr = name; | 424 | const char *name; |
426 | const char *utf_in; | ||
427 | 425 | ||
428 | GNUNET_SERVICE_client_continue (gc->client); | 426 | GNUNET_SERVICE_client_continue (gc->client); |
429 | utf_in = (const char *) &sh_msg[1]; | 427 | name = (const char *) &sh_msg[1]; |
430 | GNUNET_STRINGS_utf8_tolower (utf_in, | ||
431 | nameptr); | ||
432 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 428 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
433 | "Received LOOKUP `%s' message\n", | 429 | "Received LOOKUP `%s' message\n", |
434 | name); | 430 | name); |
diff --git a/src/gns/gnunet-service-gns_resolver.c b/src/gns/gnunet-service-gns_resolver.c index 51e650b4f..72b228f33 100644 --- a/src/gns/gnunet-service-gns_resolver.c +++ b/src/gns/gnunet-service-gns_resolver.c | |||
@@ -52,7 +52,6 @@ | |||
52 | #include "gns.h" | 52 | #include "gns.h" |
53 | #include "gnunet-service-gns.h" | 53 | #include "gnunet-service-gns.h" |
54 | #include "gnunet-service-gns_resolver.h" | 54 | #include "gnunet-service-gns_resolver.h" |
55 | #include "gnunet_vpn_service.h" | ||
56 | 55 | ||
57 | 56 | ||
58 | /** | 57 | /** |
@@ -68,11 +67,6 @@ | |||
68 | GNUNET_TIME_UNIT_SECONDS, 15) | 67 | GNUNET_TIME_UNIT_SECONDS, 15) |
69 | 68 | ||
70 | /** | 69 | /** |
71 | * Default timeout for VPN redirections. | ||
72 | */ | ||
73 | #define VPN_TIMEOUT GNUNET_TIME_relative_multiply (GNUNET_TIME_UNIT_MINUTES, 30) | ||
74 | |||
75 | /** | ||
76 | * DHT replication level | 70 | * DHT replication level |
77 | */ | 71 | */ |
78 | #define DHT_GNS_REPLICATION_LEVEL 10 | 72 | #define DHT_GNS_REPLICATION_LEVEL 10 |
@@ -255,38 +249,6 @@ struct DnsResult | |||
255 | 249 | ||
256 | 250 | ||
257 | /** | 251 | /** |
258 | * Closure for #vpn_allocation_cb. | ||
259 | */ | ||
260 | struct VpnContext | ||
261 | { | ||
262 | /** | ||
263 | * Which resolution process are we processing. | ||
264 | */ | ||
265 | struct GNS_ResolverHandle *rh; | ||
266 | |||
267 | /** | ||
268 | * Handle to the VPN request that we were performing. | ||
269 | */ | ||
270 | struct GNUNET_VPN_RedirectionRequest *vpn_request; | ||
271 | |||
272 | /** | ||
273 | * Number of records serialized in @e rd_data. | ||
274 | */ | ||
275 | unsigned int rd_count; | ||
276 | |||
277 | /** | ||
278 | * Serialized records. | ||
279 | */ | ||
280 | char *rd_data; | ||
281 | |||
282 | /** | ||
283 | * Number of bytes in @e rd_data. | ||
284 | */ | ||
285 | ssize_t rd_data_size; | ||
286 | }; | ||
287 | |||
288 | |||
289 | /** | ||
290 | * Handle to a currently pending resolution. On result (positive or | 252 | * Handle to a currently pending resolution. On result (positive or |
291 | * negative) the #GNS_ResultProcessor is called. | 253 | * negative) the #GNS_ResultProcessor is called. |
292 | */ | 254 | */ |
@@ -322,10 +284,6 @@ struct GNS_ResolverHandle | |||
322 | */ | 284 | */ |
323 | struct GNUNET_DHT_GetHandle *get_handle; | 285 | struct GNUNET_DHT_GetHandle *get_handle; |
324 | 286 | ||
325 | /** | ||
326 | * Handle to a VPN request, NULL if none is active. | ||
327 | */ | ||
328 | struct VpnContext *vpn_ctx; | ||
329 | 287 | ||
330 | /** | 288 | /** |
331 | * Socket for a DNS request, NULL if none is active. | 289 | * Socket for a DNS request, NULL if none is active. |
@@ -463,11 +421,6 @@ struct CacheOps | |||
463 | static struct GNUNET_NAMECACHE_Handle *namecache_handle; | 421 | static struct GNUNET_NAMECACHE_Handle *namecache_handle; |
464 | 422 | ||
465 | /** | 423 | /** |
466 | * Our handle to the vpn service | ||
467 | */ | ||
468 | static struct GNUNET_VPN_Handle *vpn_handle; | ||
469 | |||
470 | /** | ||
471 | * Resolver handle to the dht | 424 | * Resolver handle to the dht |
472 | */ | 425 | */ |
473 | static struct GNUNET_DHT_Handle *dht_handle; | 426 | static struct GNUNET_DHT_Handle *dht_handle; |
@@ -1235,16 +1188,16 @@ recursive_dns_resolution (struct GNS_ResolverHandle *rh) | |||
1235 | 1188 | ||
1236 | 1189 | ||
1237 | /** | 1190 | /** |
1238 | * We encountered a CNAME record during our resolution. | 1191 | * We encountered a REDIRECT record during our resolution. |
1239 | * Merge it into our chain. | 1192 | * Merge it into our chain. |
1240 | * | 1193 | * |
1241 | * @param rh resolution we are performing | 1194 | * @param rh resolution we are performing |
1242 | * @param cname value of the cname record we got for the current | 1195 | * @param rname value of the redirect record we got for the current |
1243 | * authority chain tail | 1196 | * authority chain tail |
1244 | */ | 1197 | */ |
1245 | static void | 1198 | static void |
1246 | handle_gns_cname_result (struct GNS_ResolverHandle *rh, | 1199 | handle_gns_redirect_result (struct GNS_ResolverHandle *rh, |
1247 | const char *cname) | 1200 | const char *rname) |
1248 | { | 1201 | { |
1249 | size_t nlen; | 1202 | size_t nlen; |
1250 | char *res; | 1203 | char *res; |
@@ -1253,14 +1206,17 @@ handle_gns_cname_result (struct GNS_ResolverHandle *rh, | |||
1253 | int af; | 1206 | int af; |
1254 | struct GNUNET_IDENTITY_PublicKey zone; | 1207 | struct GNUNET_IDENTITY_PublicKey zone; |
1255 | 1208 | ||
1256 | nlen = strlen (cname); | 1209 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1257 | tld = GNS_get_tld (cname); | 1210 | "Handling GNS REDIRECT result `%s'\n", |
1211 | rname); | ||
1212 | nlen = strlen (rname); | ||
1213 | tld = GNS_get_tld (rname); | ||
1258 | if (0 == strcmp ("+", tld)) | 1214 | if (0 == strcmp ("+", tld)) |
1259 | { | 1215 | { |
1260 | /* CNAME resolution continues relative to current domain */ | 1216 | /* REDIRECT resolution continues relative to current domain */ |
1261 | if (0 == rh->name_resolution_pos) | 1217 | if (0 == rh->name_resolution_pos) |
1262 | { | 1218 | { |
1263 | res = GNUNET_strndup (cname, nlen - 2); | 1219 | res = GNUNET_strndup (rname, nlen - 2); |
1264 | rh->name_resolution_pos = nlen - 2; | 1220 | rh->name_resolution_pos = nlen - 2; |
1265 | } | 1221 | } |
1266 | else | 1222 | else |
@@ -1270,7 +1226,7 @@ handle_gns_cname_result (struct GNS_ResolverHandle *rh, | |||
1270 | (int) rh->name_resolution_pos, | 1226 | (int) rh->name_resolution_pos, |
1271 | rh->name, | 1227 | rh->name, |
1272 | (int) (nlen - 2), | 1228 | (int) (nlen - 2), |
1273 | cname); | 1229 | rname); |
1274 | rh->name_resolution_pos = strlen (res); | 1230 | rh->name_resolution_pos = strlen (res); |
1275 | } | 1231 | } |
1276 | GNUNET_free (rh->name); | 1232 | GNUNET_free (rh->name); |
@@ -1291,13 +1247,13 @@ handle_gns_cname_result (struct GNS_ResolverHandle *rh, | |||
1291 | } | 1247 | } |
1292 | if (GNUNET_OK == GNUNET_GNSRECORD_zkey_to_pkey (tld, &zone)) | 1248 | if (GNUNET_OK == GNUNET_GNSRECORD_zkey_to_pkey (tld, &zone)) |
1293 | { | 1249 | { |
1294 | /* CNAME resolution continues relative to current domain */ | 1250 | /* REDIRECT resolution continues relative to current domain */ |
1295 | if (0 == rh->name_resolution_pos) | 1251 | if (0 == rh->name_resolution_pos) |
1296 | { | 1252 | { |
1297 | GNUNET_asprintf (&res, | 1253 | GNUNET_asprintf (&res, |
1298 | "%.*s", | 1254 | "%.*s", |
1299 | (int) (strlen (cname) - (strlen (tld) + 1)), | 1255 | (int) (strlen (rname) - (strlen (tld) + 1)), |
1300 | cname); | 1256 | rname); |
1301 | } | 1257 | } |
1302 | else | 1258 | else |
1303 | { | 1259 | { |
@@ -1305,8 +1261,8 @@ handle_gns_cname_result (struct GNS_ResolverHandle *rh, | |||
1305 | "%.*s.%.*s", | 1261 | "%.*s.%.*s", |
1306 | (int) rh->name_resolution_pos, | 1262 | (int) rh->name_resolution_pos, |
1307 | rh->name, | 1263 | rh->name, |
1308 | (int) (strlen (cname) - (strlen (tld) + 1)), | 1264 | (int) (strlen (rname) - (strlen (tld) + 1)), |
1309 | cname); | 1265 | rname); |
1310 | } | 1266 | } |
1311 | rh->name_resolution_pos = strlen (res); | 1267 | rh->name_resolution_pos = strlen (res); |
1312 | GNUNET_free (rh->name); | 1268 | GNUNET_free (rh->name); |
@@ -1326,18 +1282,62 @@ handle_gns_cname_result (struct GNS_ResolverHandle *rh, | |||
1326 | } | 1282 | } |
1327 | 1283 | ||
1328 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, | 1284 | GNUNET_log (GNUNET_ERROR_TYPE_INFO, |
1329 | "Got CNAME `%s' from GNS for `%s'\n", | 1285 | "Got REDIRECT `%s' from GNS for `%s'\n", |
1330 | cname, | 1286 | rname, |
1331 | rh->name); | 1287 | rh->name); |
1332 | if (NULL != rh->std_resolve) | 1288 | if (NULL != rh->std_resolve) |
1333 | { | 1289 | { |
1334 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | 1290 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, |
1335 | "Multiple CNAME results from GNS resolving `%s'! Not really allowed...\n", | 1291 | "Multiple REDIRECT results from GNS resolving `%s'! Not really allowed...\n", |
1336 | rh->name); | 1292 | rh->name); |
1337 | GNUNET_RESOLVER_request_cancel (rh->std_resolve); | 1293 | GNUNET_RESOLVER_request_cancel (rh->std_resolve); |
1338 | } | 1294 | } |
1339 | /* name is absolute, go to DNS */ | 1295 | /* name is absolute, go to DNS */ |
1340 | GNUNET_free (rh->name); | 1296 | GNUNET_free (rh->name); |
1297 | rh->name = GNUNET_strdup (rname); | ||
1298 | rh->name_resolution_pos = strlen (rh->name); | ||
1299 | switch (rh->record_type) | ||
1300 | { | ||
1301 | case GNUNET_DNSPARSER_TYPE_A: | ||
1302 | af = AF_INET; | ||
1303 | break; | ||
1304 | |||
1305 | case GNUNET_DNSPARSER_TYPE_AAAA: | ||
1306 | af = AF_INET6; | ||
1307 | break; | ||
1308 | |||
1309 | default: | ||
1310 | af = AF_UNSPEC; | ||
1311 | break; | ||
1312 | } | ||
1313 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1314 | "Doing standard DNS lookup for `%s'\n", | ||
1315 | rh->name); | ||
1316 | |||
1317 | rh->std_resolve = GNUNET_RESOLVER_ip_get (rh->name, | ||
1318 | af, | ||
1319 | DNS_LOOKUP_TIMEOUT, | ||
1320 | &handle_dns_result, | ||
1321 | rh); | ||
1322 | } | ||
1323 | |||
1324 | |||
1325 | |||
1326 | /** | ||
1327 | * We encountered a CNAME record during our resolution. | ||
1328 | * Merge it into our chain. | ||
1329 | * | ||
1330 | * @param rh resolution we are performing | ||
1331 | * @param cname value of the cname record we got for the current | ||
1332 | * authority chain tail | ||
1333 | */ | ||
1334 | static void | ||
1335 | handle_gns_cname_result (struct GNS_ResolverHandle *rh, | ||
1336 | const char *cname) | ||
1337 | { | ||
1338 | int af; | ||
1339 | |||
1340 | GNUNET_free (rh->name); | ||
1341 | rh->name = GNUNET_strdup (cname); | 1341 | rh->name = GNUNET_strdup (cname); |
1342 | rh->name_resolution_pos = strlen (rh->name); | 1342 | rh->name_resolution_pos = strlen (rh->name); |
1343 | switch (rh->record_type) | 1343 | switch (rh->record_type) |
@@ -1379,80 +1379,6 @@ handle_gns_resolution_result (void *cls, | |||
1379 | const struct GNUNET_GNSRECORD_Data *rd); | 1379 | const struct GNUNET_GNSRECORD_Data *rd); |
1380 | 1380 | ||
1381 | 1381 | ||
1382 | /** | ||
1383 | * Callback invoked from the VPN service once a redirection is | ||
1384 | * available. Provides the IP address that can now be used to | ||
1385 | * reach the requested destination. Replaces the "VPN" record | ||
1386 | * with the respective A/AAAA record and continues processing. | ||
1387 | * | ||
1388 | * @param cls closure | ||
1389 | * @param af address family, AF_INET or AF_INET6; AF_UNSPEC on error; | ||
1390 | * will match 'result_af' from the request | ||
1391 | * @param address IP address (struct in_addr or struct in_addr6, depending on 'af') | ||
1392 | * that the VPN allocated for the redirection; | ||
1393 | * traffic to this IP will now be redirected to the | ||
1394 | * specified target peer; NULL on error | ||
1395 | */ | ||
1396 | static void | ||
1397 | vpn_allocation_cb (void *cls, | ||
1398 | int af, | ||
1399 | const void *address) | ||
1400 | { | ||
1401 | struct VpnContext *vpn_ctx = cls; | ||
1402 | struct GNS_ResolverHandle *rh = vpn_ctx->rh; | ||
1403 | struct GNUNET_GNSRECORD_Data rd[vpn_ctx->rd_count]; | ||
1404 | unsigned int i; | ||
1405 | |||
1406 | vpn_ctx->vpn_request = NULL; | ||
1407 | rh->vpn_ctx = NULL; | ||
1408 | GNUNET_assert (GNUNET_OK == | ||
1409 | GNUNET_GNSRECORD_records_deserialize ( | ||
1410 | (size_t) vpn_ctx->rd_data_size, | ||
1411 | vpn_ctx->rd_data, | ||
1412 | vpn_ctx->rd_count, | ||
1413 | rd)); | ||
1414 | for (i = 0; i < vpn_ctx->rd_count; i++) | ||
1415 | { | ||
1416 | if (GNUNET_GNSRECORD_TYPE_VPN == rd[i].record_type) | ||
1417 | { | ||
1418 | switch (af) | ||
1419 | { | ||
1420 | case AF_INET: | ||
1421 | rd[i].record_type = GNUNET_DNSPARSER_TYPE_A; | ||
1422 | rd[i].data_size = sizeof(struct in_addr); | ||
1423 | rd[i].expiration_time = GNUNET_TIME_relative_to_absolute ( | ||
1424 | VPN_TIMEOUT).abs_value_us; | ||
1425 | rd[i].flags = 0; | ||
1426 | rd[i].data = address; | ||
1427 | break; | ||
1428 | |||
1429 | case AF_INET6: | ||
1430 | rd[i].record_type = GNUNET_DNSPARSER_TYPE_AAAA; | ||
1431 | rd[i].expiration_time = GNUNET_TIME_relative_to_absolute ( | ||
1432 | VPN_TIMEOUT).abs_value_us; | ||
1433 | rd[i].flags = 0; | ||
1434 | rd[i].data = address; | ||
1435 | rd[i].data_size = sizeof(struct in6_addr); | ||
1436 | break; | ||
1437 | |||
1438 | default: | ||
1439 | GNUNET_assert (0); | ||
1440 | } | ||
1441 | break; | ||
1442 | } | ||
1443 | } | ||
1444 | GNUNET_assert (i < vpn_ctx->rd_count); | ||
1445 | if (0 == vpn_ctx->rd_count) | ||
1446 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | ||
1447 | _ ("VPN returned empty result for `%s'\n"), | ||
1448 | rh->name); | ||
1449 | handle_gns_resolution_result (rh, | ||
1450 | vpn_ctx->rd_count, | ||
1451 | rd); | ||
1452 | GNUNET_free (vpn_ctx->rd_data); | ||
1453 | GNUNET_free (vpn_ctx); | ||
1454 | } | ||
1455 | |||
1456 | 1382 | ||
1457 | /** | 1383 | /** |
1458 | * We have resolved one or more of the nameservers for a | 1384 | * We have resolved one or more of the nameservers for a |
@@ -1653,6 +1579,20 @@ handle_gns2dns_ip (void *cls, | |||
1653 | ac->authority_info.dns_authority.found = GNUNET_YES; | 1579 | ac->authority_info.dns_authority.found = GNUNET_YES; |
1654 | } | 1580 | } |
1655 | 1581 | ||
1582 | /** | ||
1583 | * We found a REDIRECT record, perform recursive resolution on it. | ||
1584 | * | ||
1585 | * @param rh resolution handle | ||
1586 | * @param rd record with CNAME to resolve recursively | ||
1587 | */ | ||
1588 | static void | ||
1589 | recursive_redirect_resolution (struct GNS_ResolverHandle *rh, | ||
1590 | const struct GNUNET_GNSRECORD_Data *rd) | ||
1591 | { | ||
1592 | handle_gns_redirect_result (rh, | ||
1593 | rd->data); | ||
1594 | } | ||
1595 | |||
1656 | 1596 | ||
1657 | /** | 1597 | /** |
1658 | * We found a CNAME record, perform recursive resolution on it. | 1598 | * We found a CNAME record, perform recursive resolution on it. |
@@ -1956,11 +1896,6 @@ handle_gns_resolution_result (void *cls, | |||
1956 | { | 1896 | { |
1957 | struct GNS_ResolverHandle *rh = cls; | 1897 | struct GNS_ResolverHandle *rh = cls; |
1958 | char *cname; | 1898 | char *cname; |
1959 | struct VpnContext *vpn_ctx; | ||
1960 | const struct GNUNET_TUN_GnsVpnRecord *vpn; | ||
1961 | const char *vname; | ||
1962 | struct GNUNET_HashCode vhash; | ||
1963 | int af; | ||
1964 | char scratch[UINT16_MAX]; | 1899 | char scratch[UINT16_MAX]; |
1965 | size_t scratch_off; | 1900 | size_t scratch_off; |
1966 | size_t scratch_start; | 1901 | size_t scratch_start; |
@@ -2006,8 +1941,18 @@ handle_gns_resolution_result (void *cls, | |||
2006 | GNUNET_free (cname); | 1941 | GNUNET_free (cname); |
2007 | return; | 1942 | return; |
2008 | } | 1943 | } |
2009 | /* If A/AAAA was requested, but we got a VPN | 1944 | if ((rd_count > 0) && |
2010 | record, we convert it to A/AAAA using GNUnet VPN */ | 1945 | (GNUNET_GNSRECORD_TYPE_REDIRECT == rd[0].record_type) && |
1946 | (GNUNET_GNSRECORD_TYPE_REDIRECT != rh->record_type)) | ||
1947 | { | ||
1948 | handle_gns_redirect_result (rh, | ||
1949 | rd[0].data); | ||
1950 | return; | ||
1951 | } | ||
1952 | |||
1953 | |||
1954 | /* If A/AAAA was requested, | ||
1955 | * but we got a GNS2DNS record */ | ||
2011 | if ((GNUNET_DNSPARSER_TYPE_A == rh->record_type) || | 1956 | if ((GNUNET_DNSPARSER_TYPE_A == rh->record_type) || |
2012 | (GNUNET_DNSPARSER_TYPE_AAAA == rh->record_type)) | 1957 | (GNUNET_DNSPARSER_TYPE_AAAA == rh->record_type)) |
2013 | { | 1958 | { |
@@ -2015,69 +1960,6 @@ handle_gns_resolution_result (void *cls, | |||
2015 | { | 1960 | { |
2016 | switch (rd[i].record_type) | 1961 | switch (rd[i].record_type) |
2017 | { | 1962 | { |
2018 | case GNUNET_GNSRECORD_TYPE_VPN: | ||
2019 | { | ||
2020 | af = (GNUNET_DNSPARSER_TYPE_A == rh->record_type) ? AF_INET : | ||
2021 | AF_INET6; | ||
2022 | if (sizeof(struct GNUNET_TUN_GnsVpnRecord) > | ||
2023 | rd[i].data_size) | ||
2024 | { | ||
2025 | GNUNET_break_op (0); | ||
2026 | fail_resolution (rh); | ||
2027 | return; | ||
2028 | } | ||
2029 | vpn = (const struct GNUNET_TUN_GnsVpnRecord *) rd[i].data; | ||
2030 | vname = (const char *) &vpn[1]; | ||
2031 | if ('\0' != vname[rd[i].data_size - 1 - sizeof(struct | ||
2032 | GNUNET_TUN_GnsVpnRecord) | ||
2033 | ]) | ||
2034 | { | ||
2035 | GNUNET_break_op (0); | ||
2036 | fail_resolution (rh); | ||
2037 | return; | ||
2038 | } | ||
2039 | GNUNET_TUN_service_name_to_hash (vname, | ||
2040 | &vhash); | ||
2041 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
2042 | "Attempting VPN allocation for %s-%s (AF: %d, proto %d)\n", | ||
2043 | GNUNET_i2s (&vpn->peer), | ||
2044 | vname, | ||
2045 | (int) af, | ||
2046 | (int) ntohs (vpn->proto)); | ||
2047 | vpn_ctx = GNUNET_new (struct VpnContext); | ||
2048 | rh->vpn_ctx = vpn_ctx; | ||
2049 | vpn_ctx->rh = rh; | ||
2050 | vpn_ctx->rd_data_size = GNUNET_GNSRECORD_records_get_size (rd_count, | ||
2051 | rd); | ||
2052 | if (vpn_ctx->rd_data_size < 0) | ||
2053 | { | ||
2054 | GNUNET_break_op (0); | ||
2055 | GNUNET_free (vpn_ctx); | ||
2056 | fail_resolution (rh); | ||
2057 | return; | ||
2058 | } | ||
2059 | vpn_ctx->rd_data = GNUNET_malloc ((size_t) vpn_ctx->rd_data_size); | ||
2060 | vpn_ctx->rd_count = rd_count; | ||
2061 | GNUNET_assert (vpn_ctx->rd_data_size == | ||
2062 | GNUNET_GNSRECORD_records_serialize (rd_count, | ||
2063 | rd, | ||
2064 | (size_t) vpn_ctx | ||
2065 | ->rd_data_size, | ||
2066 | vpn_ctx->rd_data)); | ||
2067 | vpn_ctx->vpn_request = GNUNET_VPN_redirect_to_peer (vpn_handle, | ||
2068 | af, | ||
2069 | ntohs ( | ||
2070 | vpn->proto), | ||
2071 | &vpn->peer, | ||
2072 | &vhash, | ||
2073 | GNUNET_TIME_relative_to_absolute ( | ||
2074 | VPN_TIMEOUT), | ||
2075 | & | ||
2076 | vpn_allocation_cb, | ||
2077 | vpn_ctx); | ||
2078 | return; | ||
2079 | } | ||
2080 | |||
2081 | case GNUNET_GNSRECORD_TYPE_GNS2DNS: | 1963 | case GNUNET_GNSRECORD_TYPE_GNS2DNS: |
2082 | { | 1964 | { |
2083 | /* delegation to DNS */ | 1965 | /* delegation to DNS */ |
@@ -2117,6 +1999,23 @@ handle_gns_resolution_result (void *cls, | |||
2117 | so we can free it afterwards. */ | 1999 | so we can free it afterwards. */ |
2118 | switch (rd[i].record_type) | 2000 | switch (rd[i].record_type) |
2119 | { | 2001 | { |
2002 | case GNUNET_GNSRECORD_TYPE_REDIRECT: | ||
2003 | { | ||
2004 | char *rname; | ||
2005 | rname = GNUNET_strndup (rd[i].data, rd[i].data_size); | ||
2006 | rname = translate_dot_plus (rh, rname); | ||
2007 | GNUNET_break (NULL != rname); | ||
2008 | scratch_start = scratch_off; | ||
2009 | memcpy (&scratch[scratch_start], rname, strlen (rname) + 1); | ||
2010 | scratch_off += strlen (rname) + 1; | ||
2011 | GNUNET_assert (rd_off < rd_count); | ||
2012 | rd_new[rd_off].data = &scratch[scratch_start]; | ||
2013 | rd_new[rd_off].data_size = scratch_off - scratch_start; | ||
2014 | rd_off++; | ||
2015 | GNUNET_free (rname); | ||
2016 | } | ||
2017 | break; | ||
2018 | |||
2120 | case GNUNET_DNSPARSER_TYPE_CNAME: | 2019 | case GNUNET_DNSPARSER_TYPE_CNAME: |
2121 | { | 2020 | { |
2122 | char *cname; | 2021 | char *cname; |
@@ -2380,6 +2279,12 @@ handle_gns_resolution_result (void *cls, | |||
2380 | 2279 | ||
2381 | switch (rd[0].record_type) | 2280 | switch (rd[0].record_type) |
2382 | { | 2281 | { |
2282 | case GNUNET_GNSRECORD_TYPE_REDIRECT: | ||
2283 | GNUNET_break_op (1 == rd_count); /* REDIRECT should be unique */ | ||
2284 | recursive_redirect_resolution (rh, | ||
2285 | &rd[0]); | ||
2286 | return; | ||
2287 | |||
2383 | case GNUNET_DNSPARSER_TYPE_CNAME: | 2288 | case GNUNET_DNSPARSER_TYPE_CNAME: |
2384 | GNUNET_break_op (1 == rd_count); /* CNAME should be unique */ | 2289 | GNUNET_break_op (1 == rd_count); /* CNAME should be unique */ |
2385 | recursive_cname_resolution (rh, | 2290 | recursive_cname_resolution (rh, |
@@ -2393,15 +2298,21 @@ handle_gns_resolution_result (void *cls, | |||
2393 | &rd[0]); | 2298 | &rd[0]); |
2394 | return; | 2299 | return; |
2395 | 2300 | ||
2396 | default: | 2301 | case GNUNET_GNSRECORD_TYPE_GNS2DNS: |
2397 | if (GNUNET_OK == | 2302 | if (GNUNET_OK == |
2398 | recursive_gns2dns_resolution (rh, | 2303 | recursive_gns2dns_resolution (rh, |
2399 | rd_count, | 2304 | rd_count, |
2400 | rd)) | 2305 | rd)) |
2401 | return; | 2306 | return; |
2402 | break; | 2307 | break; |
2308 | default: | ||
2309 | if (GNUNET_YES != GNUNET_GNSRECORD_is_critical (rd[0].record_type)) | ||
2310 | return; | ||
2311 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | ||
2312 | _ ("Unable to process critical delegation record\n")); | ||
2313 | break; | ||
2403 | } | 2314 | } |
2404 | fail: | 2315 | fail: |
2405 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | 2316 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, |
2406 | _ ("GNS lookup recursion failed (no delegation record found)\n")); | 2317 | _ ("GNS lookup recursion failed (no delegation record found)\n")); |
2407 | fail_resolution (rh); | 2318 | fail_resolution (rh); |
@@ -2618,6 +2529,13 @@ handle_namecache_block_response (void *cls, | |||
2618 | 2529 | ||
2619 | GNUNET_assert (NULL != rh->namecache_qe); | 2530 | GNUNET_assert (NULL != rh->namecache_qe); |
2620 | rh->namecache_qe = NULL; | 2531 | rh->namecache_qe = NULL; |
2532 | if (NULL == block) | ||
2533 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
2534 | "No block found\n"); | ||
2535 | else | ||
2536 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
2537 | "Got block with expiration %s\n", | ||
2538 | GNUNET_STRINGS_absolute_time_to_string (GNUNET_GNSRECORD_block_get_expiration (block))); | ||
2621 | if (((GNUNET_GNS_LO_DEFAULT == rh->options) || | 2539 | if (((GNUNET_GNS_LO_DEFAULT == rh->options) || |
2622 | ((GNUNET_GNS_LO_LOCAL_MASTER == rh->options) && | 2540 | ((GNUNET_GNS_LO_LOCAL_MASTER == rh->options) && |
2623 | (ac != rh->ac_head))) && | 2541 | (ac != rh->ac_head))) && |
@@ -2916,7 +2834,6 @@ GNS_resolver_lookup_cancel (struct GNS_ResolverHandle *rh) | |||
2916 | { | 2834 | { |
2917 | struct DnsResult *dr; | 2835 | struct DnsResult *dr; |
2918 | struct AuthorityChain *ac; | 2836 | struct AuthorityChain *ac; |
2919 | struct VpnContext *vpn_ctx; | ||
2920 | 2837 | ||
2921 | GNUNET_CONTAINER_DLL_remove (rlh_head, | 2838 | GNUNET_CONTAINER_DLL_remove (rlh_head, |
2922 | rlh_tail, | 2839 | rlh_tail, |
@@ -2981,12 +2898,6 @@ GNS_resolver_lookup_cancel (struct GNS_ResolverHandle *rh) | |||
2981 | GNUNET_CONTAINER_heap_remove_node (rh->dht_heap_node); | 2898 | GNUNET_CONTAINER_heap_remove_node (rh->dht_heap_node); |
2982 | rh->dht_heap_node = NULL; | 2899 | rh->dht_heap_node = NULL; |
2983 | } | 2900 | } |
2984 | if (NULL != (vpn_ctx = rh->vpn_ctx)) | ||
2985 | { | ||
2986 | GNUNET_VPN_cancel_request (vpn_ctx->vpn_request); | ||
2987 | GNUNET_free (vpn_ctx->rd_data); | ||
2988 | GNUNET_free (vpn_ctx); | ||
2989 | } | ||
2990 | if (NULL != rh->namecache_qe) | 2901 | if (NULL != rh->namecache_qe) |
2991 | { | 2902 | { |
2992 | GNUNET_NAMECACHE_cancel (rh->namecache_qe); | 2903 | GNUNET_NAMECACHE_cancel (rh->namecache_qe); |
@@ -3046,7 +2957,6 @@ GNS_resolver_init (struct GNUNET_NAMECACHE_Handle *nc, | |||
3046 | if (GNUNET_YES == disable_cache) | 2957 | if (GNUNET_YES == disable_cache) |
3047 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | 2958 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, |
3048 | "Namecache disabled\n"); | 2959 | "Namecache disabled\n"); |
3049 | vpn_handle = GNUNET_VPN_connect (cfg); | ||
3050 | } | 2960 | } |
3051 | 2961 | ||
3052 | 2962 | ||
@@ -3077,8 +2987,6 @@ GNS_resolver_done () | |||
3077 | } | 2987 | } |
3078 | GNUNET_CONTAINER_heap_destroy (dht_lookup_heap); | 2988 | GNUNET_CONTAINER_heap_destroy (dht_lookup_heap); |
3079 | dht_lookup_heap = NULL; | 2989 | dht_lookup_heap = NULL; |
3080 | GNUNET_VPN_disconnect (vpn_handle); | ||
3081 | vpn_handle = NULL; | ||
3082 | dht_handle = NULL; | 2990 | dht_handle = NULL; |
3083 | namecache_handle = NULL; | 2991 | namecache_handle = NULL; |
3084 | } | 2992 | } |
diff --git a/src/gns/plugin_block_gns.c b/src/gns/plugin_block_gns.c index 407754a8c..fd9c99cb4 100644 --- a/src/gns/plugin_block_gns.c +++ b/src/gns/plugin_block_gns.c | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet | 2 | This file is part of GNUnet |
3 | Copyright (C) 2010-2013 GNUnet e.V. | 3 | Copyright (C) 2010-2013, 2021, 2022 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 |
@@ -92,98 +92,16 @@ block_plugin_gns_create_group (void *cls, | |||
92 | 92 | ||
93 | 93 | ||
94 | /** | 94 | /** |
95 | * Function called to validate a reply or a request. For | ||
96 | * request evaluation, simply pass "NULL" for the reply_block. | ||
97 | * Note that it is assumed that the reply has already been | ||
98 | * matched to the key (and signatures checked) as it would | ||
99 | * be done with the "get_key" function. | ||
100 | * | ||
101 | * @param cls closure | ||
102 | * @param ctx block context | ||
103 | * @param type block type | ||
104 | * @param bg block group to use for evaluation | ||
105 | * @param eo control flags | ||
106 | * @param query original query (hash) | ||
107 | * @param xquery extrended query data (can be NULL, depending on @a type) | ||
108 | * @param xquery_size number of bytes in @a xquery | ||
109 | * @param reply_block response to validate | ||
110 | * @param reply_block_size number of bytes in @a reply_block | ||
111 | * @return characterization of result | ||
112 | */ | ||
113 | static enum GNUNET_BLOCK_EvaluationResult | ||
114 | block_plugin_gns_evaluate (void *cls, | ||
115 | struct GNUNET_BLOCK_Context *ctx, | ||
116 | enum GNUNET_BLOCK_Type type, | ||
117 | struct GNUNET_BLOCK_Group *bg, | ||
118 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
119 | const struct GNUNET_HashCode *query, | ||
120 | const void *xquery, | ||
121 | size_t xquery_size, | ||
122 | const void *reply_block, | ||
123 | size_t reply_block_size) | ||
124 | { | ||
125 | const struct GNUNET_GNSRECORD_Block *block; | ||
126 | struct GNUNET_HashCode h; | ||
127 | struct GNUNET_HashCode chash; | ||
128 | |||
129 | if (type != GNUNET_BLOCK_TYPE_GNS_NAMERECORD) | ||
130 | return GNUNET_BLOCK_EVALUATION_TYPE_NOT_SUPPORTED; | ||
131 | if (NULL == reply_block) | ||
132 | { | ||
133 | if (0 != xquery_size) | ||
134 | { | ||
135 | GNUNET_break_op (0); | ||
136 | return GNUNET_BLOCK_EVALUATION_REQUEST_INVALID; | ||
137 | } | ||
138 | return GNUNET_BLOCK_EVALUATION_REQUEST_VALID; | ||
139 | } | ||
140 | |||
141 | /* this is a reply */ | ||
142 | if (reply_block_size < sizeof(struct GNUNET_GNSRECORD_Block)) | ||
143 | { | ||
144 | GNUNET_break_op (0); | ||
145 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
146 | } | ||
147 | block = reply_block; | ||
148 | if (GNUNET_GNSRECORD_block_get_size (block) > reply_block_size) | ||
149 | { | ||
150 | GNUNET_break_op (0); | ||
151 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
152 | } | ||
153 | GNUNET_GNSRECORD_query_from_block (block, | ||
154 | &h); | ||
155 | if (0 != GNUNET_memcmp (&h, query)) | ||
156 | { | ||
157 | GNUNET_break_op (0); | ||
158 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
159 | } | ||
160 | if (GNUNET_OK != | ||
161 | GNUNET_GNSRECORD_block_verify (block)) | ||
162 | { | ||
163 | GNUNET_break_op (0); | ||
164 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
165 | } | ||
166 | GNUNET_CRYPTO_hash (reply_block, | ||
167 | reply_block_size, | ||
168 | &chash); | ||
169 | if (GNUNET_YES == | ||
170 | GNUNET_BLOCK_GROUP_bf_test_and_set (bg, | ||
171 | &chash)) | ||
172 | return GNUNET_BLOCK_EVALUATION_OK_DUPLICATE; | ||
173 | return GNUNET_BLOCK_EVALUATION_OK_MORE; | ||
174 | } | ||
175 | |||
176 | |||
177 | /** | ||
178 | * Function called to obtain the key for a block. | 95 | * Function called to obtain the key for a block. |
96 | * If the @a block is malformed, the function should | ||
97 | * zero-out @a key and return #GNUNET_OK. | ||
179 | * | 98 | * |
180 | * @param cls closure | 99 | * @param cls closure |
181 | * @param type block type | 100 | * @param type block type |
182 | * @param reply_block block to get the key for | 101 | * @param reply_block block to get the key for |
183 | * @param reply_block_size number of bytes in @a reply_block | 102 | * @param reply_block_size number of bytes in @a reply_block |
184 | * @param key set to the key (query) for the given block | 103 | * @param key set to the key (query) for the given block |
185 | * @return #GNUNET_OK on success, #GNUNET_SYSERR if type not supported | 104 | * @return #GNUNET_OK on success, #GNUNET_SYSERR if type not supported, #GNUNET_NO if extracting a key from a block of this type does not work |
186 | * (or if extracting a key from a block of this type does not work) | ||
187 | */ | 105 | */ |
188 | static enum GNUNET_GenericReturnValue | 106 | static enum GNUNET_GenericReturnValue |
189 | block_plugin_gns_get_key (void *cls, | 107 | block_plugin_gns_get_key (void *cls, |
@@ -194,12 +112,18 @@ block_plugin_gns_get_key (void *cls, | |||
194 | { | 112 | { |
195 | const struct GNUNET_GNSRECORD_Block *block; | 113 | const struct GNUNET_GNSRECORD_Block *block; |
196 | 114 | ||
197 | if (type != GNUNET_BLOCK_TYPE_GNS_NAMERECORD) | 115 | if (GNUNET_BLOCK_TYPE_GNS_NAMERECORD != type) |
116 | { | ||
117 | GNUNET_break (0); | ||
198 | return GNUNET_SYSERR; | 118 | return GNUNET_SYSERR; |
119 | } | ||
199 | if (reply_block_size < sizeof(struct GNUNET_GNSRECORD_Block)) | 120 | if (reply_block_size < sizeof(struct GNUNET_GNSRECORD_Block)) |
200 | { | 121 | { |
201 | GNUNET_break_op (0); | 122 | GNUNET_break_op (0); |
202 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | 123 | memset (key, |
124 | 0, | ||
125 | sizeof (*key)); | ||
126 | return GNUNET_OK; | ||
203 | } | 127 | } |
204 | block = reply_block; | 128 | block = reply_block; |
205 | GNUNET_GNSRECORD_query_from_block (block, | 129 | GNUNET_GNSRECORD_query_from_block (block, |
@@ -227,8 +151,11 @@ block_plugin_gns_check_query (void *cls, | |||
227 | const void *xquery, | 151 | const void *xquery, |
228 | size_t xquery_size) | 152 | size_t xquery_size) |
229 | { | 153 | { |
230 | if (type != GNUNET_BLOCK_TYPE_GNS_NAMERECORD) | 154 | if (GNUNET_BLOCK_TYPE_GNS_NAMERECORD != type) |
155 | { | ||
156 | GNUNET_break (0); | ||
231 | return GNUNET_SYSERR; | 157 | return GNUNET_SYSERR; |
158 | } | ||
232 | if (0 != xquery_size) | 159 | if (0 != xquery_size) |
233 | { | 160 | { |
234 | GNUNET_break_op (0); | 161 | GNUNET_break_op (0); |
@@ -243,7 +170,6 @@ block_plugin_gns_check_query (void *cls, | |||
243 | * | 170 | * |
244 | * @param cls closure | 171 | * @param cls closure |
245 | * @param type block type | 172 | * @param type block type |
246 | * @param query key for the block (hash), must match exactly | ||
247 | * @param block block data to validate | 173 | * @param block block data to validate |
248 | * @param block_size number of bytes in @a block | 174 | * @param block_size number of bytes in @a block |
249 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not | 175 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not |
@@ -251,14 +177,16 @@ block_plugin_gns_check_query (void *cls, | |||
251 | static enum GNUNET_GenericReturnValue | 177 | static enum GNUNET_GenericReturnValue |
252 | block_plugin_gns_check_block (void *cls, | 178 | block_plugin_gns_check_block (void *cls, |
253 | enum GNUNET_BLOCK_Type type, | 179 | enum GNUNET_BLOCK_Type type, |
254 | const struct GNUNET_HashCode *query, | ||
255 | const void *block, | 180 | const void *block, |
256 | size_t block_size) | 181 | size_t block_size) |
257 | { | 182 | { |
258 | const struct GNUNET_GNSRECORD_Block *gblock; | 183 | const struct GNUNET_GNSRECORD_Block *gblock; |
259 | 184 | ||
260 | if (type != GNUNET_BLOCK_TYPE_GNS_NAMERECORD) | 185 | if (GNUNET_BLOCK_TYPE_GNS_NAMERECORD != type) |
186 | { | ||
187 | GNUNET_break (0); | ||
261 | return GNUNET_SYSERR; | 188 | return GNUNET_SYSERR; |
189 | } | ||
262 | if (block_size < sizeof(struct GNUNET_GNSRECORD_Block)) | 190 | if (block_size < sizeof(struct GNUNET_GNSRECORD_Block)) |
263 | { | 191 | { |
264 | GNUNET_break_op (0); | 192 | GNUNET_break_op (0); |
@@ -306,23 +234,16 @@ block_plugin_gns_check_reply (void *cls, | |||
306 | const void *reply_block, | 234 | const void *reply_block, |
307 | size_t reply_block_size) | 235 | size_t reply_block_size) |
308 | { | 236 | { |
309 | const struct GNUNET_GNSRECORD_Block *block; | 237 | const struct GNUNET_GNSRECORD_Block *block = reply_block; |
310 | struct GNUNET_HashCode chash; | 238 | struct GNUNET_HashCode chash; |
311 | 239 | ||
312 | if (type != GNUNET_BLOCK_TYPE_GNS_NAMERECORD) | 240 | if (GNUNET_BLOCK_TYPE_GNS_NAMERECORD != type) |
313 | return GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED; | ||
314 | /* this is a reply */ | ||
315 | if (reply_block_size < sizeof(struct GNUNET_GNSRECORD_Block)) | ||
316 | { | 241 | { |
317 | GNUNET_break_op (0); | 242 | GNUNET_break (0); |
318 | return GNUNET_BLOCK_REPLY_INVALID; | 243 | return GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED; |
319 | } | ||
320 | block = reply_block; | ||
321 | if (GNUNET_GNSRECORD_block_get_size (block) > reply_block_size) | ||
322 | { | ||
323 | GNUNET_break_op (0); | ||
324 | return GNUNET_BLOCK_REPLY_INVALID; | ||
325 | } | 244 | } |
245 | GNUNET_assert (reply_block_size >= sizeof(struct GNUNET_GNSRECORD_Block)); | ||
246 | GNUNET_assert (GNUNET_GNSRECORD_block_get_size (block) > reply_block_size); | ||
326 | GNUNET_CRYPTO_hash (reply_block, | 247 | GNUNET_CRYPTO_hash (reply_block, |
327 | reply_block_size, | 248 | reply_block_size, |
328 | &chash); | 249 | &chash); |
@@ -347,7 +268,6 @@ libgnunet_plugin_block_gns_init (void *cls) | |||
347 | struct GNUNET_BLOCK_PluginFunctions *api; | 268 | struct GNUNET_BLOCK_PluginFunctions *api; |
348 | 269 | ||
349 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); | 270 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); |
350 | api->evaluate = &block_plugin_gns_evaluate; | ||
351 | api->get_key = &block_plugin_gns_get_key; | 271 | api->get_key = &block_plugin_gns_get_key; |
352 | api->create_group = &block_plugin_gns_create_group; | 272 | api->create_group = &block_plugin_gns_create_group; |
353 | api->check_query = &block_plugin_gns_check_query; | 273 | api->check_query = &block_plugin_gns_check_query; |
diff --git a/src/gns/plugin_gnsrecord_gns.c b/src/gns/plugin_gnsrecord_gns.c index 391144925..dc7ffa9b2 100644 --- a/src/gns/plugin_gnsrecord_gns.c +++ b/src/gns/plugin_gnsrecord_gns.c | |||
@@ -64,8 +64,7 @@ gns_value_to_string (void *cls, | |||
64 | return GNUNET_IDENTITY_public_key_to_string (&pk); | 64 | return GNUNET_IDENTITY_public_key_to_string (&pk); |
65 | 65 | ||
66 | case GNUNET_GNSRECORD_TYPE_NICK: | 66 | case GNUNET_GNSRECORD_TYPE_NICK: |
67 | return GNUNET_strndup (data, data_size); | 67 | case GNUNET_GNSRECORD_TYPE_REDIRECT: |
68 | |||
69 | case GNUNET_GNSRECORD_TYPE_LEHO: | 68 | case GNUNET_GNSRECORD_TYPE_LEHO: |
70 | return GNUNET_strndup (data, data_size); | 69 | return GNUNET_strndup (data, data_size); |
71 | 70 | ||
@@ -133,7 +132,9 @@ gns_value_to_string (void *cls, | |||
133 | GNUNET_free (ival); | 132 | GNUNET_free (ival); |
134 | return box_str; | 133 | return box_str; |
135 | } | 134 | } |
136 | 135 | case GNUNET_GNSRECORD_TYPE_TOMBSTONE: { | |
136 | return GNUNET_strdup (_("This is a memento of an older block for internal maintenance.")); | ||
137 | } | ||
137 | default: | 138 | default: |
138 | return NULL; | 139 | return NULL; |
139 | } | 140 | } |
@@ -184,16 +185,13 @@ gns_string_to_value (void *cls, | |||
184 | if (record_type != type) | 185 | if (record_type != type) |
185 | { | 186 | { |
186 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | 187 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, |
187 | _("Record type does not match parsed record type\n")); | 188 | _ ("Record type does not match parsed record type\n")); |
188 | return GNUNET_SYSERR; | 189 | return GNUNET_SYSERR; |
189 | } | 190 | } |
190 | return GNUNET_OK; | 191 | return GNUNET_OK; |
191 | 192 | ||
192 | case GNUNET_GNSRECORD_TYPE_NICK: | 193 | case GNUNET_GNSRECORD_TYPE_NICK: |
193 | *data = GNUNET_strdup (s); | 194 | case GNUNET_GNSRECORD_TYPE_REDIRECT: |
194 | *data_size = strlen (s); | ||
195 | return GNUNET_OK; | ||
196 | |||
197 | case GNUNET_GNSRECORD_TYPE_LEHO: | 195 | case GNUNET_GNSRECORD_TYPE_LEHO: |
198 | *data = GNUNET_strdup (s); | 196 | *data = GNUNET_strdup (s); |
199 | *data_size = strlen (s); | 197 | *data_size = strlen (s); |
@@ -301,6 +299,12 @@ gns_string_to_value (void *cls, | |||
301 | GNUNET_free (bval); | 299 | GNUNET_free (bval); |
302 | return GNUNET_OK; | 300 | return GNUNET_OK; |
303 | } | 301 | } |
302 | case GNUNET_GNSRECORD_TYPE_TOMBSTONE: { | ||
303 | *data_size = 0; | ||
304 | *data = NULL; | ||
305 | return GNUNET_OK; | ||
306 | } | ||
307 | |||
304 | 308 | ||
305 | default: | 309 | default: |
306 | return GNUNET_SYSERR; | 310 | return GNUNET_SYSERR; |
@@ -317,12 +321,16 @@ static struct | |||
317 | const char *name; | 321 | const char *name; |
318 | uint32_t number; | 322 | uint32_t number; |
319 | } gns_name_map[] = { { "PKEY", GNUNET_GNSRECORD_TYPE_PKEY }, | 323 | } gns_name_map[] = { { "PKEY", GNUNET_GNSRECORD_TYPE_PKEY }, |
320 | { "EDKEY", GNUNET_GNSRECORD_TYPE_PKEY }, | 324 | { "EDKEY", GNUNET_GNSRECORD_TYPE_EDKEY }, |
321 | { "NICK", GNUNET_GNSRECORD_TYPE_NICK }, | 325 | { "NICK", GNUNET_GNSRECORD_TYPE_NICK }, |
322 | { "LEHO", GNUNET_GNSRECORD_TYPE_LEHO }, | 326 | { "LEHO", GNUNET_GNSRECORD_TYPE_LEHO }, |
323 | { "VPN", GNUNET_GNSRECORD_TYPE_VPN }, | 327 | { "VPN", GNUNET_GNSRECORD_TYPE_VPN }, |
324 | { "GNS2DNS", GNUNET_GNSRECORD_TYPE_GNS2DNS }, | 328 | { "GNS2DNS", GNUNET_GNSRECORD_TYPE_GNS2DNS }, |
325 | { "BOX", GNUNET_GNSRECORD_TYPE_BOX }, | 329 | { "BOX", GNUNET_GNSRECORD_TYPE_BOX }, |
330 | { "REDIRECT", GNUNET_GNSRECORD_TYPE_REDIRECT }, | ||
331 | /* Tombstones should never be added manually | ||
332 | * so this makes sense, kind of */ | ||
333 | { "\u271E", GNUNET_GNSRECORD_TYPE_TOMBSTONE }, | ||
326 | { NULL, UINT32_MAX } }; | 334 | { NULL, UINT32_MAX } }; |
327 | 335 | ||
328 | 336 | ||
@@ -365,6 +373,19 @@ gns_number_to_typename (void *cls, uint32_t type) | |||
365 | } | 373 | } |
366 | 374 | ||
367 | 375 | ||
376 | static enum GNUNET_GenericReturnValue | ||
377 | gns_is_critical (void *cls, uint32_t type) | ||
378 | { | ||
379 | return ((type == GNUNET_GNSRECORD_TYPE_PKEY) || | ||
380 | (type == GNUNET_GNSRECORD_TYPE_EDKEY) || | ||
381 | (type == GNUNET_GNSRECORD_TYPE_GNS2DNS) || | ||
382 | (type == GNUNET_GNSRECORD_TYPE_REDIRECT) ? | ||
383 | GNUNET_YES : GNUNET_NO); | ||
384 | } | ||
385 | |||
386 | |||
387 | |||
388 | |||
368 | /** | 389 | /** |
369 | * Entry point for the plugin. | 390 | * Entry point for the plugin. |
370 | * | 391 | * |
@@ -381,6 +402,7 @@ libgnunet_plugin_gnsrecord_gns_init (void *cls) | |||
381 | api->string_to_value = &gns_string_to_value; | 402 | api->string_to_value = &gns_string_to_value; |
382 | api->typename_to_number = &gns_typename_to_number; | 403 | api->typename_to_number = &gns_typename_to_number; |
383 | api->number_to_typename = &gns_number_to_typename; | 404 | api->number_to_typename = &gns_number_to_typename; |
405 | api->is_critical = &gns_is_critical; | ||
384 | return api; | 406 | return api; |
385 | } | 407 | } |
386 | 408 | ||
diff --git a/src/gns/test_gns_cname_lookup.sh b/src/gns/test_gns_cname_lookup.sh deleted file mode 100755 index 3a189e1e2..000000000 --- a/src/gns/test_gns_cname_lookup.sh +++ /dev/null | |||
@@ -1,99 +0,0 @@ | |||
1 | #!/bin/sh | ||
2 | # This file is in the public domain. | ||
3 | trap "gnunet-arm -e -c test_gns_lookup.conf" INT | ||
4 | |||
5 | LOCATION=$(which gnunet-config) | ||
6 | if [ -z $LOCATION ] | ||
7 | then | ||
8 | LOCATION="gnunet-config" | ||
9 | fi | ||
10 | $LOCATION --version 1> /dev/null | ||
11 | if test $? != 0 | ||
12 | then | ||
13 | echo "GNUnet command line tools cannot be found, check environmental variables PATH and GNUNET_PREFIX" | ||
14 | exit 77 | ||
15 | fi | ||
16 | |||
17 | # permissive DNS resolver we will use for the test | ||
18 | DNS_RESOLVER="8.8.8.8" | ||
19 | if ! nslookup gnunet.org $DNS_RESOLVER > /dev/null 2>&1 | ||
20 | then | ||
21 | echo "Cannot reach DNS, skipping test" | ||
22 | exit 77 | ||
23 | fi | ||
24 | |||
25 | |||
26 | rm -rf `gnunet-config -c test_gns_lookup.conf -f -s paths -o GNUNET_TEST_HOME` | ||
27 | |||
28 | TEST_IP_PLUS="127.0.0.1" | ||
29 | TEST_IP_DNS="131.159.74.67" | ||
30 | TEST_RECORD_CNAME_SERVER="server" | ||
31 | TEST_RECORD_CNAME_PLUS="server.+" | ||
32 | TEST_RECORD_CNAME_DNS="gnunet.org" | ||
33 | TEST_RECORD_NAME_SERVER="server" | ||
34 | TEST_RECORD_NAME_PLUS="www" | ||
35 | TEST_RECORD_NAME_ZKEY="www2" | ||
36 | TEST_RECORD_NAME_DNS="www3" | ||
37 | MY_EGO="myego" | ||
38 | TEST_DOMAIN_PLUS="www.$MY_EGO" | ||
39 | TEST_DOMAIN_ZKEY="www2.$MY_EGO" | ||
40 | TEST_DOMAIN_DNS="www3.$MY_EGO" | ||
41 | which timeout > /dev/null 2>&1 && DO_TIMEOUT="timeout 15" | ||
42 | |||
43 | gnunet-arm -s -c test_gns_lookup.conf | ||
44 | gnunet-identity -C $MY_EGO -c test_gns_lookup.conf | ||
45 | MY_EGO_PKEY=$(gnunet-identity -d -c test_gns_lookup.conf | grep ${MY_EGO} | awk '{print $3}') | ||
46 | TEST_RECORD_CNAME_ZKEY="server.${MY_EGO_PKEY}" | ||
47 | gnunet-namestore -p -z $MY_EGO -a -n $TEST_RECORD_NAME_DNS -t CNAME -V $TEST_RECORD_CNAME_DNS -e never -c test_gns_lookup.conf | ||
48 | gnunet-namestore -p -z $MY_EGO -a -n $TEST_RECORD_NAME_PLUS -t CNAME -V $TEST_RECORD_CNAME_PLUS -e never -c test_gns_lookup.conf | ||
49 | gnunet-namestore -p -z $MY_EGO -a -n $TEST_RECORD_NAME_ZKEY -t CNAME -V $TEST_RECORD_CNAME_ZKEY -e never -c test_gns_lookup.conf | ||
50 | gnunet-namestore -p -z $MY_EGO -a -n $TEST_RECORD_CNAME_SERVER -t A -V $TEST_IP_PLUS -e never -c test_gns_lookup.conf | ||
51 | RES_CNAME=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN_PLUS -t A -c test_gns_lookup.conf` | ||
52 | RES_CNAME_RAW=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN_PLUS -t CNAME -c test_gns_lookup.conf` | ||
53 | RES_CNAME_ZKEY=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN_ZKEY -t A -c test_gns_lookup.conf` | ||
54 | RES_CNAME_DNS=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN_DNS -t A -c test_gns_lookup.conf | grep $TEST_IP_DNS` | ||
55 | |||
56 | TESTEGOZONE=`gnunet-identity -c test_gns_lookup.conf -d | awk '{print $3}'` | ||
57 | gnunet-namestore -p -z $MY_EGO -d -n $TEST_RECORD_NAME_DNS -t CNAME -V $TEST_RECORD_CNAME_DNS -e never -c test_gns_lookup.conf | ||
58 | gnunet-namestore -p -z $MY_EGO -d -n $TEST_RECORD_NAME_PLUS -t CNAME -V $TEST_RECORD_CNAME_PLUS -e never -c test_gns_lookup.conf | ||
59 | gnunet-namestore -p -z $MY_EGO -d -n $TEST_RECORD_NAME_ZKEY -t CNAME -V $TEST_RECORD_CNAME_ZKEY -e never -c test_gns_lookup.conf | ||
60 | gnunet-namestore -p -z $MY_EGO -d -n $TEST_RECORD_CNAME_SERVER -t A -V $TEST_IP_PLUS -e never -c test_gns_lookup.conf | ||
61 | gnunet-identity -D $MY_EGO -c test_gns_lookup.conf | ||
62 | gnunet-arm -e -c test_gns_lookup.conf | ||
63 | rm -rf `gnunet-config -c test_gns_lookup.conf -f -s paths -o GNUNET_TEST_HOME` | ||
64 | |||
65 | # make cmp case-insensitive by converting to lower case first | ||
66 | RES_CNAME_RAW=`echo $RES_CNAME_RAW | tr [A-Z] [a-z]` | ||
67 | TESTEGOZONE=`echo $TESTEGOZONE | tr [A-Z] [a-z]` | ||
68 | if [ "$RES_CNAME_RAW" = "server.$TESTEGOZONE" ] | ||
69 | then | ||
70 | echo "PASS: CNAME resolution from GNS" | ||
71 | else | ||
72 | echo "FAIL: CNAME resolution from GNS, got $RES_CNAME_RAW, expected server.$TESTEGOZONE." | ||
73 | exit 1 | ||
74 | fi | ||
75 | |||
76 | if [ "$RES_CNAME" = "$TEST_IP_PLUS" ] | ||
77 | then | ||
78 | echo "PASS: IP resolution from GNS (.+)" | ||
79 | else | ||
80 | echo "FAIL: IP resolution from GNS (.+), got $RES_CNAME, expected $TEST_IP_PLUS." | ||
81 | exit 1 | ||
82 | fi | ||
83 | |||
84 | if [ "$RES_CNAME_ZKEY" = "$TEST_IP_PLUS" ] | ||
85 | then | ||
86 | echo "PASS: IP resolution from GNS (.zkey)" | ||
87 | else | ||
88 | echo "FAIL: IP resolution from GNS (.zkey), got $RES_CNAME, expected $TEST_IP_PLUS." | ||
89 | exit 1 | ||
90 | fi | ||
91 | |||
92 | if echo "$RES_CNAME_DNS" | grep "$TEST_IP_DNS" > /dev/null | ||
93 | then | ||
94 | echo "PASS: IP resolution from DNS" | ||
95 | exit 0 | ||
96 | else | ||
97 | echo "FAIL: IP resolution from DNS, got $RES_CNAME_DNS, expected $TEST_IP_DNS." | ||
98 | exit 1 | ||
99 | fi | ||
diff --git a/src/gns/test_gns_gns2dns_cname_lookup.sh b/src/gns/test_gns_gns2dns_cname_lookup.sh index ce1afacf4..9315f6b2f 100755 --- a/src/gns/test_gns_gns2dns_cname_lookup.sh +++ b/src/gns/test_gns_gns2dns_cname_lookup.sh | |||
@@ -16,9 +16,11 @@ fi | |||
16 | 16 | ||
17 | rm -rf `gnunet-config -c test_gns_lookup.conf -f -s paths -o GNUNET_TEST_HOME` | 17 | rm -rf `gnunet-config -c test_gns_lookup.conf -f -s paths -o GNUNET_TEST_HOME` |
18 | # IP address of 'www.gnunet.org' | 18 | # IP address of 'www.gnunet.org' |
19 | TEST_IP="131.159.74.67" | 19 | TEST_IP="147.87.255.218" |
20 | # IP address of 'gnunet.org' | ||
21 | TEST_IPALT="131.159.74.67" | ||
20 | # IPv6 address of 'gnunet.org' | 22 | # IPv6 address of 'gnunet.org' |
21 | TEST_IP6="2001:4ca0:2001:42:225:90ff:fe6b:d60" | 23 | TEST_IP6="2a07:6b47:100:464::9357:ffdb" |
22 | 24 | ||
23 | # main label used during resolution | 25 | # main label used during resolution |
24 | TEST_RECORD_NAME="homepage" | 26 | TEST_RECORD_NAME="homepage" |
@@ -46,7 +48,7 @@ TEST_DOMAIN="www.${TEST_RECORD_NAME}.$MY_EGO" | |||
46 | which timeout > /dev/null 2>&1 && DO_TIMEOUT="timeout 15" | 48 | which timeout > /dev/null 2>&1 && DO_TIMEOUT="timeout 15" |
47 | 49 | ||
48 | gnunet-arm -s -c test_gns_lookup.conf | 50 | gnunet-arm -s -c test_gns_lookup.conf |
49 | OUT=`$DO_TIMEOUT gnunet-resolver -c test_gns_lookup.conf gnunet.org` | 51 | OUT=`$DO_TIMEOUT gnunet-resolver -c test_gns_lookup.conf www.gnunet.org` |
50 | echo $OUT | grep $TEST_IP - > /dev/null || { gnunet-arm -e -c test_gns_lookup.conf ; echo "IPv4 for gnunet.org not found ($OUT), skipping test"; exit 77; } | 52 | echo $OUT | grep $TEST_IP - > /dev/null || { gnunet-arm -e -c test_gns_lookup.conf ; echo "IPv4 for gnunet.org not found ($OUT), skipping test"; exit 77; } |
51 | echo $OUT | grep $TEST_IP6 - > /dev/null || { gnunet-arm -e -c test_gns_lookup.conf ; echo "IPv6 for gnunet.org not found ($OUT), skipping test"; exit 77; } | 53 | echo $OUT | grep $TEST_IP6 - > /dev/null || { gnunet-arm -e -c test_gns_lookup.conf ; echo "IPv6 for gnunet.org not found ($OUT), skipping test"; exit 77; } |
52 | 54 | ||
@@ -59,6 +61,7 @@ gnunet-namestore -p -z $MY_EGO -a -n $TEST_RECORD_NAME -t GNS2DNS -V $TEST_RECOR | |||
59 | gnunet-namestore -p -z $MY_EGO -a -n $TEST_RECORD_NAME -t GNS2DNS -V $TEST_RECORD_GNS2DNS2 -e never -c test_gns_lookup.conf | 61 | gnunet-namestore -p -z $MY_EGO -a -n $TEST_RECORD_NAME -t GNS2DNS -V $TEST_RECORD_GNS2DNS2 -e never -c test_gns_lookup.conf |
60 | gnunet-namestore -p -z $MY_EGO -a -n $TEST_RECORD_NAME -t GNS2DNS -V $TEST_RECORD_GNS2DNS3 -e never -c test_gns_lookup.conf | 62 | gnunet-namestore -p -z $MY_EGO -a -n $TEST_RECORD_NAME -t GNS2DNS -V $TEST_RECORD_GNS2DNS3 -e never -c test_gns_lookup.conf |
61 | 63 | ||
64 | gnunet-namestore -z $MY_EGO -D -c test_gns_lookup.conf | ||
62 | 65 | ||
63 | echo "EGOs:" | 66 | echo "EGOs:" |
64 | gnunet-identity -d | 67 | gnunet-identity -d |
diff --git a/src/gns/test_gns_gns2dns_lookup.sh b/src/gns/test_gns_gns2dns_lookup.sh index dcad594b3..240e441a4 100755 --- a/src/gns/test_gns_gns2dns_lookup.sh +++ b/src/gns/test_gns_gns2dns_lookup.sh | |||
@@ -17,9 +17,11 @@ rm -rf `gnunet-config -c test_gns_lookup.conf -f -s paths -o GNUNET_TEST_HOME` | |||
17 | # IP address of 'docs.gnunet.org' | 17 | # IP address of 'docs.gnunet.org' |
18 | TEST_IP_ALT2="147.87.255.218" | 18 | TEST_IP_ALT2="147.87.255.218" |
19 | # IP address of 'www.gnunet.org' | 19 | # IP address of 'www.gnunet.org' |
20 | TEST_IP="131.159.74.67" | 20 | TEST_IP="147.87.255.218" |
21 | # IP address of 'gnunet.org' | ||
22 | TEST_IP_ALT="131.159.74.67" | ||
21 | # IPv6 address of 'gnunet.org' | 23 | # IPv6 address of 'gnunet.org' |
22 | TEST_IP6="2001:4ca0:2001:42:225:90ff:fe6b:d60" | 24 | TEST_IP6="2a07:6b47:100:464::9357:ffdb" |
23 | # permissive DNS resolver we will use for the test | 25 | # permissive DNS resolver we will use for the test |
24 | TEST_IP_GNS2DNS="8.8.8.8" | 26 | TEST_IP_GNS2DNS="8.8.8.8" |
25 | 27 | ||
@@ -49,7 +51,7 @@ which timeout > /dev/null 2>&1 && DO_TIMEOUT="timeout 15" | |||
49 | 51 | ||
50 | gnunet-arm -s -c test_gns_lookup.conf | 52 | gnunet-arm -s -c test_gns_lookup.conf |
51 | 53 | ||
52 | OUT=`$DO_TIMEOUT gnunet-resolver -c test_gns_lookup.conf gnunet.org` | 54 | OUT=`$DO_TIMEOUT gnunet-resolver -c test_gns_lookup.conf www.gnunet.org` |
53 | echo $OUT | grep $TEST_IP - > /dev/null || { gnunet-arm -e -c test_gns_lookup.conf ; echo "IPv4 for gnunet.org not found ($OUT), skipping test"; exit 77; } | 55 | echo $OUT | grep $TEST_IP - > /dev/null || { gnunet-arm -e -c test_gns_lookup.conf ; echo "IPv4 for gnunet.org not found ($OUT), skipping test"; exit 77; } |
54 | echo $OUT | grep $TEST_IP6 - > /dev/null || { gnunet-arm -e -c test_gns_lookup.conf ; echo "IPv6 for gnunet.org not found ($OUT), skipping test"; exit 77; } | 56 | echo $OUT | grep $TEST_IP6 - > /dev/null || { gnunet-arm -e -c test_gns_lookup.conf ; echo "IPv6 for gnunet.org not found ($OUT), skipping test"; exit 77; } |
55 | 57 | ||
@@ -69,7 +71,7 @@ gnunet-identity -d | |||
69 | # lookup 'www.gnunet.org', IPv4 | 71 | # lookup 'www.gnunet.org', IPv4 |
70 | RES_IP=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN -t A -c test_gns_lookup.conf` | 72 | RES_IP=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN -t A -c test_gns_lookup.conf` |
71 | # lookup 'www.gnunet.org', IPv6 | 73 | # lookup 'www.gnunet.org', IPv6 |
72 | RES_IP6=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN -t AAAA -c test_gns_lookup.conf` | 74 | RES_IP6=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN -t AAAA -c test_gns_lookup.conf | head -n1` |
73 | # lookup 'gnunet.org', IPv4 | 75 | # lookup 'gnunet.org', IPv4 |
74 | RES_IP_ALT=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN_ALT -t A -c test_gns_lookup.conf` | 76 | RES_IP_ALT=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN_ALT -t A -c test_gns_lookup.conf` |
75 | # lookup 'docs.gnunet.org', IPv4 | 77 | # lookup 'docs.gnunet.org', IPv4 |
@@ -91,7 +93,7 @@ else | |||
91 | ret=1 | 93 | ret=1 |
92 | fi | 94 | fi |
93 | 95 | ||
94 | if [ "$RES_IP6" = "$TEST_IP6" ] | 96 | if [ "${RES_IP6%?}" = "${TEST_IP6%?}" ] |
95 | then | 97 | then |
96 | echo "PASS: Resolved $TEST_DOMAIN to $RES_IP6." | 98 | echo "PASS: Resolved $TEST_DOMAIN to $RES_IP6." |
97 | else | 99 | else |
@@ -99,7 +101,7 @@ else | |||
99 | ret=1 | 101 | ret=1 |
100 | fi | 102 | fi |
101 | 103 | ||
102 | if echo "$RES_IP_ALT" | grep "$TEST_IP" > /dev/null | 104 | if echo "$RES_IP_ALT" | grep "$TEST_IP_ALT" > /dev/null |
103 | then | 105 | then |
104 | echo "PASS: Resolved $TEST_DOMAIN_ALT to $RES_IP_ALT." | 106 | echo "PASS: Resolved $TEST_DOMAIN_ALT to $RES_IP_ALT." |
105 | else | 107 | else |
diff --git a/src/gns/test_gns_gns2dns_zkey_lookup.sh b/src/gns/test_gns_gns2dns_zkey_lookup.sh index 1f8e34c42..a299c34b6 100755 --- a/src/gns/test_gns_gns2dns_zkey_lookup.sh +++ b/src/gns/test_gns_gns2dns_zkey_lookup.sh | |||
@@ -17,9 +17,11 @@ rm -rf `gnunet-config -c test_gns_lookup.conf -f -s paths -o GNUNET_TEST_HOME` | |||
17 | # IP address of 'docs.gnunet.org' | 17 | # IP address of 'docs.gnunet.org' |
18 | TEST_IP_ALT2="147.87.255.218" | 18 | TEST_IP_ALT2="147.87.255.218" |
19 | # IP address of 'www.gnunet.org' | 19 | # IP address of 'www.gnunet.org' |
20 | TEST_IP="131.159.74.67" | 20 | TEST_IP="147.87.255.218" |
21 | # IP address of 'www.gnunet.org' | ||
22 | TEST_IP_ALT="131.159.74.67" | ||
21 | # IPv6 address of 'gnunet.org' | 23 | # IPv6 address of 'gnunet.org' |
22 | TEST_IP6="2001:4ca0:2001:42:225:90ff:fe6b:d60" | 24 | TEST_IP6="2a07:6b47:100:464::9357:ffdb" |
23 | # permissive DNS resolver we will use for the test | 25 | # permissive DNS resolver we will use for the test |
24 | TEST_IP_GNS2DNS="8.8.8.8" | 26 | TEST_IP_GNS2DNS="8.8.8.8" |
25 | 27 | ||
@@ -46,7 +48,7 @@ which timeout > /dev/null 2>&1 && DO_TIMEOUT="timeout 15" | |||
46 | 48 | ||
47 | gnunet-arm -s -c test_gns_lookup.conf | 49 | gnunet-arm -s -c test_gns_lookup.conf |
48 | 50 | ||
49 | OUT=`$DO_TIMEOUT gnunet-resolver -c test_gns_lookup.conf gnunet.org` | 51 | OUT=`$DO_TIMEOUT gnunet-resolver -c test_gns_lookup.conf www.gnunet.org` |
50 | echo $OUT | grep $TEST_IP - > /dev/null || { gnunet-arm -e -c test_gns_lookup.conf ; echo "IPv4 for gnunet.org not found ($OUT), skipping test"; exit 77; } | 52 | echo $OUT | grep $TEST_IP - > /dev/null || { gnunet-arm -e -c test_gns_lookup.conf ; echo "IPv4 for gnunet.org not found ($OUT), skipping test"; exit 77; } |
51 | echo $OUT | grep $TEST_IP6 - > /dev/null || { gnunet-arm -e -c test_gns_lookup.conf ; echo "IPv6 for gnunet.org not found ($OUT), skipping test"; exit 77; } | 53 | echo $OUT | grep $TEST_IP6 - > /dev/null || { gnunet-arm -e -c test_gns_lookup.conf ; echo "IPv6 for gnunet.org not found ($OUT), skipping test"; exit 77; } |
52 | 54 | ||
@@ -66,7 +68,7 @@ gnunet-namestore -p -z $MY_EGO -a -n $TEST_RECORD_NAME -t GNS2DNS -V $TEST_RECOR | |||
66 | # lookup 'www.gnunet.org', IPv4 | 68 | # lookup 'www.gnunet.org', IPv4 |
67 | RES_IP=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN -t A -c test_gns_lookup.conf` | 69 | RES_IP=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN -t A -c test_gns_lookup.conf` |
68 | # lookup 'www.gnunet.org', IPv6 | 70 | # lookup 'www.gnunet.org', IPv6 |
69 | RES_IP6=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN -t AAAA -c test_gns_lookup.conf` | 71 | RES_IP6=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN -t AAAA -c test_gns_lookup.conf | head -n1` |
70 | # lookup 'gnunet.org', IPv4 | 72 | # lookup 'gnunet.org', IPv4 |
71 | RES_IP_ALT=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN_ALT -t A -c test_gns_lookup.conf` | 73 | RES_IP_ALT=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN_ALT -t A -c test_gns_lookup.conf` |
72 | # lookup 'docs.gnunet.org', IPv4 | 74 | # lookup 'docs.gnunet.org', IPv4 |
@@ -88,7 +90,7 @@ else | |||
88 | ret=1 | 90 | ret=1 |
89 | fi | 91 | fi |
90 | 92 | ||
91 | if [ "$RES_IP6" = "$TEST_IP6" ] | 93 | if [ "${RES_IP6%?}" = "${TEST_IP6%?}" ] |
92 | then | 94 | then |
93 | echo "PASS: Resolved $TEST_DOMAIN to $RES_IP6." | 95 | echo "PASS: Resolved $TEST_DOMAIN to $RES_IP6." |
94 | else | 96 | else |
@@ -96,7 +98,7 @@ else | |||
96 | ret=1 | 98 | ret=1 |
97 | fi | 99 | fi |
98 | 100 | ||
99 | if echo "$RES_IP_ALT" | grep "$TEST_IP" > /dev/null | 101 | if echo "$RES_IP_ALT" | grep "$TEST_IP_ALT" > /dev/null |
100 | then | 102 | then |
101 | echo "PASS: Resolved $TEST_DOMAIN_ALT to $RES_IP_ALT." | 103 | echo "PASS: Resolved $TEST_DOMAIN_ALT to $RES_IP_ALT." |
102 | else | 104 | else |
diff --git a/src/gns/test_gns_redirect_lookup.sh b/src/gns/test_gns_redirect_lookup.sh new file mode 100755 index 000000000..dfe5087ef --- /dev/null +++ b/src/gns/test_gns_redirect_lookup.sh | |||
@@ -0,0 +1,100 @@ | |||
1 | #!/bin/sh | ||
2 | # This file is in the public domain. | ||
3 | trap "gnunet-arm -e -c test_gns_lookup.conf" INT | ||
4 | |||
5 | LOCATION=$(which gnunet-config) | ||
6 | if [ -z $LOCATION ] | ||
7 | then | ||
8 | LOCATION="gnunet-config" | ||
9 | fi | ||
10 | $LOCATION --version 1> /dev/null | ||
11 | if test $? != 0 | ||
12 | then | ||
13 | echo "GNUnet command line tools cannot be found, check environmental variables PATH and GNUNET_PREFIX" | ||
14 | exit 77 | ||
15 | fi | ||
16 | |||
17 | # permissive DNS resolver we will use for the test | ||
18 | DNS_RESOLVER="8.8.8.8" | ||
19 | if ! nslookup gnunet.org $DNS_RESOLVER > /dev/null 2>&1 | ||
20 | then | ||
21 | echo "Cannot reach DNS, skipping test" | ||
22 | exit 77 | ||
23 | fi | ||
24 | |||
25 | |||
26 | rm -rf `gnunet-config -c test_gns_lookup.conf -f -s paths -o GNUNET_TEST_HOME` | ||
27 | |||
28 | TEST_IP_PLUS="127.0.0.1" | ||
29 | TEST_IP_DNS="131.159.74.67" | ||
30 | TEST_RECORD_REDIRECT_SERVER="server" | ||
31 | TEST_RECORD_REDIRECT_PLUS="server.+" | ||
32 | TEST_RECORD_REDIRECT_DNS="gnunet.org" | ||
33 | TEST_RECORD_NAME_SERVER="server" | ||
34 | TEST_RECORD_NAME_PLUS="www" | ||
35 | TEST_RECORD_NAME_ZKEY="www2" | ||
36 | TEST_RECORD_NAME_DNS="www3" | ||
37 | MY_EGO="myego" | ||
38 | TEST_DOMAIN_PLUS="www.$MY_EGO" | ||
39 | TEST_DOMAIN_ZKEY="www2.$MY_EGO" | ||
40 | TEST_DOMAIN_DNS="www3.$MY_EGO" | ||
41 | which timeout > /dev/null 2>&1 && DO_TIMEOUT="timeout 15" | ||
42 | |||
43 | gnunet-arm -s -c test_gns_lookup.conf | ||
44 | gnunet-identity -C $MY_EGO -c test_gns_lookup.conf | ||
45 | MY_EGO_PKEY=$(gnunet-identity -d -c test_gns_lookup.conf | grep ${MY_EGO} | awk '{print $3}') | ||
46 | TEST_RECORD_REDIRECT_ZKEY="server.${MY_EGO_PKEY}" | ||
47 | gnunet-namestore -p -z $MY_EGO -a -n $TEST_RECORD_NAME_DNS -t REDIRECT -V $TEST_RECORD_REDIRECT_DNS -e never -c test_gns_lookup.conf | ||
48 | gnunet-namestore -p -z $MY_EGO -a -n $TEST_RECORD_NAME_PLUS -t REDIRECT -V $TEST_RECORD_REDIRECT_PLUS -e never -c test_gns_lookup.conf | ||
49 | gnunet-namestore -p -z $MY_EGO -a -n $TEST_RECORD_NAME_ZKEY -t REDIRECT -V $TEST_RECORD_REDIRECT_ZKEY -e never -c test_gns_lookup.conf | ||
50 | gnunet-namestore -p -z $MY_EGO -a -n $TEST_RECORD_REDIRECT_SERVER -t A -V $TEST_IP_PLUS -e never -c test_gns_lookup.conf | ||
51 | gnunet-namestore -D -z $MY_EGO | ||
52 | RES_REDIRECT=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN_PLUS -t A -c test_gns_lookup.conf` | ||
53 | RES_REDIRECT_RAW=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN_PLUS -t REDIRECT -c test_gns_lookup.conf` | ||
54 | RES_REDIRECT_ZKEY=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN_ZKEY -t A -c test_gns_lookup.conf` | ||
55 | RES_REDIRECT_DNS=`$DO_TIMEOUT gnunet-gns --raw -u $TEST_DOMAIN_DNS -t A -c test_gns_lookup.conf | grep $TEST_IP_DNS` | ||
56 | |||
57 | TESTEGOZONE=`gnunet-identity -c test_gns_lookup.conf -d | awk '{print $3}'` | ||
58 | gnunet-namestore -p -z $MY_EGO -d -n $TEST_RECORD_NAME_DNS -t REDIRECT -V $TEST_RECORD_REDIRECT_DNS -e never -c test_gns_lookup.conf | ||
59 | gnunet-namestore -p -z $MY_EGO -d -n $TEST_RECORD_NAME_PLUS -t REDIRECT -V $TEST_RECORD_REDIRECT_PLUS -e never -c test_gns_lookup.conf | ||
60 | gnunet-namestore -p -z $MY_EGO -d -n $TEST_RECORD_NAME_ZKEY -t REDIRECT -V $TEST_RECORD_REDIRECT_ZKEY -e never -c test_gns_lookup.conf | ||
61 | gnunet-namestore -p -z $MY_EGO -d -n $TEST_RECORD_REDIRECT_SERVER -t A -V $TEST_IP_PLUS -e never -c test_gns_lookup.conf | ||
62 | gnunet-identity -D $MY_EGO -c test_gns_lookup.conf | ||
63 | gnunet-arm -e -c test_gns_lookup.conf | ||
64 | rm -rf `gnunet-config -c test_gns_lookup.conf -f -s paths -o GNUNET_TEST_HOME` | ||
65 | |||
66 | # make cmp case-insensitive by converting to lower case first | ||
67 | RES_REDIRECT_RAW=`echo $RES_REDIRECT_RAW | tr [A-Z] [a-z]` | ||
68 | TESTEGOZONE=`echo $TESTEGOZONE | tr [A-Z] [a-z]` | ||
69 | if [ "$RES_REDIRECT_RAW" = "server.$TESTEGOZONE" ] | ||
70 | then | ||
71 | echo "PASS: REDIRECT resolution from GNS" | ||
72 | else | ||
73 | echo "FAIL: REDIRECT resolution from GNS, got $RES_REDIRECT_RAW, expected server.$TESTEGOZONE." | ||
74 | exit 1 | ||
75 | fi | ||
76 | |||
77 | if [ "$RES_REDIRECT" = "$TEST_IP_PLUS" ] | ||
78 | then | ||
79 | echo "PASS: IP resolution from GNS (.+)" | ||
80 | else | ||
81 | echo "FAIL: IP resolution from GNS (.+), got $RES_REDIRECT, expected $TEST_IP_PLUS." | ||
82 | exit 1 | ||
83 | fi | ||
84 | |||
85 | if [ "$RES_REDIRECT_ZKEY" = "$TEST_IP_PLUS" ] | ||
86 | then | ||
87 | echo "PASS: IP resolution from GNS (.zkey)" | ||
88 | else | ||
89 | echo "FAIL: IP resolution from GNS (.zkey), got $RES_REDIRECT, expected $TEST_IP_PLUS." | ||
90 | exit 1 | ||
91 | fi | ||
92 | |||
93 | if echo "$RES_REDIRECT_DNS" | grep "$TEST_IP_DNS" > /dev/null | ||
94 | then | ||
95 | echo "PASS: IP resolution from DNS" | ||
96 | exit 0 | ||
97 | else | ||
98 | echo "FAIL: IP resolution from DNS, got $RES_REDIRECT_DNS, expected $TEST_IP_DNS." | ||
99 | exit 1 | ||
100 | fi | ||
diff --git a/src/gnsrecord/Makefile.am b/src/gnsrecord/Makefile.am index 4308d9c1a..e2538b1a2 100644 --- a/src/gnsrecord/Makefile.am +++ b/src/gnsrecord/Makefile.am | |||
@@ -20,7 +20,6 @@ check_PROGRAMS = \ | |||
20 | test_gnsrecord_crypto \ | 20 | test_gnsrecord_crypto \ |
21 | test_gnsrecord_serialization \ | 21 | test_gnsrecord_serialization \ |
22 | test_gnsrecord_block_expiration \ | 22 | test_gnsrecord_block_expiration \ |
23 | test_gnsrecord_testvectors \ | ||
24 | perf_gnsrecord_crypto | 23 | perf_gnsrecord_crypto |
25 | 24 | ||
26 | if ENABLE_TEST_RUN | 25 | if ENABLE_TEST_RUN |
@@ -35,7 +34,8 @@ lib_LTLIBRARIES = \ | |||
35 | libgnunetgnsrecordjson.la | 34 | libgnunetgnsrecordjson.la |
36 | 35 | ||
37 | gnunet_gnsrecord_tvg_SOURCES = \ | 36 | gnunet_gnsrecord_tvg_SOURCES = \ |
38 | gnunet-gnsrecord-tvg.c | 37 | gnunet-gnsrecord-tvg.c \ |
38 | gnsrecord_crypto.h | ||
39 | gnunet_gnsrecord_tvg_LDADD = \ | 39 | gnunet_gnsrecord_tvg_LDADD = \ |
40 | $(top_builddir)/src/util/libgnunetutil.la \ | 40 | $(top_builddir)/src/util/libgnunetutil.la \ |
41 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 41 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
@@ -86,13 +86,13 @@ libgnunet_plugin_gnsrecord_dns_la_LDFLAGS = \ | |||
86 | EXTRA_DIST = \ | 86 | EXTRA_DIST = \ |
87 | $(check_SCRIPTS) | 87 | $(check_SCRIPTS) |
88 | 88 | ||
89 | test_gnsrecord_testvectors_SOURCES = \ | 89 | #test_gnsrecord_testvectors_SOURCES = \ |
90 | test_gnsrecord_testvectors.c | 90 | # test_gnsrecord_testvectors.c |
91 | test_gnsrecord_testvectors_LDADD = \ | 91 | #test_gnsrecord_testvectors_LDADD = \ |
92 | $(top_builddir)/src/testing/libgnunettesting.la \ | 92 | # $(top_builddir)/src/testing/libgnunettesting.la \ |
93 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 93 | # $(top_builddir)/src/identity/libgnunetidentity.la \ |
94 | libgnunetgnsrecord.la \ | 94 | # libgnunetgnsrecord.la \ |
95 | $(top_builddir)/src/util/libgnunetutil.la | 95 | # $(top_builddir)/src/util/libgnunetutil.la |
96 | 96 | ||
97 | 97 | ||
98 | test_gnsrecord_serialization_SOURCES = \ | 98 | test_gnsrecord_serialization_SOURCES = \ |
diff --git a/src/gnsrecord/gnsrecord.c b/src/gnsrecord/gnsrecord.c index e9994a868..52c480ef6 100644 --- a/src/gnsrecord/gnsrecord.c +++ b/src/gnsrecord/gnsrecord.c | |||
@@ -260,4 +260,25 @@ GNUNET_GNSRECORD_number_to_typename (uint32_t type) | |||
260 | } | 260 | } |
261 | 261 | ||
262 | 262 | ||
263 | enum GNUNET_GenericReturnValue | ||
264 | GNUNET_GNSRECORD_is_critical (uint32_t type) | ||
265 | { | ||
266 | struct Plugin *plugin; | ||
267 | |||
268 | if (GNUNET_GNSRECORD_TYPE_ANY == type) | ||
269 | return GNUNET_NO; | ||
270 | init (); | ||
271 | for (unsigned int i = 0; i < num_plugins; i++) | ||
272 | { | ||
273 | plugin = gns_plugins[i]; | ||
274 | if (NULL == plugin->api->is_critical) | ||
275 | continue; | ||
276 | if (GNUNET_NO == plugin->api->is_critical (plugin->api->cls, type)) | ||
277 | continue; | ||
278 | return GNUNET_YES; | ||
279 | } | ||
280 | return GNUNET_NO; | ||
281 | } | ||
282 | |||
283 | |||
263 | /* end of gnsrecord.c */ | 284 | /* end of gnsrecord.c */ |
diff --git a/src/gnsrecord/gnsrecord_crypto.c b/src/gnsrecord/gnsrecord_crypto.c index 890ddb011..ff92911de 100644 --- a/src/gnsrecord/gnsrecord_crypto.c +++ b/src/gnsrecord/gnsrecord_crypto.c | |||
@@ -223,7 +223,6 @@ block_create_ecdsa (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | |||
223 | unsigned char ctr[GNUNET_CRYPTO_AES_KEY_LENGTH / 2]; | 223 | unsigned char ctr[GNUNET_CRYPTO_AES_KEY_LENGTH / 2]; |
224 | unsigned char skey[GNUNET_CRYPTO_AES_KEY_LENGTH]; | 224 | unsigned char skey[GNUNET_CRYPTO_AES_KEY_LENGTH]; |
225 | struct GNUNET_GNSRECORD_Data rdc[GNUNET_NZL (rd_count)]; | 225 | struct GNUNET_GNSRECORD_Data rdc[GNUNET_NZL (rd_count)]; |
226 | uint32_t rd_count_nbo; | ||
227 | struct GNUNET_TIME_Absolute now; | 226 | struct GNUNET_TIME_Absolute now; |
228 | 227 | ||
229 | if (payload_len < 0) | 228 | if (payload_len < 0) |
@@ -254,7 +253,6 @@ block_create_ecdsa (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | |||
254 | /* serialize */ | 253 | /* serialize */ |
255 | *block = GNUNET_malloc (sizeof (struct GNUNET_GNSRECORD_Block) + payload_len); | 254 | *block = GNUNET_malloc (sizeof (struct GNUNET_GNSRECORD_Block) + payload_len); |
256 | (*block)->size = htonl(sizeof (struct GNUNET_GNSRECORD_Block) + payload_len); | 255 | (*block)->size = htonl(sizeof (struct GNUNET_GNSRECORD_Block) + payload_len); |
257 | rd_count_nbo = htonl (rd_count); | ||
258 | { | 256 | { |
259 | char payload[payload_len]; | 257 | char payload[payload_len]; |
260 | 258 | ||
@@ -282,12 +280,12 @@ block_create_ecdsa (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | |||
282 | label, | 280 | label, |
283 | ecblock->expiration_time.abs_value_us__, | 281 | ecblock->expiration_time.abs_value_us__, |
284 | pkey); | 282 | pkey); |
285 | GNUNET_break (payload_len == | 283 | GNUNET_assert (payload_len == |
286 | ecdsa_symmetric_encrypt (payload, | 284 | ecdsa_symmetric_encrypt (payload, |
287 | payload_len, | 285 | payload_len, |
288 | skey, | 286 | skey, |
289 | ctr, | 287 | ctr, |
290 | &ecblock[1])); | 288 | &ecblock[1])); |
291 | GNUNET_memcpy (&gnr_block[1], &ecblock[1], payload_len); | 289 | GNUNET_memcpy (&gnr_block[1], &ecblock[1], payload_len); |
292 | } | 290 | } |
293 | if (GNUNET_OK != | 291 | if (GNUNET_OK != |
@@ -298,8 +296,10 @@ block_create_ecdsa (const struct GNUNET_CRYPTO_EcdsaPrivateKey *key, | |||
298 | GNUNET_break (0); | 296 | GNUNET_break (0); |
299 | GNUNET_free (*block); | 297 | GNUNET_free (*block); |
300 | GNUNET_free (dkey); | 298 | GNUNET_free (dkey); |
299 | GNUNET_free (gnr_block); | ||
301 | return GNUNET_SYSERR; | 300 | return GNUNET_SYSERR; |
302 | } | 301 | } |
302 | GNUNET_free (gnr_block); | ||
303 | GNUNET_free (dkey); | 303 | GNUNET_free (dkey); |
304 | return GNUNET_OK; | 304 | return GNUNET_OK; |
305 | } | 305 | } |
@@ -348,7 +348,6 @@ block_create_eddsa (const struct GNUNET_CRYPTO_EddsaPrivateKey *key, | |||
348 | unsigned char nonce[crypto_secretbox_NONCEBYTES]; | 348 | unsigned char nonce[crypto_secretbox_NONCEBYTES]; |
349 | unsigned char skey[crypto_secretbox_KEYBYTES]; | 349 | unsigned char skey[crypto_secretbox_KEYBYTES]; |
350 | struct GNUNET_GNSRECORD_Data rdc[GNUNET_NZL (rd_count)]; | 350 | struct GNUNET_GNSRECORD_Data rdc[GNUNET_NZL (rd_count)]; |
351 | uint32_t rd_count_nbo; | ||
352 | struct GNUNET_TIME_Absolute now; | 351 | struct GNUNET_TIME_Absolute now; |
353 | 352 | ||
354 | if (payload_len < 0) | 353 | if (payload_len < 0) |
@@ -381,7 +380,6 @@ block_create_eddsa (const struct GNUNET_CRYPTO_EddsaPrivateKey *key, | |||
381 | + payload_len + crypto_secretbox_MACBYTES); | 380 | + payload_len + crypto_secretbox_MACBYTES); |
382 | (*block)->size = htonl(sizeof (struct GNUNET_GNSRECORD_Block) | 381 | (*block)->size = htonl(sizeof (struct GNUNET_GNSRECORD_Block) |
383 | + payload_len + crypto_secretbox_MACBYTES); | 382 | + payload_len + crypto_secretbox_MACBYTES); |
384 | rd_count_nbo = htonl (rd_count); | ||
385 | { | 383 | { |
386 | char payload[payload_len]; | 384 | char payload[payload_len]; |
387 | 385 | ||
@@ -415,12 +413,12 @@ block_create_eddsa (const struct GNUNET_CRYPTO_EddsaPrivateKey *key, | |||
415 | label, | 413 | label, |
416 | edblock->expiration_time.abs_value_us__, | 414 | edblock->expiration_time.abs_value_us__, |
417 | pkey); | 415 | pkey); |
418 | GNUNET_break (GNUNET_OK == | 416 | GNUNET_assert (GNUNET_OK == |
419 | eddsa_symmetric_encrypt (payload, | 417 | eddsa_symmetric_encrypt (payload, |
420 | payload_len, | 418 | payload_len, |
421 | skey, | 419 | skey, |
422 | nonce, | 420 | nonce, |
423 | &edblock[1])); | 421 | &edblock[1])); |
424 | GNUNET_memcpy (&gnr_block[1], &edblock[1], | 422 | GNUNET_memcpy (&gnr_block[1], &edblock[1], |
425 | payload_len + crypto_secretbox_MACBYTES); | 423 | payload_len + crypto_secretbox_MACBYTES); |
426 | 424 | ||
@@ -438,7 +436,7 @@ GNUNET_GNSRECORD_block_calculate_size (const struct | |||
438 | unsigned int rd_count) | 436 | unsigned int rd_count) |
439 | { | 437 | { |
440 | struct GNUNET_IDENTITY_PublicKey pkey; | 438 | struct GNUNET_IDENTITY_PublicKey pkey; |
441 | ssize_t res; | 439 | ssize_t res = -1; |
442 | 440 | ||
443 | GNUNET_IDENTITY_key_get_public (key, | 441 | GNUNET_IDENTITY_key_get_public (key, |
444 | &pkey); | 442 | &pkey); |
@@ -453,7 +451,7 @@ GNUNET_GNSRECORD_block_calculate_size (const struct | |||
453 | default: | 451 | default: |
454 | GNUNET_assert (0); | 452 | GNUNET_assert (0); |
455 | } | 453 | } |
456 | return -1; | 454 | return res; |
457 | 455 | ||
458 | } | 456 | } |
459 | 457 | ||
@@ -593,8 +591,9 @@ GNUNET_GNSRECORD_block_verify (const struct GNUNET_GNSRECORD_Block *block) | |||
593 | purp = GNUNET_malloc (sizeof (struct GNRBlockPS) + payload_len); | 591 | purp = GNUNET_malloc (sizeof (struct GNRBlockPS) + payload_len); |
594 | purp->purpose.size = htonl (sizeof (struct GNRBlockPS) + payload_len); | 592 | purp->purpose.size = htonl (sizeof (struct GNRBlockPS) + payload_len); |
595 | purp->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_GNS_RECORD_SIGN); | 593 | purp->purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_GNS_RECORD_SIGN); |
596 | GNUNET_memcpy (&purp[1], &block[1], payload_len); | 594 | GNUNET_memcpy (&purp[1], |
597 | 595 | &block[1], | |
596 | payload_len); | ||
598 | switch (ntohl (block->type)) | 597 | switch (ntohl (block->type)) |
599 | { | 598 | { |
600 | case GNUNET_GNSRECORD_TYPE_PKEY: | 599 | case GNUNET_GNSRECORD_TYPE_PKEY: |
@@ -650,10 +649,10 @@ block_decrypt_ecdsa (const struct GNUNET_GNSRECORD_Block *block, | |||
650 | char payload[payload_len]; | 649 | char payload[payload_len]; |
651 | unsigned int rd_count; | 650 | unsigned int rd_count; |
652 | 651 | ||
653 | GNUNET_break (payload_len == | 652 | GNUNET_assert (payload_len == |
654 | ecdsa_symmetric_decrypt (&block[1], payload_len, | 653 | ecdsa_symmetric_decrypt (&block[1], payload_len, |
655 | key, ctr, | 654 | key, ctr, |
656 | payload)); | 655 | payload)); |
657 | rd_count = GNUNET_GNSRECORD_records_deserialize_get_size (payload_len, | 656 | rd_count = GNUNET_GNSRECORD_records_deserialize_get_size (payload_len, |
658 | payload); | 657 | payload); |
659 | if (rd_count > 2048) | 658 | if (rd_count > 2048) |
@@ -754,7 +753,6 @@ block_decrypt_eddsa (const struct GNUNET_GNSRECORD_Block *block, | |||
754 | GNUNET_GNSRECORD_RecordCallback proc, | 753 | GNUNET_GNSRECORD_RecordCallback proc, |
755 | void *proc_cls) | 754 | void *proc_cls) |
756 | { | 755 | { |
757 | const struct GNUNET_GNSRECORD_EddsaBlock *edblock = &block->eddsa_block; | ||
758 | size_t payload_len = ntohl (block->size) - sizeof (struct | 756 | size_t payload_len = ntohl (block->size) - sizeof (struct |
759 | GNUNET_GNSRECORD_Block); | 757 | GNUNET_GNSRECORD_Block); |
760 | unsigned char nonce[crypto_secretbox_NONCEBYTES]; | 758 | unsigned char nonce[crypto_secretbox_NONCEBYTES]; |
@@ -776,10 +774,10 @@ block_decrypt_eddsa (const struct GNUNET_GNSRECORD_Block *block, | |||
776 | char payload[payload_len]; | 774 | char payload[payload_len]; |
777 | unsigned int rd_count; | 775 | unsigned int rd_count; |
778 | 776 | ||
779 | GNUNET_break (GNUNET_OK == | 777 | GNUNET_assert (GNUNET_OK == |
780 | eddsa_symmetric_decrypt (&block[1], payload_len, | 778 | eddsa_symmetric_decrypt (&block[1], payload_len, |
781 | key, nonce, | 779 | key, nonce, |
782 | payload)); | 780 | payload)); |
783 | payload_len -= crypto_secretbox_MACBYTES; | 781 | payload_len -= crypto_secretbox_MACBYTES; |
784 | rd_count = GNUNET_GNSRECORD_records_deserialize_get_size (payload_len, | 782 | rd_count = GNUNET_GNSRECORD_records_deserialize_get_size (payload_len, |
785 | payload); | 783 | payload); |
@@ -909,7 +907,7 @@ GNUNET_GNSRECORD_block_decrypt (const struct GNUNET_GNSRECORD_Block *block, | |||
909 | proc_cls); | 907 | proc_cls); |
910 | break; | 908 | break; |
911 | default: | 909 | default: |
912 | return GNUNET_SYSERR; | 910 | res = GNUNET_SYSERR; |
913 | } | 911 | } |
914 | GNUNET_free (norm_label); | 912 | GNUNET_free (norm_label); |
915 | return res; | 913 | return res; |
diff --git a/src/gnsrecord/gnsrecord_misc.c b/src/gnsrecord/gnsrecord_misc.c index 61604c730..54d8fb860 100644 --- a/src/gnsrecord/gnsrecord_misc.c +++ b/src/gnsrecord/gnsrecord_misc.c | |||
@@ -38,23 +38,26 @@ | |||
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 | char * | 40 | char * |
41 | GNUNET_GNSRECORD_string_to_lowercase (const char *src) | 41 | GNUNET_GNSRECORD_string_normalize (const char *src) |
42 | { | 42 | { |
43 | char *res; | 43 | /*FIXME: We may want to follow RFC5890/RFC5891 */ |
44 | 44 | return GNUNET_STRINGS_utf8_normalize (src); | |
45 | res = GNUNET_strdup (src); | ||
46 | GNUNET_STRINGS_utf8_tolower (src, res); | ||
47 | return res; | ||
48 | } | 45 | } |
49 | 46 | ||
50 | char * | 47 | enum GNUNET_GenericReturnValue |
51 | GNUNET_GNSRECORD_string_normalize (const char *src) | 48 | GNUNET_GNSRECORD_label_check (const char*label, char **emsg) |
52 | { | 49 | { |
53 | char *res; | 50 | if (NULL == label) |
54 | res = GNUNET_strdup (src); | 51 | { |
55 | GNUNET_STRINGS_utf8_tolower (src, res); | 52 | *emsg = GNUNET_strdup (_ ("Label is NULL which is not allowed\n")); |
56 | GNUNET_STRINGS_utf8_normalize (src, res); | 53 | return GNUNET_NO; |
57 | return res; | 54 | } |
55 | if (0 != strchr (label, '.')) | ||
56 | { | ||
57 | *emsg = GNUNET_strdup (_ ("Label contains `.' which is not allowed\n")); | ||
58 | return GNUNET_NO; | ||
59 | } | ||
60 | return GNUNET_OK; | ||
58 | } | 61 | } |
59 | 62 | ||
60 | /** | 63 | /** |
@@ -144,19 +147,11 @@ GNUNET_GNSRECORD_records_cmp (const struct GNUNET_GNSRECORD_Data *a, | |||
144 | } | 147 | } |
145 | 148 | ||
146 | 149 | ||
147 | /** | ||
148 | * Returns the expiration time of the given block of records. The block | ||
149 | * expiration time is the expiration time of the record with smallest | ||
150 | * expiration time. | ||
151 | * | ||
152 | * @param rd_count number of records given in @a rd | ||
153 | * @param rd array of records | ||
154 | * @return absolute expiration time | ||
155 | */ | ||
156 | struct GNUNET_TIME_Absolute | 150 | struct GNUNET_TIME_Absolute |
157 | GNUNET_GNSRECORD_record_get_expiration_time (unsigned int rd_count, | 151 | GNUNET_GNSRECORD_record_get_expiration_time (unsigned int rd_count, |
158 | const struct | 152 | const struct |
159 | GNUNET_GNSRECORD_Data *rd) | 153 | GNUNET_GNSRECORD_Data *rd, |
154 | struct GNUNET_TIME_Absolute min) | ||
160 | { | 155 | { |
161 | struct GNUNET_TIME_Absolute expire; | 156 | struct GNUNET_TIME_Absolute expire; |
162 | struct GNUNET_TIME_Absolute at; | 157 | struct GNUNET_TIME_Absolute at; |
@@ -164,8 +159,8 @@ GNUNET_GNSRECORD_record_get_expiration_time (unsigned int rd_count, | |||
164 | struct GNUNET_TIME_Absolute at_shadow; | 159 | struct GNUNET_TIME_Absolute at_shadow; |
165 | struct GNUNET_TIME_Relative rt_shadow; | 160 | struct GNUNET_TIME_Relative rt_shadow; |
166 | 161 | ||
167 | if (NULL == rd) | 162 | if (0 == rd_count) |
168 | return GNUNET_TIME_UNIT_ZERO_ABS; | 163 | return GNUNET_TIME_absolute_max (GNUNET_TIME_UNIT_ZERO_ABS, min); |
169 | expire = GNUNET_TIME_UNIT_FOREVER_ABS; | 164 | expire = GNUNET_TIME_UNIT_FOREVER_ABS; |
170 | for (unsigned int c = 0; c < rd_count; c++) | 165 | for (unsigned int c = 0; c < rd_count; c++) |
171 | { | 166 | { |
@@ -202,6 +197,7 @@ GNUNET_GNSRECORD_record_get_expiration_time (unsigned int rd_count, | |||
202 | expire = GNUNET_TIME_absolute_min (at, | 197 | expire = GNUNET_TIME_absolute_min (at, |
203 | expire); | 198 | expire); |
204 | } | 199 | } |
200 | expire = GNUNET_TIME_absolute_max (expire, min); | ||
205 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 201 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
206 | "Determined expiration time for block with %u records to be %s\n", | 202 | "Determined expiration time for block with %u records to be %s\n", |
207 | rd_count, | 203 | rd_count, |
@@ -284,12 +280,24 @@ GNUNET_GNSRECORD_identity_from_data (const char *data, | |||
284 | { | 280 | { |
285 | if (GNUNET_NO == GNUNET_GNSRECORD_is_zonekey_type (type)) | 281 | if (GNUNET_NO == GNUNET_GNSRECORD_is_zonekey_type (type)) |
286 | return GNUNET_SYSERR; | 282 | return GNUNET_SYSERR; |
287 | if (data_size > sizeof (struct GNUNET_IDENTITY_PublicKey)) | 283 | switch (type) |
288 | return GNUNET_SYSERR; | 284 | { |
289 | return (GNUNET_IDENTITY_read_key_from_buffer (key, data, data_size) == | 285 | case GNUNET_GNSRECORD_TYPE_PKEY: |
290 | data_size? | 286 | if (data_size > sizeof (struct GNUNET_CRYPTO_EcdsaPublicKey)) |
291 | GNUNET_OK : | 287 | return GNUNET_SYSERR; |
292 | GNUNET_SYSERR); | 288 | memcpy (&key->ecdsa_key, data, data_size); |
289 | break; | ||
290 | case GNUNET_GNSRECORD_TYPE_EDKEY: | ||
291 | if (data_size > sizeof (struct GNUNET_CRYPTO_EddsaPublicKey)) | ||
292 | return GNUNET_SYSERR; | ||
293 | memcpy (&key->eddsa_key, data, data_size); | ||
294 | break; | ||
295 | default: | ||
296 | return GNUNET_NO; | ||
297 | } | ||
298 | key->type = htonl (type); | ||
299 | |||
300 | return GNUNET_YES; | ||
293 | } | 301 | } |
294 | 302 | ||
295 | 303 | ||
@@ -302,16 +310,11 @@ GNUNET_GNSRECORD_data_from_identity (const struct | |||
302 | { | 310 | { |
303 | char *tmp; | 311 | char *tmp; |
304 | *type = ntohl (key->type); | 312 | *type = ntohl (key->type); |
305 | *data_size = GNUNET_IDENTITY_key_get_length (key); | 313 | *data_size = GNUNET_IDENTITY_key_get_length (key) - sizeof (key->type); |
306 | if (0 == *data_size) | 314 | if (0 == *data_size) |
307 | return GNUNET_SYSERR; | 315 | return GNUNET_SYSERR; |
308 | tmp = GNUNET_malloc (*data_size); | 316 | tmp = GNUNET_malloc (*data_size); |
309 | if (GNUNET_IDENTITY_write_key_to_buffer (key, tmp, *data_size) | 317 | memcpy (tmp, ((char*) key) + sizeof (key->type), *data_size); |
310 | != *data_size) { | ||
311 | GNUNET_free (tmp); | ||
312 | *data_size = 0; | ||
313 | return GNUNET_SYSERR; | ||
314 | } | ||
315 | *data = tmp; | 318 | *data = tmp; |
316 | return GNUNET_OK; | 319 | return GNUNET_OK; |
317 | } | 320 | } |
@@ -406,5 +409,176 @@ GNUNET_GNSRECORD_record_to_identity_key (const struct GNUNET_GNSRECORD_Data *rd, | |||
406 | 409 | ||
407 | } | 410 | } |
408 | 411 | ||
412 | enum GNUNET_GenericReturnValue | ||
413 | GNUNET_GNSRECORD_normalize_record_set (const char *label, | ||
414 | const struct | ||
415 | GNUNET_GNSRECORD_Data *rd, | ||
416 | unsigned int rd_count, | ||
417 | struct GNUNET_GNSRECORD_Data * | ||
418 | rd_public, | ||
419 | unsigned int *rd_count_public, | ||
420 | struct GNUNET_TIME_Absolute *expiry, | ||
421 | int include_private, | ||
422 | char **emsg) | ||
423 | { | ||
424 | struct GNUNET_TIME_Absolute now; | ||
425 | struct GNUNET_TIME_Absolute minimum_expiration; | ||
426 | int have_zone_delegation = GNUNET_NO; | ||
427 | int have_gns2dns = GNUNET_NO; | ||
428 | int have_other = GNUNET_NO; | ||
429 | int have_redirect = GNUNET_NO; | ||
430 | int have_empty_label = (0 == strcmp (GNUNET_GNS_EMPTY_LABEL_AT, label)); | ||
431 | unsigned int rd_count_tmp; | ||
432 | |||
433 | minimum_expiration = GNUNET_TIME_UNIT_ZERO_ABS; | ||
434 | now = GNUNET_TIME_absolute_get (); | ||
435 | rd_count_tmp = 0; | ||
436 | for (unsigned int i = 0; i < rd_count; i++) | ||
437 | { | ||
438 | /* Ignore the tombstone. For maintenance only. Remember expiration time. */ | ||
439 | if (GNUNET_GNSRECORD_TYPE_TOMBSTONE == rd[i].record_type) | ||
440 | { | ||
441 | minimum_expiration.abs_value_us = rd[i].expiration_time; | ||
442 | continue; | ||
443 | } | ||
444 | /* No NICK records unless empty label */ | ||
445 | if (have_empty_label && | ||
446 | (GNUNET_GNSRECORD_TYPE_NICK == rd[i].record_type)) | ||
447 | continue; | ||
448 | |||
449 | /** | ||
450 | * Check for delegation and redirect consistency. | ||
451 | * Note that we check for consistency BEFORE we filter for | ||
452 | * private records ON PURPOSE. | ||
453 | * We also want consistent record sets in our local zone(s). | ||
454 | * The only exception is the tombstone (above) which we ignore | ||
455 | * for the consistency check(s). | ||
456 | * FIXME: What about shadow records? Should we ignore them? | ||
457 | */ | ||
458 | if (GNUNET_YES == GNUNET_GNSRECORD_is_zonekey_type (rd[i].record_type)) | ||
459 | { | ||
460 | /* No delegation records under empty label*/ | ||
461 | if (have_empty_label) | ||
462 | { | ||
463 | *emsg = GNUNET_strdup (_ ( | ||
464 | "Zone delegation record not allowed in apex.")); | ||
465 | return GNUNET_SYSERR; | ||
466 | } | ||
467 | if ((GNUNET_YES == have_other) || | ||
468 | (GNUNET_YES == have_redirect) || | ||
469 | (GNUNET_YES == have_gns2dns)) | ||
470 | { | ||
471 | *emsg = GNUNET_strdup (_ ( | ||
472 | "Zone delegation record set contains mutually exclusive records.")); | ||
473 | return GNUNET_SYSERR; | ||
474 | } | ||
475 | have_zone_delegation = GNUNET_YES; | ||
476 | } | ||
477 | else if (GNUNET_GNSRECORD_TYPE_REDIRECT == rd[i].record_type) | ||
478 | { | ||
479 | if (GNUNET_YES == have_redirect) | ||
480 | { | ||
481 | *emsg = GNUNET_strdup (_ ( | ||
482 | "Multiple REDIRECT records.")); | ||
483 | return GNUNET_SYSERR; | ||
484 | |||
485 | } | ||
486 | if ((GNUNET_YES == have_other) || | ||
487 | (GNUNET_YES == have_zone_delegation) || | ||
488 | (GNUNET_YES == have_gns2dns)) | ||
489 | { | ||
490 | *emsg = GNUNET_strdup (_ ( | ||
491 | "Redirection record set conains mutually exclusive records.")); | ||
492 | return GNUNET_SYSERR; | ||
493 | } | ||
494 | /* No redirection records under empty label*/ | ||
495 | if (have_empty_label) | ||
496 | { | ||
497 | *emsg = GNUNET_strdup (_ ( | ||
498 | "Redirection records not allowed in apex.")); | ||
499 | return GNUNET_SYSERR; | ||
500 | } | ||
501 | have_redirect = GNUNET_YES; | ||
502 | } | ||
503 | else if (GNUNET_GNSRECORD_TYPE_GNS2DNS == rd[i].record_type) | ||
504 | { | ||
505 | /* No gns2dns records under empty label*/ | ||
506 | if (have_empty_label) | ||
507 | { | ||
508 | *emsg = GNUNET_strdup (_ ( | ||
509 | "Redirection records not allowed in apex..")); | ||
510 | return GNUNET_SYSERR; | ||
511 | } | ||
512 | if ((GNUNET_YES == have_other) || | ||
513 | (GNUNET_YES == have_redirect) || | ||
514 | (GNUNET_YES == have_zone_delegation)) | ||
515 | { | ||
516 | *emsg = GNUNET_strdup (_ ( | ||
517 | "Redirection record set conains mutually exclusive records.")); | ||
518 | return GNUNET_SYSERR; | ||
519 | } | ||
520 | have_gns2dns = GNUNET_YES; | ||
521 | } | ||
522 | else | ||
523 | { | ||
524 | /* Some other record. | ||
525 | * Not allowed for zone delegations or redirections */ | ||
526 | if ((GNUNET_YES == have_zone_delegation) || | ||
527 | (GNUNET_YES == have_redirect) || | ||
528 | (GNUNET_YES == have_gns2dns)) | ||
529 | { | ||
530 | *emsg = GNUNET_strdup (_ ( | ||
531 | "Mutually exclusive records.")); | ||
532 | return GNUNET_SYSERR; | ||
533 | } | ||
534 | have_other = GNUNET_YES; | ||
535 | } | ||
536 | |||
537 | /* Ignore private records for public record set */ | ||
538 | |||
539 | if ((GNUNET_NO == include_private) && | ||
540 | (0 != (rd[i].flags & GNUNET_GNSRECORD_RF_PRIVATE))) | ||
541 | continue; | ||
542 | /* Skip expired records */ | ||
543 | if ((0 == (rd[i].flags & GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION)) && | ||
544 | (rd[i].expiration_time < now.abs_value_us)) | ||
545 | continue; /* record already expired, skip it */ | ||
546 | rd_public[rd_count_tmp] = rd[i]; | ||
547 | /* Make sure critical record types are marked as such */ | ||
548 | if (GNUNET_YES == GNUNET_GNSRECORD_is_critical (rd[i].record_type)) | ||
549 | rd_public[rd_count_tmp].flags |= GNUNET_GNSRECORD_RF_CRITICAL; | ||
550 | rd_count_tmp++; | ||
551 | } | ||
552 | |||
553 | *expiry = GNUNET_GNSRECORD_record_get_expiration_time (rd_count_tmp, | ||
554 | rd_public, | ||
555 | minimum_expiration); | ||
556 | *rd_count_public = rd_count_tmp; | ||
557 | return GNUNET_OK; | ||
558 | } | ||
559 | |||
560 | enum GNUNET_GenericReturnValue | ||
561 | GNUNET_GNSRECORD_convert_records_for_export (const char *label, | ||
562 | const struct | ||
563 | GNUNET_GNSRECORD_Data *rd, | ||
564 | unsigned int rd_count, | ||
565 | struct GNUNET_GNSRECORD_Data * | ||
566 | rd_public, | ||
567 | unsigned int *rd_count_public, | ||
568 | struct GNUNET_TIME_Absolute *expiry, | ||
569 | char **emsg) | ||
570 | { | ||
571 | return GNUNET_GNSRECORD_normalize_record_set (label, | ||
572 | rd, | ||
573 | rd_count, | ||
574 | rd_public, | ||
575 | rd_count_public, | ||
576 | expiry, | ||
577 | GNUNET_NO, | ||
578 | emsg); | ||
579 | |||
580 | } | ||
581 | |||
582 | |||
409 | 583 | ||
410 | /* end of gnsrecord_misc.c */ | 584 | /* end of gnsrecord_misc.c */ |
diff --git a/src/gnsrecord/gnunet-gnsrecord-tvg.c b/src/gnsrecord/gnunet-gnsrecord-tvg.c index f9b83e48b..87de32066 100644 --- a/src/gnsrecord/gnunet-gnsrecord-tvg.c +++ b/src/gnsrecord/gnunet-gnsrecord-tvg.c | |||
@@ -33,9 +33,6 @@ | |||
33 | #include <inttypes.h> | 33 | #include <inttypes.h> |
34 | #include "gnsrecord_crypto.h" | 34 | #include "gnsrecord_crypto.h" |
35 | 35 | ||
36 | #define TEST_RECORD_LABEL "test" | ||
37 | #define TEST_RECORD_A "1.2.3.4" | ||
38 | #define TEST_RRCOUNT 2 | ||
39 | 36 | ||
40 | static char *d_pkey = | 37 | static char *d_pkey = |
41 | "50d7b652a4efeadff37396909785e5952171a02178c8e7d450fa907925fafd98"; | 38 | "50d7b652a4efeadff37396909785e5952171a02178c8e7d450fa907925fafd98"; |
@@ -43,7 +40,9 @@ static char *d_pkey = | |||
43 | static char *d_edkey = | 40 | static char *d_edkey = |
44 | "5af7020ee19160328832352bbc6a68a8d71a7cbe1b929969a7c66d415a0d8f65"; | 41 | "5af7020ee19160328832352bbc6a68a8d71a7cbe1b929969a7c66d415a0d8f65"; |
45 | 42 | ||
46 | int parsehex (char *src, char *dst, size_t dstlen, int invert) | 43 | |
44 | static int | ||
45 | parsehex (char *src, char *dst, size_t dstlen, int invert) | ||
47 | { | 46 | { |
48 | char *line = src; | 47 | char *line = src; |
49 | char *data = line; | 48 | char *data = line; |
@@ -83,6 +82,7 @@ print_bytes_ (void *buf, | |||
83 | printf ("\n"); | 82 | printf ("\n"); |
84 | } | 83 | } |
85 | 84 | ||
85 | |||
86 | static void | 86 | static void |
87 | print_bytes (void *buf, | 87 | print_bytes (void *buf, |
88 | size_t buf_len, | 88 | size_t buf_len, |
@@ -95,7 +95,7 @@ print_bytes (void *buf, | |||
95 | static void | 95 | static void |
96 | print_record (const struct GNUNET_GNSRECORD_Data *rd) | 96 | print_record (const struct GNUNET_GNSRECORD_Data *rd) |
97 | { | 97 | { |
98 | 98 | uint16_t flags = htons (rd->flags); | |
99 | fprintf (stdout, | 99 | fprintf (stdout, |
100 | "EXPIRATION: %" PRIu64 "\n", rd->expiration_time); | 100 | "EXPIRATION: %" PRIu64 "\n", rd->expiration_time); |
101 | fprintf (stdout, | 101 | fprintf (stdout, |
@@ -103,7 +103,9 @@ print_record (const struct GNUNET_GNSRECORD_Data *rd) | |||
103 | fprintf (stdout, | 103 | fprintf (stdout, |
104 | "TYPE: %d\n", rd->record_type); | 104 | "TYPE: %d\n", rd->record_type); |
105 | fprintf (stdout, | 105 | fprintf (stdout, |
106 | "FLAGS: %d\n", rd->flags); | 106 | "FLAGS: "); |
107 | print_bytes ((void*) &flags, sizeof (flags), 8); | ||
108 | printf ("\n"); | ||
107 | fprintf (stdout, | 109 | fprintf (stdout, |
108 | "DATA:\n"); | 110 | "DATA:\n"); |
109 | print_bytes ((char*) rd->data, rd->data_size, 8); | 111 | print_bytes ((char*) rd->data, rd->data_size, 8); |
@@ -120,15 +122,9 @@ print_record (const struct GNUNET_GNSRECORD_Data *rd) | |||
120 | * @param cfg configuration | 122 | * @param cfg configuration |
121 | */ | 123 | */ |
122 | static void | 124 | static void |
123 | run_pkey (void) | 125 | run_pkey (struct GNUNET_GNSRECORD_Data *rd, int rd_count, const char *label) |
124 | { | 126 | { |
125 | struct GNUNET_GNSRECORD_Data rd[2]; | ||
126 | struct GNUNET_TIME_Absolute expire; | 127 | struct GNUNET_TIME_Absolute expire; |
127 | struct GNUNET_TIME_Absolute now = GNUNET_TIME_absolute_get (); | ||
128 | struct GNUNET_TIME_Absolute exp1; | ||
129 | struct GNUNET_TIME_Absolute exp2; | ||
130 | struct GNUNET_TIME_Relative delta1; | ||
131 | struct GNUNET_TIME_Relative delta2; | ||
132 | struct GNUNET_GNSRECORD_Block *rrblock; | 128 | struct GNUNET_GNSRECORD_Block *rrblock; |
133 | char *bdata; | 129 | char *bdata; |
134 | struct GNUNET_IDENTITY_PrivateKey id_priv; | 130 | struct GNUNET_IDENTITY_PrivateKey id_priv; |
@@ -136,24 +132,12 @@ run_pkey (void) | |||
136 | struct GNUNET_IDENTITY_PrivateKey pkey_data_p; | 132 | struct GNUNET_IDENTITY_PrivateKey pkey_data_p; |
137 | struct GNUNET_IDENTITY_PublicKey pkey_data; | 133 | struct GNUNET_IDENTITY_PublicKey pkey_data; |
138 | struct GNUNET_HashCode query; | 134 | struct GNUNET_HashCode query; |
139 | void *data; | ||
140 | size_t data_size; | ||
141 | char *rdata; | 135 | char *rdata; |
142 | size_t rdata_size; | 136 | size_t rdata_size; |
143 | uint32_t rd_count_nbo; | ||
144 | char ztld[128]; | 137 | char ztld[128]; |
145 | unsigned char ctr[GNUNET_CRYPTO_AES_KEY_LENGTH / 2]; | 138 | unsigned char ctr[GNUNET_CRYPTO_AES_KEY_LENGTH / 2]; |
146 | unsigned char skey[GNUNET_CRYPTO_AES_KEY_LENGTH]; | 139 | unsigned char skey[GNUNET_CRYPTO_AES_KEY_LENGTH]; |
147 | 140 | ||
148 | /* | ||
149 | * Make two different expiration times | ||
150 | */ | ||
151 | GNUNET_STRINGS_fancy_time_to_absolute ("2048-01-23 10:51:34", | ||
152 | &exp1); | ||
153 | GNUNET_STRINGS_fancy_time_to_absolute ("3540-05-22 07:55:01", | ||
154 | &exp2); | ||
155 | |||
156 | |||
157 | id_priv.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); | 141 | id_priv.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
158 | GNUNET_CRYPTO_ecdsa_key_create (&id_priv.ecdsa_key); | 142 | GNUNET_CRYPTO_ecdsa_key_create (&id_priv.ecdsa_key); |
159 | parsehex (d_pkey, | 143 | parsehex (d_pkey, |
@@ -168,13 +152,14 @@ run_pkey (void) | |||
168 | sizeof (struct GNUNET_CRYPTO_EcdsaPrivateKey), 8, 1); | 152 | sizeof (struct GNUNET_CRYPTO_EcdsaPrivateKey), 8, 1); |
169 | fprintf (stdout, "\n"); | 153 | fprintf (stdout, "\n"); |
170 | fprintf (stdout, "Zone identifier (ztype|zkey):\n"); | 154 | fprintf (stdout, "Zone identifier (ztype|zkey):\n"); |
155 | GNUNET_assert (0 < GNUNET_IDENTITY_key_get_length (&id_pub)); | ||
171 | print_bytes (&id_pub, GNUNET_IDENTITY_key_get_length (&id_pub), 8); | 156 | print_bytes (&id_pub, GNUNET_IDENTITY_key_get_length (&id_pub), 8); |
172 | GNUNET_STRINGS_data_to_string (&id_pub, | 157 | GNUNET_STRINGS_data_to_string (&id_pub, |
173 | GNUNET_IDENTITY_key_get_length (&id_pub), | 158 | GNUNET_IDENTITY_key_get_length (&id_pub), |
174 | ztld, | 159 | ztld, |
175 | sizeof (ztld)); | 160 | sizeof (ztld)); |
176 | fprintf (stdout, "\n"); | 161 | fprintf (stdout, "\n"); |
177 | fprintf (stdout, "Encoded zone identifier (zkl = zTLD):\n"); | 162 | fprintf (stdout, "zTLD:\n"); |
178 | fprintf (stdout, "%s\n", ztld); | 163 | fprintf (stdout, "%s\n", ztld); |
179 | fprintf (stdout, "\n"); | 164 | fprintf (stdout, "\n"); |
180 | 165 | ||
@@ -183,39 +168,31 @@ run_pkey (void) | |||
183 | GNUNET_IDENTITY_key_get_public (&pkey_data_p, | 168 | GNUNET_IDENTITY_key_get_public (&pkey_data_p, |
184 | &pkey_data); | 169 | &pkey_data); |
185 | fprintf (stdout, | 170 | fprintf (stdout, |
186 | "Label: %s\nRRCOUNT: %d\n\n", TEST_RECORD_LABEL, TEST_RRCOUNT); | 171 | "Label: %s\nRRCOUNT: %d\n\n", label, rd_count); |
187 | memset (rd, 0, sizeof (struct GNUNET_GNSRECORD_Data) * 2); | ||
188 | GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_string_to_value ( | ||
189 | GNUNET_DNSPARSER_TYPE_A, TEST_RECORD_A, &data, &data_size)); | ||
190 | rd[0].data = data; | ||
191 | rd[0].data_size = data_size; | ||
192 | rd[0].expiration_time = exp1.abs_value_us; | ||
193 | rd[0].record_type = GNUNET_DNSPARSER_TYPE_A; | ||
194 | fprintf (stdout, "Record #0\n"); | ||
195 | print_record (&rd[0]); | ||
196 | 172 | ||
197 | rd[1].data = "Some nick"; | 173 | for (int i = 0; i < rd_count; i++) |
198 | rd[1].data_size = sizeof (struct GNUNET_IDENTITY_PublicKey); | 174 | { |
199 | rd[1].expiration_time = exp2.abs_value_us; | 175 | fprintf (stdout, "Record #%d\n", i); |
200 | rd[1].record_type = GNUNET_GNSRECORD_TYPE_NICK; | 176 | print_record (&rd[i]); |
201 | rd[1].flags = GNUNET_GNSRECORD_RF_PRIVATE; | 177 | } |
202 | fprintf (stdout, "Record #1\n"); | ||
203 | print_record (&rd[1]); | ||
204 | 178 | ||
205 | rdata_size = GNUNET_GNSRECORD_records_get_size (TEST_RRCOUNT, | 179 | rdata_size = GNUNET_GNSRECORD_records_get_size (rd_count, |
206 | rd); | 180 | rd); |
207 | rdata = GNUNET_malloc (rdata_size); | 181 | rdata = GNUNET_malloc (rdata_size); |
208 | GNUNET_GNSRECORD_records_serialize (2, | 182 | GNUNET_GNSRECORD_records_serialize (rd_count, |
209 | rd, | 183 | rd, |
210 | rdata_size, | 184 | (size_t) rdata_size, |
211 | rdata); | 185 | rdata); |
212 | fprintf (stdout, "RDATA:\n"); | 186 | fprintf (stdout, "RDATA:\n"); |
213 | print_bytes (rdata, rdata_size, 8); | 187 | print_bytes (rdata, |
188 | (size_t) rdata_size, | ||
189 | 8); | ||
214 | fprintf (stdout, "\n"); | 190 | fprintf (stdout, "\n"); |
215 | expire = GNUNET_GNSRECORD_record_get_expiration_time (TEST_RRCOUNT, rd); | 191 | expire = GNUNET_GNSRECORD_record_get_expiration_time (rd_count, rd, |
192 | GNUNET_TIME_UNIT_ZERO_ABS); | ||
216 | GNR_derive_block_aes_key (ctr, | 193 | GNR_derive_block_aes_key (ctr, |
217 | skey, | 194 | skey, |
218 | TEST_RECORD_LABEL, | 195 | label, |
219 | GNUNET_TIME_absolute_hton ( | 196 | GNUNET_TIME_absolute_hton ( |
220 | expire).abs_value_us__, | 197 | expire).abs_value_us__, |
221 | &id_pub.ecdsa_key); | 198 | &id_pub.ecdsa_key); |
@@ -227,25 +204,26 @@ run_pkey (void) | |||
227 | print_bytes (skey, sizeof (skey), 8); | 204 | print_bytes (skey, sizeof (skey), 8); |
228 | fprintf (stdout, "\n"); | 205 | fprintf (stdout, "\n"); |
229 | GNUNET_GNSRECORD_query_from_public_key (&id_pub, | 206 | GNUNET_GNSRECORD_query_from_public_key (&id_pub, |
230 | TEST_RECORD_LABEL, | 207 | label, |
231 | &query); | 208 | &query); |
232 | fprintf (stdout, "Storage key (q):\n"); | 209 | fprintf (stdout, "Storage key (q):\n"); |
233 | print_bytes (&query, sizeof (query), 8); | 210 | print_bytes (&query, sizeof (query), 8); |
234 | fprintf (stdout, "\n"); | 211 | fprintf (stdout, "\n"); |
235 | GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_block_create (&id_priv, | 212 | GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_block_create (&id_priv, |
236 | expire, | 213 | expire, |
237 | TEST_RECORD_LABEL, | 214 | label, |
238 | rd, | 215 | rd, |
239 | TEST_RRCOUNT, | 216 | rd_count, |
240 | &rrblock)); | 217 | &rrblock)); |
241 | size_t bdata_size = ntohl(rrblock->size) - sizeof (struct GNUNET_GNSRECORD_Block); | 218 | size_t bdata_size = ntohl (rrblock->size) - sizeof (struct |
219 | GNUNET_GNSRECORD_Block); | ||
242 | 220 | ||
243 | bdata = (char*) &(&rrblock->ecdsa_block)[1]; | 221 | bdata = (char*) &(&rrblock->ecdsa_block)[1]; |
244 | fprintf (stdout, "BDATA:\n"); | 222 | fprintf (stdout, "BDATA:\n"); |
245 | print_bytes (bdata, bdata_size, 8); | 223 | print_bytes (bdata, bdata_size, 8); |
246 | fprintf (stdout, "\n"); | 224 | fprintf (stdout, "\n"); |
247 | fprintf (stdout, "RRBLOCK:\n"); | 225 | fprintf (stdout, "RRBLOCK:\n"); |
248 | print_bytes (rrblock, ntohl(rrblock->size), 8); | 226 | print_bytes (rrblock, ntohl (rrblock->size), 8); |
249 | fprintf (stdout, "\n"); | 227 | fprintf (stdout, "\n"); |
250 | GNUNET_free (rdata); | 228 | GNUNET_free (rdata); |
251 | } | 229 | } |
@@ -260,15 +238,9 @@ run_pkey (void) | |||
260 | * @param cfg configuration | 238 | * @param cfg configuration |
261 | */ | 239 | */ |
262 | static void | 240 | static void |
263 | run_edkey (void) | 241 | run_edkey (struct GNUNET_GNSRECORD_Data *rd, int rd_count, const char*label) |
264 | { | 242 | { |
265 | struct GNUNET_GNSRECORD_Data rd[2]; | ||
266 | struct GNUNET_TIME_Absolute expire; | 243 | struct GNUNET_TIME_Absolute expire; |
267 | struct GNUNET_TIME_Absolute now = GNUNET_TIME_absolute_get (); | ||
268 | struct GNUNET_TIME_Absolute exp1; | ||
269 | struct GNUNET_TIME_Absolute exp2; | ||
270 | struct GNUNET_TIME_Relative delta1; | ||
271 | struct GNUNET_TIME_Relative delta2; | ||
272 | struct GNUNET_GNSRECORD_Block *rrblock; | 244 | struct GNUNET_GNSRECORD_Block *rrblock; |
273 | char *bdata; | 245 | char *bdata; |
274 | struct GNUNET_IDENTITY_PrivateKey id_priv; | 246 | struct GNUNET_IDENTITY_PrivateKey id_priv; |
@@ -276,23 +248,13 @@ run_edkey (void) | |||
276 | struct GNUNET_IDENTITY_PrivateKey pkey_data_p; | 248 | struct GNUNET_IDENTITY_PrivateKey pkey_data_p; |
277 | struct GNUNET_IDENTITY_PublicKey pkey_data; | 249 | struct GNUNET_IDENTITY_PublicKey pkey_data; |
278 | struct GNUNET_HashCode query; | 250 | struct GNUNET_HashCode query; |
279 | void *data; | ||
280 | size_t data_size; | ||
281 | char *rdata; | 251 | char *rdata; |
282 | size_t rdata_size; | 252 | size_t rdata_size; |
283 | uint32_t rd_count_nbo; | 253 | |
284 | char ztld[128]; | 254 | char ztld[128]; |
285 | unsigned char nonce[crypto_secretbox_NONCEBYTES]; | 255 | unsigned char nonce[crypto_secretbox_NONCEBYTES]; |
286 | unsigned char skey[crypto_secretbox_KEYBYTES]; | 256 | unsigned char skey[crypto_secretbox_KEYBYTES]; |
287 | 257 | ||
288 | /* | ||
289 | * Make two different expiration times | ||
290 | */ | ||
291 | GNUNET_STRINGS_fancy_time_to_absolute ("%2048-01-23 10:51:34", | ||
292 | &exp1); | ||
293 | GNUNET_STRINGS_fancy_time_to_absolute ("3540-05-22 07:55:01", | ||
294 | &exp2); | ||
295 | |||
296 | id_priv.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); | 258 | id_priv.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
297 | GNUNET_CRYPTO_ecdsa_key_create (&id_priv.ecdsa_key); | 259 | GNUNET_CRYPTO_ecdsa_key_create (&id_priv.ecdsa_key); |
298 | GNUNET_IDENTITY_key_get_public (&id_priv, | 260 | GNUNET_IDENTITY_key_get_public (&id_priv, |
@@ -311,13 +273,14 @@ run_edkey (void) | |||
311 | GNUNET_CRYPTO_EddsaPrivateKey), 8); | 273 | GNUNET_CRYPTO_EddsaPrivateKey), 8); |
312 | fprintf (stdout, "\n"); | 274 | fprintf (stdout, "\n"); |
313 | fprintf (stdout, "Zone identifier (ztype|zkey):\n"); | 275 | fprintf (stdout, "Zone identifier (ztype|zkey):\n"); |
276 | GNUNET_assert (0 < GNUNET_IDENTITY_key_get_length (&id_pub)); | ||
314 | print_bytes (&id_pub, GNUNET_IDENTITY_key_get_length (&id_pub), 8); | 277 | print_bytes (&id_pub, GNUNET_IDENTITY_key_get_length (&id_pub), 8); |
315 | GNUNET_STRINGS_data_to_string (&id_pub, | 278 | GNUNET_STRINGS_data_to_string (&id_pub, |
316 | GNUNET_IDENTITY_key_get_length (&id_pub), | 279 | GNUNET_IDENTITY_key_get_length (&id_pub), |
317 | ztld, | 280 | ztld, |
318 | sizeof (ztld)); | 281 | sizeof (ztld)); |
319 | fprintf (stdout, "\n"); | 282 | fprintf (stdout, "\n"); |
320 | fprintf (stdout, "Encoded zone identifier (zkl = zTLD):\n"); | 283 | fprintf (stdout, "zTLD:\n"); |
321 | fprintf (stdout, "%s\n", ztld); | 284 | fprintf (stdout, "%s\n", ztld); |
322 | fprintf (stdout, "\n"); | 285 | fprintf (stdout, "\n"); |
323 | 286 | ||
@@ -326,40 +289,33 @@ run_edkey (void) | |||
326 | GNUNET_IDENTITY_key_get_public (&pkey_data_p, | 289 | GNUNET_IDENTITY_key_get_public (&pkey_data_p, |
327 | &pkey_data); | 290 | &pkey_data); |
328 | fprintf (stdout, | 291 | fprintf (stdout, |
329 | "Label: %s\nRRCOUNT: %d\n\n", TEST_RECORD_LABEL, TEST_RRCOUNT); | 292 | "Label: %s\nRRCOUNT: %d\n\n", label, rd_count); |
330 | memset (rd, 0, sizeof (struct GNUNET_GNSRECORD_Data) * 2); | ||
331 | GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_string_to_value ( | ||
332 | GNUNET_DNSPARSER_TYPE_A, TEST_RECORD_A, &data, &data_size)); | ||
333 | rd[0].data = data; | ||
334 | rd[0].data_size = data_size; | ||
335 | rd[0].expiration_time = exp1.abs_value_us; | ||
336 | rd[0].record_type = GNUNET_DNSPARSER_TYPE_A; | ||
337 | fprintf (stdout, "Record #0\n"); | ||
338 | print_record (&rd[0]); | ||
339 | 293 | ||
340 | rd[1].data = "My Nick"; | 294 | for (int i = 0; i < rd_count; i++) |
341 | rd[1].data_size = sizeof (struct GNUNET_IDENTITY_PublicKey); | 295 | { |
342 | rd[1].expiration_time = exp2.abs_value_us; | 296 | fprintf (stdout, "Record #%d\n", i); |
343 | rd[1].record_type = GNUNET_GNSRECORD_TYPE_NICK; | 297 | print_record (&rd[i]); |
344 | rd[1].flags = GNUNET_GNSRECORD_RF_PRIVATE; | 298 | } |
345 | fprintf (stdout, "Record #1\n"); | ||
346 | print_record (&rd[1]); | ||
347 | 299 | ||
348 | rdata_size = GNUNET_GNSRECORD_records_get_size (TEST_RRCOUNT, | 300 | rdata_size = GNUNET_GNSRECORD_records_get_size (rd_count, |
349 | rd); | 301 | rd); |
350 | expire = GNUNET_GNSRECORD_record_get_expiration_time (TEST_RRCOUNT, | 302 | expire = GNUNET_GNSRECORD_record_get_expiration_time (rd_count, |
351 | rd); | 303 | rd, |
352 | rdata = GNUNET_malloc (rdata_size); | 304 | GNUNET_TIME_UNIT_ZERO_ABS); |
353 | GNUNET_GNSRECORD_records_serialize (2, | 305 | GNUNET_assert (0 < rdata_size); |
306 | rdata = GNUNET_malloc ((size_t) rdata_size); | ||
307 | GNUNET_GNSRECORD_records_serialize (rd_count, | ||
354 | rd, | 308 | rd, |
355 | rdata_size, | 309 | (size_t) rdata_size, |
356 | rdata); | 310 | rdata); |
357 | fprintf (stdout, "RDATA:\n"); | 311 | fprintf (stdout, "RDATA:\n"); |
358 | print_bytes (rdata, rdata_size, 8); | 312 | print_bytes (rdata, |
313 | (size_t) rdata_size, | ||
314 | 8); | ||
359 | fprintf (stdout, "\n"); | 315 | fprintf (stdout, "\n"); |
360 | GNR_derive_block_xsalsa_key (nonce, | 316 | GNR_derive_block_xsalsa_key (nonce, |
361 | skey, | 317 | skey, |
362 | TEST_RECORD_LABEL, | 318 | label, |
363 | GNUNET_TIME_absolute_hton ( | 319 | GNUNET_TIME_absolute_hton ( |
364 | expire).abs_value_us__, | 320 | expire).abs_value_us__, |
365 | &id_pub.eddsa_key); | 321 | &id_pub.eddsa_key); |
@@ -370,7 +326,7 @@ run_edkey (void) | |||
370 | print_bytes (skey, sizeof (skey), 8); | 326 | print_bytes (skey, sizeof (skey), 8); |
371 | fprintf (stdout, "\n"); | 327 | fprintf (stdout, "\n"); |
372 | GNUNET_GNSRECORD_query_from_public_key (&id_pub, | 328 | GNUNET_GNSRECORD_query_from_public_key (&id_pub, |
373 | TEST_RECORD_LABEL, | 329 | label, |
374 | &query); | 330 | &query); |
375 | fprintf (stdout, "Storage key (q):\n"); | 331 | fprintf (stdout, "Storage key (q):\n"); |
376 | print_bytes (&query, sizeof (query), 8); | 332 | print_bytes (&query, sizeof (query), 8); |
@@ -378,18 +334,19 @@ run_edkey (void) | |||
378 | 334 | ||
379 | GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_block_create (&id_priv, | 335 | GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_block_create (&id_priv, |
380 | expire, | 336 | expire, |
381 | TEST_RECORD_LABEL, | 337 | label, |
382 | rd, | 338 | rd, |
383 | TEST_RRCOUNT, | 339 | rd_count, |
384 | &rrblock)); | 340 | &rrblock)); |
385 | size_t bdata_size = ntohl(rrblock->size) - sizeof (struct GNUNET_GNSRECORD_Block); | 341 | size_t bdata_size = ntohl (rrblock->size) - sizeof (struct |
342 | GNUNET_GNSRECORD_Block); | ||
386 | 343 | ||
387 | bdata = (char*) &(&rrblock->eddsa_block)[1]; | 344 | bdata = (char*) &(&rrblock->eddsa_block)[1]; |
388 | fprintf (stdout, "BDATA:\n"); | 345 | fprintf (stdout, "BDATA:\n"); |
389 | print_bytes (bdata, bdata_size, 8); | 346 | print_bytes (bdata, bdata_size, 8); |
390 | fprintf (stdout, "\n"); | 347 | fprintf (stdout, "\n"); |
391 | fprintf (stdout, "RRBLOCK:\n"); | 348 | fprintf (stdout, "RRBLOCK:\n"); |
392 | print_bytes (rrblock, ntohl(rrblock->size), 8); | 349 | print_bytes (rrblock, ntohl (rrblock->size), 8); |
393 | fprintf (stdout, "\n"); | 350 | fprintf (stdout, "\n"); |
394 | GNUNET_free (rdata); | 351 | GNUNET_free (rdata); |
395 | } | 352 | } |
@@ -409,8 +366,67 @@ run (void *cls, | |||
409 | const char *cfgfile, | 366 | const char *cfgfile, |
410 | const struct GNUNET_CONFIGURATION_Handle *cfg) | 367 | const struct GNUNET_CONFIGURATION_Handle *cfg) |
411 | { | 368 | { |
412 | run_pkey (); | 369 | struct GNUNET_GNSRECORD_Data rd_pkey; |
413 | run_edkey (); | 370 | struct GNUNET_GNSRECORD_Data rd[3]; |
371 | struct GNUNET_TIME_Absolute exp1; | ||
372 | struct GNUNET_TIME_Absolute exp2; | ||
373 | struct GNUNET_TIME_Relative exp3; | ||
374 | size_t pkey_data_size; | ||
375 | size_t ip_data_size; | ||
376 | char *pkey_data; | ||
377 | char *ip_data; | ||
378 | |||
379 | /* | ||
380 | * Make different expiration times | ||
381 | */ | ||
382 | GNUNET_STRINGS_fancy_time_to_absolute ("2048-01-23 10:51:34", | ||
383 | &exp1); | ||
384 | GNUNET_STRINGS_fancy_time_to_absolute ("3540-05-22 07:55:01", | ||
385 | &exp2); | ||
386 | GNUNET_STRINGS_fancy_time_to_relative ("100y", | ||
387 | &exp3); | ||
388 | |||
389 | |||
390 | memset (&rd_pkey, 0, sizeof (struct GNUNET_GNSRECORD_Data)); | ||
391 | GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_string_to_value ( | ||
392 | GNUNET_GNSRECORD_TYPE_PKEY, | ||
393 | "000G0011WESGZY9VRV9NNJ66W3GKNZFZF56BFD2BQF3MHMJST2G2GKDYGG", | ||
394 | (void**) &pkey_data, | ||
395 | &pkey_data_size)); | ||
396 | rd_pkey.data = pkey_data; | ||
397 | rd_pkey.data_size = pkey_data_size; | ||
398 | rd_pkey.expiration_time = exp1.abs_value_us; | ||
399 | rd_pkey.record_type = GNUNET_GNSRECORD_TYPE_PKEY; | ||
400 | rd_pkey.flags = GNUNET_GNSRECORD_RF_CRITICAL; | ||
401 | GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_string_to_value ( | ||
402 | GNUNET_DNSPARSER_TYPE_AAAA, | ||
403 | "::dead:beef", | ||
404 | (void**) &ip_data, | ||
405 | &ip_data_size)); | ||
406 | |||
407 | rd[0].data = ip_data; | ||
408 | rd[0].data_size = ip_data_size; | ||
409 | rd[0].expiration_time = exp1.abs_value_us; | ||
410 | rd[0].record_type = GNUNET_DNSPARSER_TYPE_AAAA; | ||
411 | rd[0].flags = GNUNET_GNSRECORD_RF_NONE; | ||
412 | |||
413 | rd[1].data = "\u611b\u79f0"; | ||
414 | rd[1].data_size = strlen (rd[1].data); | ||
415 | rd[1].expiration_time = exp2.abs_value_us; | ||
416 | rd[1].record_type = GNUNET_GNSRECORD_TYPE_NICK; | ||
417 | rd[1].flags = GNUNET_GNSRECORD_RF_PRIVATE; | ||
418 | |||
419 | rd[2].data = "Hello World"; | ||
420 | rd[2].data_size = strlen (rd[2].data); | ||
421 | rd[2].expiration_time = exp3.rel_value_us; | ||
422 | rd[2].record_type = GNUNET_DNSPARSER_TYPE_TXT; | ||
423 | rd[2].flags = GNUNET_GNSRECORD_RF_SUPPLEMENTAL | ||
424 | | GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION; | ||
425 | |||
426 | run_pkey (&rd_pkey, 1, "testdelegation"); | ||
427 | run_pkey (rd, 3, "namesystem"); | ||
428 | run_edkey (&rd_pkey, 1, "testdelegation"); | ||
429 | run_edkey (rd, 3, "namesystem"); | ||
414 | } | 430 | } |
415 | 431 | ||
416 | 432 | ||
diff --git a/src/gnsrecord/perf_gnsrecord_crypto.c b/src/gnsrecord/perf_gnsrecord_crypto.c index d9a3c20cf..6b5f84235 100644 --- a/src/gnsrecord/perf_gnsrecord_crypto.c +++ b/src/gnsrecord/perf_gnsrecord_crypto.c | |||
@@ -90,12 +90,12 @@ run (void *cls, | |||
90 | start_time = GNUNET_TIME_absolute_get (); | 90 | start_time = GNUNET_TIME_absolute_get (); |
91 | for (unsigned int i = 0; i < ROUNDS; i++) | 91 | for (unsigned int i = 0; i < ROUNDS; i++) |
92 | { | 92 | { |
93 | GNUNET_assert (NULL != (block = | 93 | GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_block_create2 (&privkey, |
94 | GNUNET_GNSRECORD_block_create2 (&privkey, | ||
95 | expire, | 94 | expire, |
96 | s_name, | 95 | s_name, |
97 | s_rd, | 96 | s_rd, |
98 | RECORDS))); | 97 | RECORDS, |
98 | &block)); | ||
99 | GNUNET_GNSRECORD_query_from_private_key (&privkey, | 99 | GNUNET_GNSRECORD_query_from_private_key (&privkey, |
100 | s_name, | 100 | s_name, |
101 | &query); | 101 | &query); |
diff --git a/src/gnsrecord/plugin_gnsrecord_dns.c b/src/gnsrecord/plugin_gnsrecord_dns.c index 123c59905..649133cd1 100644 --- a/src/gnsrecord/plugin_gnsrecord_dns.c +++ b/src/gnsrecord/plugin_gnsrecord_dns.c | |||
@@ -773,6 +773,12 @@ dns_number_to_typename (void *cls, uint32_t type) | |||
773 | } | 773 | } |
774 | 774 | ||
775 | 775 | ||
776 | static enum GNUNET_GenericReturnValue | ||
777 | dns_is_critical (void *cls, uint32_t type) | ||
778 | { | ||
779 | return GNUNET_NO; | ||
780 | } | ||
781 | |||
776 | /** | 782 | /** |
777 | * Entry point for the plugin. | 783 | * Entry point for the plugin. |
778 | * | 784 | * |
@@ -789,6 +795,7 @@ libgnunet_plugin_gnsrecord_dns_init (void *cls) | |||
789 | api->string_to_value = &dns_string_to_value; | 795 | api->string_to_value = &dns_string_to_value; |
790 | api->typename_to_number = &dns_typename_to_number; | 796 | api->typename_to_number = &dns_typename_to_number; |
791 | api->number_to_typename = &dns_number_to_typename; | 797 | api->number_to_typename = &dns_number_to_typename; |
798 | api->is_critical = &dns_is_critical; | ||
792 | return api; | 799 | return api; |
793 | } | 800 | } |
794 | 801 | ||
diff --git a/src/gnsrecord/test_gnsrecord_block_expiration.c b/src/gnsrecord/test_gnsrecord_block_expiration.c index b53d7d7e8..d14ce3914 100644 --- a/src/gnsrecord/test_gnsrecord_block_expiration.c +++ b/src/gnsrecord/test_gnsrecord_block_expiration.c | |||
@@ -72,7 +72,8 @@ run (void *cls, char *const *args, const char *cfgfile, | |||
72 | 72 | ||
73 | GNUNET_assert (expiration_abs.abs_value_us == | 73 | GNUNET_assert (expiration_abs.abs_value_us == |
74 | GNUNET_GNSRECORD_record_get_expiration_time (2, | 74 | GNUNET_GNSRECORD_record_get_expiration_time (2, |
75 | rd).abs_value_us); | 75 | rd, |
76 | GNUNET_TIME_UNIT_ZERO_ABS).abs_value_us); | ||
76 | 77 | ||
77 | rd[1].expiration_time = expiration_abs_shadow.abs_value_us; | 78 | rd[1].expiration_time = expiration_abs_shadow.abs_value_us; |
78 | rd[1].record_type = TEST_RECORD_TYPE; | 79 | rd[1].record_type = TEST_RECORD_TYPE; |
@@ -83,7 +84,8 @@ run (void *cls, char *const *args, const char *cfgfile, | |||
83 | 84 | ||
84 | GNUNET_assert (expiration_abs_shadow.abs_value_us == | 85 | GNUNET_assert (expiration_abs_shadow.abs_value_us == |
85 | GNUNET_GNSRECORD_record_get_expiration_time (2, | 86 | GNUNET_GNSRECORD_record_get_expiration_time (2, |
86 | rd).abs_value_us); | 87 | rd, |
88 | GNUNET_TIME_UNIT_ZERO_ABS).abs_value_us); | ||
87 | res = 0; | 89 | res = 0; |
88 | } | 90 | } |
89 | 91 | ||
diff --git a/src/gnsrecord/test_gnsrecord_testvectors.c b/src/gnsrecord/test_gnsrecord_testvectors.c index 153c56261..bb4922417 100644 --- a/src/gnsrecord/test_gnsrecord_testvectors.c +++ b/src/gnsrecord/test_gnsrecord_testvectors.c | |||
@@ -10,16 +10,16 @@ | |||
10 | 10 | ||
11 | 11 | ||
12 | static char *d = | 12 | static char *d = |
13 | "50d7b652a4efeadff37396909785e5952171a02178c8e7d450fa907925fafd98"; | 13 | "50d7b652a4efeadff37396909785e5952171a02178c8e7d450fa907925fafd98"; |
14 | 14 | ||
15 | 15 | ||
16 | static char *zid = | 16 | static char *zid = |
17 | "00010000677c477d2d93097c85b195c6f96d84ff61f5982c2c4fe02d5a11fedfb0c2901f"; | 17 | "00010000677c477d2d93097c85b195c6f96d84ff61f5982c2c4fe02d5a11fedfb0c2901f"; |
18 | 18 | ||
19 | #define RRCOUNT 2 | 19 | #define RRCOUNT 2 |
20 | #define LABEL "test" | 20 | #define LABEL "namesystem" |
21 | 21 | ||
22 | #define R0_EXPIRATION 14888744139323793 | 22 | #define R0_EXPIRATION |
23 | #define R0_DATA_SIZE 4 | 23 | #define R0_DATA_SIZE 4 |
24 | #define R0_TYPE 1 | 24 | #define R0_TYPE 1 |
25 | #define R0_FLAGS 0 | 25 | #define R0_FLAGS 0 |
@@ -31,12 +31,12 @@ static char *zid = | |||
31 | #define R1_TYPE 65536 | 31 | #define R1_TYPE 65536 |
32 | #define R1_FLAGS 2 | 32 | #define R1_FLAGS 2 |
33 | #define R1_DATA \ | 33 | #define R1_DATA \ |
34 | "000100000e601be42eb57fb4697610cf3a3b18347b65a33f025b5b174abefb30807bfecf" | 34 | "000100000e601be42eb57fb4697610cf3a3b18347b65a33f025b5b174abefb30807bfecf" |
35 | 35 | ||
36 | #define R1_RRBLOCK \ | 36 | #define R1_RRBLOCK \ |
37 | "000100008e16da87203b5159c5538e9b765742e968c54af9afbc0890dc80205ad14c84e107b0c115fc0089aa38b9c7ab9cbe1d77040d282a51a2ad493f61f3495f02d8170fe473a55ec6bdf9a509ab1701ffc37ea3bb4cac4a672520986df96e67cc1a73000000940000000f0034e53be193799100e4837eb5d04f92903de4b5234e8ccac5736c9793379a59c33375fc8951aca2eb7aad067bf9af60bf26758646a17f5e5c3b6215f94079545b1c4d4f1b2ebb22c2b4dad44126817b6f001530d476401dd67ac0148554e806353da9e4298079f3e1b16942c48d90c4360c61238c40d9d52911aea52cc0037ac7160bb3cf5b2f4a722fd96b" | 37 | "000100008e16da87203b5159c5538e9b765742e968c54af9afbc0890dc80205ad14c84e107b0c115fc0089aa38b9c7ab9cbe1d77040d282a51a2ad493f61f3495f02d8170fe473a55ec6bdf9a509ab1701ffc37ea3bb4cac4a672520986df96e67cc1a73000000940000000f0034e53be193799100e4837eb5d04f92903de4b5234e8ccac5736c9793379a59c33375fc8951aca2eb7aad067bf9af60bf26758646a17f5e5c3b6215f94079545b1c4d4f1b2ebb22c2b4dad44126817b6f001530d476401dd67ac0148554e806353da9e4298079f3e1b16942c48d90c4360c61238c40d9d52911aea52cc0037ac7160bb3cf5b2f4a722fd96b" |
38 | 38 | ||
39 | int parsehex(char *src, char *dst, size_t dstlen, int invert) | 39 | int parsehex (char *src, char *dst, size_t dstlen, int invert) |
40 | { | 40 | { |
41 | char *line = src; | 41 | char *line = src; |
42 | char *data = line; | 42 | char *data = line; |
@@ -44,7 +44,8 @@ int parsehex(char *src, char *dst, size_t dstlen, int invert) | |||
44 | int read_byte; | 44 | int read_byte; |
45 | int data_len = 0; | 45 | int data_len = 0; |
46 | 46 | ||
47 | while (sscanf(data, " %02x%n", &read_byte, &off) == 1) { | 47 | while (sscanf (data, " %02x%n", &read_byte, &off) == 1) |
48 | { | ||
48 | if (invert) | 49 | if (invert) |
49 | dst[dstlen - 1 - data_len++] = read_byte; | 50 | dst[dstlen - 1 - data_len++] = read_byte; |
50 | else | 51 | else |
@@ -62,8 +63,8 @@ res_checker (void *cls, | |||
62 | int r1_found = 0; | 63 | int r1_found = 0; |
63 | char r0_data[R0_DATA_SIZE]; | 64 | char r0_data[R0_DATA_SIZE]; |
64 | char r1_data[R1_DATA_SIZE]; | 65 | char r1_data[R1_DATA_SIZE]; |
65 | parsehex(R0_DATA, (char*)r0_data, 0, 0); | 66 | parsehex (R0_DATA, (char*) r0_data, 0, 0); |
66 | parsehex(R1_DATA, (char*)r1_data, 0, 0); | 67 | parsehex (R1_DATA, (char*) r1_data, 0, 0); |
67 | GNUNET_assert (rd_count == RRCOUNT); | 68 | GNUNET_assert (rd_count == RRCOUNT); |
68 | for (int i = 0; i < RRCOUNT; i++) | 69 | for (int i = 0; i < RRCOUNT; i++) |
69 | { | 70 | { |
@@ -104,7 +105,7 @@ res_checker (void *cls, | |||
104 | 105 | ||
105 | 106 | ||
106 | int | 107 | int |
107 | main() | 108 | main () |
108 | { | 109 | { |
109 | struct GNUNET_IDENTITY_PrivateKey priv; | 110 | struct GNUNET_IDENTITY_PrivateKey priv; |
110 | struct GNUNET_IDENTITY_PublicKey pub; | 111 | struct GNUNET_IDENTITY_PublicKey pub; |
@@ -112,13 +113,15 @@ main() | |||
112 | struct GNUNET_GNSRECORD_Block *rrblock; | 113 | struct GNUNET_GNSRECORD_Block *rrblock; |
113 | char *bdata; | 114 | char *bdata; |
114 | 115 | ||
115 | parsehex(d,(char*)&priv.ecdsa_key, sizeof (priv.ecdsa_key), 1); | 116 | parsehex (d,(char*) &priv.ecdsa_key, sizeof (priv.ecdsa_key), 1); |
116 | priv.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); | 117 | priv.type = htonl (GNUNET_GNSRECORD_TYPE_PKEY); |
117 | parsehex(zid,(char*)&pub_parsed, 0, 0); | 118 | parsehex (zid,(char*) &pub_parsed, 0, 0); |
118 | GNUNET_IDENTITY_key_get_public(&priv, &pub); | 119 | GNUNET_IDENTITY_key_get_public (&priv, &pub); |
119 | GNUNET_assert (0 == memcmp (&pub, &pub_parsed, sizeof (pub))); | 120 | GNUNET_assert (0 == memcmp (&pub, &pub_parsed, sizeof (pub))); |
120 | rrblock = GNUNET_malloc (strlen (R1_RRBLOCK) / 2); | 121 | rrblock = GNUNET_malloc (strlen (R1_RRBLOCK) / 2); |
121 | parsehex(R1_RRBLOCK, (char*)rrblock, 0, 0); | 122 | parsehex (R1_RRBLOCK, (char*) rrblock, 0, 0); |
123 | GNUNET_assert (GNUNET_YES | ||
124 | == GNUNET_GNSRECORD_is_critical (GNUNET_GNSRECORD_TYPE_PKEY)); | ||
122 | GNUNET_GNSRECORD_block_decrypt (rrblock, | 125 | GNUNET_GNSRECORD_block_decrypt (rrblock, |
123 | &pub_parsed, | 126 | &pub_parsed, |
124 | LABEL, | 127 | LABEL, |
diff --git a/src/hello/.gitignore b/src/hello/.gitignore index bb49ceb20..d175d148e 100644 --- a/src/hello/.gitignore +++ b/src/hello/.gitignore | |||
@@ -1,3 +1,5 @@ | |||
1 | gnunet-hello | 1 | gnunet-hello |
2 | test_friend_hello | 2 | test_friend_hello |
3 | test_hello | 3 | test_hello |
4 | test_hello-uri | ||
5 | test_hello-ng | ||
diff --git a/src/hello/Makefile.am b/src/hello/Makefile.am index 6a250e42f..c04b85106 100644 --- a/src/hello/Makefile.am +++ b/src/hello/Makefile.am | |||
@@ -11,7 +11,8 @@ lib_LTLIBRARIES = libgnunethello.la | |||
11 | libgnunethello_la_SOURCES = \ | 11 | libgnunethello_la_SOURCES = \ |
12 | hello.c \ | 12 | hello.c \ |
13 | address.c \ | 13 | address.c \ |
14 | hello-ng.c | 14 | hello-ng.c \ |
15 | hello-uri.c | ||
15 | libgnunethello_la_LIBADD = \ | 16 | libgnunethello_la_LIBADD = \ |
16 | $(top_builddir)/src/util/libgnunetutil.la $(XLIB) \ | 17 | $(top_builddir)/src/util/libgnunetutil.la $(XLIB) \ |
17 | $(LTLIBINTL) | 18 | $(LTLIBINTL) |
@@ -24,6 +25,7 @@ noinst_PROGRAMS = \ | |||
24 | 25 | ||
25 | check_PROGRAMS = \ | 26 | check_PROGRAMS = \ |
26 | test_hello \ | 27 | test_hello \ |
28 | test_hello-uri \ | ||
27 | test_friend_hello \ | 29 | test_friend_hello \ |
28 | test_hello-ng | 30 | test_hello-ng |
29 | 31 | ||
@@ -36,25 +38,32 @@ test_hello_SOURCES = \ | |||
36 | test_hello.c | 38 | test_hello.c |
37 | test_hello_LDADD = \ | 39 | test_hello_LDADD = \ |
38 | libgnunethello.la \ | 40 | libgnunethello.la \ |
39 | $(top_builddir)/src/util/libgnunetutil.la | 41 | $(top_builddir)/src/util/libgnunetutil.la |
40 | 42 | ||
41 | test_hello_ng_SOURCES = \ | 43 | test_hello_ng_SOURCES = \ |
42 | test_hello-ng.c | 44 | test_hello-ng.c |
43 | test_hello_ng_LDADD = \ | 45 | test_hello_ng_LDADD = \ |
44 | libgnunethello.la \ | 46 | libgnunethello.la \ |
45 | $(top_builddir)/src/util/libgnunetutil.la | 47 | $(top_builddir)/src/util/libgnunetutil.la |
48 | |||
49 | test_hello_uri_SOURCES = \ | ||
50 | test_hello-uri.c | ||
51 | test_hello_uri_LDADD = \ | ||
52 | libgnunethello.la \ | ||
53 | $(top_builddir)/src/util/libgnunetutil.la \ | ||
54 | -lgcrypt | ||
46 | 55 | ||
47 | 56 | ||
48 | test_friend_hello_SOURCES = \ | 57 | test_friend_hello_SOURCES = \ |
49 | test_friend_hello.c | 58 | test_friend_hello.c |
50 | test_friend_hello_LDADD = \ | 59 | test_friend_hello_LDADD = \ |
51 | libgnunethello.la \ | 60 | libgnunethello.la \ |
52 | $(top_builddir)/src/util/libgnunetutil.la | 61 | $(top_builddir)/src/util/libgnunetutil.la |
53 | 62 | ||
54 | gnunet_hello_SOURCES = \ | 63 | gnunet_hello_SOURCES = \ |
55 | gnunet-hello.c | 64 | gnunet-hello.c |
56 | gnunet_hello_LDADD = \ | 65 | gnunet_hello_LDADD = \ |
57 | libgnunethello.la \ | 66 | libgnunethello.la \ |
58 | $(top_builddir)/src/util/libgnunetutil.la | 67 | $(top_builddir)/src/util/libgnunetutil.la |
59 | gnunet_hello_LDFLAGS = \ | 68 | gnunet_hello_LDFLAGS = \ |
60 | $(GN_LIBINTL) | 69 | $(GN_LIBINTL) |
diff --git a/src/hello/hello-uri.c b/src/hello/hello-uri.c new file mode 100644 index 000000000..bacaf697e --- /dev/null +++ b/src/hello/hello-uri.c | |||
@@ -0,0 +1,891 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2022 GNUnet e.V. | ||
4 | |||
5 | GNUnet is free software: you can redistribute it and/or modify it | ||
6 | under the terms of the GNU Affero General Public License as published | ||
7 | by the Free Software Foundation, either version 3 of the License, | ||
8 | or (at your option) any later version. | ||
9 | |||
10 | GNUnet is distributed in the hope that it will be useful, but | ||
11 | WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
13 | Affero General Public License for more details. | ||
14 | |||
15 | You should have received a copy of the GNU Affero General Public License | ||
16 | along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
17 | |||
18 | SPDX-License-Identifier: AGPL3.0-or-later | ||
19 | */ | ||
20 | |||
21 | /** | ||
22 | * @file hello/hello-uri.c | ||
23 | * @brief helper library for handling URI-based HELLOs | ||
24 | * @author Christian Grothoff | ||
25 | * | ||
26 | * Note: | ||
27 | * - Current API does not support deserializing HELLO of | ||
28 | * another peer and then serializing it into another | ||
29 | * format (we always require the private key). | ||
30 | * Not sure if we need this, but if we do, we need | ||
31 | * to extend the builder and the API. | ||
32 | * - Current API does not allow overriding the default | ||
33 | * HELLO expiration time. We may want to add a function | ||
34 | * that does this to create bootstrap HELLOs shipped with | ||
35 | * the TGZ. | ||
36 | */ | ||
37 | #include "platform.h" | ||
38 | #include "gnunet_signatures.h" | ||
39 | #include "gnunet_hello_uri_lib.h" | ||
40 | #include "gnunet_protocols.h" | ||
41 | #include "gnunet_util_lib.h" | ||
42 | |||
43 | |||
44 | GNUNET_NETWORK_STRUCT_BEGIN | ||
45 | |||
46 | /** | ||
47 | * Message signed as part of a HELLO block/URL. | ||
48 | */ | ||
49 | struct HelloSignaturePurpose | ||
50 | { | ||
51 | /** | ||
52 | * Purpose must be #GNUNET_SIGNATURE_PURPOSE_HELLO | ||
53 | */ | ||
54 | struct GNUNET_CRYPTO_EccSignaturePurpose purpose; | ||
55 | |||
56 | /** | ||
57 | * When does the signature expire? | ||
58 | */ | ||
59 | struct GNUNET_TIME_AbsoluteNBO expiration_time; | ||
60 | |||
61 | /** | ||
62 | * Hash over all addresses. | ||
63 | */ | ||
64 | struct GNUNET_HashCode h_addrs; | ||
65 | |||
66 | }; | ||
67 | |||
68 | /** | ||
69 | * Message used when gossiping HELLOs between peers. | ||
70 | */ | ||
71 | struct HelloUriMessage | ||
72 | { | ||
73 | /** | ||
74 | * Type must be #GNUNET_MESSAGE_TYPE_HELLO_URI | ||
75 | */ | ||
76 | struct GNUNET_MessageHeader header; | ||
77 | |||
78 | /** | ||
79 | * Reserved. 0. | ||
80 | */ | ||
81 | uint16_t reserved GNUNET_PACKED; | ||
82 | |||
83 | /** | ||
84 | * Number of URLs encoded after the end of the struct, in NBO. | ||
85 | */ | ||
86 | uint16_t url_counter GNUNET_PACKED; | ||
87 | |||
88 | /* followed by a 'block' */ | ||
89 | }; | ||
90 | |||
91 | |||
92 | /** | ||
93 | * Start of a 'block'. | ||
94 | */ | ||
95 | struct BlockHeader | ||
96 | { | ||
97 | /** | ||
98 | * Public key of the peer. | ||
99 | */ | ||
100 | struct GNUNET_PeerIdentity pid; | ||
101 | |||
102 | /** | ||
103 | * Signature over the block, of purpose #GNUNET_SIGNATURE_PURPOSE_HELLO. | ||
104 | */ | ||
105 | struct GNUNET_CRYPTO_EddsaSignature sig; | ||
106 | |||
107 | /** | ||
108 | * When does the HELLO expire? | ||
109 | */ | ||
110 | struct GNUNET_TIME_AbsoluteNBO expiration_time; | ||
111 | |||
112 | }; | ||
113 | |||
114 | |||
115 | /** | ||
116 | * Message used when a DHT provides its HELLO to direct | ||
117 | * neighbours. | ||
118 | */ | ||
119 | struct DhtHelloMessage | ||
120 | { | ||
121 | /** | ||
122 | * Type must be #GNUNET_MESSAGE_TYPE_DHT_P2P_HELLO | ||
123 | */ | ||
124 | struct GNUNET_MessageHeader header; | ||
125 | |||
126 | /** | ||
127 | * Reserved. 0. | ||
128 | */ | ||
129 | uint16_t reserved GNUNET_PACKED; | ||
130 | |||
131 | /** | ||
132 | * Number of URLs encoded after the end of the struct, in NBO. | ||
133 | */ | ||
134 | uint16_t url_counter GNUNET_PACKED; | ||
135 | |||
136 | /** | ||
137 | * Signature over the block, of purpose #GNUNET_SIGNATURE_PURPOSE_HELLO. | ||
138 | */ | ||
139 | struct GNUNET_CRYPTO_EddsaSignature sig; | ||
140 | |||
141 | /** | ||
142 | * When does the HELLO expire? | ||
143 | */ | ||
144 | struct GNUNET_TIME_AbsoluteNBO expiration_time; | ||
145 | |||
146 | /* followed by the serialized addresses of the 'block' */ | ||
147 | }; | ||
148 | |||
149 | |||
150 | GNUNET_NETWORK_STRUCT_END | ||
151 | |||
152 | |||
153 | /** | ||
154 | * Address of a peer. | ||
155 | */ | ||
156 | struct Address | ||
157 | { | ||
158 | /** | ||
159 | * Kept in a DLL. | ||
160 | */ | ||
161 | struct Address *next; | ||
162 | |||
163 | /** | ||
164 | * Kept in a DLL. | ||
165 | */ | ||
166 | struct Address *prev; | ||
167 | |||
168 | /** | ||
169 | * Actual URI, allocated at the end of this struct. | ||
170 | */ | ||
171 | const char *uri; | ||
172 | |||
173 | /** | ||
174 | * Length of @a uri including 0-terminator. | ||
175 | */ | ||
176 | size_t uri_len; | ||
177 | }; | ||
178 | |||
179 | |||
180 | /** | ||
181 | * Context for building (or parsing) HELLO URIs. | ||
182 | */ | ||
183 | struct GNUNET_HELLO_Builder | ||
184 | { | ||
185 | /** | ||
186 | * Public key of the peer. | ||
187 | */ | ||
188 | struct GNUNET_PeerIdentity pid; | ||
189 | |||
190 | /** | ||
191 | * Head of the addresses DLL. | ||
192 | */ | ||
193 | struct Address *a_head; | ||
194 | |||
195 | /** | ||
196 | * Tail of the addresses DLL. | ||
197 | */ | ||
198 | struct Address *a_tail; | ||
199 | |||
200 | /** | ||
201 | * Length of the @a a_head DLL. | ||
202 | */ | ||
203 | unsigned int a_length; | ||
204 | |||
205 | }; | ||
206 | |||
207 | |||
208 | /** | ||
209 | * Compute @a hash over addresses in @a builder. | ||
210 | * | ||
211 | * @param builder the builder to hash addresses of | ||
212 | * @param[out] hash where to write the hash | ||
213 | */ | ||
214 | static void | ||
215 | hash_addresses (const struct GNUNET_HELLO_Builder *builder, | ||
216 | struct GNUNET_HashCode *hash) | ||
217 | { | ||
218 | struct GNUNET_HashContext *hc; | ||
219 | |||
220 | hc = GNUNET_CRYPTO_hash_context_start (); | ||
221 | for (struct Address *a = builder->a_head; | ||
222 | NULL != a; | ||
223 | a = a->next) | ||
224 | { | ||
225 | GNUNET_CRYPTO_hash_context_read (hc, | ||
226 | a->uri, | ||
227 | a->uri_len); | ||
228 | } | ||
229 | GNUNET_CRYPTO_hash_context_finish (hc, | ||
230 | hash); | ||
231 | |||
232 | } | ||
233 | |||
234 | |||
235 | /** | ||
236 | * Create HELLO signature. | ||
237 | * | ||
238 | * @param builder the builder to use | ||
239 | * @param et expiration time to sign | ||
240 | * @param priv key to sign with | ||
241 | * @param[out] sig where to write the signature | ||
242 | */ | ||
243 | static void | ||
244 | sign_hello (const struct GNUNET_HELLO_Builder *builder, | ||
245 | struct GNUNET_TIME_Timestamp et, | ||
246 | const struct GNUNET_CRYPTO_EddsaPrivateKey *priv, | ||
247 | struct GNUNET_CRYPTO_EddsaSignature *sig) | ||
248 | { | ||
249 | struct HelloSignaturePurpose hsp = { | ||
250 | .purpose.size = htonl (sizeof (hsp)), | ||
251 | .purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_HELLO), | ||
252 | .expiration_time = GNUNET_TIME_absolute_hton (et.abs_time) | ||
253 | }; | ||
254 | |||
255 | hash_addresses (builder, | ||
256 | &hsp.h_addrs); | ||
257 | GNUNET_CRYPTO_eddsa_sign (priv, | ||
258 | &hsp, | ||
259 | sig); | ||
260 | } | ||
261 | |||
262 | |||
263 | /** | ||
264 | * Verify HELLO signature. | ||
265 | * | ||
266 | * @param builder the builder to use | ||
267 | * @param et expiration time to verify | ||
268 | * @param sig signature to verify | ||
269 | * @return #GNUNET_OK if everything is ok, #GNUNET_NO if the | ||
270 | * HELLO expired, #GNUNET_SYSERR if the signature is wrong | ||
271 | */ | ||
272 | static enum GNUNET_GenericReturnValue | ||
273 | verify_hello (const struct GNUNET_HELLO_Builder *builder, | ||
274 | struct GNUNET_TIME_Absolute et, | ||
275 | const struct GNUNET_CRYPTO_EddsaSignature *sig) | ||
276 | { | ||
277 | struct HelloSignaturePurpose hsp = { | ||
278 | .purpose.size = htonl (sizeof (hsp)), | ||
279 | .purpose.purpose = htonl (GNUNET_SIGNATURE_PURPOSE_HELLO), | ||
280 | .expiration_time = GNUNET_TIME_absolute_hton (et) | ||
281 | }; | ||
282 | |||
283 | hash_addresses (builder, | ||
284 | &hsp.h_addrs); | ||
285 | if (GNUNET_OK != | ||
286 | GNUNET_CRYPTO_eddsa_verify (GNUNET_SIGNATURE_PURPOSE_HELLO, | ||
287 | &hsp, | ||
288 | sig, | ||
289 | &builder->pid.public_key)) | ||
290 | { | ||
291 | GNUNET_break_op (0); | ||
292 | return GNUNET_SYSERR; | ||
293 | } | ||
294 | if (GNUNET_TIME_absolute_is_past (et)) | ||
295 | return GNUNET_NO; | ||
296 | return GNUNET_OK; | ||
297 | } | ||
298 | |||
299 | |||
300 | struct GNUNET_HELLO_Builder * | ||
301 | GNUNET_HELLO_builder_new (const struct GNUNET_PeerIdentity *pid) | ||
302 | { | ||
303 | struct GNUNET_HELLO_Builder *builder; | ||
304 | |||
305 | builder = GNUNET_new (struct GNUNET_HELLO_Builder); | ||
306 | builder->pid = *pid; | ||
307 | return builder; | ||
308 | } | ||
309 | |||
310 | |||
311 | void | ||
312 | GNUNET_HELLO_builder_free (struct GNUNET_HELLO_Builder *builder) | ||
313 | { | ||
314 | struct Address *a; | ||
315 | |||
316 | while (NULL != (a = builder->a_head)) | ||
317 | { | ||
318 | GNUNET_CONTAINER_DLL_remove (builder->a_head, | ||
319 | builder->a_tail, | ||
320 | a); | ||
321 | builder->a_length--; | ||
322 | GNUNET_free (a); | ||
323 | } | ||
324 | GNUNET_assert (0 == builder->a_length); | ||
325 | GNUNET_free (builder); | ||
326 | } | ||
327 | |||
328 | |||
329 | struct GNUNET_HELLO_Builder * | ||
330 | GNUNET_HELLO_builder_from_msg (const struct GNUNET_MessageHeader *msg) | ||
331 | { | ||
332 | const struct HelloUriMessage *h; | ||
333 | uint16_t size = ntohs (msg->size); | ||
334 | |||
335 | if (GNUNET_MESSAGE_TYPE_HELLO_URI != ntohs (msg->type)) | ||
336 | { | ||
337 | GNUNET_break (0); | ||
338 | return NULL; | ||
339 | } | ||
340 | if (sizeof (struct HelloUriMessage) > size) | ||
341 | { | ||
342 | GNUNET_break_op (0); | ||
343 | return NULL; | ||
344 | } | ||
345 | h = (const struct HelloUriMessage *) msg; | ||
346 | size -= sizeof (*h); | ||
347 | return GNUNET_HELLO_builder_from_block (&h[1], | ||
348 | size); | ||
349 | } | ||
350 | |||
351 | |||
352 | struct GNUNET_HELLO_Builder * | ||
353 | GNUNET_HELLO_builder_from_block (const void *block, | ||
354 | size_t block_size) | ||
355 | { | ||
356 | const struct BlockHeader *bh = block; | ||
357 | struct GNUNET_HELLO_Builder *b; | ||
358 | |||
359 | if (block_size < sizeof (*bh)) | ||
360 | { | ||
361 | GNUNET_break_op (0); | ||
362 | return NULL; | ||
363 | } | ||
364 | b = GNUNET_HELLO_builder_new (&bh->pid); | ||
365 | block += sizeof (*bh); | ||
366 | block_size -= sizeof (*bh); | ||
367 | while (block_size > 0) | ||
368 | { | ||
369 | const void *end = memchr (block, | ||
370 | '\0', | ||
371 | block_size); | ||
372 | |||
373 | if (NULL == end) | ||
374 | { | ||
375 | GNUNET_break_op (0); | ||
376 | GNUNET_HELLO_builder_free (b); | ||
377 | return NULL; | ||
378 | } | ||
379 | if (GNUNET_OK != | ||
380 | GNUNET_HELLO_builder_add_address (b, | ||
381 | block)) | ||
382 | { | ||
383 | GNUNET_break_op (0); | ||
384 | GNUNET_HELLO_builder_free (b); | ||
385 | return NULL; | ||
386 | } | ||
387 | end++; | ||
388 | block_size -= (end - block); | ||
389 | block = end; | ||
390 | } | ||
391 | { | ||
392 | enum GNUNET_GenericReturnValue ret; | ||
393 | |||
394 | ret = verify_hello (b, | ||
395 | GNUNET_TIME_absolute_ntoh (bh->expiration_time), | ||
396 | &bh->sig); | ||
397 | GNUNET_break (GNUNET_SYSERR != ret); | ||
398 | if (GNUNET_OK != ret) | ||
399 | { | ||
400 | GNUNET_HELLO_builder_free (b); | ||
401 | return NULL; | ||
402 | } | ||
403 | } | ||
404 | return b; | ||
405 | } | ||
406 | |||
407 | |||
408 | struct GNUNET_HELLO_Builder * | ||
409 | GNUNET_HELLO_builder_from_url (const char *url) | ||
410 | { | ||
411 | const char *q; | ||
412 | const char *s1; | ||
413 | const char *s2; | ||
414 | struct GNUNET_PeerIdentity pid; | ||
415 | struct GNUNET_CRYPTO_EddsaSignature sig; | ||
416 | struct GNUNET_TIME_Absolute et; | ||
417 | size_t len; | ||
418 | struct GNUNET_HELLO_Builder *b; | ||
419 | |||
420 | if (0 != strncasecmp (url, | ||
421 | "gnunet://hello/", | ||
422 | strlen ("gnunet://hello/"))) | ||
423 | return NULL; | ||
424 | url += strlen ("gnunet://hello/"); | ||
425 | s1 = strchr (url, '/'); | ||
426 | if (NULL == s1) | ||
427 | { | ||
428 | GNUNET_break_op (0); | ||
429 | return NULL; | ||
430 | } | ||
431 | s2 = strchr (s1 + 1, '/'); | ||
432 | if (NULL == s1) | ||
433 | { | ||
434 | GNUNET_break_op (0); | ||
435 | return NULL; | ||
436 | } | ||
437 | q = strchr (url, '?'); | ||
438 | if (NULL == q) | ||
439 | q = url + strlen (url); | ||
440 | if (GNUNET_OK != | ||
441 | GNUNET_STRINGS_string_to_data (url, | ||
442 | s1 - url, | ||
443 | &pid, | ||
444 | sizeof(pid))) | ||
445 | { | ||
446 | GNUNET_break_op (0); | ||
447 | return NULL; | ||
448 | } | ||
449 | if (GNUNET_OK != | ||
450 | GNUNET_STRINGS_string_to_data (s1 + 1, | ||
451 | s2 - (s1 + 1), | ||
452 | &sig, | ||
453 | sizeof(sig))) | ||
454 | { | ||
455 | GNUNET_break_op (0); | ||
456 | return NULL; | ||
457 | } | ||
458 | { | ||
459 | unsigned long long sec; | ||
460 | char dummy = '?'; | ||
461 | |||
462 | if ( (0 == sscanf (s2 + 1, | ||
463 | "%llu%c", | ||
464 | &sec, | ||
465 | &dummy)) || | ||
466 | ('?' != dummy) ) | ||
467 | { | ||
468 | GNUNET_break_op (0); | ||
469 | return NULL; | ||
470 | } | ||
471 | et = GNUNET_TIME_absolute_from_s (sec); | ||
472 | } | ||
473 | |||
474 | b = GNUNET_HELLO_builder_new (&pid); | ||
475 | len = strlen (q); | ||
476 | while (len > 0) | ||
477 | { | ||
478 | const char *eq; | ||
479 | const char *amp; | ||
480 | char *addr = NULL; | ||
481 | char *uri; | ||
482 | |||
483 | /* skip ?/& separator */ | ||
484 | len--; | ||
485 | q++; | ||
486 | eq = strchr (q, '='); | ||
487 | if ( (eq == q) || | ||
488 | (NULL == eq) ) | ||
489 | { | ||
490 | GNUNET_break_op (0); | ||
491 | GNUNET_HELLO_builder_free (b); | ||
492 | return NULL; | ||
493 | } | ||
494 | amp = strchr (eq, '&'); | ||
495 | if (NULL == amp) | ||
496 | amp = &q[len]; | ||
497 | GNUNET_STRINGS_urldecode (eq + 1, | ||
498 | amp - (eq + 1), | ||
499 | &addr); | ||
500 | if ( (NULL == addr) || | ||
501 | (0 == strlen (addr)) ) | ||
502 | { | ||
503 | GNUNET_free (addr); | ||
504 | GNUNET_break_op (0); | ||
505 | GNUNET_HELLO_builder_free (b); | ||
506 | return NULL; | ||
507 | } | ||
508 | GNUNET_asprintf (&uri, | ||
509 | "%.*s://%s", | ||
510 | (int) (eq - q), | ||
511 | q, | ||
512 | addr); | ||
513 | GNUNET_free (addr); | ||
514 | if (GNUNET_OK != | ||
515 | GNUNET_HELLO_builder_add_address (b, | ||
516 | uri)) | ||
517 | { | ||
518 | GNUNET_break_op (0); | ||
519 | GNUNET_free (uri); | ||
520 | GNUNET_HELLO_builder_free (b); | ||
521 | return NULL; | ||
522 | } | ||
523 | GNUNET_free (uri); | ||
524 | /* move to next URL */ | ||
525 | len -= (amp - q); | ||
526 | q = amp; | ||
527 | } | ||
528 | |||
529 | { | ||
530 | enum GNUNET_GenericReturnValue ret; | ||
531 | |||
532 | ret = verify_hello (b, | ||
533 | et, | ||
534 | &sig); | ||
535 | GNUNET_break (GNUNET_SYSERR != ret); | ||
536 | if (GNUNET_OK != ret) | ||
537 | { | ||
538 | GNUNET_HELLO_builder_free (b); | ||
539 | return NULL; | ||
540 | } | ||
541 | } | ||
542 | return b; | ||
543 | } | ||
544 | |||
545 | |||
546 | struct GNUNET_MQ_Envelope * | ||
547 | GNUNET_HELLO_builder_to_env (const struct GNUNET_HELLO_Builder *builder, | ||
548 | const struct GNUNET_CRYPTO_EddsaPrivateKey *priv) | ||
549 | { | ||
550 | struct GNUNET_MQ_Envelope *env; | ||
551 | struct HelloUriMessage *msg; | ||
552 | size_t blen; | ||
553 | |||
554 | if (builder->a_length > UINT16_MAX) | ||
555 | { | ||
556 | GNUNET_break (0); | ||
557 | return NULL; | ||
558 | } | ||
559 | blen = 0; | ||
560 | GNUNET_assert (GNUNET_NO == | ||
561 | GNUNET_HELLO_builder_to_block (builder, | ||
562 | priv, | ||
563 | NULL, | ||
564 | &blen)); | ||
565 | env = GNUNET_MQ_msg_extra (msg, | ||
566 | blen, | ||
567 | GNUNET_MESSAGE_TYPE_HELLO_URI); | ||
568 | msg->url_counter = htonl ((uint16_t) builder->a_length); | ||
569 | GNUNET_assert (GNUNET_OK == | ||
570 | GNUNET_HELLO_builder_to_block (builder, | ||
571 | priv, | ||
572 | &msg[1], | ||
573 | &blen)); | ||
574 | return env; | ||
575 | } | ||
576 | |||
577 | |||
578 | struct GNUNET_MessageHeader * | ||
579 | GNUNET_HELLO_builder_to_dht_hello_msg ( | ||
580 | const struct GNUNET_HELLO_Builder *builder, | ||
581 | const struct GNUNET_CRYPTO_EddsaPrivateKey *priv) | ||
582 | { | ||
583 | struct DhtHelloMessage *msg; | ||
584 | size_t blen; | ||
585 | |||
586 | if (builder->a_length > UINT16_MAX) | ||
587 | { | ||
588 | GNUNET_break (0); | ||
589 | return NULL; | ||
590 | } | ||
591 | blen = 0; | ||
592 | GNUNET_assert (GNUNET_NO == | ||
593 | GNUNET_HELLO_builder_to_block (builder, | ||
594 | priv, | ||
595 | NULL, | ||
596 | &blen)); | ||
597 | GNUNET_assert (blen < UINT16_MAX); | ||
598 | GNUNET_assert (blen >= sizeof (struct BlockHeader)); | ||
599 | { | ||
600 | char buf[blen] GNUNET_ALIGN; | ||
601 | const struct BlockHeader *block = (const struct BlockHeader *) buf; | ||
602 | |||
603 | GNUNET_assert (GNUNET_OK == | ||
604 | GNUNET_HELLO_builder_to_block (builder, | ||
605 | priv, | ||
606 | buf, | ||
607 | &blen)); | ||
608 | msg = GNUNET_malloc (sizeof (*msg) | ||
609 | + blen | ||
610 | - sizeof (*block)); | ||
611 | msg->header.type = htons (GNUNET_MESSAGE_TYPE_DHT_P2P_HELLO); | ||
612 | msg->header.size = htons (sizeof (*msg) | ||
613 | + blen | ||
614 | - sizeof (*block)); | ||
615 | memcpy (&msg[1], | ||
616 | &block[1], | ||
617 | blen - sizeof (*block)); | ||
618 | msg->sig = block->sig; | ||
619 | msg->expiration_time = block->expiration_time; | ||
620 | } | ||
621 | msg->url_counter = htonl ((uint16_t) builder->a_length); | ||
622 | return &msg->header; | ||
623 | } | ||
624 | |||
625 | |||
626 | char * | ||
627 | GNUNET_HELLO_builder_to_url (const struct GNUNET_HELLO_Builder *builder, | ||
628 | const struct GNUNET_CRYPTO_EddsaPrivateKey *priv) | ||
629 | { | ||
630 | struct GNUNET_CRYPTO_EddsaSignature sig; | ||
631 | struct GNUNET_TIME_Timestamp et; | ||
632 | char *result; | ||
633 | char *pids; | ||
634 | char *sigs; | ||
635 | const char *sep = "?"; | ||
636 | |||
637 | et = GNUNET_TIME_relative_to_timestamp (GNUNET_HELLO_ADDRESS_EXPIRATION); | ||
638 | sign_hello (builder, | ||
639 | et, | ||
640 | priv, | ||
641 | &sig); | ||
642 | pids = GNUNET_STRINGS_data_to_string_alloc (&builder->pid, | ||
643 | sizeof (builder->pid)); | ||
644 | sigs = GNUNET_STRINGS_data_to_string_alloc (&sig, | ||
645 | sizeof (sig)); | ||
646 | GNUNET_asprintf (&result, | ||
647 | "gnunet://hello/%s/%s/%llu", | ||
648 | pids, | ||
649 | sigs, | ||
650 | (unsigned long long) GNUNET_TIME_timestamp_to_s (et)); | ||
651 | GNUNET_free (sigs); | ||
652 | GNUNET_free (pids); | ||
653 | for (struct Address *a = builder->a_head; | ||
654 | NULL != a; | ||
655 | a = a->next) | ||
656 | { | ||
657 | char *ue; | ||
658 | char *tmp; | ||
659 | int pfx_len; | ||
660 | const char *eou; | ||
661 | |||
662 | eou = strstr (a->uri, | ||
663 | "://"); | ||
664 | if (NULL == eou) | ||
665 | { | ||
666 | GNUNET_break (0); | ||
667 | GNUNET_free (result); | ||
668 | return NULL; | ||
669 | } | ||
670 | pfx_len = eou - a->uri; | ||
671 | eou += 3; | ||
672 | GNUNET_STRINGS_urlencode (eou, | ||
673 | a->uri_len - 4 - pfx_len, | ||
674 | &ue); | ||
675 | GNUNET_asprintf (&tmp, | ||
676 | "%s%s%.*s=%s", | ||
677 | result, | ||
678 | sep, | ||
679 | pfx_len, | ||
680 | a->uri, | ||
681 | ue); | ||
682 | GNUNET_free (ue); | ||
683 | GNUNET_free (result); | ||
684 | result = tmp; | ||
685 | sep = "&"; | ||
686 | } | ||
687 | return result; | ||
688 | } | ||
689 | |||
690 | |||
691 | enum GNUNET_GenericReturnValue | ||
692 | GNUNET_HELLO_builder_to_block (const struct GNUNET_HELLO_Builder *builder, | ||
693 | const struct GNUNET_CRYPTO_EddsaPrivateKey *priv, | ||
694 | void *block, | ||
695 | size_t *block_size) | ||
696 | { | ||
697 | struct BlockHeader bh; | ||
698 | size_t needed = sizeof (bh); | ||
699 | char *pos; | ||
700 | struct GNUNET_TIME_Timestamp et; | ||
701 | |||
702 | for (struct Address *a = builder->a_head; | ||
703 | NULL != a; | ||
704 | a = a->next) | ||
705 | { | ||
706 | GNUNET_assert (needed + a->uri_len > needed); | ||
707 | needed += a->uri_len; | ||
708 | } | ||
709 | if ( (NULL == block) || | ||
710 | (needed < *block_size) ) | ||
711 | { | ||
712 | *block_size = needed; | ||
713 | return GNUNET_NO; | ||
714 | } | ||
715 | bh.pid = builder->pid; | ||
716 | et = GNUNET_TIME_relative_to_timestamp (GNUNET_HELLO_ADDRESS_EXPIRATION); | ||
717 | bh.expiration_time = GNUNET_TIME_absolute_hton (et.abs_time); | ||
718 | sign_hello (builder, | ||
719 | et, | ||
720 | priv, | ||
721 | &bh.sig); | ||
722 | memcpy (block, | ||
723 | &bh, | ||
724 | sizeof (bh)); | ||
725 | pos = block + sizeof (bh); | ||
726 | for (struct Address *a = builder->a_head; | ||
727 | NULL != a; | ||
728 | a = a->next) | ||
729 | { | ||
730 | memcpy (pos, | ||
731 | a->uri, | ||
732 | a->uri_len); | ||
733 | pos += a->uri_len; | ||
734 | } | ||
735 | *block_size = needed; | ||
736 | return GNUNET_OK; | ||
737 | } | ||
738 | |||
739 | |||
740 | enum GNUNET_GenericReturnValue | ||
741 | GNUNET_HELLO_builder_add_address (struct GNUNET_HELLO_Builder *builder, | ||
742 | const char *address) | ||
743 | { | ||
744 | size_t alen = strlen (address) + 1; | ||
745 | struct Address *a; | ||
746 | const char *e; | ||
747 | |||
748 | if (NULL == (e = strstr (address, | ||
749 | "://"))) | ||
750 | { | ||
751 | GNUNET_break_op (0); | ||
752 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | ||
753 | "Invalid address `%s'\n", | ||
754 | address); | ||
755 | return GNUNET_SYSERR; | ||
756 | } | ||
757 | if (e == address) | ||
758 | { | ||
759 | GNUNET_break_op (0); | ||
760 | return GNUNET_SYSERR; | ||
761 | } | ||
762 | for (const char *p = address; p != e; p++) | ||
763 | if ( (! isalpha ((unsigned char) *p)) && | ||
764 | ('+' != *p) ) | ||
765 | { | ||
766 | GNUNET_break_op (0); | ||
767 | return GNUNET_SYSERR; | ||
768 | } | ||
769 | /* check for duplicates */ | ||
770 | for (a = builder->a_head; | ||
771 | NULL != a; | ||
772 | a = a->next) | ||
773 | if (0 == strcmp (address, | ||
774 | a->uri)) | ||
775 | return GNUNET_NO; | ||
776 | a = GNUNET_malloc (sizeof (struct Address) + alen); | ||
777 | a->uri_len = alen; | ||
778 | memcpy (&a[1], | ||
779 | address, | ||
780 | alen); | ||
781 | a->uri = (const char *) &a[1]; | ||
782 | GNUNET_CONTAINER_DLL_insert_tail (builder->a_head, | ||
783 | builder->a_tail, | ||
784 | a); | ||
785 | builder->a_length++; | ||
786 | return GNUNET_OK; | ||
787 | } | ||
788 | |||
789 | |||
790 | enum GNUNET_GenericReturnValue | ||
791 | GNUNET_HELLO_builder_del_address (struct GNUNET_HELLO_Builder *builder, | ||
792 | const char *address) | ||
793 | { | ||
794 | struct Address *a; | ||
795 | |||
796 | /* check for duplicates */ | ||
797 | for (a = builder->a_head; | ||
798 | NULL != a; | ||
799 | a = a->next) | ||
800 | if (0 == strcmp (address, | ||
801 | a->uri)) | ||
802 | break; | ||
803 | if (NULL == a) | ||
804 | return GNUNET_NO; | ||
805 | GNUNET_CONTAINER_DLL_remove (builder->a_head, | ||
806 | builder->a_tail, | ||
807 | a); | ||
808 | builder->a_length--; | ||
809 | GNUNET_free (a); | ||
810 | return GNUNET_OK; | ||
811 | } | ||
812 | |||
813 | |||
814 | void | ||
815 | GNUNET_HELLO_builder_iterate (const struct GNUNET_HELLO_Builder *builder, | ||
816 | struct GNUNET_PeerIdentity *pid, | ||
817 | GNUNET_HELLO_UriCallback uc, | ||
818 | void *uc_cls) | ||
819 | { | ||
820 | struct Address *nxt; | ||
821 | |||
822 | *pid = builder->pid; | ||
823 | if (NULL == uc) | ||
824 | return; | ||
825 | for (struct Address *a = builder->a_head; | ||
826 | NULL != a; | ||
827 | a = nxt) | ||
828 | { | ||
829 | nxt = a->next; | ||
830 | uc (uc_cls, | ||
831 | a->uri); | ||
832 | } | ||
833 | } | ||
834 | |||
835 | |||
836 | enum GNUNET_GenericReturnValue | ||
837 | GNUNET_HELLO_dht_msg_to_block (const struct GNUNET_MessageHeader *hello, | ||
838 | const struct GNUNET_PeerIdentity *pid, | ||
839 | void **block, | ||
840 | size_t *block_size, | ||
841 | struct GNUNET_TIME_Absolute *block_expiration) | ||
842 | { | ||
843 | const struct DhtHelloMessage *msg | ||
844 | = (const struct DhtHelloMessage *) hello; | ||
845 | uint16_t len = ntohs (hello->size); | ||
846 | struct BlockHeader *bh; | ||
847 | struct GNUNET_HELLO_Builder *b; | ||
848 | enum GNUNET_GenericReturnValue ret; | ||
849 | |||
850 | if (GNUNET_MESSAGE_TYPE_DHT_P2P_HELLO != ntohs (hello->type)) | ||
851 | { | ||
852 | GNUNET_break (0); | ||
853 | return GNUNET_SYSERR; | ||
854 | } | ||
855 | if (len < sizeof (*msg)) | ||
856 | { | ||
857 | GNUNET_break_op (0); | ||
858 | return GNUNET_SYSERR; | ||
859 | } | ||
860 | len -= sizeof (*msg); | ||
861 | *block_size = len + sizeof (*bh); | ||
862 | *block = GNUNET_malloc (*block_size); | ||
863 | bh = *block; | ||
864 | bh->pid = *pid; | ||
865 | bh->sig = msg->sig; | ||
866 | bh->expiration_time = msg->expiration_time; | ||
867 | *block_expiration = GNUNET_TIME_absolute_ntoh (msg->expiration_time); | ||
868 | memcpy (&bh[1], | ||
869 | &msg[1], | ||
870 | len); | ||
871 | b = GNUNET_HELLO_builder_from_block (*block, | ||
872 | *block_size); | ||
873 | if (NULL == b) | ||
874 | { | ||
875 | GNUNET_break_op (0); | ||
876 | GNUNET_free (*block); | ||
877 | *block_size = 0; | ||
878 | return GNUNET_SYSERR; | ||
879 | } | ||
880 | ret = verify_hello (b, | ||
881 | *block_expiration, | ||
882 | &msg->sig); | ||
883 | GNUNET_HELLO_builder_free (b); | ||
884 | if (GNUNET_SYSERR == ret) | ||
885 | { | ||
886 | GNUNET_free (*block); | ||
887 | *block_size = 0; | ||
888 | return GNUNET_SYSERR; | ||
889 | } | ||
890 | return ret; | ||
891 | } | ||
diff --git a/src/hello/test_hello-ng.c b/src/hello/test_hello-ng.c index e6b1d42a0..4ace9439f 100644 --- a/src/hello/test_hello-ng.c +++ b/src/hello/test_hello-ng.c | |||
@@ -1,3 +1,22 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2022 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 | */ | ||
1 | #include "platform.h" | 20 | #include "platform.h" |
2 | #include "gnunet_util_lib.h" | 21 | #include "gnunet_util_lib.h" |
3 | #include "gnunet_nt_lib.h" | 22 | #include "gnunet_nt_lib.h" |
@@ -23,12 +42,12 @@ main (int argc, | |||
23 | GNUNET_NT_LAN, | 42 | GNUNET_NT_LAN, |
24 | t, | 43 | t, |
25 | &privKey, | 44 | &privKey, |
26 | (void**)&res, | 45 | (void**) &res, |
27 | &res_len); | 46 | &res_len); |
28 | GNUNET_log (GNUNET_ERROR_TYPE_MESSAGE, | 47 | GNUNET_log (GNUNET_ERROR_TYPE_MESSAGE, |
29 | "%s\n", res); | 48 | "%s\n", res); |
30 | GNUNET_assert (NULL != | 49 | GNUNET_assert (NULL != |
31 | GNUNET_HELLO_extract_address ((void**)res, | 50 | GNUNET_HELLO_extract_address ((void**) res, |
32 | res_len, | 51 | res_len, |
33 | &pid, | 52 | &pid, |
34 | &nt, | 53 | &nt, |
diff --git a/src/hello/test_hello-uri.c b/src/hello/test_hello-uri.c new file mode 100644 index 000000000..7e70d6763 --- /dev/null +++ b/src/hello/test_hello-uri.c | |||
@@ -0,0 +1,212 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2022 GNUnet e.V. | ||
4 | |||
5 | GNUnet is free software: you can redistribute it and/or modify it | ||
6 | under the terms of the GNU Affero General Public License as published | ||
7 | by the Free Software Foundation, either version 3 of the License, | ||
8 | or (at your option) any later version. | ||
9 | |||
10 | GNUnet is distributed in the hope that it will be useful, but | ||
11 | WITHOUT ANY WARRANTY; without even the implied warranty of | ||
12 | MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU | ||
13 | Affero General Public License for more details. | ||
14 | |||
15 | You should have received a copy of the GNU Affero General Public License | ||
16 | along with this program. If not, see <http://www.gnu.org/licenses/>. | ||
17 | |||
18 | SPDX-License-Identifier: AGPL3.0-or-later | ||
19 | */ | ||
20 | /** | ||
21 | * @file hello/test_hello-uri.c | ||
22 | * @brief test for helper library for handling URI-based HELLOs | ||
23 | * @author Christian Grothoff | ||
24 | */ | ||
25 | #include "platform.h" | ||
26 | #include "gnunet_signatures.h" | ||
27 | #include "gnunet_hello_uri_lib.h" | ||
28 | #include "gnunet_util_lib.h" | ||
29 | |||
30 | |||
31 | /** | ||
32 | * Check for expected URIs. | ||
33 | * | ||
34 | * @param cls a `unsigned int*`, bitmask set to found URIs | ||
35 | * @param uri URI to check for | ||
36 | */ | ||
37 | static void | ||
38 | check_uris (void *cls, | ||
39 | const char *uri) | ||
40 | { | ||
41 | unsigned int *found = cls; | ||
42 | |||
43 | if (0 == strcmp (uri, | ||
44 | "test://address")) | ||
45 | *found |= 1; | ||
46 | else if (0 == strcmp (uri, | ||
47 | "test://more")) | ||
48 | *found |= 2; | ||
49 | else | ||
50 | *found = (unsigned int) -1; | ||
51 | } | ||
52 | |||
53 | |||
54 | int | ||
55 | main (int argc, | ||
56 | char *argv[]) | ||
57 | { | ||
58 | struct GNUNET_PeerIdentity pid; | ||
59 | struct GNUNET_HELLO_Builder *b; | ||
60 | struct GNUNET_CRYPTO_EddsaPrivateKey priv; | ||
61 | |||
62 | GNUNET_log_setup ("test-hell-uri", | ||
63 | "WARNING", | ||
64 | NULL); | ||
65 | GNUNET_CRYPTO_eddsa_key_create (&priv); | ||
66 | GNUNET_CRYPTO_eddsa_key_get_public (&priv, | ||
67 | &pid.public_key); | ||
68 | b = GNUNET_HELLO_builder_new (&pid); | ||
69 | GNUNET_assert (GNUNET_SYSERR == | ||
70 | GNUNET_HELLO_builder_add_address (b, | ||
71 | "invalid")); | ||
72 | GNUNET_assert (GNUNET_SYSERR == | ||
73 | GNUNET_HELLO_builder_add_address (b, | ||
74 | "i%v://bla")); | ||
75 | GNUNET_assert (GNUNET_SYSERR == | ||
76 | GNUNET_HELLO_builder_add_address (b, | ||
77 | "://empty")); | ||
78 | GNUNET_assert (GNUNET_OK == | ||
79 | GNUNET_HELLO_builder_add_address (b, | ||
80 | "test://address")); | ||
81 | GNUNET_assert (GNUNET_NO == | ||
82 | GNUNET_HELLO_builder_add_address (b, | ||
83 | "test://address")); | ||
84 | GNUNET_assert (GNUNET_OK == | ||
85 | GNUNET_HELLO_builder_add_address (b, | ||
86 | "test://more")); | ||
87 | { | ||
88 | void *block; | ||
89 | size_t block_size = 0; | ||
90 | struct GNUNET_HELLO_Builder *b2; | ||
91 | struct GNUNET_PeerIdentity p2; | ||
92 | unsigned int found; | ||
93 | |||
94 | GNUNET_assert (GNUNET_NO == | ||
95 | GNUNET_HELLO_builder_to_block (b, | ||
96 | &priv, | ||
97 | NULL, | ||
98 | &block_size)); | ||
99 | GNUNET_assert (GNUNET_NO == | ||
100 | GNUNET_HELLO_builder_to_block (b, | ||
101 | &priv, | ||
102 | NULL, | ||
103 | &block_size)); | ||
104 | GNUNET_assert (0 != block_size); | ||
105 | block = GNUNET_malloc (block_size); | ||
106 | GNUNET_assert (GNUNET_OK == | ||
107 | GNUNET_HELLO_builder_to_block (b, | ||
108 | &priv, | ||
109 | block, | ||
110 | &block_size)); | ||
111 | b2 = GNUNET_HELLO_builder_from_block (block, | ||
112 | block_size); | ||
113 | GNUNET_free (block); | ||
114 | GNUNET_assert (NULL != b2); | ||
115 | found = 0; | ||
116 | GNUNET_HELLO_builder_iterate (b2, | ||
117 | &p2, | ||
118 | &check_uris, | ||
119 | &found); | ||
120 | GNUNET_assert (3 == found); | ||
121 | GNUNET_assert (0 == | ||
122 | GNUNET_memcmp (&p2, | ||
123 | &pid)); | ||
124 | GNUNET_HELLO_builder_free (b2); | ||
125 | } | ||
126 | |||
127 | { | ||
128 | char *url; | ||
129 | struct GNUNET_HELLO_Builder *b2; | ||
130 | struct GNUNET_PeerIdentity p2; | ||
131 | unsigned int found; | ||
132 | |||
133 | url = GNUNET_HELLO_builder_to_url (b, | ||
134 | &priv); | ||
135 | b2 = GNUNET_HELLO_builder_from_url (url); | ||
136 | GNUNET_free (url); | ||
137 | GNUNET_assert (NULL != b2); | ||
138 | found = 0; | ||
139 | GNUNET_HELLO_builder_iterate (b2, | ||
140 | &p2, | ||
141 | &check_uris, | ||
142 | &found); | ||
143 | GNUNET_assert (3 == found); | ||
144 | GNUNET_assert (0 == | ||
145 | GNUNET_memcmp (&p2, | ||
146 | &pid)); | ||
147 | GNUNET_HELLO_builder_free (b2); | ||
148 | } | ||
149 | |||
150 | { | ||
151 | struct GNUNET_MQ_Envelope *env; | ||
152 | struct GNUNET_HELLO_Builder *b2; | ||
153 | struct GNUNET_PeerIdentity p2; | ||
154 | unsigned int found; | ||
155 | |||
156 | env = GNUNET_HELLO_builder_to_env (b, | ||
157 | &priv); | ||
158 | b2 = GNUNET_HELLO_builder_from_msg (GNUNET_MQ_env_get_msg (env)); | ||
159 | GNUNET_free (env); | ||
160 | GNUNET_assert (NULL != b2); | ||
161 | found = 0; | ||
162 | GNUNET_HELLO_builder_iterate (b2, | ||
163 | &p2, | ||
164 | &check_uris, | ||
165 | &found); | ||
166 | GNUNET_assert (3 == found); | ||
167 | GNUNET_assert (0 == | ||
168 | GNUNET_memcmp (&p2, | ||
169 | &pid)); | ||
170 | GNUNET_HELLO_builder_free (b2); | ||
171 | } | ||
172 | |||
173 | GNUNET_HELLO_builder_free (b); | ||
174 | |||
175 | GNUNET_CRYPTO_mpi_print_unsigned (priv.d, | ||
176 | sizeof (priv.d), | ||
177 | GCRYMPI_CONST_ONE); | ||
178 | priv.d[0] &= 248; | ||
179 | priv.d[31] &= 127; | ||
180 | priv.d[31] |= 64; | ||
181 | { | ||
182 | char *buf; | ||
183 | |||
184 | buf = GNUNET_STRINGS_data_to_string_alloc (&priv, | ||
185 | sizeof (priv)); | ||
186 | fprintf (stderr, | ||
187 | "PK: %s\n", | ||
188 | buf); | ||
189 | GNUNET_free (buf); | ||
190 | } | ||
191 | GNUNET_CRYPTO_eddsa_key_get_public (&priv, | ||
192 | &pid.public_key); | ||
193 | b = GNUNET_HELLO_builder_new (&pid); | ||
194 | GNUNET_assert (GNUNET_OK == | ||
195 | GNUNET_HELLO_builder_add_address (b, | ||
196 | "a://first")); | ||
197 | GNUNET_assert (GNUNET_OK == | ||
198 | GNUNET_HELLO_builder_add_address (b, | ||
199 | "b://second")); | ||
200 | { | ||
201 | char *url; | ||
202 | |||
203 | url = GNUNET_HELLO_builder_to_url (b, | ||
204 | &priv); | ||
205 | fprintf (stderr, | ||
206 | "TV: %s\n", | ||
207 | url); | ||
208 | GNUNET_free (url); | ||
209 | } | ||
210 | |||
211 | return 0; | ||
212 | } | ||
diff --git a/src/hostlist/gnunet-daemon-hostlist_client.c b/src/hostlist/gnunet-daemon-hostlist_client.c index 44966d3de..1f7d4cc35 100644 --- a/src/hostlist/gnunet-daemon-hostlist_client.c +++ b/src/hostlist/gnunet-daemon-hostlist_client.c | |||
@@ -1635,7 +1635,11 @@ GNUNET_HOSTLIST_client_start (const struct GNUNET_CONFIGURATION_Handle *c, | |||
1635 | "PROXY_TYPE", | 1635 | "PROXY_TYPE", |
1636 | &proxytype_str)) | 1636 | &proxytype_str)) |
1637 | { | 1637 | { |
1638 | GNUNET_STRINGS_utf8_toupper (proxytype_str, proxytype_str); | 1638 | if (GNUNET_OK != GNUNET_STRINGS_utf8_toupper (proxytype_str, |
1639 | proxytype_str)) | ||
1640 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | ||
1641 | "Unable to convert `%s' to UTF-8 uppercase\n", | ||
1642 | proxytype_str); | ||
1639 | proxy_type = CURLPROXY_HTTP; | 1643 | proxy_type = CURLPROXY_HTTP; |
1640 | if (0 == strcmp (proxytype_str, "HTTP")) | 1644 | if (0 == strcmp (proxytype_str, "HTTP")) |
1641 | proxy_type = CURLPROXY_HTTP; | 1645 | proxy_type = CURLPROXY_HTTP; |
diff --git a/src/identity/Makefile.am b/src/identity/Makefile.am index e535c208a..5a2110974 100644 --- a/src/identity/Makefile.am +++ b/src/identity/Makefile.am | |||
@@ -95,6 +95,7 @@ test_identity_defaults_LDADD = \ | |||
95 | $(top_builddir)/src/util/libgnunetutil.la | 95 | $(top_builddir)/src/util/libgnunetutil.la |
96 | 96 | ||
97 | EXTRA_DIST = \ | 97 | EXTRA_DIST = \ |
98 | test_identity.conf | 98 | test_identity.conf \ |
99 | test_identity_messages.sh | ||
99 | 100 | ||
100 | 101 | ||
diff --git a/src/identity/gnunet-service-identity.c b/src/identity/gnunet-service-identity.c index 2bb4b0897..51f897557 100644 --- a/src/identity/gnunet-service-identity.c +++ b/src/identity/gnunet-service-identity.c | |||
@@ -489,8 +489,7 @@ handle_get_default_message (void *cls, | |||
489 | char *identifier; | 489 | char *identifier; |
490 | 490 | ||
491 | name = GNUNET_strdup ((const char *) &gdm[1]); | 491 | name = GNUNET_strdup ((const char *) &gdm[1]); |
492 | GNUNET_STRINGS_utf8_tolower ((const char *) &gdm[1], | 492 | GNUNET_STRINGS_utf8_tolower ((const char *) &gdm[1], name); |
493 | name); | ||
494 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 493 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
495 | "Received GET_DEFAULT for service `%s' from client\n", | 494 | "Received GET_DEFAULT for service `%s' from client\n", |
496 | name); | 495 | name); |
diff --git a/src/include/Makefile.am b/src/include/Makefile.am index e4b02b8ee..8808f6802 100644 --- a/src/include/Makefile.am +++ b/src/include/Makefile.am | |||
@@ -57,6 +57,7 @@ gnunetinclude_HEADERS = \ | |||
57 | gnunet_gnsrecord_plugin.h \ | 57 | gnunet_gnsrecord_plugin.h \ |
58 | gnu_name_system_record_types.h \ | 58 | gnu_name_system_record_types.h \ |
59 | gnunet_hello_lib.h \ | 59 | gnunet_hello_lib.h \ |
60 | gnunet_hello_uri_lib.h \ | ||
60 | gnunet_helper_lib.h \ | 61 | gnunet_helper_lib.h \ |
61 | gnunet_identity_service.h \ | 62 | gnunet_identity_service.h \ |
62 | gnunet_abe_lib.h \ | 63 | gnunet_abe_lib.h \ |
diff --git a/src/include/gnunet_block_group_lib.h b/src/include/gnunet_block_group_lib.h index 6cb601757..b03e913c6 100644 --- a/src/include/gnunet_block_group_lib.h +++ b/src/include/gnunet_block_group_lib.h | |||
@@ -94,7 +94,7 @@ GNUNET_BLOCK_GROUP_bf_create (void *cls, | |||
94 | * @return #GNUNET_YES if @a hc is (likely) a duplicate | 94 | * @return #GNUNET_YES if @a hc is (likely) a duplicate |
95 | * #GNUNET_NO if @a hc was definitively not in @bg (but now is) | 95 | * #GNUNET_NO if @a hc was definitively not in @bg (but now is) |
96 | */ | 96 | */ |
97 | int | 97 | enum GNUNET_GenericReturnValue |
98 | GNUNET_BLOCK_GROUP_bf_test_and_set (struct GNUNET_BLOCK_Group *bg, | 98 | GNUNET_BLOCK_GROUP_bf_test_and_set (struct GNUNET_BLOCK_Group *bg, |
99 | const struct GNUNET_HashCode *hc); | 99 | const struct GNUNET_HashCode *hc); |
100 | 100 | ||
diff --git a/src/include/gnunet_block_lib.h b/src/include/gnunet_block_lib.h index 5640209a6..515b8256c 100644 --- a/src/include/gnunet_block_lib.h +++ b/src/include/gnunet_block_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) 2010 GNUnet e.V. | 3 | Copyright (C) 2010, 2022 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 |
@@ -119,6 +119,12 @@ enum GNUNET_BLOCK_Type | |||
119 | GNUNET_BLOCK_TYPE_REVOCATION = 12, | 119 | GNUNET_BLOCK_TYPE_REVOCATION = 12, |
120 | 120 | ||
121 | /** | 121 | /** |
122 | * Type of a block that contains a DHT-NG HELLO for a peer (for | ||
123 | * DHT and CADET find-peer operations). | ||
124 | */ | ||
125 | GNUNET_BLOCK_TYPE_DHT_URL_HELLO = 13, | ||
126 | |||
127 | /** | ||
122 | * Block to store a cadet regex state | 128 | * Block to store a cadet regex state |
123 | */ | 129 | */ |
124 | GNUNET_BLOCK_TYPE_REGEX = 22, | 130 | GNUNET_BLOCK_TYPE_REGEX = 22, |
@@ -156,108 +162,35 @@ enum GNUNET_BLOCK_Type | |||
156 | 162 | ||
157 | 163 | ||
158 | /** | 164 | /** |
159 | * Flags that can be set to control the evaluation. | ||
160 | * @deprecated | ||
161 | */ | ||
162 | enum GNUNET_BLOCK_EvaluationOptions | ||
163 | { | ||
164 | /** | ||
165 | * Default behavior. | ||
166 | */ | ||
167 | GNUNET_BLOCK_EO_NONE = 0, | ||
168 | |||
169 | /** | ||
170 | * The block is obtained from the local database, skip cryptographic | ||
171 | * checks. | ||
172 | */ | ||
173 | GNUNET_BLOCK_EO_LOCAL_SKIP_CRYPTO = 1 | ||
174 | }; | ||
175 | |||
176 | |||
177 | /** | ||
178 | * Possible ways for how a block may relate to a query. | 165 | * Possible ways for how a block may relate to a query. |
179 | * @deprecated | ||
180 | */ | 166 | */ |
181 | enum GNUNET_BLOCK_EvaluationResult | 167 | enum GNUNET_BLOCK_ReplyEvaluationResult |
182 | { | 168 | { |
183 | /** | ||
184 | * Valid result, and there may be more. | ||
185 | */ | ||
186 | GNUNET_BLOCK_EVALUATION_OK_MORE = 0, | ||
187 | 169 | ||
188 | /** | 170 | /** |
189 | * Last possible valid result. | 171 | * Specified block type not supported by any plugin. |
190 | */ | 172 | */ |
191 | GNUNET_BLOCK_EVALUATION_OK_LAST = 1, | 173 | GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED = -1, |
192 | 174 | ||
193 | /** | 175 | /** |
194 | * Valid result, but suppressed because it is a duplicate. | 176 | * Valid result, but suppressed because it is a duplicate. |
195 | */ | 177 | */ |
196 | GNUNET_BLOCK_EVALUATION_OK_DUPLICATE = 2, | 178 | GNUNET_BLOCK_REPLY_OK_DUPLICATE = 0, |
197 | |||
198 | /** | ||
199 | * Block does not match query (invalid result) | ||
200 | */ | ||
201 | GNUNET_BLOCK_EVALUATION_RESULT_INVALID = 3, | ||
202 | 179 | ||
203 | /** | 180 | /** |
204 | * Block does not match xquery (valid result, not relevant for the request) | 181 | * Block does not match xquery (valid result, not relevant for the request) |
205 | */ | 182 | */ |
206 | GNUNET_BLOCK_EVALUATION_RESULT_IRRELEVANT = 4, | 183 | GNUNET_BLOCK_REPLY_IRRELEVANT = 1, |
207 | |||
208 | /** | ||
209 | * Query is valid, no reply given. | ||
210 | */ | ||
211 | GNUNET_BLOCK_EVALUATION_REQUEST_VALID = 10, | ||
212 | |||
213 | /** | ||
214 | * Query format does not match block type (invalid query). For | ||
215 | * example, xquery not given or xquery_size not appropriate for | ||
216 | * type. | ||
217 | */ | ||
218 | GNUNET_BLOCK_EVALUATION_REQUEST_INVALID = 11, | ||
219 | |||
220 | /** | ||
221 | * Specified block type not supported by this plugin. | ||
222 | */ | ||
223 | GNUNET_BLOCK_EVALUATION_TYPE_NOT_SUPPORTED = 20 | ||
224 | }; | ||
225 | |||
226 | |||
227 | /** | ||
228 | * Possible ways for how a block may relate to a query. | ||
229 | */ | ||
230 | enum GNUNET_BLOCK_ReplyEvaluationResult | ||
231 | { | ||
232 | /** | ||
233 | * Valid result, but suppressed because it is a duplicate. | ||
234 | */ | ||
235 | GNUNET_BLOCK_REPLY_OK_DUPLICATE = 0, | ||
236 | 184 | ||
237 | /** | 185 | /** |
238 | * Valid result, and there may be more. | 186 | * Valid result, and there may be more. |
239 | */ | 187 | */ |
240 | GNUNET_BLOCK_REPLY_OK_MORE = 1, | 188 | GNUNET_BLOCK_REPLY_OK_MORE = 2, |
241 | 189 | ||
242 | /** | 190 | /** |
243 | * Last possible valid result. | 191 | * Last possible valid result. |
244 | */ | 192 | */ |
245 | GNUNET_BLOCK_REPLY_OK_LAST = 2, | 193 | GNUNET_BLOCK_REPLY_OK_LAST = 3 |
246 | |||
247 | /** | ||
248 | * Specified block type not supported by any plugin. | ||
249 | */ | ||
250 | GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED = -1, | ||
251 | |||
252 | /** | ||
253 | * Block does not match query (invalid result) | ||
254 | */ | ||
255 | GNUNET_BLOCK_REPLY_INVALID = -2, | ||
256 | |||
257 | /** | ||
258 | * Block does not match xquery (valid result, not relevant for the request) | ||
259 | */ | ||
260 | GNUNET_BLOCK_REPLY_IRRELEVANT = -3, | ||
261 | 194 | ||
262 | }; | 195 | }; |
263 | 196 | ||
@@ -356,44 +289,12 @@ GNUNET_BLOCK_group_destroy (struct GNUNET_BLOCK_Group *bg); | |||
356 | 289 | ||
357 | 290 | ||
358 | /** | 291 | /** |
359 | * Function called to validate a reply or a request. For | 292 | * Function called to validate if a reply is good for a |
360 | * request evaluation, simply pass "NULL" for the @a reply_block. | 293 | * particular query. |
361 | * Note that it is assumed that the reply has already been | ||
362 | * matched to the key (and signatures checked) as it would | ||
363 | * be done with the #GNUNET_BLOCK_get_key() function. | ||
364 | * | ||
365 | * @param ctx block contxt | ||
366 | * @param type block type | ||
367 | * @param group block group to use for evaluation | ||
368 | * @param eo evaluation options to control evaluation | ||
369 | * @param query original query (hash) | ||
370 | * @param xquery extrended query data (can be NULL, depending on type) | ||
371 | * @param xquery_size number of bytes in @a xquery | ||
372 | * @param reply_block response to validate | ||
373 | * @param reply_block_size number of bytes in @a reply_block | ||
374 | * @return characterization of result | ||
375 | * @deprecated | ||
376 | */ | ||
377 | enum GNUNET_BLOCK_EvaluationResult | ||
378 | GNUNET_BLOCK_evaluate (struct GNUNET_BLOCK_Context *ctx, | ||
379 | enum GNUNET_BLOCK_Type type, | ||
380 | struct GNUNET_BLOCK_Group *group, | ||
381 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
382 | const struct GNUNET_HashCode *query, | ||
383 | const void *xquery, | ||
384 | size_t xquery_size, | ||
385 | const void *reply_block, | ||
386 | size_t reply_block_size); | ||
387 | |||
388 | |||
389 | /** | ||
390 | * Function called to validate a reply. | ||
391 | * Also checks the query key against the block contents | ||
392 | * as it would be done with the #GNUNET_BLOCK_get_key() function. | ||
393 | * | 294 | * |
394 | * @param ctx block contxt | 295 | * @param ctx block contxt |
395 | * @param type block type | 296 | * @param type block type |
396 | * @param group block group to use for evaluation | 297 | * @param[in,out] group block group to use for evaluation |
397 | * @param query original query (hash) | 298 | * @param query original query (hash) |
398 | * @param xquery extrended query data (can be NULL, depending on type) | 299 | * @param xquery extrended query data (can be NULL, depending on type) |
399 | * @param xquery_size number of bytes in @a xquery | 300 | * @param xquery_size number of bytes in @a xquery |
@@ -436,7 +337,6 @@ GNUNET_BLOCK_check_query (struct GNUNET_BLOCK_Context *ctx, | |||
436 | * | 337 | * |
437 | * @param ctx block contxt | 338 | * @param ctx block contxt |
438 | * @param type block type | 339 | * @param type block type |
439 | * @param query query key (hash) | ||
440 | * @param block payload to put | 340 | * @param block payload to put |
441 | * @param block_size number of bytes in @a block | 341 | * @param block_size number of bytes in @a block |
442 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not, | 342 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not, |
@@ -445,13 +345,14 @@ GNUNET_BLOCK_check_query (struct GNUNET_BLOCK_Context *ctx, | |||
445 | enum GNUNET_GenericReturnValue | 345 | enum GNUNET_GenericReturnValue |
446 | GNUNET_BLOCK_check_block (struct GNUNET_BLOCK_Context *ctx, | 346 | GNUNET_BLOCK_check_block (struct GNUNET_BLOCK_Context *ctx, |
447 | enum GNUNET_BLOCK_Type type, | 347 | enum GNUNET_BLOCK_Type type, |
448 | const struct GNUNET_HashCode *query, | ||
449 | const void *block, | 348 | const void *block, |
450 | size_t block_size); | 349 | size_t block_size); |
451 | 350 | ||
452 | 351 | ||
453 | /** | 352 | /** |
454 | * Function called to obtain the key for a block. | 353 | * Function called to obtain the @a key for a @a block. |
354 | * If the @a block is malformed, the function should | ||
355 | * zero-out @a key and return #GNUNET_OK. | ||
455 | * | 356 | * |
456 | * @param ctx block context | 357 | * @param ctx block context |
457 | * @param type block type | 358 | * @param type block type |
@@ -459,9 +360,8 @@ GNUNET_BLOCK_check_block (struct GNUNET_BLOCK_Context *ctx, | |||
459 | * @param block_size number of bytes in @a block | 360 | * @param block_size number of bytes in @a block |
460 | * @param key set to the key (query) for the given block | 361 | * @param key set to the key (query) for the given block |
461 | * @return #GNUNET_YES on success, | 362 | * @return #GNUNET_YES on success, |
462 | * #GNUNET_NO if the block is malformed | 363 | * #GNUNET_NO if extracting a key from a block of this @a type does not work |
463 | * #GNUNET_SYSERR if type not supported | 364 | * #GNUNET_SYSERR if @a type not supported |
464 | * (or if extracting a key from a block of this type does not work) | ||
465 | */ | 365 | */ |
466 | enum GNUNET_GenericReturnValue | 366 | enum GNUNET_GenericReturnValue |
467 | GNUNET_BLOCK_get_key (struct GNUNET_BLOCK_Context *ctx, | 367 | GNUNET_BLOCK_get_key (struct GNUNET_BLOCK_Context *ctx, |
diff --git a/src/include/gnunet_block_plugin.h b/src/include/gnunet_block_plugin.h index 2c9a3839d..1fa7ccf8b 100644 --- a/src/include/gnunet_block_plugin.h +++ b/src/include/gnunet_block_plugin.h | |||
@@ -1,6 +1,6 @@ | |||
1 | /* | 1 | /* |
2 | This file is part of GNUnet | 2 | This file is part of GNUnet |
3 | Copyright (C) 2010,2013,2017 GNUnet e.V. | 3 | Copyright (C) 2010, 2013, 2017, 2021, 2022 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 |
@@ -163,43 +163,9 @@ typedef struct GNUNET_BLOCK_Group * | |||
163 | 163 | ||
164 | 164 | ||
165 | /** | 165 | /** |
166 | * Function called to validate a reply or a request. For | ||
167 | * request evaluation, simply pass "NULL" for the @a reply_block. | ||
168 | * Note that it is assumed that the reply has already been | ||
169 | * matched to the key (and signatures checked) as it would | ||
170 | * be done with the "get_key" function. | ||
171 | * | ||
172 | * @param cls closure | ||
173 | * @param ctx block context | ||
174 | * @param type block type | ||
175 | * @param group which block group to use for evaluation | ||
176 | * @param eo evaluation options to control evaluation | ||
177 | * @param query original query (hash) | ||
178 | * @param xquery extrended query data (can be NULL, depending on type) | ||
179 | * @param xquery_size number of bytes in @a xquery | ||
180 | * @param reply_block response to validate | ||
181 | * @param reply_block_size number of bytes in @a reply_block | ||
182 | * @return characterization of result | ||
183 | * @deprecated | ||
184 | */ | ||
185 | typedef enum GNUNET_BLOCK_EvaluationResult | ||
186 | (*GNUNET_BLOCK_EvaluationFunction)(void *cls, | ||
187 | struct GNUNET_BLOCK_Context *ctx, | ||
188 | enum GNUNET_BLOCK_Type type, | ||
189 | struct GNUNET_BLOCK_Group *group, | ||
190 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
191 | const struct GNUNET_HashCode *query, | ||
192 | const void *xquery, | ||
193 | size_t xquery_size, | ||
194 | const void *reply_block, | ||
195 | size_t reply_block_size); | ||
196 | |||
197 | |||
198 | /** | ||
199 | * Function called to validate a query. | 166 | * Function called to validate a query. |
200 | * | 167 | * |
201 | * @param cls closure | 168 | * @param cls closure |
202 | * @param ctx block context | ||
203 | * @param type block type | 169 | * @param type block type |
204 | * @param query original query (hash) | 170 | * @param query original query (hash) |
205 | * @param xquery extrended query data (can be NULL, depending on type) | 171 | * @param xquery extrended query data (can be NULL, depending on type) |
@@ -215,19 +181,17 @@ typedef enum GNUNET_GenericReturnValue | |||
215 | 181 | ||
216 | 182 | ||
217 | /** | 183 | /** |
218 | * Function called to validate a block for storage. | 184 | * Function called to validate a @a block for storage. |
219 | * | 185 | * |
220 | * @param cls closure | 186 | * @param cls closure |
221 | * @param type block type | 187 | * @param type block type |
222 | * @param query key for the block (hash), must match exactly | ||
223 | * @param block block data to validate | 188 | * @param block block data to validate |
224 | * @param block_size number of bytes in @a block | 189 | * @param block_size number of bytes in @a block |
225 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not | 190 | * @return #GNUNET_OK if the @a block is fine, #GNUNET_NO if not, #GNUNET_SYSERR if the @a type is not supported |
226 | */ | 191 | */ |
227 | typedef enum GNUNET_GenericReturnValue | 192 | typedef enum GNUNET_GenericReturnValue |
228 | (*GNUNET_BLOCK_BlockEvaluationFunction)(void *cls, | 193 | (*GNUNET_BLOCK_BlockEvaluationFunction)(void *cls, |
229 | enum GNUNET_BLOCK_Type type, | 194 | enum GNUNET_BLOCK_Type type, |
230 | const struct GNUNET_HashCode *query, | ||
231 | const void *block, | 195 | const void *block, |
232 | size_t block_size); | 196 | size_t block_size); |
233 | 197 | ||
@@ -260,17 +224,18 @@ typedef enum GNUNET_BLOCK_ReplyEvaluationResult | |||
260 | 224 | ||
261 | 225 | ||
262 | /** | 226 | /** |
263 | * Function called to obtain the key for a block. | 227 | * Function called to obtain the @a key for a block. |
228 | * If the @a block is malformed, the function should | ||
229 | * zero-out @a key and return #GNUNET_OK. | ||
264 | * | 230 | * |
265 | * @param cls closure | 231 | * @param cls closure |
266 | * @param type block type | 232 | * @param type block type |
267 | * @param block block to get the key for | 233 | * @param block block to get the @a key for |
268 | * @param block_size number of bytes in @a block | 234 | * @param block_size number of bytes in @a block |
269 | * @param[out] key set to the key (query) for the given block | 235 | * @param[out] key set to the key (query) for the given block |
270 | * @return #GNUNET_YES on success, | 236 | * @return #GNUNET_YES on success, |
271 | * #GNUNET_NO if the block is malformed | 237 | * #GNUNET_NO if extracting a key for this @a type does not work |
272 | * #GNUNET_SYSERR if type not supported | 238 | * #GNUNET_SYSERR if @a type not supported |
273 | * (or if extracting a key from a block of this type does not work) | ||
274 | */ | 239 | */ |
275 | typedef enum GNUNET_GenericReturnValue | 240 | typedef enum GNUNET_GenericReturnValue |
276 | (*GNUNET_BLOCK_GetKeyFunction) (void *cls, | 241 | (*GNUNET_BLOCK_GetKeyFunction) (void *cls, |
@@ -297,14 +262,6 @@ struct GNUNET_BLOCK_PluginFunctions | |||
297 | const enum GNUNET_BLOCK_Type *types; | 262 | const enum GNUNET_BLOCK_Type *types; |
298 | 263 | ||
299 | /** | 264 | /** |
300 | * Main function of a block plugin. Allows us to check if a | ||
301 | * block matches a query. | ||
302 | * | ||
303 | * @param deprecated | ||
304 | */ | ||
305 | GNUNET_BLOCK_EvaluationFunction evaluate; | ||
306 | |||
307 | /** | ||
308 | * Obtain the key for a given block (if possible). | 265 | * Obtain the key for a given block (if possible). |
309 | */ | 266 | */ |
310 | GNUNET_BLOCK_GetKeyFunction get_key; | 267 | GNUNET_BLOCK_GetKeyFunction get_key; |
diff --git a/src/include/gnunet_common.h b/src/include/gnunet_common.h index 4472d3ee8..9bcd99c7b 100644 --- a/src/include/gnunet_common.h +++ b/src/include/gnunet_common.h | |||
@@ -623,6 +623,31 @@ GNUNET_abort_ (void) GNUNET_NORETURN; | |||
623 | 623 | ||
624 | 624 | ||
625 | /** | 625 | /** |
626 | * Convert a buffer to an 8-character string | ||
627 | * representative of the contents. This is used | ||
628 | * for logging binary data when debugging. | ||
629 | * | ||
630 | * @param buf buffer to log | ||
631 | * @param buf_size number of bytes in @a buf | ||
632 | * @return text representation of buf, valid until next | ||
633 | * call to this function | ||
634 | */ | ||
635 | const char * | ||
636 | GNUNET_b2s (const void *buf, | ||
637 | size_t buf_size); | ||
638 | |||
639 | |||
640 | /** | ||
641 | * Convert a fixed-sized object to a string using | ||
642 | * #GNUNET_b2s(). | ||
643 | * | ||
644 | * @param obj address of object to convert | ||
645 | * @return string representing the binary obj buffer | ||
646 | */ | ||
647 | #define GNUNET_B2S(obj) GNUNET_b2s ((obj), sizeof (*(obj))) | ||
648 | |||
649 | |||
650 | /** | ||
626 | * @ingroup logging | 651 | * @ingroup logging |
627 | * Ignore the next @a n calls to the log function. | 652 | * Ignore the next @a n calls to the log function. |
628 | * | 653 | * |
@@ -1240,7 +1265,7 @@ GNUNET_is_zero_ (const void *a, | |||
1240 | * @return GNUNET_YES if a is zero, GNUNET_NO otherwise | 1265 | * @return GNUNET_YES if a is zero, GNUNET_NO otherwise |
1241 | */ | 1266 | */ |
1242 | #define GNUNET_is_zero(a) \ | 1267 | #define GNUNET_is_zero(a) \ |
1243 | GNUNET_is_zero_ (a, sizeof (*a)) | 1268 | GNUNET_is_zero_ ((a), sizeof (*(a))) |
1244 | 1269 | ||
1245 | 1270 | ||
1246 | /** | 1271 | /** |
diff --git a/src/include/gnunet_crypto_lib.h b/src/include/gnunet_crypto_lib.h index 1ab135d80..72d783148 100644 --- a/src/include/gnunet_crypto_lib.h +++ b/src/include/gnunet_crypto_lib.h | |||
@@ -307,7 +307,7 @@ struct GNUNET_CRYPTO_SymmetricSessionKey | |||
307 | /** | 307 | /** |
308 | * Type of a nonce used for challenges. | 308 | * Type of a nonce used for challenges. |
309 | */ | 309 | */ |
310 | struct ChallengeNonceP | 310 | struct GNUNET_CRYPTO_ChallengeNonceP |
311 | { | 311 | { |
312 | /** | 312 | /** |
313 | * The value of the nonce. Note that this is NOT a hash. | 313 | * The value of the nonce. Note that this is NOT a hash. |
@@ -2551,9 +2551,9 @@ GNUNET_CRYPTO_cs_private_key_generate (struct GNUNET_CRYPTO_CsPrivateKey *priv); | |||
2551 | * @param[out] pub where to write the public key | 2551 | * @param[out] pub where to write the public key |
2552 | */ | 2552 | */ |
2553 | void | 2553 | void |
2554 | GNUNET_CRYPTO_cs_private_key_get_public (const struct | 2554 | GNUNET_CRYPTO_cs_private_key_get_public ( |
2555 | GNUNET_CRYPTO_CsPrivateKey *priv, | 2555 | const struct GNUNET_CRYPTO_CsPrivateKey *priv, |
2556 | struct GNUNET_CRYPTO_CsPublicKey *pub); | 2556 | struct GNUNET_CRYPTO_CsPublicKey *pub); |
2557 | 2557 | ||
2558 | 2558 | ||
2559 | /** | 2559 | /** |
@@ -2565,11 +2565,13 @@ GNUNET_CRYPTO_cs_private_key_get_public (const struct | |||
2565 | * Comment: Can be done in one HKDF shot and split output. | 2565 | * Comment: Can be done in one HKDF shot and split output. |
2566 | * | 2566 | * |
2567 | * @param nonce is a random nonce | 2567 | * @param nonce is a random nonce |
2568 | * @param seed seed to use in derivation | ||
2568 | * @param lts is a long-term-secret in form of a private key | 2569 | * @param lts is a long-term-secret in form of a private key |
2569 | * @param[out] r array containing derived secrets r0 and r1 | 2570 | * @param[out] r array containing derived secrets r0 and r1 |
2570 | */ | 2571 | */ |
2571 | void | 2572 | void |
2572 | GNUNET_CRYPTO_cs_r_derive (const struct GNUNET_CRYPTO_CsNonce *nonce, | 2573 | GNUNET_CRYPTO_cs_r_derive (const struct GNUNET_CRYPTO_CsNonce *nonce, |
2574 | const char *seed, | ||
2573 | const struct GNUNET_CRYPTO_CsPrivateKey *lts, | 2575 | const struct GNUNET_CRYPTO_CsPrivateKey *lts, |
2574 | struct GNUNET_CRYPTO_CsRSecret r[2]); | 2576 | struct GNUNET_CRYPTO_CsRSecret r[2]); |
2575 | 2577 | ||
@@ -2595,10 +2597,9 @@ GNUNET_CRYPTO_cs_r_get_public (const struct GNUNET_CRYPTO_CsRSecret *r_priv, | |||
2595 | * @param[out] bs array containing the two derived blinding secrets | 2597 | * @param[out] bs array containing the two derived blinding secrets |
2596 | */ | 2598 | */ |
2597 | void | 2599 | void |
2598 | GNUNET_CRYPTO_cs_blinding_secrets_derive (const struct | 2600 | GNUNET_CRYPTO_cs_blinding_secrets_derive ( |
2599 | GNUNET_CRYPTO_CsNonce *blind_seed, | 2601 | const struct GNUNET_CRYPTO_CsNonce *blind_seed, |
2600 | struct GNUNET_CRYPTO_CsBlindingSecret | 2602 | struct GNUNET_CRYPTO_CsBlindingSecret bs[2]); |
2601 | bs[2]); | ||
2602 | 2603 | ||
2603 | 2604 | ||
2604 | /** | 2605 | /** |
@@ -2614,15 +2615,14 @@ GNUNET_CRYPTO_cs_blinding_secrets_derive (const struct | |||
2614 | * @param[out] blinded_r_pub array of the two blinded R | 2615 | * @param[out] blinded_r_pub array of the two blinded R |
2615 | */ | 2616 | */ |
2616 | void | 2617 | void |
2617 | GNUNET_CRYPTO_cs_calc_blinded_c (const struct GNUNET_CRYPTO_CsBlindingSecret | 2618 | GNUNET_CRYPTO_cs_calc_blinded_c ( |
2618 | bs[2], | 2619 | const struct GNUNET_CRYPTO_CsBlindingSecret bs[2], |
2619 | const struct GNUNET_CRYPTO_CsRPublic r_pub[2], | 2620 | const struct GNUNET_CRYPTO_CsRPublic r_pub[2], |
2620 | const struct GNUNET_CRYPTO_CsPublicKey *pub, | 2621 | const struct GNUNET_CRYPTO_CsPublicKey *pub, |
2621 | const void *msg, | 2622 | const void *msg, |
2622 | size_t msg_len, | 2623 | size_t msg_len, |
2623 | struct GNUNET_CRYPTO_CsC blinded_c[2], | 2624 | struct GNUNET_CRYPTO_CsC blinded_c[2], |
2624 | struct GNUNET_CRYPTO_CsRPublic | 2625 | struct GNUNET_CRYPTO_CsRPublic blinded_r_pub[2]); |
2625 | blinded_r_pub[2]); | ||
2626 | 2626 | ||
2627 | 2627 | ||
2628 | /** | 2628 | /** |
@@ -2642,13 +2642,12 @@ GNUNET_CRYPTO_cs_calc_blinded_c (const struct GNUNET_CRYPTO_CsBlindingSecret | |||
2642 | * @return 0 or 1 for b (see Clause Blind Signature Scheme) | 2642 | * @return 0 or 1 for b (see Clause Blind Signature Scheme) |
2643 | */ | 2643 | */ |
2644 | unsigned int | 2644 | unsigned int |
2645 | GNUNET_CRYPTO_cs_sign_derive (const struct GNUNET_CRYPTO_CsPrivateKey *priv, | 2645 | GNUNET_CRYPTO_cs_sign_derive ( |
2646 | const struct GNUNET_CRYPTO_CsRSecret r[2], | 2646 | const struct GNUNET_CRYPTO_CsPrivateKey *priv, |
2647 | const struct GNUNET_CRYPTO_CsC c[2], | 2647 | const struct GNUNET_CRYPTO_CsRSecret r[2], |
2648 | const struct GNUNET_CRYPTO_CsNonce *nonce, | 2648 | const struct GNUNET_CRYPTO_CsC c[2], |
2649 | struct GNUNET_CRYPTO_CsBlindS * | 2649 | const struct GNUNET_CRYPTO_CsNonce *nonce, |
2650 | blinded_signature_scalar | 2650 | struct GNUNET_CRYPTO_CsBlindS *blinded_signature_scalar); |
2651 | ); | ||
2652 | 2651 | ||
2653 | 2652 | ||
2654 | /** | 2653 | /** |
@@ -2659,10 +2658,10 @@ GNUNET_CRYPTO_cs_sign_derive (const struct GNUNET_CRYPTO_CsPrivateKey *priv, | |||
2659 | * @param[out] signature_scalar where to write the unblinded signature | 2658 | * @param[out] signature_scalar where to write the unblinded signature |
2660 | */ | 2659 | */ |
2661 | void | 2660 | void |
2662 | GNUNET_CRYPTO_cs_unblind (const struct | 2661 | GNUNET_CRYPTO_cs_unblind ( |
2663 | GNUNET_CRYPTO_CsBlindS *blinded_signature_scalar, | 2662 | const struct GNUNET_CRYPTO_CsBlindS *blinded_signature_scalar, |
2664 | const struct GNUNET_CRYPTO_CsBlindingSecret *bs, | 2663 | const struct GNUNET_CRYPTO_CsBlindingSecret *bs, |
2665 | struct GNUNET_CRYPTO_CsS *signature_scalar); | 2664 | struct GNUNET_CRYPTO_CsS *signature_scalar); |
2666 | 2665 | ||
2667 | 2666 | ||
2668 | /** | 2667 | /** |
diff --git a/src/include/gnunet_datacache_lib.h b/src/include/gnunet_datacache_lib.h index 11076e3e7..737a5c845 100644 --- a/src/include/gnunet_datacache_lib.h +++ b/src/include/gnunet_datacache_lib.h | |||
@@ -154,6 +154,7 @@ GNUNET_DATACACHE_get (struct GNUNET_DATACACHE_Handle *h, | |||
154 | * | 154 | * |
155 | * @param h handle to the datacache | 155 | * @param h handle to the datacache |
156 | * @param key area of the keyspace to look into | 156 | * @param key area of the keyspace to look into |
157 | * @param type entries of which type are relevant? | ||
157 | * @param num_results number of results that should be returned to @a iter | 158 | * @param num_results number of results that should be returned to @a iter |
158 | * @param iter maybe NULL (to just count) | 159 | * @param iter maybe NULL (to just count) |
159 | * @param iter_cls closure for @a iter | 160 | * @param iter_cls closure for @a iter |
@@ -162,6 +163,7 @@ GNUNET_DATACACHE_get (struct GNUNET_DATACACHE_Handle *h, | |||
162 | unsigned int | 163 | unsigned int |
163 | GNUNET_DATACACHE_get_closest (struct GNUNET_DATACACHE_Handle *h, | 164 | GNUNET_DATACACHE_get_closest (struct GNUNET_DATACACHE_Handle *h, |
164 | const struct GNUNET_HashCode *key, | 165 | const struct GNUNET_HashCode *key, |
166 | enum GNUNET_BLOCK_Type type, | ||
165 | unsigned int num_results, | 167 | unsigned int num_results, |
166 | GNUNET_DATACACHE_Iterator iter, | 168 | GNUNET_DATACACHE_Iterator iter, |
167 | void *iter_cls); | 169 | void *iter_cls); |
diff --git a/src/include/gnunet_datacache_plugin.h b/src/include/gnunet_datacache_plugin.h index 24570be72..34bf5f277 100644 --- a/src/include/gnunet_datacache_plugin.h +++ b/src/include/gnunet_datacache_plugin.h | |||
@@ -158,14 +158,16 @@ struct GNUNET_DATACACHE_PluginFunctions | |||
158 | 158 | ||
159 | 159 | ||
160 | /** | 160 | /** |
161 | * Iterate over the results that are "close" to a particular key in | 161 | * Iterate over the results that are "close" to a particular key in the |
162 | * the datacache. "close" is defined as numerically larger than @a | 162 | * datacache. "close" is defined as returning the @a num_results that are |
163 | * key (when interpreted as a circular address space), with small | 163 | * numerically closest and larger than @a key and also @a num_results that |
164 | * distance. | 164 | * are numerically lower than @a key. Thus, the maximum number of results |
165 | * returned is actually twice @a num_results. | ||
165 | * | 166 | * |
166 | * @param cls closure (internal context for the plugin) | 167 | * @param cls closure (internal context for the plugin) |
167 | * @param key area of the keyspace to look into | 168 | * @param key area of the keyspace to look into |
168 | * @param num_results number of results that should be returned to @a iter | 169 | * @param type desired block type for the replies |
170 | * @param num_results half the number of results that should be returned to @a iter | ||
169 | * @param iter maybe NULL (to just count) | 171 | * @param iter maybe NULL (to just count) |
170 | * @param iter_cls closure for @a iter | 172 | * @param iter_cls closure for @a iter |
171 | * @return the number of results found | 173 | * @return the number of results found |
@@ -173,6 +175,7 @@ struct GNUNET_DATACACHE_PluginFunctions | |||
173 | unsigned int | 175 | unsigned int |
174 | (*get_closest) (void *cls, | 176 | (*get_closest) (void *cls, |
175 | const struct GNUNET_HashCode *key, | 177 | const struct GNUNET_HashCode *key, |
178 | enum GNUNET_BLOCK_Type type, | ||
176 | unsigned int num_results, | 179 | unsigned int num_results, |
177 | GNUNET_DATACACHE_Iterator iter, | 180 | GNUNET_DATACACHE_Iterator iter, |
178 | void *iter_cls); | 181 | void *iter_cls); |
diff --git a/src/include/gnunet_dht_service.h b/src/include/gnunet_dht_service.h index 768b19fb1..22b659d66 100644 --- a/src/include/gnunet_dht_service.h +++ b/src/include/gnunet_dht_service.h | |||
@@ -101,14 +101,14 @@ enum GNUNET_DHT_RouteOption | |||
101 | GNUNET_DHT_RO_RECORD_ROUTE = 2, | 101 | GNUNET_DHT_RO_RECORD_ROUTE = 2, |
102 | 102 | ||
103 | /** | 103 | /** |
104 | * This is a 'FIND-PEER' request, so approximate results are fine. | 104 | * Approximate results are fine. |
105 | */ | 105 | */ |
106 | GNUNET_DHT_RO_FIND_PEER = 4, | 106 | GNUNET_DHT_RO_FIND_APPROXIMATE = 4, |
107 | 107 | ||
108 | /** | 108 | /** |
109 | * Flag given to monitors if this was the last hop for a GET/PUT. | 109 | * Flag given to monitors if this was the last hop for a GET/PUT. |
110 | * This is only used for internal processing. | 110 | * This is only used for internal processing. |
111 | */ | 111 | */ |
112 | GNUNET_DHT_RO_LAST_HOP = 65535 | 112 | GNUNET_DHT_RO_LAST_HOP = 65535 |
113 | }; | 113 | }; |
114 | 114 | ||
@@ -131,11 +131,6 @@ struct GNUNET_DHT_HopSignature | |||
131 | struct GNUNET_TIME_AbsoluteNBO expiration_time; | 131 | struct GNUNET_TIME_AbsoluteNBO expiration_time; |
132 | 132 | ||
133 | /** | 133 | /** |
134 | * Key of the block. | ||
135 | */ | ||
136 | struct GNUNET_HashCode key; | ||
137 | |||
138 | /** | ||
139 | * Hash over the payload of the block. | 134 | * Hash over the payload of the block. |
140 | */ | 135 | */ |
141 | struct GNUNET_HashCode h_data; | 136 | struct GNUNET_HashCode h_data; |
@@ -181,6 +176,7 @@ struct GNUNET_DHT_PathElement | |||
181 | 176 | ||
182 | }; | 177 | }; |
183 | 178 | ||
179 | |||
184 | GNUNET_NETWORK_STRUCT_END | 180 | GNUNET_NETWORK_STRUCT_END |
185 | 181 | ||
186 | /** | 182 | /** |
@@ -266,7 +262,7 @@ GNUNET_DHT_put_cancel (struct GNUNET_DHT_PutHandle *ph); | |||
266 | * | 262 | * |
267 | * @param cls closure | 263 | * @param cls closure |
268 | * @param exp when will this value expire | 264 | * @param exp when will this value expire |
269 | * @param key key of the result | 265 | * @param query_hash key of the query |
270 | * @param get_path peers on reply path (or NULL if not recorded) | 266 | * @param get_path peers on reply path (or NULL if not recorded) |
271 | * [0] = datastore's first neighbor, [length - 1] = local peer | 267 | * [0] = datastore's first neighbor, [length - 1] = local peer |
272 | * @param get_path_length number of entries in @a get_path | 268 | * @param get_path_length number of entries in @a get_path |
@@ -282,7 +278,7 @@ GNUNET_DHT_put_cancel (struct GNUNET_DHT_PutHandle *ph); | |||
282 | typedef void | 278 | typedef void |
283 | (*GNUNET_DHT_GetIterator) (void *cls, | 279 | (*GNUNET_DHT_GetIterator) (void *cls, |
284 | struct GNUNET_TIME_Absolute exp, | 280 | struct GNUNET_TIME_Absolute exp, |
285 | const struct GNUNET_HashCode *key, | 281 | const struct GNUNET_HashCode *query_hash, |
286 | const struct GNUNET_DHT_PathElement *get_path, | 282 | const struct GNUNET_DHT_PathElement *get_path, |
287 | unsigned int get_path_length, | 283 | unsigned int get_path_length, |
288 | const struct GNUNET_DHT_PathElement *put_path, | 284 | const struct GNUNET_DHT_PathElement *put_path, |
@@ -487,7 +483,6 @@ GNUNET_DHT_pp2s (const struct GNUNET_DHT_PathElement *path, | |||
487 | * the last signature on the path is never verified as that is the slot where | 483 | * the last signature on the path is never verified as that is the slot where |
488 | * our peer (@a me) would need to sign. | 484 | * our peer (@a me) would need to sign. |
489 | * | 485 | * |
490 | * @param key key of the data (not necessarily the query hash) | ||
491 | * @param data payload (the block) | 486 | * @param data payload (the block) |
492 | * @param data_size number of bytes in @a data | 487 | * @param data_size number of bytes in @a data |
493 | * @param exp_time expiration time of @a data | 488 | * @param exp_time expiration time of @a data |
@@ -501,8 +496,7 @@ GNUNET_DHT_pp2s (const struct GNUNET_DHT_PathElement *path, | |||
501 | * @a get_path_len + @a put_path_len - 1 if no signature was valid | 496 | * @a get_path_len + @a put_path_len - 1 if no signature was valid |
502 | */ | 497 | */ |
503 | unsigned int | 498 | unsigned int |
504 | GNUNET_DHT_verify_path (const struct GNUNET_HashCode *key, | 499 | GNUNET_DHT_verify_path (const void *data, |
505 | const void *data, | ||
506 | size_t data_size, | 500 | size_t data_size, |
507 | struct GNUNET_TIME_Absolute exp_time, | 501 | struct GNUNET_TIME_Absolute exp_time, |
508 | const struct GNUNET_DHT_PathElement *put_path, | 502 | const struct GNUNET_DHT_PathElement *put_path, |
@@ -512,6 +506,63 @@ GNUNET_DHT_verify_path (const struct GNUNET_HashCode *key, | |||
512 | const struct GNUNET_PeerIdentity *me); | 506 | const struct GNUNET_PeerIdentity *me); |
513 | 507 | ||
514 | 508 | ||
509 | /** | ||
510 | * Handle to get a HELLO URL from the DHT for manual bootstrapping. | ||
511 | */ | ||
512 | struct GNUNET_DHT_HelloGetHandle; | ||
513 | |||
514 | |||
515 | /** | ||
516 | * Signature called with the result of a HELLO GET operation. | ||
517 | * | ||
518 | * @param cls closure | ||
519 | * @param hello_url the resulting HELLO URL, NULL on error | ||
520 | */ | ||
521 | typedef void | ||
522 | (*GNUNET_DHT_HelloGetCallback)(void *cls, | ||
523 | const char *hello_url); | ||
524 | |||
525 | |||
526 | /** | ||
527 | * Obtain HELLO URL of the DHT identified by @a dht_handle. | ||
528 | * | ||
529 | * @param dht_handle DHT to query | ||
530 | * @param cb function to call with the result | ||
531 | * @param cb_cls closure for @a cb | ||
532 | * @return NULL on failure | ||
533 | */ | ||
534 | struct GNUNET_DHT_HelloGetHandle * | ||
535 | GNUNET_DHT_hello_get (struct GNUNET_DHT_Handle *dht_handle, | ||
536 | GNUNET_DHT_HelloGetCallback cb, | ||
537 | void *cb_cls); | ||
538 | |||
539 | |||
540 | /** | ||
541 | * Cancel hello get operation. | ||
542 | * | ||
543 | * @param[in] hgh operation to cancel. | ||
544 | */ | ||
545 | void | ||
546 | GNUNET_DHT_hello_get_cancel (struct GNUNET_DHT_HelloGetHandle *hgh); | ||
547 | |||
548 | |||
549 | /** | ||
550 | * Offer HELLO URL of the DHT identified by @a dht_handle. | ||
551 | * Callback may be invoked once, only way to cancel is to | ||
552 | * disconnect @a dht_handle. | ||
553 | * | ||
554 | * @param dht_handle DHT to query | ||
555 | * @param url URL with a HELLO to offer to the DHT | ||
556 | * @param cb function called when done | ||
557 | * @param cb_cls closure for @a cb | ||
558 | */ | ||
559 | void | ||
560 | GNUNET_DHT_hello_offer (struct GNUNET_DHT_Handle *dht_handle, | ||
561 | const char *url, | ||
562 | GNUNET_SCHEDULER_TaskCallback cb, | ||
563 | void *cb_cls); | ||
564 | |||
565 | |||
515 | #if 0 /* keep Emacsens' auto-indent happy */ | 566 | #if 0 /* keep Emacsens' auto-indent happy */ |
516 | { | 567 | { |
517 | #endif | 568 | #endif |
diff --git a/src/include/gnunet_dhtu_plugin.h b/src/include/gnunet_dhtu_plugin.h index 2c97d5848..fa0b5f667 100644 --- a/src/include/gnunet_dhtu_plugin.h +++ b/src/include/gnunet_dhtu_plugin.h | |||
@@ -59,15 +59,6 @@ struct GNUNET_DHTU_PreferenceHandle; | |||
59 | 59 | ||
60 | 60 | ||
61 | /** | 61 | /** |
62 | * Key used to identify peer's position in the DHT. | ||
63 | */ | ||
64 | struct GNUNET_DHTU_HashKey | ||
65 | { | ||
66 | struct GNUNET_HashCode sha512; | ||
67 | }; | ||
68 | |||
69 | |||
70 | /** | ||
71 | * The datastore service will pass a pointer to a struct | 62 | * The datastore service will pass a pointer to a struct |
72 | * of this type as the first and only argument to the | 63 | * of this type as the first and only argument to the |
73 | * entry point of each datastore plugin. | 64 | * entry point of each datastore plugin. |
@@ -88,7 +79,6 @@ struct GNUNET_DHTU_PluginEnvironment | |||
88 | * Function to call with new addresses of this peer. | 79 | * Function to call with new addresses of this peer. |
89 | * | 80 | * |
90 | * @param cls the closure | 81 | * @param cls the closure |
91 | * @param key hash position of this address in the DHT | ||
92 | * @param address address under which we are likely reachable, | 82 | * @param address address under which we are likely reachable, |
93 | * pointer will remain valid until @e address_del_cb is called; to be used for HELLOs. Example: "ip+udp://1.1.1.1:2086/" | 83 | * pointer will remain valid until @e address_del_cb is called; to be used for HELLOs. Example: "ip+udp://1.1.1.1:2086/" |
94 | * @param source handle for sending from this address, NULL if we can only receive | 84 | * @param source handle for sending from this address, NULL if we can only receive |
@@ -96,7 +86,6 @@ struct GNUNET_DHTU_PluginEnvironment | |||
96 | */ | 86 | */ |
97 | void | 87 | void |
98 | (*address_add_cb)(void *cls, | 88 | (*address_add_cb)(void *cls, |
99 | struct GNUNET_DHTU_HashKey *key, | ||
100 | const char *address, | 89 | const char *address, |
101 | struct GNUNET_DHTU_Source *source, | 90 | struct GNUNET_DHTU_Source *source, |
102 | void **ctx); | 91 | void **ctx); |
@@ -128,20 +117,19 @@ struct GNUNET_DHTU_PluginEnvironment | |||
128 | * that peer. | 117 | * that peer. |
129 | * | 118 | * |
130 | * @param cls the closure | 119 | * @param cls the closure |
131 | * @param pk public key of the target, | ||
132 | * pointer will remain valid until @e disconnect_cb is called | ||
133 | * @para peer_id hash position of the peer, | ||
134 | * pointer will remain valid until @e disconnect_cb is called | ||
135 | * @param target handle to the target, | 120 | * @param target handle to the target, |
136 | * pointer will remain valid until @e disconnect_cb is called | 121 | * pointer will remain valid until @e disconnect_cb is called |
122 | * @para pid peer identity, | ||
123 | * pointer will remain valid until @e disconnect_cb is called | ||
137 | * @param[out] ctx storage space for DHT to use in association with this target | 124 | * @param[out] ctx storage space for DHT to use in association with this target |
138 | */ | 125 | */ |
139 | void | 126 | void |
140 | (*connect_cb)(void *cls, | 127 | (*connect_cb)(void *cls, |
141 | struct GNUNET_DHTU_Target *target, | 128 | struct GNUNET_DHTU_Target *target, |
142 | struct GNUNET_DHTU_HashKey *key, | 129 | const struct GNUNET_PeerIdentity *pid, |
143 | void **ctx); | 130 | void **ctx); |
144 | 131 | ||
132 | |||
145 | /** | 133 | /** |
146 | * Function to call when we disconnected from a peer and can henceforth | 134 | * Function to call when we disconnected from a peer and can henceforth |
147 | * cannot transmit to that peer anymore. | 135 | * cannot transmit to that peer anymore. |
@@ -185,10 +173,12 @@ struct GNUNET_DHTU_PluginFunctions | |||
185 | * Request creation of a session with a peer at the given @a address. | 173 | * Request creation of a session with a peer at the given @a address. |
186 | * | 174 | * |
187 | * @param cls closure (internal context for the plugin) | 175 | * @param cls closure (internal context for the plugin) |
188 | * @param address target address to connect to | 176 | * @param pid target identity of the peer to connect to |
177 | * @param address target address URI to connect to | ||
189 | */ | 178 | */ |
190 | void | 179 | void |
191 | (*try_connect) (void *cls, | 180 | (*try_connect) (void *cls, |
181 | const struct GNUNET_PeerIdentity *pid, | ||
192 | const char *address); | 182 | const char *address); |
193 | 183 | ||
194 | 184 | ||
@@ -205,7 +195,7 @@ struct GNUNET_DHTU_PluginFunctions | |||
205 | struct GNUNET_DHTU_Target *target); | 195 | struct GNUNET_DHTU_Target *target); |
206 | 196 | ||
207 | /** | 197 | /** |
208 | * Do no long request underlay to keep the connection alive. | 198 | * Do no longer request underlay to keep the connection alive. |
209 | * | 199 | * |
210 | * @param cls closure | 200 | * @param cls closure |
211 | * @param target connection to keep alive | 201 | * @param target connection to keep alive |
diff --git a/src/include/gnunet_fs_service.h b/src/include/gnunet_fs_service.h index 686035e2c..96936bad2 100644 --- a/src/include/gnunet_fs_service.h +++ b/src/include/gnunet_fs_service.h | |||
@@ -1729,7 +1729,7 @@ GNUNET_FS_file_information_get_id (struct GNUNET_FS_FileInformation *s); | |||
1729 | * @return "filename" field of the structure (can be NULL) | 1729 | * @return "filename" field of the structure (can be NULL) |
1730 | */ | 1730 | */ |
1731 | const char * | 1731 | const char * |
1732 | GNUNET_FS_file_information_get_filename (struct GNUNET_FS_FileInformation *s); | 1732 | GNUNET_FS_file_information_get_filename (const struct GNUNET_FS_FileInformation *s); |
1733 | 1733 | ||
1734 | 1734 | ||
1735 | /** | 1735 | /** |
diff --git a/src/include/gnunet_gns_service.h b/src/include/gnunet_gns_service.h index 3f6c9b9aa..5c06f8045 100644 --- a/src/include/gnunet_gns_service.h +++ b/src/include/gnunet_gns_service.h | |||
@@ -48,12 +48,6 @@ extern "C" { | |||
48 | 48 | ||
49 | 49 | ||
50 | /** | 50 | /** |
51 | * String we use to indicate an empty label (top-level | ||
52 | * entry in the zone). DNS uses "@", so do we. | ||
53 | */ | ||
54 | #define GNUNET_GNS_EMPTY_LABEL_AT "@" | ||
55 | |||
56 | /** | ||
57 | * Connection to the GNS service. | 51 | * Connection to the GNS service. |
58 | */ | 52 | */ |
59 | struct GNUNET_GNS_Handle; | 53 | struct GNUNET_GNS_Handle; |
diff --git a/src/include/gnunet_gnsrecord_lib.h b/src/include/gnunet_gnsrecord_lib.h index fdbac3cf5..51dd5972d 100644 --- a/src/include/gnunet_gnsrecord_lib.h +++ b/src/include/gnunet_gnsrecord_lib.h | |||
@@ -44,6 +44,12 @@ extern "C" { | |||
44 | #endif | 44 | #endif |
45 | 45 | ||
46 | /** | 46 | /** |
47 | * String we use to indicate an empty label (top-level | ||
48 | * entry in the zone). DNS uses "@", so do we. | ||
49 | */ | ||
50 | #define GNUNET_GNS_EMPTY_LABEL_AT "@" | ||
51 | |||
52 | /** | ||
47 | * Maximum size of a value that can be stored in a GNS block. | 53 | * Maximum size of a value that can be stored in a GNS block. |
48 | */ | 54 | */ |
49 | #define GNUNET_GNSRECORD_MAX_BLOCK_SIZE (63 * 1024) | 55 | #define GNUNET_GNSRECORD_MAX_BLOCK_SIZE (63 * 1024) |
@@ -299,8 +305,6 @@ struct GNUNET_GNSRECORD_ReverseRecord | |||
299 | /* followed by the name the delegator uses to refer to our namespace */ | 305 | /* followed by the name the delegator uses to refer to our namespace */ |
300 | }; | 306 | }; |
301 | 307 | ||
302 | GNUNET_NETWORK_STRUCT_END | ||
303 | |||
304 | 308 | ||
305 | /** | 309 | /** |
306 | * Process a records that were decrypted from a block. | 310 | * Process a records that were decrypted from a block. |
@@ -427,7 +431,8 @@ GNUNET_GNSRECORD_is_expired (const struct GNUNET_GNSRECORD_Data *rd); | |||
427 | 431 | ||
428 | 432 | ||
429 | /** | 433 | /** |
430 | * Normalize a UTF-8 string to UTF-8 NFC | 434 | * Normalize a UTF-8 string to a GNS name |
435 | * | ||
431 | * @param src source string | 436 | * @param src source string |
432 | * @return converted result | 437 | * @return converted result |
433 | */ | 438 | */ |
@@ -436,15 +441,6 @@ GNUNET_GNSRECORD_string_normalize (const char *src); | |||
436 | 441 | ||
437 | 442 | ||
438 | /** | 443 | /** |
439 | * Convert a UTF-8 string to UTF-8 lowercase | ||
440 | * @param src source string | ||
441 | * @return converted result | ||
442 | */ | ||
443 | char * | ||
444 | GNUNET_GNSRECORD_string_to_lowercase (const char *src); | ||
445 | |||
446 | |||
447 | /** | ||
448 | * Convert a zone to a string (for printing debug messages). | 444 | * Convert a zone to a string (for printing debug messages). |
449 | * This is one of the very few calls in the entire API that is | 445 | * This is one of the very few calls in the entire API that is |
450 | * NOT reentrant! | 446 | * NOT reentrant! |
@@ -616,11 +612,14 @@ GNUNET_GNSRECORD_records_cmp (const struct GNUNET_GNSRECORD_Data *a, | |||
616 | * | 612 | * |
617 | * @param rd_count number of records given in @a rd | 613 | * @param rd_count number of records given in @a rd |
618 | * @param rd array of records | 614 | * @param rd array of records |
615 | * @param min minimum expiration time | ||
619 | * @return absolute expiration time | 616 | * @return absolute expiration time |
620 | */ | 617 | */ |
621 | struct GNUNET_TIME_Absolute | 618 | struct GNUNET_TIME_Absolute |
622 | GNUNET_GNSRECORD_record_get_expiration_time ( | 619 | GNUNET_GNSRECORD_record_get_expiration_time (unsigned int rd_count, |
623 | unsigned int rd_count, const struct GNUNET_GNSRECORD_Data *rd); | 620 | const struct |
621 | GNUNET_GNSRECORD_Data *rd, | ||
622 | struct GNUNET_TIME_Absolute min); | ||
624 | 623 | ||
625 | 624 | ||
626 | /** | 625 | /** |
@@ -700,6 +699,77 @@ GNUNET_GNSRECORD_data_from_identity (const struct | |||
700 | enum GNUNET_GenericReturnValue | 699 | enum GNUNET_GenericReturnValue |
701 | GNUNET_GNSRECORD_is_zonekey_type (uint32_t type); | 700 | GNUNET_GNSRECORD_is_zonekey_type (uint32_t type); |
702 | 701 | ||
702 | /** | ||
703 | * Check if this type is a critical record. | ||
704 | * | ||
705 | * @param type the type to check | ||
706 | * @return GNUNET_YES if it is critical. | ||
707 | */ | ||
708 | enum GNUNET_GenericReturnValue | ||
709 | GNUNET_GNSRECORD_is_critical (uint32_t type); | ||
710 | |||
711 | /** | ||
712 | * Normalize namestore records: Check for consistency and | ||
713 | * expirations. Purge expired records. Returns a "clean" record set. | ||
714 | * Also returns the minimum expiration time this block should be | ||
715 | * published under. | ||
716 | * Also checks rules with respect to labels (e.g. no delegations under | ||
717 | * the empty label) | ||
718 | * | ||
719 | * @param label the label under which this set (supposed to be) stored. | ||
720 | * @param rd input records | ||
721 | * @param rd_count size of the @a rd and @a rd_public arrays | ||
722 | * @param rd_public where to write the converted records | ||
723 | * @param rd_public_count number of records written to @a rd_public | ||
724 | * @param min_expiry the minimum expiration of this set | ||
725 | * @param include_private GNUNET_YES if private records should be included. | ||
726 | * @param emsg the error message if something went wrong | ||
727 | * @return GNUNET_OK if set could be normalized and is consistent | ||
728 | */ | ||
729 | enum GNUNET_GenericReturnValue | ||
730 | GNUNET_GNSRECORD_normalize_record_set (const char *label, | ||
731 | const struct GNUNET_GNSRECORD_Data *rd, | ||
732 | unsigned int rd_count, | ||
733 | struct GNUNET_GNSRECORD_Data *rd_public, | ||
734 | unsigned int *rd_count_public, | ||
735 | struct GNUNET_TIME_Absolute *min_expiry, | ||
736 | int include_private, | ||
737 | char **emsg); | ||
738 | |||
739 | |||
740 | /** | ||
741 | * Convert namestore records from the internal format to that | ||
742 | * suitable for publication (removes private records). | ||
743 | * | ||
744 | * @param label the label under which this set is (supposed to be) published. | ||
745 | * @param rd input records | ||
746 | * @param rd_count size of the @a rd and @a rd_public arrays | ||
747 | * @param rd_public where to write the converted records | ||
748 | * @param rd_public_count number of records written to @a rd_public | ||
749 | * @param expiry the expiration of the block | ||
750 | * @param emsg the error message if something went wrong | ||
751 | * @return GNUNET_OK if set is consistent and can be exported | ||
752 | */ | ||
753 | enum GNUNET_GenericReturnValue | ||
754 | GNUNET_GNSRECORD_convert_records_for_export (const char *label, | ||
755 | const struct | ||
756 | GNUNET_GNSRECORD_Data *rd, | ||
757 | unsigned int rd_count, | ||
758 | struct GNUNET_GNSRECORD_Data * | ||
759 | rd_public, | ||
760 | unsigned int *rd_count_public, | ||
761 | struct GNUNET_TIME_Absolute *expiry, | ||
762 | char **emsg); | ||
763 | |||
764 | /** | ||
765 | * Check label for invalid characters. | ||
766 | * | ||
767 | * @param label the label to check | ||
768 | * @param emsg an error message (NULL if label is valid). Will be allocated. | ||
769 | * @return GNUNET_OK if label is valid. | ||
770 | */ | ||
771 | enum GNUNET_GenericReturnValue | ||
772 | GNUNET_GNSRECORD_label_check (const char*label, char **emsg); | ||
703 | 773 | ||
704 | #if 0 /* keep Emacsens' auto-indent happy */ | 774 | #if 0 /* keep Emacsens' auto-indent happy */ |
705 | { | 775 | { |
diff --git a/src/include/gnunet_gnsrecord_plugin.h b/src/include/gnunet_gnsrecord_plugin.h index aec22c3af..84b7c3c23 100644 --- a/src/include/gnunet_gnsrecord_plugin.h +++ b/src/include/gnunet_gnsrecord_plugin.h | |||
@@ -105,6 +105,18 @@ typedef const char * | |||
105 | (*GNUNET_GNSRECORD_NumberToTypenameFunction) (void *cls, | 105 | (*GNUNET_GNSRECORD_NumberToTypenameFunction) (void *cls, |
106 | uint32_t type); | 106 | uint32_t type); |
107 | 107 | ||
108 | /** | ||
109 | * Function called to check for critical records. | ||
110 | * | ||
111 | * @param cls closure | ||
112 | * @param type number of a type to check | ||
113 | * @return GNUNET_YES if critical, otherwise GNUNET_NO | ||
114 | */ | ||
115 | typedef enum GNUNET_GenericReturnValue | ||
116 | (*GNUNET_GNSRECORD_IsCriticalFunction) (void *cls, | ||
117 | uint32_t type); | ||
118 | |||
119 | |||
108 | 120 | ||
109 | /** | 121 | /** |
110 | * Each plugin is required to return a pointer to a struct of this | 122 | * Each plugin is required to return a pointer to a struct of this |
@@ -136,6 +148,11 @@ struct GNUNET_GNSRECORD_PluginFunctions | |||
136 | * Number to typename. | 148 | * Number to typename. |
137 | */ | 149 | */ |
138 | GNUNET_GNSRECORD_NumberToTypenameFunction number_to_typename; | 150 | GNUNET_GNSRECORD_NumberToTypenameFunction number_to_typename; |
151 | |||
152 | /** | ||
153 | * Is critical. | ||
154 | */ | ||
155 | GNUNET_GNSRECORD_IsCriticalFunction is_critical; | ||
139 | }; | 156 | }; |
140 | 157 | ||
141 | /** @} */ /* end of group */ | 158 | /** @} */ /* end of group */ |
diff --git a/src/include/gnunet_hello_uri_lib.h b/src/include/gnunet_hello_uri_lib.h new file mode 100644 index 000000000..c109a151a --- /dev/null +++ b/src/include/gnunet_hello_uri_lib.h | |||
@@ -0,0 +1,248 @@ | |||
1 | /* | ||
2 | This file is part of GNUnet. | ||
3 | Copyright (C) 2022 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 Christian Grothoff | ||
23 | * @file | ||
24 | * Helper library for handling HELLO URIs | ||
25 | * | ||
26 | * @defgroup hello_uri Hello_Uri library | ||
27 | * Helper library for handling HELLO URIs | ||
28 | * | ||
29 | * @{ | ||
30 | */ | ||
31 | |||
32 | #ifndef GNUNET_HELLO_URI_LIB_H | ||
33 | #define GNUNET_HELLO_URI_LIB_H | ||
34 | |||
35 | #ifdef __cplusplus | ||
36 | extern "C" { | ||
37 | #if 0 /* keep Emacsens' auto-indent happy */ | ||
38 | } | ||
39 | #endif | ||
40 | #endif | ||
41 | |||
42 | #include "gnunet_util_lib.h" | ||
43 | |||
44 | |||
45 | /** | ||
46 | * Context for building (or parsing) HELLO URIs. | ||
47 | */ | ||
48 | struct GNUNET_HELLO_Builder; | ||
49 | |||
50 | |||
51 | /** | ||
52 | * For how long are HELLO signatures valid? | ||
53 | */ | ||
54 | #define GNUNET_HELLO_ADDRESS_EXPIRATION GNUNET_TIME_relative_multiply ( \ | ||
55 | GNUNET_TIME_UNIT_DAYS, 2) | ||
56 | |||
57 | |||
58 | /** | ||
59 | * Allocate builder. | ||
60 | * | ||
61 | * @param pid peer the builder is for | ||
62 | * @return new builder | ||
63 | */ | ||
64 | struct GNUNET_HELLO_Builder * | ||
65 | GNUNET_HELLO_builder_new (const struct GNUNET_PeerIdentity *pid); | ||
66 | |||
67 | |||
68 | /** | ||
69 | * Release resources of a @a builder. | ||
70 | * | ||
71 | * @param[in] builder to free | ||
72 | */ | ||
73 | void | ||
74 | GNUNET_HELLO_builder_free (struct GNUNET_HELLO_Builder *builder); | ||
75 | |||
76 | |||
77 | /** | ||
78 | * Parse @a msg into builder. | ||
79 | * | ||
80 | * @param msg message to parse | ||
81 | * @return builder, NULL on failure | ||
82 | */ | ||
83 | struct GNUNET_HELLO_Builder * | ||
84 | GNUNET_HELLO_builder_from_msg (const struct GNUNET_MessageHeader *msg); | ||
85 | |||
86 | |||
87 | /** | ||
88 | * Parse @a block into builder. | ||
89 | * | ||
90 | * @param block DHT block to parse | ||
91 | * @param block_size number of bytes in @a block | ||
92 | * @return builder, NULL on failure | ||
93 | */ | ||
94 | struct GNUNET_HELLO_Builder * | ||
95 | GNUNET_HELLO_builder_from_block (const void *block, | ||
96 | size_t block_size); | ||
97 | |||
98 | |||
99 | /** | ||
100 | * Parse GNUnet HELLO @a url into builder. | ||
101 | * | ||
102 | * @param url URL to parse | ||
103 | * @return builder, NULL on failure | ||
104 | */ | ||
105 | struct GNUNET_HELLO_Builder * | ||
106 | GNUNET_HELLO_builder_from_url (const char *url); | ||
107 | |||
108 | |||
109 | /** | ||
110 | * Generate envelope with GNUnet HELLO message (including | ||
111 | * peer ID) from a @a builder | ||
112 | * | ||
113 | * @param builder builder to serialize | ||
114 | * @param priv private key to use to sign the result | ||
115 | * @return HELLO message matching @a builder | ||
116 | */ | ||
117 | struct GNUNET_MQ_Envelope * | ||
118 | GNUNET_HELLO_builder_to_env (const struct GNUNET_HELLO_Builder *builder, | ||
119 | const struct GNUNET_CRYPTO_EddsaPrivateKey *priv); | ||
120 | |||
121 | |||
122 | /** | ||
123 | * Generate DHT HELLO message (without peer ID) from a @a builder | ||
124 | * | ||
125 | * @param builder builder to serialize | ||
126 | * @param priv private key to use to sign the result | ||
127 | * @return HELLO message matching @a builder | ||
128 | */ | ||
129 | struct GNUNET_MessageHeader * | ||
130 | GNUNET_HELLO_builder_to_dht_hello_msg ( | ||
131 | const struct GNUNET_HELLO_Builder *builder, | ||
132 | const struct GNUNET_CRYPTO_EddsaPrivateKey *priv); | ||
133 | |||
134 | |||
135 | /** | ||
136 | * Generate GNUnet HELLO URI from a @a builder | ||
137 | * | ||
138 | * @param builder builder to serialize | ||
139 | * @param priv private key to use to sign the result | ||
140 | * @return hello URI | ||
141 | */ | ||
142 | char * | ||
143 | GNUNET_HELLO_builder_to_url (const struct GNUNET_HELLO_Builder *builder, | ||
144 | const struct GNUNET_CRYPTO_EddsaPrivateKey *priv); | ||
145 | |||
146 | /** | ||
147 | * Generate DHT block from a @a builder | ||
148 | * | ||
149 | * @param builder the builder to serialize | ||
150 | * @param priv private key to use to sign the result | ||
151 | * @param[out] block where to write the block, NULL to only calculate @a block_size | ||
152 | * @param[in,out] block_size input is number of bytes available in @a block, | ||
153 | * output is number of bytes needed in @a block | ||
154 | * @return #GNUNET_OK on success, #GNUNET_NO if @a block_size was too small | ||
155 | * or if @a block was NULL | ||
156 | */ | ||
157 | enum GNUNET_GenericReturnValue | ||
158 | GNUNET_HELLO_builder_to_block (const struct GNUNET_HELLO_Builder *builder, | ||
159 | const struct GNUNET_CRYPTO_EddsaPrivateKey *priv, | ||
160 | void *block, | ||
161 | size_t *block_size); | ||
162 | |||
163 | |||
164 | /** | ||
165 | * Add individual @a address to the @a builder | ||
166 | * | ||
167 | * @param[in,out] builder to update | ||
168 | * @param address address URI to add | ||
169 | * @return #GNUNET_OK on success, #GNUNET_NO if @a address was already | ||
170 | * in @a builder | ||
171 | */ | ||
172 | enum GNUNET_GenericReturnValue | ||
173 | GNUNET_HELLO_builder_add_address (struct GNUNET_HELLO_Builder *builder, | ||
174 | const char *address); | ||
175 | |||
176 | |||
177 | /** | ||
178 | * Remove individual @a address from the @a builder | ||
179 | * | ||
180 | * @param[in,out] builder to update | ||
181 | * @param address address URI to remove | ||
182 | * @return #GNUNET_OK on success, #GNUNET_NO if @a address was not | ||
183 | * in @a builder | ||
184 | */ | ||
185 | enum GNUNET_GenericReturnValue | ||
186 | GNUNET_HELLO_builder_del_address (struct GNUNET_HELLO_Builder *builder, | ||
187 | const char *address); | ||
188 | |||
189 | |||
190 | /** | ||
191 | * Callback function used to extract URIs from a builder. | ||
192 | * | ||
193 | * @param cls closure | ||
194 | * @param uri one of the URIs | ||
195 | */ | ||
196 | typedef void | ||
197 | (*GNUNET_HELLO_UriCallback) (void *cls, | ||
198 | const char *uri); | ||
199 | |||
200 | |||
201 | /** | ||
202 | * Iterate over URIs in a builder. | ||
203 | * | ||
204 | * @param builder builder to iterate over | ||
205 | * @param[out] pid set to the peer the @a builder is for | ||
206 | * @param uc callback invoked for each URI, can be NULL | ||
207 | * @param uc_cls closure for @a addrgen | ||
208 | */ | ||
209 | void | ||
210 | GNUNET_HELLO_builder_iterate (const struct GNUNET_HELLO_Builder *builder, | ||
211 | struct GNUNET_PeerIdentity *pid, | ||
212 | GNUNET_HELLO_UriCallback uc, | ||
213 | void *uc_cls); | ||
214 | |||
215 | |||
216 | /** | ||
217 | * Convert a DHT @a hello message to a HELLO @a block. | ||
218 | * | ||
219 | * @param hello the HELLO message | ||
220 | * @param pid peer that created the @a hello | ||
221 | * @param[out] block set to the HELLO block | ||
222 | * @param[out] block_size set to number of bytes in @a block | ||
223 | * @param[out] block_expiration set to expiration time of @a block | ||
224 | * @return #GNUNET_OK on success, | ||
225 | * #GNUNET_NO if the @a hello is expired (@a block is set!) | ||
226 | * #GNUNET_SYSERR if @a hello is invalid (@a block will be set to NULL) | ||
227 | */ | ||
228 | enum GNUNET_GenericReturnValue | ||
229 | GNUNET_HELLO_dht_msg_to_block (const struct GNUNET_MessageHeader *hello, | ||
230 | const struct GNUNET_PeerIdentity *pid, | ||
231 | void **block, | ||
232 | size_t *block_size, | ||
233 | struct GNUNET_TIME_Absolute *block_expiration); | ||
234 | |||
235 | |||
236 | #if 0 /* keep Emacsens' auto-indent happy */ | ||
237 | { | ||
238 | #endif | ||
239 | #ifdef __cplusplus | ||
240 | } | ||
241 | #endif | ||
242 | |||
243 | /* ifndef GNUNET_HELLO_URI_LIB_H */ | ||
244 | #endif | ||
245 | |||
246 | /** @} */ /* end of group */ | ||
247 | |||
248 | /* end of gnunet_hello_uri_lib.h */ | ||
diff --git a/src/include/gnunet_json_lib.h b/src/include/gnunet_json_lib.h index 7d101196c..6e73a3365 100644 --- a/src/include/gnunet_json_lib.h +++ b/src/include/gnunet_json_lib.h | |||
@@ -48,10 +48,10 @@ struct GNUNET_JSON_Specification; | |||
48 | * @return #GNUNET_SYSERR on error, | 48 | * @return #GNUNET_SYSERR on error, |
49 | * #GNUNET_OK on success | 49 | * #GNUNET_OK on success |
50 | */ | 50 | */ |
51 | typedef int | 51 | typedef enum GNUNET_GenericReturnValue |
52 | (*GNUNET_JSON_Parser) (void *cls, | 52 | (*GNUNET_JSON_Parser)(void *cls, |
53 | json_t *root, | 53 | json_t *root, |
54 | struct GNUNET_JSON_Specification *spec); | 54 | struct GNUNET_JSON_Specification *spec); |
55 | 55 | ||
56 | 56 | ||
57 | /** | 57 | /** |
diff --git a/src/include/gnunet_namestore_service.h b/src/include/gnunet_namestore_service.h index 2482b97a5..619b81aed 100644 --- a/src/include/gnunet_namestore_service.h +++ b/src/include/gnunet_namestore_service.h | |||
@@ -134,6 +134,39 @@ GNUNET_NAMESTORE_records_store (struct GNUNET_NAMESTORE_Handle *h, | |||
134 | GNUNET_NAMESTORE_ContinuationWithStatus cont, | 134 | GNUNET_NAMESTORE_ContinuationWithStatus cont, |
135 | void *cont_cls); | 135 | void *cont_cls); |
136 | 136 | ||
137 | /** | ||
138 | * Store an item in the namestore. If the item is already present, | ||
139 | * it is replaced with the new record. Use an empty array to | ||
140 | * remove all records under the given name. | ||
141 | * | ||
142 | * The continuation is called after the value has been stored in the | ||
143 | * database. Monitors may be notified asynchronously (basically with | ||
144 | * a buffer). However, if any monitor is consistently too slow to | ||
145 | * keep up with the changes, calling @a cont will be delayed until the | ||
146 | * monitors do keep up. | ||
147 | * | ||
148 | * @param h handle to the namestore | ||
149 | * @param pkey private key of the zone | ||
150 | * @param label name that is being mapped | ||
151 | * @param rd_count number of records in the 'rd' array | ||
152 | * @param rd array of records with data to store | ||
153 | * @param is_zonemaster update tombstones, do not process monitors | ||
154 | * @param cont continuation to call when done | ||
155 | * @param cont_cls closure for @a cont | ||
156 | * @return handle to abort the request | ||
157 | */ | ||
158 | struct GNUNET_NAMESTORE_QueueEntry * | ||
159 | GNUNET_NAMESTORE_records_store_ (struct GNUNET_NAMESTORE_Handle *h, | ||
160 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | ||
161 | const char *label, | ||
162 | unsigned int rd_count, | ||
163 | const struct GNUNET_GNSRECORD_Data *rd, | ||
164 | int is_zonemaster, | ||
165 | GNUNET_NAMESTORE_ContinuationWithStatus cont, | ||
166 | void *cont_cls); | ||
167 | |||
168 | |||
169 | |||
137 | 170 | ||
138 | /** | 171 | /** |
139 | * Process a record that was stored in the namestore. | 172 | * Process a record that was stored in the namestore. |
@@ -179,6 +212,61 @@ GNUNET_NAMESTORE_records_lookup (struct GNUNET_NAMESTORE_Handle *h, | |||
179 | 212 | ||
180 | 213 | ||
181 | /** | 214 | /** |
215 | * Open a record set for editing. | ||
216 | * Retrieves an exclusive lock on this set. | ||
217 | * Must be commited using @a GNUNET_NAMESTORE_records_commit | ||
218 | * | ||
219 | * @param h handle to the namestore | ||
220 | * @param pkey private key of the zone | ||
221 | * @param label name that is being mapped | ||
222 | * @param error_cb function to call on error (i.e. disconnect or unable to get lock) | ||
223 | * the handle is afterwards invalid | ||
224 | * @param error_cb_cls closure for @a error_cb | ||
225 | * @param rm function to call with the result (with 0 records if we don't have that label) | ||
226 | * @param rm_cls closure for @a rm | ||
227 | * @return handle to abort the request | ||
228 | */ | ||
229 | struct GNUNET_NAMESTORE_QueueEntry * | ||
230 | GNUNET_NAMESTORE_records_open (struct GNUNET_NAMESTORE_Handle *h, | ||
231 | const struct | ||
232 | GNUNET_IDENTITY_PrivateKey *pkey, | ||
233 | const char *label, | ||
234 | GNUNET_SCHEDULER_TaskCallback error_cb, | ||
235 | void *error_cb_cls, | ||
236 | GNUNET_NAMESTORE_RecordMonitor rm, | ||
237 | void *rm_cls); | ||
238 | |||
239 | /** | ||
240 | * Commit the record set to the namestore. | ||
241 | * Releases the lock on the record set. | ||
242 | * Use an empty array to | ||
243 | * remove all records under the given name. | ||
244 | * | ||
245 | * The continuation is called after the value has been stored in the | ||
246 | * database. Monitors may be notified asynchronously (basically with | ||
247 | * a buffer). However, if any monitor is consistently too slow to | ||
248 | * keep up with the changes, calling @a cont will be delayed until the | ||
249 | * monitors do keep up. | ||
250 | * | ||
251 | * @param h handle to the namestore | ||
252 | * @param pkey private key of the zone | ||
253 | * @param label name that is being mapped | ||
254 | * @param rd_count number of records in the 'rd' array | ||
255 | * @param rd array of records with data to store | ||
256 | * @param cont continuation to call when done | ||
257 | * @param cont_cls closure for @a cont | ||
258 | * @return handle to abort the request | ||
259 | */ | ||
260 | struct GNUNET_NAMESTORE_QueueEntry * | ||
261 | GNUNET_NAMESTORE_records_commit (struct GNUNET_NAMESTORE_Handle *h, | ||
262 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | ||
263 | const char *label, | ||
264 | unsigned int rd_count, | ||
265 | const struct GNUNET_GNSRECORD_Data *rd, | ||
266 | GNUNET_NAMESTORE_ContinuationWithStatus cont, | ||
267 | void *cont_cls); | ||
268 | |||
269 | /** | ||
182 | * Look for an existing PKEY delegation record for a given public key. | 270 | * Look for an existing PKEY delegation record for a given public key. |
183 | * Returns at most one result to the processor. | 271 | * Returns at most one result to the processor. |
184 | * | 272 | * |
diff --git a/src/include/gnunet_protocols.h b/src/include/gnunet_protocols.h index 9e278eb92..f2892e125 100644 --- a/src/include/gnunet_protocols.h +++ b/src/include/gnunet_protocols.h | |||
@@ -153,10 +153,10 @@ extern "C" { | |||
153 | ******************************************************************************/ | 153 | ******************************************************************************/ |
154 | 154 | ||
155 | /** | 155 | /** |
156 | * Previously used for HELLO messages used for communicating peer addresses. | 156 | * Latest HELLO messages used for communicating peer addresses. |
157 | * Managed by libgnunethello. | 157 | * Managed by libgnunethello. |
158 | */ | 158 | */ |
159 | #define GNUNET_MESSAGE_TYPE_HELLO_LEGACY 16 | 159 | #define GNUNET_MESSAGE_TYPE_HELLO_URI 16 |
160 | 160 | ||
161 | /** | 161 | /** |
162 | * HELLO message with friend only flag used for communicating peer addresses. | 162 | * HELLO message with friend only flag used for communicating peer addresses. |
@@ -660,13 +660,26 @@ extern "C" { | |||
660 | #define GNUNET_MESSAGE_TYPE_DHT_CLIENT_GET_RESULTS_KNOWN 156 | 660 | #define GNUNET_MESSAGE_TYPE_DHT_CLIENT_GET_RESULTS_KNOWN 156 |
661 | 661 | ||
662 | /** | 662 | /** |
663 | * DHT wants to use CORE to transmit data. | 663 | * HELLO advertising a neighbours addresses. |
664 | */ | 664 | */ |
665 | #define GNUNET_MESSAGE_TYPE_DHT_CORE 143 | 665 | #define GNUNET_MESSAGE_TYPE_DHT_P2P_HELLO 157 |
666 | 666 | ||
667 | /** | 667 | /** |
668 | * Further X-VINE DHT messages continued from 880 | 668 | * Encapsulation of DHT messages in CORE service. |
669 | */ | 669 | */ |
670 | #define GNUNET_MESSAGE_TYPE_DHT_CORE 158 | ||
671 | |||
672 | /** | ||
673 | * HELLO URL send between client and service (in | ||
674 | * either direction). | ||
675 | */ | ||
676 | #define GNUNET_MESSAGE_TYPE_DHT_CLIENT_HELLO_URL 159 | ||
677 | |||
678 | /** | ||
679 | * Client requests DHT service's HELLO URL. | ||
680 | */ | ||
681 | #define GNUNET_MESSAGE_TYPE_DHT_CLIENT_HELLO_GET 161 | ||
682 | |||
670 | 683 | ||
671 | /******************************************************************************* | 684 | /******************************************************************************* |
672 | * HOSTLIST message types | 685 | * HOSTLIST message types |
@@ -1796,7 +1809,6 @@ extern "C" { | |||
1796 | #define GNUNET_MESSAGE_TYPE_SETU_P2P_SEND_FULL 710 | 1809 | #define GNUNET_MESSAGE_TYPE_SETU_P2P_SEND_FULL 710 |
1797 | 1810 | ||
1798 | 1811 | ||
1799 | |||
1800 | /******************************************************************************* | 1812 | /******************************************************************************* |
1801 | * SETI message types | 1813 | * SETI message types |
1802 | ******************************************************************************/ | 1814 | ******************************************************************************/ |
diff --git a/src/include/gnunet_strings_lib.h b/src/include/gnunet_strings_lib.h index 9dd2f733e..bb8577b7a 100644 --- a/src/include/gnunet_strings_lib.h +++ b/src/include/gnunet_strings_lib.h | |||
@@ -159,14 +159,12 @@ GNUNET_STRINGS_to_utf8 (const char *input, | |||
159 | 159 | ||
160 | /** | 160 | /** |
161 | * Normalize the utf-8 input string to NFC. | 161 | * Normalize the utf-8 input string to NFC. |
162 | * Output needs to be allocated appropriately. | ||
163 | * | 162 | * |
164 | * @param input input string | 163 | * @param input input string |
165 | * @param output output buffer | 164 | * @return result (freshly allocated) or NULL on error. |
166 | */ | 165 | */ |
167 | void | 166 | char* |
168 | GNUNET_STRINGS_utf8_normalize (const char *input, | 167 | GNUNET_STRINGS_utf8_normalize (const char *input); |
169 | char *output); | ||
170 | 168 | ||
171 | 169 | ||
172 | /** | 170 | /** |
@@ -192,8 +190,9 @@ GNUNET_STRINGS_from_utf8 (const char *input, | |||
192 | * | 190 | * |
193 | * @param input input string | 191 | * @param input input string |
194 | * @param output output buffer | 192 | * @param output output buffer |
193 | * @return GNUNET_OK on success | ||
195 | */ | 194 | */ |
196 | void | 195 | enum GNUNET_GenericReturnValue |
197 | GNUNET_STRINGS_utf8_tolower (const char *input, | 196 | GNUNET_STRINGS_utf8_tolower (const char *input, |
198 | char *output); | 197 | char *output); |
199 | 198 | ||
@@ -204,8 +203,9 @@ GNUNET_STRINGS_utf8_tolower (const char *input, | |||
204 | * | 203 | * |
205 | * @param input input string | 204 | * @param input input string |
206 | * @param output output buffer | 205 | * @param output output buffer |
206 | * @return GNUNET_OK on success | ||
207 | */ | 207 | */ |
208 | void | 208 | enum GNUNET_GenericReturnValue |
209 | GNUNET_STRINGS_utf8_toupper (const char *input, | 209 | GNUNET_STRINGS_utf8_toupper (const char *input, |
210 | char *output); | 210 | char *output); |
211 | 211 | ||
@@ -458,7 +458,7 @@ GNUNET_STRINGS_base64url_decode (const char *data, | |||
458 | * | 458 | * |
459 | * @param data the data to encode | 459 | * @param data the data to encode |
460 | * @param len the length of the input | 460 | * @param len the length of the input |
461 | * @param output where to write the output (*output should be NULL, | 461 | * @param[out] out where to write the output (*output should be NULL, |
462 | * is allocated) | 462 | * is allocated) |
463 | * @return the size of the output | 463 | * @return the size of the output |
464 | */ | 464 | */ |
diff --git a/src/include/gnunet_time_lib.h b/src/include/gnunet_time_lib.h index b14439462..96413c3cc 100644 --- a/src/include/gnunet_time_lib.h +++ b/src/include/gnunet_time_lib.h | |||
@@ -762,11 +762,22 @@ GNUNET_TIME_absolute_from_s (uint64_t s_after_epoch); | |||
762 | * | 762 | * |
763 | * @param s_after_epoch seconds after epoch to convert | 763 | * @param s_after_epoch seconds after epoch to convert |
764 | * @return converted time value | 764 | * @return converted time value |
765 | */struct GNUNET_TIME_Timestamp | 765 | */ |
766 | struct GNUNET_TIME_Timestamp | ||
766 | GNUNET_TIME_timestamp_from_s (uint64_t s_after_epoch); | 767 | GNUNET_TIME_timestamp_from_s (uint64_t s_after_epoch); |
767 | 768 | ||
768 | 769 | ||
769 | /** | 770 | /** |
771 | * Convert timestamp to number of seconds after the UNIX epoch. | ||
772 | * | ||
773 | * @param ts timestamp to convert | ||
774 | * @return converted time value | ||
775 | */ | ||
776 | uint64_t | ||
777 | GNUNET_TIME_timestamp_to_s (struct GNUNET_TIME_Timestamp ts); | ||
778 | |||
779 | |||
780 | /** | ||
770 | * Convert absolute time from network byte order. | 781 | * Convert absolute time from network byte order. |
771 | * | 782 | * |
772 | * @param a time to convert | 783 | * @param a time to convert |
diff --git a/src/json/json_pack.c b/src/json/json_pack.c index 296f56104..cc1ca3e97 100644 --- a/src/json/json_pack.c +++ b/src/json/json_pack.c | |||
@@ -31,6 +31,12 @@ GNUNET_JSON_pack_ (struct GNUNET_JSON_PackSpec spec[]) | |||
31 | { | 31 | { |
32 | json_t *ret; | 32 | json_t *ret; |
33 | 33 | ||
34 | if (NULL == spec[0].field_name) | ||
35 | { | ||
36 | ret = spec[0].object; | ||
37 | spec[0].object = NULL; | ||
38 | return ret; | ||
39 | } | ||
34 | ret = json_object (); | 40 | ret = json_object (); |
35 | GNUNET_assert (NULL != ret); | 41 | GNUNET_assert (NULL != ret); |
36 | for (unsigned int i = 0; | 42 | for (unsigned int i = 0; |
diff --git a/src/messenger/gnunet-service-messenger.c b/src/messenger/gnunet-service-messenger.c index 546f4c0d2..31bffec18 100644 --- a/src/messenger/gnunet-service-messenger.c +++ b/src/messenger/gnunet-service-messenger.c | |||
@@ -170,9 +170,7 @@ handle_room_close (void *cls, | |||
170 | 170 | ||
171 | if (GNUNET_YES == close_handle_room (msg_client->handle, &(msg->key))) | 171 | if (GNUNET_YES == close_handle_room (msg_client->handle, &(msg->key))) |
172 | { | 172 | { |
173 | const struct GNUNET_ShortHashCode *member_id = get_handle_member_id (msg_client->handle, &(msg->key)); | 173 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Closing room succeeded: %s\n", GNUNET_h2s (&(msg->key))); |
174 | |||
175 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Closing room with member id: %s\n", GNUNET_sh2s (member_id)); | ||
176 | 174 | ||
177 | struct GNUNET_MESSENGER_RoomMessage *response; | 175 | struct GNUNET_MESSENGER_RoomMessage *response; |
178 | struct GNUNET_MQ_Envelope *env; | 176 | struct GNUNET_MQ_Envelope *env; |
diff --git a/src/messenger/gnunet-service-messenger_member_session.c b/src/messenger/gnunet-service-messenger_member_session.c index 846dbbe2b..6bd1d24b8 100644 --- a/src/messenger/gnunet-service-messenger_member_session.c +++ b/src/messenger/gnunet-service-messenger_member_session.c | |||
@@ -84,6 +84,9 @@ check_member_session_completion (struct GNUNET_MESSENGER_MemberSession *session) | |||
84 | { | 84 | { |
85 | GNUNET_assert (session); | 85 | GNUNET_assert (session); |
86 | 86 | ||
87 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Check session history (%s) for completion.\n", | ||
88 | GNUNET_sh2s(get_member_session_id(session))); | ||
89 | |||
87 | if (!session->messages.tail) | 90 | if (!session->messages.tail) |
88 | { | 91 | { |
89 | session->completed = GNUNET_YES; | 92 | session->completed = GNUNET_YES; |
@@ -142,7 +145,10 @@ check_member_session_completion (struct GNUNET_MESSENGER_MemberSession *session) | |||
142 | completion: | 145 | completion: |
143 | if (GNUNET_YES == is_member_session_completed(session)) | 146 | if (GNUNET_YES == is_member_session_completed(session)) |
144 | { | 147 | { |
145 | GNUNET_CONTAINER_multihashmap_destroy (session->history); | 148 | GNUNET_log(GNUNET_ERROR_TYPE_DEBUG, "Completed session history (%s)\n", |
149 | GNUNET_sh2s(get_member_session_id(session))); | ||
150 | |||
151 | GNUNET_CONTAINER_multihashmap_clear (session->history); | ||
146 | 152 | ||
147 | struct GNUNET_MESSENGER_ContactStore *store = get_member_contact_store(session->member->store); | 153 | struct GNUNET_MESSENGER_ContactStore *store = get_member_contact_store(session->member->store); |
148 | 154 | ||
diff --git a/src/messenger/gnunet-service-messenger_room.c b/src/messenger/gnunet-service-messenger_room.c index 7f2fd0ca6..7a20d2191 100644 --- a/src/messenger/gnunet-service-messenger_room.c +++ b/src/messenger/gnunet-service-messenger_room.c | |||
@@ -92,14 +92,14 @@ static void | |||
92 | handle_room_messages (struct GNUNET_MESSENGER_SrvRoom *room); | 92 | handle_room_messages (struct GNUNET_MESSENGER_SrvRoom *room); |
93 | 93 | ||
94 | void | 94 | void |
95 | destroy_room (struct GNUNET_MESSENGER_SrvRoom *room) | 95 | destroy_room (struct GNUNET_MESSENGER_SrvRoom *room, |
96 | int deletion) | ||
96 | { | 97 | { |
97 | GNUNET_assert(room); | 98 | GNUNET_assert(room); |
98 | 99 | ||
99 | if (room->idle) | 100 | if (room->idle) |
100 | { | 101 | { |
101 | GNUNET_SCHEDULER_cancel (room->idle); | 102 | GNUNET_SCHEDULER_cancel (room->idle); |
102 | |||
103 | room->idle = NULL; | 103 | room->idle = NULL; |
104 | } | 104 | } |
105 | 105 | ||
@@ -107,18 +107,22 @@ destroy_room (struct GNUNET_MESSENGER_SrvRoom *room) | |||
107 | GNUNET_CADET_close_port (room->port); | 107 | GNUNET_CADET_close_port (room->port); |
108 | 108 | ||
109 | GNUNET_CONTAINER_multipeermap_iterate (room->tunnels, iterate_destroy_tunnels, NULL); | 109 | GNUNET_CONTAINER_multipeermap_iterate (room->tunnels, iterate_destroy_tunnels, NULL); |
110 | |||
111 | handle_room_messages (room); | 110 | handle_room_messages (room); |
112 | 111 | ||
113 | if (room->service->dir) | 112 | if (!(room->service->dir)) |
113 | goto skip_saving; | ||
114 | |||
115 | if (GNUNET_YES == deletion) | ||
116 | remove_room (room); | ||
117 | else | ||
114 | save_room (room); | 118 | save_room (room); |
115 | 119 | ||
120 | skip_saving: | ||
116 | clear_member_store (get_room_member_store(room)); | 121 | clear_member_store (get_room_member_store(room)); |
117 | clear_message_store (get_room_message_store(room)); | 122 | clear_message_store (get_room_message_store(room)); |
118 | clear_operation_store(get_room_operation_store(room)); | 123 | clear_operation_store(get_room_operation_store(room)); |
119 | 124 | ||
120 | GNUNET_CONTAINER_multipeermap_destroy (room->tunnels); | 125 | GNUNET_CONTAINER_multipeermap_destroy (room->tunnels); |
121 | |||
122 | clear_list_tunnels (&(room->basement)); | 126 | clear_list_tunnels (&(room->basement)); |
123 | clear_message_state(&(room->state)); | 127 | clear_message_state(&(room->state)); |
124 | 128 | ||
@@ -1221,6 +1225,20 @@ save_room (struct GNUNET_MESSENGER_SrvRoom *room) | |||
1221 | GNUNET_free(room_dir); | 1225 | GNUNET_free(room_dir); |
1222 | } | 1226 | } |
1223 | 1227 | ||
1228 | void | ||
1229 | remove_room (struct GNUNET_MESSENGER_SrvRoom *room) | ||
1230 | { | ||
1231 | GNUNET_assert(room); | ||
1232 | |||
1233 | char *room_dir; | ||
1234 | get_room_data_subdir (room, &room_dir); | ||
1235 | |||
1236 | if (GNUNET_YES == GNUNET_DISK_directory_test (room_dir, GNUNET_YES)) | ||
1237 | GNUNET_DISK_directory_remove(room_dir); | ||
1238 | |||
1239 | GNUNET_free(room_dir); | ||
1240 | } | ||
1241 | |||
1224 | static void | 1242 | static void |
1225 | remove_room_member_session (struct GNUNET_MESSENGER_SrvRoom *room, | 1243 | remove_room_member_session (struct GNUNET_MESSENGER_SrvRoom *room, |
1226 | struct GNUNET_MESSENGER_MemberSession *session) | 1244 | struct GNUNET_MESSENGER_MemberSession *session) |
diff --git a/src/messenger/gnunet-service-messenger_room.h b/src/messenger/gnunet-service-messenger_room.h index 4b3811104..58edc4121 100644 --- a/src/messenger/gnunet-service-messenger_room.h +++ b/src/messenger/gnunet-service-messenger_room.h | |||
@@ -95,10 +95,15 @@ create_room (struct GNUNET_MESSENGER_SrvHandle *handle, | |||
95 | /** | 95 | /** |
96 | * Destroys a room and frees its memory fully. | 96 | * Destroys a room and frees its memory fully. |
97 | * | 97 | * |
98 | * The <i>deletion</i> flag should only be set to #GNUNET_YES if the | ||
99 | * room gets dropped by the service, otherwise #GNUNET_NO. | ||
100 | * | ||
98 | * @param[in/out] room Room | 101 | * @param[in/out] room Room |
102 | * @param[in] deletion Flag to indicate context of destruction | ||
99 | */ | 103 | */ |
100 | void | 104 | void |
101 | destroy_room (struct GNUNET_MESSENGER_SrvRoom *room); | 105 | destroy_room (struct GNUNET_MESSENGER_SrvRoom *room, |
106 | int deletion); | ||
102 | 107 | ||
103 | /** | 108 | /** |
104 | * Returns the used member store of a given <i>room</i>. | 109 | * Returns the used member store of a given <i>room</i>. |
@@ -364,4 +369,12 @@ load_room (struct GNUNET_MESSENGER_SrvRoom *room); | |||
364 | void | 369 | void |
365 | save_room (struct GNUNET_MESSENGER_SrvRoom *room); | 370 | save_room (struct GNUNET_MESSENGER_SrvRoom *room); |
366 | 371 | ||
372 | /** | ||
373 | * Removes the configuration for a given <i>room</i> of a service. | ||
374 | * | ||
375 | * @param[in] room Room | ||
376 | */ | ||
377 | void | ||
378 | remove_room (struct GNUNET_MESSENGER_SrvRoom *room); | ||
379 | |||
367 | #endif //GNUNET_SERVICE_MESSENGER_ROOM_H | 380 | #endif //GNUNET_SERVICE_MESSENGER_ROOM_H |
diff --git a/src/messenger/gnunet-service-messenger_service.c b/src/messenger/gnunet-service-messenger_service.c index b53b72af8..83d7632d8 100644 --- a/src/messenger/gnunet-service-messenger_service.c +++ b/src/messenger/gnunet-service-messenger_service.c | |||
@@ -94,7 +94,7 @@ iterate_destroy_rooms (void *cls, | |||
94 | void *value) | 94 | void *value) |
95 | { | 95 | { |
96 | struct GNUNET_MESSENGER_SrvRoom *room = value; | 96 | struct GNUNET_MESSENGER_SrvRoom *room = value; |
97 | destroy_room (room); | 97 | destroy_room (room, GNUNET_NO); |
98 | return GNUNET_YES; | 98 | return GNUNET_YES; |
99 | } | 99 | } |
100 | 100 | ||
@@ -220,7 +220,7 @@ open_service_room (struct GNUNET_MESSENGER_Service *service, | |||
220 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST))) | 220 | GNUNET_CONTAINER_MULTIHASHMAPOPTION_UNIQUE_FAST))) |
221 | return GNUNET_YES; | 221 | return GNUNET_YES; |
222 | 222 | ||
223 | destroy_room (room); | 223 | destroy_room (room, GNUNET_YES); |
224 | return GNUNET_NO; | 224 | return GNUNET_NO; |
225 | } | 225 | } |
226 | 226 | ||
@@ -253,7 +253,7 @@ entry_service_room (struct GNUNET_MESSENGER_Service *service, | |||
253 | } | 253 | } |
254 | else | 254 | else |
255 | { | 255 | { |
256 | destroy_room (room); | 256 | destroy_room (room, GNUNET_YES); |
257 | return GNUNET_NO; | 257 | return GNUNET_NO; |
258 | } | 258 | } |
259 | 259 | ||
@@ -287,7 +287,7 @@ close_service_room (struct GNUNET_MESSENGER_Service *service, | |||
287 | { | 287 | { |
288 | if (GNUNET_OK == GNUNET_CONTAINER_multihashmap_remove (service->rooms, key, room)) | 288 | if (GNUNET_OK == GNUNET_CONTAINER_multihashmap_remove (service->rooms, key, room)) |
289 | { | 289 | { |
290 | destroy_room (room); | 290 | destroy_room (room, GNUNET_YES); |
291 | return GNUNET_YES; | 291 | return GNUNET_YES; |
292 | } | 292 | } |
293 | else | 293 | else |
diff --git a/src/messenger/messenger.conf.in b/src/messenger/messenger.conf.in index 6b54550ea..ef0544681 100644 --- a/src/messenger/messenger.conf.in +++ b/src/messenger/messenger.conf.in | |||
@@ -1,12 +1,12 @@ | |||
1 | [messenger] | 1 | [messenger] |
2 | START_ON_DEMAND = YES | 2 | START_ON_DEMAND = @START_ON_DEMAND@ |
3 | RUN_PER_USER = YES | 3 | RUN_PER_USER = YES |
4 | PORT = 2097 | 4 | @JAVAPORT@PORT = 2125 |
5 | HOSTNAME = localhost | 5 | HOSTNAME = localhost |
6 | BINARY = gnunet-service-messenger | 6 | BINARY = gnunet-service-messenger |
7 | ACCEPT_FROM = 127.0.0.1; | 7 | ACCEPT_FROM = 127.0.0.1; |
8 | ACCEPT_FROM6 = ::1; | 8 | ACCEPT_FROM6 = ::1; |
9 | UNIXPATH = $GNUNET_RUNTIME_DIR/gnunet-service-messenger.sock | 9 | UNIXPATH = $GNUNET_USER_RUNTIME_DIR/gnunet-service-messenger.sock |
10 | UNIX_MATCH_UID = NO | 10 | UNIX_MATCH_UID = NO |
11 | UNIX_MATCH_GID = YES | 11 | UNIX_MATCH_GID = YES |
12 | 12 | ||
diff --git a/src/messenger/messenger_api_message.c b/src/messenger/messenger_api_message.c index 496c98dbf..3814def70 100644 --- a/src/messenger/messenger_api_message.c +++ b/src/messenger/messenger_api_message.c | |||
@@ -219,6 +219,10 @@ get_message_body_kind_size (enum GNUNET_MESSENGER_MessageKind kind) | |||
219 | case GNUNET_MESSENGER_KIND_PRIVATE: | 219 | case GNUNET_MESSENGER_KIND_PRIVATE: |
220 | length += member_size(struct GNUNET_MESSENGER_Message, body.privacy.key); | 220 | length += member_size(struct GNUNET_MESSENGER_Message, body.privacy.key); |
221 | break; | 221 | break; |
222 | case GNUNET_MESSENGER_KIND_DELETE: | ||
223 | length += member_size(struct GNUNET_MESSENGER_Message, body.deletion.hash); | ||
224 | length += member_size(struct GNUNET_MESSENGER_Message, body.deletion.delay); | ||
225 | break; | ||
222 | default: | 226 | default: |
223 | break; | 227 | break; |
224 | } | 228 | } |
@@ -445,6 +449,10 @@ encode_message_body (enum GNUNET_MESSENGER_MessageKind kind, | |||
445 | encode_step(buffer, offset, &(body->privacy.key)); | 449 | encode_step(buffer, offset, &(body->privacy.key)); |
446 | encode_step_ext(buffer, offset, body->privacy.data, min(length - offset, body->privacy.length)); | 450 | encode_step_ext(buffer, offset, body->privacy.data, min(length - offset, body->privacy.length)); |
447 | break; | 451 | break; |
452 | case GNUNET_MESSENGER_KIND_DELETE: | ||
453 | encode_step(buffer, offset, &(body->deletion.hash)); | ||
454 | encode_step(buffer, offset, &(body->deletion.delay)); | ||
455 | break; | ||
448 | default: | 456 | default: |
449 | break; | 457 | break; |
450 | } | 458 | } |
@@ -616,6 +624,10 @@ decode_message_body (enum GNUNET_MESSENGER_MessageKind *kind, | |||
616 | body->privacy.length = (length - offset); | 624 | body->privacy.length = (length - offset); |
617 | decode_step_malloc(buffer, offset, body->privacy.data, length - offset, 0); | 625 | decode_step_malloc(buffer, offset, body->privacy.data, length - offset, 0); |
618 | break; | 626 | break; |
627 | case GNUNET_MESSENGER_KIND_DELETE: | ||
628 | decode_step(buffer, offset, &(body->deletion.hash)); | ||
629 | decode_step(buffer, offset, &(body->deletion.delay)); | ||
630 | break; | ||
619 | default: | 631 | default: |
620 | *kind = GNUNET_MESSENGER_KIND_UNKNOWN; | 632 | *kind = GNUNET_MESSENGER_KIND_UNKNOWN; |
621 | break; | 633 | break; |
diff --git a/src/namecache/test_namecache_api_cache_block.c b/src/namecache/test_namecache_api_cache_block.c index 310c4de42..6188fb014 100644 --- a/src/namecache/test_namecache_api_cache_block.c +++ b/src/namecache/test_namecache_api_cache_block.c | |||
@@ -187,9 +187,10 @@ run (void *cls, | |||
187 | rd.data = GNUNET_malloc (TEST_RECORD_DATALEN); | 187 | rd.data = GNUNET_malloc (TEST_RECORD_DATALEN); |
188 | rd.flags = 0; | 188 | rd.flags = 0; |
189 | memset ((char *) rd.data, 'a', TEST_RECORD_DATALEN); | 189 | memset ((char *) rd.data, 'a', TEST_RECORD_DATALEN); |
190 | block = GNUNET_GNSRECORD_block_create (&privkey, | 190 | GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_block_create (&privkey, |
191 | GNUNET_TIME_UNIT_FOREVER_ABS, | 191 | GNUNET_TIME_UNIT_FOREVER_ABS, |
192 | name, &rd, 1); | 192 | name, &rd, 1, |
193 | &block)); | ||
193 | if (NULL == block) | 194 | if (NULL == block) |
194 | { | 195 | { |
195 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | 196 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, |
diff --git a/src/namestore/Makefile.am b/src/namestore/Makefile.am index 51708dd67..2441b864a 100644 --- a/src/namestore/Makefile.am +++ b/src/namestore/Makefile.am | |||
@@ -39,6 +39,7 @@ if HAVE_SQLITE | |||
39 | SQLITE_PLUGIN = libgnunet_plugin_namestore_sqlite.la | 39 | SQLITE_PLUGIN = libgnunet_plugin_namestore_sqlite.la |
40 | SQLITE_TESTS = test_plugin_namestore_sqlite \ | 40 | SQLITE_TESTS = test_plugin_namestore_sqlite \ |
41 | test_namestore_api_store_sqlite \ | 41 | test_namestore_api_store_sqlite \ |
42 | test_namestore_api_store_locking_sqlite \ | ||
42 | test_namestore_api_store_update_sqlite \ | 43 | test_namestore_api_store_update_sqlite \ |
43 | test_namestore_api_zone_iteration_sqlite \ | 44 | test_namestore_api_zone_iteration_sqlite \ |
44 | test_namestore_api_remove_sqlite \ | 45 | test_namestore_api_remove_sqlite \ |
@@ -249,6 +250,16 @@ test_namestore_api_store_sqlite_LDADD = \ | |||
249 | $(top_builddir)/src/identity/libgnunetidentity.la \ | 250 | $(top_builddir)/src/identity/libgnunetidentity.la \ |
250 | libgnunetnamestore.la | 251 | libgnunetnamestore.la |
251 | 252 | ||
253 | test_namestore_api_store_locking_sqlite_SOURCES = \ | ||
254 | test_namestore_api_store_locking.c | ||
255 | test_namestore_api_store_locking_sqlite_LDADD = \ | ||
256 | $(top_builddir)/src/testing/libgnunettesting.la \ | ||
257 | $(top_builddir)/src/util/libgnunetutil.la \ | ||
258 | $(top_builddir)/src/gnsrecord/libgnunetgnsrecord.la \ | ||
259 | $(top_builddir)/src/identity/libgnunetidentity.la \ | ||
260 | libgnunetnamestore.la | ||
261 | |||
262 | |||
252 | test_namestore_api_store_postgres_SOURCES = \ | 263 | test_namestore_api_store_postgres_SOURCES = \ |
253 | test_namestore_api_store.c | 264 | test_namestore_api_store.c |
254 | test_namestore_api_store_postgres_LDADD = \ | 265 | test_namestore_api_store_postgres_LDADD = \ |
diff --git a/src/namestore/gnunet-namestore.c b/src/namestore/gnunet-namestore.c index 852d99608..af40f2dbe 100644 --- a/src/namestore/gnunet-namestore.c +++ b/src/namestore/gnunet-namestore.c | |||
@@ -33,6 +33,12 @@ | |||
33 | #include <gnunet_gns_service.h> | 33 | #include <gnunet_gns_service.h> |
34 | #include <gnunet_namestore_service.h> | 34 | #include <gnunet_namestore_service.h> |
35 | 35 | ||
36 | /** | ||
37 | * The upper bound for the zone iteration interval | ||
38 | * (per record). | ||
39 | */ | ||
40 | #define WARN_RELATIVE_EXPIRATION_LIMIT GNUNET_TIME_relative_multiply ( \ | ||
41 | GNUNET_TIME_UNIT_MINUTES, 15) | ||
36 | 42 | ||
37 | /** | 43 | /** |
38 | * Entry in record set for bulk processing. | 44 | * Entry in record set for bulk processing. |
@@ -430,6 +436,8 @@ display_record (const char *rname, | |||
430 | if ((GNUNET_GNSRECORD_TYPE_NICK == rd[i].record_type) && | 436 | if ((GNUNET_GNSRECORD_TYPE_NICK == rd[i].record_type) && |
431 | (0 != strcmp (rname, GNUNET_GNS_EMPTY_LABEL_AT))) | 437 | (0 != strcmp (rname, GNUNET_GNS_EMPTY_LABEL_AT))) |
432 | continue; | 438 | continue; |
439 | if (GNUNET_GNSRECORD_TYPE_TOMBSTONE == rd[i].record_type) | ||
440 | continue; | ||
433 | if ((type != rd[i].record_type) && (GNUNET_GNSRECORD_TYPE_ANY != type)) | 441 | if ((type != rd[i].record_type) && (GNUNET_GNSRECORD_TYPE_ANY != type)) |
434 | continue; | 442 | continue; |
435 | have_record = GNUNET_YES; | 443 | have_record = GNUNET_YES; |
@@ -447,6 +455,8 @@ display_record (const char *rname, | |||
447 | if ((GNUNET_GNSRECORD_TYPE_NICK == rd[i].record_type) && | 455 | if ((GNUNET_GNSRECORD_TYPE_NICK == rd[i].record_type) && |
448 | (0 != strcmp (rname, GNUNET_GNS_EMPTY_LABEL_AT))) | 456 | (0 != strcmp (rname, GNUNET_GNS_EMPTY_LABEL_AT))) |
449 | continue; | 457 | continue; |
458 | if (GNUNET_GNSRECORD_TYPE_TOMBSTONE == rd[i].record_type) | ||
459 | continue; | ||
450 | if ((type != rd[i].record_type) && (GNUNET_GNSRECORD_TYPE_ANY != type)) | 460 | if ((type != rd[i].record_type) && (GNUNET_GNSRECORD_TYPE_ANY != type)) |
451 | continue; | 461 | continue; |
452 | typestr = GNUNET_GNSRECORD_number_to_typename (rd[i].record_type); | 462 | typestr = GNUNET_GNSRECORD_number_to_typename (rd[i].record_type); |
@@ -649,28 +659,6 @@ get_existing_record (void *cls, | |||
649 | { | 659 | { |
650 | switch (rd[i].record_type) | 660 | switch (rd[i].record_type) |
651 | { | 661 | { |
652 | case GNUNET_DNSPARSER_TYPE_CNAME: | ||
653 | fprintf ( | ||
654 | stderr, | ||
655 | _ ( | ||
656 | "A %s record exists already under `%s', no other records can be added.\n"), | ||
657 | "CNAME", | ||
658 | rec_name); | ||
659 | ret = 1; | ||
660 | test_finished (); | ||
661 | return; | ||
662 | |||
663 | case GNUNET_GNSRECORD_TYPE_PKEY: | ||
664 | case GNUNET_GNSRECORD_TYPE_EDKEY: | ||
665 | fprintf ( | ||
666 | stderr, | ||
667 | _ ( | ||
668 | "A zone key record exists already under `%s', no other records can be added.\n"), | ||
669 | rec_name); | ||
670 | ret = 1; | ||
671 | test_finished (); | ||
672 | return; | ||
673 | |||
674 | case GNUNET_DNSPARSER_TYPE_SOA: | 662 | case GNUNET_DNSPARSER_TYPE_SOA: |
675 | if (GNUNET_DNSPARSER_TYPE_SOA == type) | 663 | if (GNUNET_DNSPARSER_TYPE_SOA == type) |
676 | { | 664 | { |
@@ -686,51 +674,6 @@ get_existing_record (void *cls, | |||
686 | break; | 674 | break; |
687 | } | 675 | } |
688 | } | 676 | } |
689 | switch (type) | ||
690 | { | ||
691 | case GNUNET_DNSPARSER_TYPE_CNAME: | ||
692 | if (0 != rd_count) | ||
693 | { | ||
694 | fprintf (stderr, | ||
695 | _ ( | ||
696 | "Records already exist under `%s', cannot add `%s' record.\n"), | ||
697 | rec_name, | ||
698 | "CNAME"); | ||
699 | ret = 1; | ||
700 | test_finished (); | ||
701 | return; | ||
702 | } | ||
703 | break; | ||
704 | |||
705 | case GNUNET_GNSRECORD_TYPE_PKEY: | ||
706 | case GNUNET_GNSRECORD_TYPE_EDKEY: | ||
707 | if (0 != rd_count) | ||
708 | { | ||
709 | fprintf (stderr, | ||
710 | _ ( | ||
711 | "Records already exist under `%s', cannot add record.\n"), | ||
712 | rec_name); | ||
713 | ret = 1; | ||
714 | test_finished (); | ||
715 | return; | ||
716 | } | ||
717 | break; | ||
718 | |||
719 | case GNUNET_GNSRECORD_TYPE_GNS2DNS: | ||
720 | for (unsigned int i = 0; i < rd_count; i++) | ||
721 | if (GNUNET_GNSRECORD_TYPE_GNS2DNS != rd[i].record_type) | ||
722 | { | ||
723 | fprintf ( | ||
724 | stderr, | ||
725 | _ ( | ||
726 | "Non-GNS2DNS records already exist under `%s', cannot add GNS2DNS record.\n"), | ||
727 | rec_name); | ||
728 | ret = 1; | ||
729 | test_finished (); | ||
730 | return; | ||
731 | } | ||
732 | break; | ||
733 | } | ||
734 | memset (rdn, 0, sizeof(struct GNUNET_GNSRECORD_Data)); | 677 | memset (rdn, 0, sizeof(struct GNUNET_GNSRECORD_Data)); |
735 | GNUNET_memcpy (&rdn[1], rd, rd_count * sizeof(struct GNUNET_GNSRECORD_Data)); | 678 | GNUNET_memcpy (&rdn[1], rd, rd_count * sizeof(struct GNUNET_GNSRECORD_Data)); |
736 | rde = &rdn[0]; | 679 | rde = &rdn[0]; |
@@ -929,6 +872,13 @@ parse_expiration (const char *expirationstring, | |||
929 | { | 872 | { |
930 | *etime_is_rel = GNUNET_YES; | 873 | *etime_is_rel = GNUNET_YES; |
931 | *etime = etime_rel.rel_value_us; | 874 | *etime = etime_rel.rel_value_us; |
875 | if (GNUNET_TIME_relative_cmp (etime_rel, <, WARN_RELATIVE_EXPIRATION_LIMIT)) | ||
876 | { | ||
877 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | ||
878 | "Relative expiration times of less than %s are not recommended. To improve availability, consider increasing this value.\n", | ||
879 | GNUNET_STRINGS_relative_time_to_string ( | ||
880 | WARN_RELATIVE_EXPIRATION_LIMIT, GNUNET_NO)); | ||
881 | } | ||
932 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 882 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
933 | "Storing record with relative expiration time of %s\n", | 883 | "Storing record with relative expiration time of %s\n", |
934 | GNUNET_STRINGS_relative_time_to_string (etime_rel, GNUNET_NO)); | 884 | GNUNET_STRINGS_relative_time_to_string (etime_rel, GNUNET_NO)); |
@@ -1212,8 +1162,8 @@ run_with_zone_pkey (const struct GNUNET_CONFIGURATION_Handle *cfg) | |||
1212 | char sname[64]; | 1162 | char sname[64]; |
1213 | struct GNUNET_IDENTITY_PublicKey pkey; | 1163 | struct GNUNET_IDENTITY_PublicKey pkey; |
1214 | 1164 | ||
1215 | memset(sh, 0, 105); | 1165 | memset (sh, 0, 105); |
1216 | memset(sname, 0, 64); | 1166 | memset (sname, 0, 64); |
1217 | 1167 | ||
1218 | if ((2 != (sscanf (uri, "gnunet://gns/%58s/%63s", sh, sname))) || | 1168 | if ((2 != (sscanf (uri, "gnunet://gns/%58s/%63s", sh, sname))) || |
1219 | (GNUNET_OK != | 1169 | (GNUNET_OK != |
@@ -1286,15 +1236,6 @@ identity_cb (void *cls, struct GNUNET_IDENTITY_Ego *ego) | |||
1286 | const struct GNUNET_CONFIGURATION_Handle *cfg = cls; | 1236 | const struct GNUNET_CONFIGURATION_Handle *cfg = cls; |
1287 | 1237 | ||
1288 | el = NULL; | 1238 | el = NULL; |
1289 | if ((NULL != name) && (0 != strchr (name, '.'))) | ||
1290 | { | ||
1291 | fprintf (stderr, | ||
1292 | _ ("Label `%s' contains `.' which is not allowed\n"), | ||
1293 | name); | ||
1294 | GNUNET_SCHEDULER_shutdown (); | ||
1295 | ret = -1; | ||
1296 | return; | ||
1297 | } | ||
1298 | 1239 | ||
1299 | if (NULL == ego) | 1240 | if (NULL == ego) |
1300 | { | 1241 | { |
@@ -1705,13 +1646,13 @@ main (int argc, char *const *argv) | |||
1705 | NULL))) | 1646 | NULL))) |
1706 | { | 1647 | { |
1707 | GNUNET_free_nz ((void *) argv); | 1648 | GNUNET_free_nz ((void *) argv); |
1708 | //FIXME | 1649 | // FIXME |
1709 | //GNUNET_CRYPTO_ecdsa_key_clear (&zone_pkey); | 1650 | // GNUNET_CRYPTO_ecdsa_key_clear (&zone_pkey); |
1710 | return lret; | 1651 | return lret; |
1711 | } | 1652 | } |
1712 | GNUNET_free_nz ((void *) argv); | 1653 | GNUNET_free_nz ((void *) argv); |
1713 | //FIXME | 1654 | // FIXME |
1714 | //GNUNET_CRYPTO_ecdsa_key_clear (&zone_pkey); | 1655 | // GNUNET_CRYPTO_ecdsa_key_clear (&zone_pkey); |
1715 | return ret; | 1656 | return ret; |
1716 | } | 1657 | } |
1717 | 1658 | ||
diff --git a/src/namestore/gnunet-service-namestore.c b/src/namestore/gnunet-service-namestore.c index 9b2d9b6f3..d735822fb 100644 --- a/src/namestore/gnunet-service-namestore.c +++ b/src/namestore/gnunet-service-namestore.c | |||
@@ -121,6 +121,23 @@ struct ZoneIteration | |||
121 | int send_end; | 121 | int send_end; |
122 | }; | 122 | }; |
123 | 123 | ||
124 | /** | ||
125 | * Lock on a record set | ||
126 | */ | ||
127 | struct RecordsLock | ||
128 | { | ||
129 | /* DLL */ | ||
130 | struct RecordsLock *prev; | ||
131 | |||
132 | /* DLL */ | ||
133 | struct RecordsLock *next; | ||
134 | |||
135 | /* Hash of the locked label */ | ||
136 | struct GNUNET_HashCode label_hash; | ||
137 | |||
138 | /* Client locking the zone */ | ||
139 | struct NamestoreClient *client; | ||
140 | }; | ||
124 | 141 | ||
125 | /** | 142 | /** |
126 | * A namestore client | 143 | * A namestore client |
@@ -394,6 +411,16 @@ static struct StoreActivity *sa_head; | |||
394 | static struct StoreActivity *sa_tail; | 411 | static struct StoreActivity *sa_tail; |
395 | 412 | ||
396 | /** | 413 | /** |
414 | * Head of the DLL of record set locks | ||
415 | */ | ||
416 | static struct RecordsLock *locks_head; | ||
417 | |||
418 | /** | ||
419 | * Tail of the DLL of record set locks | ||
420 | */ | ||
421 | static struct RecordsLock *locks_tail; | ||
422 | |||
423 | /** | ||
397 | * Notification context shared by all monitors. | 424 | * Notification context shared by all monitors. |
398 | */ | 425 | */ |
399 | static struct GNUNET_NotificationContext *monitor_nc; | 426 | static struct GNUNET_NotificationContext *monitor_nc; |
@@ -420,6 +447,7 @@ static void | |||
420 | cleanup_task (void *cls) | 447 | cleanup_task (void *cls) |
421 | { | 448 | { |
422 | struct CacheOperation *cop; | 449 | struct CacheOperation *cop; |
450 | struct RecordsLock *lock; | ||
423 | 451 | ||
424 | (void) cls; | 452 | (void) cls; |
425 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Stopping namestore service\n"); | 453 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Stopping namestore service\n"); |
@@ -431,6 +459,14 @@ cleanup_task (void *cls) | |||
431 | GNUNET_CONTAINER_DLL_remove (cop_head, cop_tail, cop); | 459 | GNUNET_CONTAINER_DLL_remove (cop_head, cop_tail, cop); |
432 | GNUNET_free (cop); | 460 | GNUNET_free (cop); |
433 | } | 461 | } |
462 | while (NULL != (lock = locks_head)) | ||
463 | { | ||
464 | GNUNET_CONTAINER_DLL_remove (locks_head, | ||
465 | locks_tail, | ||
466 | lock); | ||
467 | GNUNET_free (lock); | ||
468 | } | ||
469 | |||
434 | if (NULL != namecache) | 470 | if (NULL != namecache) |
435 | { | 471 | { |
436 | GNUNET_NAMECACHE_disconnect (namecache); | 472 | GNUNET_NAMECACHE_disconnect (namecache); |
@@ -808,7 +844,8 @@ send_lookup_response (struct NamestoreClient *nc, | |||
808 | * @param rid client's request ID | 844 | * @param rid client's request ID |
809 | */ | 845 | */ |
810 | static void | 846 | static void |
811 | send_store_response (struct NamestoreClient *nc, int res, uint32_t rid) | 847 | send_store_response (struct NamestoreClient *nc, int res, const char*emsg, |
848 | uint32_t rid) | ||
812 | { | 849 | { |
813 | struct GNUNET_MQ_Envelope *env; | 850 | struct GNUNET_MQ_Envelope *env; |
814 | struct RecordStoreResponseMessage *rcr_msg; | 851 | struct RecordStoreResponseMessage *rcr_msg; |
@@ -820,10 +857,17 @@ send_store_response (struct NamestoreClient *nc, int res, uint32_t rid) | |||
820 | "Store requests completed", | 857 | "Store requests completed", |
821 | 1, | 858 | 1, |
822 | GNUNET_NO); | 859 | GNUNET_NO); |
823 | env = GNUNET_MQ_msg (rcr_msg, | 860 | env = GNUNET_MQ_msg_extra (rcr_msg, |
824 | GNUNET_MESSAGE_TYPE_NAMESTORE_RECORD_STORE_RESPONSE); | 861 | (NULL != emsg) ? strlen (emsg) + 1 : 0, |
862 | GNUNET_MESSAGE_TYPE_NAMESTORE_RECORD_STORE_RESPONSE); | ||
825 | rcr_msg->gns_header.r_id = htonl (rid); | 863 | rcr_msg->gns_header.r_id = htonl (rid); |
826 | rcr_msg->op_result = htonl (res); | 864 | rcr_msg->op_result = htonl (res); |
865 | rcr_msg->reserved = htons (0); | ||
866 | if (NULL != emsg) | ||
867 | { | ||
868 | rcr_msg->emsg_len = htons (strlen (emsg) + 1); | ||
869 | memcpy (&rcr_msg[1], emsg, strlen (emsg) + 1); | ||
870 | } | ||
827 | GNUNET_MQ_send (nc->mq, env); | 871 | GNUNET_MQ_send (nc->mq, env); |
828 | } | 872 | } |
829 | 873 | ||
@@ -874,7 +918,7 @@ finish_cache_operation (void *cls, int32_t success, const char *emsg) | |||
874 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "CACHE operation completed\n"); | 918 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "CACHE operation completed\n"); |
875 | GNUNET_CONTAINER_DLL_remove (cop_head, cop_tail, cop); | 919 | GNUNET_CONTAINER_DLL_remove (cop_head, cop_tail, cop); |
876 | if (NULL != cop->nc) | 920 | if (NULL != cop->nc) |
877 | send_store_response (cop->nc, success, cop->rid); | 921 | send_store_response (cop->nc, success, emsg, cop->rid); |
878 | if (NULL != (zi = cop->zi)) | 922 | if (NULL != (zi = cop->zi)) |
879 | { | 923 | { |
880 | zi->cache_ops--; | 924 | zi->cache_ops--; |
@@ -910,29 +954,40 @@ refresh_block (struct NamestoreClient *nc, | |||
910 | const struct GNUNET_GNSRECORD_Data *rd) | 954 | const struct GNUNET_GNSRECORD_Data *rd) |
911 | { | 955 | { |
912 | struct GNUNET_GNSRECORD_Block *block; | 956 | struct GNUNET_GNSRECORD_Block *block; |
957 | struct GNUNET_GNSRECORD_Data rd_clean[rd_count]; | ||
913 | struct CacheOperation *cop; | 958 | struct CacheOperation *cop; |
914 | struct GNUNET_IDENTITY_PublicKey pkey; | 959 | struct GNUNET_IDENTITY_PublicKey pkey; |
915 | struct GNUNET_GNSRECORD_Data *nick; | 960 | struct GNUNET_GNSRECORD_Data *nick; |
916 | struct GNUNET_GNSRECORD_Data *res; | 961 | struct GNUNET_GNSRECORD_Data *res; |
917 | unsigned int res_count; | 962 | unsigned int res_count; |
963 | unsigned int rd_count_clean; | ||
918 | struct GNUNET_TIME_Absolute exp_time; | 964 | struct GNUNET_TIME_Absolute exp_time; |
919 | 965 | ||
966 | /** Do not block-cache tombstones */ | ||
967 | rd_count_clean = 0; | ||
968 | for (int i = 0; i < rd_count; i++) | ||
969 | { | ||
970 | if (GNUNET_GNSRECORD_TYPE_TOMBSTONE == rd[i].record_type) | ||
971 | continue; | ||
972 | rd_clean[rd_count_clean++] = rd[i]; | ||
973 | } | ||
974 | |||
920 | nick = get_nick_record (zone_key); | 975 | nick = get_nick_record (zone_key); |
921 | res_count = rd_count; | 976 | res_count = rd_count_clean; |
922 | res = (struct GNUNET_GNSRECORD_Data *) rd; /* fixme: a bit unclean... */ | 977 | res = (struct GNUNET_GNSRECORD_Data *) rd_clean; /* fixme: a bit unclean... */ |
923 | if ((NULL != nick) && (0 != strcmp (name, GNUNET_GNS_EMPTY_LABEL_AT))) | 978 | if ((NULL != nick) && (0 != strcmp (name, GNUNET_GNS_EMPTY_LABEL_AT))) |
924 | { | 979 | { |
925 | nick->flags = | 980 | nick->flags = |
926 | (nick->flags | GNUNET_GNSRECORD_RF_PRIVATE) ^ GNUNET_GNSRECORD_RF_PRIVATE; | 981 | (nick->flags | GNUNET_GNSRECORD_RF_PRIVATE) ^ GNUNET_GNSRECORD_RF_PRIVATE; |
927 | merge_with_nick_records (nick, rd_count, rd, &res_count, &res); | 982 | merge_with_nick_records (nick, rd_count_clean, rd_clean, &res_count, &res); |
928 | } | 983 | } |
929 | if (NULL != nick) | 984 | if (NULL != nick) |
930 | GNUNET_free (nick); | 985 | GNUNET_free (nick); |
931 | if (0 == res_count) | 986 | if (0 == res_count) |
932 | { | 987 | { |
933 | if (NULL != nc) | 988 | if (NULL != nc) |
934 | send_store_response (nc, GNUNET_OK, rid); | 989 | send_store_response (nc, GNUNET_OK, NULL, rid); |
935 | if (rd != res) | 990 | if (rd_clean != res) |
936 | GNUNET_free (res); | 991 | GNUNET_free (res); |
937 | return; /* no data, no need to update cache */ | 992 | return; /* no data, no need to update cache */ |
938 | } | 993 | } |
@@ -943,20 +998,21 @@ refresh_block (struct NamestoreClient *nc, | |||
943 | 1, | 998 | 1, |
944 | GNUNET_NO); | 999 | GNUNET_NO); |
945 | if (NULL != nc) | 1000 | if (NULL != nc) |
946 | send_store_response (nc, GNUNET_OK, rid); | 1001 | send_store_response (nc, GNUNET_OK, NULL, rid); |
947 | if (rd != res) | 1002 | if (rd_clean != res) |
948 | GNUNET_free (res); | 1003 | GNUNET_free (res); |
949 | return; | 1004 | return; |
950 | } | 1005 | } |
951 | exp_time = GNUNET_GNSRECORD_record_get_expiration_time (res_count, res); | 1006 | exp_time = GNUNET_GNSRECORD_record_get_expiration_time (res_count, res, |
1007 | GNUNET_TIME_UNIT_ZERO_ABS); | ||
952 | if (cache_keys) | 1008 | if (cache_keys) |
953 | GNUNET_assert (GNUNET_OK == | 1009 | GNUNET_assert (GNUNET_OK == |
954 | GNUNET_GNSRECORD_block_create2 (zone_key, exp_time, name, | 1010 | GNUNET_GNSRECORD_block_create2 (zone_key, exp_time, name, |
955 | res, res_count, &block)); | 1011 | res, res_count, &block)); |
956 | else | 1012 | else |
957 | GNUNET_assert (GNUNET_OK == | 1013 | GNUNET_assert (GNUNET_OK == |
958 | GNUNET_GNSRECORD_block_create (zone_key, exp_time, name, | 1014 | GNUNET_GNSRECORD_block_create (zone_key, exp_time, name, |
959 | res, res_count, &block)); | 1015 | res, res_count, &block)); |
960 | GNUNET_assert (NULL != block); | 1016 | GNUNET_assert (NULL != block); |
961 | GNUNET_IDENTITY_key_get_public (zone_key, &pkey); | 1017 | GNUNET_IDENTITY_key_get_public (zone_key, &pkey); |
962 | GNUNET_log ( | 1018 | GNUNET_log ( |
@@ -974,7 +1030,7 @@ refresh_block (struct NamestoreClient *nc, | |||
974 | cop->nc = nc; | 1030 | cop->nc = nc; |
975 | cop->zi = zi; | 1031 | cop->zi = zi; |
976 | if (NULL != zi) | 1032 | if (NULL != zi) |
977 | zi->cache_ops++; | 1033 | zi->cache_ops ++; |
978 | cop->rid = rid; | 1034 | cop->rid = rid; |
979 | GNUNET_CONTAINER_DLL_insert (cop_head, cop_tail, cop); | 1035 | GNUNET_CONTAINER_DLL_insert (cop_head, cop_tail, cop); |
980 | cop->qe = GNUNET_NAMECACHE_block_cache (namecache, | 1036 | cop->qe = GNUNET_NAMECACHE_block_cache (namecache, |
@@ -982,7 +1038,7 @@ refresh_block (struct NamestoreClient *nc, | |||
982 | &finish_cache_operation, | 1038 | &finish_cache_operation, |
983 | cop); | 1039 | cop); |
984 | GNUNET_free (block); | 1040 | GNUNET_free (block); |
985 | if (rd != res) | 1041 | if (rd_clean != res) |
986 | GNUNET_free (res); | 1042 | GNUNET_free (res); |
987 | } | 1043 | } |
988 | 1044 | ||
@@ -1098,6 +1154,7 @@ client_disconnect_cb (void *cls, | |||
1098 | struct NamestoreClient *nc = app_ctx; | 1154 | struct NamestoreClient *nc = app_ctx; |
1099 | struct ZoneIteration *no; | 1155 | struct ZoneIteration *no; |
1100 | struct CacheOperation *cop; | 1156 | struct CacheOperation *cop; |
1157 | struct RecordsLock *lock; | ||
1101 | 1158 | ||
1102 | (void) cls; | 1159 | (void) cls; |
1103 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Client %p disconnected\n", client); | 1160 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, "Client %p disconnected\n", client); |
@@ -1148,6 +1205,15 @@ client_disconnect_cb (void *cls, | |||
1148 | for (cop = cop_head; NULL != cop; cop = cop->next) | 1205 | for (cop = cop_head; NULL != cop; cop = cop->next) |
1149 | if (nc == cop->nc) | 1206 | if (nc == cop->nc) |
1150 | cop->nc = NULL; | 1207 | cop->nc = NULL; |
1208 | for (lock = locks_head; NULL != lock; lock = lock->next) | ||
1209 | { | ||
1210 | if (nc != lock->client) | ||
1211 | continue; | ||
1212 | GNUNET_CONTAINER_DLL_remove (locks_head, | ||
1213 | locks_tail, | ||
1214 | lock); | ||
1215 | GNUNET_free (lock); | ||
1216 | } | ||
1151 | GNUNET_free (nc); | 1217 | GNUNET_free (nc); |
1152 | } | 1218 | } |
1153 | 1219 | ||
@@ -1341,6 +1407,105 @@ check_record_lookup (void *cls, const struct LabelLookupMessage *ll_msg) | |||
1341 | return GNUNET_OK; | 1407 | return GNUNET_OK; |
1342 | } | 1408 | } |
1343 | 1409 | ||
1410 | static void | ||
1411 | calculate_lock_hash (const char *label, | ||
1412 | const struct GNUNET_IDENTITY_PrivateKey *zone, | ||
1413 | struct GNUNET_HashCode *result) | ||
1414 | { | ||
1415 | struct GNUNET_HashContext *hctx; | ||
1416 | |||
1417 | hctx = GNUNET_CRYPTO_hash_context_start (); | ||
1418 | GNUNET_CRYPTO_hash_context_read (hctx, label, strlen (label)); | ||
1419 | GNUNET_CRYPTO_hash_context_read (hctx, zone, | ||
1420 | sizeof (*zone)); | ||
1421 | GNUNET_CRYPTO_hash_context_finish (hctx, result); | ||
1422 | } | ||
1423 | |||
1424 | /** | ||
1425 | * Release a lock on a record set. | ||
1426 | * Does nothing if lock not held. | ||
1427 | * | ||
1428 | * @param label the label of the record set | ||
1429 | * @param zone the zone | ||
1430 | * @param nc the client releasing the lock | ||
1431 | */ | ||
1432 | static void | ||
1433 | NST_label_lock_release (const char *label, | ||
1434 | const struct GNUNET_IDENTITY_PrivateKey *zone, | ||
1435 | const struct NamestoreClient *nc) | ||
1436 | { | ||
1437 | struct GNUNET_HashCode label_hash; | ||
1438 | struct RecordsLock *lock; | ||
1439 | |||
1440 | calculate_lock_hash (label, zone, &label_hash); | ||
1441 | for (lock = locks_head; NULL != lock; lock = lock->next) | ||
1442 | if (0 == memcmp (&label_hash, &lock->label_hash, sizeof (label_hash))) | ||
1443 | break; | ||
1444 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1445 | "Record locked: %s\n", (NULL == lock) ? "No" : "Yes"); | ||
1446 | if (NULL == lock) | ||
1447 | return; | ||
1448 | if (lock->client != nc) | ||
1449 | { | ||
1450 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | ||
1451 | "Lock is held by other client on `%s'\n", label); | ||
1452 | return; | ||
1453 | } | ||
1454 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1455 | "Unocking %s\n", GNUNET_h2s (&label_hash)); | ||
1456 | GNUNET_CONTAINER_DLL_remove (locks_head, | ||
1457 | locks_tail, | ||
1458 | lock); | ||
1459 | GNUNET_free (lock); | ||
1460 | } | ||
1461 | |||
1462 | /** | ||
1463 | * Get/set a lock on a record set. | ||
1464 | * May be called multiple times but will | ||
1465 | * not aquire additional locks. | ||
1466 | * | ||
1467 | * @param the label of the record set | ||
1468 | * @param the zone | ||
1469 | * @param the client doing the locking | ||
1470 | * @return GNUNET_YES if lock retrieved or set already. | ||
1471 | */ | ||
1472 | static enum GNUNET_GenericReturnValue | ||
1473 | NST_label_lock (const char *label, | ||
1474 | const struct GNUNET_IDENTITY_PrivateKey *zone, | ||
1475 | struct NamestoreClient *nc) | ||
1476 | { | ||
1477 | struct GNUNET_HashCode label_hash; | ||
1478 | struct RecordsLock *lock; | ||
1479 | |||
1480 | calculate_lock_hash (label, zone, &label_hash); | ||
1481 | for (lock = locks_head; NULL != lock; lock = lock->next) | ||
1482 | if (0 == memcmp (&label_hash, &lock->label_hash, sizeof (label_hash))) | ||
1483 | break; | ||
1484 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1485 | "Record locked: %s\n", (NULL == lock) ? "No" : "Yes"); | ||
1486 | if (NULL != lock) | ||
1487 | { | ||
1488 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1489 | "Client holds lock: %s\n", (lock->client != nc) ? "No" : "Yes"); | ||
1490 | if (lock->client != nc) | ||
1491 | { | ||
1492 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | ||
1493 | "Lock is held by other client on `%s'\n", label); | ||
1494 | return GNUNET_NO; | ||
1495 | } | ||
1496 | return GNUNET_YES; | ||
1497 | } | ||
1498 | lock = GNUNET_new (struct RecordsLock); | ||
1499 | lock->client = nc; | ||
1500 | memcpy (&lock->label_hash, &label_hash, sizeof (label_hash)); | ||
1501 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1502 | "Locking %s\n", GNUNET_h2s (&label_hash)); | ||
1503 | GNUNET_CONTAINER_DLL_insert (locks_head, | ||
1504 | locks_tail, | ||
1505 | lock); | ||
1506 | return GNUNET_YES; | ||
1507 | } | ||
1508 | |||
1344 | 1509 | ||
1345 | /** | 1510 | /** |
1346 | * Handles a #GNUNET_MESSAGE_TYPE_NAMESTORE_RECORD_LOOKUP message | 1511 | * Handles a #GNUNET_MESSAGE_TYPE_NAMESTORE_RECORD_LOOKUP message |
@@ -1355,13 +1520,14 @@ handle_record_lookup (void *cls, const struct LabelLookupMessage *ll_msg) | |||
1355 | struct GNUNET_MQ_Envelope *env; | 1520 | struct GNUNET_MQ_Envelope *env; |
1356 | struct LabelLookupResponseMessage *llr_msg; | 1521 | struct LabelLookupResponseMessage *llr_msg; |
1357 | struct RecordLookupContext rlc; | 1522 | struct RecordLookupContext rlc; |
1523 | struct RecordsLock *lock; | ||
1524 | struct GNUNET_HashCode label_hash; | ||
1358 | const char *name_tmp; | 1525 | const char *name_tmp; |
1359 | char *res_name; | 1526 | char *res_name; |
1360 | char *conv_name; | 1527 | char *conv_name; |
1361 | uint32_t name_len; | 1528 | uint32_t name_len; |
1362 | int res; | 1529 | int res; |
1363 | 1530 | ||
1364 | name_len = ntohl (ll_msg->label_len); | ||
1365 | name_tmp = (const char *) &ll_msg[1]; | 1531 | name_tmp = (const char *) &ll_msg[1]; |
1366 | GNUNET_SERVICE_client_continue (nc->client); | 1532 | GNUNET_SERVICE_client_continue (nc->client); |
1367 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1533 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
@@ -1377,6 +1543,29 @@ handle_record_lookup (void *cls, const struct LabelLookupMessage *ll_msg) | |||
1377 | GNUNET_SERVICE_client_drop (nc->client); | 1543 | GNUNET_SERVICE_client_drop (nc->client); |
1378 | return; | 1544 | return; |
1379 | } | 1545 | } |
1546 | name_len = strlen (conv_name) + 1; | ||
1547 | if (GNUNET_YES == ntohl (ll_msg->locking)) | ||
1548 | { | ||
1549 | if (GNUNET_NO == NST_label_lock (conv_name, &ll_msg->zone, nc)) | ||
1550 | { | ||
1551 | GNUNET_log (GNUNET_ERROR_TYPE_WARNING, | ||
1552 | "Lock is held by other client on `%s'\n", conv_name); | ||
1553 | env = | ||
1554 | GNUNET_MQ_msg_extra (llr_msg, | ||
1555 | name_len, | ||
1556 | GNUNET_MESSAGE_TYPE_NAMESTORE_RECORD_LOOKUP_RESPONSE); | ||
1557 | llr_msg->gns_header.r_id = ll_msg->gns_header.r_id; | ||
1558 | llr_msg->private_key = ll_msg->zone; | ||
1559 | llr_msg->name_len = htons (name_len); | ||
1560 | llr_msg->rd_count = htons (0); | ||
1561 | llr_msg->rd_len = htons (0); | ||
1562 | llr_msg->found = htons (GNUNET_SYSERR); | ||
1563 | GNUNET_memcpy (&llr_msg[1], conv_name, name_len); | ||
1564 | GNUNET_MQ_send (nc->mq, env); | ||
1565 | GNUNET_free (conv_name); | ||
1566 | return; | ||
1567 | } | ||
1568 | } | ||
1380 | rlc.label = conv_name; | 1569 | rlc.label = conv_name; |
1381 | rlc.found = GNUNET_NO; | 1570 | rlc.found = GNUNET_NO; |
1382 | rlc.res_rd_count = 0; | 1571 | rlc.res_rd_count = 0; |
@@ -1388,7 +1577,6 @@ handle_record_lookup (void *cls, const struct LabelLookupMessage *ll_msg) | |||
1388 | conv_name, | 1577 | conv_name, |
1389 | &lookup_it, | 1578 | &lookup_it, |
1390 | &rlc); | 1579 | &rlc); |
1391 | GNUNET_free (conv_name); | ||
1392 | env = | 1580 | env = |
1393 | GNUNET_MQ_msg_extra (llr_msg, | 1581 | GNUNET_MQ_msg_extra (llr_msg, |
1394 | name_len + rlc.rd_ser_len, | 1582 | name_len + rlc.rd_ser_len, |
@@ -1400,16 +1588,18 @@ handle_record_lookup (void *cls, const struct LabelLookupMessage *ll_msg) | |||
1400 | llr_msg->rd_len = htons (rlc.rd_ser_len); | 1588 | llr_msg->rd_len = htons (rlc.rd_ser_len); |
1401 | res_name = (char *) &llr_msg[1]; | 1589 | res_name = (char *) &llr_msg[1]; |
1402 | if ((GNUNET_YES == rlc.found) && (GNUNET_OK == res)) | 1590 | if ((GNUNET_YES == rlc.found) && (GNUNET_OK == res)) |
1403 | llr_msg->found = ntohs (GNUNET_YES); | 1591 | llr_msg->found = htons (GNUNET_YES); |
1404 | else | 1592 | else |
1405 | llr_msg->found = ntohs (GNUNET_NO); | 1593 | llr_msg->found = htons (GNUNET_NO); |
1406 | GNUNET_memcpy (&llr_msg[1], name_tmp, name_len); | 1594 | GNUNET_memcpy (&llr_msg[1], conv_name, name_len); |
1407 | GNUNET_memcpy (&res_name[name_len], rlc.res_rd, rlc.rd_ser_len); | 1595 | GNUNET_memcpy (&res_name[name_len], rlc.res_rd, rlc.rd_ser_len); |
1408 | GNUNET_MQ_send (nc->mq, env); | 1596 | GNUNET_MQ_send (nc->mq, env); |
1409 | GNUNET_free (rlc.res_rd); | 1597 | GNUNET_free (rlc.res_rd); |
1598 | GNUNET_free (conv_name); | ||
1410 | } | 1599 | } |
1411 | 1600 | ||
1412 | 1601 | ||
1602 | |||
1413 | /** | 1603 | /** |
1414 | * Checks a #GNUNET_MESSAGE_TYPE_NAMESTORE_RECORD_STORE message | 1604 | * Checks a #GNUNET_MESSAGE_TYPE_NAMESTORE_RECORD_STORE message |
1415 | * | 1605 | * |
@@ -1452,6 +1642,45 @@ check_record_store (void *cls, const struct RecordStoreMessage *rp_msg) | |||
1452 | 1642 | ||
1453 | 1643 | ||
1454 | /** | 1644 | /** |
1645 | * Check if set contains a tombstone, store if necessary | ||
1646 | * | ||
1647 | * @param cls a `struct GNUNET_GNSRECORD_Data **` for storing the nick (if found) | ||
1648 | * @param seq sequence number of the record, MUST NOT BE ZERO | ||
1649 | * @param private_key the private key of the zone (unused) | ||
1650 | * @param label should be #GNUNET_GNS_EMPTY_LABEL_AT | ||
1651 | * @param rd_count number of records in @a rd | ||
1652 | * @param rd records stored under @a label in the zone | ||
1653 | */ | ||
1654 | static void | ||
1655 | get_block_exp_existing (void *cls, | ||
1656 | uint64_t seq, | ||
1657 | const struct | ||
1658 | GNUNET_IDENTITY_PrivateKey *private_key, | ||
1659 | const char *label, | ||
1660 | unsigned int rd_count, | ||
1661 | const struct GNUNET_GNSRECORD_Data *rd) | ||
1662 | { | ||
1663 | struct GNUNET_TIME_Absolute *exp = cls; | ||
1664 | struct GNUNET_GNSRECORD_Data rd_pub[rd_count]; | ||
1665 | unsigned int rd_pub_count; | ||
1666 | char *emsg; | ||
1667 | |||
1668 | if (GNUNET_OK != GNUNET_GNSRECORD_convert_records_for_export (label, | ||
1669 | rd, | ||
1670 | rd_count, | ||
1671 | rd_pub, | ||
1672 | &rd_pub_count, | ||
1673 | exp, | ||
1674 | &emsg)) | ||
1675 | { | ||
1676 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | ||
1677 | "%s\n", emsg); | ||
1678 | GNUNET_free (emsg); | ||
1679 | } | ||
1680 | } | ||
1681 | |||
1682 | |||
1683 | /** | ||
1455 | * Handles a #GNUNET_MESSAGE_TYPE_NAMESTORE_RECORD_STORE message | 1684 | * Handles a #GNUNET_MESSAGE_TYPE_NAMESTORE_RECORD_STORE message |
1456 | * | 1685 | * |
1457 | * @param cls client sending the message | 1686 | * @param cls client sending the message |
@@ -1470,37 +1699,75 @@ handle_record_store (void *cls, const struct RecordStoreMessage *rp_msg) | |||
1470 | unsigned int rd_count; | 1699 | unsigned int rd_count; |
1471 | int res; | 1700 | int res; |
1472 | struct StoreActivity *sa; | 1701 | struct StoreActivity *sa; |
1702 | struct RecordsLock *lock; | ||
1703 | struct GNUNET_HashCode label_hash; | ||
1704 | struct GNUNET_TIME_Absolute existing_block_exp; | ||
1705 | struct GNUNET_TIME_Absolute new_block_exp; | ||
1473 | 1706 | ||
1474 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1707 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1475 | "Received NAMESTORE_RECORD_STORE message\n"); | 1708 | "Received NAMESTORE_RECORD_STORE message\n"); |
1709 | existing_block_exp = GNUNET_TIME_UNIT_ZERO_ABS; | ||
1710 | new_block_exp = GNUNET_TIME_UNIT_ZERO_ABS; | ||
1476 | rid = ntohl (rp_msg->gns_header.r_id); | 1711 | rid = ntohl (rp_msg->gns_header.r_id); |
1477 | name_len = ntohs (rp_msg->name_len); | 1712 | name_len = ntohs (rp_msg->name_len); |
1478 | rd_count = ntohs (rp_msg->rd_count); | 1713 | rd_count = ntohs (rp_msg->rd_count); |
1479 | rd_ser_len = ntohs (rp_msg->rd_len); | 1714 | rd_ser_len = ntohs (rp_msg->rd_len); |
1480 | GNUNET_break (0 == ntohs (rp_msg->reserved)); | ||
1481 | name_tmp = (const char *) &rp_msg[1]; | 1715 | name_tmp = (const char *) &rp_msg[1]; |
1482 | rd_ser = &name_tmp[name_len]; | 1716 | rd_ser = &name_tmp[name_len]; |
1483 | { | 1717 | { |
1484 | struct GNUNET_GNSRECORD_Data rd[GNUNET_NZL (rd_count)]; | 1718 | struct GNUNET_GNSRECORD_Data rd[GNUNET_NZL (rd_count)]; |
1485 | 1719 | char *emsg; | |
1486 | if (GNUNET_OK != | ||
1487 | GNUNET_GNSRECORD_records_deserialize (rd_ser_len, rd_ser, rd_count, rd)) | ||
1488 | { | ||
1489 | GNUNET_break (0); | ||
1490 | GNUNET_SERVICE_client_drop (nc->client); | ||
1491 | return; | ||
1492 | } | ||
1493 | 1720 | ||
1494 | /* Extracting and converting private key */ | 1721 | /* Extracting and converting private key */ |
1495 | conv_name = GNUNET_GNSRECORD_string_normalize (name_tmp); | 1722 | conv_name = GNUNET_GNSRECORD_string_normalize (name_tmp); |
1496 | if (NULL == conv_name) | 1723 | if (NULL == conv_name) |
1497 | { | 1724 | { |
1498 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | 1725 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, |
1499 | "Error converting name `%s'\n", | 1726 | "Error normalizing name `%s'\n", |
1500 | name_tmp); | 1727 | name_tmp); |
1501 | GNUNET_SERVICE_client_drop (nc->client); | 1728 | send_store_response (nc, GNUNET_SYSERR, _ ("Error normalizing name."), |
1729 | rid); | ||
1730 | GNUNET_SERVICE_client_continue (nc->client); | ||
1731 | return; | ||
1732 | } | ||
1733 | |||
1734 | /* Check name for validity */ | ||
1735 | if (GNUNET_OK != GNUNET_GNSRECORD_label_check (conv_name, &emsg)) | ||
1736 | { | ||
1737 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | ||
1738 | "Label invalid: `%s'\n", | ||
1739 | emsg); | ||
1740 | send_store_response (nc, GNUNET_SYSERR, emsg, rid); | ||
1741 | GNUNET_free (emsg); | ||
1742 | GNUNET_free (conv_name); | ||
1743 | GNUNET_SERVICE_client_continue (nc->client); | ||
1744 | return; | ||
1745 | } | ||
1746 | |||
1747 | if (GNUNET_OK != | ||
1748 | GNUNET_GNSRECORD_records_deserialize (rd_ser_len, rd_ser, rd_count, rd)) | ||
1749 | { | ||
1750 | send_store_response (nc, GNUNET_SYSERR, | ||
1751 | _ ("Error deserializing records."), rid); | ||
1752 | GNUNET_free (conv_name); | ||
1753 | GNUNET_SERVICE_client_continue (nc->client); | ||
1502 | return; | 1754 | return; |
1503 | } | 1755 | } |
1756 | if (GNUNET_YES == ntohl (rp_msg->locking)) | ||
1757 | { | ||
1758 | if (GNUNET_NO == NST_label_lock (conv_name, &rp_msg->private_key, nc)) | ||
1759 | { | ||
1760 | send_store_response (nc, GNUNET_SYSERR, _ ("Record set locked."), rid); | ||
1761 | GNUNET_SERVICE_client_continue (nc->client); | ||
1762 | GNUNET_free (conv_name); | ||
1763 | return; | ||
1764 | } | ||
1765 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
1766 | "Client has lock on `%s', continuing.\n", conv_name); | ||
1767 | if (GNUNET_YES == ntohl (rp_msg->locking)) | ||
1768 | NST_label_lock_release (conv_name, &rp_msg->private_key, nc); | ||
1769 | } | ||
1770 | |||
1504 | GNUNET_STATISTICS_update (statistics, | 1771 | GNUNET_STATISTICS_update (statistics, |
1505 | "Well-formed store requests received", | 1772 | "Well-formed store requests received", |
1506 | 1, | 1773 | 1, |
@@ -1509,12 +1776,12 @@ handle_record_store (void *cls, const struct RecordStoreMessage *rp_msg) | |||
1509 | "Creating %u records for name `%s'\n", | 1776 | "Creating %u records for name `%s'\n", |
1510 | (unsigned int) rd_count, | 1777 | (unsigned int) rd_count, |
1511 | conv_name); | 1778 | conv_name); |
1512 | if ((0 == rd_count) && | 1779 | if ((GNUNET_NO == GSN_database->lookup_records (GSN_database->cls, |
1513 | (GNUNET_NO == GSN_database->lookup_records (GSN_database->cls, | ||
1514 | &rp_msg->private_key, | 1780 | &rp_msg->private_key, |
1515 | conv_name, | 1781 | conv_name, |
1516 | NULL, | 1782 | &get_block_exp_existing, |
1517 | 0))) | 1783 | &existing_block_exp)) && |
1784 | (rd_count == 0)) | ||
1518 | { | 1785 | { |
1519 | /* This name does not exist, so cannot be removed */ | 1786 | /* This name does not exist, so cannot be removed */ |
1520 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1787 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
@@ -1525,9 +1792,18 @@ handle_record_store (void *cls, const struct RecordStoreMessage *rp_msg) | |||
1525 | else | 1792 | else |
1526 | { | 1793 | { |
1527 | /* remove "NICK" records, unless this is for the | 1794 | /* remove "NICK" records, unless this is for the |
1528 | #GNUNET_GNS_EMPTY_LABEL_AT label */ | 1795 | #GNUNET_GNS_EMPTY_LABEL_AT label |
1796 | We may need one additional record later for tombstone. | ||
1797 | FIXME: Since we must normalize the record set (check for | ||
1798 | consistency etc) we have to iterate the set twice. | ||
1799 | May be inefficient. | ||
1800 | We cannot really move the nick caching into GNSRECORD. | ||
1801 | */ | ||
1529 | struct GNUNET_GNSRECORD_Data rd_clean[GNUNET_NZL (rd_count)]; | 1802 | struct GNUNET_GNSRECORD_Data rd_clean[GNUNET_NZL (rd_count)]; |
1803 | struct GNUNET_GNSRECORD_Data rd_nf[GNUNET_NZL (rd_count) + 1]; | ||
1530 | unsigned int rd_clean_off; | 1804 | unsigned int rd_clean_off; |
1805 | unsigned int rd_nf_count; | ||
1806 | char *emsg; | ||
1531 | int have_nick; | 1807 | int have_nick; |
1532 | 1808 | ||
1533 | rd_clean_off = 0; | 1809 | rd_clean_off = 0; |
@@ -1535,6 +1811,7 @@ handle_record_store (void *cls, const struct RecordStoreMessage *rp_msg) | |||
1535 | for (unsigned int i = 0; i < rd_count; i++) | 1811 | for (unsigned int i = 0; i < rd_count; i++) |
1536 | { | 1812 | { |
1537 | rd_clean[rd_clean_off] = rd[i]; | 1813 | rd_clean[rd_clean_off] = rd[i]; |
1814 | |||
1538 | if ((0 == strcmp (GNUNET_GNS_EMPTY_LABEL_AT, conv_name)) || | 1815 | if ((0 == strcmp (GNUNET_GNS_EMPTY_LABEL_AT, conv_name)) || |
1539 | (GNUNET_GNSRECORD_TYPE_NICK != rd[i].record_type)) | 1816 | (GNUNET_GNSRECORD_TYPE_NICK != rd[i].record_type)) |
1540 | rd_clean_off++; | 1817 | rd_clean_off++; |
@@ -1546,6 +1823,38 @@ handle_record_store (void *cls, const struct RecordStoreMessage *rp_msg) | |||
1546 | have_nick = GNUNET_YES; | 1823 | have_nick = GNUNET_YES; |
1547 | } | 1824 | } |
1548 | } | 1825 | } |
1826 | if (GNUNET_OK != GNUNET_GNSRECORD_normalize_record_set (conv_name, | ||
1827 | rd_clean, | ||
1828 | rd_clean_off, | ||
1829 | rd_nf, | ||
1830 | &rd_nf_count, | ||
1831 | &new_block_exp, | ||
1832 | GNUNET_YES, | ||
1833 | &emsg)) | ||
1834 | { | ||
1835 | send_store_response (nc, GNUNET_SYSERR, emsg, rid); | ||
1836 | GNUNET_free (emsg); | ||
1837 | GNUNET_SERVICE_client_continue (nc->client); | ||
1838 | GNUNET_free (conv_name); | ||
1839 | return; | ||
1840 | } | ||
1841 | /* | ||
1842 | * If existing_block_exp is 0, then there was not record set | ||
1843 | * and no tombstone. | ||
1844 | * Otherwise, if the existing block expiration is after the | ||
1845 | * new block expiration would be, we need to add a tombstone | ||
1846 | * or update it. | ||
1847 | */ | ||
1848 | if (GNUNET_TIME_absolute_cmp (new_block_exp, <=, existing_block_exp)) | ||
1849 | { | ||
1850 | rd_nf[rd_nf_count].record_type = GNUNET_GNSRECORD_TYPE_TOMBSTONE; | ||
1851 | rd_nf[rd_nf_count].expiration_time = | ||
1852 | existing_block_exp.abs_value_us; | ||
1853 | rd_nf[rd_nf_count].data = NULL; | ||
1854 | rd_nf[rd_nf_count].data_size = 0; | ||
1855 | rd_nf[rd_nf_count].flags = GNUNET_GNSRECORD_RF_PRIVATE; | ||
1856 | rd_nf_count++; | ||
1857 | } | ||
1549 | if ((0 == strcmp (GNUNET_GNS_EMPTY_LABEL_AT, conv_name)) && | 1858 | if ((0 == strcmp (GNUNET_GNS_EMPTY_LABEL_AT, conv_name)) && |
1550 | (GNUNET_NO == have_nick)) | 1859 | (GNUNET_NO == have_nick)) |
1551 | { | 1860 | { |
@@ -1555,19 +1864,18 @@ handle_record_store (void *cls, const struct RecordStoreMessage *rp_msg) | |||
1555 | res = GSN_database->store_records (GSN_database->cls, | 1864 | res = GSN_database->store_records (GSN_database->cls, |
1556 | &rp_msg->private_key, | 1865 | &rp_msg->private_key, |
1557 | conv_name, | 1866 | conv_name, |
1558 | rd_clean_off, | 1867 | rd_nf_count, |
1559 | rd_clean); | 1868 | rd_nf); |
1560 | } | 1869 | } |
1561 | 1870 | ||
1562 | if (GNUNET_OK != res) | 1871 | if (GNUNET_OK != res) |
1563 | { | 1872 | { |
1564 | /* store not successful, not need to tell monitors */ | 1873 | /* store not successful, no need to tell monitors */ |
1565 | send_store_response (nc, res, rid); | 1874 | send_store_response (nc, res, _ ("Store failed"), rid); |
1566 | GNUNET_SERVICE_client_continue (nc->client); | 1875 | GNUNET_SERVICE_client_continue (nc->client); |
1567 | GNUNET_free (conv_name); | 1876 | GNUNET_free (conv_name); |
1568 | return; | 1877 | return; |
1569 | } | 1878 | } |
1570 | |||
1571 | sa = GNUNET_malloc (sizeof(struct StoreActivity) | 1879 | sa = GNUNET_malloc (sizeof(struct StoreActivity) |
1572 | + ntohs (rp_msg->gns_header.header.size)); | 1880 | + ntohs (rp_msg->gns_header.header.size)); |
1573 | GNUNET_CONTAINER_DLL_insert (sa_head, sa_tail, sa); | 1881 | GNUNET_CONTAINER_DLL_insert (sa_head, sa_tail, sa); |
diff --git a/src/namestore/namestore.h b/src/namestore/namestore.h index fd9a8ed47..0f3ffa837 100644 --- a/src/namestore/namestore.h +++ b/src/namestore/namestore.h | |||
@@ -68,6 +68,11 @@ struct RecordStoreMessage | |||
68 | struct GNUNET_TIME_AbsoluteNBO expire; | 68 | struct GNUNET_TIME_AbsoluteNBO expire; |
69 | 69 | ||
70 | /** | 70 | /** |
71 | * Unock the label with this request. | ||
72 | */ | ||
73 | uint32_t locking GNUNET_PACKED; | ||
74 | |||
75 | /** | ||
71 | * Name length | 76 | * Name length |
72 | */ | 77 | */ |
73 | uint16_t name_len GNUNET_PACKED; | 78 | uint16_t name_len GNUNET_PACKED; |
@@ -83,7 +88,7 @@ struct RecordStoreMessage | |||
83 | uint16_t rd_count GNUNET_PACKED; | 88 | uint16_t rd_count GNUNET_PACKED; |
84 | 89 | ||
85 | /** | 90 | /** |
86 | * always zero (for alignment) | 91 | * Reserved for alignment. |
87 | */ | 92 | */ |
88 | uint16_t reserved GNUNET_PACKED; | 93 | uint16_t reserved GNUNET_PACKED; |
89 | 94 | ||
@@ -113,6 +118,20 @@ struct RecordStoreResponseMessage | |||
113 | * #GNUNET_SYSERR on failure, #GNUNET_OK on success | 118 | * #GNUNET_SYSERR on failure, #GNUNET_OK on success |
114 | */ | 119 | */ |
115 | int32_t op_result GNUNET_PACKED; | 120 | int32_t op_result GNUNET_PACKED; |
121 | |||
122 | /** | ||
123 | * Error message length | ||
124 | */ | ||
125 | uint16_t emsg_len GNUNET_PACKED; | ||
126 | |||
127 | /** | ||
128 | * Reserved for alignment. | ||
129 | */ | ||
130 | uint16_t reserved GNUNET_PACKED; | ||
131 | |||
132 | /** | ||
133 | * Followed by error message | ||
134 | */ | ||
116 | }; | 135 | }; |
117 | 136 | ||
118 | 137 | ||
@@ -132,6 +151,11 @@ struct LabelLookupMessage | |||
132 | uint32_t label_len GNUNET_PACKED; | 151 | uint32_t label_len GNUNET_PACKED; |
133 | 152 | ||
134 | /** | 153 | /** |
154 | * Lock the label with this lookup | ||
155 | */ | ||
156 | uint32_t locking GNUNET_PACKED; | ||
157 | |||
158 | /** | ||
135 | * The private key of the zone to look up in | 159 | * The private key of the zone to look up in |
136 | */ | 160 | */ |
137 | struct GNUNET_IDENTITY_PrivateKey zone; | 161 | struct GNUNET_IDENTITY_PrivateKey zone; |
@@ -171,7 +195,7 @@ struct LabelLookupResponseMessage | |||
171 | * Was the label found in the database?? | 195 | * Was the label found in the database?? |
172 | * #GNUNET_YES or #GNUNET_NO | 196 | * #GNUNET_YES or #GNUNET_NO |
173 | */ | 197 | */ |
174 | uint16_t found GNUNET_PACKED; | 198 | int16_t found GNUNET_PACKED; |
175 | 199 | ||
176 | /** | 200 | /** |
177 | * The private key of the authority. | 201 | * The private key of the authority. |
diff --git a/src/namestore/namestore_api.c b/src/namestore/namestore_api.c index b24db9b26..a7380bbde 100644 --- a/src/namestore/namestore_api.c +++ b/src/namestore/namestore_api.c | |||
@@ -346,6 +346,44 @@ check_rd (size_t rd_len, const void *rd_buf, unsigned int rd_count) | |||
346 | return GNUNET_OK; | 346 | return GNUNET_OK; |
347 | } | 347 | } |
348 | 348 | ||
349 | /** | ||
350 | * Handle an incoming message of type | ||
351 | * #GNUNET_MESSAGE_TYPE_NAMESTORE_RECORD_STORE_RESPONSE | ||
352 | * | ||
353 | * @param cls | ||
354 | * @param msg the message we received | ||
355 | * @return #GNUNET_OK on success, #GNUNET_SYSERR on error | ||
356 | */ | ||
357 | static int | ||
358 | check_record_store_response (void *cls, | ||
359 | const struct RecordStoreResponseMessage *msg) | ||
360 | { | ||
361 | const char *emsg; | ||
362 | size_t msg_len; | ||
363 | size_t emsg_len; | ||
364 | |||
365 | (void) cls; | ||
366 | msg_len = ntohs (msg->gns_header.header.size); | ||
367 | emsg_len = ntohs (msg->emsg_len); | ||
368 | if (0 != ntohs (msg->reserved)) | ||
369 | { | ||
370 | GNUNET_break (0); | ||
371 | return GNUNET_SYSERR; | ||
372 | } | ||
373 | if (msg_len != sizeof(struct RecordStoreResponseMessage) + emsg_len) | ||
374 | { | ||
375 | GNUNET_break (0); | ||
376 | return GNUNET_SYSERR; | ||
377 | } | ||
378 | emsg = (const char *) &msg[1]; | ||
379 | if ((0 != emsg_len) && ('\0' != emsg[emsg_len - 1])) | ||
380 | { | ||
381 | GNUNET_break (0); | ||
382 | return GNUNET_SYSERR; | ||
383 | } | ||
384 | return GNUNET_OK; | ||
385 | } | ||
386 | |||
349 | 387 | ||
350 | /** | 388 | /** |
351 | * Handle an incoming message of type | 389 | * Handle an incoming message of type |
@@ -364,19 +402,16 @@ handle_record_store_response (void *cls, | |||
364 | const char *emsg; | 402 | const char *emsg; |
365 | 403 | ||
366 | qe = find_qe (h, ntohl (msg->gns_header.r_id)); | 404 | qe = find_qe (h, ntohl (msg->gns_header.r_id)); |
405 | emsg = (const char *) &msg[1]; | ||
367 | res = ntohl (msg->op_result); | 406 | res = ntohl (msg->op_result); |
368 | LOG (GNUNET_ERROR_TYPE_DEBUG, | 407 | LOG (GNUNET_ERROR_TYPE_DEBUG, |
369 | "Received RECORD_STORE_RESPONSE with result %d\n", | 408 | "Received RECORD_STORE_RESPONSE with result %d\n", |
370 | res); | 409 | res); |
371 | /* TODO: add actual error message from namestore to response... */ | ||
372 | if (GNUNET_SYSERR == res) | ||
373 | emsg = _ ("Namestore failed to store record\n"); | ||
374 | else | ||
375 | emsg = NULL; | ||
376 | if (NULL == qe) | 410 | if (NULL == qe) |
377 | return; | 411 | return; |
378 | if (NULL != qe->cont) | 412 | if (NULL != qe->cont) |
379 | qe->cont (qe->cont_cls, res, emsg); | 413 | qe->cont (qe->cont_cls, res, |
414 | (GNUNET_OK == res) ? NULL : emsg); | ||
380 | free_qe (qe); | 415 | free_qe (qe); |
381 | } | 416 | } |
382 | 417 | ||
@@ -444,8 +479,10 @@ handle_lookup_result (void *cls, const struct LabelLookupResponseMessage *msg) | |||
444 | size_t name_len; | 479 | size_t name_len; |
445 | size_t rd_len; | 480 | size_t rd_len; |
446 | unsigned int rd_count; | 481 | unsigned int rd_count; |
482 | int16_t found = (int16_t) ntohs (msg->found); | ||
447 | 483 | ||
448 | LOG (GNUNET_ERROR_TYPE_DEBUG, "Received RECORD_LOOKUP_RESULT\n"); | 484 | LOG (GNUNET_ERROR_TYPE_DEBUG, "Received RECORD_LOOKUP_RESULT (found=%i)\n", |
485 | found); | ||
449 | qe = find_qe (h, ntohl (msg->gns_header.r_id)); | 486 | qe = find_qe (h, ntohl (msg->gns_header.r_id)); |
450 | if (NULL == qe) | 487 | if (NULL == qe) |
451 | return; | 488 | return; |
@@ -453,7 +490,7 @@ handle_lookup_result (void *cls, const struct LabelLookupResponseMessage *msg) | |||
453 | rd_count = ntohs (msg->rd_count); | 490 | rd_count = ntohs (msg->rd_count); |
454 | name_len = ntohs (msg->name_len); | 491 | name_len = ntohs (msg->name_len); |
455 | name = (const char *) &msg[1]; | 492 | name = (const char *) &msg[1]; |
456 | if (GNUNET_NO == ntohs (msg->found)) | 493 | if (GNUNET_NO == found) |
457 | { | 494 | { |
458 | /* label was not in namestore */ | 495 | /* label was not in namestore */ |
459 | if (NULL != qe->proc) | 496 | if (NULL != qe->proc) |
@@ -461,6 +498,13 @@ handle_lookup_result (void *cls, const struct LabelLookupResponseMessage *msg) | |||
461 | free_qe (qe); | 498 | free_qe (qe); |
462 | return; | 499 | return; |
463 | } | 500 | } |
501 | if (GNUNET_SYSERR == found) | ||
502 | { | ||
503 | if (NULL != qe->error_cb) | ||
504 | qe->error_cb (qe->error_cb_cls); | ||
505 | free_qe (qe); | ||
506 | return; | ||
507 | } | ||
464 | 508 | ||
465 | rd_tmp = &name[name_len]; | 509 | rd_tmp = &name[name_len]; |
466 | { | 510 | { |
@@ -775,7 +819,7 @@ static void | |||
775 | reconnect (struct GNUNET_NAMESTORE_Handle *h) | 819 | reconnect (struct GNUNET_NAMESTORE_Handle *h) |
776 | { | 820 | { |
777 | struct GNUNET_MQ_MessageHandler handlers[] = | 821 | struct GNUNET_MQ_MessageHandler handlers[] = |
778 | { GNUNET_MQ_hd_fixed_size (record_store_response, | 822 | { GNUNET_MQ_hd_var_size (record_store_response, |
779 | GNUNET_MESSAGE_TYPE_NAMESTORE_RECORD_STORE_RESPONSE, | 823 | GNUNET_MESSAGE_TYPE_NAMESTORE_RECORD_STORE_RESPONSE, |
780 | struct RecordStoreResponseMessage, | 824 | struct RecordStoreResponseMessage, |
781 | h), | 825 | h), |
@@ -969,30 +1013,16 @@ warn_delay (void *cls) | |||
969 | GNUNET_NAMESTORE_cancel (qe); | 1013 | GNUNET_NAMESTORE_cancel (qe); |
970 | } | 1014 | } |
971 | 1015 | ||
972 | |||
973 | /** | ||
974 | * Store an item in the namestore. If the item is already present, | ||
975 | * it is replaced with the new record. Use an empty array to | ||
976 | * remove all records under the given name. | ||
977 | * | ||
978 | * @param h handle to the namestore | ||
979 | * @param pkey private key of the zone | ||
980 | * @param label name that is being mapped (at most 255 characters long) | ||
981 | * @param rd_count number of records in the @a rd array | ||
982 | * @param rd array of records with data to store | ||
983 | * @param cont continuation to call when done | ||
984 | * @param cont_cls closure for @a cont | ||
985 | * @return handle to abort the request | ||
986 | */ | ||
987 | struct GNUNET_NAMESTORE_QueueEntry * | 1016 | struct GNUNET_NAMESTORE_QueueEntry * |
988 | GNUNET_NAMESTORE_records_store ( | 1017 | records_store_ ( |
989 | struct GNUNET_NAMESTORE_Handle *h, | 1018 | struct GNUNET_NAMESTORE_Handle *h, |
990 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 1019 | const struct GNUNET_IDENTITY_PrivateKey *pkey, |
991 | const char *label, | 1020 | const char *label, |
992 | unsigned int rd_count, | 1021 | unsigned int rd_count, |
993 | const struct GNUNET_GNSRECORD_Data *rd, | 1022 | const struct GNUNET_GNSRECORD_Data *rd, |
994 | GNUNET_NAMESTORE_ContinuationWithStatus cont, | 1023 | GNUNET_NAMESTORE_ContinuationWithStatus cont, |
995 | void *cont_cls) | 1024 | void *cont_cls, |
1025 | int locking) | ||
996 | { | 1026 | { |
997 | struct GNUNET_NAMESTORE_QueueEntry *qe; | 1027 | struct GNUNET_NAMESTORE_QueueEntry *qe; |
998 | struct GNUNET_MQ_Envelope *env; | 1028 | struct GNUNET_MQ_Envelope *env; |
@@ -1037,8 +1067,9 @@ GNUNET_NAMESTORE_records_store ( | |||
1037 | msg->name_len = htons (name_len); | 1067 | msg->name_len = htons (name_len); |
1038 | msg->rd_count = htons (rd_count); | 1068 | msg->rd_count = htons (rd_count); |
1039 | msg->rd_len = htons (rd_ser_len); | 1069 | msg->rd_len = htons (rd_ser_len); |
1040 | msg->reserved = htons (0); | 1070 | msg->reserved = ntohs(0); |
1041 | msg->private_key = *pkey; | 1071 | msg->private_key = *pkey; |
1072 | msg->locking = htonl (locking); | ||
1042 | 1073 | ||
1043 | name_tmp = (char *) &msg[1]; | 1074 | name_tmp = (char *) &msg[1]; |
1044 | GNUNET_memcpy (name_tmp, label, name_len); | 1075 | GNUNET_memcpy (name_tmp, label, name_len); |
@@ -1070,28 +1101,45 @@ GNUNET_NAMESTORE_records_store ( | |||
1070 | return qe; | 1101 | return qe; |
1071 | } | 1102 | } |
1072 | 1103 | ||
1104 | struct GNUNET_NAMESTORE_QueueEntry * | ||
1105 | GNUNET_NAMESTORE_records_store ( | ||
1106 | struct GNUNET_NAMESTORE_Handle *h, | ||
1107 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | ||
1108 | const char *label, | ||
1109 | unsigned int rd_count, | ||
1110 | const struct GNUNET_GNSRECORD_Data *rd, | ||
1111 | GNUNET_NAMESTORE_ContinuationWithStatus cont, | ||
1112 | void *cont_cls) | ||
1113 | { | ||
1114 | return records_store_ (h, pkey, label, | ||
1115 | rd_count, rd, cont, cont_cls, GNUNET_NO); | ||
1116 | } | ||
1117 | |||
1118 | struct GNUNET_NAMESTORE_QueueEntry * | ||
1119 | GNUNET_NAMESTORE_records_commit ( | ||
1120 | struct GNUNET_NAMESTORE_Handle *h, | ||
1121 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | ||
1122 | const char *label, | ||
1123 | unsigned int rd_count, | ||
1124 | const struct GNUNET_GNSRECORD_Data *rd, | ||
1125 | GNUNET_NAMESTORE_ContinuationWithStatus cont, | ||
1126 | void *cont_cls) | ||
1127 | { | ||
1128 | return records_store_ (h, pkey, label, | ||
1129 | rd_count, rd, cont, cont_cls, GNUNET_YES); | ||
1130 | } | ||
1131 | |||
1073 | 1132 | ||
1074 | /** | ||
1075 | * Lookup an item in the namestore. | ||
1076 | * | ||
1077 | * @param h handle to the namestore | ||
1078 | * @param pkey private key of the zone | ||
1079 | * @param label name that is being mapped (at most 255 characters long) | ||
1080 | * @param error_cb function to call on error (i.e. disconnect) | ||
1081 | * @param error_cb_cls closure for @a error_cb | ||
1082 | * @param rm function to call with the result (with 0 records if we don't have that label) | ||
1083 | * @param rm_cls closure for @a rm | ||
1084 | * @return handle to abort the request | ||
1085 | */ | ||
1086 | struct GNUNET_NAMESTORE_QueueEntry * | 1133 | struct GNUNET_NAMESTORE_QueueEntry * |
1087 | GNUNET_NAMESTORE_records_lookup ( | 1134 | records_lookup_ ( |
1088 | struct GNUNET_NAMESTORE_Handle *h, | 1135 | struct GNUNET_NAMESTORE_Handle *h, |
1089 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | 1136 | const struct GNUNET_IDENTITY_PrivateKey *pkey, |
1090 | const char *label, | 1137 | const char *label, |
1091 | GNUNET_SCHEDULER_TaskCallback error_cb, | 1138 | GNUNET_SCHEDULER_TaskCallback error_cb, |
1092 | void *error_cb_cls, | 1139 | void *error_cb_cls, |
1093 | GNUNET_NAMESTORE_RecordMonitor rm, | 1140 | GNUNET_NAMESTORE_RecordMonitor rm, |
1094 | void *rm_cls) | 1141 | void *rm_cls, |
1142 | int locking) | ||
1095 | { | 1143 | { |
1096 | struct GNUNET_NAMESTORE_QueueEntry *qe; | 1144 | struct GNUNET_NAMESTORE_QueueEntry *qe; |
1097 | struct GNUNET_MQ_Envelope *env; | 1145 | struct GNUNET_MQ_Envelope *env; |
@@ -1119,6 +1167,7 @@ GNUNET_NAMESTORE_records_lookup ( | |||
1119 | msg->gns_header.r_id = htonl (qe->op_id); | 1167 | msg->gns_header.r_id = htonl (qe->op_id); |
1120 | msg->zone = *pkey; | 1168 | msg->zone = *pkey; |
1121 | msg->label_len = htonl (label_len); | 1169 | msg->label_len = htonl (label_len); |
1170 | msg->locking = htonl (locking); | ||
1122 | GNUNET_memcpy (&msg[1], label, label_len); | 1171 | GNUNET_memcpy (&msg[1], label, label_len); |
1123 | if (NULL == h->mq) | 1172 | if (NULL == h->mq) |
1124 | qe->env = env; | 1173 | qe->env = env; |
@@ -1127,22 +1176,34 @@ GNUNET_NAMESTORE_records_lookup ( | |||
1127 | return qe; | 1176 | return qe; |
1128 | } | 1177 | } |
1129 | 1178 | ||
1179 | struct GNUNET_NAMESTORE_QueueEntry * | ||
1180 | GNUNET_NAMESTORE_records_lookup ( | ||
1181 | struct GNUNET_NAMESTORE_Handle *h, | ||
1182 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | ||
1183 | const char *label, | ||
1184 | GNUNET_SCHEDULER_TaskCallback error_cb, | ||
1185 | void *error_cb_cls, | ||
1186 | GNUNET_NAMESTORE_RecordMonitor rm, | ||
1187 | void *rm_cls) | ||
1188 | { | ||
1189 | return records_lookup_ (h, pkey, label, | ||
1190 | error_cb, error_cb_cls, rm, rm_cls, GNUNET_NO); | ||
1191 | } | ||
1192 | |||
1193 | struct GNUNET_NAMESTORE_QueueEntry * | ||
1194 | GNUNET_NAMESTORE_records_open ( | ||
1195 | struct GNUNET_NAMESTORE_Handle *h, | ||
1196 | const struct GNUNET_IDENTITY_PrivateKey *pkey, | ||
1197 | const char *label, | ||
1198 | GNUNET_SCHEDULER_TaskCallback error_cb, | ||
1199 | void *error_cb_cls, | ||
1200 | GNUNET_NAMESTORE_RecordMonitor rm, | ||
1201 | void *rm_cls) | ||
1202 | { | ||
1203 | return records_lookup_ (h, pkey, label, | ||
1204 | error_cb, error_cb_cls, rm, rm_cls, GNUNET_YES); | ||
1205 | } | ||
1130 | 1206 | ||
1131 | /** | ||
1132 | * Look for an existing PKEY delegation record for a given public key. | ||
1133 | * Returns at most one result to the processor. | ||
1134 | * | ||
1135 | * @param h handle to the namestore | ||
1136 | * @param zone public key of the zone to look up in, never NULL | ||
1137 | * @param value_zone public key of the target zone (value), never NULL | ||
1138 | * @param error_cb function to call on error (i.e. disconnect) | ||
1139 | * @param error_cb_cls closure for @a error_cb | ||
1140 | * @param proc function to call on the matching records, or with | ||
1141 | * NULL (rd_count == 0) if there are no matching records | ||
1142 | * @param proc_cls closure for @a proc | ||
1143 | * @return a handle that can be used to | ||
1144 | * cancel | ||
1145 | */ | ||
1146 | struct GNUNET_NAMESTORE_QueueEntry * | 1207 | struct GNUNET_NAMESTORE_QueueEntry * |
1147 | GNUNET_NAMESTORE_zone_to_name ( | 1208 | GNUNET_NAMESTORE_zone_to_name ( |
1148 | struct GNUNET_NAMESTORE_Handle *h, | 1209 | struct GNUNET_NAMESTORE_Handle *h, |
diff --git a/src/namestore/plugin_namestore_sqlite.c b/src/namestore/plugin_namestore_sqlite.c index 7cb9b7ed0..0b3aac84f 100644 --- a/src/namestore/plugin_namestore_sqlite.c +++ b/src/namestore/plugin_namestore_sqlite.c | |||
@@ -329,6 +329,11 @@ 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 | { | ||
333 | LOG (GNUNET_ERROR_TYPE_DEBUG, | ||
334 | "Checking if `%d' is zonekey type\n", | ||
335 | rd[i].record_type); | ||
336 | |||
332 | if (GNUNET_YES == GNUNET_GNSRECORD_is_zonekey_type (rd[i].record_type)) | 337 | if (GNUNET_YES == GNUNET_GNSRECORD_is_zonekey_type (rd[i].record_type)) |
333 | { | 338 | { |
334 | GNUNET_break (GNUNET_YES == | 339 | GNUNET_break (GNUNET_YES == |
@@ -336,8 +341,13 @@ namestore_sqlite_store_records (void *cls, | |||
336 | rd[i].data_size, | 341 | rd[i].data_size, |
337 | rd[i].record_type, | 342 | rd[i].record_type, |
338 | &pkey)); | 343 | &pkey)); |
344 | LOG (GNUNET_ERROR_TYPE_DEBUG, | ||
345 | "Storing delegation zone record value `%s'\n", | ||
346 | GNUNET_GNSRECORD_z2s (&pkey)); | ||
347 | |||
339 | break; | 348 | break; |
340 | } | 349 | } |
350 | } | ||
341 | rvalue = GNUNET_CRYPTO_random_u64 (GNUNET_CRYPTO_QUALITY_WEAK, | 351 | rvalue = GNUNET_CRYPTO_random_u64 (GNUNET_CRYPTO_QUALITY_WEAK, |
342 | UINT64_MAX); | 352 | UINT64_MAX); |
343 | data_size = GNUNET_GNSRECORD_records_get_size (rd_count, | 353 | data_size = GNUNET_GNSRECORD_records_get_size (rd_count, |
diff --git a/src/namestore/test_namestore_api_lookup_nick.c b/src/namestore/test_namestore_api_lookup_nick.c index 6ce969c9b..7decf39f8 100644 --- a/src/namestore/test_namestore_api_lookup_nick.c +++ b/src/namestore/test_namestore_api_lookup_nick.c | |||
@@ -262,12 +262,12 @@ nick_cont (void *cls, int32_t success, const char *emsg) | |||
262 | "Nick added : %s\n", | 262 | "Nick added : %s\n", |
263 | (success == GNUNET_OK) ? "SUCCESS" : "FAIL"); | 263 | (success == GNUNET_OK) ? "SUCCESS" : "FAIL"); |
264 | 264 | ||
265 | rd_orig.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us; | 265 | rd_orig.expiration_time = GNUNET_TIME_UNIT_HOURS.rel_value_us; |
266 | rd_orig.record_type = TEST_RECORD_TYPE; | 266 | rd_orig.record_type = TEST_RECORD_TYPE; |
267 | rd_orig.data_size = TEST_RECORD_DATALEN; | 267 | rd_orig.data_size = TEST_RECORD_DATALEN; |
268 | record_data = GNUNET_malloc (TEST_RECORD_DATALEN); | 268 | record_data = GNUNET_malloc (TEST_RECORD_DATALEN); |
269 | rd_orig.data = record_data; | 269 | rd_orig.data = record_data; |
270 | rd_orig.flags = 0; | 270 | rd_orig.flags = GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION; |
271 | memset ((char *) rd_orig.data, 'a', TEST_RECORD_DATALEN); | 271 | memset ((char *) rd_orig.data, 'a', TEST_RECORD_DATALEN); |
272 | 272 | ||
273 | nsqe = GNUNET_NAMESTORE_records_store (nsh, &privkey, | 273 | nsqe = GNUNET_NAMESTORE_records_store (nsh, &privkey, |
diff --git a/src/namestore/test_namestore_api_lookup_public.c b/src/namestore/test_namestore_api_lookup_public.c index 5e3e7bbd8..cd69b96ef 100644 --- a/src/namestore/test_namestore_api_lookup_public.c +++ b/src/namestore/test_namestore_api_lookup_public.c | |||
@@ -188,7 +188,7 @@ run (void *cls, | |||
188 | struct GNUNET_TESTING_Peer *peer) | 188 | struct GNUNET_TESTING_Peer *peer) |
189 | { | 189 | { |
190 | struct GNUNET_GNSRECORD_Data rd; | 190 | struct GNUNET_GNSRECORD_Data rd; |
191 | const char *name = "dummy.dummy.gnunet"; | 191 | const char *name = "dummy"; |
192 | 192 | ||
193 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, | 193 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, |
194 | &endbadly, | 194 | &endbadly, |
diff --git a/src/namestore/test_namestore_api_lookup_shadow.c b/src/namestore/test_namestore_api_lookup_shadow.c index 79fa4c9c6..8f47d1280 100644 --- a/src/namestore/test_namestore_api_lookup_shadow.c +++ b/src/namestore/test_namestore_api_lookup_shadow.c | |||
@@ -223,7 +223,7 @@ run (void *cls, | |||
223 | struct GNUNET_TESTING_Peer *peer) | 223 | struct GNUNET_TESTING_Peer *peer) |
224 | { | 224 | { |
225 | struct GNUNET_GNSRECORD_Data rd; | 225 | struct GNUNET_GNSRECORD_Data rd; |
226 | const char *name = "dummy.dummy.gnunet"; | 226 | const char *name = "dummy"; |
227 | 227 | ||
228 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, | 228 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, |
229 | &endbadly, | 229 | &endbadly, |
diff --git a/src/namestore/test_namestore_api_lookup_shadow_filter.c b/src/namestore/test_namestore_api_lookup_shadow_filter.c index 4fc197750..0bcd130f9 100644 --- a/src/namestore/test_namestore_api_lookup_shadow_filter.c +++ b/src/namestore/test_namestore_api_lookup_shadow_filter.c | |||
@@ -32,7 +32,7 @@ | |||
32 | 32 | ||
33 | #define TEST_RECORD_TYPE GNUNET_DNSPARSER_TYPE_TXT | 33 | #define TEST_RECORD_TYPE GNUNET_DNSPARSER_TYPE_TXT |
34 | 34 | ||
35 | #define TEST_NAME "dummy.dummy.gnunet" | 35 | #define TEST_NAME "gnunet" |
36 | #define TEST_RECORD_DATALEN 123 | 36 | #define TEST_RECORD_DATALEN 123 |
37 | #define TEST_RECORD_DATA 'a' | 37 | #define TEST_RECORD_DATA 'a' |
38 | #define TEST_SHADOW_RECORD_DATA 'b' | 38 | #define TEST_SHADOW_RECORD_DATA 'b' |
diff --git a/src/namestore/test_namestore_api_remove.c b/src/namestore/test_namestore_api_remove.c index b6254e531..e8124c595 100644 --- a/src/namestore/test_namestore_api_remove.c +++ b/src/namestore/test_namestore_api_remove.c | |||
@@ -153,7 +153,7 @@ run (void *cls, | |||
153 | struct GNUNET_TESTING_Peer *peer) | 153 | struct GNUNET_TESTING_Peer *peer) |
154 | { | 154 | { |
155 | struct GNUNET_GNSRECORD_Data rd; | 155 | struct GNUNET_GNSRECORD_Data rd; |
156 | const char *name = "dummy.dummy.gnunet"; | 156 | const char *name = "dummy"; |
157 | 157 | ||
158 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, | 158 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, |
159 | &endbadly, | 159 | &endbadly, |
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 e66992909..958ea4bf2 100644 --- a/src/namestore/test_namestore_api_remove_not_existing_record.c +++ b/src/namestore/test_namestore_api_remove_not_existing_record.c | |||
@@ -127,7 +127,7 @@ run (void *cls, | |||
127 | const struct GNUNET_CONFIGURATION_Handle *cfg, | 127 | const struct GNUNET_CONFIGURATION_Handle *cfg, |
128 | struct GNUNET_TESTING_Peer *peer) | 128 | struct GNUNET_TESTING_Peer *peer) |
129 | { | 129 | { |
130 | const char *name = "dummy.dummy.gnunet"; | 130 | const char *name = "dummy"; |
131 | 131 | ||
132 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, | 132 | endbadly_task = GNUNET_SCHEDULER_add_delayed (TIMEOUT, |
133 | &endbadly, | 133 | &endbadly, |
diff --git a/src/namestore/test_namestore_api_zone_to_name.c b/src/namestore/test_namestore_api_zone_to_name.c index 3fd10e4a1..1e2f8248b 100644 --- a/src/namestore/test_namestore_api_zone_to_name.c +++ b/src/namestore/test_namestore_api_zone_to_name.c | |||
@@ -216,11 +216,11 @@ run (void *cls, | |||
216 | { | 216 | { |
217 | struct GNUNET_GNSRECORD_Data rd; | 217 | struct GNUNET_GNSRECORD_Data rd; |
218 | 218 | ||
219 | rd.expiration_time = GNUNET_TIME_absolute_get ().abs_value_us; | 219 | rd.expiration_time = GNUNET_TIME_UNIT_HOURS.rel_value_us; |
220 | rd.record_type = GNUNET_GNSRECORD_TYPE_PKEY; | 220 | rd.record_type = GNUNET_GNSRECORD_TYPE_PKEY; |
221 | rd.data_size = GNUNET_IDENTITY_key_get_length (&s_zone_value); | 221 | rd.data_size = sizeof (s_zone_value.ecdsa_key); |
222 | rd.data = &s_zone_value; | 222 | rd.data = &s_zone_value.ecdsa_key; |
223 | rd.flags = 0; | 223 | rd.flags = GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION; |
224 | 224 | ||
225 | nsh = GNUNET_NAMESTORE_connect (cfg); | 225 | nsh = GNUNET_NAMESTORE_connect (cfg); |
226 | GNUNET_break (NULL != nsh); | 226 | GNUNET_break (NULL != nsh); |
@@ -230,7 +230,7 @@ run (void *cls, | |||
230 | 1, | 230 | 1, |
231 | &rd, | 231 | &rd, |
232 | &put_cont, | 232 | &put_cont, |
233 | NULL); | 233 | s_name); |
234 | } | 234 | } |
235 | } | 235 | } |
236 | 236 | ||
diff --git a/src/namestore/test_namestore_delete.sh b/src/namestore/test_namestore_delete.sh index 44ea1e66c..b861a4bc0 100755 --- a/src/namestore/test_namestore_delete.sh +++ b/src/namestore/test_namestore_delete.sh | |||
@@ -61,15 +61,7 @@ for LINE in $OUTPUT ; | |||
61 | stop_peer | 61 | stop_peer |
62 | 62 | ||
63 | 63 | ||
64 | if [ $FOUND_NAME = false -a $FOUND_IP != false ] | 64 | if [ $FOUND_IP = true ] |
65 | then | ||
66 | echo "PASS: Delete name in namestore" | ||
67 | exit 0 | ||
68 | elif [ $FOUND_NAME = true ] | ||
69 | then | ||
70 | echo "FAIL: Delete name in namestore: name returned" | ||
71 | exit 1 | ||
72 | elif [ $FOUND_IP = true ] | ||
73 | then | 65 | then |
74 | echo "FAIL: Delete name in namestore: IP returned" | 66 | echo "FAIL: Delete name in namestore: IP returned" |
75 | exit 1 | 67 | exit 1 |
diff --git a/src/namestore/test_plugin_rest_namestore.sh b/src/namestore/test_plugin_rest_namestore.sh index 8a45cebf5..50b3c8c12 100755 --- a/src/namestore/test_plugin_rest_namestore.sh +++ b/src/namestore/test_plugin_rest_namestore.sh | |||
@@ -78,15 +78,16 @@ curl_delete () { | |||
78 | 78 | ||
79 | TEST_ID="test" | 79 | TEST_ID="test" |
80 | gnunet-arm -s -c test_namestore_api.conf | 80 | gnunet-arm -s -c test_namestore_api.conf |
81 | gnunet-arm -i rest -c test_namestore_api.conf | ||
82 | #Test GET | 81 | #Test GET |
83 | gnunet-identity -C $TEST_ID -c test_namestore_api.conf | 82 | gnunet-identity -C $TEST_ID -c test_namestore_api.conf |
84 | test="$(gnunet-namestore -D -z $TEST_ID -c test_namestore_api.conf)" | 83 | test="$(gnunet-namestore -D -z $TEST_ID -c test_namestore_api.conf)" |
85 | name=$TEST_ID | 84 | name=$TEST_ID |
86 | public="$(gnunet-identity -d -c test_namestore_api.conf | grep $TEST_ID | awk 'NR==1{print $3}')" | 85 | public="$(gnunet-identity -d -c test_namestore_api.conf | grep $TEST_ID | awk 'NR==1{print $3}')" |
87 | echo "$name $public" | 86 | 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 | 87 | gnunet-namestore -z $name -p -a -n "test_entry" -e "1d" -V "000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8" -t "PKEY" -c test_namestore_api.conf |
89 | #curl_get "${namestore_link}" "HTTP/1.1 200 OK" | 88 | sleep 1 |
89 | gnunet-arm -i rest -c test_namestore_api.conf | ||
90 | sleep 1 | ||
90 | curl_get "${namestore_link}/$name" "HTTP/1.1 200 OK" | 91 | curl_get "${namestore_link}/$name" "HTTP/1.1 200 OK" |
91 | curl_get "${namestore_link}/$public" "error" | 92 | curl_get "${namestore_link}/$public" "error" |
92 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf | 93 | gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf |
@@ -128,9 +129,6 @@ gnunet-namestore -z $name -d -n "test_entry" -c test_namestore_api.conf > /dev/ | |||
128 | #Test DELETE | 129 | #Test DELETE |
129 | gnunet-namestore -z $name -p -a -n "test_entry" -e "1d" -V "000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8" -t "PKEY" -c test_namestore_api.conf | 130 | gnunet-namestore -z $name -p -a -n "test_entry" -e "1d" -V "000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8" -t "PKEY" -c test_namestore_api.conf |
130 | curl_delete "${namestore_link}/$name/test_entry" "HTTP/1.1 204" | 131 | curl_delete "${namestore_link}/$name/test_entry" "HTTP/1.1 204" |
131 | curl_delete "${namestore_link}/$name/test_entry" "error" | ||
132 | gnunet-namestore -z $name -p -a -n "test_entry" -e "1d" -V "000G006WVZ8HQ5YTVFNX09HK0VJVVQ9ZCBYDSCH3ERT04N5ZRBKEB82EP8" -t "PKEY" -c test_namestore_api.conf | ||
133 | curl_delete "${namestore_link}/$public/test_entry" "error" | ||
134 | 132 | ||
135 | gnunet-arm -e -c test_namestore_api.conf | 133 | gnunet-arm -e -c test_namestore_api.conf |
136 | exit 0; | 134 | exit 0; |
diff --git a/src/reclaim/reclaim_api.c b/src/reclaim/reclaim_api.c index f41473f9f..bc6b835c9 100644 --- a/src/reclaim/reclaim_api.c +++ b/src/reclaim/reclaim_api.c | |||
@@ -1550,7 +1550,6 @@ GNUNET_RECLAIM_ticket_issue ( | |||
1550 | struct IssueTicketMessage *tim; | 1550 | struct IssueTicketMessage *tim; |
1551 | size_t attr_len; | 1551 | size_t attr_len; |
1552 | 1552 | ||
1553 | fprintf (stderr, "Issuing ticket\n"); | ||
1554 | op = GNUNET_new (struct GNUNET_RECLAIM_Operation); | 1553 | op = GNUNET_new (struct GNUNET_RECLAIM_Operation); |
1555 | op->h = h; | 1554 | op->h = h; |
1556 | op->ti_cb = cb; | 1555 | op->ti_cb = cb; |
diff --git a/src/reclaim/test_reclaim.conf b/src/reclaim/test_reclaim.conf index ec19056e4..2dc53fe81 100644 --- a/src/reclaim/test_reclaim.conf +++ b/src/reclaim/test_reclaim.conf | |||
@@ -15,7 +15,7 @@ PLUGINS = | |||
15 | 15 | ||
16 | [reclaim] | 16 | [reclaim] |
17 | START_ON_DEMAND = YES | 17 | START_ON_DEMAND = YES |
18 | TICKET_REFRESH_INTERVAL = 15s | 18 | TICKET_REFRESH_INTERVAL = 30 s |
19 | #PREFIX = valgrind --leak-check=full --show-leak-kinds=all --track-origins=yes --log-file=$GNUNET_TMP/idplog | 19 | #PREFIX = valgrind --leak-check=full --show-leak-kinds=all --track-origins=yes --log-file=$GNUNET_TMP/idplog |
20 | 20 | ||
21 | [gns] | 21 | [gns] |
diff --git a/src/reclaim/test_reclaim_consume.sh b/src/reclaim/test_reclaim_consume.sh index 9186d3cb1..c012862c3 100755 --- a/src/reclaim/test_reclaim_consume.sh +++ b/src/reclaim/test_reclaim_consume.sh | |||
@@ -32,12 +32,14 @@ TEST_KEY=$(gnunet-identity -d -e testego -q -c test_reclaim.conf) | |||
32 | gnunet-reclaim -e testego -a email -V john@doe.gnu -c test_reclaim.conf | 32 | gnunet-reclaim -e testego -a email -V john@doe.gnu -c test_reclaim.conf |
33 | gnunet-reclaim -e testego -a name -V John -c test_reclaim.conf | 33 | gnunet-reclaim -e testego -a name -V John -c test_reclaim.conf |
34 | TICKET=$(gnunet-reclaim -e testego -i "email,name" -r $SUBJECT_KEY -c test_reclaim.conf | awk '{print $1}') | 34 | TICKET=$(gnunet-reclaim -e testego -i "email,name" -r $SUBJECT_KEY -c test_reclaim.conf | awk '{print $1}') |
35 | gnunet-reclaim -e rpego -C $TICKET -c test_reclaim.conf >/dev/null 2>&1 | 35 | gnunet-reclaim -e rpego -C $TICKET -c test_reclaim.conf #>/dev/null 2>&1 |
36 | 36 | ||
37 | if test $? != 0 | 37 | RES=$? |
38 | gnunet-identity -D testego -c test_reclaim.conf | ||
39 | gnunet-identity -D rpego -c test_reclaim.conf | ||
40 | gnunet-arm -e -c test_reclaim.conf | ||
41 | if test $RES != 0 | ||
38 | then | 42 | then |
39 | "Failed." | 43 | echo "Failed." |
40 | exit 1 | ||
41 | fi | 44 | fi |
42 | #curl http://localhost:7776/reclaim/tickets/testego | 45 | |
43 | gnunet-arm -e -c test_reclaim.conf | ||
diff --git a/src/regex/plugin_block_regex.c b/src/regex/plugin_block_regex.c index 0953830ab..61442ac10 100644 --- a/src/regex/plugin_block_regex.c +++ b/src/regex/plugin_block_regex.c | |||
@@ -93,242 +93,6 @@ block_plugin_regex_create_group (void *cls, | |||
93 | 93 | ||
94 | 94 | ||
95 | /** | 95 | /** |
96 | * Function called to validate a reply or a request of type | ||
97 | * #GNUNET_BLOCK_TYPE_REGEX. | ||
98 | * For request evaluation, pass "NULL" for the reply_block. | ||
99 | * Note that it is assumed that the reply has already been | ||
100 | * matched to the key (and signatures checked) as it would | ||
101 | * be done with the #GNUNET_BLOCK_get_key() function. | ||
102 | * | ||
103 | * @param cls closure | ||
104 | * @param type block type | ||
105 | * @param bg block group to evaluate against | ||
106 | * @param eo control flags | ||
107 | * @param query original query (hash) | ||
108 | * @param xquery extrended query data (can be NULL, depending on type) | ||
109 | * @param xquery_size number of bytes in @a xquery | ||
110 | * @param reply_block response to validate | ||
111 | * @param reply_block_size number of bytes in @a reply_block | ||
112 | * @return characterization of result | ||
113 | */ | ||
114 | static enum GNUNET_BLOCK_EvaluationResult | ||
115 | evaluate_block_regex (void *cls, | ||
116 | enum GNUNET_BLOCK_Type type, | ||
117 | struct GNUNET_BLOCK_Group *bg, | ||
118 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
119 | const struct GNUNET_HashCode *query, | ||
120 | const void *xquery, | ||
121 | size_t xquery_size, | ||
122 | const void *reply_block, | ||
123 | size_t reply_block_size) | ||
124 | { | ||
125 | struct GNUNET_HashCode chash; | ||
126 | |||
127 | if (NULL == reply_block) | ||
128 | { | ||
129 | if (0 != xquery_size) | ||
130 | { | ||
131 | const char *s; | ||
132 | |||
133 | s = (const char *) xquery; | ||
134 | if ('\0' != s[xquery_size - 1]) /* must be valid 0-terminated string */ | ||
135 | { | ||
136 | GNUNET_break_op (0); | ||
137 | return GNUNET_BLOCK_EVALUATION_REQUEST_INVALID; | ||
138 | } | ||
139 | } | ||
140 | return GNUNET_BLOCK_EVALUATION_REQUEST_VALID; | ||
141 | } | ||
142 | if (0 != xquery_size) | ||
143 | { | ||
144 | const char *s; | ||
145 | |||
146 | s = (const char *) xquery; | ||
147 | if ('\0' != s[xquery_size - 1]) /* must be valid 0-terminated string */ | ||
148 | { | ||
149 | GNUNET_break_op (0); | ||
150 | return GNUNET_BLOCK_EVALUATION_REQUEST_INVALID; | ||
151 | } | ||
152 | } | ||
153 | else if (NULL != query) | ||
154 | { | ||
155 | /* xquery is required for regex GETs, at least an empty string */ | ||
156 | GNUNET_break_op (0); | ||
157 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, "type %d, query %p, xquery %p\n", | ||
158 | type, query, xquery); | ||
159 | return GNUNET_BLOCK_EVALUATION_REQUEST_INVALID; | ||
160 | } | ||
161 | switch (REGEX_BLOCK_check (reply_block, | ||
162 | reply_block_size, | ||
163 | query, | ||
164 | xquery)) | ||
165 | { | ||
166 | case GNUNET_SYSERR: | ||
167 | GNUNET_break_op (0); | ||
168 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
169 | |||
170 | case GNUNET_NO: | ||
171 | /* xquery mismatch, can happen */ | ||
172 | return GNUNET_BLOCK_EVALUATION_RESULT_IRRELEVANT; | ||
173 | |||
174 | default: | ||
175 | break; | ||
176 | } | ||
177 | GNUNET_CRYPTO_hash (reply_block, | ||
178 | reply_block_size, | ||
179 | &chash); | ||
180 | if (GNUNET_YES == | ||
181 | GNUNET_BLOCK_GROUP_bf_test_and_set (bg, | ||
182 | &chash)) | ||
183 | return GNUNET_BLOCK_EVALUATION_OK_DUPLICATE; | ||
184 | return GNUNET_BLOCK_EVALUATION_OK_MORE; | ||
185 | } | ||
186 | |||
187 | |||
188 | /** | ||
189 | * Function called to validate a reply or a request of type | ||
190 | * #GNUNET_BLOCK_TYPE_REGEX_ACCEPT. | ||
191 | * For request evaluation, pass "NULL" for the reply_block. | ||
192 | * Note that it is assumed that the reply has already been | ||
193 | * matched to the key (and signatures checked) as it would | ||
194 | * be done with the #GNUNET_BLOCK_get_key() function. | ||
195 | * | ||
196 | * @param cls closure | ||
197 | * @param type block type | ||
198 | * @param bg block group to evaluate against | ||
199 | * @param eo control flags | ||
200 | * @param query original query (hash) | ||
201 | * @param xquery extrended query data (can be NULL, depending on type) | ||
202 | * @param xquery_size number of bytes in @a xquery | ||
203 | * @param reply_block response to validate | ||
204 | * @param reply_block_size number of bytes in @a reply_block | ||
205 | * @return characterization of result | ||
206 | */ | ||
207 | static enum GNUNET_BLOCK_EvaluationResult | ||
208 | evaluate_block_regex_accept (void *cls, | ||
209 | enum GNUNET_BLOCK_Type type, | ||
210 | struct GNUNET_BLOCK_Group *bg, | ||
211 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
212 | const struct GNUNET_HashCode *query, | ||
213 | const void *xquery, | ||
214 | size_t xquery_size, const void *reply_block, | ||
215 | size_t reply_block_size) | ||
216 | { | ||
217 | const struct RegexAcceptBlock *rba; | ||
218 | struct GNUNET_HashCode chash; | ||
219 | |||
220 | if (0 != xquery_size) | ||
221 | { | ||
222 | GNUNET_break_op (0); | ||
223 | return GNUNET_BLOCK_EVALUATION_REQUEST_INVALID; | ||
224 | } | ||
225 | if (NULL == reply_block) | ||
226 | return GNUNET_BLOCK_EVALUATION_REQUEST_VALID; | ||
227 | if (sizeof(struct RegexAcceptBlock) != reply_block_size) | ||
228 | { | ||
229 | GNUNET_break_op (0); | ||
230 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
231 | } | ||
232 | rba = reply_block; | ||
233 | if (ntohl (rba->purpose.size) != | ||
234 | sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) | ||
235 | + sizeof(struct GNUNET_TIME_AbsoluteNBO) | ||
236 | + sizeof(struct GNUNET_HashCode)) | ||
237 | { | ||
238 | GNUNET_break_op (0); | ||
239 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
240 | } | ||
241 | if (0 == GNUNET_TIME_absolute_get_remaining (GNUNET_TIME_absolute_ntoh ( | ||
242 | rba->expiration_time)). | ||
243 | rel_value_us) | ||
244 | { | ||
245 | /* technically invalid, but can happen without an error, so | ||
246 | we're nice by reporting it as a 'duplicate' */ | ||
247 | return GNUNET_BLOCK_EVALUATION_OK_DUPLICATE; | ||
248 | } | ||
249 | if (GNUNET_OK != | ||
250 | GNUNET_CRYPTO_eddsa_verify_ (GNUNET_SIGNATURE_PURPOSE_REGEX_ACCEPT, | ||
251 | &rba->purpose, | ||
252 | &rba->signature, | ||
253 | &rba->peer.public_key)) | ||
254 | { | ||
255 | GNUNET_break_op (0); | ||
256 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
257 | } | ||
258 | GNUNET_CRYPTO_hash (reply_block, | ||
259 | reply_block_size, | ||
260 | &chash); | ||
261 | if (GNUNET_YES == | ||
262 | GNUNET_BLOCK_GROUP_bf_test_and_set (bg, | ||
263 | &chash)) | ||
264 | return GNUNET_BLOCK_EVALUATION_OK_DUPLICATE; | ||
265 | return GNUNET_BLOCK_EVALUATION_OK_MORE; | ||
266 | } | ||
267 | |||
268 | |||
269 | /** | ||
270 | * Function called to validate a reply or a request. For | ||
271 | * request evaluation, simply pass "NULL" for the reply_block. | ||
272 | * Note that it is assumed that the reply has already been | ||
273 | * matched to the key (and signatures checked) as it would | ||
274 | * be done with the #GNUNET_BLOCK_get_key() function. | ||
275 | * | ||
276 | * @param cls closure | ||
277 | * @param ctx block context | ||
278 | * @param type block type | ||
279 | * @param bg group to evaluate against | ||
280 | * @param eo control flags | ||
281 | * @param query original query (hash) | ||
282 | * @param xquery extrended query data (can be NULL, depending on type) | ||
283 | * @param xquery_size number of bytes in xquery | ||
284 | * @param reply_block response to validate | ||
285 | * @param reply_block_size number of bytes in reply block | ||
286 | * @return characterization of result | ||
287 | */ | ||
288 | static enum GNUNET_BLOCK_EvaluationResult | ||
289 | block_plugin_regex_evaluate (void *cls, | ||
290 | struct GNUNET_BLOCK_Context *ctx, | ||
291 | enum GNUNET_BLOCK_Type type, | ||
292 | struct GNUNET_BLOCK_Group *bg, | ||
293 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
294 | const struct GNUNET_HashCode *query, | ||
295 | const void *xquery, | ||
296 | size_t xquery_size, | ||
297 | const void *reply_block, | ||
298 | size_t reply_block_size) | ||
299 | { | ||
300 | enum GNUNET_BLOCK_EvaluationResult result; | ||
301 | |||
302 | switch (type) | ||
303 | { | ||
304 | case GNUNET_BLOCK_TYPE_REGEX: | ||
305 | result = evaluate_block_regex (cls, | ||
306 | type, | ||
307 | bg, | ||
308 | eo, | ||
309 | query, | ||
310 | xquery, xquery_size, | ||
311 | reply_block, reply_block_size); | ||
312 | break; | ||
313 | |||
314 | case GNUNET_BLOCK_TYPE_REGEX_ACCEPT: | ||
315 | result = evaluate_block_regex_accept (cls, | ||
316 | type, | ||
317 | bg, | ||
318 | eo, | ||
319 | query, | ||
320 | xquery, xquery_size, | ||
321 | reply_block, reply_block_size); | ||
322 | break; | ||
323 | |||
324 | default: | ||
325 | result = GNUNET_BLOCK_EVALUATION_TYPE_NOT_SUPPORTED; | ||
326 | } | ||
327 | return result; | ||
328 | } | ||
329 | |||
330 | |||
331 | /** | ||
332 | * Function called to validate a query. | 96 | * Function called to validate a query. |
333 | * | 97 | * |
334 | * @param cls closure | 98 | * @param cls closure |
@@ -341,10 +105,10 @@ block_plugin_regex_evaluate (void *cls, | |||
341 | */ | 105 | */ |
342 | static enum GNUNET_GenericReturnValue | 106 | static enum GNUNET_GenericReturnValue |
343 | block_plugin_regex_check_query (void *cls, | 107 | block_plugin_regex_check_query (void *cls, |
344 | enum GNUNET_BLOCK_Type type, | 108 | enum GNUNET_BLOCK_Type type, |
345 | const struct GNUNET_HashCode *query, | 109 | const struct GNUNET_HashCode *query, |
346 | const void *xquery, | 110 | const void *xquery, |
347 | size_t xquery_size) | 111 | size_t xquery_size) |
348 | { | 112 | { |
349 | switch (type) | 113 | switch (type) |
350 | { | 114 | { |
@@ -380,7 +144,6 @@ block_plugin_regex_check_query (void *cls, | |||
380 | * | 144 | * |
381 | * @param cls closure | 145 | * @param cls closure |
382 | * @param type block type | 146 | * @param type block type |
383 | * @param query key for the block (hash), must match exactly | ||
384 | * @param block block data to validate | 147 | * @param block block data to validate |
385 | * @param block_size number of bytes in @a block | 148 | * @param block_size number of bytes in @a block |
386 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not | 149 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not |
@@ -388,7 +151,6 @@ block_plugin_regex_check_query (void *cls, | |||
388 | static enum GNUNET_GenericReturnValue | 151 | static enum GNUNET_GenericReturnValue |
389 | block_plugin_regex_check_block (void *cls, | 152 | block_plugin_regex_check_block (void *cls, |
390 | enum GNUNET_BLOCK_Type type, | 153 | enum GNUNET_BLOCK_Type type, |
391 | const struct GNUNET_HashCode *query, | ||
392 | const void *block, | 154 | const void *block, |
393 | size_t block_size) | 155 | size_t block_size) |
394 | { | 156 | { |
@@ -398,7 +160,7 @@ block_plugin_regex_check_block (void *cls, | |||
398 | if (GNUNET_SYSERR == | 160 | if (GNUNET_SYSERR == |
399 | REGEX_BLOCK_check (block, | 161 | REGEX_BLOCK_check (block, |
400 | block_size, | 162 | block_size, |
401 | query, | 163 | NULL, |
402 | NULL)) | 164 | NULL)) |
403 | return GNUNET_NO; | 165 | return GNUNET_NO; |
404 | return GNUNET_OK; | 166 | return GNUNET_OK; |
@@ -480,12 +242,7 @@ block_plugin_regex_check_reply ( | |||
480 | const char *s; | 242 | const char *s; |
481 | 243 | ||
482 | s = (const char *) xquery; | 244 | s = (const char *) xquery; |
483 | if ('\0' != s[xquery_size - 1]) /* must be valid 0-terminated string */ | 245 | GNUNET_assert ('\0' == s[xquery_size - 1]); |
484 | { | ||
485 | /* Technically, the query is invalid ... */ | ||
486 | GNUNET_break (0); | ||
487 | return GNUNET_BLOCK_REPLY_INVALID; | ||
488 | } | ||
489 | } | 246 | } |
490 | switch (REGEX_BLOCK_check (reply_block, | 247 | switch (REGEX_BLOCK_check (reply_block, |
491 | reply_block_size, | 248 | reply_block_size, |
@@ -493,8 +250,7 @@ block_plugin_regex_check_reply ( | |||
493 | xquery)) | 250 | xquery)) |
494 | { | 251 | { |
495 | case GNUNET_SYSERR: | 252 | case GNUNET_SYSERR: |
496 | GNUNET_break_op (0); | 253 | GNUNET_assert (0); |
497 | return GNUNET_BLOCK_REPLY_INVALID; | ||
498 | case GNUNET_NO: | 254 | case GNUNET_NO: |
499 | /* xquery mismatch, can happen */ | 255 | /* xquery mismatch, can happen */ |
500 | return GNUNET_BLOCK_REPLY_IRRELEVANT; | 256 | return GNUNET_BLOCK_REPLY_IRRELEVANT; |
@@ -513,20 +269,12 @@ block_plugin_regex_check_reply ( | |||
513 | { | 269 | { |
514 | const struct RegexAcceptBlock *rba; | 270 | const struct RegexAcceptBlock *rba; |
515 | 271 | ||
516 | if (sizeof(struct RegexAcceptBlock) != reply_block_size) | 272 | GNUNET_assert (sizeof(struct RegexAcceptBlock) == reply_block_size); |
517 | { | ||
518 | GNUNET_break_op (0); | ||
519 | return GNUNET_BLOCK_REPLY_INVALID; | ||
520 | } | ||
521 | rba = reply_block; | 273 | rba = reply_block; |
522 | if (ntohl (rba->purpose.size) != | 274 | GNUNET_assert (ntohl (rba->purpose.size) == |
523 | sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) | 275 | sizeof(struct GNUNET_CRYPTO_EccSignaturePurpose) |
524 | + sizeof(struct GNUNET_TIME_AbsoluteNBO) | 276 | + sizeof(struct GNUNET_TIME_AbsoluteNBO) |
525 | + sizeof(struct GNUNET_HashCode)) | 277 | + sizeof(struct GNUNET_HashCode)); |
526 | { | ||
527 | GNUNET_break_op (0); | ||
528 | return GNUNET_BLOCK_REPLY_INVALID; | ||
529 | } | ||
530 | GNUNET_CRYPTO_hash (reply_block, | 278 | GNUNET_CRYPTO_hash (reply_block, |
531 | reply_block_size, | 279 | reply_block_size, |
532 | &chash); | 280 | &chash); |
@@ -552,8 +300,8 @@ block_plugin_regex_check_reply ( | |||
552 | * @param block block to get the key for | 300 | * @param block block to get the key for |
553 | * @param block_size number of bytes in @a block | 301 | * @param block_size number of bytes in @a block |
554 | * @param key set to the key (query) for the given block | 302 | * @param key set to the key (query) for the given block |
555 | * @return #GNUNET_OK on success, #GNUNET_SYSERR if type not supported | 303 | * @return #GNUNET_OK on success, #GNUNET_SYSERR if type not supported, |
556 | * (or if extracting a key from a block of this type does not work) | 304 | * #GNUNET_NO if extracting a key from a block of this type does not work |
557 | */ | 305 | */ |
558 | static enum GNUNET_GenericReturnValue | 306 | static enum GNUNET_GenericReturnValue |
559 | block_plugin_regex_get_key (void *cls, | 307 | block_plugin_regex_get_key (void *cls, |
@@ -571,14 +319,20 @@ block_plugin_regex_get_key (void *cls, | |||
571 | key)) | 319 | key)) |
572 | { | 320 | { |
573 | GNUNET_break_op (0); | 321 | GNUNET_break_op (0); |
574 | return GNUNET_NO; | 322 | memset (key, |
323 | 0, | ||
324 | sizeof (*key)); | ||
325 | return GNUNET_OK; | ||
575 | } | 326 | } |
576 | return GNUNET_OK; | 327 | return GNUNET_OK; |
577 | case GNUNET_BLOCK_TYPE_REGEX_ACCEPT: | 328 | case GNUNET_BLOCK_TYPE_REGEX_ACCEPT: |
578 | if (sizeof(struct RegexAcceptBlock) != block_size) | 329 | if (sizeof(struct RegexAcceptBlock) != block_size) |
579 | { | 330 | { |
580 | GNUNET_break_op (0); | 331 | GNUNET_break_op (0); |
581 | return GNUNET_NO; | 332 | memset (key, |
333 | 0, | ||
334 | sizeof (*key)); | ||
335 | return GNUNET_OK; | ||
582 | } | 336 | } |
583 | *key = ((struct RegexAcceptBlock *) block)->key; | 337 | *key = ((struct RegexAcceptBlock *) block)->key; |
584 | return GNUNET_OK; | 338 | return GNUNET_OK; |
@@ -603,7 +357,6 @@ libgnunet_plugin_block_regex_init (void *cls) | |||
603 | struct GNUNET_BLOCK_PluginFunctions *api; | 357 | struct GNUNET_BLOCK_PluginFunctions *api; |
604 | 358 | ||
605 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); | 359 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); |
606 | api->evaluate = &block_plugin_regex_evaluate; | ||
607 | api->get_key = &block_plugin_regex_get_key; | 360 | api->get_key = &block_plugin_regex_get_key; |
608 | api->check_query = &block_plugin_regex_check_query; | 361 | api->check_query = &block_plugin_regex_check_query; |
609 | api->check_block = &block_plugin_regex_check_block; | 362 | api->check_block = &block_plugin_regex_check_block; |
diff --git a/src/revocation/gnunet-revocation-tvg.c b/src/revocation/gnunet-revocation-tvg.c index 3ba5b56fa..a34a6bc98 100644 --- a/src/revocation/gnunet-revocation-tvg.c +++ b/src/revocation/gnunet-revocation-tvg.c | |||
@@ -159,6 +159,7 @@ run (void *cls, | |||
159 | print_bytes (pow, | 159 | print_bytes (pow, |
160 | GNUNET_REVOCATION_proof_get_size (pow), | 160 | GNUNET_REVOCATION_proof_get_size (pow), |
161 | 8); | 161 | 8); |
162 | GNUNET_free (ph); | ||
162 | } | 163 | } |
163 | 164 | ||
164 | 165 | ||
diff --git a/src/revocation/plugin_block_revocation.c b/src/revocation/plugin_block_revocation.c index 3beae60bb..12ec555e4 100644 --- a/src/revocation/plugin_block_revocation.c +++ b/src/revocation/plugin_block_revocation.c | |||
@@ -44,65 +44,6 @@ struct InternalContext | |||
44 | 44 | ||
45 | 45 | ||
46 | /** | 46 | /** |
47 | * Function called to validate a reply or a request. For | ||
48 | * request evaluation, simply pass "NULL" for the reply_block. | ||
49 | * | ||
50 | * @param cls our `struct InternalContext` | ||
51 | * @param ctx context | ||
52 | * @param type block type | ||
53 | * @param group block group to use | ||
54 | * @param eo control flags | ||
55 | * @param query original query (hash) | ||
56 | * @param xquery extrended query data (can be NULL, depending on type) | ||
57 | * @param xquery_size number of bytes in xquery | ||
58 | * @param reply_block response to validate | ||
59 | * @param reply_block_size number of bytes in reply block | ||
60 | * @return characterization of result | ||
61 | */ | ||
62 | static enum GNUNET_BLOCK_EvaluationResult | ||
63 | block_plugin_revocation_evaluate (void *cls, | ||
64 | struct GNUNET_BLOCK_Context *ctx, | ||
65 | enum GNUNET_BLOCK_Type type, | ||
66 | struct GNUNET_BLOCK_Group *group, | ||
67 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
68 | const struct GNUNET_HashCode *query, | ||
69 | const void *xquery, | ||
70 | size_t xquery_size, | ||
71 | const void *reply_block, | ||
72 | size_t reply_block_size) | ||
73 | { | ||
74 | struct InternalContext *ic = cls; | ||
75 | ssize_t pklen; | ||
76 | const struct RevokeMessage *rm = reply_block; | ||
77 | |||
78 | if (NULL == reply_block) | ||
79 | return GNUNET_BLOCK_EVALUATION_REQUEST_VALID; | ||
80 | if (reply_block_size != sizeof(*rm)) | ||
81 | { | ||
82 | GNUNET_break_op (0); | ||
83 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
84 | } | ||
85 | struct GNUNET_REVOCATION_PowP *pow = (struct GNUNET_REVOCATION_PowP *) &rm[1]; | ||
86 | const struct GNUNET_IDENTITY_PublicKey *pk; | ||
87 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | ||
88 | if (GNUNET_YES != GNUNET_REVOCATION_check_pow (pow, | ||
89 | ic->matching_bits, | ||
90 | ic->epoch_duration)) | ||
91 | { | ||
92 | GNUNET_break_op (0); | ||
93 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
94 | } | ||
95 | pklen = GNUNET_IDENTITY_key_get_length (pk); | ||
96 | if (0 > pklen) | ||
97 | { | ||
98 | GNUNET_break_op (0); | ||
99 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
100 | } | ||
101 | return GNUNET_BLOCK_EVALUATION_OK_LAST; | ||
102 | } | ||
103 | |||
104 | |||
105 | /** | ||
106 | * Function called to validate a query. | 47 | * Function called to validate a query. |
107 | * | 48 | * |
108 | * @param cls closure | 49 | * @param cls closure |
@@ -124,7 +65,10 @@ block_plugin_revocation_check_query (void *cls, | |||
124 | (void) query; | 65 | (void) query; |
125 | (void) xquery; | 66 | (void) xquery; |
126 | if (GNUNET_BLOCK_TYPE_REVOCATION != type) | 67 | if (GNUNET_BLOCK_TYPE_REVOCATION != type) |
68 | { | ||
69 | GNUNET_break (0); | ||
127 | return GNUNET_SYSERR; | 70 | return GNUNET_SYSERR; |
71 | } | ||
128 | if (0 != xquery_size) | 72 | if (0 != xquery_size) |
129 | return GNUNET_NO; | 73 | return GNUNET_NO; |
130 | return GNUNET_OK; | 74 | return GNUNET_OK; |
@@ -136,7 +80,6 @@ block_plugin_revocation_check_query (void *cls, | |||
136 | * | 80 | * |
137 | * @param cls closure | 81 | * @param cls closure |
138 | * @param type block type | 82 | * @param type block type |
139 | * @param query key for the block (hash), must match exactly | ||
140 | * @param block block data to validate | 83 | * @param block block data to validate |
141 | * @param block_size number of bytes in @a block | 84 | * @param block_size number of bytes in @a block |
142 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not | 85 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not |
@@ -144,7 +87,6 @@ block_plugin_revocation_check_query (void *cls, | |||
144 | static enum GNUNET_GenericReturnValue | 87 | static enum GNUNET_GenericReturnValue |
145 | block_plugin_revocation_check_block (void *cls, | 88 | block_plugin_revocation_check_block (void *cls, |
146 | enum GNUNET_BLOCK_Type type, | 89 | enum GNUNET_BLOCK_Type type, |
147 | const struct GNUNET_HashCode *query, | ||
148 | const void *block, | 90 | const void *block, |
149 | size_t block_size) | 91 | size_t block_size) |
150 | { | 92 | { |
@@ -157,7 +99,10 @@ block_plugin_revocation_check_block (void *cls, | |||
157 | size_t left; | 99 | size_t left; |
158 | 100 | ||
159 | if (GNUNET_BLOCK_TYPE_REVOCATION != type) | 101 | if (GNUNET_BLOCK_TYPE_REVOCATION != type) |
102 | { | ||
103 | GNUNET_break (0); | ||
160 | return GNUNET_SYSERR; | 104 | return GNUNET_SYSERR; |
105 | } | ||
161 | if (block_size < sizeof(*rm) + sizeof(*pow)) | 106 | if (block_size < sizeof(*rm) + sizeof(*pow)) |
162 | { | 107 | { |
163 | GNUNET_break_op (0); | 108 | GNUNET_break_op (0); |
@@ -224,7 +169,10 @@ block_plugin_revocation_check_reply ( | |||
224 | (void) reply_block; | 169 | (void) reply_block; |
225 | (void) reply_block_size; | 170 | (void) reply_block_size; |
226 | if (GNUNET_BLOCK_TYPE_REVOCATION != type) | 171 | if (GNUNET_BLOCK_TYPE_REVOCATION != type) |
172 | { | ||
173 | GNUNET_break (0); | ||
227 | return GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED; | 174 | return GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED; |
175 | } | ||
228 | return GNUNET_BLOCK_REPLY_OK_LAST; | 176 | return GNUNET_BLOCK_REPLY_OK_LAST; |
229 | } | 177 | } |
230 | 178 | ||
@@ -255,7 +203,10 @@ block_plugin_revocation_get_key (void *cls, | |||
255 | size_t left; | 203 | size_t left; |
256 | 204 | ||
257 | if (GNUNET_BLOCK_TYPE_REVOCATION != type) | 205 | if (GNUNET_BLOCK_TYPE_REVOCATION != type) |
206 | { | ||
207 | GNUNET_break (0); | ||
258 | return GNUNET_SYSERR; | 208 | return GNUNET_SYSERR; |
209 | } | ||
259 | if (block_size < sizeof(*rm) + sizeof(*pow)) | 210 | if (block_size < sizeof(*rm) + sizeof(*pow)) |
260 | { | 211 | { |
261 | GNUNET_break_op (0); | 212 | GNUNET_break_op (0); |
@@ -314,7 +265,6 @@ libgnunet_plugin_block_revocation_init (void *cls) | |||
314 | return NULL; | 265 | return NULL; |
315 | 266 | ||
316 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); | 267 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); |
317 | api->evaluate = &block_plugin_revocation_evaluate; | ||
318 | api->get_key = &block_plugin_revocation_get_key; | 268 | api->get_key = &block_plugin_revocation_get_key; |
319 | api->check_query = &block_plugin_revocation_check_query; | 269 | api->check_query = &block_plugin_revocation_check_query; |
320 | api->check_block = &block_plugin_revocation_check_block; | 270 | api->check_block = &block_plugin_revocation_check_block; |
diff --git a/src/revocation/revocation_api.c b/src/revocation/revocation_api.c index bc5dae021..9080ab862 100644 --- a/src/revocation/revocation_api.c +++ b/src/revocation/revocation_api.c | |||
@@ -758,13 +758,11 @@ GNUNET_REVOCATION_proof_get_size (const struct GNUNET_REVOCATION_PowP *pow) | |||
758 | size_t size; | 758 | size_t size; |
759 | size_t ksize; | 759 | size_t ksize; |
760 | const struct GNUNET_IDENTITY_PublicKey *pk; | 760 | const struct GNUNET_IDENTITY_PublicKey *pk; |
761 | const struct GNUNET_IDENTITY_Signature *sig; | ||
762 | 761 | ||
763 | size = sizeof (struct GNUNET_REVOCATION_PowP); | 762 | size = sizeof (struct GNUNET_REVOCATION_PowP); |
764 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; | 763 | pk = (const struct GNUNET_IDENTITY_PublicKey *) &pow[1]; |
765 | ksize = GNUNET_IDENTITY_key_get_length (pk); | 764 | ksize = GNUNET_IDENTITY_key_get_length (pk); |
766 | size += ksize; | 765 | size += ksize; |
767 | sig = (struct GNUNET_IDENTITY_Signature *) ((char*) &pow[1] + ksize); | ||
768 | size += GNUNET_IDENTITY_signature_get_raw_length_by_type (pk->type); | 766 | size += GNUNET_IDENTITY_signature_get_raw_length_by_type (pk->type); |
769 | return size; | 767 | return size; |
770 | } | 768 | } |
diff --git a/src/set/plugin_block_set_test.c b/src/set/plugin_block_set_test.c index 3d66831bb..cb5cef5ad 100644 --- a/src/set/plugin_block_set_test.c +++ b/src/set/plugin_block_set_test.c | |||
@@ -30,46 +30,9 @@ | |||
30 | 30 | ||
31 | 31 | ||
32 | /** | 32 | /** |
33 | * Function called to validate a reply or a request. For | ||
34 | * request evaluation, simply pass "NULL" for the reply_block. | ||
35 | * | ||
36 | * @param cls closure | ||
37 | * @param ctx block context | ||
38 | * @param type block type | ||
39 | * @param group block group to use | ||
40 | * @param eo control flags | ||
41 | * @param query original query (hash) | ||
42 | * @param xquery extrended query data (can be NULL, depending on type) | ||
43 | * @param xquery_size number of bytes in xquery | ||
44 | * @param reply_block response to validate | ||
45 | * @param reply_block_size number of bytes in reply block | ||
46 | * @return characterization of result | ||
47 | */ | ||
48 | static enum GNUNET_BLOCK_EvaluationResult | ||
49 | block_plugin_set_test_evaluate (void *cls, | ||
50 | struct GNUNET_BLOCK_Context *ctx, | ||
51 | enum GNUNET_BLOCK_Type type, | ||
52 | struct GNUNET_BLOCK_Group *group, | ||
53 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
54 | const struct GNUNET_HashCode *query, | ||
55 | const void *xquery, | ||
56 | size_t xquery_size, | ||
57 | const void *reply_block, | ||
58 | size_t reply_block_size) | ||
59 | { | ||
60 | if ((NULL == reply_block) || | ||
61 | (reply_block_size == 0) || | ||
62 | (0 != ((char *) reply_block)[0])) | ||
63 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
64 | return GNUNET_BLOCK_EVALUATION_OK_MORE; | ||
65 | } | ||
66 | |||
67 | |||
68 | /** | ||
69 | * Function called to validate a query. | 33 | * Function called to validate a query. |
70 | * | 34 | * |
71 | * @param cls closure | 35 | * @param cls closure |
72 | * @param ctx block context | ||
73 | * @param type block type | 36 | * @param type block type |
74 | * @param query original query (hash) | 37 | * @param query original query (hash) |
75 | * @param xquery extrended query data (can be NULL, depending on type) | 38 | * @param xquery extrended query data (can be NULL, depending on type) |
@@ -92,7 +55,6 @@ block_plugin_set_test_check_query (void *cls, | |||
92 | * | 55 | * |
93 | * @param cls closure | 56 | * @param cls closure |
94 | * @param type block type | 57 | * @param type block type |
95 | * @param query key for the block (hash), must match exactly | ||
96 | * @param block block data to validate | 58 | * @param block block data to validate |
97 | * @param block_size number of bytes in @a block | 59 | * @param block_size number of bytes in @a block |
98 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not | 60 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not |
@@ -100,7 +62,6 @@ block_plugin_set_test_check_query (void *cls, | |||
100 | static enum GNUNET_GenericReturnValue | 62 | static enum GNUNET_GenericReturnValue |
101 | block_plugin_set_test_check_block (void *cls, | 63 | block_plugin_set_test_check_block (void *cls, |
102 | enum GNUNET_BLOCK_Type type, | 64 | enum GNUNET_BLOCK_Type type, |
103 | const struct GNUNET_HashCode *query, | ||
104 | const void *block, | 65 | const void *block, |
105 | size_t block_size) | 66 | size_t block_size) |
106 | { | 67 | { |
@@ -141,7 +102,7 @@ block_plugin_set_test_check_reply (void *cls, | |||
141 | if ((NULL == reply_block) || | 102 | if ((NULL == reply_block) || |
142 | (0 == reply_block_size) || | 103 | (0 == reply_block_size) || |
143 | (0 != ((char *) reply_block)[0])) | 104 | (0 != ((char *) reply_block)[0])) |
144 | return GNUNET_BLOCK_REPLY_INVALID; | 105 | GNUNET_assert (0); |
145 | return GNUNET_BLOCK_REPLY_OK_MORE; | 106 | return GNUNET_BLOCK_REPLY_OK_MORE; |
146 | } | 107 | } |
147 | 108 | ||
@@ -164,7 +125,7 @@ block_plugin_set_test_get_key (void *cls, | |||
164 | size_t block_size, | 125 | size_t block_size, |
165 | struct GNUNET_HashCode *key) | 126 | struct GNUNET_HashCode *key) |
166 | { | 127 | { |
167 | return GNUNET_SYSERR; | 128 | return GNUNET_NO; |
168 | } | 129 | } |
169 | 130 | ||
170 | 131 | ||
@@ -181,7 +142,6 @@ libgnunet_plugin_block_set_test_init (void *cls) | |||
181 | struct GNUNET_BLOCK_PluginFunctions *api; | 142 | struct GNUNET_BLOCK_PluginFunctions *api; |
182 | 143 | ||
183 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); | 144 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); |
184 | api->evaluate = &block_plugin_set_test_evaluate; | ||
185 | api->get_key = &block_plugin_set_test_get_key; | 145 | api->get_key = &block_plugin_set_test_get_key; |
186 | api->check_query = &block_plugin_set_test_check_query; | 146 | api->check_query = &block_plugin_set_test_check_query; |
187 | api->check_block = &block_plugin_set_test_check_block; | 147 | api->check_block = &block_plugin_set_test_check_block; |
diff --git a/src/seti/plugin_block_seti_test.c b/src/seti/plugin_block_seti_test.c index af86e1af6..5b9196cef 100644 --- a/src/seti/plugin_block_seti_test.c +++ b/src/seti/plugin_block_seti_test.c | |||
@@ -30,42 +30,6 @@ | |||
30 | 30 | ||
31 | 31 | ||
32 | /** | 32 | /** |
33 | * Function called to validate a reply or a request. For | ||
34 | * request evaluation, simply pass "NULL" for the reply_block. | ||
35 | * | ||
36 | * @param cls closure | ||
37 | * @param ctx block context | ||
38 | * @param type block type | ||
39 | * @param group block group to use | ||
40 | * @param eo control flags | ||
41 | * @param query original query (hash) | ||
42 | * @param xquery extrended query data (can be NULL, depending on type) | ||
43 | * @param xquery_size number of bytes in xquery | ||
44 | * @param reply_block response to validate | ||
45 | * @param reply_block_size number of bytes in reply block | ||
46 | * @return characterization of result | ||
47 | */ | ||
48 | static enum GNUNET_BLOCK_EvaluationResult | ||
49 | block_plugin_seti_test_evaluate (void *cls, | ||
50 | struct GNUNET_BLOCK_Context *ctx, | ||
51 | enum GNUNET_BLOCK_Type type, | ||
52 | struct GNUNET_BLOCK_Group *group, | ||
53 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
54 | const struct GNUNET_HashCode *query, | ||
55 | const void *xquery, | ||
56 | size_t xquery_size, | ||
57 | const void *reply_block, | ||
58 | size_t reply_block_size) | ||
59 | { | ||
60 | if ((NULL == reply_block) || | ||
61 | (reply_block_size == 0) || | ||
62 | (0 != ((char *) reply_block)[0])) | ||
63 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
64 | return GNUNET_BLOCK_EVALUATION_OK_MORE; | ||
65 | } | ||
66 | |||
67 | |||
68 | /** | ||
69 | * Function called to validate a query. | 33 | * Function called to validate a query. |
70 | * | 34 | * |
71 | * @param cls closure | 35 | * @param cls closure |
@@ -83,6 +47,16 @@ block_plugin_seti_test_check_query (void *cls, | |||
83 | const void *xquery, | 47 | const void *xquery, |
84 | size_t xquery_size) | 48 | size_t xquery_size) |
85 | { | 49 | { |
50 | if (GNUNET_BLOCK_TYPE_SETI_TEST != type) | ||
51 | { | ||
52 | GNUNET_break (0); | ||
53 | return GNUNET_SYSERR; | ||
54 | } | ||
55 | if (0 != xquery_size) | ||
56 | { | ||
57 | GNUNET_break_op (0); | ||
58 | return GNUNET_NO; | ||
59 | } | ||
86 | return GNUNET_OK; | 60 | return GNUNET_OK; |
87 | } | 61 | } |
88 | 62 | ||
@@ -92,7 +66,6 @@ block_plugin_seti_test_check_query (void *cls, | |||
92 | * | 66 | * |
93 | * @param cls closure | 67 | * @param cls closure |
94 | * @param type block type | 68 | * @param type block type |
95 | * @param query key for the block (hash), must match exactly | ||
96 | * @param block block data to validate | 69 | * @param block block data to validate |
97 | * @param block_size number of bytes in @a block | 70 | * @param block_size number of bytes in @a block |
98 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not | 71 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not |
@@ -100,10 +73,15 @@ block_plugin_seti_test_check_query (void *cls, | |||
100 | static enum GNUNET_GenericReturnValue | 73 | static enum GNUNET_GenericReturnValue |
101 | block_plugin_seti_test_check_block (void *cls, | 74 | block_plugin_seti_test_check_block (void *cls, |
102 | enum GNUNET_BLOCK_Type type, | 75 | enum GNUNET_BLOCK_Type type, |
103 | const struct GNUNET_HashCode *query, | ||
104 | const void *block, | 76 | const void *block, |
105 | size_t block_size) | 77 | size_t block_size) |
106 | { | 78 | { |
79 | (void) cls; | ||
80 | if (GNUNET_BLOCK_TYPE_SETI_TEST != type) | ||
81 | { | ||
82 | GNUNET_break (0); | ||
83 | return GNUNET_SYSERR; | ||
84 | } | ||
107 | if ((NULL == block) || | 85 | if ((NULL == block) || |
108 | (0 == block_size) || | 86 | (0 == block_size) || |
109 | (0 != ((char *) block)[0])) | 87 | (0 != ((char *) block)[0])) |
@@ -138,10 +116,18 @@ block_plugin_seti_test_check_reply (void *cls, | |||
138 | const void *reply_block, | 116 | const void *reply_block, |
139 | size_t reply_block_size) | 117 | size_t reply_block_size) |
140 | { | 118 | { |
119 | (void) cls; | ||
120 | (void) xquery; | ||
121 | (void) xquery_size; | ||
122 | if (GNUNET_BLOCK_TYPE_SETI_TEST != type) | ||
123 | { | ||
124 | GNUNET_break (0); | ||
125 | return GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED; | ||
126 | } | ||
141 | if ( (NULL == reply_block) || | 127 | if ( (NULL == reply_block) || |
142 | (0 == reply_block_size) || | 128 | (0 == reply_block_size) || |
143 | (0 != ((char *) reply_block)[0]) ) | 129 | (0 != ((char *) reply_block)[0]) ) |
144 | return GNUNET_BLOCK_REPLY_INVALID; | 130 | GNUNET_assert (0); |
145 | return GNUNET_BLOCK_REPLY_OK_MORE; | 131 | return GNUNET_BLOCK_REPLY_OK_MORE; |
146 | } | 132 | } |
147 | 133 | ||
@@ -164,7 +150,12 @@ block_plugin_seti_test_get_key (void *cls, | |||
164 | size_t block_size, | 150 | size_t block_size, |
165 | struct GNUNET_HashCode *key) | 151 | struct GNUNET_HashCode *key) |
166 | { | 152 | { |
167 | return GNUNET_SYSERR; | 153 | if (GNUNET_BLOCK_TYPE_SETI_TEST != type) |
154 | { | ||
155 | GNUNET_break (0); | ||
156 | return GNUNET_SYSERR; | ||
157 | } | ||
158 | return GNUNET_NO; | ||
168 | } | 159 | } |
169 | 160 | ||
170 | 161 | ||
@@ -181,7 +172,6 @@ libgnunet_plugin_block_seti_test_init (void *cls) | |||
181 | struct GNUNET_BLOCK_PluginFunctions *api; | 172 | struct GNUNET_BLOCK_PluginFunctions *api; |
182 | 173 | ||
183 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); | 174 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); |
184 | api->evaluate = &block_plugin_seti_test_evaluate; | ||
185 | api->get_key = &block_plugin_seti_test_get_key; | 175 | api->get_key = &block_plugin_seti_test_get_key; |
186 | api->check_query = &block_plugin_seti_test_check_query; | 176 | api->check_query = &block_plugin_seti_test_check_query; |
187 | api->check_block = &block_plugin_seti_test_check_block; | 177 | api->check_block = &block_plugin_seti_test_check_block; |
diff --git a/src/setu/plugin_block_setu_test.c b/src/setu/plugin_block_setu_test.c index 9872bba39..178ad3314 100644 --- a/src/setu/plugin_block_setu_test.c +++ b/src/setu/plugin_block_setu_test.c | |||
@@ -23,49 +23,12 @@ | |||
23 | * @brief set test block, recognizes elements with non-zero first byte as invalid | 23 | * @brief set test block, recognizes elements with non-zero first byte as invalid |
24 | * @author Christian Grothoff | 24 | * @author Christian Grothoff |
25 | */ | 25 | */ |
26 | |||
27 | #include "platform.h" | 26 | #include "platform.h" |
28 | #include "gnunet_block_plugin.h" | 27 | #include "gnunet_block_plugin.h" |
29 | #include "gnunet_block_group_lib.h" | 28 | #include "gnunet_block_group_lib.h" |
30 | 29 | ||
31 | 30 | ||
32 | /** | 31 | /** |
33 | * Function called to validate a reply or a request. For | ||
34 | * request evaluation, simply pass "NULL" for the reply_block. | ||
35 | * | ||
36 | * @param cls closure | ||
37 | * @param ctx block context | ||
38 | * @param type block type | ||
39 | * @param group block group to use | ||
40 | * @param eo control flags | ||
41 | * @param query original query (hash) | ||
42 | * @param xquery extrended query data (can be NULL, depending on type) | ||
43 | * @param xquery_size number of bytes in xquery | ||
44 | * @param reply_block response to validate | ||
45 | * @param reply_block_size number of bytes in reply block | ||
46 | * @return characterization of result | ||
47 | */ | ||
48 | static enum GNUNET_BLOCK_EvaluationResult | ||
49 | block_plugin_setu_test_evaluate (void *cls, | ||
50 | struct GNUNET_BLOCK_Context *ctx, | ||
51 | enum GNUNET_BLOCK_Type type, | ||
52 | struct GNUNET_BLOCK_Group *group, | ||
53 | enum GNUNET_BLOCK_EvaluationOptions eo, | ||
54 | const struct GNUNET_HashCode *query, | ||
55 | const void *xquery, | ||
56 | size_t xquery_size, | ||
57 | const void *reply_block, | ||
58 | size_t reply_block_size) | ||
59 | { | ||
60 | if ((NULL == reply_block) || | ||
61 | (reply_block_size == 0) || | ||
62 | (0 != ((char *) reply_block)[0])) | ||
63 | return GNUNET_BLOCK_EVALUATION_RESULT_INVALID; | ||
64 | return GNUNET_BLOCK_EVALUATION_OK_MORE; | ||
65 | } | ||
66 | |||
67 | |||
68 | /** | ||
69 | * Function called to validate a query. | 32 | * Function called to validate a query. |
70 | * | 33 | * |
71 | * @param cls closure | 34 | * @param cls closure |
@@ -83,6 +46,16 @@ block_plugin_setu_test_check_query (void *cls, | |||
83 | const void *xquery, | 46 | const void *xquery, |
84 | size_t xquery_size) | 47 | size_t xquery_size) |
85 | { | 48 | { |
49 | if (GNUNET_BLOCK_TYPE_SETU_TEST != type) | ||
50 | { | ||
51 | GNUNET_break (0); | ||
52 | return GNUNET_SYSERR; | ||
53 | } | ||
54 | if (0 != xquery_size) | ||
55 | { | ||
56 | GNUNET_break_op (0); | ||
57 | return GNUNET_NO; | ||
58 | } | ||
86 | return GNUNET_OK; | 59 | return GNUNET_OK; |
87 | } | 60 | } |
88 | 61 | ||
@@ -92,7 +65,6 @@ block_plugin_setu_test_check_query (void *cls, | |||
92 | * | 65 | * |
93 | * @param cls closure | 66 | * @param cls closure |
94 | * @param type block type | 67 | * @param type block type |
95 | * @param query key for the block (hash), must match exactly | ||
96 | * @param block block data to validate | 68 | * @param block block data to validate |
97 | * @param block_size number of bytes in @a block | 69 | * @param block_size number of bytes in @a block |
98 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not | 70 | * @return #GNUNET_OK if the block is fine, #GNUNET_NO if not |
@@ -100,14 +72,18 @@ block_plugin_setu_test_check_query (void *cls, | |||
100 | static enum GNUNET_GenericReturnValue | 72 | static enum GNUNET_GenericReturnValue |
101 | block_plugin_setu_test_check_block (void *cls, | 73 | block_plugin_setu_test_check_block (void *cls, |
102 | enum GNUNET_BLOCK_Type type, | 74 | enum GNUNET_BLOCK_Type type, |
103 | const struct GNUNET_HashCode *query, | ||
104 | const void *block, | 75 | const void *block, |
105 | size_t block_size) | 76 | size_t block_size) |
106 | { | 77 | { |
78 | if (GNUNET_BLOCK_TYPE_SETU_TEST != type) | ||
79 | { | ||
80 | GNUNET_break (0); | ||
81 | return GNUNET_SYSERR; | ||
82 | } | ||
107 | if ( (NULL == block) || | 83 | if ( (NULL == block) || |
108 | (0 == block_size) || | 84 | (0 == block_size) || |
109 | (0 != ((char *) block)[0]) ) | 85 | (0 != ((char *) block)[0]) ) |
110 | return GNUNET_SYSERR; | 86 | return GNUNET_NO; |
111 | return GNUNET_OK; | 87 | return GNUNET_OK; |
112 | } | 88 | } |
113 | 89 | ||
@@ -138,10 +114,18 @@ block_plugin_setu_test_check_reply (void *cls, | |||
138 | const void *reply_block, | 114 | const void *reply_block, |
139 | size_t reply_block_size) | 115 | size_t reply_block_size) |
140 | { | 116 | { |
117 | (void) cls; | ||
118 | (void) xquery; | ||
119 | (void) xquery_size; | ||
120 | if (GNUNET_BLOCK_TYPE_SETU_TEST != type) | ||
121 | { | ||
122 | GNUNET_break (0); | ||
123 | return GNUNET_BLOCK_REPLY_TYPE_NOT_SUPPORTED; | ||
124 | } | ||
141 | if ( (NULL == reply_block) || | 125 | if ( (NULL == reply_block) || |
142 | (0 == reply_block_size) || | 126 | (0 == reply_block_size) || |
143 | (0 != ((char *) reply_block)[0]) ) | 127 | (0 != ((char *) reply_block)[0]) ) |
144 | return GNUNET_BLOCK_REPLY_INVALID; | 128 | GNUNET_assert (0); |
145 | return GNUNET_BLOCK_REPLY_OK_MORE; | 129 | return GNUNET_BLOCK_REPLY_OK_MORE; |
146 | } | 130 | } |
147 | 131 | ||
@@ -164,7 +148,12 @@ block_plugin_setu_test_get_key (void *cls, | |||
164 | size_t block_size, | 148 | size_t block_size, |
165 | struct GNUNET_HashCode *key) | 149 | struct GNUNET_HashCode *key) |
166 | { | 150 | { |
167 | return GNUNET_SYSERR; | 151 | if (GNUNET_BLOCK_TYPE_SETU_TEST != type) |
152 | { | ||
153 | GNUNET_break (0); | ||
154 | return GNUNET_SYSERR; | ||
155 | } | ||
156 | return GNUNET_NO; | ||
168 | } | 157 | } |
169 | 158 | ||
170 | 159 | ||
@@ -175,13 +164,12 @@ void * | |||
175 | libgnunet_plugin_block_setu_test_init (void *cls) | 164 | libgnunet_plugin_block_setu_test_init (void *cls) |
176 | { | 165 | { |
177 | static enum GNUNET_BLOCK_Type types[] = { | 166 | static enum GNUNET_BLOCK_Type types[] = { |
178 | GNUNET_BLOCK_TYPE_SETU_TEST, | 167 | GNUNET_BLOCK_TYPE_SETU_TEST, |
179 | GNUNET_BLOCK_TYPE_ANY /* end of list */ | 168 | GNUNET_BLOCK_TYPE_ANY /* end of list */ |
180 | }; | 169 | }; |
181 | struct GNUNET_BLOCK_PluginFunctions *api; | 170 | struct GNUNET_BLOCK_PluginFunctions *api; |
182 | 171 | ||
183 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); | 172 | api = GNUNET_new (struct GNUNET_BLOCK_PluginFunctions); |
184 | api->evaluate = &block_plugin_setu_test_evaluate; | ||
185 | api->get_key = &block_plugin_setu_test_get_key; | 173 | api->get_key = &block_plugin_setu_test_get_key; |
186 | api->check_query = &block_plugin_setu_test_check_query; | 174 | api->check_query = &block_plugin_setu_test_check_query; |
187 | api->check_block = &block_plugin_setu_test_check_block; | 175 | api->check_block = &block_plugin_setu_test_check_block; |
diff --git a/src/transport/Makefile.am b/src/transport/Makefile.am index ec00bc917..69b05fb13 100644 --- a/src/transport/Makefile.am +++ b/src/transport/Makefile.am | |||
@@ -773,6 +773,8 @@ TESTS += \ | |||
773 | endif | 773 | endif |
774 | endif | 774 | endif |
775 | 775 | ||
776 | # Only test TNG if we run experimental | ||
777 | if HAVE_EXPERIMENTAL | ||
776 | check_SCRIPTS= \ | 778 | check_SCRIPTS= \ |
777 | test_transport_simple_send_string.sh \ | 779 | test_transport_simple_send_string.sh \ |
778 | test_transport_simple_send.sh \ | 780 | test_transport_simple_send.sh \ |
@@ -780,6 +782,7 @@ check_SCRIPTS= \ | |||
780 | test_transport_udp_backchannel.sh \ | 782 | test_transport_udp_backchannel.sh \ |
781 | test_transport_simple_send_dv_circle.sh | 783 | test_transport_simple_send_dv_circle.sh |
782 | # test_transport_simple_send_dv_inverse.sh | 784 | # test_transport_simple_send_dv_inverse.sh |
785 | endif | ||
783 | 786 | ||
784 | test_transport_start_with_config_SOURCES = \ | 787 | test_transport_start_with_config_SOURCES = \ |
785 | test_transport_start_with_config.c | 788 | test_transport_start_with_config.c |
@@ -1521,7 +1524,10 @@ test_transport_api_slow_ats_LDADD = \ | |||
1521 | 1524 | ||
1522 | 1525 | ||
1523 | EXTRA_DIST = \ | 1526 | EXTRA_DIST = \ |
1524 | $(check_SCRIPTS) \ | 1527 | test_transport_simple_send_string.sh \ |
1528 | test_transport_simple_send.sh \ | ||
1529 | test_transport_simple_send_broadcast.sh \ | ||
1530 | test_transport_udp_backchannel.sh \ | ||
1525 | gnunet-transport-certificate-creation.in \ | 1531 | gnunet-transport-certificate-creation.in \ |
1526 | communicator-unix.conf \ | 1532 | communicator-unix.conf \ |
1527 | test_plugin_hostkey \ | 1533 | test_plugin_hostkey \ |
diff --git a/src/transport/gnunet-communicator-tcp.c b/src/transport/gnunet-communicator-tcp.c index 3bfdeaa90..be75fa0e8 100644 --- a/src/transport/gnunet-communicator-tcp.c +++ b/src/transport/gnunet-communicator-tcp.c | |||
@@ -143,7 +143,7 @@ struct TcpHandshakeSignature | |||
143 | /** | 143 | /** |
144 | * Challenge value used to protect against replay attack, if there is no stored monotonic time value. | 144 | * Challenge value used to protect against replay attack, if there is no stored monotonic time value. |
145 | */ | 145 | */ |
146 | struct ChallengeNonceP challenge; | 146 | struct GNUNET_CRYPTO_ChallengeNonceP challenge; |
147 | }; | 147 | }; |
148 | 148 | ||
149 | /** | 149 | /** |
@@ -176,7 +176,7 @@ struct TcpHandshakeAckSignature | |||
176 | /** | 176 | /** |
177 | * Challenge value used to protect against replay attack, if there is no stored monotonic time value. | 177 | * Challenge value used to protect against replay attack, if there is no stored monotonic time value. |
178 | */ | 178 | */ |
179 | struct ChallengeNonceP challenge; | 179 | struct GNUNET_CRYPTO_ChallengeNonceP challenge; |
180 | }; | 180 | }; |
181 | 181 | ||
182 | /** | 182 | /** |
@@ -203,7 +203,7 @@ struct TCPConfirmation | |||
203 | /** | 203 | /** |
204 | * Challenge value used to protect against replay attack, if there is no stored monotonic time value. | 204 | * Challenge value used to protect against replay attack, if there is no stored monotonic time value. |
205 | */ | 205 | */ |
206 | struct ChallengeNonceP challenge; | 206 | struct GNUNET_CRYPTO_ChallengeNonceP challenge; |
207 | 207 | ||
208 | }; | 208 | }; |
209 | 209 | ||
@@ -238,7 +238,7 @@ struct TCPConfirmationAck | |||
238 | /** | 238 | /** |
239 | * Challenge value used to protect against replay attack, if there is no stored monotonic time value. | 239 | * Challenge value used to protect against replay attack, if there is no stored monotonic time value. |
240 | */ | 240 | */ |
241 | struct ChallengeNonceP challenge; | 241 | struct GNUNET_CRYPTO_ChallengeNonceP challenge; |
242 | 242 | ||
243 | }; | 243 | }; |
244 | 244 | ||
@@ -587,12 +587,12 @@ struct Queue | |||
587 | /** | 587 | /** |
588 | * Challenge value used to protect against replay attack, if there is no stored monotonic time value. | 588 | * Challenge value used to protect against replay attack, if there is no stored monotonic time value. |
589 | */ | 589 | */ |
590 | struct ChallengeNonceP challenge; | 590 | struct GNUNET_CRYPTO_ChallengeNonceP challenge; |
591 | 591 | ||
592 | /** | 592 | /** |
593 | * Challenge value received. In case of inbound connection we have to remember the value, because we send the challenge back later after we received the GNUNET_MESSAGE_TYPE_COMMUNICATOR_TCP_CONFIRMATION_ACK. | 593 | * Challenge value received. In case of inbound connection we have to remember the value, because we send the challenge back later after we received the GNUNET_MESSAGE_TYPE_COMMUNICATOR_TCP_CONFIRMATION_ACK. |
594 | */ | 594 | */ |
595 | struct ChallengeNonceP challenge_received; | 595 | struct GNUNET_CRYPTO_ChallengeNonceP challenge_received; |
596 | 596 | ||
597 | /** | 597 | /** |
598 | * Iteration Context for retrieving the monotonic time send with key for rekeying. | 598 | * Iteration Context for retrieving the monotonic time send with key for rekeying. |
@@ -1447,7 +1447,7 @@ handshake_ack_monotime_cb (void *cls, | |||
1447 | * @param queue The queue context. | 1447 | * @param queue The queue context. |
1448 | */ | 1448 | */ |
1449 | static void | 1449 | static void |
1450 | send_challenge (struct ChallengeNonceP challenge, struct Queue *queue) | 1450 | send_challenge (struct GNUNET_CRYPTO_ChallengeNonceP challenge, struct Queue *queue) |
1451 | { | 1451 | { |
1452 | struct TCPConfirmationAck tca; | 1452 | struct TCPConfirmationAck tca; |
1453 | struct TcpHandshakeAckSignature thas; | 1453 | struct TcpHandshakeAckSignature thas; |
@@ -1680,7 +1680,7 @@ try_handle_plaintext (struct Queue *queue) | |||
1680 | uint16_t type; | 1680 | uint16_t type; |
1681 | size_t size = 0; /* make compiler happy */ | 1681 | size_t size = 0; /* make compiler happy */ |
1682 | struct TcpHandshakeAckSignature thas; | 1682 | struct TcpHandshakeAckSignature thas; |
1683 | const struct ChallengeNonceP challenge = queue->challenge; | 1683 | const struct GNUNET_CRYPTO_ChallengeNonceP challenge = queue->challenge; |
1684 | 1684 | ||
1685 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 1685 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
1686 | "try handle plaintext!\n"); | 1686 | "try handle plaintext!\n"); |
diff --git a/src/transport/gnunet-service-tng.c b/src/transport/gnunet-service-tng.c index 0427bd229..21c9be05c 100644 --- a/src/transport/gnunet-service-tng.c +++ b/src/transport/gnunet-service-tng.c | |||
@@ -581,7 +581,7 @@ struct DvInitPS | |||
581 | /** | 581 | /** |
582 | * Challenge value used by the initiator to re-identify the path. | 582 | * Challenge value used by the initiator to re-identify the path. |
583 | */ | 583 | */ |
584 | struct ChallengeNonceP challenge; | 584 | struct GNUNET_CRYPTO_ChallengeNonceP challenge; |
585 | }; | 585 | }; |
586 | 586 | ||
587 | 587 | ||
@@ -621,7 +621,7 @@ struct DvHopPS | |||
621 | /** | 621 | /** |
622 | * Challenge value used by the initiator to re-identify the path. | 622 | * Challenge value used by the initiator to re-identify the path. |
623 | */ | 623 | */ |
624 | struct ChallengeNonceP challenge; | 624 | struct GNUNET_CRYPTO_ChallengeNonceP challenge; |
625 | }; | 625 | }; |
626 | 626 | ||
627 | 627 | ||
@@ -715,7 +715,7 @@ struct TransportDVLearnMessage | |||
715 | /** | 715 | /** |
716 | * Challenge value used by the initiator to re-identify the path. | 716 | * Challenge value used by the initiator to re-identify the path. |
717 | */ | 717 | */ |
718 | struct ChallengeNonceP challenge; | 718 | struct GNUNET_CRYPTO_ChallengeNonceP challenge; |
719 | 719 | ||
720 | /* Followed by @e num_hops `struct DVPathEntryP` values, | 720 | /* Followed by @e num_hops `struct DVPathEntryP` values, |
721 | excluding the initiator of the DV trace; the last entry is the | 721 | excluding the initiator of the DV trace; the last entry is the |
@@ -834,7 +834,7 @@ struct TransportValidationChallengeMessage | |||
834 | /** | 834 | /** |
835 | * Challenge to be signed by the receiving peer. | 835 | * Challenge to be signed by the receiving peer. |
836 | */ | 836 | */ |
837 | struct ChallengeNonceP challenge; | 837 | struct GNUNET_CRYPTO_ChallengeNonceP challenge; |
838 | 838 | ||
839 | /** | 839 | /** |
840 | * Timestamp of the sender, to be copied into the reply to allow | 840 | * Timestamp of the sender, to be copied into the reply to allow |
@@ -864,7 +864,7 @@ struct TransportValidationPS | |||
864 | /** | 864 | /** |
865 | * Challenge signed by the receiving peer. | 865 | * Challenge signed by the receiving peer. |
866 | */ | 866 | */ |
867 | struct ChallengeNonceP challenge; | 867 | struct GNUNET_CRYPTO_ChallengeNonceP challenge; |
868 | }; | 868 | }; |
869 | 869 | ||
870 | 870 | ||
@@ -893,7 +893,7 @@ struct TransportValidationResponseMessage | |||
893 | /** | 893 | /** |
894 | * The challenge that was signed by the receiving peer. | 894 | * The challenge that was signed by the receiving peer. |
895 | */ | 895 | */ |
896 | struct ChallengeNonceP challenge; | 896 | struct GNUNET_CRYPTO_ChallengeNonceP challenge; |
897 | 897 | ||
898 | /** | 898 | /** |
899 | * Original timestamp of the sender (was @code{sender_time}), | 899 | * Original timestamp of the sender (was @code{sender_time}), |
@@ -1056,7 +1056,7 @@ struct LearnLaunchEntry | |||
1056 | /** | 1056 | /** |
1057 | * Challenge that uniquely identifies this activity. | 1057 | * Challenge that uniquely identifies this activity. |
1058 | */ | 1058 | */ |
1059 | struct ChallengeNonceP challenge; | 1059 | struct GNUNET_CRYPTO_ChallengeNonceP challenge; |
1060 | 1060 | ||
1061 | /** | 1061 | /** |
1062 | * When did we transmit the DV learn message (used to calculate RTT) and | 1062 | * When did we transmit the DV learn message (used to calculate RTT) and |
@@ -2569,7 +2569,7 @@ struct ValidationState | |||
2569 | * (We must not rotate more often as otherwise we may discard valid answers | 2569 | * (We must not rotate more often as otherwise we may discard valid answers |
2570 | * due to packet losses, latency and reorderings on the network). | 2570 | * due to packet losses, latency and reorderings on the network). |
2571 | */ | 2571 | */ |
2572 | struct ChallengeNonceP challenge; | 2572 | struct GNUNET_CRYPTO_ChallengeNonceP challenge; |
2573 | 2573 | ||
2574 | /** | 2574 | /** |
2575 | * Claimed address of the peer. | 2575 | * Claimed address of the peer. |
@@ -6886,7 +6886,7 @@ static int | |||
6886 | validate_dv_initiator_signature ( | 6886 | validate_dv_initiator_signature ( |
6887 | struct GNUNET_TIME_AbsoluteNBO sender_monotonic_time, | 6887 | struct GNUNET_TIME_AbsoluteNBO sender_monotonic_time, |
6888 | const struct GNUNET_PeerIdentity *init, | 6888 | const struct GNUNET_PeerIdentity *init, |
6889 | const struct ChallengeNonceP *challenge, | 6889 | const struct GNUNET_CRYPTO_ChallengeNonceP *challenge, |
6890 | const struct GNUNET_CRYPTO_EddsaSignature *init_sig) | 6890 | const struct GNUNET_CRYPTO_EddsaSignature *init_sig) |
6891 | { | 6891 | { |
6892 | struct DvInitPS ip = { .purpose.purpose = htonl ( | 6892 | struct DvInitPS ip = { .purpose.purpose = htonl ( |
@@ -8340,7 +8340,7 @@ struct CheckKnownChallengeContext | |||
8340 | /** | 8340 | /** |
8341 | * Set to the challenge we are looking for. | 8341 | * Set to the challenge we are looking for. |
8342 | */ | 8342 | */ |
8343 | const struct ChallengeNonceP *challenge; | 8343 | const struct GNUNET_CRYPTO_ChallengeNonceP *challenge; |
8344 | 8344 | ||
8345 | /** | 8345 | /** |
8346 | * Set to a matching validation state, if one was found. | 8346 | * Set to a matching validation state, if one was found. |
diff --git a/src/transport/gnunet-service-transport.c b/src/transport/gnunet-service-transport.c index 24cc6464a..fad2ca4a1 100644 --- a/src/transport/gnunet-service-transport.c +++ b/src/transport/gnunet-service-transport.c | |||
@@ -1628,8 +1628,8 @@ GST_receive_callback (void *cls, | |||
1628 | GST_neighbours_notify_data_recv (address, message); | 1628 | GST_neighbours_notify_data_recv (address, message); |
1629 | switch (type) | 1629 | switch (type) |
1630 | { | 1630 | { |
1631 | case GNUNET_MESSAGE_TYPE_HELLO_LEGACY: | 1631 | case GNUNET_MESSAGE_TYPE_HELLO_URI: |
1632 | /* Legacy HELLO message, discard */ | 1632 | /* Future HELLO message, discard */ |
1633 | return ret; | 1633 | return ret; |
1634 | 1634 | ||
1635 | case GNUNET_MESSAGE_TYPE_HELLO: | 1635 | case GNUNET_MESSAGE_TYPE_HELLO: |
diff --git a/src/transport/test_transport_simple_send.sh b/src/transport/test_transport_simple_send.sh index 3d5266622..0250070be 100755 --- a/src/transport/test_transport_simple_send.sh +++ b/src/transport/test_transport_simple_send.sh | |||
@@ -2,9 +2,10 @@ | |||
2 | if ! [ -d "/run/netns" ]; then | 2 | if ! [ -d "/run/netns" ]; then |
3 | echo You have to create the directory /run/netns. | 3 | echo You have to create the directory /run/netns. |
4 | fi | 4 | fi |
5 | if [ "$(cat /proc/sys/kernel/unprivileged_userns_clone)" == 1 ]; then | 5 | if [ -f /proc/sys/kernel/unprivileged_userns_clone ]; then |
6 | exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; ./test_transport_start_with_config test_transport_simple_send_topo.conf" | 6 | if [ "$(cat /proc/sys/kernel/unprivileged_userns_clone)" != 1 ]; then |
7 | else | ||
8 | echo -e "Error during test setup: The kernel parameter kernel.unprivileged_userns_clone has to be set to 1! One has to execute\n\n sysctl kernel.unprivileged_userns_clone=1\n" | 7 | echo -e "Error during test setup: The kernel parameter kernel.unprivileged_userns_clone has to be set to 1! One has to execute\n\n sysctl kernel.unprivileged_userns_clone=1\n" |
9 | exit 78 | 8 | exit 78 |
9 | fi | ||
10 | fi | 10 | fi |
11 | exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; ./test_transport_start_with_config test_transport_simple_send_topo.conf" | ||
diff --git a/src/transport/test_transport_simple_send_broadcast.sh b/src/transport/test_transport_simple_send_broadcast.sh index f264b1203..a4801bf70 100755 --- a/src/transport/test_transport_simple_send_broadcast.sh +++ b/src/transport/test_transport_simple_send_broadcast.sh | |||
@@ -2,10 +2,10 @@ | |||
2 | if ! [ -d "/run/netns" ]; then | 2 | if ! [ -d "/run/netns" ]; then |
3 | echo You have to create the directory /run/netns. | 3 | echo You have to create the directory /run/netns. |
4 | fi | 4 | fi |
5 | if [ "$(cat /proc/sys/kernel/unprivileged_userns_clone)" == 1 ]; then | 5 | if [ -f /proc/sys/kernel/unprivileged_userns_clone ]; then |
6 | # exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; valgrind --leak-check=full --track-origins=yes --trace-children=yes --trace-children-skip=/usr/bin/awk,/usr/bin/cut,/usr/bin/seq,/sbin/ip/sed/bash ./test_transport_start_with_config test_transport_simple_send_broadcast_topo.conf" | 6 | if [ "$(cat /proc/sys/kernel/unprivileged_userns_clone)" != 1 ]; then |
7 | exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; ./test_transport_start_with_config test_transport_simple_send_broadcast_topo.conf" | ||
8 | else | ||
9 | echo -e "Error during test setup: The kernel parameter kernel.unprivileged_userns_clone has to be set to 1! One has to execute\n\n sysctl kernel.unprivileged_userns_clone=1\n" | 7 | echo -e "Error during test setup: The kernel parameter kernel.unprivileged_userns_clone has to be set to 1! One has to execute\n\n sysctl kernel.unprivileged_userns_clone=1\n" |
10 | exit 78 | 8 | exit 78 |
9 | fi | ||
11 | fi | 10 | fi |
11 | exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; ./test_transport_start_with_config test_transport_simple_send_broadcast_topo.conf" | ||
diff --git a/src/transport/test_transport_simple_send_dv.sh b/src/transport/test_transport_simple_send_dv.sh index fa127cfa4..b57ee0629 100755 --- a/src/transport/test_transport_simple_send_dv.sh +++ b/src/transport/test_transport_simple_send_dv.sh | |||
@@ -2,10 +2,10 @@ | |||
2 | if ! [ -d "/run/netns" ]; then | 2 | if ! [ -d "/run/netns" ]; then |
3 | echo You have to create the directory /run/netns. | 3 | echo You have to create the directory /run/netns. |
4 | fi | 4 | fi |
5 | if [ "$(cat /proc/sys/kernel/unprivileged_userns_clone)" == 1 ]; then | 5 | if [ -f /proc/sys/kernel/unprivileged_userns_clone ]; then |
6 | # exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; valgrind --leak-check=full --track-origins=yes --trace-children=yes --trace-children-skip=/usr/bin/awk,/usr/bin/cut,/usr/bin/seq,/sbin/ip/sed/bash ./test_transport_start_with_config test_transport_distance_vector_topo.conf" | 6 | if [ "$(cat /proc/sys/kernel/unprivileged_userns_clone)" != 1 ]; then |
7 | exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; ./test_transport_start_with_config test_transport_distance_vector_topo.conf" | ||
8 | else | ||
9 | echo -e "Error during test setup: The kernel parameter kernel.unprivileged_userns_clone has to be set to 1! One has to execute\n\n sysctl kernel.unprivileged_userns_clone=1\n" | 7 | echo -e "Error during test setup: The kernel parameter kernel.unprivileged_userns_clone has to be set to 1! One has to execute\n\n sysctl kernel.unprivileged_userns_clone=1\n" |
10 | exit 78 | 8 | exit 78 |
9 | fi | ||
11 | fi | 10 | fi |
11 | exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; ./test_transport_start_with_config test_transport_distance_vector_topo.conf" | ||
diff --git a/src/transport/test_transport_simple_send_dv_circle.sh b/src/transport/test_transport_simple_send_dv_circle.sh index de16df356..bd5f00abe 100755 --- a/src/transport/test_transport_simple_send_dv_circle.sh +++ b/src/transport/test_transport_simple_send_dv_circle.sh | |||
@@ -2,11 +2,10 @@ | |||
2 | if ! [ -d "/run/netns" ]; then | 2 | if ! [ -d "/run/netns" ]; then |
3 | echo You have to create the directory /run/netns. | 3 | echo You have to create the directory /run/netns. |
4 | fi | 4 | fi |
5 | if [ "$(cat /proc/sys/kernel/unprivileged_userns_clone)" == 1 ]; then | 5 | if [ -f /proc/sys/kernel/unprivileged_userns_clone ]; then |
6 | # exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; valgrind --leak-check=full --track-origins=yes --trace-children=yes --trace-children-skip=/usr/bin/awk,/usr/bin/cut,/usr/bin/seq,/sbin/ip/sed/bash ./test_transport_start_with_config test_transport_distance_vector_topo.conf" | 6 | if [ "$(cat /proc/sys/kernel/unprivileged_userns_clone)" != 1 ]; then |
7 | exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; ./test_transport_start_with_config test_transport_distance_vector_circle_topo.conf" | ||
8 | #./test_transport_start_with_config test_transport_distance_vector_circle_topo.conf | ||
9 | else | ||
10 | echo -e "Error during test setup: The kernel parameter kernel.unprivileged_userns_clone has to be set to 1! One has to execute\n\n sysctl kernel.unprivileged_userns_clone=1\n" | 7 | echo -e "Error during test setup: The kernel parameter kernel.unprivileged_userns_clone has to be set to 1! One has to execute\n\n sysctl kernel.unprivileged_userns_clone=1\n" |
11 | exit 78 | 8 | exit 78 |
9 | fi | ||
12 | fi | 10 | fi |
11 | exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; ./test_transport_start_with_config test_transport_distance_vector_circle_topo.conf" | ||
diff --git a/src/transport/test_transport_simple_send_string.sh b/src/transport/test_transport_simple_send_string.sh index b2bd05d5f..211abb494 100755 --- a/src/transport/test_transport_simple_send_string.sh +++ b/src/transport/test_transport_simple_send_string.sh | |||
@@ -11,9 +11,11 @@ EOF | |||
11 | if ! [ -d "/run/netns" ]; then | 11 | if ! [ -d "/run/netns" ]; then |
12 | echo You have to create the directory /run/netns. | 12 | echo You have to create the directory /run/netns. |
13 | fi | 13 | fi |
14 | if [ "$(cat /proc/sys/kernel/unprivileged_userns_clone)" == 1 ]; then | 14 | if [ -f /proc/sys/kernel/unprivileged_userns_clone ]; then |
15 | exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; ./test_transport_start_with_config -s '$string'" | 15 | if [ "$(cat /proc/sys/kernel/unprivileged_userns_clone)" != 1 ]; then |
16 | else | ||
17 | echo -e "Error during test setup: The kernel parameter kernel.unprivileged_userns_clone has to be set to 1! One has to execute\n\n sysctl kernel.unprivileged_userns_clone=1\n" | 16 | echo -e "Error during test setup: The kernel parameter kernel.unprivileged_userns_clone has to be set to 1! One has to execute\n\n sysctl kernel.unprivileged_userns_clone=1\n" |
18 | exit 78 | 17 | exit 78 |
18 | fi | ||
19 | fi | 19 | fi |
20 | |||
21 | exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; ./test_transport_start_with_config -s '$string'" | ||
diff --git a/src/transport/test_transport_udp_backchannel.sh b/src/transport/test_transport_udp_backchannel.sh index c52734a55..1a7c83385 100755 --- a/src/transport/test_transport_udp_backchannel.sh +++ b/src/transport/test_transport_udp_backchannel.sh | |||
@@ -5,11 +5,10 @@ fi | |||
5 | if ! [ -d "/run/netns" ]; then | 5 | if ! [ -d "/run/netns" ]; then |
6 | echo You have to create the directory /run/netns. | 6 | echo You have to create the directory /run/netns. |
7 | fi | 7 | fi |
8 | if [ "$(cat /proc/sys/kernel/unprivileged_userns_clone)" == 1 ]; then | 8 | if [ -f /proc/sys/kernel/unprivileged_userns_clone ]; then |
9 | #exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; valgrind --leak-check=full --track-origins=yes --trace-children=yes --trace-children-skip=/usr/bin/awk,/usr/bin/cut,/usr/bin/seq,/sbin/ip ./test_transport_start_with_config test_transport_udp_backchannel_topo.conf" | 9 | if [ "$(cat /proc/sys/kernel/unprivileged_userns_clone)" != 1 ]; then |
10 | exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; GNUNET_FORCE_LOG=';;;;DEBUG' GNUNET_FORCE_LOGFILE='test.out' ./test_transport_start_with_config test_transport_udp_backchannel_topo.conf" | ||
11 | # exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; valgrind --leak-check=full --track-origins=yes ./test_transport_start_with_config test_transport_udp_backchannel_topo.conf" | ||
12 | else | ||
13 | echo -e "Error during test setup: The kernel parameter kernel.unprivileged_userns_clone has to be set to 1! One has to execute\n\n sysctl kernel.unprivileged_userns_clone=1\n" | 10 | echo -e "Error during test setup: The kernel parameter kernel.unprivileged_userns_clone has to be set to 1! One has to execute\n\n sysctl kernel.unprivileged_userns_clone=1\n" |
14 | exit 78 | 11 | exit 78 |
12 | fi | ||
15 | fi | 13 | fi |
14 | exec unshare -r -nmU bash -c "mount -t tmpfs --make-rshared tmpfs /run/netns; GNUNET_FORCE_LOG=';;;;DEBUG' GNUNET_FORCE_LOGFILE='test.out' ./test_transport_start_with_config test_transport_udp_backchannel_topo.conf" | ||
diff --git a/src/util/common_logging.c b/src/util/common_logging.c index cba37cd2f..b07f3fc0b 100644 --- a/src/util/common_logging.c +++ b/src/util/common_logging.c | |||
@@ -321,6 +321,28 @@ log_rotate (const char *new_name) | |||
321 | } | 321 | } |
322 | 322 | ||
323 | 323 | ||
324 | const char * | ||
325 | GNUNET_b2s (const void *buf, | ||
326 | size_t buf_size) | ||
327 | { | ||
328 | static GNUNET_THREAD_LOCAL char ret[9]; | ||
329 | struct GNUNET_HashCode hc; | ||
330 | char *tmp; | ||
331 | |||
332 | GNUNET_CRYPTO_hash (buf, | ||
333 | buf_size, | ||
334 | &hc); | ||
335 | tmp = GNUNET_STRINGS_data_to_string_alloc (&hc, | ||
336 | sizeof (hc)); | ||
337 | memcpy (ret, | ||
338 | tmp, | ||
339 | 8); | ||
340 | GNUNET_free (tmp); | ||
341 | ret[8] = '\0'; | ||
342 | return ret; | ||
343 | } | ||
344 | |||
345 | |||
324 | /** | 346 | /** |
325 | * Setup the log file. | 347 | * Setup the log file. |
326 | * | 348 | * |
@@ -1015,7 +1037,8 @@ mylog (enum GNUNET_ErrorType kind, | |||
1015 | else | 1037 | else |
1016 | { | 1038 | { |
1017 | /* RFC 3339 timestamp, with snprintf placeholder for microseconds */ | 1039 | /* RFC 3339 timestamp, with snprintf placeholder for microseconds */ |
1018 | if (0 == strftime (date2, DATE_STR_SIZE, "%Y-%m-%dT%H:%M:%S.%%06u%z", tmptr)) | 1040 | if (0 == strftime (date2, DATE_STR_SIZE, "%Y-%m-%dT%H:%M:%S.%%06u%z", |
1041 | tmptr)) | ||
1019 | abort (); | 1042 | abort (); |
1020 | /* Fill in microseconds */ | 1043 | /* Fill in microseconds */ |
1021 | if (0 > snprintf (date, sizeof(date), date2, timeofday.tv_usec)) | 1044 | if (0 > snprintf (date, sizeof(date), date2, timeofday.tv_usec)) |
diff --git a/src/util/crypto_cs.c b/src/util/crypto_cs.c index c89ba5d83..4c6648229 100644 --- a/src/util/crypto_cs.c +++ b/src/util/crypto_cs.c | |||
@@ -40,11 +40,6 @@ | |||
40 | */ | 40 | */ |
41 | 41 | ||
42 | 42 | ||
43 | /** | ||
44 | * Create a new random private key. | ||
45 | * | ||
46 | * @param[out] priv where to write the fresh private key | ||
47 | */ | ||
48 | void | 43 | void |
49 | GNUNET_CRYPTO_cs_private_key_generate (struct GNUNET_CRYPTO_CsPrivateKey *priv) | 44 | GNUNET_CRYPTO_cs_private_key_generate (struct GNUNET_CRYPTO_CsPrivateKey *priv) |
50 | { | 45 | { |
@@ -52,16 +47,10 @@ GNUNET_CRYPTO_cs_private_key_generate (struct GNUNET_CRYPTO_CsPrivateKey *priv) | |||
52 | } | 47 | } |
53 | 48 | ||
54 | 49 | ||
55 | /** | ||
56 | * Extract the public key of the given private key. | ||
57 | * | ||
58 | * @param priv the private key | ||
59 | * @param[out] pub where to write the public key | ||
60 | */ | ||
61 | void | 50 | void |
62 | GNUNET_CRYPTO_cs_private_key_get_public (const struct | 51 | GNUNET_CRYPTO_cs_private_key_get_public ( |
63 | GNUNET_CRYPTO_CsPrivateKey *priv, | 52 | const struct GNUNET_CRYPTO_CsPrivateKey *priv, |
64 | struct GNUNET_CRYPTO_CsPublicKey *pub) | 53 | struct GNUNET_CRYPTO_CsPublicKey *pub) |
65 | { | 54 | { |
66 | GNUNET_assert (0 == crypto_scalarmult_ed25519_base_noclamp (pub->point.y, | 55 | GNUNET_assert (0 == crypto_scalarmult_ed25519_base_noclamp (pub->point.y, |
67 | priv->scalar.d)); | 56 | priv->scalar.d)); |
@@ -69,63 +58,40 @@ GNUNET_CRYPTO_cs_private_key_get_public (const struct | |||
69 | 58 | ||
70 | 59 | ||
71 | /** | 60 | /** |
72 | * maps 32 random bytes to a scalar | 61 | * Maps 32 random bytes to a scalar. This is necessary because libsodium |
73 | * this is necessary because libsodium expects scalar to be in the prime order subgroup | 62 | * expects scalar to be in the prime order subgroup. |
74 | * @param[out] scalar containing 32 byte char array, is modified to be in prime order subgroup | 63 | * |
64 | * @param[in,out] scalar containing 32 byte char array, is modified to be in prime order subgroup | ||
75 | */ | 65 | */ |
76 | static void | 66 | static void |
77 | map_to_scalar_subgroup (struct GNUNET_CRYPTO_Cs25519Scalar *scalar) | 67 | map_to_scalar_subgroup (struct GNUNET_CRYPTO_Cs25519Scalar *scalar) |
78 | { | 68 | { |
79 | // perform clamping as described in RFC7748 | 69 | /* perform clamping as described in RFC7748 */ |
80 | scalar->d[0] &= 248; | 70 | scalar->d[0] &= 248; |
81 | scalar->d[31] &= 127; | 71 | scalar->d[31] &= 127; |
82 | scalar->d[31] |= 64; | 72 | scalar->d[31] |= 64; |
83 | } | 73 | } |
84 | 74 | ||
85 | 75 | ||
86 | /** | ||
87 | * Derive a new secret r pair r0 and r1. | ||
88 | * In original papers r is generated randomly | ||
89 | * To provide abort-idempotency, r needs to be derived but still needs to be UNPREDICTABLE | ||
90 | * To ensure unpredictability a new nonce should be used when a new r needs to be derived. | ||
91 | * Uses HKDF internally. | ||
92 | * Comment: Can be done in one HKDF shot and split output. | ||
93 | * | ||
94 | * @param nonce is a random nonce | ||
95 | * @param lts is a long-term-secret in form of a private key | ||
96 | * @param[out] r array containing derived secrets r0 and r1 | ||
97 | */ | ||
98 | void | 76 | void |
99 | GNUNET_CRYPTO_cs_r_derive (const struct GNUNET_CRYPTO_CsNonce *nonce, | 77 | GNUNET_CRYPTO_cs_r_derive (const struct GNUNET_CRYPTO_CsNonce *nonce, |
78 | const char *seed, | ||
100 | const struct GNUNET_CRYPTO_CsPrivateKey *lts, | 79 | const struct GNUNET_CRYPTO_CsPrivateKey *lts, |
101 | struct GNUNET_CRYPTO_CsRSecret r[2]) | 80 | struct GNUNET_CRYPTO_CsRSecret r[2]) |
102 | { | 81 | { |
103 | GNUNET_assert (GNUNET_YES == | 82 | GNUNET_assert ( |
104 | GNUNET_CRYPTO_hkdf (r, | 83 | GNUNET_YES == |
105 | sizeof (struct GNUNET_CRYPTO_CsRSecret) | 84 | GNUNET_CRYPTO_kdf ( |
106 | * 2, | 85 | r, sizeof (struct GNUNET_CRYPTO_CsRSecret) * 2, |
107 | GCRY_MD_SHA512, | 86 | seed, strlen (seed), |
108 | GCRY_MD_SHA256, | 87 | lts, sizeof (*lts), |
109 | "r", | 88 | nonce, sizeof (*nonce), |
110 | strlen ("r"), | 89 | NULL, 0)); |
111 | lts, | ||
112 | sizeof (*lts), | ||
113 | nonce, | ||
114 | sizeof (*nonce), | ||
115 | NULL, | ||
116 | 0)); | ||
117 | |||
118 | map_to_scalar_subgroup (&r[0].scalar); | 90 | map_to_scalar_subgroup (&r[0].scalar); |
119 | map_to_scalar_subgroup (&r[1].scalar); | 91 | map_to_scalar_subgroup (&r[1].scalar); |
120 | } | 92 | } |
121 | 93 | ||
122 | 94 | ||
123 | /** | ||
124 | * Extract the public R of the given secret r. | ||
125 | * | ||
126 | * @param r_priv the private key | ||
127 | * @param[out] r_pub where to write the public key | ||
128 | */ | ||
129 | void | 95 | void |
130 | GNUNET_CRYPTO_cs_r_get_public (const struct GNUNET_CRYPTO_CsRSecret *r_priv, | 96 | GNUNET_CRYPTO_cs_r_get_public (const struct GNUNET_CRYPTO_CsRSecret *r_priv, |
131 | struct GNUNET_CRYPTO_CsRPublic *r_pub) | 97 | struct GNUNET_CRYPTO_CsRPublic *r_pub) |
@@ -135,36 +101,23 @@ GNUNET_CRYPTO_cs_r_get_public (const struct GNUNET_CRYPTO_CsRSecret *r_priv, | |||
135 | } | 101 | } |
136 | 102 | ||
137 | 103 | ||
138 | /** | ||
139 | * Derives new random blinding factors. | ||
140 | * In original papers blinding factors are generated randomly | ||
141 | * To provide abort-idempotency, blinding factors need to be derived but still need to be UNPREDICTABLE | ||
142 | * To ensure unpredictability a new nonce has to be used. | ||
143 | * Uses HKDF internally | ||
144 | * | ||
145 | * @param secret is secret to derive blinding factors | ||
146 | * @param secret_len secret length | ||
147 | * @param[out] bs array containing the two derived blinding secrets | ||
148 | */ | ||
149 | void | 104 | void |
150 | GNUNET_CRYPTO_cs_blinding_secrets_derive (const struct | 105 | GNUNET_CRYPTO_cs_blinding_secrets_derive ( |
151 | GNUNET_CRYPTO_CsNonce *blind_seed, | 106 | const struct GNUNET_CRYPTO_CsNonce *blind_seed, |
152 | struct GNUNET_CRYPTO_CsBlindingSecret | 107 | struct GNUNET_CRYPTO_CsBlindingSecret bs[2]) |
153 | bs[2]) | ||
154 | { | 108 | { |
155 | GNUNET_assert (GNUNET_YES == | 109 | GNUNET_assert ( |
156 | GNUNET_CRYPTO_hkdf (bs, | 110 | GNUNET_YES == |
157 | sizeof (struct | 111 | GNUNET_CRYPTO_hkdf (bs, |
158 | GNUNET_CRYPTO_CsBlindingSecret) | 112 | sizeof (struct GNUNET_CRYPTO_CsBlindingSecret) * 2, |
159 | * 2, | 113 | GCRY_MD_SHA512, |
160 | GCRY_MD_SHA512, | 114 | GCRY_MD_SHA256, |
161 | GCRY_MD_SHA256, | 115 | "alphabeta", |
162 | "alphabeta", | 116 | strlen ("alphabeta"), |
163 | strlen ("alphabeta"), | 117 | blind_seed, |
164 | blind_seed, | 118 | sizeof(*blind_seed), |
165 | sizeof(*blind_seed), | 119 | NULL, |
166 | NULL, | 120 | 0)); |
167 | 0)); | ||
168 | map_to_scalar_subgroup (&bs[0].alpha); | 121 | map_to_scalar_subgroup (&bs[0].alpha); |
169 | map_to_scalar_subgroup (&bs[0].beta); | 122 | map_to_scalar_subgroup (&bs[0].beta); |
170 | map_to_scalar_subgroup (&bs[1].alpha); | 123 | map_to_scalar_subgroup (&bs[1].alpha); |
@@ -205,11 +158,16 @@ cs_full_domain_hash (const struct GNUNET_CRYPTO_CsRPublic *r_dash, | |||
205 | memcpy (r_m_concat, r_dash, sizeof(struct GNUNET_CRYPTO_CsRPublic)); | 158 | memcpy (r_m_concat, r_dash, sizeof(struct GNUNET_CRYPTO_CsRPublic)); |
206 | memcpy (r_m_concat + sizeof(struct GNUNET_CRYPTO_CsRPublic), msg, msg_len); | 159 | memcpy (r_m_concat + sizeof(struct GNUNET_CRYPTO_CsRPublic), msg, msg_len); |
207 | struct GNUNET_HashCode prehash; | 160 | struct GNUNET_HashCode prehash; |
208 | GNUNET_CRYPTO_hash (r_m_concat, r_m_concat_len, &prehash); | 161 | |
162 | GNUNET_CRYPTO_hash (r_m_concat, | ||
163 | r_m_concat_len, | ||
164 | &prehash); | ||
209 | 165 | ||
210 | // modulus converted to MPI representation | 166 | // modulus converted to MPI representation |
211 | gcry_mpi_t l_mpi; | 167 | gcry_mpi_t l_mpi; |
212 | GNUNET_CRYPTO_mpi_scan_unsigned (&l_mpi, L_BIG_ENDIAN, sizeof(L_BIG_ENDIAN)); | 168 | GNUNET_CRYPTO_mpi_scan_unsigned (&l_mpi, |
169 | L_BIG_ENDIAN, | ||
170 | sizeof(L_BIG_ENDIAN)); | ||
213 | 171 | ||
214 | // calculate full domain hash | 172 | // calculate full domain hash |
215 | gcry_mpi_t c_mpi; | 173 | gcry_mpi_t c_mpi; |
@@ -224,7 +182,9 @@ cs_full_domain_hash (const struct GNUNET_CRYPTO_CsRPublic *r_dash, | |||
224 | 182 | ||
225 | // convert c from mpi | 183 | // convert c from mpi |
226 | unsigned char c_big_endian[256 / 8]; | 184 | unsigned char c_big_endian[256 / 8]; |
227 | GNUNET_CRYPTO_mpi_print_unsigned (c_big_endian, sizeof(c_big_endian), c_mpi); | 185 | GNUNET_CRYPTO_mpi_print_unsigned (c_big_endian, |
186 | sizeof(c_big_endian), | ||
187 | c_mpi); | ||
228 | gcry_mpi_release (c_mpi); | 188 | gcry_mpi_release (c_mpi); |
229 | for (size_t i = 0; i<32; i++) | 189 | for (size_t i = 0; i<32; i++) |
230 | c->scalar.d[i] = c_big_endian[31 - i]; | 190 | c->scalar.d[i] = c_big_endian[31 - i]; |
@@ -266,28 +226,15 @@ calc_r_dash (const struct GNUNET_CRYPTO_CsBlindingSecret *bs, | |||
266 | } | 226 | } |
267 | 227 | ||
268 | 228 | ||
269 | /** | ||
270 | * Calculate two blinded c's | ||
271 | * Comment: One would be insecure due to Wagner's algorithm solving ROS | ||
272 | * | ||
273 | * @param bs array of the two blinding factor structs each containing alpha and beta | ||
274 | * @param r_pub array of the two signer's nonce R | ||
275 | * @param pub the public key of the signer | ||
276 | * @param msg the message to blind in preparation for signing | ||
277 | * @param msg_len length of message msg | ||
278 | * @param[out] blinded_c array of the two blinded c's | ||
279 | * @param[out] blinded_r_pub array of the two blinded R | ||
280 | */ | ||
281 | void | 229 | void |
282 | GNUNET_CRYPTO_cs_calc_blinded_c (const struct GNUNET_CRYPTO_CsBlindingSecret | 230 | GNUNET_CRYPTO_cs_calc_blinded_c ( |
283 | bs[2], | 231 | const struct GNUNET_CRYPTO_CsBlindingSecret bs[2], |
284 | const struct GNUNET_CRYPTO_CsRPublic r_pub[2], | 232 | const struct GNUNET_CRYPTO_CsRPublic r_pub[2], |
285 | const struct GNUNET_CRYPTO_CsPublicKey *pub, | 233 | const struct GNUNET_CRYPTO_CsPublicKey *pub, |
286 | const void *msg, | 234 | const void *msg, |
287 | size_t msg_len, | 235 | size_t msg_len, |
288 | struct GNUNET_CRYPTO_CsC blinded_c[2], | 236 | struct GNUNET_CRYPTO_CsC blinded_c[2], |
289 | struct GNUNET_CRYPTO_CsRPublic | 237 | struct GNUNET_CRYPTO_CsRPublic blinded_r_pub[2]) |
290 | blinded_r_pub[2]) | ||
291 | { | 238 | { |
292 | // for i 0/1: R'i = Ri + alpha i*G + beta i*pub | 239 | // for i 0/1: R'i = Ri + alpha i*G + beta i*pub |
293 | calc_r_dash (&bs[0], &r_pub[0], pub, &blinded_r_pub[0]); | 240 | calc_r_dash (&bs[0], &r_pub[0], pub, &blinded_r_pub[0]); |
@@ -309,30 +256,13 @@ GNUNET_CRYPTO_cs_calc_blinded_c (const struct GNUNET_CRYPTO_CsBlindingSecret | |||
309 | } | 256 | } |
310 | 257 | ||
311 | 258 | ||
312 | /** | ||
313 | * Sign a blinded c | ||
314 | * This function derives b from a nonce and a longterm secret | ||
315 | * In original papers b is generated randomly | ||
316 | * To provide abort-idempotency, b needs to be derived but still need to be UNPREDICTABLE. | ||
317 | * To ensure unpredictability a new nonce has to be used for every signature | ||
318 | * HKDF is used internally for derivation | ||
319 | * r0 and r1 can be derived prior by using GNUNET_CRYPTO_cs_r_derive | ||
320 | * | ||
321 | * @param priv private key to use for the signing and as LTS in HKDF | ||
322 | * @param r array of the two secret nonce from the signer | ||
323 | * @param c array of the two blinded c to sign c_b | ||
324 | * @param nonce is a random nonce | ||
325 | * @param[out] blinded_signature_scalar where to write the signature | ||
326 | * @return 0 or 1 for b (see Clause Blind Signature Scheme) | ||
327 | */ | ||
328 | unsigned int | 259 | unsigned int |
329 | GNUNET_CRYPTO_cs_sign_derive (const struct GNUNET_CRYPTO_CsPrivateKey *priv, | 260 | GNUNET_CRYPTO_cs_sign_derive ( |
330 | const struct GNUNET_CRYPTO_CsRSecret r[2], | 261 | const struct GNUNET_CRYPTO_CsPrivateKey *priv, |
331 | const struct GNUNET_CRYPTO_CsC c[2], | 262 | const struct GNUNET_CRYPTO_CsRSecret r[2], |
332 | const struct GNUNET_CRYPTO_CsNonce *nonce, | 263 | const struct GNUNET_CRYPTO_CsC c[2], |
333 | struct GNUNET_CRYPTO_CsBlindS * | 264 | const struct GNUNET_CRYPTO_CsNonce *nonce, |
334 | blinded_signature_scalar | 265 | struct GNUNET_CRYPTO_CsBlindS *blinded_signature_scalar) |
335 | ) | ||
336 | { | 266 | { |
337 | uint32_t hkdf_out; | 267 | uint32_t hkdf_out; |
338 | 268 | ||
@@ -365,18 +295,11 @@ GNUNET_CRYPTO_cs_sign_derive (const struct GNUNET_CRYPTO_CsPrivateKey *priv, | |||
365 | } | 295 | } |
366 | 296 | ||
367 | 297 | ||
368 | /** | ||
369 | * Unblind a blind-signed signature using a c that was blinded | ||
370 | * | ||
371 | * @param blinded_signature_scalar the signature made on the blinded c | ||
372 | * @param bs the blinding factors used in the blinding | ||
373 | * @param[out] signature_scalar where to write the unblinded signature | ||
374 | */ | ||
375 | void | 298 | void |
376 | GNUNET_CRYPTO_cs_unblind (const struct | 299 | GNUNET_CRYPTO_cs_unblind ( |
377 | GNUNET_CRYPTO_CsBlindS *blinded_signature_scalar, | 300 | const struct GNUNET_CRYPTO_CsBlindS *blinded_signature_scalar, |
378 | const struct GNUNET_CRYPTO_CsBlindingSecret *bs, | 301 | const struct GNUNET_CRYPTO_CsBlindingSecret *bs, |
379 | struct GNUNET_CRYPTO_CsS *signature_scalar) | 302 | struct GNUNET_CRYPTO_CsS *signature_scalar) |
380 | { | 303 | { |
381 | crypto_core_ed25519_scalar_add (signature_scalar->scalar.d, | 304 | crypto_core_ed25519_scalar_add (signature_scalar->scalar.d, |
382 | blinded_signature_scalar->scalar.d, | 305 | blinded_signature_scalar->scalar.d, |
@@ -384,16 +307,6 @@ GNUNET_CRYPTO_cs_unblind (const struct | |||
384 | } | 307 | } |
385 | 308 | ||
386 | 309 | ||
387 | /** | ||
388 | * Verify whether the given message corresponds to the given signature and the | ||
389 | * signature is valid with respect to the given public key. | ||
390 | * | ||
391 | * @param sig signature that is being validated | ||
392 | * @param pub public key of the signer | ||
393 | * @param msg is the message that should be signed by @a sig (message is used to calculate c) | ||
394 | * @param msg_len is the message length | ||
395 | * @returns #GNUNET_YES on success, #GNUNET_SYSERR if signature invalid | ||
396 | */ | ||
397 | enum GNUNET_GenericReturnValue | 310 | enum GNUNET_GenericReturnValue |
398 | GNUNET_CRYPTO_cs_verify (const struct GNUNET_CRYPTO_CsSignature *sig, | 311 | GNUNET_CRYPTO_cs_verify (const struct GNUNET_CRYPTO_CsSignature *sig, |
399 | const struct GNUNET_CRYPTO_CsPublicKey *pub, | 312 | const struct GNUNET_CRYPTO_CsPublicKey *pub, |
@@ -402,7 +315,12 @@ GNUNET_CRYPTO_cs_verify (const struct GNUNET_CRYPTO_CsSignature *sig, | |||
402 | { | 315 | { |
403 | // calculate c' = H(R, m) | 316 | // calculate c' = H(R, m) |
404 | struct GNUNET_CRYPTO_CsC c_dash; | 317 | struct GNUNET_CRYPTO_CsC c_dash; |
405 | cs_full_domain_hash (&sig->r_point, msg, msg_len, pub, &c_dash); | 318 | |
319 | cs_full_domain_hash (&sig->r_point, | ||
320 | msg, | ||
321 | msg_len, | ||
322 | pub, | ||
323 | &c_dash); | ||
406 | 324 | ||
407 | // s'G ?= R' + c' pub | 325 | // s'G ?= R' + c' pub |
408 | struct GNUNET_CRYPTO_Cs25519Point sig_scal_mul_base; | 326 | struct GNUNET_CRYPTO_Cs25519Point sig_scal_mul_base; |
diff --git a/src/util/crypto_hash.c b/src/util/crypto_hash.c index dcd46e5f9..f516f5474 100644 --- a/src/util/crypto_hash.c +++ b/src/util/crypto_hash.c | |||
@@ -76,7 +76,8 @@ GNUNET_CRYPTO_hash_from_string2 (const char *enc, | |||
76 | char upper_enc[enclen]; | 76 | char upper_enc[enclen]; |
77 | char *up_ptr = upper_enc; | 77 | char *up_ptr = upper_enc; |
78 | 78 | ||
79 | GNUNET_STRINGS_utf8_toupper (enc, up_ptr); | 79 | if (GNUNET_OK != GNUNET_STRINGS_utf8_toupper (enc, up_ptr)) |
80 | return GNUNET_SYSERR; | ||
80 | 81 | ||
81 | return GNUNET_STRINGS_string_to_data (upper_enc, enclen, | 82 | return GNUNET_STRINGS_string_to_data (upper_enc, enclen, |
82 | (unsigned char *) result, | 83 | (unsigned char *) result, |
diff --git a/src/util/dnsstub.c b/src/util/dnsstub.c index 1ac274c92..c2f2a441f 100644 --- a/src/util/dnsstub.c +++ b/src/util/dnsstub.c | |||
@@ -324,24 +324,50 @@ do_dns_read (struct GNUNET_DNSSTUB_RequestSocket *rs, | |||
324 | found = GNUNET_NO; | 324 | found = GNUNET_NO; |
325 | for (struct DnsServer *ds = ctx->dns_head; NULL != ds; ds = ds->next) | 325 | for (struct DnsServer *ds = ctx->dns_head; NULL != ds; ds = ds->next) |
326 | { | 326 | { |
327 | if (0 == memcmp (&addr, | 327 | if (ds->ss.ss_family != addr.ss_family) |
328 | &ds->ss, | 328 | continue; |
329 | GNUNET_MIN (sizeof(struct sockaddr_storage), addrlen))) | 329 | if (addr.ss_family == AF_INET) |
330 | { | 330 | { |
331 | found = GNUNET_YES; | 331 | struct sockaddr_in *v4 = (struct sockaddr_in *) &addr; |
332 | break; | 332 | struct sockaddr_in *ds_v4 = (struct sockaddr_in *) &ds->ss; |
333 | |||
334 | |||
335 | if ((0 == memcmp (&v4->sin_addr, | ||
336 | &ds_v4->sin_addr, | ||
337 | sizeof(struct sockaddr_in))) && | ||
338 | (v4->sin_port == ds_v4->sin_port)) | ||
339 | { | ||
340 | found = GNUNET_YES; | ||
341 | break; | ||
342 | } | ||
343 | } | ||
344 | else | ||
345 | { | ||
346 | struct sockaddr_in6 *v6 = (struct sockaddr_in6 *) &addr; | ||
347 | struct sockaddr_in6 *ds_v6 = (struct sockaddr_in6 *) &ds->ss; | ||
348 | |||
349 | if (0 == memcmp (&v6->sin6_addr, | ||
350 | &ds_v6->sin6_addr, | ||
351 | sizeof (v6->sin6_addr)) && | ||
352 | (v6->sin6_port == ds_v6->sin6_port)) | ||
353 | { | ||
354 | found = GNUNET_YES; | ||
355 | break; | ||
356 | } | ||
357 | |||
333 | } | 358 | } |
334 | } | 359 | } |
335 | if (GNUNET_NO == found) | 360 | if (GNUNET_NO == found) |
336 | { | 361 | { |
337 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 362 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
338 | "Received DNS response from server we never asked (ignored)"); | 363 | "Received DNS response from server we never asked (ignored)\n"); |
364 | |||
339 | return GNUNET_NO; | 365 | return GNUNET_NO; |
340 | } | 366 | } |
341 | if (sizeof(struct GNUNET_TUN_DnsHeader) > (size_t) r) | 367 | if (sizeof(struct GNUNET_TUN_DnsHeader) > (size_t) r) |
342 | { | 368 | { |
343 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | 369 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, |
344 | _ ("Received DNS response that is too small (%u bytes)"), | 370 | _ ("Received DNS response that is too small (%u bytes)\n"), |
345 | (unsigned int) r); | 371 | (unsigned int) r); |
346 | return GNUNET_NO; | 372 | return GNUNET_NO; |
347 | } | 373 | } |
@@ -648,7 +674,7 @@ GNUNET_DNSSTUB_add_dns_sa (struct GNUNET_DNSSTUB_Context *ctx, | |||
648 | ds = GNUNET_new (struct DnsServer); | 674 | ds = GNUNET_new (struct DnsServer); |
649 | switch (sa->sa_family) | 675 | switch (sa->sa_family) |
650 | { | 676 | { |
651 | case AF_INET: | 677 | case AF_INET : |
652 | GNUNET_memcpy (&ds->ss, sa, sizeof(struct sockaddr_in)); | 678 | GNUNET_memcpy (&ds->ss, sa, sizeof(struct sockaddr_in)); |
653 | break; | 679 | break; |
654 | 680 | ||
diff --git a/src/util/getopt_helpers.c b/src/util/getopt_helpers.c index 917aa440b..96aee40e3 100644 --- a/src/util/getopt_helpers.c +++ b/src/util/getopt_helpers.c | |||
@@ -174,7 +174,8 @@ OUTER: | |||
174 | i++; | 174 | i++; |
175 | } | 175 | } |
176 | pd = GNUNET_OS_project_data_get (); | 176 | pd = GNUNET_OS_project_data_get (); |
177 | printf ("Report bugs to %s.\n" | 177 | printf ("\n" |
178 | "Report bugs to %s.\n" | ||
178 | "Home page: %s\n", | 179 | "Home page: %s\n", |
179 | pd->bug_email, | 180 | pd->bug_email, |
180 | pd->homepage); | 181 | pd->homepage); |
diff --git a/src/util/gnunet-crypto-tvg.c b/src/util/gnunet-crypto-tvg.c index 6b2a7f472..0071f3e90 100644 --- a/src/util/gnunet-crypto-tvg.c +++ b/src/util/gnunet-crypto-tvg.c | |||
@@ -852,7 +852,7 @@ checkvec (const char *operation, | |||
852 | return GNUNET_SYSERR; | 852 | return GNUNET_SYSERR; |
853 | } | 853 | } |
854 | 854 | ||
855 | if ((b != 1)&& (b != 0)) | 855 | if ((b != 1) && (b != 0)) |
856 | { | 856 | { |
857 | GNUNET_break (0); | 857 | GNUNET_break (0); |
858 | return GNUNET_SYSERR; | 858 | return GNUNET_SYSERR; |
@@ -869,9 +869,14 @@ checkvec (const char *operation, | |||
869 | unsigned int b_comp; | 869 | unsigned int b_comp; |
870 | 870 | ||
871 | 871 | ||
872 | GNUNET_CRYPTO_cs_r_derive (&nonce, &priv, r_priv_comp); | 872 | GNUNET_CRYPTO_cs_r_derive (&nonce, |
873 | GNUNET_CRYPTO_cs_r_get_public (&r_priv_comp[0], &r_pub_comp[0]); | 873 | "rw", |
874 | GNUNET_CRYPTO_cs_r_get_public (&r_priv_comp[1], &r_pub_comp[1]); | 874 | &priv, |
875 | r_priv_comp); | ||
876 | GNUNET_CRYPTO_cs_r_get_public (&r_priv_comp[0], | ||
877 | &r_pub_comp[0]); | ||
878 | GNUNET_CRYPTO_cs_r_get_public (&r_priv_comp[1], | ||
879 | &r_pub_comp[1]); | ||
875 | GNUNET_assert (0 == memcmp (&r_priv_comp, | 880 | GNUNET_assert (0 == memcmp (&r_priv_comp, |
876 | &r_priv, | 881 | &r_priv, |
877 | sizeof(struct GNUNET_CRYPTO_CsRSecret) * 2)); | 882 | sizeof(struct GNUNET_CRYPTO_CsRSecret) * 2)); |
@@ -1316,9 +1321,14 @@ output_vectors () | |||
1316 | strlen ("nonce_secret"), | 1321 | strlen ("nonce_secret"), |
1317 | NULL, | 1322 | NULL, |
1318 | 0)); | 1323 | 0)); |
1319 | GNUNET_CRYPTO_cs_r_derive (&nonce, &priv, r_priv); | 1324 | GNUNET_CRYPTO_cs_r_derive (&nonce, |
1320 | GNUNET_CRYPTO_cs_r_get_public (&r_priv[0], &r_pub[0]); | 1325 | "rw", |
1321 | GNUNET_CRYPTO_cs_r_get_public (&r_priv[1], &r_pub[1]); | 1326 | &priv, |
1327 | r_priv); | ||
1328 | GNUNET_CRYPTO_cs_r_get_public (&r_priv[0], | ||
1329 | &r_pub[0]); | ||
1330 | GNUNET_CRYPTO_cs_r_get_public (&r_priv[1], | ||
1331 | &r_pub[1]); | ||
1322 | GNUNET_CRYPTO_cs_blinding_secrets_derive (&nonce, | 1332 | GNUNET_CRYPTO_cs_blinding_secrets_derive (&nonce, |
1323 | bs); | 1333 | bs); |
1324 | GNUNET_CRYPTO_cs_calc_blinded_c (bs, | 1334 | GNUNET_CRYPTO_cs_calc_blinded_c (bs, |
diff --git a/src/util/network.c b/src/util/network.c index 688c37665..2f77bc54e 100644 --- a/src/util/network.c +++ b/src/util/network.c | |||
@@ -350,7 +350,8 @@ initialize_network_handle (struct GNUNET_NETWORK_Handle *h, | |||
350 | 350 | ||
351 | if (h->fd >= FD_SETSIZE) | 351 | if (h->fd >= FD_SETSIZE) |
352 | { | 352 | { |
353 | GNUNET_break (GNUNET_OK == GNUNET_NETWORK_socket_close (h)); | 353 | GNUNET_break (GNUNET_OK == |
354 | GNUNET_NETWORK_socket_close (h)); | ||
354 | errno = EMFILE; | 355 | errno = EMFILE; |
355 | return GNUNET_SYSERR; | 356 | return GNUNET_SYSERR; |
356 | } | 357 | } |
diff --git a/src/util/plugin.c b/src/util/plugin.c index 39874a588..6ee41eec9 100644 --- a/src/util/plugin.c +++ b/src/util/plugin.c | |||
@@ -289,12 +289,12 @@ GNUNET_PLUGIN_unload (const char *library_name, | |||
289 | done = resolve_function (pos, | 289 | done = resolve_function (pos, |
290 | "done"); | 290 | "done"); |
291 | ret = NULL; | 291 | ret = NULL; |
292 | if (NULL != done) | ||
293 | ret = done (arg); | ||
294 | if (NULL == prev) | 292 | if (NULL == prev) |
295 | plugins = pos->next; | 293 | plugins = pos->next; |
296 | else | 294 | else |
297 | prev->next = pos->next; | 295 | prev->next = pos->next; |
296 | if (NULL != done) | ||
297 | ret = done (arg); | ||
298 | lt_dlclose (pos->handle); | 298 | lt_dlclose (pos->handle); |
299 | GNUNET_free (pos->name); | 299 | GNUNET_free (pos->name); |
300 | GNUNET_free (pos); | 300 | GNUNET_free (pos); |
diff --git a/src/util/strings.c b/src/util/strings.c index ece096f72..7e218cc59 100644 --- a/src/util/strings.c +++ b/src/util/strings.c | |||
@@ -390,7 +390,7 @@ GNUNET_STRINGS_conv (const char *input, | |||
390 | ret[encoded_string_length] = '\0'; | 390 | ret[encoded_string_length] = '\0'; |
391 | free (encoded_string); | 391 | free (encoded_string); |
392 | return ret; | 392 | return ret; |
393 | fail: | 393 | fail: |
394 | LOG (GNUNET_ERROR_TYPE_WARNING, | 394 | LOG (GNUNET_ERROR_TYPE_WARNING, |
395 | _ ("Character sets requested were `%s'->`%s'\n"), | 395 | _ ("Character sets requested were `%s'->`%s'\n"), |
396 | "UTF-8", | 396 | "UTF-8", |
@@ -426,24 +426,27 @@ GNUNET_STRINGS_from_utf8 (const char *input, | |||
426 | } | 426 | } |
427 | 427 | ||
428 | 428 | ||
429 | void | 429 | char * |
430 | GNUNET_STRINGS_utf8_normalize (const char *input, | 430 | GNUNET_STRINGS_utf8_normalize (const char *input) |
431 | char *output) | ||
432 | { | 431 | { |
433 | uint8_t *tmp; | 432 | uint8_t *tmp; |
434 | size_t len; | 433 | size_t len; |
435 | 434 | char *output; | |
436 | tmp = u8_normalize (UNINORM_NFC, | 435 | tmp = u8_normalize (UNINORM_NFC, |
437 | (uint8_t *) input, | 436 | (uint8_t *) input, |
438 | strlen ((char*) input), | 437 | strlen ((char*) input), |
439 | NULL, | 438 | NULL, |
440 | &len); | 439 | &len); |
440 | if (NULL == tmp) | ||
441 | return NULL; | ||
442 | output = GNUNET_malloc (len + 1); | ||
441 | GNUNET_memcpy (output, tmp, len); | 443 | GNUNET_memcpy (output, tmp, len); |
442 | output[len] = '\0'; | 444 | output[len] = '\0'; |
443 | free (tmp); | 445 | free (tmp); |
446 | return output; | ||
444 | } | 447 | } |
445 | 448 | ||
446 | void | 449 | enum GNUNET_GenericReturnValue |
447 | GNUNET_STRINGS_utf8_tolower (const char *input, | 450 | GNUNET_STRINGS_utf8_tolower (const char *input, |
448 | char *output) | 451 | char *output) |
449 | { | 452 | { |
@@ -456,13 +459,16 @@ GNUNET_STRINGS_utf8_tolower (const char *input, | |||
456 | UNINORM_NFD, | 459 | UNINORM_NFD, |
457 | NULL, | 460 | NULL, |
458 | &len); | 461 | &len); |
462 | if (NULL == tmp_in) | ||
463 | return GNUNET_SYSERR; | ||
459 | GNUNET_memcpy (output, tmp_in, len); | 464 | GNUNET_memcpy (output, tmp_in, len); |
460 | output[len] = '\0'; | 465 | output[len] = '\0'; |
461 | free (tmp_in); | 466 | GNUNET_free (tmp_in); |
467 | return GNUNET_OK; | ||
462 | } | 468 | } |
463 | 469 | ||
464 | 470 | ||
465 | void | 471 | enum GNUNET_GenericReturnValue |
466 | GNUNET_STRINGS_utf8_toupper (const char *input, | 472 | GNUNET_STRINGS_utf8_toupper (const char *input, |
467 | char *output) | 473 | char *output) |
468 | { | 474 | { |
@@ -475,9 +481,13 @@ GNUNET_STRINGS_utf8_toupper (const char *input, | |||
475 | UNINORM_NFD, | 481 | UNINORM_NFD, |
476 | NULL, | 482 | NULL, |
477 | &len); | 483 | &len); |
484 | if (NULL == tmp_in) | ||
485 | return GNUNET_SYSERR; | ||
486 | /* 0-terminator does not fit */ | ||
478 | GNUNET_memcpy (output, tmp_in, len); | 487 | GNUNET_memcpy (output, tmp_in, len); |
479 | output[len] = '\0'; | 488 | output[len] = '\0'; |
480 | free (tmp_in); | 489 | GNUNET_free (tmp_in); |
490 | return GNUNET_OK; | ||
481 | } | 491 | } |
482 | 492 | ||
483 | 493 | ||
@@ -1604,7 +1614,7 @@ GNUNET_STRINGS_base64_encode (const void *in, | |||
1604 | char *opt; | 1614 | char *opt; |
1605 | 1615 | ||
1606 | ret = 0; | 1616 | ret = 0; |
1607 | GNUNET_assert (len < SIZE_MAX / 4 * 3 ); | 1617 | GNUNET_assert (len < SIZE_MAX / 4 * 3); |
1608 | opt = GNUNET_malloc (2 + (len * 4 / 3) + 8); | 1618 | opt = GNUNET_malloc (2 + (len * 4 / 3) + 8); |
1609 | for (size_t i = 0; i < len; ++i) | 1619 | for (size_t i = 0; i < len; ++i) |
1610 | { | 1620 | { |
@@ -1741,7 +1751,7 @@ GNUNET_STRINGS_base64_decode (const char *data, | |||
1741 | output[ret++] = c; | 1751 | output[ret++] = c; |
1742 | } | 1752 | } |
1743 | } | 1753 | } |
1744 | END: | 1754 | END: |
1745 | *out = output; | 1755 | *out = output; |
1746 | return ret; | 1756 | return ret; |
1747 | } | 1757 | } |
@@ -1803,12 +1813,19 @@ GNUNET_STRINGS_urldecode (const char *data, | |||
1803 | char *wpos = *out; | 1813 | char *wpos = *out; |
1804 | size_t resl = 0; | 1814 | size_t resl = 0; |
1805 | 1815 | ||
1806 | while ('\0' != *rpos) | 1816 | while ( ('\0' != *rpos) && |
1817 | (data + len != rpos) ) | ||
1807 | { | 1818 | { |
1808 | unsigned int num; | 1819 | unsigned int num; |
1809 | switch (*rpos) | 1820 | switch (*rpos) |
1810 | { | 1821 | { |
1811 | case '%': | 1822 | case '%': |
1823 | if (rpos + 3 > data + len) | ||
1824 | { | ||
1825 | GNUNET_break_op (0); | ||
1826 | GNUNET_free (*out); | ||
1827 | return 0; | ||
1828 | } | ||
1812 | if (1 != sscanf (rpos + 1, "%2x", &num)) | 1829 | if (1 != sscanf (rpos + 1, "%2x", &num)) |
1813 | break; | 1830 | break; |
1814 | *wpos = (char) ((unsigned char) num); | 1831 | *wpos = (char) ((unsigned char) num); |
diff --git a/src/util/test_crypto_cs.c b/src/util/test_crypto_cs.c index d3406516e..914ded9bc 100644 --- a/src/util/test_crypto_cs.c +++ b/src/util/test_crypto_cs.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 GNUnet e.V. | 3 | Copyright (C) 2021,2022 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 |
@@ -30,148 +30,168 @@ | |||
30 | 30 | ||
31 | #define ITER 25 | 31 | #define ITER 25 |
32 | 32 | ||
33 | void | 33 | static void |
34 | test_create_priv (struct GNUNET_CRYPTO_CsPrivateKey *priv) | 34 | test_create_priv (struct GNUNET_CRYPTO_CsPrivateKey *priv) |
35 | { | 35 | { |
36 | /* TEST 1 | 36 | /* TEST 1 |
37 | * Check that privkey is set | 37 | * Check that privkey is set |
38 | */ | 38 | */ |
39 | struct GNUNET_CRYPTO_CsPrivateKey other_priv; | 39 | struct GNUNET_CRYPTO_CsPrivateKey other_priv; |
40 | memcpy (&other_priv.scalar, &priv->scalar, sizeof(other_priv.scalar)); | ||
41 | 40 | ||
41 | other_priv = *priv; | ||
42 | GNUNET_CRYPTO_cs_private_key_generate (priv); | 42 | GNUNET_CRYPTO_cs_private_key_generate (priv); |
43 | 43 | GNUNET_assert (0 != | |
44 | GNUNET_assert (0 != memcmp (&other_priv.scalar, | 44 | GNUNET_memcmp (&other_priv.scalar, |
45 | &priv->scalar, | 45 | &priv->scalar)); |
46 | sizeof(other_priv.scalar))); | ||
47 | } | 46 | } |
48 | 47 | ||
49 | 48 | ||
50 | void | 49 | static void |
51 | test_generate_pub (const struct GNUNET_CRYPTO_CsPrivateKey *priv, | 50 | test_generate_pub (const struct GNUNET_CRYPTO_CsPrivateKey *priv, |
52 | struct GNUNET_CRYPTO_CsPublicKey *pub) | 51 | struct GNUNET_CRYPTO_CsPublicKey *pub) |
53 | { | 52 | { |
54 | /* TEST 1 | 53 | /* TEST 1 |
55 | * Check that pubkey is set | 54 | * Check that pubkey is set |
56 | */ | 55 | */ |
57 | struct GNUNET_CRYPTO_CsPublicKey other_pub; | 56 | struct GNUNET_CRYPTO_CsPublicKey other_pub; |
58 | memcpy (&other_pub.point, &pub->point, sizeof(other_pub.point)); | ||
59 | |||
60 | GNUNET_CRYPTO_cs_private_key_get_public (priv, pub); | ||
61 | 57 | ||
62 | GNUNET_assert (0 != memcmp (&other_pub.point, | 58 | other_pub = *pub; |
63 | &pub->point, | 59 | GNUNET_CRYPTO_cs_private_key_get_public (priv, |
64 | sizeof(other_pub.point))); | 60 | pub); |
61 | GNUNET_assert (0 != | ||
62 | GNUNET_memcmp (&other_pub.point, | ||
63 | &pub->point)); | ||
65 | 64 | ||
66 | /* TEST 2 | 65 | /* TEST 2 |
67 | * Check that pubkey is a valid point | 66 | * Check that pubkey is a valid point |
68 | */ | 67 | */ |
69 | GNUNET_assert (1 == crypto_core_ed25519_is_valid_point (pub->point.y)); | 68 | GNUNET_assert (1 == |
69 | crypto_core_ed25519_is_valid_point (pub->point.y)); | ||
70 | 70 | ||
71 | /* TEST 3 | 71 | /* TEST 3 |
72 | * Check if function gives the same result for the same output | 72 | * Check if function gives the same result for the same output |
73 | */ | 73 | */ |
74 | memcpy (&other_pub.point, &pub->point, sizeof(other_pub.point)); | 74 | other_pub = *pub; |
75 | 75 | for (unsigned int i = 0; i<ITER; i++) | |
76 | for (int i = 0; i<ITER; i++) { | 76 | { |
77 | GNUNET_CRYPTO_cs_private_key_get_public (priv, pub); | 77 | GNUNET_CRYPTO_cs_private_key_get_public (priv, |
78 | GNUNET_assert (0 == memcmp (&other_pub.point, | 78 | pub); |
79 | &pub->point, | 79 | GNUNET_assert (0 == |
80 | sizeof(other_pub.point))); | 80 | GNUNET_memcmp (&other_pub.point, |
81 | &pub->point)); | ||
81 | } | 82 | } |
82 | } | 83 | } |
83 | 84 | ||
84 | 85 | ||
85 | void | 86 | static void |
86 | test_derive_rsecret (const struct GNUNET_CRYPTO_CsNonce *nonce, | 87 | test_derive_rsecret (const struct GNUNET_CRYPTO_CsNonce *nonce, |
87 | const struct GNUNET_CRYPTO_CsPrivateKey *priv, | 88 | const struct GNUNET_CRYPTO_CsPrivateKey *priv, |
88 | struct GNUNET_CRYPTO_CsRSecret r[2]) | 89 | struct GNUNET_CRYPTO_CsRSecret r[2]) |
89 | { | 90 | { |
90 | /* TEST 1 | 91 | /* TEST 1 |
91 | * Check that r are set | 92 | * Check that r are set |
92 | */ | 93 | */ |
93 | struct GNUNET_CRYPTO_CsPrivateKey other_r[2]; | 94 | struct GNUNET_CRYPTO_CsPrivateKey other_r[2]; |
94 | memcpy (&other_r[0], &r[0], sizeof(struct GNUNET_CRYPTO_CsPrivateKey) * 2); | ||
95 | 95 | ||
96 | GNUNET_CRYPTO_cs_r_derive (nonce, priv, r); | 96 | memcpy (other_r, |
97 | 97 | r, | |
98 | GNUNET_assert (0 != memcmp (&other_r[0], | 98 | sizeof(struct GNUNET_CRYPTO_CsPrivateKey) * 2); |
99 | &r[0], | 99 | GNUNET_CRYPTO_cs_r_derive (nonce, |
100 | sizeof(struct GNUNET_CRYPTO_CsPrivateKey) * 2)); | 100 | "nw", |
101 | priv, | ||
102 | r); | ||
103 | GNUNET_assert (0 != | ||
104 | memcmp (&other_r[0], | ||
105 | &r[0], | ||
106 | sizeof(struct GNUNET_CRYPTO_CsPrivateKey) * 2)); | ||
101 | 107 | ||
102 | /* TEST 2 | 108 | /* TEST 2 |
103 | * Check if function gives the same result for the same input. | 109 | * Check if function gives the same result for the same input. |
104 | * This test ensures that the derivation is deterministic. | 110 | * This test ensures that the derivation is deterministic. |
105 | */ | 111 | */ |
106 | memcpy (&other_r[0], &r[0], sizeof(struct GNUNET_CRYPTO_CsPrivateKey) * 2); | 112 | memcpy (other_r, |
107 | for (int i = 0; i<ITER; i++) { | 113 | r, |
108 | GNUNET_CRYPTO_cs_r_derive (nonce, priv, r); | 114 | sizeof(struct GNUNET_CRYPTO_CsPrivateKey) * 2); |
109 | GNUNET_assert (0 == memcmp (&other_r[0], | 115 | for (unsigned int i = 0; i<ITER; i++) |
110 | &r[0], | 116 | { |
111 | sizeof(struct GNUNET_CRYPTO_CsPrivateKey) * 2)); | 117 | GNUNET_CRYPTO_cs_r_derive (nonce, |
118 | "nw", | ||
119 | priv, | ||
120 | r); | ||
121 | GNUNET_assert (0 == | ||
122 | memcmp (other_r, | ||
123 | r, | ||
124 | sizeof(struct GNUNET_CRYPTO_CsPrivateKey) * 2)); | ||
112 | } | 125 | } |
113 | } | 126 | } |
114 | 127 | ||
115 | 128 | ||
116 | void | 129 | static void |
117 | test_generate_rpublic (const struct GNUNET_CRYPTO_CsRSecret *r_priv, | 130 | test_generate_rpublic (const struct GNUNET_CRYPTO_CsRSecret *r_priv, |
118 | struct GNUNET_CRYPTO_CsRPublic *r_pub) | 131 | struct GNUNET_CRYPTO_CsRPublic *r_pub) |
119 | { | 132 | { |
120 | /* TEST 1 | 133 | /* TEST 1 |
121 | * Check that r_pub is set | 134 | * Check that r_pub is set |
122 | */ | 135 | */ |
123 | struct GNUNET_CRYPTO_CsRPublic other_r_pub; | 136 | struct GNUNET_CRYPTO_CsRPublic other_r_pub; |
124 | memcpy (&other_r_pub.point, &r_pub->point, sizeof(other_r_pub.point)); | ||
125 | |||
126 | GNUNET_CRYPTO_cs_r_get_public (r_priv, r_pub); | ||
127 | |||
128 | GNUNET_assert (0 != memcmp (&other_r_pub.point, | ||
129 | &r_pub->point, | ||
130 | sizeof(other_r_pub.point))); | ||
131 | 137 | ||
138 | other_r_pub = *r_pub; | ||
139 | GNUNET_CRYPTO_cs_r_get_public (r_priv, | ||
140 | r_pub); | ||
141 | GNUNET_assert (0 != | ||
142 | GNUNET_memcmp (&other_r_pub.point, | ||
143 | &r_pub->point)); | ||
132 | /* TEST 2 | 144 | /* TEST 2 |
133 | * Check that r_pub is a valid point | 145 | * Check that r_pub is a valid point |
134 | */ | 146 | */ |
135 | GNUNET_assert (1 == crypto_core_ed25519_is_valid_point (r_pub->point.y)); | 147 | GNUNET_assert (1 == |
148 | crypto_core_ed25519_is_valid_point (r_pub->point.y)); | ||
136 | 149 | ||
137 | /* TEST 3 | 150 | /* TEST 3 |
138 | * Check if function gives the same result for the same output | 151 | * Check if function gives the same result for the same output |
139 | */ | 152 | */ |
140 | memcpy (&other_r_pub.point, &r_pub->point, sizeof(other_r_pub.point)); | 153 | other_r_pub.point = r_pub->point; |
141 | for (int i = 0; i<ITER; i++) { | 154 | for (int i = 0; i<ITER; i++) |
142 | GNUNET_CRYPTO_cs_r_get_public (r_priv, r_pub); | 155 | { |
143 | GNUNET_assert (0 == memcmp (&other_r_pub.point, | 156 | GNUNET_CRYPTO_cs_r_get_public (r_priv, |
144 | &r_pub->point, | 157 | r_pub); |
145 | sizeof(other_r_pub.point))); | 158 | GNUNET_assert (0 == |
159 | GNUNET_memcmp (&other_r_pub.point, | ||
160 | &r_pub->point)); | ||
146 | } | 161 | } |
147 | } | 162 | } |
148 | 163 | ||
149 | 164 | ||
150 | void | 165 | static void |
151 | test_derive_blindingsecrets (const struct GNUNET_CRYPTO_CsNonce *blind_seed, | 166 | test_derive_blindingsecrets (const struct GNUNET_CRYPTO_CsNonce *blind_seed, |
152 | struct GNUNET_CRYPTO_CsBlindingSecret bs[2]) | 167 | struct GNUNET_CRYPTO_CsBlindingSecret bs[2]) |
153 | { | 168 | { |
154 | /* TEST 1 | 169 | /* TEST 1 |
155 | * Check that blinding secrets are set | 170 | * Check that blinding secrets are set |
156 | */ | 171 | */ |
157 | struct GNUNET_CRYPTO_CsBlindingSecret other_bs[2]; | 172 | struct GNUNET_CRYPTO_CsBlindingSecret other_bs[2]; |
158 | memcpy (&other_bs[0], &bs[0], sizeof(struct GNUNET_CRYPTO_CsBlindingSecret) | 173 | |
159 | * 2); | 174 | memcpy (other_bs, |
175 | bs, | ||
176 | sizeof(struct GNUNET_CRYPTO_CsBlindingSecret) * 2); | ||
160 | 177 | ||
161 | GNUNET_CRYPTO_cs_blinding_secrets_derive (blind_seed, bs); | 178 | GNUNET_CRYPTO_cs_blinding_secrets_derive (blind_seed, bs); |
162 | 179 | ||
163 | GNUNET_assert (0 != memcmp (&other_bs[0], | 180 | GNUNET_assert (0 != |
164 | &bs[0], | 181 | memcmp (other_bs, |
165 | sizeof(struct GNUNET_CRYPTO_CsBlindingSecret) | 182 | bs, |
166 | * 2)); | 183 | sizeof(struct GNUNET_CRYPTO_CsBlindingSecret) |
184 | * 2)); | ||
167 | 185 | ||
168 | /* TEST 2 | 186 | /* TEST 2 |
169 | * Check if function gives the same result for the same input. | 187 | * Check if function gives the same result for the same input. |
170 | * This test ensures that the derivation is deterministic. | 188 | * This test ensures that the derivation is deterministic. |
171 | */ | 189 | */ |
172 | memcpy (&other_bs[0], &bs[0], sizeof(struct GNUNET_CRYPTO_CsBlindingSecret) | 190 | memcpy (other_bs, |
173 | * 2); | 191 | bs, |
174 | for (int i = 0; i<ITER; i++) { | 192 | sizeof(struct GNUNET_CRYPTO_CsBlindingSecret) * 2); |
193 | for (unsigned int i = 0; i<ITER; i++) | ||
194 | { | ||
175 | GNUNET_CRYPTO_cs_blinding_secrets_derive (blind_seed, bs); | 195 | GNUNET_CRYPTO_cs_blinding_secrets_derive (blind_seed, bs); |
176 | GNUNET_assert (0 == memcmp (&other_bs[0], | 196 | GNUNET_assert (0 == memcmp (&other_bs[0], |
177 | &bs[0], | 197 | &bs[0], |
@@ -181,19 +201,20 @@ test_derive_blindingsecrets (const struct GNUNET_CRYPTO_CsNonce *blind_seed, | |||
181 | } | 201 | } |
182 | 202 | ||
183 | 203 | ||
184 | void | 204 | static void |
185 | test_calc_blindedc (const struct GNUNET_CRYPTO_CsBlindingSecret bs[2], | 205 | test_calc_blindedc (const struct GNUNET_CRYPTO_CsBlindingSecret bs[2], |
186 | const struct GNUNET_CRYPTO_CsRPublic r_pub[2], | 206 | const struct GNUNET_CRYPTO_CsRPublic r_pub[2], |
187 | const struct GNUNET_CRYPTO_CsPublicKey *pub, | 207 | const struct GNUNET_CRYPTO_CsPublicKey *pub, |
188 | const void *msg, | 208 | const void *msg, |
189 | size_t msg_len, | 209 | size_t msg_len, |
190 | struct GNUNET_CRYPTO_CsC blinded_cs[2], | 210 | struct GNUNET_CRYPTO_CsC blinded_cs[2], |
191 | struct GNUNET_CRYPTO_CsRPublic blinded_r_pub[2]) | 211 | struct GNUNET_CRYPTO_CsRPublic blinded_r_pub[2]) |
192 | { | 212 | { |
193 | /* TEST 1 | 213 | /* TEST 1 |
194 | * Check that the blinded c's and blinded r's | 214 | * Check that the blinded c's and blinded r's |
195 | */ | 215 | */ |
196 | struct GNUNET_CRYPTO_CsC other_blinded_c[2]; | 216 | struct GNUNET_CRYPTO_CsC other_blinded_c[2]; |
217 | |||
197 | memcpy (&other_blinded_c[0], | 218 | memcpy (&other_blinded_c[0], |
198 | &blinded_cs[0], | 219 | &blinded_cs[0], |
199 | sizeof(struct GNUNET_CRYPTO_CsC) * 2); | 220 | sizeof(struct GNUNET_CRYPTO_CsC) * 2); |
@@ -222,7 +243,8 @@ test_calc_blindedc (const struct GNUNET_CRYPTO_CsBlindingSecret bs[2], | |||
222 | * Check if R' - aG -bX = R for b = 0 | 243 | * Check if R' - aG -bX = R for b = 0 |
223 | * This test does the opposite operations and checks wether the equation is still correct. | 244 | * This test does the opposite operations and checks wether the equation is still correct. |
224 | */ | 245 | */ |
225 | for (unsigned int b = 0; b <= 1; b++) { | 246 | for (unsigned int b = 0; b <= 1; b++) |
247 | { | ||
226 | struct GNUNET_CRYPTO_Cs25519Point aG; | 248 | struct GNUNET_CRYPTO_Cs25519Point aG; |
227 | struct GNUNET_CRYPTO_Cs25519Point bX; | 249 | struct GNUNET_CRYPTO_Cs25519Point bX; |
228 | struct GNUNET_CRYPTO_Cs25519Point r_min_aG; | 250 | struct GNUNET_CRYPTO_Cs25519Point r_min_aG; |
@@ -252,7 +274,6 @@ test_calc_blindedc (const struct GNUNET_CRYPTO_CsBlindingSecret bs[2], | |||
252 | } | 274 | } |
253 | 275 | ||
254 | 276 | ||
255 | |||
256 | /* TEST 3 | 277 | /* TEST 3 |
257 | * Check that the blinded r_pubs' are valid points | 278 | * Check that the blinded r_pubs' are valid points |
258 | */ | 279 | */ |
@@ -271,7 +292,8 @@ test_calc_blindedc (const struct GNUNET_CRYPTO_CsBlindingSecret bs[2], | |||
271 | &blinded_r_pub[0], | 292 | &blinded_r_pub[0], |
272 | sizeof(struct GNUNET_CRYPTO_CsRPublic) * 2); | 293 | sizeof(struct GNUNET_CRYPTO_CsRPublic) * 2); |
273 | 294 | ||
274 | for (int i = 0; i<ITER; i++) { | 295 | for (unsigned int i = 0; i<ITER; i++) |
296 | { | ||
275 | GNUNET_CRYPTO_cs_calc_blinded_c (bs, | 297 | GNUNET_CRYPTO_cs_calc_blinded_c (bs, |
276 | r_pub, | 298 | r_pub, |
277 | pub, | 299 | pub, |
@@ -289,13 +311,13 @@ test_calc_blindedc (const struct GNUNET_CRYPTO_CsBlindingSecret bs[2], | |||
289 | } | 311 | } |
290 | 312 | ||
291 | 313 | ||
292 | void | 314 | static void |
293 | test_blind_sign (unsigned int *b, | 315 | test_blind_sign (unsigned int *b, |
294 | const struct GNUNET_CRYPTO_CsPrivateKey *priv, | 316 | const struct GNUNET_CRYPTO_CsPrivateKey *priv, |
295 | const struct GNUNET_CRYPTO_CsRSecret r[2], | 317 | const struct GNUNET_CRYPTO_CsRSecret r[2], |
296 | const struct GNUNET_CRYPTO_CsC c[2], | 318 | const struct GNUNET_CRYPTO_CsC c[2], |
297 | const struct GNUNET_CRYPTO_CsNonce *nonce, | 319 | const struct GNUNET_CRYPTO_CsNonce *nonce, |
298 | struct GNUNET_CRYPTO_CsBlindS *blinded_s) | 320 | struct GNUNET_CRYPTO_CsBlindS *blinded_s) |
299 | { | 321 | { |
300 | /* TEST 1 | 322 | /* TEST 1 |
301 | * Check that blinded_s is set | 323 | * Check that blinded_s is set |
@@ -336,8 +358,10 @@ test_blind_sign (unsigned int *b, | |||
336 | * Check if function gives the same result for the same input. | 358 | * Check if function gives the same result for the same input. |
337 | */ | 359 | */ |
338 | memcpy (&other_blinded_s, blinded_s, sizeof(struct GNUNET_CRYPTO_CsBlindS)); | 360 | memcpy (&other_blinded_s, blinded_s, sizeof(struct GNUNET_CRYPTO_CsBlindS)); |
339 | unsigned int other_b; | 361 | for (unsigned int i = 0; i<ITER; i++) |
340 | for (int i = 0; i<ITER; i++) { | 362 | { |
363 | unsigned int other_b; | ||
364 | |||
341 | other_b = GNUNET_CRYPTO_cs_sign_derive (priv, r, c, nonce, blinded_s); | 365 | other_b = GNUNET_CRYPTO_cs_sign_derive (priv, r, c, nonce, blinded_s); |
342 | 366 | ||
343 | GNUNET_assert (other_b == *b); | 367 | GNUNET_assert (other_b == *b); |
@@ -348,10 +372,10 @@ test_blind_sign (unsigned int *b, | |||
348 | } | 372 | } |
349 | 373 | ||
350 | 374 | ||
351 | void | 375 | static void |
352 | test_unblinds (const struct GNUNET_CRYPTO_CsBlindS *blinded_signature_scalar, | 376 | test_unblinds (const struct GNUNET_CRYPTO_CsBlindS *blinded_signature_scalar, |
353 | const struct GNUNET_CRYPTO_CsBlindingSecret *bs, | 377 | const struct GNUNET_CRYPTO_CsBlindingSecret *bs, |
354 | struct GNUNET_CRYPTO_CsS *signature_scalar) | 378 | struct GNUNET_CRYPTO_CsS *signature_scalar) |
355 | { | 379 | { |
356 | /* TEST 1 | 380 | /* TEST 1 |
357 | * Check that signature_scalar is set | 381 | * Check that signature_scalar is set |
@@ -387,7 +411,8 @@ test_unblinds (const struct GNUNET_CRYPTO_CsBlindS *blinded_signature_scalar, | |||
387 | memcpy (&other_signature_scalar, signature_scalar, | 411 | memcpy (&other_signature_scalar, signature_scalar, |
388 | sizeof(struct GNUNET_CRYPTO_CsS)); | 412 | sizeof(struct GNUNET_CRYPTO_CsS)); |
389 | 413 | ||
390 | for (int i = 0; i<ITER; i++) { | 414 | for (unsigned int i = 0; i<ITER; i++) |
415 | { | ||
391 | GNUNET_CRYPTO_cs_unblind (blinded_signature_scalar, bs, signature_scalar); | 416 | GNUNET_CRYPTO_cs_unblind (blinded_signature_scalar, bs, signature_scalar); |
392 | GNUNET_assert (0 == memcmp (&other_signature_scalar, | 417 | GNUNET_assert (0 == memcmp (&other_signature_scalar, |
393 | signature_scalar, | 418 | signature_scalar, |
@@ -396,10 +421,10 @@ test_unblinds (const struct GNUNET_CRYPTO_CsBlindS *blinded_signature_scalar, | |||
396 | } | 421 | } |
397 | 422 | ||
398 | 423 | ||
399 | void | 424 | static void |
400 | test_blind_verify (const struct GNUNET_CRYPTO_CsSignature *sig, | 425 | test_blind_verify (const struct GNUNET_CRYPTO_CsSignature *sig, |
401 | const struct GNUNET_CRYPTO_CsPublicKey *pub, | 426 | const struct GNUNET_CRYPTO_CsPublicKey *pub, |
402 | const struct GNUNET_CRYPTO_CsC *c) | 427 | const struct GNUNET_CRYPTO_CsC *c) |
403 | { | 428 | { |
404 | /* TEST 1 | 429 | /* TEST 1 |
405 | * Test verifies the blinded signature sG == Rb + cbX | 430 | * Test verifies the blinded signature sG == Rb + cbX |
@@ -425,28 +450,30 @@ test_blind_verify (const struct GNUNET_CRYPTO_CsSignature *sig, | |||
425 | } | 450 | } |
426 | 451 | ||
427 | 452 | ||
428 | void | 453 | static void |
429 | test_verify (const struct GNUNET_CRYPTO_CsSignature *sig, | 454 | test_verify (const struct GNUNET_CRYPTO_CsSignature *sig, |
430 | const struct GNUNET_CRYPTO_CsPublicKey *pub, | 455 | const struct GNUNET_CRYPTO_CsPublicKey *pub, |
431 | const void *msg, | 456 | const void *msg, |
432 | size_t msg_len) | 457 | size_t msg_len) |
433 | { | 458 | { |
434 | /* TEST 1 | 459 | /* TEST 1 |
435 | * Test simple verification | 460 | * Test simple verification |
436 | */ | 461 | */ |
437 | GNUNET_assert (GNUNET_YES == GNUNET_CRYPTO_cs_verify (sig, | 462 | GNUNET_assert (GNUNET_YES == |
438 | pub, | 463 | GNUNET_CRYPTO_cs_verify (sig, |
439 | msg, | 464 | pub, |
440 | msg_len)); | 465 | msg, |
466 | msg_len)); | ||
441 | /* TEST 2 | 467 | /* TEST 2 |
442 | * Test verification of "wrong" message | 468 | * Test verification of "wrong" message |
443 | */ | 469 | */ |
444 | char other_msg[] = "test massege"; | 470 | char other_msg[] = "test massege"; |
445 | size_t other_msg_len = strlen ("test massege"); | 471 | size_t other_msg_len = strlen ("test massege"); |
446 | GNUNET_assert (GNUNET_SYSERR == GNUNET_CRYPTO_cs_verify (sig, | 472 | GNUNET_assert (GNUNET_SYSERR == |
447 | pub, | 473 | GNUNET_CRYPTO_cs_verify (sig, |
448 | other_msg, | 474 | pub, |
449 | other_msg_len)); | 475 | other_msg, |
476 | other_msg_len)); | ||
450 | } | 477 | } |
451 | 478 | ||
452 | 479 | ||
@@ -461,71 +488,122 @@ main (int argc, | |||
461 | size_t message_len = strlen ("test message"); | 488 | size_t message_len = strlen ("test message"); |
462 | 489 | ||
463 | struct GNUNET_CRYPTO_CsPrivateKey priv; | 490 | struct GNUNET_CRYPTO_CsPrivateKey priv; |
491 | |||
492 | memset (&priv, | ||
493 | 42, | ||
494 | sizeof (priv)); | ||
464 | test_create_priv (&priv); | 495 | test_create_priv (&priv); |
465 | 496 | ||
466 | struct GNUNET_CRYPTO_CsPublicKey pub; | 497 | struct GNUNET_CRYPTO_CsPublicKey pub; |
467 | test_generate_pub (&priv, &pub); | 498 | |
499 | memset (&pub, | ||
500 | 42, | ||
501 | sizeof (pub)); | ||
502 | test_generate_pub (&priv, | ||
503 | &pub); | ||
468 | 504 | ||
469 | // derive nonce | 505 | // derive nonce |
470 | struct GNUNET_CRYPTO_CsNonce nonce; | 506 | struct GNUNET_CRYPTO_CsNonce nonce; |
471 | GNUNET_assert (GNUNET_YES == GNUNET_CRYPTO_hkdf (nonce.nonce, | 507 | GNUNET_assert (GNUNET_YES == |
472 | sizeof(nonce.nonce), | 508 | GNUNET_CRYPTO_kdf (nonce.nonce, |
473 | GCRY_MD_SHA512, | 509 | sizeof(nonce.nonce), |
474 | GCRY_MD_SHA256, | 510 | "nonce", |
475 | "nonce", | 511 | strlen ("nonce"), |
476 | strlen ("nonce"), | 512 | "nonce_secret", |
477 | "nonce_secret", | 513 | strlen ("nonce_secret"), |
478 | strlen ("nonce_secret"), | 514 | NULL, |
479 | NULL, | 515 | 0)); |
480 | 0)); | ||
481 | 516 | ||
482 | // generate r, R | 517 | // generate r, R |
483 | struct GNUNET_CRYPTO_CsRSecret r_secrets[2]; | 518 | struct GNUNET_CRYPTO_CsRSecret r_secrets[2]; |
484 | test_derive_rsecret (&nonce, &priv, r_secrets); | 519 | |
520 | memset (r_secrets, | ||
521 | 42, | ||
522 | sizeof (r_secrets)); | ||
523 | test_derive_rsecret (&nonce, | ||
524 | &priv, | ||
525 | r_secrets); | ||
485 | 526 | ||
486 | struct GNUNET_CRYPTO_CsRPublic r_publics[2]; | 527 | struct GNUNET_CRYPTO_CsRPublic r_publics[2]; |
487 | test_generate_rpublic (&r_secrets[0], &r_publics[0]); | 528 | |
488 | test_generate_rpublic (&r_secrets[1], &r_publics[1]); | 529 | memset (r_publics, |
530 | 42, | ||
531 | sizeof (r_publics)); | ||
532 | test_generate_rpublic (&r_secrets[0], | ||
533 | &r_publics[0]); | ||
534 | test_generate_rpublic (&r_secrets[1], | ||
535 | &r_publics[1]); | ||
489 | 536 | ||
490 | // ---------- actions performed by user | 537 | // ---------- actions performed by user |
491 | 538 | ||
492 | // generate blinding secrets | 539 | // generate blinding secrets |
493 | struct GNUNET_CRYPTO_CsBlindingSecret blindingsecrets[2]; | 540 | struct GNUNET_CRYPTO_CsBlindingSecret blindingsecrets[2]; |
541 | |||
542 | memset (blindingsecrets, | ||
543 | 42, | ||
544 | sizeof (blindingsecrets)); | ||
494 | test_derive_blindingsecrets (&nonce, | 545 | test_derive_blindingsecrets (&nonce, |
495 | blindingsecrets); | 546 | blindingsecrets); |
496 | 547 | ||
497 | // calculate blinded c's | 548 | // calculate blinded c's |
498 | struct GNUNET_CRYPTO_CsC blinded_cs[2]; | 549 | struct GNUNET_CRYPTO_CsC blinded_cs[2]; |
499 | struct GNUNET_CRYPTO_CsRPublic blinded_r_pubs[2]; | 550 | struct GNUNET_CRYPTO_CsRPublic blinded_r_pubs[2]; |
551 | |||
552 | memset (blinded_cs, | ||
553 | 42, | ||
554 | sizeof (blinded_cs)); | ||
555 | memset (blinded_r_pubs, | ||
556 | 42, | ||
557 | sizeof (blinded_r_pubs)); | ||
500 | test_calc_blindedc (blindingsecrets, | 558 | test_calc_blindedc (blindingsecrets, |
501 | r_publics, | 559 | r_publics, |
502 | &pub, | 560 | &pub, |
503 | message, | 561 | message, |
504 | message_len, | 562 | message_len, |
505 | blinded_cs, | 563 | blinded_cs, |
506 | blinded_r_pubs); | 564 | blinded_r_pubs); |
507 | 565 | ||
508 | // ---------- actions performed by signer | 566 | // ---------- actions performed by signer |
509 | // sign blinded c's and get b and s in return | 567 | // sign blinded c's and get b and s in return |
510 | unsigned int b; | 568 | unsigned int b; |
511 | struct GNUNET_CRYPTO_CsBlindS blinded_s; | 569 | struct GNUNET_CRYPTO_CsBlindS blinded_s; |
512 | test_blind_sign (&b, &priv, r_secrets, blinded_cs, &nonce, &blinded_s); | 570 | |
571 | memset (&blinded_s, | ||
572 | 42, | ||
573 | sizeof (blinded_s)); | ||
574 | test_blind_sign (&b, | ||
575 | &priv, | ||
576 | r_secrets, | ||
577 | blinded_cs, | ||
578 | &nonce, | ||
579 | &blinded_s); | ||
513 | 580 | ||
514 | // verify blinded signature | 581 | // verify blinded signature |
515 | struct GNUNET_CRYPTO_CsSignature blinded_signature; | 582 | struct GNUNET_CRYPTO_CsSignature blinded_signature; |
583 | |||
516 | blinded_signature.r_point = r_publics[b]; | 584 | blinded_signature.r_point = r_publics[b]; |
517 | blinded_signature.s_scalar.scalar = blinded_s.scalar; | 585 | blinded_signature.s_scalar.scalar = blinded_s.scalar; |
518 | test_blind_verify (&blinded_signature, &pub, &blinded_cs[b]); | 586 | test_blind_verify (&blinded_signature, |
587 | &pub, | ||
588 | &blinded_cs[b]); | ||
519 | 589 | ||
520 | // ---------- actions performed by user | 590 | // ---------- actions performed by user |
521 | struct GNUNET_CRYPTO_CsS sig_scalar; | 591 | struct GNUNET_CRYPTO_CsS sig_scalar; |
522 | test_unblinds (&blinded_s, &blindingsecrets[b], &sig_scalar); | 592 | |
593 | memset (&sig_scalar, | ||
594 | 42, | ||
595 | sizeof (sig_scalar)); | ||
596 | test_unblinds (&blinded_s, | ||
597 | &blindingsecrets[b], | ||
598 | &sig_scalar); | ||
523 | 599 | ||
524 | // verify unblinded signature | 600 | // verify unblinded signature |
525 | struct GNUNET_CRYPTO_CsSignature signature; | 601 | struct GNUNET_CRYPTO_CsSignature signature; |
526 | signature.r_point = blinded_r_pubs[b]; | 602 | signature.r_point = blinded_r_pubs[b]; |
527 | signature.s_scalar = sig_scalar; | 603 | signature.s_scalar = sig_scalar; |
528 | test_verify (&signature, &pub, message, message_len); | 604 | test_verify (&signature, |
529 | 605 | &pub, | |
606 | message, | ||
607 | message_len); | ||
530 | return 0; | 608 | return 0; |
531 | } | 609 | } |
diff --git a/src/util/test_strings.c b/src/util/test_strings.c index 1ecd31464..cccffcaf5 100644 --- a/src/util/test_strings.c +++ b/src/util/test_strings.c | |||
@@ -114,10 +114,9 @@ main (int argc, char *argv[]) | |||
114 | /* Normalization */ | 114 | /* Normalization */ |
115 | r = "q\u0307\u0323"; /* Non-canonical order */ | 115 | r = "q\u0307\u0323"; /* Non-canonical order */ |
116 | 116 | ||
117 | GNUNET_STRINGS_utf8_normalize (r, | 117 | b = GNUNET_STRINGS_utf8_normalize (r); |
118 | buf); | 118 | GNUNET_assert (0 == strcmp ("q\u0323\u0307", b)); |
119 | GNUNET_assert (0 == strcmp ("q\u0323\u0307", buf)); | 119 | GNUNET_free (b); |
120 | |||
121 | b = GNUNET_STRINGS_to_utf8 ("TEST", 4, "ASCII"); | 120 | b = GNUNET_STRINGS_to_utf8 ("TEST", 4, "ASCII"); |
122 | WANT ("TEST", b); | 121 | WANT ("TEST", b); |
123 | 122 | ||
diff --git a/src/util/time.c b/src/util/time.c index 83b39b4e8..68a6937a0 100644 --- a/src/util/time.c +++ b/src/util/time.c | |||
@@ -695,6 +695,13 @@ GNUNET_TIME_timestamp_from_s (uint64_t s_after_epoch) | |||
695 | } | 695 | } |
696 | 696 | ||
697 | 697 | ||
698 | uint64_t | ||
699 | GNUNET_TIME_timestamp_to_s (struct GNUNET_TIME_Timestamp ts) | ||
700 | { | ||
701 | return ts.abs_time.abs_value_us / GNUNET_TIME_UNIT_SECONDS.rel_value_us; | ||
702 | } | ||
703 | |||
704 | |||
698 | struct GNUNET_TIME_Absolute | 705 | struct GNUNET_TIME_Absolute |
699 | GNUNET_TIME_absolute_ntoh (struct GNUNET_TIME_AbsoluteNBO a) | 706 | GNUNET_TIME_absolute_ntoh (struct GNUNET_TIME_AbsoluteNBO a) |
700 | { | 707 | { |
diff --git a/src/zonemaster/gnunet-service-zonemaster-monitor.c b/src/zonemaster/gnunet-service-zonemaster-monitor.c index 3392a19d7..748a0f342 100644 --- a/src/zonemaster/gnunet-service-zonemaster-monitor.c +++ b/src/zonemaster/gnunet-service-zonemaster-monitor.c | |||
@@ -29,7 +29,6 @@ | |||
29 | #include "gnunet_namestore_service.h" | 29 | #include "gnunet_namestore_service.h" |
30 | #include "gnunet_statistics_service.h" | 30 | #include "gnunet_statistics_service.h" |
31 | 31 | ||
32 | |||
33 | #define LOG_STRERROR_FILE(kind, syscall, \ | 32 | #define LOG_STRERROR_FILE(kind, syscall, \ |
34 | filename) GNUNET_log_from_strerror_file (kind, "util", \ | 33 | filename) GNUNET_log_from_strerror_file (kind, "util", \ |
35 | syscall, \ | 34 | syscall, \ |
@@ -58,7 +57,6 @@ | |||
58 | */ | 57 | */ |
59 | #define DHT_GNS_REPLICATION_LEVEL 5 | 58 | #define DHT_GNS_REPLICATION_LEVEL 5 |
60 | 59 | ||
61 | |||
62 | /** | 60 | /** |
63 | * Handle for DHT PUT activity triggered from the namestore monitor. | 61 | * Handle for DHT PUT activity triggered from the namestore monitor. |
64 | */ | 62 | */ |
@@ -197,39 +195,6 @@ dht_put_monitor_continuation (void *cls) | |||
197 | 195 | ||
198 | 196 | ||
199 | /** | 197 | /** |
200 | * Convert namestore records from the internal format to that | ||
201 | * suitable for publication (removes private records, converts | ||
202 | * to absolute expiration time). | ||
203 | * | ||
204 | * @param rd input records | ||
205 | * @param rd_count size of the @a rd and @a rd_public arrays | ||
206 | * @param rd_public where to write the converted records | ||
207 | * @return number of records written to @a rd_public | ||
208 | */ | ||
209 | static unsigned int | ||
210 | convert_records_for_export (const struct GNUNET_GNSRECORD_Data *rd, | ||
211 | unsigned int rd_count, | ||
212 | struct GNUNET_GNSRECORD_Data *rd_public) | ||
213 | { | ||
214 | struct GNUNET_TIME_Absolute now; | ||
215 | unsigned int rd_public_count; | ||
216 | |||
217 | rd_public_count = 0; | ||
218 | now = GNUNET_TIME_absolute_get (); | ||
219 | for (unsigned int i = 0; i < rd_count; i++) | ||
220 | { | ||
221 | if (0 != (rd[i].flags & GNUNET_GNSRECORD_RF_PRIVATE)) | ||
222 | continue; | ||
223 | if ((0 == (rd[i].flags & GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION)) && | ||
224 | (rd[i].expiration_time < now.abs_value_us)) | ||
225 | continue; /* record already expired, skip it */ | ||
226 | rd_public[rd_public_count++] = rd[i]; | ||
227 | } | ||
228 | return rd_public_count; | ||
229 | } | ||
230 | |||
231 | |||
232 | /** | ||
233 | * Store GNS records in the DHT. | 198 | * Store GNS records in the DHT. |
234 | * | 199 | * |
235 | * @param key key of the zone | 200 | * @param key key of the zone |
@@ -244,16 +209,14 @@ perform_dht_put (const struct GNUNET_IDENTITY_PrivateKey *key, | |||
244 | const char *label, | 209 | const char *label, |
245 | const struct GNUNET_GNSRECORD_Data *rd_public, | 210 | const struct GNUNET_GNSRECORD_Data *rd_public, |
246 | unsigned int rd_public_count, | 211 | unsigned int rd_public_count, |
212 | struct GNUNET_TIME_Absolute expire, | ||
247 | struct DhtPutActivity *ma) | 213 | struct DhtPutActivity *ma) |
248 | { | 214 | { |
249 | struct GNUNET_GNSRECORD_Block *block; | 215 | struct GNUNET_GNSRECORD_Block *block; |
250 | struct GNUNET_HashCode query; | 216 | struct GNUNET_HashCode query; |
251 | struct GNUNET_TIME_Absolute expire; | ||
252 | size_t block_size; | 217 | size_t block_size; |
253 | struct GNUNET_DHT_PutHandle *ret; | 218 | struct GNUNET_DHT_PutHandle *ret; |
254 | 219 | ||
255 | expire = GNUNET_GNSRECORD_record_get_expiration_time (rd_public_count, | ||
256 | rd_public); | ||
257 | if (cache_keys) | 220 | if (cache_keys) |
258 | GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_block_create2 (key, | 221 | GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_block_create2 (key, |
259 | expire, | 222 | expire, |
@@ -301,7 +264,6 @@ perform_dht_put (const struct GNUNET_IDENTITY_PrivateKey *key, | |||
301 | return ret; | 264 | return ret; |
302 | } | 265 | } |
303 | 266 | ||
304 | |||
305 | /** | 267 | /** |
306 | * Process a record that was stored in the namestore | 268 | * Process a record that was stored in the namestore |
307 | * (invoked by the monitor). | 269 | * (invoked by the monitor). |
@@ -322,6 +284,8 @@ handle_monitor_event (void *cls, | |||
322 | struct GNUNET_GNSRECORD_Data rd_public[rd_count]; | 284 | struct GNUNET_GNSRECORD_Data rd_public[rd_count]; |
323 | unsigned int rd_public_count; | 285 | unsigned int rd_public_count; |
324 | struct DhtPutActivity *ma; | 286 | struct DhtPutActivity *ma; |
287 | struct GNUNET_TIME_Absolute expire; | ||
288 | char *emsg; | ||
325 | 289 | ||
326 | (void) cls; | 290 | (void) cls; |
327 | GNUNET_STATISTICS_update (statistics, | 291 | GNUNET_STATISTICS_update (statistics, |
@@ -334,9 +298,21 @@ handle_monitor_event (void *cls, | |||
334 | label); | 298 | label); |
335 | /* filter out records that are not public, and convert to | 299 | /* filter out records that are not public, and convert to |
336 | absolute expiration time. */ | 300 | absolute expiration time. */ |
337 | rd_public_count = convert_records_for_export (rd, | 301 | if (GNUNET_OK != GNUNET_GNSRECORD_convert_records_for_export (label, |
338 | rd_count, | 302 | rd, |
339 | rd_public); | 303 | rd_count, |
304 | rd_public, | ||
305 | &rd_public_count, | ||
306 | &expire, | ||
307 | &emsg)) | ||
308 | { | ||
309 | GNUNET_log (GNUNET_ERROR_TYPE_ERROR, | ||
310 | "Zonemaster-monitor failed: %s\n", emsg); | ||
311 | GNUNET_free (emsg); | ||
312 | GNUNET_NAMESTORE_zone_monitor_next (zmon, | ||
313 | 1); | ||
314 | return; /* nothing to do */ | ||
315 | } | ||
340 | if (0 == rd_public_count) | 316 | if (0 == rd_public_count) |
341 | { | 317 | { |
342 | GNUNET_NAMESTORE_zone_monitor_next (zmon, | 318 | GNUNET_NAMESTORE_zone_monitor_next (zmon, |
@@ -347,8 +323,9 @@ handle_monitor_event (void *cls, | |||
347 | ma->start_date = GNUNET_TIME_absolute_get (); | 323 | ma->start_date = GNUNET_TIME_absolute_get (); |
348 | ma->ph = perform_dht_put (zone, | 324 | ma->ph = perform_dht_put (zone, |
349 | label, | 325 | label, |
350 | rd, | 326 | rd_public, |
351 | rd_count, | 327 | rd_public_count, |
328 | expire, | ||
352 | ma); | 329 | ma); |
353 | if (NULL == ma->ph) | 330 | if (NULL == ma->ph) |
354 | { | 331 | { |
diff --git a/src/zonemaster/gnunet-service-zonemaster.c b/src/zonemaster/gnunet-service-zonemaster.c index bacafb97c..c6b86bf71 100644 --- a/src/zonemaster/gnunet-service-zonemaster.c +++ b/src/zonemaster/gnunet-service-zonemaster.c | |||
@@ -30,7 +30,6 @@ | |||
30 | #include "gnunet_namestore_service.h" | 30 | #include "gnunet_namestore_service.h" |
31 | #include "gnunet_statistics_service.h" | 31 | #include "gnunet_statistics_service.h" |
32 | 32 | ||
33 | |||
34 | #define LOG_STRERROR_FILE(kind, syscall, \ | 33 | #define LOG_STRERROR_FILE(kind, syscall, \ |
35 | filename) GNUNET_log_from_strerror_file (kind, "util", \ | 34 | filename) GNUNET_log_from_strerror_file (kind, "util", \ |
36 | syscall, \ | 35 | syscall, \ |
@@ -90,7 +89,6 @@ | |||
90 | */ | 89 | */ |
91 | #define DHT_GNS_REPLICATION_LEVEL 5 | 90 | #define DHT_GNS_REPLICATION_LEVEL 5 |
92 | 91 | ||
93 | |||
94 | /** | 92 | /** |
95 | * Handle for DHT PUT activity triggered from the namestore monitor. | 93 | * Handle for DHT PUT activity triggered from the namestore monitor. |
96 | */ | 94 | */ |
@@ -527,46 +525,6 @@ dht_put_continuation (void *cls) | |||
527 | } | 525 | } |
528 | 526 | ||
529 | 527 | ||
530 | /** | ||
531 | * Convert namestore records from the internal format to that | ||
532 | * suitable for publication (removes private records, converts | ||
533 | * to absolute expiration time). | ||
534 | * | ||
535 | * @param rd input records | ||
536 | * @param rd_count size of the @a rd and @a rd_public arrays | ||
537 | * @param rd_public where to write the converted records | ||
538 | * @return number of records written to @a rd_public | ||
539 | */ | ||
540 | static unsigned int | ||
541 | convert_records_for_export (const struct GNUNET_GNSRECORD_Data *rd, | ||
542 | unsigned int rd_count, | ||
543 | struct GNUNET_GNSRECORD_Data *rd_public) | ||
544 | { | ||
545 | struct GNUNET_TIME_Absolute now; | ||
546 | unsigned int rd_public_count; | ||
547 | |||
548 | rd_public_count = 0; | ||
549 | now = GNUNET_TIME_absolute_get (); | ||
550 | for (unsigned int i = 0; i < rd_count; i++) | ||
551 | { | ||
552 | if (0 != (rd[i].flags & GNUNET_GNSRECORD_RF_PRIVATE)) | ||
553 | continue; | ||
554 | if ((0 == (rd[i].flags & GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION)) && | ||
555 | (rd[i].expiration_time < now.abs_value_us)) | ||
556 | continue; /* record already expired, skip it */ | ||
557 | if (0 != (rd[i].flags & GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION)) | ||
558 | { | ||
559 | /* GNUNET_GNSRECORD_block_create will convert to absolute time; | ||
560 | we just need to adjust our iteration frequency */ | ||
561 | min_relative_record_time.rel_value_us = | ||
562 | GNUNET_MIN (rd[i].expiration_time, | ||
563 | min_relative_record_time.rel_value_us); | ||
564 | } | ||
565 | rd_public[rd_public_count++] = rd[i]; | ||
566 | } | ||
567 | return rd_public_count; | ||
568 | } | ||
569 | |||
570 | 528 | ||
571 | /** | 529 | /** |
572 | * Store GNS records in the DHT. | 530 | * Store GNS records in the DHT. |
@@ -583,30 +541,28 @@ perform_dht_put (const struct GNUNET_IDENTITY_PrivateKey *key, | |||
583 | const char *label, | 541 | const char *label, |
584 | const struct GNUNET_GNSRECORD_Data *rd_public, | 542 | const struct GNUNET_GNSRECORD_Data *rd_public, |
585 | unsigned int rd_public_count, | 543 | unsigned int rd_public_count, |
544 | const struct GNUNET_TIME_Absolute expire, | ||
586 | struct DhtPutActivity *ma) | 545 | struct DhtPutActivity *ma) |
587 | { | 546 | { |
588 | struct GNUNET_GNSRECORD_Block *block; | 547 | struct GNUNET_GNSRECORD_Block *block; |
589 | struct GNUNET_HashCode query; | 548 | struct GNUNET_HashCode query; |
590 | struct GNUNET_TIME_Absolute expire; | ||
591 | size_t block_size; | 549 | size_t block_size; |
592 | struct GNUNET_DHT_PutHandle *ret; | 550 | struct GNUNET_DHT_PutHandle *ret; |
593 | 551 | ||
594 | expire = GNUNET_GNSRECORD_record_get_expiration_time (rd_public_count, | ||
595 | rd_public); | ||
596 | if (cache_keys) | 552 | if (cache_keys) |
597 | GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_block_create2 (key, | 553 | GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_block_create2 (key, |
598 | expire, | 554 | expire, |
599 | label, | 555 | label, |
600 | rd_public, | 556 | rd_public, |
601 | rd_public_count, | 557 | rd_public_count, |
602 | &block)); | 558 | &block)); |
603 | else | 559 | else |
604 | GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_block_create (key, | 560 | GNUNET_assert (GNUNET_OK == GNUNET_GNSRECORD_block_create (key, |
605 | expire, | 561 | expire, |
606 | label, | 562 | label, |
607 | rd_public, | 563 | rd_public, |
608 | rd_public_count, | 564 | rd_public_count, |
609 | &block)); | 565 | &block)); |
610 | if (NULL == block) | 566 | if (NULL == block) |
611 | { | 567 | { |
612 | GNUNET_break (0); | 568 | GNUNET_break (0); |
@@ -713,7 +669,6 @@ zone_iteration_finished (void *cls) | |||
713 | } | 669 | } |
714 | } | 670 | } |
715 | 671 | ||
716 | |||
717 | /** | 672 | /** |
718 | * Function used to put all records successively into the DHT. | 673 | * Function used to put all records successively into the DHT. |
719 | * | 674 | * |
@@ -733,12 +688,26 @@ put_gns_record (void *cls, | |||
733 | struct GNUNET_GNSRECORD_Data rd_public[rd_count]; | 688 | struct GNUNET_GNSRECORD_Data rd_public[rd_count]; |
734 | unsigned int rd_public_count; | 689 | unsigned int rd_public_count; |
735 | struct DhtPutActivity *ma; | 690 | struct DhtPutActivity *ma; |
691 | struct GNUNET_TIME_Absolute expire; | ||
692 | char *emsg; | ||
736 | 693 | ||
737 | (void) cls; | 694 | (void) cls; |
738 | ns_iteration_left--; | 695 | ns_iteration_left--; |
739 | rd_public_count = convert_records_for_export (rd, | 696 | if (GNUNET_OK != GNUNET_GNSRECORD_convert_records_for_export (label, |
740 | rd_count, | 697 | rd, |
741 | rd_public); | 698 | rd_count, |
699 | rd_public, | ||
700 | &rd_public_count, | ||
701 | &expire, | ||
702 | &emsg)) | ||
703 | { | ||
704 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | ||
705 | "Record set inconsistent, moving to next record set: %s\n", | ||
706 | emsg); | ||
707 | GNUNET_free (emsg); | ||
708 | check_zone_namestore_next (); | ||
709 | return; | ||
710 | } | ||
742 | if (0 == rd_public_count) | 711 | if (0 == rd_public_count) |
743 | { | 712 | { |
744 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 713 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
@@ -746,15 +715,30 @@ put_gns_record (void *cls, | |||
746 | check_zone_namestore_next (); | 715 | check_zone_namestore_next (); |
747 | return; | 716 | return; |
748 | } | 717 | } |
718 | for (unsigned int i = 0; i < rd_public_count; i++) | ||
719 | { | ||
720 | if (0 != (rd_public[i].flags & GNUNET_GNSRECORD_RF_RELATIVE_EXPIRATION)) | ||
721 | { | ||
722 | /* GNUNET_GNSRECORD_block_create will convert to absolute time; | ||
723 | we just need to adjust our iteration frequency */ | ||
724 | min_relative_record_time.rel_value_us = | ||
725 | GNUNET_MIN (rd_public[i].expiration_time, | ||
726 | min_relative_record_time.rel_value_us); | ||
727 | } | ||
728 | } | ||
729 | |||
730 | |||
749 | /* We got a set of records to publish */ | 731 | /* We got a set of records to publish */ |
750 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, | 732 | GNUNET_log (GNUNET_ERROR_TYPE_DEBUG, |
751 | "Starting DHT PUT\n"); | 733 | "Starting DHT PUT\n"); |
734 | |||
752 | ma = GNUNET_new (struct DhtPutActivity); | 735 | ma = GNUNET_new (struct DhtPutActivity); |
753 | ma->start_date = GNUNET_TIME_absolute_get (); | 736 | ma->start_date = GNUNET_TIME_absolute_get (); |
754 | ma->ph = perform_dht_put (key, | 737 | ma->ph = perform_dht_put (key, |
755 | label, | 738 | label, |
756 | rd_public, | 739 | rd_public, |
757 | rd_public_count, | 740 | rd_public_count, |
741 | expire, | ||
758 | ma); | 742 | ma); |
759 | put_cnt++; | 743 | put_cnt++; |
760 | if (0 == put_cnt % DELTA_INTERVAL) | 744 | if (0 == put_cnt % DELTA_INTERVAL) |
@@ -788,7 +772,6 @@ put_gns_record (void *cls, | |||
788 | } | 772 | } |
789 | } | 773 | } |
790 | 774 | ||
791 | |||
792 | /** | 775 | /** |
793 | * Periodically iterate over all zones and store everything in DHT | 776 | * Periodically iterate over all zones and store everything in DHT |
794 | * | 777 | * |