diff --git a/src/addrman.h b/src/addrman.h index ae977a70f..6be2d839f 100644 --- a/src/addrman.h +++ b/src/addrman.h @@ -1,667 +1,667 @@ // Copyright (c) 2012 Pieter Wuille // Copyright (c) 2012-2016 The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #ifndef BITCOIN_ADDRMAN_H #define BITCOIN_ADDRMAN_H #include #include #include #include #include #include #include #include #include #include /** * Extended statistics about a CAddress */ class CAddrInfo : public CAddress { public: //! last try whatsoever by us (memory only) int64_t nLastTry; //! last counted attempt (memory only) int64_t nLastCountAttempt; private: //! where knowledge about this address first came from CNetAddr source; //! last successful connection by us int64_t nLastSuccess; //! connection attempts since last successful attempt int nAttempts; //! reference count in new sets (memory only) int nRefCount; //! in tried set? (memory only) bool fInTried; //! position in vRandom int nRandomPos; friend class CAddrMan; public: ADD_SERIALIZE_METHODS; template inline void SerializationOp(Stream &s, Operation ser_action) { READWRITEAS(CAddress, *this); READWRITE(source); READWRITE(nLastSuccess); READWRITE(nAttempts); } void Init() { nLastSuccess = 0; nLastTry = 0; nLastCountAttempt = 0; nAttempts = 0; nRefCount = 0; fInTried = false; nRandomPos = -1; } CAddrInfo(const CAddress &addrIn, const CNetAddr &addrSource) : CAddress(addrIn), source(addrSource) { Init(); } CAddrInfo() : CAddress(), source() { Init(); } //! Calculate in which "tried" bucket this entry belongs int GetTriedBucket(const uint256 &nKey) const; //! Calculate in which "new" bucket this entry belongs, given a certain //! source int GetNewBucket(const uint256 &nKey, const CNetAddr &src) const; //! Calculate in which "new" bucket this entry belongs, using its default //! source int GetNewBucket(const uint256 &nKey) const { return GetNewBucket(nKey, source); } //! Calculate in which position of a bucket to store this entry. int GetBucketPosition(const uint256 &nKey, bool fNew, int nBucket) const; //! Determine whether the statistics about this entry are bad enough so that //! it can just be deleted bool IsTerrible(int64_t nNow = GetAdjustedTime()) const; //! Calculate the relative chance this entry should be given when selecting //! nodes to connect to double GetChance(int64_t nNow = GetAdjustedTime()) const; }; /** Stochastic address manager * * Design goals: * * Keep the address tables in-memory, and asynchronously dump the entire * table to peers.dat. * * Make sure no (localized) attacker can fill the entire table with his * nodes/addresses. * * To that end: * * Addresses are organized into buckets. * * Addresses that have not yet been tried go into 1024 "new" buckets. * * Based on the address range (/16 for IPv4) of the source of * information, 64 buckets are selected at random. * * The actual bucket is chosen from one of these, based on the range in * which the address itself is located. * * One single address can occur in up to 8 different buckets to increase * selection chances for addresses that * are seen frequently. The chance for increasing this multiplicity * decreases exponentially. * * When adding a new address to a full bucket, a randomly chosen entry * (with a bias favoring less recently seen * ones) is removed from it first. * * Addresses of nodes that are known to be accessible go into 256 "tried" * buckets. * * Each address range selects at random 8 of these buckets. * * The actual bucket is chosen from one of these, based on the full * address. * * When adding a new good address to a full bucket, a randomly chosen * entry (with a bias favoring less recently * tried ones) is evicted from it, back to the "new" buckets. * * Bucket selection is based on cryptographic hashing, using a * randomly-generated 256-bit key, which should not * be observable by adversaries. * * Several indexes are kept for high performance. Defining DEBUG_ADDRMAN * will introduce frequent (and expensive) * consistency checks for the entire data structure. */ //! total number of buckets for tried addresses #define ADDRMAN_TRIED_BUCKET_COUNT_LOG2 8 //! total number of buckets for new addresses #define ADDRMAN_NEW_BUCKET_COUNT_LOG2 10 //! maximum allowed number of entries in buckets for new and tried addresses #define ADDRMAN_BUCKET_SIZE_LOG2 6 //! over how many buckets entries with tried addresses from a single group (/16 //! for IPv4) are spread #define ADDRMAN_TRIED_BUCKETS_PER_GROUP 8 //! over how many buckets entries with new addresses originating from a single //! group are spread #define ADDRMAN_NEW_BUCKETS_PER_SOURCE_GROUP 64 //! in how many buckets for entries with new addresses a single address may //! occur #define ADDRMAN_NEW_BUCKETS_PER_ADDRESS 8 //! how old addresses can maximally be #define ADDRMAN_HORIZON_DAYS 30 //! after how many failed attempts we give up on a new node #define ADDRMAN_RETRIES 3 //! how many successive failures are allowed ... #define ADDRMAN_MAX_FAILURES 10 //! ... in at least this many days #define ADDRMAN_MIN_FAIL_DAYS 7 //! how recent a successful connection should be before we allow an address to //! be evicted from tried #define ADDRMAN_REPLACEMENT_SECONDS (4 * 60 * 60) //! the maximum percentage of nodes to return in a getaddr call #define ADDRMAN_GETADDR_MAX_PCT 23 //! the maximum number of nodes to return in a getaddr call #define ADDRMAN_GETADDR_MAX 2500 //! Convenience #define ADDRMAN_TRIED_BUCKET_COUNT (1 << ADDRMAN_TRIED_BUCKET_COUNT_LOG2) #define ADDRMAN_NEW_BUCKET_COUNT (1 << ADDRMAN_NEW_BUCKET_COUNT_LOG2) #define ADDRMAN_BUCKET_SIZE (1 << ADDRMAN_BUCKET_SIZE_LOG2) //! the maximum number of tried addr collisions to store #define ADDRMAN_SET_TRIED_COLLISION_SIZE 10 /** * Stochastical (IP) address manager */ class CAddrMan { protected: //! critical section to protect the inner data structures mutable CCriticalSection cs; private: //! last used nId int nIdCount GUARDED_BY(cs); //! table with information about all nIds std::map mapInfo GUARDED_BY(cs); //! find an nId based on its network address std::map mapAddr GUARDED_BY(cs); //! randomly-ordered vector of all nIds std::vector vRandom GUARDED_BY(cs); // number of "tried" entries int nTried GUARDED_BY(cs); //! list of "tried" buckets int vvTried[ADDRMAN_TRIED_BUCKET_COUNT][ADDRMAN_BUCKET_SIZE] GUARDED_BY(cs); //! number of (unique) "new" entries int nNew GUARDED_BY(cs); //! list of "new" buckets int vvNew[ADDRMAN_NEW_BUCKET_COUNT][ADDRMAN_BUCKET_SIZE] GUARDED_BY(cs); //! last time Good was called (memory only) int64_t nLastGood GUARDED_BY(cs); //! Holds addrs inserted into tried table that collide with existing - //! entries. Test-before-evict discpline used to resolve these collisions. + //! entries. Test-before-evict discipline used to resolve these collisions. std::set m_tried_collisions; protected: //! secret key to randomize bucket select with uint256 nKey; //! Source of random numbers for randomization in inner loops FastRandomContext insecure_rand; //! Find an entry. CAddrInfo *Find(const CNetAddr &addr, int *pnId = nullptr) EXCLUSIVE_LOCKS_REQUIRED(cs); //! find an entry, creating it if necessary. //! nTime and nServices of the found node are updated, if necessary. CAddrInfo *Create(const CAddress &addr, const CNetAddr &addrSource, int *pnId = nullptr) EXCLUSIVE_LOCKS_REQUIRED(cs); //! Swap two elements in vRandom. void SwapRandom(unsigned int nRandomPos1, unsigned int nRandomPos2) EXCLUSIVE_LOCKS_REQUIRED(cs); //! Move an entry from the "new" table(s) to the "tried" table void MakeTried(CAddrInfo &info, int nId) EXCLUSIVE_LOCKS_REQUIRED(cs); //! Delete an entry. It must not be in tried, and have refcount 0. void Delete(int nId) EXCLUSIVE_LOCKS_REQUIRED(cs); //! Clear a position in a "new" table. This is the only place where entries //! are actually deleted. void ClearNew(int nUBucket, int nUBucketPos) EXCLUSIVE_LOCKS_REQUIRED(cs); //! Mark an entry "good", possibly moving it from "new" to "tried". void Good_(const CService &addr, bool test_before_evict, int64_t time) EXCLUSIVE_LOCKS_REQUIRED(cs); //! Add an entry to the "new" table. bool Add_(const CAddress &addr, const CNetAddr &source, int64_t nTimePenalty) EXCLUSIVE_LOCKS_REQUIRED(cs); //! Mark an entry as attempted to connect. void Attempt_(const CService &addr, bool fCountFailure, int64_t nTime) EXCLUSIVE_LOCKS_REQUIRED(cs); //! Select an address to connect to, if newOnly is set to true, only the new //! table is selected from. CAddrInfo Select_(bool newOnly) EXCLUSIVE_LOCKS_REQUIRED(cs); //! See if any to-be-evicted tried table entries have been tested and if so //! resolve the collisions. void ResolveCollisions_() EXCLUSIVE_LOCKS_REQUIRED(cs); //! Return a random to-be-evicted tried table address. CAddrInfo SelectTriedCollision_() EXCLUSIVE_LOCKS_REQUIRED(cs); #ifdef DEBUG_ADDRMAN //! Perform consistency check. Returns an error code or zero. int Check_() EXCLUSIVE_LOCKS_REQUIRED(cs); #endif //! Select several addresses at once. void GetAddr_(std::vector &vAddr) EXCLUSIVE_LOCKS_REQUIRED(cs); //! Mark an entry as currently-connected-to. void Connected_(const CService &addr, int64_t nTime) EXCLUSIVE_LOCKS_REQUIRED(cs); //! Update an entry's service bits. void SetServices_(const CService &addr, ServiceFlags nServices) EXCLUSIVE_LOCKS_REQUIRED(cs); public: /** * serialized format: * * version byte (currently 1) * * 0x20 + nKey (serialized as if it were a vector, for backward * compatibility) * * nNew * * nTried * * number of "new" buckets XOR 2**30 * * all nNew addrinfos in vvNew * * all nTried addrinfos in vvTried * * for each bucket: * * number of elements * * for each element: index * * 2**30 is xorred with the number of buckets to make addrman deserializer * v0 detect it as incompatible. This is necessary because it did not check * the version number on deserialization. * * Notice that vvTried, mapAddr and vVector are never encoded explicitly; * they are instead reconstructed from the other information. * * vvNew is serialized, but only used if ADDRMAN_UNKNOWN_BUCKET_COUNT didn't * change, otherwise it is reconstructed as well. * * This format is more complex, but significantly smaller (at most 1.5 MiB), * and supports changes to the ADDRMAN_ parameters without breaking the * on-disk structure. * * We don't use ADD_SERIALIZE_METHODS since the serialization and * deserialization code has very little in common. */ template void Serialize(Stream &s) const { LOCK(cs); uint8_t nVersion = 1; s << nVersion; s << uint8_t(32); s << nKey; s << nNew; s << nTried; int nUBuckets = ADDRMAN_NEW_BUCKET_COUNT ^ (1 << 30); s << nUBuckets; std::map mapUnkIds; int nIds = 0; for (const auto &entry : mapInfo) { mapUnkIds[entry.first] = nIds; const CAddrInfo &info = entry.second; if (info.nRefCount) { // this means nNew was wrong, oh ow assert(nIds != nNew); s << info; nIds++; } } nIds = 0; for (const auto &entry : mapInfo) { const CAddrInfo &info = entry.second; if (info.fInTried) { // this means nTried was wrong, oh ow assert(nIds != nTried); s << info; nIds++; } } for (int bucket = 0; bucket < ADDRMAN_NEW_BUCKET_COUNT; bucket++) { int nSize = 0; for (int i = 0; i < ADDRMAN_BUCKET_SIZE; i++) { if (vvNew[bucket][i] != -1) nSize++; } s << nSize; for (int i = 0; i < ADDRMAN_BUCKET_SIZE; i++) { if (vvNew[bucket][i] != -1) { int nIndex = mapUnkIds[vvNew[bucket][i]]; s << nIndex; } } } } template void Unserialize(Stream &s) { LOCK(cs); Clear(); uint8_t nVersion; s >> nVersion; uint8_t nKeySize; s >> nKeySize; if (nKeySize != 32) { throw std::ios_base::failure( "Incorrect keysize in addrman deserialization"); } s >> nKey; s >> nNew; s >> nTried; int nUBuckets = 0; s >> nUBuckets; if (nVersion != 0) { nUBuckets ^= (1 << 30); } if (nNew > ADDRMAN_NEW_BUCKET_COUNT * ADDRMAN_BUCKET_SIZE) { throw std::ios_base::failure( "Corrupt CAddrMan serialization, nNew exceeds limit."); } if (nTried > ADDRMAN_TRIED_BUCKET_COUNT * ADDRMAN_BUCKET_SIZE) { throw std::ios_base::failure( "Corrupt CAddrMan serialization, nTried exceeds limit."); } // Deserialize entries from the new table. for (int n = 0; n < nNew; n++) { CAddrInfo &info = mapInfo[n]; s >> info; mapAddr[info] = n; info.nRandomPos = vRandom.size(); vRandom.push_back(n); if (nVersion != 1 || nUBuckets != ADDRMAN_NEW_BUCKET_COUNT) { // In case the new table data cannot be used (nVersion unknown, // or bucket count wrong), immediately try to give them a // reference based on their primary source address. int nUBucket = info.GetNewBucket(nKey); int nUBucketPos = info.GetBucketPosition(nKey, true, nUBucket); if (vvNew[nUBucket][nUBucketPos] == -1) { vvNew[nUBucket][nUBucketPos] = n; info.nRefCount++; } } } nIdCount = nNew; // Deserialize entries from the tried table. int nLost = 0; for (int n = 0; n < nTried; n++) { CAddrInfo info; s >> info; int nKBucket = info.GetTriedBucket(nKey); int nKBucketPos = info.GetBucketPosition(nKey, false, nKBucket); if (vvTried[nKBucket][nKBucketPos] == -1) { info.nRandomPos = vRandom.size(); info.fInTried = true; vRandom.push_back(nIdCount); mapInfo[nIdCount] = info; mapAddr[info] = nIdCount; vvTried[nKBucket][nKBucketPos] = nIdCount; nIdCount++; } else { nLost++; } } nTried -= nLost; // Deserialize positions in the new table (if possible). for (int bucket = 0; bucket < nUBuckets; bucket++) { int nSize = 0; s >> nSize; for (int n = 0; n < nSize; n++) { int nIndex = 0; s >> nIndex; if (nIndex >= 0 && nIndex < nNew) { CAddrInfo &info = mapInfo[nIndex]; int nUBucketPos = info.GetBucketPosition(nKey, true, bucket); if (nVersion == 1 && nUBuckets == ADDRMAN_NEW_BUCKET_COUNT && vvNew[bucket][nUBucketPos] == -1 && info.nRefCount < ADDRMAN_NEW_BUCKETS_PER_ADDRESS) { info.nRefCount++; vvNew[bucket][nUBucketPos] = nIndex; } } } } // Prune new entries with refcount 0 (as a result of collisions). int nLostUnk = 0; for (std::map::const_iterator it = mapInfo.begin(); it != mapInfo.end();) { if (it->second.fInTried == false && it->second.nRefCount == 0) { std::map::const_iterator itCopy = it++; Delete(itCopy->first); nLostUnk++; } else { it++; } } if (nLost + nLostUnk > 0) { LogPrint(BCLog::ADDRMAN, "addrman lost %i new and %i tried addresses due to " "collisions\n", nLostUnk, nLost); } Check(); } void Clear() { LOCK(cs); std::vector().swap(vRandom); nKey = insecure_rand.rand256(); for (size_t bucket = 0; bucket < ADDRMAN_NEW_BUCKET_COUNT; bucket++) { for (size_t entry = 0; entry < ADDRMAN_BUCKET_SIZE; entry++) { vvNew[bucket][entry] = -1; } } for (size_t bucket = 0; bucket < ADDRMAN_TRIED_BUCKET_COUNT; bucket++) { for (size_t entry = 0; entry < ADDRMAN_BUCKET_SIZE; entry++) { vvTried[bucket][entry] = -1; } } nIdCount = 0; nTried = 0; nNew = 0; // Initially at 1 so that "never" is strictly worse. nLastGood = 1; mapInfo.clear(); mapAddr.clear(); } CAddrMan() { Clear(); } ~CAddrMan() { nKey.SetNull(); } //! Return the number of (unique) addresses in all tables. size_t size() const { // TODO: Cache this in an atomic to avoid this overhead LOCK(cs); return vRandom.size(); } //! Consistency check void Check() { #ifdef DEBUG_ADDRMAN { LOCK(cs); int err; if ((err = Check_())) { LogPrintf("ADDRMAN CONSISTENCY CHECK FAILED!!! err=%i\n", err); } } #endif } //! Add a single address. bool Add(const CAddress &addr, const CNetAddr &source, int64_t nTimePenalty = 0) { LOCK(cs); bool fRet = false; Check(); fRet |= Add_(addr, source, nTimePenalty); Check(); if (fRet) { LogPrint(BCLog::ADDRMAN, "Added %s from %s: %i tried, %i new\n", addr.ToStringIPPort(), source.ToString(), nTried, nNew); } return fRet; } //! Add multiple addresses. bool Add(const std::vector &vAddr, const CNetAddr &source, int64_t nTimePenalty = 0) { LOCK(cs); int nAdd = 0; Check(); for (const CAddress &a : vAddr) { nAdd += Add_(a, source, nTimePenalty) ? 1 : 0; } Check(); if (nAdd) { LogPrint(BCLog::ADDRMAN, "Added %i addresses from %s: %i tried, %i new\n", nAdd, source.ToString(), nTried, nNew); } return nAdd > 0; } //! Mark an entry as accessible. void Good(const CService &addr, bool test_before_evict = true, int64_t nTime = GetAdjustedTime()) { LOCK(cs); Check(); Good_(addr, test_before_evict, nTime); Check(); } //! Mark an entry as connection attempted to. void Attempt(const CService &addr, bool fCountFailure, int64_t nTime = GetAdjustedTime()) { LOCK(cs); Check(); Attempt_(addr, fCountFailure, nTime); Check(); } //! See if any to-be-evicted tried table entries have been tested and if so //! resolve the collisions. void ResolveCollisions() { LOCK(cs); Check(); ResolveCollisions_(); Check(); } //! Randomly select an address in tried that another address is attempting //! to evict. CAddrInfo SelectTriedCollision() { CAddrInfo ret; { LOCK(cs); Check(); ret = SelectTriedCollision_(); Check(); } return ret; } /** * Choose an address to connect to. */ CAddrInfo Select(bool newOnly = false) { CAddrInfo addrRet; { LOCK(cs); Check(); addrRet = Select_(newOnly); Check(); } return addrRet; } //! Return a bunch of addresses, selected at random. std::vector GetAddr() { Check(); std::vector vAddr; { LOCK(cs); GetAddr_(vAddr); } Check(); return vAddr; } //! Mark an entry as currently-connected-to. void Connected(const CService &addr, int64_t nTime = GetAdjustedTime()) { LOCK(cs); Check(); Connected_(addr, nTime); Check(); } void SetServices(const CService &addr, ServiceFlags nServices) { LOCK(cs); Check(); SetServices_(addr, nServices); Check(); } }; #endif // BITCOIN_ADDRMAN_H diff --git a/src/qt/editaddressdialog.h b/src/qt/editaddressdialog.h index d3f5159f2..8bc5026a4 100644 --- a/src/qt/editaddressdialog.h +++ b/src/qt/editaddressdialog.h @@ -1,62 +1,58 @@ // Copyright (c) 2011-2015 The Bitcoin Core developers // Distributed under the MIT software license, see the accompanying // file COPYING or http://www.opensource.org/licenses/mit-license.php. #ifndef BITCOIN_QT_EDITADDRESSDIALOG_H #define BITCOIN_QT_EDITADDRESSDIALOG_H #include class AddressTableModel; namespace Ui { class EditAddressDialog; } QT_BEGIN_NAMESPACE class QDataWidgetMapper; QT_END_NAMESPACE /** * Dialog for editing an address and associated information. */ class EditAddressDialog : public QDialog { Q_OBJECT public: - enum Mode { - NewSendingAddress, - EditReceivingAddress, - EditSendingAddress - }; + enum Mode { NewSendingAddress, EditReceivingAddress, EditSendingAddress }; explicit EditAddressDialog(Mode mode, QWidget *parent = nullptr); ~EditAddressDialog(); void setModel(AddressTableModel *model); void loadRow(int row); QString getAddress() const; void setAddress(const QString &address); public Q_SLOTS: void accept() override; private: bool saveCurrentRow(); /** * Return a descriptive string when adding an already-existing address * fails. */ QString getDuplicateAddressWarning() const; Ui::EditAddressDialog *ui; QDataWidgetMapper *mapper; Mode mode; AddressTableModel *model; QString address; }; #endif // BITCOIN_QT_EDITADDRESSDIALOG_H diff --git a/test/lint/dictionary/english.json b/test/lint/dictionary/english.json index 48ceaa8b9..6b14225ab 100644 --- a/test/lint/dictionary/english.json +++ b/test/lint/dictionary/english.json @@ -1,645 +1,647 @@ { "rules": { "exact": { "abandonning": "abandoning", "abigious": "ambiguous", "abitrate": "arbitrate", "abov": "above", "absense": "absence", "absolut": "absolute", "absoulte": "absolute", "acceleratoin": "acceleration", "accelleration": "acceleration", "accesing": "accessing", "accesnt": "accent", "accessable": "accessible", "accesss": "access", "accidentaly": "accidentally", "accidentually": "accidentally", "accomodate": "accommodate", "accomodates": "accommodates", "accout": "account", "accross": "across", "acess": "access", "acessable": "accessible", "acient": "ancient", "ackowledge": "acknowledge", "ackowledged": "acknowledged", "acknowldegement": "acknowldegement", "acording": "according", "activete": "activate", "acumulating": "accumulating", "addional": "additional", "additionaly": "additionally", "addreses": "addresses", "aditional": "additional", "aditionally": "additionally", "aditionaly": "additionally", "adress": "address", "adresses": "addresses", "adviced": "advised", "afecting": "affecting", "albumns": "albums", "alegorical": "allegorical", "algorith": "algorithm", "algorithmical": "algorithmic", "algoritm": "algorithm", "algoritms": "algorithms", "algorrithm": "algorithm", "algorritm": "algorithm", "allpication": "application", "alogirhtms": "algorithms", "alot": "a lot", "alow": "allow", "alows": "allows", "alreardy": "already", "altough": "although", "ambigious": "ambiguous", "amoung": "among", "amout": "amount", "analysator": "analyzer", "ang": "and", "anniversery": "anniversary", "annoucement": "announcement", "anomolies": "anomalies", "anomoly": "anomaly", "aparent": "apparent", "aplication": "application", "appearence": "appearance", "appliction": "application", "applictions": "applications", "appropiate": "appropriate", "appropriatly": "appropriately", "apropriate": "appropriate", "aquire": "acquire", "aquired": "acquired", "arbitary": "arbitrary", "architechture": "architecture", "arguement": "argument", "arguements": "arguments", "aritmetic": "arithmetic", "arraival": "arrival", "artifical": "artificial", "artillary": "artillery", "assigment": "assignment", "assigments": "assignments", "assistent": "assistant", "asuming": "assuming", "asycronous": "asynchronous", "atomatically": "automatically", "attachement": "attachment", "attemps": "attempts", "attruibutes": "attributes", "authentification": "authentication", "authorative": "authoritative", "automaticaly": "automatically", "automaticly": "automatically", "automatize": "automate", "automatized": "automated", "automatizes": "automates", "autonymous": "autonomous", "auxilliary": "auxiliary", "avaiable": "available", "availabled": "available", "availablity": "availability", "availale": "available", "availavility": "availability", "availble": "available", "availiable": "available", "avaliable": "available", "backgroud": "background", "bahavior": "behavior", "baloon": "balloon", "baloons": "balloons", "bandwith": "bandwidth", "batery": "battery", "becomming": "becoming", "becuase": "because", "begining": "beginning", "bianries": "binaries", "boundries": "boundaries", "calender": "calendar", "cancelation": "cancellation", "cannonical": "canonical", "capabilites": "capabilities", "capatibilities": "capabilities", "cariage": "carriage", "challange": "challenge", "challanges": "challenges", "changable": "changeable", "charachter": "character", "charachters": "characters", "charater": "character", "charaters": "characters", "charcter": "character", "childs": "children", "chnage": "change", "chnages": "changes", "choosen": "chosen", "collapsable": "collapsible", "colorfull": "colorful", "comand": "command", "comit": "commit", "commerical": "commercial", "comminucation": "communication", "commited": "committed", "commiting": "committing", "committ": "commit", "commoditiy": "commodity", "compability": "compatibility", "compatability": "compatibility", "compatable": "compatible", "compatibiliy": "compatibility", "compatibilty": "compatibility", "compilant": "compliant", "compleatly": "completely", "completly": "completely", "complient": "compliant", "compres": "compress", "compresion": "compression", "comression": "compression", "conditionaly": "conditionally", "configuratoin": "configuration", "conjuction": "conjunction", "connectinos": "connections", "connnection": "connection", "connnections": "connections", "consistancy": "consistency", "consistant": "consistent", "containes": "contains", "contaning": "containing", "containts": "contains", "contaisn": "contains", "contence": "contents", "continous": "continuous", "continously": "continuously", "continueing": "continuing", "contraints": "constraints", "convertor": "converter", "convinient": "convenient", "corected": "corrected", "correponding": "corresponding", "correponds": "corresponds", "correspoding": "corresponding", "cryptocraphic": "cryptographic", "curently": "currently", "dafault": "default", "deafult": "default", "deamon": "daemon", "decompres": "decompress", "definate": "definite", "definately": "definitely", "delare": "declare", "delared": "declared", "delares": "declares", "delaring": "declaring", "delemiter": "delimiter", "delemiters": "delimiters", "delimeter": "delimiter", "delimeters": "delimiters", "dependancies": "dependencies", "dependancy": "dependency", "dependant": "dependent", "depreacted": "deprecated", "depreacte": "deprecate", "depricated": "deprecated", "desactivate": "deactivate", "destructable": "destructible", "detabase": "database", "developement": "development", "developped": "developed", "developpement": "development", "developper": "developer", "developpment": "development", "deveolpment": "development", "devided": "divided", "dictionnary": "dictionary", "diplay": "display", "disapeared": "disappeared", "discontiguous": "noncontiguous", "dispertion": "dispersion", "dissapears": "disappears", + "discpline": "discipline", "docuentation": "documentation", "documantation": "documentation", "documentaion": "documentation", "doesen't": "doesn't", "dont": "don't", "downlad": "download", "downlads": "downloads", "easilly": "easily", "ecspecially": "especially", "edditable": "editable", "editting": "editing", "efficently": "efficiently", "eletronic": "electronic", "eligibilty": "eligibility", "embeded": "embedded", "enchanced": "enhanced", "encorporating": "incorporating", "endianess": "endianness", "enhaced": "enhanced", "enlightnment": "enlightenment", "enocded": "encoded", "enterily": "entirely", "envireonment": "environment", "enviroiment": "environment", "enviroment": "environment", "environement": "environment", "environent": "environment", "equiped": "equipped", "equivelant": "equivalent", "equivilant": "equivalent", "estbalishment": "establishment", "etsablishment": "establishment", "etsbalishment": "establishment", "excecutable": "executable", "exceded": "exceeded", "excellant": "excellent", "existant": "existent", "exlcude": "exclude", "exlcusive": "exclusive", "expecially": "especially", "explicitely": "explicitly", "explict": "explicit", "explictly": "explicitly", "expresion": "expression", "exprimental": "experimental", "extensability": "extensibility", "extention": "extension", "extracter": "extractor", "failuer": "failure", "familar": "familiar", "fatser": "faster", "feauture": "feature", "feautures": "features", "fetaure": "feature", "fetaures": "features", "formated": "formatted", "forse": "force", "fortan": "fortran", "forwardig": "forwarding", "framwork": "framework", "fullfill": "fulfill", "fulfilled": "fulfilled", "functionallity": "functionality", "functionaly": "functionally", "functionnality": "functionality", "functiosn": "functions", "functonality": "functionality", "futhermore": "furthermore", "generiously": "generously", "grabing": "grabbing", "grahical": "graphical", "grahpical": "graphical", "grapic": "graphic", "guage": "gauge", "halfs": "halves", "handfull": "handful", "havent": "haven't", "heirarchically": "hierarchically", "helpfull": "helpful", "hierachy": "hierarchy", "heirachy": "hierarchy", "heirarchy": "hierarchy", "hierarchie": "hierarchy", "heirarchie": "hierarchy", "howver": "however", "immeadiately": "immediately", "implemantation": "implementation", "implemention": "implementation", "inadvertantly": "inadvertently", "incomming": "incoming", "incompatabilities": "incompatibilities", "incompatable": "incompatible", "inconsistant": "inconsistent", "indendation": "indentation", "indended": "intended", "independant": "independent", "independed": "independent", "informatiom": "information", "informations": "information", "infromation": "information", "initalize": "initialize", "initators": "initiators", "initializiation": "initialization", "inofficial": "unofficial", "integreated": "integrated", "integrety": "integrity", "integrey": "integrity", "intendet": "intended", "intentially": "intentionally", "interchangable": "interchangeable", "intermittant": "intermittent", "interupted": "interrupted", "intial": "initial", "intialization": "initialization", "intregral": "integral", "intuative": "intuitive", "invokation": "invocation", "invokations": "invocations", "jave": "java", "labled": "labeled", "langage": "language", "langauage": "language", "langauge": "language", "langugage": "language", "lauch": "launch", "leightweight": "lightweight", "lesstiff": "lesstif", "libaries": "libraries", "libary": "library", "librairies": "libraries", "libraris": "libraries", "licenceing": "licencing", "loggging": "logging", "loggin": "login", "logile": "logfile", "machinary": "machinery", "maintainance": "maintenance", "maintainence": "maintenance", "maintan": "maintain", "makeing": "making", "malplace": "misplace", "malplaced": "misplaced", "managable": "manageable", "managment": "management", "manoeuvering": "maneuvering", "mathimatical": "mathematical", "mathimatic": "mathematic", "mathimatics": "mathematics", "ment": "meant", "messsage": "message", "messsages": "messages", "microprocesspr": "microprocessor", "milliseonds": "milliseconds", "miliseconds": "milliseconds", "mimick": "mimic", "miscelleneous": "miscellaneous", "misformed": "malformed", "mispelled": "misspelled", "mispelt": "misspelt", "mmnemonic": "mnemonic", "modulues": "modules", "monochorome": "monochrome", "monochromo": "monochrome", "monocrome": "monochrome", "mroe": "more", "multidimensionnal": "multidimensional", "mulitplied": "multiplied", "mutiple": "multiple", "nam": "name", "nams": "names", "navagating": "navigating", "nead": "need", "neccesary": "necessary", "neccessary": "necessary", "necesary": "necessary", "negotation": "negotiation", "nescessary": "necessary", "nessessary": "necessary", "noticable": "noticeable", "notications": "notifications", "occurence": "occurrence", "occurences": "occurrences", "occationally": "occasionally", "ocurrence": "occurrence", "ocurrences": "occurrences", "ocurs": "occurs", "omitt": "omit", "ommitted": "omitted", "onself": "oneself", "optionnal": "optional", "optmizations": "optimizations", "orientatied": "orientated", "orientied": "oriented", "ouput": "output", "overaall": "overall", "overriden": "overridden", "overwitten": "overwritten", "pacakge": "package", "pachage": "package", "packacge": "package", "packege": "package", "packge": "package", "pakage": "package", "pallette": "palette", "paramameters": "parameters", "paramater": "parameter", "parametes": "parameters", "parametised": "parametrised", "paramter": "parameter", "paramters": "parameters", "particularily": "particularly", "pased": "passed", "pendantic": "pedantic", "peprocessor": "preprocessor", "perfoming": "performing", "permissons": "permissions", "persistant": "persistent", "plattform": "platform", "pleaes": "please", "ploting": "plotting", "poinnter": "pointer", "posible": "possible", "possibilites": "possibilities", "powerfull": "powerful", "preceed": "precede", "preceeded": "preceded", "preceeding": "preceding", "precendence": "precedence", "precission": "precision", "prefered": "preferred", "prefferably": "preferably", "prepaired": "prepared", "primative": "primitive", "princliple": "principle", "priorty": "priority", "priviledge": "privilege", "priviledges": "privileges", "procceed": "proceed", "proccesors": "processors", "proces": "process", "processess": "processes", "processessing": "processing", "processpr": "processor", "processsing": "processing", "progams": "programs", "programers": "programmers", "programm": "program", "programms": "programs", "promps": "prompts", "pronnounced": "pronounced", "prononciation": "pronunciation", "pronouce": "pronounce", "pronunce": "pronounce", "propery": "property", "propigate": "propagate", "propigated": "propagated", "propigates": "propagates", "propogate": "propagate", "propogated": "propagated", "propogates": "propagates", "propigation": "propagation", "prosess": "process", "protable": "portable", "protcol": "protocol", "protecion": "protection", "protocoll": "protocol", "psychadelic": "psychedelic", "quering": "querying", "reasearch": "research", "reasearcher": "researcher", "reasearchers": "researchers", "recogniced": "recognised", "recognizeable": "recognizable", "recommanded": "recommended", "redircet": "redirect", "redirectrion": "redirection", "reenable": "re-enable", "reenabled": "re-enabled", "reencode": "re-encode", "refence": "reference", "registerd": "registered", "registraration": "registration", "regulamentations": "regulations", "relevent": "relevant", "remoote": "remote", "removeable": "removable", "repectively": "respectively", "replacments": "replacements", "replys": "replies", "requiere": "require", "requred": "required", "requried": "required", "resizeable": "resizable", "ressize": "resize", "ressource": "resource", "ressources": "resources", "retransmited": "retransmitted", "retreive": "retrieve", "retreived": "retrieved", "rmeove": "remove", "rmeoved": "removed", "rmeoves": "removes", "runned": "ran", "runnning": "running", "sacrifying": "sacrificing", "safly": "safely", "savable": "saveable", "searchs": "searches", "secund": "second", "seeked": "sought", "separatly": "separately", "sepcify": "specify", "seperated": "separated", "seperately": "separately", "seperate": "separate", "seperatly": "separately", "seperator": "separator", "sepperate": "separate", "sequencial": "sequential", "serveral": "several", "setts": "sets", "similiar": "similar", "simliar": "similar", "softwares": "software", "speach": "speech", "speciefied": "specified", "specifed": "specified", "specificatin": "specification", "specificaton": "specification", "specifing": "specifying", "speficied": "specified", "speling": "spelling", "splitted": "split", "spreaded": "spread", "staically": "statically", "standardss": "standards", "standart": "standard", "staticly": "statically", "subdirectoires": "subdirectories", "suble": "subtle", "succesfully": "successfully", "succesful": "successful", "sucessfully": "successfully", "superflous": "superfluous", "superseeded": "superseded", "suplied": "supplied", "suport": "support", "suppored": "supported", "supportin": "supporting", "suppoted": "supported", "suppported": "supported", "suppport": "support", "supress": "suppress", "surpress": "suppress", "surpresses": "suppresses", "surpesses": "suppresses", "suspicously": "suspiciously", "synax": "syntax", "synchonized": "synchronized", "syncronize": "synchronize", "syncronizing": "synchronizing", "syncronus": "synchronous", "syste": "system", "sytem": "system", "sythesis": "synthesis", "taht": "that", "taget": "target", "taret": "target", "tagets": "targets", "tarets": "targets", "targetted": "targeted", "targetting": "targeting", "teh": "the", "thats": "that's", "throught": "through", + "transation": "transaction", "tranfer": "transfer", "transfered": "transferred", "transfering": "transferring", "trasmission": "transmission", "treshold": "threshold", "trigerring": "triggering", "unconditionaly": "unconditionally", "unecessary": "unnecessary", "unexecpted": "unexpected", "unfortunatelly": "unfortunately", "unintentially": "unintentionally", "unknonw": "unknown", "unkown": "unknown", "unneedingly": "unnecessarily", "unuseful": "useless", "upto": "up to", "usefule": "useful", "usefull": "useful", "usege": "usage", "usera": "users", "usualy": "usually", "utilites": "utilities", "utillities": "utilities", "utilties": "utilities", "utiltity": "utility", "utitlty": "utility", "variantions": "variations", "varient": "variant", "verbse": "verbose", "verisons": "versions", "verison": "version", "verson": "version", "visiters": "visitors", "vitual": "virtual", "whataver": "whatever", "wheter": "whether", "wierd": "weird", "writting": "writing", "yur": "your" }, "partial": { "recieve": "receive", "uft8": "utf8", "lenght": "length", "heigth": "height", "fuction": "function" } } } diff --git a/test/util/data/bitcoin-util-test.json b/test/util/data/bitcoin-util-test.json index 73fd9a954..5123d3c64 100644 --- a/test/util/data/bitcoin-util-test.json +++ b/test/util/data/bitcoin-util-test.json @@ -1,328 +1,328 @@ [ { "exec": "./bitcoin-tx", "args": ["-create", "nversion=1"], "output_cmp": "blanktxv1.hex", "description": "Creates a blank v1 transaction" }, { "exec": "./bitcoin-tx", "args": ["-json","-create", "nversion=1"], "output_cmp": "blanktxv1.json", "description": "Creates a blank v1 transaction (output in json)" }, { "exec": "./bitcoin-tx", "args": ["-"], "input": "blanktxv2.hex", "output_cmp": "blanktxv2.hex", "description": "Creates a blank transaction when nothing is piped into bitcoin-tx" }, { "exec": "./bitcoin-tx", "args": ["-json","-create"], "output_cmp": "blanktxv2.json", "description": "Creates a blank transaction (output in json)" }, { "exec": "./bitcoin-tx", "args": ["-json","-"], "input": "blanktxv2.hex", "output_cmp": "blanktxv2.json", "description": "Creates a blank transaction when nothing is piped into bitcoin-tx (output in json)" }, { "exec": "./bitcoin-tx", "args": ["-", "delin=1"], "input": "tx394b54bb.hex", "output_cmp": "tt-delin1-out.hex", "description": "Deletes a single input from a transaction" }, { "exec": "./bitcoin-tx", "args": ["-json", "-", "delin=1"], "input": "tx394b54bb.hex", "output_cmp": "tt-delin1-out.json", "description": "Deletes a single input from a transaction (output in json)" }, { "exec": "./bitcoin-tx", "args": ["-", "delin=31"], "input": "tx394b54bb.hex", "return_code": 1, "error_txt": "error: Invalid TX input index '31'", "description": "Attempts to delete an input with a bad index from a transaction. Expected to fail." }, { "exec": "./bitcoin-tx", "args": ["-", "delout=1"], "input": "tx394b54bb.hex", "output_cmp": "tt-delout1-out.hex", "description": "Deletes a single output from a transaction" }, { "exec": "./bitcoin-tx", "args": ["-json", "-", "delout=1"], "input": "tx394b54bb.hex", "output_cmp": "tt-delout1-out.json", "description": "Deletes a single output from a transaction (output in json)" }, { "exec": "./bitcoin-tx", "args": ["-", "delout=2"], "input": "tx394b54bb.hex", "return_code": 1, "error_txt": "error: Invalid TX output index '2'", "description": "Attempts to delete an output with a bad index from a transaction. Expected to fail." }, { "exec": "./bitcoin-tx", "args": ["-", "locktime=317000"], "input": "tx394b54bb.hex", "output_cmp": "tt-locktime317000-out.hex", "description": "Adds an nlocktime to a transaction" }, { "exec": "./bitcoin-tx", "args": ["-json", "-", "locktime=317000"], "input": "tx394b54bb.hex", "output_cmp": "tt-locktime317000-out.json", "description": "Adds an nlocktime to a transaction (output in json)" }, { "exec": "./bitcoin-tx", "args": ["-create", "outaddr=1"], "return_code": 1, "error_txt": "error: TX output missing or too many separators", "description": "Malformed outaddr argument (no address specified). Expected to fail." }, { "exec": "./bitcoin-tx", "args": ["-create", "outaddr=1:13tuJJDR2RgArmgfv6JScSdreahzgc4T6o:garbage"], "return_code": 1, "error_txt": "error: TX output missing or too many separators", "description": "Malformed outaddr argument (too many separators). Expected to fail." }, { "exec": "./bitcoin-tx", "args": ["-create", "outpubkey=0"], "return_code": 1, "error_txt": "error: TX output missing or too many separators", "description": "Malformed outpubkey argument (no pubkey specified). Expected to fail." }, { "exec": "./bitcoin-tx", "args": ["-create", "outpubkey=0:02a5613bd857b7048924264d1e70e08fb2a7e6527d32b7ab1bb993ac59964ff397:W:non53nse"], "return_code": 1, "error_txt": "error: TX output missing or too many separators", "description": "Malformed outpubkey argument (too many separators). Expected to fail." }, { "exec": "./bitcoin-tx", "args": ["-create", "in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0", "in=bf829c6bcf84579331337659d31f89dfd138f7f7785802d5501c92333145ca7c:18", "in=22a6f904655d53ae2ff70e701a0bbd90aa3975c0f40bfc6cc996a9049e31cdfc:1", "outaddr=0.18:13tuJJDR2RgArmgfv6JScSdreahzgc4T6o", "outaddr=4:1P8yWvZW8jVihP1bzHeqfE4aoXNX8AVa46"], "output_cmp": "txcreate1.hex", "description": "Creates a new transaction with three inputs and two outputs" }, { "exec": "./bitcoin-tx", "args": ["-json", "-create", "in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0", "in=bf829c6bcf84579331337659d31f89dfd138f7f7785802d5501c92333145ca7c:18", "in=22a6f904655d53ae2ff70e701a0bbd90aa3975c0f40bfc6cc996a9049e31cdfc:1", "outaddr=0.18:13tuJJDR2RgArmgfv6JScSdreahzgc4T6o", "outaddr=4:1P8yWvZW8jVihP1bzHeqfE4aoXNX8AVa46"], "output_cmp": "txcreate1.json", "description": "Creates a new transaction with three inputs and two outputs (output in json)" }, { "exec": "./bitcoin-tx", "args": ["-create", "outscript=0:"], "output_cmp": "txcreate2.hex", "description": "Creates a new transaction with a single empty output script" }, { "exec": "./bitcoin-tx", "args": ["-json", "-create", "outscript=0:"], "output_cmp": "txcreate2.json", "description": "Creates a new transaction with a single empty output script (output in json)" }, { "exec": "./bitcoin-tx", "args": ["02000000000100000000000000000000000000"], "output_cmp": "txcreate2.hex", - "description": "Parses a transation with no inputs and a single output script" + "description": "Parses a transaction with no inputs and a single output script" }, { "exec": "./bitcoin-tx", "args": ["-json", "02000000000100000000000000000000000000"], "output_cmp": "txcreate2.json", - "description": "Parses a transation with no inputs and a single output script (output in json)" + "description": "Parses a transaction with no inputs and a single output script (output in json)" }, { "exec": "./bitcoin-tx", "args": ["-create", "outscript=0:OP_DROP", "nversion=1"], "output_cmp": "txcreatescript1.hex", "description": "Create a new transaction with a single output script (OP_DROP)" }, { "exec": "./bitcoin-tx", "args": ["-json", "-create", "outscript=0:OP_DROP", "nversion=1"], "output_cmp": "txcreatescript1.json", "description": "Create a new transaction with a single output script (OP_DROP) (output as json)" }, { "exec": "./bitcoin-tx", "args": ["-create", "outscript=0:OP_DROP:S", "nversion=1"], "output_cmp": "txcreatescript2.hex", "description": "Create a new transaction with a single output script (OP_DROP) in a P2SH" }, { "exec": "./bitcoin-tx", "args": ["-json", "-create", "outscript=0:OP_DROP:S", "nversion=1"], "output_cmp": "txcreatescript2.json", "description": "Create a new transaction with a single output script (OP_DROP) in a P2SH (output as json)" }, { "exec": "./bitcoin-tx", "args": ["-create", "nversion=1", "in=4d49a71ec9da436f71ec4ee231d04f292a29cd316f598bb7068feccabdc59485:0", "set=privatekeys:[\"5HpHagT65TZzG1PH3CSu63k8DbpvD8s5ip4nEB3kEsreAnchuDf\"]", "set=prevtxs:[{\"txid\":\"4d49a71ec9da436f71ec4ee231d04f292a29cd316f598bb7068feccabdc59485\",\"vout\":0,\"scriptPubKey\":\"76a91491b24bf9f5288532960ac687abb035127b1d28a588ac\"}]", "sign=ALL", "outaddr=0.001:193P6LtvS4nCnkDvM9uXn1gsSRqh4aDAz7"], "output_cmp": "txcreatesignv1.hex", "description": "Creates a new v1 transaction with a single input and a single output, and then signs the transaction" }, { "exec": "./bitcoin-tx", "args": ["-json", "-create", "nversion=1", "in=4d49a71ec9da436f71ec4ee231d04f292a29cd316f598bb7068feccabdc59485:0", "set=privatekeys:[\"5HpHagT65TZzG1PH3CSu63k8DbpvD8s5ip4nEB3kEsreAnchuDf\"]", "set=prevtxs:[{\"txid\":\"4d49a71ec9da436f71ec4ee231d04f292a29cd316f598bb7068feccabdc59485\",\"vout\":0,\"scriptPubKey\":\"76a91491b24bf9f5288532960ac687abb035127b1d28a588ac\"}]", "sign=ALL", "outaddr=0.001:193P6LtvS4nCnkDvM9uXn1gsSRqh4aDAz7"], "output_cmp": "txcreatesignv1.json", "description": "Creates a new v1 transaction with a single input and a single output, and then signs the transaction (output in json)" }, { "exec": "./bitcoin-tx", "args": ["-create", "in=4d49a71ec9da436f71ec4ee231d04f292a29cd316f598bb7068feccabdc59485:0", "set=privatekeys:[\"5HpHagT65TZzG1PH3CSu63k8DbpvD8s5ip4nEB3kEsreAnchuDf\"]", "set=prevtxs:[{\"txid\":\"4d49a71ec9da436f71ec4ee231d04f292a29cd316f598bb7068feccabdc59485\",\"vout\":0,\"scriptPubKey\":\"76a91491b24bf9f5288532960ac687abb035127b1d28a588ac\"}]", "sign=ALL", "outaddr=0.001:193P6LtvS4nCnkDvM9uXn1gsSRqh4aDAz7"], "output_cmp": "txcreatesignv2.hex", "description": "Creates a new transaction with a single input and a single output, and then signs the transaction" }, { "exec": "./bitcoin-tx", "args": ["-create", "outpubkey=0:02a5613bd857b7048924264d1e70e08fb2a7e6527d32b7ab1bb993ac59964ff397", "nversion=1"], "output_cmp": "txcreateoutpubkey1.hex", "description": "Creates a new transaction with a single pay-to-pubkey output" }, { "exec": "./bitcoin-tx", "args": ["-json", "-create", "outpubkey=0:02a5613bd857b7048924264d1e70e08fb2a7e6527d32b7ab1bb993ac59964ff397", "nversion=1"], "output_cmp": "txcreateoutpubkey1.json", "description": "Creates a new transaction with a single pay-to-pubkey output (output as json)" }, { "exec": "./bitcoin-tx", "args": ["-create", "in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0", "outdata=4:badhexdata"], "return_code": 1, "error_txt": "error: invalid TX output data", "description": "Attempts to create a new transaction with one input and an output with malformed hex data. Expected to fail" }, { "exec": "./bitcoin-tx", "args": ["-create", "in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0", "outdata=badhexdata"], "return_code": 1, "error_txt": "error: invalid TX output data", "description": "Attempts to create a new transaction with one input and an output with no value and malformed hex data. Expected to fail" }, { "exec": "./bitcoin-tx", "args": ["-create", "in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0", "outaddr=0.18:13tuJJDR2RgArmgfv6JScSdreahzgc4T6o", "outdata=4:54686973204f505f52455455524e207472616e73616374696f6e206f7574707574207761732063726561746564206279206d6f646966696564206372656174657261777472616e73616374696f6e2e"], "output_cmp": "txcreatedata1.hex", "description": "Creates a new transaction with one input, one address output and one data output" }, { "exec": "./bitcoin-tx", "args": ["-json", "-create", "nversion=1", "in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0", "outaddr=0.18:13tuJJDR2RgArmgfv6JScSdreahzgc4T6o", "outdata=4:54686973204f505f52455455524e207472616e73616374696f6e206f7574707574207761732063726561746564206279206d6f646966696564206372656174657261777472616e73616374696f6e2e"], "output_cmp": "txcreatedata1.json", "description": "Creates a new v1 transaction with one input, one address output and one data output (output in json)" }, { "exec": "./bitcoin-tx", "args": ["-create", "in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0", "outaddr=0.18:13tuJJDR2RgArmgfv6JScSdreahzgc4T6o", "outdata=54686973204f505f52455455524e207472616e73616374696f6e206f7574707574207761732063726561746564206279206d6f646966696564206372656174657261777472616e73616374696f6e2e"], "output_cmp": "txcreatedata2.hex", "description": "Creates a new transaction with one input, one address output and one data (zero value) output" }, { "exec": "./bitcoin-tx", "args": ["-json", "-create", "in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0", "outaddr=0.18:13tuJJDR2RgArmgfv6JScSdreahzgc4T6o", "outdata=54686973204f505f52455455524e207472616e73616374696f6e206f7574707574207761732063726561746564206279206d6f646966696564206372656174657261777472616e73616374696f6e2e"], "output_cmp": "txcreatedata2.json", "description": "Creates a new transaction with one input, one address output and one data (zero value) output (output in json)" }, { "exec": "./bitcoin-tx", "args": ["-create", "in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0:4294967293", "outaddr=0.18:13tuJJDR2RgArmgfv6JScSdreahzgc4T6o"], "output_cmp": "txcreatedata_seq0.hex", "description": "Creates a new transaction with one input with sequence number and one address output" }, { "exec": "./bitcoin-tx", "args": ["-json", "-create", "in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0:4294967293", "outaddr=0.18:13tuJJDR2RgArmgfv6JScSdreahzgc4T6o"], "output_cmp": "txcreatedata_seq0.json", "description": "Creates a new transaction with one input with sequence number and one address output (output in json)" }, { "exec": "./bitcoin-tx", "args": ["01000000011f5c38dfcf6f1a5f5a87c416076d392c87e6d41970d5ad5e477a02d66bde97580000000000fdffffff0180a81201000000001976a9141fc11f39be1729bf973a7ab6a615ca4729d6457488ac00000000", "in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0:1"], "output_cmp": "txcreatedata_seq1.hex", "description": "Adds a new input with sequence number to a transaction" }, { "exec": "./bitcoin-tx", "args": ["-json", "01000000011f5c38dfcf6f1a5f5a87c416076d392c87e6d41970d5ad5e477a02d66bde97580000000000fdffffff0180a81201000000001976a9141fc11f39be1729bf973a7ab6a615ca4729d6457488ac00000000", "in=5897de6bd6027a475eadd57019d4e6872c396d0716c4875a5f1a6fcfdf385c1f:0:1"], "output_cmp": "txcreatedata_seq1.json", "description": "Adds a new input with sequence number to a transaction (output in json)" }, { "exec": "./bitcoin-tx", "args": ["-create", "outmultisig=1:2:3:02a5613bd857b7048924264d1e70e08fb2a7e6527d32b7ab1bb993ac59964ff397:021ac43c7ff740014c3b33737ede99c967e4764553d1b2b83db77c83b8715fa72d:02df2089105c77f266fa11a9d33f05c735234075f2e8780824c6b709415f9fb485", "nversion=1"], "output_cmp": "txcreatemultisig1.hex", "description": "Creates a new transaction with a single 2-of-3 multisig output" }, { "exec": "./bitcoin-tx", "args": ["-json", "-create", "outmultisig=1:2:3:02a5613bd857b7048924264d1e70e08fb2a7e6527d32b7ab1bb993ac59964ff397:021ac43c7ff740014c3b33737ede99c967e4764553d1b2b83db77c83b8715fa72d:02df2089105c77f266fa11a9d33f05c735234075f2e8780824c6b709415f9fb485", "nversion=1"], "output_cmp": "txcreatemultisig1.json", "description": "Creates a new transaction with a single 2-of-3 multisig output (output in json)" }, { "exec": "./bitcoin-tx", "args": ["-create", "outmultisig=1:2:3:02a5613bd857b7048924264d1e70e08fb2a7e6527d32b7ab1bb993ac59964ff397:021ac43c7ff740014c3b33737ede99c967e4764553d1b2b83db77c83b8715fa72d:02df2089105c77f266fa11a9d33f05c735234075f2e8780824c6b709415f9fb485:S", "nversion=1"], "output_cmp": "txcreatemultisig2.hex", "description": "Creates a new transaction with a single 2-of-3 multisig in a P2SH output" }, { "exec": "./bitcoin-tx", "args": ["-json", "-create", "outmultisig=1:2:3:02a5613bd857b7048924264d1e70e08fb2a7e6527d32b7ab1bb993ac59964ff397:021ac43c7ff740014c3b33737ede99c967e4764553d1b2b83db77c83b8715fa72d:02df2089105c77f266fa11a9d33f05c735234075f2e8780824c6b709415f9fb485:S", "nversion=1"], "output_cmp": "txcreatemultisig2.json", "description": "Creates a new transaction with a single 2-of-3 multisig in a P2SH output (output in json)" } ]