aboutsummaryrefslogtreecommitdiff
path: root/src/qt/paymentserver.cpp
AgeCommit message (Collapse)Author
2014-12-08[Qt] update paymentserver license and cleanup orderingPhilip Kaufmann
2014-12-08[Qt] add BIP70 payment request size DoS protection for URIsPhilip Kaufmann
- current code only does this for payment request files, which are used on Mac - also rename readPaymentRequest to readPaymentRequestFromFile, so it's obvious that function only handles payment request files and not URIs - small logging changes in readPaymentRequestFromFile
2014-12-08[Qt] remove dup lock that is done in SetAddressBook()Philip Kaufmann
2014-12-08[Qt] ensure socket is set to NULL in PaymentServer::ipcSendCommandLinePhilip Kaufmann
2014-12-08[Qt] add BIP70/BIP71 constants for all messages and mime typesPhilip Kaufmann
- also rename current ones to match the new ones - remove constant from guiconstant.h and add it to paymentserver.cpp
2014-12-08[Qt] make PaymentServer::ipcParseCommandLine voidPhilip Kaufmann
- the function only returned true, so make it void - add a comment about payment request network detection
2014-09-26Use a typedef for monetary valuesMark Friedenbach
2014-09-16Move CTxDestination from script/script to script/standardPieter Wuille
2014-09-10Merge pull request #4623Wladimir J. van der Laan
e84843c Broken addresses on command line no longer trigger testnet. (Ross Nicoll)
2014-08-30Broken addresses on command line no longer trigger testnet.Ross Nicoll
When passing a bitcoin: URI on the command line, invalid addresses do not incorrectly send the user to the test network.
2014-08-26Split up util.cpp/hWladimir J. van der Laan
Split up util.cpp/h into: - string utilities (hex, base32, base64): no internal dependencies, no dependency on boost (apart from foreach) - money utilities (parsesmoney, formatmoney) - time utilities (gettime*, sleep, format date): - and the rest (logging, argument parsing, config file parsing) The latter is basically the environment and OS handling, and is stripped of all utility functions, so we may want to rename it to something else than util.cpp/h for clarity (Matt suggested osinterface). Breaks dependency of sha256.cpp on all the things pulled in by util.
2014-08-04qt: Demote ReportInvalidCertificate message to qDebugWladimir J. van der Laan
Too spammy.
2014-07-31qt: Update some messages after suggestions by translatorsWladimir J. van der Laan
- *cannot* is more common, thus preferred to *can not* - Use *Watch-only* instead of *Watchonly* as one word
2014-07-08Payment request parsing on startup now only changes network if a valid ↵Ross Nicoll
network name is specified.
2014-07-07remove SOCKS4 support from core and GUIPhilip Kaufmann
- now we support SOCKS5 only
2014-07-03Move fee policy out of coreGavin Andresen
2014-07-02qt: fix 'opens in testnet mode when presented with a BIP-72 link with no ↵Julian Haight
fallback' Passes tests: ``` $ ./bitcoin-qt 'bitcoin:?r=http://www.example.com/' .. fixed the original problem - this launches mainnet. $ ./bitcoin-qt 'bitcoin:mngeNQbTKnmaMbx8EXCYdwUbnt9JJD52cC' .. launches testnet $ ./bitcoin-qt -testnet 'bitcoin:1NXXeQRyMFFFRfyUix2o7mk1vhvk2Nxp78' .. sanity check - launches mainnet. ``` Fixes #4355. Closes #4411.
2014-07-01qt: Change serious messages from qDebug to qWarningWladimir J. van der Laan
By changing the logging stream for warnings from qDebug to qWarning, these will always be logged to debug.log.
2014-06-25Remove unnecessary dependencies for bitcoin-cliWladimir J. van der Laan
This commit removes all the unnecessary dependencies (key, core, netbase, sync, ...) from bitcoin-cli. To do this it shards the chain parameters into BaseParams, which contains just the RPC port and data directory (as used by utils and bitcoin-cli) and Params, with the rest.
2014-06-16Remove `using namespace std` from header fileWladimir J. van der Laan
It's considered bad form to import things into the global namespace in a header. Put it in the cpp files where it is needed instead.
2014-06-12add NetworkIDString() to chainparamsPhilip Kaufmann
- returns the BIP70 network string - use that new function in the core and GUI code and remove unused code and functions
2014-06-09Merge pull request #3824Wladimir J. van der Laan
f0a83fc Use Params().NetworkID() instead of TestNet() from the payment protocol (jtimon) 2871889 net.h was using std namespace through chainparams.h included in protocol.h (jtimon) c8c52de Replace virtual methods with static attributes, chainparams.h depends on protocol.h instead of the other way around (jtimon) a3d946e Get rid of TestNet() (jtimon) 6fc0fa6 Add RPCisTestNet chain parameter (jtimon) cfeb823 Add RequireStandard chain parameter (jtimon) 21913a9 Add AllowMinDifficultyBlocks chain parameter (jtimon) d754f34 Move majority constants to chainparams (jtimon) 8d26721 Get rid of RegTest() (jtimon) cb9bd83 Add DefaultCheckMemPool chain parameter (jtimon) 2595b9a Add DefaultMinerThreads chain parameter (jtimon) bfa9a1a Add MineBlocksOnDemand chain parameter (jtimon) 1712adb Add MiningRequiresPeers chain parameter (jtimon)
2014-06-06Type-safe CFeeRate classGavin Andresen
Use CFeeRate instead of an int64_t for quantities that are fee-per-size. Helps prevent unit-conversion mismatches between the wallet, relaying, and mining code.
2014-06-04Use Params().NetworkID() instead of TestNet() from the payment protocoljtimon
2014-05-06[Qt] ensure payment request network matches client networkPhilip Kaufmann
- replaces checks in SendCoinsDialog::handlePaymentRequest() that belong to PaymentServer (normal URIs are special cased, as only an isValid check is done on BTC addresses) - prevents the client to handle payment requests that do not match the clients network and shows an error instead (mainly a problem with drag&drop payment requests onto the client window) - includes some small comment changes also
2014-01-17[Qt] let OptionsModel::getProxySettings() directly query proxyPhilip Kaufmann
- as a proxy set via GUI can be overridden via -proxy, directly query the core to get active proxy - give a warning, if active proxy is not SOCKS5 (needs to be SOCKS5 for the Qt networking code to work) - also remove an obsolete connect() call from optionsdialog.cpp and a reference to Bitcoin-Qt (now just GUI)
2014-01-14[Qt] small paymentserver header cleanupPhilip Kaufmann
2014-01-13Merge pull request #3374Wladimir J. van der Laan
bd70562 [Qt] add messages when handling local payment request files (Philip Kaufmann)
2014-01-10Merge pull request #3488Wladimir J. van der Laan
2102ab9 ui: Fix GUI initialization order (Wladimir J. van der Laan)
2014-01-06qt: protect SetAddressBook with cs_wallet lock everywhereWladimir J. van der Laan
2014-01-05ui: Fix GUI initialization orderWladimir J. van der Laan
Fixes at least #3478. Splits and documents the phases: 1. Parse command-line options. These take precedence over anything else. 2. Basic Qt initialization (not dependent on parameters or configuration) 3. Application identification 4. Initialization of translations 5. Now that settings and translations are available, ask user for data directory 6. Determine availability of data directory and parse bitcoin.conf 7. URI IPC sending 8. Main GUI initialization Splits command line parsing logic from ipcSendCommandLine into ipcParseCommandLine, as isTestNet() can only be overridden in the early stages before choosing a data directory. Sending however needs to happen after choosing a data directory.
2013-12-10[Qt] add messages when handling local payment request filesPhilip Kaufmann
- important for the open URI dialog to give users feedback when a file is invalid etc.
2013-12-06[Qt] misc PaymentServer changes (e.g. changes to eventFilter())Philip Kaufmann
- make eventFilter() private and pass events on to QObject::eventFilter() instead of just returning false - re-work paymentservertest.cpp to correctly handle the event test after the above change (rewrite test_main to allow usage of QCoreApplication:: in the tests) - delete socket when we were unable to connect in ipcSendCommandLine() - show a message to the user if we fail to start-up (instead of just a debug.log entry) - misc small comment changes
2013-12-04Payment request URI syntax changed, from request=... to r=...Gavin Andresen
BIP 72 was changed to save six bytes in bitcoin: URIs.
2013-11-11[Qt] paymentserver: start netManager in uiReady()Philip Kaufmann
- remove explicit init of netManager as this is done in the constructor anyway - move initNetManager() call to uiReady(), which removes an assert() and allows us to use message() in initNetManager() (currently unused but could be necessary because of proxy related messages) - make initNetManager() private - update paymentservertests.cpp
2013-11-10Cleanup code using forward declarations.Brandon Dahler
Use misc methods of avoiding unnecesary header includes. Replace int typedefs with int##_t from stdint.h. Replace PRI64[xdu] with PRI[xdu]64 from inttypes.h. Normalize QT_VERSION ifs where possible. Resolve some indirect dependencies as direct ones. Remove extern declarations from .cpp files.
2013-11-06Merge pull request #3145Wladimir J. van der Laan
395d0d5 rework an ugly hack in processPaymentRequest() (Philip Kaufmann) 952d2cd make processPaymentRequest() use a single SendCoinsRecipient (Philip Kaufmann) 983cef4 payment-request UI: use SendCoinsRecipient.message for memo (Philip Kaufmann) c6c97e0 [Qt] Rework of payment request UI (mainly for insecure pr) (Philip Kaufmann)
2013-11-04qt: add license header to source filesWladimir J. van der Laan
Closes #839
2013-10-31rework an ugly hack in processPaymentRequest()Philip Kaufmann
- use a QStringList to store valid addresses and format them for GUI and debug.log usage via .join()
2013-10-31make processPaymentRequest() use a single SendCoinsRecipientPhilip Kaufmann
- as one this pulls main purpose is to change a payment request to be displayed as a single sendcoins entry
2013-10-31payment-request UI: use SendCoinsRecipient.message for memoPhilip Kaufmann
2013-10-31[Qt] Rework of payment request UI (mainly for insecure pr)Philip Kaufmann
- this shows insecure (unsecured) payment requests in a new yellowish colored UI (based on the secure payment request UI) instead of our normal payment UI - allows us to receive paymentACK messages for insecure payment requests - allows us to handle expirations for insecure payment request - changed walletmodel, so that all types of payment requests don't touch the addressbook
2013-10-30re-work -debug switch handlingPhilip Kaufmann
- re-work -debug help message text - make -debug log every debugging information again (even all categories) - remove unneeded fDebug checks in front of LogPrint()/qDebug(), as that check is done in LogPrintf() when category is != NULL (true for all LogPrint() calls - remove fDebug ONLY in code which is NOT performance-critical - harmonize addrman category name - deprecate -debugnet usage, should be used via -debug=net and remove the corresponding global
2013-10-25Merge pull request #3130 from Diapolo/paymentACK_via_messageWladimir J. van der Laan
Qt: move paymentACK handling to paymentserver
2013-10-24paymentserver: init all class members in constructorPhilip Kaufmann
2013-10-24Qt: move paymentACK handling to paymentserverPhilip Kaufmann
- add new slot handlePaymentACK() to paymentserver, which handles paymentACK messages (currently we just display them) - make paymentACK message a modal information dialog - change some QObject::tr() to just tr() - clarify the processPaymentRequest() error, when IsDust() - small string change to prevent a tripple + usage with QString
2013-10-20Merge pull request #3119Pieter Wuille
db0e8cc Bump Year Number to 2013 (super3)
2013-10-20Bump Year Number to 2013super3
2013-10-19paymentserver: style fixes / cleanupPhilip Kaufmann
- rename reportError() into message() to be in line with our default message() signal/slot naming (and can be used for all types of messages) - rename some QStrings to not collide with message() function - add a missing message for malformed URIs that IS also used in BitcoinGUI - fix / extend some comments and misc style fixes
2013-10-11paymentserver: use own HTML-esc / add new header constPhilip Kaufmann
- make processPaymentRequest() use our own HTML-escaping function from GUIUtil - make string "application/bitcoin-payment" a constant (below similar constant strings in the .cpp file)