aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--locale/de/LC_MESSAGES/bitcoin.mobin21572 -> 24800 bytes
-rw-r--r--locale/de/LC_MESSAGES/bitcoin.po994
-rw-r--r--locale/nl/LC_MESSAGES/bitcoin.po2
-rw-r--r--locale/pl/LC_MESSAGES/bitcoin.po528
-rw-r--r--locale/ru/LC_MESSAGES/bitcoin.mobin25721 -> 25742 bytes
-rw-r--r--locale/ru/LC_MESSAGES/bitcoin.po6
-rw-r--r--share/uiproject.fbp2
-rw-r--r--src/base58.h171
-rw-r--r--src/db.cpp8
-rw-r--r--src/init.cpp4
-rw-r--r--src/key.h5
-rw-r--r--src/keystore.cpp60
-rw-r--r--src/keystore.h30
-rw-r--r--src/main.cpp9
-rw-r--r--src/main.h2
-rw-r--r--src/makefile.vc9
-rw-r--r--src/net.cpp25
-rw-r--r--src/net.h3
-rw-r--r--src/rpc.cpp176
-rw-r--r--src/script.cpp80
-rw-r--r--src/script.h31
-rw-r--r--src/ui.cpp84
-rw-r--r--src/uibase.cpp2
-rw-r--r--src/wallet.cpp65
-rw-r--r--src/wallet.h18
25 files changed, 1304 insertions, 1010 deletions
diff --git a/locale/de/LC_MESSAGES/bitcoin.mo b/locale/de/LC_MESSAGES/bitcoin.mo
index bcea1d3662..622661faf7 100644
--- a/locale/de/LC_MESSAGES/bitcoin.mo
+++ b/locale/de/LC_MESSAGES/bitcoin.mo
Binary files differ
diff --git a/locale/de/LC_MESSAGES/bitcoin.po b/locale/de/LC_MESSAGES/bitcoin.po
index a0519f0a2f..94ecc96926 100644
--- a/locale/de/LC_MESSAGES/bitcoin.po
+++ b/locale/de/LC_MESSAGES/bitcoin.po
@@ -3,128 +3,436 @@ msgid ""
msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2011-05-15 18:18+0100\n"
-"PO-Revision-Date: 2011-05-26 22:34+0100\n"
-"Last-Translator: Jakob Kramer <censored@gmail.com>\n"
+"POT-Creation-Date: 2011-07-17 02:21+0100\n"
+"PO-Revision-Date: 2011-07-17 02:54+0100\n"
+"Last-Translator: Michael Bemmerl <mail@mx-server.de>\n"
"Language-Team: German <translation-team-de@lists.sourceforge.net>\n"
-"Language: de\n"
"MIME-Version: 1.0\n"
"Content-Type: text/plain; charset=UTF-8\n"
"Content-Transfer-Encoding: 8bit\n"
+"Language: de\n"
"Plural-Forms: nplurals=2; plural=(n != 1);\n"
"X-Generator: Virtaal 0.6.1\n"
"X-Poedit-KeywordsList: _;gettext;gettext_noop\n"
"X-Poedit-Basepath: .\n"
"X-Poedit-SearchPath-0: ../../..\n"
-#: ../../../src/net.cpp:1499
+#: ../../../src/init.cpp:162
+msgid "Bitcoin version"
+msgstr "Bitcoin Version"
+
+#: ../../../src/init.cpp:163
+msgid "Usage:"
+msgstr "Verwendung:"
+
+#: ../../../src/init.cpp:165
+msgid "Send command to -server or bitcoind\n"
+msgstr "Sende Befehl zu -server oder bitcoind\n"
+
+#: ../../../src/init.cpp:166
+msgid "List commands\n"
+msgstr "Liste Befehle auf\n"
+
+#: ../../../src/init.cpp:167
+msgid "Get help for a command\n"
+msgstr "Hilfe für einen Befehl erhalten\n"
+
+#: ../../../src/init.cpp:168
+msgid "Options:\n"
+msgstr "Optionen:\n"
+
+#: ../../../src/init.cpp:169
+msgid "Specify configuration file (default: bitcoin.conf)\n"
+msgstr "Konfigurationsdatei bestimmen (Standard: bitcoin.conf)\n"
+
+#: ../../../src/init.cpp:170
+msgid "Specify pid file (default: bitcoind.pid)\n"
+msgstr "pid-Datei bestimmen (Standard: bitcoind.pid)\n"
+
+#: ../../../src/init.cpp:171
+msgid "Generate coins\n"
+msgstr "Münzen erzeugen\n"
+
+#: ../../../src/init.cpp:172
+msgid "Don't generate coins\n"
+msgstr "Keine Münzen erzeugen\n"
+
+#: ../../../src/init.cpp:173
+msgid "Start minimized\n"
+msgstr "Minimiert starten\n"
+
+#: ../../../src/init.cpp:174
+msgid "Specify data directory\n"
+msgstr "Datenverzeichnis festlegen\n"
+
+#: ../../../src/init.cpp:175
+msgid "Specify connection timeout (in milliseconds)\n"
+msgstr "Verbindungs-Timeout in Milisekunden\n"
+
+#: ../../../src/init.cpp:176
+msgid "Connect through socks4 proxy\n"
+msgstr "Socks4-Proxy verwenden\n"
+
+#: ../../../src/init.cpp:177
+msgid "Allow DNS lookups for addnode and connect\n"
+msgstr "DNS-Auflösung für addnode und connect erlauben\n"
+
+#: ../../../src/init.cpp:178
+msgid "Add a node to connect to\n"
+msgstr "Einen Teilnehmer hinzufügen, zu dem verbunden werden soll\n"
+
+#: ../../../src/init.cpp:179
+msgid "Connect only to the specified node\n"
+msgstr "Nur zu dem angegebenen Teilnehmer verbinden\n"
+
+#: ../../../src/init.cpp:180
+msgid "Don't accept connections from outside\n"
+msgstr "Akzeptiere keine externen Verbindungen\n"
+
+#: ../../../src/init.cpp:183
+msgid "Don't attempt to use UPnP to map the listening port\n"
+msgstr "Versuche nicht, UPnP zur Portweiterleitung zu nutzen\n"
+
+#: ../../../src/init.cpp:185
+msgid "Attempt to use UPnP to map the listening port\n"
+msgstr "Versuche, UPnP zur Portweiterleitung zu nutzen\n"
+
+#: ../../../src/init.cpp:188
+msgid "Fee per KB to add to transactions you send\n"
+msgstr "Gebühr pro KB für Überweisungen, die Sie tätigen\n"
+
+#: ../../../src/init.cpp:190
+msgid "Accept command line and JSON-RPC commands\n"
+msgstr "Akzeptiere Kommandozeile und JSON-RPC-Befehle\n"
+
+#: ../../../src/init.cpp:193
+msgid "Run in the background as a daemon and accept commands\n"
+msgstr "Laufe im Hintergrund als Daemon und akzeptiere Befehle\n"
+
+#: ../../../src/init.cpp:195
+msgid "Use the test network\n"
+msgstr "Nutze das Testnetzwerk\n"
+
+#: ../../../src/init.cpp:196
+msgid "Username for JSON-RPC connections\n"
+msgstr "Benutzername für JSON-RPC-Verbindungen\n"
+
+#: ../../../src/init.cpp:197
+msgid "Password for JSON-RPC connections\n"
+msgstr "Passwort für JSON-RPC-Verbindungen\n"
+
+#: ../../../src/init.cpp:198
+msgid "Listen for JSON-RPC connections on <port> (default: 8332)\n"
+msgstr "Horche für JSON-RPC-Verbindungen auf <port> (Standard: 8332)\n"
+
+#: ../../../src/init.cpp:199
+msgid "Allow JSON-RPC connections from specified IP address\n"
+msgstr "Erlaube JSON-RPC-Verbindungen von bestimmter IP-Adresse\n"
+
+#: ../../../src/init.cpp:200
+msgid "Send commands to node running on <ip> (default: 127.0.0.1)\n"
+msgstr "Sende Befehle zum Knoten mit <ip> (Standard: 127.0.0.1)\n"
+
+#: ../../../src/init.cpp:201
+msgid "Set key pool size to <n> (default: 100)\n"
+msgstr "Setze Key-Pool-Größe auf <n> (Standard: 100)\n"
+
+#: ../../../src/init.cpp:202
+msgid "Rescan the block chain for missing wallet transactions\n"
+msgstr "Frage die Block-Kette nach fehlenden Brieftaschen-Überweisungen ab\n"
+
+#: ../../../src/init.cpp:206
+msgid ""
+"\n"
+"SSL options: (see the Bitcoin Wiki for SSL setup instructions)\n"
+msgstr ""
+"\n"
+"SSL-Optionen: (siehe das Bitcoin-Wiki für SSL-Installationsanleitungen)\n"
+
+#: ../../../src/init.cpp:207
+msgid "Use OpenSSL (https) for JSON-RPC connections\n"
+msgstr "Nutze OpenSSL (https) für JSON-RPC-Verbindungen\n"
+
+#: ../../../src/init.cpp:208
+msgid "Server certificate file (default: server.cert)\n"
+msgstr "Server-Zertifikatsdatei (Standard: server.cert)\n"
+
+#: ../../../src/init.cpp:209
+msgid "Server private key (default: server.pem)\n"
+msgstr "Server-Geheimschlüssel (Standard: server.pem)\n"
+
+#: ../../../src/init.cpp:210
+msgid "Acceptable ciphers (default: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)\n"
+msgstr "Anzunehmende Verschlüsselungen (Standard: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)\n"
+
+#: ../../../src/init.cpp:214
+msgid "This help message\n"
+msgstr "Diese Anleitung\n"
+
+#: ../../../src/init.cpp:351
+#, c-format
+msgid "Cannot obtain a lock on data directory %s. Bitcoin is probably already running."
+msgstr "Erhalte keine Datensperre für das Datenverzeichnis %s. Bitcoin läuft wahrscheinlich bereits."
+
+#: ../../../src/init.cpp:377
+msgid "Error loading addr.dat \n"
+msgstr "Fehler beim Laden von addr.dat \n"
+
+#: ../../../src/init.cpp:383
+msgid "Error loading blkindex.dat \n"
+msgstr "Fehler beim Laden von blkindex.dat \n"
+
+#: ../../../src/init.cpp:394
+msgid "Error loading wallet.dat: Wallet corrupted \n"
+msgstr "Fehler beim Laden von wallet.dat: Brieftasche beschädigt \n"
+
+#: ../../../src/init.cpp:396
+msgid "Error loading wallet.dat: Wallet requires newer version of Bitcoin \n"
+msgstr "Fehler beim Laden von wallet.dat: Die Brieftasche benötigt eine neuere Version von Bitcoin \n"
+
+#: ../../../src/init.cpp:398
+msgid "Error loading wallet.dat \n"
+msgstr "Fehler beim Laden von wallet.dat \n"
+
+#: ../../../src/init.cpp:488
+msgid "Invalid -proxy address"
+msgstr "Ungültige -Proxy Adresse"
+
+#: ../../../src/init.cpp:513
+msgid "Invalid amount for -paytxfee=<amount>"
+msgstr "Ungültiger Betrag für -paytxfee=<amount>"
+
+#: ../../../src/init.cpp:517
+msgid "Warning: -paytxfee is set very high. This is the transaction fee you will pay if you send a transaction."
+msgstr "Warnung: -paytxfee ist sehr hoch gesetzt. Das ist die Überweisungsgebühr, die Sie für das Senden einer Überweisung zahlen."
+
+#: ../../../src/main.cpp:1430
+msgid "Warning: Disk space is low "
+msgstr "Warnung: Festplatte fast voll "
+
+#: ../../../src/net.cpp:1615
#, c-format
msgid "Unable to bind to port %d on this computer. Bitcoin is probably already running."
msgstr "Kann nicht zu Port %d auf diesem Computer verbinden. Bitcoin läuft wahrscheinlich bereits."
-#: ../../../src/ui.cpp:202
+#: ../../../src/rpc.cpp:2100
+#: ../../../src/rpc.cpp:2102
+#, c-format
+msgid "To use the %s option"
+msgstr "Um die %s-Option zu nutzen"
+
+#: ../../../src/rpc.cpp:2104
+#, c-format
+msgid ""
+"Warning: %s, you must set rpcpassword=<password>\n"
+"in the configuration file: %s\n"
+"If the file does not exist, create it with owner-readable-only file permissions.\n"
+msgstr ""
+"Warnung: %s, müssen Sie rpcpassword=<password>\n"
+"in der Konfigurationsdatei %s einstellen.\n"
+"Wenn die Datei nicht existiert, erstellen Sie sie mit ausschließlich Besitzer-Leserechten.\n"
+
+#: ../../../src/rpc.cpp:2277
+#, c-format
+msgid ""
+"You must set rpcpassword=<password> in the configuration file:\n"
+"%s\n"
+"If the file does not exist, create it with owner-readable-only file permissions."
+msgstr ""
+"Sie müssen rpcpassword=<password> in der Konfigurationsdatei\n"
+"\"%s\" einstellen.\n"
+"Wenn die Datei nicht existiert, erstellen Sie sie mit ausschließlich Besitzer-Leserechten."
+
+#: ../../../src/ui.cpp:216
#, c-format
msgid "This transaction is over the size limit. You can still send it for a fee of %s, which goes to the nodes that process your transaction and helps to support the network. Do you want to pay the fee?"
msgstr "Diese Überweisung übersteigt das Betragslimit. Sie können sie trotzdem tätigen, aber es wird eine Gebühr von %s erhoben, die an den Teilnehmer ausgeschüttet wird, der Ihre Überweisung bearbeitet und dadurch hilft, das Netzwerk am laufen zu halten. Möchten Sie die Gebühr entrichten?"
-#: ../../../src/ui.cpp:301
+#: ../../../src/ui.cpp:259
+#: ../../../src/ui.cpp:1246
+msgid "Enter the current passphrase to the wallet."
+msgstr "Geben Sie die derzeitige Passphrase der Brieftasche ein."
+
+# See http://dict.leo.org/forum/viewUnsolvedquery.php?idThread=465865&idForum=2&lp=ende&lang=de
+#: ../../../src/ui.cpp:260
+#: ../../../src/ui.cpp:1182
+#: ../../../src/ui.cpp:1199
+#: ../../../src/ui.cpp:1247
+#: ../../../src/ui.cpp:1273
+#: ../../../src/ui.cpp:1293
+msgid "Passphrase"
+msgstr "Passphrase"
+
+#: ../../../src/ui.cpp:266
+msgid "Please supply the current wallet decryption passphrase."
+msgstr "Bitte geben Sie die derzeitige Passphrase zur Entschlüsselung der Brieftasche an."
+
+#: ../../../src/ui.cpp:274
+#: ../../../src/ui.cpp:1258
+#: ../../../src/ui.cpp:1315
+msgid "The passphrase entered for the wallet decryption was incorrect."
+msgstr "Die eingegebene Passphrase zur Entschlüsselung der Brieftasche war inkorrekt."
+
+#: ../../../src/ui.cpp:351
msgid "Status"
msgstr "Status"
-#: ../../../src/ui.cpp:302
+#: ../../../src/ui.cpp:352
msgid "Date"
msgstr "Datum"
-#: ../../../src/ui.cpp:303
+#: ../../../src/ui.cpp:353
msgid "Description"
msgstr "Beschreibung"
-#: ../../../src/ui.cpp:304
+#: ../../../src/ui.cpp:354
msgid "Debit"
msgstr "Belastungen"
-#: ../../../src/ui.cpp:305
+#: ../../../src/ui.cpp:355
msgid "Credit"
msgstr "Gutschriften"
-#: ../../../src/ui.cpp:511
+#: ../../../src/ui.cpp:566
#, c-format
msgid "Open for %d blocks"
msgstr "Offen für %d Blöcke"
-#: ../../../src/ui.cpp:513
+#: ../../../src/ui.cpp:568
#, c-format
msgid "Open until %s"
msgstr "Offen bis %s"
-#: ../../../src/ui.cpp:519
+#: ../../../src/ui.cpp:574
#, c-format
msgid "%d/offline?"
msgstr "%d/Offline?"
-#: ../../../src/ui.cpp:521
+#: ../../../src/ui.cpp:576
#, c-format
msgid "%d/unconfirmed"
msgstr "%d/nicht bestätigt"
-#: ../../../src/ui.cpp:523
+#: ../../../src/ui.cpp:578
#, c-format
msgid "%d confirmations"
msgstr "%d Bestätigungen"
-#: ../../../src/ui.cpp:608
+#: ../../../src/ui.cpp:663
msgid "Generated"
msgstr "Erzeugt"
-#: ../../../src/ui.cpp:616
+#: ../../../src/ui.cpp:671
#, c-format
msgid "Generated (%s matures in %d more blocks)"
msgstr "Erzeugt (%s reifen nach %d weiteren Blöcken)"
-#: ../../../src/ui.cpp:620
+#: ../../../src/ui.cpp:675
msgid "Generated - Warning: This block was not received by any other nodes and will probably not be accepted!"
msgstr "Erzeugt - Warnung: Dieser Block wurde von keinem anderen Teilnehmer empfangen und wird wahrscheinlich nicht akzeptiert werden!"
-#: ../../../src/ui.cpp:624
+#: ../../../src/ui.cpp:679
msgid "Generated (not accepted)"
msgstr "Erzeugt (nicht akzeptiert)"
-#: ../../../src/ui.cpp:634
+#: ../../../src/ui.cpp:689
msgid "From: "
msgstr "Von: "
-#: ../../../src/ui.cpp:658
+#: ../../../src/ui.cpp:713
msgid "Received with: "
msgstr "Empfangen durch: "
-#: ../../../src/ui.cpp:704
+#: ../../../src/ui.cpp:759
msgid "Payment to yourself"
msgstr "Überweisung an Sie selbst"
-#: ../../../src/ui.cpp:738
+#: ../../../src/ui.cpp:793
msgid "To: "
msgstr "An: "
-#: ../../../src/ui.cpp:1053
+#: ../../../src/ui.cpp:1108
msgid " Generating"
msgstr " Erzeugen"
-#: ../../../src/ui.cpp:1055
+#: ../../../src/ui.cpp:1110
msgid "(not connected)"
msgstr "(nicht verbunden)"
-#: ../../../src/ui.cpp:1058
+#: ../../../src/ui.cpp:1113
#, c-format
msgid " %d connections %d blocks %d transactions"
msgstr " %d Verbindungen %d Blöcke %d Überweisungen"
-#: ../../../src/ui.cpp:1163
-#: ../../../src/ui.cpp:2527
+#: ../../../src/ui.cpp:1170
+msgid "Wallet already encrypted."
+msgstr "Brieftasche bereits verschlüsselt."
+
+#: ../../../src/ui.cpp:1181
+msgid ""
+"Enter the new passphrase to the wallet.\n"
+"Please use a passphrase of 10 or more random characters, or eight or more words."
+msgstr ""
+"Geben Sie die neue Passphrase der Brieftasche ein.\n"
+"Bitte benutzen Sie eine Passphrase mit zehn oder mehr zufällig gewählten Zeichen, oder acht oder mehr Wörter."
+
+#: ../../../src/ui.cpp:1188
+#: ../../../src/ui.cpp:1281
+msgid "Error: The supplied passphrase was too short."
+msgstr "Fehler: Die angegebene Passphrase war zu kurz. "
+
+#: ../../../src/ui.cpp:1192
+msgid ""
+"WARNING: If you encrypt your wallet and lose your passphrase, you will LOSE ALL OF YOUR BITCOINS!\n"
+"Are you sure you wish to encrypt your wallet?"
+msgstr ""
+"WARNUNG: Wenn Sie Ihre Brieftasche verschlüsseln und die Passphrase verlieren, werden Sie ALLE IHRE BITCOINS VERLIEREN!\n"
+"Sind Sie sicher, dass Sie Ihre Brieftasche verschlüsseln wollen?"
+
+#: ../../../src/ui.cpp:1198
+msgid "Please re-enter your new wallet passphrase."
+msgstr "Bitte geben Sie erneut Ihre neue Passphrase der Brieftasche ein."
+
+#: ../../../src/ui.cpp:1207
+#: ../../../src/ui.cpp:1303
+msgid "Error: the supplied passphrases didn't match."
+msgstr "Fehler: Die angegebenen Passphrasen stimmten nicht überein."
+
+#: ../../../src/ui.cpp:1217
+msgid "Wallet encryption failed."
+msgstr "Verschlüsselung der Brieftasche fehlgeschlagen."
+
+#: ../../../src/ui.cpp:1224
+msgid ""
+"Wallet Encrypted.\n"
+"Remember that encrypting your wallet cannot fully protect your bitcoins from being stolen by malware infecting your computer."
+msgstr ""
+"Brieftasche verschlüsselt.\n"
+"Beachten Sie, dass das Verschlüsseln der Brieftasche Ihre Bitcoins nicht völlig vor Diebstahl durch Schadprogramme auf Ihrem Computer schützt."
+
+#: ../../../src/ui.cpp:1235
+msgid "Wallet is unencrypted, please encrypt it first."
+msgstr "Die Brieftasche ist nicht verschlüsselt, bitte verschlüsselen Sie sie erst."
+
+#: ../../../src/ui.cpp:1272
+msgid "Enter the new passphrase for the wallet."
+msgstr "Geben Sie die neue Passphrase der Brieftasche ein."
+
+#: ../../../src/ui.cpp:1292
+msgid "Re-enter the new passphrase for the wallet."
+msgstr "Geben Sie erneut die neue Passphrase der Brieftasche ein."
+
+#: ../../../src/ui.cpp:1324
+msgid "Wallet Passphrase Changed."
+msgstr "Die Passphrase der Brieftasche wurde geändert."
+
+#: ../../../src/ui.cpp:1381
+#: ../../../src/ui.cpp:2816
msgid "New Receiving Address"
msgstr "&Neue Empfangs-Adresse"
-#: ../../../src/ui.cpp:1164
-#: ../../../src/ui.cpp:2528
+#: ../../../src/ui.cpp:1382
+#: ../../../src/ui.cpp:2817
msgid ""
"You should use a new address for each payment you receive.\n"
"\n"
@@ -134,248 +442,248 @@ msgstr ""
"\n"
"Beschreibung"
-#: ../../../src/ui.cpp:1233
+#: ../../../src/ui.cpp:1466
msgid "<b>Status:</b> "
msgstr "<b>Status:</b> "
-#: ../../../src/ui.cpp:1238
+#: ../../../src/ui.cpp:1471
msgid ", has not been successfully broadcast yet"
msgstr ", wurde noch nicht erfolgreich übertragen"
-#: ../../../src/ui.cpp:1240
+#: ../../../src/ui.cpp:1473
#, c-format
msgid ", broadcast through %d node"
msgstr ", durch %d Teilnehmer übertragen"
-#: ../../../src/ui.cpp:1242
+#: ../../../src/ui.cpp:1475
#, c-format
msgid ", broadcast through %d nodes"
msgstr ", durch %d Teilnehmer übertragen"
-#: ../../../src/ui.cpp:1246
+#: ../../../src/ui.cpp:1479
msgid "<b>Date:</b> "
msgstr "<b>Datum</b> "
-#: ../../../src/ui.cpp:1254
+#: ../../../src/ui.cpp:1487
msgid "<b>Source:</b> Generated<br>"
msgstr "<b>Quelle:</b> Erzeugt<br>"
-#: ../../../src/ui.cpp:1260
-#: ../../../src/ui.cpp:1278
+#: ../../../src/ui.cpp:1493
+#: ../../../src/ui.cpp:1511
msgid "<b>From:</b> "
msgstr "<b>Von:</b> "
-#: ../../../src/ui.cpp:1278
+#: ../../../src/ui.cpp:1511
msgid "unknown"
msgstr "Unbekannt"
-#: ../../../src/ui.cpp:1279
-#: ../../../src/ui.cpp:1303
-#: ../../../src/ui.cpp:1362
+#: ../../../src/ui.cpp:1512
+#: ../../../src/ui.cpp:1536
+#: ../../../src/ui.cpp:1595
msgid "<b>To:</b> "
msgstr "<b>An:</b> "
-#: ../../../src/ui.cpp:1282
+#: ../../../src/ui.cpp:1515
msgid " (yours, label: "
msgstr " (Eigene, Beschreibung: "
-#: ../../../src/ui.cpp:1284
+#: ../../../src/ui.cpp:1517
msgid " (yours)"
msgstr " (Eigene)"
-#: ../../../src/ui.cpp:1321
-#: ../../../src/ui.cpp:1333
-#: ../../../src/ui.cpp:1379
-#: ../../../src/ui.cpp:1396
+#: ../../../src/ui.cpp:1554
+#: ../../../src/ui.cpp:1566
+#: ../../../src/ui.cpp:1612
+#: ../../../src/ui.cpp:1629
msgid "<b>Credit:</b> "
msgstr "<b>Gutschrift:</b> "
-#: ../../../src/ui.cpp:1323
+#: ../../../src/ui.cpp:1556
#, c-format
msgid "(%s matures in %d more blocks)"
msgstr "(%s reifen nach %d weiteren Blöcken)"
-#: ../../../src/ui.cpp:1325
+#: ../../../src/ui.cpp:1558
msgid "(not accepted)"
msgstr "(nicht akzeptiert)"
-#: ../../../src/ui.cpp:1370
-#: ../../../src/ui.cpp:1378
-#: ../../../src/ui.cpp:1393
+#: ../../../src/ui.cpp:1603
+#: ../../../src/ui.cpp:1611
+#: ../../../src/ui.cpp:1626
msgid "<b>Debit:</b> "
msgstr "<b>Belastung:</b> "
-#: ../../../src/ui.cpp:1384
+#: ../../../src/ui.cpp:1617
msgid "<b>Transaction fee:</b> "
msgstr "<b>Überweisungsgebühr:</b> "
-#: ../../../src/ui.cpp:1400
+#: ../../../src/ui.cpp:1633
msgid "<b>Net amount:</b> "
msgstr "<b>Nettobetrag:</b> "
-#: ../../../src/ui.cpp:1407
+#: ../../../src/ui.cpp:1640
msgid "Message:"
msgstr "Nachricht:"
-#: ../../../src/ui.cpp:1409
+#: ../../../src/ui.cpp:1642
msgid "Comment:"
msgstr "Kommentar:"
-#: ../../../src/ui.cpp:1412
+#: ../../../src/ui.cpp:1645
msgid "Generated coins must wait 120 blocks before they can be spent. When you generated this block, it was broadcast to the network to be added to the block chain. If it fails to get into the chain, it will change to \"not accepted\" and not be spendable. This may occasionally happen if another node generates a block within a few seconds of yours."
msgstr "Erzeugte Münzen müssen 120 Blöcke lang reifen. Als Sie diesen Block erzeugt haben, wurde er an alle Teilnehmer übertragen, damit er zur Block-Kette hinzugefügt werden kann. Falls der Block es nicht in die Block-Kette schafft, wird die Beschreibung zu \"nicht akzeptiert\" geändert, und Sie können die Münzen nicht ausgeben. Dies kann manchmal passieren, wenn Sie und ein anderer Teilnehmer annähernd zeitgleich einen Block erzeugen."
-#: ../../../src/ui.cpp:1592
+#: ../../../src/ui.cpp:1825
msgid "Cannot write autostart/bitcoin.desktop file"
msgstr "Kann Datei autostart/bitcoin.desktop nicht schreiben"
-#: ../../../src/ui.cpp:1628
+#: ../../../src/ui.cpp:1861
msgid "Main"
msgstr "Haupt"
-#: ../../../src/ui.cpp:1636
+#: ../../../src/ui.cpp:1871
msgid "&Start Bitcoin on window system startup"
msgstr "Bitcoin beim &Systemstart ausführen"
-#: ../../../src/ui.cpp:1643
+#: ../../../src/ui.cpp:1878
msgid "&Minimize on close"
-msgstr "Beim schließen &Minimieren"
+msgstr "Beim Schließen &minimieren"
-#: ../../../src/ui.cpp:1785
+#: ../../../src/ui.cpp:2020
#, c-format
msgid "version %s"
-msgstr "version %s"
+msgstr "Version %s"
-#: ../../../src/ui.cpp:1897
+#: ../../../src/ui.cpp:2143
msgid "Error in amount "
msgstr "Fehler in Betrag "
-#: ../../../src/ui.cpp:1897
-#: ../../../src/ui.cpp:1902
-#: ../../../src/ui.cpp:1907
-#: ../../../src/ui.cpp:1942
-#: ../../../src/uibase.cpp:55
+#: ../../../src/ui.cpp:2143
+#: ../../../src/ui.cpp:2148
+#: ../../../src/ui.cpp:2153
+#: ../../../src/ui.cpp:2202
+#: ../../../src/uibase.cpp:61
msgid "Send Coins"
msgstr "Überweisen"
-#: ../../../src/ui.cpp:1902
+#: ../../../src/ui.cpp:2148
msgid "Amount exceeds your balance "
msgstr "Der Betrag übersteigt Ihr Guthaben "
-#: ../../../src/ui.cpp:1907
+#: ../../../src/ui.cpp:2153
msgid "Total exceeds your balance when the "
msgstr "Der Betrag übersteigt Ihr Guthaben, wenn man die "
-#: ../../../src/ui.cpp:1907
+#: ../../../src/ui.cpp:2153
msgid " transaction fee is included "
msgstr " Überweisungsgebühr berücksichtigt "
-#: ../../../src/ui.cpp:1925
+#: ../../../src/ui.cpp:2176
msgid "Payment sent "
msgstr "Zahlung überwiesen "
-#: ../../../src/ui.cpp:1925
-#: ../../../src/ui.cpp:1930
-#: ../../../src/ui.cpp:2074
-#: ../../../src/ui.cpp:2227
-#: ../../../src/main.cpp:3999
+#: ../../../src/ui.cpp:2176
+#: ../../../src/ui.cpp:2185
+#: ../../../src/ui.cpp:2336
+#: ../../../src/ui.cpp:2500
+#: ../../../src/wallet.cpp:1097
msgid "Sending..."
msgstr "Überweise ..."
-#: ../../../src/ui.cpp:1942
+#: ../../../src/ui.cpp:2202
msgid "Invalid address "
msgstr "Ungültige Adresse "
-#: ../../../src/ui.cpp:1995
+#: ../../../src/ui.cpp:2257
#, c-format
msgid "Sending %s to %s"
msgstr "Überweise %s an %s"
-#: ../../../src/ui.cpp:2068
-#: ../../../src/ui.cpp:2101
+#: ../../../src/ui.cpp:2330
+#: ../../../src/ui.cpp:2363
msgid "CANCELLED"
msgstr "ANNULLIERT"
-#: ../../../src/ui.cpp:2072
+#: ../../../src/ui.cpp:2334
msgid "Cancelled"
msgstr "Annulliert"
-#: ../../../src/ui.cpp:2074
+#: ../../../src/ui.cpp:2336
msgid "Transfer cancelled "
msgstr "Überweisung annulliert "
-#: ../../../src/ui.cpp:2127
+#: ../../../src/ui.cpp:2389
msgid "Error: "
msgstr "Fehler: "
-#: ../../../src/ui.cpp:2141
-#: ../../../src/ui.cpp:2212
-#: ../../../src/main.cpp:4018
+#: ../../../src/ui.cpp:2403
+#: ../../../src/ui.cpp:2474
+#: ../../../src/wallet.cpp:1116
msgid "Insufficient funds"
msgstr "Unzureichende Geldmittel"
-#: ../../../src/ui.cpp:2146
+#: ../../../src/ui.cpp:2408
msgid "Connecting..."
msgstr "Verbinde ..."
-#: ../../../src/ui.cpp:2151
+#: ../../../src/ui.cpp:2413
msgid "Unable to connect"
msgstr "Kann nicht verbinden"
-#: ../../../src/ui.cpp:2156
+#: ../../../src/ui.cpp:2418
msgid "Requesting public key..."
msgstr "Fordere öffentlichen Schlüssel an ..."
-#: ../../../src/ui.cpp:2168
+#: ../../../src/ui.cpp:2430
msgid "Received public key..."
msgstr "Öffentlicher Schlüssel empfangen ..."
-#: ../../../src/ui.cpp:2182
+#: ../../../src/ui.cpp:2444
msgid "Recipient is not accepting transactions sent by IP address"
msgstr "Empfänger akzeptiert keine Überweisungen von IP-Adressen"
-#: ../../../src/ui.cpp:2184
+#: ../../../src/ui.cpp:2446
msgid "Transfer was not accepted"
msgstr "Überweisung wurde nicht akzeptiert"
-#: ../../../src/ui.cpp:2193
+#: ../../../src/ui.cpp:2455
msgid "Invalid response received"
msgstr "Ungültige Antwort erhalten"
-#: ../../../src/ui.cpp:2208
+#: ../../../src/ui.cpp:2470
msgid "Creating transaction..."
msgstr "Erstelle Überweisung ..."
-#: ../../../src/ui.cpp:2220
+#: ../../../src/ui.cpp:2489
#, c-format
msgid "This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds"
msgstr "Diese Überweisung benötigt eine Überweisungsgebühr von mindestens %s wegen ihres Betrags, Komplexität oder der Benutzung kürzlich erhaltener Geldmittel"
-#: ../../../src/ui.cpp:2222
+#: ../../../src/ui.cpp:2491
msgid "Transaction creation failed"
msgstr "Überweisung konnte nicht erzeugt werden."
-#: ../../../src/ui.cpp:2229
+#: ../../../src/ui.cpp:2502
msgid "Transaction aborted"
msgstr "Überweisung abgebrochen"
-#: ../../../src/ui.cpp:2237
+#: ../../../src/ui.cpp:2510
msgid "Lost connection, transaction cancelled"
msgstr "Verbindung verloren, Überweisungsvorgang abgebrochen"
-#: ../../../src/ui.cpp:2253
+#: ../../../src/ui.cpp:2526
msgid "Sending payment..."
msgstr "Überweise Zahlung ..."
-#: ../../../src/ui.cpp:2259
+#: ../../../src/ui.cpp:2532
msgid "The transaction was rejected. This might happen if some of the coins in your wallet were already spent, such as if you used a copy of wallet.dat and coins were spent in the copy but not marked as spent here."
msgstr "Die Überweisung wurde abgelehnt. Das kann passieren, wenn einige der Münzen in Ihrer Brieftasche bereits ausgegeben wurden, z.B. weil Sie eine Kopie der Brieftasche (wallet.dat) gemacht haben. Bitcoins, die mithilfe der Kopie ausgegeben wurden, sind in dieser Brieftasche noch nicht als ausgegeben markiert worden."
-#: ../../../src/ui.cpp:2268
+#: ../../../src/ui.cpp:2541
msgid "Waiting for confirmation..."
msgstr "Warte auf Bestätigung ..."
-#: ../../../src/ui.cpp:2286
+#: ../../../src/ui.cpp:2559
msgid ""
"The payment was sent, but the recipient was unable to verify it.\n"
"The transaction is recorded and will credit to the recipient,\n"
@@ -383,304 +691,251 @@ msgid ""
msgstr ""
"Die Zahlung wurde überwiesen, aber der Empfänger konnte sie nicht bestätigen.\n"
"Die Überweisung wurde gespeichert und wird dem Empfänger gutgeschrieben,\n"
-"aber die begleitende Nachricht wird nicht ankommen."
+"aber die begleitende Nachricht wird leer sein."
-#: ../../../src/ui.cpp:2295
+#: ../../../src/ui.cpp:2568
msgid "Payment was sent, but an invalid response was received"
msgstr "Die Zahlung wurde überwiesen, aber die Antwort war fehlerhaft"
-#: ../../../src/ui.cpp:2301
+#: ../../../src/ui.cpp:2574
msgid "Payment completed"
msgstr "Zahlung ausgeführt"
-#: ../../../src/ui.cpp:2332
-#: ../../../src/ui.cpp:2478
-#: ../../../src/ui.cpp:2515
+#: ../../../src/ui.cpp:2616
+#: ../../../src/ui.cpp:2764
+#: ../../../src/ui.cpp:2804
msgid "Name"
msgstr "Name"
-#: ../../../src/ui.cpp:2333
-#: ../../../src/ui.cpp:2478
-#: ../../../src/ui.cpp:2515
+#: ../../../src/ui.cpp:2617
+#: ../../../src/ui.cpp:2764
+#: ../../../src/ui.cpp:2804
msgid "Address"
msgstr "Adresse"
-#: ../../../src/ui.cpp:2335
-#: ../../../src/ui.cpp:2490
+#: ../../../src/ui.cpp:2619
+#: ../../../src/ui.cpp:2776
msgid "Label"
msgstr "Beschreibung"
-#: ../../../src/ui.cpp:2336
-#: ../../../src/uibase.cpp:837
+#: ../../../src/ui.cpp:2620
+#: ../../../src/uibase.cpp:847
msgid "Bitcoin Address"
msgstr "Bitcoin-Adresse"
-#: ../../../src/ui.cpp:2460
+#: ../../../src/ui.cpp:2746
msgid "This is one of your own addresses for receiving payments and cannot be entered in the address book. "
msgstr "Dies ist eine Ihrer eigenen Adressen für den Zahlungseingang und kann deshalb nicht in das Adressbuch übernommen werden. "
-#: ../../../src/ui.cpp:2478
-#: ../../../src/ui.cpp:2484
+#: ../../../src/ui.cpp:2764
+#: ../../../src/ui.cpp:2770
msgid "Edit Address"
msgstr "Adresse bearbeiten"
-#: ../../../src/ui.cpp:2490
+#: ../../../src/ui.cpp:2776
msgid "Edit Address Label"
msgstr "Beschreibung der Adresse bearbeiten"
-#: ../../../src/ui.cpp:2515
-#: ../../../src/ui.cpp:2521
+#: ../../../src/ui.cpp:2804
+#: ../../../src/ui.cpp:2810
msgid "Add Address"
msgstr "Adresse hinzufügen"
-#: ../../../src/ui.cpp:2598
+#: ../../../src/ui.cpp:2898
msgid "Bitcoin"
msgstr "Bitcoin"
-#: ../../../src/ui.cpp:2600
+#: ../../../src/ui.cpp:2900
msgid "Bitcoin - Generating"
msgstr "Bitcoin - Erzeuge"
-#: ../../../src/ui.cpp:2602
+#: ../../../src/ui.cpp:2902
msgid "Bitcoin - (not connected)"
msgstr "Bitcoin - (nicht verbunden)"
-#: ../../../src/ui.cpp:2681
+#: ../../../src/ui.cpp:2981
msgid "&Open Bitcoin"
-msgstr "Bitcoin Ö&ffnen"
+msgstr "Bitcoin ö&ffnen"
-#: ../../../src/ui.cpp:2682
+#: ../../../src/ui.cpp:2982
msgid "&Send Bitcoins"
msgstr "Bitcoins &senden"
-#: ../../../src/ui.cpp:2683
+#: ../../../src/ui.cpp:2983
msgid "O&ptions..."
msgstr "O&ptionen ..."
-#: ../../../src/ui.cpp:2686
+#: ../../../src/ui.cpp:2986
#: ../../../src/uibase.cpp:25
msgid "E&xit"
msgstr "B&eenden"
-#: ../../../src/ui.cpp:2902
+#: ../../../src/ui.cpp:3212
msgid "Program has crashed and will terminate. "
msgstr "Das Programm ist abgestürzt und wird beendet. "
-#: ../../../src/main.cpp:1868
-msgid "Warning: Disk space is low "
-msgstr "Warnung: Festplatte fast voll "
-
-#: ../../../src/main.cpp:3992
-#, c-format
-msgid "Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds "
-msgstr "Fehler: Diese Überweisung benötigt eine Überweisungsgebühr von mindestens %s wegen ihrer Größe, Komplexität oder der Benutzung erst kürzlich erhaltener Geldmittel "
-
-#: ../../../src/main.cpp:3994
-msgid "Error: Transaction creation failed "
-msgstr "Fehler: Überweisung konnte nicht erzeugt werden. "
-
-#: ../../../src/main.cpp:4003
-msgid "Error: The transaction was rejected. This might happen if some of the coins in your wallet were already spent, such as if you used a copy of wallet.dat and coins were spent in the copy but not marked as spent here."
-msgstr "Fehler: Die Überweisung wurde abgelehnt. Das kann passieren, wenn einige der Münzen in Ihrer Brieftasche bereits ausgegeben wurden, z.B. weil Sie eine Kopie der Brieftasche (wallet.dat) gemacht haben. Bitcoins, die mithilfe der Kopie ausgegeben wurden, sind in dieser Brieftasche noch nicht als ausgegeben markiert worden."
-
-#: ../../../src/main.cpp:4016
-msgid "Invalid amount"
-msgstr "Ungültiger Betrag"
-
-#: ../../../src/main.cpp:4023
-msgid "Invalid bitcoin address"
-msgstr "Ungültige Bitcoin-Adresse"
-
-#: ../../../src/rpc.cpp:1800
-#: ../../../src/rpc.cpp:1802
-#, c-format
-msgid "To use the %s option"
-msgstr "Um die %s Option zu nutzen"
-
-#: ../../../src/rpc.cpp:1804
-#, c-format
-msgid ""
-"Warning: %s, you must set rpcpassword=<password>\n"
-"in the configuration file: %s\n"
-"If the file does not exist, create it with owner-readable-only file permissions.\n"
-msgstr ""
-"Warnung: %s, Sie müssen rpcpassword=<password> einstellen\n"
-"in der Konfigurationsdatei: %s\n"
-"Wenn die Datei nicht existiert, erstellen Sie sie mit ausschließlich Besitzer-Leserechten.\n"
-
-#: ../../../src/rpc.cpp:1972
-#, c-format
-msgid ""
-"You must set rpcpassword=<password> in the configuration file:\n"
-"%s\n"
-"If the file does not exist, create it with owner-readable-only file permissions."
-msgstr ""
-"Sie müssen rpcpassword=<password> in der Konfigurationsdatei einstellen:\n"
-"%s\n"
-"Wenn die Datei nicht existiert, erstellen Sie sie mit ausschließlich Besitzer-Leserechten."
-
-#: ../../../src/util.cpp:865
-msgid "Warning: Please check that your computer's date and time are correct. If your clock is wrong Bitcoin will not work properly."
-msgstr "Warnung: Bitte überprüfen Sie die Richtigkeit des Datums und der Uhrzeit Ihres Computers. Falls Ihre Uhr falsch läuft, wird Bitcoin nicht richtig funktionieren."
-
-#: ../../../src/util.cpp:898
-msgid "beta"
-msgstr "Beta"
-
#: ../../../src/uibase.cpp:28
msgid "&File"
msgstr "&Datei"
#: ../../../src/uibase.cpp:32
msgid "&Your Receiving Addresses..."
-msgstr "&Ihre Empfangs-Adressen ..."
+msgstr "&Ihre Empfangs-Adressen..."
+
+#: ../../../src/uibase.cpp:35
+msgid "&Encrypt Wallet..."
+msgstr "Bri&eftasche verschlüsseln..."
-#: ../../../src/uibase.cpp:36
+#: ../../../src/uibase.cpp:38
+msgid "&Change Wallet Encryption Passphrase..."
+msgstr "Passphrase der Vers&chlüsselung der Brieftasche ändern..."
+
+#: ../../../src/uibase.cpp:42
msgid "&Options..."
-msgstr "&Optionen ..."
+msgstr "&Optionen..."
-#: ../../../src/uibase.cpp:39
+#: ../../../src/uibase.cpp:45
msgid "&Settings"
msgstr "&Einstellungen"
-#: ../../../src/uibase.cpp:43
+#: ../../../src/uibase.cpp:49
msgid "&About..."
msgstr "Ü&ber..."
-#: ../../../src/uibase.cpp:46
+#: ../../../src/uibase.cpp:52
msgid "&Help"
msgstr "&Hilfe"
-#: ../../../src/uibase.cpp:56
+#: ../../../src/uibase.cpp:62
msgid "Address Book"
msgstr "Adressbuch"
-#: ../../../src/uibase.cpp:69
+#: ../../../src/uibase.cpp:75
msgid "Your Bitcoin Address:"
msgstr "Ihre Bitcoin-Adresse:"
-#: ../../../src/uibase.cpp:76
+#: ../../../src/uibase.cpp:82
msgid " &New... "
-msgstr " &Neu ... "
+msgstr " &Neu... "
-#: ../../../src/uibase.cpp:79
-#: ../../../src/uibase.cpp:780
-#: ../../../src/uibase.cpp:883
+#: ../../../src/uibase.cpp:85
+#: ../../../src/uibase.cpp:790
+#: ../../../src/uibase.cpp:893
msgid " &Copy to Clipboard "
msgstr " In die Zwischenablage &kopieren "
-#: ../../../src/uibase.cpp:93
+#: ../../../src/uibase.cpp:99
msgid "Balance:"
msgstr "Kontostand:"
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
msgid " All"
msgstr " Alle"
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
msgid " Sent"
msgstr " Überwiesen"
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
msgid " Received"
msgstr " Erhalten"
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
msgid " In Progress"
msgstr " In Bearbeitung"
-#: ../../../src/uibase.cpp:130
+#: ../../../src/uibase.cpp:136
msgid "All Transactions"
msgstr "Alle Überweisungen"
-#: ../../../src/uibase.cpp:141
+#: ../../../src/uibase.cpp:147
msgid "Sent/Received"
msgstr "Überwiesen/Erhalten"
-#: ../../../src/uibase.cpp:152
+#: ../../../src/uibase.cpp:158
msgid "Sent"
msgstr "Überwiesen"
-#: ../../../src/uibase.cpp:163
+#: ../../../src/uibase.cpp:169
msgid "Received"
msgstr "Erhalten"
-#: ../../../src/uibase.cpp:302
-#: ../../../src/uibase.cpp:443
-#: ../../../src/uibase.cpp:542
-#: ../../../src/uibase.cpp:722
-#: ../../../src/uibase.cpp:783
-#: ../../../src/uibase.cpp:892
-#: ../../../src/uibase.cpp:981
+#: ../../../src/uibase.cpp:312
+#: ../../../src/uibase.cpp:453
+#: ../../../src/uibase.cpp:552
+#: ../../../src/uibase.cpp:732
+#: ../../../src/uibase.cpp:793
+#: ../../../src/uibase.cpp:902
+#: ../../../src/uibase.cpp:991
msgid "OK"
msgstr "OK"
-#: ../../../src/uibase.cpp:345
+#: ../../../src/uibase.cpp:355
msgid "&Start Bitcoin on system startup"
msgstr "Bitcoin beim &Systemstart ausführen"
-#: ../../../src/uibase.cpp:348
+#: ../../../src/uibase.cpp:358
msgid "&Minimize to the tray instead of the taskbar"
msgstr "In den Infobereich statt in die Taskleiste &minimieren"
-#: ../../../src/uibase.cpp:351
+#: ../../../src/uibase.cpp:361
msgid "Map port using &UPnP"
msgstr "Portweiterleitung via &UPnP"
-#: ../../../src/uibase.cpp:354
+#: ../../../src/uibase.cpp:364
msgid "M&inimize to the tray on close"
msgstr "Beim Schließen in den Infobereich m&inimieren"
-#: ../../../src/uibase.cpp:360
+#: ../../../src/uibase.cpp:370
msgid "&Connect through socks4 proxy: "
msgstr "&Per Socks4-Proxy verbinden: "
-#: ../../../src/uibase.cpp:371
+#: ../../../src/uibase.cpp:381
msgid "Proxy &IP:"
-msgstr "Proxy &IP:"
+msgstr "Proxy-&IP:"
-#: ../../../src/uibase.cpp:379
+#: ../../../src/uibase.cpp:389
msgid " &Port:"
msgstr " &Port:"
-#: ../../../src/uibase.cpp:392
+#: ../../../src/uibase.cpp:402
msgid "Optional transaction fee per KB that helps make sure your transactions are processed quickly. Most transactions are 1KB. Fee 0.01 recommended."
msgstr "Eine freiwillige Überweisungsgebühr pro KB, die dabei hilft, dass Ihre Überweisungen schnell durchgeführt werden. Die meisten Überweisungen sind 1 KB groß. Eine Gebühr von 0,01 ist empfohlen."
-#: ../../../src/uibase.cpp:399
+#: ../../../src/uibase.cpp:409
msgid "Pay transaction fee:"
msgstr "Überweisungsgebühr:"
-#: ../../../src/uibase.cpp:420
+#: ../../../src/uibase.cpp:430
msgid "// [don't translate] Test panel 2 for future expansion"
msgstr ""
-#: ../../../src/uibase.cpp:424
+#: ../../../src/uibase.cpp:434
msgid "// [don't translate] Let's not start multiple pages until the first page is filled up"
msgstr ""
-#: ../../../src/uibase.cpp:446
-#: ../../../src/uibase.cpp:668
-#: ../../../src/uibase.cpp:727
-#: ../../../src/uibase.cpp:786
-#: ../../../src/uibase.cpp:895
-#: ../../../src/uibase.cpp:984
+#: ../../../src/uibase.cpp:456
+#: ../../../src/uibase.cpp:678
+#: ../../../src/uibase.cpp:737
+#: ../../../src/uibase.cpp:796
+#: ../../../src/uibase.cpp:905
+#: ../../../src/uibase.cpp:994
msgid "Cancel"
msgstr "Abbrechen"
-#: ../../../src/uibase.cpp:449
+#: ../../../src/uibase.cpp:459
msgid "&Apply"
msgstr "&Anwenden"
-#: ../../../src/uibase.cpp:508
+#: ../../../src/uibase.cpp:518
msgid "Bitcoin "
msgstr "Bitcoin "
-#: ../../../src/uibase.cpp:514
+#: ../../../src/uibase.cpp:524
msgid "version"
msgstr "Version"
-#: ../../../src/uibase.cpp:525
+#: ../../../src/uibase.cpp:535
msgid ""
"Copyright (c) 2009-2011 Bitcoin Developers\n"
"\n"
@@ -705,39 +960,39 @@ msgstr ""
"kryptographische Software von Eric Young (eay@cryptsoft.com)\n"
"und UPnP-Software, entwickelt von Thomas Bernard."
-#: ../../../src/uibase.cpp:581
+#: ../../../src/uibase.cpp:591
msgid "Enter a Bitcoin address (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)"
msgstr "Geben Sie eine Bitcoin-Adresse ein (z.B. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)"
-#: ../../../src/uibase.cpp:595
+#: ../../../src/uibase.cpp:605
msgid "Pay &To:"
msgstr "Überweisen &An:"
-#: ../../../src/uibase.cpp:610
+#: ../../../src/uibase.cpp:620
msgid "&Paste"
msgstr "&Einfügen"
-#: ../../../src/uibase.cpp:613
+#: ../../../src/uibase.cpp:623
msgid " Address &Book..."
msgstr " Address&buch..."
-#: ../../../src/uibase.cpp:620
+#: ../../../src/uibase.cpp:630
msgid "&Amount:"
msgstr "&Betrag:"
-#: ../../../src/uibase.cpp:630
+#: ../../../src/uibase.cpp:640
msgid "T&ransfer:"
msgstr "Ü&berweisung:"
-#: ../../../src/uibase.cpp:636
+#: ../../../src/uibase.cpp:646
msgid " Standard"
msgstr " Standard"
-#: ../../../src/uibase.cpp:663
+#: ../../../src/uibase.cpp:673
msgid "&Send"
msgstr "Ü&berweisen"
-#: ../../../src/uibase.cpp:711
+#: ../../../src/uibase.cpp:721
msgid ""
"\n"
"\n"
@@ -747,229 +1002,82 @@ msgstr ""
"\n"
"Verbinde ..."
-#: ../../../src/uibase.cpp:761
+#: ../../../src/uibase.cpp:771
msgid "These are your Bitcoin addresses for receiving payments. You may want to give a different one to each sender so you can keep track of who is paying you. The highlighted address is displayed in the main window."
msgstr "Dies sind Ihre Bitcoin-Adressen zum Empfang von Zahlungen. Sie sollten vielleicht jedem Überweisenden eine andere Adresse geben um nachvollziehen zu können von wem eine Zahlung stammt. Die markierte Adresse wird im Hauptfenster angezeigt."
-#: ../../../src/uibase.cpp:774
-#: ../../../src/uibase.cpp:886
+#: ../../../src/uibase.cpp:784
+#: ../../../src/uibase.cpp:896
msgid "&Edit..."
-msgstr "&Bearbeiten ..."
+msgstr "&Bearbeiten..."
-#: ../../../src/uibase.cpp:777
-#: ../../../src/uibase.cpp:889
+#: ../../../src/uibase.cpp:787
+#: ../../../src/uibase.cpp:899
msgid " &New Address... "
-msgstr " &Neue Adresse ... "
+msgstr " &Neue Adresse... "
-#: ../../../src/uibase.cpp:849
+#: ../../../src/uibase.cpp:859
msgid "Sending"
msgstr "Überweise"
-#: ../../../src/uibase.cpp:857
+#: ../../../src/uibase.cpp:867
msgid "These are your Bitcoin addresses for receiving payments. You can give a different one to each sender to keep track of who is paying you. The highlighted address will be displayed in the main window."
msgstr "Dies sind Ihre Bitcoin-Adressen zum Empfang von Zahlungen. Sie können jedem Überweisenden eine andere Adresse geben um nachvollziehen zu können von wem eine Zahlung stammt. Die markierte Adresse wird im Hauptfenster angezeigt."
-#: ../../../src/uibase.cpp:870
+#: ../../../src/uibase.cpp:880
msgid "Receiving"
msgstr "Empfange"
-#: ../../../src/uibase.cpp:880
+#: ../../../src/uibase.cpp:890
msgid "&Delete"
msgstr "&Löschen"
-#: ../../../src/init.cpp:147
-msgid "Bitcoin version"
-msgstr "Bitcoin "
-
-#: ../../../src/init.cpp:148
-msgid "Usage:"
-msgstr "Benutz:"
-
-#: ../../../src/init.cpp:150
-msgid "Send command to -server or bitcoind\n"
-msgstr "Sende Befehl zu -server oder bitcoind\n"
-
-#: ../../../src/init.cpp:151
-msgid "List commands\n"
-msgstr "Liste Befehle auf\n"
-
-#: ../../../src/init.cpp:152
-msgid "Get help for a command\n"
-msgstr "Hilfe für einen Befehl erhalten\n"
-
-#: ../../../src/init.cpp:153
-msgid "Options:\n"
-msgstr "Optionen:\n"
-
-#: ../../../src/init.cpp:154
-msgid "Specify configuration file (default: bitcoin.conf)\n"
-msgstr "Konfigurationsdatei bestimmen (Standard: bitcoin.conf)\n"
-
-#: ../../../src/init.cpp:155
-msgid "Specify pid file (default: bitcoind.pid)\n"
-msgstr "pid-Datei bestimmen (Standard: bitcoind.pid)\n"
-
-#: ../../../src/init.cpp:156
-msgid "Generate coins\n"
-msgstr "Münzen erzeugen\n"
-
-#: ../../../src/init.cpp:157
-msgid "Don't generate coins\n"
-msgstr "Keine Münzen erzeugen\n"
-
-#: ../../../src/init.cpp:158
-msgid "Start minimized\n"
-msgstr "Minimiert starten\n"
-
-#: ../../../src/init.cpp:159
-msgid "Specify data directory\n"
-msgstr "Datenverzeichnis festlegen\n"
-
-#: ../../../src/init.cpp:160
-msgid "Connect through socks4 proxy\n"
-msgstr "Socks4-Proxy verwenden\n"
-
-#: ../../../src/init.cpp:161
-msgid "Specify connection timeout (in milliseconds)\n"
-msgstr "Verbindungs-Timeout in Milisekunden\n"
-
-#: ../../../src/init.cpp:161
-msgid "Allow DNS lookups for addnode and connect\n"
-msgstr "DNS-Auflösung für addnode und connect erlauben\n"
-
-#: ../../../src/init.cpp:162
-msgid "Add a node to connect to\n"
-msgstr "Einen Teilnehmer hinzufügen, zu dem verbunden werden soll\n"
-
-#: ../../../src/init.cpp:163
-msgid "Connect only to the specified node\n"
-msgstr "Nur zu dem angegebenen Teilnehmer verbinden\n"
-
-#: ../../../src/init.cpp:164
-msgid "Don't accept connections from outside\n"
-msgstr "Akzeptiere keine externen Verbindungen\n"
-
-#: ../../../src/init.cpp:167
-msgid "Don't attempt to use UPnP to map the listening port\n"
-msgstr "Versuche nicht, UPnP zur Portweiterleitung zu nutzen\n"
-
-#: ../../../src/init.cpp:169
-msgid "Attempt to use UPnP to map the listening port\n"
-msgstr "Versuche, UPnP zur Portweiterleitung zu nutzen\n"
-
-#: ../../../src/init.cpp:172
-msgid "Fee per KB to add to transactions you send\n"
-msgstr "Gebühr pro KB für Überweisungen, die Sie tätigen\n"
-
-#: ../../../src/init.cpp:174
-msgid "Accept command line and JSON-RPC commands\n"
-msgstr "Akzeptiere Kommandozeile und JSON-RPC-Befehle\n"
-
-#: ../../../src/init.cpp:177
-msgid "Run in the background as a daemon and accept commands\n"
-msgstr "Laufe im Hintergrund als Daemon und akzeptiere Befehle\n"
-
-#: ../../../src/init.cpp:179
-msgid "Use the test network\n"
-msgstr "Nutze das Testnetzwerk\n"
-
-#: ../../../src/init.cpp:180
-msgid "Username for JSON-RPC connections\n"
-msgstr "Benutzername für JSON-RPC-Verbindungen\n"
-
-#: ../../../src/init.cpp:181
-msgid "Password for JSON-RPC connections\n"
-msgstr "Passwort für JSON-RPC-Verbindungen\n"
-
-#: ../../../src/init.cpp:182
-msgid "Listen for JSON-RPC connections on <port> (default: 8332)\n"
-msgstr "Horche für JSON-RPC-Verbindungen auf <port> (Standard: 8332)\n"
-
-#: ../../../src/init.cpp:183
-msgid "Allow JSON-RPC connections from specified IP address\n"
-msgstr "Erlaube JSON-RPC-Verbindungen von bestimmter IP-Adresse\n"
-
-#: ../../../src/init.cpp:184
-msgid "Send commands to node running on <ip> (default: 127.0.0.1)\n"
-msgstr "Sende Befehle zum Knoten mit <ip> (Standard: 127.0.0.1)\n"
-
-#: ../../../src/init.cpp:185
-msgid "Set key pool size to <n> (default: 100)\n"
-msgstr "Setze Key-Pool-Größe auf <n> (Standard: 100)\n"
-
-#: ../../../src/init.cpp:186
-msgid "Rescan the block chain for missing wallet transactions\n"
-msgstr "Frage die Block-Kette nach fehlenden Brieftaschen-Überweisungen ab\n"
-
-#: ../../../src/init.cpp:190
-msgid ""
-"\n"
-"SSL options: (see the Bitcoin Wiki for SSL setup instructions)\n"
-msgstr ""
-"\n"
-"SSL-Optionen: (siehe das Bitcoin-Wiki für SSL-Installationsanleitungen)\n"
-
-#: ../../../src/init.cpp:191
-msgid "Use OpenSSL (https) for JSON-RPC connections\n"
-msgstr "Nutze OpenSSL (https) für JSON-RPC-Verbindungen\n"
-
-#: ../../../src/init.cpp:192
-msgid "Server certificate file (default: server.cert)\n"
-msgstr "Server-Zertifikatsdatei (Standard: server.cert)\n"
-
-#: ../../../src/init.cpp:193
-msgid "Server private key (default: server.pem)\n"
-msgstr "Server-Geheimschlüssel (Standard: server.pem)\n"
+#: ../../../src/util.cpp:869
+msgid "Warning: Please check that your computer's date and time are correct. If your clock is wrong Bitcoin will not work properly."
+msgstr "Warnung: Bitte überprüfen Sie die Richtigkeit des Datums und der Uhrzeit Ihres Computers. Falls Ihre Uhr falsch läuft, wird Bitcoin nicht richtig funktionieren."
-#: ../../../src/init.cpp:194
-msgid "Acceptable ciphers (default: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)\n"
-msgstr "Anzunehmende Verschlüsselungen (Standard: TLSv1+HIGH:!SSLv2:!aNULL:!eNULL:!AH:!3DES:@STRENGTH)\n"
+#: ../../../src/util.cpp:903
+msgid "beta"
+msgstr "Beta"
-#: ../../../src/init.cpp:198
-msgid "This help message\n"
-msgstr "Diese Anleitung\n"
+#: ../../../src/wallet.cpp:1081
+msgid "Error: Wallet locked, unable to create transaction "
+msgstr "Fehler: Brieftasche ist verschlossen; Überweisung konnte nicht erstellt werden "
-#: ../../../src/init.cpp:335
+#: ../../../src/wallet.cpp:1089
#, c-format
-msgid "Cannot obtain a lock on data directory %s. Bitcoin is probably already running."
-msgstr "Erhalte keinen Lock für Datenverzeichnis %s. Bitcoin läuft wahrscheinlich bereits."
-
-#: ../../../src/init.cpp:361
-msgid "Error loading addr.dat \n"
-msgstr "Fehler beim Laden von addr.dat \n"
-
-#: ../../../src/init.cpp:367
-msgid "Error loading blkindex.dat \n"
-msgstr "Fehler beim Laden von blkindex.dat \n"
+msgid "Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds "
+msgstr "Fehler: Diese Überweisung benötigt eine Überweisungsgebühr von mindestens %s wegen ihrer Größe, Komplexität oder der Benutzung erst kürzlich erhaltener Geldmittel "
-#: ../../../src/init.cpp:374
-msgid "Error loading wallet.dat \n"
-msgstr "Fehler beim Laden von wallet.dat \n"
+#: ../../../src/wallet.cpp:1091
+msgid "Error: Transaction creation failed "
+msgstr "Fehler: Überweisung konnte nicht erzeugt werden. "
-#: ../../../src/init.cpp:454
-msgid "Invalid -proxy address"
-msgstr "Ungültige -Proxy Adresse"
+#: ../../../src/wallet.cpp:1101
+msgid "Error: The transaction was rejected. This might happen if some of the coins in your wallet were already spent, such as if you used a copy of wallet.dat and coins were spent in the copy but not marked as spent here."
+msgstr "Fehler: Die Überweisung wurde abgelehnt. Das kann passieren, wenn einige der Münzen in Ihrer Brieftasche bereits ausgegeben wurden, z.B. weil Sie eine Kopie der Brieftasche (wallet.dat) gemacht haben. Bitcoins, die mithilfe der Kopie ausgegeben wurden, sind in dieser Brieftasche noch nicht als ausgegeben markiert worden."
-#: ../../../src/init.cpp:477
-msgid "Invalid amount for -paytxfee=<amount>"
-msgstr "Ungültiger Betrag für -paytxfee=<amount>"
+#: ../../../src/wallet.cpp:1114
+msgid "Invalid amount"
+msgstr "Ungültiger Betrag"
-#: ../../../src/init.cpp:481
-msgid "Warning: -paytxfee is set very high. This is the transaction fee you will pay if you send a transaction."
-msgstr "Warnung: -paytxfee ist sehr hoch gesetzt. Das ist die Überweisungsgebühr, die Sie fürs Senden einer Überweisung zahlen."
+#: ../../../src/wallet.cpp:1121
+msgid "Invalid bitcoin address"
+msgstr "Ungültige Bitcoin-Adresse"
-#: ../../../src/uibase.h:147
+#: ../../../src/uibase.h:151
msgid "Transaction Details"
msgstr "Überweisungsdetails"
-#: ../../../src/uibase.h:199
+#: ../../../src/uibase.h:203
msgid "Options"
msgstr "Optionen"
-#: ../../../src/uibase.h:228
+#: ../../../src/uibase.h:232
msgid "About Bitcoin"
msgstr "Über Bitcoin"
-#: ../../../src/uibase.h:337
+#: ../../../src/uibase.h:341
msgid "Your Bitcoin Addresses"
msgstr "Ihre Bitcoin-Adressen"
+
diff --git a/locale/nl/LC_MESSAGES/bitcoin.po b/locale/nl/LC_MESSAGES/bitcoin.po
index 97216add99..986a1e5d98 100644
--- a/locale/nl/LC_MESSAGES/bitcoin.po
+++ b/locale/nl/LC_MESSAGES/bitcoin.po
@@ -448,7 +448,7 @@ msgstr "&Open Bitcoin"
#: ../../../src/ui.cpp:2682
msgid "&Send Bitcoins"
-msgstr "&Open Bitcoin"
+msgstr "&Verstuur Bitcoins"
#: ../../../src/ui.cpp:2683
msgid "O&ptions..."
diff --git a/locale/pl/LC_MESSAGES/bitcoin.po b/locale/pl/LC_MESSAGES/bitcoin.po
index ef6be0d9da..7c177b82de 100644
--- a/locale/pl/LC_MESSAGES/bitcoin.po
+++ b/locale/pl/LC_MESSAGES/bitcoin.po
@@ -2,7 +2,7 @@ msgid ""
msgstr ""
"Project-Id-Version: Bitcoin\n"
"Report-Msgid-Bugs-To: \n"
-"POT-Creation-Date: 2011-06-28 20:11+0100\n"
+"POT-Creation-Date: 2011-07-14 18:55+0100\n"
"PO-Revision-Date: \n"
"Last-Translator: Dawid Spiechowicz <spiechu@gmail.com>\n"
"Language-Team: Spiechu <spiechu@gmail.com>\n"
@@ -18,7 +18,7 @@ msgstr ""
"Plural-Forms: nplurals=3; plural=(n==1 ? 0 : n%10>=2 && n%10<=4 && (n%100<10 || n%100>=20) ? 1 : 2)\n"
"X-Poedit-SearchPath-0: ../../..\n"
-#: ../../../src/net.cpp:1590
+#: ../../../src/net.cpp:1615
#, c-format
msgid "Unable to bind to port %d on this computer. Bitcoin is probably already running."
msgstr "Nie można powiązać z portem %d tego komputera. Prawdopodobnie program Bitcoin jest już uruchomiony."
@@ -188,29 +188,37 @@ msgstr "Błąd ładowania addr.dat \n"
msgid "Error loading blkindex.dat \n"
msgstr "Błąd ładowania blkindex.dat \n"
-#: ../../../src/init.cpp:391
+#: ../../../src/init.cpp:394
+msgid "Error loading wallet.dat: Wallet corrupted \n"
+msgstr "Błąd ładowania wallet.dat: Portfel uszkodzony \n"
+
+#: ../../../src/init.cpp:396
+msgid "Error loading wallet.dat: Wallet requires newer version of Bitcoin \n"
+msgstr "Błąd ładowania wallet.dat: Portfel wymaga nowszej wersji Bitcoin \n"
+
+#: ../../../src/init.cpp:398
msgid "Error loading wallet.dat \n"
msgstr "Błąd ładowania wallet.dat \n"
-#: ../../../src/init.cpp:481
+#: ../../../src/init.cpp:488
msgid "Invalid -proxy address"
msgstr "Niewłaściwy adres -proxy"
-#: ../../../src/init.cpp:504
+#: ../../../src/init.cpp:513
msgid "Invalid amount for -paytxfee=<amount>"
msgstr "Nieprawidłowa kwota w -paytxfee=<amount>"
-#: ../../../src/init.cpp:508
+#: ../../../src/init.cpp:517
msgid "Warning: -paytxfee is set very high. This is the transaction fee you will pay if you send a transaction."
msgstr "Ostrzeżenie: ustawienie -paytxfee jest bardzo wysokie. To jest prowizja transakcji, którą zapłacisz jeżeli wyślesz transakcję."
-#: ../../../src/rpc.cpp:1822
-#: ../../../src/rpc.cpp:1824
+#: ../../../src/rpc.cpp:2100
+#: ../../../src/rpc.cpp:2102
#, c-format
msgid "To use the %s option"
msgstr "Użycie opcji %s"
-#: ../../../src/rpc.cpp:1826
+#: ../../../src/rpc.cpp:2104
#, c-format
msgid ""
"Warning: %s, you must set rpcpassword=<password>\n"
@@ -221,7 +229,7 @@ msgstr ""
"w pliku konfiguracyjnym: %s\n"
"Jeżeli plik nie istnieje, utwórz go z uprawnieniami tylko do odczytu dla właściciela.\n"
-#: ../../../src/rpc.cpp:1994
+#: ../../../src/rpc.cpp:2277
#, c-format
msgid ""
"You must set rpcpassword=<password> in the configuration file:\n"
@@ -232,11 +240,11 @@ msgstr ""
"%s\n"
"Jeżeli plik nie istnieje, utwórz go z uprawnieniami tylko do odczytu dla właściciela."
-#: ../../../src/util.cpp:874
+#: ../../../src/util.cpp:869
msgid "Warning: Please check that your computer's date and time are correct. If your clock is wrong Bitcoin will not work properly."
msgstr "Ostrzeżenie: Sprawdź czy ustawienia daty i czasu komputera są prawidłowe. Jeżeli zegar jest źle ustawiony, Bitcoin nie będzie poprawnie działał."
-#: ../../../src/util.cpp:908
+#: ../../../src/util.cpp:903
msgid "beta"
msgstr "beta"
@@ -245,104 +253,190 @@ msgstr "beta"
msgid "This transaction is over the size limit. You can still send it for a fee of %s, which goes to the nodes that process your transaction and helps to support the network. Do you want to pay the fee?"
msgstr "Ta transakcja jest poza limitem wielkości. W dalszym ciągu możesz wysłać ją z prowizją %s, która dotrze do węzłów przetwarzających twoją transakcję i pomoże utrzymać sieć. Chcesz zapłacić prowizję?"
-#: ../../../src/ui.cpp:316
+#: ../../../src/ui.cpp:259
+#: ../../../src/ui.cpp:1246
+msgid "Enter the current passphrase to the wallet."
+msgstr "Wpisz obecne hasło do portfela."
+
+#: ../../../src/ui.cpp:260
+#: ../../../src/ui.cpp:1182
+#: ../../../src/ui.cpp:1199
+#: ../../../src/ui.cpp:1247
+#: ../../../src/ui.cpp:1273
+#: ../../../src/ui.cpp:1293
+msgid "Passphrase"
+msgstr "Hasło"
+
+#: ../../../src/ui.cpp:266
+msgid "Please supply the current wallet decryption passphrase."
+msgstr "Proszę dostarczyć hasło do odszyfrowania portfela."
+
+#: ../../../src/ui.cpp:274
+#: ../../../src/ui.cpp:1258
+#: ../../../src/ui.cpp:1315
+msgid "The passphrase entered for the wallet decryption was incorrect."
+msgstr "Wpisane hasło do odszyfrowania portfela jest nieprawidłowe."
+
+#: ../../../src/ui.cpp:351
msgid "Status"
msgstr "Status"
-#: ../../../src/ui.cpp:317
+#: ../../../src/ui.cpp:352
msgid "Date"
msgstr "Data"
-#: ../../../src/ui.cpp:318
+#: ../../../src/ui.cpp:353
msgid "Description"
msgstr "Opis"
-#: ../../../src/ui.cpp:319
+#: ../../../src/ui.cpp:354
msgid "Debit"
msgstr "Obciążenie"
-#: ../../../src/ui.cpp:320
+#: ../../../src/ui.cpp:355
msgid "Credit"
msgstr "Suma"
-#: ../../../src/ui.cpp:526
+#: ../../../src/ui.cpp:566
#, c-format
msgid "Open for %d blocks"
msgstr "Otwórz na %d bloków"
-#: ../../../src/ui.cpp:528
+#: ../../../src/ui.cpp:568
#, c-format
msgid "Open until %s"
msgstr "Otwarte dopóki %s"
-#: ../../../src/ui.cpp:534
+#: ../../../src/ui.cpp:574
#, c-format
msgid "%d/offline?"
msgstr "%d/offline?"
-#: ../../../src/ui.cpp:536
+#: ../../../src/ui.cpp:576
#, c-format
msgid "%d/unconfirmed"
msgstr "%d/niepotwierdzono"
-#: ../../../src/ui.cpp:538
+#: ../../../src/ui.cpp:578
#, c-format
msgid "%d confirmations"
msgstr "%d potwierdzeń"
-#: ../../../src/ui.cpp:623
+#: ../../../src/ui.cpp:663
msgid "Generated"
msgstr "Wygenerowano"
-#: ../../../src/ui.cpp:631
+#: ../../../src/ui.cpp:671
#, c-format
msgid "Generated (%s matures in %d more blocks)"
msgstr "Wygenerowano (%s dojrzałych w %d więcej bloków)"
-#: ../../../src/ui.cpp:635
+#: ../../../src/ui.cpp:675
msgid "Generated - Warning: This block was not received by any other nodes and will probably not be accepted!"
msgstr "Wygenerowano - Ostrzeżenie: Ten blok nie został otrzymany przez żaden inny węzeł i prawdopodobnie nie zostanie zaakceptowany!"
-#: ../../../src/ui.cpp:639
+#: ../../../src/ui.cpp:679
msgid "Generated (not accepted)"
msgstr "Wygenerowano (nie zaakceptowano)"
-#: ../../../src/ui.cpp:649
+#: ../../../src/ui.cpp:689
msgid "From: "
msgstr "Od:"
-#: ../../../src/ui.cpp:673
+#: ../../../src/ui.cpp:713
msgid "Received with: "
msgstr "Otrzymano z:"
-#: ../../../src/ui.cpp:719
+#: ../../../src/ui.cpp:759
msgid "Payment to yourself"
msgstr "Płatność dla siebie samego"
-#: ../../../src/ui.cpp:753
+#: ../../../src/ui.cpp:793
msgid "To: "
msgstr "Do:"
-#: ../../../src/ui.cpp:1068
+#: ../../../src/ui.cpp:1108
msgid " Generating"
msgstr " Generowanie"
-#: ../../../src/ui.cpp:1070
+#: ../../../src/ui.cpp:1110
msgid "(not connected)"
msgstr "(nie połączony)"
-#: ../../../src/ui.cpp:1073
+#: ../../../src/ui.cpp:1113
#, c-format
msgid " %d connections %d blocks %d transactions"
msgstr " %d połączeń %d bloków %d transakcji"
-#: ../../../src/ui.cpp:1178
-#: ../../../src/ui.cpp:2571
+#: ../../../src/ui.cpp:1170
+msgid "Wallet already encrypted."
+msgstr "Portfel już zaszyfrowany."
+
+#: ../../../src/ui.cpp:1181
+msgid ""
+"Enter the new passphrase to the wallet.\n"
+"Please use a passphrase of 10 or more random characters, or eight or more words."
+msgstr ""
+"Wpisz nowe hasło dla portfela.\n"
+"Proszę użyć hasła składającego się z 10 lub więcej losowych znaków albo ośmiu lub więcej słów."
+
+#: ../../../src/ui.cpp:1188
+#: ../../../src/ui.cpp:1281
+msgid "Error: The supplied passphrase was too short."
+msgstr "Błąd: Dostarczone hasło jest za krótkie."
+
+#: ../../../src/ui.cpp:1192
+msgid ""
+"WARNING: If you encrypt your wallet and lose your passphrase, you will LOSE ALL OF YOUR BITCOINS!\n"
+"Are you sure you wish to encrypt your wallet?"
+msgstr ""
+"OSTRZEŻENIE: Jeżeli zaszyfrujesz swój portfel i zgubisz hasło, STRACISZ WSZYSTKIE SWOJE BITCOINY!\n"
+"Czy jesteś pewny, że chcesz zaszyfrować swój portfel?"
+
+#: ../../../src/ui.cpp:1198
+msgid "Please re-enter your new wallet passphrase."
+msgstr "Proszę powtórzyć nowe hasło do portfela."
+
+#: ../../../src/ui.cpp:1207
+#: ../../../src/ui.cpp:1303
+msgid "Error: the supplied passphrases didn't match."
+msgstr "Błąd: dostarczone hasła się nie zgadzają."
+
+#: ../../../src/ui.cpp:1217
+msgid "Wallet encryption failed."
+msgstr "Szyfrowanie portfela nie powiodło się."
+
+#: ../../../src/ui.cpp:1224
+msgid ""
+"Wallet Encrypted.\n"
+"Remember that encrypting your wallet cannot fully protect your bitcoins from being stolen by malware infecting your computer."
+msgstr ""
+"Portfel zaszyfrowany.\n"
+"Pamiętaj, że zaszyfrowanie portfela nie chroni w pełni twoich bitcoinów przed kradzieżą przeprowadzoną przez złośliwe oprogramowanie infekujące twój komputer."
+
+#: ../../../src/ui.cpp:1235
+msgid "Wallet is unencrypted, please encrypt it first."
+msgstr "Portfel jest niezaszyfrowany, proszę najpierw zaszyfrować."
+
+#: ../../../src/ui.cpp:1272
+msgid "Enter the new passphrase for the wallet."
+msgstr "Wprowadź nowe hasło dla portfela."
+
+#: ../../../src/ui.cpp:1292
+msgid "Re-enter the new passphrase for the wallet."
+msgstr "Powtórnie wprowadź nowe hasło dla portfela."
+
+#: ../../../src/ui.cpp:1324
+msgid "Wallet Passphrase Changed."
+msgstr "Hasło dla portfela zostało zmienione."
+
+#: ../../../src/ui.cpp:1381
+#: ../../../src/ui.cpp:2816
msgid "New Receiving Address"
msgstr "Nowy Adres Odbiorczy"
-#: ../../../src/ui.cpp:1179
-#: ../../../src/ui.cpp:2572
+#: ../../../src/ui.cpp:1382
+#: ../../../src/ui.cpp:2817
msgid ""
"You should use a new address for each payment you receive.\n"
"\n"
@@ -352,248 +446,248 @@ msgstr ""
"\n"
"Etykieta"
-#: ../../../src/ui.cpp:1251
+#: ../../../src/ui.cpp:1466
msgid "<b>Status:</b> "
msgstr "<b>Status:</b>"
-#: ../../../src/ui.cpp:1256
+#: ../../../src/ui.cpp:1471
msgid ", has not been successfully broadcast yet"
msgstr ", nie został jeszcze prawidłowo rozgłoszony"
-#: ../../../src/ui.cpp:1258
+#: ../../../src/ui.cpp:1473
#, c-format
msgid ", broadcast through %d node"
msgstr ", rozgłasza przez %d węzeł"
-#: ../../../src/ui.cpp:1260
+#: ../../../src/ui.cpp:1475
#, c-format
msgid ", broadcast through %d nodes"
msgstr ", rozgłasza przez %d węzłów"
-#: ../../../src/ui.cpp:1264
+#: ../../../src/ui.cpp:1479
msgid "<b>Date:</b> "
msgstr "<b>Data:</b>"
-#: ../../../src/ui.cpp:1272
+#: ../../../src/ui.cpp:1487
msgid "<b>Source:</b> Generated<br>"
msgstr "<b>Źródło:</b> Wygenerowano<br>"
-#: ../../../src/ui.cpp:1278
-#: ../../../src/ui.cpp:1296
+#: ../../../src/ui.cpp:1493
+#: ../../../src/ui.cpp:1511
msgid "<b>From:</b> "
msgstr "<b>Od:</b>"
-#: ../../../src/ui.cpp:1296
+#: ../../../src/ui.cpp:1511
msgid "unknown"
msgstr "nieznany"
-#: ../../../src/ui.cpp:1297
-#: ../../../src/ui.cpp:1321
-#: ../../../src/ui.cpp:1380
+#: ../../../src/ui.cpp:1512
+#: ../../../src/ui.cpp:1536
+#: ../../../src/ui.cpp:1595
msgid "<b>To:</b> "
msgstr "<b>Do:</b>"
-#: ../../../src/ui.cpp:1300
+#: ../../../src/ui.cpp:1515
msgid " (yours, label: "
msgstr " (twoja, etykieta: "
-#: ../../../src/ui.cpp:1302
+#: ../../../src/ui.cpp:1517
msgid " (yours)"
msgstr " (twoja)"
-#: ../../../src/ui.cpp:1339
-#: ../../../src/ui.cpp:1351
-#: ../../../src/ui.cpp:1397
-#: ../../../src/ui.cpp:1414
+#: ../../../src/ui.cpp:1554
+#: ../../../src/ui.cpp:1566
+#: ../../../src/ui.cpp:1612
+#: ../../../src/ui.cpp:1629
msgid "<b>Credit:</b> "
msgstr "<b>Suma:</b>"
-#: ../../../src/ui.cpp:1341
+#: ../../../src/ui.cpp:1556
#, c-format
msgid "(%s matures in %d more blocks)"
msgstr "(%s dojrzałych w %d więcej bloków)"
-#: ../../../src/ui.cpp:1343
+#: ../../../src/ui.cpp:1558
msgid "(not accepted)"
msgstr "(nie zaakceptowano)"
-#: ../../../src/ui.cpp:1388
-#: ../../../src/ui.cpp:1396
-#: ../../../src/ui.cpp:1411
+#: ../../../src/ui.cpp:1603
+#: ../../../src/ui.cpp:1611
+#: ../../../src/ui.cpp:1626
msgid "<b>Debit:</b> "
msgstr "<b>Obciążenie:</b>"
-#: ../../../src/ui.cpp:1402
+#: ../../../src/ui.cpp:1617
msgid "<b>Transaction fee:</b> "
msgstr "<b>Prowizja transakcji:</b>"
-#: ../../../src/ui.cpp:1418
+#: ../../../src/ui.cpp:1633
msgid "<b>Net amount:</b> "
msgstr "<b>Kwota netto:</b>"
-#: ../../../src/ui.cpp:1425
+#: ../../../src/ui.cpp:1640
msgid "Message:"
msgstr "Wiadomość:"
-#: ../../../src/ui.cpp:1427
+#: ../../../src/ui.cpp:1642
msgid "Comment:"
msgstr "Komentarz:"
-#: ../../../src/ui.cpp:1430
+#: ../../../src/ui.cpp:1645
msgid "Generated coins must wait 120 blocks before they can be spent. When you generated this block, it was broadcast to the network to be added to the block chain. If it fails to get into the chain, it will change to \"not accepted\" and not be spendable. This may occasionally happen if another node generates a block within a few seconds of yours."
msgstr "Wygenerowane monety muszą poczekać 120 bloków zanim mogą zostać wydane. Gdy wygenerowałeś ten blok, został rozgłoszony do sieci z przeznaczeniem do dodania do łańcucha bloków. Jeżeli nie uda się dodać bloku do łańcucha, zostanie oznaczony jako \"nie zaakceptowany\" i nie będzie mógł zostać wydany. Sporadycznie dzieje się tak jeżeli inny węzeł wygeneruje blok nie dalej niż kilka sekund od ciebie."
-#: ../../../src/ui.cpp:1610
+#: ../../../src/ui.cpp:1825
msgid "Cannot write autostart/bitcoin.desktop file"
msgstr "Nie mogę zapisać pliku autostart/bitcoin.desktop"
-#: ../../../src/ui.cpp:1646
+#: ../../../src/ui.cpp:1861
msgid "Main"
msgstr "Główne"
-#: ../../../src/ui.cpp:1656
+#: ../../../src/ui.cpp:1871
msgid "&Start Bitcoin on window system startup"
msgstr "&Uruchom Bitcoin przy starcie systemu"
-#: ../../../src/ui.cpp:1663
+#: ../../../src/ui.cpp:1878
msgid "&Minimize on close"
msgstr "&Minimalizuj przy zamknięciu"
-#: ../../../src/ui.cpp:1805
+#: ../../../src/ui.cpp:2020
#, c-format
msgid "version %s"
msgstr "wersja %s"
-#: ../../../src/ui.cpp:1928
+#: ../../../src/ui.cpp:2143
msgid "Error in amount "
msgstr "Nieprawidłowa kwota"
-#: ../../../src/ui.cpp:1928
-#: ../../../src/ui.cpp:1933
-#: ../../../src/ui.cpp:1938
-#: ../../../src/ui.cpp:1973
-#: ../../../src/uibase.cpp:55
+#: ../../../src/ui.cpp:2143
+#: ../../../src/ui.cpp:2148
+#: ../../../src/ui.cpp:2153
+#: ../../../src/ui.cpp:2202
+#: ../../../src/uibase.cpp:61
msgid "Send Coins"
msgstr "Wyślij Monety"
-#: ../../../src/ui.cpp:1933
+#: ../../../src/ui.cpp:2148
msgid "Amount exceeds your balance "
msgstr "Kwota przekracza twój stan konta"
-#: ../../../src/ui.cpp:1938
+#: ../../../src/ui.cpp:2153
msgid "Total exceeds your balance when the "
msgstr "Przekroczenie twojego stanu konta gdy"
-#: ../../../src/ui.cpp:1938
+#: ../../../src/ui.cpp:2153
msgid " transaction fee is included "
msgstr " prowizja jest wliczona"
-#: ../../../src/ui.cpp:1956
+#: ../../../src/ui.cpp:2176
msgid "Payment sent "
msgstr "Wysłano płatność"
-#: ../../../src/ui.cpp:1956
-#: ../../../src/ui.cpp:1961
-#: ../../../src/ui.cpp:2107
-#: ../../../src/ui.cpp:2260
-#: ../../../src/wallet.cpp:924
+#: ../../../src/ui.cpp:2176
+#: ../../../src/ui.cpp:2185
+#: ../../../src/ui.cpp:2336
+#: ../../../src/ui.cpp:2500
+#: ../../../src/wallet.cpp:1097
msgid "Sending..."
msgstr "Wysyłanie..."
-#: ../../../src/ui.cpp:1973
+#: ../../../src/ui.cpp:2202
msgid "Invalid address "
msgstr "Nieprawidłowy adres"
-#: ../../../src/ui.cpp:2028
+#: ../../../src/ui.cpp:2257
#, c-format
msgid "Sending %s to %s"
msgstr "Wysyłanie %s do %s"
-#: ../../../src/ui.cpp:2101
-#: ../../../src/ui.cpp:2134
+#: ../../../src/ui.cpp:2330
+#: ../../../src/ui.cpp:2363
msgid "CANCELLED"
msgstr "ANULOWANO"
-#: ../../../src/ui.cpp:2105
+#: ../../../src/ui.cpp:2334
msgid "Cancelled"
msgstr "Anulowano"
-#: ../../../src/ui.cpp:2107
+#: ../../../src/ui.cpp:2336
msgid "Transfer cancelled "
msgstr "Transfer anulowano"
-#: ../../../src/ui.cpp:2160
+#: ../../../src/ui.cpp:2389
msgid "Error: "
msgstr "Błąd:"
-#: ../../../src/ui.cpp:2174
-#: ../../../src/ui.cpp:2245
-#: ../../../src/wallet.cpp:943
+#: ../../../src/ui.cpp:2403
+#: ../../../src/ui.cpp:2474
+#: ../../../src/wallet.cpp:1116
msgid "Insufficient funds"
msgstr "Niewystarczające fundusze"
-#: ../../../src/ui.cpp:2179
+#: ../../../src/ui.cpp:2408
msgid "Connecting..."
msgstr "Łączenie..."
-#: ../../../src/ui.cpp:2184
+#: ../../../src/ui.cpp:2413
msgid "Unable to connect"
msgstr "Nie można połączyć"
-#: ../../../src/ui.cpp:2189
+#: ../../../src/ui.cpp:2418
msgid "Requesting public key..."
msgstr "Żądanie klucza publicznego..."
-#: ../../../src/ui.cpp:2201
+#: ../../../src/ui.cpp:2430
msgid "Received public key..."
msgstr "Otrzymano klucz publiczny..."
-#: ../../../src/ui.cpp:2215
+#: ../../../src/ui.cpp:2444
msgid "Recipient is not accepting transactions sent by IP address"
msgstr "Adresat nie akceptuje transakcji wysyłanych przez adres IP"
-#: ../../../src/ui.cpp:2217
+#: ../../../src/ui.cpp:2446
msgid "Transfer was not accepted"
msgstr "Transfer nie został zaakceptowany"
-#: ../../../src/ui.cpp:2226
+#: ../../../src/ui.cpp:2455
msgid "Invalid response received"
msgstr "Otrzymano niepoprawną odpowiedź"
-#: ../../../src/ui.cpp:2241
+#: ../../../src/ui.cpp:2470
msgid "Creating transaction..."
msgstr "Tworzenie transakcji..."
-#: ../../../src/ui.cpp:2253
+#: ../../../src/ui.cpp:2489
#, c-format
msgid "This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds"
msgstr "Ta transakcja wymaga prowizji co najmniej %s z uwagi na kwotę, złożoność lub użycie niedawno otrzymanych funduszy"
-#: ../../../src/ui.cpp:2255
+#: ../../../src/ui.cpp:2491
msgid "Transaction creation failed"
msgstr "Błąd tworzenia transakcji "
-#: ../../../src/ui.cpp:2262
+#: ../../../src/ui.cpp:2502
msgid "Transaction aborted"
msgstr "Transakcję przerwano"
-#: ../../../src/ui.cpp:2270
+#: ../../../src/ui.cpp:2510
msgid "Lost connection, transaction cancelled"
msgstr "Utracono połączenie, transakcja anulowana"
-#: ../../../src/ui.cpp:2286
+#: ../../../src/ui.cpp:2526
msgid "Sending payment..."
msgstr "Wysyłanie płatności..."
-#: ../../../src/ui.cpp:2292
+#: ../../../src/ui.cpp:2532
msgid "The transaction was rejected. This might happen if some of the coins in your wallet were already spent, such as if you used a copy of wallet.dat and coins were spent in the copy but not marked as spent here."
msgstr "Transakcja została odrzucona. Może się tak zdarzyć jeżeli część monet w twoim portfelu zostało wydanych, np. gdy użyto kopii pliku wallet.dat i monety zostały wydane w kopii, a tutaj nie zostały oznaczone jako wydane."
-#: ../../../src/ui.cpp:2301
+#: ../../../src/ui.cpp:2541
msgid "Waiting for confirmation..."
msgstr "Oczekiwanie na potwierdzenie..."
-#: ../../../src/ui.cpp:2319
+#: ../../../src/ui.cpp:2559
msgid ""
"The payment was sent, but the recipient was unable to verify it.\n"
"The transaction is recorded and will credit to the recipient,\n"
@@ -603,84 +697,84 @@ msgstr ""
"Transakcja została zarejestrowana i zostanie przypisana do odbiorcy,\n"
"ale informacja w komentarzu będzie pusta."
-#: ../../../src/ui.cpp:2328
+#: ../../../src/ui.cpp:2568
msgid "Payment was sent, but an invalid response was received"
msgstr "Płatność została wysłana, ale otrzymano nieprawidłową odpowiedź"
-#: ../../../src/ui.cpp:2334
+#: ../../../src/ui.cpp:2574
msgid "Payment completed"
msgstr "Płatność zakończona"
-#: ../../../src/ui.cpp:2376
-#: ../../../src/ui.cpp:2522
-#: ../../../src/ui.cpp:2559
+#: ../../../src/ui.cpp:2616
+#: ../../../src/ui.cpp:2764
+#: ../../../src/ui.cpp:2804
msgid "Name"
msgstr "Nazwa"
-#: ../../../src/ui.cpp:2377
-#: ../../../src/ui.cpp:2522
-#: ../../../src/ui.cpp:2559
+#: ../../../src/ui.cpp:2617
+#: ../../../src/ui.cpp:2764
+#: ../../../src/ui.cpp:2804
msgid "Address"
msgstr "Adres"
-#: ../../../src/ui.cpp:2379
-#: ../../../src/ui.cpp:2534
+#: ../../../src/ui.cpp:2619
+#: ../../../src/ui.cpp:2776
msgid "Label"
msgstr "Etykieta"
-#: ../../../src/ui.cpp:2380
-#: ../../../src/uibase.cpp:837
+#: ../../../src/ui.cpp:2620
+#: ../../../src/uibase.cpp:847
msgid "Bitcoin Address"
msgstr "Adres Bitcoin"
-#: ../../../src/ui.cpp:2504
+#: ../../../src/ui.cpp:2746
msgid "This is one of your own addresses for receiving payments and cannot be entered in the address book. "
msgstr "To jest jeden z twoich adresów na otrzymywane płatności i nie może zostać wpisany do księgi adresowej."
-#: ../../../src/ui.cpp:2522
-#: ../../../src/ui.cpp:2528
+#: ../../../src/ui.cpp:2764
+#: ../../../src/ui.cpp:2770
msgid "Edit Address"
msgstr "Edytuj Adres"
-#: ../../../src/ui.cpp:2534
+#: ../../../src/ui.cpp:2776
msgid "Edit Address Label"
msgstr "Edytuj Etykietę Adresu"
-#: ../../../src/ui.cpp:2559
-#: ../../../src/ui.cpp:2565
+#: ../../../src/ui.cpp:2804
+#: ../../../src/ui.cpp:2810
msgid "Add Address"
msgstr "Dodaj Adres"
-#: ../../../src/ui.cpp:2642
+#: ../../../src/ui.cpp:2898
msgid "Bitcoin"
msgstr "Bitcoin"
-#: ../../../src/ui.cpp:2644
+#: ../../../src/ui.cpp:2900
msgid "Bitcoin - Generating"
msgstr "Bitcoin - Generowanie"
-#: ../../../src/ui.cpp:2646
+#: ../../../src/ui.cpp:2902
msgid "Bitcoin - (not connected)"
msgstr "Bitcoin - (nie połączony)"
-#: ../../../src/ui.cpp:2725
+#: ../../../src/ui.cpp:2981
msgid "&Open Bitcoin"
msgstr "&Otwórz Bitcoin"
-#: ../../../src/ui.cpp:2726
+#: ../../../src/ui.cpp:2982
msgid "&Send Bitcoins"
msgstr "&Wyślij Bitcoiny"
-#: ../../../src/ui.cpp:2727
+#: ../../../src/ui.cpp:2983
msgid "O&ptions..."
msgstr "O&pcje..."
-#: ../../../src/ui.cpp:2730
+#: ../../../src/ui.cpp:2986
#: ../../../src/uibase.cpp:25
msgid "E&xit"
msgstr "W&yjście"
-#: ../../../src/ui.cpp:2956
+#: ../../../src/ui.cpp:3212
msgid "Program has crashed and will terminate. "
msgstr "Program uległ awarii i zostanie przerwany."
@@ -696,152 +790,160 @@ msgstr "&Plik"
msgid "&Your Receiving Addresses..."
msgstr "&Twój Adres Odbiorczy..."
-#: ../../../src/uibase.cpp:36
+#: ../../../src/uibase.cpp:35
+msgid "&Encrypt Wallet..."
+msgstr "&Zaszyfruj portfel..."
+
+#: ../../../src/uibase.cpp:38
+msgid "&Change Wallet Encryption Passphrase..."
+msgstr "&Zmień hasło szyfrowania portfela..."
+
+#: ../../../src/uibase.cpp:42
msgid "&Options..."
msgstr "&Opcje..."
-#: ../../../src/uibase.cpp:39
+#: ../../../src/uibase.cpp:45
msgid "&Settings"
msgstr "&Ustawienia"
-#: ../../../src/uibase.cpp:43
+#: ../../../src/uibase.cpp:49
msgid "&About..."
msgstr "&O programie..."
-#: ../../../src/uibase.cpp:46
+#: ../../../src/uibase.cpp:52
msgid "&Help"
msgstr "&Pomoc"
-#: ../../../src/uibase.cpp:56
+#: ../../../src/uibase.cpp:62
msgid "Address Book"
msgstr "Księga Adresowa"
-#: ../../../src/uibase.cpp:69
+#: ../../../src/uibase.cpp:75
msgid "Your Bitcoin Address:"
msgstr "Twój Adres Bitcoin:"
-#: ../../../src/uibase.cpp:76
+#: ../../../src/uibase.cpp:82
msgid " &New... "
msgstr " &Nowy..."
-#: ../../../src/uibase.cpp:79
-#: ../../../src/uibase.cpp:780
-#: ../../../src/uibase.cpp:883
+#: ../../../src/uibase.cpp:85
+#: ../../../src/uibase.cpp:790
+#: ../../../src/uibase.cpp:893
msgid " &Copy to Clipboard "
msgstr " &Kopiuj do schowka "
-#: ../../../src/uibase.cpp:93
+#: ../../../src/uibase.cpp:99
msgid "Balance:"
msgstr "Saldo:"
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
msgid " All"
msgstr " Wszystko"
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
msgid " Sent"
msgstr "Wysłano"
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
msgid " Received"
msgstr "Otrzymano"
-#: ../../../src/uibase.cpp:109
+#: ../../../src/uibase.cpp:115
msgid " In Progress"
msgstr "W Trakcie"
-#: ../../../src/uibase.cpp:130
+#: ../../../src/uibase.cpp:136
msgid "All Transactions"
msgstr "Wszystkie Transakcje"
-#: ../../../src/uibase.cpp:141
+#: ../../../src/uibase.cpp:147
msgid "Sent/Received"
msgstr "Wysłano/Otrzymano"
-#: ../../../src/uibase.cpp:152
+#: ../../../src/uibase.cpp:158
msgid "Sent"
msgstr "Wysłano"
-#: ../../../src/uibase.cpp:163
+#: ../../../src/uibase.cpp:169
msgid "Received"
msgstr "Otrzymano"
-#: ../../../src/uibase.cpp:302
-#: ../../../src/uibase.cpp:443
-#: ../../../src/uibase.cpp:542
-#: ../../../src/uibase.cpp:722
-#: ../../../src/uibase.cpp:783
-#: ../../../src/uibase.cpp:892
-#: ../../../src/uibase.cpp:981
+#: ../../../src/uibase.cpp:312
+#: ../../../src/uibase.cpp:453
+#: ../../../src/uibase.cpp:552
+#: ../../../src/uibase.cpp:732
+#: ../../../src/uibase.cpp:793
+#: ../../../src/uibase.cpp:902
+#: ../../../src/uibase.cpp:991
msgid "OK"
msgstr "OK"
-#: ../../../src/uibase.cpp:345
+#: ../../../src/uibase.cpp:355
msgid "&Start Bitcoin on system startup"
msgstr "&Uruchom Bitcoin wraz ze startem systemu"
-#: ../../../src/uibase.cpp:348
+#: ../../../src/uibase.cpp:358
msgid "&Minimize to the tray instead of the taskbar"
msgstr "&Zminimalizuj do traya zamiast do paska zadań"
-#: ../../../src/uibase.cpp:351
+#: ../../../src/uibase.cpp:361
msgid "Map port using &UPnP"
msgstr "Mapuj port używając &UPnP"
-#: ../../../src/uibase.cpp:354
+#: ../../../src/uibase.cpp:364
msgid "M&inimize to the tray on close"
msgstr "Zm&inimalizuj do traya przy zamknięciu"
-#: ../../../src/uibase.cpp:360
+#: ../../../src/uibase.cpp:370
msgid "&Connect through socks4 proxy: "
msgstr "&Połącz przez socks4 proxy:"
-#: ../../../src/uibase.cpp:371
+#: ../../../src/uibase.cpp:381
msgid "Proxy &IP:"
msgstr "Proxy &IP:"
-#: ../../../src/uibase.cpp:379
+#: ../../../src/uibase.cpp:389
msgid " &Port:"
msgstr " &Port:"
-#: ../../../src/uibase.cpp:392
+#: ../../../src/uibase.cpp:402
msgid "Optional transaction fee per KB that helps make sure your transactions are processed quickly. Most transactions are 1KB. Fee 0.01 recommended."
msgstr "Opcjonalna prowizja określona dla KB transakcji, która zapewni, że twoje transakcje będą szybko przetworzone. Większość transakcji to 1KB. Rekomendowana prowizja to 0.01."
-#: ../../../src/uibase.cpp:399
+#: ../../../src/uibase.cpp:409
msgid "Pay transaction fee:"
msgstr "Płać prowizję transakcji:"
-#: ../../../src/uibase.cpp:420
+#: ../../../src/uibase.cpp:430
msgid "// [don't translate] Test panel 2 for future expansion"
msgstr ""
-#: ../../../src/uibase.cpp:424
+#: ../../../src/uibase.cpp:434
msgid "// [don't translate] Let's not start multiple pages until the first page is filled up"
msgstr ""
-#: ../../../src/uibase.cpp:446
-#: ../../../src/uibase.cpp:668
-#: ../../../src/uibase.cpp:727
-#: ../../../src/uibase.cpp:786
-#: ../../../src/uibase.cpp:895
-#: ../../../src/uibase.cpp:984
+#: ../../../src/uibase.cpp:456
+#: ../../../src/uibase.cpp:678
+#: ../../../src/uibase.cpp:737
+#: ../../../src/uibase.cpp:796
+#: ../../../src/uibase.cpp:905
+#: ../../../src/uibase.cpp:994
msgid "Cancel"
msgstr "Anuluj"
-#: ../../../src/uibase.cpp:449
+#: ../../../src/uibase.cpp:459
msgid "&Apply"
msgstr "&Zastosuj"
-#: ../../../src/uibase.cpp:508
+#: ../../../src/uibase.cpp:518
msgid "Bitcoin "
msgstr "Bitcoin"
-#: ../../../src/uibase.cpp:514
+#: ../../../src/uibase.cpp:524
msgid "version"
msgstr "wersja"
-#: ../../../src/uibase.cpp:525
+#: ../../../src/uibase.cpp:535
msgid ""
"Copyright (c) 2009-2011 Bitcoin Developers\n"
"\n"
@@ -865,39 +967,39 @@ msgstr ""
"OpenSSL Toolkit (http://www.openssl.org/) i oprogramowanie kryptograficzne napisane przez \n"
"Erica Younga (eay@cryptsoft.com) oraz oprogramowanie UPnP napisane przez Thomasa Bernarda."
-#: ../../../src/uibase.cpp:581
+#: ../../../src/uibase.cpp:591
msgid "Enter a Bitcoin address (e.g. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)"
msgstr "Wprowadź adres Bitcoin (np. 1NS17iag9jJgTHD1VXjvLCEnZuQ3rJDE9L)"
-#: ../../../src/uibase.cpp:595
+#: ../../../src/uibase.cpp:605
msgid "Pay &To:"
msgstr "Wpłać &Dla:"
-#: ../../../src/uibase.cpp:610
+#: ../../../src/uibase.cpp:620
msgid "&Paste"
msgstr "&Wklej"
-#: ../../../src/uibase.cpp:613
+#: ../../../src/uibase.cpp:623
msgid " Address &Book..."
msgstr " Księga &Adresowa..."
-#: ../../../src/uibase.cpp:620
+#: ../../../src/uibase.cpp:630
msgid "&Amount:"
msgstr "&Kwota:"
-#: ../../../src/uibase.cpp:630
+#: ../../../src/uibase.cpp:640
msgid "T&ransfer:"
msgstr "T&ransfer:"
-#: ../../../src/uibase.cpp:636
+#: ../../../src/uibase.cpp:646
msgid " Standard"
msgstr " Standard"
-#: ../../../src/uibase.cpp:663
+#: ../../../src/uibase.cpp:673
msgid "&Send"
msgstr "&Wyślij"
-#: ../../../src/uibase.cpp:711
+#: ../../../src/uibase.cpp:721
msgid ""
"\n"
"\n"
@@ -907,70 +1009,74 @@ msgstr ""
"\n"
"Łączenie..."
-#: ../../../src/uibase.cpp:761
+#: ../../../src/uibase.cpp:771
msgid "These are your Bitcoin addresses for receiving payments. You may want to give a different one to each sender so you can keep track of who is paying you. The highlighted address is displayed in the main window."
msgstr "To są twoje adresy Bitcoin dla otrzymywania płatności. Możesz chcieć podać różne dla każdego płacącego aby kontrolować kto ci płaci. Wyróżniony adres będzie wyświetlany w oknie głównym."
-#: ../../../src/uibase.cpp:774
-#: ../../../src/uibase.cpp:886
+#: ../../../src/uibase.cpp:784
+#: ../../../src/uibase.cpp:896
msgid "&Edit..."
msgstr "&Edytuj..."
-#: ../../../src/uibase.cpp:777
-#: ../../../src/uibase.cpp:889
+#: ../../../src/uibase.cpp:787
+#: ../../../src/uibase.cpp:899
msgid " &New Address... "
msgstr " &Nowy Adres..."
-#: ../../../src/uibase.cpp:849
+#: ../../../src/uibase.cpp:859
msgid "Sending"
msgstr "Wysyłanie"
-#: ../../../src/uibase.cpp:857
+#: ../../../src/uibase.cpp:867
msgid "These are your Bitcoin addresses for receiving payments. You can give a different one to each sender to keep track of who is paying you. The highlighted address will be displayed in the main window."
msgstr "To są twoje adresy Bitcoin dla otrzymywania płatności. Możesz podać różne dla każdego płacącego aby kontrolować kto ci płaci. Wyróżniony adres będzie wyświetlany w oknie głównym."
-#: ../../../src/uibase.cpp:870
+#: ../../../src/uibase.cpp:880
msgid "Receiving"
msgstr "Otrzymywanie"
-#: ../../../src/uibase.cpp:880
+#: ../../../src/uibase.cpp:890
msgid "&Delete"
msgstr "&Usuń"
-#: ../../../src/wallet.cpp:917
+#: ../../../src/wallet.cpp:1081
+msgid "Error: Wallet locked, unable to create transaction "
+msgstr "Błąd: Portfel zablokowany, nie można utworzyć transakcji"
+
+#: ../../../src/wallet.cpp:1089
#, c-format
msgid "Error: This transaction requires a transaction fee of at least %s because of its amount, complexity, or use of recently received funds "
msgstr "Błąd: Ta transakcja wymaga prowizji co najmniej %s z uwagi na kwotę, złożoność lub użycie niedawno otrzymanych funduszy"
-#: ../../../src/wallet.cpp:919
+#: ../../../src/wallet.cpp:1091
msgid "Error: Transaction creation failed "
msgstr "Błąd: Nie udało się utworzyć transakcji"
-#: ../../../src/wallet.cpp:928
+#: ../../../src/wallet.cpp:1101
msgid "Error: The transaction was rejected. This might happen if some of the coins in your wallet were already spent, such as if you used a copy of wallet.dat and coins were spent in the copy but not marked as spent here."
msgstr "Błąd: Transakcja została odrzucona. Może się tak zdarzyć jeżeli część monet w twoim portfelu zostało wydanych, np. gdy użyto kopii pliku wallet.dat i monety zostały wydane w kopii, a tutaj nie zostały oznaczone jako wydane."
-#: ../../../src/wallet.cpp:941
+#: ../../../src/wallet.cpp:1114
msgid "Invalid amount"
msgstr "Niewłaściwa kwota"
-#: ../../../src/wallet.cpp:948
+#: ../../../src/wallet.cpp:1121
msgid "Invalid bitcoin address"
msgstr "Niewłaściwy adres bitcoin"
-#: ../../../src/uibase.h:147
+#: ../../../src/uibase.h:151
msgid "Transaction Details"
msgstr "Szczegóły Transakcji"
-#: ../../../src/uibase.h:199
+#: ../../../src/uibase.h:203
msgid "Options"
msgstr "Opcje"
-#: ../../../src/uibase.h:228
+#: ../../../src/uibase.h:232
msgid "About Bitcoin"
msgstr "O Bitcoin"
-#: ../../../src/uibase.h:337
+#: ../../../src/uibase.h:341
msgid "Your Bitcoin Addresses"
msgstr "Twoje Adresy Bitcoin"
diff --git a/locale/ru/LC_MESSAGES/bitcoin.mo b/locale/ru/LC_MESSAGES/bitcoin.mo
index 92bb888fe9..4175fc47d1 100644
--- a/locale/ru/LC_MESSAGES/bitcoin.mo
+++ b/locale/ru/LC_MESSAGES/bitcoin.mo
Binary files differ
diff --git a/locale/ru/LC_MESSAGES/bitcoin.po b/locale/ru/LC_MESSAGES/bitcoin.po
index d53b08d46c..266e76825a 100644
--- a/locale/ru/LC_MESSAGES/bitcoin.po
+++ b/locale/ru/LC_MESSAGES/bitcoin.po
@@ -3,8 +3,8 @@ msgstr ""
"Project-Id-Version: \n"
"Report-Msgid-Bugs-To: m0Ray <m0ray@nm.ru>\n"
"POT-Creation-Date: 2011-05-15 18:24+0100\n"
-"PO-Revision-Date: 2011-05-23 07:06+0500\n"
-"Last-Translator: m0Ray <m0ray@nm.ru>\n"
+"PO-Revision-Date: 2011-07-17 04:18+0100\n"
+"Last-Translator: Michael Bemmerl <mail@mx-server.de>\n"
"Language-Team: \n"
"Language: \n"
"MIME-Version: 1.0\n"
@@ -448,7 +448,7 @@ msgstr "&Открыть Bitcoin"
#: ../../../src/ui.cpp:2682
msgid "&Send Bitcoins"
-msgstr "&Открыть Bitcoin"
+msgstr "&Отправить Bitcoins"
#: ../../../src/ui.cpp:2683
msgid "O&ptions..."
diff --git a/share/uiproject.fbp b/share/uiproject.fbp
index d5e6b1e36b..7d2c258415 100644
--- a/share/uiproject.fbp
+++ b/share/uiproject.fbp
@@ -2090,7 +2090,7 @@
<property name="font"></property>
<property name="hidden">0</property>
<property name="id">wxID_ANY</property>
- <property name="label">&amp;Connect through socks4 proxy: </property>
+ <property name="label">&amp;Connect through socks4 proxy (requires restart to apply): </property>
<property name="maximum_size"></property>
<property name="minimum_size"></property>
<property name="name">m_checkBoxUseProxy</property>
diff --git a/src/base58.h b/src/base58.h
index c2729d4770..04922c74d8 100644
--- a/src/base58.h
+++ b/src/base58.h
@@ -159,52 +159,149 @@ inline bool DecodeBase58Check(const std::string& str, std::vector<unsigned char>
-#define ADDRESSVERSION ((unsigned char)(fTestNet ? 111 : 0))
-
-inline std::string Hash160ToAddress(uint160 hash160)
+class CBase58Data
{
- // add 1-byte version number to the front
- std::vector<unsigned char> vch(1, ADDRESSVERSION);
- vch.insert(vch.end(), UBEGIN(hash160), UEND(hash160));
- return EncodeBase58Check(vch);
-}
+protected:
+ unsigned char nVersion;
+ std::vector<unsigned char> vchData;
-inline bool AddressToHash160(const char* psz, uint160& hash160Ret)
-{
- std::vector<unsigned char> vch;
- if (!DecodeBase58Check(psz, vch))
- return false;
- if (vch.empty())
- return false;
- unsigned char nVersion = vch[0];
- if (vch.size() != sizeof(hash160Ret) + 1)
- return false;
- memcpy(&hash160Ret, &vch[1], sizeof(hash160Ret));
- return (nVersion <= ADDRESSVERSION);
-}
+ CBase58Data()
+ {
+ nVersion = 0;
+ vchData.clear();
+ }
-inline bool AddressToHash160(const std::string& str, uint160& hash160Ret)
-{
- return AddressToHash160(str.c_str(), hash160Ret);
-}
+ ~CBase58Data()
+ {
+ if (!vchData.empty())
+ memset(&vchData[0], 0, vchData.size());
+ }
-inline bool IsValidBitcoinAddress(const char* psz)
-{
- uint160 hash160;
- return AddressToHash160(psz, hash160);
-}
+ void SetData(int nVersionIn, const void* pdata, size_t nSize)
+ {
+ nVersion = nVersionIn;
+ vchData.resize(nSize);
+ if (!vchData.empty())
+ memcpy(&vchData[0], pdata, nSize);
+ }
-inline bool IsValidBitcoinAddress(const std::string& str)
-{
- return IsValidBitcoinAddress(str.c_str());
-}
+ void SetData(int nVersionIn, const unsigned char *pbegin, const unsigned char *pend)
+ {
+ SetData(nVersionIn, (void*)pbegin, pend - pbegin);
+ }
+
+public:
+ bool SetString(const char* psz)
+ {
+ std::vector<unsigned char> vchTemp;
+ DecodeBase58Check(psz, vchTemp);
+ if (vchTemp.empty())
+ {
+ vchData.clear();
+ nVersion = 0;
+ return false;
+ }
+ nVersion = vchTemp[0];
+ vchData.resize(vchTemp.size() - 1);
+ if (!vchData.empty())
+ memcpy(&vchData[0], &vchTemp[1], vchData.size());
+ memset(&vchTemp[0], 0, vchTemp.size());
+ return true;
+ }
+
+ bool SetString(const std::string& str)
+ {
+ return SetString(str.c_str());
+ }
+ std::string ToString() const
+ {
+ std::vector<unsigned char> vch(1, nVersion);
+ vch.insert(vch.end(), vchData.begin(), vchData.end());
+ return EncodeBase58Check(vch);
+ }
+
+ int CompareTo(const CBase58Data& b58) const
+ {
+ if (nVersion < b58.nVersion) return -1;
+ if (nVersion > b58.nVersion) return 1;
+ if (vchData < b58.vchData) return -1;
+ if (vchData > b58.vchData) return 1;
+ return 0;
+ }
+ bool operator==(const CBase58Data& b58) const { return CompareTo(b58) == 0; }
+ bool operator<=(const CBase58Data& b58) const { return CompareTo(b58) <= 0; }
+ bool operator>=(const CBase58Data& b58) const { return CompareTo(b58) >= 0; }
+ bool operator< (const CBase58Data& b58) const { return CompareTo(b58) < 0; }
+ bool operator> (const CBase58Data& b58) const { return CompareTo(b58) > 0; }
+};
-inline std::string PubKeyToAddress(const std::vector<unsigned char>& vchPubKey)
+class CBitcoinAddress : public CBase58Data
{
- return Hash160ToAddress(Hash160(vchPubKey));
-}
+public:
+ bool SetHash160(const uint160& hash160)
+ {
+ SetData(fTestNet ? 111 : 0, &hash160, 20);
+ return true;
+ }
+
+ bool SetPubKey(const std::vector<unsigned char>& vchPubKey)
+ {
+ return SetHash160(Hash160(vchPubKey));
+ }
+
+ bool IsValid() const
+ {
+ int nExpectedSize = 20;
+ bool fExpectTestNet = false;
+ switch(nVersion)
+ {
+ case 0:
+ break;
+
+ case 111:
+ fExpectTestNet = true;
+ break;
+
+ default:
+ return false;
+ }
+ return fExpectTestNet == fTestNet && vchData.size() == nExpectedSize;
+ }
+
+ CBitcoinAddress()
+ {
+ }
+
+ CBitcoinAddress(uint160 hash160In)
+ {
+ SetHash160(hash160In);
+ }
+
+ CBitcoinAddress(const std::vector<unsigned char>& vchPubKey)
+ {
+ SetPubKey(vchPubKey);
+ }
+
+ CBitcoinAddress(const std::string& strAddress)
+ {
+ SetString(strAddress);
+ }
+
+ CBitcoinAddress(const char* pszAddress)
+ {
+ SetString(pszAddress);
+ }
+
+ uint160 GetHash160() const
+ {
+ assert(vchData.size() == 20);
+ uint160 hash160;
+ memcpy(&hash160, &vchData[0], 20);
+ return hash160;
+ }
+};
#endif
diff --git a/src/db.cpp b/src/db.cpp
index 4df05d68ed..9c8c9c4f73 100644
--- a/src/db.cpp
+++ b/src/db.cpp
@@ -528,7 +528,7 @@ bool CAddrDB::LoadAddresses()
char psz[1000];
while (fgets(psz, sizeof(psz), filein))
{
- CAddress addr(psz, NODE_NETWORK);
+ CAddress addr(psz, false, NODE_NETWORK);
addr.nTime = 0; // so it won't relay unless successfully connected
if (addr.IsValid())
AddAddress(addr);
@@ -777,7 +777,7 @@ int CWalletDB::LoadWallet(CWallet* pwallet)
key.SetPrivKey(wkey.vchPrivKey);
}
if (!pwallet->LoadKey(key))
- return false;
+ return DB_CORRUPT;
}
else if (strType == "mkey")
{
@@ -786,7 +786,7 @@ int CWalletDB::LoadWallet(CWallet* pwallet)
CMasterKey kMasterKey;
ssValue >> kMasterKey;
if(pwallet->mapMasterKeys.count(nID) != 0)
- return false;
+ return DB_CORRUPT;
pwallet->mapMasterKeys[nID] = kMasterKey;
if (pwallet->nMasterKeyMaxID < nID)
pwallet->nMasterKeyMaxID = nID;
@@ -798,7 +798,7 @@ int CWalletDB::LoadWallet(CWallet* pwallet)
vector<unsigned char> vchPrivKey;
ssValue >> vchPrivKey;
if (!pwallet->LoadCryptedKey(vchPubKey, vchPrivKey))
- return false;
+ return DB_CORRUPT;
}
else if (strType == "defaultkey")
{
diff --git a/src/init.cpp b/src/init.cpp
index fd1d8d3cd9..acfcc44d10 100644
--- a/src/init.cpp
+++ b/src/init.cpp
@@ -247,7 +247,8 @@ bool AppInit2(int argc, char* argv[])
fPrintToDebugger = GetBoolArg("-printtodebugger");
fTestNet = GetBoolArg("-testnet");
- fNoListen = GetBoolArg("-nolisten");
+ bool fTOR = (fUseProxy && addrProxy.port == htons(9050));
+ fNoListen = GetBoolArg("-nolisten") || fTOR;
fLogTimestamps = GetBoolArg("-logtimestamps");
for (int i = 1; i < argc; i++)
@@ -425,7 +426,6 @@ bool AppInit2(int argc, char* argv[])
printf("mapBlockIndex.size() = %d\n", mapBlockIndex.size());
printf("nBestHeight = %d\n", nBestHeight);
printf("setKeyPool.size() = %d\n", pwalletMain->setKeyPool.size());
- printf("mapPubKeys.size() = %d\n", mapPubKeys.size());
printf("mapWallet.size() = %d\n", pwalletMain->mapWallet.size());
printf("mapAddressBook.size() = %d\n", pwalletMain->mapAddressBook.size());
diff --git a/src/key.h b/src/key.h
index c43e4ee235..3c14cfedd5 100644
--- a/src/key.h
+++ b/src/key.h
@@ -220,6 +220,11 @@ public:
return false;
return true;
}
+
+ CBitcoinAddress GetAddress() const
+ {
+ return CBitcoinAddress(GetPubKey());
+ }
};
#endif
diff --git a/src/keystore.cpp b/src/keystore.cpp
index de13958a8b..1828d6dddc 100644
--- a/src/keystore.cpp
+++ b/src/keystore.cpp
@@ -16,14 +16,19 @@ std::vector<unsigned char> CKeyStore::GenerateNewKey()
return key.GetPubKey();
}
+bool CKeyStore::GetPubKey(const CBitcoinAddress &address, std::vector<unsigned char> &vchPubKeyOut) const
+{
+ CKey key;
+ if (!GetKey(address, key))
+ return false;
+ vchPubKeyOut = key.GetPubKey();
+ return true;
+}
+
bool CBasicKeyStore::AddKey(const CKey& key)
{
- CRITICAL_BLOCK(cs_mapPubKeys)
CRITICAL_BLOCK(cs_KeyStore)
- {
- mapKeys[key.GetPubKey()] = key.GetPrivKey();
- mapPubKeys[Hash160(key.GetPubKey())] = key.GetPubKey();
- }
+ mapKeys[key.GetAddress()] = key.GetSecret();
return true;
}
@@ -44,11 +49,11 @@ bool CCryptoKeyStore::Unlock(const CKeyingMaterial& vMasterKeyIn)
if (!SetCrypted())
return false;
- std::map<std::vector<unsigned char>, std::vector<unsigned char> >::const_iterator mi = mapCryptedKeys.begin();
+ CryptedKeyMap::const_iterator mi = mapCryptedKeys.begin();
for (; mi != mapCryptedKeys.end(); ++mi)
{
- const std::vector<unsigned char> &vchPubKey = (*mi).first;
- const std::vector<unsigned char> &vchCryptedSecret = (*mi).second;
+ const std::vector<unsigned char> &vchPubKey = (*mi).second.first;
+ const std::vector<unsigned char> &vchCryptedSecret = (*mi).second.second;
CSecret vchSecret;
if(!DecryptSecret(vMasterKeyIn, vchCryptedSecret, Hash(vchPubKey.begin(), vchPubKey.end()), vchSecret))
return false;
@@ -88,31 +93,30 @@ bool CCryptoKeyStore::AddKey(const CKey& key)
bool CCryptoKeyStore::AddCryptedKey(const std::vector<unsigned char> &vchPubKey, const std::vector<unsigned char> &vchCryptedSecret)
{
- CRITICAL_BLOCK(cs_mapPubKeys)
CRITICAL_BLOCK(cs_KeyStore)
{
if (!SetCrypted())
return false;
- mapCryptedKeys[vchPubKey] = vchCryptedSecret;
- mapPubKeys[Hash160(vchPubKey)] = vchPubKey;
+ mapCryptedKeys[CBitcoinAddress(vchPubKey)] = make_pair(vchPubKey, vchCryptedSecret);
}
return true;
}
-bool CCryptoKeyStore::GetPrivKey(const std::vector<unsigned char> &vchPubKey, CKey& keyOut) const
+bool CCryptoKeyStore::GetKey(const CBitcoinAddress &address, CKey& keyOut) const
{
CRITICAL_BLOCK(cs_vMasterKey)
{
if (!IsCrypted())
- return CBasicKeyStore::GetPrivKey(vchPubKey, keyOut);
+ return CBasicKeyStore::GetKey(address, keyOut);
- std::map<std::vector<unsigned char>, std::vector<unsigned char> >::const_iterator mi = mapCryptedKeys.find(vchPubKey);
+ CryptedKeyMap::const_iterator mi = mapCryptedKeys.find(address);
if (mi != mapCryptedKeys.end())
{
- const std::vector<unsigned char> &vchCryptedSecret = (*mi).second;
+ const std::vector<unsigned char> &vchPubKey = (*mi).second.first;
+ const std::vector<unsigned char> &vchCryptedSecret = (*mi).second.second;
CSecret vchSecret;
- if (!DecryptSecret(vMasterKey, (*mi).second, Hash((*mi).first.begin(), (*mi).first.end()), vchSecret))
+ if (!DecryptSecret(vMasterKey, vchCryptedSecret, Hash(vchPubKey.begin(), vchPubKey.end()), vchSecret))
return false;
keyOut.SetSecret(vchSecret);
return true;
@@ -121,6 +125,23 @@ bool CCryptoKeyStore::GetPrivKey(const std::vector<unsigned char> &vchPubKey, CK
return false;
}
+bool CCryptoKeyStore::GetPubKey(const CBitcoinAddress &address, std::vector<unsigned char>& vchPubKeyOut) const
+{
+ CRITICAL_BLOCK(cs_vMasterKey)
+ {
+ if (!IsCrypted())
+ return CKeyStore::GetPubKey(address, vchPubKeyOut);
+
+ CryptedKeyMap::const_iterator mi = mapCryptedKeys.find(address);
+ if (mi != mapCryptedKeys.end())
+ {
+ vchPubKeyOut = (*mi).second.first;
+ return true;
+ }
+ }
+ return false;
+}
+
bool CCryptoKeyStore::EncryptKeys(CKeyingMaterial& vMasterKeyIn)
{
CRITICAL_BLOCK(cs_KeyStore)
@@ -133,12 +154,13 @@ bool CCryptoKeyStore::EncryptKeys(CKeyingMaterial& vMasterKeyIn)
CKey key;
BOOST_FOREACH(KeyMap::value_type& mKey, mapKeys)
{
- if (!key.SetPrivKey(mKey.second))
+ if (!key.SetSecret(mKey.second))
return false;
+ const std::vector<unsigned char> vchPubKey = key.GetPubKey();
std::vector<unsigned char> vchCryptedSecret;
- if (!EncryptSecret(vMasterKeyIn, key.GetSecret(), Hash(mKey.first.begin(), mKey.first.end()), vchCryptedSecret))
+ if (!EncryptSecret(vMasterKeyIn, key.GetSecret(), Hash(vchPubKey.begin(), vchPubKey.end()), vchCryptedSecret))
return false;
- if (!AddCryptedKey(mKey.first, vchCryptedSecret))
+ if (!AddCryptedKey(vchPubKey, vchCryptedSecret))
return false;
}
mapKeys.clear();
diff --git a/src/keystore.h b/src/keystore.h
index 0dc09f05b8..436053a9e3 100644
--- a/src/keystore.h
+++ b/src/keystore.h
@@ -12,12 +12,13 @@ public:
mutable CCriticalSection cs_KeyStore;
virtual bool AddKey(const CKey& key) =0;
- virtual bool HaveKey(const std::vector<unsigned char> &vchPubKey) const =0;
- virtual bool GetPrivKey(const std::vector<unsigned char> &vchPubKey, CKey& keyOut) const =0;
+ virtual bool HaveKey(const CBitcoinAddress &address) const =0;
+ virtual bool GetKey(const CBitcoinAddress &address, CKey& keyOut) const =0;
+ virtual bool GetPubKey(const CBitcoinAddress &address, std::vector<unsigned char>& vchPubKeyOut) const;
virtual std::vector<unsigned char> GenerateNewKey();
};
-typedef std::map<std::vector<unsigned char>, CPrivKey> KeyMap;
+typedef std::map<CBitcoinAddress, CSecret> KeyMap;
class CBasicKeyStore : public CKeyStore
{
@@ -26,26 +27,28 @@ protected:
public:
bool AddKey(const CKey& key);
- bool HaveKey(const std::vector<unsigned char> &vchPubKey) const
+ bool HaveKey(const CBitcoinAddress &address) const
{
- return (mapKeys.count(vchPubKey) > 0);
+ return (mapKeys.count(address) > 0);
}
- bool GetPrivKey(const std::vector<unsigned char> &vchPubKey, CKey& keyOut) const
+ bool GetKey(const CBitcoinAddress &address, CKey& keyOut) const
{
- std::map<std::vector<unsigned char>, CPrivKey>::const_iterator mi = mapKeys.find(vchPubKey);
+ KeyMap::const_iterator mi = mapKeys.find(address);
if (mi != mapKeys.end())
{
- keyOut.SetPrivKey((*mi).second);
+ keyOut.SetSecret((*mi).second);
return true;
}
return false;
}
};
+typedef std::map<CBitcoinAddress, std::pair<std::vector<unsigned char>, std::vector<unsigned char> > > CryptedKeyMap;
+
class CCryptoKeyStore : public CBasicKeyStore
{
private:
- std::map<std::vector<unsigned char>, std::vector<unsigned char> > mapCryptedKeys;
+ CryptedKeyMap mapCryptedKeys;
CKeyingMaterial vMasterKey;
@@ -103,13 +106,14 @@ public:
virtual bool AddCryptedKey(const std::vector<unsigned char> &vchPubKey, const std::vector<unsigned char> &vchCryptedSecret);
std::vector<unsigned char> GenerateNewKey();
bool AddKey(const CKey& key);
- bool HaveKey(const std::vector<unsigned char> &vchPubKey) const
+ bool HaveKey(const CBitcoinAddress &address) const
{
if (!IsCrypted())
- return CBasicKeyStore::HaveKey(vchPubKey);
- return mapCryptedKeys.count(vchPubKey) > 0;
+ return CBasicKeyStore::HaveKey(address);
+ return mapCryptedKeys.count(address) > 0;
}
- bool GetPrivKey(const std::vector<unsigned char> &vchPubKey, CKey& keyOut) const;
+ bool GetKey(const CBitcoinAddress &address, CKey& keyOut) const;
+ bool GetPubKey(const CBitcoinAddress &address, std::vector<unsigned char>& vchPubKeyOut) const;
};
#endif
diff --git a/src/main.cpp b/src/main.cpp
index 6902194016..b57974f577 100644
--- a/src/main.cpp
+++ b/src/main.cpp
@@ -21,9 +21,6 @@ set<CWallet*> setpwalletRegistered;
CCriticalSection cs_main;
-CCriticalSection cs_mapPubKeys;
-map<uint160, vector<unsigned char> > mapPubKeys;
-
map<uint256, CTransaction> mapTransactions;
CCriticalSection cs_mapTransactions;
unsigned int nTransactionsUpdated = 0;
@@ -1899,6 +1896,8 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv)
return error("message addr size() = %d", vAddr.size());
// Store the new addresses
+ CAddrDB addrDB;
+ addrDB.TxnBegin();
int64 nNow = GetAdjustedTime();
int64 nSince = nNow - 10 * 60;
BOOST_FOREACH(CAddress& addr, vAddr)
@@ -1910,7 +1909,7 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv)
continue;
if (addr.nTime <= 100000000 || addr.nTime > nNow + 10 * 60)
addr.nTime = nNow - 5 * 24 * 60 * 60;
- AddAddress(addr, 2 * 60 * 60);
+ AddAddress(addr, 2 * 60 * 60, &addrDB);
pfrom->AddAddressKnown(addr);
if (addr.nTime > nSince && !pfrom->fGetAddr && vAddr.size() <= 10 && addr.IsRoutable())
{
@@ -1941,6 +1940,7 @@ bool static ProcessMessage(CNode* pfrom, string strCommand, CDataStream& vRecv)
}
}
}
+ addrDB.TxnCommit(); // Save addresses (it's ok if this fails)
if (vAddr.size() < 1000)
pfrom->fGetAddr = false;
}
@@ -2567,6 +2567,7 @@ bool SendMessages(CNode* pto, bool fSendTrickle)
vGetData.clear();
}
}
+ mapAlreadyAskedFor[inv] = nNow;
pto->mapAskFor.erase(pto->mapAskFor.begin());
}
if (!vGetData.empty())
diff --git a/src/main.h b/src/main.h
index d34f68f9d0..9d6de52fa4 100644
--- a/src/main.h
+++ b/src/main.h
@@ -1568,7 +1568,5 @@ public:
extern std::map<uint256, CTransaction> mapTransactions;
-extern std::map<uint160, std::vector<unsigned char> > mapPubKeys;
-extern CCriticalSection cs_mapPubKeys;
#endif
diff --git a/src/makefile.vc b/src/makefile.vc
index b25ba60c50..c050deb6ed 100644
--- a/src/makefile.vc
+++ b/src/makefile.vc
@@ -41,12 +41,12 @@ DEFS=$(DEFS) /DUSE_UPNP=$(USE_UPNP)
!ENDIF
LIBS=$(LIBS) \
- kernel32.lib user32.lib gdi32.lib comdlg32.lib winspool.lib winmm.lib shell32.lib comctl32.lib ole32.lib oleaut32.lib uuid.lib rpcrt4.lib advapi32.lib ws2_32.lib shlwapi.lib
+ kernel32.lib user32.lib gdi32.lib comdlg32.lib winspool.lib winmm.lib shell32.lib comctl32.lib ole32.lib oleaut32.lib uuid.lib rpcrt4.lib advapi32.lib ws2_32.lib shlwapi.lib iphlpapi.lib
DEBUGFLAGS=/Os
CFLAGS=/MD /c /nologo /EHsc /GR /Zm300 $(DEBUGFLAGS) $(DEFS) $(INCLUDEPATHS)
HEADERS=headers.h strlcpy.h serialize.h uint256.h util.h key.h bignum.h base58.h \
- script.h db.h net.h irc.h main.h rpc.h uibase.h ui.h noui.h init.h wallet.h keystore.h
+ script.h db.h net.h irc.h main.h rpc.h uibase.h ui.h noui.h init.h wallet.h keystore.h crypter.h
OBJS= \
obj\util.obj \
@@ -58,7 +58,8 @@ OBJS= \
obj\main.obj \
obj\wallet.obj \
obj\rpc.obj \
- obj\init.obj
+ obj\init.obj \
+ obj\crypter.obj
CRYPTOPP_OBJS= \
cryptopp\obj\sha.obj \
@@ -93,6 +94,8 @@ obj\rpc.obj: $(HEADERS)
obj\init.obj: $(HEADERS)
+obj\crypter.obj: $(HEADERS)
+
obj\ui.obj: $(HEADERS)
obj\uibase.obj: $(HEADERS)
diff --git a/src/net.cpp b/src/net.cpp
index ac5a2834b0..d697788213 100644
--- a/src/net.cpp
+++ b/src/net.cpp
@@ -440,7 +440,7 @@ void ThreadGetMyExternalIP(void* parg)
-bool AddAddress(CAddress addr, int64 nTimePenalty)
+bool AddAddress(CAddress addr, int64 nTimePenalty, CAddrDB *pAddrDB)
{
if (!addr.IsRoutable())
return false;
@@ -455,7 +455,10 @@ bool AddAddress(CAddress addr, int64 nTimePenalty)
// New address
printf("AddAddress(%s)\n", addr.ToString().c_str());
mapAddresses.insert(make_pair(addr.GetKey(), addr));
- CAddrDB().WriteAddress(addr);
+ if (pAddrDB)
+ pAddrDB->WriteAddress(addr);
+ else
+ CAddrDB().WriteAddress(addr);
return true;
}
else
@@ -477,7 +480,12 @@ bool AddAddress(CAddress addr, int64 nTimePenalty)
fUpdated = true;
}
if (fUpdated)
- CAddrDB().WriteAddress(addrFound);
+ {
+ if (pAddrDB)
+ pAddrDB->WriteAddress(addrFound);
+ else
+ CAddrDB().WriteAddress(addrFound);
+ }
}
}
return false;
@@ -1084,13 +1092,14 @@ void ThreadMapPort2(void* parg)
{
char intClient[16];
char intPort[6];
+ string strDesc = "Bitcoin " + FormatFullVersion();
#ifndef __WXMSW__
r = UPNP_AddPortMapping(urls.controlURL, data.first.servicetype,
- port, port, lanaddr, 0, "TCP", 0);
+ port, port, lanaddr, strDesc.c_str(), "TCP", 0);
#else
r = UPNP_AddPortMapping(urls.controlURL, data.first.servicetype,
- port, port, lanaddr, 0, "TCP", 0, "0");
+ port, port, lanaddr, strDesc.c_str(), "TCP", 0, "0");
#endif
if(r!=UPNPCOMMAND_SUCCESS)
printf("AddPortMapping(%s, %s, %s) failed with code %d (%s)\n",
@@ -1158,6 +1167,8 @@ void DNSAddressSeed()
if (!fTestNet)
{
printf("Loading addresses from DNS seeds (could take a while)\n");
+ CAddrDB addrDB;
+ addrDB.TxnBegin();
for (int seed_idx = 0; seed_idx < ARRAYLEN(strDNSSeed); seed_idx++) {
vector<CAddress> vaddr;
@@ -1168,12 +1179,14 @@ void DNSAddressSeed()
if (addr.GetByte(3) != 127)
{
addr.nTime = 0;
- AddAddress(addr);
+ AddAddress(addr, 0, &addrDB);
found++;
}
}
}
}
+
+ addrDB.TxnCommit(); // Save addresses (it's ok if this fails)
}
printf("%d addresses found from DNS seeds\n", found);
diff --git a/src/net.h b/src/net.h
index afa264b723..78055bfc69 100644
--- a/src/net.h
+++ b/src/net.h
@@ -14,6 +14,7 @@
class CMessageHeader;
class CAddress;
+class CAddrDB;
class CInv;
class CRequestTracker;
class CNode;
@@ -39,7 +40,7 @@ bool ConnectSocket(const CAddress& addrConnect, SOCKET& hSocketRet, int nTimeout
bool Lookup(const char *pszName, std::vector<CAddress>& vaddr, int nServices, int nMaxSolutions, bool fAllowLookup = false, int portDefault = 0, bool fAllowPort = false);
bool Lookup(const char *pszName, CAddress& addr, int nServices, bool fAllowLookup = false, int portDefault = 0, bool fAllowPort = false);
bool GetMyExternalIP(unsigned int& ipRet);
-bool AddAddress(CAddress addr, int64 nTimePenalty=0);
+bool AddAddress(CAddress addr, int64 nTimePenalty=0, CAddrDB *pAddrDB=NULL);
void AddressCurrentlyConnected(const CAddress& addr);
CNode* FindNode(unsigned int ip);
CNode* ConnectNode(CAddress addrConnect, int64 nTimeout=0);
diff --git a/src/rpc.cpp b/src/rpc.cpp
index fa14fc0b2f..a4deece6b2 100644
--- a/src/rpc.cpp
+++ b/src/rpc.cpp
@@ -342,21 +342,19 @@ Value getnewaddress(const Array& params, bool fHelp)
strAccount = AccountFromValue(params[0]);
// Generate a new key that is added to wallet
- string strAddress = PubKeyToAddress(pwalletMain->GetOrReuseKeyFromPool());
+ CBitcoinAddress address(pwalletMain->GetOrReuseKeyFromPool());
// This could be done in the same main CS as GetKeyFromKeyPool.
CRITICAL_BLOCK(pwalletMain->cs_mapAddressBook)
- pwalletMain->SetAddressBookName(strAddress, strAccount);
+ pwalletMain->SetAddressBookName(address, strAccount);
- return strAddress;
+ return address.ToString();
}
// requires cs_main, cs_mapWallet, cs_mapAddressBook locks
-string GetAccountAddress(string strAccount, bool bForceNew=false)
+CBitcoinAddress GetAccountAddress(string strAccount, bool bForceNew=false)
{
- string strAddress;
-
CWalletDB walletdb(pwalletMain->strWalletFile);
CAccount account;
@@ -393,16 +391,13 @@ string GetAccountAddress(string strAccount, bool bForceNew=false)
else
{
account.vchPubKey = pwalletMain->GetOrReuseKeyFromPool();
- string strAddress = PubKeyToAddress(account.vchPubKey);
- pwalletMain->SetAddressBookName(strAddress, strAccount);
+ pwalletMain->SetAddressBookName(CBitcoinAddress(account.vchPubKey), strAccount);
walletdb.WriteAccount(strAccount, account);
}
}
}
- strAddress = PubKeyToAddress(account.vchPubKey);
-
- return strAddress;
+ return CBitcoinAddress(account.vchPubKey);
}
Value getaccountaddress(const Array& params, bool fHelp)
@@ -421,7 +416,7 @@ Value getaccountaddress(const Array& params, bool fHelp)
CRITICAL_BLOCK(pwalletMain->cs_mapWallet)
CRITICAL_BLOCK(pwalletMain->cs_mapAddressBook)
{
- ret = GetAccountAddress(strAccount);
+ ret = GetAccountAddress(strAccount).ToString();
}
return ret;
@@ -436,10 +431,8 @@ Value setaccount(const Array& params, bool fHelp)
"setaccount <bitcoinaddress> <account>\n"
"Sets the account associated with the given address.");
- string strAddress = params[0].get_str();
- uint160 hash160;
- bool isValid = AddressToHash160(strAddress, hash160);
- if (!isValid)
+ CBitcoinAddress address(params[0].get_str());
+ if (!address.IsValid())
throw JSONRPCError(-5, "Invalid bitcoin address");
@@ -452,14 +445,14 @@ Value setaccount(const Array& params, bool fHelp)
CRITICAL_BLOCK(pwalletMain->cs_mapWallet)
CRITICAL_BLOCK(pwalletMain->cs_mapAddressBook)
{
- if (pwalletMain->mapAddressBook.count(strAddress))
+ if (pwalletMain->mapAddressBook.count(address))
{
- string strOldAccount = pwalletMain->mapAddressBook[strAddress];
- if (strAddress == GetAccountAddress(strOldAccount))
+ string strOldAccount = pwalletMain->mapAddressBook[address];
+ if (address == GetAccountAddress(strOldAccount))
GetAccountAddress(strOldAccount, true);
}
- pwalletMain->SetAddressBookName(strAddress, strAccount);
+ pwalletMain->SetAddressBookName(address, strAccount);
}
return Value::null;
@@ -473,12 +466,14 @@ Value getaccount(const Array& params, bool fHelp)
"getaccount <bitcoinaddress>\n"
"Returns the account associated with the given address.");
- string strAddress = params[0].get_str();
+ CBitcoinAddress address(params[0].get_str());
+ if (!address.IsValid())
+ throw JSONRPCError(-5, "Invalid bitcoin address");
string strAccount;
CRITICAL_BLOCK(pwalletMain->cs_mapAddressBook)
{
- map<string, string>::iterator mi = pwalletMain->mapAddressBook.find(strAddress);
+ map<CBitcoinAddress, string>::iterator mi = pwalletMain->mapAddressBook.find(address);
if (mi != pwalletMain->mapAddressBook.end() && !(*mi).second.empty())
strAccount = (*mi).second;
}
@@ -499,17 +494,12 @@ Value getaddressesbyaccount(const Array& params, bool fHelp)
Array ret;
CRITICAL_BLOCK(pwalletMain->cs_mapAddressBook)
{
- BOOST_FOREACH(const PAIRTYPE(string, string)& item, pwalletMain->mapAddressBook)
+ BOOST_FOREACH(const PAIRTYPE(CBitcoinAddress, string)& item, pwalletMain->mapAddressBook)
{
- const string& strAddress = item.first;
+ const CBitcoinAddress& address = item.first;
const string& strName = item.second;
if (strName == strAccount)
- {
- // We're only adding valid bitcoin addresses and not ip addresses
- CScript scriptPubKey;
- if (scriptPubKey.SetBitcoinAddress(strAddress))
- ret.push_back(strAddress);
- }
+ ret.push_back(address.ToString());
}
}
return ret;
@@ -543,7 +533,9 @@ Value sendtoaddress(const Array& params, bool fHelp)
"sendtoaddress <bitcoinaddress> <amount> [comment] [comment-to]\n"
"<amount> is a real and is rounded to the nearest 0.00000001");
- string strAddress = params[0].get_str();
+ CBitcoinAddress address(params[0].get_str());
+ if (!address.IsValid())
+ throw JSONRPCError(-5, "Invalid bitcoin address");
// Amount
int64 nAmount = AmountFromValue(params[1]);
@@ -561,7 +553,7 @@ Value sendtoaddress(const Array& params, bool fHelp)
if(pwalletMain->IsLocked())
throw JSONRPCError(-14, "Error: The wallet passphrase entered was incorrect.");
- string strError = pwalletMain->SendMoneyToBitcoinAddress(strAddress, nAmount, wtx);
+ string strError = pwalletMain->SendMoneyToBitcoinAddress(address, nAmount, wtx);
if (strError != "")
throw JSONRPCError(-4, strError);
}
@@ -578,10 +570,11 @@ Value getreceivedbyaddress(const Array& params, bool fHelp)
"Returns the total amount received by <bitcoinaddress> in transactions with at least [minconf] confirmations.");
// Bitcoin address
- string strAddress = params[0].get_str();
+ CBitcoinAddress address = CBitcoinAddress(params[0].get_str());
CScript scriptPubKey;
- if (!scriptPubKey.SetBitcoinAddress(strAddress))
+ if (!address.IsValid())
throw JSONRPCError(-5, "Invalid bitcoin address");
+ scriptPubKey.SetBitcoinAddress(address);
if (!IsMine(*pwalletMain,scriptPubKey))
return (double)0.0;
@@ -611,22 +604,16 @@ Value getreceivedbyaddress(const Array& params, bool fHelp)
}
-void GetAccountPubKeys(string strAccount, set<CScript>& setPubKey)
+void GetAccountAddresses(string strAccount, set<CBitcoinAddress>& setAddress)
{
CRITICAL_BLOCK(pwalletMain->cs_mapAddressBook)
{
- BOOST_FOREACH(const PAIRTYPE(string, string)& item, pwalletMain->mapAddressBook)
+ BOOST_FOREACH(const PAIRTYPE(CBitcoinAddress, string)& item, pwalletMain->mapAddressBook)
{
- const string& strAddress = item.first;
+ const CBitcoinAddress& address = item.first;
const string& strName = item.second;
if (strName == strAccount)
- {
- // We're only counting our own valid bitcoin addresses and not ip addresses
- CScript scriptPubKey;
- if (scriptPubKey.SetBitcoinAddress(strAddress))
- if (IsMine(*pwalletMain,scriptPubKey))
- setPubKey.insert(scriptPubKey);
- }
+ setAddress.insert(address);
}
}
}
@@ -646,8 +633,8 @@ Value getreceivedbyaccount(const Array& params, bool fHelp)
// Get the set of pub keys that have the label
string strAccount = AccountFromValue(params[0]);
- set<CScript> setPubKey;
- GetAccountPubKeys(strAccount, setPubKey);
+ set<CBitcoinAddress> setAddress;
+ GetAccountAddresses(strAccount, setAddress);
// Tally
int64 nAmount = 0;
@@ -660,9 +647,12 @@ Value getreceivedbyaccount(const Array& params, bool fHelp)
continue;
BOOST_FOREACH(const CTxOut& txout, wtx.vout)
- if (setPubKey.count(txout.scriptPubKey))
+ {
+ CBitcoinAddress address;
+ if (ExtractAddress(txout.scriptPubKey, pwalletMain, address) && setAddress.count(address))
if (wtx.GetDepthInMainChain() >= nMinDepth)
nAmount += txout.nValue;
+ }
}
}
@@ -733,13 +723,13 @@ Value getbalance(const Array& params, bool fHelp)
int64 allGeneratedImmature, allGeneratedMature, allFee;
allGeneratedImmature = allGeneratedMature = allFee = 0;
string strSentAccount;
- list<pair<string, int64> > listReceived;
- list<pair<string, int64> > listSent;
+ list<pair<CBitcoinAddress, int64> > listReceived;
+ list<pair<CBitcoinAddress, int64> > listSent;
wtx.GetAmounts(allGeneratedImmature, allGeneratedMature, listReceived, listSent, allFee, strSentAccount);
if (wtx.GetDepthInMainChain() >= nMinDepth)
- BOOST_FOREACH(const PAIRTYPE(string,int64)& r, listReceived)
+ BOOST_FOREACH(const PAIRTYPE(CBitcoinAddress,int64)& r, listReceived)
nBalance += r.second;
- BOOST_FOREACH(const PAIRTYPE(string,int64)& r, listSent)
+ BOOST_FOREACH(const PAIRTYPE(CBitcoinAddress,int64)& r, listSent)
nBalance -= r.second;
nBalance -= allFee;
nBalance += allGeneratedMature;
@@ -816,7 +806,9 @@ Value sendfrom(const Array& params, bool fHelp)
"<amount> is a real and is rounded to the nearest 0.00000001");
string strAccount = AccountFromValue(params[0]);
- string strAddress = params[1].get_str();
+ CBitcoinAddress address(params[1].get_str());
+ if (!address.IsValid())
+ throw JSONRPCError(-5, "Invalid bitcoin address");
int64 nAmount = AmountFromValue(params[2]);
int nMinDepth = 1;
if (params.size() > 3)
@@ -842,7 +834,7 @@ Value sendfrom(const Array& params, bool fHelp)
throw JSONRPCError(-6, "Account has insufficient funds");
// Send
- string strError = pwalletMain->SendMoneyToBitcoinAddress(strAddress, nAmount, wtx);
+ string strError = pwalletMain->SendMoneyToBitcoinAddress(address, nAmount, wtx);
if (strError != "")
throw JSONRPCError(-4, strError);
}
@@ -874,22 +866,22 @@ Value sendmany(const Array& params, bool fHelp)
if (params.size() > 3 && params[3].type() != null_type && !params[3].get_str().empty())
wtx.mapValue["comment"] = params[3].get_str();
- set<string> setAddress;
+ set<CBitcoinAddress> setAddress;
vector<pair<CScript, int64> > vecSend;
int64 totalAmount = 0;
BOOST_FOREACH(const Pair& s, sendTo)
{
- uint160 hash160;
- string strAddress = s.name_;
+ CBitcoinAddress address(s.name_);
+ if (!address.IsValid())
+ throw JSONRPCError(-5, string("Invalid bitcoin address:")+s.name_);
- if (setAddress.count(strAddress))
- throw JSONRPCError(-8, string("Invalid parameter, duplicated address: ")+strAddress);
- setAddress.insert(strAddress);
+ if (setAddress.count(address))
+ throw JSONRPCError(-8, string("Invalid parameter, duplicated address: ")+s.name_);
+ setAddress.insert(address);
CScript scriptPubKey;
- if (!scriptPubKey.SetBitcoinAddress(strAddress))
- throw JSONRPCError(-5, string("Invalid bitcoin address:")+strAddress);
+ scriptPubKey.SetBitcoinAddress(address);
int64 nAmount = AmountFromValue(s.value_);
totalAmount += nAmount;
@@ -950,7 +942,7 @@ Value ListReceived(const Array& params, bool fByAccounts)
fIncludeEmpty = params[1].get_bool();
// Tally
- map<uint160, tallyitem> mapTally;
+ map<CBitcoinAddress, tallyitem> mapTally;
CRITICAL_BLOCK(pwalletMain->cs_mapWallet)
{
for (map<uint256, CWalletTx>::iterator it = pwalletMain->mapWallet.begin(); it != pwalletMain->mapWallet.end(); ++it)
@@ -965,12 +957,11 @@ Value ListReceived(const Array& params, bool fByAccounts)
BOOST_FOREACH(const CTxOut& txout, wtx.vout)
{
- // Only counting our own bitcoin addresses and not ip addresses
- uint160 hash160 = txout.scriptPubKey.GetBitcoinAddressHash160();
- if (hash160 == 0 || !mapPubKeys.count(hash160)) // IsMine
+ CBitcoinAddress address;
+ if (!ExtractAddress(txout.scriptPubKey, pwalletMain, address) || !address.IsValid())
continue;
- tallyitem& item = mapTally[hash160];
+ tallyitem& item = mapTally[address];
item.nAmount += txout.nValue;
item.nConf = min(item.nConf, nDepth);
}
@@ -982,14 +973,11 @@ Value ListReceived(const Array& params, bool fByAccounts)
map<string, tallyitem> mapAccountTally;
CRITICAL_BLOCK(pwalletMain->cs_mapAddressBook)
{
- BOOST_FOREACH(const PAIRTYPE(string, string)& item, pwalletMain->mapAddressBook)
+ BOOST_FOREACH(const PAIRTYPE(CBitcoinAddress, string)& item, pwalletMain->mapAddressBook)
{
- const string& strAddress = item.first;
+ const CBitcoinAddress& address = item.first;
const string& strAccount = item.second;
- uint160 hash160;
- if (!AddressToHash160(strAddress, hash160))
- continue;
- map<uint160, tallyitem>::iterator it = mapTally.find(hash160);
+ map<CBitcoinAddress, tallyitem>::iterator it = mapTally.find(address);
if (it == mapTally.end() && !fIncludeEmpty)
continue;
@@ -1010,7 +998,7 @@ Value ListReceived(const Array& params, bool fByAccounts)
else
{
Object obj;
- obj.push_back(Pair("address", strAddress));
+ obj.push_back(Pair("address", address.ToString()));
obj.push_back(Pair("account", strAccount));
obj.push_back(Pair("label", strAccount)); // deprecated
obj.push_back(Pair("amount", ValueFromAmount(nAmount)));
@@ -1073,8 +1061,8 @@ void ListTransactions(const CWalletTx& wtx, const string& strAccount, int nMinDe
{
int64 nGeneratedImmature, nGeneratedMature, nFee;
string strSentAccount;
- list<pair<string, int64> > listReceived;
- list<pair<string, int64> > listSent;
+ list<pair<CBitcoinAddress, int64> > listReceived;
+ list<pair<CBitcoinAddress, int64> > listSent;
wtx.GetAmounts(nGeneratedImmature, nGeneratedMature, listReceived, listSent, nFee, strSentAccount);
bool fAllAccounts = (strAccount == string("*"));
@@ -1102,11 +1090,11 @@ void ListTransactions(const CWalletTx& wtx, const string& strAccount, int nMinDe
// Sent
if ((!listSent.empty() || nFee != 0) && (fAllAccounts || strAccount == strSentAccount))
{
- BOOST_FOREACH(const PAIRTYPE(string, int64)& s, listSent)
+ BOOST_FOREACH(const PAIRTYPE(CBitcoinAddress, int64)& s, listSent)
{
Object entry;
entry.push_back(Pair("account", strSentAccount));
- entry.push_back(Pair("address", s.first));
+ entry.push_back(Pair("address", s.first.ToString()));
entry.push_back(Pair("category", "send"));
entry.push_back(Pair("amount", ValueFromAmount(-s.second)));
entry.push_back(Pair("fee", ValueFromAmount(-nFee)));
@@ -1120,7 +1108,7 @@ void ListTransactions(const CWalletTx& wtx, const string& strAccount, int nMinDe
if (listReceived.size() > 0 && wtx.GetDepthInMainChain() >= nMinDepth)
CRITICAL_BLOCK(pwalletMain->cs_mapAddressBook)
{
- BOOST_FOREACH(const PAIRTYPE(string, int64)& r, listReceived)
+ BOOST_FOREACH(const PAIRTYPE(CBitcoinAddress, int64)& r, listReceived)
{
string account;
if (pwalletMain->mapAddressBook.count(r.first))
@@ -1129,7 +1117,7 @@ void ListTransactions(const CWalletTx& wtx, const string& strAccount, int nMinDe
{
Object entry;
entry.push_back(Pair("account", account));
- entry.push_back(Pair("address", r.first));
+ entry.push_back(Pair("address", r.first.ToString()));
entry.push_back(Pair("category", "receive"));
entry.push_back(Pair("amount", ValueFromAmount(r.second)));
if (fLong)
@@ -1240,9 +1228,8 @@ Value listaccounts(const Array& params, bool fHelp)
CRITICAL_BLOCK(pwalletMain->cs_mapWallet)
CRITICAL_BLOCK(pwalletMain->cs_mapAddressBook)
{
- BOOST_FOREACH(const PAIRTYPE(string, string)& entry, pwalletMain->mapAddressBook) {
- uint160 hash160;
- if(AddressToHash160(entry.first, hash160) && mapPubKeys.count(hash160)) // This address belongs to me
+ BOOST_FOREACH(const PAIRTYPE(CBitcoinAddress, string)& entry, pwalletMain->mapAddressBook) {
+ if (pwalletMain->HaveKey(entry.first)) // This address belongs to me
mapAccountBalances[entry.second] = 0;
}
@@ -1251,16 +1238,16 @@ Value listaccounts(const Array& params, bool fHelp)
const CWalletTx& wtx = (*it).second;
int64 nGeneratedImmature, nGeneratedMature, nFee;
string strSentAccount;
- list<pair<string, int64> > listReceived;
- list<pair<string, int64> > listSent;
+ list<pair<CBitcoinAddress, int64> > listReceived;
+ list<pair<CBitcoinAddress, int64> > listSent;
wtx.GetAmounts(nGeneratedImmature, nGeneratedMature, listReceived, listSent, nFee, strSentAccount);
mapAccountBalances[strSentAccount] -= nFee;
- BOOST_FOREACH(const PAIRTYPE(string, int64)& s, listSent)
+ BOOST_FOREACH(const PAIRTYPE(CBitcoinAddress, int64)& s, listSent)
mapAccountBalances[strSentAccount] -= s.second;
if (wtx.GetDepthInMainChain() >= nMinDepth)
{
mapAccountBalances[""] += nGeneratedMature;
- BOOST_FOREACH(const PAIRTYPE(string, int64)& r, listReceived)
+ BOOST_FOREACH(const PAIRTYPE(CBitcoinAddress, int64)& r, listReceived)
if (pwalletMain->mapAddressBook.count(r.first))
mapAccountBalances[pwalletMain->mapAddressBook[r.first]] += r.second;
else
@@ -1552,9 +1539,8 @@ Value validateaddress(const Array& params, bool fHelp)
"validateaddress <bitcoinaddress>\n"
"Return information about <bitcoinaddress>.");
- string strAddress = params[0].get_str();
- uint160 hash160;
- bool isValid = AddressToHash160(strAddress, hash160);
+ CBitcoinAddress address(params[0].get_str());
+ bool isValid = address.IsValid();
Object ret;
ret.push_back(Pair("isvalid", isValid));
@@ -1562,13 +1548,13 @@ Value validateaddress(const Array& params, bool fHelp)
{
// Call Hash160ToAddress() so we always return current ADDRESSVERSION
// version of the address:
- string currentAddress = Hash160ToAddress(hash160);
+ string currentAddress = address.ToString();
ret.push_back(Pair("address", currentAddress));
- ret.push_back(Pair("ismine", (mapPubKeys.count(hash160) > 0)));
+ ret.push_back(Pair("ismine", (pwalletMain->HaveKey(address) > 0)));
CRITICAL_BLOCK(pwalletMain->cs_mapAddressBook)
{
- if (pwalletMain->mapAddressBook.count(currentAddress))
- ret.push_back(Pair("account", pwalletMain->mapAddressBook[currentAddress]));
+ if (pwalletMain->mapAddressBook.count(address))
+ ret.push_back(Pair("account", pwalletMain->mapAddressBook[address]));
}
}
return ret;
@@ -1756,7 +1742,7 @@ string pAllowInSafeMode[] =
"getinfo",
"getnewaddress",
"getaccountaddress",
- "setlabel",
+ "setlabel", // deprecated
"getaccount",
"getlabel", // deprecated
"getaddressesbyaccount",
@@ -2387,7 +2373,7 @@ int CommandLineRPC(int argc, char *argv[])
if (strMethod == "getreceivedbyaccount" && n > 1) ConvertTo<boost::int64_t>(params[1]);
if (strMethod == "getreceivedbylabel" && n > 1) ConvertTo<boost::int64_t>(params[1]); // deprecated
if (strMethod == "getallreceived" && n > 0) ConvertTo<boost::int64_t>(params[0]); // deprecated
- if (strMethod == "getallreceived" && n > 1) ConvertTo<bool>(params[1]);
+ if (strMethod == "getallreceived" && n > 1) ConvertTo<bool>(params[1]); // deprecated
if (strMethod == "listreceivedbyaddress" && n > 0) ConvertTo<boost::int64_t>(params[0]);
if (strMethod == "listreceivedbyaddress" && n > 1) ConvertTo<bool>(params[1]);
if (strMethod == "listreceivedbyaccount" && n > 0) ConvertTo<boost::int64_t>(params[0]);
diff --git a/src/script.cpp b/src/script.cpp
index 654aaa10e3..0fc4611fda 100644
--- a/src/script.cpp
+++ b/src/script.cpp
@@ -1041,7 +1041,9 @@ bool Solver(const CKeyStore& keystore, const CScript& scriptPubKey, uint256 hash
// Sign
const valtype& vchPubKey = item.second;
CKey key;
- if (!keystore.GetPrivKey(vchPubKey, key))
+ if (!keystore.GetKey(Hash160(vchPubKey), key))
+ return false;
+ if (key.GetPubKey() != vchPubKey)
return false;
if (hash != 0)
{
@@ -1055,12 +1057,8 @@ bool Solver(const CKeyStore& keystore, const CScript& scriptPubKey, uint256 hash
else if (item.first == OP_PUBKEYHASH)
{
// Sign and give pubkey
- map<uint160, valtype>::iterator mi = mapPubKeys.find(uint160(item.second));
- if (mi == mapPubKeys.end())
- return false;
- const vector<unsigned char>& vchPubKey = (*mi).second;
CKey key;
- if (!keystore.GetPrivKey(vchPubKey, key))
+ if (!keystore.GetKey(uint160(item.second), key))
return false;
if (hash != 0)
{
@@ -1068,7 +1066,7 @@ bool Solver(const CKeyStore& keystore, const CScript& scriptPubKey, uint256 hash
if (!key.Sign(hash, vchSig))
return false;
vchSig.push_back((unsigned char)nHashType);
- scriptSigRet << vchSig << vchPubKey;
+ scriptSigRet << vchSig << key.GetPubKey();
}
}
else
@@ -1102,19 +1100,16 @@ bool IsMine(const CKeyStore &keystore, const CScript& scriptPubKey)
{
if (item.first == OP_PUBKEY)
{
- // Sign
const valtype& vchPubKey = item.second;
- if (!keystore.HaveKey(vchPubKey))
+ vector<unsigned char> vchPubKeyFound;
+ if (!keystore.GetPubKey(Hash160(vchPubKey), vchPubKeyFound))
+ return false;
+ if (vchPubKeyFound != vchPubKey)
return false;
}
else if (item.first == OP_PUBKEYHASH)
{
- // Sign and give pubkey
- map<uint160, valtype>::iterator mi = mapPubKeys.find(uint160(item.second));
- if (mi == mapPubKeys.end())
- return false;
- const vector<unsigned char>& vchPubKey = (*mi).second;
- if (!keystore.HaveKey(vchPubKey))
+ if (!keystore.HaveKey(uint160(item.second)))
return false;
}
else
@@ -1127,58 +1122,33 @@ bool IsMine(const CKeyStore &keystore, const CScript& scriptPubKey)
return true;
}
-
-bool ExtractPubKey(const CScript& scriptPubKey, const CKeyStore* keystore, vector<unsigned char>& vchPubKeyRet)
+// requires either keystore==0, or a lock on keystore->cs_KeyStore
+bool static ExtractAddressInner(const CScript& scriptPubKey, const CKeyStore* keystore, CBitcoinAddress& addressRet)
{
- vchPubKeyRet.clear();
-
vector<pair<opcodetype, valtype> > vSolution;
if (!Solver(scriptPubKey, vSolution))
return false;
- CRITICAL_BLOCK(cs_mapPubKeys)
+ BOOST_FOREACH(PAIRTYPE(opcodetype, valtype)& item, vSolution)
{
- BOOST_FOREACH(PAIRTYPE(opcodetype, valtype)& item, vSolution)
- {
- valtype vchPubKey;
- if (item.first == OP_PUBKEY)
- {
- vchPubKey = item.second;
- }
- else if (item.first == OP_PUBKEYHASH)
- {
- map<uint160, valtype>::iterator mi = mapPubKeys.find(uint160(item.second));
- if (mi == mapPubKeys.end())
- continue;
- vchPubKey = (*mi).second;
- }
- if (keystore == NULL || keystore->HaveKey(vchPubKey))
- {
- vchPubKeyRet = vchPubKey;
- return true;
- }
- }
+ if (item.first == OP_PUBKEY)
+ addressRet.SetPubKey(item.second);
+ else if (item.first == OP_PUBKEYHASH)
+ addressRet.SetHash160((uint160)item.second);
+ if (keystore == NULL || keystore->HaveKey(addressRet))
+ return true;
}
return false;
}
-bool ExtractHash160(const CScript& scriptPubKey, uint160& hash160Ret)
+bool ExtractAddress(const CScript& scriptPubKey, const CKeyStore* keystore, CBitcoinAddress& addressRet)
{
- hash160Ret = 0;
-
- vector<pair<opcodetype, valtype> > vSolution;
- if (!Solver(scriptPubKey, vSolution))
- return false;
-
- BOOST_FOREACH(PAIRTYPE(opcodetype, valtype)& item, vSolution)
- {
- if (item.first == OP_PUBKEYHASH)
- {
- hash160Ret = uint160(item.second);
- return true;
- }
- }
+ if (keystore)
+ CRITICAL_BLOCK(keystore->cs_KeyStore)
+ return ExtractAddressInner(scriptPubKey, keystore, addressRet);
+ else
+ return ExtractAddressInner(scriptPubKey, NULL, addressRet);
return false;
}
diff --git a/src/script.h b/src/script.h
index 2a36db2faf..9d94e3f5c8 100644
--- a/src/script.h
+++ b/src/script.h
@@ -622,7 +622,7 @@ public:
}
- uint160 GetBitcoinAddressHash160() const
+ CBitcoinAddress GetBitcoinAddress() const
{
opcodetype opcode;
std::vector<unsigned char> vch;
@@ -634,36 +634,18 @@ public:
if (!GetOp(pc, opcode, vch) || opcode != OP_EQUALVERIFY) return 0;
if (!GetOp(pc, opcode, vch) || opcode != OP_CHECKSIG) return 0;
if (pc != end()) return 0;
- return hash160;
+ return CBitcoinAddress(hash160);
}
- std::string GetBitcoinAddress() const
- {
- uint160 hash160 = GetBitcoinAddressHash160();
- if (hash160 == 0)
- return "";
- return Hash160ToAddress(hash160);
- }
-
- void SetBitcoinAddress(const uint160& hash160)
+ void SetBitcoinAddress(const CBitcoinAddress& address)
{
this->clear();
- *this << OP_DUP << OP_HASH160 << hash160 << OP_EQUALVERIFY << OP_CHECKSIG;
+ *this << OP_DUP << OP_HASH160 << address.GetHash160() << OP_EQUALVERIFY << OP_CHECKSIG;
}
void SetBitcoinAddress(const std::vector<unsigned char>& vchPubKey)
{
- SetBitcoinAddress(Hash160(vchPubKey));
- }
-
- bool SetBitcoinAddress(const std::string& strAddress)
- {
- this->clear();
- uint160 hash160;
- if (!AddressToHash160(strAddress, hash160))
- return false;
- SetBitcoinAddress(hash160);
- return true;
+ SetBitcoinAddress(CBitcoinAddress(vchPubKey));
}
@@ -710,8 +692,7 @@ public:
bool IsStandard(const CScript& scriptPubKey);
bool IsMine(const CKeyStore& keystore, const CScript& scriptPubKey);
-bool ExtractPubKey(const CScript& scriptPubKey, const CKeyStore* pkeystore, std::vector<unsigned char>& vchPubKeyRet);
-bool ExtractHash160(const CScript& scriptPubKey, uint160& hash160Ret);
+bool ExtractAddress(const CScript& scriptPubKey, const CKeyStore* pkeystore, CBitcoinAddress& addressRet);
bool SignSignature(const CKeyStore& keystore, const CTransaction& txFrom, CTransaction& txTo, unsigned int nIn, int nHashType=SIGHASH_ALL, CScript scriptPrereq=CScript());
bool VerifySignature(const CTransaction& txFrom, const CTransaction& txTo, unsigned int nIn, int nHashType=0);
diff --git a/src/ui.cpp b/src/ui.cpp
index eae0a4f4c8..c3c234439c 100644
--- a/src/ui.cpp
+++ b/src/ui.cpp
@@ -235,12 +235,13 @@ void SetDefaultReceivingAddress(const string& strAddress)
return;
if (strAddress != pframeMain->m_textCtrlAddress->GetValue())
{
- uint160 hash160;
- if (!AddressToHash160(strAddress, hash160))
+ CBitcoinAddress address(strAddress);
+ if (!address.IsValid())
return;
- if (!mapPubKeys.count(hash160))
+ vector<unsigned char> vchPubKey;
+ if (!pwalletMain->GetPubKey(address, vchPubKey))
return;
- pwalletMain->SetDefaultKey(mapPubKeys[hash160]);
+ pwalletMain->SetDefaultKey(vchPubKey);
pframeMain->m_textCtrlAddress->SetValue(strAddress);
}
}
@@ -366,7 +367,7 @@ CMainFrame::CMainFrame(wxWindow* parent) : CMainFrameBase(parent)
// Fill your address text box
vector<unsigned char> vchPubKey;
if (CWalletDB(pwalletMain->strWalletFile,"r").ReadDefaultKey(vchPubKey))
- m_textCtrlAddress->SetValue(PubKeyToAddress(vchPubKey));
+ m_textCtrlAddress->SetValue(CBitcoinAddress(vchPubKey).ToString());
if (pwalletMain->IsCrypted())
m_menuOptions->Remove(m_menuOptionsEncryptWallet);
@@ -703,24 +704,23 @@ bool CMainFrame::InsertTransaction(const CWalletTx& wtx, bool fNew, int nIndex)
{
if (pwalletMain->IsMine(txout))
{
- vector<unsigned char> vchPubKey;
- if (ExtractPubKey(txout.scriptPubKey, pwalletMain, vchPubKey))
+ CBitcoinAddress address;
+ if (ExtractAddress(txout.scriptPubKey, pwalletMain, address))
{
CRITICAL_BLOCK(pwalletMain->cs_mapAddressBook)
{
//strDescription += _("Received payment to ");
//strDescription += _("Received with address ");
strDescription += _("Received with: ");
- string strAddress = PubKeyToAddress(vchPubKey);
- map<string, string>::iterator mi = pwalletMain->mapAddressBook.find(strAddress);
+ map<CBitcoinAddress, string>::iterator mi = pwalletMain->mapAddressBook.find(address);
if (mi != pwalletMain->mapAddressBook.end() && !(*mi).second.empty())
{
string strLabel = (*mi).second;
- strDescription += strAddress.substr(0,12) + "... ";
+ strDescription += address.ToString().substr(0,12) + "... ";
strDescription += "(" + strLabel + ")";
}
else
- strDescription += strAddress;
+ strDescription += address.ToString();
}
}
break;
@@ -776,6 +776,7 @@ bool CMainFrame::InsertTransaction(const CWalletTx& wtx, bool fNew, int nIndex)
if (pwalletMain->IsMine(txout))
continue;
+ CBitcoinAddress address;
string strAddress;
if (!mapValue["to"].empty())
{
@@ -785,15 +786,14 @@ bool CMainFrame::InsertTransaction(const CWalletTx& wtx, bool fNew, int nIndex)
else
{
// Sent to Bitcoin Address
- uint160 hash160;
- if (ExtractHash160(txout.scriptPubKey, hash160))
- strAddress = Hash160ToAddress(hash160);
+ if (ExtractAddress(txout.scriptPubKey, NULL, address))
+ strAddress = address.ToString();
}
string strDescription = _("To: ");
CRITICAL_BLOCK(pwalletMain->cs_mapAddressBook)
- if (pwalletMain->mapAddressBook.count(strAddress) && !pwalletMain->mapAddressBook[strAddress].empty())
- strDescription += pwalletMain->mapAddressBook[strAddress] + " ";
+ if (pwalletMain->mapAddressBook.count(address) && !pwalletMain->mapAddressBook[address].empty())
+ strDescription += pwalletMain->mapAddressBook[address] + " ";
strDescription += strAddress;
if (!mapValue["message"].empty())
{
@@ -1114,7 +1114,7 @@ void CMainFrame::OnPaintListCtrl(wxPaintEvent& event)
m_statusBar->SetStatusText(strStatus, 2);
// Update receiving address
- string strDefaultAddress = PubKeyToAddress(pwalletMain->vchDefaultKey);
+ string strDefaultAddress = CBitcoinAddress(pwalletMain->vchDefaultKey).ToString();
if (m_textCtrlAddress->GetValue() != strDefaultAddress)
m_textCtrlAddress->SetValue(strDefaultAddress);
}
@@ -1393,7 +1393,7 @@ void CMainFrame::OnButtonNew(wxCommandEvent& event)
return;
// Generate new key
- strAddress = PubKeyToAddress(pwalletMain->GetOrReuseKeyFromPool());
+ strAddress = CBitcoinAddress(pwalletMain->GetOrReuseKeyFromPool()).ToString();
if (fWasLocked)
pwalletMain->Lock();
@@ -1502,17 +1502,16 @@ CTxDetailsDialog::CTxDetailsDialog(wxWindow* parent, CWalletTx wtx) : CTxDetails
{
if (pwalletMain->IsMine(txout))
{
- vector<unsigned char> vchPubKey;
- if (ExtractPubKey(txout.scriptPubKey, pwalletMain, vchPubKey))
+ CBitcoinAddress address;
+ if (ExtractAddress(txout.scriptPubKey, pwalletMain, address))
{
- string strAddress = PubKeyToAddress(vchPubKey);
- if (pwalletMain->mapAddressBook.count(strAddress))
+ if (pwalletMain->mapAddressBook.count(address))
{
strHTML += string() + _("<b>From:</b> ") + _("unknown") + "<br>";
strHTML += _("<b>To:</b> ");
- strHTML += HtmlEscape(strAddress);
- if (!pwalletMain->mapAddressBook[strAddress].empty())
- strHTML += _(" (yours, label: ") + pwalletMain->mapAddressBook[strAddress] + ")";
+ strHTML += HtmlEscape(address.ToString());
+ if (!pwalletMain->mapAddressBook[address].empty())
+ strHTML += _(" (yours, label: ") + pwalletMain->mapAddressBook[address] + ")";
else
strHTML += _(" (yours)");
strHTML += "<br>";
@@ -1588,13 +1587,13 @@ CTxDetailsDialog::CTxDetailsDialog(wxWindow* parent, CWalletTx wtx) : CTxDetails
if (wtx.mapValue["to"].empty())
{
// Offline transaction
- uint160 hash160;
- if (ExtractHash160(txout.scriptPubKey, hash160))
+ CBitcoinAddress address;
+ if (ExtractAddress(txout.scriptPubKey, pwalletMain, address))
{
- string strAddress = Hash160ToAddress(hash160);
+ string strAddress = address.ToString();
strHTML += _("<b>To:</b> ");
- if (pwalletMain->mapAddressBook.count(strAddress) && !pwalletMain->mapAddressBook[strAddress].empty())
- strHTML += pwalletMain->mapAddressBook[strAddress] + " ";
+ if (pwalletMain->mapAddressBook.count(address) && !pwalletMain->mapAddressBook[address].empty())
+ strHTML += pwalletMain->mapAddressBook[address] + " ";
strHTML += strAddress;
strHTML += "<br>";
}
@@ -2155,8 +2154,8 @@ void CSendDialog::OnButtonSend(wxCommandEvent& event)
}
// Parse bitcoin address
- uint160 hash160;
- bool fBitcoinAddress = AddressToHash160(strAddress, hash160);
+ CBitcoinAddress address(strAddress);
+ bool fBitcoinAddress = address.IsValid();
if (fBitcoinAddress)
{
@@ -2169,7 +2168,7 @@ void CSendDialog::OnButtonSend(wxCommandEvent& event)
// Send to bitcoin address
CScript scriptPubKey;
- scriptPubKey << OP_DUP << OP_HASH160 << hash160 << OP_EQUALVERIFY << OP_CHECKSIG;
+ scriptPubKey.SetBitcoinAddress(address);
string strError = pwalletMain->SendMoney(scriptPubKey, nValue, wtx, true);
if (strError == "")
@@ -2213,7 +2212,7 @@ void CSendDialog::OnButtonSend(wxCommandEvent& event)
}
CRITICAL_BLOCK(pwalletMain->cs_mapAddressBook)
- if (!pwalletMain->mapAddressBook.count(strAddress))
+ if (!pwalletMain->mapAddressBook.count(address))
pwalletMain->SetAddressBookName(strAddress, "");
EndModal(true);
@@ -2625,15 +2624,14 @@ CAddressBookDialog::CAddressBookDialog(wxWindow* parent, const wxString& strInit
CRITICAL_BLOCK(pwalletMain->cs_mapAddressBook)
{
string strDefaultReceiving = (string)pframeMain->m_textCtrlAddress->GetValue();
- BOOST_FOREACH(const PAIRTYPE(string, string)& item, pwalletMain->mapAddressBook)
+ BOOST_FOREACH(const PAIRTYPE(CBitcoinAddress, string)& item, pwalletMain->mapAddressBook)
{
- string strAddress = item.first;
+ const CBitcoinAddress& address = item.first;
string strName = item.second;
- uint160 hash160;
- bool fMine = (AddressToHash160(strAddress, hash160) && mapPubKeys.count(hash160));
+ bool fMine = pwalletMain->HaveKey(address);
wxListCtrl* plistCtrl = fMine ? m_listCtrlReceiving : m_listCtrlSending;
- int nIndex = InsertLine(plistCtrl, strName, strAddress);
- if (strAddress == (fMine ? strDefaultReceiving : string(strInitSelected)))
+ int nIndex = InsertLine(plistCtrl, strName, address.ToString());
+ if (address.ToString() == (fMine ? strDefaultReceiving : string(strInitSelected)))
plistCtrl->SetItemState(nIndex, wxLIST_STATE_SELECTED|wxLIST_STATE_FOCUSED, wxLIST_STATE_SELECTED|wxLIST_STATE_FOCUSED);
}
}
@@ -2740,8 +2738,8 @@ void CAddressBookDialog::OnButtonCopy(wxCommandEvent& event)
bool CAddressBookDialog::CheckIfMine(const string& strAddress, const string& strTitle)
{
- uint160 hash160;
- bool fMine = (AddressToHash160(strAddress, hash160) && mapPubKeys.count(hash160));
+ CBitcoinAddress address(strAddress);
+ bool fMine = address.IsValid() && pwalletMain->HaveKey(address);
if (fMine)
wxMessageBox(_("This is one of your own addresses for receiving payments and cannot be entered in the address book. "), strTitle);
return fMine;
@@ -2827,7 +2825,7 @@ void CAddressBookDialog::OnButtonNew(wxCommandEvent& event)
return;
// Generate new key
- strAddress = PubKeyToAddress(pwalletMain->GetOrReuseKeyFromPool());
+ strAddress = CBitcoinAddress(pwalletMain->GetOrReuseKeyFromPool()).ToString();
if (fWasLocked)
pwalletMain->Lock();
diff --git a/src/uibase.cpp b/src/uibase.cpp
index 18eec44138..6d219ad667 100644
--- a/src/uibase.cpp
+++ b/src/uibase.cpp
@@ -367,7 +367,7 @@ COptionsDialogBase::COptionsDialogBase( wxWindow* parent, wxWindowID id, const w
wxBoxSizer* bSizer102;
bSizer102 = new wxBoxSizer( wxHORIZONTAL );
- m_checkBoxUseProxy = new wxCheckBox( m_panelMain, wxID_ANY, _("&Connect through socks4 proxy: "), wxDefaultPosition, wxDefaultSize, 0 );
+ m_checkBoxUseProxy = new wxCheckBox( m_panelMain, wxID_ANY, _("&Connect through socks4 proxy (requires restart to apply): "), wxDefaultPosition, wxDefaultSize, 0 );
bSizer102->Add( m_checkBoxUseProxy, 0, wxALL|wxALIGN_CENTER_VERTICAL, 5 );
bSizer69->Add( bSizer102, 1, wxEXPAND, 5 );
diff --git a/src/wallet.cpp b/src/wallet.cpp
index 2ee918fdab..1f3f44bfa0 100644
--- a/src/wallet.cpp
+++ b/src/wallet.cpp
@@ -124,7 +124,6 @@ public:
bool CWallet::EncryptWallet(const string& strWalletPassphrase)
{
- CRITICAL_BLOCK(cs_mapPubKeys)
CRITICAL_BLOCK(cs_KeyStore)
CRITICAL_BLOCK(cs_vMasterKey)
CRITICAL_BLOCK(cs_pwalletdbEncryption)
@@ -271,7 +270,7 @@ bool CWallet::AddToWallet(const CWalletTx& wtxIn)
if (txout.scriptPubKey == scriptDefaultKey)
{
SetDefaultKey(GetOrReuseKeyFromPool());
- SetAddressBookName(PubKeyToAddress(vchDefaultKey), "");
+ SetAddressBookName(CBitcoinAddress(vchDefaultKey), "");
}
}
@@ -407,8 +406,8 @@ int CWalletTx::GetRequestCount() const
return nRequests;
}
-void CWalletTx::GetAmounts(int64& nGeneratedImmature, int64& nGeneratedMature, list<pair<string, int64> >& listReceived,
- list<pair<string, int64> >& listSent, int64& nFee, string& strSentAccount) const
+void CWalletTx::GetAmounts(int64& nGeneratedImmature, int64& nGeneratedMature, list<pair<CBitcoinAddress, int64> >& listReceived,
+ list<pair<CBitcoinAddress, int64> >& listSent, int64& nFee, string& strSentAccount) const
{
nGeneratedImmature = nGeneratedMature = nFee = 0;
listReceived.clear();
@@ -436,14 +435,9 @@ void CWalletTx::GetAmounts(int64& nGeneratedImmature, int64& nGeneratedMature, l
// but non-standard clients might (so return a list of address/amount pairs)
BOOST_FOREACH(const CTxOut& txout, vout)
{
- string address;
- uint160 hash160;
+ CBitcoinAddress address;
vector<unsigned char> vchPubKey;
- if (ExtractHash160(txout.scriptPubKey, hash160))
- address = Hash160ToAddress(hash160);
- else if (ExtractPubKey(txout.scriptPubKey, NULL, vchPubKey))
- address = PubKeyToAddress(vchPubKey);
- else
+ if (!ExtractAddress(txout.scriptPubKey, NULL, address))
{
printf("CWalletTx::GetAmounts: Unknown transaction type found, txid %s\n",
this->GetHash().ToString().c_str());
@@ -471,25 +465,25 @@ void CWalletTx::GetAccountAmounts(const string& strAccount, int64& nGenerated, i
int64 allGeneratedImmature, allGeneratedMature, allFee;
allGeneratedImmature = allGeneratedMature = allFee = 0;
string strSentAccount;
- list<pair<string, int64> > listReceived;
- list<pair<string, int64> > listSent;
+ list<pair<CBitcoinAddress, int64> > listReceived;
+ list<pair<CBitcoinAddress, int64> > listSent;
GetAmounts(allGeneratedImmature, allGeneratedMature, listReceived, listSent, allFee, strSentAccount);
if (strAccount == "")
nGenerated = allGeneratedMature;
if (strAccount == strSentAccount)
{
- BOOST_FOREACH(const PAIRTYPE(string,int64)& s, listSent)
+ BOOST_FOREACH(const PAIRTYPE(CBitcoinAddress,int64)& s, listSent)
nSent += s.second;
nFee = allFee;
}
CRITICAL_BLOCK(pwallet->cs_mapAddressBook)
{
- BOOST_FOREACH(const PAIRTYPE(string,int64)& r, listReceived)
+ BOOST_FOREACH(const PAIRTYPE(CBitcoinAddress,int64)& r, listReceived)
{
if (pwallet->mapAddressBook.count(r.first))
{
- map<string, string>::const_iterator mi = pwallet->mapAddressBook.find(r.first);
+ map<CBitcoinAddress, string>::const_iterator mi = pwallet->mapAddressBook.find(r.first);
if (mi != pwallet->mapAddressBook.end() && (*mi).second == strAccount)
nReceived += r.second;
}
@@ -941,9 +935,17 @@ bool CWallet::CreateTransaction(const vector<pair<CScript, int64> >& vecSend, CW
dPriority += (double)nCredit * pcoin.first->GetDepthInMainChain();
}
- // Fill a vout back to self with any change
- int64 nChange = nValueIn - nTotalValue;
- if (nChange >= CENT)
+ int64 nChange = nValueIn - nValue - nFeeRet;
+ // if sub-cent change is required, the fee must be raised to at least MIN_TX_FEE
+ // or until nChange becomes zero
+ if (nFeeRet < MIN_TX_FEE && nChange > 0 && nChange < CENT)
+ {
+ int64 nMoveToFee = min(nChange, MIN_TX_FEE - nFeeRet);
+ nChange -= nMoveToFee;
+ nFeeRet += nMoveToFee;
+ }
+
+ if (nChange > 0)
{
// Note: We use a new key here to keep it from being obvious which side is the change.
// The drawback is that by not reusing a previous key, the change may be lost if a
@@ -958,7 +960,7 @@ bool CWallet::CreateTransaction(const vector<pair<CScript, int64> >& vecSend, CW
// Fill a vout to ourself, using same address type as the payment
CScript scriptChange;
- if (vecSend[0].first.GetBitcoinAddressHash160() != 0)
+ if (vecSend[0].first.GetBitcoinAddress().IsValid())
scriptChange.SetBitcoinAddress(vchPubKey);
else
scriptChange << vchPubKey << OP_CHECKSIG;
@@ -1107,7 +1109,7 @@ string CWallet::SendMoney(CScript scriptPubKey, int64 nValue, CWalletTx& wtxNew,
// requires cs_main lock
-string CWallet::SendMoneyToBitcoinAddress(string strAddress, int64 nValue, CWalletTx& wtxNew, bool fAskFee)
+string CWallet::SendMoneyToBitcoinAddress(const CBitcoinAddress& address, int64 nValue, CWalletTx& wtxNew, bool fAskFee)
{
// Check amount
if (nValue <= 0)
@@ -1117,8 +1119,7 @@ string CWallet::SendMoneyToBitcoinAddress(string strAddress, int64 nValue, CWall
// Parse bitcoin address
CScript scriptPubKey;
- if (!scriptPubKey.SetBitcoinAddress(strAddress))
- return _("Invalid bitcoin address");
+ scriptPubKey.SetBitcoinAddress(address);
return SendMoney(scriptPubKey, nValue, wtxNew, fAskFee);
}
@@ -1136,13 +1137,13 @@ int CWallet::LoadWallet(bool& fFirstRunRet)
return nLoadWalletRet;
fFirstRunRet = vchDefaultKey.empty();
- if (!HaveKey(vchDefaultKey))
+ if (!HaveKey(Hash160(vchDefaultKey)))
{
// Create new keyUser and set as default key
RandAddSeedPerfmon();
SetDefaultKey(GetOrReuseKeyFromPool());
- if (!SetAddressBookName(PubKeyToAddress(vchDefaultKey), ""))
+ if (!SetAddressBookName(CBitcoinAddress(vchDefaultKey), ""))
return DB_LOAD_FAIL;
}
@@ -1151,20 +1152,20 @@ int CWallet::LoadWallet(bool& fFirstRunRet)
}
-bool CWallet::SetAddressBookName(const string& strAddress, const string& strName)
+bool CWallet::SetAddressBookName(const CBitcoinAddress& address, const string& strName)
{
- mapAddressBook[strAddress] = strName;
+ mapAddressBook[address] = strName;
if (!fFileBacked)
return false;
- return CWalletDB(strWalletFile).WriteName(strAddress, strName);
+ return CWalletDB(strWalletFile).WriteName(address.ToString(), strName);
}
-bool CWallet::DelAddressBookName(const string& strAddress)
+bool CWallet::DelAddressBookName(const CBitcoinAddress& address)
{
- mapAddressBook.erase(strAddress);
+ mapAddressBook.erase(address);
if (!fFileBacked)
return false;
- return CWalletDB(strWalletFile).EraseName(strAddress);
+ return CWalletDB(strWalletFile).EraseName(address.ToString());
}
@@ -1263,7 +1264,7 @@ void CWallet::ReserveKeyFromKeyPool(int64& nIndex, CKeyPool& keypool)
setKeyPool.erase(setKeyPool.begin());
if (!walletdb.ReadPool(nIndex, keypool))
throw runtime_error("ReserveKeyFromKeyPool() : read failed");
- if (!HaveKey(keypool.vchPubKey))
+ if (!HaveKey(Hash160(keypool.vchPubKey)))
throw runtime_error("ReserveKeyFromKeyPool() : unknown key in key pool");
assert(!keypool.vchPubKey.empty());
printf("keypool reserve %"PRI64d"\n", nIndex);
diff --git a/src/wallet.h b/src/wallet.h
index c19b3f43c7..51dfa5df5b 100644
--- a/src/wallet.h
+++ b/src/wallet.h
@@ -53,7 +53,7 @@ public:
std::map<uint256, int> mapRequestCount;
mutable CCriticalSection cs_mapRequestCount;
- std::map<std::string, std::string> mapAddressBook;
+ std::map<CBitcoinAddress, std::string> mapAddressBook;
mutable CCriticalSection cs_mapAddressBook;
std::vector<unsigned char> vchDefaultKey;
@@ -81,7 +81,7 @@ public:
bool CommitTransaction(CWalletTx& wtxNew, CReserveKey& reservekey);
bool BroadcastTransaction(CWalletTx& wtxNew);
std::string SendMoney(CScript scriptPubKey, int64 nValue, CWalletTx& wtxNew, bool fAskFee=false);
- std::string SendMoneyToBitcoinAddress(std::string strAddress, int64 nValue, CWalletTx& wtxNew, bool fAskFee=false);
+ std::string SendMoneyToBitcoinAddress(const CBitcoinAddress& address, int64 nValue, CWalletTx& wtxNew, bool fAskFee=false);
bool TopUpKeyPool();
void ReserveKeyFromKeyPool(int64& nIndex, CKeyPool& keypool);
@@ -104,10 +104,10 @@ public:
}
bool IsChange(const CTxOut& txout) const
{
- std::vector<unsigned char> vchPubKey;
- if (ExtractPubKey(txout.scriptPubKey, this, vchPubKey))
+ CBitcoinAddress address;
+ if (ExtractAddress(txout.scriptPubKey, this, address))
CRITICAL_BLOCK(cs_mapAddressBook)
- if (!mapAddressBook.count(PubKeyToAddress(vchPubKey)))
+ if (!mapAddressBook.count(address))
return true;
return false;
}
@@ -171,10 +171,10 @@ public:
// bool BackupWallet(const std::string& strDest);
// requires cs_mapAddressBook lock
- bool SetAddressBookName(const std::string& strAddress, const std::string& strName);
+ bool SetAddressBookName(const CBitcoinAddress& address, const std::string& strName);
// requires cs_mapAddressBook lock
- bool DelAddressBookName(const std::string& strAddress);
+ bool DelAddressBookName(const CBitcoinAddress& address);
void UpdatedTransaction(const uint256 &hashTx)
{
@@ -464,8 +464,8 @@ public:
return nChangeCached;
}
- void GetAmounts(int64& nGeneratedImmature, int64& nGeneratedMature, std::list<std::pair<std::string /* address */, int64> >& listReceived,
- std::list<std::pair<std::string /* address */, int64> >& listSent, int64& nFee, std::string& strSentAccount) const;
+ void GetAmounts(int64& nGeneratedImmature, int64& nGeneratedMature, std::list<std::pair<CBitcoinAddress, int64> >& listReceived,
+ std::list<std::pair<CBitcoinAddress, int64> >& listSent, int64& nFee, std::string& strSentAccount) const;
void GetAccountAmounts(const std::string& strAccount, int64& nGenerated, int64& nReceived,
int64& nSent, int64& nFee) const;