Commit Graph

78 Commits

Author SHA1 Message Date
Gavin Andresen 895c12943b Merge pull request #1042 from gavinandresen/use_ssl_cleanup
Remove USE_SSL #define
2012-04-05 07:34:45 -07:00
Gavin Andresen 5ce4c2a23a Remove USE_SSL #define 2012-04-04 21:19:27 -04:00
Gavin Andresen ea8c55cfd7 Enable addmultisigaddress RPC call for main network 2012-04-04 16:01:27 -04:00
Wladimir J. van der Laan 5a60b66a9d Use a messagebox to display the error when -server is provided without providing a rpc password 2012-04-04 09:37:26 +02:00
Wladimir J. van der Laan 1a3f0da922 support RPC stop and encryptwallet with UI 2012-04-04 09:35:01 +02:00
Wladimir J. van der Laan 52d3a48128 VC2010 compile fixes 2012-04-03 20:22:41 +02:00
Pieter Wuille 439e1497e1 Introduce explicit -walletupgrade option
Do not automatically change the wallet format unless the user takes an
explicit action that implies an upgrade (encrypting, for now), or uses
-walletupgrade.

-walletupgrade optionally takes an integer argument: the client version
up to which upgrading is allowed. Without an argument, it is upgraded
to latest supported version. If an argument to -walletupgrade is
provided at the time the wallet is created, the new wallet will initially
not use features beyond that version.

Third, the current wallet version number is reported in getinfo.
2012-03-22 23:47:29 +01:00
Wladimir J. van der Laan 4a43dfbf3e replace call to PrintConsole with call to error()
As these are equivalent functions, this cleans up the source a bit.
Also remove PrintConsole() as this was the only use.
2012-03-21 20:33:53 +01:00
Gregory Maxwell 82a10c8170 Resolves issue #922 - "wallet passphrase timeout of several years doesn't work"
2^31 milliseconds is only about 25 days. Also clamps Sleep() to 10 years,
because it currently sleeps for 0 seconds when the sleep time would cross
2^31 seconds since the epoch. Hopefully boost will be fixed by 2028.
2012-03-10 17:38:37 -05:00
Gavin Andresen 972060ce0e bitcoind changes to stop storing settings in wallet.dat. 2012-02-26 23:21:33 +01:00
Luke Dashjr 34f8788915 Cleanup JSON-RPC getblock output to be consistent
- Add "size" and "bits"
- Rename "blockcount" to "height"
- Rename "hashprevious" and "hashnext" to "previousblockhash" and "nextblockhash" (respectively)
2012-02-22 12:31:28 -05:00
Gavin Andresen 0a6b081cca Merge branch 'testnetmining' of github.com:gavinandresen/bitcoin-git 2012-02-17 13:48:01 -05:00
Gavin Andresen 0f8cb5db73 Fix issue #848 : broken mining on testnet 2012-02-16 11:37:54 -05:00
Pieter Wuille c59881eaee Symbolic names for threads
Introduce an enum threadId, and use symbolic indices when accessing
vnThreadsRunning.
2012-02-16 12:43:06 +01:00
Pieter Wuille aa625ed6ed Extra wallet locking fixes
* Fix sign error in calculation of seconds to sleep
* Do not mix GetTime() (seconds) and Sleep() (milliseconds)
* Do not sleep forever if walletlock() is called
* Do locking within critical section
2012-02-11 21:59:39 +01:00
Pieter Wuille b0529ffd95 Fix wallet locking locking 2012-02-11 21:59:39 +01:00
Pieter Wuille 402deef944 Fix #822 2012-02-11 15:25:42 +01:00
Gavin Andresen 882164196e Update all copyrights to 2012 2012-02-07 11:28:30 -05:00
Gregory Maxwell b04f301c8e Have bitcoind recommend a secure RPC password. Increase invalid password delay.
Help users avoid insecure configurations a bit by recommending a
secure RPC password and increasing the incorrect password delay.

This may open up a RPC DOS for users with exposed RPC ports and
short passwords. Since users shouldn't have exposed RPC ports OR
short passwords, the DOS risk is preferable to the compromise
risk.

