aboutsummaryrefslogtreecommitdiff
path: root/src/wallet/wallet_rpc_server.cpp (unfollow)
AgeCommit message (Collapse)AuthorFilesLines
2019-05-21Fix allow any cert mode in wallet rpc when configured over rpcLee Clagett1-1/+5
2019-05-21Add ssl_options support to monerod's rpc mode.Lee Clagett1-50/+1
2019-05-11wallet: fix certificate fingerprint length checkmoneromooo-monero1-1/+1
Fixed by crCr62U0
2019-05-10wallet_rpc_server: use original addresses in destinations in get_transfersmoneromooo-monero1-1/+9
And add them for pending transfers, where they were missing
2019-04-30wallet_rpc_server: reject standalone short payment id in address bookmoneromooo-monero1-4/+4
2019-04-26change SSL certificate fingerprint whitelisting from SHA1 to SHA-256moneromooo-monero1-0/+9
SHA1 is too close to bruteforceable
2019-04-25wallet_rpc_server: adding missing return on error in set_daemonmoneromooo-monero1-0/+1
2019-04-25wallet_rpc_server: return false on error in set_log_categoriesmoneromooo-monero1-1/+1
Reported by SmajeNz0
2019-04-25wallet_rpc_server: fix crash in validate_address if no wallet is loadedmoneromooo-monero1-1/+2
Reported by SmajeNz0
2019-04-20wallet_rpc_server: add block_height and frozen to incoming_transfersmoneromooo-monero1-0/+2
2019-04-17wallet_rpc_server: add unlocked field to incoming_transfers outputmoneromooo-monero1-0/+1
2019-04-16wallet_rpc_server: set suggested_confirmations_threshold for pool txesmoneromooo-monero1-5/+3
2019-04-16wallet_rpc_server: add set_log_level/set_log_categoriesmoneromooo-monero1-0/+33
2019-04-15wallet_rpc_server: remove unused codemoneromooo-monero1-5/+1
2019-04-12wallet_rpc_server: fix inconsistent wallet caches on reloadmoneromooo-monero1-41/+48
Loading the same wallet as the currently loaded one would autosave the current state after loading it, leading to some kind of rollback effect. We now save before loading to avoid this. If loading fails, it means the current wallet will be saved (or maybe not, depending on where the failure occurs: most of the sanity checks occur before saving). There is a new autosave_current flag to open/restore calls so the (enabled by default) autosave can be skipped.
2019-04-10wallet_rpc_server: add a all flag to export_outputsmoneromooo-monero1-1/+1
if we don't want to export new outputs only
2019-04-07Enabling daemon-rpc SSL now requires non-system CA verificationLee Clagett1-7/+16
If `--daemon-ssl enabled` is set in the wallet, then a user certificate, fingerprint, or onion/i2p address must be provided.
2019-04-07Pass SSL arguments via one class and use shared_ptr instead of referenceLee Clagett1-9/+29
2019-04-06Change default SSL to "enabled" if user specifies fingerprint/certificateLee Clagett1-4/+9
Currently if a user specifies a ca file or fingerprint to verify peer, the default behavior is SSL autodetect which allows for mitm downgrade attacks. It should be investigated whether a manual override should be allowed - the configuration is likely always invalid.
2019-04-06Change SSL certificate file list to OpenSSL builtin load_verify_locationLee Clagett1-15/+5
Specifying SSL certificates for peer verification does an exact match, making it a not-so-obvious alias for the fingerprints option. This changes the checks to OpenSSL which loads concatenated certificate(s) from a single file and does a certificate-authority (chain of trust) check instead. There is no drop in security - a compromised exact match fingerprint has the same worse case failure. There is increased security in allowing separate long-term CA key and short-term SSL server keys. This also removes loading of the system-default CA files if a custom CA file or certificate fingerprint is specified.
2019-04-06wallet: add number of blocks required for the balance to fully unlockmoneromooo-monero1-4/+5
2019-04-04wallet: new option to start background miningmoneromooo-monero1-0/+56
The setup-background-mining option can be used to select background mining when a wallet loads. The user will be asked the first time the wallet is created.
2019-04-01wallet: add number of blocks required for the balance to fully unlockmoneromooo-monero1-4/+5
2019-04-01wallet_rpc_server: error out on getting the spend key from a hot walletmoneromooo-monero1-1/+7
2019-04-01wallet_rpc_server: always fill out subaddr_indices in get_transfersmoneromooo-monero1-0/+2
It was not filled out for in and pool types
2019-04-01wallet_rpc_server: error out on getting the spend key from a hot walletmoneromooo-monero1-1/+7
2019-04-01wallet_rpc_server: add a set_daemon RPCmoneromooo-monero1-0/+34
2019-04-01wallet_rpc_server: always fill out subaddr_indices in get_transfersmoneromooo-monero1-0/+2
It was not filled out for in and pool types
2019-04-01wallet_rpc_server: set confirmations to 0 for pending/pool txesmoneromooo-monero1-1/+1
2019-03-25wallet_rpc_server: allow english/local language names in create_walletmoneromooo-monero1-3/+9
and return both in get_languages
2019-03-25wallet: fix memory only walletsmoneromooo-monero1-16/+5
at least when using restore_deterministic_wallet
2019-03-24wallet: use original user address if we have a short payment idmoneromooo-monero1-1/+1
2019-03-21wallet_rpc_server: remove mixin from transfer RPCsmoneromooo-monero1-36/+4
it's been a while, only use ring_size now
2019-03-17wallet_rpc_server: new auto_refresh RPCmoneromooo-monero1-1/+33
It can enable/disable auto refresh, and set auto refresh period
2019-03-15wallet_rpc_server: fix buffer read overflow in string assignmentmoneromooo-monero1-1/+1
2019-03-13wallet_rpc_server: include out subaddress indices in get_transfersmoneromooo-monero1-0/+4
2019-03-13wallet_rpc_server: add missing --rpc-ssl-allowed-fingerprintsmoneromooo-monero1-0/+1
2019-03-05Update 2019 copyrightbinaryFate1-1/+1
2019-03-05add multisig tx sets to describe_transfer rpc endpointspoke01-22/+52
2019-03-05epee: add SSL supportMartijn Otto1-1/+6
RPC connections now have optional tranparent SSL. An optional private key and certificate file can be passed, using the --{rpc,daemon}-ssl-private-key and --{rpc,daemon}-ssl-certificate options. Those have as argument a path to a PEM format private private key and certificate, respectively. If not given, a temporary self signed certificate will be used. SSL can be enabled or disabled using --{rpc}-ssl, which accepts autodetect (default), disabled or enabled. Access can be restricted to particular certificates using the --rpc-ssl-allowed-certificates, which takes a list of paths to PEM encoded certificates. This can allow a wallet to connect to only the daemon they think they're connected to, by forcing SSL and listing the paths to the known good certificates. To generate long term certificates: openssl genrsa -out /tmp/KEY 4096 openssl req -new -key /tmp/KEY -out /tmp/REQ openssl x509 -req -days 999999 -sha256 -in /tmp/REQ -signkey /tmp/KEY -out /tmp/CERT /tmp/KEY is the private key, and /tmp/CERT is the certificate, both in PEM format. /tmp/REQ can be removed. Adjust the last command to set expiration date, etc, as needed. It doesn't make a whole lot of sense for monero anyway, since most servers will run with one time temporary self signed certificates anyway. SSL support is transparent, so all communication is done on the existing ports, with SSL autodetection. This means you can start using an SSL daemon now, but you should not enforce SSL yet or nothing will talk to you.
2019-03-05wallet_rpc_server: avoid repeated string allocations when parsingmoneromooo-monero1-20/+14
2019-03-04various: remove unused variablesmoneromooo-monero1-5/+0
2019-03-02Simplify RPC endpoint, emoving second RPC endpoint generate_from_view_keyJoel1-15/+4
2019-02-21Remove code duplicationJoel1-157/+18
2019-02-20wallet-rpc: get balance for all accounts and subaddressesstoffu1-20/+44
2019-02-19Add generate_from_view_key RPC methodJoel1-0/+152
2019-02-19Add generate_from_keys RPC methodJoel1-0/+166
2019-02-17wallet-rpc: get transfers for all accounts and subaddressesJethro Grassie1-4/+12
2019-02-14wallet_rpc_server: add a validate_address RPCmoneromooo-monero1-0/+51
2019-02-02epee: add SSL supportmoneromooo-monero1-1/+31
RPC connections now have optional tranparent SSL. An optional private key and certificate file can be passed, using the --{rpc,daemon}-ssl-private-key and --{rpc,daemon}-ssl-certificate options. Those have as argument a path to a PEM format private private key and certificate, respectively. If not given, a temporary self signed certificate will be used. SSL can be enabled or disabled using --{rpc}-ssl, which accepts autodetect (default), disabled or enabled. Access can be restricted to particular certificates using the --rpc-ssl-allowed-certificates, which takes a list of paths to PEM encoded certificates. This can allow a wallet to connect to only the daemon they think they're connected to, by forcing SSL and listing the paths to the known good certificates. To generate long term certificates: openssl genrsa -out /tmp/KEY 4096 openssl req -new -key /tmp/KEY -out /tmp/REQ openssl x509 -req -days 999999 -sha256 -in /tmp/REQ -signkey /tmp/KEY -out /tmp/CERT /tmp/KEY is the private key, and /tmp/CERT is the certificate, both in PEM format. /tmp/REQ can be removed. Adjust the last command to set expiration date, etc, as needed. It doesn't make a whole lot of sense for monero anyway, since most servers will run with one time temporary self signed certificates anyway. SSL support is transparent, so all communication is done on the existing ports, with SSL autodetection. This means you can start using an SSL daemon now, but you should not enforce SSL yet or nothing will talk to you.
2019-02-02wallet_rpc_server: remove detached short payment ids supportmoneromooo-monero1-5/+1
2019-01-28rpc: fix internal daemon calls in restricted rpc getting partial datamoneromooo-monero1-76/+76
2019-01-18core, wallet: remember original text version of destination addressmoneromooo-monero1-0/+2
2018-12-24wallet_rpc_server: add all field to export_key_imagesmoneromooo-monero1-1/+1
To use if you want all key images, not just the ones for recently imported outputs
2018-11-23wallet_rpc_server: do not use RPC data if the call failedmoneromooo-monero1-1/+2
Found by codacy.com
2018-11-05wallet_rpc_server: account for watch-only/non-deterministic/multisig when ↵stoffu1-1/+32
querying seed Followup on #4653
2018-11-04wallet2: only export necessary outputs and key imagesmoneromooo-monero1-6/+7
and disable annoying test that requires ridiculous amounts of skullduggery every time some format changes
2018-11-03wallet: add a non destructive blockchain rescanmoneromooo-monero1-1/+1
2018-11-02wallet_rpc_server: include additional tx keys in sign_transfer responsestoffu1-0/+4
Followup on #4552
2018-10-29wallet-rpc: add on_restore_deterministic RPC call.Hasan Pekdemir1-0/+194
2018-10-18Add RPC error code for non-deterministic walletMichał Sałaban1-0/+1
2018-10-16wallet_rpc_server: fix change_wallet_password RPCmoneromooo-monero1-2/+1
2018-10-11Return appropriate RPC error code when key image signature check failsMichał Sałaban1-0/+5
2018-10-10wallet_rpc_server: optionally return tx keys in sign_transfermoneromooo-monero1-0/+2
2018-10-09wallet_rpc_server: add describe_transfer RPCmoneromooo-monero1-0/+165
for unsigned tx sets using a view only wallet
2018-10-01Arbitrary M/N multisig schemes:naughtyfox1-1/+50
* support in wallet2 * support in monero-wallet-cli * support in monero-wallet-rpc * support in wallet api * support in monero-gen-trusted-multisig * unit tests for multisig wallets creation
2018-10-01wallet_rpc_server: include all transfer records for a txidmoneromooo-monero1-8/+14
Since subaddresses were added, a tx can now create more than one payment
2018-10-01wallet: fix --generate-from-json using wrong passwordmoneromooo-monero1-1/+2
2018-09-29Merge pull request #4459Riccardo Spagni1-0/+3
bcf3f6af fuzz_tests: catch unhandled exceptions (moneromooo-monero) 3ebd05d4 miner: restore stream flags after changing them (moneromooo-monero) a093092e levin_protocol_handler_async: do not propagate exception through dtor (moneromooo-monero) 1eebb82b net_helper: do not propagate exceptions through dtor (moneromooo-monero) fb6a3630 miner: do not propagate exceptions through dtor (moneromooo-monero) 2e2139ff epee: do not propagate exception through dtor (moneromooo-monero) 0749a8bd db_lmdb: do not propagate exceptions in dtor (moneromooo-monero) 1b0afeeb wallet_rpc_server: exit cleanly on unhandled exceptions (moneromooo-monero) 418a9936 unit_tests: catch unhandled exceptions (moneromooo-monero) ea7f9543 threadpool: do not propagate exceptions through the dtor (moneromooo-monero) 6e855422 gen_multisig: nice exit on unhandled exception (moneromooo-monero) 53df2deb db_lmdb: catch error in mdb_stat calls during migration (moneromooo-monero) e67016dd blockchain_blackball: catch failure to commit db transaction (moneromooo-monero) 661439f4 mlog: don't remove old logs if we failed to rename the current file (moneromooo-monero) 5fdcda50 easylogging++: test for NULL before dereference (moneromooo-monero) 7ece1550 performance_test: fix bad last argument calling add_arg (moneromooo-monero) a085da32 unit_tests: add check for page size > 0 before dividing (moneromooo-monero) d8b1ec8b unit_tests: use std::shared_ptr to shut coverity up about leaks (moneromooo-monero) 02563bf4 simplewallet: top level exception catcher to print nicer messages (moneromooo-monero) c57a65b2 blockchain_blackball: fix shift range for 32 bit archs (moneromooo-monero)
2018-09-29Merge pull request #4427Riccardo Spagni1-1/+1
83debef9 wallet_rpc_server: remove verbose field in incoming_transfers query (moneromooo-monero)
2018-09-28wallet_rpc_server: remove verbose field in incoming_transfers querymoneromooo-monero1-1/+1
The key image (which was only supplied if verbose was true) is readily available, not a secret key, and it was only modelled after the CLI command because it's a bit spammy for the CLI.
2018-09-24wallet_rpc_server: include account index in incoming_transfers RPCmoneromooo-monero1-1/+1
2018-09-22wallet_rpc_server: fix --run-as-service on Windowsmoneromooo-monero1-0/+1
Thanks iDunk for the windows testing
2018-09-21wallet_rpc_server: fix build for windowsmoneromooo-monero1-8/+17
Thanks iDunk for building patches on windows
2018-09-18wallet: add 'outputs' option for sweep_* commandswhythat1-2/+16
'outputs' option allows to specify the number of separate outputs of smaller denomination that will be created by sweep operation. rebased by moneromooo
2018-09-15add daemonizer to rpc walletjcktm1-111/+164
2018-09-12wallet: use wipeable_string in more places where a secret is usedmoneromooo-monero1-15/+24
2018-09-11v8: per byte fee, pad bulletproofs, fixed 11 ring sizemoneromooo-monero1-1/+0
2018-09-09wallet_rpc_server: remove some unused codemoneroexamples1-9/+0
2018-09-08wallet_rpc_server: error out if wallet-file and wallet-dir are both usedmoneromooo-monero1-1/+6
2018-09-05wallet rpc: Add close_wallet RPCGuillaume LE VAILLANT1-0/+42
And close the current wallet automatically if necessary when opening another wallet.
2018-08-23wallet: store trusted-daemon flag in wallet2stoffu1-23/+12
2018-08-22rpc-wallet: refresh command addedDusan Klinec1-0/+22
2018-08-17[#4027] add change_wallet_password wallet rpc commandartyomsol1-0/+32
2018-08-16store secret keys encrypted where possiblemoneromooo-monero1-5/+5
The secret spend key is kept encrypted in memory, and decrypted on the fly when needed. Both spend and view secret keys are kept encrypted in a JSON field in the keys file. This avoids leaving the keys in memory due to being manipulated by the JSON I/O API.
2018-08-16wallet: wipe seed from memory where appropriatemoneromooo-monero1-1/+3
2018-08-16wallet2: make --restricted-rpc available for wallet RPC onlystoffu1-32/+35
2018-08-03wallet: distinguish coinbase from other txes in show_transfersmoneromooo-monero1-1/+1
2018-07-31wallet-rpc: add get_address_index commandstoffu1-0/+21
2018-07-31wallet-rpc: filter getbalance response by address indexstoffu1-4/+10
2018-07-20wallet rpc: support making integrated address of given standard addressstoffu1-1/+33
2018-06-27wallet: include a suggested number of confirmations based on amountmoneromooo-monero1-0/+19
This is based on how much an attacking miner stands to lose in block rewardy by mining a private chain which double spends a payment. This is not foolproof, since mining is based on luck, and breaks down as the attacking miner nears 50% of the network hash rate, and the estimation is based on a constant block reward.
2018-06-21wallet-rpc.getaddress: throw if index is out of boundstoffu1-0/+2
2018-06-15Fix RPC crashes that didn't check for an open walletHoward Chu1-0/+6
2018-06-13wallet: on first refresh, start off with a quantized heightmoneromooo-monero1-2/+2
for privacy reasons, so an untrusted node can't easily track wallets from IP address to IP address, etc. The granularity is 1024 blocks, which is about a day and a half.
2018-06-03wallet-rpc: watch-only and cold wallet features addedDusan Klinec1-7/+217
- unsigned_txset, signed_txset in transfer / submit_transfer / sign_transfer - export_outputs, import_outputs Squashed commits: [f4d9f3d4] wallet-rpc: do_not_relay removed from submit_transfer [5b16a86f] wallet-rpc: review-fix - method signature changes, renaming [b7fbb10a] wallet-rpc: naming fixes (unsigned vs signed), consts renamed [8c7d2727] wallet-rpc: sign_transfer added [481d024a] wallet2: sign_tx splitted to work with strings and structs, more granular [2a474db9] wallet-rpc: wallet2::load_unsigned_tx split to load from str, file [b1e3a018] wallet-rpc: review fix, load_tx_from_str variable rename [1f6373be] wallet-rpc: review fix: save_tx_to_{str,file} [2a08eafc] wallet-rpc: review comments fixes - redundant this removed from wallet2.cpp - load_tx_from_str, load_tx_from_file [43498052] wallet-rpc: submit_transfer added [9c45d1ad] wallet-rpc: watch_only check, return unsigned_txset [62831396] wallet2: added string variants to load_tx, save_tx - analogously to save_multisig_tx - required for monero-wallet-rpc to support watch-only wallet
2018-04-22wallet cli/rpc: terminate execution with code 0 when --help or --version is ↵stoffu1-1/+7
given
2018-04-14wallet_rpc_server: add a get_version RPCmoneromooo-monero1-0/+6
2018-03-15Fix typos in various filesDimitris Apostolou1-1/+1
2018-03-15wallet2+cli+rpc: eliminate redundant m_http_client from cli/rpc and delegate ↵stoffu1-5/+3
calls to wallet2
2018-03-05allow using ring size instead of mixin for rpc transfercryptochangements341-4/+36
2018-03-05Stagenetstoffu1-15/+23
2018-02-08wallet: suggest the use of sweep_unmixable when not_enough_outs_to_mix is thrownstoffu1-1/+1
2018-02-05Add default value to max_height, otherwise it's 0Michał Sałaban1-2/+3
2018-01-31wallet-rpc: take subaddress account as arg for get_transfer_by_txidstoffu1-4/+11
2018-01-31wallet-rpc: rename *_INDEX_OUTOFBOUND into *_INDEX_OUT_OF_BOUNDSstoffu1-2/+2
2018-01-29Fixed typos and wording tweaksMaxithi1-9/+9
2018-01-29Return appropriate error code when there's no connection to daemonMichał Sałaban1-0/+5
2018-01-28Return appropriate error code when not enough money for txMichał Sałaban1-0/+5
2018-01-28wallet: automatically use low priority if safe (no backlog & recent blocks ↵stoffu1-4/+8
not full)
2018-01-26Update 2018 copyrightxmr-eric1-1/+1
2018-01-26wallet rpc: show fees when querying incoming transfersstoffu1-2/+2
2018-01-14Allow retrieving spend key via RPCMichał Sałaban1-0/+4
2018-01-10Reserve proofstoffu1-0/+60
2018-01-10epee: remove dependency on commonmoneromooo-monero1-1/+2
2017-12-27Resolve addresses in get_transfersMichał Sałaban1-0/+4
2017-12-25Revert "return subaddress in get_bulk_payments"moneromooo-monero1-1/+0
This reverts commit b60f48f0e31c17638f771042887b2fffdbad15b4.
2017-12-24wallet_rpc_server: fix wallet leak on error exitmoneromooo-monero1-0/+2
Makes it easier to debug leaks
2017-12-20wallet_rpc_server: factor transfer info return and add missing infomoneromooo-monero1-301/+103
Additional tx keys, amounts and fees were missing in some cases
2017-12-18check accessing an element past the end of a containermoneromooo-monero1-5/+12
2017-12-18add empty container sanity checks when using front() and back()moneromooo-monero1-0/+7
2017-12-18wallet-rpc: added receiving address to res of get(_bulk)_payments; selective ↵stoffu1-4/+18
addresses for getaddress
2017-12-18Account taggingstoffu1-0/+70
2017-12-17wallet: factor multisig info parsingmoneromooo-monero1-50/+1
2017-12-17wallet: use raw encrypted data in multisig import/export RPCmoneromooo-monero1-47/+7
2017-12-17wallet: add multisig sign/submit RPCmoneromooo-monero1-82/+361
2017-12-17Match surae's recommendation to derive multisig keysmoneromooo-monero1-3/+3
2017-12-17wallet: guard against partly initialized multisig walletmoneromooo-monero1-4/+25
2017-12-17add multisig core test and factor multisig building blocksmoneromooo-monero1-14/+1
2017-12-17N-1/N multisigmoneromooo-monero1-11/+93
2017-12-17multisig address generation RPCmoneromooo-monero1-0/+234
2017-12-17gen_multisig: generates multisig wallets if participants trust each othermoneromooo-monero1-0/+1
2017-12-17Add N/N multisig tx generation and signingmoneromooo-monero1-0/+1
Scheme by luigi1111: Multisig for RingCT on Monero 2 of 2 User A (coordinator): Spendkey b,B Viewkey a,A (shared) User B: Spendkey c,C Viewkey a,A (shared) Public Address: C+B, A Both have their own watch only wallet via C+B, a A will coordinate spending process (though B could easily as well, coordinator is more needed for more participants) A and B watch for incoming outputs B creates "half" key images for discovered output D: I2_D = (Hs(aR)+c) * Hp(D) B also creates 1.5 random keypairs (one scalar and 2 pubkeys; one on base G and one on base Hp(D)) for each output, storing the scalar(k) (linked to D), and sending the pubkeys with I2_D. A also creates "half" key images: I1_D = (Hs(aR)+b) * Hp(D) Then I_D = I1_D + I2_D Having I_D allows A to check spent status of course, but more importantly allows A to actually build a transaction prefix (and thus transaction). A builds the transaction until most of the way through MLSAG_Gen, adding the 2 pubkeys (per input) provided with I2_D to his own generated ones where they are needed (secret row L, R). At this point, A has a mostly completed transaction (but with an invalid/incomplete signature). A sends over the tx and includes r, which allows B (with the recipient's address) to verify the destination and amount (by reconstructing the stealth address and decoding ecdhInfo). B then finishes the signature by computing ss[secret_index][0] = ss[secret_index][0] + k - cc[secret_index]*c (secret indices need to be passed as well). B can then broadcast the tx, or send it back to A for broadcasting. Once B has completed the signing (and verified the tx to be valid), he can add the full I_D to his cache, allowing him to verify spent status as well. NOTE: A and B *must* present key A and B to each other with a valid signature proving they know a and b respectively. Otherwise, trickery like the following becomes possible: A creates viewkey a,A, spendkey b,B, and sends a,A,B to B. B creates a fake key C = zG - B. B sends C back to A. The combined spendkey C+B then equals zG, allowing B to spend funds at any time! The signature fixes this, because B does not know a c corresponding to C (and thus can't produce a signature). 2 of 3 User A (coordinator) Shared viewkey a,A "spendkey" j,J User B "spendkey" k,K User C "spendkey" m,M A collects K and M from B and C B collects J and M from A and C C collects J and K from A and B A computes N = nG, n = Hs(jK) A computes O = oG, o = Hs(jM) B anc C compute P = pG, p = Hs(kM) || Hs(mK) B and C can also compute N and O respectively if they wish to be able to coordinate Address: N+O+P, A The rest follows as above. The coordinator possesses 2 of 3 needed keys; he can get the other needed part of the signature/key images from either of the other two. Alternatively, if secure communication exists between parties: A gives j to B B gives k to C C gives m to A Address: J+K+M, A 3 of 3 Identical to 2 of 2, except the coordinator must collect the key images from both of the others. The transaction must also be passed an additional hop: A -> B -> C (or A -> C -> B), who can then broadcast it or send it back to A. N-1 of N Generally the same as 2 of 3, except participants need to be arranged in a ring to pass their keys around (using either the secure or insecure method). For example (ignoring viewkey so letters line up): [4 of 5] User: spendkey A: a B: b C: c D: d E: e a -> B, b -> C, c -> D, d -> E, e -> A Order of signing does not matter, it just must reach n-1 users. A "remaining keys" list must be passed around with the transaction so the signers know if they should use 1 or both keys. Collecting key image parts becomes a little messy, but basically every wallet sends over both of their parts with a tag for each. Thia way the coordinating wallet can keep track of which images have been added and which wallet they come from. Reasoning: 1. The key images must be added only once (coordinator will get key images for key a from both A and B, he must add only one to get the proper key actual key image) 2. The coordinator must keep track of which helper pubkeys came from which wallet (discussed in 2 of 2 section). The coordinator must choose only one set to use, then include his choice in the "remaining keys" list so the other wallets know which of their keys to use. You can generalize it further to N-2 of N or even M of N, but I'm not sure there's legitimate demand to justify the complexity. It might also be straightforward enough to support with minimal changes from N-1 format. You basically just give each user additional keys for each additional "-1" you desire. N-2 would be 3 keys per user, N-3 4 keys, etc. The process is somewhat cumbersome: To create a N/N multisig wallet: - each participant creates a normal wallet - each participant runs "prepare_multisig", and sends the resulting string to every other participant - each participant runs "make_multisig N A B C D...", with N being the threshold and A B C D... being the strings received from other participants (the threshold must currently equal N) As txes are received, participants' wallets will need to synchronize so that those new outputs may be spent: - each participant runs "export_multisig FILENAME", and sends the FILENAME file to every other participant - each participant runs "import_multisig A B C D...", with A B C D... being the filenames received from other participants Then, a transaction may be initiated: - one of the participants runs "transfer ADDRESS AMOUNT" - this partly signed transaction will be written to the "multisig_monero_tx" file - the initiator sends this file to another participant - that other participant runs "sign_multisig multisig_monero_tx" - the resulting transaction is written to the "multisig_monero_tx" file again - if the threshold was not reached, the file must be sent to another participant, until enough have signed - the last participant to sign runs "submit_multisig multisig_monero_tx" to relay the transaction to the Monero network
2017-12-08return subaddress in get_bulk_paymentsDmitriy Plekhanov1-0/+1
2017-11-27new wipeable_string class to replace std::string passphrasesmoneromooo-monero1-1/+2
2017-11-24wallet_rpc_server: new relay_tx commandmoneromooo-monero1-0/+41
It takes a full tx+metadata hex string as input
2017-11-24wallet: transfer RPC can now return tx metadata (pending_tx)moneromooo-monero1-3/+39
2017-11-21Spend proof without txkeystoffu1-0/+50
2017-11-21fix for tx proof: use exception instead of error_str when signature gen failedstoffu1-6/+1
2017-11-18Tx proof (revised):stoffu1-0/+161
- refactoring: proof generation/checking code was moved from simplewallet.cpp to wallet2.cpp - allow an arbitrary message to be signed together with txid - introduce two types (outbound & inbound) of tx proofs; with the same syntax, inbound is selected when <address> belongs to this wallet, outbound otherwise. see GitHub thread for more discussion - wallet RPC: added get_tx_key, check_tx_key, get_tx_proof, check_tx_proof - wallet API: moved WalletManagerImpl::checkPayment to Wallet::checkTxKey, added Wallet::getTxProof/checkTxProof - get_tx_key/check_tx_key: handle additional tx keys by concatenating them into a single string
2017-11-15Wallet RPC: Add prompt-for-password flagTim L1-5/+8
2017-11-15Add out-of-bound exceptions and handle them in RPCMichał Sałaban1-21/+21
2017-11-15simplewallet: wrong ns for input_line in sweep_single (fix #2634)stoffu1-1/+1
2017-11-15wallet: add sweep_single commandstoffu1-0/+96
2017-11-14More missed readline dependencies thru scoped_message_writerHoward Chu1-2/+1
2017-11-14wallet: move some scoped_message_writer calls from the libsmoneromooo-monero1-1/+11
2017-11-14wallet: rejig to avoid prompting in wallet2moneromooo-monero1-5/+15
wallet2 is a library, and should not prompt for stdin. Instead, pass a function so simplewallet can prompt on stdin, and a GUI might display a window, etc.
2017-11-14simplewallet: reject attempts to use too low mixin earlymoneromooo-monero1-16/+3
This yields a clear error message rather then some possibly confusing more technical errors down the line
2017-11-06track double spending in the txpoolmoneromooo-monero1-6/+8
Transactions in the txpool are marked when another transaction is seen double spending one or more of its inputs. This is then exposed wherever appropriate. Note that being marked with this "double spend seen" flag does NOT mean this transaction IS a double spend and will never be mined: it just means that the network has seen at least another transaction spending at least one of the same inputs, so care should be taken to wait for a few confirmations before acting upon that transaction (ie, mostly of use for merchants wanting to accept unconfirmed transactions).
2017-11-03Fix file permission issueTim L1-0/+0
This branch fixes a file permission issue introduced by https://github.com/monero-project/monero/commit/69c37200aa87f100f731e755bdca7a0dc6ae820a
2017-10-30RPC Add cross origin resource sharing supportTim L1-1/+1
2017-10-23Add more specific RPC error codesMichał Sałaban1-96/+91
2017-10-16Wallet: Descriptions through new commands 'set_description', 'get_description'rbrunner71-0/+29
2017-10-15Fix compiler warnings with Clang 6.0.0.Vasil Dimov1-1/+1
monero/src/cryptonote_protocol/block_queue.cpp:208:44: error: suggest braces around initialization of subobject [-Werror,-Wmissing-braces] static const boost::uuids::uuid uuid0 = {0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0}; ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~ { } monero/src/wallet/wallet_rpc_server.cpp:1895:43: error: lambda capture 'wal' is not used [-Werror,-Wunused-lambda-capture] tools::signal_handler::install([&wrpc, &wal](int) { ^ monero/src/cryptonote_protocol/cryptonote_protocol_handler.inl:1616:40: error: lambda capture 'arg' is not used [-Werror,-Wunused-lambda-capture] m_p2p->for_each_connection([this, &arg, &fluffy_arg, &exclude_context, &fullConnections... ^ monero/src/cryptonote_protocol/cryptonote_protocol_handler.inl:1616:46: error: lambda capture 'fluffy_arg' is not used [-Werror,-Wunused-lambda-capture] m_p2p->for_each_connection([this, &arg, &fluffy_arg, &exclude_context, &fullConnections... ^ monero/src/blockchain_utilities/blockchain_export.cpp:181:3: error: bool literal returned from 'main' [-Werror,-Wmain] CHECK_AND_ASSERT_MES(r, false, "Failed to initialize source blockchain storage"); ^ ~~~~~ monero/contrib/epee/include/misc_log_ex.h:180:97: note: expanded from macro 'CHECK_AND_ASSERT_MES' ...fail_ret_val, message) do{if(!(expr)) {LOG_ERROR(message); return fail_ret_val;};}while(0) ^ ~~~~~~~~~~~~ monero/src/blockchain_utilities/blockchain_export.cpp:195:3: error: bool literal returned from 'main' [-Werror,-Wmain] CHECK_AND_ASSERT_MES(r, false, "Failed to export blockchain raw data"); ^ ~~~~~ monero/contrib/epee/include/misc_log_ex.h:180:97: note: expanded from macro 'CHECK_AND_ASSERT_MES' ...fail_ret_val, message) do{if(!(expr)) {LOG_ERROR(message); return fail_ret_val;};}while(0) ^ ~~~~~~~~~~~~
2017-10-07Subaddresseskenshi841-42/+183
2017-10-07Don't try to create wallet-dir when it's not given, don't crash if ↵Michał Sałaban1-1/+1
wallet-dir already exists.
2017-09-25move checkpoints in a separate librarymoneromooo-monero1-3/+3
2017-09-25wallet_rpc_server: catch failure to create directorymoneromooo-monero1-1/+10
CID 175281
2017-09-25wallet_rpc_server: init m_vm to NULL in ctormoneromooo-monero1-1/+1
CID 175279
2017-09-25wallet_rpc_server: guard against exceptionsmoneromooo-monero1-1/+9
CID 175305
2017-09-13wallet_rpc_server: fix index for newly added address book entrymoneromooo-monero1-1/+1
2017-08-30Do not create file when RPC user/pass is given and use file lockingLee Clagett1-29/+20
2017-08-12wallet_rpc_server: adjust small ring sizes to 5 for v6moneromooo-monero1-11/+17
2017-08-11wallet_rpc_server: fix possible privacy leak in on_import_key_images()Jaquee1-1/+6
2017-08-07change mixin to ring size in user visible placesmoneromooo-monero1-2/+2
2017-08-02wallet: return unlock_time in get_transfersmoneromooo-monero1-0/+4
also show it in simplewallet's show_transfer
2017-07-27Move OpenAlias console input back from libsmoneromooo-monero1-6/+49
Library code should definitely not ask for console input unless it's clearly an input function. Delegating the user interaction part to the caller means it can now be used by a GUI, or have a decision algorithm better adapted to a particular caller.
2017-07-26wallet_rpc_server: optionally return tx blobs on transfer callsmoneromooo-monero1-7/+38
also add do_not_relay flag to them, so it now becomes possible to create a tx without sending it yet
2017-06-26Minor cleanup: tab vs. space + logs messagesbinaryFate1-3/+3
2017-06-26Fix #2120: return per-tx amount in transfer_split RPC call.binaryFate1-0/+7
2017-06-23Fix on_transfer RPC incorrect logging infoMike C1-1/+1
2017-04-24wallet: add sweep_below functionmoneromooo-monero1-1/+1
It sweeps all outputs below the given threshold This is available via the existing sweep_all RPC, by setting amount_threshold the desired amount (in atomic units)
2017-04-11Resolve #92 add ability to create wallets thru RPCHoward Chu1-94/+326
Reviewed and squashed. Open/Create is only allowed if no walletfile was specified at startup.
2017-03-20wallet rpc: enable solo miningstoffu1-0/+51
2017-03-19wallet-rpc bugfix: get_transfer_by_txid previously checking against payment idkenshi841-1/+1
2017-03-18wallet_rpc_server: make a few RPCs unavailable in restricted modemoneromooo-monero1-0/+28
Address book modification, setting tx nodes, importing key images
2017-03-18use const references in catch blocksmoneromooo-monero1-8/+8
2017-03-18wallet_rpc_server: add a rescan_spent RPCmoneromooo-monero1-0/+22
2017-03-17wallet-rpc: enable openaliasstoffu1-3/+3
2017-02-28wallet: fix --log-file not workingmoneromooo-monero1-0/+1
2017-02-24wallet_rpc_server: new --trusted-daemon flagmoneromooo-monero1-5/+16
and remove trusted_daemon fields from transfer RPCs, it is much friendlier on users
2017-02-21update copyright year, fix occasional lack of newline at line endRiccardo Spagni1-1/+1
2017-02-14simplewallet: validate hex input sizemoneromooo-monero1-4/+4
2017-02-08extract some basic code from libcryptonote_core into libcryptonote_basickenshi841-2/+2
2017-02-06Add server auth to monerod, and client auth to wallet-cli and wallet-rpcLee Clagett1-62/+25
2017-02-04wallet_rpc_server: add address book RPC callsmoneromooo-monero1-0/+98
2017-01-29wallet_rpc_server: fix short payment id validation in transfermoneromooo-monero1-1/+1
2017-01-28wallet_rpc_server: fix logs going to the wrong filemoneromooo-monero1-4/+2
2017-01-16wallet2: reuse fake outs when adjusting fee on transfermoneromooo-monero1-0/+5
This avoids indirectly leaking the real output to the daemon, and is faster. This will still happen for more complex cases, especially when cancelling a tx and "re-rolling" it.
2017-01-16Change logging to easylogging++moneromooo-monero1-5/+9
This replaces the epee and data_loggers logging systems with a single one, and also adds filename:line and explicit severity levels. Categories may be defined, and logging severity set by category (or set of categories). epee style 0-4 log level maps to a sensible severity configuration. Log files now also rotate when reaching 100 MB. To select which logs to output, use the MONERO_LOGS environment variable, with a comma separated list of categories (globs are supported), with their requested severity level after a colon. If a log matches more than one such setting, the last one in the configuration string applies. A few examples: This one is (mostly) silent, only outputting fatal errors: MONERO_LOGS=*:FATAL This one is very verbose: MONERO_LOGS=*:TRACE This one is totally silent (logwise): MONERO_LOGS="" This one outputs all errors and warnings, except for the "verify" category, which prints just fatal errors (the verify category is used for logs about incoming transactions and blocks, and it is expected that some/many will fail to verify, hence we don't want the spam): MONERO_LOGS=*:WARNING,verify:FATAL Log levels are, in decreasing order of priority: FATAL, ERROR, WARNING, INFO, DEBUG, TRACE Subcategories may be added using prefixes and globs. This example will output net.p2p logs at the TRACE level, but all other net* logs only at INFO: MONERO_LOGS=*:ERROR,net*:INFO,net.p2p:TRACE Logs which are intended for the user (which Monero was using a lot through epee, but really isn't a nice way to go things) should use the "global" category. There are a few helper macros for using this category, eg: MGINFO("this shows up by default") or MGINFO_RED("this is red"), to try to keep a similar look and feel for now. Existing epee log macros still exist, and map to the new log levels, but since they're used as a "user facing" UI element as much as a logging system, they often don't map well to log severities (ie, a log level 0 log may be an error, or may be something we want the user to see, such as an important info). In those cases, I tried to use the new macros. In other cases, I left the existing macros in. When modifying logs, it is probably best to switch to the new macros with explicit levels. The --log-level options and set_log commands now also accept category settings, in addition to the epee style log levels.
2017-01-11Added (not yet enabled) HTTP client authenticationLee Clagett1-1/+1
2017-01-08wallet_rpc_server: new RPC call to get a transfer by txidmoneromooo-monero1-61/+152
2016-12-19Refactored password prompting for walletsLee Clagett1-3/+3
2016-12-16Enabled HTTP auth support for monero-wallet-rpcLee Clagett1-7/+91
2016-12-05Added confirmation before binding wallet-rpc to external IPLee Clagett1-11/+30
2016-12-04Fix a few minor typosPierre Boyer1-1/+1
2016-11-28wallet: add API and RPC to create/parse monero: URIsmoneromooo-monero1-0/+27
2016-11-16wallet: return fee in transfer RPCmoneromooo-monero1-0/+4
2016-11-10Created monero-wallet-rpc, moving functionality from monero-wallet-cliLee Clagett1-10/+117
2016-09-18epee: optionally restrict HTTP service to a configurable user agentmoneromooo-monero1-1/+4
This is intended to catch traffic coming from a web browser, so we avoid issues with a web page sending a transfer RPC to the wallet. Requiring a particular user agent can act as a simple password scheme, while we wait for 0MQ and proper authentication to be merged.