i18n: translate more dynamic messages

This commit is contained in:
Vincent Breitmoser 2019-09-28 21:54:00 +02:00
parent 82f5450eb5
commit 9152e2d3dd
No known key found for this signature in database
GPG Key ID: 7BD18320DEADFA11
11 changed files with 474 additions and 312 deletions

View File

@ -1,7 +1,7 @@
{{#> layout }}
{{#with page}}
<p>
{{ text "We have sent an email with further instructions to <span class=\"email\">{{ address }}</span>" rerender }}.
{{ text "We have sent an email with further instructions to <span class=\"email\">{{ address }}</span>." rerender }}
</p>
{{/with}}
{{/layout}}

View File

@ -1,6 +1,6 @@
# Translators:
# Vincent Breitmoser <look@my.amazin.horse>, 2019
#
#
msgid ""
msgstr ""
"Project-Id-Version: hagrid\n"
@ -44,18 +44,27 @@ msgid "We found an entry for <span class=\"email\">{{ query }}</span>:"
msgstr "Eintrag gefunden für <span class=\"email\">{{ query }}</span>:"
#: src/gettext_strings.rs:8
msgid ""
"<strong>Hint:</strong> It's more convenient to use <span "
"class=\"brand\">keys.openpgp.org</span> from your OpenPGP software.<br /> "
"Take a look at our <a href=\"/about/usage\">usage guide</a> for details."
msgstr ""
"<strong>Tip:</strong> Es ist bequemer, <span class=\"brand\">keys.openpgp.org</span> aus OpenPGP software zu verwenden. <br />\n"
"Mehr dazu findest du in den <a href=\"/about/usage\">Nutzungshinweisen</a>."
#: src/gettext_strings.rs:9
msgid "debug info"
msgstr "debug info"
#: src/gettext_strings.rs:9
#: src/gettext_strings.rs:10
msgid "Search by Email Address / Key ID / Fingerprint"
msgstr "Suche nach Email-Adresse / Schlüssel-ID / Fingerprint"
#: src/gettext_strings.rs:10
#: src/gettext_strings.rs:11
msgid "Search"
msgstr "Suchen"
#: src/gettext_strings.rs:11
#: src/gettext_strings.rs:12
msgid ""
"You can also <a href=\"/upload\">upload</a> or <a "
"href=\"/manage\">manage</a> your key."
@ -63,23 +72,23 @@ msgstr ""
"Du kannst deinen Schlüssel <a href=\"/upload\">hochladen</a> oder <a "
"href=\"/manage\">verwalten</a>."
#: src/gettext_strings.rs:12
#: src/gettext_strings.rs:13
msgid "Find out more <a href=\"/about\">about this service</a>."
msgstr "Erfahre mehr <a href=\"/about\">über diesen Keyserver</a>."
#: src/gettext_strings.rs:13
#: src/gettext_strings.rs:14
msgid "News:"
msgstr "News:"
#: src/gettext_strings.rs:14
#: src/gettext_strings.rs:15
msgid "v{{ version }} built from"
msgstr "v{{ version }}, Revision"
#: src/gettext_strings.rs:15
#: src/gettext_strings.rs:16
msgid "Powered by <a href=\"https://sequoia-pgp.org\">Sequoia-PGP</a>"
msgstr "Powered by <a href=\"https://sequoia-pgp.org\">Sequoia-PGP</a>"
#: src/gettext_strings.rs:16
#: src/gettext_strings.rs:17
msgid ""
"Background image retrieved from <a "
"href=\"https://www.toptal.com/designers/subtlepatterns/subtle-grey/\">Subtle"
@ -88,23 +97,23 @@ msgstr ""
"Hintergrund von <a href=\"https://www.toptal.com/designers/subtlepatterns"
"/subtle-grey/\">Subtle Patterns</a> unter CC BY-SA 3.0"
#: src/gettext_strings.rs:17
#: src/gettext_strings.rs:18
msgid "Maintenance Mode"
msgstr "Wartungsarbeiten"
#: src/gettext_strings.rs:18
#: src/gettext_strings.rs:19
msgid "Manage your key"
msgstr "Schlüssel verwalten"
#: src/gettext_strings.rs:19
#: src/gettext_strings.rs:20
msgid "Enter any verified e-mail address of your key"
msgstr "Eine Adresse des zu verwaltenden Schlüssels"
#: src/gettext_strings.rs:20
#: src/gettext_strings.rs:21
msgid "Send link"
msgstr "Sende Link"
#: src/gettext_strings.rs:21
#: src/gettext_strings.rs:22
msgid ""
"We will send you an e-mail with a link you can use to remove any of your "
"e-mail addresses from search."
@ -112,7 +121,7 @@ msgstr ""
"Du wirst eine E-Mail mit einem Link erhalten, der es erlaubt, Adressen aus "
"der Suche zu entfernen."
#: src/gettext_strings.rs:22
#: src/gettext_strings.rs:23
msgid ""
"Managing the key <span class=\"fingerprint\"><a href=\"{{ key_link }}\" "
"target=\"_blank\">{{ key_fpr }}</a></span>."
@ -120,11 +129,11 @@ msgstr ""
"Verwaltung des Schlüssels <span class=\"fingerprint\"><a href=\"{{ key_link "
"}}\" target=\"_blank\">{{ key_fpr }}</a></span>."
#: src/gettext_strings.rs:23
#: src/gettext_strings.rs:24
msgid "Your key is published with the following identity information:"
msgstr "Dieser Schlüssel ist veröffentlicht mit diesen Identitäten:"
#: src/gettext_strings.rs:24
#: src/gettext_strings.rs:25
msgid ""
"Clicking \"delete\" on any address will remove it from this key. It will no "
"longer appear in a search.<br /> To add another address, <a "
@ -134,7 +143,7 @@ msgstr ""
"entfernt werden. <br /> Um eine Adresse hinzuzufügen, muss der Schlüssel <a "
"href=\"/upload\">erneut hochgeladen</a> werden."
#: src/gettext_strings.rs:25
#: src/gettext_strings.rs:26
msgid ""
"Your key is published as only non-identity information. (<a href=\"/about\""
" target=\"_blank\">what does this mean?</a>)"
@ -142,25 +151,25 @@ msgstr ""
"Dieser Schlüssel ist jetzt ohne Identitäts-Informationen veröffentlicht (<a "
"href=\"/about\" target=\"_blank\">was heisst das?</a>)"
#: src/gettext_strings.rs:26
#: src/gettext_strings.rs:27
msgid "To add an address, <a href=\"/upload\">upload</a> the key again."
msgstr ""
"Um eine Identität hinzuzufügen, lade den Schlüssel <a "
"href=\"/upload\">erneut hoch</a>."
#: src/gettext_strings.rs:27
#: src/gettext_strings.rs:28
msgid ""
"We have sent an email with further instructions to <span class=\"email\">{{ "
"address }}</span>"
"address }}</span>."
msgstr ""
"Eine E-Mail mit den nächsten Schritten wurde an <span class=\"email\">{{ "
"address }}</span> gesendet."
#: src/gettext_strings.rs:28
#: src/gettext_strings.rs:29
msgid "This address was already verified."
msgstr "Diese Adresse war bereits bestätigt."
#: src/gettext_strings.rs:29
#: src/gettext_strings.rs:30
msgid ""
"Your key <span class=\"fingerprint\">{{ key_fpr }}</span> is now published "
"for the identity <a href=\"{{userid_link}}\" target=\"_blank\"><span "
@ -170,29 +179,29 @@ msgstr ""
"veröffentlicht mit der Identität <a href=\"{{userid_link}}\" "
"target=\"_blank\"><span class=\"email\">{{ userid }}</span></a>."
#: src/gettext_strings.rs:30
#: src/gettext_strings.rs:31
msgid "Verification failed! Perhaps the link you used was expired?"
msgstr ""
"Bei der Bestätigung ist ein Fehler aufgetreten! Vielleicht war das Zeitlimit"
" für den Link abgelaufen?"
#: src/gettext_strings.rs:31
#: src/gettext_strings.rs:32
msgid "You can <a href=\"/upload\">try uploading again</a>."
msgstr "Du kannst den Upload <a href=\"/upload\">erneut versuchen</a>."
#: src/gettext_strings.rs:32
#: src/gettext_strings.rs:33
msgid "Upload your key"
msgstr "Schlüssel hochladen"
#: src/gettext_strings.rs:33
#: src/gettext_strings.rs:34
msgid "Your public key"
msgstr "Dein Schlüssel"
#: src/gettext_strings.rs:34
#: src/gettext_strings.rs:35
msgid "Upload"
msgstr "Upload"
#: src/gettext_strings.rs:35
#: src/gettext_strings.rs:36
msgid ""
"Need more info? Check our <a target=\"_blank\" href=\"/about\">intro</a> and"
" <a target=\"_blank\" href=\"/about/usage\">usage guide</a>!"
@ -201,7 +210,7 @@ msgstr ""
"href=\"/about\">Übersicht</a> und <a target=\"_blank\" "
"href=\"/about/usage\">Nutzungshinweise</a>."
#: src/gettext_strings.rs:36
#: src/gettext_strings.rs:37
msgid ""
"You uploaded the key <span class=\"fingerprint\"><a href=\"{{ key_link }}\" "
"target=\"_blank\">{{ key_fpr }}</a></span>."
@ -209,11 +218,11 @@ msgstr ""
"Schlüssel <span class=\"fingerprint\"><a href=\"{{ key_link }}\" "
"target=\"_blank\">{{key_fpr}}</a></span> erfolgreich hochgeladen."
#: src/gettext_strings.rs:37
#: src/gettext_strings.rs:38
msgid "This key is revoked."
msgstr "Dieser Schlüssel ist widerrufen."
#: src/gettext_strings.rs:38
#: src/gettext_strings.rs:39
msgid ""
"It is published without identity information and can't be made available for"
" search by e-mail address"
@ -221,11 +230,11 @@ msgstr ""
"Er wird veröffentlicht ohne Identitäten, ist aber nicht für eine Suche nach "
"E-Mail Adresse verfügbar."
#: src/gettext_strings.rs:39
#: src/gettext_strings.rs:40
msgid "what does this mean?"
msgstr "was heisst das?"
#: src/gettext_strings.rs:40
#: src/gettext_strings.rs:41
msgid ""
"This key is now published with the following identity information (<a "
"href=\"/about\" target=\"_blank\">what does this mean?</a>):"
@ -233,11 +242,11 @@ msgstr ""
"Dieser Schlüssel ist mit folgenden Identitäten veröffentlicht (<a "
"href=\"/about\" target=\"_blank\">was heisst das?</a>):"
#: src/gettext_strings.rs:41
#: src/gettext_strings.rs:42
msgid "Published"
msgstr "Veröffentlicht"
#: src/gettext_strings.rs:42
#: src/gettext_strings.rs:43
msgid ""
"This key is now published with only non-identity information (<a "
"href=\"/about\" target=\"_blank\">what does this mean?</a>)"
@ -245,7 +254,7 @@ msgstr ""
"Dieser Schlüssel ist jetzt ohne Identitäts-Informationen veröffentlicht (<a "
"href=\"/about\" target=\"_blank\">was heisst das?</a>)"
#: src/gettext_strings.rs:43
#: src/gettext_strings.rs:44
msgid ""
"To make the key available for search by e-mail address, you can verify it "
"belongs to you:"
@ -253,11 +262,11 @@ msgstr ""
"Um den Schlüssel für eine Suche per E-Mail Adresse verfügbar zu machen, muss"
" die entsprechende Adresse bestätigt werden:"
#: src/gettext_strings.rs:44
#: src/gettext_strings.rs:45
msgid "Verification Pending"
msgstr "Bestätigung wird erwartet"
#: src/gettext_strings.rs:45
#: src/gettext_strings.rs:46
msgid ""
"<strong>Note:</strong> Some providers delay e-mails for up to 15 minutes to "
"prevent spam. Please be patient."
@ -265,11 +274,11 @@ msgstr ""
"<strong>Hinweis:</strong> Manche Provider verzögern den Empfang von Emails "
"um bis zu 15 Minuten, um Spam zu verhindern. Bitte einen Moment Geduld."
#: src/gettext_strings.rs:46
#: src/gettext_strings.rs:47
msgid "Send Verification Mail"
msgstr "Bestätigungs-E-Mail senden"
#: src/gettext_strings.rs:47
#: src/gettext_strings.rs:48
msgid ""
"This key contains one identity that could not be parsed as an email "
"address.<br /> This identity can't be published on <span "
@ -281,7 +290,7 @@ msgstr ""
"class=\"brand\">keys.openpgp.org</span> veröffentlicht werden. (<a "
"href=\"/about/faq#non-email-uids\" target=\"_blank\">warum?</a>)"
#: src/gettext_strings.rs:48
#: src/gettext_strings.rs:49
msgid ""
"This key contains {{ count_unparsed }} identities that could not be parsed "
"as an email address.<br /> These identities can't be published on <span "
@ -293,7 +302,7 @@ msgstr ""
"auf <span class=\"brand\">keys.openpgp.org</span> veröffentlicht werden. (<a"
" href=\"/about/faq#non-email-uids\" target=\"_blank\">warum?</a>)"
#: src/gettext_strings.rs:49
#: src/gettext_strings.rs:50
msgid ""
"This key contains one revoked identity, which is not published. (<a "
"href=\"/about/faq#revoked-uids\" target=\"_blank\">Why?</a>)"
@ -302,7 +311,7 @@ msgstr ""
"veröffentlicht. (<a href=\"/about/faq#revoked-uids\" "
"target=\"_blank\">Warum?</a>)"
#: src/gettext_strings.rs:50
#: src/gettext_strings.rs:51
msgid ""
"This key contains {{ count_revoked }} revoked identities, which are not "
"published. (<a href=\"/about/faq#revoked-uids\" target=\"_blank\">Why?</a>)"
@ -311,11 +320,11 @@ msgstr ""
"werden nicht veröffentlicht. (<a href=\"/about/faq#revoked-uids\" "
"target=\"_blank\">Warum?</a>)"
#: src/gettext_strings.rs:51
#: src/gettext_strings.rs:52
msgid "Your keys have been successfully uploaded:"
msgstr "Schlüssel erfolgreich hochgeladen:"
#: src/gettext_strings.rs:52
#: src/gettext_strings.rs:53
msgid ""
"<strong>Note:</strong> To make keys searchable by address, you must upload "
"them individually."
@ -323,11 +332,11 @@ msgstr ""
"<strong>Hinweis:</strong> Schlüssel müssen einzeln hochgeladen werden, um "
"sie für die Suche per E-Mail-Adresse zu bestätigen."
#: src/gettext_strings.rs:53
#: src/gettext_strings.rs:54
msgid "Verifying your email address…"
msgstr "E-Mail Adresse wird bestätigt..."
#: src/gettext_strings.rs:54
#: src/gettext_strings.rs:55
msgid ""
"If the process doesn't complete after a few seconds, <input type=\"submit\" "
"class=\"textbutton\" value=\"click here\" />."
@ -335,15 +344,15 @@ msgstr ""
"Wenn der Vorgang nicht in einigen Sekunden erfolgreich ist, <input "
"type=\"submit\" class=\"textbutton\" value=\"klicke hier\"/>."
#: src/gettext_strings.rs:56
#: src/gettext_strings.rs:57
msgid "Manage your key on {{domain}}"
msgstr "Schlüssel-Verwaltung auf {{domain}}"
#: src/gettext_strings.rs:58
#: src/gettext_strings.rs:59
msgid "Hi,"
msgstr "Hi,"
#: src/gettext_strings.rs:59
#: src/gettext_strings.rs:60
msgid ""
"this is an automated message from <a rel=\"nofollow\" href=\"{{ base_uri "
"}}\" style=\"text-decoration:none; color: #333\"><tt>{{ domain }}</tt></a>."
@ -352,22 +361,22 @@ msgstr ""
"base_uri }}\" style=\"text-decoration:none; color: #333\"><tt>{{ domain "
"}}</tt></a>."
#: src/gettext_strings.rs:60
#: src/gettext_strings.rs:61
msgid "If you didn't request this message, please ignore it."
msgstr "Falls dies unerwartet ist, bitte die Nachricht ignorieren."
#: src/gettext_strings.rs:61
#: src/gettext_strings.rs:62
msgid "OpenPGP key: <tt>{{ primary_fp }}</tt>"
msgstr "OpenPGP Schlüssel: <tt>{{ primary_fp }}</tt>"
#: src/gettext_strings.rs:62
#: src/gettext_strings.rs:63
msgid ""
"To manage and delete listed addresses on this key, please follow the link "
"below:"
msgstr ""
"Du kannst die Identitäten dieses Schlüssels unter folgendem Link verwalten:"
#: src/gettext_strings.rs:63
#: src/gettext_strings.rs:64
msgid ""
"You can find more info at <a href=\"{{ base_uri }}/about\">{{ domain "
"}}/about</a>."
@ -375,7 +384,7 @@ msgstr ""
"Weitere Informationen findest du unter <a href=\"{{base_uri}}/about\">{{ "
"domain }}/about</a>."
#: src/gettext_strings.rs:64
#: src/gettext_strings.rs:65
msgid ""
"Greetings from the <a rel=\"nofollow\" href=\"{{ base_uri }}\" style=\"text-"
"decoration:none; color: #333\"><tt>keys.openpgp.org</tt></a> team"
@ -383,7 +392,7 @@ msgstr ""
"Das <a rel=\"nofollow\" href=\"{{base_uri}}\" style=\"text-decoration:none; "
"color: #333\"><tt>keys.openpgp.org</tt></a> Team"
#: src/gettext_strings.rs:67
#: src/gettext_strings.rs:68
msgid ""
"this is an automated message from {{domain}}. If you didn't\n"
"request this message, please ignore it."
@ -391,30 +400,30 @@ msgstr ""
"dies ist eine automatisierte Nachricht von {{domain}}. Falls dies unerwartet"
" ist, bitte die Nachricht ignorieren."
#: src/gettext_strings.rs:68
#: src/gettext_strings.rs:69
msgid "OpenPGP key: {{primary_fp}}"
msgstr "OpenPGP Schlüssel: {{primary_fp}}"
#: src/gettext_strings.rs:69
#: src/gettext_strings.rs:70
msgid ""
"To manage and delete listed addresses on this key, please follow\n"
"the link below:"
msgstr ""
"Du kannst die Identitäten dieses Schlüssels unter folgendem Link verwalten:"
#: src/gettext_strings.rs:70
#: src/gettext_strings.rs:71
msgid "You can find more info at {{base_uri}}/about"
msgstr "Weiter Informationen findest du unter {{base_uri}}/about"
#: src/gettext_strings.rs:71
#: src/gettext_strings.rs:72
msgid "Greetings from the keys.openpgp.org team"
msgstr "Das keys.openpgp.org Team"
#: src/gettext_strings.rs:73
#: src/gettext_strings.rs:74
msgid "Verify {{userid}} for your key on {{domain}}"
msgstr "Bestätige {{userid}} für deinen Schlüssel auf {{domain}}"
#: src/gettext_strings.rs:76
#: src/gettext_strings.rs:77
msgid ""
"this is an automated message from <a rel=\"nofollow\" href=\"{{base_uri}}\" "
"style=\"text-decoration:none; color: #333\"><tt>{{domain}}</tt></a>. If you "
@ -424,11 +433,11 @@ msgstr ""
"base_uri }}\" style=\"text-decoration:none; color: #333\"><tt>{{ domain "
"}}</tt></a>. Falls dies unerwartet ist, bitte die Nachricht ignorieren."
#: src/gettext_strings.rs:77
#: src/gettext_strings.rs:78
msgid "OpenPGP key: <tt>{{primary_fp}}</tt>"
msgstr "OpenPGP Schlüssel: <tt>{{primary_fp}}</tt>"
#: src/gettext_strings.rs:78
#: src/gettext_strings.rs:79
msgid ""
"To let others find this key from your email address \"<a rel=\"nofollow\" "
"href=\"#\" style=\"text-decoration:none; color: #333\">{{userid}}</a>\", "
@ -438,7 +447,7 @@ msgstr ""
"=\"text-decoration:none; color: #333\">{{userid}}</a>\" verfügbar zu machen,"
" klicke diesen Link:"
#: src/gettext_strings.rs:79
#: src/gettext_strings.rs:80
msgid ""
"You can find more info at <a "
"href=\"{{base_uri}}/about\">{{domain}}/about</a>."
@ -446,7 +455,7 @@ msgstr ""
"Weiter Informationen findest du unter <a "
"href=\"{{base_uri}}/about\">{{domain}}/about</a>."
#: src/gettext_strings.rs:80
#: src/gettext_strings.rs:81
msgid ""
"Greetings from the <a rel=\"nofollow\" href=\"{{base_uri}}\" style=\"text-"
"decoration:none; color: #333\"><tt>keys.openpgp.org</tt></a> team"
@ -454,7 +463,7 @@ msgstr ""
"Grüße vom <a rel=\"nofollow\" href=\"{{base_uri}}\" style=\"text-"
"decoration:none; color: #333\"><tt>keys.openpgp.org</tt></a> team"
#: src/gettext_strings.rs:85
#: src/gettext_strings.rs:86
msgid ""
"To let others find this key from your email address \"{{userid}}\",\n"
"please follow the link below:"
@ -462,11 +471,11 @@ msgstr ""
"Um diesen OpenPGP-Schlüssel unter der Adresse \"{{userid}}\" auffindbar zu machen,\n"
"klicke diesen Link:"
#: src/gettext_strings.rs:89
#: src/gettext_strings.rs:90
msgid "Your key upload on {{domain}}"
msgstr "Hochgeladener Schlüssel auf {{domain}}"
#: src/gettext_strings.rs:92
#: src/gettext_strings.rs:93
msgid ""
"this is an automated message from <a rel=\"nofollow\" href=\"{{base_uri}}\" "
"style=\"text-decoration:none; color: #333\"><tt>{{domain}}</tt></a>. If you "
@ -476,7 +485,7 @@ msgstr ""
"base_uri }}\" style=\"text-decoration:none; color: #333\"><tt>{{ domain "
"}}</tt></a>. Falls dies unerwartet ist, bitte die Nachricht ignorieren."
#: src/gettext_strings.rs:94
#: src/gettext_strings.rs:95
msgid ""
"This key was just uploaded for the first time, and is now published without "
"identity information. If you want to allow others to find this key by e-mail"
@ -486,7 +495,7 @@ msgstr ""
"Identitäten veröffentlicht. Um diesen Schlüssel für eine Suche nach E-Mail "
"Adresse verfügbar zu machen, folge diesem Link:"
#: src/gettext_strings.rs:99
#: src/gettext_strings.rs:100
msgid ""
"this is an automated message from {{domain}}. If you didn't upload your key\n"
"there, please ignore this message."
@ -494,7 +503,7 @@ msgstr ""
"dies ist eine automatisierte Nachricht von {{domain}}. Falls dies unerwartet ist,\n"
"bitte die Nachricht ignorieren."
#: src/gettext_strings.rs:101
#: src/gettext_strings.rs:102
msgid ""
"This key was just uploaded for the first time, and is now published without\n"
"identity information. If you want to allow others to find this key by e-mail\n"
@ -503,3 +512,41 @@ msgstr ""
"Dieser Schlüssel wurde gerade erstmals hochgeladen, und zunächst ohne Identitäten\n"
"veröffentlicht. Um diesen Schlüssel für eine Suche nach E-Mail Adresse verfügbar\n"
"zu machen, folge diesem Link:"
#: src/web/hkp.rs:144
msgid "Upload successful. This is a new key, a welcome mail has been sent!"
msgstr ""
"Upload erfolgreich. Da es sich um einen neuen Schlüssel handelt, wurde eine "
"Willkommens-Nachricht versandt."
#: src/web/hkp.rs:146
msgid ""
"Upload successful. Note that identity information will only be published "
"after verification! see {}/about/usage#gnupg-upload"
msgstr ""
"Upload erfolgreich. Für die Veröffentlichung von Identitäten ist eine "
"Bestätigung erforderlich! Siehe {}/about/usage#gnupg-upload"
#: src/web/manage.rs:103
msgid "This link is invalid or expired"
msgstr "Dieser Link ist ungültig, oder bereits abgelaufen."
#: src/web/manage.rs:129
msgid "Malformed address: {}"
msgstr "Ungültiges Adress-Format: {}"
#: src/web/manage.rs:136
msgid "No key for address: {}"
msgstr "Kein Schlüssel gefunden für {}"
#: src/web/manage.rs:152
msgid "A request was already sent for this address recently."
msgstr "Eine E-Mail für diesen Schlüssel wurde erst kürzlich versandt!"
#: src/web/vks.rs:173
msgid "Something went wrong processing key {}"
msgstr "Ein Fehler ist aufgetreten beim Verarbeiten des Schlüssels {}"
#: src/web/vks.rs:276
msgid "Invalid verification token!"
msgstr "Verifikations-Link ungültig."

View File

@ -41,18 +41,25 @@ msgid "We found an entry for <span class=\"email\">{{ query }}</span>:"
msgstr "We found an entry for <span class=\"email\">{{ query }}</span>:"
#: src/gettext_strings.rs:8
msgid ""
"<strong>Hint:</strong> It's more convenient to use <span class=\"brand"
"\">keys.openpgp.org</span> from your OpenPGP software.<br /> Take a look at "
"our <a href=\"/about/usage\">usage guide</a> for details."
msgstr ""
#: src/gettext_strings.rs:9
msgid "debug info"
msgstr "debug info"
#: src/gettext_strings.rs:9
#: src/gettext_strings.rs:10
msgid "Search by Email Address / Key ID / Fingerprint"
msgstr "Search by Email Address / Key ID / Fingerprint"
#: src/gettext_strings.rs:10
#: src/gettext_strings.rs:11
msgid "Search"
msgstr "Search"
#: src/gettext_strings.rs:11
#: src/gettext_strings.rs:12
msgid ""
"You can also <a href=\"/upload\">upload</a> or <a href=\"/manage\">manage</"
"a> your key."
@ -60,23 +67,23 @@ msgstr ""
"You can also <a href=\"/upload\">upload</a> or <a href=\"/manage\">manage</"
"a> your key."
#: src/gettext_strings.rs:12
#: src/gettext_strings.rs:13
msgid "Find out more <a href=\"/about\">about this service</a>."
msgstr "Find out more <a href=\"/about\">about this service</a>."
#: src/gettext_strings.rs:13
#: src/gettext_strings.rs:14
msgid "News:"
msgstr "News:"
#: src/gettext_strings.rs:14
#: src/gettext_strings.rs:15
msgid "v{{ version }} built from"
msgstr "v{{ version }} built from"
#: src/gettext_strings.rs:15
#: src/gettext_strings.rs:16
msgid "Powered by <a href=\"https://sequoia-pgp.org\">Sequoia-PGP</a>"
msgstr "Powered by <a href=\"https://sequoia-pgp.org\">Sequoia-PGP</a>"
#: src/gettext_strings.rs:16
#: src/gettext_strings.rs:17
msgid ""
"Background image retrieved from <a href=\"https://www.toptal.com/designers/"
"subtlepatterns/subtle-grey/\">Subtle Patterns</a> under CC BY-SA 3.0"
@ -84,77 +91,78 @@ msgstr ""
"Background image retrieved from <a href=\"https://www.toptal.com/designers/"
"subtlepatterns/subtle-grey/\">Subtle Patterns</a> under CC BY-SA 3.0"
#: src/gettext_strings.rs:17
#: src/gettext_strings.rs:18
msgid "Maintenance Mode"
msgstr "Maintenance Mode"
#: src/gettext_strings.rs:18
#: src/gettext_strings.rs:19
msgid "Manage your key"
msgstr "Manage your key"
#: src/gettext_strings.rs:19
#: src/gettext_strings.rs:20
msgid "Enter any verified e-mail address of your key"
msgstr "Enter any verified e-mail address of your key"
#: src/gettext_strings.rs:20
#: src/gettext_strings.rs:21
msgid "Send link"
msgstr "Send link"
#: src/gettext_strings.rs:21
msgid ""
"We will send you an e-mail with a link you can use to remove any of your e-"
"mail addresses from search."
msgstr ""
"We will send you an e-mail with a link you can use to remove any of your e-"
"mail addresses from search."
#: src/gettext_strings.rs:22
msgid ""
"We will send you an e-mail with a link you can use to remove any of your e-"
"mail addresses from search."
msgstr ""
"We will send you an e-mail with a link you can use to remove any of your e-"
"mail addresses from search."
#: src/gettext_strings.rs:23
msgid ""
"Managing the key <span class=\"fingerprint\"><a href=\"{{ key_link }}\" "
"target=\"_blank\">{{ key_fpr }}</a></span>."
msgstr ""
"Managing the key <span class=\"fingerprint\"><a href=\"{{ key_link }}\" "
"target=\"_blank\">{{ key_fpr }}</a></span>."
#: src/gettext_strings.rs:23
#: src/gettext_strings.rs:24
msgid "Your key is published with the following identity information:"
msgstr "Your key is published with the following identity information:"
#: src/gettext_strings.rs:24
msgid ""
"Clicking \"delete\" on any address will remove it from this key. It will no "
"longer appear in a search.<br /> To add another address, <a href=\"/upload"
"\">upload</a> the key again."
msgstr ""
"Clicking \"delete\" on any address will remove it from this key. It will no "
"longer appear in a search.<br /> To add another address, <a href=\"/upload"
"\">upload</a> the key again."
#: src/gettext_strings.rs:25
msgid ""
"Clicking \"delete\" on any address will remove it from this key. It will no "
"longer appear in a search.<br /> To add another address, <a href=\"/upload"
"\">upload</a> the key again."
msgstr ""
"Clicking \"delete\" on any address will remove it from this key. It will no "
"longer appear in a search.<br /> To add another address, <a href=\"/upload"
"\">upload</a> the key again."
#: src/gettext_strings.rs:26
msgid ""
"Your key is published as only non-identity information. (<a href=\"/about\" "
"target=\"_blank\">what does this mean?</a>)"
msgstr ""
"Your key is published as only non-identity information. (<a href=\"/about\" "
"target=\"_blank\">what does this mean?</a>)"
#: src/gettext_strings.rs:26
#: src/gettext_strings.rs:27
msgid "To add an address, <a href=\"/upload\">upload</a> the key again."
msgstr "To add an address, <a href=\"/upload\">upload</a> the key again."
#: src/gettext_strings.rs:27
#: src/gettext_strings.rs:28
#, fuzzy
msgid ""
"We have sent an email with further instructions to <span class=\"email"
"\">{{ address }}</span>"
"\">{{ address }}</span>."
msgstr ""
"We have sent an email with further instructions to <span class=\"email"
"\">{{ address }}</span>"
#: src/gettext_strings.rs:28
#: src/gettext_strings.rs:29
msgid "This address was already verified."
msgstr "This address was already verified."
#: src/gettext_strings.rs:29
#: src/gettext_strings.rs:30
msgid ""
"Your key <span class=\"fingerprint\">{{ key_fpr }}</span> is now published "
"for the identity <a href=\"{{userid_link}}\" target=\"_blank\"><span class="
@ -164,48 +172,48 @@ msgstr ""
"for the identity <a href=\"{{userid_link}}\" target=\"_blank\"><span class="
"\"email\">{{ userid }}</span></a>."
#: src/gettext_strings.rs:30
#: src/gettext_strings.rs:31
msgid "Verification failed! Perhaps the link you used was expired?"
msgstr "Verification failed! Perhaps the link you used was expired?"
#: src/gettext_strings.rs:31
#: src/gettext_strings.rs:32
msgid "You can <a href=\"/upload\">try uploading again</a>."
msgstr "You can <a href=\"/upload\">try uploading again</a>."
#: src/gettext_strings.rs:32
#: src/gettext_strings.rs:33
#, fuzzy
msgid "Upload your key"
msgstr "Manage your key"
#: src/gettext_strings.rs:33
#: src/gettext_strings.rs:34
msgid "Your public key"
msgstr "Your public key"
#: src/gettext_strings.rs:34
#: src/gettext_strings.rs:35
msgid "Upload"
msgstr "Upload"
#: src/gettext_strings.rs:35
msgid ""
"Need more info? Check our <a target=\"_blank\" href=\"/about\">intro</a> and "
"<a target=\"_blank\" href=\"/about/usage\">usage guide</a>!"
msgstr ""
"Need more info? Check our <a target=\"_blank\" href=\"/about\">intro</a> and "
"<a target=\"_blank\" href=\"/about/usage\">usage guide</a>!"
#: src/gettext_strings.rs:36
msgid ""
"Need more info? Check our <a target=\"_blank\" href=\"/about\">intro</a> and "
"<a target=\"_blank\" href=\"/about/usage\">usage guide</a>!"
msgstr ""
"Need more info? Check our <a target=\"_blank\" href=\"/about\">intro</a> and "
"<a target=\"_blank\" href=\"/about/usage\">usage guide</a>!"
#: src/gettext_strings.rs:37
msgid ""
"You uploaded the key <span class=\"fingerprint\"><a href=\"{{ key_link }}\" "
"target=\"_blank\">{{ key_fpr }}</a></span>."
msgstr ""
"You uploaded the key <span class=\"fingerprint\"><a href=\"{{ key_link }}\" "
"target=\"_blank\">{{ key_fpr }}</a></span>."
#: src/gettext_strings.rs:37
#: src/gettext_strings.rs:38
msgid "This key is revoked."
msgstr "This key is revoked."
#: src/gettext_strings.rs:38
#: src/gettext_strings.rs:39
msgid ""
"It is published without identity information and can't be made available for "
"search by e-mail address"
@ -213,11 +221,11 @@ msgstr ""
"It is published without identity information and can't be made available for "
"search by e-mail address"
#: src/gettext_strings.rs:39
#: src/gettext_strings.rs:40
msgid "what does this mean?"
msgstr "what does this mean?"
#: src/gettext_strings.rs:40
#: src/gettext_strings.rs:41
msgid ""
"This key is now published with the following identity information (<a href="
"\"/about\" target=\"_blank\">what does this mean?</a>):"
@ -225,54 +233,54 @@ msgstr ""
"This key is now published with the following identity information (<a href="
"\"/about\" target=\"_blank\">what does this mean?</a>):"
#: src/gettext_strings.rs:41
#: src/gettext_strings.rs:42
msgid "Published"
msgstr "Published"
#: src/gettext_strings.rs:42
msgid ""
"This key is now published with only non-identity information (<a href=\"/"
"about\" target=\"_blank\">what does this mean?</a>)"
msgstr ""
"This key is now published with only non-identity information (<a href=\"/"
"about\" target=\"_blank\">what does this mean?</a>)"
#: src/gettext_strings.rs:43
msgid ""
"This key is now published with only non-identity information (<a href=\"/"
"about\" target=\"_blank\">what does this mean?</a>)"
msgstr ""
"This key is now published with only non-identity information (<a href=\"/"
"about\" target=\"_blank\">what does this mean?</a>)"
#: src/gettext_strings.rs:44
msgid ""
"To make the key available for search by e-mail address, you can verify it "
"belongs to you:"
msgstr ""
"To make the key available for search by e-mail address, you can verify it "
"belongs to you:"
#: src/gettext_strings.rs:44
#: src/gettext_strings.rs:45
msgid "Verification Pending"
msgstr "Verification Pending"
#: src/gettext_strings.rs:45
#: src/gettext_strings.rs:46
msgid ""
"<strong>Note:</strong> Some providers delay e-mails for up to 15 minutes to "
"prevent spam. Please be patient."
msgstr ""
#: src/gettext_strings.rs:46
#: src/gettext_strings.rs:47
msgid "Send Verification Mail"
msgstr "Send Verification Mail"
#: src/gettext_strings.rs:47
msgid ""
"This key contains one identity that could not be parsed as an email address."
"<br /> This identity can't be published on <span class=\"brand\">keys."
"openpgp.org</span>. (<a href=\"/about/faq#non-email-uids\" target=\"_blank"
"\">why?</a>)"
msgstr ""
"This key contains one identity that could not be parsed as an email address."
"<br /> This identity can't be published on <span class=\"brand\">keys."
"openpgp.org</span>. (<a href=\"/about/faq#non-email-uids\" target=\"_blank"
"\">why?</a>)"
#: src/gettext_strings.rs:48
msgid ""
"This key contains one identity that could not be parsed as an email address."
"<br /> This identity can't be published on <span class=\"brand\">keys."
"openpgp.org</span>. (<a href=\"/about/faq#non-email-uids\" target=\"_blank"
"\">why?</a>)"
msgstr ""
"This key contains one identity that could not be parsed as an email address."
"<br /> This identity can't be published on <span class=\"brand\">keys."
"openpgp.org</span>. (<a href=\"/about/faq#non-email-uids\" target=\"_blank"
"\">why?</a>)"
#: src/gettext_strings.rs:49
msgid ""
"This key contains {{ count_unparsed }} identities that could not be parsed "
"as an email address.<br /> These identities can't be published on <span "
"class=\"brand\">keys.openpgp.org</span>. (<a href=\"/about/faq#non-email-"
@ -283,14 +291,14 @@ msgstr ""
"class=\"brand\">keys.openpgp.org</span>. (<a href=\"/about/faq#non-email-"
"uids\" target=\"_blank\">why?</a>)"
#: src/gettext_strings.rs:49
#: src/gettext_strings.rs:50
#, fuzzy
msgid ""
"This key contains one revoked identity, which is not published. (<a href=\"/"
"about/faq#revoked-uids\" target=\"_blank\">Why?</a>)"
msgstr "This key contains one revoked identity, which is not published."
#: src/gettext_strings.rs:50
#: src/gettext_strings.rs:51
#, fuzzy
msgid ""
"This key contains {{ count_revoked }} revoked identities, which are not "
@ -299,11 +307,11 @@ msgstr ""
"This key contains {{ count_revoked }} revoked identities, which are not "
"published."
#: src/gettext_strings.rs:51
#: src/gettext_strings.rs:52
msgid "Your keys have been successfully uploaded:"
msgstr "Your keys have been successfully uploaded:"
#: src/gettext_strings.rs:52
#: src/gettext_strings.rs:53
msgid ""
"<strong>Note:</strong> To make keys searchable by address, you must upload "
"them individually."
@ -311,11 +319,11 @@ msgstr ""
"<strong>Note:</strong> To make keys searchable by address, you must upload "
"them individually."
#: src/gettext_strings.rs:53
#: src/gettext_strings.rs:54
msgid "Verifying your email address…"
msgstr "Verifying your email address…"
#: src/gettext_strings.rs:54
#: src/gettext_strings.rs:55
msgid ""
"If the process doesn't complete after a few seconds, <input type=\"submit\" "
"class=\"textbutton\" value=\"click here\" />."
@ -323,15 +331,15 @@ msgstr ""
"If the process doesn't complete after a few seconds, <input type=\"submit\" "
"class=\"textbutton\" value=\"click here\" />."
#: src/gettext_strings.rs:56
#: src/gettext_strings.rs:57
msgid "Manage your key on {{domain}}"
msgstr "Manage your key on {{domain}}"
#: src/gettext_strings.rs:58
#: src/gettext_strings.rs:59
msgid "Hi,"
msgstr "Hi,"
#: src/gettext_strings.rs:59
#: src/gettext_strings.rs:60
msgid ""
"this is an automated message from <a rel=\"nofollow\" href="
"\"{{ base_uri }}\" style=\"text-decoration:none; color: "
@ -341,39 +349,39 @@ msgstr ""
"\"{{ base_uri }}\" style=\"text-decoration:none; color: "
"#333\"><tt>{{ domain }}</tt></a>."
#: src/gettext_strings.rs:60
#: src/gettext_strings.rs:61
msgid "If you didn't request this message, please ignore it."
msgstr "If you didn't request this message, please ignore it."
#: src/gettext_strings.rs:61
#: src/gettext_strings.rs:62
msgid "OpenPGP key: <tt>{{ primary_fp }}</tt>"
msgstr "OpenPGP key: <tt>{{ primary_fp }}</tt>"
#: src/gettext_strings.rs:62
msgid ""
"To manage and delete listed addresses on this key, please follow the link "
"below:"
msgstr ""
"To manage and delete listed addresses on this key, please follow the link "
"below:"
#: src/gettext_strings.rs:63
msgid ""
"You can find more info at <a href=\"{{ base_uri }}/about\">{{ domain }}/"
"about</a>."
"To manage and delete listed addresses on this key, please follow the link "
"below:"
msgstr ""
"You can find more info at <a href=\"{{ base_uri }}/about\">{{ domain }}/"
"about</a>."
"To manage and delete listed addresses on this key, please follow the link "
"below:"
#: src/gettext_strings.rs:64
msgid ""
"You can find more info at <a href=\"{{ base_uri }}/about\">{{ domain }}/"
"about</a>."
msgstr ""
"You can find more info at <a href=\"{{ base_uri }}/about\">{{ domain }}/"
"about</a>."
#: src/gettext_strings.rs:65
msgid ""
"Greetings from the <a rel=\"nofollow\" href=\"{{ base_uri }}\" style=\"text-"
"decoration:none; color: #333\"><tt>keys.openpgp.org</tt></a> team"
msgstr ""
"Greetings from the <a rel=\"nofollow\" href=\"{{ base_uri }}\" style=\"text-"
"decoration:none; color: #333\"><tt>keys.openpgp.org</tt></a> team"
#: src/gettext_strings.rs:67
#: src/gettext_strings.rs:68
#, fuzzy
msgid ""
"this is an automated message from {{domain}}. If you didn't\n"
@ -381,11 +389,11 @@ msgid ""
msgstr ""
"this is an automated message from {{domain}}. If you didn't upload your key"
#: src/gettext_strings.rs:68
#: src/gettext_strings.rs:69
msgid "OpenPGP key: {{primary_fp}}"
msgstr "OpenPGP key: {{primary_fp}}"
#: src/gettext_strings.rs:69
#: src/gettext_strings.rs:70
#, fuzzy
msgid ""
"To manage and delete listed addresses on this key, please follow\n"
@ -394,19 +402,19 @@ msgstr ""
"To manage and delete listed addresses on this key, please follow the link "
"below:"
#: src/gettext_strings.rs:70
#: src/gettext_strings.rs:71
msgid "You can find more info at {{base_uri}}/about"
msgstr "You can find more info at {{base_uri}}/about"
#: src/gettext_strings.rs:71
#: src/gettext_strings.rs:72
msgid "Greetings from the keys.openpgp.org team"
msgstr "Greetings from the keys.openpgp.org team"
#: src/gettext_strings.rs:73
#: src/gettext_strings.rs:74
msgid "Verify {{userid}} for your key on {{domain}}"
msgstr "Verify {{userid}} for your key on {{domain}}"
#: src/gettext_strings.rs:76
#: src/gettext_strings.rs:77
msgid ""
"this is an automated message from <a rel=\"nofollow\" href=\"{{base_uri}}\" "
"style=\"text-decoration:none; color: #333\"><tt>{{domain}}</tt></a>. If you "
@ -416,48 +424,48 @@ msgstr ""
"style=\"text-decoration:none; color: #333\"><tt>{{domain}}</tt></a>. If you "
"didn't request this message, please ignore it."
#: src/gettext_strings.rs:77
#: src/gettext_strings.rs:78
msgid "OpenPGP key: <tt>{{primary_fp}}</tt>"
msgstr "OpenPGP key: <tt>{{primary_fp}}</tt>"
#: src/gettext_strings.rs:78
msgid ""
"To let others find this key from your email address \"<a rel=\"nofollow\" "
"href=\"#\" style=\"text-decoration:none; color: #333\">{{userid}}</a>\", "
"please click the link below:"
msgstr ""
"To let others find this key from your email address \"<a rel=\"nofollow\" "
"href=\"#\" style=\"text-decoration:none; color: #333\">{{userid}}</a>\", "
"please click the link below:"
#: src/gettext_strings.rs:79
msgid ""
"You can find more info at <a href=\"{{base_uri}}/about\">{{domain}}/about</"
"a>."
"To let others find this key from your email address \"<a rel=\"nofollow\" "
"href=\"#\" style=\"text-decoration:none; color: #333\">{{userid}}</a>\", "
"please click the link below:"
msgstr ""
"You can find more info at <a href=\"{{base_uri}}/about\">{{domain}}/about</"
"a>."
"To let others find this key from your email address \"<a rel=\"nofollow\" "
"href=\"#\" style=\"text-decoration:none; color: #333\">{{userid}}</a>\", "
"please click the link below:"
#: src/gettext_strings.rs:80
msgid ""
"You can find more info at <a href=\"{{base_uri}}/about\">{{domain}}/about</"
"a>."
msgstr ""
"You can find more info at <a href=\"{{base_uri}}/about\">{{domain}}/about</"
"a>."
#: src/gettext_strings.rs:81
msgid ""
"Greetings from the <a rel=\"nofollow\" href=\"{{base_uri}}\" style=\"text-"
"decoration:none; color: #333\"><tt>keys.openpgp.org</tt></a> team"
msgstr ""
"Greetings from the <a rel=\"nofollow\" href=\"{{base_uri}}\" style=\"text-"
"decoration:none; color: #333\"><tt>keys.openpgp.org</tt></a> team"
#: src/gettext_strings.rs:85
#: src/gettext_strings.rs:86
#, fuzzy
msgid ""
"To let others find this key from your email address \"{{userid}}\",\n"
"please follow the link below:"
msgstr "To let others find this key from your email address \"{{userid}}\","
#: src/gettext_strings.rs:89
#: src/gettext_strings.rs:90
msgid "Your key upload on {{domain}}"
msgstr "Your key upload on {{domain}}"
#: src/gettext_strings.rs:92
#: src/gettext_strings.rs:93
msgid ""
"this is an automated message from <a rel=\"nofollow\" href=\"{{base_uri}}\" "
"style=\"text-decoration:none; color: #333\"><tt>{{domain}}</tt></a>. If you "
@ -467,7 +475,7 @@ msgstr ""
"style=\"text-decoration:none; color: #333\"><tt>{{domain}}</tt></a>. If you "
"didn't upload your key there, please ignore this message."
#: src/gettext_strings.rs:94
#: src/gettext_strings.rs:95
msgid ""
"This key was just uploaded for the first time, and is now published without "
"identity information. If you want to allow others to find this key by e-mail "
@ -477,7 +485,7 @@ msgstr ""
"identity information. If you want to allow others to find this key by e-mail "
"address, please follow this link:"
#: src/gettext_strings.rs:99
#: src/gettext_strings.rs:100
#, fuzzy
msgid ""
"this is an automated message from {{domain}}. If you didn't upload your key\n"
@ -485,7 +493,7 @@ msgid ""
msgstr ""
"this is an automated message from {{domain}}. If you didn't upload your key"
#: src/gettext_strings.rs:101
#: src/gettext_strings.rs:102
#, fuzzy
msgid ""
"This key was just uploaded for the first time, and is now published without\n"
@ -497,6 +505,41 @@ msgstr ""
"identity information. If you want to allow others to find this key by e-mail "
"address, please follow this link:"
#: src/web/hkp.rs:144
msgid "Upload successful. This is a new key, a welcome mail has been sent!"
msgstr ""
#: src/web/hkp.rs:146
msgid ""
"Upload successful. Note that identity information will only be published "
"after verification! see {}/about/usage#gnupg-upload"
msgstr ""
#: src/web/manage.rs:103
msgid "This link is invalid or expired"
msgstr ""
#: src/web/manage.rs:129
msgid "Malformed address: {}"
msgstr ""
#: src/web/manage.rs:136
msgid "No key for address: {}"
msgstr ""
#: src/web/manage.rs:152
msgid "A request was already sent for this address recently."
msgstr ""
#: src/web/vks.rs:173
msgid "Something went wrong processing key {}"
msgstr ""
#: src/web/vks.rs:276
#, fuzzy
msgid "Invalid verification token!"
msgstr "Send Verification Mail"
#~ msgid "(<a href=\"/about/faq#revoked-uids\" target=\"_blank\">Why?</a>)"
#~ msgstr "(<a href=\"/about/faq#revoked-uids\" target=\"_blank\">Why?</a>)"

View File

@ -41,289 +41,325 @@ msgid "We found an entry for <span class=\"email\">{{ query }}</span>:"
msgstr ""
#: src/gettext_strings.rs:8
msgid "debug info"
msgid "<strong>Hint:</strong> It's more convenient to use <span class=\"brand\">keys.openpgp.org</span> from your OpenPGP software.<br /> Take a look at our <a href=\"/about/usage\">usage guide</a> for details."
msgstr ""
#: src/gettext_strings.rs:9
msgid "Search by Email Address / Key ID / Fingerprint"
msgid "debug info"
msgstr ""
#: src/gettext_strings.rs:10
msgid "Search"
msgid "Search by Email Address / Key ID / Fingerprint"
msgstr ""
#: src/gettext_strings.rs:11
msgid "You can also <a href=\"/upload\">upload</a> or <a href=\"/manage\">manage</a> your key."
msgid "Search"
msgstr ""
#: src/gettext_strings.rs:12
msgid "Find out more <a href=\"/about\">about this service</a>."
msgid "You can also <a href=\"/upload\">upload</a> or <a href=\"/manage\">manage</a> your key."
msgstr ""
#: src/gettext_strings.rs:13
msgid "News:"
msgid "Find out more <a href=\"/about\">about this service</a>."
msgstr ""
#: src/gettext_strings.rs:14
msgid "v{{ version }} built from"
msgid "News:"
msgstr ""
#: src/gettext_strings.rs:15
msgid "Powered by <a href=\"https://sequoia-pgp.org\">Sequoia-PGP</a>"
msgid "v{{ version }} built from"
msgstr ""
#: src/gettext_strings.rs:16
msgid "Background image retrieved from <a href=\"https://www.toptal.com/designers/subtlepatterns/subtle-grey/\">Subtle Patterns</a> under CC BY-SA 3.0"
msgid "Powered by <a href=\"https://sequoia-pgp.org\">Sequoia-PGP</a>"
msgstr ""
#: src/gettext_strings.rs:17
msgid "Maintenance Mode"
msgid "Background image retrieved from <a href=\"https://www.toptal.com/designers/subtlepatterns/subtle-grey/\">Subtle Patterns</a> under CC BY-SA 3.0"
msgstr ""
#: src/gettext_strings.rs:18
msgid "Manage your key"
msgid "Maintenance Mode"
msgstr ""
#: src/gettext_strings.rs:19
msgid "Enter any verified e-mail address of your key"
msgid "Manage your key"
msgstr ""
#: src/gettext_strings.rs:20
msgid "Send link"
msgid "Enter any verified e-mail address of your key"
msgstr ""
#: src/gettext_strings.rs:21
msgid "We will send you an e-mail with a link you can use to remove any of your e-mail addresses from search."
msgid "Send link"
msgstr ""
#: src/gettext_strings.rs:22
msgid "Managing the key <span class=\"fingerprint\"><a href=\"{{ key_link }}\" target=\"_blank\">{{ key_fpr }}</a></span>."
msgid "We will send you an e-mail with a link you can use to remove any of your e-mail addresses from search."
msgstr ""
#: src/gettext_strings.rs:23
msgid "Your key is published with the following identity information:"
msgid "Managing the key <span class=\"fingerprint\"><a href=\"{{ key_link }}\" target=\"_blank\">{{ key_fpr }}</a></span>."
msgstr ""
#: src/gettext_strings.rs:24
msgid "Clicking \"delete\" on any address will remove it from this key. It will no longer appear in a search.<br /> To add another address, <a href=\"/upload\">upload</a> the key again."
msgid "Your key is published with the following identity information:"
msgstr ""
#: src/gettext_strings.rs:25
msgid "Your key is published as only non-identity information. (<a href=\"/about\" target=\"_blank\">what does this mean?</a>)"
msgid "Clicking \"delete\" on any address will remove it from this key. It will no longer appear in a search.<br /> To add another address, <a href=\"/upload\">upload</a> the key again."
msgstr ""
#: src/gettext_strings.rs:26
msgid "To add an address, <a href=\"/upload\">upload</a> the key again."
msgid "Your key is published as only non-identity information. (<a href=\"/about\" target=\"_blank\">what does this mean?</a>)"
msgstr ""
#: src/gettext_strings.rs:27
msgid "We have sent an email with further instructions to <span class=\"email\">{{ address }}</span>"
msgid "To add an address, <a href=\"/upload\">upload</a> the key again."
msgstr ""
#: src/gettext_strings.rs:28
msgid "This address was already verified."
msgid "We have sent an email with further instructions to <span class=\"email\">{{ address }}</span>."
msgstr ""
#: src/gettext_strings.rs:29
msgid "Your key <span class=\"fingerprint\">{{ key_fpr }}</span> is now published for the identity <a href=\"{{userid_link}}\" target=\"_blank\"><span class=\"email\">{{ userid }}</span></a>."
msgid "This address was already verified."
msgstr ""
#: src/gettext_strings.rs:30
msgid "Verification failed! Perhaps the link you used was expired?"
msgid "Your key <span class=\"fingerprint\">{{ key_fpr }}</span> is now published for the identity <a href=\"{{userid_link}}\" target=\"_blank\"><span class=\"email\">{{ userid }}</span></a>."
msgstr ""
#: src/gettext_strings.rs:31
msgid "You can <a href=\"/upload\">try uploading again</a>."
msgid "Verification failed! Perhaps the link you used was expired?"
msgstr ""
#: src/gettext_strings.rs:32
msgid "Upload your key"
msgid "You can <a href=\"/upload\">try uploading again</a>."
msgstr ""
#: src/gettext_strings.rs:33
msgid "Your public key"
msgid "Upload your key"
msgstr ""
#: src/gettext_strings.rs:34
msgid "Upload"
msgid "Your public key"
msgstr ""
#: src/gettext_strings.rs:35
msgid "Need more info? Check our <a target=\"_blank\" href=\"/about\">intro</a> and <a target=\"_blank\" href=\"/about/usage\">usage guide</a>!"
msgid "Upload"
msgstr ""
#: src/gettext_strings.rs:36
msgid "You uploaded the key <span class=\"fingerprint\"><a href=\"{{ key_link }}\" target=\"_blank\">{{ key_fpr }}</a></span>."
msgid "Need more info? Check our <a target=\"_blank\" href=\"/about\">intro</a> and <a target=\"_blank\" href=\"/about/usage\">usage guide</a>!"
msgstr ""
#: src/gettext_strings.rs:37
msgid "This key is revoked."
msgid "You uploaded the key <span class=\"fingerprint\"><a href=\"{{ key_link }}\" target=\"_blank\">{{ key_fpr }}</a></span>."
msgstr ""
#: src/gettext_strings.rs:38
msgid "It is published without identity information and can't be made available for search by e-mail address"
msgid "This key is revoked."
msgstr ""
#: src/gettext_strings.rs:39
msgid "what does this mean?"
msgid "It is published without identity information and can't be made available for search by e-mail address"
msgstr ""
#: src/gettext_strings.rs:40
msgid "This key is now published with the following identity information (<a href=\"/about\" target=\"_blank\">what does this mean?</a>):"
msgid "what does this mean?"
msgstr ""
#: src/gettext_strings.rs:41
msgid "Published"
msgid "This key is now published with the following identity information (<a href=\"/about\" target=\"_blank\">what does this mean?</a>):"
msgstr ""
#: src/gettext_strings.rs:42
msgid "This key is now published with only non-identity information (<a href=\"/about\" target=\"_blank\">what does this mean?</a>)"
msgid "Published"
msgstr ""
#: src/gettext_strings.rs:43
msgid "To make the key available for search by e-mail address, you can verify it belongs to you:"
msgid "This key is now published with only non-identity information (<a href=\"/about\" target=\"_blank\">what does this mean?</a>)"
msgstr ""
#: src/gettext_strings.rs:44
msgid "Verification Pending"
msgid "To make the key available for search by e-mail address, you can verify it belongs to you:"
msgstr ""
#: src/gettext_strings.rs:45
msgid "<strong>Note:</strong> Some providers delay e-mails for up to 15 minutes to prevent spam. Please be patient."
msgid "Verification Pending"
msgstr ""
#: src/gettext_strings.rs:46
msgid "Send Verification Mail"
msgid "<strong>Note:</strong> Some providers delay e-mails for up to 15 minutes to prevent spam. Please be patient."
msgstr ""
#: src/gettext_strings.rs:47
msgid "This key contains one identity that could not be parsed as an email address.<br /> This identity can't be published on <span class=\"brand\">keys.openpgp.org</span>. (<a href=\"/about/faq#non-email-uids\" target=\"_blank\">why?</a>)"
msgid "Send Verification Mail"
msgstr ""
#: src/gettext_strings.rs:48
msgid "This key contains {{ count_unparsed }} identities that could not be parsed as an email address.<br /> These identities can't be published on <span class=\"brand\">keys.openpgp.org</span>. (<a href=\"/about/faq#non-email-uids\" target=\"_blank\">why?</a>)"
msgid "This key contains one identity that could not be parsed as an email address.<br /> This identity can't be published on <span class=\"brand\">keys.openpgp.org</span>. (<a href=\"/about/faq#non-email-uids\" target=\"_blank\">why?</a>)"
msgstr ""
#: src/gettext_strings.rs:49
msgid "This key contains one revoked identity, which is not published. (<a href=\"/about/faq#revoked-uids\" target=\"_blank\">Why?</a>)"
msgid "This key contains {{ count_unparsed }} identities that could not be parsed as an email address.<br /> These identities can't be published on <span class=\"brand\">keys.openpgp.org</span>. (<a href=\"/about/faq#non-email-uids\" target=\"_blank\">why?</a>)"
msgstr ""
#: src/gettext_strings.rs:50
msgid "This key contains {{ count_revoked }} revoked identities, which are not published. (<a href=\"/about/faq#revoked-uids\" target=\"_blank\">Why?</a>)"
msgid "This key contains one revoked identity, which is not published. (<a href=\"/about/faq#revoked-uids\" target=\"_blank\">Why?</a>)"
msgstr ""
#: src/gettext_strings.rs:51
msgid "Your keys have been successfully uploaded:"
msgid "This key contains {{ count_revoked }} revoked identities, which are not published. (<a href=\"/about/faq#revoked-uids\" target=\"_blank\">Why?</a>)"
msgstr ""
#: src/gettext_strings.rs:52
msgid "<strong>Note:</strong> To make keys searchable by address, you must upload them individually."
msgid "Your keys have been successfully uploaded:"
msgstr ""
#: src/gettext_strings.rs:53
msgid "Verifying your email address…"
msgid "<strong>Note:</strong> To make keys searchable by address, you must upload them individually."
msgstr ""
#: src/gettext_strings.rs:54
msgid "Verifying your email address…"
msgstr ""
#: src/gettext_strings.rs:55
msgid "If the process doesn't complete after a few seconds, <input type=\"submit\" class=\"textbutton\" value=\"click here\" />."
msgstr ""
#: src/gettext_strings.rs:56
#: src/gettext_strings.rs:57
msgid "Manage your key on {{domain}}"
msgstr ""
#: src/gettext_strings.rs:58
#: src/gettext_strings.rs:59
msgid "Hi,"
msgstr ""
#: src/gettext_strings.rs:59
#: src/gettext_strings.rs:60
msgid "this is an automated message from <a rel=\"nofollow\" href=\"{{ base_uri }}\" style=\"text-decoration:none; color: #333\"><tt>{{ domain }}</tt></a>."
msgstr ""
#: src/gettext_strings.rs:60
#: src/gettext_strings.rs:61
msgid "If you didn't request this message, please ignore it."
msgstr ""
#: src/gettext_strings.rs:61
#: src/gettext_strings.rs:62
msgid "OpenPGP key: <tt>{{ primary_fp }}</tt>"
msgstr ""
#: src/gettext_strings.rs:62
#: src/gettext_strings.rs:63
msgid "To manage and delete listed addresses on this key, please follow the link below:"
msgstr ""
#: src/gettext_strings.rs:63
#: src/gettext_strings.rs:64
msgid "You can find more info at <a href=\"{{ base_uri }}/about\">{{ domain }}/about</a>."
msgstr ""
#: src/gettext_strings.rs:64
#: src/gettext_strings.rs:65
msgid "Greetings from the <a rel=\"nofollow\" href=\"{{ base_uri }}\" style=\"text-decoration:none; color: #333\"><tt>keys.openpgp.org</tt></a> team"
msgstr ""
#: src/gettext_strings.rs:67
#: src/gettext_strings.rs:68
msgid "this is an automated message from {{domain}}. If you didn't\nrequest this message, please ignore it."
msgstr ""
#: src/gettext_strings.rs:68
#: src/gettext_strings.rs:69
msgid "OpenPGP key: {{primary_fp}}"
msgstr ""
#: src/gettext_strings.rs:69
#: src/gettext_strings.rs:70
msgid "To manage and delete listed addresses on this key, please follow\nthe link below:"
msgstr ""
#: src/gettext_strings.rs:70
#: src/gettext_strings.rs:71
msgid "You can find more info at {{base_uri}}/about"
msgstr ""
#: src/gettext_strings.rs:71
#: src/gettext_strings.rs:72
msgid "Greetings from the keys.openpgp.org team"
msgstr ""
#: src/gettext_strings.rs:73
#: src/gettext_strings.rs:74
msgid "Verify {{userid}} for your key on {{domain}}"
msgstr ""
#: src/gettext_strings.rs:76
#: src/gettext_strings.rs:77
msgid "this is an automated message from <a rel=\"nofollow\" href=\"{{base_uri}}\" style=\"text-decoration:none; color: #333\"><tt>{{domain}}</tt></a>. If you didn't request this message, please ignore it."
msgstr ""
#: src/gettext_strings.rs:77
#: src/gettext_strings.rs:78
msgid "OpenPGP key: <tt>{{primary_fp}}</tt>"
msgstr ""
#: src/gettext_strings.rs:78
#: src/gettext_strings.rs:79
msgid "To let others find this key from your email address \"<a rel=\"nofollow\" href=\"#\" style=\"text-decoration:none; color: #333\">{{userid}}</a>\", please click the link below:"
msgstr ""
#: src/gettext_strings.rs:79
#: src/gettext_strings.rs:80
msgid "You can find more info at <a href=\"{{base_uri}}/about\">{{domain}}/about</a>."
msgstr ""
#: src/gettext_strings.rs:80
#: src/gettext_strings.rs:81
msgid "Greetings from the <a rel=\"nofollow\" href=\"{{base_uri}}\" style=\"text-decoration:none; color: #333\"><tt>keys.openpgp.org</tt></a> team"
msgstr ""
#: src/gettext_strings.rs:85
#: src/gettext_strings.rs:86
msgid "To let others find this key from your email address \"{{userid}}\",\nplease follow the link below:"
msgstr ""
#: src/gettext_strings.rs:89
#: src/gettext_strings.rs:90
msgid "Your key upload on {{domain}}"
msgstr ""
#: src/gettext_strings.rs:92
#: src/gettext_strings.rs:93
msgid "this is an automated message from <a rel=\"nofollow\" href=\"{{base_uri}}\" style=\"text-decoration:none; color: #333\"><tt>{{domain}}</tt></a>. If you didn't upload your key there, please ignore this message."
msgstr ""
#: src/gettext_strings.rs:94
#: src/gettext_strings.rs:95
msgid "This key was just uploaded for the first time, and is now published without identity information. If you want to allow others to find this key by e-mail address, please follow this link:"
msgstr ""
#: src/gettext_strings.rs:99
#: src/gettext_strings.rs:100
msgid "this is an automated message from {{domain}}. If you didn't upload your key\nthere, please ignore this message."
msgstr ""
#: src/gettext_strings.rs:101
#: src/gettext_strings.rs:102
msgid "This key was just uploaded for the first time, and is now published without\nidentity information. If you want to allow others to find this key by e-mail\naddress, please follow this link:"
msgstr ""
#: src/web/hkp.rs:144
msgid "Upload successful. This is a new key, a welcome mail has been sent!"
msgstr ""
#: src/web/hkp.rs:146
msgid "Upload successful. Note that identity information will only be published after verification! see {}/about/usage#gnupg-upload"
msgstr ""
#: src/web/manage.rs:103
msgid "This link is invalid or expired"
msgstr ""
#: src/web/manage.rs:129
msgid "Malformed address: {}"
msgstr ""
#: src/web/manage.rs:136
msgid "No key for address: {}"
msgstr ""
#: src/web/manage.rs:152
msgid "A request was already sent for this address recently."
msgstr ""
#: src/web/vks.rs:173
msgid "Something went wrong processing key {}"
msgstr ""
#: src/web/vks.rs:276
msgid "Invalid verification token!"
msgstr ""

View File

@ -5,6 +5,7 @@ fn _dummy() {
t!("Looks like something went wrong :(");
t!("<strong>Error:</strong> {{ internal_error }}");
t!("We found an entry for <span class=\"email\">{{ query }}</span>:");
t!("<strong>Hint:</strong> It's more convenient to use <span class=\"brand\">keys.openpgp.org</span> from your OpenPGP software.<br /> Take a look at our <a href=\"/about/usage\">usage guide</a> for details.");
t!("debug info");
t!("Search by Email Address / Key ID / Fingerprint");
t!("Search");
@ -24,7 +25,7 @@ fn _dummy() {
t!("Clicking \"delete\" on any address will remove it from this key. It will no longer appear in a search.<br /> To add another address, <a href=\"/upload\">upload</a> the key again.");
t!("Your key is published as only non-identity information. (<a href=\"/about\" target=\"_blank\">what does this mean?</a>)");
t!("To add an address, <a href=\"/upload\">upload</a> the key again.");
t!("We have sent an email with further instructions to <span class=\"email\">{{ address }}</span>");
t!("We have sent an email with further instructions to <span class=\"email\">{{ address }}</span>.");
t!("This address was already verified.");
t!("Your key <span class=\"fingerprint\">{{ key_fpr }}</span> is now published for the identity <a href=\"{{userid_link}}\" target=\"_blank\"><span class=\"email\">{{ userid }}</span></a>.");
t!("Verification failed! Perhaps the link you used was expired?");

View File

@ -7,6 +7,8 @@ use rocket::request::{self, Request, FromRequest};
use rocket::http::uri::Uri;
use rocket_i18n::I18n;
use gettext_macros::i18n;
use crate::database::{Database, Query, KeyDatabase};
use crate::database::types::{Email, Fingerprint, KeyID};
@ -116,10 +118,11 @@ pub fn pks_add_form_data(
db: rocket::State<KeyDatabase>,
tokens_stateless: rocket::State<tokens::Service>,
rate_limiter: rocket::State<RateLimiter>,
i18n: I18n,
cont_type: &ContentType,
data: Data,
) -> MyResponse {
match vks_web::process_post_form_data(db, tokens_stateless, rate_limiter, cont_type, data) {
match vks_web::process_post_form_data(db, tokens_stateless, rate_limiter, i18n, cont_type, data) {
Ok(_) => MyResponse::plain("Ok".into()),
Err(err) => MyResponse::ise(err),
}
@ -135,17 +138,17 @@ pub fn pks_add_form(
i18n: I18n,
data: Data,
) -> MyResponse {
match vks_web::process_post_form(db, tokens_stateless, rate_limiter, data) {
match vks_web::process_post_form(&db, &tokens_stateless, &rate_limiter, &i18n, data) {
Ok(UploadResponse::Ok { is_new_key, key_fpr, primary_uid, token, .. }) => {
let msg = if is_new_key && send_welcome_mail(&request_origin, &mail_service, &i18n, key_fpr, primary_uid, token) {
"Upload successful. This is a new key, a welcome mail has been sent!".to_owned()
i18n!(i18n.catalog, "Upload successful. This is a new key, a welcome mail has been sent!")
} else {
format!("Upload successful. Note that identity information will only be published after verification! see {}/about/usage#gnupg-upload", request_origin.get_base_uri())
i18n!(i18n.catalog, "Upload successful. Note that identity information will only be published after verification! see {}/about/usage#gnupg-upload"; request_origin.get_base_uri())
};
MyResponse::plain(msg)
}
Ok(_) => {
let msg = format!("Upload successful. Note that identity information will only be published after verification! see {}/about/usage#gnupg-upload", request_origin.get_base_uri());
let msg = i18n!(i18n.catalog, "Upload successful. Note that identity information will only be published after verification! see {}/about/usage#gnupg-upload"; request_origin.get_base_uri());
MyResponse::plain(msg)
}
Err(err) => MyResponse::ise(err),
@ -169,9 +172,11 @@ fn send_welcome_mail(
}
#[get("/pks/lookup")]
pub fn pks_lookup(state: rocket::State<HagridState>,
db: rocket::State<KeyDatabase>,
key: Hkp) -> MyResponse {
pub fn pks_lookup(
state: rocket::State<HagridState>,
db: rocket::State<KeyDatabase>,
key: Hkp
) -> MyResponse {
let (query, index) = match key {
Hkp::Fingerprint { fpr, index } =>
(Query::ByFingerprint(fpr), index),

View File

@ -1,7 +1,8 @@
use rocket::{Request, Data};
use rocket::fairing::{Fairing, Info, Kind};
use rocket_contrib::templates::Template;
use rocket::http::Method;
use rocket_contrib::templates::Template;
use rocket_i18n::I18n;
use std::fs;
use std::path::PathBuf;
@ -18,6 +19,7 @@ mod templates {
pub message: String,
pub commit: String,
pub version: String,
pub lang: String,
}
}
@ -93,11 +95,15 @@ pub fn maintenance_error_json(message: String) -> MyResponse {
}
#[get("/maintenance/web/<message>")]
pub fn maintenance_error_web(message: String) -> MyResponse {
pub fn maintenance_error_web(
message: String,
i18n: I18n,
) -> MyResponse {
let ctx = templates::MaintenanceMode{
message,
version: env!("VERGEN_SEMVER").to_string(),
commit: env!("VERGEN_SHA_SHORT").to_string(),
lang: i18n.lang.to_owned(),
};
MyResponse::Maintenance(Template::render("maintenance", ctx))
}

View File

@ -5,6 +5,8 @@ use rocket_i18n::I18n;
use failure::Fallible as Result;
use gettext_macros::i18n;
use crate::web::{RequestOrigin, MyResponse};
use crate::web::vks_web;
use crate::database::{Database, KeyDatabase, types::Email, types::Fingerprint};
@ -64,6 +66,7 @@ pub fn vks_manage() -> Result<MyResponse> {
pub fn vks_manage_key(
request_origin: RequestOrigin,
db: State<KeyDatabase>,
i18n: I18n,
token: String,
token_service: rocket::State<tokens::Service>,
) -> MyResponse {
@ -97,13 +100,13 @@ pub fn vks_manage_key(
},
Ok(None) => MyResponse::not_found(
Some("manage/manage"),
Some("This link is invalid or expired".to_owned())),
Some(i18n!(i18n.catalog, "This link is invalid or expired"))),
Err(e) => MyResponse::ise(e),
}
} else {
MyResponse::not_found(
Some("manage/manage"),
Some("This link is invalid or expired".to_owned()))
Some(i18n!(i18n.catalog, "This link is invalid or expired")))
}
}
@ -123,14 +126,14 @@ pub fn vks_manage_post(
Ok(email) => email,
Err(_) => return MyResponse::not_found(
Some("manage/manage"),
Some(format!("Malformed email address: {}", request.search_term)))
Some(i18n!(i18n.catalog, "Malformed address: {}"; request.search_term)))
};
let tpk = match db.lookup(&database::Query::ByEmail(email.clone())) {
Ok(Some(tpk)) => tpk,
Ok(None) => return MyResponse::not_found(
Some("manage/manage"),
Some(format!("No key for address {}", request.search_term))),
Some(i18n!(i18n.catalog, "No key for address: {}"; request.search_term))),
Err(e) => return MyResponse::ise(e),
};
@ -139,13 +142,14 @@ pub fn vks_manage_post(
.any(|candidate| candidate == email);
if !email_exists {
return MyResponse::ise(failure::err_msg("Address check failed!"));
return MyResponse::ise(
failure::err_msg("Internal error: address check failed!"));
}
if !rate_limiter.action_perform(format!("manage-{}", &email)) {
return MyResponse::not_found(
Some("manage/manage"),
Some("A request was already sent for this address recently.".to_owned()));
Some(i18n!(i18n.catalog, "A request was already sent for this address recently.")));
}
let fpr: Fingerprint = tpk.fingerprint().try_into().unwrap();
@ -168,10 +172,11 @@ pub fn vks_manage_post(
pub fn vks_manage_unpublish(
request_origin: RequestOrigin,
db: rocket::State<KeyDatabase>,
i18n: I18n,
token_service: rocket::State<tokens::Service>,
request: Form<forms::ManageDelete>,
) -> MyResponse {
match vks_manage_unpublish_or_fail(request_origin, db, token_service, request) {
match vks_manage_unpublish_or_fail(request_origin, db, token_service, i18n, request) {
Ok(response) => response,
Err(e) => MyResponse::ise(e),
}
@ -181,6 +186,7 @@ pub fn vks_manage_unpublish_or_fail(
request_origin: RequestOrigin,
db: rocket::State<KeyDatabase>,
token_service: rocket::State<tokens::Service>,
i18n: I18n,
request: Form<forms::ManageDelete>,
) -> Result<MyResponse> {
let verify_token = token_service.check::<StatelessVerifyToken>(&request.token)?;
@ -189,5 +195,5 @@ pub fn vks_manage_unpublish_or_fail(
db.set_email_unpublished(&verify_token.fpr, &email)?;
counters::inc_address_unpublished(&email);
Ok(vks_manage_key(request_origin, db, request.token.to_owned(), token_service))
Ok(vks_manage_key(request_origin, db, i18n, request.token.to_owned(), token_service))
}

View File

@ -9,6 +9,7 @@ use crate::rate_limiter::RateLimiter;
use crate::web::RequestOrigin;
use rocket_i18n::I18n;
use gettext_macros::i18n;
use sequoia_openpgp::TPK;
@ -92,6 +93,7 @@ impl StatelessSerializable for VerifyTpkState {
pub fn process_key(
db: &KeyDatabase,
i18n: &I18n,
tokens_stateless: &tokens::Service,
rate_limiter: &RateLimiter,
reader: impl Read,
@ -125,7 +127,7 @@ pub fn process_key(
match tpks.len() {
0 => UploadResponse::err("No key submitted"),
1 => process_key_single(db, tokens_stateless, rate_limiter, tpks.into_iter().next().unwrap()),
1 => process_key_single(db, i18n, tokens_stateless, rate_limiter, tpks.into_iter().next().unwrap()),
_ => process_key_multiple(db, tpks),
}
}
@ -157,6 +159,7 @@ fn process_key_multiple(
fn process_key_single(
db: &KeyDatabase,
i18n: &I18n,
tokens_stateless: &tokens::Service,
rate_limiter: &RateLimiter,
tpk: TPK,
@ -167,8 +170,8 @@ fn process_key_single(
Ok(ImportResult::New(tpk_status)) => (tpk_status, true),
Ok(ImportResult::Updated(tpk_status)) => (tpk_status, false),
Ok(ImportResult::Unchanged(tpk_status)) => (tpk_status, false),
Err(_) => return UploadResponse::err(&format!(
"Something went wrong processing key {}", fp)),
Err(_) => return UploadResponse::err(&i18n!(i18n.catalog,
"Something went wrong processing key {}"; fp)),
};
let verify_state = {
@ -263,12 +266,14 @@ fn send_verify_email(
pub fn verify_confirm(
db: rocket::State<KeyDatabase>,
i18n: &I18n,
token_service: rocket::State<StatefulTokens>,
token: String,
) -> response::PublishResponse {
let (fingerprint, email) = match check_publish_token(&db, &token_service, token) {
Ok(x) => x,
Err(_) => return PublishResponse::err("Invalid verification token!"),
Err(_) => return PublishResponse::err(
&i18n!(i18n.catalog, "Invalid verification token!")),
};
response::PublishResponse::Ok {

View File

@ -79,12 +79,13 @@ pub fn upload_json(
db: rocket::State<KeyDatabase>,
tokens_stateless: rocket::State<tokens::Service>,
rate_limiter: rocket::State<RateLimiter>,
i18n: I18n,
data: Result<Json<json::UploadRequest>, JsonError>,
) -> JsonResult {
let data = json_or_error(data)?;
use std::io::Cursor;
let data_reader = Cursor::new(data.keytext.as_bytes());
let result = vks::process_key(&db, &tokens_stateless, &rate_limiter, data_reader);
let result = vks::process_key(&db, &i18n, &tokens_stateless, &rate_limiter, data_reader);
upload_ok_json(result)
}

View File

@ -195,10 +195,11 @@ pub fn upload_post_form_data(
db: rocket::State<KeyDatabase>,
tokens_stateless: rocket::State<tokens::Service>,
rate_limiter: rocket::State<RateLimiter>,
i18n: I18n,
cont_type: &ContentType,
data: Data,
) -> MyResponse {
match process_post_form_data(db, tokens_stateless, rate_limiter, cont_type, data) {
match process_post_form_data(db, tokens_stateless, rate_limiter, i18n, cont_type, data) {
Ok(response) => MyResponse::upload_response(response),
Err(err) => MyResponse::bad_request("upload/upload", err),
}
@ -208,6 +209,7 @@ pub fn process_post_form_data(
db: rocket::State<KeyDatabase>,
tokens_stateless: rocket::State<tokens::Service>,
rate_limiter: rocket::State<RateLimiter>,
i18n: I18n,
cont_type: &ContentType,
data: Data,
) -> Result<UploadResponse> {
@ -218,7 +220,7 @@ pub fn process_post_form_data(
.ok_or_else(|| failure::err_msg("`Content-Type: multipart/form-data` \
boundary param not provided"))?;
process_upload(&db, &tokens_stateless, &rate_limiter, data, boundary)
process_upload(&db, &tokens_stateless, &rate_limiter, &i18n, data, boundary)
}
#[get("/search?<q>")]
@ -257,6 +259,7 @@ pub fn quick_upload(
db: rocket::State<KeyDatabase>,
tokens_stateless: rocket::State<tokens::Service>,
rate_limiter: rocket::State<RateLimiter>,
i18n: I18n,
request_origin: RequestOrigin,
data: Data,
) -> MyResponse {
@ -267,11 +270,14 @@ pub fn quick_upload(
return MyResponse::bad_request("400-plain", failure::err_msg(error));
}
MyResponse::upload_response_quick(vks::process_key(
&db,
&tokens_stateless,
&rate_limiter,
Cursor::new(buf)), request_origin.get_base_uri())
MyResponse::upload_response_quick(
vks::process_key(
&db,
&i18n,
&tokens_stateless,
&rate_limiter,
Cursor::new(buf)
), request_origin.get_base_uri())
}
#[get("/upload/<token>", rank = 2)]
@ -297,18 +303,20 @@ pub fn upload_post_form(
db: rocket::State<KeyDatabase>,
tokens_stateless: rocket::State<tokens::Service>,
rate_limiter: rocket::State<RateLimiter>,
i18n: I18n,
data: Data,
) -> MyResponse {
match process_post_form(db, tokens_stateless, rate_limiter, data) {
match process_post_form(&db, &tokens_stateless, &rate_limiter, &i18n, data) {
Ok(response) => MyResponse::upload_response(response),
Err(err) => MyResponse::bad_request("upload/upload", err),
}
}
pub fn process_post_form(
db: rocket::State<KeyDatabase>,
tokens_stateless: rocket::State<tokens::Service>,
rate_limiter: rocket::State<RateLimiter>,
db: &KeyDatabase,
tokens_stateless: &tokens::Service,
rate_limiter: &RateLimiter,
i18n: &I18n,
data: Data,
) -> Result<UploadResponse> {
use rocket::request::FormItems;
@ -331,6 +339,7 @@ pub fn process_post_form(
"keytext" => {
return Ok(vks::process_key(
&db,
&i18n,
&tokens_stateless,
&rate_limiter,
Cursor::new(decoded_value.as_bytes())
@ -348,6 +357,7 @@ fn process_upload(
db: &KeyDatabase,
tokens_stateless: &tokens::Service,
rate_limiter: &RateLimiter,
i18n: &I18n,
data: Data,
boundary: &str,
) -> Result<UploadResponse> {
@ -356,10 +366,10 @@ fn process_upload(
// how the files are saved; Multipart would be a good impl candidate though
match Multipart::with_body(data.open().take(UPLOAD_LIMIT), boundary).save().temp() {
Full(entries) => {
process_multipart(db, tokens_stateless, rate_limiter, entries)
process_multipart(db, tokens_stateless, rate_limiter, i18n, entries)
}
Partial(partial, _) => {
process_multipart(db, tokens_stateless, rate_limiter, partial.entries)
process_multipart(db, tokens_stateless, rate_limiter, i18n, partial.entries)
}
Error(err) => Err(err.into())
}
@ -369,12 +379,13 @@ fn process_multipart(
db: &KeyDatabase,
tokens_stateless: &tokens::Service,
rate_limiter: &RateLimiter,
i18n: &I18n,
entries: Entries,
) -> Result<UploadResponse> {
match entries.fields.get("keytext") {
Some(ent) if ent.len() == 1 => {
let reader = ent[0].data.readable()?;
Ok(vks::process_key(db, tokens_stateless, rate_limiter, reader))
Ok(vks::process_key(db, i18n, tokens_stateless, rate_limiter, reader))
}
Some(_) => Err(failure::err_msg("Multiple keytexts found")),
None => Err(failure::err_msg("No keytext found")),
@ -422,10 +433,11 @@ pub fn verify_confirm(
db: rocket::State<KeyDatabase>,
token_service: rocket::State<StatefulTokens>,
rate_limiter: rocket::State<RateLimiter>,
i18n: I18n,
token: String,
) -> MyResponse {
let rate_limit_id = format!("verify-token-{}", &token);
match vks::verify_confirm(db, token_service, token) {
match vks::verify_confirm(db, &i18n, token_service, token) {
PublishResponse::Ok { fingerprint, email } => {
rate_limiter.action_perform(rate_limit_id);
let userid_link = uri!(search: &email).to_string();