Also logs the client IP address for incorrect attempts.
2012-02-05 02:58:35 -05:00
Luke Dashjr 2bc4fd609c Bitcoin-Qt signmessage GUI (pull request #582) 2012-01-27 08:41:55 +01:00
Gavin Andresen dc77dce07c Fixed addmultisigaddress if looking up public keys from locked wallets. 2012-01-23 12:04:34 -05:00
Forrest Voight ab84512258 Added mintime and curtime to RPC getmemorypool 2012-01-14 19:23:37 -05:00
Forrest Voight 52a3d2635c Separated COINBASE_FLAGS out into main.h and made RPC getmemorypool return it 2012-01-14 19:22:24 -05:00
Gavin Andresen 9e8818ec9d Remove base58 encoding from validateaddress/addmultisigaddress
base58-encoding of full/compressed public keys needs more thought; it probably makes sense to define a base58 encoding that includes a version byte and a checksum. So just support hex and bitcoin-address encodings for now.
2012-01-13 10:22:24 -05:00
Gavin Andresen 922e8e2929 Replace OP_EVAL (BIP 12) with Pay-to-script-hash (BIP 16). 2012-01-13 10:22:23 -05:00
Gavin Andresen f290a649f9 Merge branch 'getmininginfo' of https://github.com/luke-jr/bitcoin 2012-01-13 10:06:05 -05:00
Gavin Andresen a1de57a063 Compile with extra warnings turned on. And more makefile/code tidying up.
This turns on most gcc warnings, and removes some unused variables and other code that triggers warnings.
Exceptions are:
 -Wno-sign-compare : triggered by lots of comparisons of signed integer to foo.size(), which is unsigned.
 -Wno-char-subscripts : triggered by the convert-to-hex functions (I may fix this in a future commit).
2012-01-12 20:02:47 -05:00
Luke Dashjr 340f0876ea collect more info on tx pooling and block finding for getmininginfo 2012-01-12 19:47:39 -05:00
Luke Dashjr 6950bb6200 Add new "getmininginfo" JSON-RPC method, with mining-only fields moved out of "getinfo" 2012-01-12 19:47:23 -05:00
Pieter Wuille 11529c6e4f Compressed pubkeys
This patch enabled compressed pubkeys when -compressedpubkeys is passed.
These are 33 bytes instead of 65, and require only marginally more CPU
power when verifying. Compressed pubkeys have a different corresponding
address, so it is determined at generation. When -compressedpubkeys is
given, all newly generated addresses will use a compressed key, while
older/other addresses keep using normal keys. Unpatched clients will
relay and verify these transactions.
2012-01-09 15:18:19 +01:00
Gavin Andresen 8a53cb0b9d New RPC commands: getblockhash and getblock 2011-12-23 16:26:38 -05:00
Gavin Andresen 2e17ac83c6 Fix broken ExtractAddress (refactored, made callers check for addresses in keystore if they care) 2011-12-22 15:57:31 -05:00
Wladimir J. van der Laan bde280b9a4 Revert "Use standard C99 (and Qt) types for 64-bit integers"
This reverts commit 21d9f36781.
2011-12-21 22:33:19 +01:00
Luke Dashjr 21d9f36781 Use standard C99 (and Qt) types for 64-bit integers 2011-12-20 16:52:59 -05:00
Gavin Andresen 595925592d Merge branch 'op_eval' 2011-12-20 14:43:31 -05:00
Gavin Andresen 26ce92b352 Use std::numeric_limits<> for typesafe INT_MAX/etc 2011-12-19 19:10:34 -05:00
Gavin Andresen bafb43d6c1 Merge branch 'txn_block_info' of https://github.com/luke-jr/bitcoin 2011-12-19 15:14:22 -05:00
Gavin Andresen 2a45a494b0 Use block times for 'hard' OP_EVAL switchover, and refactored EvalScript
so it takes a flag for how to interpret OP_EVAL.
Also increased IsStandard size of scriptSigs to 500 bytes, so
a 3-of-3 multisig transaction IsStandard.
2011-12-19 13:24:48 -05:00
Gavin Andresen fae3e2aab6 Disable addmultisigaddress if not testnet 2011-12-19 13:24:48 -05:00
Gavin Andresen e679ec969c OP_EVAL implementation
OP_EVAL is a new opcode that evaluates an item on the stack as a script.
It enables a new type of bitcoin address that needs an arbitrarily
complex script to redeem.
2011-12-19 12:40:19 -05:00
Gavin Andresen bf798734db Support 3 new multisignature IsStandard transactions
Initial support for (a and b), (a or b), and 2-of-3 escrow
transactions (where a, b, and c are keys).
2011-12-19 12:40:19 -05:00
Gavin Andresen 99a289f531 Merge pull request #574 from sipa/dumpprivkey
Dumpprivkey
2011-12-19 07:27:25 -08:00
Gavin Andresen f8ded588a2 Implement BIP 14 : separate protocol version from client version 2011-12-19 10:24:23 -05:00
Pieter Wuille 95d888a6d1 Key import and export
Introduces two new RPC calls:
* dumpprivkey: retrieve the private key corresponding to an address
* importprivkey: add a private key to your wallet

The private key format is analoguous to the address format. It is
a 51-character base58-encoded string, that includes a version number
and a checksum.

Includes patch by mhanne:
* add optional account parameter for importprivkey, if omitted use default
2011-12-17 21:49:48 +01:00
Pieter Wuille 30ab2c9c46 Preparations for key import/export 2011-12-17 21:49:48 +01:00
Pieter Wuille 93db3fceac Add GetSecret() and GetKeys() to CKeyStore 2011-12-17 21:49:47 +01:00
Gavin Andresen f81ce5bd6d Speed up RPC authentication (reworked pull from Joel Katz) 2011-12-01 15:55:25 -05:00
Dylan Noblesmith 94f778bdeb Implement an mlock()'d string class for storing passphrases
SecureString is identical to std::string except with secure_allocator
substituting for std::allocator. This makes casting between them
impossible, so converting between the two at API boundaries requires
calling ::c_str() for now.
2011-11-26 06:02:04 +00:00
Gavin Andresen 0310cd6403 Merge pull request #632 from mndrix/deprecate-getblocknumber
Deprecate RPC getblocknumber
2011-11-21 11:31:42 -08:00
Gavin Andresen d764d9161e Obsolete keypool and make sure database removes log files on shutdown. 2011-11-15 09:30:16 -05:00